mirror of
https://github.com/slidevjs/rough-notation.git
synced 2026-01-16 18:27:56 +01:00
initial code
This commit is contained in:
14
src/keyframes.ts
Normal file
14
src/keyframes.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
export function ensureKeyframes() {
|
||||
if (!(window as any).__rough_notation_keyframe_styles) {
|
||||
const style = (window as any).__rough_notation_keyframe_styles = document.createElement('style');
|
||||
style.textContent = `
|
||||
@keyframes rough-notation-dash {
|
||||
to {
|
||||
stroke-dashoffset: 0;
|
||||
}
|
||||
}
|
||||
`;
|
||||
console.log('keyframe added');
|
||||
document.head.appendChild(style);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user