@kaspernj/api-maker 1.0.341 → 1.0.342
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/package.json +1 -1
- package/src/use-input.mjs +3 -8
package/package.json
CHANGED
package/src/use-input.mjs
CHANGED
|
@@ -18,12 +18,7 @@ const useInput = ({props, wrapperOptions}) => {
|
|
|
18
18
|
setForm()
|
|
19
19
|
}, [s.props.inputRef?.current])
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
() => ({
|
|
23
|
-
props
|
|
24
|
-
}),
|
|
25
|
-
[]
|
|
26
|
-
)
|
|
21
|
+
s.meta.fakeComponent = {props}
|
|
27
22
|
|
|
28
23
|
const formatValue = useCallback((value) => {
|
|
29
24
|
const {formatValue} = s.props
|
|
@@ -129,8 +124,8 @@ const useInput = ({props, wrapperOptions}) => {
|
|
|
129
124
|
if (form && form != s.s.form) s.set({form})
|
|
130
125
|
}, [])
|
|
131
126
|
|
|
132
|
-
const getId = useCallback(() => idForComponent(fakeComponent), [])
|
|
133
|
-
const getName = useCallback(() => nameForComponent(fakeComponent), [])
|
|
127
|
+
const getId = useCallback(() => idForComponent(s.m.fakeComponent), [])
|
|
128
|
+
const getName = useCallback(() => nameForComponent(s.m.fakeComponent), [])
|
|
134
129
|
|
|
135
130
|
const getInputProps = useCallback(() => {
|
|
136
131
|
const givenInputProps = s.props.inputProps || {}
|