@elevasis/ui 2.31.0 → 2.33.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 (169) hide show
  1. package/dist/{CoreAuthKitInner-KSEGSB67.js → CoreAuthKitInner-QC62UHTZ.js} +1 -1
  2. package/dist/api/index.js +3 -3
  3. package/dist/app/index.css +38 -0
  4. package/dist/app/index.d.ts +69 -9
  5. package/dist/app/index.js +7 -6
  6. package/dist/auth/context.js +1 -1
  7. package/dist/auth/index.js +1 -1
  8. package/dist/charts/index.js +5 -6
  9. package/dist/{chunk-JKSUN5GN.js → chunk-2GMF5IRF.js} +81 -746
  10. package/dist/{chunk-XQHZBA65.js → chunk-2RJMVWFJ.js} +1 -6
  11. package/dist/{chunk-CW3UNAF2.js → chunk-4DYOXEH6.js} +410 -5
  12. package/dist/{chunk-HQGF4ATG.js → chunk-52NLZN6Z.js} +118 -141
  13. package/dist/chunk-AHCKOU2M.js +13 -0
  14. package/dist/chunk-CLDCYJQT.js +1 -0
  15. package/dist/chunk-DWXDNT7P.js +145 -0
  16. package/dist/chunk-E4T2N7P7.js +124 -0
  17. package/dist/{chunk-HYNYEBHM.js → chunk-E7C4XEWH.js} +3 -3
  18. package/dist/{chunk-L3BVJWML.js → chunk-EPTHX4VZ.js} +1 -1
  19. package/dist/{chunk-QDEETKYT.js → chunk-FFPHJBJC.js} +9 -9
  20. package/dist/chunk-GNRMB6DC.js +5126 -0
  21. package/dist/{chunk-DZTG5IAC.js → chunk-I2KLQ2HA.js} +1 -7
  22. package/dist/{chunk-Q6OYNEGR.js → chunk-IUKFNASA.js} +5 -6
  23. package/dist/{chunk-QHEWXU7I.js → chunk-JFL3GRD4.js} +1 -1
  24. package/dist/{chunk-T3IPHEYJ.js → chunk-JHT5JIJ3.js} +4410 -566
  25. package/dist/{chunk-L2NVFLXU.js → chunk-MHLZ4F4N.js} +4 -4
  26. package/dist/{chunk-XQQEKWTL.js → chunk-N55DVMAG.js} +6 -2
  27. package/dist/{chunk-TOIXUWR6.js → chunk-ND5TDV2J.js} +1 -1
  28. package/dist/{chunk-5LJAEZMA.js → chunk-NOIRGGW2.js} +5 -6
  29. package/dist/{chunk-7KC4P3AU.js → chunk-QNOVUCSV.js} +2 -12
  30. package/dist/{chunk-3BAPR3KA.js → chunk-RQA2EVN3.js} +5 -15
  31. package/dist/{chunk-ND42LPY4.js → chunk-TKF5S4XP.js} +6 -6
  32. package/dist/{chunk-DWK2QIAK.js → chunk-TYRUKGGD.js} +1 -1
  33. package/dist/{chunk-Y4FWCG7Y.js → chunk-UVFOURXR.js} +8 -7
  34. package/dist/chunk-UW7IV2Y3.js +447 -0
  35. package/dist/{chunk-P55BJZZW.js → chunk-V6SZ4ECN.js} +20 -5
  36. package/dist/{chunk-6YT4IKJ7.js → chunk-VNAZTCHA.js} +15 -0
  37. package/dist/chunk-XG57WXOL.js +85 -0
  38. package/dist/{chunk-SHQXMW4F.js → chunk-XOFSMJLF.js} +46 -28
  39. package/dist/{chunk-7HMCB26R.js → chunk-XZGSCABI.js} +1 -1
  40. package/dist/chunk-YAQ25UNM.js +2126 -0
  41. package/dist/chunk-ZGTDKH3P.js +467 -0
  42. package/dist/components/chat/index.js +1 -1
  43. package/dist/components/index.css +38 -0
  44. package/dist/components/index.d.ts +262 -51
  45. package/dist/components/index.js +37 -39
  46. package/dist/components/navigation/index.css +38 -0
  47. package/dist/components/navigation/index.js +5 -3
  48. package/dist/execution/index.d.ts +11 -2
  49. package/dist/execution/index.js +1 -1
  50. package/dist/features/auth/index.css +38 -0
  51. package/dist/features/auth/index.d.ts +91 -14
  52. package/dist/features/auth/index.js +42 -10
  53. package/dist/features/clients/index.css +38 -0
  54. package/dist/features/clients/index.d.ts +1 -1
  55. package/dist/features/clients/index.js +17 -15
  56. package/dist/features/crm/index.css +38 -0
  57. package/dist/features/crm/index.d.ts +80 -18
  58. package/dist/features/crm/index.js +17 -15
  59. package/dist/features/dashboard/index.css +38 -0
  60. package/dist/features/dashboard/index.d.ts +174 -25
  61. package/dist/features/dashboard/index.js +17 -16
  62. package/dist/features/delivery/index.css +38 -0
  63. package/dist/features/delivery/index.d.ts +80 -18
  64. package/dist/features/delivery/index.js +16 -15
  65. package/dist/features/knowledge/index.css +38 -0
  66. package/dist/features/knowledge/index.d.ts +20 -18
  67. package/dist/features/knowledge/index.js +114 -609
  68. package/dist/features/lead-gen/index.css +38 -0
  69. package/dist/features/lead-gen/index.d.ts +45 -43
  70. package/dist/features/lead-gen/index.js +17 -16
  71. package/dist/features/monitoring/index.css +38 -0
  72. package/dist/features/monitoring/index.d.ts +20 -18
  73. package/dist/features/monitoring/index.js +18 -17
  74. package/dist/features/monitoring/requests/index.css +38 -0
  75. package/dist/features/monitoring/requests/index.d.ts +23 -21
  76. package/dist/features/monitoring/requests/index.js +16 -14
  77. package/dist/features/operations/index.css +38 -0
  78. package/dist/features/operations/index.d.ts +1299 -66
  79. package/dist/features/operations/index.js +22 -24
  80. package/dist/features/seo/index.d.ts +20 -18
  81. package/dist/features/seo/index.js +2 -2
  82. package/dist/features/settings/index.css +38 -0
  83. package/dist/features/settings/index.d.ts +80 -18
  84. package/dist/features/settings/index.js +17 -15
  85. package/dist/graph/index.js +1 -1
  86. package/dist/hooks/delivery/index.css +38 -0
  87. package/dist/hooks/delivery/index.d.ts +60 -0
  88. package/dist/hooks/delivery/index.js +3 -3
  89. package/dist/hooks/index.css +38 -0
  90. package/dist/hooks/index.d.ts +492 -89
  91. package/dist/hooks/index.js +15 -13
  92. package/dist/hooks/operations/command-view/utils/transformCommandViewData.d.ts +332 -33
  93. package/dist/hooks/operations/command-view/utils/transformCommandViewData.js +1 -1
  94. package/dist/hooks/published.css +38 -0
  95. package/dist/hooks/published.d.ts +492 -89
  96. package/dist/hooks/published.js +15 -13
  97. package/dist/index.css +38 -0
  98. package/dist/index.d.ts +1353 -1349
  99. package/dist/index.js +16 -14
  100. package/dist/initialization/index.d.ts +60 -0
  101. package/dist/initialization/index.js +1 -1
  102. package/dist/knowledge/index.d.ts +1217 -1292
  103. package/dist/knowledge/index.js +6538 -2198
  104. package/dist/knowledge-search-index-P7PR626V.js +1514 -0
  105. package/dist/layout/index.js +3 -4
  106. package/dist/organization/index.css +38 -0
  107. package/dist/organization/index.js +1 -1
  108. package/dist/profile/index.d.ts +60 -0
  109. package/dist/profile/index.js +1 -1
  110. package/dist/provider/ElevasisServiceContext.js +1 -1
  111. package/dist/provider/index.css +38 -0
  112. package/dist/provider/index.d.ts +1068 -1246
  113. package/dist/provider/index.js +12 -10
  114. package/dist/provider/published.css +38 -0
  115. package/dist/provider/published.d.ts +1065 -1243
  116. package/dist/provider/published.js +9 -7
  117. package/dist/router/context.js +1 -1
  118. package/dist/router/index.js +1 -1
  119. package/dist/sse/index.js +1 -1
  120. package/dist/supabase/index.d.ts +117 -0
  121. package/dist/supabase/index.js +1 -1
  122. package/dist/test-utils/index.d.ts +16 -9
  123. package/dist/test-utils/index.js +40 -33
  124. package/dist/test-utils/setup-integration.js +1 -1
  125. package/dist/test-utils/setup.js +1 -1
  126. package/dist/theme/index.js +3 -3
  127. package/dist/theme/presets/index.js +1 -1
  128. package/dist/typeform/index.js +1 -1
  129. package/dist/typeform/schemas.js +1 -1
  130. package/dist/types/index.d.ts +394 -35
  131. package/dist/utils/index.d.ts +174 -25
  132. package/dist/utils/index.js +2 -2
  133. package/dist/vite/index.js +1 -1
  134. package/dist/vite-plugin-knowledge/index.js +1 -1
  135. package/dist/zustand/index.js +1 -1
  136. package/package.json +10 -9
  137. package/src/README.md +29 -29
  138. package/src/api/README.md +18 -18
  139. package/src/app/README.md +24 -24
  140. package/src/auth/README.md +18 -18
  141. package/src/components/README.md +24 -24
  142. package/src/execution/README.md +16 -16
  143. package/src/features/README.md +28 -28
  144. package/src/graph/README.md +16 -16
  145. package/src/hooks/README.md +23 -23
  146. package/src/initialization/README.md +19 -19
  147. package/src/knowledge/README.md +31 -31
  148. package/src/organization/README.md +18 -18
  149. package/src/profile/README.md +19 -19
  150. package/src/provider/README.md +32 -32
  151. package/src/router/README.md +18 -18
  152. package/src/sse/README.md +13 -13
  153. package/src/test-utils/README.md +7 -7
  154. package/src/theme/README.md +23 -23
  155. package/src/theme/presets/README.md +19 -19
  156. package/src/types/README.md +16 -16
  157. package/src/utils/README.md +18 -18
  158. package/src/zustand/README.md +18 -18
  159. package/dist/chunk-542WPQU2.js +0 -413
  160. package/dist/chunk-6IXOKUBC.js +0 -347
  161. package/dist/chunk-CQZ3DNQY.js +0 -740
  162. package/dist/chunk-ECNNI3NT.js +0 -6
  163. package/dist/chunk-GRDLB6LM.js +0 -160
  164. package/dist/chunk-JDNEWB5F.js +0 -10
  165. package/dist/chunk-MVFCLZSK.js +0 -4337
  166. package/dist/chunk-O2QOPJI5.js +0 -2235
  167. package/dist/chunk-OAVTMITG.js +0 -13
  168. package/dist/chunk-TVRQ6AQI.js +0 -476
  169. package/dist/chunk-WF227UBV.js +0 -48
@@ -1,12 +1,14 @@
1
- export { FeatureShell } from '../chunk-QDEETKYT.js';
2
- export { ElevasisFeaturesProvider, useElevasisFeatures, useOptionalElevasisFeatures } from '../chunk-6IXOKUBC.js';
3
- import '../chunk-L3BVJWML.js';
1
+ export { SystemShell } from '../chunk-FFPHJBJC.js';
2
+ import '../chunk-EPTHX4VZ.js';
4
3
  import '../chunk-3KMDHCAR.js';
5
- export { ElevasisCoreProvider, NotificationProvider, useNotificationAdapter } from '../chunk-CQZ3DNQY.js';
4
+ export { ElevasisCoreProvider, NotificationProvider, useNotificationAdapter } from '../chunk-UW7IV2Y3.js';
6
5
  import '../chunk-SZHARWKU.js';
6
+ export { ElevasisSystemsProvider, useElevasisSystems, useOptionalElevasisSystems } from '../chunk-ZGTDKH3P.js';
7
7
  import '../chunk-TKAYX2SP.js';
8
8
  import '../chunk-NYBEU5TE.js';
9
- import '../chunk-TOIXUWR6.js';
9
+ import '../chunk-DWXDNT7P.js';
10
+ import '../chunk-GNRMB6DC.js';
11
+ import '../chunk-ND5TDV2J.js';
10
12
  import '../chunk-2IFYDILW.js';
11
13
  import '../chunk-Q7DJKLEN.js';
12
14
  import '../chunk-JA5ECJJB.js';
@@ -15,7 +17,7 @@ export { AppearanceProvider, useAppearance } from '../chunk-E565XMTQ.js';
15
17
  import '../chunk-JBWJ6WHZ.js';
16
18
  import '../chunk-DT3QYZVU.js';
17
19
  import '../chunk-RNP5R5I3.js';
18
- import '../chunk-XQHZBA65.js';
20
+ import '../chunk-2RJMVWFJ.js';
19
21
  import '../chunk-KRWALB24.js';
20
22
  import '../chunk-VKIZUUPM.js';
21
23
  import '../chunk-533DUEQY.js';
@@ -23,4 +25,4 @@ import '../chunk-DD3CCMCZ.js';
23
25
  import '../chunk-2Q2JQSQO.js';
24
26
  export { ElevasisServiceProvider, useElevasisServices } from '../chunk-KJ3QUBNU.js';
25
27
  import '../chunk-BRJ3QZ4E.js';
26
- import '../chunk-DZTG5IAC.js';
28
+ import '../chunk-I2KLQ2HA.js';
@@ -1,2 +1,2 @@
1
1
  export { RouterProvider, useRouterContext } from '../chunk-Q7DJKLEN.js';
2
- import '../chunk-DZTG5IAC.js';
2
+ import '../chunk-I2KLQ2HA.js';
@@ -1,3 +1,3 @@
1
1
  export { ScrollToTop, TanStackRouterBridge } from '../chunk-2IFYDILW.js';
2
2
  export { RouterProvider, useRouterContext } from '../chunk-Q7DJKLEN.js';
3
- import '../chunk-DZTG5IAC.js';
3
+ import '../chunk-I2KLQ2HA.js';
package/dist/sse/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import '../chunk-DZTG5IAC.js';
1
+ import '../chunk-I2KLQ2HA.js';
2
2
  import { fetchEventSource } from '@microsoft/fetch-event-source';
3
3
 
4
4
  async function fetchEventSourceWithTokenRefresh(options) {
@@ -2765,6 +2765,66 @@ type Database = {
2765
2765
  }
2766
2766
  ];
2767
2767
  };
2768
+ user_notes: {
2769
+ Row: {
2770
+ content: string;
2771
+ created_at: string;
2772
+ created_by: string;
2773
+ id: string;
2774
+ metadata: Json;
2775
+ organization_id: string | null;
2776
+ pinned: boolean;
2777
+ priority: string;
2778
+ source: string | null;
2779
+ title: string | null;
2780
+ updated_at: string;
2781
+ user_id: string;
2782
+ };
2783
+ Insert: {
2784
+ content: string;
2785
+ created_at?: string;
2786
+ created_by?: string;
2787
+ id?: string;
2788
+ metadata?: Json;
2789
+ organization_id?: string | null;
2790
+ pinned?: boolean;
2791
+ priority?: string;
2792
+ source?: string | null;
2793
+ title?: string | null;
2794
+ updated_at?: string;
2795
+ user_id: string;
2796
+ };
2797
+ Update: {
2798
+ content?: string;
2799
+ created_at?: string;
2800
+ created_by?: string;
2801
+ id?: string;
2802
+ metadata?: Json;
2803
+ organization_id?: string | null;
2804
+ pinned?: boolean;
2805
+ priority?: string;
2806
+ source?: string | null;
2807
+ title?: string | null;
2808
+ updated_at?: string;
2809
+ user_id?: string;
2810
+ };
2811
+ Relationships: [
2812
+ {
2813
+ foreignKeyName: "user_notes_organization_id_fkey";
2814
+ columns: ["organization_id"];
2815
+ isOneToOne: false;
2816
+ referencedRelation: "organizations";
2817
+ referencedColumns: ["id"];
2818
+ },
2819
+ {
2820
+ foreignKeyName: "user_notes_user_id_fkey";
2821
+ columns: ["user_id"];
2822
+ isOneToOne: false;
2823
+ referencedRelation: "users";
2824
+ referencedColumns: ["id"];
2825
+ }
2826
+ ];
2827
+ };
2768
2828
  users: {
2769
2829
  Row: {
2770
2830
  config: Json;
@@ -5647,6 +5707,63 @@ declare const useSupabase: () => SupabaseClient<Database, "public", "public", {
5647
5707
  referencedColumns: ["id"];
5648
5708
  }];
5649
5709
  };
5710
+ user_notes: {
5711
+ Row: {
5712
+ content: string;
5713
+ created_at: string;
5714
+ created_by: string;
5715
+ id: string;
5716
+ metadata: Json;
5717
+ organization_id: string | null;
5718
+ pinned: boolean;
5719
+ priority: string;
5720
+ source: string | null;
5721
+ title: string | null;
5722
+ updated_at: string;
5723
+ user_id: string;
5724
+ };
5725
+ Insert: {
5726
+ content: string;
5727
+ created_at?: string;
5728
+ created_by?: string;
5729
+ id?: string;
5730
+ metadata?: Json;
5731
+ organization_id?: string | null;
5732
+ pinned?: boolean;
5733
+ priority?: string;
5734
+ source?: string | null;
5735
+ title?: string | null;
5736
+ updated_at?: string;
5737
+ user_id: string;
5738
+ };
5739
+ Update: {
5740
+ content?: string;
5741
+ created_at?: string;
5742
+ created_by?: string;
5743
+ id?: string;
5744
+ metadata?: Json;
5745
+ organization_id?: string | null;
5746
+ pinned?: boolean;
5747
+ priority?: string;
5748
+ source?: string | null;
5749
+ title?: string | null;
5750
+ updated_at?: string;
5751
+ user_id?: string;
5752
+ };
5753
+ Relationships: [{
5754
+ foreignKeyName: "user_notes_organization_id_fkey";
5755
+ columns: ["organization_id"];
5756
+ isOneToOne: false;
5757
+ referencedRelation: "organizations";
5758
+ referencedColumns: ["id"];
5759
+ }, {
5760
+ foreignKeyName: "user_notes_user_id_fkey";
5761
+ columns: ["user_id"];
5762
+ isOneToOne: false;
5763
+ referencedRelation: "users";
5764
+ referencedColumns: ["id"];
5765
+ }];
5766
+ };
5650
5767
  users: {
5651
5768
  Row: {
5652
5769
  config: Json;
@@ -1,3 +1,3 @@
1
1
  export { getSupabaseClient, useSupabase } from '../chunk-BRXELOHC.js';
2
2
  import '../chunk-BRJ3QZ4E.js';
3
- import '../chunk-DZTG5IAC.js';
3
+ import '../chunk-I2KLQ2HA.js';
@@ -137,19 +137,26 @@ declare function mockFeatureAccess({ allowed, restrictedBy }?: MockFeatureAccess
137
137
  };
138
138
 
139
139
  type OrgOsUiRouteContractMode = 'development' | 'production';
140
- interface OrgOsRouteContractFeature {
140
+ interface OrgOsRouteContractSystem {
141
141
  id: string;
142
+ lifecycle?: string | null;
142
143
  path?: string | null;
144
+ ui?: {
145
+ path?: string | null;
146
+ } | null;
143
147
  enabled?: boolean;
144
148
  devOnly?: boolean;
145
149
  }
150
+ type OrgOsRouteContractSystemsDomain = Record<string, OrgOsRouteContractSystem> | {
151
+ systems: readonly OrgOsRouteContractSystem[];
152
+ };
146
153
  interface OrgOsRouteContractOrganizationModel {
147
- features: readonly OrgOsRouteContractFeature[];
154
+ systems: OrgOsRouteContractSystemsDomain;
148
155
  }
149
156
  interface OrgOsUiRouteContractTarget {
150
157
  name: string;
151
158
  routeTreePath: string;
152
- featureIds: readonly string[];
159
+ systemIds: readonly string[];
153
160
  orgModelSource: string;
154
161
  shellSource: string;
155
162
  }
@@ -160,13 +167,13 @@ interface OrgOsUiRouteContractOptions {
160
167
  routePaths?: Iterable<string>;
161
168
  mode?: OrgOsUiRouteContractMode;
162
169
  }
163
- type OrgOsUiRouteContractIssueKind = 'missing-feature' | 'missing-route';
170
+ type OrgOsUiRouteContractIssueKind = 'missing-system' | 'missing-route';
164
171
  interface OrgOsUiRouteContractIssue {
165
172
  target: OrgOsUiRouteContractTarget;
166
173
  kind: OrgOsUiRouteContractIssueKind;
167
- featureId: string;
174
+ systemId: string;
168
175
  path?: string;
169
- ownerFeatureId?: string;
176
+ ownerSystemId?: string;
170
177
  }
171
178
  interface OrgOsUiRouteContractResult {
172
179
  issues: OrgOsUiRouteContractIssue[];
@@ -174,11 +181,11 @@ interface OrgOsUiRouteContractResult {
174
181
  }
175
182
  declare function normalizeOrgOsRoutePath(path: string): string;
176
183
  declare function extractOrgOsRouteTreeFullPaths(routeTreeSource: string): Set<string>;
177
- declare function ownsOrgOsFeature(ownerFeatureId: string, featureId: string): boolean;
184
+ declare function ownsOrgOsSystem(ownerSystemId: string, systemId: string): boolean;
178
185
  declare function collectOrgOsUiRouteContractIssues(options: OrgOsUiRouteContractOptions): OrgOsUiRouteContractResult;
179
186
  declare function formatOrgOsUiRouteContractIssue(issue: OrgOsUiRouteContractIssue): string;
180
187
  declare function formatOrgOsUiRouteContractFailure(issues: readonly OrgOsUiRouteContractIssue[]): string;
181
188
  declare function assertOrgOsUiRouteContract(options: OrgOsUiRouteContractOptions): OrgOsUiRouteContractResult;
182
189
 
183
- export { TestProviders, assertOrgOsUiRouteContract, collectOrgOsUiRouteContractIssues, createMockUseAuth, createTestQueryClient, createTestWrapper, extractOrgOsRouteTreeFullPaths, formatOrgOsUiRouteContractFailure, formatOrgOsUiRouteContractIssue, handlers, mockAuthLoading, mockAuthenticatedUser, mockFeatureAccess, mockUnauthenticatedUser, mockUseAuth, mockWorkOSUser, normalizeOrgOsRoutePath, ownsOrgOsFeature, renderWithProviders as render, renderHookWithProviders, renderWithProviders, server };
184
- export type { CustomRenderHookOptions, CustomRenderOptions, MockFeatureAccessOptions, OrgOsRouteContractFeature, OrgOsRouteContractOrganizationModel, OrgOsUiRouteContractIssue, OrgOsUiRouteContractIssueKind, OrgOsUiRouteContractMode, OrgOsUiRouteContractOptions, OrgOsUiRouteContractResult, OrgOsUiRouteContractTarget, TestProvidersProps };
190
+ export { TestProviders, assertOrgOsUiRouteContract, collectOrgOsUiRouteContractIssues, createMockUseAuth, createTestQueryClient, createTestWrapper, extractOrgOsRouteTreeFullPaths, formatOrgOsUiRouteContractFailure, formatOrgOsUiRouteContractIssue, handlers, mockAuthLoading, mockAuthenticatedUser, mockFeatureAccess, mockUnauthenticatedUser, mockUseAuth, mockWorkOSUser, normalizeOrgOsRoutePath, ownsOrgOsSystem, renderWithProviders as render, renderHookWithProviders, renderWithProviders, server };
191
+ export type { CustomRenderHookOptions, CustomRenderOptions, MockFeatureAccessOptions, OrgOsRouteContractOrganizationModel, OrgOsRouteContractSystem, OrgOsUiRouteContractIssue, OrgOsUiRouteContractIssueKind, OrgOsUiRouteContractMode, OrgOsUiRouteContractOptions, OrgOsUiRouteContractResult, OrgOsUiRouteContractTarget, TestProvidersProps };
@@ -3,12 +3,12 @@ export { handlers, server } from '../chunk-7XKCG5CT.js';
3
3
  import { mockWorkOSUser, mockUseAuth, mockUnauthenticatedUser, mockAuthenticatedUser, mockAuthLoading, createMockUseAuth } from '../chunk-DRQPEMJI.js';
4
4
  export { createMockUseAuth, mockAuthLoading, mockAuthenticatedUser, mockUnauthenticatedUser, mockUseAuth, mockWorkOSUser } from '../chunk-DRQPEMJI.js';
5
5
  import '../chunk-XCYKC6OZ.js';
6
- import { ApiClientProvider } from '../chunk-TOIXUWR6.js';
7
- import '../chunk-XQHZBA65.js';
6
+ import { ApiClientProvider } from '../chunk-ND5TDV2J.js';
7
+ import '../chunk-2RJMVWFJ.js';
8
8
  import '../chunk-KRWALB24.js';
9
9
  import '../chunk-DD3CCMCZ.js';
10
10
  import { ElevasisServiceProvider } from '../chunk-KJ3QUBNU.js';
11
- import { __export, __reExport } from '../chunk-DZTG5IAC.js';
11
+ import { __export, __reExport } from '../chunk-I2KLQ2HA.js';
12
12
  import { MantineProvider } from '@mantine/core';
13
13
  import { QueryClient, QueryClientProvider } from '@tanstack/react-query';
14
14
  import * as react_star from '@testing-library/react';
@@ -35,7 +35,7 @@ __export(test_utils_exports, {
35
35
  mockUseAuth: () => mockUseAuth,
36
36
  mockWorkOSUser: () => mockWorkOSUser,
37
37
  normalizeOrgOsRoutePath: () => normalizeOrgOsRoutePath,
38
- ownsOrgOsFeature: () => ownsOrgOsFeature,
38
+ ownsOrgOsSystem: () => ownsOrgOsSystem,
39
39
  render: () => renderWithProviders,
40
40
  renderHookWithProviders: () => renderHookWithProviders,
41
41
  renderWithProviders: () => renderWithProviders,
@@ -183,8 +183,12 @@ function extractOrgOsRouteTreeFullPaths(routeTreeSource) {
183
183
  const paths = [...routeTreeSource.matchAll(/fullPath:\s*'([^']+)'/g)].map((match) => match[1]).filter((path) => Boolean(path)).map(normalizeOrgOsRoutePath);
184
184
  return new Set(paths);
185
185
  }
186
- function ownsOrgOsFeature(ownerFeatureId, featureId) {
187
- return featureId === ownerFeatureId || featureId.startsWith(`${ownerFeatureId}.`);
186
+ function ownsOrgOsSystem(ownerSystemId, systemId) {
187
+ return systemId === ownerSystemId || systemId.startsWith(`${ownerSystemId}.`);
188
+ }
189
+ function getOrgOsRouteContractSystems(organizationModel) {
190
+ const { systems } = organizationModel;
191
+ return "systems" in systems && Array.isArray(systems.systems) ? systems.systems : Object.values(systems);
188
192
  }
189
193
  function collectOrgOsUiRouteContractIssues(options) {
190
194
  const { target, organizationModel, mode = "production" } = options;
@@ -193,53 +197,56 @@ function collectOrgOsUiRouteContractIssues(options) {
193
197
  throw new Error("Org OS UI route contract requires either routeTreeSource or routePaths.");
194
198
  }
195
199
  const normalizedRoutePaths = new Set([...routePaths].map(normalizeOrgOsRoutePath));
196
- const modelFeatureIds = new Set(organizationModel.features.map((feature) => feature.id));
200
+ const systems = getOrgOsRouteContractSystems(organizationModel);
201
+ const modelSystemIds = new Set(systems.map((system) => system.id));
197
202
  const issues = [];
198
203
  let checkedPathCount = 0;
199
- for (const featureId of target.featureIds) {
200
- if (!modelFeatureIds.has(featureId)) {
204
+ for (const systemId of target.systemIds) {
205
+ if (!modelSystemIds.has(systemId)) {
201
206
  issues.push({
202
207
  target,
203
- kind: "missing-feature",
204
- featureId
208
+ kind: "missing-system",
209
+ systemId
205
210
  });
206
211
  }
207
212
  }
208
- for (const feature of organizationModel.features) {
209
- if (!feature.path || feature.enabled === false) continue;
210
- if (feature.devOnly && mode === "production") continue;
211
- const ownerFeatureId = target.featureIds.find((candidate) => ownsOrgOsFeature(candidate, feature.id));
212
- if (!ownerFeatureId) continue;
213
+ for (const system of systems) {
214
+ const path = system.ui?.path ?? system.path;
215
+ if (!path || system.enabled === false) continue;
216
+ if (system.lifecycle === "archived" || system.lifecycle === "deprecated") continue;
217
+ if (system.devOnly && mode === "production") continue;
218
+ const ownerSystemId = target.systemIds.find((candidate) => ownsOrgOsSystem(candidate, system.id));
219
+ if (!ownerSystemId) continue;
213
220
  checkedPathCount += 1;
214
- const path = normalizeOrgOsRoutePath(feature.path);
215
- if (!normalizedRoutePaths.has(path)) {
221
+ const normalizedPath = normalizeOrgOsRoutePath(path);
222
+ if (!normalizedRoutePaths.has(normalizedPath)) {
216
223
  issues.push({
217
224
  target,
218
225
  kind: "missing-route",
219
- featureId: feature.id,
220
- ownerFeatureId,
221
- path
226
+ systemId: system.id,
227
+ ownerSystemId,
228
+ path: normalizedPath
222
229
  });
223
230
  }
224
231
  }
225
232
  return { issues, checkedPathCount };
226
233
  }
227
234
  function formatOrgOsUiRouteContractIssue(issue) {
228
- if (issue.kind === "missing-feature") {
235
+ if (issue.kind === "missing-system") {
229
236
  return [
230
- `[missing-feature] Registered FeatureModule "${issue.featureId}" is not present in ${issue.target.orgModelSource}.`,
237
+ `[missing-system] Registered SystemModule "${issue.systemId}" is not present in ${issue.target.orgModelSource}.`,
231
238
  "Fix:",
232
- `- If the feature should ship in ${issue.target.name}, add it to the organization model.`,
233
- `- If it should not ship, remove that FeatureModule from ${issue.target.shellSource}.`
239
+ `- If the system should ship in ${issue.target.name}, add it to the organization model.`,
240
+ `- If it should not ship, remove that SystemModule from ${issue.target.shellSource}.`
234
241
  ].join("\n");
235
242
  }
236
243
  return [
237
- `[missing-route] Feature "${issue.featureId}" points to "${issue.path}", but ${issue.target.routeTreePath} does not contain that path.`,
238
- `Owner FeatureModule: ${issue.ownerFeatureId}`,
244
+ `[missing-route] System "${issue.systemId}" points to "${issue.path}", but ${issue.target.routeTreePath} does not contain that path.`,
245
+ `Owner SystemModule: ${issue.ownerSystemId}`,
239
246
  "Fix one source of truth:",
240
247
  `- Add or rename the TanStack route file under ${issue.target.name}/src/routes so routeTree.gen.ts contains "${issue.path}".`,
241
- `- Or update ${issue.target.orgModelSource} so OrganizationModel.features[].path matches the route that actually exists.`,
242
- `- Or disable/remove the feature for ${issue.target.name} if this app intentionally does not ship it.`
248
+ `- Or update ${issue.target.orgModelSource} so OrganizationModel.systems[].path matches the route that actually exists.`,
249
+ `- Or disable/remove the system for ${issue.target.name} if this app intentionally does not ship it.`
243
250
  ].join("\n");
244
251
  }
245
252
  function formatOrgOsUiRouteContractFailure(issues) {
@@ -247,11 +254,11 @@ function formatOrgOsUiRouteContractFailure(issues) {
247
254
  `Org OS UI route contract failed with ${issues.length} issue(s).`,
248
255
  "",
249
256
  "This check is derived from app-level contracts, not a route allowlist:",
250
- "- OrganizationModel.features[].path is the expected path source.",
257
+ "- OrganizationModel.systems[].path is the expected path source.",
251
258
  "- routeTree.gen.ts fullPath entries are the actual generated routes.",
252
- "- FeatureModule.featureId values define which Org OS branches this shell propagates.",
259
+ "- SystemModule.systemId values define which Org OS branches this shell propagates.",
253
260
  "",
254
- "Do not add route-specific exceptions. Fix the route file, the Org model path, or the app feature registration.",
261
+ "Do not add route-specific exceptions. Fix the route file, the Org model path, or the app system registration.",
255
262
  ""
256
263
  ];
257
264
  for (const issue of issues) {
@@ -267,4 +274,4 @@ function assertOrgOsUiRouteContract(options) {
267
274
  return result;
268
275
  }
269
276
 
270
- export { TestProviders, assertOrgOsUiRouteContract, collectOrgOsUiRouteContractIssues, createTestQueryClient, createTestWrapper, extractOrgOsRouteTreeFullPaths, formatOrgOsUiRouteContractFailure, formatOrgOsUiRouteContractIssue, mockFeatureAccess, normalizeOrgOsRoutePath, ownsOrgOsFeature, renderWithProviders as render, renderHookWithProviders, renderWithProviders };
277
+ export { TestProviders, assertOrgOsUiRouteContract, collectOrgOsUiRouteContractIssues, createTestQueryClient, createTestWrapper, extractOrgOsRouteTreeFullPaths, formatOrgOsUiRouteContractFailure, formatOrgOsUiRouteContractIssue, mockFeatureAccess, normalizeOrgOsRoutePath, ownsOrgOsSystem, renderWithProviders as render, renderHookWithProviders, renderWithProviders };
@@ -1,6 +1,6 @@
1
1
  import { setupBrowserMocks } from '../chunk-HJ4CJIWN.js';
2
2
  import { mockUseAuth } from '../chunk-DRQPEMJI.js';
3
- import '../chunk-DZTG5IAC.js';
3
+ import '../chunk-I2KLQ2HA.js';
4
4
  import '@testing-library/jest-dom/vitest';
5
5
  import { cleanup } from '@testing-library/react';
6
6
  import { vi, afterEach } from 'vitest';
@@ -1,7 +1,7 @@
1
1
  import { server } from '../chunk-7XKCG5CT.js';
2
2
  import { setupBrowserMocks } from '../chunk-HJ4CJIWN.js';
3
3
  import { mockUseAuth } from '../chunk-DRQPEMJI.js';
4
- import '../chunk-DZTG5IAC.js';
4
+ import '../chunk-I2KLQ2HA.js';
5
5
  import '@testing-library/jest-dom/vitest';
6
6
  import { cleanup } from '@testing-library/react';
7
7
  import { vi, beforeAll, afterEach, afterAll, expect } from 'vitest';
@@ -1,5 +1,5 @@
1
- export { useAvailablePresets } from '../chunk-QHEWXU7I.js';
2
- export { PresetsProvider, TOKEN_VAR_MAP, componentThemes, createCssVariablesResolver, mantineThemeOverride, usePresetsContext } from '../chunk-3BAPR3KA.js';
1
+ export { useAvailablePresets } from '../chunk-JFL3GRD4.js';
2
+ export { PresetsProvider, TOKEN_VAR_MAP, componentThemes, createCssVariablesResolver, mantineThemeOverride, usePresetsContext } from '../chunk-RQA2EVN3.js';
3
3
  export { generateShades, getPreset, PRESETS as presets } from '../chunk-3FV6HBXS.js';
4
4
  import '../chunk-WLOQ4IBG.js';
5
- import '../chunk-DZTG5IAC.js';
5
+ import '../chunk-I2KLQ2HA.js';
@@ -1,3 +1,3 @@
1
1
  export { THEME_PRESETS, ThemePresetEnum, generateShades, getPreset, PRESETS as presets } from '../../chunk-3FV6HBXS.js';
2
2
  import '../../chunk-WLOQ4IBG.js';
3
- import '../../chunk-DZTG5IAC.js';
3
+ import '../../chunk-I2KLQ2HA.js';
@@ -1,5 +1,5 @@
1
1
  export { answerValueSchema, checkboxWithOtherSchema, multiAnswerValueSchema, radioWithOtherSchema } from '../chunk-6M6OLGQY.js';
2
- import '../chunk-DZTG5IAC.js';
2
+ import '../chunk-I2KLQ2HA.js';
3
3
  import { createContext, useMemo, useState, useCallback, useEffect, useContext, useRef } from 'react';
4
4
  import { Box, Progress, Text, Group, Button, Kbd, Modal, Stack, Transition, Title, UnstyledButton, TextInput, Textarea, Center, Alert, Card, ActionIcon, Paper } from '@mantine/core';
5
5
  import { IconArrowLeft, IconCheck, IconArrowRight, IconPlus, IconPencil, IconTrash, IconX } from '@tabler/icons-react';
@@ -1,2 +1,2 @@
1
1
  export { answerValueSchema, checkboxWithOtherSchema, multiAnswerValueSchema, radioWithOtherSchema } from '../chunk-6M6OLGQY.js';
2
- import '../chunk-DZTG5IAC.js';
2
+ import '../chunk-I2KLQ2HA.js';