@lizzelabs/react-harmony 1.0.0 → 1.0.1

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.
Files changed (79) hide show
  1. package/dist/animations-B09mMqCx.js +24 -0
  2. package/dist/animations.es.js +5 -0
  3. package/dist/components/animations/animations.d.ts +5 -0
  4. package/dist/components/animations/animations.hook.d.ts +2 -0
  5. package/dist/components/animations/animations.types.d.ts +16 -0
  6. package/dist/components/animations/index.d.ts +3 -0
  7. package/dist/components/index.d.ts +7 -0
  8. package/dist/components/media/index.d.ts +3 -0
  9. package/dist/components/media/media.d.ts +5 -0
  10. package/dist/components/media/media.hook.d.ts +2 -0
  11. package/dist/components/media/media.types.d.ts +15 -0
  12. package/dist/components/piece/index.d.ts +3 -0
  13. package/dist/components/piece/piece.d.ts +6 -0
  14. package/dist/components/piece/piece.hook.d.ts +5 -0
  15. package/dist/components/piece/piece.static.d.ts +2 -0
  16. package/dist/components/piece/piece.types.d.ts +34 -0
  17. package/dist/components/piece/piece.utils.d.ts +7 -0
  18. package/dist/components/piece-provider/index.d.ts +3 -0
  19. package/dist/components/piece-provider/piece-provider.context.d.ts +2 -0
  20. package/dist/components/piece-provider/piece-provider.d.ts +4 -0
  21. package/dist/components/piece-provider/piece-provider.hook.d.ts +2 -0
  22. package/dist/components/piece-provider/piece-provider.types.d.ts +24 -0
  23. package/dist/components/screen/index.d.ts +3 -0
  24. package/dist/components/screen/screen.d.ts +4 -0
  25. package/dist/components/screen/screen.hook.d.ts +4 -0
  26. package/dist/components/screen/screen.types.d.ts +15 -0
  27. package/dist/components/scrollable/index.d.ts +3 -0
  28. package/dist/components/scrollable/scrollable.d.ts +6 -0
  29. package/dist/components/scrollable/scrollable.hook.d.ts +5 -0
  30. package/dist/components/scrollable/scrollable.styles.d.ts +14 -0
  31. package/dist/components/scrollable/scrollable.types.d.ts +12 -0
  32. package/dist/components/text/index.d.ts +3 -0
  33. package/dist/components/text/text.d.ts +4 -0
  34. package/dist/components/text/text.hook.d.ts +5 -0
  35. package/dist/components/text/text.types.d.ts +3 -0
  36. package/dist/components.es.js +24 -0
  37. package/dist/fillObjectWithDefaults-AoLKqRgC.js +13 -0
  38. package/dist/hocs/index.d.ts +1 -0
  39. package/dist/hocs/withPieceAsContainer.d.ts +7 -0
  40. package/dist/index.d.ts +5 -0
  41. package/dist/index.es.js +36 -0
  42. package/dist/media-BrSPl6_U.js +48 -0
  43. package/dist/media.es.js +5 -0
  44. package/dist/piece-Mpz6AD6r.js +221 -0
  45. package/dist/piece-provider-DTglah_F.js +1388 -0
  46. package/dist/piece-provider.es.js +5 -0
  47. package/dist/piece.es.js +5 -0
  48. package/dist/screen-gL0zeQqb.js +53 -0
  49. package/dist/screen.es.js +5 -0
  50. package/dist/scrollable-hsA1xMFz.js +94 -0
  51. package/dist/scrollable.es.js +5 -0
  52. package/dist/styles-DofTX6nZ.js +653 -0
  53. package/dist/systems/harmony/alignment-container.d.ts +2 -0
  54. package/dist/systems/harmony/contents.d.ts +2 -0
  55. package/dist/systems/harmony/index.d.ts +1 -0
  56. package/dist/systems/harmony/input.d.ts +2 -0
  57. package/dist/systems/harmony/media.d.ts +2 -0
  58. package/dist/systems/harmony/piece.d.ts +2 -0
  59. package/dist/systems/harmony/reset.d.ts +2 -0
  60. package/dist/systems/harmony/screen.d.ts +2 -0
  61. package/dist/systems/harmony/scrollable.d.ts +2 -0
  62. package/dist/systems/index.d.ts +2 -0
  63. package/dist/systems/mergeSystems.d.ts +2 -0
  64. package/dist/systems.es.js +97 -0
  65. package/dist/text-BEFRS4fh.js +70 -0
  66. package/dist/text.es.js +6 -0
  67. package/dist/types/css.d.ts +6 -0
  68. package/dist/types/html.d.ts +5 -0
  69. package/dist/types/index.d.ts +3 -0
  70. package/dist/types/utils.d.ts +20 -0
  71. package/dist/types.es.js +1 -0
  72. package/dist/utils/appendClasses.d.ts +1 -0
  73. package/dist/utils/excludeProperties.d.ts +1 -0
  74. package/dist/utils/fillObjectWithDefaults.d.ts +1 -0
  75. package/dist/utils/index.d.ts +5 -0
  76. package/dist/utils/splitProps.d.ts +4 -0
  77. package/dist/utils/styles.d.ts +28 -0
  78. package/dist/utils.es.js +25 -0
  79. package/package.json +1 -1
@@ -0,0 +1,5 @@
1
+ import { P, u as i } from "./piece-provider-DTglah_F.js";
2
+ export {
3
+ P as PieceProvider,
4
+ i as usePieceProvider
5
+ };
@@ -0,0 +1,5 @@
1
+ import { P, u as a } from "./piece-Mpz6AD6r.js";
2
+ export {
3
+ P as Piece,
4
+ a as usePiece
5
+ };
@@ -0,0 +1,53 @@
1
+ import { u as d, i as f, j as m } from "./piece-provider-DTglah_F.js";
2
+ import { useMemo as u, useId as y, useInsertionEffect as S, memo as h } from "react";
3
+ import { S as b } from "./styles-DofTX6nZ.js";
4
+ import { P as g } from "./piece-Mpz6AD6r.js";
5
+ const x = (e) => {
6
+ const { theme: t } = d(), { id: r, fontSize: i, fontFamily: a, containerId: l } = e, n = u(() => new b(), []), s = y();
7
+ return S(() => (n.apply({
8
+ "html,body": {
9
+ margin: 0,
10
+ padding: 0,
11
+ border: 0,
12
+ fontSize: i,
13
+ fontWeight: 400,
14
+ fontStyle: "normal",
15
+ fontFamily: a,
16
+ fontOpticalSizing: "auto",
17
+ overflow: e.overflow ? "auto" : "hidden"
18
+ },
19
+ [`html,body,#${l}`]: {
20
+ height: "100dvh",
21
+ width: "100dvw"
22
+ },
23
+ "*::before, *::after": {
24
+ boxSizing: "border-box"
25
+ },
26
+ ...Array.isArray(e.globalStyle) ? e.globalStyle.reduce(
27
+ (c, o) => ({
28
+ ...c,
29
+ ...typeof o == "function" ? o(t) : o
30
+ }),
31
+ {}
32
+ ) : typeof e.globalStyle == "function" ? e.globalStyle(t) : e.globalStyle
33
+ }), () => {
34
+ n.delete();
35
+ }), [n, t]), {
36
+ id: r || s
37
+ };
38
+ }, v = (e) => {
39
+ const { id: t } = x(e);
40
+ return /* @__PURE__ */ m.jsx(
41
+ g,
42
+ {
43
+ id: t,
44
+ as: "main",
45
+ kind: "screen",
46
+ children: e.children
47
+ }
48
+ );
49
+ }, z = h(v, f);
50
+ export {
51
+ z as S,
52
+ x as u
53
+ };
@@ -0,0 +1,5 @@
1
+ import { S as s, u as S } from "./screen-gL0zeQqb.js";
2
+ export {
3
+ s as Screen,
4
+ S as useScreen
5
+ };
@@ -0,0 +1,94 @@
1
+ import { useRef as w, useMemo as m, memo as S } from "react";
2
+ import { f as k } from "./fillObjectWithDefaults-AoLKqRgC.js";
3
+ import { u as v, i as $ } from "./piece-provider-DTglah_F.js";
4
+ import { u as C } from "./piece-Mpz6AD6r.js";
5
+ const p = (o, e, n, a, s, i, t) => ({
6
+ scrollBehavior: e,
7
+ overflowX: s ? "auto" : "hidden",
8
+ overflowY: i ? "auto" : "hidden",
9
+ flexDirection: i ? "column" : "row",
10
+ ...t ? { scrollSnapType: t } : {},
11
+ minHeight: 0,
12
+ boxSizing: "content-box",
13
+ transition: "all 0.3s ease-in-out",
14
+ display: "flex",
15
+ flex: "1 1 100%",
16
+ scrollbarWidth: o,
17
+ scrollbarColor: `${a} ${n}`,
18
+ [`@supports not (scrollbar-width: ${o})`]: {
19
+ "&::-webkit-scrollbar": {
20
+ width: "8px"
21
+ },
22
+ "&::-webkit-scrollbar-thumb": {
23
+ backgroundColor: n,
24
+ border: `1px solid ${n}`
25
+ },
26
+ "&::-webkit-scrollbar-track": {
27
+ boxShadow: `inset 0 0 0 ${o}px ${a}`,
28
+ backgroundColor: a
29
+ }
30
+ }
31
+ }), g = (o) => {
32
+ const { theme: e, getContext: n } = v(), a = w(null), s = m(() => n(o), [o, n]), {
33
+ scrollSnap: i,
34
+ primary: t,
35
+ highlight: l,
36
+ horizontal: c,
37
+ vertical: f,
38
+ behavior: u,
39
+ withStyle: r,
40
+ size: b,
41
+ ...y
42
+ } = k(o, s.defaults), h = m(
43
+ () => Array.isArray(r) ? r.reduce(
44
+ (x, d) => ({
45
+ ...x,
46
+ ...typeof d == "function" ? d(e) : d
47
+ }),
48
+ p(
49
+ b,
50
+ u,
51
+ typeof t == "function" ? t(e) : t,
52
+ typeof l == "function" ? l(e) : l,
53
+ c,
54
+ f,
55
+ i
56
+ )
57
+ ) : {
58
+ ...r !== void 0 && typeof r == "function" ? r(e) : r,
59
+ ...p(
60
+ b,
61
+ u,
62
+ typeof t == "function" ? t(e) : t,
63
+ typeof l == "function" ? l(e) : l,
64
+ c,
65
+ f,
66
+ i
67
+ )
68
+ },
69
+ [
70
+ r,
71
+ e,
72
+ b,
73
+ u,
74
+ t,
75
+ l,
76
+ c,
77
+ f,
78
+ i
79
+ ]
80
+ );
81
+ return C({
82
+ ...y,
83
+ ref: a,
84
+ kind: o.kind || "scrollable",
85
+ withStyle: h
86
+ });
87
+ }, P = (o) => g(o).element, j = S(
88
+ P,
89
+ $
90
+ );
91
+ export {
92
+ j as S,
93
+ g as u
94
+ };
@@ -0,0 +1,5 @@
1
+ import { S as e, u as o } from "./scrollable-hsA1xMFz.js";
2
+ export {
3
+ e as Scrollable,
4
+ o as useScrollable
5
+ };