@adamosuiteservices/ui 2.10.12 → 2.11.13

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 (53) hide show
  1. package/dist/accordion-rounded.cjs +7 -7
  2. package/dist/accordion-rounded.js +1 -1
  3. package/dist/calendar-Bapd0vmU.js +2949 -0
  4. package/dist/calendar-DMvGcwMp.cjs +76 -0
  5. package/dist/calendar.cjs +1 -76
  6. package/dist/calendar.js +3 -2945
  7. package/dist/colors.css +1 -1
  8. package/dist/combobox-CW07jN3o.cjs +37 -0
  9. package/dist/combobox-CtdzWxGX.js +598 -0
  10. package/dist/combobox.cjs +1 -37
  11. package/dist/combobox.js +2 -596
  12. package/dist/components/layout/full-screen-loader/full-screen-loader-manager.d.ts +6 -0
  13. package/dist/components/layout/full-screen-loader/full-screen-loader-observable.d.ts +8 -0
  14. package/dist/components/layout/full-screen-loader/full-screen-loader.d.ts +4 -0
  15. package/dist/components/layout/full-screen-loader/index.d.ts +3 -0
  16. package/dist/components/ui/date-picker-selector/date-picker-selector.d.ts +21 -0
  17. package/dist/components/ui/date-picker-selector/index.d.ts +1 -0
  18. package/dist/date-picker-selector.cjs +1 -0
  19. package/dist/date-picker-selector.js +105 -0
  20. package/dist/full-screen-loader.cjs +4 -0
  21. package/dist/full-screen-loader.js +50 -0
  22. package/dist/spinner-B-sC3DVC.cjs +1 -0
  23. package/dist/spinner-DvrliN2E.js +19 -0
  24. package/dist/spinner.cjs +1 -1
  25. package/dist/spinner.js +1 -16
  26. package/dist/styles.css +1 -1
  27. package/dist/table.cjs +5 -5
  28. package/dist/table.js +2 -2
  29. package/dist/tailwind-colors.css +1 -1
  30. package/dist/tailwind-theme.css +1 -1
  31. package/dist/themes.css +1 -1
  32. package/dist/tooltip.cjs +5 -4
  33. package/dist/tooltip.js +4 -3
  34. package/dist/types/theme.type.d.ts +1 -1
  35. package/docs/components/layout/full-screen-loader.md +500 -0
  36. package/docs/components/ui/accordion-rounded.md +7 -7
  37. package/docs/components/ui/accordion.md +2 -2
  38. package/docs/components/ui/alert.md +3 -3
  39. package/docs/components/ui/avatar.md +10 -10
  40. package/docs/components/ui/badge.md +10 -53
  41. package/docs/components/ui/button.md +1 -1
  42. package/docs/components/ui/calendar.md +1 -1
  43. package/docs/components/ui/combobox.md +7 -7
  44. package/docs/components/ui/date-picker-selector.md +376 -0
  45. package/docs/components/ui/hover-card.md +1 -1
  46. package/docs/components/ui/icon.md +12 -12
  47. package/docs/components/ui/input-group.md +9 -14
  48. package/docs/components/ui/popover.md +2 -2
  49. package/docs/components/ui/spinner.md +1 -1
  50. package/docs/components/ui/table.md +1 -1
  51. package/docs/components/ui/tooltip.md +3 -3
  52. package/docs/components/ui/typography.md +1 -1
  53. package/package.json +9 -1
@@ -0,0 +1,105 @@
1
+ import { j as a } from "./jsx-runtime-BzflLqGi.js";
2
+ import { B as p } from "./button-CBy_oQDu.js";
3
+ import { b as v, C, s as g } from "./calendar-Bapd0vmU.js";
4
+ import { C as k } from "./combobox-CtdzWxGX.js";
5
+ import { I as P } from "./input-DFvZLcgm.js";
6
+ import { P as w, c as L, b as _ } from "./popover-DcQ18EVl.js";
7
+ import { c as N } from "./index-CRiPKpXj.js";
8
+ import { useState as d } from "react";
9
+ function i(r, o, n) {
10
+ return v(r, -o, n);
11
+ }
12
+ function E({ dateRange: r, onDateRangeChange: o, labels: n, combobox: u, calendar: f, className: y, ...x }) {
13
+ const [h, D] = d(void 0), [b, l] = d(!1), [c, m] = d(r), s = { ...{
14
+ last30Days: "Last 30 days",
15
+ last7Days: "Last 7 days",
16
+ last90Days: "Last 90 days",
17
+ custom: "Custom",
18
+ placeholder: "Date",
19
+ cancel: "Cancel",
20
+ apply: "Apply"
21
+ }, ...n }, j = (t) => {
22
+ const e = g(/* @__PURE__ */ new Date());
23
+ switch (t) {
24
+ case "7_days":
25
+ return { from: i(e, 7), to: e };
26
+ case "30_days":
27
+ return { from: i(e, 30), to: e };
28
+ case "90_days":
29
+ return { from: i(e, 90), to: e };
30
+ default:
31
+ return { from: void 0, to: void 0 };
32
+ }
33
+ };
34
+ return /* @__PURE__ */ a.jsxs("div", { className: N("adm:flex adm:w-max adm:flex-col", y), ...x, children: [
35
+ /* @__PURE__ */ a.jsx(
36
+ k,
37
+ {
38
+ alwaysShowPlaceholder: !0,
39
+ selectedFeedback: "check",
40
+ icon: "calendar_today",
41
+ options: [
42
+ { label: s.last30Days, value: "30_days" },
43
+ { label: s.last7Days, value: "7_days" },
44
+ { label: s.last90Days, value: "90_days" },
45
+ { label: s.custom, value: "custom" }
46
+ ],
47
+ value: h,
48
+ onValueChange: (t) => {
49
+ if (typeof t == "string")
50
+ if (t === "custom")
51
+ l(!0);
52
+ else {
53
+ const e = j(t);
54
+ o(e), m(void 0);
55
+ }
56
+ D(t);
57
+ },
58
+ labels: { placeholder: s.placeholder },
59
+ ...u
60
+ }
61
+ ),
62
+ /* @__PURE__ */ a.jsxs(w, { open: b, onOpenChange: l, children: [
63
+ /* @__PURE__ */ a.jsx(L, { asChild: !0, children: /* @__PURE__ */ a.jsx(P, { className: "adm:sr-only" }) }),
64
+ /* @__PURE__ */ a.jsxs(_, { align: "start", children: [
65
+ /* @__PURE__ */ a.jsx(
66
+ C,
67
+ {
68
+ required: !0,
69
+ mode: "range",
70
+ selected: c,
71
+ onSelect: m,
72
+ captionLayout: "dropdown",
73
+ classNames: { root: "adm:p-0!" },
74
+ ...f
75
+ }
76
+ ),
77
+ /* @__PURE__ */ a.jsxs("div", { className: "adm:mt-2 adm:flex adm:justify-end adm:gap-2", children: [
78
+ /* @__PURE__ */ a.jsx(
79
+ p,
80
+ {
81
+ variant: "link",
82
+ onClick: () => {
83
+ l(!1);
84
+ },
85
+ children: s.cancel
86
+ }
87
+ ),
88
+ /* @__PURE__ */ a.jsx(
89
+ p,
90
+ {
91
+ variant: "link",
92
+ onClick: () => {
93
+ c && o(c), l(!1);
94
+ },
95
+ children: s.apply
96
+ }
97
+ )
98
+ ] })
99
+ ] })
100
+ ] })
101
+ ] });
102
+ }
103
+ export {
104
+ E as DatePickerSelector
105
+ };
@@ -0,0 +1,4 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./jsx-runtime-BB_1_6y_.cjs"),i=require("./spinner-B-sC3DVC.cjs"),a=require("react");class l{subscribers=[];subscribe(e){return this.subscribers.push(e),()=>{this.subscribers=this.subscribers.filter(r=>r!==e)}}emit(e){this.subscribers.forEach(r=>r(e))}}const s=new l;function c(){const[t,e]=a.useState(!1);return a.useEffect(()=>{const r=s.subscribe(({open:u})=>{e(u)});return()=>{r()}},[]),t?n.jsxRuntimeExports.jsx("div",{"data-slot":"full-screen-loader",className:`
2
+ adm:fixed adm:inset-0 adm:z-100 adm:flex adm:items-center
3
+ adm:justify-center adm:bg-black/50
4
+ `,children:n.jsxRuntimeExports.jsx(i.Spinner,{className:"adm:text-4xl adm:text-primary"})}):null}class o{show(){s.emit({open:!0})}hide(){s.emit({open:!1})}}const b=new o;exports.FullScreenLoader=c;exports.FullScreenLoaderManager=b;exports.FullScreenLoaderObservable=s;
@@ -0,0 +1,50 @@
1
+ import { j as a } from "./jsx-runtime-BzflLqGi.js";
2
+ import { S as i } from "./spinner-DvrliN2E.js";
3
+ import { useState as c, useEffect as l } from "react";
4
+ class u {
5
+ subscribers = [];
6
+ subscribe(e) {
7
+ return this.subscribers.push(e), () => {
8
+ this.subscribers = this.subscribers.filter((s) => s !== e);
9
+ };
10
+ }
11
+ emit(e) {
12
+ this.subscribers.forEach((s) => s(e));
13
+ }
14
+ }
15
+ const t = new u();
16
+ function f() {
17
+ const [r, e] = c(!1);
18
+ return l(() => {
19
+ const s = t.subscribe(({ open: n }) => {
20
+ e(n);
21
+ });
22
+ return () => {
23
+ s();
24
+ };
25
+ }, []), r ? /* @__PURE__ */ a.jsx(
26
+ "div",
27
+ {
28
+ "data-slot": "full-screen-loader",
29
+ className: `
30
+ adm:fixed adm:inset-0 adm:z-100 adm:flex adm:items-center
31
+ adm:justify-center adm:bg-black/50
32
+ `,
33
+ children: /* @__PURE__ */ a.jsx(i, { className: "adm:text-4xl adm:text-primary" })
34
+ }
35
+ ) : null;
36
+ }
37
+ class o {
38
+ show() {
39
+ t.emit({ open: !0 });
40
+ }
41
+ hide() {
42
+ t.emit({ open: !1 });
43
+ }
44
+ }
45
+ const p = new o();
46
+ export {
47
+ f as FullScreenLoader,
48
+ p as FullScreenLoaderManager,
49
+ t as FullScreenLoaderObservable
50
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";const i=require("./jsx-runtime-BB_1_6y_.cjs"),s=require("./icon-DPMQJBkA.cjs"),t=require("./index-DoxiiusW.cjs");function r({className:e,...n}){return i.jsxRuntimeExports.jsx(s.Icon,{symbol:"progress_activity",role:"status","aria-label":"Loading",className:t.cn("adm:animate-spin adm:text-lg",e),...n})}exports.Spinner=r;
@@ -0,0 +1,19 @@
1
+ "use client";
2
+ import { j as t } from "./jsx-runtime-BzflLqGi.js";
3
+ import { I as r } from "./icon-DKAhvlX_.js";
4
+ import { c as o } from "./index-CRiPKpXj.js";
5
+ function n({ className: a, ...s }) {
6
+ return /* @__PURE__ */ t.jsx(
7
+ r,
8
+ {
9
+ symbol: "progress_activity",
10
+ role: "status",
11
+ "aria-label": "Loading",
12
+ className: o("adm:animate-spin adm:text-lg", a),
13
+ ...s
14
+ }
15
+ );
16
+ }
17
+ export {
18
+ n as S
19
+ };
package/dist/spinner.cjs CHANGED
@@ -1 +1 @@
1
- "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./jsx-runtime-BB_1_6y_.cjs"),i=require("./icon-DPMQJBkA.cjs"),r=require("./index-DoxiiusW.cjs");function s({className:e,...t}){return n.jsxRuntimeExports.jsx(i.Icon,{symbol:"progress_activity",role:"status","aria-label":"Loading",className:r.cn("adm:animate-spin adm:text-lg",e),...t})}exports.Spinner=s;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./spinner-B-sC3DVC.cjs");exports.Spinner=e.Spinner;
package/dist/spinner.js CHANGED
@@ -1,19 +1,4 @@
1
- "use client";
2
- import { j as r } from "./jsx-runtime-BzflLqGi.js";
3
- import { I as s } from "./icon-DKAhvlX_.js";
4
- import { c as o } from "./index-CRiPKpXj.js";
5
- function n({ className: t, ...a }) {
6
- return /* @__PURE__ */ r.jsx(
7
- s,
8
- {
9
- symbol: "progress_activity",
10
- role: "status",
11
- "aria-label": "Loading",
12
- className: o("adm:animate-spin adm:text-lg", t),
13
- ...a
14
- }
15
- );
16
- }
1
+ import { S as n } from "./spinner-DvrliN2E.js";
17
2
  export {
18
3
  n as Spinner
19
4
  };