2023-10-02 10:46:09 +00:00
|
|
|
import BaseStyle from 'primevue/base/style';
|
|
|
|
|
|
|
|
const css = `
|
|
|
|
@keyframes ripple {
|
|
|
|
100% {
|
|
|
|
opacity: 0;
|
|
|
|
transform: scale(2.5);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
@layer primevue {
|
|
|
|
.p-ripple {
|
|
|
|
overflow: hidden;
|
|
|
|
position: relative;
|
|
|
|
}
|
|
|
|
|
|
|
|
.p-ink {
|
|
|
|
display: block;
|
|
|
|
position: absolute;
|
|
|
|
background: rgba(255, 255, 255, 0.5);
|
|
|
|
border-radius: 100%;
|
|
|
|
transform: scale(0);
|
|
|
|
pointer-events: none;
|
|
|
|
}
|
|
|
|
|
|
|
|
.p-ink-active {
|
|
|
|
animation: ripple 0.4s linear;
|
|
|
|
}
|
|
|
|
|
|
|
|
.p-ripple-disabled .p-ink {
|
2023-10-17 19:27:27 +00:00
|
|
|
display: none;
|
2023-10-02 10:46:09 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const classes = {
|
|
|
|
root: 'p-ink'
|
|
|
|
};
|
|
|
|
|
|
|
|
export default BaseStyle.extend({
|
|
|
|
name: 'ripple',
|
|
|
|
css,
|
|
|
|
classes
|
|
|
|
});
|