@availity/mui-textfield 1.1.1 → 1.1.3

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/CHANGELOG.md CHANGED
@@ -2,6 +2,20 @@
2
2
 
3
3
  This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
4
4
 
5
+ ## [1.1.3](https://github.com/Availity/element/compare/@availity/mui-textfield@1.1.2...@availity/mui-textfield@1.1.3) (2025-04-08)
6
+
7
+ ### Dependency Updates
8
+
9
+ * `mui-form-utils` updated to version `1.1.2`
10
+ * `mui-button` updated to version `1.1.2`
11
+ * `mui-menu` updated to version `1.1.2`
12
+ ## [1.1.2](https://github.com/Availity/element/compare/@availity/mui-textfield@1.1.1...@availity/mui-textfield@1.1.2) (2025-04-04)
13
+
14
+
15
+ ### Bug Fixes
16
+
17
+ * **mui-textfield:** ensure helperText props are passed to helperText ([2d3de04](https://github.com/Availity/element/commit/2d3de04393bb0df18d5a8d73cad0ea688f90a0b2))
18
+
5
19
  ## [1.1.1](https://github.com/Availity/element/compare/@availity/mui-textfield@1.1.0...@availity/mui-textfield@1.1.1) (2025-03-27)
6
20
 
7
21
  ## [1.1.0](https://github.com/Availity/element/compare/@availity/mui-textfield@1.0.1...@availity/mui-textfield@1.1.0) (2025-03-21)
package/dist/index.d.mts CHANGED
@@ -19,7 +19,7 @@ type TextFieldFormHelperTextProps = {
19
19
  helperText: string;
20
20
  maxLength: string;
21
21
  showCharacterCount: boolean;
22
- };
22
+ } & FormHelperTextProps;
23
23
  declare const TextField: react.ForwardRefExoticComponent<Omit<TextFieldProps, "ref"> & react.RefAttributes<HTMLDivElement | HTMLInputElement>>;
24
24
 
25
25
  export { TextField, type TextFieldFormHelperTextProps, type TextFieldProps };
package/dist/index.d.ts CHANGED
@@ -19,7 +19,7 @@ type TextFieldFormHelperTextProps = {
19
19
  helperText: string;
20
20
  maxLength: string;
21
21
  showCharacterCount: boolean;
22
- };
22
+ } & FormHelperTextProps;
23
23
  declare const TextField: react.ForwardRefExoticComponent<Omit<TextFieldProps, "ref"> & react.RefAttributes<HTMLDivElement | HTMLInputElement>>;
24
24
 
25
25
  export { TextField, type TextFieldFormHelperTextProps, type TextFieldProps };
package/dist/index.js CHANGED
@@ -110,15 +110,21 @@ var SelectPlaceholder = (0, import_styles.styled)("span", {
110
110
  slot: "SelectPlaceholder",
111
111
  overridesResolver: (props, styles) => styles.avFilled
112
112
  })(({ theme }) => ({ opacity: 1, color: theme.palette.grey[400] }));
113
- var TextFieldFormHelperText = ({
114
- charCount,
115
- helperText,
116
- maxLength,
117
- showCharacterCount
118
- }) => {
113
+ var TextFieldFormHelperText = (_a) => {
114
+ var _b = _a, {
115
+ charCount,
116
+ helperText,
117
+ maxLength,
118
+ showCharacterCount
119
+ } = _b, FormHelperTextProps2 = __objRest(_b, [
120
+ "charCount",
121
+ "helperText",
122
+ "maxLength",
123
+ "showCharacterCount"
124
+ ]);
119
125
  if (showCharacterCount) {
120
126
  return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(Grid, { container: true, justifyContent: "space-between", flexWrap: "nowrap", children: [
121
- /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_mui_form_utils.FormHelperText, { sx: { marginRight: "12px" }, children: helperText }),
127
+ /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_mui_form_utils.FormHelperText, __spreadProps(__spreadValues({}, FormHelperTextProps2), { sx: { marginRight: "12px" }, children: helperText })),
122
128
  /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(Typography, { variant: "caption", marginTop: "4px", lineHeight: "1.25rem", children: [
123
129
  /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Typography, { component: "span", variant: "inherit", color: charCount > maxLength ? "error" : "textPrimary", children: charCount || 0 }),
124
130
  "/",
@@ -126,7 +132,7 @@ var TextFieldFormHelperText = ({
126
132
  ] })
127
133
  ] });
128
134
  }
129
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_mui_form_utils.FormHelperText, { children: helperText });
135
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_mui_form_utils.FormHelperText, __spreadProps(__spreadValues({}, FormHelperTextProps2), { children: helperText }));
130
136
  };
131
137
  var TextField = (0, import_react3.forwardRef)((props, ref) => {
132
138
  var _b, _c, _d, _e, _f, _g, _h;
package/dist/index.mjs CHANGED
@@ -83,15 +83,21 @@ var SelectPlaceholder = styled("span", {
83
83
  slot: "SelectPlaceholder",
84
84
  overridesResolver: (props, styles) => styles.avFilled
85
85
  })(({ theme }) => ({ opacity: 1, color: theme.palette.grey[400] }));
86
- var TextFieldFormHelperText = ({
87
- charCount,
88
- helperText,
89
- maxLength,
90
- showCharacterCount
91
- }) => {
86
+ var TextFieldFormHelperText = (_a) => {
87
+ var _b = _a, {
88
+ charCount,
89
+ helperText,
90
+ maxLength,
91
+ showCharacterCount
92
+ } = _b, FormHelperTextProps2 = __objRest(_b, [
93
+ "charCount",
94
+ "helperText",
95
+ "maxLength",
96
+ "showCharacterCount"
97
+ ]);
92
98
  if (showCharacterCount) {
93
99
  return /* @__PURE__ */ jsxs(Grid, { container: true, justifyContent: "space-between", flexWrap: "nowrap", children: [
94
- /* @__PURE__ */ jsx6(FormHelperText, { sx: { marginRight: "12px" }, children: helperText }),
100
+ /* @__PURE__ */ jsx6(FormHelperText, __spreadProps(__spreadValues({}, FormHelperTextProps2), { sx: { marginRight: "12px" }, children: helperText })),
95
101
  /* @__PURE__ */ jsxs(Typography, { variant: "caption", marginTop: "4px", lineHeight: "1.25rem", children: [
96
102
  /* @__PURE__ */ jsx6(Typography, { component: "span", variant: "inherit", color: charCount > maxLength ? "error" : "textPrimary", children: charCount || 0 }),
97
103
  "/",
@@ -99,7 +105,7 @@ var TextFieldFormHelperText = ({
99
105
  ] })
100
106
  ] });
101
107
  }
102
- return /* @__PURE__ */ jsx6(FormHelperText, { children: helperText });
108
+ return /* @__PURE__ */ jsx6(FormHelperText, __spreadProps(__spreadValues({}, FormHelperTextProps2), { children: helperText }));
103
109
  };
104
110
  var TextField = forwardRef3((props, ref) => {
105
111
  var _b, _c, _d, _e, _f, _g, _h;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@availity/mui-textfield",
3
- "version": "1.1.1",
3
+ "version": "1.1.3",
4
4
  "description": "Availity MUI Textfield Component - part of the @availity/element design system",
5
5
  "keywords": [
6
6
  "react",
@@ -40,7 +40,7 @@
40
40
  "publish:canary": "yarn npm publish --access public --tag canary"
41
41
  },
42
42
  "dependencies": {
43
- "@availity/mui-form-utils": "1.1.0",
43
+ "@availity/mui-form-utils": "1.1.1",
44
44
  "@availity/mui-icon": "1.0.1"
45
45
  },
46
46
  "devDependencies": {
@@ -40,18 +40,21 @@ export type TextFieldFormHelperTextProps = {
40
40
  helperText: string;
41
41
  maxLength: string;
42
42
  showCharacterCount: boolean;
43
- };
43
+ } & FormHelperTextProps;
44
44
 
45
45
  const TextFieldFormHelperText = ({
46
46
  charCount,
47
47
  helperText,
48
48
  maxLength,
49
49
  showCharacterCount,
50
+ ...FormHelperTextProps
50
51
  }: TextFieldFormHelperTextProps) => {
51
52
  if (showCharacterCount) {
52
53
  return (
53
54
  <Grid container justifyContent="space-between" flexWrap="nowrap">
54
- <FormHelperText sx={{ marginRight: '12px' }}>{helperText}</FormHelperText>
55
+ <FormHelperText {...FormHelperTextProps} sx={{ marginRight: '12px' }}>
56
+ {helperText}
57
+ </FormHelperText>
55
58
  <Typography variant="caption" marginTop="4px" lineHeight="1.25rem">
56
59
  <Typography component="span" variant="inherit" color={charCount > maxLength ? 'error' : 'textPrimary'}>
57
60
  {charCount || 0}
@@ -62,7 +65,7 @@ const TextFieldFormHelperText = ({
62
65
  );
63
66
  }
64
67
 
65
- return <FormHelperText>{helperText}</FormHelperText>;
68
+ return <FormHelperText {...FormHelperTextProps}>{helperText}</FormHelperText>;
66
69
  };
67
70
 
68
71
  export const TextField = forwardRef<HTMLDivElement | HTMLInputElement, TextFieldProps>((props, ref) => {