@kanda-libs/ks-component-ts 0.2.476 → 0.2.478
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/app/src/App.tsx +18 -30
- package/dist/index.d.ts +13249 -13246
- package/dist/index.esm.js +4 -4
- package/dist/index.esm.js.map +3 -3
- package/dist/library.css +9 -10
- package/package.json +1 -1
- package/src/components/FormTheme/index.tsx +7 -2
- package/src/field/components/Address/AddressPostcode/AddressPostcodeUncontrolled/helpers.ts +1 -1
- package/src/field/components/Address/AddressSelect/useAddressSelectProps.ts +2 -2
- package/src/field/components/Address/types.d.ts +9 -6
- package/src/field/components/PhoneNumberInput/PhoneNumberInputUncontrolled/PhoneNumberInputUncontrolled.tsx +1 -1
- package/src/field/components/PhoneNumberInput/PhoneNumberInputUncontrolled/usePhoneNumberInputUncontrolled.ts +5 -1
- package/src/field/components/PhoneNumberInput/constants.ts +5 -1
- package/src/generated/widget/index.tsx +71174 -71175
- package/src/styles/library.css +9 -10
- package/src/types.d.ts +1 -0
package/app/src/App.tsx
CHANGED
|
@@ -9,6 +9,8 @@ import {
|
|
|
9
9
|
Label,
|
|
10
10
|
SearchInput,
|
|
11
11
|
ValidationItems,
|
|
12
|
+
Widget,
|
|
13
|
+
FormTheme,
|
|
12
14
|
} from "@kanda-libs/ks-component-ts";
|
|
13
15
|
import { StringIndexedObject } from "~/types";
|
|
14
16
|
import { useEffect, useState } from "react";
|
|
@@ -25,10 +27,6 @@ const capitalise = (str: string) => str.charAt(0).toUpperCase() + str.slice(1);
|
|
|
25
27
|
function App() {
|
|
26
28
|
const form = useForm({
|
|
27
29
|
mode: "onBlur",
|
|
28
|
-
defaultValues: {
|
|
29
|
-
range1: "100000",
|
|
30
|
-
range2: "100000",
|
|
31
|
-
},
|
|
32
30
|
});
|
|
33
31
|
|
|
34
32
|
const { watch, setValue } = form;
|
|
@@ -71,38 +69,28 @@ function App() {
|
|
|
71
69
|
|
|
72
70
|
return (
|
|
73
71
|
<div style={{ maxWidth: 500 }}>
|
|
74
|
-
<
|
|
75
|
-
<button
|
|
76
|
-
onClick={() => {
|
|
77
|
-
console.log("click");
|
|
78
|
-
setIsLoading(!isLoading);
|
|
79
|
-
}}
|
|
80
|
-
className="mb-10"
|
|
81
|
-
>
|
|
82
|
-
change
|
|
83
|
-
</button>
|
|
84
|
-
<div className="px-5">
|
|
72
|
+
<div className="p-5">
|
|
85
73
|
<Form
|
|
86
74
|
id="ksts-test-form"
|
|
87
75
|
form={form}
|
|
88
76
|
onSubmit={onSubmit}
|
|
89
|
-
className="flex flex-col"
|
|
77
|
+
className="flex flex-col p-6 bg-neutral-100"
|
|
90
78
|
>
|
|
91
|
-
<
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
79
|
+
<FormTheme variant="inline">
|
|
80
|
+
<Widget.JobCustomerPhone className="bg-neutral-000 mb-10" />
|
|
81
|
+
</FormTheme>
|
|
82
|
+
<FormTheme variant="default">
|
|
83
|
+
<Widget.JobCustomerPhone
|
|
84
|
+
className="bg-neutral-000"
|
|
85
|
+
name="defaultphone"
|
|
86
|
+
/>
|
|
87
|
+
</FormTheme>
|
|
88
|
+
<Button.Text
|
|
89
|
+
submit
|
|
90
|
+
label="submit"
|
|
91
|
+
id="ksts-test-form-submit"
|
|
92
|
+
className="mt-6"
|
|
104
93
|
/>
|
|
105
|
-
<Button.Text submit label="submit" id="ksts-test-form-submit" />
|
|
106
94
|
</Form>
|
|
107
95
|
</div>
|
|
108
96
|
</div>
|