Sha256: c2e08a859d186fb9d172e09abb7db7f84d3d769a618d7fba5fd2620b32e893ee
Contents?: true
Size: 1.31 KB
Versions: 16
Compression:
Stored size: 1.31 KB
Contents
import { registerIconLibrary, setDefaultAnimation } from "shoelace" // Change the default animation for all tooltips setDefaultAnimation("tooltip.show", { keyframes: [ { transform: "translateY(10px)", opacity: "0" }, { transform: "translateY(0)", opacity: "1" } ], options: { duration: 100 } }) setDefaultAnimation("tooltip.hide", { keyframes: [ { transform: "translateY(0)", opacity: "1" }, { transform: "translateY(10px)", opacity: "0" } ], options: { duration: 100 } }) // Change the default animation for all dialogs setDefaultAnimation("dialog.show", { keyframes: [ { transform: "scale(0.98)", opacity: "0" }, { transform: "scale(1)", opacity: "1" } ], options: { duration: 150 } }) setDefaultAnimation("dialog.hide", { keyframes: [ { transform: "scale(1)", opacity: "1" }, { transform: "scale(0.98)", opacity: "0" } ], options: { duration: 150 } }) const spriteUrl = document .querySelector('meta[name="alchemy-icon-sprite"]') .getAttribute("content") const iconMap = { "x-lg": "close" } const options = { resolver: (name) => `${spriteUrl}#ri-${iconMap[name] || name}-line`, mutator: (svg) => svg.setAttribute("fill", "currentColor"), spriteSheet: true } registerIconLibrary("default", options) registerIconLibrary("system", options)
Version data entries
16 entries across 16 versions & 1 rubygems