@dovetail-v2/refine 0.3.29-alpha.0 → 0.3.29-alpha.2
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/components/CreateButton/index.d.ts +2 -1
- package/dist/components/TableToolbar/index.d.ts +1 -0
- package/dist/i18n.d.ts +2 -0
- package/dist/locales/en-US/index.d.ts +1 -0
- package/dist/locales/zh-CN/index.d.ts +1 -0
- package/dist/refine.cjs +38 -24
- package/dist/refine.js +38 -24
- package/dist/style.css +18 -1
- package/dist/types/resource.d.ts +2 -2
- package/package.json +1 -1
package/dist/i18n.d.ts
CHANGED
|
@@ -158,6 +158,7 @@ export declare const resources: {
|
|
|
158
158
|
not_support: string;
|
|
159
159
|
stopped_state: string;
|
|
160
160
|
any_node_ip: string;
|
|
161
|
+
default_http_protocol_tooltip: string;
|
|
161
162
|
storage_class: string;
|
|
162
163
|
persistent_volume: string;
|
|
163
164
|
provisioner: string;
|
|
@@ -442,6 +443,7 @@ export declare const resources: {
|
|
|
442
443
|
not_support: string;
|
|
443
444
|
stopped_state: string;
|
|
444
445
|
any_node_ip: string;
|
|
446
|
+
default_http_protocol_tooltip: string;
|
|
445
447
|
storage_class: string;
|
|
446
448
|
persistent_volume: string;
|
|
447
449
|
provisioner: string;
|
package/dist/refine.cjs
CHANGED
|
@@ -612,6 +612,7 @@ const only_support_one_yaml$1 = "Only one YAML configuration is supported at a t
|
|
|
612
612
|
const not_support$1 = "Not supported";
|
|
613
613
|
const stopped_state$1 = "Stopped";
|
|
614
614
|
const any_node_ip$1 = "Any node IP";
|
|
615
|
+
const default_http_protocol_tooltip$1 = "The link uses HTTP protocol by default.";
|
|
615
616
|
const storage_class$1 = "Storage class";
|
|
616
617
|
const persistent_volume$1 = "Persistent volume";
|
|
617
618
|
const provisioner$1 = "Provisioner";
|
|
@@ -655,9 +656,9 @@ const retain$1 = "Retain";
|
|
|
655
656
|
const default_sc$1 = "Default storage class";
|
|
656
657
|
const reclaim_policy$1 = "Reclaim policy";
|
|
657
658
|
const allow_expand$1 = "Volume expansion";
|
|
658
|
-
const request_capacity$1 = "
|
|
659
|
-
const edit_request_capacity$1 = "Edit
|
|
660
|
-
const edit_request_capacity_success_toast$1 = "Successfully edited
|
|
659
|
+
const request_capacity$1 = "Requested capacity";
|
|
660
|
+
const edit_request_capacity$1 = "Edit requested capacity";
|
|
661
|
+
const edit_request_capacity_success_toast$1 = "Successfully edited the requested capacity";
|
|
661
662
|
const edit_taint$1 = "Edit taint";
|
|
662
663
|
const edit_node_taint$1 = "Edit taint";
|
|
663
664
|
const edit_node_taint_success_toast$1 = "Successfully edited the taint for the node {{name}}";
|
|
@@ -666,10 +667,10 @@ const node_taint_PreferNoSchedule$1 = "PreferNoSchedule";
|
|
|
666
667
|
const node_taint_NoExecute$1 = "NoExecute";
|
|
667
668
|
const taint$1 = "Taint";
|
|
668
669
|
const change_form_mode_alert$1 = "Switching from YAML editing to form editing will discard all changes made to the YAML file.";
|
|
669
|
-
const pvc_storage_required$1 = "Please specify the
|
|
670
|
+
const pvc_storage_required$1 = "Please specify the requested capacity.";
|
|
670
671
|
const pvc_storage_min$1 = "Please enter a positive integer.";
|
|
671
672
|
const pvc_storage_reduce_limit$1 = "The value cannot be less than the current value.";
|
|
672
|
-
const pvc_storage_max_limit$1 = "The
|
|
673
|
+
const pvc_storage_max_limit$1 = "The requested capacity cannot exceed 64 TiB.";
|
|
673
674
|
const key_empty_text$1 = "Please specify a key.";
|
|
674
675
|
const format_error$1 = "Format error.";
|
|
675
676
|
const taint_effect_empty_text$1 = "Please select an effect.";
|
|
@@ -888,6 +889,7 @@ const dovetail$1 = {
|
|
|
888
889
|
not_support: not_support$1,
|
|
889
890
|
stopped_state: stopped_state$1,
|
|
890
891
|
any_node_ip: any_node_ip$1,
|
|
892
|
+
default_http_protocol_tooltip: default_http_protocol_tooltip$1,
|
|
891
893
|
storage_class: storage_class$1,
|
|
892
894
|
persistent_volume: persistent_volume$1,
|
|
893
895
|
provisioner: provisioner$1,
|
|
@@ -1169,6 +1171,7 @@ const support = "支持";
|
|
|
1169
1171
|
const not_support = "不支持";
|
|
1170
1172
|
const stopped_state = "已停止";
|
|
1171
1173
|
const any_node_ip = "任意节点 IP";
|
|
1174
|
+
const default_http_protocol_tooltip = "当前链接默认使用 HTTP 协议。";
|
|
1172
1175
|
const storage_class = "存储类";
|
|
1173
1176
|
const persistent_volume = "持久卷";
|
|
1174
1177
|
const provisioner = "制备器";
|
|
@@ -1444,6 +1447,7 @@ const dovetail = {
|
|
|
1444
1447
|
not_support,
|
|
1445
1448
|
stopped_state,
|
|
1446
1449
|
any_node_ip,
|
|
1450
|
+
default_http_protocol_tooltip,
|
|
1447
1451
|
storage_class,
|
|
1448
1452
|
persistent_volume,
|
|
1449
1453
|
provisioner,
|
|
@@ -10260,7 +10264,7 @@ class IngressClassModel extends ResourceModel {
|
|
|
10260
10264
|
return (_a = this.spec) == null ? void 0 : _a.controller;
|
|
10261
10265
|
}
|
|
10262
10266
|
}
|
|
10263
|
-
const
|
|
10267
|
+
const index_1rec449 = "";
|
|
10264
10268
|
const ServiceInClusterAccessComponent = ({
|
|
10265
10269
|
service
|
|
10266
10270
|
}) => {
|
|
@@ -10282,6 +10286,8 @@ const ServiceInClusterAccessComponent = ({
|
|
|
10282
10286
|
};
|
|
10283
10287
|
const BreakLineStyle = "b1vtjd4k";
|
|
10284
10288
|
const LinkStyle$2 = "luro4rx";
|
|
10289
|
+
const ShowLinkStyle = "s1gydjqf";
|
|
10290
|
+
const DashedUnderlineSpanStyle = "dvp1i89";
|
|
10285
10291
|
const ServiceOutClusterAccessComponent = ({
|
|
10286
10292
|
service,
|
|
10287
10293
|
breakLine = true,
|
|
@@ -10300,29 +10306,38 @@ const ServiceOutClusterAccessComponent = ({
|
|
|
10300
10306
|
content = (_a = spec.ports) == null ? void 0 : _a.filter((v) => !!v).map((p) => [/* @__PURE__ */ common.jsxRuntimeExports.jsx(eagle.Link, {
|
|
10301
10307
|
href: `http://${clusterVip}:${p.nodePort}`,
|
|
10302
10308
|
target: "_blank",
|
|
10303
|
-
className: common.cx_default(
|
|
10304
|
-
children:
|
|
10309
|
+
className: common.cx_default(ShowLinkStyle, eagle.Typo.Label.l4_regular_title),
|
|
10310
|
+
children: /* @__PURE__ */ common.jsxRuntimeExports.jsx(eagle.Tooltip, {
|
|
10311
|
+
title: i18n2.t("dovetail.default_http_protocol_tooltip"),
|
|
10312
|
+
children: /* @__PURE__ */ common.jsxRuntimeExports.jsx("span", {
|
|
10313
|
+
className: DashedUnderlineSpanStyle,
|
|
10314
|
+
children: `${clusterVip}:${p.nodePort}`
|
|
10315
|
+
})
|
|
10316
|
+
})
|
|
10305
10317
|
}, p.name)]);
|
|
10306
10318
|
if (content && content instanceof Array) {
|
|
10307
10319
|
const result = [];
|
|
10308
10320
|
for (let i2 = 0; i2 < content.length; i2++) {
|
|
10309
10321
|
result.push(content[i2]);
|
|
10310
10322
|
if (i2 < content.length - 1) {
|
|
10311
|
-
result.push(",");
|
|
10323
|
+
result.push(", ");
|
|
10312
10324
|
}
|
|
10313
10325
|
}
|
|
10314
10326
|
content = result;
|
|
10315
10327
|
}
|
|
10316
10328
|
break;
|
|
10317
10329
|
}
|
|
10318
|
-
content = (_b = spec.ports) == null ? void 0 : _b.filter((v) => !!v).map((p) => /* @__PURE__ */ common.jsxRuntimeExports.jsx(eagle.
|
|
10319
|
-
|
|
10320
|
-
|
|
10321
|
-
|
|
10322
|
-
|
|
10323
|
-
|
|
10324
|
-
|
|
10325
|
-
|
|
10330
|
+
content = (_b = spec.ports) == null ? void 0 : _b.filter((v) => !!v).map((p) => /* @__PURE__ */ common.jsxRuntimeExports.jsx(eagle.Link, {
|
|
10331
|
+
href: `http://${clusterVip}:${p.nodePort}`,
|
|
10332
|
+
target: "_blank",
|
|
10333
|
+
className: common.cx_default(eagle.Typo.Label.l4_regular_title, BreakLineStyle, LinkStyle$2),
|
|
10334
|
+
children: /* @__PURE__ */ common.jsxRuntimeExports.jsx(eagle.Tooltip, {
|
|
10335
|
+
title: i18n2.t("dovetail.default_http_protocol_tooltip"),
|
|
10336
|
+
children: /* @__PURE__ */ common.jsxRuntimeExports.jsxs("span", {
|
|
10337
|
+
className: DashedUnderlineSpanStyle,
|
|
10338
|
+
children: [clusterVip, ":", p.nodePort]
|
|
10339
|
+
})
|
|
10340
|
+
})
|
|
10326
10341
|
}, p.nodePort));
|
|
10327
10342
|
return /* @__PURE__ */ common.jsxRuntimeExports.jsx("ul", {
|
|
10328
10343
|
children: content
|
|
@@ -12239,17 +12254,14 @@ function CreateButton(props) {
|
|
|
12239
12254
|
const { t: t2, i18n: i18n2 } = common.useTranslation();
|
|
12240
12255
|
const openForm = useOpenForm();
|
|
12241
12256
|
const { resource } = core.useResource();
|
|
12242
|
-
const configs = React.useContext(ConfigsContext);
|
|
12243
|
-
const config = configs[(resource == null ? void 0 : resource.name) || ""];
|
|
12244
12257
|
const label2 = props.label || ((_a = resource == null ? void 0 : resource.meta) == null ? void 0 : _a.kind);
|
|
12245
|
-
const createButtonText = config.createButtonText;
|
|
12246
12258
|
return /* @__PURE__ */ common.jsxRuntimeExports.jsx(
|
|
12247
12259
|
eagle.Button,
|
|
12248
12260
|
{
|
|
12249
12261
|
prefixIcon: /* @__PURE__ */ common.jsxRuntimeExports.jsx(iconsReact.PlusAddCreateNew16BoldOntintIcon, {}),
|
|
12250
12262
|
type: "primary",
|
|
12251
12263
|
onClick: () => openForm(),
|
|
12252
|
-
children:
|
|
12264
|
+
children: props.children || t2("dovetail.create_resource", {
|
|
12253
12265
|
resource: transformResourceKindInSentence(label2, i18n2.language)
|
|
12254
12266
|
})
|
|
12255
12267
|
}
|
|
@@ -12307,7 +12319,8 @@ const TableToolBar = ({
|
|
|
12307
12319
|
title,
|
|
12308
12320
|
description,
|
|
12309
12321
|
selectedKeys,
|
|
12310
|
-
hideCreate
|
|
12322
|
+
hideCreate,
|
|
12323
|
+
createButtonElement
|
|
12311
12324
|
}) => {
|
|
12312
12325
|
const {
|
|
12313
12326
|
resource
|
|
@@ -12325,7 +12338,7 @@ const TableToolBar = ({
|
|
|
12325
12338
|
}) : void 0, /* @__PURE__ */ common.jsxRuntimeExports.jsx(core.CanAccess, {
|
|
12326
12339
|
resource: resource == null ? void 0 : resource.name,
|
|
12327
12340
|
action: AccessControlAuth.Create,
|
|
12328
|
-
children: !hideCreate ? /* @__PURE__ */ common.jsxRuntimeExports.jsx(CreateButton, {
|
|
12341
|
+
children: !hideCreate ? createButtonElement || /* @__PURE__ */ common.jsxRuntimeExports.jsx(CreateButton, {
|
|
12329
12342
|
label: title
|
|
12330
12343
|
}) : null
|
|
12331
12344
|
})]
|
|
@@ -15855,7 +15868,8 @@ function ListPage(props) {
|
|
|
15855
15868
|
selectedKeys,
|
|
15856
15869
|
title: (config == null ? void 0 : config.customListTitle) || (config == null ? void 0 : config.displayName) || config.kind,
|
|
15857
15870
|
description: config == null ? void 0 : config.description,
|
|
15858
|
-
hideCreate: config == null ? void 0 : config.hideCreate
|
|
15871
|
+
hideCreate: config == null ? void 0 : config.hideCreate,
|
|
15872
|
+
createButtonElement: config == null ? void 0 : config.createButtonElement
|
|
15859
15873
|
}), belowToolBarContent, /* @__PURE__ */ common.jsxRuntimeExports.jsx(eagle.Divider, {
|
|
15860
15874
|
style: {
|
|
15861
15875
|
margin: 0,
|
package/dist/refine.js
CHANGED
|
@@ -593,6 +593,7 @@ const only_support_one_yaml$1 = "Only one YAML configuration is supported at a t
|
|
|
593
593
|
const not_support$1 = "Not supported";
|
|
594
594
|
const stopped_state$1 = "Stopped";
|
|
595
595
|
const any_node_ip$1 = "Any node IP";
|
|
596
|
+
const default_http_protocol_tooltip$1 = "The link uses HTTP protocol by default.";
|
|
596
597
|
const storage_class$1 = "Storage class";
|
|
597
598
|
const persistent_volume$1 = "Persistent volume";
|
|
598
599
|
const provisioner$1 = "Provisioner";
|
|
@@ -636,9 +637,9 @@ const retain$1 = "Retain";
|
|
|
636
637
|
const default_sc$1 = "Default storage class";
|
|
637
638
|
const reclaim_policy$1 = "Reclaim policy";
|
|
638
639
|
const allow_expand$1 = "Volume expansion";
|
|
639
|
-
const request_capacity$1 = "
|
|
640
|
-
const edit_request_capacity$1 = "Edit
|
|
641
|
-
const edit_request_capacity_success_toast$1 = "Successfully edited
|
|
640
|
+
const request_capacity$1 = "Requested capacity";
|
|
641
|
+
const edit_request_capacity$1 = "Edit requested capacity";
|
|
642
|
+
const edit_request_capacity_success_toast$1 = "Successfully edited the requested capacity";
|
|
642
643
|
const edit_taint$1 = "Edit taint";
|
|
643
644
|
const edit_node_taint$1 = "Edit taint";
|
|
644
645
|
const edit_node_taint_success_toast$1 = "Successfully edited the taint for the node {{name}}";
|
|
@@ -647,10 +648,10 @@ const node_taint_PreferNoSchedule$1 = "PreferNoSchedule";
|
|
|
647
648
|
const node_taint_NoExecute$1 = "NoExecute";
|
|
648
649
|
const taint$1 = "Taint";
|
|
649
650
|
const change_form_mode_alert$1 = "Switching from YAML editing to form editing will discard all changes made to the YAML file.";
|
|
650
|
-
const pvc_storage_required$1 = "Please specify the
|
|
651
|
+
const pvc_storage_required$1 = "Please specify the requested capacity.";
|
|
651
652
|
const pvc_storage_min$1 = "Please enter a positive integer.";
|
|
652
653
|
const pvc_storage_reduce_limit$1 = "The value cannot be less than the current value.";
|
|
653
|
-
const pvc_storage_max_limit$1 = "The
|
|
654
|
+
const pvc_storage_max_limit$1 = "The requested capacity cannot exceed 64 TiB.";
|
|
654
655
|
const key_empty_text$1 = "Please specify a key.";
|
|
655
656
|
const format_error$1 = "Format error.";
|
|
656
657
|
const taint_effect_empty_text$1 = "Please select an effect.";
|
|
@@ -869,6 +870,7 @@ const dovetail$1 = {
|
|
|
869
870
|
not_support: not_support$1,
|
|
870
871
|
stopped_state: stopped_state$1,
|
|
871
872
|
any_node_ip: any_node_ip$1,
|
|
873
|
+
default_http_protocol_tooltip: default_http_protocol_tooltip$1,
|
|
872
874
|
storage_class: storage_class$1,
|
|
873
875
|
persistent_volume: persistent_volume$1,
|
|
874
876
|
provisioner: provisioner$1,
|
|
@@ -1150,6 +1152,7 @@ const support = "支持";
|
|
|
1150
1152
|
const not_support = "不支持";
|
|
1151
1153
|
const stopped_state = "已停止";
|
|
1152
1154
|
const any_node_ip = "任意节点 IP";
|
|
1155
|
+
const default_http_protocol_tooltip = "当前链接默认使用 HTTP 协议。";
|
|
1153
1156
|
const storage_class = "存储类";
|
|
1154
1157
|
const persistent_volume = "持久卷";
|
|
1155
1158
|
const provisioner = "制备器";
|
|
@@ -1425,6 +1428,7 @@ const dovetail = {
|
|
|
1425
1428
|
not_support,
|
|
1426
1429
|
stopped_state,
|
|
1427
1430
|
any_node_ip,
|
|
1431
|
+
default_http_protocol_tooltip,
|
|
1428
1432
|
storage_class,
|
|
1429
1433
|
persistent_volume,
|
|
1430
1434
|
provisioner,
|
|
@@ -10241,7 +10245,7 @@ class IngressClassModel extends ResourceModel {
|
|
|
10241
10245
|
return (_a = this.spec) == null ? void 0 : _a.controller;
|
|
10242
10246
|
}
|
|
10243
10247
|
}
|
|
10244
|
-
const
|
|
10248
|
+
const index_1rec449 = "";
|
|
10245
10249
|
const ServiceInClusterAccessComponent = ({
|
|
10246
10250
|
service
|
|
10247
10251
|
}) => {
|
|
@@ -10263,6 +10267,8 @@ const ServiceInClusterAccessComponent = ({
|
|
|
10263
10267
|
};
|
|
10264
10268
|
const BreakLineStyle = "b1vtjd4k";
|
|
10265
10269
|
const LinkStyle$2 = "luro4rx";
|
|
10270
|
+
const ShowLinkStyle = "s1gydjqf";
|
|
10271
|
+
const DashedUnderlineSpanStyle = "dvp1i89";
|
|
10266
10272
|
const ServiceOutClusterAccessComponent = ({
|
|
10267
10273
|
service,
|
|
10268
10274
|
breakLine = true,
|
|
@@ -10281,29 +10287,38 @@ const ServiceOutClusterAccessComponent = ({
|
|
|
10281
10287
|
content = (_a = spec.ports) == null ? void 0 : _a.filter((v) => !!v).map((p) => [/* @__PURE__ */ jsxRuntimeExports.jsx(Link$1, {
|
|
10282
10288
|
href: `http://${clusterVip}:${p.nodePort}`,
|
|
10283
10289
|
target: "_blank",
|
|
10284
|
-
className: cx_default(
|
|
10285
|
-
children:
|
|
10290
|
+
className: cx_default(ShowLinkStyle, Typo.Label.l4_regular_title),
|
|
10291
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Tooltip, {
|
|
10292
|
+
title: i18n2.t("dovetail.default_http_protocol_tooltip"),
|
|
10293
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", {
|
|
10294
|
+
className: DashedUnderlineSpanStyle,
|
|
10295
|
+
children: `${clusterVip}:${p.nodePort}`
|
|
10296
|
+
})
|
|
10297
|
+
})
|
|
10286
10298
|
}, p.name)]);
|
|
10287
10299
|
if (content && content instanceof Array) {
|
|
10288
10300
|
const result = [];
|
|
10289
10301
|
for (let i2 = 0; i2 < content.length; i2++) {
|
|
10290
10302
|
result.push(content[i2]);
|
|
10291
10303
|
if (i2 < content.length - 1) {
|
|
10292
|
-
result.push(",");
|
|
10304
|
+
result.push(", ");
|
|
10293
10305
|
}
|
|
10294
10306
|
}
|
|
10295
10307
|
content = result;
|
|
10296
10308
|
}
|
|
10297
10309
|
break;
|
|
10298
10310
|
}
|
|
10299
|
-
content = (_b = spec.ports) == null ? void 0 : _b.filter((v) => !!v).map((p) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
10300
|
-
|
|
10301
|
-
|
|
10302
|
-
|
|
10303
|
-
|
|
10304
|
-
|
|
10305
|
-
|
|
10306
|
-
|
|
10311
|
+
content = (_b = spec.ports) == null ? void 0 : _b.filter((v) => !!v).map((p) => /* @__PURE__ */ jsxRuntimeExports.jsx(Link$1, {
|
|
10312
|
+
href: `http://${clusterVip}:${p.nodePort}`,
|
|
10313
|
+
target: "_blank",
|
|
10314
|
+
className: cx_default(Typo.Label.l4_regular_title, BreakLineStyle, LinkStyle$2),
|
|
10315
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Tooltip, {
|
|
10316
|
+
title: i18n2.t("dovetail.default_http_protocol_tooltip"),
|
|
10317
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs("span", {
|
|
10318
|
+
className: DashedUnderlineSpanStyle,
|
|
10319
|
+
children: [clusterVip, ":", p.nodePort]
|
|
10320
|
+
})
|
|
10321
|
+
})
|
|
10307
10322
|
}, p.nodePort));
|
|
10308
10323
|
return /* @__PURE__ */ jsxRuntimeExports.jsx("ul", {
|
|
10309
10324
|
children: content
|
|
@@ -12220,17 +12235,14 @@ function CreateButton(props) {
|
|
|
12220
12235
|
const { t: t2, i18n: i18n2 } = useTranslation();
|
|
12221
12236
|
const openForm = useOpenForm();
|
|
12222
12237
|
const { resource } = useResource();
|
|
12223
|
-
const configs = useContext(ConfigsContext);
|
|
12224
|
-
const config = configs[(resource == null ? void 0 : resource.name) || ""];
|
|
12225
12238
|
const label2 = props.label || ((_a = resource == null ? void 0 : resource.meta) == null ? void 0 : _a.kind);
|
|
12226
|
-
const createButtonText = config.createButtonText;
|
|
12227
12239
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
12228
12240
|
Button,
|
|
12229
12241
|
{
|
|
12230
12242
|
prefixIcon: /* @__PURE__ */ jsxRuntimeExports.jsx(PlusAddCreateNew16BoldOntintIcon, {}),
|
|
12231
12243
|
type: "primary",
|
|
12232
12244
|
onClick: () => openForm(),
|
|
12233
|
-
children:
|
|
12245
|
+
children: props.children || t2("dovetail.create_resource", {
|
|
12234
12246
|
resource: transformResourceKindInSentence(label2, i18n2.language)
|
|
12235
12247
|
})
|
|
12236
12248
|
}
|
|
@@ -12288,7 +12300,8 @@ const TableToolBar = ({
|
|
|
12288
12300
|
title,
|
|
12289
12301
|
description,
|
|
12290
12302
|
selectedKeys,
|
|
12291
|
-
hideCreate
|
|
12303
|
+
hideCreate,
|
|
12304
|
+
createButtonElement
|
|
12292
12305
|
}) => {
|
|
12293
12306
|
const {
|
|
12294
12307
|
resource
|
|
@@ -12306,7 +12319,7 @@ const TableToolBar = ({
|
|
|
12306
12319
|
}) : void 0, /* @__PURE__ */ jsxRuntimeExports.jsx(CanAccess, {
|
|
12307
12320
|
resource: resource == null ? void 0 : resource.name,
|
|
12308
12321
|
action: AccessControlAuth.Create,
|
|
12309
|
-
children: !hideCreate ? /* @__PURE__ */ jsxRuntimeExports.jsx(CreateButton, {
|
|
12322
|
+
children: !hideCreate ? createButtonElement || /* @__PURE__ */ jsxRuntimeExports.jsx(CreateButton, {
|
|
12310
12323
|
label: title
|
|
12311
12324
|
}) : null
|
|
12312
12325
|
})]
|
|
@@ -15836,7 +15849,8 @@ function ListPage(props) {
|
|
|
15836
15849
|
selectedKeys,
|
|
15837
15850
|
title: (config == null ? void 0 : config.customListTitle) || (config == null ? void 0 : config.displayName) || config.kind,
|
|
15838
15851
|
description: config == null ? void 0 : config.description,
|
|
15839
|
-
hideCreate: config == null ? void 0 : config.hideCreate
|
|
15852
|
+
hideCreate: config == null ? void 0 : config.hideCreate,
|
|
15853
|
+
createButtonElement: config == null ? void 0 : config.createButtonElement
|
|
15840
15854
|
}), belowToolBarContent, /* @__PURE__ */ jsxRuntimeExports.jsx(Divider, {
|
|
15841
15855
|
style: {
|
|
15842
15856
|
margin: 0,
|
package/dist/style.css
CHANGED
|
@@ -966,7 +966,24 @@
|
|
|
966
966
|
|
|
967
967
|
.luro4rx.ant-btn-link.ant-btn {
|
|
968
968
|
padding: 0;
|
|
969
|
-
height:
|
|
969
|
+
height: 18px;
|
|
970
|
+
}
|
|
971
|
+
|
|
972
|
+
.s1gydjqf.ant-btn-link.ant-btn {
|
|
973
|
+
padding: 0;
|
|
974
|
+
height: 18px;
|
|
975
|
+
color: var(--blue-60) !important;
|
|
976
|
+
}
|
|
977
|
+
.s1gydjqf.ant-btn-link.ant-btn:hover {
|
|
978
|
+
color: var(--blue-50) !important;
|
|
979
|
+
}
|
|
980
|
+
|
|
981
|
+
.dvp1i89 {
|
|
982
|
+
display: inline-block;
|
|
983
|
+
width: auto !important;
|
|
984
|
+
height: 18px;
|
|
985
|
+
line-height: 18px;
|
|
986
|
+
border-bottom: 1px dashed rgba(107, 128, 167, 0.6);
|
|
970
987
|
}/* // basic */
|
|
971
988
|
/* FishEye Color Variables and Functions */
|
|
972
989
|
/*
|
package/dist/types/resource.d.ts
CHANGED
|
@@ -205,8 +205,8 @@ export type ResourceConfig<Model extends ResourceModel = ResourceModel> = {
|
|
|
205
205
|
* 开启后,Dovetail不会为该资源创建路由,也不会渲染默认的UI组件。
|
|
206
206
|
*/
|
|
207
207
|
isCustom?: boolean;
|
|
208
|
-
/**
|
|
209
|
-
|
|
208
|
+
/** 自定义创建按钮元素,提供时替代默认的 CreateButton 组件 */
|
|
209
|
+
createButtonElement?: React.ReactNode;
|
|
210
210
|
/** 删除操作的提示文本
|
|
211
211
|
* 默认是:该操作无法被撤回。
|
|
212
212
|
*/
|