@dovetail-v2/refine 0.0.34 → 0.0.35-beta.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.
@@ -10,9 +10,9 @@ import React__default, { createElement, isValidElement, cloneElement, Children,
10
10
  import { ResourceContext, matchResourceFromRoute, useResource, useDelete, useNavigation, useBreadcrumb, useList, useParsed, useGo, useDeleteMany, useShow, useUpdate, useDataProvider, useRefineContext, useTranslate, useWarnAboutChange, useForm as useForm$1, flattenObjectKeys, useInvalidate, useUserFriendlyName, useModal, pickNotDeprecated, useMenu, useTable, Refine } from "@refinedev/core";
11
11
  import { parse, stringify } from "qs";
12
12
  import { useLocation, useHistory, useParams, matchPath, Link, Route, NavLink, Router } from "react-router-dom";
13
- import { Typo, useUIKit, kitContext, Link as Link$1, OverflowTooltip, Tooltip, pushModal, StatusCapsule, Button, Icon as Icon$1, popModal, Loading, Divider, Fields, Form, Space, Modal, useMessage, ModalStack, KitStoreProvider } from "@cloudtower/eagle";
13
+ import { Typo, useUIKit, kitContext, Link as Link$1, OverflowTooltip, Tooltip, StatusCapsule, pushModal, Button, Icon as Icon$1, popModal, Loading, Divider, Fields, Form, Space, Modal, useMessage, ModalStack, KitStoreProvider } from "@cloudtower/eagle";
14
+ import { PlusAddCreateNew16BoldOntintIcon, EditPen16PrimaryIcon, Download16GradientBlueIcon, TrashBinDelete16Icon, MoreEllipsis324BoldSecondaryIcon, MoreEllipsis324BoldBlueIcon, MoreEllipsis316BoldBlueIcon, ArrowChevronLeft16BoldTertiaryIcon, ArrowChevronLeftSmall16BoldBlueIcon, EditPen16GradientBlueIcon, ViewEye16GrayIcon, RecoverContinue16GradientBlueIcon, SuspendedPause16GradientBlueIcon, Retry16GradientBlueIcon, HierarchyTriangleRight16GrayIcon, HierarchyTriangleRight16BlueIcon, ClipboardCopy16GradientGrayIcon, ClipboardCopy16GradientBlueIcon, Retry16GradientGrayIcon, EditPen16GradientGrayIcon, Showdiff16GradientGrayIcon, Showdiff16GradientBlueIcon, XmarkFailedSeriousWarningFill16RedIcon, ExclamationErrorCircleFill16RedIcon, Pause16GradientBlueIcon } from "@cloudtower/icons-react";
14
15
  import { get as get$2, first, debounce, last, isObject as isObject$2, merge, keyBy } from "lodash-es";
15
- import { PlusAddCreateNew16BoldOntintIcon, EditPen16PrimaryIcon, Download16GradientBlueIcon, TrashBinDelete16Icon, MoreEllipsis324BoldSecondaryIcon, MoreEllipsis324BoldBlueIcon, MoreEllipsis316BoldBlueIcon, ArrowChevronLeft16BoldTertiaryIcon, ArrowChevronLeftSmall16BoldBlueIcon, ViewEye16GrayIcon, RecoverContinue16GradientBlueIcon, SuspendedPause16GradientBlueIcon, Retry16GradientBlueIcon, HierarchyTriangleRight16GrayIcon, HierarchyTriangleRight16BlueIcon, ClipboardCopy16GradientGrayIcon, ClipboardCopy16GradientBlueIcon, Retry16GradientGrayIcon, EditPen16GradientGrayIcon, EditPen16GradientBlueIcon, Showdiff16GradientGrayIcon, Showdiff16GradientBlueIcon, XmarkFailedSeriousWarningFill16RedIcon, ExclamationErrorCircleFill16RedIcon, Pause16GradientBlueIcon } from "@cloudtower/icons-react";
16
16
  import yaml from "js-yaml";
17
17
  import * as monaco from "monaco-editor";
18
18
  import { setDiagnosticsOptions } from "monaco-yaml";
@@ -1284,7 +1284,7 @@ const updated_time = "变更时间";
1284
1284
  const message = "信息";
1285
1285
  const save = "保存";
1286
1286
  const workload = "工作负载";
1287
- const all_namespaces = "所有名字空间";
1287
+ const all_namespaces = "全部名字空间";
1288
1288
  const empty = "暂无数据";
1289
1289
  const schedule = "调度时间表";
1290
1290
  const lastScheduleTime = "上次调度时间";
@@ -8424,9 +8424,223 @@ const WidgetErrorContent$1 = (props) => {
8424
8424
  })
8425
8425
  });
8426
8426
  };
8427
- const PodSelectorTable = ({ podSelectors = {} }) => {
8427
+ function memoize$1(fn) {
8428
+ var cache = /* @__PURE__ */ Object.create(null);
8429
+ return function(arg) {
8430
+ if (cache[arg] === void 0)
8431
+ cache[arg] = fn(arg);
8432
+ return cache[arg];
8433
+ };
8434
+ }
8435
+ var reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/;
8436
+ var isPropValid = /* @__PURE__ */ memoize$1(
8437
+ function(prop) {
8438
+ return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111 && prop.charCodeAt(1) === 110 && prop.charCodeAt(2) < 91;
8439
+ }
8440
+ /* Z+1 */
8441
+ );
8442
+ var isCapital = (ch) => ch.toUpperCase() === ch;
8443
+ var filterKey = (keys) => (key2) => keys.indexOf(key2) === -1;
8444
+ var omit = (obj, keys) => {
8445
+ const res = {};
8446
+ Object.keys(obj).filter(filterKey(keys)).forEach((key2) => {
8447
+ res[key2] = obj[key2];
8448
+ });
8449
+ return res;
8450
+ };
8451
+ function filterProps(asIs, props, omitKeys) {
8452
+ const filteredProps = omit(props, omitKeys);
8453
+ if (!asIs) {
8454
+ const interopValidAttr = typeof isPropValid === "function" ? { default: isPropValid } : isPropValid;
8455
+ Object.keys(filteredProps).forEach((key2) => {
8456
+ if (!interopValidAttr.default(key2)) {
8457
+ delete filteredProps[key2];
8458
+ }
8459
+ });
8460
+ }
8461
+ return filteredProps;
8462
+ }
8463
+ var warnIfInvalid = (value2, componentName) => {
8464
+ if (process.env.NODE_ENV !== "production") {
8465
+ if (typeof value2 === "string" || typeof value2 === "number" && isFinite(value2)) {
8466
+ return;
8467
+ }
8468
+ const stringified = typeof value2 === "object" ? JSON.stringify(value2) : String(value2);
8469
+ console.warn(
8470
+ `An interpolation evaluated to '${stringified}' in the component '${componentName}', which is probably a mistake. You should explicitly cast or transform the value to a string.`
8471
+ );
8472
+ }
8473
+ };
8474
+ var idx = 0;
8475
+ function styled(tag) {
8476
+ var _a;
8477
+ let mockedClass = "";
8478
+ if (process.env.NODE_ENV === "test") {
8479
+ mockedClass += `mocked-styled-${idx++}`;
8480
+ if ((_a = tag == null ? void 0 : tag.__linaria) == null ? void 0 : _a.className) {
8481
+ mockedClass += ` ${tag.__linaria.className}`;
8482
+ }
8483
+ }
8484
+ return (options) => {
8485
+ if (process.env.NODE_ENV !== "production" && process.env.NODE_ENV !== "test") {
8486
+ if (Array.isArray(options)) {
8487
+ throw new Error(
8488
+ 'Using the "styled" tag in runtime is not supported. Make sure you have set up the Babel plugin correctly. See https://github.com/callstack/linaria#setup'
8489
+ );
8490
+ }
8491
+ }
8492
+ const render = (props, ref) => {
8493
+ const { as: component = tag, class: className = mockedClass } = props;
8494
+ const shouldKeepProps = options.propsAsIs === void 0 ? !(typeof component === "string" && component.indexOf("-") === -1 && !isCapital(component[0])) : options.propsAsIs;
8495
+ const filteredProps = filterProps(shouldKeepProps, props, [
8496
+ "as",
8497
+ "class"
8498
+ ]);
8499
+ filteredProps.ref = ref;
8500
+ filteredProps.className = options.atomic ? cx_default(options.class, filteredProps.className || className) : cx_default(filteredProps.className || className, options.class);
8501
+ const { vars } = options;
8502
+ if (vars) {
8503
+ const style = {};
8504
+ for (const name2 in vars) {
8505
+ const variable = vars[name2];
8506
+ const result = variable[0];
8507
+ const unit = variable[1] || "";
8508
+ const value2 = typeof result === "function" ? result(props) : result;
8509
+ warnIfInvalid(value2, options.name);
8510
+ style[`--${name2}`] = `${value2}${unit}`;
8511
+ }
8512
+ const ownStyle = filteredProps.style || {};
8513
+ const keys = Object.keys(ownStyle);
8514
+ if (keys.length > 0) {
8515
+ keys.forEach((key2) => {
8516
+ style[key2] = ownStyle[key2];
8517
+ });
8518
+ }
8519
+ filteredProps.style = style;
8520
+ }
8521
+ if (tag.__linaria && tag !== component) {
8522
+ filteredProps.as = component;
8523
+ return React__default.createElement(tag, filteredProps);
8524
+ }
8525
+ return React__default.createElement(component, filteredProps);
8526
+ };
8527
+ const Result = React__default.forwardRef ? React__default.forwardRef(render) : (props) => {
8528
+ const rest = omit(props, ["innerRef"]);
8529
+ return render(rest, props.innerRef);
8530
+ };
8531
+ Result.displayName = options.name;
8532
+ Result.__linaria = {
8533
+ className: options.class || mockedClass,
8534
+ extends: tag
8535
+ };
8536
+ return Result;
8537
+ };
8538
+ }
8539
+ var styled_default = process.env.NODE_ENV !== "production" ? new Proxy(styled, {
8540
+ get(o, prop) {
8541
+ return o(prop);
8542
+ }
8543
+ }) : styled;
8544
+ const TableWidgets_ny30pi = "";
8545
+ const AuxiliaryLine = /* @__PURE__ */ styled_default("div")({
8546
+ name: "AuxiliaryLine",
8547
+ class: "ax1qopv",
8548
+ propsAsIs: false
8549
+ });
8550
+ const index_dmbxj3 = "";
8551
+ const TableContainerStyle = "t1upn1sz";
8552
+ function Table(props) {
8428
8553
  const kit = useUIKit();
8554
+ const {
8555
+ t: t2
8556
+ } = useTranslation();
8557
+ const {
8558
+ loading,
8559
+ error,
8560
+ data: dataSource,
8561
+ rowKey,
8562
+ columns,
8563
+ scroll,
8564
+ currentPage,
8565
+ currentSize,
8566
+ RowMenu,
8567
+ refetch,
8568
+ onPageChange,
8569
+ onSizeChange,
8570
+ empty: empty2
8571
+ } = props;
8572
+ const auxiliaryLineRef = useRef(null);
8573
+ const wrapperRef = useRef(null);
8574
+ const pagination = useMemo(() => ({
8575
+ current: currentPage,
8576
+ pageSize: currentSize,
8577
+ onChange: onPageChange
8578
+ }), [currentPage, currentSize, onPageChange]);
8579
+ const finalColumns = useMemo(() => {
8580
+ if (RowMenu) {
8581
+ const actionColumn = {
8582
+ key: "_action_",
8583
+ display: true,
8584
+ dataIndex: [],
8585
+ title: "",
8586
+ render: (_, record) => {
8587
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(RowMenu, {
8588
+ record
8589
+ });
8590
+ }
8591
+ };
8592
+ return [...columns, actionColumn];
8593
+ }
8594
+ return columns;
8595
+ }, [columns, RowMenu]);
8596
+ if (loading) {
8597
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(kit.loading, {});
8598
+ } else if (error) {
8599
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(WidgetErrorContent$1, {
8600
+ errorText: t2("dovetail.retry_when_access_data_failed"),
8601
+ refetch,
8602
+ style: {
8603
+ padding: "15px 0"
8604
+ }
8605
+ });
8606
+ } else if (dataSource.length === 0) {
8607
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(WidgetErrorContent$1, {
8608
+ errorText: empty2 || t2("dovetail.empty"),
8609
+ style: {
8610
+ padding: "15px 0"
8611
+ }
8612
+ });
8613
+ }
8614
+ return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", {
8615
+ ref: wrapperRef,
8616
+ className: cx_default(TableContainerStyle, props.className, "table-wrapper"),
8617
+ children: [/* @__PURE__ */ jsxRuntimeExports.jsx(kit.table, {
8618
+ tableLayout: "fixed",
8619
+ columns: finalColumns,
8620
+ dataSource,
8621
+ pagination,
8622
+ error,
8623
+ loading,
8624
+ rowKey,
8625
+ wrapper: wrapperRef,
8626
+ scroll
8627
+ }), /* @__PURE__ */ jsxRuntimeExports.jsx(AuxiliaryLine, {
8628
+ ref: auxiliaryLineRef
8629
+ }), /* @__PURE__ */ jsxRuntimeExports.jsx(kit.pagination, {
8630
+ current: currentPage,
8631
+ size: currentSize,
8632
+ count: dataSource.length,
8633
+ onChange: onPageChange,
8634
+ onSizeChange
8635
+ })]
8636
+ });
8637
+ }
8638
+ const ComponentContext = createContext({});
8639
+ const PodSelectorTable = ({ podSelectors = {} }) => {
8429
8640
  const { t: t2 } = useTranslation();
8641
+ const component = useContext(ComponentContext);
8642
+ const Table$1 = component.Table || Table;
8643
+ const [currentPage, setCurrentPage] = useState(1);
8430
8644
  const datas = Object.keys(podSelectors).map((key2) => ({
8431
8645
  id: key2,
8432
8646
  key: key2,
@@ -8458,19 +8672,26 @@ const PodSelectorTable = ({ podSelectors = {} }) => {
8458
8672
  );
8459
8673
  }
8460
8674
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
8461
- kit.table,
8675
+ Table$1,
8462
8676
  {
8677
+ tableKey: "podSelector",
8463
8678
  loading: false,
8464
- dataSource: datas,
8679
+ data: datas,
8465
8680
  columns: addDefaultRenderToColumns(columns),
8466
- rowKey: "type",
8467
- empty: t2("dovetail.empty")
8681
+ rowKey: "key",
8682
+ empty: t2("dovetail.empty"),
8683
+ currentSize: 10,
8684
+ currentPage,
8685
+ onPageChange: setCurrentPage,
8686
+ showMenuColumn: false
8468
8687
  }
8469
8688
  );
8470
8689
  };
8471
8690
  const PortsTable = ({ service }) => {
8472
- const kit = useUIKit();
8473
8691
  const { t: t2 } = useTranslation();
8692
+ const component = useContext(ComponentContext);
8693
+ const Table$1 = component.Table || Table;
8694
+ const [currentPage, setCurrentPage] = useState(1);
8474
8695
  const columns = [
8475
8696
  {
8476
8697
  key: "name",
@@ -8516,13 +8737,18 @@ const PortsTable = ({ service }) => {
8516
8737
  return /* @__PURE__ */ jsxRuntimeExports.jsx(WidgetErrorContent$1, { errorText: t2("dovetail.no_resource", { kind: t2("dovetail.port") }), style: { padding: "15px 0" } });
8517
8738
  }
8518
8739
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
8519
- kit.table,
8740
+ Table$1,
8520
8741
  {
8742
+ tableKey: "ports",
8521
8743
  loading: false,
8522
- dataSource: ports,
8744
+ data: ports,
8523
8745
  columns: addDefaultRenderToColumns(columns),
8524
- rowKey: "type",
8525
- empty: t2("dovetail.empty")
8746
+ rowKey: "name",
8747
+ empty: t2("dovetail.empty"),
8748
+ currentSize: 10,
8749
+ currentPage,
8750
+ onPageChange: setCurrentPage,
8751
+ showMenuColumn: false
8526
8752
  }
8527
8753
  );
8528
8754
  };
@@ -9811,8 +10037,10 @@ const Time = (props) => {
9811
10037
  });
9812
10038
  };
9813
10039
  const ConditionsTable = ({ conditions = [] }) => {
9814
- const kit = useUIKit();
10040
+ const [currentPage, setCurrentPage] = useState(1);
9815
10041
  const { t: t2 } = useTranslation();
10042
+ const component = useContext(ComponentContext);
10043
+ const Table$1 = component.Table || Table;
9816
10044
  const conditionsWithId = addId(conditions, "type");
9817
10045
  const columns = [
9818
10046
  {
@@ -9833,7 +10061,7 @@ const ConditionsTable = ({ conditions = [] }) => {
9833
10061
  "False": "red",
9834
10062
  "Unknown": "warning"
9835
10063
  };
9836
- return /* @__PURE__ */ jsxRuntimeExports.jsx(kit.statusCapsule, { color: colorMap[value2 || "Unknown"], className: cx_default(StateTagStyle, "no-background"), children: t2(`dovetail.${value2.toLowerCase()}`) });
10064
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(StatusCapsule, { color: colorMap[value2 || "Unknown"], className: cx_default(StateTagStyle, "no-background"), children: t2(`dovetail.${value2.toLowerCase()}`) });
9837
10065
  },
9838
10066
  sortable: true
9839
10067
  },
@@ -9867,227 +10095,21 @@ const ConditionsTable = ({ conditions = [] }) => {
9867
10095
  return /* @__PURE__ */ jsxRuntimeExports.jsx(WidgetErrorContent$1, { errorText: t2("dovetail.no_resource", { kind: t2("dovetail.condition") }), style: { padding: "15px 0" } });
9868
10096
  }
9869
10097
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
9870
- kit.table,
10098
+ Table$1,
9871
10099
  {
10100
+ tableKey: "condition",
9872
10101
  loading: false,
9873
- dataSource: conditionsWithId,
10102
+ data: conditionsWithId,
9874
10103
  columns: addDefaultRenderToColumns(columns),
9875
10104
  rowKey: "type",
9876
- empty: t2("dovetail.empty")
10105
+ empty: t2("dovetail.empty"),
10106
+ currentSize: 10,
10107
+ currentPage,
10108
+ onPageChange: setCurrentPage,
10109
+ showMenuColumn: false
9877
10110
  }
9878
10111
  );
9879
10112
  };
9880
- function memoize$1(fn) {
9881
- var cache = /* @__PURE__ */ Object.create(null);
9882
- return function(arg) {
9883
- if (cache[arg] === void 0)
9884
- cache[arg] = fn(arg);
9885
- return cache[arg];
9886
- };
9887
- }
9888
- var reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/;
9889
- var isPropValid = /* @__PURE__ */ memoize$1(
9890
- function(prop) {
9891
- return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111 && prop.charCodeAt(1) === 110 && prop.charCodeAt(2) < 91;
9892
- }
9893
- /* Z+1 */
9894
- );
9895
- var isCapital = (ch) => ch.toUpperCase() === ch;
9896
- var filterKey = (keys) => (key2) => keys.indexOf(key2) === -1;
9897
- var omit = (obj, keys) => {
9898
- const res = {};
9899
- Object.keys(obj).filter(filterKey(keys)).forEach((key2) => {
9900
- res[key2] = obj[key2];
9901
- });
9902
- return res;
9903
- };
9904
- function filterProps(asIs, props, omitKeys) {
9905
- const filteredProps = omit(props, omitKeys);
9906
- if (!asIs) {
9907
- const interopValidAttr = typeof isPropValid === "function" ? { default: isPropValid } : isPropValid;
9908
- Object.keys(filteredProps).forEach((key2) => {
9909
- if (!interopValidAttr.default(key2)) {
9910
- delete filteredProps[key2];
9911
- }
9912
- });
9913
- }
9914
- return filteredProps;
9915
- }
9916
- var warnIfInvalid = (value2, componentName) => {
9917
- if (process.env.NODE_ENV !== "production") {
9918
- if (typeof value2 === "string" || typeof value2 === "number" && isFinite(value2)) {
9919
- return;
9920
- }
9921
- const stringified = typeof value2 === "object" ? JSON.stringify(value2) : String(value2);
9922
- console.warn(
9923
- `An interpolation evaluated to '${stringified}' in the component '${componentName}', which is probably a mistake. You should explicitly cast or transform the value to a string.`
9924
- );
9925
- }
9926
- };
9927
- var idx = 0;
9928
- function styled(tag) {
9929
- var _a;
9930
- let mockedClass = "";
9931
- if (process.env.NODE_ENV === "test") {
9932
- mockedClass += `mocked-styled-${idx++}`;
9933
- if ((_a = tag == null ? void 0 : tag.__linaria) == null ? void 0 : _a.className) {
9934
- mockedClass += ` ${tag.__linaria.className}`;
9935
- }
9936
- }
9937
- return (options) => {
9938
- if (process.env.NODE_ENV !== "production" && process.env.NODE_ENV !== "test") {
9939
- if (Array.isArray(options)) {
9940
- throw new Error(
9941
- 'Using the "styled" tag in runtime is not supported. Make sure you have set up the Babel plugin correctly. See https://github.com/callstack/linaria#setup'
9942
- );
9943
- }
9944
- }
9945
- const render = (props, ref) => {
9946
- const { as: component = tag, class: className = mockedClass } = props;
9947
- const shouldKeepProps = options.propsAsIs === void 0 ? !(typeof component === "string" && component.indexOf("-") === -1 && !isCapital(component[0])) : options.propsAsIs;
9948
- const filteredProps = filterProps(shouldKeepProps, props, [
9949
- "as",
9950
- "class"
9951
- ]);
9952
- filteredProps.ref = ref;
9953
- filteredProps.className = options.atomic ? cx_default(options.class, filteredProps.className || className) : cx_default(filteredProps.className || className, options.class);
9954
- const { vars } = options;
9955
- if (vars) {
9956
- const style = {};
9957
- for (const name2 in vars) {
9958
- const variable = vars[name2];
9959
- const result = variable[0];
9960
- const unit = variable[1] || "";
9961
- const value2 = typeof result === "function" ? result(props) : result;
9962
- warnIfInvalid(value2, options.name);
9963
- style[`--${name2}`] = `${value2}${unit}`;
9964
- }
9965
- const ownStyle = filteredProps.style || {};
9966
- const keys = Object.keys(ownStyle);
9967
- if (keys.length > 0) {
9968
- keys.forEach((key2) => {
9969
- style[key2] = ownStyle[key2];
9970
- });
9971
- }
9972
- filteredProps.style = style;
9973
- }
9974
- if (tag.__linaria && tag !== component) {
9975
- filteredProps.as = component;
9976
- return React__default.createElement(tag, filteredProps);
9977
- }
9978
- return React__default.createElement(component, filteredProps);
9979
- };
9980
- const Result = React__default.forwardRef ? React__default.forwardRef(render) : (props) => {
9981
- const rest = omit(props, ["innerRef"]);
9982
- return render(rest, props.innerRef);
9983
- };
9984
- Result.displayName = options.name;
9985
- Result.__linaria = {
9986
- className: options.class || mockedClass,
9987
- extends: tag
9988
- };
9989
- return Result;
9990
- };
9991
- }
9992
- var styled_default = process.env.NODE_ENV !== "production" ? new Proxy(styled, {
9993
- get(o, prop) {
9994
- return o(prop);
9995
- }
9996
- }) : styled;
9997
- const TableWidgets_ny30pi = "";
9998
- const AuxiliaryLine = /* @__PURE__ */ styled_default("div")({
9999
- name: "AuxiliaryLine",
10000
- class: "ax1qopv",
10001
- propsAsIs: false
10002
- });
10003
- const index_dmbxj3 = "";
10004
- const TableContainerStyle = "t1upn1sz";
10005
- function Table(props) {
10006
- const kit = useUIKit();
10007
- const {
10008
- t: t2
10009
- } = useTranslation();
10010
- const {
10011
- loading,
10012
- error,
10013
- data: dataSource,
10014
- rowKey,
10015
- columns,
10016
- scroll,
10017
- currentPage,
10018
- currentSize,
10019
- RowMenu,
10020
- refetch,
10021
- onPageChange,
10022
- onSizeChange,
10023
- empty: empty2
10024
- } = props;
10025
- const auxiliaryLineRef = useRef(null);
10026
- const wrapperRef = useRef(null);
10027
- const pagination = useMemo(() => ({
10028
- current: currentPage,
10029
- pageSize: currentSize,
10030
- onChange: onPageChange
10031
- }), [currentPage, currentSize, onPageChange]);
10032
- const finalColumns = useMemo(() => {
10033
- if (RowMenu) {
10034
- const actionColumn = {
10035
- key: "_action_",
10036
- display: true,
10037
- dataIndex: [],
10038
- title: "",
10039
- render: (_, record) => {
10040
- return /* @__PURE__ */ jsxRuntimeExports.jsx(RowMenu, {
10041
- record
10042
- });
10043
- }
10044
- };
10045
- return [...columns, actionColumn];
10046
- }
10047
- return columns;
10048
- }, [columns, RowMenu]);
10049
- if (loading) {
10050
- return /* @__PURE__ */ jsxRuntimeExports.jsx(kit.loading, {});
10051
- } else if (error) {
10052
- return /* @__PURE__ */ jsxRuntimeExports.jsx(WidgetErrorContent$1, {
10053
- errorText: t2("dovetail.retry_when_access_data_failed"),
10054
- refetch,
10055
- style: {
10056
- padding: "15px 0"
10057
- }
10058
- });
10059
- } else if (dataSource.length === 0) {
10060
- return /* @__PURE__ */ jsxRuntimeExports.jsx(WidgetErrorContent$1, {
10061
- errorText: empty2 || t2("dovetail.empty"),
10062
- style: {
10063
- padding: "15px 0"
10064
- }
10065
- });
10066
- }
10067
- return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", {
10068
- ref: wrapperRef,
10069
- className: cx_default(TableContainerStyle, props.className, "table-wrapper"),
10070
- children: [/* @__PURE__ */ jsxRuntimeExports.jsx(kit.table, {
10071
- tableLayout: "fixed",
10072
- columns: finalColumns,
10073
- dataSource,
10074
- pagination,
10075
- error,
10076
- loading,
10077
- rowKey,
10078
- wrapper: wrapperRef,
10079
- scroll
10080
- }), /* @__PURE__ */ jsxRuntimeExports.jsx(AuxiliaryLine, {
10081
- ref: auxiliaryLineRef
10082
- }), /* @__PURE__ */ jsxRuntimeExports.jsx(kit.pagination, {
10083
- current: currentPage,
10084
- size: currentSize,
10085
- count: dataSource.length,
10086
- onChange: onPageChange,
10087
- onSizeChange
10088
- })]
10089
- });
10090
- }
10091
10113
  function useEdit() {
10092
10114
  const { resource } = useParsed();
10093
10115
  const go = useGo();
@@ -10281,6 +10303,8 @@ const CronjobJobsTable = ({
10281
10303
  const kit = useUIKit();
10282
10304
  const [selectedKeys] = useState([]);
10283
10305
  const [currentPage, setCurrentPage] = useState(1);
10306
+ const component = useContext(ComponentContext);
10307
+ const Table$1 = component.Table || Table;
10284
10308
  const {
10285
10309
  data: data2
10286
10310
  } = useList({
@@ -10302,7 +10326,7 @@ const CronjobJobsTable = ({
10302
10326
  children: [hideToolBar ? null : /* @__PURE__ */ jsxRuntimeExports.jsx(TableToolBar, {
10303
10327
  selectedKeys,
10304
10328
  hideCreate: true
10305
- }), /* @__PURE__ */ jsxRuntimeExports.jsx(Table, {
10329
+ }), /* @__PURE__ */ jsxRuntimeExports.jsx(Table$1, {
10306
10330
  tableKey: "cronjobs",
10307
10331
  loading: !dataSource,
10308
10332
  data: dataSource || [],
@@ -10312,7 +10336,8 @@ const CronjobJobsTable = ({
10312
10336
  currentPage,
10313
10337
  onPageChange: (p) => setCurrentPage(p),
10314
10338
  currentSize: 10,
10315
- refetch: () => null
10339
+ refetch: () => null,
10340
+ showMenuColumn: false
10316
10341
  })]
10317
10342
  });
10318
10343
  };
@@ -10401,6 +10426,8 @@ const EventsTable = ({}) => {
10401
10426
  ],
10402
10427
  [i18n2]
10403
10428
  );
10429
+ const component = useContext(ComponentContext);
10430
+ const Table$1 = component.Table || Table;
10404
10431
  const dataSource = useMemo(() => {
10405
10432
  return data2 == null ? void 0 : data2.data.filter((d) => {
10406
10433
  const objectId = `${d.regarding.namespace}/${d.regarding.name}`;
@@ -10417,7 +10444,7 @@ const EventsTable = ({}) => {
10417
10444
  );
10418
10445
  }
10419
10446
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
10420
- Table,
10447
+ Table$1,
10421
10448
  {
10422
10449
  tableKey: "events",
10423
10450
  loading: isLoading,
@@ -10428,7 +10455,8 @@ const EventsTable = ({}) => {
10428
10455
  currentPage,
10429
10456
  onPageChange: (p) => setCurrentPage(p),
10430
10457
  currentSize: 10,
10431
- refetch: () => null
10458
+ refetch: () => null,
10459
+ showMenuColumn: false
10432
10460
  }
10433
10461
  );
10434
10462
  };
@@ -10465,11 +10493,13 @@ const ResourceLink = (props) => {
10465
10493
  return /* @__PURE__ */ jsxRuntimeExports.jsx(kit.Link, { onClick, children: resourceId });
10466
10494
  };
10467
10495
  const IngressRulesTable = ({ ingress }) => {
10468
- const kit = useUIKit();
10469
10496
  const { t: t2 } = useTranslation();
10470
10497
  const rows = useMemo(() => {
10471
10498
  return addId(ingress.flattenedRules || [], "fullPath");
10472
10499
  }, [ingress.flattenedRules]);
10500
+ const component = useContext(ComponentContext);
10501
+ const Table$1 = component.Table || Table;
10502
+ const [currentPage, setCurrentPage] = useState(1);
10473
10503
  const columns = [
10474
10504
  {
10475
10505
  key: "pathType",
@@ -10533,13 +10563,18 @@ const IngressRulesTable = ({ ingress }) => {
10533
10563
  return /* @__PURE__ */ jsxRuntimeExports.jsx(WidgetErrorContent$1, { errorText: t2("dovetail.no_resource", { kind: t2("dovetail.rule") }), style: { padding: "15px 0" } });
10534
10564
  }
10535
10565
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
10536
- kit.table,
10566
+ Table$1,
10537
10567
  {
10568
+ tableKey: "ingressRules",
10538
10569
  loading: false,
10539
- dataSource: rows,
10570
+ data: rows,
10540
10571
  columns: addDefaultRenderToColumns(columns),
10541
- rowKey: "type",
10542
- empty: t2("dovetail.empty")
10572
+ rowKey: "pathType",
10573
+ empty: t2("dovetail.empty"),
10574
+ currentSize: 10,
10575
+ currentPage,
10576
+ onPageChange: setCurrentPage,
10577
+ showMenuColumn: false
10543
10578
  }
10544
10579
  );
10545
10580
  };
@@ -10603,7 +10638,7 @@ function KeyValueAnnotation(props) {
10603
10638
  children: Object.keys(data2).length
10604
10639
  }), /* @__PURE__ */ jsxRuntimeExports.jsx(Button, {
10605
10640
  type: "link",
10606
- className: ExpandButtonStyle,
10641
+ className: cx_default(ExpandButtonStyle, Typo.Label.l4_regular_title),
10607
10642
  onClick: () => {
10608
10643
  setIsExpand(!isExpand);
10609
10644
  },
@@ -10718,8 +10753,7 @@ function Tabs(props) {
10718
10753
  return /* @__PURE__ */ jsxRuntimeExports.jsx(kit.tabsTabPane, { tab: tab.title, children: tab.children }, tab.title);
10719
10754
  }) });
10720
10755
  }
10721
- const ComponentContext = createContext({});
10722
- const ShowContent_tusz9j = "";
10756
+ const ShowContent_eym19u = "";
10723
10757
  const ShowContentWrapperStyle = "s9agep2";
10724
10758
  const BackButton = "bo89gfi";
10725
10759
  const ToolBarWrapper = "t1ohe42f";
@@ -10802,7 +10836,7 @@ const ShowContent = (props) => {
10802
10836
  children: field.render ? field.render(value2, record, field) : /* @__PURE__ */ jsxRuntimeExports.jsxs("div", {
10803
10837
  className: FieldWrapperStyle,
10804
10838
  children: [field.title && /* @__PURE__ */ jsxRuntimeExports.jsx("span", {
10805
- className: Typo.Label.l3_regular,
10839
+ className: Typo.Label.l4_regular_title,
10806
10840
  style: {
10807
10841
  width: field.labelWidth || "165px",
10808
10842
  marginRight: 8,
@@ -10815,6 +10849,7 @@ const ShowContent = (props) => {
10815
10849
  minWidth: 0
10816
10850
  },
10817
10851
  children: /* @__PURE__ */ jsxRuntimeExports.jsx(ValueDisplay, {
10852
+ className: Typo.Label.l4_regular_title,
10818
10853
  value: content,
10819
10854
  useOverflow: false
10820
10855
  })
@@ -10868,6 +10903,7 @@ const ShowContent = (props) => {
10868
10903
  marginRight: 8
10869
10904
  },
10870
10905
  onClick: openForm,
10906
+ prefixIcon: /* @__PURE__ */ jsxRuntimeExports.jsx(EditPen16GradientBlueIcon, {}),
10871
10907
  children: t2("dovetail.edit_yaml")
10872
10908
  }), /* @__PURE__ */ jsxRuntimeExports.jsx(Dropdown, {
10873
10909
  record,
@@ -10937,6 +10973,8 @@ const WorkloadPodsTable = ({
10937
10973
  const kit = useUIKit();
10938
10974
  const [selectedKeys, setSelectedKeys] = useState([]);
10939
10975
  const [currentPage, setCurrentPage] = useState(1);
10976
+ const component = useContext(ComponentContext);
10977
+ const Table$1 = component.Table || Table;
10940
10978
  const {
10941
10979
  data: data2
10942
10980
  } = useList({
@@ -10977,7 +11015,7 @@ const WorkloadPodsTable = ({
10977
11015
  children: [hideToolbar ? null : /* @__PURE__ */ jsxRuntimeExports.jsx(TableToolBar, {
10978
11016
  selectedKeys,
10979
11017
  hideCreate: true
10980
- }), /* @__PURE__ */ jsxRuntimeExports.jsx(Table, {
11018
+ }), /* @__PURE__ */ jsxRuntimeExports.jsx(Table$1, {
10981
11019
  tableKey: "pods",
10982
11020
  loading: !dataSource,
10983
11021
  data: dataSource || [],
@@ -10988,7 +11026,8 @@ const WorkloadPodsTable = ({
10988
11026
  currentPage,
10989
11027
  onPageChange: (p) => setCurrentPage(p),
10990
11028
  currentSize: 10,
10991
- refetch: () => null
11029
+ refetch: () => null,
11030
+ showMenuColumn: false
10992
11031
  })]
10993
11032
  });
10994
11033
  };
@@ -11162,7 +11201,7 @@ function EditField(props) {
11162
11201
  children: i18n2.t("dovetail.edit")
11163
11202
  });
11164
11203
  }
11165
- const index_1qy3pu6 = "";
11204
+ const index_psn0hb = "";
11166
11205
  const WorkloadReplicasWrapperStyle = "w8ychfk";
11167
11206
  const DonutChartWrapperStyle = "d1o004do";
11168
11207
  const DonutChartStyle = "dfo80qq";
@@ -11262,10 +11301,10 @@ function WorkloadReplicas({
11262
11301
  color: "rgba(33, 190, 106, 1)"
11263
11302
  }];
11264
11303
  const remain = replicas - readyReplicas;
11265
- if (remain > 0) {
11304
+ if (remain > 0 || replicas === 0) {
11266
11305
  data2.push({
11267
11306
  name: "remain",
11268
- value: remain,
11307
+ value: replicas === 0 ? 1 : remain,
11269
11308
  color: "rgba(162, 240, 213, 1)"
11270
11309
  });
11271
11310
  }
@@ -11297,20 +11336,20 @@ function WorkloadReplicas({
11297
11336
  })
11298
11337
  }), /* @__PURE__ */ jsxRuntimeExports.jsxs("div", {
11299
11338
  className: ContentWrapperStyle,
11300
- children: [/* @__PURE__ */ jsxRuntimeExports.jsxs("div", {
11301
- children: [/* @__PURE__ */ jsxRuntimeExports.jsx("span", {
11339
+ children: [/* @__PURE__ */ jsxRuntimeExports.jsxs("tr", {
11340
+ children: [/* @__PURE__ */ jsxRuntimeExports.jsx("td", {
11302
11341
  className: LabelStyle,
11303
11342
  children: t2("dovetail.pod_ready_num")
11304
- }), /* @__PURE__ */ jsxRuntimeExports.jsx("span", {
11343
+ }), /* @__PURE__ */ jsxRuntimeExports.jsx("td", {
11305
11344
  children: readyReplicas
11306
11345
  })]
11307
- }), /* @__PURE__ */ jsxRuntimeExports.jsxs("div", {
11308
- children: [/* @__PURE__ */ jsxRuntimeExports.jsx("span", {
11346
+ }), /* @__PURE__ */ jsxRuntimeExports.jsxs("tr", {
11347
+ children: [/* @__PURE__ */ jsxRuntimeExports.jsx("td", {
11309
11348
  className: LabelStyle,
11310
11349
  children: t2("dovetail.pod_replicas_num")
11311
- }), /* @__PURE__ */ jsxRuntimeExports.jsx("span", {
11350
+ }), /* @__PURE__ */ jsxRuntimeExports.jsx("td", {
11312
11351
  children: replicas
11313
- }), /* @__PURE__ */ jsxRuntimeExports.jsx("span", {
11352
+ }), /* @__PURE__ */ jsxRuntimeExports.jsx("td", {
11314
11353
  children: editable && canScale && /* @__PURE__ */ jsxRuntimeExports.jsx(EditField, {
11315
11354
  modalProps: {
11316
11355
  formRef,
@@ -17545,8 +17584,8 @@ const MonacoYamlEditor$2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.
17545
17584
  __proto__: null,
17546
17585
  default: MonacoYamlEditor$1
17547
17586
  }, Symbol.toStringTag, { value: "Module" }));
17548
- const NetworkPolicyRulesTable_1ig139p = "";
17549
- const EditorStyle$1 = "e151npt0";
17587
+ const NetworkPolicyRulesViewer_13asgaq = "";
17588
+ const EditorStyle$1 = "e1cjl2b8";
17550
17589
  const NetworkPolicyRulesViewer = ({
17551
17590
  ingressOrEgress,
17552
17591
  kind
@@ -17576,8 +17615,10 @@ const PodContainersTable = ({
17576
17615
  containerStatuses,
17577
17616
  initContainerStatuses
17578
17617
  }) => {
17579
- const kit = useUIKit();
17580
17618
  const { i18n: i18n2 } = useTranslation();
17619
+ const component = useContext(ComponentContext);
17620
+ const Table$1 = component.Table || Table;
17621
+ const [currentPage, setCurrentPage] = useState(1);
17581
17622
  const columns = useMemo(
17582
17623
  () => [
17583
17624
  {
@@ -17643,13 +17684,18 @@ const PodContainersTable = ({
17643
17684
  return /* @__PURE__ */ jsxRuntimeExports.jsx(WidgetErrorContent, { errorText: i18n2.t("dovetail.no_resource", { kind: i18n2.t("dovetail.container") }), style: { padding: "15px 0" } });
17644
17685
  }
17645
17686
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
17646
- kit.table,
17687
+ Table$1,
17647
17688
  {
17689
+ tableKey: "podContainers",
17648
17690
  loading: false,
17649
- dataSource,
17691
+ data: dataSource,
17650
17692
  columns: addDefaultRenderToColumns(columns),
17651
17693
  rowKey: "containerID",
17652
- error: false
17694
+ error: false,
17695
+ currentSize: 10,
17696
+ currentPage,
17697
+ onPageChange: setCurrentPage,
17698
+ showMenuColumn: false
17653
17699
  }
17654
17700
  );
17655
17701
  };
@@ -18169,7 +18215,7 @@ const NamespacesFilter = ({
18169
18215
  })]
18170
18216
  });
18171
18217
  };
18172
- const index_1srrgg6 = "";
18218
+ const index_hp158y = "";
18173
18219
  const ListPageStyle = "laykzsq";
18174
18220
  const ListContentStyle = "l1ng0psc";
18175
18221
  const TableStyle = "tj6zpn4";
@@ -18205,15 +18251,23 @@ function ListPage(props) {
18205
18251
  className: ListContentStyle,
18206
18252
  children: [/* @__PURE__ */ jsxRuntimeExports.jsx(NamespacesFilter, {
18207
18253
  className: NamespaceFilterStyle
18208
- }), /* @__PURE__ */ jsxRuntimeExports.jsx(Table$1, {
18209
- ...tableProps,
18210
- empty: tableProps.empty || t2("dovetail.no_resource", {
18211
- kind: ` ${config.kind}`
18212
- }),
18213
- className: cx_default(tableProps.className, TableStyle),
18214
- scroll: {
18215
- y: "calc(100% - 48px)"
18216
- }
18254
+ }), /* @__PURE__ */ jsxRuntimeExports.jsx("div", {
18255
+ className: TableStyle,
18256
+ children: !(tableProps.data.length || tableProps.loading) ? /* @__PURE__ */ jsxRuntimeExports.jsx(WidgetErrorContent, {
18257
+ errorText: tableProps.empty || t2("dovetail.no_resource", {
18258
+ kind: ` ${config.kind}`
18259
+ }),
18260
+ hiddenRetry: true
18261
+ }) : /* @__PURE__ */ jsxRuntimeExports.jsx(Table$1, {
18262
+ ...tableProps,
18263
+ empty: tableProps.empty || t2("dovetail.no_resource", {
18264
+ kind: ` ${config.kind}`
18265
+ }),
18266
+ className: cx_default(tableProps.className),
18267
+ scroll: {
18268
+ y: "calc(100% - 48px)"
18269
+ }
18270
+ })
18217
18271
  })]
18218
18272
  })]
18219
18273
  });
@@ -22089,7 +22143,7 @@ const Separator = () => {
22089
22143
  });
22090
22144
  };
22091
22145
  const MonacoYamlEditor = React__default.lazy(() => Promise.resolve().then(() => MonacoYamlEditor$2));
22092
- const MonacoYamlDiffEditor = React__default.lazy(() => import("./MonacoYamlDiffEditor-799d6dfe.js"));
22146
+ const MonacoYamlDiffEditor = React__default.lazy(() => import("./MonacoYamlDiffEditor-126d544d.js"));
22093
22147
  const YamlEditorComponent = forwardRef(
22094
22148
  function YamlEditorComponent2(props, ref) {
22095
22149
  const {
@@ -23441,6 +23495,7 @@ const CompletionsCountColumnRenderer = (i18n2) => {
23441
23495
  }),
23442
23496
  sortable: true,
23443
23497
  width: 120,
23498
+ align: "right",
23444
23499
  sorter: CommonSorter(dataIndex)
23445
23500
  };
23446
23501
  };
@@ -23658,6 +23713,7 @@ const PodContainersNumColumnRenderer = (i18n2) => {
23658
23713
  }),
23659
23714
  width: 120,
23660
23715
  sortable: true,
23716
+ align: "right",
23661
23717
  sorter: CommonSorter(["readyDisplay"])
23662
23718
  };
23663
23719
  };