@nextsparkjs/core 0.1.0-beta.129 → 0.1.0-beta.130

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.
@@ -1 +1 @@
1
- {"version":3,"file":"block-picker.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/block-picker.tsx"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAA;AACvE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAA;AACxE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAA;AAuBxF,UAAU,gBAAgB;IACxB,MAAM,EAAE,WAAW,EAAE,CAAA;IACrB,UAAU,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;IACvC,YAAY,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;IAC1C,YAAY,EAAE,kBAAkB,CAAA;IAChC,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACrC,mBAAmB,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;IAC5D,aAAa,EAAE,OAAO,CAAA;IACtB,eAAe,CAAC,EAAE,OAAO,CAAA;IAEzB,UAAU,EAAE,CAAC,aAAa,GAAG,gBAAgB,CAAC,EAAE,CAAA;IAChD,eAAe,EAAE,MAAM,GAAG,IAAI,CAAA;IAC9B,aAAa,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;IACnC,eAAe,EAAE,CAAC,MAAM,EAAE,CAAC,aAAa,GAAG,gBAAgB,CAAC,EAAE,KAAK,IAAI,CAAA;CACxE;AAED,wBAAgB,WAAW,CAAC,EAC1B,MAAM,EACN,UAAU,EACV,YAAY,EACZ,YAAY,EACZ,YAAY,EACZ,mBAAmB,EACnB,aAAa,EACb,eAAuB,EAEvB,UAAU,EACV,eAAe,EACf,aAAa,EACb,eAAe,GAChB,EAAE,gBAAgB,2CA2TlB"}
1
+ {"version":3,"file":"block-picker.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/block-picker.tsx"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAA;AACvE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAA;AACxE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAA;AAuBxF,UAAU,gBAAgB;IACxB,MAAM,EAAE,WAAW,EAAE,CAAA;IACrB,UAAU,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;IACvC,YAAY,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;IAC1C,YAAY,EAAE,kBAAkB,CAAA;IAChC,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACrC,mBAAmB,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;IAC5D,aAAa,EAAE,OAAO,CAAA;IACtB,eAAe,CAAC,EAAE,OAAO,CAAA;IAEzB,UAAU,EAAE,CAAC,aAAa,GAAG,gBAAgB,CAAC,EAAE,CAAA;IAChD,eAAe,EAAE,MAAM,GAAG,IAAI,CAAA;IAC9B,aAAa,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;IACnC,eAAe,EAAE,CAAC,MAAM,EAAE,CAAC,aAAa,GAAG,gBAAgB,CAAC,EAAE,KAAK,IAAI,CAAA;CACxE;AAED,wBAAgB,WAAW,CAAC,EAC1B,MAAM,EACN,UAAU,EACV,YAAY,EACZ,YAAY,EACZ,YAAY,EACZ,mBAAmB,EACnB,aAAa,EACb,eAAuB,EAEvB,UAAU,EACV,eAAe,EACf,aAAa,EACb,eAAe,GAChB,EAAE,gBAAgB,2CA6TlB"}
@@ -147,6 +147,8 @@ function BlockPicker({
147
147
  /* @__PURE__ */ jsx(
148
148
  Input,
149
149
  {
150
+ id: "block-search",
151
+ name: "block-search",
150
152
  type: "text",
151
153
  placeholder: t("sidebar.search.placeholder"),
152
154
  value: search,
@@ -60,7 +60,7 @@ function BlockPreviewCanvas({
60
60
  onDuplicate,
61
61
  onRemove
62
62
  },
63
- block.id
63
+ block.id || `block-${index}`
64
64
  )) });
65
65
  }
66
66
  const SelectableBlockPreview = memo(function SelectableBlockPreview2({
@@ -1 +1 @@
1
- {"version":3,"file":"builder-editor-view.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/builder-editor-view.tsx"],"names":[],"mappings":"AA+BA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAA;AAwCxF,MAAM,WAAW,sBAAsB;IACrC,UAAU,EAAE,MAAM,CAAA;IAClB,YAAY,EAAE,kBAAkB,CAAA;IAChC,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,IAAI,EAAE,QAAQ,GAAG,MAAM,CAAA;CACxB;AAED,wBAAgB,iBAAiB,CAAC,EAAE,UAAU,EAAE,YAAY,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,sBAAsB,2CA2rB/F"}
1
+ {"version":3,"file":"builder-editor-view.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/builder-editor-view.tsx"],"names":[],"mappings":"AA+BA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAA;AAwCxF,MAAM,WAAW,sBAAsB;IACrC,UAAU,EAAE,MAAM,CAAA;IAClB,YAAY,EAAE,kBAAkB,CAAA;IAChC,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,IAAI,EAAE,QAAQ,GAAG,MAAM,CAAA;CACxB;AAED,wBAAgB,iBAAiB,CAAC,EAAE,UAAU,EAAE,YAAY,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,sBAAsB,2CA+rB/F"}
@@ -387,6 +387,8 @@ function BuilderEditorView({ entitySlug, entityConfig, id, mode }) {
387
387
  /* @__PURE__ */ jsx(
388
388
  Input,
389
389
  {
390
+ id: "builder-title",
391
+ name: "builder-title",
390
392
  ref: titleInputRef,
391
393
  value: title,
392
394
  onChange: (e) => {
@@ -417,6 +419,8 @@ function BuilderEditorView({ entitySlug, entityConfig, id, mode }) {
417
419
  /* @__PURE__ */ jsx(
418
420
  Input,
419
421
  {
422
+ id: "builder-slug",
423
+ name: "builder-slug",
420
424
  value: slug,
421
425
  onChange: (e) => {
422
426
  const newSlug = e.target.value;
@@ -1 +1 @@
1
- {"version":3,"file":"config-panel.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/config-panel.tsx"],"names":[],"mappings":"AA8BA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAA;AACxF,OAAO,KAAK,EAAE,YAAY,EAAmB,MAAM,uBAAuB,CAAA;AAiB1E,UAAU,gBAAgB;IACxB,YAAY,EAAE,kBAAkB,CAAA;IAChC,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACrC,mBAAmB,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;IAC5D,YAAY,EAAE,YAAY,CAAA;IAC1B,oBAAoB,EAAE,CAAC,QAAQ,EAAE,YAAY,KAAK,IAAI,CAAA;CACvD;AAED;;;;;GAKG;AACH,wBAAgB,WAAW,CAAC,EAC1B,YAAY,EACZ,YAAY,EACZ,mBAAmB,EACnB,YAAY,EACZ,oBAAoB,EACrB,EAAE,gBAAgB,2CA2elB"}
1
+ {"version":3,"file":"config-panel.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/config-panel.tsx"],"names":[],"mappings":"AA8BA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAA;AACxF,OAAO,KAAK,EAAE,YAAY,EAAmB,MAAM,uBAAuB,CAAA;AAiB1E,UAAU,gBAAgB;IACxB,YAAY,EAAE,kBAAkB,CAAA;IAChC,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACrC,mBAAmB,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;IAC5D,YAAY,EAAE,YAAY,CAAA;IAC1B,oBAAoB,EAAE,CAAC,QAAQ,EAAE,YAAY,KAAK,IAAI,CAAA;CACvD;AAED;;;;;GAKG;AACH,wBAAgB,WAAW,CAAC,EAC1B,YAAY,EACZ,YAAY,EACZ,mBAAmB,EACnB,YAAY,EACZ,oBAAoB,EACrB,EAAE,gBAAgB,2CA6elB"}
@@ -43,7 +43,7 @@ function ConfigPanel({
43
43
  pageSettings,
44
44
  onPageSettingsChange
45
45
  }) {
46
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
46
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j;
47
47
  const t = useTranslations("admin.builder");
48
48
  const tSettings = useTranslations("admin.pages.settings");
49
49
  const [entityFieldsOpen, setEntityFieldsOpen] = useState(true);
@@ -53,10 +53,11 @@ function ConfigPanel({
53
53
  const taxonomyTypes = ((_b = entityConfig.taxonomies) == null ? void 0 : _b.types) || [];
54
54
  const taxonomiesEnabled = ((_c = entityConfig.taxonomies) == null ? void 0 : _c.enabled) && taxonomyTypes.length > 0;
55
55
  const firstTaxonomy = taxonomyTypes[0];
56
- const taxonomyApiPath = ((_d = firstTaxonomy == null ? void 0 : firstTaxonomy.type) == null ? void 0 : _d.replace("_", "-")) + "s";
56
+ const taxonomyApiPath = (firstTaxonomy == null ? void 0 : firstTaxonomy.type) ? firstTaxonomy.type.replace("_", "-") + "s" : void 0;
57
57
  const { data: taxonomyData, isLoading: taxonomyLoading } = useQuery({
58
58
  queryKey: ["taxonomies", taxonomyApiPath],
59
59
  queryFn: async () => {
60
+ if (!taxonomyApiPath) return { data: [] };
60
61
  const response = await fetch(`/api/v1/${taxonomyApiPath}`);
61
62
  if (!response.ok) return { data: [] };
62
63
  return response.json();
@@ -68,7 +69,7 @@ function ConfigPanel({
68
69
  const showEntityFieldsSection = useMemo(() => {
69
70
  return sidebarFields.length > 0 || taxonomiesEnabled;
70
71
  }, [sidebarFields.length, taxonomiesEnabled]);
71
- const showSeoSection = ((_e = entityConfig.builder) == null ? void 0 : _e.seo) !== false;
72
+ const showSeoSection = ((_d = entityConfig.builder) == null ? void 0 : _d.seo) !== false;
72
73
  const renderField = (fieldName) => {
73
74
  var _a2;
74
75
  const value = entityFields[fieldName];
@@ -89,6 +90,7 @@ function ConfigPanel({
89
90
  /* @__PURE__ */ jsx(
90
91
  SimpleRelationSelect,
91
92
  {
93
+ id: fieldName,
92
94
  entityType: fieldConfig.relation.entity,
93
95
  titleField: fieldConfig.relation.titleField,
94
96
  value: value || void 0,
@@ -338,7 +340,7 @@ function ConfigPanel({
338
340
  Input,
339
341
  {
340
342
  id: "meta-title",
341
- value: ((_f = pageSettings.seo) == null ? void 0 : _f.metaTitle) || "",
343
+ value: ((_e = pageSettings.seo) == null ? void 0 : _e.metaTitle) || "",
342
344
  onChange: (e) => handleSeoChange("metaTitle", e.target.value),
343
345
  placeholder: tSettings("seo.metaTitlePlaceholder"),
344
346
  "data-cy": sel("blockEditor.configPanel.seoSection.metaTitle")
@@ -352,7 +354,7 @@ function ConfigPanel({
352
354
  Textarea,
353
355
  {
354
356
  id: "meta-description",
355
- value: ((_g = pageSettings.seo) == null ? void 0 : _g.metaDescription) || "",
357
+ value: ((_f = pageSettings.seo) == null ? void 0 : _f.metaDescription) || "",
356
358
  onChange: (e) => handleSeoChange("metaDescription", e.target.value),
357
359
  placeholder: tSettings("seo.metaDescriptionPlaceholder"),
358
360
  rows: 3,
@@ -360,7 +362,7 @@ function ConfigPanel({
360
362
  }
361
363
  ),
362
364
  /* @__PURE__ */ jsxs("p", { className: "text-xs text-muted-foreground", children: [
363
- ((_i = (_h = pageSettings.seo) == null ? void 0 : _h.metaDescription) == null ? void 0 : _i.length) || 0,
365
+ ((_h = (_g = pageSettings.seo) == null ? void 0 : _g.metaDescription) == null ? void 0 : _h.length) || 0,
364
366
  "/160 ",
365
367
  tSettings("seo.characters")
366
368
  ] })
@@ -371,7 +373,7 @@ function ConfigPanel({
371
373
  Input,
372
374
  {
373
375
  id: "meta-keywords",
374
- value: ((_j = pageSettings.seo) == null ? void 0 : _j.metaKeywords) || "",
376
+ value: ((_i = pageSettings.seo) == null ? void 0 : _i.metaKeywords) || "",
375
377
  onChange: (e) => handleSeoChange("metaKeywords", e.target.value),
376
378
  placeholder: tSettings("seo.metaKeywordsPlaceholder"),
377
379
  "data-cy": sel("blockEditor.configPanel.seoSection.metaKeywords")
@@ -384,7 +386,7 @@ function ConfigPanel({
384
386
  Input,
385
387
  {
386
388
  id: "og-image",
387
- value: ((_k = pageSettings.seo) == null ? void 0 : _k.ogImage) || "",
389
+ value: ((_j = pageSettings.seo) == null ? void 0 : _j.ogImage) || "",
388
390
  onChange: (e) => handleSeoChange("ogImage", e.target.value),
389
391
  placeholder: tSettings("seo.ogImagePlaceholder"),
390
392
  "data-cy": sel("blockEditor.configPanel.seoSection.ogImage")
@@ -1 +1 @@
1
- {"version":3,"file":"dynamic-form.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/dynamic-form.tsx"],"names":[],"mappings":"AA6BA,OAAO,KAAK,EAAE,eAAe,EAAY,MAAM,uBAAuB,CAAA;AAItE,UAAU,gBAAgB;IACxB,gBAAgB,EAAE,eAAe,EAAE,CAAA;IACnC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IAC/B,QAAQ,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,CAAA;CACpD;AA4RD;;;;;;;;GAQG;AACH,wBAAgB,WAAW,CAAC,EAAE,gBAAgB,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE,gBAAgB,2CAodnF"}
1
+ {"version":3,"file":"dynamic-form.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/dynamic-form.tsx"],"names":[],"mappings":"AA6BA,OAAO,KAAK,EAAE,eAAe,EAAY,MAAM,uBAAuB,CAAA;AAItE,UAAU,gBAAgB;IACxB,gBAAgB,EAAE,eAAe,EAAE,CAAA;IACnC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IAC/B,QAAQ,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,CAAA;CACpD;AA6RD;;;;;;;;GAQG;AACH,wBAAgB,WAAW,CAAC,EAAE,gBAAgB,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE,gBAAgB,2CAodnF"}
@@ -228,6 +228,7 @@ function RelationshipField({
228
228
  /* @__PURE__ */ jsx(
229
229
  SelectTrigger,
230
230
  {
231
+ id: field.name,
231
232
  "data-cy": sel("blockEditor.blockPropertiesPanel.form.field", { name: field.name }),
232
233
  children: /* @__PURE__ */ jsx(SelectValue, { placeholder: field.placeholder || t("selectEntity", { entity: field.targetEntity }) })
233
234
  }
@@ -1 +1 @@
1
- {"version":3,"file":"entity-fields-sidebar.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/entity-fields-sidebar.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAA;AAiBxF,UAAU,wBAAwB;IAChC,YAAY,EAAE,kBAAkB,CAAA;IAChC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IAC/B,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;IACjD,kBAAkB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC7B,gBAAgB,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,IAAI,CAAA;CAChD;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,EAClC,YAAY,EACZ,MAAM,EACN,QAAQ,EACR,kBAAuB,EACvB,gBAAgB,EACjB,EAAE,wBAAwB,2CAiS1B"}
1
+ {"version":3,"file":"entity-fields-sidebar.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/block-editor/entity-fields-sidebar.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAA;AAiBxF,UAAU,wBAAwB;IAChC,YAAY,EAAE,kBAAkB,CAAA;IAChC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IAC/B,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;IACjD,kBAAkB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC7B,gBAAgB,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,IAAI,CAAA;CAChD;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,EAClC,YAAY,EACZ,MAAM,EACN,QAAQ,EACR,kBAAuB,EACvB,gBAAgB,EACjB,EAAE,wBAAwB,2CAmS1B"}
@@ -25,16 +25,17 @@ function EntityFieldsSidebar({
25
25
  selectedCategories = [],
26
26
  onCategoryToggle
27
27
  }) {
28
- var _a, _b, _c, _d;
28
+ var _a, _b, _c;
29
29
  const t = useTranslations("admin.builder");
30
30
  const sidebarFields = ((_a = entityConfig.builder) == null ? void 0 : _a.sidebarFields) || [];
31
31
  const taxonomyTypes = ((_b = entityConfig.taxonomies) == null ? void 0 : _b.types) || [];
32
32
  const taxonomiesEnabled = ((_c = entityConfig.taxonomies) == null ? void 0 : _c.enabled) && taxonomyTypes.length > 0;
33
33
  const firstTaxonomy = taxonomyTypes[0];
34
- const taxonomyApiPath = ((_d = firstTaxonomy == null ? void 0 : firstTaxonomy.type) == null ? void 0 : _d.replace("_", "-")) + "s";
34
+ const taxonomyApiPath = (firstTaxonomy == null ? void 0 : firstTaxonomy.type) ? firstTaxonomy.type.replace("_", "-") + "s" : void 0;
35
35
  const { data: taxonomyData, isLoading: taxonomyLoading } = useQuery({
36
36
  queryKey: ["taxonomies", taxonomyApiPath],
37
37
  queryFn: async () => {
38
+ if (!taxonomyApiPath) return { data: [] };
38
39
  const response = await fetch(`/api/v1/${taxonomyApiPath}`);
39
40
  if (!response.ok) return { data: [] };
40
41
  return response.json();
@@ -62,6 +63,7 @@ function EntityFieldsSidebar({
62
63
  /* @__PURE__ */ jsx(
63
64
  SimpleRelationSelect,
64
65
  {
66
+ id: fieldName,
65
67
  entityType: fieldConfig.relation.entity,
66
68
  titleField: fieldConfig.relation.titleField,
67
69
  value: value || void 0,
@@ -29,6 +29,8 @@ export interface SimpleRelationSelectProps {
29
29
  limit?: number;
30
30
  /** Query filter params appended to the API call (e.g., { type: 'generic' }) */
31
31
  filter?: Record<string, string>;
32
+ /** HTML id for the trigger button (enables label[for] association) */
33
+ id?: string;
32
34
  }
33
- export declare function SimpleRelationSelect({ value, onChange, entityType, titleField, multiple, placeholder, disabled, parentId, propField, usePropertyMode, propertyOptions, userFiltered, teamId, limit, filter, }: SimpleRelationSelectProps): import("react/jsx-runtime").JSX.Element;
35
+ export declare function SimpleRelationSelect({ value, onChange, entityType, titleField, multiple, placeholder, disabled, parentId, propField, usePropertyMode, propertyOptions, userFiltered, teamId, limit, filter, id, }: SimpleRelationSelectProps): import("react/jsx-runtime").JSX.Element;
34
36
  //# sourceMappingURL=simple-relation-select.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"simple-relation-select.d.ts","sourceRoot":"","sources":["../../../src/components/ui/simple-relation-select.tsx"],"names":[],"mappings":"AAuBA,MAAM,WAAW,kBAAkB;IACjC,EAAE,EAAE,MAAM,CAAA;IACV,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB;AAED,MAAM,WAAW,oBAAoB;IACnC,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;IACb,UAAU,EAAE,MAAM,CAAA;CACnB;AAED,MAAM,WAAW,yBAAyB;IACxC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IACzB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,IAAI,KAAK,IAAI,CAAA;IACnD,UAAU,EAAE,MAAM,CAAA;IAClB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAA;IAEjB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,eAAe,CAAC,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;IAEzD,YAAY,CAAC,EAAE,OAAO,CAAA;IAEtB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,8FAA8F;IAC9F,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,+EAA+E;IAC/E,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;CAChC;AAED,wBAAgB,oBAAoB,CAAC,EACnC,KAAK,EACL,QAAQ,EACR,UAAU,EACV,UAAU,EACV,QAAgB,EAChB,WAA8B,EAC9B,QAAgB,EAChB,QAAQ,EACR,SAAS,EACT,eAAuB,EACvB,eAAoB,EACpB,YAAoB,EACpB,MAAM,EACN,KAAU,EACV,MAAM,GACP,EAAE,yBAAyB,2CAulB3B"}
1
+ {"version":3,"file":"simple-relation-select.d.ts","sourceRoot":"","sources":["../../../src/components/ui/simple-relation-select.tsx"],"names":[],"mappings":"AAuBA,MAAM,WAAW,kBAAkB;IACjC,EAAE,EAAE,MAAM,CAAA;IACV,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB;AAED,MAAM,WAAW,oBAAoB;IACnC,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;IACb,UAAU,EAAE,MAAM,CAAA;CACnB;AAED,MAAM,WAAW,yBAAyB;IACxC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IACzB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,IAAI,KAAK,IAAI,CAAA;IACnD,UAAU,EAAE,MAAM,CAAA;IAClB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAA;IAEjB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,eAAe,CAAC,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;IAEzD,YAAY,CAAC,EAAE,OAAO,CAAA;IAEtB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,8FAA8F;IAC9F,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,+EAA+E;IAC/E,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAC/B,sEAAsE;IACtE,EAAE,CAAC,EAAE,MAAM,CAAA;CACZ;AAED,wBAAgB,oBAAoB,CAAC,EACnC,KAAK,EACL,QAAQ,EACR,UAAU,EACV,UAAU,EACV,QAAgB,EAChB,WAA8B,EAC9B,QAAgB,EAChB,QAAQ,EACR,SAAS,EACT,eAAuB,EACvB,eAAoB,EACpB,YAAoB,EACpB,MAAM,EACN,KAAU,EACV,MAAM,EACN,EAAE,GACH,EAAE,yBAAyB,2CAwlB3B"}
@@ -34,7 +34,8 @@ function SimpleRelationSelect({
34
34
  userFiltered = false,
35
35
  teamId,
36
36
  limit = 20,
37
- filter
37
+ filter,
38
+ id
38
39
  }) {
39
40
  const [open, setOpen] = React.useState(false);
40
41
  const [options, setOptions] = React.useState([]);
@@ -316,7 +317,7 @@ function SimpleRelationSelect({
316
317
  const handleSelect = (optionId) => {
317
318
  const selectedOption = options.find((opt) => opt.id === optionId);
318
319
  if (multiple) {
319
- const newValues = selectedValues.includes(optionId) ? selectedValues.filter((id) => id !== optionId) : [...selectedValues, optionId];
320
+ const newValues = selectedValues.includes(optionId) ? selectedValues.filter((id2) => id2 !== optionId) : [...selectedValues, optionId];
320
321
  onChange(newValues.length > 0 ? newValues : null);
321
322
  if (selectedOption) {
322
323
  if (selectedValues.includes(optionId)) {
@@ -337,7 +338,7 @@ function SimpleRelationSelect({
337
338
  };
338
339
  const handleRemove = (optionId) => {
339
340
  if (multiple) {
340
- const newValues = selectedValues.filter((id) => id !== optionId);
341
+ const newValues = selectedValues.filter((id2) => id2 !== optionId);
341
342
  onChange(newValues.length > 0 ? newValues : null);
342
343
  setSelectedOptions((prev) => prev.filter((opt) => opt.id !== optionId));
343
344
  } else {
@@ -390,6 +391,7 @@ function SimpleRelationSelect({
390
391
  /* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx(
391
392
  Button,
392
393
  {
394
+ id,
393
395
  variant: "outline",
394
396
  role: "combobox",
395
397
  "aria-expanded": open,
@@ -27,7 +27,7 @@ function SubscriptionProvider({ children }) {
27
27
  const data = await response.json();
28
28
  return ((_a2 = data.data) == null ? void 0 : _a2.subscription) ?? data.data;
29
29
  },
30
- enabled: !!team,
30
+ enabled: !!team && BILLING_REGISTRY.plans.length > 0,
31
31
  staleTime: 5 * 60 * 1e3,
32
32
  // 5 minutes
33
33
  refetchOnWindowFocus: false
@@ -1,5 +1,5 @@
1
1
  {
2
- "generated": "2026-03-25T21:49:37.359Z",
2
+ "generated": "2026-03-26T20:40:48.170Z",
3
3
  "totalClasses": 1078,
4
4
  "classes": [
5
5
  "!text-2xl",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nextsparkjs/core",
3
- "version": "0.1.0-beta.129",
3
+ "version": "0.1.0-beta.130",
4
4
  "description": "NextSpark - The complete SaaS framework for Next.js",
5
5
  "license": "MIT",
6
6
  "author": "NextSpark <hello@nextspark.dev>",
@@ -462,7 +462,7 @@
462
462
  "tailwind-merge": "^3.3.1",
463
463
  "uuid": "^13.0.0",
464
464
  "zod": "^4.1.5",
465
- "@nextsparkjs/testing": "0.1.0-beta.129"
465
+ "@nextsparkjs/testing": "0.1.0-beta.130"
466
466
  },
467
467
  "scripts": {
468
468
  "postinstall": "node scripts/postinstall.mjs || true",