@delightui/components 0.1.82 → 0.1.83

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.
@@ -295,7 +295,7 @@ declare const usePresenter: (props: CheckboxProps) => {
295
295
  };
296
296
  labelAlignment: import("./Checkbox.types").CheckboxLabelAlignmentEnum;
297
297
  disabled: boolean;
298
- isChecked: boolean | undefined;
298
+ isChecked: boolean;
299
299
  required: boolean | undefined;
300
300
  name: string | undefined;
301
301
  invalid: boolean;
@@ -0,0 +1,2 @@
1
+ declare const CheckboxLikeFieldsExample: () => import("react/jsx-runtime").JSX.Element;
2
+ export default CheckboxLikeFieldsExample;
@@ -0,0 +1,11 @@
1
+ export type CheckboxFieldProps = {
2
+ checked?: boolean;
3
+ defaultChecked?: boolean;
4
+ value?: boolean;
5
+ onValueChange?: (value: boolean) => void;
6
+ };
7
+ declare const useCheckboxField: ({ checked, defaultChecked, value, onValueChange }: CheckboxFieldProps) => {
8
+ isChecked: boolean;
9
+ onCheckboxChanged: (event: React.ChangeEvent<HTMLInputElement>) => void;
10
+ };
11
+ export default useCheckboxField;
@@ -3,8 +3,8 @@ declare const usePresenter: (props: CustomToggleProps) => {
3
3
  variantProps: {
4
4
  'component-variant': string;
5
5
  };
6
- isChecked: boolean | undefined;
7
- handleChange: (e: React.ChangeEvent<HTMLInputElement>) => void;
6
+ isChecked: boolean;
7
+ handleChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
8
8
  disabled: boolean;
9
9
  invalid: boolean;
10
10
  otherInputProps: {
@@ -0,0 +1,2 @@
1
+ declare const InputExample: () => import("react/jsx-runtime").JSX.Element;
2
+ export default InputExample;
@@ -3,7 +3,7 @@ declare const usePresenter: (props: ToggleProps) => {
3
3
  variantProps: {
4
4
  'component-variant': string;
5
5
  };
6
- isChecked: boolean | undefined;
6
+ isChecked: boolean;
7
7
  onToggleChanged: (event: React.ChangeEvent<HTMLInputElement>) => void;
8
8
  otherInputProps: {
9
9
  className?: string | undefined | undefined;
@@ -268,8 +268,8 @@ declare const usePresenter: (props: ToggleButtonProps) => {
268
268
  trailingIcon?: import("react").ReactNode;
269
269
  initialValue?: boolean | undefined;
270
270
  };
271
- isChecked: boolean | undefined;
272
- handleChange: (e: React.ChangeEvent<HTMLInputElement>) => void;
271
+ isChecked: boolean;
272
+ handleChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
273
273
  disabled: boolean;
274
274
  required: boolean;
275
275
  invalid: boolean;
@@ -558,6 +558,7 @@
558
558
  align-items: center;
559
559
  gap: var(--toggle-row-gap) var(--toggle-column-gap);
560
560
  color: var(--toggle-color);
561
+ cursor: pointer;
561
562
  height: var(--toggle-height);
562
563
  min-height: var(--toggle-min-height);
563
564
  max-height: var(--toggle-max-height);
@@ -3710,18 +3711,18 @@ span.flatpickr-weekday {
3710
3711
  color: var(--chip-input-color);
3711
3712
  }
3712
3713
 
3713
- .ChipInput-module_chipInput__tCCgW .ChipInput-module_chipList__l2ctU {
3714
+ .ChipInput-module_chipInput__tCCgW .ChipInput-module_trigger__KLvR4 .ChipInput-module_chipList__l2ctU {
3714
3715
  --list-row-gap: var(--chip-input-chip-list-row-gap);
3715
3716
  --list-column-gap: var(--chip-input-chip-list-column-gap, var(--chip-input-chip-list-row-gap));
3716
3717
  }
3717
3718
 
3718
- .ChipInput-module_chipInput__tCCgW .ChipInput-module_chipList__l2ctU > * {
3719
+ .ChipInput-module_chipInput__tCCgW .ChipInput-module_trigger__KLvR4 .ChipInput-module_chipList__l2ctU > * {
3719
3720
  display: flex;
3720
3721
  justify-content: flex-start;
3721
3722
  align-items: center;
3722
3723
  }
3723
3724
 
3724
- .ChipInput-module_chipInput__tCCgW .ChipInput-module_chipList__l2ctU .ChipInput-module_chip__-6re8 {
3725
+ .ChipInput-module_chipInput__tCCgW .ChipInput-module_trigger__KLvR4 .ChipInput-module_chipList__l2ctU .ChipInput-module_chip__-6re8 {
3725
3726
  --chip-border-top-left-radius: var(--chip-input-chip-item-border-top-left-radius);
3726
3727
  --chip-border-top-right-radius: var(--chip-input-chip-item-border-top-right-radius);
3727
3728
  --chip-border-bottom-left-radius: var(--chip-input-chip-item-border-bottom-left-radius);
@@ -3735,21 +3736,21 @@ span.flatpickr-weekday {
3735
3736
  --chip-column-gap: var(--chip-input-chip-item-column-gap);
3736
3737
  }
3737
3738
 
3738
- .ChipInput-module_chipInput__tCCgW .ChipInput-module_input__J979Z {
3739
+ .ChipInput-module_chipInput__tCCgW .ChipInput-module_trigger__KLvR4 .ChipInput-module_chipList__l2ctU .ChipInput-module_input__J979Z {
3739
3740
  --input-border-top-width: 0px;
3740
3741
  --input-border-right-width: 0px;
3741
3742
  --input-border-bottom-width: 0px;
3742
3743
  --input-border-left-width: 0px;
3743
3744
  }
3744
3745
 
3745
- .ChipInput-module_chipInput__tCCgW .ChipInput-module_input__J979Z.ChipInput-module_disabledInput__ciuDU {
3746
+ .ChipInput-module_chipInput__tCCgW .ChipInput-module_trigger__KLvR4 .ChipInput-module_chipList__l2ctU .ChipInput-module_input__J979Z.ChipInput-module_disabledInput__ciuDU {
3746
3747
  --input-border-top-width: 0px;
3747
3748
  --input-border-right-width: 0px;
3748
3749
  --input-border-bottom-width: 0px;
3749
3750
  --input-border-left-width: 0px;
3750
3751
  }
3751
3752
 
3752
- .ChipInput-module_chipInput__tCCgW .ChipInput-module_input__J979Z:hover:not(:disabled), .ChipInput-module_chipInput__tCCgW .ChipInput-module_input__J979Z:active:not(:disabled), .ChipInput-module_chipInput__tCCgW .ChipInput-module_input__J979Z:has(:focus-visible):not(:disabled) {
3753
+ .ChipInput-module_chipInput__tCCgW .ChipInput-module_trigger__KLvR4 .ChipInput-module_chipList__l2ctU .ChipInput-module_input__J979Z:hover:not(:disabled), .ChipInput-module_chipInput__tCCgW .ChipInput-module_trigger__KLvR4 .ChipInput-module_chipList__l2ctU .ChipInput-module_input__J979Z:active:not(:disabled), .ChipInput-module_chipInput__tCCgW .ChipInput-module_trigger__KLvR4 .ChipInput-module_chipList__l2ctU .ChipInput-module_input__J979Z:has(:focus-visible):not(:disabled) {
3753
3754
  --input-border-top-width: 0px;
3754
3755
  --input-border-right-width: 0px;
3755
3756
  --input-border-bottom-width: 0px;
@@ -14790,6 +14791,16 @@ span.flatpickr-weekday {
14790
14791
  --select-paragraph-spacing: 0px;
14791
14792
  --select-paragraph-indent: 0px
14792
14793
  }
14794
+ [data-theme='dark'] [component-variant="select-single-select"][invalid]:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-single-select"][invalid]:not(:disabled):not([disabled]), [data-theme='dark'] [component-variant="select-single-select"]:invalid:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-single-select"]:invalid:not(:disabled):not([disabled]) {
14795
+ --select-width: 100%;
14796
+ --select-row-gap: var(--spacing-space-2);
14797
+ --select-column-gap: var(--spacing-space-2);
14798
+ --select-font-family: sans-sarif;
14799
+ --select-font-size: initial;
14800
+ --select-font-weight: regular;
14801
+ --select-paragraph-spacing: 0px;
14802
+ --select-paragraph-indent: 0px
14803
+ }
14793
14804
  [data-theme='dark'] [component-variant="select-single-select"][disabled],
14794
14805
  [data-theme='light'] [component-variant="select-single-select"][disabled],
14795
14806
  [data-theme='dark'] [component-variant="select-single-select"]:disabled,
@@ -14853,6 +14864,16 @@ span.flatpickr-weekday {
14853
14864
  --select-paragraph-spacing: 0px;
14854
14865
  --select-paragraph-indent: 0px
14855
14866
  }
14867
+ [data-theme='dark'] [component-variant="select-multi-select"][invalid]:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-multi-select"][invalid]:not(:disabled):not([disabled]), [data-theme='dark'] [component-variant="select-multi-select"]:invalid:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-multi-select"]:invalid:not(:disabled):not([disabled]) {
14868
+ --select-width: 100%;
14869
+ --select-row-gap: var(--spacing-space-2);
14870
+ --select-column-gap: var(--spacing-space-2);
14871
+ --select-font-family: sans-sarif;
14872
+ --select-font-size: initial;
14873
+ --select-font-weight: regular;
14874
+ --select-paragraph-spacing: 0px;
14875
+ --select-paragraph-indent: 0px
14876
+ }
14856
14877
  [data-theme='dark'] [component-variant="select-multi-select"][disabled],
14857
14878
  [data-theme='light'] [component-variant="select-multi-select"][disabled],
14858
14879
  [data-theme='dark'] [component-variant="select-multi-select"]:disabled,
@@ -15001,6 +15022,33 @@ span.flatpickr-weekday {
15001
15022
  --select-trigger-paragraph-spacing: 0px;
15002
15023
  --select-trigger-paragraph-indent: 0px
15003
15024
  }
15025
+ [data-theme='dark'] [component-variant="select-single-select"][invalid]:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-single-select"][invalid]:not(:disabled):not([disabled]), [data-theme='dark'] [component-variant="select-single-select"]:invalid:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-single-select"]:invalid:not(:disabled):not([disabled]) {
15026
+ --select-trigger-height: 32px;
15027
+ --select-trigger-width: 100%;
15028
+ --select-trigger-background-color: var(--interactive-surface-secondary-default);
15029
+ --select-trigger-color: var(--text-primary);
15030
+ --select-trigger-border-top-left-radius: var(--corner-radius-extra-small);
15031
+ --select-trigger-border-top-right-radius: var(--corner-radius-extra-small);
15032
+ --select-trigger-border-bottom-left-radius: var(--corner-radius-extra-small);
15033
+ --select-trigger-border-bottom-right-radius: var(--corner-radius-extra-small);
15034
+ --select-trigger-border-color: var(--border-destructive);
15035
+ --select-trigger-border-top-width: 1px;
15036
+ --select-trigger-border-right-width: 1px;
15037
+ --select-trigger-border-bottom-width: 1px;
15038
+ --select-trigger-border-left-width: 1px;
15039
+ --select-trigger-padding-left: var(--spacing-space-5);
15040
+ --select-trigger-padding-right: var(--spacing-space-5);
15041
+ --select-trigger-padding-top: var(--spacing-space-5);
15042
+ --select-trigger-padding-bottom: var(--spacing-space-5);
15043
+ --select-trigger-row-gap: var(--spacing-space-5);
15044
+ --select-trigger-column-gap: var(--spacing-space-5);
15045
+ --select-trigger-font-family: var(--font-family-body);
15046
+ --select-trigger-font-size: var(--font-size-body-small);
15047
+ --select-trigger-font-weight: var(--font-weight-regular);
15048
+ --select-trigger-line-height: var(--line-height-body-small);
15049
+ --select-trigger-paragraph-spacing: 0px;
15050
+ --select-trigger-paragraph-indent: 0px
15051
+ }
15004
15052
  [data-theme='dark'] [component-variant="select-single-select"][disabled],
15005
15053
  [data-theme='light'] [component-variant="select-single-select"][disabled],
15006
15054
  [data-theme='dark'] [component-variant="select-single-select"]:disabled,
@@ -15166,6 +15214,33 @@ span.flatpickr-weekday {
15166
15214
  --select-trigger-paragraph-spacing: 0px;
15167
15215
  --select-trigger-paragraph-indent: 0px
15168
15216
  }
15217
+ [data-theme='dark'] [component-variant="select-multi-select"][invalid]:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-multi-select"][invalid]:not(:disabled):not([disabled]), [data-theme='dark'] [component-variant="select-multi-select"]:invalid:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-multi-select"]:invalid:not(:disabled):not([disabled]) {
15218
+ --select-trigger-height: 32px;
15219
+ --select-trigger-width: 100%;
15220
+ --select-trigger-background-color: var(--interactive-surface-secondary-default);
15221
+ --select-trigger-color: var(--text-primary);
15222
+ --select-trigger-border-top-left-radius: var(--corner-radius-extra-small);
15223
+ --select-trigger-border-top-right-radius: var(--corner-radius-extra-small);
15224
+ --select-trigger-border-bottom-left-radius: var(--corner-radius-extra-small);
15225
+ --select-trigger-border-bottom-right-radius: var(--corner-radius-extra-small);
15226
+ --select-trigger-border-color: var(--border-destructive);
15227
+ --select-trigger-border-top-width: 1px;
15228
+ --select-trigger-border-right-width: 1px;
15229
+ --select-trigger-border-bottom-width: 1px;
15230
+ --select-trigger-border-left-width: 1px;
15231
+ --select-trigger-padding-left: var(--spacing-space-5);
15232
+ --select-trigger-padding-right: var(--spacing-space-5);
15233
+ --select-trigger-padding-top: var(--spacing-space-5);
15234
+ --select-trigger-padding-bottom: var(--spacing-space-5);
15235
+ --select-trigger-row-gap: var(--spacing-space-5);
15236
+ --select-trigger-column-gap: var(--spacing-space-5);
15237
+ --select-trigger-font-family: var(--font-family-body);
15238
+ --select-trigger-font-size: var(--font-size-body-small);
15239
+ --select-trigger-font-weight: var(--font-weight-regular);
15240
+ --select-trigger-line-height: var(--line-height-body-small);
15241
+ --select-trigger-paragraph-spacing: 0px;
15242
+ --select-trigger-paragraph-indent: 0px
15243
+ }
15169
15244
  [data-theme='dark'] [component-variant="select-multi-select"][disabled],
15170
15245
  [data-theme='light'] [component-variant="select-multi-select"][disabled],
15171
15246
  [data-theme='dark'] [component-variant="select-multi-select"]:disabled,
@@ -15316,6 +15391,30 @@ span.flatpickr-weekday {
15316
15391
  --select-options-paragraph-spacing: 0px;
15317
15392
  --select-options-paragraph-indent: 0px
15318
15393
  }
15394
+ [data-theme='dark'] [component-variant="select-single-select"][invalid]:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-single-select"][invalid]:not(:disabled):not([disabled]), [data-theme='dark'] [component-variant="select-single-select"]:invalid:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-single-select"]:invalid:not(:disabled):not([disabled]) {
15395
+ --select-options-width: 100%;
15396
+ --select-options-background-color: var(--surface-background-4);
15397
+ --select-options-border-top-left-radius: var(--corner-radius-extra-small);
15398
+ --select-options-border-top-right-radius: var(--corner-radius-extra-small);
15399
+ --select-options-border-bottom-left-radius: var(--corner-radius-extra-small);
15400
+ --select-options-border-bottom-right-radius: var(--corner-radius-extra-small);
15401
+ --select-options-border-color: var(--border-border-grey-3);
15402
+ --select-options-border-top-width: 1px;
15403
+ --select-options-border-right-width: 1px;
15404
+ --select-options-border-bottom-width: 1px;
15405
+ --select-options-border-left-width: 1px;
15406
+ --select-options-padding-left: var(--spacing-space-5);
15407
+ --select-options-padding-right: var(--spacing-space-5);
15408
+ --select-options-padding-top: var(--spacing-space-5);
15409
+ --select-options-padding-bottom: var(--spacing-space-5);
15410
+ --select-options-row-gap: var(--spacing-space-3);
15411
+ --select-options-column-gap: var(--spacing-space-3);
15412
+ --select-options-font-family: sans-sarif;
15413
+ --select-options-font-size: initial;
15414
+ --select-options-font-weight: regular;
15415
+ --select-options-paragraph-spacing: 0px;
15416
+ --select-options-paragraph-indent: 0px
15417
+ }
15319
15418
  [data-theme='dark'] [component-variant="select-multi-select"], [data-theme='light'] [component-variant="select-multi-select"] {
15320
15419
  --select-options-width: 100%;
15321
15420
  --select-options-background-color: var(--surface-background-4);
@@ -15436,6 +15535,30 @@ span.flatpickr-weekday {
15436
15535
  --select-options-paragraph-spacing: 0px;
15437
15536
  --select-options-paragraph-indent: 0px
15438
15537
  }
15538
+ [data-theme='dark'] [component-variant="select-multi-select"][invalid]:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-multi-select"][invalid]:not(:disabled):not([disabled]), [data-theme='dark'] [component-variant="select-multi-select"]:invalid:not(:disabled):not([disabled]), [data-theme='light'] [component-variant="select-multi-select"]:invalid:not(:disabled):not([disabled]) {
15539
+ --select-options-width: 100%;
15540
+ --select-options-background-color: var(--surface-background-4);
15541
+ --select-options-border-top-left-radius: var(--corner-radius-extra-small);
15542
+ --select-options-border-top-right-radius: var(--corner-radius-extra-small);
15543
+ --select-options-border-bottom-left-radius: var(--corner-radius-extra-small);
15544
+ --select-options-border-bottom-right-radius: var(--corner-radius-extra-small);
15545
+ --select-options-border-color: var(--border-border-grey-3);
15546
+ --select-options-border-top-width: 1px;
15547
+ --select-options-border-right-width: 1px;
15548
+ --select-options-border-bottom-width: 1px;
15549
+ --select-options-border-left-width: 1px;
15550
+ --select-options-padding-left: var(--spacing-space-5);
15551
+ --select-options-padding-right: var(--spacing-space-5);
15552
+ --select-options-padding-top: var(--spacing-space-5);
15553
+ --select-options-padding-bottom: var(--spacing-space-5);
15554
+ --select-options-row-gap: var(--spacing-space-3);
15555
+ --select-options-column-gap: var(--spacing-space-3);
15556
+ --select-options-font-family: sans-sarif;
15557
+ --select-options-font-size: initial;
15558
+ --select-options-font-weight: regular;
15559
+ --select-options-paragraph-spacing: 0px;
15560
+ --select-options-paragraph-indent: 0px
15561
+ }
15439
15562
  [data-theme='dark'] [component-variant^="select-list-item-"], [data-theme='light'] [component-variant^="select-list-item-"] {
15440
15563
  --select-list-item-opacity: 1;
15441
15564
  --select-list-item-height: auto;