@smplkit/sdk 1.3.19 → 1.3.21

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.
package/dist/index.cjs CHANGED
@@ -820,7 +820,7 @@ var Flag = class {
820
820
  type;
821
821
  /** Flag-level default value. */
822
822
  default;
823
- /** Closed set of possible values. */
823
+ /** Closed set of possible values (constrained), or null (unconstrained). */
824
824
  values;
825
825
  /** Optional description. */
826
826
  description;
@@ -1218,7 +1218,7 @@ var FlagsClient = class {
1218
1218
  name: options.name ?? keyToDisplayName(key),
1219
1219
  type: "STRING",
1220
1220
  default: options.default,
1221
- values: options.values ?? [],
1221
+ values: options.values ?? null,
1222
1222
  description: options.description ?? null,
1223
1223
  environments: {},
1224
1224
  createdAt: null,
@@ -1233,7 +1233,7 @@ var FlagsClient = class {
1233
1233
  name: options.name ?? keyToDisplayName(key),
1234
1234
  type: "NUMERIC",
1235
1235
  default: options.default,
1236
- values: options.values ?? [],
1236
+ values: options.values ?? null,
1237
1237
  description: options.description ?? null,
1238
1238
  environments: {},
1239
1239
  createdAt: null,
@@ -1248,7 +1248,7 @@ var FlagsClient = class {
1248
1248
  name: options.name ?? keyToDisplayName(key),
1249
1249
  type: "JSON",
1250
1250
  default: options.default,
1251
- values: options.values ?? [],
1251
+ values: options.values ?? null,
1252
1252
  description: options.description ?? null,
1253
1253
  environments: {},
1254
1254
  createdAt: null,
@@ -1726,7 +1726,7 @@ var FlagsClient = class {
1726
1726
  name: attrs.name,
1727
1727
  type: attrs.type,
1728
1728
  default: attrs.default,
1729
- values: (attrs.values ?? []).map((v) => ({ name: v.name, value: v.value })),
1729
+ values: attrs.values ? attrs.values.map((v) => ({ name: v.name, value: v.value })) : null,
1730
1730
  description: attrs.description ?? null,
1731
1731
  environments: attrs.environments ?? {},
1732
1732
  createdAt: attrs.created_at ?? null,
@@ -1740,7 +1740,7 @@ var FlagsClient = class {
1740
1740
  name: attrs.name,
1741
1741
  type: attrs.type,
1742
1742
  default: attrs.default,
1743
- values: (attrs.values ?? []).map((v) => ({ name: v.name, value: v.value })),
1743
+ values: attrs.values ? attrs.values.map((v) => ({ name: v.name, value: v.value })) : null,
1744
1744
  description: attrs.description ?? null,
1745
1745
  environments: attrs.environments ?? {}
1746
1746
  };