@cfx-dev/ui-components 0.0.19 → 0.0.21

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 (77) hide show
  1. package/dist/Combination-Dp_plIQU.js +793 -0
  2. package/dist/{Icons-B26SczGZ.js → Icons-BlBKvJD8.js} +40 -98
  3. package/dist/{Rail-BCY3h7eP.js → Rail-CCuyJpf6.js} +11 -11
  4. package/dist/_commonjsHelpers-C6fGbg64.js +6 -0
  5. package/dist/assets/InputDropzone.css +1 -0
  6. package/dist/assets/ItemPreview.css +1 -0
  7. package/dist/assets/Table.css +1 -0
  8. package/dist/components/BackdropPortal/BackdropPortal.d.ts +1 -0
  9. package/dist/components/BackdropPortal/BackdropPortal.js +9 -7
  10. package/dist/components/Badge/Badge.d.ts +2 -2
  11. package/dist/components/Button/Button.d.ts +2 -1
  12. package/dist/components/Button/Button.js +27 -25
  13. package/dist/components/Button/ButtonBar.d.ts +0 -1
  14. package/dist/components/Button/LinkButton.js +13 -13
  15. package/dist/components/Flyout/Flyout.d.ts +1 -0
  16. package/dist/components/Flyout/Flyout.js +28 -27
  17. package/dist/components/Input/Input.js +1 -1
  18. package/dist/components/Input/RichInput.js +2 -2
  19. package/dist/components/InputDropzone/InputDropzone.d.ts +14 -0
  20. package/dist/components/InputDropzone/InputDropzone.js +1103 -0
  21. package/dist/components/InputDropzone/ItemPreview.d.ts +8 -0
  22. package/dist/components/InputDropzone/ItemPreview.js +24 -0
  23. package/dist/components/Layout/Scrollable/Rail.js +3 -3
  24. package/dist/components/Layout/Scrollable/Scrollable.js +2 -2
  25. package/dist/components/Layout/Scrollable/VirtualScrollable.js +3 -4
  26. package/dist/components/Modal/Modal.d.ts +0 -2
  27. package/dist/components/Modal/Modal.js +3 -3
  28. package/dist/components/NavList/NavList.js +5 -5
  29. package/dist/components/OnScreenSensor.js +6 -6
  30. package/dist/components/Overlay/Overlay.d.ts +1 -0
  31. package/dist/components/Overlay/Overlay.js +16 -15
  32. package/dist/components/Select/Select.js +652 -663
  33. package/dist/components/Shroud/Shroud.js +20 -19
  34. package/dist/components/Switch/Switch.js +1 -1
  35. package/dist/components/Table/Table.d.ts +17 -0
  36. package/dist/components/Table/Table.js +61 -0
  37. package/dist/components/Tabular/Tabular.d.ts +1 -1
  38. package/dist/components/Text/Text.types.d.ts +0 -1
  39. package/dist/components/Title/Title.d.ts +1 -0
  40. package/dist/components/Title/Title.js +26 -25
  41. package/dist/{extends-Dk_bSU3E.js → extends-hS2Bh-Yp.js} +1 -2
  42. package/dist/{index-C75OpfGQ.js → index-2hJuj4UN.js} +2018 -2526
  43. package/dist/index-DQMInta3.js +663 -0
  44. package/dist/index.esm-BkynlSN6.js +72 -0
  45. package/dist/main.d.ts +17 -26
  46. package/dist/main.js +145 -122
  47. package/dist/{medium-Dc7QRuE0.js → medium-JVtzoF2c.js} +3 -3
  48. package/dist/style-guide/Colours/DarkThemeSwatches.d.ts +2 -0
  49. package/dist/style-guide/Colours/DarkThemeSwatches.js +110 -0
  50. package/dist/style-guide/Colours/LightThemeSwatches.d.ts +2 -0
  51. package/dist/style-guide/Colours/LightThemeSwatches.js +105 -0
  52. package/dist/style-guide/Colours/Swatches.d.ts +6 -0
  53. package/dist/style-guide/Colours/Swatches.js +48 -0
  54. package/dist/style-guide/Icons/IconDisplayGrid.d.ts +2 -0
  55. package/dist/style-guide/Icons/IconDisplayGrid.js +42 -0
  56. package/dist/style-guide/Icons/Icons.js +7 -0
  57. package/dist/tslib.es6-CBKHJX9H.js +151 -0
  58. package/dist/utils/functional.js +19 -6
  59. package/dist/utils/hooks.d.ts +2 -1
  60. package/dist/utils/hooks.js +77 -10
  61. package/dist/utils/links.js +1128 -12
  62. package/dist/utils/math.js +8 -3
  63. package/dist/utils/mergeRefs.d.ts +1 -1
  64. package/dist/utils/mergeRefs.js +2 -2
  65. package/dist/utils/outlet.js +19 -4
  66. package/dist/utils/string.js +42 -7
  67. package/package.json +7 -13
  68. package/dist/Combination-Dj-a6dCZ.js +0 -1462
  69. package/dist/components/Icons.js +0 -6
  70. package/dist/functional-C0pE183N.js +0 -30
  71. package/dist/hooks-GAujvL7d.js +0 -86
  72. package/dist/links-CgOD-Vfj.js +0 -1142
  73. package/dist/math-i2ceybzU.js +0 -16
  74. package/dist/outlet-B11a3Kgw.js +0 -27
  75. package/dist/string-NVxCUbqk.js +0 -54
  76. package/dist/tslib.es6-Dd_EkEfR.js +0 -48
  77. /package/dist/{components → style-guide/Icons}/Icons.d.ts +0 -0
@@ -1,6 +0,0 @@
1
- import "react/jsx-runtime";
2
- import { B as n, I as s } from "../Icons-B26SczGZ.js";
3
- export {
4
- n as BrandIcon,
5
- s as Icons
6
- };
@@ -1,30 +0,0 @@
1
- function e() {
2
- }
3
- function t() {
4
- return !0;
5
- }
6
- function r() {
7
- return !1;
8
- }
9
- function o(n) {
10
- return n;
11
- }
12
- function u(n) {
13
- n();
14
- }
15
- const a = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
16
- __proto__: null,
17
- identity: o,
18
- invoke: u,
19
- noop: e,
20
- returnFalse: r,
21
- returnTrue: t
22
- }, Symbol.toStringTag, { value: "Module" }));
23
- export {
24
- r as a,
25
- u as b,
26
- a as f,
27
- o as i,
28
- e as n,
29
- t as r
30
- };
@@ -1,86 +0,0 @@
1
- import { jsx as d } from "react/jsx-runtime";
2
- import o from "react";
3
- import { $ as f } from "./index-C75OpfGQ.js";
4
- const i = Symbol("Uninitialized");
5
- function E(e, ...t) {
6
- const n = o.useRef(i);
7
- return n.current === i && (n.current = e(...t)), n.current;
8
- }
9
- function u(e) {
10
- const t = o.useRef(e);
11
- return t.current = e, t;
12
- }
13
- function c(e, t = "keydown", n) {
14
- o.useEffect(() => {
15
- const r = (s) => {
16
- c.shouldProcessEvent(s) && e.current(s);
17
- };
18
- return window.addEventListener(t, r, n), () => {
19
- window.removeEventListener(t, r, n);
20
- };
21
- }, [t, n]);
22
- }
23
- c.shouldProcessEvent = (e) => {
24
- if (e.target instanceof Element) {
25
- if (e.target.hasAttribute("contenteditable"))
26
- return !1;
27
- switch (e.target.tagName) {
28
- case "INPUT":
29
- case "SELECT":
30
- case "TEXTAREA":
31
- return !1;
32
- default:
33
- return !0;
34
- }
35
- }
36
- return !0;
37
- };
38
- function a(e) {
39
- const t = u((n) => {
40
- a.isCloseEvent(n) && e();
41
- });
42
- c(t);
43
- }
44
- a.isCloseEvent = (e) => e.key === "Escape";
45
- function m(e) {
46
- const t = u(e);
47
- o.useEffect(() => {
48
- const n = () => t.current();
49
- return window.addEventListener("resize", n), () => window.removeEventListener("resize", n);
50
- }, []);
51
- }
52
- function b(e) {
53
- const {
54
- children: t
55
- } = e;
56
- return /* @__PURE__ */ d("div", { style: { display: "none" }, children: t });
57
- }
58
- function w(e) {
59
- const [t, n] = o.useState(() => b);
60
- return o.useEffect(() => {
61
- let r = document.getElementById(e);
62
- r || (r = document.createElement("div"), r.id = e, document.body.appendChild(r));
63
- const s = ({
64
- children: l
65
- }) => f.createPortal(l, r);
66
- n(() => s);
67
- }, [e]), t;
68
- }
69
- const v = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
70
- __proto__: null,
71
- useDynamicRef: u,
72
- useGlobalKeyboardEvent: c,
73
- useInstance: E,
74
- useKeyboardClose: a,
75
- useOutlet: w,
76
- useWindowResize: m
77
- }, Symbol.toStringTag, { value: "Module" }));
78
- export {
79
- w as a,
80
- m as b,
81
- a as c,
82
- E as d,
83
- c as e,
84
- v as h,
85
- u
86
- };