@ubnt/store.core 9.15.0-alpha.0 → 9.15.0-alpha.2

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 (54) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/lib/assets/attention.svg +5 -5
  3. package/lib/assets/attention2.svg +5 -5
  4. package/lib/assets/minus4.svg +8 -8
  5. package/lib/assets/minus5.svg +8 -8
  6. package/lib/components/LandingPagePro/LandingPagePro.d.ts +2 -2
  7. package/lib/components/LandingPagePro/LandingPagePro.js +31 -11
  8. package/lib/components/LandingPagePro/LandingPagePro.js.map +1 -1
  9. package/lib/components/LandingPagePro/LandingPagePro.mjs +32 -12
  10. package/lib/components/LandingPagePro/LandingPagePro.mjs.map +1 -1
  11. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.js +1 -1
  12. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.mjs +1 -1
  13. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.styles.js +1 -1
  14. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.styles.js.map +1 -1
  15. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.styles.mjs +1 -1
  16. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.styles.mjs.map +1 -1
  17. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/CounterSection.js +1 -1
  18. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/CounterSection.mjs +1 -1
  19. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/attention.svg.js +1 -1
  20. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/attention.svg.mjs +2 -2
  21. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/minus.svg.js +1 -1
  22. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/minus.svg.mjs +2 -2
  23. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/ProgressBarChart.js +1 -1
  24. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/ProgressBarChart.mjs +1 -1
  25. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/assets/attention.svg.js +1 -1
  26. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/assets/attention.svg.mjs +2 -2
  27. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.js +1 -1
  28. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.mjs +1 -1
  29. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/minus.svg.js +1 -1
  30. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/minus.svg.mjs +2 -2
  31. package/lib/constants/icons/options/colors/black.svg.js +5 -5
  32. package/lib/constants/icons/options/colors/index.js +3 -3
  33. package/lib/constants/icons/options/styles/black.svg.js +5 -5
  34. package/lib/constants/icons/options/styles/index.js +3 -3
  35. package/lib/constants/optionIcons.js +6 -6
  36. package/lib/constants/optionIcons.mjs +4 -4
  37. package/lib/contexts/MenuContext/context.js +11 -51
  38. package/lib/contexts/MenuContext/context.js.map +1 -1
  39. package/lib/contexts/MenuContext/context.mjs +12 -46
  40. package/lib/contexts/MenuContext/context.mjs.map +1 -1
  41. package/lib/contexts/MenuContext/mapping.d.ts +9 -45
  42. package/lib/contexts/MenuContext/mapping.js +41 -1365
  43. package/lib/contexts/MenuContext/mapping.js.map +1 -1
  44. package/lib/contexts/MenuContext/mapping.mjs +42 -1353
  45. package/lib/contexts/MenuContext/mapping.mjs.map +1 -1
  46. package/lib/contexts/MenuContext/types.d.ts +1 -2
  47. package/lib/contexts/MenuContext/types.js.map +1 -1
  48. package/lib/contexts/MenuContext/types.mjs.map +1 -1
  49. package/lib/contexts/MenuContext/utils.d.ts +1 -3
  50. package/lib/contexts/MenuContext/utils.js +1 -18
  51. package/lib/contexts/MenuContext/utils.js.map +1 -1
  52. package/lib/contexts/MenuContext/utils.mjs +2 -17
  53. package/lib/contexts/MenuContext/utils.mjs.map +1 -1
  54. package/package.json +1 -1
@@ -1,5 +1,6 @@
1
1
  import type { StaticImageData } from "next/image";
2
- import { GlobalStoreId, StoreId } from "../../types";
2
+ import type { StoreId } from "../../types";
3
+ import { GlobalStoreId } from "../../types";
3
4
  import { Language } from "../../types/constants";
4
5
  /**
5
6
  * Enum containing "id's" for different microsites used in navigation
@@ -73,30 +74,12 @@ export type SiteUrl = [
73
74
  searchParams?: Record<string, string | number | boolean>,
74
75
  fragment?: string | number
75
76
  ];
76
- export interface NavigationPath {
77
- url?: never;
78
- /**
79
- * Base path of the collection
80
- * @example "/collections/unifi-dream-wall"
81
- */
82
- path: string;
83
- /**
84
- * Store mapped path if it differs
85
- * ! Set the path value as `null` if disabled for a store
86
- */
87
- storePath?: Partial<Record<GlobalStoreId, string | null>>;
88
- /**
89
- * Hides menu item in store if store path is null. It takes in
90
- * consideration both `storePath` and `path` values.
91
- */
92
- hideInStoreIfStorePathNull?: boolean;
93
- }
94
- export type NavigationPathWithUrl = Omit<NavigationPath, "url"> & {
77
+ export type NavigationUrl = {
95
78
  /**
96
79
  * (Optional) External URL to ui.com or uisp.com
97
80
  * Will override path usage, however, both will be used for active state check
98
81
  */
99
- url?: SiteUrl;
82
+ url: SiteUrl;
100
83
  };
101
84
  export type NavigationItemIcon = {
102
85
  src: string | StaticImageData;
@@ -119,24 +102,16 @@ export type NavigationInvisibleItem = {
119
102
  * (Optional) Use it to keep hidden from rendering in navigations, but preserve itself in categories.
120
103
  */
121
104
  invisible?: boolean;
122
- /**
123
- * (Optional) Use it to determine if should be shown in store only
124
- */
125
- storeOnly?: boolean;
126
- /**
127
- * (Optional) Use it to determine if should be shown in microsite only
128
- */
129
- micrositeOnly?: boolean;
130
105
  };
131
- export type NavigationSubSubItem = NavigationItemCore & NavigationInvisibleItem & {} & /**
106
+ export type NavigationSubSubItem = NavigationItemCore & NavigationInvisibleItem &
107
+ /**
132
108
  * The item either has a single path
133
- */ (NavigationPathWithUrl
109
+ */ (NavigationUrl
134
110
  /**
135
111
  * Or multi-item sub-sub-items
136
112
  */
137
113
  | {
138
114
  url?: never;
139
- path: null;
140
115
  items: NavigationSubSubItem[];
141
116
  } | {
142
117
  /**
@@ -144,7 +119,6 @@ export type NavigationSubSubItem = NavigationItemCore & NavigationInvisibleItem
144
119
  */
145
120
  url: SiteUrl;
146
121
  fallbackUrl?: never;
147
- path?: never;
148
122
  items?: NavigationSubSubItem[];
149
123
  });
150
124
  export type NavigationSubItem = NavigationItemCore & NavigationInvisibleItem & {
@@ -170,17 +144,12 @@ export type NavigationSubItem = NavigationItemCore & NavigationInvisibleItem & {
170
144
  icon: NavigationItemIcon;
171
145
  } & /**
172
146
  * The item either has a single path
173
- */ (NavigationPathWithUrl
147
+ */ (NavigationUrl
174
148
  /**
175
149
  * Or multi-item sub-sub-items
176
150
  */
177
151
  | {
178
- url?: never;
179
- path: null;
180
- items: NavigationSubSubItem[];
181
- } | {
182
- url: SiteUrl;
183
- path: null;
152
+ url?: SiteUrl;
184
153
  items: NavigationSubSubItem[];
185
154
  });
186
155
  export type NavigationItem = NavigationItemCore & NavigationInvisibleItem & ({
@@ -190,7 +159,6 @@ export type NavigationItem = NavigationItemCore & NavigationInvisibleItem & ({
190
159
  fallbackUrl?: never;
191
160
  items: NavigationSubItem[];
192
161
  key?: string;
193
- path?: never;
194
162
  url: SiteUrl;
195
163
  } | {
196
164
  /**
@@ -200,7 +168,6 @@ export type NavigationItem = NavigationItemCore & NavigationInvisibleItem & ({
200
168
  fallbackUrl?: SiteUrl;
201
169
  items: NavigationSubItem[];
202
170
  key?: string;
203
- path: string | null;
204
171
  url?: never;
205
172
  });
206
173
  export type NavigationSection = NavigationSectionFlat | NavigationSectionNested | NavigationSectionNestedWithFallback;
@@ -208,7 +175,6 @@ export type NavigationSection = NavigationSectionFlat | NavigationSectionNested
208
175
  * Goes directly to a specific url, no fuss
209
176
  */
210
177
  type NavigationSectionFlat = Pick<NavigationItemCore, "label"> & {
211
- path?: string | null;
212
178
  items?: never;
213
179
  key?: string;
214
180
  url: SiteUrl;
@@ -218,7 +184,6 @@ type NavigationSectionFlat = Pick<NavigationItemCore, "label"> & {
218
184
  * fallback to `fallbackUrl`
219
185
  */
220
186
  type NavigationSectionNested = Pick<NavigationItemCore, "label"> & {
221
- path?: string | null;
222
187
  /**
223
188
  * Fallback url if no `url` provided and items are not available in the current store
224
189
  */
@@ -260,7 +225,6 @@ export declare const NavigationItemId: {
260
225
  NewIntegrations: string;
261
226
  Accessories: string;
262
227
  UnifiIdentity: string;
263
- Amplifi: string;
264
228
  SixtyGhzWireless: string;
265
229
  Wireless: string;
266
230
  Fiber: string;