@x-plat/design-system 0.12.0 → 0.14.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.
Files changed (72) hide show
  1. package/dist/{breakpoints-DsXkJgdl.d.cts → breakpoints-CKkNxA-y.d.cts} +1 -1
  2. package/dist/{breakpoints-DsXkJgdl.d.ts → breakpoints-CKkNxA-y.d.ts} +1 -1
  3. package/dist/components/AutoResizeTextArea/index.cjs +2 -2
  4. package/dist/components/AutoResizeTextArea/index.js +2 -2
  5. package/dist/components/Badge/index.d.cts +1 -1
  6. package/dist/components/Badge/index.d.ts +1 -1
  7. package/dist/components/ChatInput/index.cjs +2 -2
  8. package/dist/components/ChatInput/index.js +2 -2
  9. package/dist/components/CheckBox/index.cjs +2 -2
  10. package/dist/components/CheckBox/index.js +2 -2
  11. package/dist/components/DatePicker/index.cjs +109 -75
  12. package/dist/components/DatePicker/index.d.cts +19 -0
  13. package/dist/components/DatePicker/index.d.ts +19 -0
  14. package/dist/components/DatePicker/index.js +109 -75
  15. package/dist/components/Editor/index.css +3 -0
  16. package/dist/components/FieldMessage/index.cjs +2 -2
  17. package/dist/components/FieldMessage/index.d.cts +8 -0
  18. package/dist/components/FieldMessage/index.d.ts +8 -0
  19. package/dist/components/FieldMessage/index.js +2 -2
  20. package/dist/components/FileUpload/index.cjs +10 -6
  21. package/dist/components/FileUpload/index.d.cts +15 -2
  22. package/dist/components/FileUpload/index.d.ts +15 -2
  23. package/dist/components/FileUpload/index.js +10 -6
  24. package/dist/components/ImageSelector/index.cjs +7 -6
  25. package/dist/components/ImageSelector/index.d.cts +15 -2
  26. package/dist/components/ImageSelector/index.d.ts +15 -2
  27. package/dist/components/ImageSelector/index.js +7 -6
  28. package/dist/components/Input/index.cjs +2 -2
  29. package/dist/components/Input/index.d.cts +4 -0
  30. package/dist/components/Input/index.d.ts +4 -0
  31. package/dist/components/Input/index.js +2 -2
  32. package/dist/components/Radio/index.cjs +2 -2
  33. package/dist/components/Radio/index.js +2 -2
  34. package/dist/components/Select/index.cjs +2 -2
  35. package/dist/components/Select/index.d.cts +1 -2
  36. package/dist/components/Select/index.d.ts +1 -2
  37. package/dist/components/Select/index.js +2 -2
  38. package/dist/components/Switch/index.cjs +2 -2
  39. package/dist/components/Switch/index.js +2 -2
  40. package/dist/components/TextArea/index.cjs +2 -2
  41. package/dist/components/TextArea/index.js +2 -2
  42. package/dist/components/TimePicker/index.cjs +2 -2
  43. package/dist/components/TimePicker/index.js +2 -2
  44. package/dist/components/ToggleChip/index.cjs +69 -0
  45. package/dist/components/ToggleChip/index.css +102 -0
  46. package/dist/components/ToggleChip/index.d.cts +37 -0
  47. package/dist/components/ToggleChip/index.d.ts +37 -0
  48. package/dist/components/ToggleChip/index.js +42 -0
  49. package/dist/components/index.cjs +184 -119
  50. package/dist/components/index.css +40 -0
  51. package/dist/components/index.d.cts +2 -1
  52. package/dist/components/index.d.ts +2 -1
  53. package/dist/components/index.js +174 -110
  54. package/dist/index.cjs +203 -138
  55. package/dist/index.css +40 -0
  56. package/dist/index.d.cts +4 -3
  57. package/dist/index.d.ts +4 -3
  58. package/dist/index.js +191 -127
  59. package/dist/layout/Grid/Item/index.d.cts +1 -1
  60. package/dist/layout/Grid/Item/index.d.ts +1 -1
  61. package/dist/layout/Grid/index.d.cts +1 -1
  62. package/dist/layout/Grid/index.d.ts +1 -1
  63. package/dist/layout/index.d.cts +1 -1
  64. package/dist/layout/index.d.ts +1 -1
  65. package/dist/tokens/index.d.cts +1 -1
  66. package/dist/tokens/index.d.ts +1 -1
  67. package/guidelines/Guidelines.md +13 -1
  68. package/guidelines/MIGRATION.md +297 -0
  69. package/guidelines/components/chip-tag.md +75 -2
  70. package/guidelines/components/datepicker.md +26 -0
  71. package/guidelines/components/file-media.md +21 -4
  72. package/package.json +1 -1
@@ -26,7 +26,7 @@ export { Input, PasswordInput } from './Input/index.cjs';
26
26
  export { Link } from './Link/index.cjs';
27
27
  export { LinkButton } from './LinkButton/index.cjs';
28
28
  export { Modal } from './Modal/index.cjs';
29
- export { NotificationBadge as Badge, NotificationBadge } from './NotificationBadge/index.cjs';
29
+ export { Badge, Badge as NotificationBadge } from './NotificationBadge/index.cjs';
30
30
  export { Pagination } from './Pagination/index.cjs';
31
31
  export { PopOver } from './PopOver/index.cjs';
32
32
  export { Progress } from './Progress/index.cjs';
@@ -44,6 +44,7 @@ export { Tag } from './Tag/index.cjs';
44
44
  export { TextArea } from './TextArea/index.cjs';
45
45
  export { TimePicker } from './TimePicker/index.cjs';
46
46
  export { ToastProvider, useToast } from './Toast/index.cjs';
47
+ export { ToggleChip } from './ToggleChip/index.cjs';
47
48
  export { Tooltip } from './Tooltip/index.cjs';
48
49
  export { Video, VideoProps } from './Video/index.cjs';
49
50
  import 'react';
@@ -26,7 +26,7 @@ export { Input, PasswordInput } from './Input/index.js';
26
26
  export { Link } from './Link/index.js';
27
27
  export { LinkButton } from './LinkButton/index.js';
28
28
  export { Modal } from './Modal/index.js';
29
- export { NotificationBadge as Badge, NotificationBadge } from './NotificationBadge/index.js';
29
+ export { Badge, Badge as NotificationBadge } from './NotificationBadge/index.js';
30
30
  export { Pagination } from './Pagination/index.js';
31
31
  export { PopOver } from './PopOver/index.js';
32
32
  export { Progress } from './Progress/index.js';
@@ -44,6 +44,7 @@ export { Tag } from './Tag/index.js';
44
44
  export { TextArea } from './TextArea/index.js';
45
45
  export { TimePicker } from './TimePicker/index.js';
46
46
  export { ToastProvider, useToast } from './Toast/index.js';
47
+ export { ToggleChip } from './ToggleChip/index.js';
47
48
  export { Tooltip } from './Tooltip/index.js';
48
49
  export { Video, VideoProps } from './Video/index.js';
49
50
  import 'react';
@@ -1532,11 +1532,11 @@ var FieldMessage = (props) => {
1532
1532
  FieldMessage.displayName = "FieldMessage";
1533
1533
  var FieldMessage_default = FieldMessage;
1534
1534
  var Field = (props) => {
1535
- const { label, required = false, htmlFor, validations, children } = props;
1535
+ const { label, required = false, htmlFor, labelId, validations, children } = props;
1536
1536
  const hasMessages = !!validations && validations.length > 0;
1537
1537
  if (!label && !hasMessages) return /* @__PURE__ */ jsx297(Fragment, { children });
1538
1538
  return /* @__PURE__ */ jsxs191("div", { className: "lib-xplat-field", children: [
1539
- label && /* @__PURE__ */ jsxs191("label", { className: "lib-xplat-field-label", htmlFor, children: [
1539
+ label && /* @__PURE__ */ jsxs191("label", { className: "lib-xplat-field-label", id: labelId, htmlFor, children: [
1540
1540
  label,
1541
1541
  required && /* @__PURE__ */ jsx297("span", { className: "required", "aria-hidden": "true", children: "*" })
1542
1542
  ] }),
@@ -3303,8 +3303,12 @@ var SingleDatePicker = (props) => {
3303
3303
  highlightDates = [],
3304
3304
  locale = "ko",
3305
3305
  rangeStart,
3306
- rangeEnd
3306
+ rangeEnd,
3307
+ label,
3308
+ required,
3309
+ validations
3307
3310
  } = props;
3311
+ const labelId = React12.useId();
3308
3312
  const initialYear = value?.getFullYear();
3309
3313
  const initialMonth = value?.getMonth();
3310
3314
  const { year, month, days, goToPrevMonth, goToNextMonth, setYear, setMonth } = useCalendar(
@@ -3367,10 +3371,12 @@ var SingleDatePicker = (props) => {
3367
3371
  const monthLabels = MONTH_LABELS[locale];
3368
3372
  const titleText = pickerMode === "days" ? locale === "ko" ? `${year}\uB144 ${monthLabels[month]}` : `${monthLabels[month]} ${year}` : pickerMode === "months" ? `${year}` : `${yearRangeStart} - ${yearRangeStart + 11}`;
3369
3373
  const hasRange = rangeStart != null && rangeEnd != null;
3370
- return /* @__PURE__ */ jsxs200(
3374
+ const calendar = /* @__PURE__ */ jsxs200(
3371
3375
  "div",
3372
3376
  {
3373
3377
  className: clsx_default("lib-xplat-datepicker", "single"),
3378
+ role: "group",
3379
+ "aria-labelledby": label ? labelId : void 0,
3374
3380
  children: [
3375
3381
  /* @__PURE__ */ jsxs200("div", { className: "datepicker-header", children: [
3376
3382
  /* @__PURE__ */ jsx314("button", { className: "datepicker-nav", onClick: handlePrev, type: "button", children: /* @__PURE__ */ jsx314(ChevronLeftIcon_default, {}) }),
@@ -3391,18 +3397,18 @@ var SingleDatePicker = (props) => {
3391
3397
  y
3392
3398
  );
3393
3399
  }) }),
3394
- pickerMode === "months" && /* @__PURE__ */ jsx314("div", { className: "datepicker-picker-grid", children: monthLabels.map((label, i) => /* @__PURE__ */ jsx314(
3400
+ pickerMode === "months" && /* @__PURE__ */ jsx314("div", { className: "datepicker-picker-grid", children: monthLabels.map((label2, i) => /* @__PURE__ */ jsx314(
3395
3401
  "button",
3396
3402
  {
3397
3403
  type: "button",
3398
3404
  className: clsx_default("datepicker-picker-cell", i === month && "active"),
3399
3405
  onClick: () => handleMonthSelect(i),
3400
- children: label
3406
+ children: label2
3401
3407
  },
3402
3408
  i
3403
3409
  )) }),
3404
3410
  pickerMode === "days" && /* @__PURE__ */ jsxs200(Fragment4, { children: [
3405
- /* @__PURE__ */ jsx314("div", { className: "datepicker-weekdays", children: weekdays.map((label, i) => /* @__PURE__ */ jsx314(
3411
+ /* @__PURE__ */ jsx314("div", { className: "datepicker-weekdays", children: weekdays.map((label2, i) => /* @__PURE__ */ jsx314(
3406
3412
  "div",
3407
3413
  {
3408
3414
  className: clsx_default(
@@ -3410,9 +3416,9 @@ var SingleDatePicker = (props) => {
3410
3416
  i === 0 && "sunday",
3411
3417
  i === 6 && "saturday"
3412
3418
  ),
3413
- children: label
3419
+ children: label2
3414
3420
  },
3415
- label
3421
+ label2
3416
3422
  )) }),
3417
3423
  /* @__PURE__ */ jsx314("div", { className: "datepicker-grid", children: days.map((day, idx) => {
3418
3424
  const t = day.date.getTime();
@@ -3444,6 +3450,7 @@ var SingleDatePicker = (props) => {
3444
3450
  ]
3445
3451
  }
3446
3452
  );
3453
+ return /* @__PURE__ */ jsx314(Field, { label, required, labelId, validations, children: calendar });
3447
3454
  };
3448
3455
  SingleDatePicker.displayName = "SingleDatePicker";
3449
3456
  var SingleDatePicker_default = SingleDatePicker;
@@ -3458,7 +3465,18 @@ var formatDate = (date) => {
3458
3465
  return `${y}/${m}/${d}`;
3459
3466
  };
3460
3467
  var InputDatePicker = (props) => {
3461
- const { value, onChange, minDate, maxDate, disabled, locale = "ko", placeholder } = props;
3468
+ const {
3469
+ value,
3470
+ onChange,
3471
+ minDate,
3472
+ maxDate,
3473
+ disabled,
3474
+ locale = "ko",
3475
+ placeholder,
3476
+ label,
3477
+ required,
3478
+ validations
3479
+ } = props;
3462
3480
  const [isOpen, setIsOpen] = React13.useState(false);
3463
3481
  const [tempDate, setTempDate] = React13.useState(value ?? /* @__PURE__ */ new Date());
3464
3482
  const handleOpen = () => {
@@ -3484,6 +3502,9 @@ var InputDatePicker = (props) => {
3484
3502
  placeholder,
3485
3503
  suffix: /* @__PURE__ */ jsx315(CalenderIcon_default, {}),
3486
3504
  disabled,
3505
+ label,
3506
+ required,
3507
+ validations,
3487
3508
  readOnly: true
3488
3509
  }
3489
3510
  ) }),
@@ -3615,8 +3636,12 @@ var RangePicker = (props) => {
3615
3636
  onChange,
3616
3637
  minDate,
3617
3638
  maxDate,
3618
- locale = "ko"
3639
+ locale = "ko",
3640
+ label,
3641
+ required,
3642
+ validations
3619
3643
  } = props;
3644
+ const labelId = React16.useId();
3620
3645
  const [activeTab, setActiveTab] = React16.useState("start");
3621
3646
  const handleStartChange = (date) => {
3622
3647
  if (!date) return;
@@ -3630,70 +3655,79 @@ var RangePicker = (props) => {
3630
3655
  };
3631
3656
  const startMaxDate = maxDate && endDate < maxDate ? endDate : endDate;
3632
3657
  const endMinDate = minDate && startDate > minDate ? startDate : startDate;
3633
- return /* @__PURE__ */ jsxs203("div", { className: clsx_default("lib-xplat-datepicker", "range"), children: [
3634
- /* @__PURE__ */ jsx318("div", { className: "datepicker-range-tabs", children: /* @__PURE__ */ jsx318(
3635
- Tab_default,
3636
- {
3637
- activeIndex: activeTab === "start" ? 0 : 1,
3638
- tabs: [
3639
- { value: "start", title: locale === "ko" ? "\uC2DC\uC791\uC77C" : "Start" },
3640
- { value: "end", title: locale === "ko" ? "\uC885\uB8CC\uC77C" : "End" }
3641
- ],
3642
- onChange: (tab) => setActiveTab(tab.value),
3643
- type: "toggle",
3644
- size: "sm"
3645
- }
3646
- ) }),
3647
- /* @__PURE__ */ jsxs203("div", { className: "datepicker-range-panels", children: [
3648
- /* @__PURE__ */ jsx318(
3649
- SingleDatePicker_default,
3650
- {
3651
- value: startDate,
3652
- onChange: handleStartChange,
3653
- minDate,
3654
- maxDate: startMaxDate,
3655
- rangeStart: startDate,
3656
- rangeEnd: endDate,
3657
- locale
3658
- }
3659
- ),
3660
- /* @__PURE__ */ jsx318(
3661
- SingleDatePicker_default,
3662
- {
3663
- value: endDate,
3664
- onChange: handleEndChange,
3665
- minDate: endMinDate,
3666
- maxDate,
3667
- rangeStart: startDate,
3668
- rangeEnd: endDate,
3669
- locale
3670
- }
3671
- )
3672
- ] }),
3673
- /* @__PURE__ */ jsx318("div", { className: "datepicker-range-mobile", children: activeTab === "start" ? /* @__PURE__ */ jsx318(
3674
- SingleDatePicker_default,
3675
- {
3676
- value: startDate,
3677
- onChange: handleStartChange,
3678
- minDate,
3679
- maxDate: startMaxDate,
3680
- rangeStart: startDate,
3681
- rangeEnd: endDate,
3682
- locale
3683
- }
3684
- ) : /* @__PURE__ */ jsx318(
3685
- SingleDatePicker_default,
3686
- {
3687
- value: endDate,
3688
- onChange: handleEndChange,
3689
- minDate: endMinDate,
3690
- maxDate,
3691
- rangeStart: startDate,
3692
- rangeEnd: endDate,
3693
- locale
3694
- }
3695
- ) })
3696
- ] });
3658
+ const calendar = /* @__PURE__ */ jsxs203(
3659
+ "div",
3660
+ {
3661
+ className: clsx_default("lib-xplat-datepicker", "range"),
3662
+ role: "group",
3663
+ "aria-labelledby": label ? labelId : void 0,
3664
+ children: [
3665
+ /* @__PURE__ */ jsx318("div", { className: "datepicker-range-tabs", children: /* @__PURE__ */ jsx318(
3666
+ Tab_default,
3667
+ {
3668
+ activeIndex: activeTab === "start" ? 0 : 1,
3669
+ tabs: [
3670
+ { value: "start", title: locale === "ko" ? "\uC2DC\uC791\uC77C" : "Start" },
3671
+ { value: "end", title: locale === "ko" ? "\uC885\uB8CC\uC77C" : "End" }
3672
+ ],
3673
+ onChange: (tab) => setActiveTab(tab.value),
3674
+ type: "toggle",
3675
+ size: "sm"
3676
+ }
3677
+ ) }),
3678
+ /* @__PURE__ */ jsxs203("div", { className: "datepicker-range-panels", children: [
3679
+ /* @__PURE__ */ jsx318(
3680
+ SingleDatePicker_default,
3681
+ {
3682
+ value: startDate,
3683
+ onChange: handleStartChange,
3684
+ minDate,
3685
+ maxDate: startMaxDate,
3686
+ rangeStart: startDate,
3687
+ rangeEnd: endDate,
3688
+ locale
3689
+ }
3690
+ ),
3691
+ /* @__PURE__ */ jsx318(
3692
+ SingleDatePicker_default,
3693
+ {
3694
+ value: endDate,
3695
+ onChange: handleEndChange,
3696
+ minDate: endMinDate,
3697
+ maxDate,
3698
+ rangeStart: startDate,
3699
+ rangeEnd: endDate,
3700
+ locale
3701
+ }
3702
+ )
3703
+ ] }),
3704
+ /* @__PURE__ */ jsx318("div", { className: "datepicker-range-mobile", children: activeTab === "start" ? /* @__PURE__ */ jsx318(
3705
+ SingleDatePicker_default,
3706
+ {
3707
+ value: startDate,
3708
+ onChange: handleStartChange,
3709
+ minDate,
3710
+ maxDate: startMaxDate,
3711
+ rangeStart: startDate,
3712
+ rangeEnd: endDate,
3713
+ locale
3714
+ }
3715
+ ) : /* @__PURE__ */ jsx318(
3716
+ SingleDatePicker_default,
3717
+ {
3718
+ value: endDate,
3719
+ onChange: handleEndChange,
3720
+ minDate: endMinDate,
3721
+ maxDate,
3722
+ rangeStart: startDate,
3723
+ rangeEnd: endDate,
3724
+ locale
3725
+ }
3726
+ ) })
3727
+ ]
3728
+ }
3729
+ );
3730
+ return /* @__PURE__ */ jsx318(Field, { label, required, labelId, validations, children: calendar });
3697
3731
  };
3698
3732
  RangePicker.displayName = "RangePicker";
3699
3733
  var RangePicker_default = RangePicker;
@@ -5466,10 +5500,13 @@ var FileUpload = (props) => {
5466
5500
  multiple = false,
5467
5501
  maxSize,
5468
5502
  onChange,
5469
- label = "\uD30C\uC77C\uC744 \uB4DC\uB798\uADF8\uD558\uAC70\uB098 \uD074\uB9AD\uD558\uC5EC \uC5C5\uB85C\uB4DC",
5503
+ placeholder = "\uD30C\uC77C\uC744 \uB4DC\uB798\uADF8\uD558\uAC70\uB098 \uD074\uB9AD\uD558\uC5EC \uC5C5\uB85C\uB4DC",
5470
5504
  description,
5471
- validations
5505
+ validations,
5506
+ label,
5507
+ required
5472
5508
  } = props;
5509
+ const fieldId = React23.useId();
5473
5510
  const [isDragOver, setIsDragOver] = React23.useState(false);
5474
5511
  const inputRef = React23.useRef(null);
5475
5512
  const handleFiles = (fileList) => {
@@ -5514,6 +5551,7 @@ var FileUpload = (props) => {
5514
5551
  "input",
5515
5552
  {
5516
5553
  ref: inputRef,
5554
+ id: fieldId,
5517
5555
  type: "file",
5518
5556
  accept,
5519
5557
  multiple,
@@ -5522,12 +5560,12 @@ var FileUpload = (props) => {
5522
5560
  }
5523
5561
  ),
5524
5562
  /* @__PURE__ */ jsx325("div", { className: "upload-icon", children: /* @__PURE__ */ jsx325(UploadIcon_default, {}) }),
5525
- /* @__PURE__ */ jsx325("p", { className: "upload-label", children: label }),
5563
+ /* @__PURE__ */ jsx325("p", { className: "upload-label", children: placeholder }),
5526
5564
  description && /* @__PURE__ */ jsx325("p", { className: "upload-description", children: description })
5527
5565
  ]
5528
5566
  }
5529
5567
  );
5530
- return /* @__PURE__ */ jsx325(Field, { validations, children: control });
5568
+ return /* @__PURE__ */ jsx325(Field, { label, required, htmlFor: fieldId, validations, children: control });
5531
5569
  };
5532
5570
  FileUpload.displayName = "FileUpload";
5533
5571
  var FileUpload_default = FileUpload;
@@ -5670,7 +5708,8 @@ var HtmlTypeWriter_default = HtmlTypeWriter;
5670
5708
  import React26 from "react";
5671
5709
  import { jsx as jsx327, jsxs as jsxs210 } from "react/jsx-runtime";
5672
5710
  var ImageSelector = (props) => {
5673
- const { value, label, onChange, validations } = props;
5711
+ const { value, placeholder, onChange, validations, label, required } = props;
5712
+ const fieldId = React26.useId();
5674
5713
  const [previewUrl, setPreviewUrl] = React26.useState();
5675
5714
  React26.useEffect(() => {
5676
5715
  if (!value) {
@@ -5700,7 +5739,7 @@ var ImageSelector = (props) => {
5700
5739
  {
5701
5740
  type: "file",
5702
5741
  accept: "image/*",
5703
- id: "image-input",
5742
+ id: fieldId,
5704
5743
  onChange: handleFileChange,
5705
5744
  ref: inputRef,
5706
5745
  "aria-invalid": hasError(validations) || void 0
@@ -5712,10 +5751,10 @@ var ImageSelector = (props) => {
5712
5751
  ] }),
5713
5752
  /* @__PURE__ */ jsx327("div", { className: "content", children: previewUrl ? /* @__PURE__ */ jsx327("img", { src: previewUrl, alt: "preview" }) : /* @__PURE__ */ jsxs210("div", { className: "skeleton", onClick: handleOpenFileDialog, children: [
5714
5753
  /* @__PURE__ */ jsx327("div", { className: "icon-wrapper", children: /* @__PURE__ */ jsx327(ImageIcon_default, {}) }),
5715
- /* @__PURE__ */ jsx327("div", { className: "label", children: label || "\uC774\uBBF8\uC9C0 \uCD94\uAC00\uD558\uAE30" })
5754
+ /* @__PURE__ */ jsx327("div", { className: "label", children: placeholder || "\uC774\uBBF8\uC9C0 \uCD94\uAC00\uD558\uAE30" })
5716
5755
  ] }) })
5717
5756
  ] });
5718
- return /* @__PURE__ */ jsx327(Field, { validations, children: control });
5757
+ return /* @__PURE__ */ jsx327(Field, { label, required, htmlFor: fieldId, validations, children: control });
5719
5758
  };
5720
5759
  ImageSelector.displayName = "ImageSelector";
5721
5760
  var ImageSelector_default = ImageSelector;
@@ -7267,9 +7306,33 @@ var ToastProvider = ({
7267
7306
  };
7268
7307
  ToastProvider.displayName = "ToastProvider";
7269
7308
 
7309
+ // src/components/ToggleChip/ToggleChip.tsx
7310
+ import { jsx as jsx353 } from "react/jsx-runtime";
7311
+ var ToggleChip = (props) => {
7312
+ const { children, selected = false, onClick, disabled = false, size = "md" } = props;
7313
+ return /* @__PURE__ */ jsx353(
7314
+ "button",
7315
+ {
7316
+ type: "button",
7317
+ className: clsx_default(
7318
+ "lib-xplat-chip",
7319
+ "lib-xplat-toggle-chip",
7320
+ size,
7321
+ selected ? "selected" : "unselected"
7322
+ ),
7323
+ "aria-pressed": selected,
7324
+ disabled,
7325
+ onClick,
7326
+ children
7327
+ }
7328
+ );
7329
+ };
7330
+ ToggleChip.displayName = "ToggleChip";
7331
+ var ToggleChip_default = ToggleChip;
7332
+
7270
7333
  // src/components/Tooltip/Tooltip.tsx
7271
7334
  import React42 from "react";
7272
- import { Fragment as Fragment6, jsx as jsx353, jsxs as jsxs224 } from "react/jsx-runtime";
7335
+ import { Fragment as Fragment6, jsx as jsx354, jsxs as jsxs224 } from "react/jsx-runtime";
7273
7336
  var OFFSET = 12;
7274
7337
  var GAP = 8;
7275
7338
  var SHOW_DELAY = 300;
@@ -7374,7 +7437,7 @@ var Tooltip = (props) => {
7374
7437
  window.clearTimeout(delayTimer.current);
7375
7438
  cancelAnimationFrame(rafRef.current);
7376
7439
  }, []);
7377
- if (!title && !description) return /* @__PURE__ */ jsx353(Fragment6, { children });
7440
+ if (!title && !description) return /* @__PURE__ */ jsx354(Fragment6, { children });
7378
7441
  return /* @__PURE__ */ jsxs224(
7379
7442
  "div",
7380
7443
  {
@@ -7388,7 +7451,7 @@ var Tooltip = (props) => {
7388
7451
  onBlur: close,
7389
7452
  children: [
7390
7453
  children,
7391
- visible && /* @__PURE__ */ jsx353(Portal_default, { children: /* @__PURE__ */ jsxs224(
7454
+ visible && /* @__PURE__ */ jsx354(Portal_default, { children: /* @__PURE__ */ jsxs224(
7392
7455
  "div",
7393
7456
  {
7394
7457
  ref: tooltipRef,
@@ -7396,8 +7459,8 @@ var Tooltip = (props) => {
7396
7459
  className: clsx_default("lib-xplat-tooltip", shape),
7397
7460
  style: { position: "fixed", left: pos.left, top: pos.top },
7398
7461
  children: [
7399
- title && /* @__PURE__ */ jsx353("div", { className: "tooltip-title", children: title }),
7400
- description && /* @__PURE__ */ jsx353("div", { className: "tooltip-desc", children: description })
7462
+ title && /* @__PURE__ */ jsx354("div", { className: "tooltip-title", children: title }),
7463
+ description && /* @__PURE__ */ jsx354("div", { className: "tooltip-desc", children: description })
7401
7464
  ]
7402
7465
  }
7403
7466
  ) })
@@ -7410,10 +7473,10 @@ var Tooltip_default = Tooltip;
7410
7473
 
7411
7474
  // src/components/Video/Video.tsx
7412
7475
  import React43 from "react";
7413
- import { jsx as jsx354, jsxs as jsxs225 } from "react/jsx-runtime";
7476
+ import { jsx as jsx355, jsxs as jsxs225 } from "react/jsx-runtime";
7414
7477
  var PipIcon = () => /* @__PURE__ */ jsxs225("svg", { viewBox: "0 0 24 24", width: "1em", height: "1em", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", children: [
7415
- /* @__PURE__ */ jsx354("rect", { x: "3", y: "5", width: "18", height: "14", rx: "2" }),
7416
- /* @__PURE__ */ jsx354("rect", { x: "12", y: "11", width: "7", height: "6", rx: "1", fill: "currentColor" })
7478
+ /* @__PURE__ */ jsx355("rect", { x: "3", y: "5", width: "18", height: "14", rx: "2" }),
7479
+ /* @__PURE__ */ jsx355("rect", { x: "12", y: "11", width: "7", height: "6", rx: "1", fill: "currentColor" })
7417
7480
  ] });
7418
7481
  var formatTime = (sec) => {
7419
7482
  if (!Number.isFinite(sec) || sec < 0) return "0:00";
@@ -7594,7 +7657,7 @@ var Video = React43.forwardRef((props, ref) => {
7594
7657
  ref: containerRef,
7595
7658
  className: clsx_default("lib-xplat-video", showControls && "has-controls"),
7596
7659
  children: [
7597
- /* @__PURE__ */ jsx354(
7660
+ /* @__PURE__ */ jsx355(
7598
7661
  "video",
7599
7662
  {
7600
7663
  ref: setRefs,
@@ -7615,7 +7678,7 @@ var Video = React43.forwardRef((props, ref) => {
7615
7678
  children
7616
7679
  }
7617
7680
  ),
7618
- showCenterPlay && /* @__PURE__ */ jsx354(
7681
+ showCenterPlay && /* @__PURE__ */ jsx355(
7619
7682
  "button",
7620
7683
  {
7621
7684
  type: "button",
@@ -7627,11 +7690,11 @@ var Video = React43.forwardRef((props, ref) => {
7627
7690
  onClick: togglePlay,
7628
7691
  "aria-label": isPlaying ? "\uC77C\uC2DC\uC815\uC9C0" : "\uC7AC\uC0DD",
7629
7692
  tabIndex: -1,
7630
- children: /* @__PURE__ */ jsx354("span", { className: "center-play-icon", children: /* @__PURE__ */ jsx354(PlayCircleIcon_default, {}) })
7693
+ children: /* @__PURE__ */ jsx355("span", { className: "center-play-icon", children: /* @__PURE__ */ jsx355(PlayCircleIcon_default, {}) })
7631
7694
  }
7632
7695
  ),
7633
7696
  showControls && /* @__PURE__ */ jsxs225("div", { className: "controls", onClick: (e) => e.stopPropagation(), children: [
7634
- /* @__PURE__ */ jsx354(
7697
+ /* @__PURE__ */ jsx355(
7635
7698
  "input",
7636
7699
  {
7637
7700
  type: "range",
@@ -7649,28 +7712,28 @@ var Video = React43.forwardRef((props, ref) => {
7649
7712
  }
7650
7713
  ),
7651
7714
  /* @__PURE__ */ jsxs225("div", { className: "controls-row", children: [
7652
- /* @__PURE__ */ jsx354(
7715
+ /* @__PURE__ */ jsx355(
7653
7716
  "button",
7654
7717
  {
7655
7718
  type: "button",
7656
7719
  className: "control-btn",
7657
7720
  onClick: togglePlay,
7658
7721
  "aria-label": isPlaying ? "\uC77C\uC2DC\uC815\uC9C0" : "\uC7AC\uC0DD",
7659
- children: isPlaying ? /* @__PURE__ */ jsx354(PauseIcon_default, {}) : /* @__PURE__ */ jsx354(PlayIcon_default, {})
7722
+ children: isPlaying ? /* @__PURE__ */ jsx355(PauseIcon_default, {}) : /* @__PURE__ */ jsx355(PlayIcon_default, {})
7660
7723
  }
7661
7724
  ),
7662
7725
  /* @__PURE__ */ jsxs225("div", { className: "volume-group", children: [
7663
- /* @__PURE__ */ jsx354(
7726
+ /* @__PURE__ */ jsx355(
7664
7727
  "button",
7665
7728
  {
7666
7729
  type: "button",
7667
7730
  className: "control-btn",
7668
7731
  onClick: toggleMute,
7669
7732
  "aria-label": isMuted ? "\uC74C\uC18C\uAC70 \uD574\uC81C" : "\uC74C\uC18C\uAC70",
7670
- children: /* @__PURE__ */ jsx354(VolumeGlyph, {})
7733
+ children: /* @__PURE__ */ jsx355(VolumeGlyph, {})
7671
7734
  }
7672
7735
  ),
7673
- /* @__PURE__ */ jsx354(
7736
+ /* @__PURE__ */ jsx355(
7674
7737
  "input",
7675
7738
  {
7676
7739
  type: "range",
@@ -7690,7 +7753,7 @@ var Video = React43.forwardRef((props, ref) => {
7690
7753
  " / ",
7691
7754
  formatTime(duration)
7692
7755
  ] }),
7693
- /* @__PURE__ */ jsx354("div", { className: "controls-spacer" }),
7756
+ /* @__PURE__ */ jsx355("div", { className: "controls-spacer" }),
7694
7757
  playbackRates && playbackRates.length > 0 && /* @__PURE__ */ jsxs225("div", { className: clsx_default("rate-group", rateMenuOpen && "is-open"), children: [
7695
7758
  /* @__PURE__ */ jsxs225(
7696
7759
  "button",
@@ -7706,7 +7769,7 @@ var Video = React43.forwardRef((props, ref) => {
7706
7769
  ]
7707
7770
  }
7708
7771
  ),
7709
- rateMenuOpen && /* @__PURE__ */ jsx354("ul", { className: "rate-menu", role: "menu", children: playbackRates.map((r2) => /* @__PURE__ */ jsx354("li", { children: /* @__PURE__ */ jsxs225(
7772
+ rateMenuOpen && /* @__PURE__ */ jsx355("ul", { className: "rate-menu", role: "menu", children: playbackRates.map((r2) => /* @__PURE__ */ jsx355("li", { children: /* @__PURE__ */ jsxs225(
7710
7773
  "button",
7711
7774
  {
7712
7775
  type: "button",
@@ -7720,7 +7783,7 @@ var Video = React43.forwardRef((props, ref) => {
7720
7783
  }
7721
7784
  ) }, r2)) })
7722
7785
  ] }),
7723
- showCaptions && /* @__PURE__ */ jsx354(
7786
+ showCaptions && /* @__PURE__ */ jsx355(
7724
7787
  "button",
7725
7788
  {
7726
7789
  type: "button",
@@ -7728,37 +7791,37 @@ var Video = React43.forwardRef((props, ref) => {
7728
7791
  onClick: toggleCaptions,
7729
7792
  "aria-label": captionsOn ? "\uC790\uB9C9 \uB044\uAE30" : "\uC790\uB9C9 \uCF1C\uAE30",
7730
7793
  "aria-pressed": captionsOn,
7731
- children: /* @__PURE__ */ jsx354(TypeIcon_default, {})
7794
+ children: /* @__PURE__ */ jsx355(TypeIcon_default, {})
7732
7795
  }
7733
7796
  ),
7734
- showPip && pipSupported && /* @__PURE__ */ jsx354(
7797
+ showPip && pipSupported && /* @__PURE__ */ jsx355(
7735
7798
  "button",
7736
7799
  {
7737
7800
  type: "button",
7738
7801
  className: clsx_default("control-btn", isPip && "is-active"),
7739
7802
  onClick: togglePip,
7740
7803
  "aria-label": isPip ? "PIP \uC885\uB8CC" : "PIP",
7741
- children: /* @__PURE__ */ jsx354(PipIcon, {})
7804
+ children: /* @__PURE__ */ jsx355(PipIcon, {})
7742
7805
  }
7743
7806
  ),
7744
- showDownload && /* @__PURE__ */ jsx354(
7807
+ showDownload && /* @__PURE__ */ jsx355(
7745
7808
  "a",
7746
7809
  {
7747
7810
  className: "control-btn",
7748
7811
  href: src,
7749
7812
  download: downloadFileName ?? true,
7750
7813
  "aria-label": "\uB2E4\uC6B4\uB85C\uB4DC",
7751
- children: /* @__PURE__ */ jsx354(DownloadIcon_default, {})
7814
+ children: /* @__PURE__ */ jsx355(DownloadIcon_default, {})
7752
7815
  }
7753
7816
  ),
7754
- /* @__PURE__ */ jsx354(
7817
+ /* @__PURE__ */ jsx355(
7755
7818
  "button",
7756
7819
  {
7757
7820
  type: "button",
7758
7821
  className: "control-btn",
7759
7822
  onClick: toggleFullscreen,
7760
7823
  "aria-label": isFullscreen ? "\uC804\uCCB4\uD654\uBA74 \uC885\uB8CC" : "\uC804\uCCB4\uD654\uBA74",
7761
- children: isFullscreen ? /* @__PURE__ */ jsx354(MinimizeIcon_default, {}) : /* @__PURE__ */ jsx354(MaximizeIcon_default, {})
7824
+ children: isFullscreen ? /* @__PURE__ */ jsx355(MinimizeIcon_default, {}) : /* @__PURE__ */ jsx355(MaximizeIcon_default, {})
7762
7825
  }
7763
7826
  )
7764
7827
  ] })
@@ -7829,6 +7892,7 @@ export {
7829
7892
  TextArea_default as TextArea,
7830
7893
  TimePicker_default as TimePicker,
7831
7894
  ToastProvider,
7895
+ ToggleChip_default as ToggleChip,
7832
7896
  Tooltip_default as Tooltip,
7833
7897
  Video_default as Video,
7834
7898
  hasError,