@dafaz-ui/react 4.0.0 → 4.0.2

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.
@@ -1,5 +1,5 @@
1
1
 
2
- > @dafaz-ui/react@4.0.0 build
2
+ > @dafaz-ui/react@4.0.2 build
3
3
  > tsup src/index.tsx --format esm,cjs --dts --external react
4
4
 
5
5
  CLI Building entry: src/index.tsx
@@ -8,11 +8,11 @@
8
8
  CLI Target: es6
9
9
  ESM Build start
10
10
  CJS Build start
11
- CJS dist/index.js 21.88 KB
12
- CJS ⚡️ Build success in 41ms
13
- ESM dist/index.mjs 19.36 KB
14
- ESM ⚡️ Build success in 41ms
11
+ ESM dist/index.mjs 19.39 KB
12
+ ESM ⚡️ Build success in 38ms
13
+ CJS dist/index.js 21.90 KB
14
+ CJS ⚡️ Build success in 38ms
15
15
  DTS Build start
16
- DTS ⚡️ Build success in 4569ms
17
- DTS dist/index.d.mts 103.69 KB
18
- DTS dist/index.d.ts 103.69 KB
16
+ DTS ⚡️ Build success in 4507ms
17
+ DTS dist/index.d.mts 103.71 KB
18
+ DTS dist/index.d.ts 103.71 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @dafaz-ui/react
2
2
 
3
+ ## 4.0.2
4
+
5
+ ### Patch Changes
6
+
7
+ - fix id InputText
8
+
9
+ ## 4.0.1
10
+
11
+ ### Patch Changes
12
+
13
+ - fix InputText
14
+
3
15
  ## 4.0.0
4
16
 
5
17
  ### Major Changes
package/dist/index.d.mts CHANGED
@@ -1962,6 +1962,7 @@ interface TextInputProps extends ComponentProps<typeof InputUI> {
1962
1962
  withShadow?: boolean;
1963
1963
  placeholder?: string;
1964
1964
  type?: string;
1965
+ id: string;
1965
1966
  }
1966
1967
  declare const TextInput: react.ForwardRefExoticComponent<Omit<TextInputProps, "ref"> & react.RefAttributes<HTMLInputElement>>;
1967
1968
 
package/dist/index.d.ts CHANGED
@@ -1962,6 +1962,7 @@ interface TextInputProps extends ComponentProps<typeof InputUI> {
1962
1962
  withShadow?: boolean;
1963
1963
  placeholder?: string;
1964
1964
  type?: string;
1965
+ id: string;
1965
1966
  }
1966
1967
  declare const TextInput: react.ForwardRefExoticComponent<Omit<TextInputProps, "ref"> & react.RefAttributes<HTMLInputElement>>;
1967
1968
 
package/dist/index.js CHANGED
@@ -931,11 +931,13 @@ var TextInput = (0, import_react4.forwardRef)(
931
931
  var _b = _a, {
932
932
  withShadow = false,
933
933
  required = true,
934
- requiredText = "Opcional"
934
+ requiredText = "Opcional",
935
+ id
935
936
  } = _b, props = __objRest(_b, [
936
937
  "withShadow",
937
938
  "required",
938
- "requiredText"
939
+ "requiredText",
940
+ "id"
939
941
  ]);
940
942
  const [hiddenOptional, setHiddenOptional] = (0, import_react4.useState)(required);
941
943
  function handleOnChange(event) {
@@ -948,7 +950,7 @@ var TextInput = (0, import_react4.forwardRef)(
948
950
  }
949
951
  }
950
952
  return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(InputContainer, { withShadow, children: [
951
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(InputUI, __spreadValues({ ref, onChange: handleOnChange }, props)),
953
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(InputUI, __spreadValues({ id, ref, onChange: handleOnChange }, props)),
952
954
  !hiddenOptional && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Sufix, { style: { marginLeft: `-${requiredText.length / 2}rem` }, children: requiredText })
953
955
  ] });
954
956
  }
package/dist/index.mjs CHANGED
@@ -885,11 +885,13 @@ var TextInput = forwardRef(
885
885
  var _b = _a, {
886
886
  withShadow = false,
887
887
  required = true,
888
- requiredText = "Opcional"
888
+ requiredText = "Opcional",
889
+ id
889
890
  } = _b, props = __objRest(_b, [
890
891
  "withShadow",
891
892
  "required",
892
- "requiredText"
893
+ "requiredText",
894
+ "id"
893
895
  ]);
894
896
  const [hiddenOptional, setHiddenOptional] = useState(required);
895
897
  function handleOnChange(event) {
@@ -902,7 +904,7 @@ var TextInput = forwardRef(
902
904
  }
903
905
  }
904
906
  return /* @__PURE__ */ jsxs4(InputContainer, { withShadow, children: [
905
- /* @__PURE__ */ jsx10(InputUI, __spreadValues({ ref, onChange: handleOnChange }, props)),
907
+ /* @__PURE__ */ jsx10(InputUI, __spreadValues({ id, ref, onChange: handleOnChange }, props)),
906
908
  !hiddenOptional && /* @__PURE__ */ jsx10(Sufix, { style: { marginLeft: `-${requiredText.length / 2}rem` }, children: requiredText })
907
909
  ] });
908
910
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dafaz-ui/react",
3
- "version": "4.0.0",
3
+ "version": "4.0.2",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",
@@ -13,6 +13,7 @@ export interface TextInputProps extends ComponentProps<typeof InputUI> {
13
13
  withShadow?: boolean
14
14
  placeholder?: string
15
15
  type?: string
16
+ id: string
16
17
  }
17
18
 
18
19
  export const TextInput = forwardRef<ElementRef<typeof InputUI>, TextInputProps>(
@@ -21,6 +22,7 @@ export const TextInput = forwardRef<ElementRef<typeof InputUI>, TextInputProps>(
21
22
  withShadow = false,
22
23
  required = true,
23
24
  requiredText = 'Opcional',
25
+ id,
24
26
  ...props
25
27
  }: TextInputProps,
26
28
  ref,
@@ -39,7 +41,7 @@ export const TextInput = forwardRef<ElementRef<typeof InputUI>, TextInputProps>(
39
41
 
40
42
  return (
41
43
  <InputContainer withShadow={withShadow}>
42
- <InputUI ref={ref} onChange={handleOnChange} {...props} />
44
+ <InputUI id={id} ref={ref} onChange={handleOnChange} {...props} />
43
45
  {!hiddenOptional && (
44
46
  <Sufix style={{ marginLeft: `-${requiredText.length / 2}rem` }}>
45
47
  {requiredText}