amis-core 6.0.0 → 6.1.0
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/esm/Root.js +2 -2
- package/esm/RootRenderer.js +4 -3
- package/esm/SchemaRenderer.js +5 -2
- package/esm/Scoped.d.ts +6 -0
- package/esm/Scoped.js +45 -8
- package/esm/StatusScoped.js +2 -2
- package/esm/WithRootStore.js +2 -2
- package/esm/WithStore.js +4 -6
- package/esm/actions/Action.js +2 -2
- package/esm/actions/AjaxAction.js +2 -2
- package/esm/actions/BreakAction.js +2 -2
- package/esm/actions/BroadcastAction.js +2 -2
- package/esm/actions/CmptAction.js +2 -2
- package/esm/actions/ContinueAction.js +2 -2
- package/esm/actions/CopyAction.js +2 -2
- package/esm/actions/CustomAction.js +3 -3
- package/esm/actions/DialogAction.js +2 -2
- package/esm/actions/DrawerAction.js +2 -2
- package/esm/actions/EmailAction.js +2 -2
- package/esm/actions/LinkAction.js +10 -5
- package/esm/actions/LoopAction.js +2 -2
- package/esm/actions/PageAction.js +2 -2
- package/esm/actions/ParallelAction.js +2 -2
- package/esm/actions/StatusAction.js +2 -2
- package/esm/actions/SwitchAction.js +2 -2
- package/esm/actions/ToastAction.js +2 -2
- package/esm/components/CustomStyle.d.ts +1 -2
- package/esm/components/CustomStyle.js +20 -7
- package/esm/components/ErrorBoundary.js +2 -2
- package/esm/components/LazyComponent.js +2 -2
- package/esm/components/Overlay.js +11 -9
- package/esm/components/PopOver.js +7 -5
- package/esm/env.d.ts +4 -0
- package/esm/env.js +2 -2
- package/esm/envOverwrite.js +2 -2
- package/esm/factory.js +15 -2
- package/esm/index.d.ts +2 -2
- package/esm/index.js +13 -8
- package/esm/locale.js +2 -2
- package/esm/polyfills.js +2 -2
- package/esm/renderers/Form.d.ts +4 -3
- package/esm/renderers/Form.js +94 -42
- package/esm/renderers/Item.d.ts +1 -0
- package/esm/renderers/Item.js +15 -16
- package/esm/renderers/Options.d.ts +5 -0
- package/esm/renderers/Options.js +27 -10
- package/esm/renderers/Placeholder.js +2 -2
- package/esm/renderers/builtin.js +2 -2
- package/esm/renderers/register.js +2 -2
- package/esm/renderers/wrapControl.js +37 -29
- package/esm/store/app.js +3 -3
- package/esm/store/combo.d.ts +48 -24
- package/esm/store/combo.js +2 -2
- package/esm/store/crud.js +2 -2
- package/esm/store/form.d.ts +20 -10
- package/esm/store/form.js +2 -2
- package/esm/store/formItem.d.ts +2 -1
- package/esm/store/formItem.js +4 -3
- package/esm/store/iRenderer.js +5 -3
- package/esm/store/index.js +2 -2
- package/esm/store/list.js +2 -2
- package/esm/store/manager.js +2 -2
- package/esm/store/modal.js +2 -2
- package/esm/store/node.js +2 -2
- package/esm/store/pagination.js +2 -2
- package/esm/store/root.js +3 -3
- package/esm/store/service.js +2 -2
- package/esm/store/status.js +2 -2
- package/esm/store/table.d.ts +42 -20
- package/esm/store/table.js +33 -19
- package/esm/store/table2.js +2 -2
- package/esm/theme.js +2 -2
- package/esm/utils/Animation.js +2 -2
- package/esm/utils/ColorScale.js +2 -2
- package/esm/utils/DataSchema.js +2 -2
- package/esm/utils/DataScope.js +2 -2
- package/esm/utils/RootClose.js +2 -2
- package/esm/utils/SimpleMap.js +2 -2
- package/esm/utils/api.js +2 -2
- package/esm/utils/arraySlice.js +2 -2
- package/esm/utils/attachmentAdpator.js +2 -2
- package/esm/utils/autobind.js +2 -2
- package/esm/utils/browser.js +2 -2
- package/esm/utils/columnsSplit.js +2 -2
- package/esm/utils/concatData.js +2 -2
- package/esm/utils/dataMapping.js +2 -2
- package/esm/utils/date.js +2 -2
- package/esm/utils/debug.js +2 -2
- package/esm/utils/decodeEntity.js +2 -2
- package/esm/utils/dom.js +2 -2
- package/esm/utils/errors.js +2 -2
- package/esm/utils/escapeHtml.js +2 -2
- package/esm/utils/filter-schema.js +2 -2
- package/esm/utils/filter.js +2 -2
- package/esm/utils/formatDuration.js +2 -2
- package/esm/utils/formula.js +2 -2
- package/esm/utils/getVariable.js +2 -2
- package/esm/utils/grammar.js +2 -2
- package/esm/utils/handleAction.js +2 -2
- package/esm/utils/helper.d.ts +8 -1
- package/esm/utils/helper.js +28 -10
- package/esm/utils/highlight.js +4 -3
- package/esm/utils/icon.js +2 -2
- package/esm/utils/image.js +2 -2
- package/esm/utils/index.d.ts +1 -0
- package/esm/utils/isPureVariable.js +2 -2
- package/esm/utils/json-schema-2-amis-schema.js +2 -2
- package/esm/utils/keyToPath.js +2 -2
- package/esm/utils/labelToString.d.ts +1 -0
- package/esm/utils/labelToString.js +38 -0
- package/esm/utils/makeSorter.js +2 -2
- package/esm/utils/math.js +2 -2
- package/esm/utils/memoryParse.js +2 -2
- package/esm/utils/normalizeLink.js +2 -2
- package/esm/utils/normalizeOptions.js +2 -2
- package/esm/utils/object.js +2 -2
- package/esm/utils/offset.js +2 -2
- package/esm/utils/offsetParent.js +2 -2
- package/esm/utils/optionValueCompare.js +2 -2
- package/esm/utils/position.js +2 -2
- package/esm/utils/prettyBytes.js +2 -2
- package/esm/utils/renderer-event.js +2 -2
- package/esm/utils/replaceText.js +10 -12
- package/esm/utils/resize-sensor.js +2 -2
- package/esm/utils/resolveCondition.js +2 -2
- package/esm/utils/resolveVariable.js +2 -2
- package/esm/utils/resolveVariableAndFilter.js +2 -2
- package/esm/utils/resolveVariableAndFilterForAsync.js +2 -2
- package/esm/utils/scrollPosition.js +2 -2
- package/esm/utils/string2regExp.d.ts +1 -1
- package/esm/utils/string2regExp.js +5 -4
- package/esm/utils/stripNumber.js +2 -2
- package/esm/utils/style-helper.d.ts +24 -5
- package/esm/utils/style-helper.js +47 -17
- package/esm/utils/style.js +2 -2
- package/esm/utils/toNumber.js +2 -2
- package/esm/utils/tokenize.d.ts +1 -0
- package/esm/utils/tokenize.js +11 -4
- package/esm/utils/tpl-builtin.js +2 -2
- package/esm/utils/tpl-lodash.js +2 -2
- package/esm/utils/tpl.js +7 -9
- package/esm/utils/uncontrollable.js +2 -2
- package/esm/utils/validateId.d.ts +16 -0
- package/esm/utils/validateId.js +154 -0
- package/esm/utils/validations.js +17 -9
- package/lib/Root.js +2 -2
- package/lib/RootRenderer.d.ts +1 -1
- package/lib/RootRenderer.js +4 -3
- package/lib/SchemaRenderer.js +5 -2
- package/lib/Scoped.d.ts +6 -0
- package/lib/Scoped.js +45 -7
- package/lib/StatusScoped.js +2 -2
- package/lib/WithRootStore.js +2 -2
- package/lib/WithStore.js +4 -6
- package/lib/actions/Action.js +2 -2
- package/lib/actions/AjaxAction.js +2 -2
- package/lib/actions/BreakAction.js +2 -2
- package/lib/actions/BroadcastAction.js +2 -2
- package/lib/actions/CmptAction.js +2 -2
- package/lib/actions/ContinueAction.js +2 -2
- package/lib/actions/CopyAction.js +2 -2
- package/lib/actions/CustomAction.js +3 -3
- package/lib/actions/DialogAction.js +2 -2
- package/lib/actions/DrawerAction.js +2 -2
- package/lib/actions/EmailAction.js +2 -2
- package/lib/actions/LinkAction.js +10 -5
- package/lib/actions/LoopAction.js +2 -2
- package/lib/actions/PageAction.js +2 -2
- package/lib/actions/ParallelAction.js +2 -2
- package/lib/actions/StatusAction.js +2 -2
- package/lib/actions/SwitchAction.js +2 -2
- package/lib/actions/ToastAction.js +2 -2
- package/lib/components/CustomStyle.d.ts +1 -2
- package/lib/components/CustomStyle.js +20 -7
- package/lib/components/ErrorBoundary.js +2 -2
- package/lib/components/LazyComponent.js +2 -2
- package/lib/components/Overlay.js +10 -8
- package/lib/components/PopOver.js +7 -5
- package/lib/env.d.ts +4 -0
- package/lib/env.js +2 -2
- package/lib/envOverwrite.js +2 -2
- package/lib/factory.js +15 -2
- package/lib/index.d.ts +2 -2
- package/lib/index.js +16 -5
- package/lib/locale.js +2 -2
- package/lib/polyfills.js +2 -2
- package/lib/renderers/Form.d.ts +4 -3
- package/lib/renderers/Form.js +94 -42
- package/lib/renderers/Item.d.ts +1 -0
- package/lib/renderers/Item.js +15 -16
- package/lib/renderers/Options.d.ts +5 -0
- package/lib/renderers/Options.js +27 -10
- package/lib/renderers/Placeholder.js +2 -2
- package/lib/renderers/builtin.js +2 -2
- package/lib/renderers/register.js +2 -2
- package/lib/renderers/wrapControl.js +36 -28
- package/lib/store/app.js +3 -3
- package/lib/store/combo.d.ts +72 -49
- package/lib/store/combo.js +2 -2
- package/lib/store/crud.js +2 -2
- package/lib/store/form.d.ts +30 -21
- package/lib/store/form.js +2 -2
- package/lib/store/formItem.d.ts +2 -1
- package/lib/store/formItem.js +4 -3
- package/lib/store/iRenderer.js +5 -3
- package/lib/store/index.js +2 -2
- package/lib/store/list.js +2 -2
- package/lib/store/manager.js +2 -2
- package/lib/store/modal.js +2 -2
- package/lib/store/node.js +2 -2
- package/lib/store/pagination.js +2 -2
- package/lib/store/root.js +3 -3
- package/lib/store/service.js +2 -2
- package/lib/store/status.js +2 -2
- package/lib/store/table.d.ts +62 -41
- package/lib/store/table.js +33 -19
- package/lib/store/table2.js +2 -2
- package/lib/theme.js +2 -2
- package/lib/utils/Animation.js +2 -2
- package/lib/utils/ColorScale.js +2 -2
- package/lib/utils/DataSchema.js +2 -2
- package/lib/utils/DataScope.js +2 -2
- package/lib/utils/RootClose.js +2 -2
- package/lib/utils/SimpleMap.js +2 -2
- package/lib/utils/api.js +2 -2
- package/lib/utils/arraySlice.js +2 -2
- package/lib/utils/attachmentAdpator.js +2 -2
- package/lib/utils/autobind.js +2 -2
- package/lib/utils/browser.js +2 -2
- package/lib/utils/columnsSplit.js +2 -2
- package/lib/utils/concatData.js +2 -2
- package/lib/utils/dataMapping.js +2 -2
- package/lib/utils/date.js +2 -2
- package/lib/utils/debug.js +2 -2
- package/lib/utils/decodeEntity.js +2 -2
- package/lib/utils/dom.js +2 -2
- package/lib/utils/errors.js +2 -2
- package/lib/utils/escapeHtml.js +2 -2
- package/lib/utils/filter-schema.js +2 -2
- package/lib/utils/filter.js +2 -2
- package/lib/utils/formatDuration.js +2 -2
- package/lib/utils/formula.js +2 -2
- package/lib/utils/getVariable.js +2 -2
- package/lib/utils/grammar.js +2 -2
- package/lib/utils/handleAction.js +2 -2
- package/lib/utils/helper.d.ts +8 -1
- package/lib/utils/helper.js +29 -8
- package/lib/utils/highlight.js +4 -3
- package/lib/utils/icon.js +2 -2
- package/lib/utils/image.js +2 -2
- package/lib/utils/index.d.ts +1 -0
- package/lib/utils/isPureVariable.js +2 -2
- package/lib/utils/json-schema-2-amis-schema.js +2 -2
- package/lib/utils/keyToPath.js +2 -2
- package/lib/utils/labelToString.d.ts +1 -0
- package/lib/utils/labelToString.js +46 -0
- package/lib/utils/makeSorter.js +2 -2
- package/lib/utils/math.js +2 -2
- package/lib/utils/memoryParse.js +2 -2
- package/lib/utils/normalizeLink.js +2 -2
- package/lib/utils/normalizeOptions.js +2 -2
- package/lib/utils/object.js +2 -2
- package/lib/utils/offset.js +2 -2
- package/lib/utils/offsetParent.js +2 -2
- package/lib/utils/optionValueCompare.js +2 -2
- package/lib/utils/position.js +2 -2
- package/lib/utils/prettyBytes.js +2 -2
- package/lib/utils/renderer-event.js +2 -2
- package/lib/utils/replaceText.js +9 -15
- package/lib/utils/resize-sensor.js +2 -2
- package/lib/utils/resolveCondition.js +2 -2
- package/lib/utils/resolveVariable.js +2 -2
- package/lib/utils/resolveVariableAndFilter.js +2 -2
- package/lib/utils/resolveVariableAndFilterForAsync.js +2 -2
- package/lib/utils/scrollPosition.js +2 -2
- package/lib/utils/string2regExp.d.ts +1 -1
- package/lib/utils/string2regExp.js +5 -4
- package/lib/utils/stripNumber.js +2 -2
- package/lib/utils/style-helper.d.ts +24 -5
- package/lib/utils/style-helper.js +47 -17
- package/lib/utils/style.js +2 -2
- package/lib/utils/toNumber.js +2 -2
- package/lib/utils/tokenize.d.ts +1 -0
- package/lib/utils/tokenize.js +11 -3
- package/lib/utils/tpl-builtin.js +2 -2
- package/lib/utils/tpl-lodash.js +2 -2
- package/lib/utils/tpl.js +6 -8
- package/lib/utils/uncontrollable.js +2 -2
- package/lib/utils/validateId.d.ts +16 -0
- package/lib/utils/validateId.js +160 -0
- package/lib/utils/validations.js +17 -9
- package/package.json +3 -3
- package/LICENSE +0 -201
package/lib/store/form.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="lodash" />
|
|
2
1
|
import { Instance } from 'mobx-state-tree';
|
|
3
2
|
import type { IFormItemStore } from './formItem';
|
|
4
3
|
import { Api, fetchOptions, Payload } from '../types';
|
|
@@ -174,7 +173,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
174
173
|
} & {
|
|
175
174
|
focus: () => void;
|
|
176
175
|
blur: () => void;
|
|
177
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
176
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
177
|
+
name?: string | undefined;
|
|
178
178
|
extraName?: string | undefined;
|
|
179
179
|
required?: boolean | undefined;
|
|
180
180
|
unique?: boolean | undefined;
|
|
@@ -243,7 +243,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
243
243
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
244
244
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
245
245
|
closeDialog: (result?: any) => void;
|
|
246
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
246
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
247
247
|
changeEmitedValue: (value: any) => void;
|
|
248
248
|
addSubFormItem: (item: {
|
|
249
249
|
id: string;
|
|
@@ -683,7 +683,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
683
683
|
} & {
|
|
684
684
|
focus: () => void;
|
|
685
685
|
blur: () => void;
|
|
686
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
686
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
687
|
+
name?: string | undefined;
|
|
687
688
|
extraName?: string | undefined;
|
|
688
689
|
required?: boolean | undefined;
|
|
689
690
|
unique?: boolean | undefined;
|
|
@@ -752,7 +753,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
752
753
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
753
754
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
754
755
|
closeDialog: (result?: any) => void;
|
|
755
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
756
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
756
757
|
changeEmitedValue: (value: any) => void;
|
|
757
758
|
addSubFormItem: (item: {
|
|
758
759
|
id: string;
|
|
@@ -1197,7 +1198,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
1197
1198
|
} & {
|
|
1198
1199
|
focus: () => void;
|
|
1199
1200
|
blur: () => void;
|
|
1200
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
1201
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
1202
|
+
name?: string | undefined;
|
|
1201
1203
|
extraName?: string | undefined;
|
|
1202
1204
|
required?: boolean | undefined;
|
|
1203
1205
|
unique?: boolean | undefined;
|
|
@@ -1266,7 +1268,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
1266
1268
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
1267
1269
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
1268
1270
|
closeDialog: (result?: any) => void;
|
|
1269
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
1271
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
1270
1272
|
changeEmitedValue: (value: any) => void;
|
|
1271
1273
|
addSubFormItem: (item: {
|
|
1272
1274
|
id: string;
|
|
@@ -1706,7 +1708,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
1706
1708
|
} & {
|
|
1707
1709
|
focus: () => void;
|
|
1708
1710
|
blur: () => void;
|
|
1709
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
1711
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
1712
|
+
name?: string | undefined;
|
|
1710
1713
|
extraName?: string | undefined;
|
|
1711
1714
|
required?: boolean | undefined;
|
|
1712
1715
|
unique?: boolean | undefined;
|
|
@@ -1775,7 +1778,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
1775
1778
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
1776
1779
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
1777
1780
|
closeDialog: (result?: any) => void;
|
|
1778
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
1781
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
1779
1782
|
changeEmitedValue: (value: any) => void;
|
|
1780
1783
|
addSubFormItem: (item: {
|
|
1781
1784
|
id: string;
|
|
@@ -2224,7 +2227,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
2224
2227
|
} & {
|
|
2225
2228
|
focus: () => void;
|
|
2226
2229
|
blur: () => void;
|
|
2227
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
2230
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
2231
|
+
name?: string | undefined;
|
|
2228
2232
|
extraName?: string | undefined;
|
|
2229
2233
|
required?: boolean | undefined;
|
|
2230
2234
|
unique?: boolean | undefined;
|
|
@@ -2293,7 +2297,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
2293
2297
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
2294
2298
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
2295
2299
|
closeDialog: (result?: any) => void;
|
|
2296
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
2300
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
2297
2301
|
changeEmitedValue: (value: any) => void;
|
|
2298
2302
|
addSubFormItem: (item: {
|
|
2299
2303
|
id: string;
|
|
@@ -2733,7 +2737,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
2733
2737
|
} & {
|
|
2734
2738
|
focus: () => void;
|
|
2735
2739
|
blur: () => void;
|
|
2736
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
2740
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
2741
|
+
name?: string | undefined;
|
|
2737
2742
|
extraName?: string | undefined;
|
|
2738
2743
|
required?: boolean | undefined;
|
|
2739
2744
|
unique?: boolean | undefined;
|
|
@@ -2802,7 +2807,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
2802
2807
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
2803
2808
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
2804
2809
|
closeDialog: (result?: any) => void;
|
|
2805
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
2810
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
2806
2811
|
changeEmitedValue: (value: any) => void;
|
|
2807
2812
|
addSubFormItem: (item: {
|
|
2808
2813
|
id: string;
|
|
@@ -3246,7 +3251,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
3246
3251
|
} & {
|
|
3247
3252
|
focus: () => void;
|
|
3248
3253
|
blur: () => void;
|
|
3249
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
3254
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
3255
|
+
name?: string | undefined;
|
|
3250
3256
|
extraName?: string | undefined;
|
|
3251
3257
|
required?: boolean | undefined;
|
|
3252
3258
|
unique?: boolean | undefined;
|
|
@@ -3315,7 +3321,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
3315
3321
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
3316
3322
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
3317
3323
|
closeDialog: (result?: any) => void;
|
|
3318
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
3324
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
3319
3325
|
changeEmitedValue: (value: any) => void;
|
|
3320
3326
|
addSubFormItem: (item: {
|
|
3321
3327
|
id: string;
|
|
@@ -3755,7 +3761,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
3755
3761
|
} & {
|
|
3756
3762
|
focus: () => void;
|
|
3757
3763
|
blur: () => void;
|
|
3758
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
3764
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
3765
|
+
name?: string | undefined;
|
|
3759
3766
|
extraName?: string | undefined;
|
|
3760
3767
|
required?: boolean | undefined;
|
|
3761
3768
|
unique?: boolean | undefined;
|
|
@@ -3824,7 +3831,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
3824
3831
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
3825
3832
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
3826
3833
|
closeDialog: (result?: any) => void;
|
|
3827
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
3834
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
3828
3835
|
changeEmitedValue: (value: any) => void;
|
|
3829
3836
|
addSubFormItem: (item: {
|
|
3830
3837
|
id: string;
|
|
@@ -4268,7 +4275,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
4268
4275
|
} & {
|
|
4269
4276
|
focus: () => void;
|
|
4270
4277
|
blur: () => void;
|
|
4271
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
4278
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
4279
|
+
name?: string | undefined;
|
|
4272
4280
|
extraName?: string | undefined;
|
|
4273
4281
|
required?: boolean | undefined;
|
|
4274
4282
|
unique?: boolean | undefined;
|
|
@@ -4337,7 +4345,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
4337
4345
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
4338
4346
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
4339
4347
|
closeDialog: (result?: any) => void;
|
|
4340
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
4348
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
4341
4349
|
changeEmitedValue: (value: any) => void;
|
|
4342
4350
|
addSubFormItem: (item: {
|
|
4343
4351
|
id: string;
|
|
@@ -4777,7 +4785,8 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
4777
4785
|
} & {
|
|
4778
4786
|
focus: () => void;
|
|
4779
4787
|
blur: () => void;
|
|
4780
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
4788
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
4789
|
+
name?: string | undefined;
|
|
4781
4790
|
extraName?: string | undefined;
|
|
4782
4791
|
required?: boolean | undefined;
|
|
4783
4792
|
unique?: boolean | undefined;
|
|
@@ -4846,7 +4855,7 @@ export declare const FormStore: import("mobx-state-tree").IModelType<{
|
|
|
4846
4855
|
resetValidationStatus: (tag?: string | undefined) => void;
|
|
4847
4856
|
openDialog: (schema: any, ctx: any, callback?: ((ret?: any) => void) | undefined) => void;
|
|
4848
4857
|
closeDialog: (result?: any) => void;
|
|
4849
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
4858
|
+
changeTmpValue: (value: any, changeReason?: "input" | "defaultValue" | "formInited" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
4850
4859
|
changeEmitedValue: (value: any) => void;
|
|
4851
4860
|
addSubFormItem: (item: {
|
|
4852
4861
|
id: string;
|
package/lib/store/form.js
CHANGED
package/lib/store/formItem.d.ts
CHANGED
|
@@ -92,7 +92,8 @@ export declare const FormItemStore: import("mobx-state-tree").IModelType<{
|
|
|
92
92
|
} & {
|
|
93
93
|
focus: () => void;
|
|
94
94
|
blur: () => void;
|
|
95
|
-
config: ({ extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
95
|
+
config: ({ name, extraName, required, unique, value, isValueSchemaExp, rules, messages, delimiter, multiple, valueField, labelField, joinValues, extractValue, type, id, selectFirst, autoFill, clearValueOnHidden, validateApi, maxLength, minLength, validateOnChange, label, inputGroupControl, pagination }: {
|
|
96
|
+
name?: string | undefined;
|
|
96
97
|
extraName?: string | undefined;
|
|
97
98
|
required?: boolean | undefined;
|
|
98
99
|
unique?: boolean | undefined;
|
package/lib/store/formItem.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* amis-core v6.
|
|
3
|
-
* Copyright 2018-
|
|
2
|
+
* amis-core v6.1.0
|
|
3
|
+
* Copyright 2018-2024 fex
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
'use strict';
|
|
@@ -270,10 +270,11 @@ var FormItemStore = node.StoreNode.named('FormItemStore')
|
|
|
270
270
|
var dialogCallbacks = new SimpleMap.SimpleMap();
|
|
271
271
|
var loadAutoUpdateCancel = null;
|
|
272
272
|
function config(_a) {
|
|
273
|
-
var extraName = _a.extraName, required = _a.required, unique = _a.unique; _a.value; var isValueSchemaExp = _a.isValueSchemaExp, rules = _a.rules, messages = _a.messages, delimiter = _a.delimiter, multiple = _a.multiple, valueField = _a.valueField, labelField = _a.labelField, joinValues = _a.joinValues, extractValue = _a.extractValue, type = _a.type, id = _a.id, selectFirst = _a.selectFirst, autoFill = _a.autoFill, clearValueOnHidden = _a.clearValueOnHidden, validateApi = _a.validateApi, maxLength = _a.maxLength, minLength = _a.minLength, validateOnChange = _a.validateOnChange, label = _a.label, inputGroupControl = _a.inputGroupControl, pagination = _a.pagination;
|
|
273
|
+
var name = _a.name, extraName = _a.extraName, required = _a.required, unique = _a.unique; _a.value; var isValueSchemaExp = _a.isValueSchemaExp, rules = _a.rules, messages = _a.messages, delimiter = _a.delimiter, multiple = _a.multiple, valueField = _a.valueField, labelField = _a.labelField, joinValues = _a.joinValues, extractValue = _a.extractValue, type = _a.type, id = _a.id, selectFirst = _a.selectFirst, autoFill = _a.autoFill, clearValueOnHidden = _a.clearValueOnHidden, validateApi = _a.validateApi, maxLength = _a.maxLength, minLength = _a.minLength, validateOnChange = _a.validateOnChange, label = _a.label, inputGroupControl = _a.inputGroupControl, pagination = _a.pagination;
|
|
274
274
|
if (typeof rules === 'string') {
|
|
275
275
|
rules = validations.str2rules(rules);
|
|
276
276
|
}
|
|
277
|
+
typeof name !== 'undefined' && (self.name = name);
|
|
277
278
|
typeof extraName !== 'undefined' && (self.extraName = extraName);
|
|
278
279
|
typeof type !== 'undefined' && (self.type = type);
|
|
279
280
|
typeof id !== 'undefined' && (self.itemId = id);
|
package/lib/store/iRenderer.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* amis-core v6.
|
|
3
|
-
* Copyright 2018-
|
|
2
|
+
* amis-core v6.1.0
|
|
3
|
+
* Copyright 2018-2024 fex
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
'use strict';
|
|
@@ -39,13 +39,13 @@ require('../utils/image.js');
|
|
|
39
39
|
require('lodash/isEqual');
|
|
40
40
|
require('../actions/Action.js');
|
|
41
41
|
require('lodash/debounce');
|
|
42
|
-
require('lodash/cloneDeep');
|
|
43
42
|
require('../utils/resize-sensor.js');
|
|
44
43
|
require('react');
|
|
45
44
|
require('react-overlays/useRootClose');
|
|
46
45
|
require('react-dom');
|
|
47
46
|
require('lodash/mapValues');
|
|
48
47
|
require('lodash/camelCase');
|
|
48
|
+
require('lodash/cloneDeep');
|
|
49
49
|
require('lodash/map');
|
|
50
50
|
require('lodash/isEmpty');
|
|
51
51
|
require('lodash/kebabCase');
|
|
@@ -173,6 +173,8 @@ var iRendererStore = node.StoreNode.named('iRendererStore')
|
|
|
173
173
|
},
|
|
174
174
|
setCurrentAction: function (action) {
|
|
175
175
|
self.action = action;
|
|
176
|
+
self.dialogData = false;
|
|
177
|
+
self.drawerOpen = false;
|
|
176
178
|
},
|
|
177
179
|
openDialog: function (ctx, additonal, callback, scoped) {
|
|
178
180
|
var chain = object.extractObjectChain(ctx);
|
package/lib/store/index.js
CHANGED
package/lib/store/list.js
CHANGED
package/lib/store/manager.js
CHANGED
package/lib/store/modal.js
CHANGED
package/lib/store/node.js
CHANGED
package/lib/store/pagination.js
CHANGED
package/lib/store/root.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* amis-core v6.
|
|
3
|
-
* Copyright 2018-
|
|
2
|
+
* amis-core v6.1.0
|
|
3
|
+
* Copyright 2018-2024 fex
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
'use strict';
|
|
@@ -35,7 +35,6 @@ require('../utils/image.js');
|
|
|
35
35
|
require('lodash/isEqual');
|
|
36
36
|
require('../actions/Action.js');
|
|
37
37
|
require('lodash/debounce');
|
|
38
|
-
require('lodash/cloneDeep');
|
|
39
38
|
require('../utils/resize-sensor.js');
|
|
40
39
|
require('react');
|
|
41
40
|
require('react-overlays/useRootClose');
|
|
@@ -43,6 +42,7 @@ require('react-dom');
|
|
|
43
42
|
require('../utils/SimpleMap.js');
|
|
44
43
|
require('lodash/mapValues');
|
|
45
44
|
require('lodash/camelCase');
|
|
45
|
+
require('lodash/cloneDeep');
|
|
46
46
|
require('lodash/map');
|
|
47
47
|
require('lodash/isEmpty');
|
|
48
48
|
require('lodash/kebabCase');
|
package/lib/store/service.js
CHANGED
package/lib/store/status.js
CHANGED