@servicetitan/form 18.1.0 → 19.3.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/masked-input.d.ts.map +1 -1
- package/dist/masked-input.js +2 -2
- package/dist/masked-input.js.map +1 -1
- package/package.json +10 -10
- package/src/masked-input.tsx +2 -0
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"masked-input.d.ts","sourceRoot":"","sources":["../src/masked-input.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,mBAAmB,EAAe,MAAM,OAAO,CAAC;AAE7D,OAAuB,EAAE,KAAK,IAAI,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AAClF,OAAO,EAAQ,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAEnE,aAAK,gBAAgB,GAAG,cAAc,GAClC,IAAI,CAAC,qBAAqB,EAAE,MAAM,mBAAmB,CAAC,gBAAgB,CAAC,CAAC,CAAC;AAE7E,eAAO,MAAM,WAAW,EAAE,EAAE,CAAC,gBAAgB,
|
1
|
+
{"version":3,"file":"masked-input.d.ts","sourceRoot":"","sources":["../src/masked-input.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,mBAAmB,EAAe,MAAM,OAAO,CAAC;AAE7D,OAAuB,EAAE,KAAK,IAAI,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AAClF,OAAO,EAAQ,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAEnE,aAAK,gBAAgB,GAAG,cAAc,GAClC,IAAI,CAAC,qBAAqB,EAAE,MAAM,mBAAmB,CAAC,gBAAgB,CAAC,CAAC,CAAC;AAE7E,eAAO,MAAM,WAAW,EAAE,EAAE,CAAC,gBAAgB,CA6B5C,CAAC"}
|
package/dist/masked-input.js
CHANGED
@@ -19,11 +19,11 @@ const jsx_runtime_1 = require("react/jsx-runtime");
|
|
19
19
|
const react_input_mask_1 = __importDefault(require("react-input-mask"));
|
20
20
|
const design_system_1 = require("@servicetitan/design-system");
|
21
21
|
const MaskedInput = (_a) => {
|
22
|
-
var { mask, maskChar, value, onChange, placeholder, disabled } = _a, props = __rest(_a, ["mask", "maskChar", "value", "onChange", "placeholder", "disabled"]);
|
22
|
+
var { mask, maskChar, value, onChange, placeholder, disabled, formatChars } = _a, props = __rest(_a, ["mask", "maskChar", "value", "onChange", "placeholder", "disabled", "formatChars"]);
|
23
23
|
const handleInputChange = (e) => {
|
24
24
|
onChange(e.target.value);
|
25
25
|
};
|
26
|
-
return ((0, jsx_runtime_1.jsx)(react_input_mask_1.default, Object.assign({ mask: mask, maskChar: maskChar, value: value, onChange: handleInputChange, placeholder: placeholder, disabled: disabled }, { children: (innerProps) => ((0, jsx_runtime_1.jsx)(design_system_1.Form.Input, Object.assign({}, props, innerProps), void 0)) }), void 0));
|
26
|
+
return ((0, jsx_runtime_1.jsx)(react_input_mask_1.default, Object.assign({ mask: mask, maskChar: maskChar, value: value, onChange: handleInputChange, placeholder: placeholder, disabled: disabled, formatChars: formatChars }, { children: (innerProps) => ((0, jsx_runtime_1.jsx)(design_system_1.Form.Input, Object.assign({}, props, innerProps), void 0)) }), void 0));
|
27
27
|
};
|
28
28
|
exports.MaskedInput = MaskedInput;
|
29
29
|
//# sourceMappingURL=masked-input.js.map
|
package/dist/masked-input.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"masked-input.js","sourceRoot":"","sources":["../src/masked-input.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAEA,wEAAkF;AAClF,+DAAmE;AAK5D,MAAM,WAAW,GAAyB,CAAC,
|
1
|
+
{"version":3,"file":"masked-input.js","sourceRoot":"","sources":["../src/masked-input.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAEA,wEAAkF;AAClF,+DAAmE;AAK5D,MAAM,WAAW,GAAyB,CAAC,EASjD,EAAE,EAAE;QAT6C,EAC9C,IAAI,EACJ,QAAQ,EACR,KAAK,EACL,QAAQ,EACR,WAAW,EACX,QAAQ,EACR,WAAW,OAEd,EADM,KAAK,cARsC,mFASjD,CADW;IAER,MAAM,iBAAiB,GAAG,CAAC,CAAgC,EAAE,EAAE;QAC3D,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IAC7B,CAAC,CAAC;IAEF,OAAO,CACH,uBAAC,0BAAc,kBACX,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,QAAQ,EAClB,KAAK,EAAE,KAAK,EACZ,QAAQ,EAAE,iBAAiB,EAC3B,WAAW,EAAE,WAAW,EACxB,QAAQ,EAAE,QAAQ,EAClB,WAAW,EAAE,WAAW,gBAEvB,CAAC,UAAiD,EAAE,EAAE,CAAC,CACpD,uBAAC,oBAAI,CAAC,KAAK,oBAAK,KAAK,EAAM,UAAU,UAAI,CAC5C,YACY,CACpB,CAAC;AACN,CAAC,CAAC;AA7BW,QAAA,WAAW,eA6BtB"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@servicetitan/form",
|
3
|
-
"version": "
|
3
|
+
"version": "19.3.0",
|
4
4
|
"description": "",
|
5
5
|
"homepage": "https://docs.st.dev/docs/frontend/form",
|
6
6
|
"repository": {
|
@@ -15,19 +15,19 @@
|
|
15
15
|
"src"
|
16
16
|
],
|
17
17
|
"devDependencies": {
|
18
|
-
"@servicetitan/confirm": "^
|
19
|
-
"@servicetitan/culture": "^
|
20
|
-
"@servicetitan/data-query": "^
|
18
|
+
"@servicetitan/confirm": "^19.3.0",
|
19
|
+
"@servicetitan/culture": "^19.3.0",
|
20
|
+
"@servicetitan/data-query": "^19.3.0",
|
21
21
|
"@servicetitan/design-system": "~10.6.0",
|
22
|
-
"@servicetitan/react-ioc": "^
|
22
|
+
"@servicetitan/react-ioc": "^19.3.0",
|
23
23
|
"@servicetitan/tokens": "~10.6.0",
|
24
24
|
"@types/debounce": "~1.2.1",
|
25
|
-
"@types/react": "~17.0.
|
25
|
+
"@types/react": "~17.0.37",
|
26
26
|
"@types/react-input-mask": "~2.0.5",
|
27
|
-
"@types/uuid": "~8.3.
|
27
|
+
"@types/uuid": "~8.3.3",
|
28
28
|
"accounting": "~0.4.1",
|
29
29
|
"formstate": "~2.0.0",
|
30
|
-
"mobx": "~6.3.
|
30
|
+
"mobx": "~6.3.8",
|
31
31
|
"mobx-react": "~7.2.1",
|
32
32
|
"moment": "~2.29.1",
|
33
33
|
"react": "~17.0.2",
|
@@ -43,7 +43,7 @@
|
|
43
43
|
"@servicetitan/tokens": "~10.6.0",
|
44
44
|
"accounting": "~0.4.1",
|
45
45
|
"formstate": "~2.0.0",
|
46
|
-
"mobx": "~6.3.
|
46
|
+
"mobx": "~6.3.8",
|
47
47
|
"mobx-react": "~7.2.1",
|
48
48
|
"moment": "~2.29.1",
|
49
49
|
"react": "~17.0.2",
|
@@ -65,5 +65,5 @@
|
|
65
65
|
"cli": {
|
66
66
|
"webpack": false
|
67
67
|
},
|
68
|
-
"gitHead": "
|
68
|
+
"gitHead": "c2541cf4d4dc01064f7d327370a90f7b4d107a0e"
|
69
69
|
}
|
package/src/masked-input.tsx
CHANGED
@@ -13,6 +13,7 @@ export const MaskedInput: FC<MaskedInputProps> = ({
|
|
13
13
|
onChange,
|
14
14
|
placeholder,
|
15
15
|
disabled,
|
16
|
+
formatChars,
|
16
17
|
...props
|
17
18
|
}) => {
|
18
19
|
const handleInputChange = (e: ChangeEvent<HTMLInputElement>) => {
|
@@ -27,6 +28,7 @@ export const MaskedInput: FC<MaskedInputProps> = ({
|
|
27
28
|
onChange={handleInputChange}
|
28
29
|
placeholder={placeholder}
|
29
30
|
disabled={disabled}
|
31
|
+
formatChars={formatChars}
|
30
32
|
>
|
31
33
|
{(innerProps: InputHTMLAttributes<HTMLInputElement>) => (
|
32
34
|
<Form.Input {...props} {...innerProps} />
|