@burdenoff/fe-libs 2026.527.2 → 2026.527.4

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 (161) hide show
  1. package/dist/button/Button.js +18 -16
  2. package/dist/chrome/AccountSwitcher.js +10 -7
  3. package/dist/chrome/AutoBreadcrumbs.js +2 -0
  4. package/dist/chrome/Breadcrumbs.js +2 -0
  5. package/dist/chrome/CommandPalette.js +5 -3
  6. package/dist/chrome/ContextSwitcher.js +90 -338
  7. package/dist/chrome/DynamicFooter.js +7 -7
  8. package/dist/chrome/Footer.js +5 -5
  9. package/dist/chrome/GeographySwitcher.js +3 -3
  10. package/dist/chrome/GlobalSearch.js +73 -448
  11. package/dist/chrome/HeaderBar.js +6 -1
  12. package/dist/chrome/LanguagePickerSheet.js +1 -1
  13. package/dist/chrome/LanguageSwitcher.js +2 -2
  14. package/dist/chrome/NotificationCenter.js +69 -694
  15. package/dist/chrome/PanelTabs.js +7 -4
  16. package/dist/chrome/PluginContextMenuTarget.js +1 -1
  17. package/dist/chrome/ProductPickerSheet.js +4 -4
  18. package/dist/chrome/ProductSideNav.js +1 -1
  19. package/dist/chrome/ProductSwitcher.js +3 -3
  20. package/dist/chrome/ProfileSwitcher.js +13 -8
  21. package/dist/chrome/ShortcutHelpDialog.js +2 -1
  22. package/dist/chrome/SideNavigation.js +75 -239
  23. package/dist/chrome/Sidebar.js +1 -0
  24. package/dist/chrome/contextSwitcher/EmptyState.js +32 -0
  25. package/dist/chrome/contextSwitcher/OrganizationList.js +34 -0
  26. package/dist/chrome/contextSwitcher/ProjectList.js +34 -0
  27. package/dist/chrome/contextSwitcher/SearchInput.js +50 -0
  28. package/dist/chrome/contextSwitcher/TabButton.js +9 -0
  29. package/dist/chrome/contextSwitcher/TriggerButton.js +38 -0
  30. package/dist/chrome/contextSwitcher/WorkspaceList.js +34 -0
  31. package/dist/chrome/contextSwitcher/icons.js +58 -0
  32. package/dist/chrome/contextSwitcher/useIsMobile.js +11 -0
  33. package/dist/chrome/globalSearch/AdvancedFiltersPanel.js +253 -0
  34. package/dist/chrome/globalSearch/CategoryTabs.js +28 -0
  35. package/dist/chrome/globalSearch/ResultsList.js +58 -0
  36. package/dist/chrome/globalSearch/SearchInput.js +28 -0
  37. package/dist/chrome/globalSearch/SearchModeBar.js +36 -0
  38. package/dist/chrome/globalSearch/useAdvancedFilters.js +78 -0
  39. package/dist/chrome/globalSearch/utils.js +22 -0
  40. package/dist/chrome/notificationCenter/BellButton.js +27 -0
  41. package/dist/chrome/notificationCenter/NotificationCardItem.js +129 -0
  42. package/dist/chrome/notificationCenter/NotificationFilters.js +67 -0
  43. package/dist/chrome/notificationCenter/NotificationFooter.js +23 -0
  44. package/dist/chrome/notificationCenter/NotificationHeader.js +75 -0
  45. package/dist/chrome/notificationCenter/NotificationList.js +75 -0
  46. package/dist/chrome/notificationCenter/NotificationPanel.js +19 -0
  47. package/dist/chrome/notificationCenter/SkeletonCard.js +18 -0
  48. package/dist/chrome/notificationCenter/constants.js +93 -0
  49. package/dist/chrome/notificationCenter/gql.js +58 -0
  50. package/dist/chrome/notificationCenter/useNotificationCenter.js +149 -0
  51. package/dist/chrome/notificationCenter/usePanelChrome.js +36 -0
  52. package/dist/chrome/sideNavigation/CollapseToggle.js +29 -0
  53. package/dist/chrome/sideNavigation/MobileActionsBar.js +25 -0
  54. package/dist/chrome/sideNavigation/NavItemRenderer.js +79 -0
  55. package/dist/chrome/sideNavigation/SidebarHeader.js +29 -0
  56. package/dist/chrome/sideNavigation/helpers.js +19 -0
  57. package/dist/chrome/sideNavigation/useSideNavigationState.js +45 -0
  58. package/dist/form/Checkbox.js +17 -15
  59. package/dist/form/FormDescription.js +9 -10
  60. package/dist/form/FormField.js +11 -12
  61. package/dist/form/FormLabel.js +13 -13
  62. package/dist/form/FormMessage.js +10 -11
  63. package/dist/form/Input.js +11 -10
  64. package/dist/form/Radio.js +25 -21
  65. package/dist/form/Select.js +81 -66
  66. package/dist/form/Textarea.js +10 -9
  67. package/dist/shared/components/AccessDenied.js +8 -4
  68. package/dist/shared/components/AppErrorBoundary.js +2 -0
  69. package/dist/shared/components/ContextConversationWidget.js +173 -767
  70. package/dist/shared/components/ErrorFallback.js +3 -0
  71. package/dist/shared/components/PWAInstallBanner.js +8 -4
  72. package/dist/shared/components/RequireAuth.js +4 -4
  73. package/dist/shared/components/SSORedirectGuard.js +1 -1
  74. package/dist/shared/components/contextConversationWidget/Composer.js +66 -0
  75. package/dist/shared/components/contextConversationWidget/MessageItem.js +124 -0
  76. package/dist/shared/components/contextConversationWidget/MessageList.js +32 -0
  77. package/dist/shared/components/contextConversationWidget/NoWorkspaceCard.js +19 -0
  78. package/dist/shared/components/contextConversationWidget/PendingAttachmentsBar.js +28 -0
  79. package/dist/shared/components/contextConversationWidget/ReplyBanner.js +32 -0
  80. package/dist/shared/components/contextConversationWidget/WidgetHeader.js +70 -0
  81. package/dist/shared/components/contextConversationWidget/queries.js +197 -0
  82. package/dist/shared/components/contextConversationWidget/types.js +10 -0
  83. package/dist/shared/components/contextConversationWidget/useAttachmentUpload.js +57 -0
  84. package/dist/shared/components/contextConversationWidget/useConversationSubscriptions.js +26 -0
  85. package/dist/shared/components/contextConversationWidget/useMessageActions.js +34 -0
  86. package/dist/shared/components/contextConversationWidget/useSendMessage.js +45 -0
  87. package/dist/shared/components/contextConversationWidget/useWidgetMessages.js +44 -0
  88. package/dist/shared/components/contextConversationWidget/utils.js +56 -0
  89. package/dist/shared/feature-flags/FeatureFlagProvider.js +21 -21
  90. package/dist/shared/geography/GeographyProvider.js +20 -20
  91. package/dist/shared/graphql/GatewayContext.js +1 -1
  92. package/dist/shared/motion/MotionList.js +1 -1
  93. package/dist/shared/pages/AiPage.js +3 -3
  94. package/dist/shared/pages/SearchPage.js +293 -1071
  95. package/dist/shared/pages/searchPage/ActiveFilterChips.js +176 -0
  96. package/dist/shared/pages/searchPage/FiltersPanel.js +329 -0
  97. package/dist/shared/pages/searchPage/ResultsList.js +119 -0
  98. package/dist/shared/pages/searchPage/ResultsStatus.js +32 -0
  99. package/dist/shared/pages/searchPage/SearchInput.js +31 -0
  100. package/dist/shared/pages/searchPage/SearchPagination.js +37 -0
  101. package/dist/shared/pages/searchPage/SearchToolbar.js +58 -0
  102. package/dist/shared/pages/searchPage/constants.js +155 -0
  103. package/dist/shared/pages/searchPage/utils.js +24 -0
  104. package/dist/shared/plugins/PluginRuntimeProvider.js +1 -1
  105. package/dist/shared/providers/shell/ActiveContextProvider.js +12 -12
  106. package/dist/shared/providers/shell/AppShellContext.js +1 -1
  107. package/dist/shared/providers/shell/AuthProvider.js +130 -384
  108. package/dist/shared/providers/shell/AuthTokenProvider.js +6 -6
  109. package/dist/shared/providers/shell/ContextManagerProvider.js +1 -1
  110. package/dist/shared/providers/shell/FeatureFlagsProvider.js +5 -5
  111. package/dist/shared/providers/shell/GlobalUiProvider.js +17 -17
  112. package/dist/shared/providers/shell/I18nProvider.js +15 -15
  113. package/dist/shared/providers/shell/PageConversationContextProvider.js +14 -14
  114. package/dist/shared/providers/shell/PermissionProvider.js +16 -16
  115. package/dist/shared/providers/shell/ShellUiProvider.js +13 -13
  116. package/dist/shared/providers/shell/ThemeProvider.js +9 -9
  117. package/dist/shared/providers/shell/authProvider/bridgeStateSync.js +34 -0
  118. package/dist/shared/providers/shell/authProvider/jwt.js +13 -0
  119. package/dist/shared/providers/shell/authProvider/ssoRelay.js +38 -0
  120. package/dist/shared/providers/shell/authProvider/useAuthActions.js +170 -0
  121. package/dist/shared/providers/shell/authProvider/useBridgeInitialization.js +86 -0
  122. package/dist/shared/providers/shell/authProvider/useRemoteSLO.js +32 -0
  123. package/dist/shared/providers/shell/authProvider/useStorageSync.js +35 -0
  124. package/dist/shared/providers/shell/authProvider/useTokenExpiryTimer.js +37 -0
  125. package/dist/shared/tours/TourPlayer.js +1 -0
  126. package/dist/shared/tours/TourPlayerProvider.js +1 -1
  127. package/dist/shared/tours/TourTooltip.js +3 -0
  128. package/dist/shared/tours/TourTrigger.js +86 -259
  129. package/dist/shared/tours/ToursContext.js +108 -398
  130. package/dist/shared/tours/tourTrigger/DesktopTourDropdown.js +48 -0
  131. package/dist/shared/tours/tourTrigger/MobileTourSheet.js +68 -0
  132. package/dist/shared/tours/tourTrigger/TourListItemDesktop.js +36 -0
  133. package/dist/shared/tours/tourTrigger/TourListItemMobile.js +47 -0
  134. package/dist/shared/tours/tourTrigger/TourStatusChip.js +30 -0
  135. package/dist/shared/tours/tourTrigger/TourTriggerButton.js +22 -0
  136. package/dist/shared/tours/toursContext/errors.js +18 -0
  137. package/dist/shared/tours/toursContext/gql.js +152 -0
  138. package/dist/shared/tours/toursContext/route.js +20 -0
  139. package/dist/shared/tours/toursContext/session.js +19 -0
  140. package/dist/shared/tours/toursContext/useIdleReady.js +18 -0
  141. package/dist/shared/tours/toursContext/useTourMutations.js +118 -0
  142. package/dist/shared-events.js +3 -3
  143. package/dist/shared-hooks.js +1 -1
  144. package/dist/storage/SaveToFilesButton.js +3 -3
  145. package/dist/storage/SaveToFilesDialog.js +1 -1
  146. package/dist/tag/TagBadge.js +1 -1
  147. package/dist/tag/TagsWidget.js +81 -226
  148. package/dist/tag/tagsWidget/AddTagTrigger.js +14 -0
  149. package/dist/tag/tagsWidget/TagBadgeList.js +17 -0
  150. package/dist/tag/tagsWidget/TagSearchPopover.js +80 -0
  151. package/dist/tag/tagsWidget/operations.js +64 -0
  152. package/dist/tag/tagsWidget/useVocabResolver.js +30 -0
  153. package/dist/ui/card.js +44 -39
  154. package/dist/ui/dropdown-menu.js +82 -66
  155. package/dist/ui/input.js +10 -10
  156. package/dist/ui/label.js +13 -11
  157. package/dist/ui/select.js +80 -66
  158. package/dist/ui/table.js +61 -54
  159. package/dist/ui/textarea.js +9 -9
  160. package/dist/ui/tooltip.js +13 -11
  161. package/package.json +1 -1
@@ -1,398 +1,150 @@
1
1
  import { Sheet as e, SheetContent as t, SheetHeader as n, SheetTitle as r } from "../ui/sheet.js";
2
- import { useCallback as i, useEffect as a, useRef as o, useState as s } from "react";
3
- import { Fragment as c, jsx as l, jsxs as u } from "react/jsx-runtime";
2
+ import { useIsMobile as i } from "./contextSwitcher/useIsMobile.js";
3
+ import { TabButton as a } from "./contextSwitcher/TabButton.js";
4
+ import { OrganizationList as o } from "./contextSwitcher/OrganizationList.js";
5
+ import { WorkspaceList as s } from "./contextSwitcher/WorkspaceList.js";
6
+ import { ProjectList as c } from "./contextSwitcher/ProjectList.js";
7
+ import { TriggerButton as l } from "./contextSwitcher/TriggerButton.js";
8
+ import { useCallback as u, useEffect as d, useRef as f, useState as p } from "react";
9
+ import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
4
10
  //#region src/chrome/ContextSwitcher.tsx
5
- function d(e = 640) {
6
- let [t, n] = s(!1);
7
- return a(() => {
8
- let t = () => n(window.innerWidth < e);
9
- return t(), window.addEventListener("resize", t), () => window.removeEventListener("resize", t);
10
- }, [e]), t;
11
- }
12
- var f = ({ value: e, onChange: t, placeholder: n, inputRef: r }) => /* @__PURE__ */ l("div", {
13
- className: "relative px-3 py-2 border-b border-[var(--color-border-subtle)]",
14
- children: /* @__PURE__ */ u("div", {
15
- className: "relative",
16
- children: [
17
- /* @__PURE__ */ l("svg", {
18
- className: "absolute left-3 top-1/2 -translate-y-1/2 w-4 h-4 text-[var(--color-text-tertiary)]",
19
- fill: "none",
20
- stroke: "currentColor",
21
- viewBox: "0 0 24 24",
22
- children: /* @__PURE__ */ l("path", {
23
- strokeLinecap: "round",
24
- strokeLinejoin: "round",
25
- strokeWidth: 2,
26
- d: "M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z"
27
- })
28
- }),
29
- /* @__PURE__ */ l("input", {
30
- ref: r,
31
- type: "text",
32
- value: e,
33
- onChange: (e) => t(e.target.value),
34
- placeholder: n,
35
- className: "w-full pl-9 pr-8 py-2 text-sm bg-[var(--color-bg-surface)] border border-[var(--color-border-subtle)] rounded-md focus:outline-none focus:ring-2 focus:ring-[var(--color-action-primary-border)] focus:border-transparent text-[var(--color-text-primary)] placeholder:text-[var(--color-text-tertiary)] transition-all duration-200"
36
- }),
37
- e && /* @__PURE__ */ l("button", {
38
- onClick: () => t(""),
39
- className: "absolute right-2 top-1/2 -translate-y-1/2 p-1 rounded-md hover:bg-[var(--color-action-ghost-bgHover)] text-[var(--color-text-tertiary)] hover:text-[var(--color-text-primary)] transition-all duration-150 ease-out",
40
- "aria-label": "Clear search",
41
- children: /* @__PURE__ */ l("svg", {
42
- className: "w-4 h-4",
43
- fill: "none",
44
- stroke: "currentColor",
45
- viewBox: "0 0 24 24",
46
- children: /* @__PURE__ */ l("path", {
47
- strokeLinecap: "round",
48
- strokeLinejoin: "round",
49
- strokeWidth: 2,
50
- d: "M6 18L18 6M6 6l12 12"
51
- })
52
- })
53
- })
54
- ]
55
- })
56
- }), p = ({ message: e, isSearchResult: t }) => /* @__PURE__ */ l("div", {
57
- className: "px-4 py-8 text-center animate-in fade-in-0 duration-200",
58
- children: t ? /* @__PURE__ */ u(c, { children: [
59
- /* @__PURE__ */ l("svg", {
60
- className: "w-8 h-8 mx-auto mb-2 text-[var(--color-text-tertiary)]",
61
- fill: "none",
62
- stroke: "currentColor",
63
- viewBox: "0 0 24 24",
64
- children: /* @__PURE__ */ l("path", {
65
- strokeLinecap: "round",
66
- strokeLinejoin: "round",
67
- strokeWidth: 2,
68
- d: "M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z"
69
- })
70
- }),
71
- /* @__PURE__ */ l("p", {
72
- className: "text-[var(--color-text-secondary)] text-sm",
73
- children: "No results found"
74
- }),
75
- /* @__PURE__ */ l("p", {
76
- className: "text-[var(--color-text-tertiary)] text-xs mt-1",
77
- children: "Try a different search term"
78
- })
79
- ] }) : /* @__PURE__ */ l("p", {
80
- className: "text-[var(--color-text-secondary)] text-sm",
81
- children: e
82
- })
83
- }), m = ({ label: e, isActive: t, onClick: n }) => /* @__PURE__ */ l("button", {
84
- onClick: n,
85
- className: `flex-1 px-3 py-2.5 text-[13px] font-medium whitespace-nowrap text-center transition-all duration-200 ease-out ${t ? "text-[var(--color-text-link)] border-b-2 border-[var(--color-action-primary-bg)] bg-[var(--color-bg-accent)]" : "text-[var(--color-text-secondary)] hover:text-[var(--color-text-primary)] hover:bg-[var(--color-action-ghost-bgHover)] border-b-2 border-transparent"}`,
86
- children: e
87
- }), h = ({ organizations: h, workspaces: g, projects: _, currentOrganizationId: v, currentWorkspaceId: y, currentProjectId: b, onOrganizationChange: x, onWorkspaceChange: S, onProjectChange: C, compact: w = !1 }) => {
88
- let [T, E] = s(!1), [D, O] = s(() => v ? "workspace" : "org"), [k, A] = s({
11
+ var _ = ({ organizations: _, workspaces: v, projects: y, currentOrganizationId: b, currentWorkspaceId: x, currentProjectId: S, onOrganizationChange: C, onWorkspaceChange: w, onProjectChange: T, compact: E = !1 }) => {
12
+ let [D, O] = p(!1), [k, A] = p(() => b ? "workspace" : "org"), [j, M] = p({
89
13
  org: "",
90
14
  workspace: "",
91
15
  project: ""
92
- }), j = d(), M = o(null), N = o(null), P = o(v);
93
- P.current = v;
94
- let F = h.find((e) => e.id === v), I = g.find((e) => e.id === y), L = _.find((e) => e.id === b), R = g.filter((e) => e.organizationId === v), z = _.filter((e) => e.workspaceId === y), B = i((e, t) => {
16
+ }), N = i(), P = f(null), F = f(null), I = f(b);
17
+ I.current = b;
18
+ let L = _.find((e) => e.id === b), R = v.find((e) => e.id === x), z = y.find((e) => e.id === S), B = v.filter((e) => e.organizationId === b), V = y.filter((e) => e.workspaceId === x), H = u((e, t) => {
95
19
  if (!t.trim()) return e;
96
20
  let n = t.toLowerCase().trim();
97
21
  return e.filter((e) => e.name.toLowerCase().includes(n));
98
- }, []), V = B(h, k.org), H = B(R, k.workspace), U = B(z, k.project), W = i((e, t) => {
99
- A((n) => ({
22
+ }, []), U = H(_, j.org), W = H(B, j.workspace), G = H(V, j.project), K = u((e, t) => {
23
+ M((n) => ({
100
24
  ...n,
101
25
  [e]: t
102
26
  }));
103
- }, []), G = i((e) => {
104
- O(e), A({
27
+ }, []), q = u((e) => {
28
+ A(e), M({
105
29
  org: "",
106
30
  workspace: "",
107
31
  project: ""
108
32
  }), setTimeout(() => {
109
- N.current?.focus();
33
+ F.current?.focus();
110
34
  }, 50);
111
35
  }, []);
112
- a(() => {
113
- if (j) return;
36
+ d(() => {
37
+ if (N) return;
114
38
  let e = (e) => {
115
- M.current && !M.current.contains(e.target) && E(!1);
39
+ P.current && !P.current.contains(e.target) && O(!1);
116
40
  };
117
- if (T) return document.addEventListener("mousedown", e), () => document.removeEventListener("mousedown", e);
118
- }, [T, j]), a(() => {
119
- if (T) {
120
- O(P.current ? "workspace" : "org");
41
+ if (D) return document.addEventListener("mousedown", e), () => document.removeEventListener("mousedown", e);
42
+ }, [D, N]), d(() => {
43
+ if (D) {
44
+ A(I.current ? "workspace" : "org");
121
45
  let e = setTimeout(() => {
122
- N.current?.focus();
46
+ F.current?.focus();
123
47
  }, 100);
124
48
  return () => clearTimeout(e);
125
49
  }
126
- A({
50
+ M({
127
51
  org: "",
128
52
  workspace: "",
129
53
  project: ""
130
54
  });
131
- }, [T]);
132
- let K = (e) => {
133
- x && x(e);
134
- }, q = (e) => {
135
- S && S(e);
136
- }, J = (e) => {
137
- C && C(e), E(!1);
138
- }, Y = () => /* @__PURE__ */ u(c, { children: [/* @__PURE__ */ u("div", {
55
+ }, [D]);
56
+ let J = (e) => {
57
+ C && C(e);
58
+ }, Y = (e) => {
59
+ w && w(e);
60
+ }, X = (e) => {
61
+ T && T(e), O(!1);
62
+ }, Z = () => /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ g("div", {
139
63
  className: "flex items-stretch border-b border-[var(--color-border-subtle)] bg-[var(--color-bg-surface)]",
140
64
  children: [
141
- /* @__PURE__ */ l(m, {
65
+ /* @__PURE__ */ h(a, {
142
66
  label: "Organization",
143
- isActive: D === "org",
144
- onClick: () => G("org")
67
+ isActive: k === "org",
68
+ onClick: () => q("org")
145
69
  }),
146
- /* @__PURE__ */ l(m, {
70
+ /* @__PURE__ */ h(a, {
147
71
  label: "Workspace",
148
- isActive: D === "workspace",
149
- onClick: () => G("workspace")
72
+ isActive: k === "workspace",
73
+ onClick: () => q("workspace")
150
74
  }),
151
- /* @__PURE__ */ l(m, {
75
+ /* @__PURE__ */ h(a, {
152
76
  label: "Project",
153
- isActive: D === "project",
154
- onClick: () => G("project")
77
+ isActive: k === "project",
78
+ onClick: () => q("project")
155
79
  })
156
80
  ]
157
- }), /* @__PURE__ */ u("div", {
81
+ }), /* @__PURE__ */ g("div", {
158
82
  className: "flex-1 overflow-hidden",
159
83
  children: [
160
- D === "org" && /* @__PURE__ */ u("div", {
161
- className: "h-full flex flex-col",
162
- children: [/* @__PURE__ */ l(f, {
163
- value: k.org,
164
- onChange: (e) => W("org", e),
165
- placeholder: "Search organizations...",
166
- inputRef: N
167
- }), /* @__PURE__ */ l("div", {
168
- className: "flex-1 overflow-y-auto py-1",
169
- children: V.length > 0 ? V.map((e, t) => /* @__PURE__ */ u("button", {
170
- onClick: () => K(e),
171
- className: `w-full flex items-center gap-3 px-4 py-3 text-sm transition-all duration-200 ease-out animate-in fade-in-0 slide-in-from-left-2 ${e.id === v ? "bg-[var(--color-bg-accent)] text-[var(--color-text-primary)] font-medium" : "text-[var(--color-text-primary)] hover:bg-[var(--color-action-ghost-bgHover)] hover:translate-x-0.5"}`,
172
- style: { animationDelay: `${t * 30}ms` },
173
- children: [
174
- /* @__PURE__ */ l("svg", {
175
- className: "w-5 h-5 text-[var(--color-text-secondary)] flex-shrink-0",
176
- fill: "none",
177
- stroke: "currentColor",
178
- viewBox: "0 0 24 24",
179
- children: /* @__PURE__ */ l("path", {
180
- strokeLinecap: "round",
181
- strokeLinejoin: "round",
182
- strokeWidth: 2,
183
- d: "M19 21V5a2 2 0 00-2-2H7a2 2 0 00-2 2v16m14 0h2m-2 0h-5m-9 0H3m2 0h5M9 7h1m-1 4h1m4-4h1m-1 4h1m-5 10v-5a1 1 0 011-1h2a1 1 0 011 1v5m-4 0h4"
184
- })
185
- }),
186
- /* @__PURE__ */ l("span", {
187
- className: "flex-1 text-left truncate",
188
- children: e.name
189
- }),
190
- e.id === v && /* @__PURE__ */ l("svg", {
191
- className: "w-5 h-5 text-[var(--color-action-primary-bg)] flex-shrink-0 animate-in zoom-in-50 duration-200",
192
- fill: "currentColor",
193
- viewBox: "0 0 20 20",
194
- children: /* @__PURE__ */ l("path", {
195
- fillRule: "evenodd",
196
- d: "M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",
197
- clipRule: "evenodd"
198
- })
199
- })
200
- ]
201
- }, e.id)) : /* @__PURE__ */ l(p, {
202
- message: "No organizations available",
203
- isSearchResult: k.org.length > 0
204
- })
205
- })]
84
+ k === "org" && /* @__PURE__ */ h(o, {
85
+ organizations: _,
86
+ searchedOrganizations: U,
87
+ currentOrganizationId: b,
88
+ searchQuery: j.org,
89
+ onSearchChange: (e) => K("org", e),
90
+ onSelect: J,
91
+ searchInputRef: F
206
92
  }),
207
- D === "workspace" && /* @__PURE__ */ u("div", {
208
- className: "h-full flex flex-col",
209
- children: [/* @__PURE__ */ l(f, {
210
- value: k.workspace,
211
- onChange: (e) => W("workspace", e),
212
- placeholder: "Search workspaces...",
213
- inputRef: N
214
- }), /* @__PURE__ */ l("div", {
215
- className: "flex-1 overflow-y-auto py-1",
216
- children: R.length === 0 ? /* @__PURE__ */ l(p, { message: "No workspaces in this organization" }) : H.length > 0 ? H.map((e, t) => /* @__PURE__ */ u("button", {
217
- onClick: () => q(e),
218
- className: `w-full flex items-center gap-3 px-4 py-3 text-sm transition-all duration-200 ease-out animate-in fade-in-0 slide-in-from-left-2 ${e.id === y ? "bg-[var(--color-bg-accent)] text-[var(--color-text-primary)] font-medium" : "text-[var(--color-text-primary)] hover:bg-[var(--color-action-ghost-bgHover)] hover:translate-x-0.5"}`,
219
- style: { animationDelay: `${t * 30}ms` },
220
- children: [
221
- /* @__PURE__ */ l("svg", {
222
- className: "w-5 h-5 text-[var(--color-text-secondary)] flex-shrink-0",
223
- fill: "none",
224
- stroke: "currentColor",
225
- viewBox: "0 0 24 24",
226
- children: /* @__PURE__ */ l("path", {
227
- strokeLinecap: "round",
228
- strokeLinejoin: "round",
229
- strokeWidth: 2,
230
- d: "M21 13.255A23.931 23.931 0 0112 15c-3.183 0-6.22-.62-9-1.745M16 6V4a2 2 0 00-2-2h-4a2 2 0 00-2 2v2m4 6h.01M5 20h14a2 2 0 002-2V8a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"
231
- })
232
- }),
233
- /* @__PURE__ */ l("span", {
234
- className: "flex-1 text-left truncate",
235
- children: e.name
236
- }),
237
- e.id === y && /* @__PURE__ */ l("svg", {
238
- className: "w-5 h-5 text-[var(--color-action-primary-bg)] flex-shrink-0 animate-in zoom-in-50 duration-200",
239
- fill: "currentColor",
240
- viewBox: "0 0 20 20",
241
- children: /* @__PURE__ */ l("path", {
242
- fillRule: "evenodd",
243
- d: "M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",
244
- clipRule: "evenodd"
245
- })
246
- })
247
- ]
248
- }, e.id)) : /* @__PURE__ */ l(p, {
249
- message: "No workspaces found",
250
- isSearchResult: k.workspace.length > 0
251
- })
252
- })]
93
+ k === "workspace" && /* @__PURE__ */ h(s, {
94
+ filteredWorkspaces: B,
95
+ searchedWorkspaces: W,
96
+ currentWorkspaceId: x,
97
+ searchQuery: j.workspace,
98
+ onSearchChange: (e) => K("workspace", e),
99
+ onSelect: Y,
100
+ searchInputRef: F
253
101
  }),
254
- D === "project" && /* @__PURE__ */ u("div", {
255
- className: "h-full flex flex-col",
256
- children: [/* @__PURE__ */ l(f, {
257
- value: k.project,
258
- onChange: (e) => W("project", e),
259
- placeholder: "Search projects...",
260
- inputRef: N
261
- }), /* @__PURE__ */ l("div", {
262
- className: "flex-1 overflow-y-auto py-1",
263
- children: z.length === 0 ? /* @__PURE__ */ l(p, { message: "No projects in this workspace" }) : U.length > 0 ? U.map((e, t) => /* @__PURE__ */ u("button", {
264
- onClick: () => J(e),
265
- className: `w-full flex items-center gap-3 px-4 py-3 text-sm transition-all duration-200 ease-out animate-in fade-in-0 slide-in-from-left-2 ${e.id === b ? "bg-[var(--color-bg-accent)] text-[var(--color-text-primary)] font-medium" : "text-[var(--color-text-primary)] hover:bg-[var(--color-action-ghost-bgHover)] hover:translate-x-0.5"}`,
266
- style: { animationDelay: `${t * 30}ms` },
267
- children: [
268
- /* @__PURE__ */ l("svg", {
269
- className: "w-5 h-5 text-[var(--color-text-secondary)] flex-shrink-0",
270
- fill: "none",
271
- stroke: "currentColor",
272
- viewBox: "0 0 24 24",
273
- children: /* @__PURE__ */ l("path", {
274
- strokeLinecap: "round",
275
- strokeLinejoin: "round",
276
- strokeWidth: 2,
277
- d: "M3 7v10a2 2 0 002 2h14a2 2 0 002-2V9a2 2 0 00-2-2h-6l-2-2H5a2 2 0 00-2 2z"
278
- })
279
- }),
280
- /* @__PURE__ */ l("span", {
281
- className: "flex-1 text-left truncate",
282
- children: e.name
283
- }),
284
- e.id === b && /* @__PURE__ */ l("svg", {
285
- className: "w-5 h-5 text-[var(--color-action-primary-bg)] flex-shrink-0 animate-in zoom-in-50 duration-200",
286
- fill: "currentColor",
287
- viewBox: "0 0 20 20",
288
- children: /* @__PURE__ */ l("path", {
289
- fillRule: "evenodd",
290
- d: "M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",
291
- clipRule: "evenodd"
292
- })
293
- })
294
- ]
295
- }, e.id)) : /* @__PURE__ */ l(p, {
296
- message: "No projects found",
297
- isSearchResult: k.project.length > 0
298
- })
299
- })]
102
+ k === "project" && /* @__PURE__ */ h(c, {
103
+ filteredProjects: V,
104
+ searchedProjects: G,
105
+ currentProjectId: S,
106
+ searchQuery: j.project,
107
+ onSearchChange: (e) => K("project", e),
108
+ onSelect: X,
109
+ searchInputRef: F
300
110
  })
301
111
  ]
302
- })] }), X = /* @__PURE__ */ l("button", {
303
- onClick: () => E(!T),
304
- className: `flex items-center gap-2 px-3 py-2 rounded-md hover:bg-[var(--color-action-ghost-bgHover)] transition-all duration-200 ease-out ${T ? "bg-[var(--color-action-ghost-bgHover)]" : ""}`,
305
- "aria-label": "Switch context",
306
- "aria-expanded": T,
307
- children: w ? /* @__PURE__ */ l("svg", {
308
- className: "w-5 h-5 text-[var(--color-text-primary)]",
309
- fill: "none",
310
- stroke: "currentColor",
311
- viewBox: "0 0 24 24",
312
- children: /* @__PURE__ */ l("path", {
313
- strokeLinecap: "round",
314
- strokeLinejoin: "round",
315
- strokeWidth: 2,
316
- d: "M19 21V5a2 2 0 00-2-2H7a2 2 0 00-2 2v16m14 0h2m-2 0h-5m-9 0H3m2 0h5M9 7h1m-1 4h1m4-4h1m-1 4h1m-5 10v-5a1 1 0 011-1h2a1 1 0 011 1v5m-4 0h4"
317
- })
318
- }) : /* @__PURE__ */ u(c, { children: [/* @__PURE__ */ u("div", {
319
- className: "flex items-center gap-1.5",
320
- children: [/* @__PURE__ */ l("svg", {
321
- className: "w-4 h-4 text-[var(--color-text-secondary)]",
322
- fill: "none",
323
- stroke: "currentColor",
324
- viewBox: "0 0 24 24",
325
- children: /* @__PURE__ */ l("path", {
326
- strokeLinecap: "round",
327
- strokeLinejoin: "round",
328
- strokeWidth: 2,
329
- d: "M19 21V5a2 2 0 00-2-2H7a2 2 0 00-2 2v16m14 0h2m-2 0h-5m-9 0H3m2 0h5M9 7h1m-1 4h1m4-4h1m-1 4h1m-5 10v-5a1 1 0 011-1h2a1 1 0 011 1v5m-4 0h4"
330
- })
331
- }), /* @__PURE__ */ u("div", {
332
- className: "flex items-center gap-1 text-sm",
333
- children: [
334
- /* @__PURE__ */ l("span", {
335
- className: "text-[var(--color-text-primary)] font-medium",
336
- children: F?.name || "Select Org"
337
- }),
338
- /* @__PURE__ */ l("span", {
339
- className: "text-[var(--color-text-tertiary)]",
340
- children: "/"
341
- }),
342
- /* @__PURE__ */ l("span", {
343
- className: "text-[var(--color-text-secondary)]",
344
- children: I?.name || "Workspace"
345
- }),
346
- L && /* @__PURE__ */ u(c, { children: [/* @__PURE__ */ l("span", {
347
- className: "text-[var(--color-text-tertiary)]",
348
- children: "/"
349
- }), /* @__PURE__ */ l("span", {
350
- className: "text-[var(--color-text-secondary)]",
351
- children: L.name
352
- })] })
353
- ]
354
- })]
355
- }), /* @__PURE__ */ l("svg", {
356
- className: `w-4 h-4 text-[var(--color-text-secondary)] transition-transform duration-200 ${T ? "rotate-180" : ""}`,
357
- fill: "none",
358
- stroke: "currentColor",
359
- viewBox: "0 0 24 24",
360
- children: /* @__PURE__ */ l("path", {
361
- strokeLinecap: "round",
362
- strokeLinejoin: "round",
363
- strokeWidth: 2,
364
- d: "M19 9l-7 7-7-7"
365
- })
366
- })] })
112
+ })] }), Q = /* @__PURE__ */ h(l, {
113
+ isOpen: D,
114
+ compact: E,
115
+ currentOrg: L,
116
+ currentWorkspace: R,
117
+ currentProject: z,
118
+ onToggle: () => O(!D)
367
119
  });
368
- return j ? /* @__PURE__ */ u("div", {
120
+ return N ? /* @__PURE__ */ g("div", {
369
121
  className: "relative",
370
- children: [X, /* @__PURE__ */ l(e, {
371
- open: T,
372
- onOpenChange: E,
373
- children: /* @__PURE__ */ u(t, {
122
+ children: [Q, /* @__PURE__ */ h(e, {
123
+ open: D,
124
+ onOpenChange: O,
125
+ children: /* @__PURE__ */ g(t, {
374
126
  side: "bottom",
375
127
  className: "h-[70vh] flex flex-col p-0",
376
- children: [/* @__PURE__ */ l(n, {
128
+ children: [/* @__PURE__ */ h(n, {
377
129
  className: "px-4 pt-4 pb-2 border-b border-[var(--color-border-subtle)]",
378
- children: /* @__PURE__ */ l(r, {
130
+ children: /* @__PURE__ */ h(r, {
379
131
  className: "text-[var(--color-text-primary)]",
380
132
  children: "Switch Context"
381
133
  })
382
- }), /* @__PURE__ */ l("div", {
134
+ }), /* @__PURE__ */ h("div", {
383
135
  className: "flex-1 flex flex-col overflow-hidden",
384
- children: Y()
136
+ children: Z()
385
137
  })]
386
138
  })
387
139
  })]
388
- }) : /* @__PURE__ */ u("div", {
140
+ }) : /* @__PURE__ */ g("div", {
389
141
  className: "relative",
390
- ref: M,
391
- children: [X, T && /* @__PURE__ */ l("div", {
142
+ ref: P,
143
+ children: [Q, D && /* @__PURE__ */ h("div", {
392
144
  className: "absolute right-0 mt-2 w-[calc(100vw-2rem)] sm:w-[26rem] bg-[var(--color-bg-elevated)] border border-[var(--color-border-default)] rounded-lg shadow-lg z-50 flex flex-col max-h-[400px] animate-in fade-in-0 zoom-in-95 slide-in-from-top-2 duration-200",
393
- children: Y()
145
+ children: Z()
394
146
  })]
395
147
  });
396
148
  };
397
149
  //#endregion
398
- export { h as ContextSwitcher };
150
+ export { _ as ContextSwitcher };
@@ -39,12 +39,12 @@ var _ = h`
39
39
  about: "about",
40
40
  contact: "contact"
41
41
  }, b = {
42
- twitter: /* @__PURE__ */ m(f, { className: "w-5 h-5" }),
43
- x: /* @__PURE__ */ m(f, { className: "w-5 h-5" }),
44
- github: /* @__PURE__ */ m(c, { className: "w-5 h-5" }),
45
- discord: /* @__PURE__ */ m(d, { className: "w-5 h-5" }),
46
- linkedin: /* @__PURE__ */ m(u, { className: "w-5 h-5" }),
47
- youtube: /* @__PURE__ */ m(p, { className: "w-5 h-5" })
42
+ twitter: /* @__PURE__ */ m(f, { className: "size-5" }),
43
+ x: /* @__PURE__ */ m(f, { className: "size-5" }),
44
+ github: /* @__PURE__ */ m(c, { className: "size-5" }),
45
+ discord: /* @__PURE__ */ m(d, { className: "size-5" }),
46
+ linkedin: /* @__PURE__ */ m(u, { className: "size-5" }),
47
+ youtube: /* @__PURE__ */ m(p, { className: "size-5" })
48
48
  }, x = [
49
49
  "terms-of-service",
50
50
  "privacy-policy",
@@ -98,7 +98,7 @@ function S({ productSlug: c, productName: u, tagline: d, version: f = "v1.0.0",
98
98
  id: e,
99
99
  label: e.charAt(0).toUpperCase() + e.slice(1),
100
100
  href: t,
101
- icon: b[e.toLowerCase()] || /* @__PURE__ */ m(l, { className: "w-5 h-5" })
101
+ icon: b[e.toLowerCase()] || /* @__PURE__ */ m(l, { className: "size-5" })
102
102
  }));
103
103
  r.length > 0 && A(r);
104
104
  }).catch(() => {}), () => {
@@ -87,19 +87,19 @@ var s = [
87
87
  id: "twitter",
88
88
  label: "Twitter",
89
89
  href: "https://twitter.com/burdenoff",
90
- icon: /* @__PURE__ */ a(i, { className: "w-5 h-5" })
90
+ icon: /* @__PURE__ */ a(i, { className: "size-5" })
91
91
  },
92
92
  {
93
93
  id: "github",
94
94
  label: "GitHub",
95
95
  href: "https://github.com/algoshred",
96
- icon: /* @__PURE__ */ a(n, { className: "w-5 h-5" })
96
+ icon: /* @__PURE__ */ a(n, { className: "size-5" })
97
97
  },
98
98
  {
99
99
  id: "discord",
100
100
  label: "Discord",
101
101
  href: "https://discord.gg/burdenoff",
102
- icon: /* @__PURE__ */ a(r, { className: "w-5 h-5" })
102
+ icon: /* @__PURE__ */ a(r, { className: "size-5" })
103
103
  }
104
104
  ], l = ({ logo: n, productName: r = "Burdenoff Workspaces", tagline: i = "Enterprise collaboration made simple", columns: l = s, socialLinks: u = c, copyright: d, version: f, buildInfo: p, context: m, children: h, renderLink: g }) => {
105
105
  let _ = (/* @__PURE__ */ new Date()).getFullYear(), v = d ?? `${_} Burdenoff. All rights reserved.`, y = g ?? (({ href: e, external: t, children: n, className: r }) => /* @__PURE__ */ a("a", {
@@ -122,7 +122,7 @@ var s = [
122
122
  /* @__PURE__ */ o("div", {
123
123
  className: "flex items-center gap-3 mb-4",
124
124
  children: [n ?? /* @__PURE__ */ a("div", {
125
- className: "w-8 h-8 rounded-md bg-gradient-to-br from-brand-primary to-brand-secondary flex items-center justify-center text-white font-bold text-sm",
125
+ className: "size-8 rounded-md bg-gradient-to-br from-brand-primary to-brand-secondary flex items-center justify-center text-white font-bold text-sm",
126
126
  children: "B"
127
127
  }), /* @__PURE__ */ a("span", {
128
128
  className: "text-lg font-semibold text-text-primary",
@@ -157,7 +157,7 @@ var s = [
157
157
  children: [
158
158
  e.icon,
159
159
  e.label,
160
- e.external && /* @__PURE__ */ a(t, { className: "w-3 h-3" })
160
+ e.external && /* @__PURE__ */ a(t, { className: "size-3" })
161
161
  ]
162
162
  }) }, e.id))
163
163
  })] }, e.title))]
@@ -41,7 +41,7 @@ var s = [
41
41
  "aria-label": "Change country",
42
42
  "aria-expanded": f,
43
43
  children: d ? /* @__PURE__ */ a("svg", {
44
- className: "w-5 h-5 text-text-primary",
44
+ className: "size-5 text-text-primary",
45
45
  fill: "none",
46
46
  stroke: "currentColor",
47
47
  viewBox: "0 0 24 24",
@@ -88,7 +88,7 @@ var s = [
88
88
  children: /* @__PURE__ */ o("div", {
89
89
  className: "relative",
90
90
  children: [/* @__PURE__ */ a("svg", {
91
- className: "absolute left-2.5 top-1/2 -translate-y-1/2 w-4 h-4 text-text-secondary pointer-events-none",
91
+ className: "absolute left-2.5 top-1/2 -translate-y-1/2 size-4 text-text-secondary pointer-events-none",
92
92
  fill: "none",
93
93
  stroke: "currentColor",
94
94
  viewBox: "0 0 24 24",
@@ -136,7 +136,7 @@ var s = [
136
136
  children: e.code
137
137
  }),
138
138
  e.code === l && /* @__PURE__ */ a("svg", {
139
- className: "w-5 h-5 text-action-primary-bg flex-shrink-0",
139
+ className: "size-5 text-action-primary-bg flex-shrink-0",
140
140
  fill: "currentColor",
141
141
  viewBox: "0 0 20 20",
142
142
  children: /* @__PURE__ */ a("path", {