@keboola/design 6.1.0 → 6.3.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.
package/dist/rjsf.js CHANGED
@@ -379,9 +379,57 @@ var HelpBlock = ({ children, className, state = "default", ...rest }) => {
379
379
  // src/icons/index.ts
380
380
  var icons_exports = {};
381
381
  __export(icons_exports, {
382
+ Google: () => Google,
382
383
  Keboola: () => Keboola
383
384
  });
384
385
  __reExport(icons_exports, lucide_react_star);
386
+ var Google = forwardRef(
387
+ ({ size = 24, className, children, ...rest }, ref) => /* @__PURE__ */ jsxs(
388
+ "svg",
389
+ {
390
+ ref,
391
+ xmlns: "http://www.w3.org/2000/svg",
392
+ width: size,
393
+ height: size,
394
+ viewBox: "12 10 20 20",
395
+ fill: "none",
396
+ className: cn("lucide", className),
397
+ ...rest,
398
+ children: [
399
+ /* @__PURE__ */ jsx(
400
+ "path",
401
+ {
402
+ d: "M31.6 20.2273C31.6 19.5182 31.5364 18.8364 31.4182 18.1818H22V22.05H27.3818C27.15 23.3 26.4455 24.3591 25.3864 25.0682V27.5773H28.6182C30.5091 25.8364 31.6 23.2727 31.6 20.2273Z",
403
+ fill: "#4285F4"
404
+ }
405
+ ),
406
+ /* @__PURE__ */ jsx(
407
+ "path",
408
+ {
409
+ d: "M22 30C24.7 30 26.9636 29.1045 28.6181 27.5773L25.3863 25.0682C24.4909 25.6682 23.3454 26.0227 22 26.0227C19.3954 26.0227 17.1909 24.2636 16.4045 21.9H13.0636V24.4909C14.7091 27.7591 18.0909 30 22 30Z",
410
+ fill: "#34A853"
411
+ }
412
+ ),
413
+ /* @__PURE__ */ jsx(
414
+ "path",
415
+ {
416
+ d: "M16.4045 21.9C16.2045 21.3 16.0909 20.6591 16.0909 20C16.0909 19.3409 16.2045 18.7 16.4045 18.1V15.5091H13.0636C12.3864 16.8591 12 18.3864 12 20C12 21.6136 12.3864 23.1409 13.0636 24.4909L16.4045 21.9Z",
417
+ fill: "#FBBC04"
418
+ }
419
+ ),
420
+ /* @__PURE__ */ jsx(
421
+ "path",
422
+ {
423
+ d: "M22 13.9773C23.4681 13.9773 24.7863 14.4818 25.8227 15.4727L28.6909 12.6045C26.9591 10.9909 24.6954 10 22 10C18.0909 10 14.7091 12.2409 13.0636 15.5091L16.4045 18.1C17.1909 15.7364 19.3954 13.9773 22 13.9773Z",
424
+ fill: "#EA4335"
425
+ }
426
+ ),
427
+ children
428
+ ]
429
+ }
430
+ )
431
+ );
432
+ Google.displayName = "Google";
385
433
  var Keboola = forwardRef(
386
434
  ({ size = 24, color = "currentColor", className, children, ...rest }, ref) => /* @__PURE__ */ jsxs(
387
435
  "svg",
@@ -1265,9 +1313,7 @@ var headerVariants = cva(
1265
1313
  variants: {
1266
1314
  variant: {
1267
1315
  default: "tw-bg-muted",
1268
- // White surface kept literal until a `card` token exists (UT-4396);
1269
- // `background` is the page base, not an elevated panel surface.
1270
- white: "tw-bg-white"
1316
+ white: "tw-bg-card"
1271
1317
  },
1272
1318
  isDisabled: {
1273
1319
  true: "tw-cursor-not-allowed tw-opacity-50",
@@ -1332,7 +1378,7 @@ var CollapsiblePanel = ({
1332
1378
  {
1333
1379
  open,
1334
1380
  className: cn(
1335
- "tw-rounded !tw-border !tw-border-solid !tw-border-border tw-bg-white",
1381
+ "tw-rounded !tw-border !tw-border-solid !tw-border-border tw-bg-card",
1336
1382
  className
1337
1383
  ),
1338
1384
  header: /* @__PURE__ */ jsxs(
@@ -8325,23 +8371,23 @@ var BadgeLabel = ({
8325
8371
  var badgeColors = {
8326
8372
  gray: "tw-bg-neutral-400 tw-text-white tw-decoration-neutral-400",
8327
8373
  "gray-darker": "tw-bg-neutral-500 tw-text-white tw-decoration-neutral-500",
8328
- "gray-inverse": "tw-bg-neutral-100 tw-text-neutral-400 tw-decoration-neutral-100",
8374
+ "gray-inverse": "tw-bg-neutral-100 tw-text-neutral-500 tw-decoration-neutral-100 [[data-theme=dark]_&]:tw-bg-neutral-800 [[data-theme=dark]_&]:tw-text-neutral-300 [[data-theme=dark]_&]:tw-decoration-neutral-800",
8329
8375
  green: "tw-bg-green-500 tw-text-white tw-decoration-green-500",
8330
8376
  "green-darker": "tw-bg-green-600 tw-text-white tw-decoration-green-600",
8331
- "green-inverse": "tw-bg-green-100 tw-text-green-900 tw-decoration-green-100",
8377
+ "green-inverse": "tw-bg-green-100 tw-text-green-900 tw-decoration-green-100 [[data-theme=dark]_&]:tw-bg-green-900 [[data-theme=dark]_&]:tw-text-green-200 [[data-theme=dark]_&]:tw-decoration-green-900",
8332
8378
  blue: "tw-bg-blue-500 tw-text-white tw-decoration-blue-500",
8333
- "blue-inverse": "tw-bg-blue-100 tw-text-blue-600 tw-decoration-blue-100",
8379
+ "blue-inverse": "tw-bg-blue-100 tw-text-blue-600 tw-decoration-blue-100 [[data-theme=dark]_&]:tw-bg-blue-900 [[data-theme=dark]_&]:tw-text-blue-200 [[data-theme=dark]_&]:tw-decoration-blue-900",
8334
8380
  red: "tw-bg-error-500 tw-text-white tw-decoration-error-500",
8335
8381
  orange: "tw-bg-warning-500 tw-text-white tw-decoration-warning-500",
8336
- "orange-inverse": "tw-bg-warning-100 tw-text-warning-500 tw-decoration-warning-100",
8382
+ "orange-inverse": "tw-bg-warning-100 tw-text-warning-500 tw-decoration-warning-100 [[data-theme=dark]_&]:tw-bg-warning-900 [[data-theme=dark]_&]:tw-text-warning-200 [[data-theme=dark]_&]:tw-decoration-warning-900",
8337
8383
  amber: "tw-bg-warning-300 tw-text-warning-800 tw-decoration-warning-300",
8338
8384
  "amber-inverse": "tw-bg-warning-100 tw-text-warning-700 tw-decoration-warning-100",
8339
8385
  teal: "tw-bg-teal-500 tw-text-white tw-decoration-teal-500",
8340
- "teal-inverse": "tw-bg-teal-100 tw-text-teal-800 tw-decoration-teal-100",
8386
+ "teal-inverse": "tw-bg-teal-100 tw-text-teal-800 tw-decoration-teal-100 [[data-theme=dark]_&]:tw-bg-teal-900 [[data-theme=dark]_&]:tw-text-teal-200 [[data-theme=dark]_&]:tw-decoration-teal-900",
8341
8387
  purple: "tw-bg-purple-500 tw-text-white tw-decoration-purple-500",
8342
- "purple-inverse": "tw-bg-purple-100 tw-text-purple-800 tw-decoration-purple-100",
8388
+ "purple-inverse": "tw-bg-purple-100 tw-text-purple-800 tw-decoration-purple-100 [[data-theme=dark]_&]:tw-bg-purple-900 [[data-theme=dark]_&]:tw-text-purple-200 [[data-theme=dark]_&]:tw-decoration-purple-900",
8343
8389
  cyan: "tw-bg-cyan-500 tw-text-white tw-decoration-cyan-500",
8344
- "cyan-inverse": "tw-bg-cyan-100 tw-text-cyan-800 tw-decoration-cyan-100",
8390
+ "cyan-inverse": "tw-bg-cyan-100 tw-text-cyan-800 tw-decoration-cyan-100 [[data-theme=dark]_&]:tw-bg-cyan-900 [[data-theme=dark]_&]:tw-text-cyan-200 [[data-theme=dark]_&]:tw-decoration-cyan-900",
8345
8391
  "sidebar-primary": "tw-bg-sidebar-primary tw-text-white tw-decoration-sidebar-primary",
8346
8392
  white: "tw-bg-white/90 tw-text-neutral-600 tw-decoration-white/90"
8347
8393
  };
@@ -9050,14 +9096,18 @@ var DynamicSelectWidget = ({
9050
9096
  const data = useRootFormData();
9051
9097
  const watch = widgetOptions.watch;
9052
9098
  const enumSource = widgetOptions.enumSource;
9053
- const items = watch ? buildDynamicOptions(watch, enumSource, data) : [];
9054
- const selectedItem = items.find((item) => item.value === (value == null ? "" : String(value)));
9099
+ const dynamicItems = watch ? buildDynamicOptions(watch, enumSource, data) : [];
9100
+ const stringValue = value == null ? "" : String(value);
9101
+ const matched = dynamicItems.find((item) => item.value === stringValue);
9102
+ const fallbackItem = !matched && stringValue !== "" ? { value: stringValue, label: stringValue } : null;
9103
+ const selectedItem = matched ?? fallbackItem;
9104
+ const items = fallbackItem ? [fallbackItem, ...dynamicItems] : dynamicItems;
9055
9105
  return /* @__PURE__ */ jsx(
9056
9106
  Combobox,
9057
9107
  {
9058
9108
  variant: "secondary",
9059
9109
  items,
9060
- value: selectedItem ?? null,
9110
+ value: selectedItem,
9061
9111
  disabled: disabled || readonly,
9062
9112
  onValueChange: (selected) => onChange(selected?.value ?? "")
9063
9113
  }