@tanstack/react-form 0.0.1 → 0.0.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/build/cjs/formContext.js.map +1 -1
- package/build/cjs/index.js +7 -0
- package/build/cjs/index.js.map +1 -1
- package/build/esm/index.js +1 -0
- package/build/esm/index.js.map +1 -1
- package/build/stats-html.html +1 -1
- package/build/stats-react.json +116 -110
- package/build/types/form-core/src/FieldApi.d.ts +9 -11
- package/build/types/form-core/src/FormApi.d.ts +7 -3
- package/build/types/index.d.ts +1 -0
- package/build/types/react-form/src/formContext.d.ts +2 -2
- package/build/types/react-form/src/index.d.ts +1 -0
- package/build/umd/index.development.js +167 -74
- package/build/umd/index.development.js.map +1 -1
- package/build/umd/index.production.js +5 -4
- package/build/umd/index.production.js.map +1 -1
- package/package.json +2 -2
- package/src/formContext.ts +2 -2
- package/src/index.ts +1 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"formContext.js","sources":["../../src/formContext.ts"],"sourcesContent":["import { FormApi } from '@tanstack/form-core'\nimport * as React from 'react'\n\nexport const formContext = React.createContext<FormApi<any
|
|
1
|
+
{"version":3,"file":"formContext.js","sources":["../../src/formContext.ts"],"sourcesContent":["import type { FormApi } from '@tanstack/form-core'\nimport * as React from 'react'\n\nexport const formContext = React.createContext<FormApi<any> | null>(null)\n\nexport function useFormContext(customFormApi?: FormApi<any>) {\n const formApi = React.useContext(formContext)\n\n if (customFormApi) {\n return customFormApi\n }\n\n if (!formApi) {\n throw new Error(`You are trying to use the form API outside of a form!`)\n }\n\n return formApi\n}\n"],"names":["formContext","React","createContext","useFormContext","customFormApi","formApi","useContext","Error"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGO,MAAMA,WAAW,gBAAGC,gBAAK,CAACC,aAAN,CAAyC,IAAzC,EAApB;AAEA,SAASC,cAAT,CAAwBC,aAAxB,EAAsD;AAC3D,EAAA,MAAMC,OAAO,GAAGJ,gBAAK,CAACK,UAAN,CAAiBN,WAAjB,CAAhB,CAAA;;AAEA,EAAA,IAAII,aAAJ,EAAmB;AACjB,IAAA,OAAOA,aAAP,CAAA;AACD,GAAA;;EAED,IAAI,CAACC,OAAL,EAAc;IACZ,MAAM,IAAIE,KAAJ,CAAN,uDAAA,CAAA,CAAA;AACD,GAAA;;AAED,EAAA,OAAOF,OAAP,CAAA;AACD;;;;;"}
|
package/build/cjs/index.js
CHANGED
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
|
|
13
13
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
14
14
|
|
|
15
|
+
var formCore = require('@tanstack/form-core');
|
|
15
16
|
var useForm = require('./useForm.js');
|
|
16
17
|
var Field = require('./Field.js');
|
|
17
18
|
var useField = require('./useField.js');
|
|
@@ -24,4 +25,10 @@ exports.Field = Field.Field;
|
|
|
24
25
|
exports.createFieldComponent = Field.createFieldComponent;
|
|
25
26
|
exports.createUseField = useField.createUseField;
|
|
26
27
|
exports.useField = useField.useField;
|
|
28
|
+
Object.keys(formCore).forEach(function (k) {
|
|
29
|
+
if (k !== 'default' && !exports.hasOwnProperty(k)) Object.defineProperty(exports, k, {
|
|
30
|
+
enumerable: true,
|
|
31
|
+
get: function () { return formCore[k]; }
|
|
32
|
+
});
|
|
33
|
+
});
|
|
27
34
|
//# sourceMappingURL=index.js.map
|
package/build/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/build/esm/index.js
CHANGED
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
* @license MIT
|
|
10
10
|
*/
|
|
11
11
|
import { FieldApi, functionalUpdate, FormApi } from '@tanstack/form-core';
|
|
12
|
+
export * from '@tanstack/form-core';
|
|
12
13
|
import { useStore } from '@tanstack/react-store';
|
|
13
14
|
import * as React from 'react';
|
|
14
15
|
import React__default from 'react';
|
package/build/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../src/formContext.ts","../../src/useField.ts","../../src/Field.tsx","../../src/useForm.tsx"],"sourcesContent":["import { FormApi } from '@tanstack/form-core'\nimport * as React from 'react'\n\nexport const formContext = React.createContext<FormApi<any>>(null!)\n\nexport function useFormContext(customFormApi?: FormApi<any>) {\n const formApi = React.useContext(formContext)\n\n if (customFormApi) {\n return customFormApi\n }\n\n if (!formApi) {\n throw new Error(`You are trying to use the form API outside of a form!`)\n }\n\n return formApi\n}\n","import * as React from 'react'\n//\nimport { useStore } from '@tanstack/react-store'\nimport type {\n DeepKeys,\n DeepValue,\n FieldOptions,\n FormApi,\n} from '@tanstack/form-core'\nimport { FieldApi } from '@tanstack/form-core'\nimport { useFormContext } from './formContext'\n\nexport type UseField<TFormData> = <TField extends DeepKeys<TFormData>>(\n opts?: { name: TField } & FieldOptions<\n DeepValue<TFormData, TField>,\n TFormData\n >,\n) => FieldApi<DeepValue<TFormData, TField>, TFormData>\n\nexport function createUseField<TFormData>(formApi: FormApi<TFormData>) {\n const useFormField: UseField<TFormData> = (opts) => {\n return useField({ ...opts, form: formApi } as any)\n }\n\n return useFormField\n}\n\nexport function useField<TData, TFormData>(\n opts: FieldOptions<TData, TFormData> & {\n // selector: (state: FieldApi<TData, TFormData>) => TSelected\n },\n): FieldApi<TData, TFormData> {\n // invariant( // TODO:\n // opts.name,\n // `useField: A field is required to use this hook. eg, useField('myField', options)`\n // )\n\n // Get the form API either manually or from context\n const formApi = useFormContext(opts.form)\n\n const [fieldApi] = React.useState<FieldApi<TData, TFormData>>(\n () => new FieldApi({ ...opts, form: formApi }),\n )\n\n // Keep options up to date as they are rendered\n fieldApi.update({ ...opts, form: formApi })\n\n useStore(fieldApi.store)\n\n // Instantiates field meta and removes it when unrendered\n React.useEffect(() => fieldApi.mount(), [fieldApi])\n\n return fieldApi\n}\n","import * as React from 'react'\nimport {\n functionalUpdate,\n type DeepKeys,\n type DeepValue,\n type FieldApi,\n type FieldOptions,\n type FormApi,\n} from '@tanstack/form-core'\nimport { useField } from './useField'\n\n//\n\nexport type FieldComponent<TFormData> = <TField extends DeepKeys<TFormData>>({\n children,\n ...fieldOptions\n}: {\n children: (fieldApi: FieldApi<DeepValue<TFormData, TField>, TFormData>) => any\n name: TField\n} & Omit<FieldOptions<DeepValue<TFormData, TField>, TFormData>, 'name'>) => any\n\nexport function createFieldComponent<TFormData>(formApi: FormApi<TFormData>) {\n const ConnectedField: FieldComponent<TFormData> = (props) => (\n <Field {...(props as any)} form={formApi} />\n )\n return ConnectedField\n}\n\nexport function Field<TData, TFormData>({\n children,\n ...fieldOptions\n}: {\n children: (fieldApi: FieldApi<TData, TFormData>) => any\n} & FieldOptions<TData, TFormData>) {\n const fieldApi = useField(fieldOptions as any)\n return functionalUpdate(children, fieldApi as any)\n}\n","import type { FormState, FormOptions } from '@tanstack/form-core'\nimport { FormApi, functionalUpdate } from '@tanstack/form-core'\nimport type { NoInfer } from '@tanstack/react-store'\nimport { useStore } from '@tanstack/react-store'\nimport React from 'react'\nimport { createFieldComponent, type FieldComponent } from './Field'\nimport { createUseField, type UseField } from './useField'\nimport { formContext } from './formContext'\n\ndeclare module '@tanstack/form-core' {\n // eslint-disable-next-line no-shadow\n interface FormApi<TFormData> {\n Form: FormComponent\n Field: FieldComponent<TFormData>\n useField: UseField<TFormData>\n useStore: <TSelected = NoInfer<FormState<TFormData>>>(\n selector?: (state: NoInfer<FormState<TFormData>>) => TSelected,\n ) => TSelected\n Subscribe: <TSelected = NoInfer<FormState<TFormData>>>(props: {\n selector?: (state: NoInfer<FormState<TFormData>>) => TSelected\n children:\n | ((state: NoInfer<TSelected>) => React.ReactNode)\n | React.ReactNode\n }) => any\n }\n}\n//\n\nexport function useForm<TData>(opts?: FormOptions<TData>): FormApi<TData> {\n const [formApi] = React.useState(() => {\n // @ts-ignore\n const api = new FormApi<TData>(opts || {})\n\n api.Form = createFormComponent(api)\n api.Field = createFieldComponent(api)\n api.useField = createUseField(api)\n api.useStore = (\n // @ts-ignore\n selector,\n ) => {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n return useStore(api.store, selector) as any\n }\n api.Subscribe = (\n // @ts-ignore\n props,\n ) => {\n return functionalUpdate(\n props.children,\n // eslint-disable-next-line react-hooks/rules-of-hooks\n useStore(api.store, props.selector),\n ) as any\n }\n\n return api\n })\n\n // React.useEffect(() => formApi.mount(), [])\n\n return formApi\n}\n\nexport type FormProps = React.HTMLProps<HTMLFormElement> & {\n children: React.ReactNode\n noFormElement?: boolean\n}\n\nexport type FormComponent = (props: FormProps) => any\n\nexport function createFormComponent(formApi: FormApi<any>) {\n const Form: FormComponent = ({ children, noFormElement, ...rest }) => {\n const isSubmitting = formApi.useStore((state) => state.isSubmitting)\n\n return (\n <formContext.Provider value={formApi}>\n {noFormElement ? (\n children\n ) : (\n <form\n onSubmit={formApi.handleSubmit}\n disabled={isSubmitting}\n {...rest}\n >\n {formApi.options.debugForm ? (\n <div\n style={{\n margin: '2rem 0',\n }}\n >\n <div\n style={{\n fontWeight: 'bolder',\n }}\n >\n Form State\n </div>\n <pre>\n <code>\n {JSON.stringify(formApi, safeStringifyReplace(), 2)}\n </code>\n </pre>\n </div>\n ) : null}\n {children}\n </form>\n )}\n </formContext.Provider>\n )\n }\n\n return Form\n}\n\nfunction safeStringifyReplace() {\n const set = new Set()\n return (_key: string, value: any) => {\n if (typeof value === 'object' || Array.isArray(value)) {\n if (set.has(value)) {\n return '(circular value)'\n }\n set.add(value)\n }\n return typeof value === 'function' ? undefined : value\n }\n}\n"],"names":["formContext","React","createContext","useFormContext","customFormApi","formApi","useContext","Error","createUseField","useFormField","opts","useField","form","fieldApi","useState","FieldApi","update","useStore","store","useEffect","mount","createFieldComponent","ConnectedField","props","Field","children","fieldOptions","functionalUpdate","useForm","api","FormApi","Form","createFormComponent","selector","Subscribe","noFormElement","rest","isSubmitting","state","handleSubmit","options","debugForm","margin","fontWeight","JSON","stringify","safeStringifyReplace","set","Set","_key","value","Array","isArray","has","add","undefined"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGO,MAAMA,WAAW,gBAAGC,KAAK,CAACC,aAAN,CAAkC,IAAlC,CAApB,CAAA;AAEA,SAASC,cAAT,CAAwBC,aAAxB,EAAsD;AAC3D,EAAA,MAAMC,OAAO,GAAGJ,KAAK,CAACK,UAAN,CAAiBN,WAAjB,CAAhB,CAAA;;AAEA,EAAA,IAAII,aAAJ,EAAmB;AACjB,IAAA,OAAOA,aAAP,CAAA;AACD,GAAA;;EAED,IAAI,CAACC,OAAL,EAAc;IACZ,MAAM,IAAIE,KAAJ,CAAN,uDAAA,CAAA,CAAA;AACD,GAAA;;AAED,EAAA,OAAOF,OAAP,CAAA;AACD;;ACEM,SAASG,cAAT,CAAmCH,OAAnC,EAAgE;EACrE,MAAMI,YAAiC,GAAIC,IAAD,IAAU;AAClD,IAAA,OAAOC,QAAQ,CAAC,EAAE,GAAGD,IAAL;AAAWE,MAAAA,IAAI,EAAEP,OAAAA;AAAjB,KAAD,CAAf,CAAA;GADF,CAAA;;AAIA,EAAA,OAAOI,YAAP,CAAA;AACD,CAAA;AAEM,SAASE,QAAT,CACLD,IADK,EAIuB;AAC5B;AACA;AACA;AACA;AAEA;AACA,EAAA,MAAML,OAAO,GAAGF,cAAc,CAACO,IAAI,CAACE,IAAN,CAA9B,CAAA;AAEA,EAAA,MAAM,CAACC,QAAD,CAAaZ,GAAAA,KAAK,CAACa,QAAN,CACjB,MAAM,IAAIC,QAAJ,CAAa,EAAE,GAAGL,IAAL;AAAWE,IAAAA,IAAI,EAAEP,OAAAA;GAA9B,CADW,CAAnB,CAT4B;;AAc5BQ,EAAAA,QAAQ,CAACG,MAAT,CAAgB,EAAE,GAAGN,IAAL;AAAWE,IAAAA,IAAI,EAAEP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AAAA,aAAAA,CAAAA,MAAAA,EAAAA,IAAAA,EAAAA,IAAI,CAACC,SAAL,CAAexC,OAAf,EAAwByC,oBAAoB,EAA5C,EAAgD,CAAhD,CADH,CADF,CAZF,CADD,GAmBG,IAxBN,EAyBGrB,QAzBH,CAJJ,CADF,CAAA;GAHF,CAAA;;AAwCA,EAAA,OAAOM,IAAP,CAAA;AACD,CAAA;;AAED,SAASe,oBAAT,GAAgC;AAC9B,EAAA,MAAMC,GAAG,GAAG,IAAIC,GAAJ,EAAZ,CAAA;AACA,EAAA,OAAO,CAACC,IAAD,EAAeC,KAAf,KAA8B;IACnC,IAAI,OAAOA,KAAP,KAAiB,QAAjB,IAA6BC,KAAK,CAACC,OAAN,CAAcF,KAAd,CAAjC,EAAuD;AACrD,MAAA,IAAIH,GAAG,CAACM,GAAJ,CAAQH,KAAR,CAAJ,EAAoB;AAClB,QAAA,OAAO,kBAAP,CAAA;AACD,OAAA;;MACDH,GAAG,CAACO,GAAJ,CAAQJ,KAAR,CAAA,CAAA;AACD,KAAA;;AACD,IAAA,OAAO,OAAOA,KAAP,KAAiB,UAAjB,GAA8BK,SAA9B,GAA0CL,KAAjD,CAAA;GAPF,CAAA;AASD;;;;"}
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../src/formContext.ts","../../src/useField.ts","../../src/Field.tsx","../../src/useForm.tsx"],"sourcesContent":["import type { FormApi } from '@tanstack/form-core'\nimport * as React from 'react'\n\nexport const formContext = React.createContext<FormApi<any> | null>(null)\n\nexport function useFormContext(customFormApi?: FormApi<any>) {\n const formApi = React.useContext(formContext)\n\n if (customFormApi) {\n return customFormApi\n }\n\n if (!formApi) {\n throw new Error(`You are trying to use the form API outside of a form!`)\n }\n\n return formApi\n}\n","import * as React from 'react'\n//\nimport { useStore } from '@tanstack/react-store'\nimport type {\n DeepKeys,\n DeepValue,\n FieldOptions,\n FormApi,\n} from '@tanstack/form-core'\nimport { FieldApi } from '@tanstack/form-core'\nimport { useFormContext } from './formContext'\n\nexport type UseField<TFormData> = <TField extends DeepKeys<TFormData>>(\n opts?: { name: TField } & FieldOptions<\n DeepValue<TFormData, TField>,\n TFormData\n >,\n) => FieldApi<DeepValue<TFormData, TField>, TFormData>\n\nexport function createUseField<TFormData>(formApi: FormApi<TFormData>) {\n const useFormField: UseField<TFormData> = (opts) => {\n return useField({ ...opts, form: formApi } as any)\n }\n\n return useFormField\n}\n\nexport function useField<TData, TFormData>(\n opts: FieldOptions<TData, TFormData> & {\n // selector: (state: FieldApi<TData, TFormData>) => TSelected\n },\n): FieldApi<TData, TFormData> {\n // invariant( // TODO:\n // opts.name,\n // `useField: A field is required to use this hook. eg, useField('myField', options)`\n // )\n\n // Get the form API either manually or from context\n const formApi = useFormContext(opts.form)\n\n const [fieldApi] = React.useState<FieldApi<TData, TFormData>>(\n () => new FieldApi({ ...opts, form: formApi }),\n )\n\n // Keep options up to date as they are rendered\n fieldApi.update({ ...opts, form: formApi })\n\n useStore(fieldApi.store)\n\n // Instantiates field meta and removes it when unrendered\n React.useEffect(() => fieldApi.mount(), [fieldApi])\n\n return fieldApi\n}\n","import * as React from 'react'\nimport {\n functionalUpdate,\n type DeepKeys,\n type DeepValue,\n type FieldApi,\n type FieldOptions,\n type FormApi,\n} from '@tanstack/form-core'\nimport { useField } from './useField'\n\n//\n\nexport type FieldComponent<TFormData> = <TField extends DeepKeys<TFormData>>({\n children,\n ...fieldOptions\n}: {\n children: (fieldApi: FieldApi<DeepValue<TFormData, TField>, TFormData>) => any\n name: TField\n} & Omit<FieldOptions<DeepValue<TFormData, TField>, TFormData>, 'name'>) => any\n\nexport function createFieldComponent<TFormData>(formApi: FormApi<TFormData>) {\n const ConnectedField: FieldComponent<TFormData> = (props) => (\n <Field {...(props as any)} form={formApi} />\n )\n return ConnectedField\n}\n\nexport function Field<TData, TFormData>({\n children,\n ...fieldOptions\n}: {\n children: (fieldApi: FieldApi<TData, TFormData>) => any\n} & FieldOptions<TData, TFormData>) {\n const fieldApi = useField(fieldOptions as any)\n return functionalUpdate(children, fieldApi as any)\n}\n","import type { FormState, FormOptions } from '@tanstack/form-core'\nimport { FormApi, functionalUpdate } from '@tanstack/form-core'\nimport type { NoInfer } from '@tanstack/react-store'\nimport { useStore } from '@tanstack/react-store'\nimport React from 'react'\nimport { createFieldComponent, type FieldComponent } from './Field'\nimport { createUseField, type UseField } from './useField'\nimport { formContext } from './formContext'\n\ndeclare module '@tanstack/form-core' {\n // eslint-disable-next-line no-shadow\n interface FormApi<TFormData> {\n Form: FormComponent\n Field: FieldComponent<TFormData>\n useField: UseField<TFormData>\n useStore: <TSelected = NoInfer<FormState<TFormData>>>(\n selector?: (state: NoInfer<FormState<TFormData>>) => TSelected,\n ) => TSelected\n Subscribe: <TSelected = NoInfer<FormState<TFormData>>>(props: {\n selector?: (state: NoInfer<FormState<TFormData>>) => TSelected\n children:\n | ((state: NoInfer<TSelected>) => React.ReactNode)\n | React.ReactNode\n }) => any\n }\n}\n//\n\nexport function useForm<TData>(opts?: FormOptions<TData>): FormApi<TData> {\n const [formApi] = React.useState(() => {\n // @ts-ignore\n const api = new FormApi<TData>(opts || {})\n\n api.Form = createFormComponent(api)\n api.Field = createFieldComponent(api)\n api.useField = createUseField(api)\n api.useStore = (\n // @ts-ignore\n selector,\n ) => {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n return useStore(api.store, selector) as any\n }\n api.Subscribe = (\n // @ts-ignore\n props,\n ) => {\n return functionalUpdate(\n props.children,\n // eslint-disable-next-line react-hooks/rules-of-hooks\n useStore(api.store, props.selector),\n ) as any\n }\n\n return api\n })\n\n // React.useEffect(() => formApi.mount(), [])\n\n return formApi\n}\n\nexport type FormProps = React.HTMLProps<HTMLFormElement> & {\n children: React.ReactNode\n noFormElement?: boolean\n}\n\nexport type FormComponent = (props: FormProps) => any\n\nexport function createFormComponent(formApi: FormApi<any>) {\n const Form: FormComponent = ({ children, noFormElement, ...rest }) => {\n const isSubmitting = formApi.useStore((state) => state.isSubmitting)\n\n return (\n <formContext.Provider value={formApi}>\n {noFormElement ? (\n children\n ) : (\n <form\n onSubmit={formApi.handleSubmit}\n disabled={isSubmitting}\n {...rest}\n >\n {formApi.options.debugForm ? (\n <div\n style={{\n margin: '2rem 0',\n }}\n >\n <div\n style={{\n fontWeight: 'bolder',\n }}\n >\n Form State\n </div>\n <pre>\n <code>\n {JSON.stringify(formApi, safeStringifyReplace(), 2)}\n </code>\n </pre>\n </div>\n ) : null}\n {children}\n </form>\n )}\n </formContext.Provider>\n )\n }\n\n return Form\n}\n\nfunction safeStringifyReplace() {\n const set = new Set()\n return (_key: string, value: any) => {\n if (typeof value === 'object' || Array.isArray(value)) {\n if (set.has(value)) {\n return '(circular value)'\n }\n set.add(value)\n }\n return typeof value === 'function' ? undefined : value\n }\n}\n"],"names":["formContext","React","createContext","useFormContext","customFormApi","formApi","useContext","Error","createUseField","useFormField","opts","useField","form","fieldApi","useState","FieldApi","update","useStore","store","useEffect","mount","createFieldComponent","ConnectedField","props","Field","children","fieldOptions","functionalUpdate","useForm","api","FormApi","Form","createFormComponent","selector","Subscribe","noFormElement","rest","isSubmitting","state","handleSubmit","options","debugForm","margin","fontWeight","JSON","stringify","safeStringifyReplace","set","Set","_key","value","Array","isArray","has","add","undefined"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGO,MAAMA,WAAW,gBAAGC,KAAK,CAACC,aAAN,CAAyC,IAAzC,CAApB,CAAA;AAEA,SAASC,cAAT,CAAwBC,aAAxB,EAAsD;AAC3D,EAAA,MAAMC,OAAO,GAAGJ,KAAK,CAACK,UAAN,CAAiBN,WAAjB,CAAhB,CAAA;;AAEA,EAAA,IAAII,aAAJ,EAAmB;AACjB,IAAA,OAAOA,aAAP,CAAA;AACD,GAAA;;EAED,IAAI,CAACC,OAAL,EAAc;IACZ,MAAM,IAAIE,KAAJ,CAAN,uDAAA,CAAA,CAAA;AACD,GAAA;;AAED,EAAA,OAAOF,OAAP,CAAA;AACD;;ACEM,SAASG,cAAT,CAA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GAAJ,CAAQJ,KAAR,CAAA,CAAA;AACD,KAAA;;AACD,IAAA,OAAO,OAAOA,KAAP,KAAiB,UAAjB,GAA8BK,SAA9B,GAA0CL,KAAjD,CAAA;GAPF,CAAA;AASD;;;;"}
|
package/build/stats-html.html
CHANGED
|
@@ -2669,7 +2669,7 @@ var drawChart = (function (exports) {
|
|
|
2669
2669
|
</script>
|
|
2670
2670
|
<script>
|
|
2671
2671
|
/*<!--*/
|
|
2672
|
-
const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.production.js","children":[{"
|
|
2672
|
+
const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.production.js","children":[{"name":"node_modules/.pnpm","children":[{"name":"@tanstack+store@0.0.1-beta.84/node_modules/@tanstack/store/build/esm/index.js","uid":"e752-25"},{"name":"@tanstack+react-store@0.0.1-beta.84_react-dom@18.2.0_react@18.2.0/node_modules/@tanstack/react-store/build/esm/index.js","uid":"e752-31"}]},{"name":"packages","children":[{"name":"form-core/build/esm/index.js","uid":"e752-27"},{"name":"react-form/src","children":[{"uid":"e752-33","name":"formContext.ts"},{"uid":"e752-35","name":"useField.ts"},{"uid":"e752-37","name":"Field.tsx"},{"uid":"e752-39","name":"useForm.tsx"},{"uid":"e752-41","name":"index.ts"}]}]},{"uid":"e752-29","name":"\u0000rollupPluginBabelHelpers.js"}]}],"isRoot":true},"nodeParts":{"e752-25":{"renderedLength":1288,"gzipLength":497,"brotliLength":0,"mainUid":"e752-24"},"e752-27":{"renderedLength":23428,"gzipLength":5141,"brotliLength":0,"mainUid":"e752-26"},"e752-29":{"renderedLength":431,"gzipLength":240,"brotliLength":0,"mainUid":"e752-28"},"e752-31":{"renderedLength":978,"gzipLength":456,"brotliLength":0,"mainUid":"e752-30"},"e752-33":{"renderedLength":369,"gzipLength":218,"brotliLength":0,"mainUid":"e752-32"},"e752-35":{"renderedLength":850,"gzipLength":417,"brotliLength":0,"mainUid":"e752-34"},"e752-37":{"renderedLength":370,"gzipLength":227,"brotliLength":0,"mainUid":"e752-36"},"e752-39":{"renderedLength":2160,"gzipLength":767,"brotliLength":0,"mainUid":"e752-38"},"e752-41":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"e752-40"}},"nodeMetas":{"e752-24":{"id":"/node_modules/.pnpm/@tanstack+store@0.0.1-beta.84/node_modules/@tanstack/store/build/esm/index.js","moduleParts":{"index.production.js":"e752-25"},"imported":[],"importedBy":[{"uid":"e752-26"},{"uid":"e752-30"}]},"e752-26":{"id":"/packages/form-core/build/esm/index.js","moduleParts":{"index.production.js":"e752-27"},"imported":[{"uid":"e752-24"}],"importedBy":[{"uid":"e752-40"},{"uid":"e752-38"},{"uid":"e752-36"},{"uid":"e752-34"}]},"e752-28":{"id":"\u0000rollupPluginBabelHelpers.js","moduleParts":{"index.production.js":"e752-29"},"imported":[],"importedBy":[{"uid":"e752-38"},{"uid":"e752-36"}]},"e752-30":{"id":"/node_modules/.pnpm/@tanstack+react-store@0.0.1-beta.84_react-dom@18.2.0_react@18.2.0/node_modules/@tanstack/react-store/build/esm/index.js","moduleParts":{"index.production.js":"e752-31"},"imported":[{"uid":"e752-43"},{"uid":"e752-24"}],"importedBy":[{"uid":"e752-38"},{"uid":"e752-34"}]},"e752-32":{"id":"/packages/react-form/src/formContext.ts","moduleParts":{"index.production.js":"e752-33"},"imported":[{"uid":"e752-42"}],"importedBy":[{"uid":"e752-38"},{"uid":"e752-34"}]},"e752-34":{"id":"/packages/react-form/src/useField.ts","moduleParts":{"index.production.js":"e752-35"},"imported":[{"uid":"e752-42"},{"uid":"e752-30"},{"uid":"e752-26"},{"uid":"e752-32"}],"importedBy":[{"uid":"e752-40"},{"uid":"e752-38"},{"uid":"e752-36"}]},"e752-36":{"id":"/packages/react-form/src/Field.tsx","moduleParts":{"index.production.js":"e752-37"},"imported":[{"uid":"e752-28"},{"uid":"e752-42"},{"uid":"e752-26"},{"uid":"e752-34"}],"importedBy":[{"uid":"e752-40"},{"uid":"e752-38"}]},"e752-38":{"id":"/packages/react-form/src/useForm.tsx","moduleParts":{"index.production.js":"e752-39"},"imported":[{"uid":"e752-28"},{"uid":"e752-26"},{"uid":"e752-30"},{"uid":"e752-42"},{"uid":"e752-36"},{"uid":"e752-34"},{"uid":"e752-32"}],"importedBy":[{"uid":"e752-40"}]},"e752-40":{"id":"/packages/react-form/src/index.ts","moduleParts":{"index.production.js":"e752-41"},"imported":[{"uid":"e752-26"},{"uid":"e752-38"},{"uid":"e752-36"},{"uid":"e752-34"}],"importedBy":[],"isEntry":true},"e752-42":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"e752-38"},{"uid":"e752-36"},{"uid":"e752-34"},{"uid":"e752-32"}],"isExternal":true},"e752-43":{"id":"use-sync-external-store/shim/with-selector","moduleParts":{},"imported":[],"importedBy":[{"uid":"e752-30"}],"isExternal":true}},"env":{"rollup":"2.78.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
|
|
2673
2673
|
|
|
2674
2674
|
const run = () => {
|
|
2675
2675
|
const width = window.innerWidth;
|
package/build/stats-react.json
CHANGED
|
@@ -6,20 +6,16 @@
|
|
|
6
6
|
{
|
|
7
7
|
"name": "index.production.js",
|
|
8
8
|
"children": [
|
|
9
|
-
{
|
|
10
|
-
"uid": "52cd-45",
|
|
11
|
-
"name": "\u0000rollupPluginBabelHelpers.js"
|
|
12
|
-
},
|
|
13
9
|
{
|
|
14
10
|
"name": "node_modules/.pnpm",
|
|
15
11
|
"children": [
|
|
16
12
|
{
|
|
17
13
|
"name": "@tanstack+store@0.0.1-beta.84/node_modules/@tanstack/store/build/esm/index.js",
|
|
18
|
-
"uid": "
|
|
14
|
+
"uid": "e752-45"
|
|
19
15
|
},
|
|
20
16
|
{
|
|
21
17
|
"name": "@tanstack+react-store@0.0.1-beta.84_react-dom@18.2.0_react@18.2.0/node_modules/@tanstack/react-store/build/esm/index.js",
|
|
22
|
-
"uid": "
|
|
18
|
+
"uid": "e752-51"
|
|
23
19
|
}
|
|
24
20
|
]
|
|
25
21
|
},
|
|
@@ -28,34 +24,38 @@
|
|
|
28
24
|
"children": [
|
|
29
25
|
{
|
|
30
26
|
"name": "form-core/build/esm/index.js",
|
|
31
|
-
"uid": "
|
|
27
|
+
"uid": "e752-47"
|
|
32
28
|
},
|
|
33
29
|
{
|
|
34
30
|
"name": "react-form/src",
|
|
35
31
|
"children": [
|
|
36
32
|
{
|
|
37
|
-
"uid": "
|
|
33
|
+
"uid": "e752-53",
|
|
38
34
|
"name": "formContext.ts"
|
|
39
35
|
},
|
|
40
36
|
{
|
|
41
|
-
"uid": "
|
|
37
|
+
"uid": "e752-55",
|
|
42
38
|
"name": "useField.ts"
|
|
43
39
|
},
|
|
44
40
|
{
|
|
45
|
-
"uid": "
|
|
41
|
+
"uid": "e752-57",
|
|
46
42
|
"name": "Field.tsx"
|
|
47
43
|
},
|
|
48
44
|
{
|
|
49
|
-
"uid": "
|
|
45
|
+
"uid": "e752-59",
|
|
50
46
|
"name": "useForm.tsx"
|
|
51
47
|
},
|
|
52
48
|
{
|
|
53
|
-
"uid": "
|
|
49
|
+
"uid": "e752-61",
|
|
54
50
|
"name": "index.ts"
|
|
55
51
|
}
|
|
56
52
|
]
|
|
57
53
|
}
|
|
58
54
|
]
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"uid": "e752-49",
|
|
58
|
+
"name": "\u0000rollupPluginBabelHelpers.js"
|
|
59
59
|
}
|
|
60
60
|
]
|
|
61
61
|
}
|
|
@@ -63,294 +63,300 @@
|
|
|
63
63
|
"isRoot": true
|
|
64
64
|
},
|
|
65
65
|
"nodeParts": {
|
|
66
|
-
"
|
|
67
|
-
"renderedLength": 431,
|
|
68
|
-
"gzipLength": 240,
|
|
69
|
-
"brotliLength": 0,
|
|
70
|
-
"mainUid": "52cd-44"
|
|
71
|
-
},
|
|
72
|
-
"52cd-47": {
|
|
66
|
+
"e752-45": {
|
|
73
67
|
"renderedLength": 1288,
|
|
74
68
|
"gzipLength": 497,
|
|
75
69
|
"brotliLength": 0,
|
|
76
|
-
"mainUid": "
|
|
70
|
+
"mainUid": "e752-44"
|
|
77
71
|
},
|
|
78
|
-
"
|
|
79
|
-
"renderedLength":
|
|
80
|
-
"gzipLength":
|
|
72
|
+
"e752-47": {
|
|
73
|
+
"renderedLength": 23428,
|
|
74
|
+
"gzipLength": 5141,
|
|
81
75
|
"brotliLength": 0,
|
|
82
|
-
"mainUid": "
|
|
76
|
+
"mainUid": "e752-46"
|
|
83
77
|
},
|
|
84
|
-
"
|
|
78
|
+
"e752-49": {
|
|
79
|
+
"renderedLength": 431,
|
|
80
|
+
"gzipLength": 240,
|
|
81
|
+
"brotliLength": 0,
|
|
82
|
+
"mainUid": "e752-48"
|
|
83
|
+
},
|
|
84
|
+
"e752-51": {
|
|
85
85
|
"renderedLength": 978,
|
|
86
86
|
"gzipLength": 456,
|
|
87
87
|
"brotliLength": 0,
|
|
88
|
-
"mainUid": "
|
|
88
|
+
"mainUid": "e752-50"
|
|
89
89
|
},
|
|
90
|
-
"
|
|
90
|
+
"e752-53": {
|
|
91
91
|
"renderedLength": 369,
|
|
92
92
|
"gzipLength": 218,
|
|
93
93
|
"brotliLength": 0,
|
|
94
|
-
"mainUid": "
|
|
94
|
+
"mainUid": "e752-52"
|
|
95
95
|
},
|
|
96
|
-
"
|
|
96
|
+
"e752-55": {
|
|
97
97
|
"renderedLength": 850,
|
|
98
98
|
"gzipLength": 417,
|
|
99
99
|
"brotliLength": 0,
|
|
100
|
-
"mainUid": "
|
|
100
|
+
"mainUid": "e752-54"
|
|
101
101
|
},
|
|
102
|
-
"
|
|
102
|
+
"e752-57": {
|
|
103
103
|
"renderedLength": 370,
|
|
104
104
|
"gzipLength": 227,
|
|
105
105
|
"brotliLength": 0,
|
|
106
|
-
"mainUid": "
|
|
106
|
+
"mainUid": "e752-56"
|
|
107
107
|
},
|
|
108
|
-
"
|
|
108
|
+
"e752-59": {
|
|
109
109
|
"renderedLength": 2160,
|
|
110
110
|
"gzipLength": 767,
|
|
111
111
|
"brotliLength": 0,
|
|
112
|
-
"mainUid": "
|
|
112
|
+
"mainUid": "e752-58"
|
|
113
113
|
},
|
|
114
|
-
"
|
|
114
|
+
"e752-61": {
|
|
115
115
|
"renderedLength": 0,
|
|
116
116
|
"gzipLength": 0,
|
|
117
117
|
"brotliLength": 0,
|
|
118
|
-
"mainUid": "
|
|
118
|
+
"mainUid": "e752-60"
|
|
119
119
|
}
|
|
120
120
|
},
|
|
121
121
|
"nodeMetas": {
|
|
122
|
-
"
|
|
123
|
-
"id": "
|
|
122
|
+
"e752-44": {
|
|
123
|
+
"id": "/node_modules/.pnpm/@tanstack+store@0.0.1-beta.84/node_modules/@tanstack/store/build/esm/index.js",
|
|
124
124
|
"moduleParts": {
|
|
125
|
-
"index.production.js": "
|
|
125
|
+
"index.production.js": "e752-45"
|
|
126
126
|
},
|
|
127
127
|
"imported": [],
|
|
128
128
|
"importedBy": [
|
|
129
129
|
{
|
|
130
|
-
"uid": "
|
|
130
|
+
"uid": "e752-46"
|
|
131
131
|
},
|
|
132
132
|
{
|
|
133
|
-
"uid": "
|
|
133
|
+
"uid": "e752-50"
|
|
134
134
|
}
|
|
135
135
|
]
|
|
136
136
|
},
|
|
137
|
-
"
|
|
138
|
-
"id": "/
|
|
137
|
+
"e752-46": {
|
|
138
|
+
"id": "/packages/form-core/build/esm/index.js",
|
|
139
139
|
"moduleParts": {
|
|
140
|
-
"index.production.js": "
|
|
140
|
+
"index.production.js": "e752-47"
|
|
141
141
|
},
|
|
142
|
-
"imported": [
|
|
142
|
+
"imported": [
|
|
143
|
+
{
|
|
144
|
+
"uid": "e752-44"
|
|
145
|
+
}
|
|
146
|
+
],
|
|
143
147
|
"importedBy": [
|
|
144
148
|
{
|
|
145
|
-
"uid": "
|
|
149
|
+
"uid": "e752-60"
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
"uid": "e752-58"
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
"uid": "e752-56"
|
|
146
156
|
},
|
|
147
157
|
{
|
|
148
|
-
"uid": "
|
|
158
|
+
"uid": "e752-54"
|
|
149
159
|
}
|
|
150
160
|
]
|
|
151
161
|
},
|
|
152
|
-
"
|
|
153
|
-
"id": "
|
|
162
|
+
"e752-48": {
|
|
163
|
+
"id": "\u0000rollupPluginBabelHelpers.js",
|
|
154
164
|
"moduleParts": {
|
|
155
|
-
"index.production.js": "
|
|
165
|
+
"index.production.js": "e752-49"
|
|
156
166
|
},
|
|
157
|
-
"imported": [
|
|
158
|
-
{
|
|
159
|
-
"uid": "52cd-46"
|
|
160
|
-
}
|
|
161
|
-
],
|
|
167
|
+
"imported": [],
|
|
162
168
|
"importedBy": [
|
|
163
169
|
{
|
|
164
|
-
"uid": "
|
|
170
|
+
"uid": "e752-58"
|
|
165
171
|
},
|
|
166
172
|
{
|
|
167
|
-
"uid": "
|
|
168
|
-
},
|
|
169
|
-
{
|
|
170
|
-
"uid": "52cd-54"
|
|
173
|
+
"uid": "e752-56"
|
|
171
174
|
}
|
|
172
175
|
]
|
|
173
176
|
},
|
|
174
|
-
"
|
|
177
|
+
"e752-50": {
|
|
175
178
|
"id": "/node_modules/.pnpm/@tanstack+react-store@0.0.1-beta.84_react-dom@18.2.0_react@18.2.0/node_modules/@tanstack/react-store/build/esm/index.js",
|
|
176
179
|
"moduleParts": {
|
|
177
|
-
"index.production.js": "
|
|
180
|
+
"index.production.js": "e752-51"
|
|
178
181
|
},
|
|
179
182
|
"imported": [
|
|
180
183
|
{
|
|
181
|
-
"uid": "
|
|
184
|
+
"uid": "e752-63"
|
|
182
185
|
},
|
|
183
186
|
{
|
|
184
|
-
"uid": "
|
|
187
|
+
"uid": "e752-44"
|
|
185
188
|
}
|
|
186
189
|
],
|
|
187
190
|
"importedBy": [
|
|
188
191
|
{
|
|
189
|
-
"uid": "
|
|
192
|
+
"uid": "e752-58"
|
|
190
193
|
},
|
|
191
194
|
{
|
|
192
|
-
"uid": "
|
|
195
|
+
"uid": "e752-54"
|
|
193
196
|
}
|
|
194
197
|
]
|
|
195
198
|
},
|
|
196
|
-
"
|
|
199
|
+
"e752-52": {
|
|
197
200
|
"id": "/packages/react-form/src/formContext.ts",
|
|
198
201
|
"moduleParts": {
|
|
199
|
-
"index.production.js": "
|
|
202
|
+
"index.production.js": "e752-53"
|
|
200
203
|
},
|
|
201
204
|
"imported": [
|
|
202
205
|
{
|
|
203
|
-
"uid": "
|
|
206
|
+
"uid": "e752-62"
|
|
204
207
|
}
|
|
205
208
|
],
|
|
206
209
|
"importedBy": [
|
|
207
210
|
{
|
|
208
|
-
"uid": "
|
|
211
|
+
"uid": "e752-58"
|
|
209
212
|
},
|
|
210
213
|
{
|
|
211
|
-
"uid": "
|
|
214
|
+
"uid": "e752-54"
|
|
212
215
|
}
|
|
213
216
|
]
|
|
214
217
|
},
|
|
215
|
-
"
|
|
218
|
+
"e752-54": {
|
|
216
219
|
"id": "/packages/react-form/src/useField.ts",
|
|
217
220
|
"moduleParts": {
|
|
218
|
-
"index.production.js": "
|
|
221
|
+
"index.production.js": "e752-55"
|
|
219
222
|
},
|
|
220
223
|
"imported": [
|
|
221
224
|
{
|
|
222
|
-
"uid": "
|
|
225
|
+
"uid": "e752-62"
|
|
223
226
|
},
|
|
224
227
|
{
|
|
225
|
-
"uid": "
|
|
228
|
+
"uid": "e752-50"
|
|
226
229
|
},
|
|
227
230
|
{
|
|
228
|
-
"uid": "
|
|
231
|
+
"uid": "e752-46"
|
|
229
232
|
},
|
|
230
233
|
{
|
|
231
|
-
"uid": "
|
|
234
|
+
"uid": "e752-52"
|
|
232
235
|
}
|
|
233
236
|
],
|
|
234
237
|
"importedBy": [
|
|
235
238
|
{
|
|
236
|
-
"uid": "
|
|
239
|
+
"uid": "e752-60"
|
|
237
240
|
},
|
|
238
241
|
{
|
|
239
|
-
"uid": "
|
|
242
|
+
"uid": "e752-58"
|
|
240
243
|
},
|
|
241
244
|
{
|
|
242
|
-
"uid": "
|
|
245
|
+
"uid": "e752-56"
|
|
243
246
|
}
|
|
244
247
|
]
|
|
245
248
|
},
|
|
246
|
-
"
|
|
249
|
+
"e752-56": {
|
|
247
250
|
"id": "/packages/react-form/src/Field.tsx",
|
|
248
251
|
"moduleParts": {
|
|
249
|
-
"index.production.js": "
|
|
252
|
+
"index.production.js": "e752-57"
|
|
250
253
|
},
|
|
251
254
|
"imported": [
|
|
252
255
|
{
|
|
253
|
-
"uid": "
|
|
256
|
+
"uid": "e752-48"
|
|
254
257
|
},
|
|
255
258
|
{
|
|
256
|
-
"uid": "
|
|
259
|
+
"uid": "e752-62"
|
|
257
260
|
},
|
|
258
261
|
{
|
|
259
|
-
"uid": "
|
|
262
|
+
"uid": "e752-46"
|
|
260
263
|
},
|
|
261
264
|
{
|
|
262
|
-
"uid": "
|
|
265
|
+
"uid": "e752-54"
|
|
263
266
|
}
|
|
264
267
|
],
|
|
265
268
|
"importedBy": [
|
|
266
269
|
{
|
|
267
|
-
"uid": "
|
|
270
|
+
"uid": "e752-60"
|
|
268
271
|
},
|
|
269
272
|
{
|
|
270
|
-
"uid": "
|
|
273
|
+
"uid": "e752-58"
|
|
271
274
|
}
|
|
272
275
|
]
|
|
273
276
|
},
|
|
274
|
-
"
|
|
277
|
+
"e752-58": {
|
|
275
278
|
"id": "/packages/react-form/src/useForm.tsx",
|
|
276
279
|
"moduleParts": {
|
|
277
|
-
"index.production.js": "
|
|
280
|
+
"index.production.js": "e752-59"
|
|
278
281
|
},
|
|
279
282
|
"imported": [
|
|
280
283
|
{
|
|
281
|
-
"uid": "
|
|
284
|
+
"uid": "e752-48"
|
|
282
285
|
},
|
|
283
286
|
{
|
|
284
|
-
"uid": "
|
|
287
|
+
"uid": "e752-46"
|
|
285
288
|
},
|
|
286
289
|
{
|
|
287
|
-
"uid": "
|
|
290
|
+
"uid": "e752-50"
|
|
288
291
|
},
|
|
289
292
|
{
|
|
290
|
-
"uid": "
|
|
293
|
+
"uid": "e752-62"
|
|
291
294
|
},
|
|
292
295
|
{
|
|
293
|
-
"uid": "
|
|
296
|
+
"uid": "e752-56"
|
|
294
297
|
},
|
|
295
298
|
{
|
|
296
|
-
"uid": "
|
|
299
|
+
"uid": "e752-54"
|
|
297
300
|
},
|
|
298
301
|
{
|
|
299
|
-
"uid": "
|
|
302
|
+
"uid": "e752-52"
|
|
300
303
|
}
|
|
301
304
|
],
|
|
302
305
|
"importedBy": [
|
|
303
306
|
{
|
|
304
|
-
"uid": "
|
|
307
|
+
"uid": "e752-60"
|
|
305
308
|
}
|
|
306
309
|
]
|
|
307
310
|
},
|
|
308
|
-
"
|
|
311
|
+
"e752-60": {
|
|
309
312
|
"id": "/packages/react-form/src/index.ts",
|
|
310
313
|
"moduleParts": {
|
|
311
|
-
"index.production.js": "
|
|
314
|
+
"index.production.js": "e752-61"
|
|
312
315
|
},
|
|
313
316
|
"imported": [
|
|
314
317
|
{
|
|
315
|
-
"uid": "
|
|
318
|
+
"uid": "e752-46"
|
|
319
|
+
},
|
|
320
|
+
{
|
|
321
|
+
"uid": "e752-58"
|
|
316
322
|
},
|
|
317
323
|
{
|
|
318
|
-
"uid": "
|
|
324
|
+
"uid": "e752-56"
|
|
319
325
|
},
|
|
320
326
|
{
|
|
321
|
-
"uid": "
|
|
327
|
+
"uid": "e752-54"
|
|
322
328
|
}
|
|
323
329
|
],
|
|
324
330
|
"importedBy": [],
|
|
325
331
|
"isEntry": true
|
|
326
332
|
},
|
|
327
|
-
"
|
|
333
|
+
"e752-62": {
|
|
328
334
|
"id": "react",
|
|
329
335
|
"moduleParts": {},
|
|
330
336
|
"imported": [],
|
|
331
337
|
"importedBy": [
|
|
332
338
|
{
|
|
333
|
-
"uid": "
|
|
339
|
+
"uid": "e752-58"
|
|
334
340
|
},
|
|
335
341
|
{
|
|
336
|
-
"uid": "
|
|
342
|
+
"uid": "e752-56"
|
|
337
343
|
},
|
|
338
344
|
{
|
|
339
|
-
"uid": "
|
|
345
|
+
"uid": "e752-54"
|
|
340
346
|
},
|
|
341
347
|
{
|
|
342
|
-
"uid": "
|
|
348
|
+
"uid": "e752-52"
|
|
343
349
|
}
|
|
344
350
|
],
|
|
345
351
|
"isExternal": true
|
|
346
352
|
},
|
|
347
|
-
"
|
|
353
|
+
"e752-63": {
|
|
348
354
|
"id": "use-sync-external-store/shim/with-selector",
|
|
349
355
|
"moduleParts": {},
|
|
350
356
|
"imported": [],
|
|
351
357
|
"importedBy": [
|
|
352
358
|
{
|
|
353
|
-
"uid": "
|
|
359
|
+
"uid": "e752-50"
|
|
354
360
|
}
|
|
355
361
|
],
|
|
356
362
|
"isExternal": true
|