@sharadox/web-library 0.0.0-stage → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENCA.md +76 -0
- package/LICENSE.md +76 -0
- package/NOTICE.md +3 -0
- package/README.md +34 -2
- package/distribution/animation/in-view/index.d.ts +3 -0
- package/distribution/animation/in-view/index.d.ts.map +1 -0
- package/distribution/animation/in-view/index.js +15 -0
- package/distribution/animation/in-view/index.js.map +1 -0
- package/distribution/animation/reveal/index.d.ts +4 -0
- package/distribution/animation/reveal/index.d.ts.map +1 -0
- package/distribution/animation/reveal/index.js +9 -0
- package/distribution/animation/reveal/index.js.map +1 -0
- package/distribution/animation/reveal/type.d.ts +14 -0
- package/distribution/animation/reveal/type.d.ts.map +1 -0
- package/distribution/animation/reveal/type.js +2 -0
- package/distribution/animation/reveal/type.js.map +1 -0
- package/distribution/animation/scroll-word/index.d.ts +4 -0
- package/distribution/animation/scroll-word/index.d.ts.map +1 -0
- package/distribution/animation/scroll-word/index.js +16 -0
- package/distribution/animation/scroll-word/index.js.map +1 -0
- package/distribution/animation/scroll-word/type.d.ts +11 -0
- package/distribution/animation/scroll-word/type.d.ts.map +1 -0
- package/distribution/animation/scroll-word/type.js +2 -0
- package/distribution/animation/scroll-word/type.js.map +1 -0
- package/distribution/animation/scroll-word/word/index.d.ts +4 -0
- package/distribution/animation/scroll-word/word/index.d.ts.map +1 -0
- package/distribution/animation/scroll-word/word/index.js +10 -0
- package/distribution/animation/scroll-word/word/index.js.map +1 -0
- package/distribution/animation/scroll-word/word/type.d.ts +14 -0
- package/distribution/animation/scroll-word/word/type.d.ts.map +1 -0
- package/distribution/animation/scroll-word/word/type.js +2 -0
- package/distribution/animation/scroll-word/word/type.js.map +1 -0
- package/distribution/animation/smooth-scroll/index.d.ts +4 -0
- package/distribution/animation/smooth-scroll/index.d.ts.map +1 -0
- package/distribution/animation/smooth-scroll/index.js +33 -0
- package/distribution/animation/smooth-scroll/index.js.map +1 -0
- package/distribution/animation/smooth-scroll/type.d.ts +7 -0
- package/distribution/animation/smooth-scroll/type.d.ts.map +1 -0
- package/distribution/animation/smooth-scroll/type.js +2 -0
- package/distribution/animation/smooth-scroll/type.js.map +1 -0
- package/distribution/class-name/index.d.ts +3 -0
- package/distribution/class-name/index.d.ts.map +1 -0
- package/distribution/class-name/index.js +5 -0
- package/distribution/class-name/index.js.map +1 -0
- package/distribution/form/bot-check/index.d.ts +4 -0
- package/distribution/form/bot-check/index.d.ts.map +1 -0
- package/distribution/form/bot-check/index.js +6 -0
- package/distribution/form/bot-check/index.js.map +1 -0
- package/distribution/form/bot-check/type.d.ts +11 -0
- package/distribution/form/bot-check/type.d.ts.map +1 -0
- package/distribution/form/bot-check/type.js +2 -0
- package/distribution/form/bot-check/type.js.map +1 -0
- package/distribution/form/field/index.d.ts +3 -0
- package/distribution/form/field/index.d.ts.map +1 -0
- package/distribution/form/field/index.js +7 -0
- package/distribution/form/field/index.js.map +1 -0
- package/distribution/form/rate-limit/index.d.ts +4 -0
- package/distribution/form/rate-limit/index.d.ts.map +1 -0
- package/distribution/form/rate-limit/index.js +14 -0
- package/distribution/form/rate-limit/index.js.map +1 -0
- package/distribution/form/rate-limit/type.d.ts +9 -0
- package/distribution/form/rate-limit/type.d.ts.map +1 -0
- package/distribution/form/rate-limit/type.js +2 -0
- package/distribution/form/rate-limit/type.js.map +1 -0
- package/distribution/html/escape/index.d.ts +3 -0
- package/distribution/html/escape/index.d.ts.map +1 -0
- package/distribution/html/escape/index.js +6 -0
- package/distribution/html/escape/index.js.map +1 -0
- package/distribution/internationalization/locale/index.d.ts +7 -0
- package/distribution/internationalization/locale/index.d.ts.map +1 -0
- package/distribution/internationalization/locale/index.js +17 -0
- package/distribution/internationalization/locale/index.js.map +1 -0
- package/distribution/internationalization/locale/type.d.ts +3 -0
- package/distribution/internationalization/locale/type.d.ts.map +1 -0
- package/distribution/internationalization/locale/type.js +2 -0
- package/distribution/internationalization/locale/type.js.map +1 -0
- package/distribution/internationalization/locale-redirect/index.d.ts +7 -0
- package/distribution/internationalization/locale-redirect/index.d.ts.map +1 -0
- package/distribution/internationalization/locale-redirect/index.js +16 -0
- package/distribution/internationalization/locale-redirect/index.js.map +1 -0
- package/distribution/internationalization/locale-redirect/type.d.ts +12 -0
- package/distribution/internationalization/locale-redirect/type.d.ts.map +1 -0
- package/distribution/internationalization/locale-redirect/type.js +2 -0
- package/distribution/internationalization/locale-redirect/type.js.map +1 -0
- package/distribution/internationalization/translate/index.d.ts +4 -0
- package/distribution/internationalization/translate/index.d.ts.map +1 -0
- package/distribution/internationalization/translate/index.js +5 -0
- package/distribution/internationalization/translate/index.js.map +1 -0
- package/distribution/math/clamp/index.d.ts +3 -0
- package/distribution/math/clamp/index.d.ts.map +1 -0
- package/distribution/math/clamp/index.js +5 -0
- package/distribution/math/clamp/index.js.map +1 -0
- package/distribution/math/pseudo-random/index.d.ts +3 -0
- package/distribution/math/pseudo-random/index.d.ts.map +1 -0
- package/distribution/math/pseudo-random/index.js +6 -0
- package/distribution/math/pseudo-random/index.js.map +1 -0
- package/distribution/math/radians/index.d.ts +3 -0
- package/distribution/math/radians/index.d.ts.map +1 -0
- package/distribution/math/radians/index.js +5 -0
- package/distribution/math/radians/index.js.map +1 -0
- package/distribution/pointer/spotlight/index.d.ts +3 -0
- package/distribution/pointer/spotlight/index.d.ts.map +1 -0
- package/distribution/pointer/spotlight/index.js +20 -0
- package/distribution/pointer/spotlight/index.js.map +1 -0
- package/distribution/search-engine/robots/index.d.ts +4 -0
- package/distribution/search-engine/robots/index.d.ts.map +1 -0
- package/distribution/search-engine/robots/index.js +7 -0
- package/distribution/search-engine/robots/index.js.map +1 -0
- package/distribution/search-engine/robots/type.d.ts +17 -0
- package/distribution/search-engine/robots/type.d.ts.map +1 -0
- package/distribution/search-engine/robots/type.js +2 -0
- package/distribution/search-engine/robots/type.js.map +1 -0
- package/distribution/search-engine/sitemap/index.d.ts +4 -0
- package/distribution/search-engine/sitemap/index.d.ts.map +1 -0
- package/distribution/search-engine/sitemap/index.js +12 -0
- package/distribution/search-engine/sitemap/index.js.map +1 -0
- package/distribution/search-engine/sitemap/type.d.ts +22 -0
- package/distribution/search-engine/sitemap/type.d.ts.map +1 -0
- package/distribution/search-engine/sitemap/type.js +2 -0
- package/distribution/search-engine/sitemap/type.js.map +1 -0
- package/distribution/search-engine/structured-data/index.d.ts +4 -0
- package/distribution/search-engine/structured-data/index.d.ts.map +1 -0
- package/distribution/search-engine/structured-data/index.js +6 -0
- package/distribution/search-engine/structured-data/index.js.map +1 -0
- package/distribution/search-engine/structured-data/type.d.ts +5 -0
- package/distribution/search-engine/structured-data/type.d.ts.map +1 -0
- package/distribution/search-engine/structured-data/type.js +2 -0
- package/distribution/search-engine/structured-data/type.js.map +1 -0
- package/distribution/test/visual-snapshot/index.d.ts +8 -0
- package/distribution/test/visual-snapshot/index.d.ts.map +1 -0
- package/distribution/test/visual-snapshot/index.js +20 -0
- package/distribution/test/visual-snapshot/index.js.map +1 -0
- package/distribution/test/visual-snapshot/type.d.ts +7 -0
- package/distribution/test/visual-snapshot/type.d.ts.map +1 -0
- package/distribution/test/visual-snapshot/type.js +2 -0
- package/distribution/test/visual-snapshot/type.js.map +1 -0
- package/distribution/time/format-time/index.d.ts +3 -0
- package/distribution/time/format-time/index.d.ts.map +1 -0
- package/distribution/time/format-time/index.js +5 -0
- package/distribution/time/format-time/index.js.map +1 -0
- package/distribution/time/open-state/index.d.ts +4 -0
- package/distribution/time/open-state/index.d.ts.map +1 -0
- package/distribution/time/open-state/index.js +11 -0
- package/distribution/time/open-state/index.js.map +1 -0
- package/distribution/time/open-state/type.d.ts +5 -0
- package/distribution/time/open-state/type.d.ts.map +1 -0
- package/distribution/time/open-state/type.js +2 -0
- package/distribution/time/open-state/type.js.map +1 -0
- package/distribution/time/sun-time/index.d.ts +4 -0
- package/distribution/time/sun-time/index.d.ts.map +1 -0
- package/distribution/time/sun-time/index.js +27 -0
- package/distribution/time/sun-time/index.js.map +1 -0
- package/distribution/time/sun-time/type.d.ts +6 -0
- package/distribution/time/sun-time/type.d.ts.map +1 -0
- package/distribution/time/sun-time/type.js +2 -0
- package/distribution/time/sun-time/type.js.map +1 -0
- package/distribution/time/sun-today/index.d.ts +4 -0
- package/distribution/time/sun-today/index.d.ts.map +1 -0
- package/distribution/time/sun-today/index.js +25 -0
- package/distribution/time/sun-today/index.js.map +1 -0
- package/distribution/time/sun-today/type.d.ts +9 -0
- package/distribution/time/sun-today/type.d.ts.map +1 -0
- package/distribution/time/sun-today/type.js +2 -0
- package/distribution/time/sun-today/type.js.map +1 -0
- package/distribution/time/zone-minute/index.d.ts +3 -0
- package/distribution/time/zone-minute/index.d.ts.map +1 -0
- package/distribution/time/zone-minute/index.js +13 -0
- package/distribution/time/zone-minute/index.js.map +1 -0
- package/package.json +99 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../source/time/sun-time/index.ts"],"names":[],"mappings":"AAEA,MAAM,kBAAkB,GAAG,IAAI,CAAC,EAAE,GAAG,GAAG,CAAC;AAEzC,iGAAiG;AACjG,MAAM,UAAU,QAAQ,CAAC,IAAU,EAAE,QAAgB,EAAE,SAAiB;IACtE,MAAM,IAAI,GAAG,IAAI,CAAC,cAAc,EAAE,CAAC;IACnC,MAAM,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,EAAE,EAAE,IAAI,CAAC,UAAU,EAAE,CAAC,CAAC;IACvE,MAAM,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC,CAAC;IAClE,MAAM,SAAS,GAAG,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC,GAAG,GAAG,CAAC,CAAC;IAC1D,MAAM,cAAc,GAClB,MAAM;QACN,CAAC,QAAQ;YACP,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC;YAC9B,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC;YAC9B,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS,CAAC;YAClC,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS,CAAC,CAAC,CAAC;IACxC,MAAM,WAAW,GACf,QAAQ;QACR,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC;QAC9B,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC;QAC9B,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS,CAAC;QAClC,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS,CAAC;QAClC,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS,CAAC;QAClC,OAAO,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS,CAAC,CAAC;IACpC,MAAM,SAAS,GACb,IAAI,CAAC,IAAI,CACP,IAAI,CAAC,GAAG,CAAC,MAAM,GAAG,kBAAkB,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,QAAQ,GAAG,kBAAkB,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC;QACvG,IAAI,CAAC,GAAG,CAAC,QAAQ,GAAG,kBAAkB,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,WAAW,CAAC,CAClE,GAAG,kBAAkB,CAAC;IACzB,MAAM,WAAW,GAAG,GAAG,GAAG,CAAC,GAAG,CAAC,SAAS,GAAG,SAAS,CAAC,GAAG,cAAc,CAAC;IACvE,MAAM,UAAU,GAAG,GAAG,GAAG,CAAC,GAAG,CAAC,SAAS,GAAG,SAAS,CAAC,GAAG,cAAc,CAAC;IACtE,OAAO,EAAE,IAAI,EAAE,IAAI,IAAI,CAAC,QAAQ,GAAG,WAAW,GAAG,GAAG,CAAC,EAAE,GAAG,EAAE,IAAI,IAAI,CAAC,QAAQ,GAAG,UAAU,GAAG,GAAG,CAAC,EAAE,CAAC;AACtG,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"type.d.ts","sourceRoot":"","sources":["../../../source/time/sun-time/type.ts"],"names":[],"mappings":"AAAA,qFAAqF;AACrF,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,IAAI,CAAC;IACX,GAAG,EAAE,IAAI,CAAC;CACX"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"type.js","sourceRoot":"","sources":["../../../source/time/sun-time/type.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { SunToday } from "@sharadox/web-library/time/sun-today/type";
|
|
2
|
+
/** Today's sunrise and sunset at a place (tomorrow's once the sun has set), refreshed every minute. Null until mounted. */
|
|
3
|
+
export declare function useSunToday(latitude: number, longitude: number): SunToday | null;
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../source/time/sun-today/index.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,2CAA2C,CAAC;AAE1E,2HAA2H;AAC3H,wBAAgB,WAAW,CAAC,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,mBAkB9D"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { useEffect, useState } from "react";
|
|
3
|
+
import { sunTimes } from "@sharadox/web-library/time/sun-time";
|
|
4
|
+
/** Today's sunrise and sunset at a place (tomorrow's once the sun has set), refreshed every minute. Null until mounted. */
|
|
5
|
+
export function useSunToday(latitude, longitude) {
|
|
6
|
+
const [sun, setSun] = useState(null);
|
|
7
|
+
useEffect(() => {
|
|
8
|
+
const tick = () => {
|
|
9
|
+
const now = new Date();
|
|
10
|
+
let times = sunTimes(now, latitude, longitude);
|
|
11
|
+
const tomorrow = now > times.set;
|
|
12
|
+
if (tomorrow)
|
|
13
|
+
times = sunTimes(new Date(now.getTime() + 864e5), latitude, longitude);
|
|
14
|
+
setSun({ ...times, now, tomorrow });
|
|
15
|
+
};
|
|
16
|
+
const first = setTimeout(tick, 0);
|
|
17
|
+
const timer = setInterval(tick, 60_000);
|
|
18
|
+
return () => {
|
|
19
|
+
clearTimeout(first);
|
|
20
|
+
clearInterval(timer);
|
|
21
|
+
};
|
|
22
|
+
}, [latitude, longitude]);
|
|
23
|
+
return sun;
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../source/time/sun-today/index.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AACb,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAG/D,2HAA2H;AAC3H,MAAM,UAAU,WAAW,CAAC,QAAgB,EAAE,SAAiB;IAC7D,MAAM,CAAC,GAAG,EAAE,MAAM,CAAC,GAAG,QAAQ,CAAkB,IAAI,CAAC,CAAC;IACtD,SAAS,CAAC,GAAG,EAAE;QACb,MAAM,IAAI,GAAG,GAAG,EAAE;YAChB,MAAM,GAAG,GAAG,IAAI,IAAI,EAAE,CAAC;YACvB,IAAI,KAAK,GAAG,QAAQ,CAAC,GAAG,EAAE,QAAQ,EAAE,SAAS,CAAC,CAAC;YAC/C,MAAM,QAAQ,GAAG,GAAG,GAAG,KAAK,CAAC,GAAG,CAAC;YACjC,IAAI,QAAQ;gBAAE,KAAK,GAAG,QAAQ,CAAC,IAAI,IAAI,CAAC,GAAG,CAAC,OAAO,EAAE,GAAG,KAAK,CAAC,EAAE,QAAQ,EAAE,SAAS,CAAC,CAAC;YACrF,MAAM,CAAC,EAAE,GAAG,KAAK,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;QACtC,CAAC,CAAC;QACF,MAAM,KAAK,GAAG,UAAU,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;QAClC,MAAM,KAAK,GAAG,WAAW,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC;QACxC,OAAO,GAAG,EAAE;YACV,YAAY,CAAC,KAAK,CAAC,CAAC;YACpB,aAAa,CAAC,KAAK,CAAC,CAAC;QACvB,CAAC,CAAC;IACJ,CAAC,EAAE,CAAC,QAAQ,EAAE,SAAS,CAAC,CAAC,CAAC;IAC1B,OAAO,GAAG,CAAC;AACb,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/** Sun times for the relevant evening, plus the moment they were computed for. */
|
|
2
|
+
export interface SunToday {
|
|
3
|
+
rise: Date;
|
|
4
|
+
set: Date;
|
|
5
|
+
now: Date;
|
|
6
|
+
/** After today's sunset these are tomorrow's times. */
|
|
7
|
+
tomorrow: boolean;
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=type.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"type.d.ts","sourceRoot":"","sources":["../../../source/time/sun-today/type.ts"],"names":[],"mappings":"AAAA,kFAAkF;AAClF,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,IAAI,CAAC;IACX,GAAG,EAAE,IAAI,CAAC;IACV,GAAG,EAAE,IAAI,CAAC;IACV,uDAAuD;IACvD,QAAQ,EAAE,OAAO,CAAC;CACnB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"type.js","sourceRoot":"","sources":["../../../source/time/sun-today/type.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../source/time/zone-minute/index.ts"],"names":[],"mappings":"AAAA,kGAAkG;AAClG,wBAAgB,aAAa,CAAC,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,GAAG,MAAM,CAUlE"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/** Minutes since midnight in a time zone for an instant, whatever the visitor's own time zone. */
|
|
2
|
+
export function minutesInZone(date, timeZone) {
|
|
3
|
+
const parts = new Intl.DateTimeFormat("en-GB", {
|
|
4
|
+
timeZone,
|
|
5
|
+
hour: "2-digit",
|
|
6
|
+
minute: "2-digit",
|
|
7
|
+
hourCycle: "h23",
|
|
8
|
+
}).formatToParts(date);
|
|
9
|
+
const hours = Number(parts.find((part) => part.type === "hour")?.value ?? 0);
|
|
10
|
+
const minutes = Number(parts.find((part) => part.type === "minute")?.value ?? 0);
|
|
11
|
+
return hours * 60 + minutes;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../source/time/zone-minute/index.ts"],"names":[],"mappings":"AAAA,kGAAkG;AAClG,MAAM,UAAU,aAAa,CAAC,IAAU,EAAE,QAAgB;IACxD,MAAM,KAAK,GAAG,IAAI,IAAI,CAAC,cAAc,CAAC,OAAO,EAAE;QAC7C,QAAQ;QACR,IAAI,EAAE,SAAS;QACf,MAAM,EAAE,SAAS;QACjB,SAAS,EAAE,KAAK;KACjB,CAAC,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC;IACvB,MAAM,KAAK,GAAG,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,IAAI,KAAK,MAAM,CAAC,EAAE,KAAK,IAAI,CAAC,CAAC,CAAC;IAC7E,MAAM,OAAO,GAAG,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,IAAI,KAAK,QAAQ,CAAC,EAAE,KAAK,IAAI,CAAC,CAAC,CAAC;IACjF,OAAO,KAAK,GAAG,EAAE,GAAG,OAAO,CAAC;AAC9B,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,102 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sharadox/web-library",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Generic building blocks for web applications: internationalization, search engine metadata, animation, time and forms.",
|
|
5
|
+
"private": false,
|
|
6
|
+
"license": "SEE LICENSE IN LICENCA.md",
|
|
7
|
+
"author": "Sharadox <email@sharadox.com>",
|
|
8
|
+
"type": "module",
|
|
9
|
+
"exports": {
|
|
10
|
+
"./*/type": {
|
|
11
|
+
"sharadox-source": "./source/*/type.ts",
|
|
12
|
+
"types": "./distribution/*/type.d.ts"
|
|
13
|
+
},
|
|
14
|
+
"./*": {
|
|
15
|
+
"sharadox-source": [
|
|
16
|
+
"./source/*/index.ts",
|
|
17
|
+
"./source/*/index.tsx"
|
|
18
|
+
],
|
|
19
|
+
"types": "./distribution/*/index.d.ts",
|
|
20
|
+
"default": "./distribution/*/index.js"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"files": [
|
|
24
|
+
"distribution",
|
|
25
|
+
"LICENCA.md",
|
|
26
|
+
"LICENSE.md",
|
|
27
|
+
"NOTICE.md"
|
|
28
|
+
],
|
|
29
|
+
"sideEffects": [
|
|
30
|
+
"**/*.css"
|
|
31
|
+
],
|
|
32
|
+
"engines": {
|
|
33
|
+
"node": ">=20"
|
|
34
|
+
},
|
|
35
|
+
"publishConfig": {
|
|
36
|
+
"access": "public"
|
|
37
|
+
},
|
|
38
|
+
"peerDependencies": {
|
|
39
|
+
"react": ">=19",
|
|
40
|
+
"@playwright/test": ">=1.50"
|
|
41
|
+
},
|
|
42
|
+
"peerDependenciesMeta": {
|
|
43
|
+
"react": {
|
|
44
|
+
"optional": true
|
|
45
|
+
},
|
|
46
|
+
"@playwright/test": {
|
|
47
|
+
"optional": true
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
"lint-staged": {
|
|
51
|
+
"*.{ts,tsx,js,mjs,cjs}": [
|
|
52
|
+
"prettier --write",
|
|
53
|
+
"eslint --fix --max-warnings=0"
|
|
54
|
+
],
|
|
55
|
+
"*.{json,md,yml,yaml,scss}": "prettier --write"
|
|
56
|
+
},
|
|
57
|
+
"devDependencies": {
|
|
58
|
+
"@eslint/js": "^9.39.5",
|
|
59
|
+
"@playwright/test": "1.65.0",
|
|
60
|
+
"@testing-library/dom": "^10.4.2",
|
|
61
|
+
"@testing-library/react": "^16.3.3",
|
|
62
|
+
"@types/node": "^24.19.2",
|
|
63
|
+
"@types/react": "^19.3.0",
|
|
64
|
+
"@vitejs/plugin-react": "^6.3.0",
|
|
65
|
+
"eslint": "9.39.5",
|
|
66
|
+
"eslint-config-prettier": "^10.1.8",
|
|
67
|
+
"eslint-plugin-react-hooks": "^7.1.1",
|
|
68
|
+
"happy-dom": "^21.0.4",
|
|
69
|
+
"husky": "^9.1.7",
|
|
70
|
+
"lint-staged": "^17.6.0",
|
|
71
|
+
"next": "16.4.5",
|
|
72
|
+
"prettier": "^3.9.10",
|
|
73
|
+
"react": "^19.3.1",
|
|
74
|
+
"react-dom": "^19.3.1",
|
|
75
|
+
"sass": "^1.108.1",
|
|
76
|
+
"turbo": "^2.11.10",
|
|
77
|
+
"typedoc": "^0.28.20",
|
|
78
|
+
"typescript": "6.0.3",
|
|
79
|
+
"typescript-eslint": "^8.72.2",
|
|
80
|
+
"vitest": "^5.1.0"
|
|
81
|
+
},
|
|
82
|
+
"repository": {
|
|
83
|
+
"type": "git",
|
|
84
|
+
"url": "git+https://github.com/Sharadox/web-library.git"
|
|
85
|
+
},
|
|
86
|
+
"homepage": "https://github.com/Sharadox/web-library#readme",
|
|
87
|
+
"dependencies": {
|
|
88
|
+
"lenis": "^1.3.27",
|
|
89
|
+
"motion": "^12.43.0"
|
|
90
|
+
},
|
|
91
|
+
"scripts": {
|
|
92
|
+
"build": "rm -rf distribution && tsc -p tsconfig.build.json && sass --no-source-map source:distribution && node script/rewrite-style-import/index.ts",
|
|
93
|
+
"lint": "eslint --max-warnings=0 .",
|
|
94
|
+
"format": "prettier --write .",
|
|
95
|
+
"format:check": "prettier --check .",
|
|
96
|
+
"type-check": "tsc --noEmit",
|
|
97
|
+
"test:unit": "vitest run",
|
|
98
|
+
"test:benchmark": "vitest bench --run --passWithNoTests",
|
|
99
|
+
"documentation": "typedoc",
|
|
100
|
+
"verify": "turbo run format:check lint type-check test:unit test:benchmark build"
|
|
101
|
+
}
|
|
6
102
|
}
|