@sarunyu/system-one 4.7.6 → 4.7.7

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
@@ -3398,75 +3398,75 @@ const DropdownMultiple = React.forwardRef(
3398
3398
  )
3399
3399
  }
3400
3400
  ),
3401
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "shrink-0", style: { color: caretColor }, children: isFocus ? /* @__PURE__ */ jsxRuntime.jsx(react.CaretUp, { size: 22 }) : /* @__PURE__ */ jsxRuntime.jsx(react.CaretDown, { size: 22 }) })
3402
- ]
3403
- }
3404
- ),
3405
- open && !isStatic && options.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
3406
- "div",
3407
- {
3408
- className: "relative bg-popover rounded-[8px] overflow-clip p-[8px] z-20 flex flex-col items-start text-popover-foreground",
3409
- style: {
3410
- boxShadow: "var(--elevation-popover)"
3411
- },
3412
- children: /* @__PURE__ */ jsxRuntime.jsx(
3413
- "div",
3414
- {
3415
- className: cn(
3416
- "w-full flex flex-col",
3417
- filteredOptions.length > 10 && "overflow-y-auto"
3418
- ),
3419
- style: filteredOptions.length > 10 ? { maxHeight: 10 * 48 } : void 0,
3420
- children: filteredOptions.length > 0 ? filteredOptions.map((opt) => {
3421
- const isSelected = currentValue.includes(opt.value);
3422
- return /* @__PURE__ */ jsxRuntime.jsx(
3401
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "shrink-0", style: { color: caretColor }, children: isFocus ? /* @__PURE__ */ jsxRuntime.jsx(react.CaretUp, { size: 22 }) : /* @__PURE__ */ jsxRuntime.jsx(react.CaretDown, { size: 22 }) }),
3402
+ open && !isStatic && options.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
3403
+ "div",
3404
+ {
3405
+ className: "absolute top-full left-0 w-full mt-1 bg-popover rounded-[8px] overflow-clip p-[8px] z-50 flex flex-col items-start text-popover-foreground",
3406
+ style: {
3407
+ boxShadow: "var(--elevation-popover)"
3408
+ },
3409
+ children: /* @__PURE__ */ jsxRuntime.jsx(
3423
3410
  "div",
3424
3411
  {
3425
- onClick: (e) => {
3426
- var _a;
3427
- e.stopPropagation();
3428
- handleToggleOption(opt.value);
3429
- (_a = inputRef.current) == null ? void 0 : _a.focus();
3430
- },
3431
3412
  className: cn(
3432
- "w-full shrink-0 rounded-[4px] cursor-pointer transition-colors duration-100",
3433
- isSelected ? "bg-primary-action-light" : "bg-popover hover:bg-disabled-bg"
3413
+ "w-full flex flex-col",
3414
+ filteredOptions.length > 10 && "overflow-y-auto"
3434
3415
  ),
3435
- children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-row items-center size-full", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-[8px] p-[14px] relative w-full", children: [
3436
- /* @__PURE__ */ jsxRuntime.jsx(
3437
- "p",
3438
- {
3439
- className: cn(
3440
- "flex-1 min-w-0 min-h-[1px] leading-[20px] not-italic overflow-hidden text-[14px] text-ellipsis whitespace-nowrap",
3441
- isSelected ? "text-primary-action" : "text-foreground"
3442
- ),
3443
- children: opt.label
3444
- }
3445
- ),
3446
- /* @__PURE__ */ jsxRuntime.jsx(
3416
+ style: filteredOptions.length > 10 ? { maxHeight: 10 * 48 } : void 0,
3417
+ children: filteredOptions.length > 0 ? filteredOptions.map((opt) => {
3418
+ const isSelected = currentValue.includes(opt.value);
3419
+ return /* @__PURE__ */ jsxRuntime.jsx(
3447
3420
  "div",
3448
3421
  {
3422
+ onClick: (e) => {
3423
+ var _a;
3424
+ e.stopPropagation();
3425
+ handleToggleOption(opt.value);
3426
+ (_a = inputRef.current) == null ? void 0 : _a.focus();
3427
+ },
3449
3428
  className: cn(
3450
- "shrink-0 w-[16px] h-[16px] rounded-[3px] flex items-center justify-center transition-colors duration-100",
3451
- "bg-transparent"
3429
+ "w-full shrink-0 rounded-[4px] cursor-pointer transition-colors duration-100",
3430
+ isSelected ? "bg-primary-action-light" : "bg-popover hover:bg-disabled-bg"
3452
3431
  ),
3453
- children: isSelected && /* @__PURE__ */ jsxRuntime.jsx(
3454
- react.Check,
3455
- {
3456
- size: 12,
3457
- weight: "bold",
3458
- className: "text-primary-action"
3459
- }
3460
- )
3461
- }
3462
- )
3463
- ] }) })
3464
- },
3465
- opt.value
3466
- );
3467
- }) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full shrink-0 bg-popover", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-row items-center size-full", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center p-[14px] relative w-full", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "flex-1 min-w-0 min-h-[1px] leading-[20px] not-italic text-[14px] text-disabled", children: "No results found" }) }) }) })
3468
- }
3469
- )
3432
+ children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-row items-center size-full", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-[8px] p-[14px] relative w-full", children: [
3433
+ /* @__PURE__ */ jsxRuntime.jsx(
3434
+ "p",
3435
+ {
3436
+ className: cn(
3437
+ "flex-1 min-w-0 min-h-[1px] leading-[20px] not-italic overflow-hidden text-[14px] text-ellipsis whitespace-nowrap",
3438
+ isSelected ? "text-primary-action" : "text-foreground"
3439
+ ),
3440
+ children: opt.label
3441
+ }
3442
+ ),
3443
+ /* @__PURE__ */ jsxRuntime.jsx(
3444
+ "div",
3445
+ {
3446
+ className: cn(
3447
+ "shrink-0 w-[16px] h-[16px] rounded-[3px] flex items-center justify-center transition-colors duration-100",
3448
+ "bg-transparent"
3449
+ ),
3450
+ children: isSelected && /* @__PURE__ */ jsxRuntime.jsx(
3451
+ react.Check,
3452
+ {
3453
+ size: 12,
3454
+ weight: "bold",
3455
+ className: "text-primary-action"
3456
+ }
3457
+ )
3458
+ }
3459
+ )
3460
+ ] }) })
3461
+ },
3462
+ opt.value
3463
+ );
3464
+ }) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full shrink-0 bg-popover", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-row items-center size-full", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center p-[14px] relative w-full", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "flex-1 min-w-0 min-h-[1px] leading-[20px] not-italic text-[14px] text-disabled", children: "No results found" }) }) }) })
3465
+ }
3466
+ )
3467
+ }
3468
+ )
3469
+ ]
3470
3470
  }
3471
3471
  ),
3472
3472
  showBelow && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-start px-[4px] text-[12px] leading-[16px]", children: /* @__PURE__ */ jsxRuntime.jsx(