@dovetail-v2/refine 0.4.3 → 0.4.5
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/dist/{PodShell-43c7028e.cjs → PodShell-a335b2b2.cjs} +4 -2
- package/dist/{PodShell-76331418.js → PodShell-a6ed3498.js} +4 -2
- package/dist/components/CopyButton/index.d.ts +7 -0
- package/dist/components/ErrorContent/index.d.ts +3 -4
- package/dist/components/FormWidgets/NameInputWidget.d.ts +0 -48
- package/dist/components/IngressRulesComponent/PathWithCopy.d.ts +7 -0
- package/dist/components/ServiceComponents/index.d.ts +10 -0
- package/dist/components/Shell/ShellToolbar.d.ts +1 -1
- package/dist/components/ShowContent/fields.d.ts +4 -0
- package/dist/components/Table/index.d.ts +2 -2
- package/dist/components/index.d.ts +1 -3
- package/dist/contexts/component.d.ts +14 -5
- package/dist/contexts/index.d.ts +1 -0
- package/dist/hooks/useDeleteModal/index.d.ts +1 -0
- package/dist/hooks/useEagleTable/columns.d.ts +5 -4
- package/dist/hooks/useSubmitForm.d.ts +1 -1
- package/dist/hooks/useTableData.d.ts +1 -1
- package/dist/i18n.d.ts +25 -0
- package/dist/{index-31874f77.cjs → index-053ee180.cjs} +1 -1
- package/dist/{index-ab97826a.js → index-d7bc2ee6.js} +1 -1
- package/dist/index.d.ts +0 -1
- package/dist/locales/en-US/index.d.ts +12 -0
- package/dist/locales/zh-CN/index.d.ts +13 -0
- package/dist/models/daemonset-model.d.ts +0 -3
- package/dist/models/statefulset-model.d.ts +0 -3
- package/dist/models/workload-base-model.d.ts +3 -0
- package/dist/models/workload-model.d.ts +3 -0
- package/dist/pages/deployments/form/index.d.ts +2 -1
- package/dist/plugins/model-plugin.d.ts +1 -1
- package/dist/refine.cjs +1175 -1031
- package/dist/refine.js +1178 -1034
- package/dist/shell.cjs +1 -1
- package/dist/shell.js +1 -1
- package/dist/style.css +148 -4
- package/dist/types/resource.d.ts +9 -9
- package/package.json +17 -6
package/dist/shell.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const index = require("./index-
|
|
3
|
+
const index = require("./index-053ee180.cjs");
|
|
4
4
|
const common = require("./common-1eb43414.cjs");
|
|
5
5
|
require("@cloudtower/eagle");
|
|
6
6
|
require("@xterm/addon-canvas");
|
package/dist/shell.js
CHANGED
package/dist/style.css
CHANGED
|
@@ -960,6 +960,56 @@
|
|
|
960
960
|
/* box shadow */
|
|
961
961
|
/* fisheye */
|
|
962
962
|
/* z-index */
|
|
963
|
+
.c1oll6q9 {
|
|
964
|
+
cursor: pointer;
|
|
965
|
+
margin: 1px 0;
|
|
966
|
+
}/* // basic */
|
|
967
|
+
/* FishEye Color Variables and Functions */
|
|
968
|
+
/*
|
|
969
|
+
--------------------------- Primary Color ---------------------------
|
|
970
|
+
*/
|
|
971
|
+
/*
|
|
972
|
+
---------------------------When necessary to add at any time---------------------------
|
|
973
|
+
*/
|
|
974
|
+
/* computed */
|
|
975
|
+
/* blue */
|
|
976
|
+
/* green */
|
|
977
|
+
/* yellow */
|
|
978
|
+
/* red */
|
|
979
|
+
/* purple */
|
|
980
|
+
/* palette global token*/
|
|
981
|
+
/* color opaque */
|
|
982
|
+
/* color transparent */
|
|
983
|
+
/* blue transparent */
|
|
984
|
+
/* green transparent */
|
|
985
|
+
/* yellow transparent */
|
|
986
|
+
/* red transparent */
|
|
987
|
+
/* gray transparent */
|
|
988
|
+
/* white transparent */
|
|
989
|
+
/* gradient opaque */
|
|
990
|
+
/* blue radial gradient */
|
|
991
|
+
/* blue linear gradient */
|
|
992
|
+
/* green radial gradient */
|
|
993
|
+
/* yellow radial gradient */
|
|
994
|
+
/* red radial gradient */
|
|
995
|
+
/* gray radial gradient */
|
|
996
|
+
/* white to gray radial gradient */
|
|
997
|
+
/* white to gray linear gradient */
|
|
998
|
+
/* gradient transparent */
|
|
999
|
+
/* secondary palette */
|
|
1000
|
+
/* purple radial gradient */
|
|
1001
|
+
/* refine alias color */
|
|
1002
|
+
/* text */
|
|
1003
|
+
/* link */
|
|
1004
|
+
/* fill */
|
|
1005
|
+
/* fill element */
|
|
1006
|
+
/* fill interaction */
|
|
1007
|
+
/* stroke */
|
|
1008
|
+
/* background */
|
|
1009
|
+
/* dim */
|
|
1010
|
+
/* box shadow */
|
|
1011
|
+
/* fisheye */
|
|
1012
|
+
/* z-index */
|
|
963
1013
|
.b1vtjd4k.ant-btn.ant-btn-link {
|
|
964
1014
|
display: block;
|
|
965
1015
|
}
|
|
@@ -984,6 +1034,28 @@
|
|
|
984
1034
|
height: 18px;
|
|
985
1035
|
line-height: 18px;
|
|
986
1036
|
border-bottom: 1px dashed rgba(107, 128, 167, 0.6);
|
|
1037
|
+
}
|
|
1038
|
+
|
|
1039
|
+
.azmggeh {
|
|
1040
|
+
display: inline-flex;
|
|
1041
|
+
align-items: center;
|
|
1042
|
+
gap: 4px;
|
|
1043
|
+
vertical-align: top;
|
|
1044
|
+
}
|
|
1045
|
+
|
|
1046
|
+
.bct30qn {
|
|
1047
|
+
margin: 0;
|
|
1048
|
+
padding-left: 0;
|
|
1049
|
+
list-style: none;
|
|
1050
|
+
}
|
|
1051
|
+
.bct30qn li + li {
|
|
1052
|
+
margin-top: 4px;
|
|
1053
|
+
}
|
|
1054
|
+
|
|
1055
|
+
.b1m9bqu {
|
|
1056
|
+
display: flex;
|
|
1057
|
+
align-items: center;
|
|
1058
|
+
min-width: 0;
|
|
987
1059
|
}/* // basic */
|
|
988
1060
|
/* FishEye Color Variables and Functions */
|
|
989
1061
|
/*
|
|
@@ -1041,14 +1113,14 @@
|
|
|
1041
1113
|
.t12ikbmp.ant-tag {
|
|
1042
1114
|
overflow: hidden;
|
|
1043
1115
|
text-overflow: ellipsis;
|
|
1044
|
-
color: #
|
|
1116
|
+
color: #1d326c;
|
|
1045
1117
|
}
|
|
1046
1118
|
.t12ikbmp.ant-tag.outside-tag {
|
|
1047
|
-
border: 1px solid #
|
|
1048
|
-
background-color: #
|
|
1119
|
+
border: 1px solid #a3b4cc;
|
|
1120
|
+
background-color: #e4e9f2;
|
|
1049
1121
|
}
|
|
1050
1122
|
.t12ikbmp.ant-tag .inside-tag {
|
|
1051
|
-
background-color: #
|
|
1123
|
+
background-color: #ccd4e3;
|
|
1052
1124
|
}/* // basic */
|
|
1053
1125
|
/* FishEye Color Variables and Functions */
|
|
1054
1126
|
/*
|
|
@@ -1717,6 +1789,78 @@
|
|
|
1717
1789
|
/* box shadow */
|
|
1718
1790
|
/* fisheye */
|
|
1719
1791
|
/* z-index */
|
|
1792
|
+
.prjtqnv {
|
|
1793
|
+
display: flex;
|
|
1794
|
+
align-items: center;
|
|
1795
|
+
width: 100%;
|
|
1796
|
+
min-width: 0;
|
|
1797
|
+
}
|
|
1798
|
+
|
|
1799
|
+
.pci82dd {
|
|
1800
|
+
flex: 1 1 auto;
|
|
1801
|
+
min-width: 0;
|
|
1802
|
+
overflow: hidden;
|
|
1803
|
+
text-overflow: ellipsis;
|
|
1804
|
+
white-space: nowrap;
|
|
1805
|
+
}
|
|
1806
|
+
.pci82dd > * {
|
|
1807
|
+
display: block;
|
|
1808
|
+
max-width: 100%;
|
|
1809
|
+
overflow: hidden;
|
|
1810
|
+
text-overflow: ellipsis;
|
|
1811
|
+
white-space: nowrap;
|
|
1812
|
+
}
|
|
1813
|
+
|
|
1814
|
+
.pmf8toc {
|
|
1815
|
+
flex: 0 0 16px;
|
|
1816
|
+
margin-left: auto;
|
|
1817
|
+
}/* // basic */
|
|
1818
|
+
/* FishEye Color Variables and Functions */
|
|
1819
|
+
/*
|
|
1820
|
+
--------------------------- Primary Color ---------------------------
|
|
1821
|
+
*/
|
|
1822
|
+
/*
|
|
1823
|
+
---------------------------When necessary to add at any time---------------------------
|
|
1824
|
+
*/
|
|
1825
|
+
/* computed */
|
|
1826
|
+
/* blue */
|
|
1827
|
+
/* green */
|
|
1828
|
+
/* yellow */
|
|
1829
|
+
/* red */
|
|
1830
|
+
/* purple */
|
|
1831
|
+
/* palette global token*/
|
|
1832
|
+
/* color opaque */
|
|
1833
|
+
/* color transparent */
|
|
1834
|
+
/* blue transparent */
|
|
1835
|
+
/* green transparent */
|
|
1836
|
+
/* yellow transparent */
|
|
1837
|
+
/* red transparent */
|
|
1838
|
+
/* gray transparent */
|
|
1839
|
+
/* white transparent */
|
|
1840
|
+
/* gradient opaque */
|
|
1841
|
+
/* blue radial gradient */
|
|
1842
|
+
/* blue linear gradient */
|
|
1843
|
+
/* green radial gradient */
|
|
1844
|
+
/* yellow radial gradient */
|
|
1845
|
+
/* red radial gradient */
|
|
1846
|
+
/* gray radial gradient */
|
|
1847
|
+
/* white to gray radial gradient */
|
|
1848
|
+
/* white to gray linear gradient */
|
|
1849
|
+
/* gradient transparent */
|
|
1850
|
+
/* secondary palette */
|
|
1851
|
+
/* purple radial gradient */
|
|
1852
|
+
/* refine alias color */
|
|
1853
|
+
/* text */
|
|
1854
|
+
/* link */
|
|
1855
|
+
/* fill */
|
|
1856
|
+
/* fill element */
|
|
1857
|
+
/* fill interaction */
|
|
1858
|
+
/* stroke */
|
|
1859
|
+
/* background */
|
|
1860
|
+
/* dim */
|
|
1861
|
+
/* box shadow */
|
|
1862
|
+
/* fisheye */
|
|
1863
|
+
/* z-index */
|
|
1720
1864
|
.l1vnw9x0 {
|
|
1721
1865
|
padding: 0 !important;
|
|
1722
1866
|
}/* // basic */
|
package/dist/types/resource.d.ts
CHANGED
|
@@ -55,10 +55,10 @@ export type RefineFormConfig<Model extends ResourceModel = ResourceModel> = {
|
|
|
55
55
|
text?: string;
|
|
56
56
|
};
|
|
57
57
|
/**
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
58
|
+
* 表单字段配置函数
|
|
59
|
+
* @param props 包含记录和动作类型的配置对象
|
|
60
|
+
* @returns 表单字段配置数组
|
|
61
|
+
*/
|
|
62
62
|
fields?: (props: {
|
|
63
63
|
record?: Model;
|
|
64
64
|
records: Model[];
|
|
@@ -78,9 +78,9 @@ export type RefineFormConfig<Model extends ResourceModel = ResourceModel> = {
|
|
|
78
78
|
*/
|
|
79
79
|
labelWidth?: string;
|
|
80
80
|
/**
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
81
|
+
* 自定义表单渲染函数
|
|
82
|
+
* @returns React节点
|
|
83
|
+
*/
|
|
84
84
|
renderForm?: () => React.ReactNode;
|
|
85
85
|
};
|
|
86
86
|
export type YamlFormConfig = {
|
|
@@ -129,7 +129,7 @@ export type CommonFormConfig<Model extends ResourceModel = ResourceModel> = {
|
|
|
129
129
|
beforeSubmit?: (values: Record<string, unknown>, setErrors: (errors: string[]) => void) => Promise<Model['_rawYaml']>;
|
|
130
130
|
/** 表单容器类型:页面形式或模态框形式
|
|
131
131
|
* PAGE 或者 MODAL
|
|
132
|
-
|
|
132
|
+
*/
|
|
133
133
|
formContainerType?: FormContainerType;
|
|
134
134
|
/**
|
|
135
135
|
* 表单标题,可以是字符串或根据操作类型返回不同标题的函数
|
|
@@ -189,7 +189,7 @@ export type ResourceConfig<Model extends ResourceModel = ResourceModel> = {
|
|
|
189
189
|
basePath: string;
|
|
190
190
|
/** Kubernetes API 版本,会影响请求 URL
|
|
191
191
|
* 实际效果为:{apiUrl}{basePath}{apiVersion}{name}
|
|
192
|
-
|
|
192
|
+
*/
|
|
193
193
|
apiVersion: string;
|
|
194
194
|
/** 资源使用的 DataProvider 的名称 */
|
|
195
195
|
dataProviderName?: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dovetail-v2/refine",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.5",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"files": [
|
|
6
6
|
"dist",
|
|
@@ -9,6 +9,20 @@
|
|
|
9
9
|
"main": "./dist/refine.cjs",
|
|
10
10
|
"module": "./dist/refine.js",
|
|
11
11
|
"types": "./dist/index.d.ts",
|
|
12
|
+
"exports": {
|
|
13
|
+
".": {
|
|
14
|
+
"import": "./dist/refine.js",
|
|
15
|
+
"require": "./dist/refine.cjs",
|
|
16
|
+
"types": "./dist/index.d.ts"
|
|
17
|
+
},
|
|
18
|
+
"./shell": {
|
|
19
|
+
"import": "./dist/shell.js",
|
|
20
|
+
"require": "./dist/shell.cjs",
|
|
21
|
+
"types": "./dist/shell.d.ts"
|
|
22
|
+
},
|
|
23
|
+
"./dist/*": "./dist/*",
|
|
24
|
+
"./package.json": "./package.json"
|
|
25
|
+
},
|
|
12
26
|
"dependencies": {
|
|
13
27
|
"@cloudtower/eagle": "^490.0.1",
|
|
14
28
|
"@cloudtower/icons-react": "^490.0.1",
|
|
@@ -55,7 +69,6 @@
|
|
|
55
69
|
"@linaria/react": "^4.5.4",
|
|
56
70
|
"@linaria/utils": "^4.5.3",
|
|
57
71
|
"@linaria/vite": "^4.5.4",
|
|
58
|
-
"@playwright/test": "^1.39.0",
|
|
59
72
|
"@refinedev/cli": "^2.9.0",
|
|
60
73
|
"@rollup/pluginutils": "^4.2.1",
|
|
61
74
|
"@tanstack/react-query": "^4.35.3",
|
|
@@ -82,10 +95,9 @@
|
|
|
82
95
|
"eslint-plugin-react-refresh": "^0.3.4",
|
|
83
96
|
"jest": "^29",
|
|
84
97
|
"json-schema": "^0.4.0",
|
|
85
|
-
"jest-environment-jsdom": "^
|
|
98
|
+
"jest-environment-jsdom": "^29.0.0",
|
|
86
99
|
"kubernetes-types": "^1.26.0",
|
|
87
100
|
"lodash": "^4.17.21",
|
|
88
|
-
"prettier": "2.8.8",
|
|
89
101
|
"sass": "1.51.0",
|
|
90
102
|
"ts-jest": "^29",
|
|
91
103
|
"vite": "^4.5.2",
|
|
@@ -109,8 +121,7 @@
|
|
|
109
121
|
"preview": "refine start",
|
|
110
122
|
"refine": "refine",
|
|
111
123
|
"unit-test": "jest",
|
|
112
|
-
"
|
|
113
|
-
"test": "pnpm unit-test && pnpm playwright-test",
|
|
124
|
+
"test": "pnpm unit-test",
|
|
114
125
|
"lint": "eslint src --ext .ts,.tsx"
|
|
115
126
|
},
|
|
116
127
|
"browserslist": {
|