docthub-core-components 2.99.2 → 3.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.
Files changed (88) hide show
  1. package/dist/components/overrides/ui/auto-complete.js +466 -0
  2. package/dist/components/overrides/ui/autocomplete-checkbox.js +480 -0
  3. package/dist/components/overrides/ui/chips/doct-chip.js +157 -0
  4. package/dist/components/overrides/ui/circular-progress.js +32 -0
  5. package/dist/components/overrides/ui/composed/address-form-section.js +67 -0
  6. package/dist/components/overrides/ui/composed/contact-form-section.js +56 -0
  7. package/dist/components/overrides/ui/composed/search-filter-section.js +132 -0
  8. package/dist/components/overrides/ui/composed/user-registration-section.js +77 -0
  9. package/dist/components/overrides/ui/currencyInput/currency-input.js +69 -0
  10. package/dist/components/overrides/ui/doct-animation-loader.js +13 -0
  11. package/dist/components/overrides/ui/expandable-card.js +115 -0
  12. package/dist/components/overrides/ui/footer/doct-footer.js +35 -0
  13. package/dist/components/overrides/ui/footer/footer-desktop.js +92 -0
  14. package/dist/components/overrides/ui/footer/footer-mobile.js +123 -0
  15. package/dist/components/overrides/ui/footer/footer-routes.js +87 -0
  16. package/dist/components/overrides/ui/footer/footer-shared.js +137 -0
  17. package/dist/components/overrides/ui/footer/presets.js +269 -0
  18. package/dist/components/overrides/ui/inputs/labeled-input.js +92 -0
  19. package/dist/components/overrides/ui/inputs/otp-input.js +101 -0
  20. package/dist/components/overrides/ui/inputs/password-input.js +77 -0
  21. package/dist/components/overrides/ui/inputs/phone-input.js +336 -0
  22. package/dist/components/overrides/ui/navigation-menu/doct-navigation-menu.js +22 -0
  23. package/dist/components/overrides/ui/navigation-menu/individual-nav-routes.js +46 -0
  24. package/dist/components/overrides/ui/navigation-menu/individual-navigation-menu-desktop.js +109 -0
  25. package/dist/components/overrides/ui/navigation-menu/individual-navigation-menu-mobile.js +231 -0
  26. package/dist/components/overrides/ui/navigation-menu/individual-navigation-menu.js +44 -0
  27. package/dist/components/overrides/ui/navigation-menu/nav-env.js +64 -0
  28. package/dist/components/overrides/ui/navigation-menu/navigation-menu-adapter.js +55 -0
  29. package/dist/components/overrides/ui/navigation-menu/navigation-menu-internal.js +36 -0
  30. package/dist/components/overrides/ui/navigation-menu/organization-nav-routes.js +34 -0
  31. package/dist/components/overrides/ui/navigation-menu/organization-navigation-menu-desktop.js +109 -0
  32. package/dist/components/overrides/ui/navigation-menu/organization-navigation-menu-mobile.js +231 -0
  33. package/dist/components/overrides/ui/navigation-menu/organization-navigation-menu.js +44 -0
  34. package/dist/components/overrides/ui/navigation-menu/presets.js +238 -0
  35. package/dist/components/overrides/ui/navigation-menu/types.js +6 -0
  36. package/dist/components/overrides/ui/pickers/date-picker-field.js +361 -0
  37. package/dist/components/overrides/ui/pickers/date-range-picker-field.js +288 -0
  38. package/dist/components/overrides/ui/pickers/day-picker-bounds.js +38 -0
  39. package/dist/components/overrides/ui/pickers/select-field.js +158 -0
  40. package/dist/components/overrides/ui/search/auto-complete.js +64 -0
  41. package/dist/components/overrides/ui/search/search-input.js +65 -0
  42. package/dist/components/overrides/ui/showcase/component-section.js +45 -0
  43. package/dist/components/ui/alert.js +94 -0
  44. package/dist/components/ui/avatar.js +69 -0
  45. package/dist/components/ui/badge.js +37 -0
  46. package/dist/components/ui/breadcrumb.js +117 -0
  47. package/dist/components/ui/button.js +223 -0
  48. package/dist/components/ui/calendar.js +100 -0
  49. package/dist/components/ui/checkbox.js +57 -0
  50. package/dist/components/ui/collapsible.js +25 -0
  51. package/dist/components/ui/command.js +132 -0
  52. package/dist/components/ui/dialog.js +230 -0
  53. package/dist/components/ui/drawer.js +119 -0
  54. package/dist/components/ui/dropdown-menu.js +216 -0
  55. package/dist/components/ui/input.js +48 -0
  56. package/dist/components/ui/label.js +22 -0
  57. package/dist/components/ui/popover.js +181 -0
  58. package/dist/components/ui/progress.js +91 -0
  59. package/dist/components/ui/radio-group.js +49 -0
  60. package/dist/components/ui/select.js +169 -0
  61. package/dist/components/ui/skeleton.js +91 -0
  62. package/dist/components/ui/spinner.js +32 -0
  63. package/dist/components/ui/tabs.js +68 -0
  64. package/dist/components/ui/textarea.js +73 -0
  65. package/dist/components/ui/timeline.js +177 -0
  66. package/dist/components/ui/toast.js +82 -0
  67. package/dist/components/ui/tooltip.js +91 -0
  68. package/dist/components/ui/typography.js +213 -0
  69. package/dist/hooks/use-exclusive-dropdown.js +53 -0
  70. package/dist/hooks/use-mobile.js +19 -0
  71. package/dist/hooks/useAutocompleteCheckbox.js +204 -0
  72. package/dist/index.esm.js +7173 -7126
  73. package/dist/index.js +187 -0
  74. package/dist/lib/dropdown-manager.js +17 -0
  75. package/dist/lib/get-floating-dropdown-position.js +32 -0
  76. package/dist/lib/get-scroll-parents.js +20 -0
  77. package/dist/lib/slot.js +40 -0
  78. package/dist/lib/utils.js +9 -0
  79. package/dist/src/components/ui/alert.d.ts +1 -1
  80. package/dist/src/components/ui/button.d.ts +1 -1
  81. package/dist/src/components/ui/command.d.ts +3 -3
  82. package/dist/src/components/ui/timeline.d.ts +1 -1
  83. package/dist/src/index.d.ts +15 -15
  84. package/dist/src/lib/get-floating-dropdown-position.d.ts +9 -1
  85. package/dist/src/lib/get-scroll-parents.d.ts +6 -0
  86. package/dist/style.css +1 -1
  87. package/dist/util/getInputClasses.js +19 -0
  88. package/package.json +131 -132
@@ -0,0 +1,109 @@
1
+ "use client";
2
+ import { jsxs as b, jsx as o } from "react/jsx-runtime";
3
+ import { c as k } from "react-compiler-runtime";
4
+ import { ArrowRight as B } from "lucide-react";
5
+ import * as S from "react";
6
+ import { cn as N } from "../../../../lib/utils.js";
7
+ import { SectionItems as _, NavItemRoot as j } from "./navigation-menu-internal.js";
8
+ import { DoctTypography as D } from "../../../ui/typography.js";
9
+ const I = {
10
+ highlighted: {
11
+ item: {
12
+ hover: "hover:bg-[#DDF3F7]",
13
+ active: "bg-[#DEF0FA]"
14
+ },
15
+ group: "bg-[#F0F6FF] rounded-[12px] border-none"
16
+ },
17
+ default: {
18
+ item: {
19
+ hover: "hover:bg-[#EBF8FA]",
20
+ active: "bg-[#EBF8FA]"
21
+ },
22
+ group: void 0
23
+ }
24
+ };
25
+ function E(s) {
26
+ const e = k(26), {
27
+ variant: t,
28
+ item: a
29
+ } = s, {
30
+ icon: i,
31
+ label: r,
32
+ description: l,
33
+ active: n
34
+ } = a, c = !!(i && l), d = !i && "pl-4 pb-[6px]", w = I[t], F = n && I[t].item.active;
35
+ let m;
36
+ e[0] !== d || e[1] !== w.item.hover || e[2] !== F ? (m = N("group flex w-full items-center rounded-[12px] pl-2 pr-[14px] py-1 text-left transition-colors pt-[6px]", d, w.item.hover, F), e[0] = d, e[1] = w.item.hover, e[2] = F, e[3] = m) : m = e[3];
37
+ let p;
38
+ e[4] !== i || e[5] !== c ? (p = i ? /* @__PURE__ */ o("div", { className: N("mr-1 flex shrink-0 items-center justify-center rounded-[999px]", c ? "h-11 w-11" : "h-8 w-8"), children: i }) : null, e[4] = i, e[5] = c, e[6] = p) : p = e[6];
39
+ let f;
40
+ e[7] !== r ? (f = /* @__PURE__ */ o(D, { variant: "textLabel2", weight: "semiBold", color: "#002830", className: "truncate font-semibold leading-5 text-primary", children: r }), e[7] = r, e[8] = f) : f = e[8];
41
+ let h;
42
+ e[9] !== l ? (h = l ? /* @__PURE__ */ o(D, { variant: "textLabel4", weight: "medium", color: "#70868B", className: "mt-0.5 line-clamp-2 leading-4 text-neutral-56", children: l }) : null, e[9] = l, e[10] = h) : h = e[10];
43
+ let x;
44
+ e[11] !== f || e[12] !== h ? (x = /* @__PURE__ */ b("div", { className: "flex-1 leading-none", children: [
45
+ f,
46
+ h
47
+ ] }), e[11] = f, e[12] = h, e[13] = x) : x = e[13];
48
+ const A = n && "opacity-100";
49
+ let u;
50
+ e[14] !== A ? (u = N("h-4 w-4 shrink-0 text-primary opacity-0 transition-transform group-hover:translate-x-0.5 group-hover:opacity-100", A), e[14] = A, e[15] = u) : u = e[15];
51
+ let g;
52
+ e[16] !== u ? (g = /* @__PURE__ */ o(B, { className: u }), e[16] = u, e[17] = g) : g = e[17];
53
+ let v;
54
+ e[18] !== g || e[19] !== x ? (v = /* @__PURE__ */ b("div", { className: "flex min-w-0 flex-1 items-center gap-2", children: [
55
+ x,
56
+ g
57
+ ] }), e[18] = g, e[19] = x, e[20] = v) : v = e[20];
58
+ let y;
59
+ return e[21] !== a || e[22] !== v || e[23] !== m || e[24] !== p ? (y = /* @__PURE__ */ b(j, { item: a, className: m, children: [
60
+ p,
61
+ v
62
+ ] }), e[21] = a, e[22] = v, e[23] = m, e[24] = p, e[25] = y) : y = e[25], y;
63
+ }
64
+ function R(s) {
65
+ const e = k(12), {
66
+ section: t,
67
+ groupVariant: a
68
+ } = s, i = t.variant ?? a ?? "default";
69
+ let r;
70
+ e[0] !== t.noPadding || e[1] !== t.title ? (r = t.title && /* @__PURE__ */ o(D, { variant: "body3", weight: "semiBold", color: "#70868B", className: N(t.noPadding ? "pt-1 pb-2" : "pt-5 pb-3", "px-6 text-[12px] font-semibold leading-4 text-primary/56"), children: t.title }), e[0] = t.noPadding, e[1] = t.title, e[2] = r) : r = e[2];
71
+ let l;
72
+ e[3] !== t.hasSeparatorAfterIndex || e[4] !== i ? (l = (d, w) => /* @__PURE__ */ b(S.Fragment, { children: [
73
+ /* @__PURE__ */ o(E, { variant: i, item: d }),
74
+ t.hasSeparatorAfterIndex === w ? /* @__PURE__ */ o("div", { className: "my-2 !mt-3 h-px w-full bg-neutral-8" }) : null
75
+ ] }, d.id), e[3] = t.hasSeparatorAfterIndex, e[4] = i, e[5] = l) : l = e[5];
76
+ let n;
77
+ e[6] !== t || e[7] !== l ? (n = /* @__PURE__ */ o("div", { className: "space-y-1 px-3 pb-4", children: /* @__PURE__ */ o(_, { section: t, renderItem: l }) }), e[6] = t, e[7] = l, e[8] = n) : n = e[8];
78
+ let c;
79
+ return e[9] !== r || e[10] !== n ? (c = /* @__PURE__ */ b("div", { className: "flex flex-col", children: [
80
+ r,
81
+ n
82
+ ] }), e[9] = r, e[10] = n, e[11] = c) : c = e[11], c;
83
+ }
84
+ function M(s) {
85
+ const e = k(9), {
86
+ groups: t,
87
+ className: a
88
+ } = s;
89
+ if (!t.length)
90
+ return null;
91
+ let i;
92
+ e[0] !== a ? (i = N("flex w-full items-stretch bg-white px-4 xl:justify-center pt-2 xl:px-0", "shadow-[0px_54px_24px_rgba(0,0,0,0.12)] backdrop-blur-[12px]", a), e[0] = a, e[1] = i) : i = e[1];
93
+ let r;
94
+ e[2] !== t ? (r = t.map($), e[2] = t, e[3] = r) : r = e[3];
95
+ let l;
96
+ e[4] !== r ? (l = /* @__PURE__ */ o("div", { className: "flex w-full xl:max-w-6xl", children: r }), e[4] = r, e[5] = l) : l = e[5];
97
+ let n;
98
+ return e[6] !== i || e[7] !== l ? (n = /* @__PURE__ */ o("nav", { "aria-label": "Docthub navigation", className: i, children: l }), e[6] = i, e[7] = l, e[8] = n) : n = e[8], n;
99
+ }
100
+ function $(s, e) {
101
+ const t = s.variant === "highlighted";
102
+ return /* @__PURE__ */ b("div", { className: N("flex min-w-0 flex-1 flex-col border-l border-black/8", e === 0 && "border-l-0", t && `${I.highlighted.group} rounded-[12px] border-none`), children: [
103
+ s.sections.map((a) => /* @__PURE__ */ o(R, { section: a, groupVariant: s.variant }, a.id)),
104
+ s.footer ? /* @__PURE__ */ o("div", { className: "mt-auto px-4 pb-4", children: s.footer }) : null
105
+ ] }, s.id);
106
+ }
107
+ export {
108
+ M as OrganizationDesktopMenu
109
+ };
@@ -0,0 +1,231 @@
1
+ "use client";
2
+ import { jsxs as O, Fragment as z, jsx as r } from "react/jsx-runtime";
3
+ import { c as S } from "react-compiler-runtime";
4
+ import { Collapsible as A } from "@base-ui/react/collapsible";
5
+ import { ChevronDown as j, Minus as E } from "lucide-react";
6
+ import * as T from "react";
7
+ import { DoctButton as F } from "../../../ui/button.js";
8
+ import { DoctTypography as B } from "../../../ui/typography.js";
9
+ import { cn as N } from "../../../../lib/utils.js";
10
+ import { NavItemRoot as P } from "./navigation-menu-internal.js";
11
+ import { MOBILE_CATEGORY_INDIVIDUALS as D, MOBILE_CATEGORY_ORGANIZATIONS as M } from "./types.js";
12
+ function V(h) {
13
+ const e = S(21), {
14
+ item: t,
15
+ taglineLayout: l,
16
+ hasIconSibling: f,
17
+ categoryId: a
18
+ } = h, c = a === void 0 ? D : a, {
19
+ icon: n,
20
+ label: o,
21
+ description: i
22
+ } = t, d = l === "vertical", u = c === M, p = u && "py-1", b = !n && (u || f) && "pl-2", m = !u && !n && f && "pb-2 pt-1";
23
+ let s;
24
+ e[0] !== p || e[1] !== b || e[2] !== m ? (s = N("flex w-full items-center gap-1 rounded-xl text-left", p, b, m), e[0] = p, e[1] = b, e[2] = m, e[3] = s) : s = e[3];
25
+ let g;
26
+ e[4] !== n ? (g = n ? /* @__PURE__ */ r("div", { className: "flex h-10 w-10 shrink-0 items-center justify-center rounded-full", children: n }) : null, e[4] = n, e[5] = g) : g = e[5];
27
+ const k = d ? "flex-col items-start gap-0.5" : "flex-row gap-2.5";
28
+ let w;
29
+ e[6] !== k ? (w = N("flex min-w-0 flex-1 items-center", k), e[6] = k, e[7] = w) : w = e[7];
30
+ let x;
31
+ e[8] !== o ? (x = /* @__PURE__ */ r(B, { variant: "textLabel4", weight: "semiBold", color: "#002830", className: "truncate text-sm font-semibold text-primary", children: o }), e[8] = o, e[9] = x) : x = e[9];
32
+ let y;
33
+ e[10] !== i ? (y = i ? /* @__PURE__ */ r(B, { variant: "textLabel4", weight: "regular", color: "#8FA1A4", className: "text-[11px] font-medium leading-4 text-neutral-44", children: i }) : null, e[10] = i, e[11] = y) : y = e[11];
34
+ let v;
35
+ e[12] !== y || e[13] !== w || e[14] !== x ? (v = /* @__PURE__ */ O("div", { className: w, children: [
36
+ x,
37
+ y
38
+ ] }), e[12] = y, e[13] = w, e[14] = x, e[15] = v) : v = e[15];
39
+ let I;
40
+ return e[16] !== t || e[17] !== v || e[18] !== s || e[19] !== g ? (I = /* @__PURE__ */ O(P, { item: t, className: s, children: [
41
+ g,
42
+ v
43
+ ] }), e[16] = t, e[17] = v, e[18] = s, e[19] = g, e[20] = I) : I = e[20], I;
44
+ }
45
+ function Y(h) {
46
+ const e = [];
47
+ for (const t of h)
48
+ if (t.title.trim().length > 0)
49
+ e.push({
50
+ id: t.id,
51
+ title: t.title,
52
+ items: [...t.items],
53
+ hasSeparatorAfterIndex: t.hasSeparatorAfterIndex,
54
+ footer: t.footer
55
+ });
56
+ else if (e.length > 0) {
57
+ const f = e[e.length - 1];
58
+ f.items.push(...t.items), t.hasSeparatorAfterIndex !== void 0 && (f.hasSeparatorAfterIndex = f.items.length - t.items.length + t.hasSeparatorAfterIndex);
59
+ }
60
+ return e;
61
+ }
62
+ function $(h) {
63
+ const e = S(35), {
64
+ section: t,
65
+ taglineLayout: l,
66
+ categoryId: f
67
+ } = h, a = f === void 0 ? D : f, [c, n] = T.useState(!0), o = a === M;
68
+ let i;
69
+ e[0] !== t.items ? (i = t.items.some(Z), e[0] = t.items, e[1] = i) : i = e[1];
70
+ const d = i, u = o ? "py-1.5" : "py-0";
71
+ let p;
72
+ e[2] !== u ? (p = N("flex flex-1 items-center justify-between px-0 text-left hover:!bg-transparent", u), e[2] = u, e[3] = p) : p = e[3];
73
+ let b;
74
+ e[4] === Symbol.for("react.memo_cache_sentinel") ? (b = () => n(U), e[4] = b) : b = e[4];
75
+ let m;
76
+ e[5] !== t.title ? (m = /* @__PURE__ */ r(B, { variant: "textLabel4", weight: "semiBold", color: "#70868B", children: t.title }), e[5] = t.title, e[6] = m) : m = e[6];
77
+ let s;
78
+ e[7] !== c ? (s = /* @__PURE__ */ r("span", { className: "ml-2 inline-flex h-5 w-5 items-center justify-center", children: c ? /* @__PURE__ */ r(E, { className: "h-3 w-3 text-neutral-56" }) : /* @__PURE__ */ r(j, { className: "h-3 w-3 text-neutral-56" }) }), e[7] = c, e[8] = s) : s = e[8];
79
+ let g;
80
+ e[9] !== p || e[10] !== m || e[11] !== s ? (g = /* @__PURE__ */ r("div", { className: "flex items-center justify-between gap-0.5 py-2", children: /* @__PURE__ */ O(F, { type: "button", variant: "ghost", size: "small", className: p, onClick: b, children: [
81
+ m,
82
+ s
83
+ ] }) }), e[9] = p, e[10] = m, e[11] = s, e[12] = g) : g = e[12];
84
+ const k = o ? "space-y-3 pb-3" : "space-y-2 pb-2", w = t.footer && (o ? "-mx-1 px-1" : "-mx-4 px-2");
85
+ let x;
86
+ e[13] !== w || e[14] !== k ? (x = N(k, w, "overflow-hidden data-[closed]:animate-collapsible-up data-[open]:animate-collapsible-down"), e[13] = w, e[14] = k, e[15] = x) : x = e[15];
87
+ let y;
88
+ if (e[16] !== a || e[17] !== d || e[18] !== t.items || e[19] !== l) {
89
+ let C;
90
+ e[21] !== a || e[22] !== d || e[23] !== l ? (C = (R) => /* @__PURE__ */ r(V, { item: R, taglineLayout: l, hasIconSibling: d, categoryId: a }, R.id), e[21] = a, e[22] = d, e[23] = l, e[24] = C) : C = e[24], y = t.items.map(C), e[16] = a, e[17] = d, e[18] = t.items, e[19] = l, e[20] = y;
91
+ } else
92
+ y = e[20];
93
+ let v;
94
+ e[25] !== t.footer ? (v = t.footer ? /* @__PURE__ */ r("div", { className: "pt-2", children: t.footer }) : null, e[25] = t.footer, e[26] = v) : v = e[26];
95
+ let I;
96
+ e[27] !== x || e[28] !== y || e[29] !== v ? (I = /* @__PURE__ */ O(A.Panel, { className: x, children: [
97
+ y,
98
+ v
99
+ ] }), e[27] = x, e[28] = y, e[29] = v, e[30] = I) : I = e[30];
100
+ let _;
101
+ return e[31] !== c || e[32] !== I || e[33] !== g ? (_ = /* @__PURE__ */ O(A.Root, { open: c, onOpenChange: n, className: "w-full", children: [
102
+ g,
103
+ I
104
+ ] }), e[31] = c, e[32] = I, e[33] = g, e[34] = _) : _ = e[34], _;
105
+ }
106
+ function U(h) {
107
+ return !h;
108
+ }
109
+ function Z(h) {
110
+ return h.icon;
111
+ }
112
+ function G(h) {
113
+ const e = S(19), {
114
+ group: t,
115
+ taglineLayout: l,
116
+ className: f,
117
+ categoryId: a
118
+ } = h, c = a === void 0 ? D : a;
119
+ let n, o;
120
+ if (e[0] !== c || e[1] !== f || e[2] !== t.sections || e[3] !== l) {
121
+ const u = Y(t.sections), p = c === M, b = p ? "space-y-0" : "space-y-4";
122
+ e[6] !== f || e[7] !== b ? (n = N(b, f), e[6] = f, e[7] = b, e[8] = n) : n = e[8];
123
+ let m;
124
+ e[9] !== c || e[10] !== p || e[11] !== l ? (m = (s, g) => p ? /* @__PURE__ */ r("div", { className: N(g > 0 && "border-t border-black/8 pt-2"), children: /* @__PURE__ */ r($, { section: s, taglineLayout: l, categoryId: c }) }, s.id) : /* @__PURE__ */ r($, { section: s, taglineLayout: l, categoryId: c }, s.id), e[9] = c, e[10] = p, e[11] = l, e[12] = m) : m = e[12], o = u.map(m), e[0] = c, e[1] = f, e[2] = t.sections, e[3] = l, e[4] = n, e[5] = o;
125
+ } else
126
+ n = e[4], o = e[5];
127
+ let i;
128
+ e[13] !== t.footer ? (i = t.footer ? /* @__PURE__ */ r("div", { className: "pt-2", children: t.footer }) : null, e[13] = t.footer, e[14] = i) : i = e[14];
129
+ let d;
130
+ return e[15] !== n || e[16] !== o || e[17] !== i ? (d = /* @__PURE__ */ O("div", { className: n, children: [
131
+ o,
132
+ i
133
+ ] }), e[15] = n, e[16] = o, e[17] = i, e[18] = d) : d = e[18], d;
134
+ }
135
+ function q(h) {
136
+ const e = S(19), {
137
+ group: t,
138
+ categoryId: l
139
+ } = h, f = t.taglineLayout ?? "horizontal", [a, c] = T.useState(t.defaultOpen ?? !1);
140
+ let n;
141
+ e[0] === Symbol.for("react.memo_cache_sentinel") ? (n = () => c(H), e[0] = n) : n = e[0];
142
+ let o;
143
+ e[1] !== t.title ? (o = /* @__PURE__ */ r(B, { variant: "textLabel4", weight: "semiBold", color: "#70868B", children: t.title }), e[1] = t.title, e[2] = o) : o = e[2];
144
+ const i = a ? "rotate-180" : "rotate-0";
145
+ let d;
146
+ e[3] !== i ? (d = N("h-4 w-4 text-neutral-56 transition-transform", i), e[3] = i, e[4] = d) : d = e[4];
147
+ let u;
148
+ e[5] !== d ? (u = /* @__PURE__ */ r(j, { className: d }), e[5] = d, e[6] = u) : u = e[6];
149
+ let p;
150
+ e[7] !== o || e[8] !== u ? (p = /* @__PURE__ */ O("button", { type: "button", className: "flex h-14 w-full items-center justify-between bg-white px-4", onClick: n, children: [
151
+ o,
152
+ u
153
+ ] }), e[7] = o, e[8] = u, e[9] = p) : p = e[9];
154
+ let b;
155
+ e[10] === Symbol.for("react.memo_cache_sentinel") ? (b = N("border-t border-black/8 bg-white px-4 pb-4 pt-2", "overflow-hidden data-[closed]:animate-collapsible-up data-[open]:animate-collapsible-down"), e[10] = b) : b = e[10];
156
+ let m;
157
+ e[11] !== l || e[12] !== t || e[13] !== f ? (m = /* @__PURE__ */ r(A.Panel, { className: b, children: /* @__PURE__ */ r(G, { group: t, taglineLayout: f, categoryId: l }) }), e[11] = l, e[12] = t, e[13] = f, e[14] = m) : m = e[14];
158
+ let s;
159
+ return e[15] !== a || e[16] !== p || e[17] !== m ? (s = /* @__PURE__ */ O(A.Root, { open: a, onOpenChange: c, className: "w-full border-t border-black/8", children: [
160
+ p,
161
+ m
162
+ ] }), e[15] = a, e[16] = p, e[17] = m, e[18] = s) : s = e[18], s;
163
+ }
164
+ function H(h) {
165
+ return !h;
166
+ }
167
+ function L(h) {
168
+ const e = S(11), {
169
+ category: t,
170
+ isOpen: l,
171
+ onClick: f
172
+ } = h;
173
+ let a;
174
+ e[0] !== t.title ? (a = /* @__PURE__ */ r("p", { className: "text-sm font-semibold text-primary", children: t.title }), e[0] = t.title, e[1] = a) : a = e[1];
175
+ const c = l ? "rotate-180" : "";
176
+ let n;
177
+ e[2] !== c ? (n = N("h-4 w-4 text-neutral-56 transition-transform", c), e[2] = c, e[3] = n) : n = e[3];
178
+ let o;
179
+ e[4] !== n ? (o = /* @__PURE__ */ r(j, { className: n }), e[4] = n, e[5] = o) : o = e[5];
180
+ let i;
181
+ return e[6] !== l || e[7] !== f || e[8] !== a || e[9] !== o ? (i = /* @__PURE__ */ O("button", { type: "button", className: "flex h-14 w-full shrink-0 items-center justify-between border-t border-black/8 bg-white px-4 first:border-t-0", onClick: f, "aria-expanded": l, children: [
182
+ a,
183
+ o
184
+ ] }), e[6] = l, e[7] = f, e[8] = a, e[9] = o, e[10] = i) : i = e[10], i;
185
+ }
186
+ function ie(h) {
187
+ const e = S(19), {
188
+ categories: t,
189
+ groups: l,
190
+ className: f
191
+ } = h, [a, c] = T.useState(null);
192
+ let n, o, i;
193
+ if (e[0] !== t || e[1] !== f || e[2] !== (l == null ? void 0 : l.length) || e[3] !== a) {
194
+ i = Symbol.for("react.early_return_sentinel");
195
+ e: {
196
+ const p = N("flex w-full flex-col border-y border-black/8 bg-white", "shadow-[0px_54px_24px_rgba(0,0,0,0.12)] backdrop-blur-[12px]", "max-h-[90vh]", "[&::-webkit-scrollbar]:w-1 [&::-webkit-scrollbar-track]:bg-transparent", "[&::-webkit-scrollbar-thumb]:bg-neutral-24 [&::-webkit-scrollbar-thumb]:rounded-full", "scrollbar-thin scrollbar-thumb-neutral-24 scrollbar-track-transparent", f);
197
+ if (t != null && t.length) {
198
+ const b = a, m = b !== null && b < t.length, s = m ? t[b] : null, g = b === 0, k = b === 1;
199
+ let w;
200
+ e[7] !== t || e[8] !== g || e[9] !== k || e[10] !== m || e[11] !== s ? (w = m && s ? /* @__PURE__ */ O(z, { children: [
201
+ /* @__PURE__ */ O("div", { className: "flex shrink-0 flex-col", children: [
202
+ /* @__PURE__ */ r(L, { category: t[0], isOpen: g, onClick: () => c(g ? null : 0) }),
203
+ k && t[1] && /* @__PURE__ */ r(L, { category: t[1], isOpen: !0, onClick: () => c(null) })
204
+ ] }),
205
+ /* @__PURE__ */ r("div", { className: "min-h-0 flex-1 overflow-y-auto overscroll-contain border-t border-black/8 bg-white", children: /* @__PURE__ */ r("div", { className: "space-y-2 px-4 pb-4 pt-2", children: s.groups.map((x, y) => /* @__PURE__ */ r(G, { group: x, taglineLayout: x.taglineLayout ?? "horizontal", categoryId: s.id, className: N(y > 0 && !x.noTopBorder && "border-t border-black/8 pt-2") }, x.id)) }) }),
206
+ g && t[1] && /* @__PURE__ */ r("div", { className: "shrink-0 border-t border-black/8", children: /* @__PURE__ */ r(L, { category: t[1], isOpen: !1, onClick: () => c(1) }) })
207
+ ] }) : /* @__PURE__ */ r("div", { className: "overflow-y-auto", children: t.map((x, y) => /* @__PURE__ */ r(L, { category: x, isOpen: !1, onClick: () => c(y) }, x.id)) }), e[7] = t, e[8] = g, e[9] = k, e[10] = m, e[11] = s, e[12] = w) : w = e[12], i = /* @__PURE__ */ r("nav", { "aria-label": "Docthub navigation", className: N(p, "flex overflow-hidden"), children: w });
208
+ break e;
209
+ }
210
+ if (!(l != null && l.length)) {
211
+ i = null;
212
+ break e;
213
+ }
214
+ n = "Docthub navigation", o = N(p, "overflow-y-auto");
215
+ }
216
+ e[0] = t, e[1] = f, e[2] = l == null ? void 0 : l.length, e[3] = a, e[4] = n, e[5] = o, e[6] = i;
217
+ } else
218
+ n = e[4], o = e[5], i = e[6];
219
+ if (i !== Symbol.for("react.early_return_sentinel"))
220
+ return i;
221
+ let d;
222
+ e[13] !== l ? (d = l.map(J), e[13] = l, e[14] = d) : d = e[14];
223
+ let u;
224
+ return e[15] !== n || e[16] !== o || e[17] !== d ? (u = /* @__PURE__ */ r("nav", { "aria-label": n, className: o, children: d }), e[15] = n, e[16] = o, e[17] = d, e[18] = u) : u = e[18], u;
225
+ }
226
+ function J(h) {
227
+ return /* @__PURE__ */ r(q, { group: h, categoryId: M }, h.id);
228
+ }
229
+ export {
230
+ ie as OrganizationMobileMenu
231
+ };
@@ -0,0 +1,44 @@
1
+ "use client";
2
+ import { jsx as c } from "react/jsx-runtime";
3
+ import { c as v } from "react-compiler-runtime";
4
+ import { useIsMobile as z } from "../../../../hooks/use-mobile.js";
5
+ import { cn as O } from "../../../../lib/utils.js";
6
+ import { getMobileCategoriesFromPresets as d } from "./navigation-menu-adapter.js";
7
+ import { OrganizationDesktopMenu as G } from "./organization-navigation-menu-desktop.js";
8
+ import { OrganizationMobileMenu as p } from "./organization-navigation-menu-mobile.js";
9
+ import { organizationNavigationGroups as h } from "./presets.js";
10
+ function I(g) {
11
+ const o = v(15), {
12
+ groups: i,
13
+ className: u,
14
+ isMobileOverride: M
15
+ } = g, N = z(), b = M ?? N;
16
+ let r;
17
+ o[0] !== u ? (r = O("w-full", u), o[0] = u, o[1] = r) : r = o[1];
18
+ const e = r;
19
+ if (b) {
20
+ let l;
21
+ o[2] !== i ? (l = i ? void 0 : d(), o[2] = i, o[3] = l) : l = o[3];
22
+ const a = l;
23
+ let m;
24
+ o[4] !== i ? (m = i ?? [], o[4] = i, o[5] = m) : m = o[5];
25
+ const f = m;
26
+ if (a) {
27
+ let t;
28
+ return o[6] !== a || o[7] !== e ? (t = /* @__PURE__ */ c(p, { categories: a, className: e }), o[6] = a, o[7] = e, o[8] = t) : t = o[8], t;
29
+ }
30
+ if (f.length) {
31
+ let t;
32
+ return o[9] !== e || o[10] !== f ? (t = /* @__PURE__ */ c(p, { groups: f, className: e }), o[9] = e, o[10] = f, o[11] = t) : t = o[11], t;
33
+ }
34
+ return null;
35
+ }
36
+ const s = i ?? h;
37
+ if (!s.length)
38
+ return null;
39
+ let n;
40
+ return o[12] !== e || o[13] !== s ? (n = /* @__PURE__ */ c(G, { groups: s, className: e }), o[12] = e, o[13] = s, o[14] = n) : n = o[14], n;
41
+ }
42
+ export {
43
+ I as OrganizationNavigationMenu
44
+ };
@@ -0,0 +1,238 @@
1
+ "use client";
2
+ import { jsx as e, jsxs as t } from "react/jsx-runtime";
3
+ import { INDIVIDUAL_NAV_ROUTES as i } from "./individual-nav-routes.js";
4
+ import { ORGANIZATION_NAV_ROUTES as s } from "./organization-nav-routes.js";
5
+ const l = [{
6
+ id: "for-individuals-explore",
7
+ title: "Explore",
8
+ sections: [{
9
+ id: "explore",
10
+ title: "Explore",
11
+ items: [{
12
+ id: "jobs",
13
+ label: "Jobs",
14
+ description: "Find your next role",
15
+ href: i.jobs,
16
+ icon: /* @__PURE__ */ e("img", { src: "/products/jobs.svg", alt: "Jobs", className: "h-11 w-11 shrink-0", loading: "lazy" })
17
+ }, {
18
+ id: "courses",
19
+ label: "Courses",
20
+ description: "Upskill your career",
21
+ href: i.courses,
22
+ icon: /* @__PURE__ */ e("img", { src: "/products/courses.svg", alt: "Courses", className: "h-11 w-11 shrink-0", loading: "lazy" })
23
+ }, {
24
+ id: "events",
25
+ label: "Events",
26
+ description: "Medical conferences",
27
+ href: i.events,
28
+ icon: /* @__PURE__ */ e("img", { src: "/products/events.svg", alt: "Events", className: "h-11 w-11 shrink-0", loading: "lazy" })
29
+ }]
30
+ }]
31
+ }, {
32
+ id: "professional-tools",
33
+ title: "Professional Tools",
34
+ sections: [{
35
+ id: "tools",
36
+ title: "Professional Tools",
37
+ items: [{
38
+ id: "logbook",
39
+ label: "Logbook",
40
+ description: "Track clinical experiences",
41
+ href: i.logbook,
42
+ icon: /* @__PURE__ */ e("img", { src: "/products/log-book.svg", alt: "Logbook", className: "h-9 w-9 sm:h-10 sm:w-10 shrink-0", loading: "lazy" })
43
+ }, {
44
+ id: "resume-builder",
45
+ label: "Resume Builder",
46
+ description: "Build professional CV",
47
+ href: i["resume-builder"],
48
+ icon: /* @__PURE__ */ e("img", { src: "/products/resume-builder.svg", alt: "Resume Builder", className: "h-9 w-9 sm:h-10 sm:w-10 shrink-0", loading: "lazy" })
49
+ }, {
50
+ id: "exhibitor",
51
+ label: "Exhibitor",
52
+ description: "Your digital e-visitor book",
53
+ href: i.exhibitor,
54
+ icon: /* @__PURE__ */ e("img", { src: "/products/exhibitor.svg", alt: "Exhibitor", className: "h-7 w-7 sm:h-8 sm:w-8 shrink-0", loading: "lazy" })
55
+ }]
56
+ }]
57
+ }, {
58
+ id: "knowledge-hub",
59
+ title: "Knowledge Hub",
60
+ sections: [{
61
+ id: "knowledge-main",
62
+ title: "Knowledge Hub",
63
+ items: [
64
+ // Hidden until dedicated page is ready:
65
+ // { id: "library", label: "Library", href: INDIVIDUAL_NAV_ROUTES.library, icon: <img src="/products/library.svg" alt="Library" className="h-8 w-8 sm:h-10 sm:w-10 shrink-0" loading="lazy" /> },
66
+ {
67
+ id: "news",
68
+ label: "News",
69
+ href: i.news,
70
+ icon: /* @__PURE__ */ e("img", { src: "/products/news.svg", alt: "News", className: "h-8 w-8 sm:h-10 sm:w-10 shrink-0", loading: "lazy" })
71
+ }
72
+ ],
73
+ hasSeparatorAfterIndex: 0
74
+ }, {
75
+ id: "knowledge-links",
76
+ // title: "Course Pages",
77
+ title: "",
78
+ noPadding: !0,
79
+ items: [{
80
+ id: "course-pages",
81
+ label: "Course Pages",
82
+ href: i["course-pages"]
83
+ }, {
84
+ id: "job-role-pages",
85
+ label: "Job Role Pages",
86
+ href: i["job-role-pages"]
87
+ }, {
88
+ id: "explore-courses-after-12th",
89
+ label: "Courses After 12th",
90
+ href: i["explore-courses-after-12th"]
91
+ }]
92
+ }]
93
+ }, {
94
+ id: "about-docthub",
95
+ title: "About Docthub",
96
+ variant: "highlighted",
97
+ sections: [{
98
+ id: "about",
99
+ title: "About Docthub",
100
+ items: [
101
+ {
102
+ id: "about-us",
103
+ label: "About Us",
104
+ href: i["about-us"]
105
+ },
106
+ {
107
+ id: "media-release",
108
+ label: "Media Release",
109
+ href: i["media-release"]
110
+ },
111
+ // Hidden until dedicated pages are ready:
112
+ // { id: "press-kit", label: "Press Kit", href: INDIVIDUAL_NAV_ROUTES["press-kit"] },
113
+ // { id: "policies", label: "Policies", href: INDIVIDUAL_NAV_ROUTES.policies },
114
+ {
115
+ id: "contact-us",
116
+ label: "Contact Us",
117
+ href: i["contact-us"]
118
+ }
119
+ ]
120
+ }],
121
+ footer: /* @__PURE__ */ e("div", { className: "mt-2 flex flex-col gap-2", children: /* @__PURE__ */ t("a", { href: i.healthcareCareerApp, className: "flex items-center gap-3 rounded-2xl border-2 border-[rgba(0,160,192,0.12)] bg-white px-2.5 py-2.5", children: [
122
+ /* @__PURE__ */ e("div", { className: "flex h-10 w-10 shrink-0 items-center justify-center", children: /* @__PURE__ */ e("img", { src: "/products/mobile-app.svg", alt: "Docthub Mobile App", className: "h-11 w-11 shrink-0", loading: "lazy" }) }),
123
+ /* @__PURE__ */ t("div", { className: "min-w-0 flex-1", children: [
124
+ /* @__PURE__ */ e("p", { className: "text-sm font-semibold text-primary", children: "Get Career App" }),
125
+ /* @__PURE__ */ e("p", { className: "text-[11px] font-medium leading-4 text-neutral-56", children: "Available on iOS and Android" })
126
+ ] })
127
+ ] }) })
128
+ }], n = [{
129
+ id: "for-organizations-business-solutions",
130
+ title: "Solutions",
131
+ sections: [{
132
+ id: "business-solutions",
133
+ title: "Business Solutions",
134
+ items: [{
135
+ id: "recruiter-solution",
136
+ label: "Recruiter Solution",
137
+ description: "Healthcare Hiring Made Easy",
138
+ href: s["recruiter-solution"],
139
+ icon: /* @__PURE__ */ e("img", { src: "/products/organization/jobs.svg", alt: "Recruiter Solution", className: "h-8 w-8 shrink-0", loading: "lazy" })
140
+ }, {
141
+ id: "institute-solution",
142
+ label: "Institute Solution",
143
+ description: "Course Admission Leads & Promotion",
144
+ href: s["institute-solution"],
145
+ icon: /* @__PURE__ */ e("img", { src: "/products/organization/courses.svg", alt: "Institute Solution", className: "h-8 w-8 shrink-0", loading: "lazy" })
146
+ }, {
147
+ id: "events-organizer-solution",
148
+ label: "Events Organizer Solution",
149
+ description: "Ease of Healthcare Event Management",
150
+ href: s["events-organizer-solution"],
151
+ icon: /* @__PURE__ */ e("img", { src: "/products/organization/events.svg", alt: "Events Organizer Solution", className: "h-8 w-8 shrink-0", loading: "lazy" })
152
+ }, {
153
+ id: "membership-management",
154
+ label: "Membership Management",
155
+ description: "A Cloud Office for Professional Associations",
156
+ href: s["membership-management"],
157
+ icon: /* @__PURE__ */ e("img", { src: "/products/organization/membership-management.svg", alt: "Membership Management", className: "h-8 w-8 shrink-0", loading: "lazy" })
158
+ }]
159
+ }]
160
+ }, {
161
+ id: "docthub-enterprise",
162
+ title: "Docthub Enterprise",
163
+ noTopBorder: !0,
164
+ sections: [{
165
+ id: "enterprise-main",
166
+ title: "Docthub Enterprise",
167
+ items: [
168
+ {
169
+ id: "what-is-enterprise",
170
+ label: "What is Docthub Enterprise?",
171
+ href: s["what-is-enterprise"]
172
+ },
173
+ // For Next Phase
174
+ // {
175
+ // id: "request-demo",
176
+ // label: "Request Demo",
177
+ // href: ORGANIZATION_NAV_ROUTES["request-demo"],
178
+ // },
179
+ {
180
+ id: "contact-sales",
181
+ label: "Contact Sales",
182
+ href: s["contact-sales"]
183
+ }
184
+ ],
185
+ hasSeparatorAfterIndex: 2
186
+ }, {
187
+ id: "popular-capabilities",
188
+ title: "Popular Capabilities",
189
+ noPadding: !0,
190
+ items: [{
191
+ id: "digital-qr-check-in",
192
+ label: "Digital QR Check-In",
193
+ href: s["qr-check-in-app"],
194
+ icon: /* @__PURE__ */ e("img", { src: "/products/qr-checkin.svg", alt: "Digital QR Check-In", className: "h-11 w-11 shrink-0", loading: "lazy" })
195
+ }, {
196
+ id: "candidate-search",
197
+ label: "Candidate Search",
198
+ href: s["recruiter-solution"],
199
+ icon: /* @__PURE__ */ e("img", { src: "/products/candidate-search.svg", alt: "Candidate Search", className: "h-11 w-11 shrink-0", loading: "lazy" })
200
+ }]
201
+ }]
202
+ }, {
203
+ id: "enterprise-access",
204
+ title: "Enterprise Access",
205
+ variant: "highlighted",
206
+ sections: [{
207
+ id: "enterprise-access-links",
208
+ title: "Enterprise Access",
209
+ items: [
210
+ {
211
+ id: "enterprise-login",
212
+ label: "Enterprise Login",
213
+ href: s["enterprise-login"]
214
+ },
215
+ {
216
+ id: "create-enterprise-account",
217
+ label: "Create Enterprise/ Business Account",
218
+ href: s["create-enterprise-account"]
219
+ }
220
+ // Hidden for now:
221
+ // { id: "contact-support", label: "Contact Support", href: ORGANIZATION_NAV_ROUTES["contact-support"] },
222
+ ]
223
+ }],
224
+ footer: /* @__PURE__ */ t("div", { className: "flex flex-col gap-3 border-t border-black/8 pt-4 pl-3", children: [
225
+ /* @__PURE__ */ e("img", { src: "/products/organization-docthub-logo.svg", alt: "Docthub Enterprise", className: "h-5 w-[155px] shrink-0", loading: "lazy" }),
226
+ /* @__PURE__ */ t("p", { className: "text-[10px] font-normal leading-[14px] text-primary/80", children: [
227
+ "Post Jobs • List Courses • Create Events",
228
+ /* @__PURE__ */ e("br", {}),
229
+ "Manage Associations • Campus Placements",
230
+ /* @__PURE__ */ e("br", {}),
231
+ "E-certifications — All in one business account."
232
+ ] })
233
+ ] })
234
+ }];
235
+ export {
236
+ l as individualNavigationGroups,
237
+ n as organizationNavigationGroups
238
+ };
@@ -0,0 +1,6 @@
1
+ "use client";
2
+ const o = "for-individuals", I = "for-organizations";
3
+ export {
4
+ o as MOBILE_CATEGORY_INDIVIDUALS,
5
+ I as MOBILE_CATEGORY_ORGANIZATIONS
6
+ };