@nocobase/client 2.0.54 → 2.0.56
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/es/flow/actions/dataScopeFormValueClear.d.ts +14 -0
- package/es/flow/models/base/ActionModel.d.ts +6 -0
- package/es/flow/models/base/GridModel.d.ts +2 -0
- package/es/flow/models/blocks/filter-form/FilterFormBlockModel.d.ts +9 -1
- package/es/index.mjs +4624 -4114
- package/es/route-switch/antd/admin-layout/badge.d.ts +11 -0
- package/lib/index.js +171 -171
- package/package.json +6 -6
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is part of the NocoBase (R) project.
|
|
3
|
+
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
+
* Authors: NocoBase Team.
|
|
5
|
+
*
|
|
6
|
+
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
+
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
+
*/
|
|
9
|
+
import type { FlowContext } from '@nocobase/flow-engine';
|
|
10
|
+
/**
|
|
11
|
+
* When a field's dataScope filter references other form values (e.g. `{{ ctx.formValues.school.id }}`),
|
|
12
|
+
* clear current field value after the dependency changes, so users don't keep an invalid stale selection.
|
|
13
|
+
*/
|
|
14
|
+
export declare function ensureFormValueDrivenDataScopeClear(ctx: FlowContext, params: any): void;
|
|
@@ -20,10 +20,12 @@ export declare const ActionSceneEnum: {
|
|
|
20
20
|
export declare class ActionModel<T extends DefaultStructure = DefaultStructure> extends FlowModel<T> {
|
|
21
21
|
props: ButtonProps & {
|
|
22
22
|
tooltip?: string;
|
|
23
|
+
iconOnly?: boolean;
|
|
23
24
|
};
|
|
24
25
|
scene: ActionSceneType;
|
|
25
26
|
defaultProps: ButtonProps & {
|
|
26
27
|
tooltip?: string;
|
|
28
|
+
iconOnly?: boolean;
|
|
27
29
|
};
|
|
28
30
|
enableEditTooltip: boolean;
|
|
29
31
|
enableEditTitle: boolean;
|
|
@@ -31,6 +33,10 @@ export declare class ActionModel<T extends DefaultStructure = DefaultStructure>
|
|
|
31
33
|
enableEditType: boolean;
|
|
32
34
|
enableEditDanger: boolean;
|
|
33
35
|
enableEditColor: boolean;
|
|
36
|
+
buttonTypeOptions: {
|
|
37
|
+
value: string;
|
|
38
|
+
label: string;
|
|
39
|
+
}[];
|
|
34
40
|
static _getScene(): any[];
|
|
35
41
|
static _isScene(scene: ActionSceneType): boolean;
|
|
36
42
|
getAclActionName(): any;
|
|
@@ -53,6 +53,7 @@ export declare class GridModel<T extends {
|
|
|
53
53
|
private buildResizedCells;
|
|
54
54
|
private getResizeRowPath;
|
|
55
55
|
private getResizeContainerWidth;
|
|
56
|
+
private prunePlaceholderOnlyRows;
|
|
56
57
|
private resizeGridLayout;
|
|
57
58
|
onMount(): void;
|
|
58
59
|
saveGridLayout(layout?: GridLayoutData | GridLayoutV2): void;
|
|
@@ -80,6 +81,7 @@ export declare class GridModel<T extends {
|
|
|
80
81
|
* 运行态按可见 block 过滤行/列,避免“整行都是 hidden block”但依然保留行间距占位。
|
|
81
82
|
* - 配置态(flowSettingsEnabled)保持原始 rows/sizes 以便拖拽和布局编辑。
|
|
82
83
|
* - 运行态仅在判断为“整列/整行都不可见”时做过滤,不写回 props/stepParams,布局元数据保持不变。
|
|
84
|
+
* - 空列是拖拽缩窄后保存的布局占位,运行态需要保留其宽度,但 Grid 渲染层不会渲染其内容。
|
|
83
85
|
*/
|
|
84
86
|
private getVisibleLayout;
|
|
85
87
|
render(): React.JSX.Element;
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
+
import type { PropertyMetaFactory } from '@nocobase/flow-engine';
|
|
9
10
|
import React from 'react';
|
|
10
11
|
import { FilterBlockModel } from '../../base';
|
|
11
12
|
export declare class FilterFormBlockModel extends FilterBlockModel<{
|
|
@@ -22,8 +23,11 @@ export declare class FilterFormBlockModel extends FilterBlockModel<{
|
|
|
22
23
|
private removeTargetBlockListener?;
|
|
23
24
|
private initialDefaultsPromise?;
|
|
24
25
|
private initialRefreshHandledTargetIds;
|
|
26
|
+
private lastDefaultValueByFieldName;
|
|
27
|
+
private defaultValuesRefreshSeq;
|
|
25
28
|
get form(): any;
|
|
26
29
|
get title(): string;
|
|
30
|
+
protected createFormValuesMetaFactory(): PropertyMetaFactory;
|
|
27
31
|
useHooksBeforeRender(): void;
|
|
28
32
|
saveStepParams(): Promise<any>;
|
|
29
33
|
addAppends(): void;
|
|
@@ -34,9 +38,13 @@ export declare class FilterFormBlockModel extends FilterBlockModel<{
|
|
|
34
38
|
prepareInitialFilterValues(): Promise<boolean>;
|
|
35
39
|
markInitialTargetRefreshHandled(targetId: string): void;
|
|
36
40
|
private ensureFilterItemsBeforeRender;
|
|
41
|
+
private canApplyFormDefaultValue;
|
|
42
|
+
private matchDefaultValueCondition;
|
|
37
43
|
applyFormDefaultValues(options?: {
|
|
38
44
|
force?: boolean;
|
|
39
|
-
|
|
45
|
+
refreshSeq?: number;
|
|
46
|
+
}): Promise<Record<string, any>>;
|
|
47
|
+
private handleFilterFormValuesChange;
|
|
40
48
|
private handleTargetBlockRemoved;
|
|
41
49
|
destroy(): Promise<boolean>;
|
|
42
50
|
renderComponent(): React.JSX.Element;
|