2023-10-02 10:46:09 +00:00
|
|
|
import BaseStyle from 'primevue/base/style';
|
|
|
|
|
2024-05-10 08:32:29 +00:00
|
|
|
const theme = ({ dt }) => `
|
|
|
|
.p-ink {
|
|
|
|
display: block;
|
|
|
|
position: absolute;
|
2024-05-13 11:17:01 +00:00
|
|
|
background: ${dt('ripple.background')};
|
2024-05-10 08:32:29 +00:00
|
|
|
border-radius: 100%;
|
|
|
|
transform: scale(0);
|
|
|
|
pointer-events: none;
|
|
|
|
}
|
|
|
|
|
|
|
|
.p-ink-active {
|
|
|
|
animation: ripple 0.4s linear;
|
|
|
|
}
|
|
|
|
|
|
|
|
@keyframes ripple {
|
|
|
|
100% {
|
|
|
|
opacity: 0;
|
|
|
|
transform: scale(2.5);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
2023-10-02 10:46:09 +00:00
|
|
|
const classes = {
|
|
|
|
root: 'p-ink'
|
|
|
|
};
|
|
|
|
|
|
|
|
export default BaseStyle.extend({
|
2024-03-31 04:44:48 +00:00
|
|
|
name: 'ripple-directive',
|
2024-05-10 08:32:29 +00:00
|
|
|
theme,
|
2023-10-02 10:46:09 +00:00
|
|
|
classes
|
|
|
|
});
|