@dafaz-ui/react 3.0.5 → 4.0.1

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.js CHANGED
@@ -64,6 +64,7 @@ __export(src_exports, {
64
64
  CheckBox: () => CheckBox,
65
65
  Heading: () => Heading,
66
66
  Radio: () => Radio,
67
+ Select: () => Select,
67
68
  Text: () => Text,
68
69
  TextArea: () => TextArea,
69
70
  TextInput: () => TextInput,
@@ -342,6 +343,10 @@ var CheckBoxUI = styled(Checkbox.Root, {
342
343
  "&:hover": {
343
344
  borderColor: "$dafaz600"
344
345
  },
346
+ "&:disabled": {
347
+ opacity: 0.5,
348
+ cursor: "not-allowed"
349
+ },
345
350
  variants: {
346
351
  size: {
347
352
  lg: {
@@ -411,6 +416,12 @@ var Label = styled("label", {
411
416
  gap: "$2",
412
417
  alignItems: "center",
413
418
  variants: {
419
+ disabled: {
420
+ true: {
421
+ opacity: 0.5,
422
+ cursor: "not-allowed"
423
+ }
424
+ },
414
425
  size: {
415
426
  lg: {
416
427
  fontSize: "$xl"
@@ -424,6 +435,7 @@ var Label = styled("label", {
424
435
  }
425
436
  },
426
437
  defaultVariants: {
438
+ disabled: false,
427
439
  size: "md"
428
440
  }
429
441
  });
@@ -435,14 +447,16 @@ function CheckBox(_a) {
435
447
  var _b = _a, {
436
448
  id,
437
449
  label,
438
- size
450
+ size,
451
+ disabled = false
439
452
  } = _b, props = __objRest(_b, [
440
453
  "id",
441
454
  "label",
442
- "size"
455
+ "size",
456
+ "disabled"
443
457
  ]);
444
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(Label, { htmlFor: id, size, children: [
445
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CheckBoxUI, __spreadProps(__spreadValues({ id }, props), { size, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CheckBoxIndicator, { asChild: true, size, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react2.Check, { weight: "bold" }) }) })),
458
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(Label, { disabled, htmlFor: id, size, children: [
459
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CheckBoxUI, __spreadProps(__spreadValues({ disabled, id }, props), { size, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CheckBoxIndicator, { asChild: true, size, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react2.Check, { weight: "bold" }) }) })),
446
460
  label
447
461
  ] });
448
462
  }
@@ -491,6 +505,10 @@ var RadioUI = styled(RadioGroup.Root, {
491
505
  display: "flex",
492
506
  flexDirection: "column",
493
507
  gap: "$4",
508
+ "&:disabled": {
509
+ opacity: 0.5,
510
+ cursor: "not-allowed"
511
+ },
494
512
  variants: {
495
513
  size: {
496
514
  lg: {},
@@ -525,6 +543,9 @@ var RadioItemUI = styled(RadioGroup2.Item, {
525
543
  alignItems: "center",
526
544
  borderBottom: "2px solid $dafaz600",
527
545
  transition: "border 0.1s linear",
546
+ "&:disabled": {
547
+ cursor: "not-allowed"
548
+ },
528
549
  '&:focus,&[data-state="checked"]': {
529
550
  backgroundColor: "$dafaz600",
530
551
  borderColor: "$dafaz600"
@@ -601,6 +622,12 @@ var Label2 = styled("label", {
601
622
  fontWeight: "$regular",
602
623
  cursor: "pointer",
603
624
  variants: {
625
+ disabled: {
626
+ true: {
627
+ opacity: 0.5,
628
+ cursor: "not-allowed"
629
+ }
630
+ },
604
631
  size: {
605
632
  lg: {
606
633
  fontSize: "$xl"
@@ -614,6 +641,7 @@ var Label2 = styled("label", {
614
641
  }
615
642
  },
616
643
  defaultVariants: {
644
+ disabled: false,
617
645
  size: "md"
618
646
  }
619
647
  });
@@ -624,15 +652,17 @@ function RadioItem(_a) {
624
652
  var _b = _a, {
625
653
  label,
626
654
  id,
627
- size
655
+ size,
656
+ disabled = false
628
657
  } = _b, props = __objRest(_b, [
629
658
  "label",
630
659
  "id",
631
- "size"
660
+ "size",
661
+ "disabled"
632
662
  ]);
633
663
  return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(RadioItemContainer, { children: [
634
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RadioItemUI, __spreadProps(__spreadValues({ id }, props), { size, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RadioIndicator, { asChild: true, size, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react3.Check, { weight: "bold" }) }) })),
635
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Label2, { htmlFor: id, size, children: label })
664
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RadioItemUI, __spreadProps(__spreadValues({ disabled, id }, props), { size, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RadioIndicator, { asChild: true, size, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react3.Check, { weight: "bold" }) }) })),
665
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Label2, { disabled, htmlFor: id, size, children: label })
636
666
  ] }, id);
637
667
  }
638
668
  RadioItem.displayName = "RadioItem";
@@ -640,21 +670,116 @@ RadioItem.displayName = "RadioItem";
640
670
  // src/components/Radio/index.tsx
641
671
  var import_jsx_runtime6 = require("react/jsx-runtime");
642
672
  function Radio(_a) {
643
- var _b = _a, { items, size } = _b, props = __objRest(_b, ["items", "size"]);
644
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(RadioUI, __spreadProps(__spreadValues({}, props), { children: items.map((item) => {
673
+ var _b = _a, {
674
+ items,
675
+ size,
676
+ disabled = false
677
+ } = _b, props = __objRest(_b, [
678
+ "items",
679
+ "size",
680
+ "disabled"
681
+ ]);
682
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(RadioUI, __spreadProps(__spreadValues({ disabled }, props), { children: items.map((item) => {
645
683
  return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
646
684
  RadioItem,
647
685
  {
648
686
  id: item.id,
649
687
  label: item.label,
650
688
  value: item.value,
651
- size
689
+ size,
690
+ disabled
652
691
  }
653
692
  );
654
693
  }) }));
655
694
  }
656
695
  Radio.displayName = "Radio";
657
696
 
697
+ // src/components/Select/styles.ts
698
+ var SelectUI = styled("select", {
699
+ gap: "$2",
700
+ overflow: "hidden",
701
+ background: "transparent",
702
+ border: "none",
703
+ fontFamily: "$app",
704
+ color: "$white",
705
+ fontWeight: "$regular",
706
+ cursor: "pointer",
707
+ boxSizing: "border-box",
708
+ borderRadius: "$md",
709
+ borderBottom: "2px solid $dafaz600",
710
+ transition: "border 0.2s linear",
711
+ width: "100%",
712
+ margin: 0,
713
+ padding: "$1 $2",
714
+ "&:focus": {
715
+ outline: 0,
716
+ borderBottom: "2px solid $dafaz400"
717
+ },
718
+ "&:disabled": {
719
+ opacity: 0.5,
720
+ cursor: "not-allowed"
721
+ },
722
+ variants: {
723
+ size: {
724
+ lg: {
725
+ fontSize: "$xl"
726
+ },
727
+ md: {
728
+ fontSize: "$lg"
729
+ },
730
+ sm: {
731
+ fontSize: "$md"
732
+ }
733
+ }
734
+ },
735
+ defaultVariants: {
736
+ size: "md"
737
+ }
738
+ });
739
+ var OptionUI = styled("option", {
740
+ backgroundColor: "$gray800",
741
+ "&.placeholder": {
742
+ backgroundColor: "$gray400"
743
+ },
744
+ variants: {
745
+ size: {
746
+ lg: {
747
+ fontSize: "$xl"
748
+ },
749
+ md: {
750
+ fontSize: "$lg"
751
+ },
752
+ sm: {
753
+ fontSize: "$md"
754
+ }
755
+ }
756
+ },
757
+ defaultVariants: {
758
+ size: "md"
759
+ }
760
+ });
761
+
762
+ // src/components/Select/index.tsx
763
+ var import_jsx_runtime7 = require("react/jsx-runtime");
764
+ function Select(_a) {
765
+ var _b = _a, {
766
+ size,
767
+ placeholder,
768
+ items
769
+ } = _b, props = __objRest(_b, [
770
+ "size",
771
+ "placeholder",
772
+ "items"
773
+ ]);
774
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(SelectUI, __spreadProps(__spreadValues({ size }, props), { defaultValue: "", children: [
775
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(OptionUI, { className: "placeholder", value: "", children: placeholder }),
776
+ items.map((item) => {
777
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(OptionUI, { value: item.value, children: item.label }, item.id);
778
+ })
779
+ ] }));
780
+ }
781
+ Select.displayName = "Select";
782
+
658
783
  // src/components/Text/styles.ts
659
784
  var TextUI = styled("p", {
660
785
  fontFamily: "$web",
@@ -678,7 +803,7 @@ var TextUI = styled("p", {
678
803
  });
679
804
 
680
805
  // src/components/Text/index.tsx
681
- var import_jsx_runtime7 = require("react/jsx-runtime");
806
+ var import_jsx_runtime8 = require("react/jsx-runtime");
682
807
  function Text(_a) {
683
808
  var _b = _a, {
684
809
  children,
@@ -687,7 +812,7 @@ function Text(_a) {
687
812
  "children",
688
813
  "size"
689
814
  ]);
690
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(TextUI, __spreadProps(__spreadValues({ size }, props), { children }));
815
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(TextUI, __spreadProps(__spreadValues({ size }, props), { children }));
691
816
  }
692
817
  Text.displayName = "Text";
693
818
 
@@ -716,7 +841,7 @@ var TextAreaUI = styled("textarea", {
716
841
  cursor: "not-allowed"
717
842
  },
718
843
  "&::placeholder": {
719
- fontSize: "$xl",
844
+ fontSize: "$lg",
720
845
  fontWeight: "$regular",
721
846
  color: "$white",
722
847
  opacity: 0.75
@@ -724,14 +849,14 @@ var TextAreaUI = styled("textarea", {
724
849
  });
725
850
 
726
851
  // src/components/TextArea/index.tsx
727
- var import_jsx_runtime8 = require("react/jsx-runtime");
852
+ var import_jsx_runtime9 = require("react/jsx-runtime");
728
853
  function TextArea(_a) {
729
854
  var _b = _a, {
730
855
  children
731
856
  } = _b, props = __objRest(_b, [
732
857
  "children"
733
858
  ]);
734
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(TextAreaUI, __spreadProps(__spreadValues({ rows: 3 }, props), { children }));
859
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(TextAreaUI, __spreadProps(__spreadValues({ rows: 3 }, props), { children }));
735
860
  }
736
861
  TextArea.displayName = "TextArea";
737
862
 
@@ -800,17 +925,19 @@ var Sufix = styled("span", {
800
925
  });
801
926
 
802
927
  // src/components/TextInput/index.tsx
803
- var import_jsx_runtime9 = require("react/jsx-runtime");
928
+ var import_jsx_runtime10 = require("react/jsx-runtime");
804
929
  var TextInput = (0, import_react4.forwardRef)(
805
930
  (_a, ref) => {
806
931
  var _b = _a, {
807
932
  withShadow = false,
808
933
  required = true,
809
- requiredText = "Opcional"
934
+ requiredText = "Opcional",
935
+ id
810
936
  } = _b, props = __objRest(_b, [
811
937
  "withShadow",
812
938
  "required",
813
- "requiredText"
939
+ "requiredText",
940
+ "id"
814
941
  ]);
815
942
  const [hiddenOptional, setHiddenOptional] = (0, import_react4.useState)(required);
816
943
  function handleOnChange(event) {
@@ -822,9 +949,9 @@ var TextInput = (0, import_react4.forwardRef)(
822
949
  }
823
950
  }
824
951
  }
825
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(InputContainer, { withShadow, children: [
826
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(InputUI, __spreadValues({ ref, onChange: handleOnChange }, props)),
827
- !hiddenOptional && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Sufix, { style: { marginLeft: `-${requiredText.length / 2}rem` }, children: requiredText })
952
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(InputContainer, { withShadow, children: [
953
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(InputUI, __spreadValues({ id, ref, onChange: handleOnChange }, props)),
954
+ !hiddenOptional && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Sufix, { style: { marginLeft: `-${requiredText.length / 2}rem` }, children: requiredText })
828
955
  ] });
829
956
  }
830
957
  );
@@ -836,6 +963,7 @@ TextInput.displayName = "TextInput";
836
963
  CheckBox,
837
964
  Heading,
838
965
  Radio,
966
+ Select,
839
967
  Text,
840
968
  TextArea,
841
969
  TextInput,
package/dist/index.mjs CHANGED
@@ -294,6 +294,10 @@ var CheckBoxUI = styled(Checkbox.Root, {
294
294
  "&:hover": {
295
295
  borderColor: "$dafaz600"
296
296
  },
297
+ "&:disabled": {
298
+ opacity: 0.5,
299
+ cursor: "not-allowed"
300
+ },
297
301
  variants: {
298
302
  size: {
299
303
  lg: {
@@ -363,6 +367,12 @@ var Label = styled("label", {
363
367
  gap: "$2",
364
368
  alignItems: "center",
365
369
  variants: {
370
+ disabled: {
371
+ true: {
372
+ opacity: 0.5,
373
+ cursor: "not-allowed"
374
+ }
375
+ },
366
376
  size: {
367
377
  lg: {
368
378
  fontSize: "$xl"
@@ -376,6 +386,7 @@ var Label = styled("label", {
376
386
  }
377
387
  },
378
388
  defaultVariants: {
389
+ disabled: false,
379
390
  size: "md"
380
391
  }
381
392
  });
@@ -387,14 +398,16 @@ function CheckBox(_a) {
387
398
  var _b = _a, {
388
399
  id,
389
400
  label,
390
- size
401
+ size,
402
+ disabled = false
391
403
  } = _b, props = __objRest(_b, [
392
404
  "id",
393
405
  "label",
394
- "size"
406
+ "size",
407
+ "disabled"
395
408
  ]);
396
- return /* @__PURE__ */ jsxs(Label, { htmlFor: id, size, children: [
397
- /* @__PURE__ */ jsx3(CheckBoxUI, __spreadProps(__spreadValues({ id }, props), { size, children: /* @__PURE__ */ jsx3(CheckBoxIndicator, { asChild: true, size, children: /* @__PURE__ */ jsx3(Check, { weight: "bold" }) }) })),
409
+ return /* @__PURE__ */ jsxs(Label, { disabled, htmlFor: id, size, children: [
410
+ /* @__PURE__ */ jsx3(CheckBoxUI, __spreadProps(__spreadValues({ disabled, id }, props), { size, children: /* @__PURE__ */ jsx3(CheckBoxIndicator, { asChild: true, size, children: /* @__PURE__ */ jsx3(Check, { weight: "bold" }) }) })),
398
411
  label
399
412
  ] });
400
413
  }
@@ -443,6 +456,10 @@ var RadioUI = styled(RadioGroup.Root, {
443
456
  display: "flex",
444
457
  flexDirection: "column",
445
458
  gap: "$4",
459
+ "&:disabled": {
460
+ opacity: 0.5,
461
+ cursor: "not-allowed"
462
+ },
446
463
  variants: {
447
464
  size: {
448
465
  lg: {},
@@ -477,6 +494,9 @@ var RadioItemUI = styled(RadioGroup2.Item, {
477
494
  alignItems: "center",
478
495
  borderBottom: "2px solid $dafaz600",
479
496
  transition: "border 0.1s linear",
497
+ "&:disabled": {
498
+ cursor: "not-allowed"
499
+ },
480
500
  '&:focus,&[data-state="checked"]': {
481
501
  backgroundColor: "$dafaz600",
482
502
  borderColor: "$dafaz600"
@@ -553,6 +573,12 @@ var Label2 = styled("label", {
553
573
  fontWeight: "$regular",
554
574
  cursor: "pointer",
555
575
  variants: {
576
+ disabled: {
577
+ true: {
578
+ opacity: 0.5,
579
+ cursor: "not-allowed"
580
+ }
581
+ },
556
582
  size: {
557
583
  lg: {
558
584
  fontSize: "$xl"
@@ -566,6 +592,7 @@ var Label2 = styled("label", {
566
592
  }
567
593
  },
568
594
  defaultVariants: {
595
+ disabled: false,
569
596
  size: "md"
570
597
  }
571
598
  });
@@ -576,15 +603,17 @@ function RadioItem(_a) {
576
603
  var _b = _a, {
577
604
  label,
578
605
  id,
579
- size
606
+ size,
607
+ disabled = false
580
608
  } = _b, props = __objRest(_b, [
581
609
  "label",
582
610
  "id",
583
- "size"
611
+ "size",
612
+ "disabled"
584
613
  ]);
585
614
  return /* @__PURE__ */ jsxs2(RadioItemContainer, { children: [
586
- /* @__PURE__ */ jsx5(RadioItemUI, __spreadProps(__spreadValues({ id }, props), { size, children: /* @__PURE__ */ jsx5(RadioIndicator, { asChild: true, size, children: /* @__PURE__ */ jsx5(Check2, { weight: "bold" }) }) })),
587
- /* @__PURE__ */ jsx5(Label2, { htmlFor: id, size, children: label })
615
+ /* @__PURE__ */ jsx5(RadioItemUI, __spreadProps(__spreadValues({ disabled, id }, props), { size, children: /* @__PURE__ */ jsx5(RadioIndicator, { asChild: true, size, children: /* @__PURE__ */ jsx5(Check2, { weight: "bold" }) }) })),
616
+ /* @__PURE__ */ jsx5(Label2, { disabled, htmlFor: id, size, children: label })
588
617
  ] }, id);
589
618
  }
590
619
  RadioItem.displayName = "RadioItem";
@@ -592,21 +621,116 @@ RadioItem.displayName = "RadioItem";
592
621
  // src/components/Radio/index.tsx
593
622
  import { jsx as jsx6 } from "react/jsx-runtime";
594
623
  function Radio(_a) {
595
- var _b = _a, { items, size } = _b, props = __objRest(_b, ["items", "size"]);
596
- return /* @__PURE__ */ jsx6(RadioUI, __spreadProps(__spreadValues({}, props), { children: items.map((item) => {
624
+ var _b = _a, {
625
+ items,
626
+ size,
627
+ disabled = false
628
+ } = _b, props = __objRest(_b, [
629
+ "items",
630
+ "size",
631
+ "disabled"
632
+ ]);
633
+ return /* @__PURE__ */ jsx6(RadioUI, __spreadProps(__spreadValues({ disabled }, props), { children: items.map((item) => {
597
634
  return /* @__PURE__ */ jsx6(
598
635
  RadioItem,
599
636
  {
600
637
  id: item.id,
601
638
  label: item.label,
602
639
  value: item.value,
603
- size
640
+ size,
641
+ disabled
604
642
  }
605
643
  );
606
644
  }) }));
607
645
  }
608
646
  Radio.displayName = "Radio";
609
647
 
648
+ // src/components/Select/styles.ts
649
+ var SelectUI = styled("select", {
650
+ gap: "$2",
651
+ overflow: "hidden",
652
+ background: "transparent",
653
+ border: "none",
654
+ fontFamily: "$app",
655
+ color: "$white",
656
+ fontWeight: "$regular",
657
+ cursor: "pointer",
658
+ boxSizing: "border-box",
659
+ borderRadius: "$md",
660
+ borderBottom: "2px solid $dafaz600",
661
+ transition: "border 0.2s linear",
662
+ width: "100%",
663
+ margin: 0,
664
+ padding: "$1 $2",
665
+ "&:focus": {
666
+ outline: 0,
667
+ borderBottom: "2px solid $dafaz400"
668
+ },
669
+ "&:disabled": {
670
+ opacity: 0.5,
671
+ cursor: "not-allowed"
672
+ },
673
+ variants: {
674
+ size: {
675
+ lg: {
676
+ fontSize: "$xl"
677
+ },
678
+ md: {
679
+ fontSize: "$lg"
680
+ },
681
+ sm: {
682
+ fontSize: "$md"
683
+ }
684
+ }
685
+ },
686
+ defaultVariants: {
687
+ size: "md"
688
+ }
689
+ });
690
+ var OptionUI = styled("option", {
691
+ backgroundColor: "$gray800",
692
+ "&.placeholder": {
693
+ backgroundColor: "$gray400"
694
+ },
695
+ variants: {
696
+ size: {
697
+ lg: {
698
+ fontSize: "$xl"
699
+ },
700
+ md: {
701
+ fontSize: "$lg"
702
+ },
703
+ sm: {
704
+ fontSize: "$md"
705
+ }
706
+ }
707
+ },
708
+ defaultVariants: {
709
+ size: "md"
710
+ }
711
+ });
712
+
713
+ // src/components/Select/index.tsx
714
+ import { jsx as jsx7, jsxs as jsxs3 } from "react/jsx-runtime";
715
+ function Select(_a) {
716
+ var _b = _a, {
717
+ size,
718
+ placeholder,
719
+ items
720
+ } = _b, props = __objRest(_b, [
721
+ "size",
722
+ "placeholder",
723
+ "items"
724
+ ]);
725
+ return /* @__PURE__ */ jsxs3(SelectUI, __spreadProps(__spreadValues({ size }, props), { defaultValue: "", children: [
726
+ /* @__PURE__ */ jsx7(OptionUI, { className: "placeholder", value: "", children: placeholder }),
727
+ items.map((item) => {
728
+ return /* @__PURE__ */ jsx7(OptionUI, { value: item.value, children: item.label }, item.id);
729
+ })
730
+ ] }));
731
+ }
732
+ Select.displayName = "Select";
733
+
610
734
  // src/components/Text/styles.ts
611
735
  var TextUI = styled("p", {
612
736
  fontFamily: "$web",
@@ -630,7 +754,7 @@ var TextUI = styled("p", {
630
754
  });
631
755
 
632
756
  // src/components/Text/index.tsx
633
- import { jsx as jsx7 } from "react/jsx-runtime";
757
+ import { jsx as jsx8 } from "react/jsx-runtime";
634
758
  function Text(_a) {
635
759
  var _b = _a, {
636
760
  children,
@@ -639,7 +763,7 @@ function Text(_a) {
639
763
  "children",
640
764
  "size"
641
765
  ]);
642
- return /* @__PURE__ */ jsx7(TextUI, __spreadProps(__spreadValues({ size }, props), { children }));
766
+ return /* @__PURE__ */ jsx8(TextUI, __spreadProps(__spreadValues({ size }, props), { children }));
643
767
  }
644
768
  Text.displayName = "Text";
645
769
 
@@ -668,7 +792,7 @@ var TextAreaUI = styled("textarea", {
668
792
  cursor: "not-allowed"
669
793
  },
670
794
  "&::placeholder": {
671
- fontSize: "$xl",
795
+ fontSize: "$lg",
672
796
  fontWeight: "$regular",
673
797
  color: "$white",
674
798
  opacity: 0.75
@@ -676,14 +800,14 @@ var TextAreaUI = styled("textarea", {
676
800
  });
677
801
 
678
802
  // src/components/TextArea/index.tsx
679
- import { jsx as jsx8 } from "react/jsx-runtime";
803
+ import { jsx as jsx9 } from "react/jsx-runtime";
680
804
  function TextArea(_a) {
681
805
  var _b = _a, {
682
806
  children
683
807
  } = _b, props = __objRest(_b, [
684
808
  "children"
685
809
  ]);
686
- return /* @__PURE__ */ jsx8(TextAreaUI, __spreadProps(__spreadValues({ rows: 3 }, props), { children }));
810
+ return /* @__PURE__ */ jsx9(TextAreaUI, __spreadProps(__spreadValues({ rows: 3 }, props), { children }));
687
811
  }
688
812
  TextArea.displayName = "TextArea";
689
813
 
@@ -755,17 +879,19 @@ var Sufix = styled("span", {
755
879
  });
756
880
 
757
881
  // src/components/TextInput/index.tsx
758
- import { jsx as jsx9, jsxs as jsxs3 } from "react/jsx-runtime";
882
+ import { jsx as jsx10, jsxs as jsxs4 } from "react/jsx-runtime";
759
883
  var TextInput = forwardRef(
760
884
  (_a, ref) => {
761
885
  var _b = _a, {
762
886
  withShadow = false,
763
887
  required = true,
764
- requiredText = "Opcional"
888
+ requiredText = "Opcional",
889
+ id
765
890
  } = _b, props = __objRest(_b, [
766
891
  "withShadow",
767
892
  "required",
768
- "requiredText"
893
+ "requiredText",
894
+ "id"
769
895
  ]);
770
896
  const [hiddenOptional, setHiddenOptional] = useState(required);
771
897
  function handleOnChange(event) {
@@ -777,9 +903,9 @@ var TextInput = forwardRef(
777
903
  }
778
904
  }
779
905
  }
780
- return /* @__PURE__ */ jsxs3(InputContainer, { withShadow, children: [
781
- /* @__PURE__ */ jsx9(InputUI, __spreadValues({ ref, onChange: handleOnChange }, props)),
782
- !hiddenOptional && /* @__PURE__ */ jsx9(Sufix, { style: { marginLeft: `-${requiredText.length / 2}rem` }, children: requiredText })
906
+ return /* @__PURE__ */ jsxs4(InputContainer, { withShadow, children: [
907
+ /* @__PURE__ */ jsx10(InputUI, __spreadValues({ id, ref, onChange: handleOnChange }, props)),
908
+ !hiddenOptional && /* @__PURE__ */ jsx10(Sufix, { style: { marginLeft: `-${requiredText.length / 2}rem` }, children: requiredText })
783
909
  ] });
784
910
  }
785
911
  );
@@ -790,6 +916,7 @@ export {
790
916
  CheckBox,
791
917
  Heading,
792
918
  Radio,
919
+ Select,
793
920
  Text,
794
921
  TextArea,
795
922
  TextInput,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dafaz-ui/react",
3
- "version": "3.0.5",
3
+ "version": "4.0.1",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",
@@ -10,11 +10,12 @@ export function CheckBox({
10
10
  id,
11
11
  label,
12
12
  size,
13
+ disabled = false,
13
14
  ...props
14
15
  }: CheckboxIUProps & CheckboxProps) {
15
16
  return (
16
- <Label htmlFor={id} size={size}>
17
- <CheckBoxUI id={id} {...props} size={size}>
17
+ <Label disabled={disabled} htmlFor={id} size={size}>
18
+ <CheckBoxUI disabled={disabled} id={id} {...props} size={size}>
18
19
  <CheckBoxIndicator asChild size={size}>
19
20
  <Check weight="bold" />
20
21
  </CheckBoxIndicator>