mirror of
https://github.com/danbulant/dribbblish-dynamic-theme
synced 2026-06-09 09:42:26 +00:00
only show js not installed message after 3s
This commit is contained in:
parent
27cd9a8a0e
commit
7f559d2a2c
2 changed files with 10 additions and 1 deletions
|
|
@ -7,7 +7,7 @@ import moment from "moment";
|
||||||
// Break if Dribbblish has already been initialized
|
// Break if Dribbblish has already been initialized
|
||||||
if ($("html").attr("dribbblish-js-installed") != undefined) throw new Error("Dribbblish has already been initialized");
|
if ($("html").attr("dribbblish-js-installed") != undefined) throw new Error("Dribbblish has already been initialized");
|
||||||
// Remove not installed message
|
// Remove not installed message
|
||||||
$("html").attr("dribbblish-js-installed", " ");
|
$("html").attr("dribbblish-js-installed", "");
|
||||||
|
|
||||||
import { waitForElement, copyToClipboard, capitalizeFirstLetter, getClosestToNum, randomFromArray, debounce } from "./Util";
|
import { waitForElement, copyToClipboard, capitalizeFirstLetter, getClosestToNum, randomFromArray, debounce } from "./Util";
|
||||||
import { default as _Dribbblish } from "./Dribbblish";
|
import { default as _Dribbblish } from "./Dribbblish";
|
||||||
|
|
|
||||||
|
|
@ -30,6 +30,12 @@
|
||||||
--is_dark: calc(1 - var(--is_light));
|
--is_dark: calc(1 - var(--is_light));
|
||||||
|
|
||||||
// Display warning for incorrectly installed js
|
// Display warning for incorrectly installed js
|
||||||
|
@keyframes noJsShow {
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
pointer-events: all;
|
||||||
|
}
|
||||||
|
}
|
||||||
&:not([dribbblish-js-installed])::after {
|
&:not([dribbblish-js-installed])::after {
|
||||||
content: "dribbblish-dynamic.js not installed correctly";
|
content: "dribbblish-dynamic.js not installed correctly";
|
||||||
position: fixed;
|
position: fixed;
|
||||||
|
|
@ -38,6 +44,9 @@
|
||||||
background-color: black;
|
background-color: black;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
line-height: 100vh;
|
line-height: 100vh;
|
||||||
|
opacity: 0;
|
||||||
|
pointer-events: none;
|
||||||
|
animation: noJsShow 0s ease-in 3s forwards;
|
||||||
@include spiceFont("glue", 32px, "Bold");
|
@include spiceFont("glue", 32px, "Bold");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue