@dovetail-v2/refine 0.3.10-alpha.0 → 0.3.11-alpha.1
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/{MonacoYamlEditor-2c53f526.cjs → MonacoYamlEditor-88c3e93a.cjs} +1 -1
- package/dist/{MonacoYamlEditor-67c1f941.js → MonacoYamlEditor-e113425c.js} +1 -1
- package/dist/{index-2fd7d5f7.js → index-4f353f96.js} +18 -11
- package/dist/{index-044042b7.cjs → index-e5d37dbf.cjs} +18 -11
- package/dist/refine.cjs +1 -1
- package/dist/refine.js +1 -1
- package/package.json +1 -1
|
@@ -6,7 +6,7 @@ const monaco = require("monaco-editor");
|
|
|
6
6
|
const monacoYaml = require("monaco-yaml");
|
|
7
7
|
const React = require("react");
|
|
8
8
|
const ReactDOM = require("react-dom");
|
|
9
|
-
const refine = require("./index-
|
|
9
|
+
const refine = require("./index-e5d37dbf.cjs");
|
|
10
10
|
require("dayjs");
|
|
11
11
|
require("i18next");
|
|
12
12
|
require("@refinedev/core");
|
|
@@ -4,7 +4,7 @@ import * as monaco from "monaco-editor";
|
|
|
4
4
|
import { setDiagnosticsOptions } from "monaco-yaml";
|
|
5
5
|
import { useRef, useEffect } from "react";
|
|
6
6
|
import ReactDOM from "react-dom";
|
|
7
|
-
import { Y as YamlEditorStyle } from "./index-
|
|
7
|
+
import { Y as YamlEditorStyle } from "./index-4f353f96.js";
|
|
8
8
|
import "dayjs";
|
|
9
9
|
import "i18next";
|
|
10
10
|
import "@refinedev/core";
|
|
@@ -12982,7 +12982,7 @@ const PodLogTab = (i18n2, apiUrl) => ({
|
|
|
12982
12982
|
]
|
|
12983
12983
|
});
|
|
12984
12984
|
const NetworkPolicyRulesViewer_r6jity = "";
|
|
12985
|
-
const MonacoYamlEditor$1 = lazy(() => import("./MonacoYamlEditor-
|
|
12985
|
+
const MonacoYamlEditor$1 = lazy(() => import("./MonacoYamlEditor-e113425c.js"));
|
|
12986
12986
|
const EditorStyle$1 = "e1cjl2b8";
|
|
12987
12987
|
const NetworkPolicyRulesViewer = ({
|
|
12988
12988
|
ingressOrEgress,
|
|
@@ -15253,7 +15253,7 @@ const PlainCodeStyle = "pqch97v";
|
|
|
15253
15253
|
const ErrorMsgStyle = "eh2qjnl";
|
|
15254
15254
|
const ErrorWrapperStyle = "e19q2bnp";
|
|
15255
15255
|
const YamlEditorStyle = "y16u5v3w";
|
|
15256
|
-
const MonacoYamlEditor = React.lazy(() => import("./MonacoYamlEditor-
|
|
15256
|
+
const MonacoYamlEditor = React.lazy(() => import("./MonacoYamlEditor-e113425c.js"));
|
|
15257
15257
|
const MonacoYamlDiffEditor = React.lazy(() => import("./MonacoYamlDiffEditor-9232e9fc.js"));
|
|
15258
15258
|
const YamlEditorComponent = forwardRef(
|
|
15259
15259
|
function YamlEditorComponent2(props, ref) {
|
|
@@ -16016,6 +16016,7 @@ const RefineFormContainer = React.forwardRef(function RefineFormContainer2({
|
|
|
16016
16016
|
onError,
|
|
16017
16017
|
onSaveButtonPropsChange
|
|
16018
16018
|
}, ref) {
|
|
16019
|
+
var _a, _b;
|
|
16019
16020
|
const action = id ? "edit" : "create";
|
|
16020
16021
|
const refineFormResult = useRefineForm({
|
|
16021
16022
|
config,
|
|
@@ -16114,6 +16115,9 @@ const RefineFormContainer = React.forwardRef(function RefineFormContainer2({
|
|
|
16114
16115
|
}),
|
|
16115
16116
|
[refineFormResult.formResult]
|
|
16116
16117
|
);
|
|
16118
|
+
if (action === "edit" && !((_b = (_a = refineFormResult.formResult.getValues()) == null ? void 0 : _a.metadata) == null ? void 0 : _b.name)) {
|
|
16119
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Loading, {});
|
|
16120
|
+
}
|
|
16117
16121
|
if (isYamlMode) {
|
|
16118
16122
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(YamlForm, { ...yamlFormProps });
|
|
16119
16123
|
}
|
|
@@ -16225,7 +16229,7 @@ function ConfirmModal({
|
|
|
16225
16229
|
});
|
|
16226
16230
|
}
|
|
16227
16231
|
function FormModal(props) {
|
|
16228
|
-
var _a, _b, _c;
|
|
16232
|
+
var _a, _b, _c, _d;
|
|
16229
16233
|
const {
|
|
16230
16234
|
resource: resourceFromProps,
|
|
16231
16235
|
id,
|
|
@@ -16280,11 +16284,11 @@ function FormModal(props) {
|
|
|
16280
16284
|
return "";
|
|
16281
16285
|
}, [isError, id, i18n2]);
|
|
16282
16286
|
const title = useMemo(() => {
|
|
16283
|
-
var _a2, _b2, _c2,
|
|
16287
|
+
var _a2, _b2, _c2, _d2;
|
|
16284
16288
|
if (typeof ((_a2 = config.formConfig) == null ? void 0 : _a2.formTitle) === "string")
|
|
16285
16289
|
return (_b2 = config.formConfig) == null ? void 0 : _b2.formTitle;
|
|
16286
16290
|
if (typeof ((_c2 = config.formConfig) == null ? void 0 : _c2.formTitle) === "function") {
|
|
16287
|
-
return (
|
|
16291
|
+
return (_d2 = config.formConfig) == null ? void 0 : _d2.formTitle(action);
|
|
16288
16292
|
}
|
|
16289
16293
|
const label2 = config.displayName || (config == null ? void 0 : config.kind);
|
|
16290
16294
|
return i18n2.t(id ? "dovetail.edit_resource" : "dovetail.create_resource", {
|
|
@@ -16292,11 +16296,11 @@ function FormModal(props) {
|
|
|
16292
16296
|
});
|
|
16293
16297
|
}, [action, config.formConfig, config.displayName, config == null ? void 0 : config.kind, i18n2, id]);
|
|
16294
16298
|
const desc = useMemo(() => {
|
|
16295
|
-
var _a2, _b2, _c2,
|
|
16299
|
+
var _a2, _b2, _c2, _d2;
|
|
16296
16300
|
if (typeof ((_a2 = config.formConfig) == null ? void 0 : _a2.formDesc) === "string")
|
|
16297
16301
|
return (_b2 = config.formConfig) == null ? void 0 : _b2.formDesc;
|
|
16298
16302
|
if (typeof ((_c2 = config.formConfig) == null ? void 0 : _c2.formDesc) === "function") {
|
|
16299
|
-
return (
|
|
16303
|
+
return (_d2 = config.formConfig) == null ? void 0 : _d2.formDesc(action);
|
|
16300
16304
|
}
|
|
16301
16305
|
return "";
|
|
16302
16306
|
}, [action, config.formConfig]);
|
|
@@ -16383,10 +16387,9 @@ function FormModal(props) {
|
|
|
16383
16387
|
onOk,
|
|
16384
16388
|
okButtonProps: {
|
|
16385
16389
|
...omit$1(saveButtonProps, "onClick"),
|
|
16386
|
-
children: (_c = config.formConfig) == null ? void 0 : _c.saveButtonText
|
|
16387
|
-
size: "middle"
|
|
16390
|
+
children: (_c = config.formConfig) == null ? void 0 : _c.saveButtonText
|
|
16388
16391
|
},
|
|
16389
|
-
okText,
|
|
16392
|
+
okText: ((_d = config.formConfig) == null ? void 0 : _d.saveButtonText) || okText,
|
|
16390
16393
|
destroyOnClose: true,
|
|
16391
16394
|
destroyOtherStep: true,
|
|
16392
16395
|
...modalProps,
|
|
@@ -17050,7 +17053,11 @@ function SelectMatchLabelButton(props) {
|
|
|
17050
17053
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Popover, {
|
|
17051
17054
|
trigger: "click",
|
|
17052
17055
|
visible: popoverVisible,
|
|
17053
|
-
onVisibleChange:
|
|
17056
|
+
onVisibleChange: (newPopoverVisible) => {
|
|
17057
|
+
if (disabled)
|
|
17058
|
+
return;
|
|
17059
|
+
setPopoverVisible(newPopoverVisible);
|
|
17060
|
+
},
|
|
17054
17061
|
overlayClassName: PopoverOverlayStyle,
|
|
17055
17062
|
content: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", {
|
|
17056
17063
|
className: PopoverContentStyle,
|
|
@@ -12983,7 +12983,7 @@ const PodLogTab = (i18n2, apiUrl) => ({
|
|
|
12983
12983
|
]
|
|
12984
12984
|
});
|
|
12985
12985
|
const NetworkPolicyRulesViewer_r6jity = "";
|
|
12986
|
-
const MonacoYamlEditor$1 = React.lazy(() => Promise.resolve().then(() => require("./MonacoYamlEditor-
|
|
12986
|
+
const MonacoYamlEditor$1 = React.lazy(() => Promise.resolve().then(() => require("./MonacoYamlEditor-88c3e93a.cjs")));
|
|
12987
12987
|
const EditorStyle$1 = "e1cjl2b8";
|
|
12988
12988
|
const NetworkPolicyRulesViewer = ({
|
|
12989
12989
|
ingressOrEgress,
|
|
@@ -15254,7 +15254,7 @@ const PlainCodeStyle = "pqch97v";
|
|
|
15254
15254
|
const ErrorMsgStyle = "eh2qjnl";
|
|
15255
15255
|
const ErrorWrapperStyle = "e19q2bnp";
|
|
15256
15256
|
const YamlEditorStyle = "y16u5v3w";
|
|
15257
|
-
const MonacoYamlEditor = React.lazy(() => Promise.resolve().then(() => require("./MonacoYamlEditor-
|
|
15257
|
+
const MonacoYamlEditor = React.lazy(() => Promise.resolve().then(() => require("./MonacoYamlEditor-88c3e93a.cjs")));
|
|
15258
15258
|
const MonacoYamlDiffEditor = React.lazy(() => Promise.resolve().then(() => require("./MonacoYamlDiffEditor-7a07db88.cjs")));
|
|
15259
15259
|
const YamlEditorComponent = React.forwardRef(
|
|
15260
15260
|
function YamlEditorComponent2(props, ref) {
|
|
@@ -16017,6 +16017,7 @@ const RefineFormContainer = React.forwardRef(function RefineFormContainer2({
|
|
|
16017
16017
|
onError,
|
|
16018
16018
|
onSaveButtonPropsChange
|
|
16019
16019
|
}, ref) {
|
|
16020
|
+
var _a, _b;
|
|
16020
16021
|
const action = id ? "edit" : "create";
|
|
16021
16022
|
const refineFormResult = useRefineForm({
|
|
16022
16023
|
config,
|
|
@@ -16115,6 +16116,9 @@ const RefineFormContainer = React.forwardRef(function RefineFormContainer2({
|
|
|
16115
16116
|
}),
|
|
16116
16117
|
[refineFormResult.formResult]
|
|
16117
16118
|
);
|
|
16119
|
+
if (action === "edit" && !((_b = (_a = refineFormResult.formResult.getValues()) == null ? void 0 : _a.metadata) == null ? void 0 : _b.name)) {
|
|
16120
|
+
return /* @__PURE__ */ common.jsxRuntimeExports.jsx(eagle.Loading, {});
|
|
16121
|
+
}
|
|
16118
16122
|
if (isYamlMode) {
|
|
16119
16123
|
return /* @__PURE__ */ common.jsxRuntimeExports.jsx(YamlForm, { ...yamlFormProps });
|
|
16120
16124
|
}
|
|
@@ -16226,7 +16230,7 @@ function ConfirmModal({
|
|
|
16226
16230
|
});
|
|
16227
16231
|
}
|
|
16228
16232
|
function FormModal(props) {
|
|
16229
|
-
var _a, _b, _c;
|
|
16233
|
+
var _a, _b, _c, _d;
|
|
16230
16234
|
const {
|
|
16231
16235
|
resource: resourceFromProps,
|
|
16232
16236
|
id,
|
|
@@ -16281,11 +16285,11 @@ function FormModal(props) {
|
|
|
16281
16285
|
return "";
|
|
16282
16286
|
}, [isError, id, i18n2]);
|
|
16283
16287
|
const title = React.useMemo(() => {
|
|
16284
|
-
var _a2, _b2, _c2,
|
|
16288
|
+
var _a2, _b2, _c2, _d2;
|
|
16285
16289
|
if (typeof ((_a2 = config.formConfig) == null ? void 0 : _a2.formTitle) === "string")
|
|
16286
16290
|
return (_b2 = config.formConfig) == null ? void 0 : _b2.formTitle;
|
|
16287
16291
|
if (typeof ((_c2 = config.formConfig) == null ? void 0 : _c2.formTitle) === "function") {
|
|
16288
|
-
return (
|
|
16292
|
+
return (_d2 = config.formConfig) == null ? void 0 : _d2.formTitle(action);
|
|
16289
16293
|
}
|
|
16290
16294
|
const label2 = config.displayName || (config == null ? void 0 : config.kind);
|
|
16291
16295
|
return i18n2.t(id ? "dovetail.edit_resource" : "dovetail.create_resource", {
|
|
@@ -16293,11 +16297,11 @@ function FormModal(props) {
|
|
|
16293
16297
|
});
|
|
16294
16298
|
}, [action, config.formConfig, config.displayName, config == null ? void 0 : config.kind, i18n2, id]);
|
|
16295
16299
|
const desc = React.useMemo(() => {
|
|
16296
|
-
var _a2, _b2, _c2,
|
|
16300
|
+
var _a2, _b2, _c2, _d2;
|
|
16297
16301
|
if (typeof ((_a2 = config.formConfig) == null ? void 0 : _a2.formDesc) === "string")
|
|
16298
16302
|
return (_b2 = config.formConfig) == null ? void 0 : _b2.formDesc;
|
|
16299
16303
|
if (typeof ((_c2 = config.formConfig) == null ? void 0 : _c2.formDesc) === "function") {
|
|
16300
|
-
return (
|
|
16304
|
+
return (_d2 = config.formConfig) == null ? void 0 : _d2.formDesc(action);
|
|
16301
16305
|
}
|
|
16302
16306
|
return "";
|
|
16303
16307
|
}, [action, config.formConfig]);
|
|
@@ -16384,10 +16388,9 @@ function FormModal(props) {
|
|
|
16384
16388
|
onOk,
|
|
16385
16389
|
okButtonProps: {
|
|
16386
16390
|
...lodashEs.omit(saveButtonProps, "onClick"),
|
|
16387
|
-
children: (_c = config.formConfig) == null ? void 0 : _c.saveButtonText
|
|
16388
|
-
size: "middle"
|
|
16391
|
+
children: (_c = config.formConfig) == null ? void 0 : _c.saveButtonText
|
|
16389
16392
|
},
|
|
16390
|
-
okText,
|
|
16393
|
+
okText: ((_d = config.formConfig) == null ? void 0 : _d.saveButtonText) || okText,
|
|
16391
16394
|
destroyOnClose: true,
|
|
16392
16395
|
destroyOtherStep: true,
|
|
16393
16396
|
...modalProps,
|
|
@@ -17051,7 +17054,11 @@ function SelectMatchLabelButton(props) {
|
|
|
17051
17054
|
children: /* @__PURE__ */ common.jsxRuntimeExports.jsx(eagle.Popover, {
|
|
17052
17055
|
trigger: "click",
|
|
17053
17056
|
visible: popoverVisible,
|
|
17054
|
-
onVisibleChange:
|
|
17057
|
+
onVisibleChange: (newPopoverVisible) => {
|
|
17058
|
+
if (disabled)
|
|
17059
|
+
return;
|
|
17060
|
+
setPopoverVisible(newPopoverVisible);
|
|
17061
|
+
},
|
|
17055
17062
|
overlayClassName: PopoverOverlayStyle,
|
|
17056
17063
|
content: /* @__PURE__ */ common.jsxRuntimeExports.jsxs("div", {
|
|
17057
17064
|
className: PopoverContentStyle,
|
package/dist/refine.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const refine = require("./index-
|
|
3
|
+
const refine = require("./index-e5d37dbf.cjs");
|
|
4
4
|
require("./common-1eb43414.cjs");
|
|
5
5
|
require("@cloudtower/eagle");
|
|
6
6
|
require("@refinedev/core");
|
package/dist/refine.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { bS, cQ, A, aX, aZ, aG, co, bl, bE, a2, cC, cq, aR, T, C, j, cW, aJ, bq, ad, cY, aj, aq, d6, ay, cr, cp, d9, aN, bx, w, aE, bG, d8, cR, bJ, D, b2, at, cl, bM, bO, bN, as, ck, au, a1, ce, cd, d7, bj, aV, cT, ae, c0, bV, cV, cU, cX, cA, aH, ak, s, q, cZ, I, bu, aU, t, M, bf, bh, cs, c$, aM, bt, ar, az, aA, a9, aB, cf, aY, aF, bH, cg, bK, aa, dj, cB, cL, bR, N, a3, g, aW, a7, bU, bz, by, c_, c6, de, i, ci, dd, cm, cn, aK, br, cu, L, bb, bc, bp, H, bd, J, be, B, b6, cO, z, b5, G, b9, E, b7, F, b8, K, c7, ba, cN, ab, dh, dg, P, bn, v, af, ai, c5, bk, d3, d2, b0, bv, cb, ca, p, aL, bm, x, ch, bw, b1, di, y, cE, cS, bP, bX, bY, dl, aI, d5, h, ah, ao, an, bQ, al, d4, c9, am, cP, cc, bi, bB, av, R, Q, O, bg, cH, cK, cG, cF, cI, cJ, cD, cv, cy, cz, cx, cw, ct, cM, bZ, aO, bs, cj, aC, m, c1, l, a_, dc, o, c2, a$, n, aT, bo, k, db, aQ, aS, bC, bF, bD, aP, S, bI, da, df, b3, b4, bA, bL, c8, c3, c4, ac, dx, a0, d1, ag, W, d0, ap, ax, aw, aD, b_, U, a4, d, dp, dn, dr, du, dt, dk, a8, ds, dm, bW, dq, a6, a5, r, a, c, e, X, V, Z, f, _, u, bT, $, b$, b, dB, dy, dz, dA, dD, dC, dv, dw } from "./index-
|
|
1
|
+
import { bS, cQ, A, aX, aZ, aG, co, bl, bE, a2, cC, cq, aR, T, C, j, cW, aJ, bq, ad, cY, aj, aq, d6, ay, cr, cp, d9, aN, bx, w, aE, bG, d8, cR, bJ, D, b2, at, cl, bM, bO, bN, as, ck, au, a1, ce, cd, d7, bj, aV, cT, ae, c0, bV, cV, cU, cX, cA, aH, ak, s, q, cZ, I, bu, aU, t, M, bf, bh, cs, c$, aM, bt, ar, az, aA, a9, aB, cf, aY, aF, bH, cg, bK, aa, dj, cB, cL, bR, N, a3, g, aW, a7, bU, bz, by, c_, c6, de, i, ci, dd, cm, cn, aK, br, cu, L, bb, bc, bp, H, bd, J, be, B, b6, cO, z, b5, G, b9, E, b7, F, b8, K, c7, ba, cN, ab, dh, dg, P, bn, v, af, ai, c5, bk, d3, d2, b0, bv, cb, ca, p, aL, bm, x, ch, bw, b1, di, y, cE, cS, bP, bX, bY, dl, aI, d5, h, ah, ao, an, bQ, al, d4, c9, am, cP, cc, bi, bB, av, R, Q, O, bg, cH, cK, cG, cF, cI, cJ, cD, cv, cy, cz, cx, cw, ct, cM, bZ, aO, bs, cj, aC, m, c1, l, a_, dc, o, c2, a$, n, aT, bo, k, db, aQ, aS, bC, bF, bD, aP, S, bI, da, df, b3, b4, bA, bL, c8, c3, c4, ac, dx, a0, d1, ag, W, d0, ap, ax, aw, aD, b_, U, a4, d, dp, dn, dr, du, dt, dk, a8, ds, dm, bW, dq, a6, a5, r, a, c, e, X, V, Z, f, _, u, bT, $, b$, b, dB, dy, dz, dA, dD, dC, dv, dw } from "./index-4f353f96.js";
|
|
2
2
|
import "./common-241b21f8.js";
|
|
3
3
|
import "@cloudtower/eagle";
|
|
4
4
|
import "@refinedev/core";
|