Running on 186526 Network.
+ Build in "unknown"
.
Copyright © 2020 - Now 186526.xyz All rights Reserved.
diff --git a/package.json b/package.json index 54c1764..fb39316 100644 --- a/package.json +++ b/package.json @@ -16,6 +16,7 @@ }, "dependencies": { "@vitejs/plugin-legacy": "^1.8.1", + "tippy.js": "^6.3.7", "typed.js": "^2.0.12", "workbox-cdn": "4.2.0" }, diff --git a/src/main.ts b/src/main.ts index 366885c..b57d792 100644 --- a/src/main.ts +++ b/src/main.ts @@ -1,10 +1,15 @@ -const __APP_VERSION__ = "__APP_VERSION"; -const __APP_BUILD_TIME__ = __APP_BUILD_TIME; +const APP_VERSION = __APP_VERSION__; +const APP_BUILD_TIME = __APP_BUILD_TIME__; import "./styles.css"; import Typed from "typed.js"; +import Tippy from 'tippy.js'; + +import 'tippy.js/dist/tippy.css'; +import 'tippy.js/animations/scale.css'; + window.addEventListener("load", (_ev) => { new Typed(document.querySelector("description") ?? "description", { stringsElement: "#description-list", @@ -18,15 +23,18 @@ window.addEventListener("load", (_ev) => { }); document.querySelectorAll("[alt]").forEach((Elem) => { - const tooltip = document.createElement("tooltiptext"); - tooltip.innerText = Elem.getAttribute("alt") ?? ""; - Elem.appendChild(tooltip); + Tippy(Elem, { + content: Elem.getAttribute("alt") ?? "", + }) }); // @ts-expect-error document.querySelector( "#footer > div" - ).innerHTML += `