@arpproject/recrate 0.1.24 → 0.1.26
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/recrate.es.js
CHANGED
|
@@ -7927,9 +7927,9 @@ var CheckCircleFilled = function CheckCircleFilled2(props, ref) {
|
|
|
7927
7927
|
icon: CheckCircleFilled$1
|
|
7928
7928
|
}));
|
|
7929
7929
|
};
|
|
7930
|
-
var RefIcon$
|
|
7930
|
+
var RefIcon$z = /* @__PURE__ */ React.forwardRef(CheckCircleFilled);
|
|
7931
7931
|
if (process.env.NODE_ENV !== "production") {
|
|
7932
|
-
RefIcon$
|
|
7932
|
+
RefIcon$z.displayName = "CheckCircleFilled";
|
|
7933
7933
|
}
|
|
7934
7934
|
var CloseCircleFilled$1 = { "icon": { "tag": "svg", "attrs": { "fill-rule": "evenodd", "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z" } }] }, "name": "close-circle", "theme": "filled" };
|
|
7935
7935
|
var CloseCircleFilled = function CloseCircleFilled2(props, ref) {
|
|
@@ -7938,9 +7938,9 @@ var CloseCircleFilled = function CloseCircleFilled2(props, ref) {
|
|
|
7938
7938
|
icon: CloseCircleFilled$1
|
|
7939
7939
|
}));
|
|
7940
7940
|
};
|
|
7941
|
-
var RefIcon$
|
|
7941
|
+
var RefIcon$y = /* @__PURE__ */ React.forwardRef(CloseCircleFilled);
|
|
7942
7942
|
if (process.env.NODE_ENV !== "production") {
|
|
7943
|
-
RefIcon$
|
|
7943
|
+
RefIcon$y.displayName = "CloseCircleFilled";
|
|
7944
7944
|
}
|
|
7945
7945
|
var CloseOutlined$1 = { "icon": { "tag": "svg", "attrs": { "fill-rule": "evenodd", "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z" } }] }, "name": "close", "theme": "outlined" };
|
|
7946
7946
|
var CloseOutlined = function CloseOutlined2(props, ref) {
|
|
@@ -7949,9 +7949,9 @@ var CloseOutlined = function CloseOutlined2(props, ref) {
|
|
|
7949
7949
|
icon: CloseOutlined$1
|
|
7950
7950
|
}));
|
|
7951
7951
|
};
|
|
7952
|
-
var RefIcon$
|
|
7952
|
+
var RefIcon$x = /* @__PURE__ */ React.forwardRef(CloseOutlined);
|
|
7953
7953
|
if (process.env.NODE_ENV !== "production") {
|
|
7954
|
-
RefIcon$
|
|
7954
|
+
RefIcon$x.displayName = "CloseOutlined";
|
|
7955
7955
|
}
|
|
7956
7956
|
var ExclamationCircleFilled$1 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z" } }] }, "name": "exclamation-circle", "theme": "filled" };
|
|
7957
7957
|
var ExclamationCircleFilled = function ExclamationCircleFilled2(props, ref) {
|
|
@@ -7960,9 +7960,9 @@ var ExclamationCircleFilled = function ExclamationCircleFilled2(props, ref) {
|
|
|
7960
7960
|
icon: ExclamationCircleFilled$1
|
|
7961
7961
|
}));
|
|
7962
7962
|
};
|
|
7963
|
-
var RefIcon$
|
|
7963
|
+
var RefIcon$w = /* @__PURE__ */ React.forwardRef(ExclamationCircleFilled);
|
|
7964
7964
|
if (process.env.NODE_ENV !== "production") {
|
|
7965
|
-
RefIcon$
|
|
7965
|
+
RefIcon$w.displayName = "ExclamationCircleFilled";
|
|
7966
7966
|
}
|
|
7967
7967
|
var InfoCircleFilled$1 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z" } }] }, "name": "info-circle", "theme": "filled" };
|
|
7968
7968
|
var InfoCircleFilled = function InfoCircleFilled2(props, ref) {
|
|
@@ -7971,9 +7971,9 @@ var InfoCircleFilled = function InfoCircleFilled2(props, ref) {
|
|
|
7971
7971
|
icon: InfoCircleFilled$1
|
|
7972
7972
|
}));
|
|
7973
7973
|
};
|
|
7974
|
-
var RefIcon$
|
|
7974
|
+
var RefIcon$v = /* @__PURE__ */ React.forwardRef(InfoCircleFilled);
|
|
7975
7975
|
if (process.env.NODE_ENV !== "production") {
|
|
7976
|
-
RefIcon$
|
|
7976
|
+
RefIcon$v.displayName = "InfoCircleFilled";
|
|
7977
7977
|
}
|
|
7978
7978
|
var attributes = "accept acceptCharset accessKey action allowFullScreen allowTransparency\n alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge\n charSet checked classID className colSpan cols content contentEditable contextMenu\n controls coords crossOrigin data dateTime default defer dir disabled download draggable\n encType form formAction formEncType formMethod formNoValidate formTarget frameBorder\n headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity\n is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media\n mediaGroup method min minLength multiple muted name noValidate nonce open\n optimum pattern placeholder poster preload radioGroup readOnly rel required\n reversed role rowSpan rows sandbox scope scoped scrolling seamless selected\n shape size sizes span spellCheck src srcDoc srcLang srcSet start step style\n summary tabIndex target title type useMap value width wmode wrap";
|
|
7979
7979
|
var eventsName = "onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown\n onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick\n onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown\n onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel\n onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough\n onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata\n onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError";
|
|
@@ -8714,9 +8714,9 @@ var LoadingOutlined = function LoadingOutlined2(props, ref) {
|
|
|
8714
8714
|
icon: LoadingOutlined$1
|
|
8715
8715
|
}));
|
|
8716
8716
|
};
|
|
8717
|
-
var RefIcon$
|
|
8717
|
+
var RefIcon$u = /* @__PURE__ */ React.forwardRef(LoadingOutlined);
|
|
8718
8718
|
if (process.env.NODE_ENV !== "production") {
|
|
8719
|
-
RefIcon$
|
|
8719
|
+
RefIcon$u.displayName = "LoadingOutlined";
|
|
8720
8720
|
}
|
|
8721
8721
|
function mergeProps$1(...items) {
|
|
8722
8722
|
const ret = {};
|
|
@@ -8775,7 +8775,7 @@ const useClosable = (propCloseCollection, contextCloseCollection, fallbackCloseC
|
|
|
8775
8775
|
const [contextLocale] = useLocale$1("global", localeValues.global);
|
|
8776
8776
|
const closeBtnIsDisabled = typeof propCloseConfig !== "boolean" ? !!(propCloseConfig === null || propCloseConfig === void 0 ? void 0 : propCloseConfig.disabled) : false;
|
|
8777
8777
|
const mergedFallbackCloseCollection = React__default.useMemo(() => Object.assign({
|
|
8778
|
-
closeIcon: /* @__PURE__ */ React__default.createElement(RefIcon$
|
|
8778
|
+
closeIcon: /* @__PURE__ */ React__default.createElement(RefIcon$x, null)
|
|
8779
8779
|
}, fallbackCloseCollection), [fallbackCloseCollection]);
|
|
8780
8780
|
const mergedClosableConfig = React__default.useMemo(() => {
|
|
8781
8781
|
if (propCloseConfig === false) {
|
|
@@ -9100,11 +9100,11 @@ const useStyle$u = genStyleHooks("Message", (token2) => {
|
|
|
9100
9100
|
return t2;
|
|
9101
9101
|
});
|
|
9102
9102
|
const TypeIcon = {
|
|
9103
|
-
info: /* @__PURE__ */ React.createElement(RefIcon$
|
|
9104
|
-
success: /* @__PURE__ */ React.createElement(RefIcon$
|
|
9105
|
-
error: /* @__PURE__ */ React.createElement(RefIcon$
|
|
9106
|
-
warning: /* @__PURE__ */ React.createElement(RefIcon$
|
|
9107
|
-
loading: /* @__PURE__ */ React.createElement(RefIcon$
|
|
9103
|
+
info: /* @__PURE__ */ React.createElement(RefIcon$v, null),
|
|
9104
|
+
success: /* @__PURE__ */ React.createElement(RefIcon$z, null),
|
|
9105
|
+
error: /* @__PURE__ */ React.createElement(RefIcon$y, null),
|
|
9106
|
+
warning: /* @__PURE__ */ React.createElement(RefIcon$w, null),
|
|
9107
|
+
loading: /* @__PURE__ */ React.createElement(RefIcon$u, null)
|
|
9108
9108
|
};
|
|
9109
9109
|
const PureContent$1 = ({
|
|
9110
9110
|
prefixCls,
|
|
@@ -9191,7 +9191,7 @@ const Holder$1 = /* @__PURE__ */ React.forwardRef((props, ref) => {
|
|
|
9191
9191
|
const getNotificationMotion = () => getMotion$3(prefixCls, transitionName);
|
|
9192
9192
|
const mergedCloseIcon = /* @__PURE__ */ React.createElement("span", {
|
|
9193
9193
|
className: `${prefixCls}-close-x`
|
|
9194
|
-
}, /* @__PURE__ */ React.createElement(RefIcon$
|
|
9194
|
+
}, /* @__PURE__ */ React.createElement(RefIcon$x, {
|
|
9195
9195
|
className: `${prefixCls}-close-icon`
|
|
9196
9196
|
}));
|
|
9197
9197
|
const [api2, holder] = useNotification$1({
|
|
@@ -10231,7 +10231,7 @@ const InnerLoadingIcon = /* @__PURE__ */ forwardRef((props, ref) => {
|
|
|
10231
10231
|
className: mergedIconCls,
|
|
10232
10232
|
style: style2,
|
|
10233
10233
|
ref
|
|
10234
|
-
}, /* @__PURE__ */ React__default.createElement(RefIcon$
|
|
10234
|
+
}, /* @__PURE__ */ React__default.createElement(RefIcon$u, {
|
|
10235
10235
|
className: iconClassName
|
|
10236
10236
|
}));
|
|
10237
10237
|
});
|
|
@@ -10967,9 +10967,9 @@ var RightOutlined = function RightOutlined2(props, ref) {
|
|
|
10967
10967
|
icon: RightOutlined$1
|
|
10968
10968
|
}));
|
|
10969
10969
|
};
|
|
10970
|
-
var RefIcon$
|
|
10970
|
+
var RefIcon$t = /* @__PURE__ */ React.forwardRef(RightOutlined);
|
|
10971
10971
|
if (process.env.NODE_ENV !== "production") {
|
|
10972
|
-
RefIcon$
|
|
10972
|
+
RefIcon$t.displayName = "RightOutlined";
|
|
10973
10973
|
}
|
|
10974
10974
|
const genCollapseMotion = (token2) => ({
|
|
10975
10975
|
[token2.componentCls]: {
|
|
@@ -17078,7 +17078,7 @@ const NormalOkBtn = () => {
|
|
|
17078
17078
|
function renderCloseIcon(prefixCls, closeIcon) {
|
|
17079
17079
|
return /* @__PURE__ */ React__default.createElement("span", {
|
|
17080
17080
|
className: `${prefixCls}-close-x`
|
|
17081
|
-
}, closeIcon || /* @__PURE__ */ React__default.createElement(RefIcon$
|
|
17081
|
+
}, closeIcon || /* @__PURE__ */ React__default.createElement(RefIcon$x, {
|
|
17082
17082
|
className: `${prefixCls}-close-icon`
|
|
17083
17083
|
}));
|
|
17084
17084
|
}
|
|
@@ -17670,7 +17670,7 @@ const Modal = (props) => {
|
|
|
17670
17670
|
})) : null;
|
|
17671
17671
|
const [mergedClosable, mergedCloseIcon, closeBtnIsDisabled, ariaProps] = useClosable(pickClosable(props), pickClosable(modalContext), {
|
|
17672
17672
|
closable: true,
|
|
17673
|
-
closeIcon: /* @__PURE__ */ React.createElement(RefIcon$
|
|
17673
|
+
closeIcon: /* @__PURE__ */ React.createElement(RefIcon$x, {
|
|
17674
17674
|
className: `${prefixCls}-close-icon`
|
|
17675
17675
|
}),
|
|
17676
17676
|
closeIconRender: (icon2) => renderCloseIcon(prefixCls, icon2)
|
|
@@ -17867,16 +17867,16 @@ const ConfirmContent = (props) => {
|
|
|
17867
17867
|
if (!icon2 && icon2 !== null) {
|
|
17868
17868
|
switch (type4) {
|
|
17869
17869
|
case "info":
|
|
17870
|
-
mergedIcon = /* @__PURE__ */ React.createElement(RefIcon$
|
|
17870
|
+
mergedIcon = /* @__PURE__ */ React.createElement(RefIcon$v, null);
|
|
17871
17871
|
break;
|
|
17872
17872
|
case "success":
|
|
17873
|
-
mergedIcon = /* @__PURE__ */ React.createElement(RefIcon$
|
|
17873
|
+
mergedIcon = /* @__PURE__ */ React.createElement(RefIcon$z, null);
|
|
17874
17874
|
break;
|
|
17875
17875
|
case "error":
|
|
17876
|
-
mergedIcon = /* @__PURE__ */ React.createElement(RefIcon$
|
|
17876
|
+
mergedIcon = /* @__PURE__ */ React.createElement(RefIcon$y, null);
|
|
17877
17877
|
break;
|
|
17878
17878
|
default:
|
|
17879
|
-
mergedIcon = /* @__PURE__ */ React.createElement(RefIcon$
|
|
17879
|
+
mergedIcon = /* @__PURE__ */ React.createElement(RefIcon$w, null);
|
|
17880
17880
|
}
|
|
17881
17881
|
}
|
|
17882
17882
|
const mergedOkCancel = okCancel !== null && okCancel !== void 0 ? okCancel : type4 === "confirm";
|
|
@@ -18640,15 +18640,15 @@ function getCloseIcon(prefixCls, closeIcon) {
|
|
|
18640
18640
|
if (closeIcon === null || closeIcon === false) {
|
|
18641
18641
|
return null;
|
|
18642
18642
|
}
|
|
18643
|
-
return closeIcon || /* @__PURE__ */ React.createElement(RefIcon$
|
|
18643
|
+
return closeIcon || /* @__PURE__ */ React.createElement(RefIcon$x, {
|
|
18644
18644
|
className: `${prefixCls}-close-icon`
|
|
18645
18645
|
});
|
|
18646
18646
|
}
|
|
18647
18647
|
const typeToIcon = {
|
|
18648
|
-
success: RefIcon$
|
|
18649
|
-
info: RefIcon$
|
|
18650
|
-
error: RefIcon$
|
|
18651
|
-
warning: RefIcon$
|
|
18648
|
+
success: RefIcon$z,
|
|
18649
|
+
info: RefIcon$v,
|
|
18650
|
+
error: RefIcon$y,
|
|
18651
|
+
warning: RefIcon$w
|
|
18652
18652
|
};
|
|
18653
18653
|
const PureContent = (props) => {
|
|
18654
18654
|
const {
|
|
@@ -25259,9 +25259,9 @@ var CheckOutlined = function CheckOutlined2(props, ref) {
|
|
|
25259
25259
|
icon: CheckOutlined$1
|
|
25260
25260
|
}));
|
|
25261
25261
|
};
|
|
25262
|
-
var RefIcon$
|
|
25262
|
+
var RefIcon$s = /* @__PURE__ */ React.forwardRef(CheckOutlined);
|
|
25263
25263
|
if (process.env.NODE_ENV !== "production") {
|
|
25264
|
-
RefIcon$
|
|
25264
|
+
RefIcon$s.displayName = "CheckOutlined";
|
|
25265
25265
|
}
|
|
25266
25266
|
var DownOutlined$1 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z" } }] }, "name": "down", "theme": "outlined" };
|
|
25267
25267
|
var DownOutlined = function DownOutlined2(props, ref) {
|
|
@@ -25270,9 +25270,9 @@ var DownOutlined = function DownOutlined2(props, ref) {
|
|
|
25270
25270
|
icon: DownOutlined$1
|
|
25271
25271
|
}));
|
|
25272
25272
|
};
|
|
25273
|
-
var RefIcon$
|
|
25273
|
+
var RefIcon$r = /* @__PURE__ */ React.forwardRef(DownOutlined);
|
|
25274
25274
|
if (process.env.NODE_ENV !== "production") {
|
|
25275
|
-
RefIcon$
|
|
25275
|
+
RefIcon$r.displayName = "DownOutlined";
|
|
25276
25276
|
}
|
|
25277
25277
|
var SearchOutlined$1 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z" } }] }, "name": "search", "theme": "outlined" };
|
|
25278
25278
|
var SearchOutlined = function SearchOutlined2(props, ref) {
|
|
@@ -25281,9 +25281,9 @@ var SearchOutlined = function SearchOutlined2(props, ref) {
|
|
|
25281
25281
|
icon: SearchOutlined$1
|
|
25282
25282
|
}));
|
|
25283
25283
|
};
|
|
25284
|
-
var RefIcon$
|
|
25284
|
+
var RefIcon$q = /* @__PURE__ */ React.forwardRef(SearchOutlined);
|
|
25285
25285
|
if (process.env.NODE_ENV !== "production") {
|
|
25286
|
-
RefIcon$
|
|
25286
|
+
RefIcon$q.displayName = "SearchOutlined";
|
|
25287
25287
|
}
|
|
25288
25288
|
function useIcons$1({
|
|
25289
25289
|
suffixIcon,
|
|
@@ -25303,7 +25303,7 @@ function useIcons$1({
|
|
|
25303
25303
|
const warning3 = devUseWarning(componentName);
|
|
25304
25304
|
warning3.deprecated(!clearIcon, "clearIcon", "allowClear={{ clearIcon: React.ReactNode }}");
|
|
25305
25305
|
}
|
|
25306
|
-
const mergedClearIcon = clearIcon !== null && clearIcon !== void 0 ? clearIcon : /* @__PURE__ */ React.createElement(RefIcon$
|
|
25306
|
+
const mergedClearIcon = clearIcon !== null && clearIcon !== void 0 ? clearIcon : /* @__PURE__ */ React.createElement(RefIcon$y, null);
|
|
25307
25307
|
const getSuffixIconNode = (arrowIcon) => {
|
|
25308
25308
|
if (suffixIcon === null && !hasFeedback && !showArrow) {
|
|
25309
25309
|
return null;
|
|
@@ -25314,7 +25314,7 @@ function useIcons$1({
|
|
|
25314
25314
|
if (suffixIcon !== void 0) {
|
|
25315
25315
|
mergedSuffixIcon = getSuffixIconNode(suffixIcon);
|
|
25316
25316
|
} else if (loading) {
|
|
25317
|
-
mergedSuffixIcon = getSuffixIconNode(/* @__PURE__ */ React.createElement(RefIcon$
|
|
25317
|
+
mergedSuffixIcon = getSuffixIconNode(/* @__PURE__ */ React.createElement(RefIcon$u, {
|
|
25318
25318
|
spin: true
|
|
25319
25319
|
}));
|
|
25320
25320
|
} else {
|
|
@@ -25324,11 +25324,11 @@ function useIcons$1({
|
|
|
25324
25324
|
showSearch
|
|
25325
25325
|
}) => {
|
|
25326
25326
|
if (open && showSearch) {
|
|
25327
|
-
return getSuffixIconNode(/* @__PURE__ */ React.createElement(RefIcon$
|
|
25327
|
+
return getSuffixIconNode(/* @__PURE__ */ React.createElement(RefIcon$q, {
|
|
25328
25328
|
className: iconCls
|
|
25329
25329
|
}));
|
|
25330
25330
|
}
|
|
25331
|
-
return getSuffixIconNode(/* @__PURE__ */ React.createElement(RefIcon$
|
|
25331
|
+
return getSuffixIconNode(/* @__PURE__ */ React.createElement(RefIcon$r, {
|
|
25332
25332
|
className: iconCls
|
|
25333
25333
|
}));
|
|
25334
25334
|
};
|
|
@@ -25337,7 +25337,7 @@ function useIcons$1({
|
|
|
25337
25337
|
if (menuItemSelectedIcon !== void 0) {
|
|
25338
25338
|
mergedItemIcon = menuItemSelectedIcon;
|
|
25339
25339
|
} else if (multiple) {
|
|
25340
|
-
mergedItemIcon = /* @__PURE__ */ React.createElement(RefIcon$
|
|
25340
|
+
mergedItemIcon = /* @__PURE__ */ React.createElement(RefIcon$s, null);
|
|
25341
25341
|
} else {
|
|
25342
25342
|
mergedItemIcon = null;
|
|
25343
25343
|
}
|
|
@@ -25345,7 +25345,7 @@ function useIcons$1({
|
|
|
25345
25345
|
if (removeIcon !== void 0) {
|
|
25346
25346
|
mergedRemoveIcon = removeIcon;
|
|
25347
25347
|
} else {
|
|
25348
|
-
mergedRemoveIcon = /* @__PURE__ */ React.createElement(RefIcon$
|
|
25348
|
+
mergedRemoveIcon = /* @__PURE__ */ React.createElement(RefIcon$x, null);
|
|
25349
25349
|
}
|
|
25350
25350
|
return {
|
|
25351
25351
|
clearIcon: mergedClearIcon,
|
|
@@ -27672,9 +27672,9 @@ var LeftOutlined = function LeftOutlined2(props, ref) {
|
|
|
27672
27672
|
icon: LeftOutlined$1
|
|
27673
27673
|
}));
|
|
27674
27674
|
};
|
|
27675
|
-
var RefIcon$
|
|
27675
|
+
var RefIcon$p = /* @__PURE__ */ React.forwardRef(LeftOutlined);
|
|
27676
27676
|
if (process.env.NODE_ENV !== "production") {
|
|
27677
|
-
RefIcon$
|
|
27677
|
+
RefIcon$p.displayName = "LeftOutlined";
|
|
27678
27678
|
}
|
|
27679
27679
|
var ESC$1 = KeyCode.ESC, TAB = KeyCode.TAB;
|
|
27680
27680
|
function useAccessibility$1(_ref) {
|
|
@@ -29263,9 +29263,9 @@ var EllipsisOutlined = function EllipsisOutlined2(props, ref) {
|
|
|
29263
29263
|
icon: EllipsisOutlined$1
|
|
29264
29264
|
}));
|
|
29265
29265
|
};
|
|
29266
|
-
var RefIcon$
|
|
29266
|
+
var RefIcon$o = /* @__PURE__ */ React.forwardRef(EllipsisOutlined);
|
|
29267
29267
|
if (process.env.NODE_ENV !== "production") {
|
|
29268
|
-
RefIcon$
|
|
29268
|
+
RefIcon$o.displayName = "EllipsisOutlined";
|
|
29269
29269
|
}
|
|
29270
29270
|
var dayjs_min$1 = { exports: {} };
|
|
29271
29271
|
var dayjs_min = dayjs_min$1.exports;
|
|
@@ -37374,9 +37374,9 @@ var PlusOutlined = function PlusOutlined2(props, ref) {
|
|
|
37374
37374
|
icon: PlusOutlined$1
|
|
37375
37375
|
}));
|
|
37376
37376
|
};
|
|
37377
|
-
var RefIcon$
|
|
37377
|
+
var RefIcon$n = /* @__PURE__ */ React.forwardRef(PlusOutlined);
|
|
37378
37378
|
if (process.env.NODE_ENV !== "production") {
|
|
37379
|
-
RefIcon$
|
|
37379
|
+
RefIcon$n.displayName = "PlusOutlined";
|
|
37380
37380
|
}
|
|
37381
37381
|
const TabContext = /* @__PURE__ */ createContext(null);
|
|
37382
37382
|
var useIndicator = function useIndicator2(options) {
|
|
@@ -39672,8 +39672,8 @@ const InternalTabs = /* @__PURE__ */ React.forwardRef((props, ref) => {
|
|
|
39672
39672
|
}) => {
|
|
39673
39673
|
onEdit === null || onEdit === void 0 ? void 0 : onEdit(editType === "add" ? event : key, editType);
|
|
39674
39674
|
},
|
|
39675
|
-
removeIcon: (_a2 = removeIcon !== null && removeIcon !== void 0 ? removeIcon : tabs === null || tabs === void 0 ? void 0 : tabs.removeIcon) !== null && _a2 !== void 0 ? _a2 : /* @__PURE__ */ React.createElement(RefIcon$
|
|
39676
|
-
addIcon: (addIcon !== null && addIcon !== void 0 ? addIcon : tabs === null || tabs === void 0 ? void 0 : tabs.addIcon) || /* @__PURE__ */ React.createElement(RefIcon$
|
|
39675
|
+
removeIcon: (_a2 = removeIcon !== null && removeIcon !== void 0 ? removeIcon : tabs === null || tabs === void 0 ? void 0 : tabs.removeIcon) !== null && _a2 !== void 0 ? _a2 : /* @__PURE__ */ React.createElement(RefIcon$x, null),
|
|
39676
|
+
addIcon: (addIcon !== null && addIcon !== void 0 ? addIcon : tabs === null || tabs === void 0 ? void 0 : tabs.addIcon) || /* @__PURE__ */ React.createElement(RefIcon$n, null),
|
|
39677
39677
|
showAdd: hideAdd !== true
|
|
39678
39678
|
};
|
|
39679
39679
|
}
|
|
@@ -39708,7 +39708,7 @@ const InternalTabs = /* @__PURE__ */ React.forwardRef((props, ref) => {
|
|
|
39708
39708
|
style: mergedStyle,
|
|
39709
39709
|
editable: editable2,
|
|
39710
39710
|
more: Object.assign({
|
|
39711
|
-
icon: (_l = (_k = (_j = (_h = tabs === null || tabs === void 0 ? void 0 : tabs.more) === null || _h === void 0 ? void 0 : _h.icon) !== null && _j !== void 0 ? _j : tabs === null || tabs === void 0 ? void 0 : tabs.moreIcon) !== null && _k !== void 0 ? _k : moreIcon) !== null && _l !== void 0 ? _l : /* @__PURE__ */ React.createElement(RefIcon$
|
|
39711
|
+
icon: (_l = (_k = (_j = (_h = tabs === null || tabs === void 0 ? void 0 : tabs.more) === null || _h === void 0 ? void 0 : _h.icon) !== null && _j !== void 0 ? _j : tabs === null || tabs === void 0 ? void 0 : tabs.moreIcon) !== null && _k !== void 0 ? _k : moreIcon) !== null && _l !== void 0 ? _l : /* @__PURE__ */ React.createElement(RefIcon$o, null),
|
|
39712
39712
|
transitionName: `${rootPrefixCls}-slide-up`
|
|
39713
39713
|
}, more),
|
|
39714
39714
|
prefixCls,
|
|
@@ -41217,6 +41217,17 @@ const Divider = (props) => {
|
|
|
41217
41217
|
if (process.env.NODE_ENV !== "production") {
|
|
41218
41218
|
Divider.displayName = "Divider";
|
|
41219
41219
|
}
|
|
41220
|
+
var UpOutlined$1 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M890.5 755.3L537.9 269.2c-12.8-17.6-39-17.6-51.7 0L133.5 755.3A8 8 0 00140 768h75c5.1 0 9.9-2.5 12.9-6.6L512 369.8l284.1 391.6c3 4.1 7.8 6.6 12.9 6.6h75c6.5 0 10.3-7.4 6.5-12.7z" } }] }, "name": "up", "theme": "outlined" };
|
|
41221
|
+
var UpOutlined = function UpOutlined2(props, ref) {
|
|
41222
|
+
return /* @__PURE__ */ React.createElement(Icon$2, _extends$1({}, props, {
|
|
41223
|
+
ref,
|
|
41224
|
+
icon: UpOutlined$1
|
|
41225
|
+
}));
|
|
41226
|
+
};
|
|
41227
|
+
var RefIcon$m = /* @__PURE__ */ React.forwardRef(UpOutlined);
|
|
41228
|
+
if (process.env.NODE_ENV !== "production") {
|
|
41229
|
+
RefIcon$m.displayName = "UpOutlined";
|
|
41230
|
+
}
|
|
41220
41231
|
function hasAddon(props) {
|
|
41221
41232
|
return !!(props.addonBefore || props.addonAfter);
|
|
41222
41233
|
}
|
|
@@ -41575,7 +41586,7 @@ const getAllowClear = (allowClear) => {
|
|
|
41575
41586
|
mergedAllowClear = allowClear;
|
|
41576
41587
|
} else if (allowClear) {
|
|
41577
41588
|
mergedAllowClear = {
|
|
41578
|
-
clearIcon: /* @__PURE__ */ React__default.createElement(RefIcon$
|
|
41589
|
+
clearIcon: /* @__PURE__ */ React__default.createElement(RefIcon$y, null)
|
|
41579
41590
|
};
|
|
41580
41591
|
}
|
|
41581
41592
|
return mergedAllowClear;
|
|
@@ -44587,10 +44598,10 @@ const FormItemLabel = ({
|
|
|
44587
44598
|
}, labelChildren));
|
|
44588
44599
|
};
|
|
44589
44600
|
const iconMap = {
|
|
44590
|
-
success: RefIcon$
|
|
44591
|
-
warning: RefIcon$
|
|
44592
|
-
error: RefIcon$
|
|
44593
|
-
validating: RefIcon$
|
|
44601
|
+
success: RefIcon$z,
|
|
44602
|
+
warning: RefIcon$w,
|
|
44603
|
+
error: RefIcon$y,
|
|
44604
|
+
validating: RefIcon$u
|
|
44594
44605
|
};
|
|
44595
44606
|
function StatusProvider({
|
|
44596
44607
|
children,
|
|
@@ -45607,7 +45618,7 @@ const Search = /* @__PURE__ */ React.forwardRef((props, ref) => {
|
|
|
45607
45618
|
customOnPressEnter === null || customOnPressEnter === void 0 ? void 0 : customOnPressEnter(e3);
|
|
45608
45619
|
onSearch(e3);
|
|
45609
45620
|
};
|
|
45610
|
-
const searchIcon = typeof enterButton === "boolean" ? /* @__PURE__ */ React.createElement(RefIcon$
|
|
45621
|
+
const searchIcon = typeof enterButton === "boolean" ? /* @__PURE__ */ React.createElement(RefIcon$q, null) : null;
|
|
45611
45622
|
const btnClassName = `${prefixCls}-button`;
|
|
45612
45623
|
let button;
|
|
45613
45624
|
const enterButtonAsElement = enterButton || {};
|
|
@@ -47521,12 +47532,12 @@ const Pagination2 = (props) => {
|
|
|
47521
47532
|
className: `${prefixCls}-item-link`,
|
|
47522
47533
|
type: "button",
|
|
47523
47534
|
tabIndex: -1
|
|
47524
|
-
}, direction === "rtl" ? /* @__PURE__ */ React.createElement(RefIcon$
|
|
47535
|
+
}, direction === "rtl" ? /* @__PURE__ */ React.createElement(RefIcon$t, null) : /* @__PURE__ */ React.createElement(RefIcon$p, null));
|
|
47525
47536
|
const nextIcon = /* @__PURE__ */ React.createElement("button", {
|
|
47526
47537
|
className: `${prefixCls}-item-link`,
|
|
47527
47538
|
type: "button",
|
|
47528
47539
|
tabIndex: -1
|
|
47529
|
-
}, direction === "rtl" ? /* @__PURE__ */ React.createElement(RefIcon$
|
|
47540
|
+
}, direction === "rtl" ? /* @__PURE__ */ React.createElement(RefIcon$p, null) : /* @__PURE__ */ React.createElement(RefIcon$t, null));
|
|
47530
47541
|
const jumpPrevIcon = (
|
|
47531
47542
|
// biome-ignore lint/a11y/useValidAnchor: it is hard to refactor
|
|
47532
47543
|
/* @__PURE__ */ React.createElement("a", {
|
|
@@ -47986,7 +47997,7 @@ const InternalSwitch = /* @__PURE__ */ React.forwardRef((props, ref) => {
|
|
|
47986
47997
|
const prefixCls = getPrefixCls("switch", customizePrefixCls);
|
|
47987
47998
|
const loadingIcon = /* @__PURE__ */ React.createElement("div", {
|
|
47988
47999
|
className: `${prefixCls}-handle`
|
|
47989
|
-
}, loading && /* @__PURE__ */ React.createElement(RefIcon$
|
|
48000
|
+
}, loading && /* @__PURE__ */ React.createElement(RefIcon$u, {
|
|
47990
48001
|
className: `${prefixCls}-loading-icon`
|
|
47991
48002
|
}));
|
|
47992
48003
|
const [wrapCSSVar, hashId, cssVarCls] = useStyle$2(prefixCls);
|
|
@@ -49122,7 +49133,7 @@ const CopyBtn = ({
|
|
|
49122
49133
|
onClick: onCopy,
|
|
49123
49134
|
"aria-label": ariaLabel,
|
|
49124
49135
|
tabIndex
|
|
49125
|
-
}, copied ? getNode(iconNodes[1], /* @__PURE__ */ React.createElement(RefIcon$
|
|
49136
|
+
}, copied ? getNode(iconNodes[1], /* @__PURE__ */ React.createElement(RefIcon$s, null), true) : getNode(iconNodes[0], btnLoading ? /* @__PURE__ */ React.createElement(RefIcon$u, null) : /* @__PURE__ */ React.createElement(RefIcon$a, null), true)));
|
|
49126
49137
|
};
|
|
49127
49138
|
const MeasureText = /* @__PURE__ */ React.forwardRef(({
|
|
49128
49139
|
style: style2,
|
|
@@ -60049,7 +60060,7 @@ const Text$2 = ({
|
|
|
60049
60060
|
color: "green",
|
|
60050
60061
|
size: "middle",
|
|
60051
60062
|
danger: !isValidTextValue,
|
|
60052
|
-
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$
|
|
60063
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$s, {})
|
|
60053
60064
|
}
|
|
60054
60065
|
)
|
|
60055
60066
|
] }),
|
|
@@ -67477,6 +67488,31 @@ let EditorState$1 = class EditorState {
|
|
|
67477
67488
|
}
|
|
67478
67489
|
});
|
|
67479
67490
|
}
|
|
67491
|
+
updateNavigationStateForId(id2, navigationState) {
|
|
67492
|
+
var _a2, _b;
|
|
67493
|
+
if (!id2) return;
|
|
67494
|
+
for (let i = this.history.length - 1; i >= 0; i -= 1) {
|
|
67495
|
+
const entry = this.history[i];
|
|
67496
|
+
if ((entry == null ? void 0 : entry.id) !== id2) continue;
|
|
67497
|
+
this.history[i] = {
|
|
67498
|
+
...entry,
|
|
67499
|
+
navigationState: {
|
|
67500
|
+
...entry.navigationState ?? {},
|
|
67501
|
+
...navigationState,
|
|
67502
|
+
tabStates: {
|
|
67503
|
+
...((_a2 = entry.navigationState) == null ? void 0 : _a2.tabStates) ?? {},
|
|
67504
|
+
...navigationState.tabStates ?? {}
|
|
67505
|
+
},
|
|
67506
|
+
uiState: {
|
|
67507
|
+
...((_b = entry.navigationState) == null ? void 0 : _b.uiState) ?? {},
|
|
67508
|
+
...navigationState.uiState ?? {}
|
|
67509
|
+
}
|
|
67510
|
+
}
|
|
67511
|
+
};
|
|
67512
|
+
this.persist();
|
|
67513
|
+
return;
|
|
67514
|
+
}
|
|
67515
|
+
}
|
|
67480
67516
|
getNavigationState(id2) {
|
|
67481
67517
|
var _a2;
|
|
67482
67518
|
if (!id2) {
|
|
@@ -67962,7 +67998,7 @@ const NumberComponent = ({
|
|
|
67962
67998
|
color: "green",
|
|
67963
67999
|
size: "middle",
|
|
67964
68000
|
disabled: !isValidNumber || !isValidConstraints,
|
|
67965
|
-
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$
|
|
68001
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$s, {})
|
|
67966
68002
|
}
|
|
67967
68003
|
)
|
|
67968
68004
|
] }),
|
|
@@ -68100,7 +68136,7 @@ const Url = ({
|
|
|
68100
68136
|
color: "green",
|
|
68101
68137
|
size: "middle",
|
|
68102
68138
|
danger: !isValidUrl,
|
|
68103
|
-
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$
|
|
68139
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$s, {})
|
|
68104
68140
|
}
|
|
68105
68141
|
)
|
|
68106
68142
|
] }),
|
|
@@ -79827,7 +79863,8 @@ const PaginateLinkedEntities = ({
|
|
|
79827
79863
|
readonly = false,
|
|
79828
79864
|
className = "",
|
|
79829
79865
|
onLoadEntity,
|
|
79830
|
-
onUnlinkEntity
|
|
79866
|
+
onUnlinkEntity,
|
|
79867
|
+
onPageChange
|
|
79831
79868
|
}) => {
|
|
79832
79869
|
var _a2, _b;
|
|
79833
79870
|
const { t: t2 } = useTranslation();
|
|
@@ -79878,6 +79915,10 @@ const PaginateLinkedEntities = ({
|
|
|
79878
79915
|
useEffect(() => {
|
|
79879
79916
|
filterAndChunkEntitiesForDisplay();
|
|
79880
79917
|
}, [filter2, currentPage]);
|
|
79918
|
+
const handlePageChange = (page) => {
|
|
79919
|
+
onPageChange == null ? void 0 : onPageChange();
|
|
79920
|
+
setCurrentPage(page);
|
|
79921
|
+
};
|
|
79881
79922
|
const handleFilterChange = (event) => {
|
|
79882
79923
|
setFilter(event.target.value);
|
|
79883
79924
|
};
|
|
@@ -79888,7 +79929,7 @@ const PaginateLinkedEntities = ({
|
|
|
79888
79929
|
current: currentPage,
|
|
79889
79930
|
pageSize,
|
|
79890
79931
|
total,
|
|
79891
|
-
onChange:
|
|
79932
|
+
onChange: handlePageChange,
|
|
79892
79933
|
showSizeChanger: false,
|
|
79893
79934
|
hideOnSinglePage: true,
|
|
79894
79935
|
showTotal: (total2) => t2("pagination_total", { total: total2 })
|
|
@@ -79922,7 +79963,7 @@ const PaginateLinkedEntities = ({
|
|
|
79922
79963
|
current: currentPage,
|
|
79923
79964
|
pageSize,
|
|
79924
79965
|
total,
|
|
79925
|
-
onChange:
|
|
79966
|
+
onChange: handlePageChange,
|
|
79926
79967
|
showSizeChanger: false,
|
|
79927
79968
|
hideOnSinglePage: true,
|
|
79928
79969
|
showTotal: (total2) => t2("pagination_total", { total: total2 })
|
|
@@ -79989,7 +80030,7 @@ const AddControl = ({
|
|
|
79989
80030
|
type: "primary",
|
|
79990
80031
|
size: "middle",
|
|
79991
80032
|
className: "focus:outline-none focus:border-2 focus:border-green-600",
|
|
79992
|
-
icon: !selectedType || selectedType !== type4 ? /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$
|
|
80033
|
+
icon: !selectedType || selectedType !== type4 ? /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$n, {}) : /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$x, {}),
|
|
79993
80034
|
children: [
|
|
79994
80035
|
" ",
|
|
79995
80036
|
getTypeLabelFromProfile(type4)
|
|
@@ -80003,7 +80044,7 @@ const AddControl = ({
|
|
|
80003
80044
|
type: "primary",
|
|
80004
80045
|
size: "middle",
|
|
80005
80046
|
className: "focus:outline-none focus:border-2 focus:border-green-600",
|
|
80006
|
-
icon: !selectedType || selectedType !== "bulkAdd" ? /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$1, {}) : /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$
|
|
80047
|
+
icon: !selectedType || selectedType !== "bulkAdd" ? /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$1, {}) : /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$x, {}),
|
|
80007
80048
|
children: " Bulk Add"
|
|
80008
80049
|
}
|
|
80009
80050
|
) })
|
|
@@ -81151,7 +81192,7 @@ const AutoComplete = ({ type: type4, onLinkEntity, onCreateEntity }) => {
|
|
|
81151
81192
|
variant: "solid",
|
|
81152
81193
|
color: "green",
|
|
81153
81194
|
block: true,
|
|
81154
|
-
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$
|
|
81195
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$n, {}),
|
|
81155
81196
|
children: [
|
|
81156
81197
|
t2("create_new_of_type", { type: entity["@type"] }),
|
|
81157
81198
|
": ",
|
|
@@ -81298,7 +81339,7 @@ const BulkAdd = ({ types: types2, primitives, onCreateEntity }) => {
|
|
|
81298
81339
|
{
|
|
81299
81340
|
type: "primary",
|
|
81300
81341
|
onClick: addRow,
|
|
81301
|
-
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$
|
|
81342
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$n, {}),
|
|
81302
81343
|
children: "Add row"
|
|
81303
81344
|
}
|
|
81304
81345
|
),
|
|
@@ -81551,6 +81592,7 @@ const EntityProperty = ({
|
|
|
81551
81592
|
const profileManager = useContext(ProfileManagerContext);
|
|
81552
81593
|
const crateManager = useContext(CrateManagerContext);
|
|
81553
81594
|
const state = useStateStore();
|
|
81595
|
+
const propertyRef = useRef(null);
|
|
81554
81596
|
const propertyDefinition = (_a2 = profileManager == null ? void 0 : profileManager.getPropertyDefinition({
|
|
81555
81597
|
property,
|
|
81556
81598
|
entity
|
|
@@ -81578,9 +81620,17 @@ const EntityProperty = ({
|
|
|
81578
81620
|
["value.@id"]
|
|
81579
81621
|
);
|
|
81580
81622
|
}, [values]);
|
|
81623
|
+
const scrollToPropertyTop = useCallback(() => {
|
|
81624
|
+
var _a3;
|
|
81625
|
+
(_a3 = propertyRef.current) == null ? void 0 : _a3.scrollIntoView({
|
|
81626
|
+
block: "start",
|
|
81627
|
+
behavior: "auto"
|
|
81628
|
+
});
|
|
81629
|
+
}, []);
|
|
81581
81630
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
81582
81631
|
"div",
|
|
81583
81632
|
{
|
|
81633
|
+
ref: propertyRef,
|
|
81584
81634
|
className: `flex flex-row flex-grow p-2 describo-property-background ${highlightRequired && isRequired && !isValid ? "bg-red-200" : ""} ${savedProperty ? "bg-green-100 transition-colors duration-1000" : ""} describo-property describo-property-name-${property}`,
|
|
81585
81635
|
children: [
|
|
81586
81636
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "min-w-32 w-1/3 xl:w-1/5 flex flex-col describo-property-heading", children: [
|
|
@@ -81636,7 +81686,8 @@ const EntityProperty = ({
|
|
|
81636
81686
|
property,
|
|
81637
81687
|
readonly: propertyDefinition == null ? void 0 : propertyDefinition.readonly,
|
|
81638
81688
|
onLoadEntity,
|
|
81639
|
-
onUnlinkEntity
|
|
81689
|
+
onUnlinkEntity,
|
|
81690
|
+
onPageChange: scrollToPropertyTop
|
|
81640
81691
|
}
|
|
81641
81692
|
),
|
|
81642
81693
|
showAddControl && !((_b = state.configuration) == null ? void 0 : _b.readonly) && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -81666,26 +81717,49 @@ const DialogAddProperty = ({
|
|
|
81666
81717
|
const { t: t2 } = useTranslation();
|
|
81667
81718
|
const profileManager = useContext(ProfileManagerContext);
|
|
81668
81719
|
const [filter2, setFilter] = useState("");
|
|
81720
|
+
const [selectedPropertyName, setSelectedPropertyName] = useState(null);
|
|
81721
|
+
useEffect(() => {
|
|
81722
|
+
if (open) {
|
|
81723
|
+
setSelectedPropertyName(null);
|
|
81724
|
+
}
|
|
81725
|
+
}, [open]);
|
|
81669
81726
|
const inputs = React__default.useMemo(() => {
|
|
81670
81727
|
if (!(entity == null ? void 0 : entity["@type"])) return [];
|
|
81671
81728
|
const { inputs: inputs2 } = profileManager.getAllInputs({ entity });
|
|
81672
81729
|
if (!filter2) return inputs2;
|
|
81730
|
+
const query = filter2.toLowerCase();
|
|
81673
81731
|
return inputs2.filter((i) => {
|
|
81674
|
-
|
|
81675
|
-
const re2 = new RegExp(filter2, "i");
|
|
81676
|
-
return ((_a2 = i == null ? void 0 : i.name) == null ? void 0 : _a2.match(re2)) || ((_b = i == null ? void 0 : i.help) == null ? void 0 : _b.match(re2));
|
|
81732
|
+
return String((i == null ? void 0 : i.name) || "").toLowerCase().includes(query) || String((i == null ? void 0 : i.help) || "").toLowerCase().includes(query);
|
|
81677
81733
|
});
|
|
81678
81734
|
}, [entity, filter2, profileManager]);
|
|
81679
81735
|
const handlePropertySelection = (item) => {
|
|
81680
|
-
|
|
81736
|
+
if (!(item == null ? void 0 : item.name) || selectedPropertyName === item.name) return;
|
|
81737
|
+
setSelectedPropertyName(item.name);
|
|
81738
|
+
window.setTimeout(() => {
|
|
81739
|
+
onAddPropertyPlaceholder(item.name);
|
|
81740
|
+
onClose();
|
|
81741
|
+
}, 120);
|
|
81742
|
+
};
|
|
81743
|
+
const handlePropertyKeyDown = (event, item) => {
|
|
81744
|
+
if (event.key !== "Enter" && event.key !== " ") return;
|
|
81745
|
+
event.preventDefault();
|
|
81746
|
+
handlePropertySelection(item);
|
|
81747
|
+
};
|
|
81748
|
+
const handleDrawerClose = () => {
|
|
81749
|
+
setSelectedPropertyName(null);
|
|
81681
81750
|
onClose();
|
|
81682
81751
|
};
|
|
81752
|
+
const renderPropertyType = (type4) => {
|
|
81753
|
+
if (Array.isArray(type4)) return type4.join(", ");
|
|
81754
|
+
return type4 || "";
|
|
81755
|
+
};
|
|
81683
81756
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
81684
81757
|
Drawer2,
|
|
81685
81758
|
{
|
|
81686
|
-
|
|
81759
|
+
rootClassName: "describo-add-property-drawer",
|
|
81760
|
+
title: /* @__PURE__ */ jsxRuntimeExports.jsx(Typography.Title, { className: "describo-add-property-title", level: 4, children: t2("add_properties_to_this_entity") || "Add properties to this entity" }),
|
|
81687
81761
|
placement: "left",
|
|
81688
|
-
onClose,
|
|
81762
|
+
onClose: handleDrawerClose,
|
|
81689
81763
|
open,
|
|
81690
81764
|
width: 600,
|
|
81691
81765
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Flex, { vertical: true, className: "h-full", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(Flex, { vertical: true, gap: 16, className: "overflow-auto flex-grow", children: [
|
|
@@ -81701,22 +81775,30 @@ const DialogAddProperty = ({
|
|
|
81701
81775
|
),
|
|
81702
81776
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Button$1, { type: "primary", size: "middle", children: t2("search") || "Search" })
|
|
81703
81777
|
] }),
|
|
81704
|
-
inputs.map((item, idx) =>
|
|
81705
|
-
|
|
81706
|
-
|
|
81707
|
-
|
|
81708
|
-
|
|
81709
|
-
|
|
81710
|
-
|
|
81711
|
-
|
|
81712
|
-
|
|
81713
|
-
|
|
81714
|
-
|
|
81715
|
-
/* @__PURE__ */ jsxRuntimeExports.
|
|
81716
|
-
|
|
81717
|
-
|
|
81718
|
-
|
|
81719
|
-
|
|
81778
|
+
inputs.map((item, idx) => {
|
|
81779
|
+
const isSelected = selectedPropertyName === item.name;
|
|
81780
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
81781
|
+
"div",
|
|
81782
|
+
{
|
|
81783
|
+
className: `describo-add-property-row ${isSelected ? "describo-add-property-row-selected" : ""}`,
|
|
81784
|
+
role: "button",
|
|
81785
|
+
tabIndex: 0,
|
|
81786
|
+
"aria-pressed": isSelected,
|
|
81787
|
+
onClick: () => handlePropertySelection(item),
|
|
81788
|
+
onKeyDown: (event) => handlePropertyKeyDown(event, item),
|
|
81789
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs(Flex, { vertical: true, children: [
|
|
81790
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(Flex, { align: "center", gap: 6, className: "describo-add-property-row-header", children: [
|
|
81791
|
+
item.label ? /* @__PURE__ */ jsxRuntimeExports.jsx(Typography.Text, { className: "describo-add-property-row-name", children: item.label }) : /* @__PURE__ */ jsxRuntimeExports.jsx(Typography.Text, { className: "describo-add-property-row-name", children: item.name }),
|
|
81792
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$7, {}),
|
|
81793
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Typography.Text, { className: "describo-add-property-row-type", children: renderPropertyType(item.type) }),
|
|
81794
|
+
isSelected && /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$s, { className: "describo-add-property-row-check" })
|
|
81795
|
+
] }),
|
|
81796
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Typography.Text, { type: "secondary", className: "describo-add-property-row-help", children: item.help })
|
|
81797
|
+
] })
|
|
81798
|
+
},
|
|
81799
|
+
`${item.name}-${idx}`
|
|
81800
|
+
);
|
|
81801
|
+
})
|
|
81720
81802
|
] }) })
|
|
81721
81803
|
}
|
|
81722
81804
|
);
|
|
@@ -106817,7 +106899,7 @@ const RenderControls = ({
|
|
|
106817
106899
|
{
|
|
106818
106900
|
onClick: () => toggle("addProperty"),
|
|
106819
106901
|
type: "primary",
|
|
106820
|
-
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$
|
|
106902
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$n, {}),
|
|
106821
106903
|
children: t2("add_label")
|
|
106822
106904
|
}
|
|
106823
106905
|
),
|
|
@@ -110617,8 +110699,56 @@ xe.displayName = "Allotment";
|
|
|
110617
110699
|
var Ve = Object.assign(xe, {
|
|
110618
110700
|
Pane: Ie
|
|
110619
110701
|
});
|
|
110702
|
+
const getProfileTabKey = (tab) => String((tab == null ? void 0 : tab.profileUrl) || (tab == null ? void 0 : tab.name) || "");
|
|
110703
|
+
const isProfileTab = (tab) => {
|
|
110704
|
+
const name2 = String((tab == null ? void 0 : tab.name) || "").toLowerCase();
|
|
110705
|
+
const label = String((tab == null ? void 0 : tab.label) || (tab == null ? void 0 : tab.name) || "").toLowerCase();
|
|
110706
|
+
return !["about", "overflow", "other"].includes(name2) && !["about", "other"].includes(label);
|
|
110707
|
+
};
|
|
110708
|
+
const findAddedProfileTab = (tabs, previousTabKeys) => {
|
|
110709
|
+
const profileTabs = tabs.filter(isProfileTab);
|
|
110710
|
+
return profileTabs.find((tab) => !previousTabKeys.has(getProfileTabKey(tab))) ?? profileTabs[profileTabs.length - 1];
|
|
110711
|
+
};
|
|
110712
|
+
const findTabForProperty = (tabs, property) => tabs.find((tab) => {
|
|
110713
|
+
var _a2;
|
|
110714
|
+
return (_a2 = tab == null ? void 0 : tab.inputs) == null ? void 0 : _a2.some((input) => (input == null ? void 0 : input.name) === property);
|
|
110715
|
+
}) ?? tabs.find((tab) => ["overflow", "other"].includes(String((tab == null ? void 0 : tab.name) || "").toLowerCase()));
|
|
110716
|
+
const getPendingAddedProfileStorageKey = (entityId) => `recrate.pending-added-profile-tab.${entityId}`;
|
|
110717
|
+
const readPendingAddedProfileTabKeys = (entityId) => {
|
|
110718
|
+
if (typeof window === "undefined") return null;
|
|
110719
|
+
try {
|
|
110720
|
+
const raw = window.sessionStorage.getItem(getPendingAddedProfileStorageKey(entityId));
|
|
110721
|
+
if (!raw) return null;
|
|
110722
|
+
const parsed = JSON.parse(raw);
|
|
110723
|
+
const requestedAt = Number(parsed == null ? void 0 : parsed.requestedAt) || 0;
|
|
110724
|
+
if (requestedAt && Date.now() - requestedAt > 10 * 60 * 1e3) {
|
|
110725
|
+
clearPendingAddedProfileTabKeys(entityId);
|
|
110726
|
+
return null;
|
|
110727
|
+
}
|
|
110728
|
+
return Array.isArray(parsed == null ? void 0 : parsed.tabKeys) ? parsed.tabKeys : null;
|
|
110729
|
+
} catch {
|
|
110730
|
+
return null;
|
|
110731
|
+
}
|
|
110732
|
+
};
|
|
110733
|
+
const writePendingAddedProfileTabKeys = (entityId, tabKeys) => {
|
|
110734
|
+
if (typeof window === "undefined") return;
|
|
110735
|
+
try {
|
|
110736
|
+
window.sessionStorage.setItem(
|
|
110737
|
+
getPendingAddedProfileStorageKey(entityId),
|
|
110738
|
+
JSON.stringify({ tabKeys, requestedAt: Date.now() })
|
|
110739
|
+
);
|
|
110740
|
+
} catch {
|
|
110741
|
+
}
|
|
110742
|
+
};
|
|
110743
|
+
const clearPendingAddedProfileTabKeys = (entityId) => {
|
|
110744
|
+
if (typeof window === "undefined") return;
|
|
110745
|
+
try {
|
|
110746
|
+
window.sessionStorage.removeItem(getPendingAddedProfileStorageKey(entityId));
|
|
110747
|
+
} catch {
|
|
110748
|
+
}
|
|
110749
|
+
};
|
|
110620
110750
|
const RenderEntity = forwardRef((props, ref) => {
|
|
110621
|
-
var _a2, _b, _c, _d, _e2, _f, _g, _h, _i, _j, _k
|
|
110751
|
+
var _a2, _b, _c, _d, _e2, _f, _g, _h, _i, _j, _k;
|
|
110622
110752
|
const { entity, onLoadEntity, onSaveCrate, onSaveEntityTemplate, onWarning, onError, onAddNewProfileRequest, onRemoveProfile } = props;
|
|
110623
110753
|
const state = useStateStore();
|
|
110624
110754
|
const profileManager = useContext(ProfileManagerContext);
|
|
@@ -110643,7 +110773,7 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110643
110773
|
}, []);
|
|
110644
110774
|
const [tabPaneWidth, setTabPaneWidth] = useState(initialTabPaneWidth);
|
|
110645
110775
|
const persistTabWidth = useMemo$1(() => debounce((w2) => {
|
|
110646
|
-
const minClamp = iconView ?
|
|
110776
|
+
const minClamp = iconView ? 80 : 100;
|
|
110647
110777
|
const maxClamp = 250;
|
|
110648
110778
|
const clamped = Math.max(minClamp, Math.min(maxClamp, Math.round(w2)));
|
|
110649
110779
|
localStorage.setItem("recrate.verticalTabWidth", String(clamped));
|
|
@@ -110652,18 +110782,32 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110652
110782
|
const [scrollRestoreNonce, setScrollRestoreNonce] = useState(0);
|
|
110653
110783
|
const contentContainerRef = useRef(null);
|
|
110654
110784
|
const activeContentRef = useRef(null);
|
|
110785
|
+
const tabRailListRef = useRef(null);
|
|
110655
110786
|
const editorPanelRef = useRef(null);
|
|
110656
110787
|
const navigationRestoreReadyRef = useRef(false);
|
|
110657
110788
|
const pendingRestoredTabRef = useRef(null);
|
|
110789
|
+
const restoreInProgressRef = useRef(false);
|
|
110790
|
+
const pendingAddedProfileSelectionRef = useRef(null);
|
|
110791
|
+
const pendingAddedPropertyRef = useRef(null);
|
|
110792
|
+
const [tabRailScrollState, setTabRailScrollState] = useState({ canScrollUp: false, canScrollDown: false });
|
|
110793
|
+
const debugScroll = (...args) => console.log("[recrate-scroll-debug]", ...args);
|
|
110658
110794
|
const getVisibleContextMarkers = (selector, dataAttribute) => {
|
|
110659
110795
|
const source = activeContentRef.current;
|
|
110660
110796
|
if (!source) return [];
|
|
110661
110797
|
return Array.from(source.querySelectorAll(selector)).map((node2) => node2.getAttribute(dataAttribute)).filter((value) => Boolean(value));
|
|
110662
110798
|
};
|
|
110663
110799
|
const captureViewContext = (tabName = activeTab, explicitScrollTop) => {
|
|
110664
|
-
var _a3, _b2, _c2, _d2;
|
|
110800
|
+
var _a3, _b2, _c2, _d2, _e3, _f2, _g2, _h2;
|
|
110665
110801
|
const entityId = contextEntity == null ? void 0 : contextEntity["@id"];
|
|
110666
|
-
if (!entityId
|
|
110802
|
+
if (!entityId) return;
|
|
110803
|
+
if (restoreInProgressRef.current && typeof explicitScrollTop !== "number") {
|
|
110804
|
+
debugScroll("capture.skipped-during-restore", {
|
|
110805
|
+
entityId,
|
|
110806
|
+
tabName,
|
|
110807
|
+
latestId: (_a3 = state.editorState.latest()) == null ? void 0 : _a3.id
|
|
110808
|
+
});
|
|
110809
|
+
return;
|
|
110810
|
+
}
|
|
110667
110811
|
const previous = state.editorState.getNavigationState(entityId) ?? {};
|
|
110668
110812
|
const scrollTop = typeof explicitScrollTop === "number" ? explicitScrollTop : ((_b2 = activeContentRef.current) == null ? void 0 : _b2.scrollTop) ?? ((_d2 = (_c2 = previous.tabStates) == null ? void 0 : _c2[tabName]) == null ? void 0 : _d2.scrollTop) ?? 0;
|
|
110669
110813
|
const nextTabState = {
|
|
@@ -110671,7 +110815,20 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110671
110815
|
expandedSections: getVisibleContextMarkers('[aria-expanded="true"],[data-expanded="true"]', "data-section-id"),
|
|
110672
110816
|
selectedItems: getVisibleContextMarkers('[aria-selected="true"],[data-selected="true"]', "data-item-id")
|
|
110673
110817
|
};
|
|
110674
|
-
|
|
110818
|
+
debugScroll("capture", {
|
|
110819
|
+
entityId,
|
|
110820
|
+
tabName,
|
|
110821
|
+
latestId: (_e3 = state.editorState.latest()) == null ? void 0 : _e3.id,
|
|
110822
|
+
explicitScrollTop,
|
|
110823
|
+
scrollTop,
|
|
110824
|
+
previousScrollTop: ((_g2 = (_f2 = previous.tabStates) == null ? void 0 : _f2[tabName]) == null ? void 0 : _g2.scrollTop) ?? null,
|
|
110825
|
+
viewport: activeContentRef.current ? {
|
|
110826
|
+
clientHeight: activeContentRef.current.clientHeight,
|
|
110827
|
+
scrollHeight: activeContentRef.current.scrollHeight,
|
|
110828
|
+
currentScrollTop: activeContentRef.current.scrollTop
|
|
110829
|
+
} : null
|
|
110830
|
+
});
|
|
110831
|
+
const navigationState = {
|
|
110675
110832
|
activeTab: tabName,
|
|
110676
110833
|
tabStates: { [tabName]: nextTabState },
|
|
110677
110834
|
uiState: {
|
|
@@ -110681,7 +110838,12 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110681
110838
|
iconView,
|
|
110682
110839
|
tabPaneWidth
|
|
110683
110840
|
}
|
|
110684
|
-
}
|
|
110841
|
+
};
|
|
110842
|
+
if (((_h2 = state.editorState.latest()) == null ? void 0 : _h2.id) === entityId) {
|
|
110843
|
+
state.editorState.updateNavigationState(navigationState);
|
|
110844
|
+
} else {
|
|
110845
|
+
state.editorState.updateNavigationStateForId(entityId, navigationState);
|
|
110846
|
+
}
|
|
110685
110847
|
};
|
|
110686
110848
|
const computeScrollViewportHeight = useMemo$1(() => debounce(() => {
|
|
110687
110849
|
var _a3, _b2;
|
|
@@ -110728,6 +110890,33 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110728
110890
|
window.clearTimeout(delayedMeasure);
|
|
110729
110891
|
};
|
|
110730
110892
|
}, [computeScrollViewportHeight, activeTab, renderTabs, tabs.length, contextEntity == null ? void 0 : contextEntity["@id"], reverseSidebarVisible]);
|
|
110893
|
+
const updateTabRailScrollState = () => {
|
|
110894
|
+
const list = tabRailListRef.current;
|
|
110895
|
+
if (!list) {
|
|
110896
|
+
setTabRailScrollState({ canScrollUp: false, canScrollDown: false });
|
|
110897
|
+
return;
|
|
110898
|
+
}
|
|
110899
|
+
const maxScrollTop = Math.max(0, list.scrollHeight - list.clientHeight);
|
|
110900
|
+
const nextState = {
|
|
110901
|
+
canScrollUp: list.scrollTop > 2,
|
|
110902
|
+
canScrollDown: list.scrollTop < maxScrollTop - 2
|
|
110903
|
+
};
|
|
110904
|
+
setTabRailScrollState((previousState) => previousState.canScrollUp === nextState.canScrollUp && previousState.canScrollDown === nextState.canScrollDown ? previousState : nextState);
|
|
110905
|
+
};
|
|
110906
|
+
useEffect(() => {
|
|
110907
|
+
const list = tabRailListRef.current;
|
|
110908
|
+
if (!list || !renderTabs) return;
|
|
110909
|
+
const activeTabElement = list.querySelector('[aria-selected="true"]');
|
|
110910
|
+
activeTabElement == null ? void 0 : activeTabElement.scrollIntoView({ block: "nearest" });
|
|
110911
|
+
updateTabRailScrollState();
|
|
110912
|
+
const resizeObserver2 = new ResizeObserver(updateTabRailScrollState);
|
|
110913
|
+
resizeObserver2.observe(list);
|
|
110914
|
+
const frame = requestAnimationFrame(updateTabRailScrollState);
|
|
110915
|
+
return () => {
|
|
110916
|
+
resizeObserver2.disconnect();
|
|
110917
|
+
cancelAnimationFrame(frame);
|
|
110918
|
+
};
|
|
110919
|
+
}, [activeTab, iconView, renderTabs, scrollViewportHeight, tabPaneWidth, tabs.length]);
|
|
110731
110920
|
useImperativeHandle(ref, () => ({
|
|
110732
110921
|
setTab: (tabName) => {
|
|
110733
110922
|
setActiveTab(tabName);
|
|
@@ -110737,7 +110926,14 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110737
110926
|
}
|
|
110738
110927
|
}));
|
|
110739
110928
|
useEffect(() => {
|
|
110929
|
+
var _a3, _b2;
|
|
110740
110930
|
navigationRestoreReadyRef.current = false;
|
|
110931
|
+
if (((_a3 = pendingAddedProfileSelectionRef.current) == null ? void 0 : _a3.entityId) !== (entity == null ? void 0 : entity["@id"])) {
|
|
110932
|
+
pendingAddedProfileSelectionRef.current = null;
|
|
110933
|
+
}
|
|
110934
|
+
if (((_b2 = pendingAddedPropertyRef.current) == null ? void 0 : _b2.entityId) !== (entity == null ? void 0 : entity["@id"])) {
|
|
110935
|
+
pendingAddedPropertyRef.current = null;
|
|
110936
|
+
}
|
|
110741
110937
|
if ((contextEntity == null ? void 0 : contextEntity["@id"]) && (entity == null ? void 0 : entity["@id"]) && contextEntity["@id"] !== entity["@id"]) {
|
|
110742
110938
|
captureViewContext(activeTab);
|
|
110743
110939
|
}
|
|
@@ -110750,8 +110946,8 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110750
110946
|
init2({ entity: entityObj });
|
|
110751
110947
|
}
|
|
110752
110948
|
}, [profileManager == null ? void 0 : profileManager.$key]);
|
|
110753
|
-
const init2 = ({ entity: entity2 }) => {
|
|
110754
|
-
var _a3, _b2, _c2, _d2, _e3;
|
|
110949
|
+
const init2 = ({ entity: entity2, extraPropertiesOverride }) => {
|
|
110950
|
+
var _a3, _b2, _c2, _d2, _e3, _f2;
|
|
110755
110951
|
if (!entity2["@id"]) return;
|
|
110756
110952
|
const latestEntry = state.editorState.latest();
|
|
110757
110953
|
const isCurrentHistoryEntity = (latestEntry == null ? void 0 : latestEntry.id) === entity2["@id"];
|
|
@@ -110759,7 +110955,7 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110759
110955
|
configuration: state.configuration,
|
|
110760
110956
|
profileManager,
|
|
110761
110957
|
entity: entity2,
|
|
110762
|
-
extraProperties
|
|
110958
|
+
extraProperties: extraPropertiesOverride ?? extraProperties
|
|
110763
110959
|
});
|
|
110764
110960
|
setContextEntity(layout.entity);
|
|
110765
110961
|
setRenderTabs(layout.renderTabs);
|
|
@@ -110769,19 +110965,79 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110769
110965
|
const tabNames = layout.tabs.map((tab) => tab.name);
|
|
110770
110966
|
const fallbackTab = tabNames.includes("about") ? "about" : tabNames[0] ?? "about";
|
|
110771
110967
|
const restoredTab = layout.renderTabs && (navState == null ? void 0 : navState.activeTab) && tabNames.includes(navState.activeTab) ? navState.activeTab : fallbackTab;
|
|
110772
|
-
|
|
110773
|
-
|
|
110774
|
-
|
|
110775
|
-
if (
|
|
110776
|
-
|
|
110777
|
-
|
|
110778
|
-
|
|
110968
|
+
const pendingAddedProfileSelection = pendingAddedProfileSelectionRef.current;
|
|
110969
|
+
const pendingAddedProfileTabKeys = Array.isArray((_a3 = navState == null ? void 0 : navState.uiState) == null ? void 0 : _a3.pendingAddedProfileTabKeys) ? navState.uiState.pendingAddedProfileTabKeys : readPendingAddedProfileTabKeys(entity2["@id"]);
|
|
110970
|
+
let nextActiveTab = restoredTab;
|
|
110971
|
+
if (layout.renderTabs && pendingAddedProfileSelection && pendingAddedProfileSelection.entityId === entity2["@id"]) {
|
|
110972
|
+
const previousTabKeys = new Set(pendingAddedProfileSelection.tabKeys);
|
|
110973
|
+
const addedProfileTab = findAddedProfileTab(layout.tabs, previousTabKeys);
|
|
110974
|
+
if (addedProfileTab == null ? void 0 : addedProfileTab.name) {
|
|
110975
|
+
nextActiveTab = addedProfileTab.name;
|
|
110976
|
+
pendingAddedProfileSelectionRef.current = null;
|
|
110977
|
+
clearPendingAddedProfileTabKeys(entity2["@id"]);
|
|
110978
|
+
}
|
|
110979
|
+
}
|
|
110980
|
+
if (layout.renderTabs && pendingAddedProfileTabKeys) {
|
|
110981
|
+
const previousTabKeys = new Set(pendingAddedProfileTabKeys);
|
|
110982
|
+
const addedProfileTab = findAddedProfileTab(layout.tabs, previousTabKeys);
|
|
110983
|
+
if (addedProfileTab == null ? void 0 : addedProfileTab.name) {
|
|
110984
|
+
nextActiveTab = addedProfileTab.name;
|
|
110985
|
+
pendingAddedProfileSelectionRef.current = null;
|
|
110986
|
+
clearPendingAddedProfileTabKeys(entity2["@id"]);
|
|
110987
|
+
const clearPendingSelection = {
|
|
110988
|
+
uiState: {
|
|
110989
|
+
pendingAddedProfileTabKeys: void 0,
|
|
110990
|
+
pendingAddedProfileRequestedAt: void 0
|
|
110991
|
+
}
|
|
110992
|
+
};
|
|
110993
|
+
if (isCurrentHistoryEntity) {
|
|
110994
|
+
state.editorState.updateNavigationState(clearPendingSelection);
|
|
110995
|
+
} else {
|
|
110996
|
+
state.editorState.updateNavigationStateForId(entity2["@id"], clearPendingSelection);
|
|
110997
|
+
}
|
|
110998
|
+
}
|
|
110999
|
+
}
|
|
111000
|
+
const pendingAddedProperty = pendingAddedPropertyRef.current;
|
|
111001
|
+
let willScrollToAddedProperty = false;
|
|
111002
|
+
if (pendingAddedProperty && pendingAddedProperty.entityId === entity2["@id"]) {
|
|
111003
|
+
const propertyTab = layout.renderTabs ? findTabForProperty(layout.tabs, pendingAddedProperty.property) : null;
|
|
111004
|
+
if (propertyTab == null ? void 0 : propertyTab.name) {
|
|
111005
|
+
nextActiveTab = propertyTab.name;
|
|
111006
|
+
pendingAddedPropertyRef.current = {
|
|
111007
|
+
...pendingAddedProperty,
|
|
111008
|
+
tabName: propertyTab.name
|
|
111009
|
+
};
|
|
111010
|
+
willScrollToAddedProperty = true;
|
|
111011
|
+
} else if (!layout.renderTabs) {
|
|
111012
|
+
willScrollToAddedProperty = true;
|
|
111013
|
+
}
|
|
111014
|
+
}
|
|
111015
|
+
debugScroll("init", {
|
|
111016
|
+
entityId: entity2["@id"],
|
|
111017
|
+
latestId: latestEntry == null ? void 0 : latestEntry.id,
|
|
111018
|
+
isCurrentHistoryEntity,
|
|
111019
|
+
renderTabs: layout.renderTabs,
|
|
111020
|
+
tabNames,
|
|
111021
|
+
restoredTab,
|
|
111022
|
+
nextActiveTab,
|
|
111023
|
+
navState
|
|
111024
|
+
});
|
|
111025
|
+
pendingRestoredTabRef.current = willScrollToAddedProperty ? null : nextActiveTab;
|
|
111026
|
+
setActiveTab(nextActiveTab);
|
|
111027
|
+
if (typeof ((_b2 = navState == null ? void 0 : navState.uiState) == null ? void 0 : _b2.showAddPanel) === "boolean") setShowAddPanel(navState.uiState.showAddPanel);
|
|
111028
|
+
if (typeof ((_c2 = navState == null ? void 0 : navState.uiState) == null ? void 0 : _c2.reverseSidebarVisible) === "boolean") setReverseSidebarVisible(navState.uiState.reverseSidebarVisible);
|
|
111029
|
+
if (typeof ((_d2 = navState == null ? void 0 : navState.uiState) == null ? void 0 : _d2.highlightRequiredProperties) === "boolean") setHighlightRequiredProperties(navState.uiState.highlightRequiredProperties);
|
|
111030
|
+
if (typeof ((_e3 = navState == null ? void 0 : navState.uiState) == null ? void 0 : _e3.iconView) === "boolean") setIconView(navState.uiState.iconView);
|
|
111031
|
+
if (typeof ((_f2 = navState == null ? void 0 : navState.uiState) == null ? void 0 : _f2.tabPaneWidth) === "number") setTabPaneWidth(navState.uiState.tabPaneWidth);
|
|
110779
111032
|
if (isCurrentHistoryEntity) {
|
|
110780
111033
|
if (layout.renderTabs) {
|
|
110781
|
-
state.editorState.update({ id: entity2["@id"], tab:
|
|
111034
|
+
state.editorState.update({ id: entity2["@id"], tab: nextActiveTab });
|
|
111035
|
+
state.editorState.updateNavigationState({ activeTab: nextActiveTab });
|
|
110782
111036
|
} else {
|
|
110783
111037
|
state.editorState.deleteFromState({ property: "tab" });
|
|
110784
111038
|
}
|
|
111039
|
+
} else if (layout.renderTabs) {
|
|
111040
|
+
state.editorState.updateNavigationStateForId(entity2["@id"], { activeTab: nextActiveTab });
|
|
110785
111041
|
}
|
|
110786
111042
|
};
|
|
110787
111043
|
const refresh = () => {
|
|
@@ -110789,6 +111045,11 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110789
111045
|
init2({ entity: entityObj });
|
|
110790
111046
|
};
|
|
110791
111047
|
const handleLoadEntityWithContext = (params) => {
|
|
111048
|
+
debugScroll("navigate", {
|
|
111049
|
+
fromEntityId: contextEntity == null ? void 0 : contextEntity["@id"],
|
|
111050
|
+
activeTab,
|
|
111051
|
+
params
|
|
111052
|
+
});
|
|
110792
111053
|
captureViewContext(activeTab);
|
|
110793
111054
|
onLoadEntity(params);
|
|
110794
111055
|
};
|
|
@@ -110808,25 +111069,65 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110808
111069
|
}
|
|
110809
111070
|
}, [extraProperties]);
|
|
110810
111071
|
useEffect(() => {
|
|
110811
|
-
var _a3, _b2, _c2;
|
|
111072
|
+
var _a3, _b2, _c2, _d2;
|
|
110812
111073
|
if (!navigationRestoreReadyRef.current) return;
|
|
110813
111074
|
if (!(contextEntity == null ? void 0 : contextEntity["@id"])) return;
|
|
111075
|
+
if (((_a3 = pendingAddedPropertyRef.current) == null ? void 0 : _a3.entityId) === contextEntity["@id"]) return;
|
|
110814
111076
|
const viewport = activeContentRef.current;
|
|
110815
111077
|
if (!viewport) return;
|
|
110816
|
-
const restoreTarget = ((
|
|
111078
|
+
const restoreTarget = ((_d2 = (_c2 = (_b2 = state.editorState.getNavigationState(contextEntity["@id"])) == null ? void 0 : _b2.tabStates) == null ? void 0 : _c2[activeTab]) == null ? void 0 : _d2.scrollTop) ?? 0;
|
|
111079
|
+
debugScroll("restore.start", {
|
|
111080
|
+
entityId: contextEntity["@id"],
|
|
111081
|
+
activeTab,
|
|
111082
|
+
restoreTarget,
|
|
111083
|
+
viewport: {
|
|
111084
|
+
clientHeight: viewport.clientHeight,
|
|
111085
|
+
scrollHeight: viewport.scrollHeight,
|
|
111086
|
+
scrollTop: viewport.scrollTop
|
|
111087
|
+
}
|
|
111088
|
+
});
|
|
110817
111089
|
let cancelled = false;
|
|
110818
111090
|
let rafId = 0;
|
|
110819
111091
|
let timerId = 0;
|
|
110820
111092
|
let attempts = 0;
|
|
110821
|
-
const maxAttempts =
|
|
111093
|
+
const maxAttempts = 40;
|
|
111094
|
+
const previousInlineScrollBehavior = viewport.style.scrollBehavior;
|
|
111095
|
+
restoreInProgressRef.current = true;
|
|
111096
|
+
viewport.style.scrollBehavior = "auto";
|
|
110822
111097
|
const attemptRestore = () => {
|
|
110823
111098
|
if (cancelled) return;
|
|
110824
111099
|
attempts += 1;
|
|
110825
111100
|
const maxScrollable = Math.max(0, viewport.scrollHeight - viewport.clientHeight);
|
|
110826
111101
|
const target = Math.min(restoreTarget, maxScrollable);
|
|
110827
|
-
viewport.
|
|
110828
|
-
const
|
|
111102
|
+
viewport.scrollTo({ top: target, behavior: "auto" });
|
|
111103
|
+
const contentReady = restoreTarget <= maxScrollable || restoreTarget === 0;
|
|
111104
|
+
const done = contentReady && Math.abs(viewport.scrollTop - target) <= 1;
|
|
111105
|
+
debugScroll("restore.attempt", {
|
|
111106
|
+
entityId: contextEntity["@id"],
|
|
111107
|
+
activeTab,
|
|
111108
|
+
attempts,
|
|
111109
|
+
restoreTarget,
|
|
111110
|
+
maxScrollable,
|
|
111111
|
+
target,
|
|
111112
|
+
actualScrollTop: viewport.scrollTop,
|
|
111113
|
+
clientHeight: viewport.clientHeight,
|
|
111114
|
+
scrollHeight: viewport.scrollHeight,
|
|
111115
|
+
contentReady,
|
|
111116
|
+
done
|
|
111117
|
+
});
|
|
110829
111118
|
if (done || attempts >= maxAttempts) {
|
|
111119
|
+
restoreInProgressRef.current = false;
|
|
111120
|
+
viewport.style.scrollBehavior = previousInlineScrollBehavior;
|
|
111121
|
+
debugScroll("restore.stop", {
|
|
111122
|
+
entityId: contextEntity["@id"],
|
|
111123
|
+
activeTab,
|
|
111124
|
+
attempts,
|
|
111125
|
+
restoreTarget,
|
|
111126
|
+
finalScrollTop: viewport.scrollTop,
|
|
111127
|
+
maxScrollable,
|
|
111128
|
+
contentReady,
|
|
111129
|
+
done
|
|
111130
|
+
});
|
|
110830
111131
|
return;
|
|
110831
111132
|
}
|
|
110832
111133
|
timerId = window.setTimeout(() => {
|
|
@@ -110838,6 +111139,8 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110838
111139
|
viewport.addEventListener("scroll", handleScroll, { passive: true });
|
|
110839
111140
|
return () => {
|
|
110840
111141
|
cancelled = true;
|
|
111142
|
+
restoreInProgressRef.current = false;
|
|
111143
|
+
viewport.style.scrollBehavior = previousInlineScrollBehavior;
|
|
110841
111144
|
if (navigationRestoreReadyRef.current) {
|
|
110842
111145
|
captureViewContext(activeTab, viewport.scrollTop);
|
|
110843
111146
|
}
|
|
@@ -110847,13 +111150,21 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110847
111150
|
};
|
|
110848
111151
|
}, [activeTab, contextEntity == null ? void 0 : contextEntity["@id"], renderTabs, tabs.length, scrollRestoreNonce]);
|
|
110849
111152
|
useEffect(() => {
|
|
111153
|
+
var _a3;
|
|
110850
111154
|
const pendingTab = pendingRestoredTabRef.current;
|
|
110851
111155
|
if (!(contextEntity == null ? void 0 : contextEntity["@id"])) return;
|
|
111156
|
+
if (((_a3 = pendingAddedPropertyRef.current) == null ? void 0 : _a3.entityId) === contextEntity["@id"]) return;
|
|
110852
111157
|
if (pendingTab) {
|
|
111158
|
+
debugScroll("restore.pending-tab", {
|
|
111159
|
+
entityId: contextEntity["@id"],
|
|
111160
|
+
pendingTab,
|
|
111161
|
+
activeTab
|
|
111162
|
+
});
|
|
110853
111163
|
if (activeTab !== pendingTab) {
|
|
110854
111164
|
return;
|
|
110855
111165
|
}
|
|
110856
111166
|
navigationRestoreReadyRef.current = true;
|
|
111167
|
+
restoreInProgressRef.current = true;
|
|
110857
111168
|
pendingRestoredTabRef.current = null;
|
|
110858
111169
|
setScrollRestoreNonce((prev2) => prev2 + 1);
|
|
110859
111170
|
return;
|
|
@@ -110861,18 +111172,112 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
110861
111172
|
if (!navigationRestoreReadyRef.current) return;
|
|
110862
111173
|
captureViewContext(activeTab);
|
|
110863
111174
|
}, [activeTab, showAddPanel, reverseSidebarVisible, highlightRequiredProperties, iconView, tabPaneWidth, contextEntity == null ? void 0 : contextEntity["@id"]]);
|
|
111175
|
+
useEffect(() => {
|
|
111176
|
+
const pendingAddedProperty = pendingAddedPropertyRef.current;
|
|
111177
|
+
if (!pendingAddedProperty || pendingAddedProperty.entityId !== (contextEntity == null ? void 0 : contextEntity["@id"])) return;
|
|
111178
|
+
if (pendingAddedProperty.tabName && pendingAddedProperty.tabName !== activeTab) return;
|
|
111179
|
+
let cancelled = false;
|
|
111180
|
+
let attempts = 0;
|
|
111181
|
+
let timerId = 0;
|
|
111182
|
+
let rafId = 0;
|
|
111183
|
+
const maxAttempts = 30;
|
|
111184
|
+
const finishAddedPropertyScroll = (viewport) => {
|
|
111185
|
+
navigationRestoreReadyRef.current = true;
|
|
111186
|
+
pendingAddedPropertyRef.current = null;
|
|
111187
|
+
captureViewContext(activeTab, viewport == null ? void 0 : viewport.scrollTop);
|
|
111188
|
+
setScrollRestoreNonce((prev2) => prev2 + 1);
|
|
111189
|
+
};
|
|
111190
|
+
const scheduleRetry = () => {
|
|
111191
|
+
if (attempts < maxAttempts) {
|
|
111192
|
+
timerId = window.setTimeout(() => {
|
|
111193
|
+
rafId = window.requestAnimationFrame(scrollToAddedProperty);
|
|
111194
|
+
}, 50);
|
|
111195
|
+
return;
|
|
111196
|
+
}
|
|
111197
|
+
finishAddedPropertyScroll(activeContentRef.current);
|
|
111198
|
+
};
|
|
111199
|
+
const scrollToAddedProperty = () => {
|
|
111200
|
+
var _a3;
|
|
111201
|
+
if (cancelled) return;
|
|
111202
|
+
attempts += 1;
|
|
111203
|
+
const propertyElement = Array.from(
|
|
111204
|
+
((_a3 = activeContentRef.current) == null ? void 0 : _a3.querySelectorAll("[data-recrate-property]")) ?? []
|
|
111205
|
+
).find((element) => element.dataset.recrateProperty === pendingAddedProperty.property);
|
|
111206
|
+
if (propertyElement) {
|
|
111207
|
+
const viewport = activeContentRef.current;
|
|
111208
|
+
const viewportRect = viewport == null ? void 0 : viewport.getBoundingClientRect();
|
|
111209
|
+
const propertyRect = propertyElement.getBoundingClientRect();
|
|
111210
|
+
if (viewport && viewportRect) {
|
|
111211
|
+
const targetTop = viewport.scrollTop + propertyRect.top - viewportRect.top;
|
|
111212
|
+
const maxScrollable = Math.max(0, viewport.scrollHeight - viewport.clientHeight);
|
|
111213
|
+
const target = Math.max(0, Math.min(targetTop, maxScrollable));
|
|
111214
|
+
viewport.scrollTo({ top: target, behavior: "auto" });
|
|
111215
|
+
rafId = window.requestAnimationFrame(() => {
|
|
111216
|
+
if (cancelled) return;
|
|
111217
|
+
const nextViewportRect = viewport.getBoundingClientRect();
|
|
111218
|
+
const nextPropertyRect = propertyElement.getBoundingClientRect();
|
|
111219
|
+
const nextMaxScrollable = Math.max(0, viewport.scrollHeight - viewport.clientHeight);
|
|
111220
|
+
const expectedTop = Math.max(0, Math.min(targetTop, nextMaxScrollable));
|
|
111221
|
+
const targetReachable = targetTop <= nextMaxScrollable + 2;
|
|
111222
|
+
const propertyTopVisible = nextPropertyRect.top >= nextViewportRect.top - 2 && nextPropertyRect.top <= nextViewportRect.bottom - 24;
|
|
111223
|
+
const reachedExpectedTop = Math.abs(viewport.scrollTop - expectedTop) <= 2;
|
|
111224
|
+
if (propertyTopVisible || targetReachable && reachedExpectedTop) {
|
|
111225
|
+
finishAddedPropertyScroll(viewport);
|
|
111226
|
+
return;
|
|
111227
|
+
}
|
|
111228
|
+
scheduleRetry();
|
|
111229
|
+
});
|
|
111230
|
+
return;
|
|
111231
|
+
} else {
|
|
111232
|
+
propertyElement.scrollIntoView({ block: "start", behavior: "auto" });
|
|
111233
|
+
finishAddedPropertyScroll();
|
|
111234
|
+
return;
|
|
111235
|
+
}
|
|
111236
|
+
}
|
|
111237
|
+
scheduleRetry();
|
|
111238
|
+
};
|
|
111239
|
+
rafId = requestAnimationFrame(scrollToAddedProperty);
|
|
111240
|
+
return () => {
|
|
111241
|
+
cancelled = true;
|
|
111242
|
+
window.cancelAnimationFrame(rafId);
|
|
111243
|
+
window.clearTimeout(timerId);
|
|
111244
|
+
};
|
|
111245
|
+
}, [activeTab, contextEntity == null ? void 0 : contextEntity["@id"], tabs.length, extraProperties.length]);
|
|
110864
111246
|
const handleAddPropertyPlaceholder = (property) => {
|
|
110865
111247
|
try {
|
|
111248
|
+
pendingAddedPropertyRef.current = {
|
|
111249
|
+
entityId: entity["@id"],
|
|
111250
|
+
property
|
|
111251
|
+
};
|
|
110866
111252
|
const newExtraProperties = [...extraProperties, property];
|
|
110867
111253
|
setExtraProperties(newExtraProperties);
|
|
111254
|
+
init2({ entity: contextEntity, extraPropertiesOverride: newExtraProperties });
|
|
110868
111255
|
} catch (error2) {
|
|
110869
111256
|
console.error(error2);
|
|
110870
111257
|
onError();
|
|
110871
111258
|
}
|
|
110872
111259
|
};
|
|
110873
111260
|
const handleAddNewProfile = () => {
|
|
111261
|
+
var _a3;
|
|
110874
111262
|
try {
|
|
110875
111263
|
const next2 = !showAddPanel;
|
|
111264
|
+
const currentProfileTabKeys = tabs.filter(isProfileTab).map(getProfileTabKey).filter(Boolean);
|
|
111265
|
+
pendingAddedProfileSelectionRef.current = {
|
|
111266
|
+
entityId: entity["@id"],
|
|
111267
|
+
tabKeys: currentProfileTabKeys
|
|
111268
|
+
};
|
|
111269
|
+
writePendingAddedProfileTabKeys(entity["@id"], currentProfileTabKeys);
|
|
111270
|
+
const pendingSelectionState = {
|
|
111271
|
+
uiState: {
|
|
111272
|
+
pendingAddedProfileTabKeys: currentProfileTabKeys,
|
|
111273
|
+
pendingAddedProfileRequestedAt: Date.now()
|
|
111274
|
+
}
|
|
111275
|
+
};
|
|
111276
|
+
if (((_a3 = state.editorState.latest()) == null ? void 0 : _a3.id) === entity["@id"]) {
|
|
111277
|
+
state.editorState.updateNavigationState(pendingSelectionState);
|
|
111278
|
+
} else {
|
|
111279
|
+
state.editorState.updateNavigationStateForId(entity["@id"], pendingSelectionState);
|
|
111280
|
+
}
|
|
110876
111281
|
setShowAddPanel(next2);
|
|
110877
111282
|
onAddNewProfileRequest == null ? void 0 : onAddNewProfileRequest(true);
|
|
110878
111283
|
} catch (error2) {
|
|
@@ -111037,57 +111442,20 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111037
111442
|
const toggleIconView = () => {
|
|
111038
111443
|
if (!iconView) {
|
|
111039
111444
|
setIconView(true);
|
|
111040
|
-
setTabPaneWidth(
|
|
111041
|
-
localStorage.setItem("recrate.verticalTabWidth", "
|
|
111445
|
+
setTabPaneWidth(80);
|
|
111446
|
+
localStorage.setItem("recrate.verticalTabWidth", "80");
|
|
111042
111447
|
} else {
|
|
111043
111448
|
setIconView(false);
|
|
111044
111449
|
setTabPaneWidth(250);
|
|
111045
111450
|
localStorage.setItem("recrate.verticalTabWidth", "250");
|
|
111046
111451
|
}
|
|
111047
111452
|
};
|
|
111048
|
-
const makeTabLabel = (tab, idx) => iconView ? /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "describo-tab-icon", children: (idx ?? 0) + 1 }) : /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col w-full group", onMouseEnter: () => setHoveredTabKey(tab.name), onMouseLeave: () => setHoveredTabKey(null), children: [
|
|
111049
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-row items-center justify-between w-full relative", children: [
|
|
111050
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111051
|
-
"div",
|
|
111052
|
-
{
|
|
111053
|
-
className: "text-left text-base font-medium text-gray-700 describo-tab-label whitespace-normal break-words",
|
|
111054
|
-
style: { maxWidth: "100%" },
|
|
111055
|
-
children: tab.label || tab.name
|
|
111056
|
-
}
|
|
111057
|
-
),
|
|
111058
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "ml-2 flex items-center space-x-2", children: [
|
|
111059
|
-
tab.missingRequiredData && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-red-600", children: /* @__PURE__ */ jsxRuntimeExports.jsx(FontAwesomeIcon, { icon: faCircleXmark, size: "lg" }) }),
|
|
111060
|
-
tab.hasData && !tab.missingRequiredData && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-green-600", children: /* @__PURE__ */ jsxRuntimeExports.jsx(FontAwesomeIcon, { icon: faCircleCheck, size: "lg" }) }),
|
|
111061
|
-
!(["about", "overflow", "other"].includes((tab.name || "").toLowerCase()) || ["about", "other"].includes((tab.label || tab.name || "").toLowerCase())) && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111062
|
-
Button$1,
|
|
111063
|
-
{
|
|
111064
|
-
"aria-label": "Remove profile",
|
|
111065
|
-
type: "text",
|
|
111066
|
-
style: { display: hoveredTabKey === tab.name ? "inline-flex" : "none" },
|
|
111067
|
-
onClick: (e3) => {
|
|
111068
|
-
e3.stopPropagation();
|
|
111069
|
-
handleRemoveProfile(tab);
|
|
111070
|
-
},
|
|
111071
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$d, { style: { color: "oklch(57.7% 0.245 27.325)" } })
|
|
111072
|
-
}
|
|
111073
|
-
)
|
|
111074
|
-
] })
|
|
111075
|
-
] }),
|
|
111076
|
-
tab.description && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111077
|
-
"div",
|
|
111078
|
-
{
|
|
111079
|
-
className: "text-left text-gray-500 font-light text-xs describo-tab-description whitespace-normal break-words",
|
|
111080
|
-
style: { maxWidth: "100%" },
|
|
111081
|
-
children: tab.description
|
|
111082
|
-
}
|
|
111083
|
-
)
|
|
111084
|
-
] });
|
|
111085
111453
|
const addProfileTabLabel = /* @__PURE__ */ jsxRuntimeExports.jsx(Tooltip2, { title: t2("add_profile_button_tooltip"), children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111086
111454
|
Button$1,
|
|
111087
111455
|
{
|
|
111088
111456
|
type: "default",
|
|
111089
111457
|
shape: "circle",
|
|
111090
|
-
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$
|
|
111458
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$n, {}),
|
|
111091
111459
|
"aria-label": "Add Profile",
|
|
111092
111460
|
"aria-controls": "add-property-panel",
|
|
111093
111461
|
"aria-expanded": showAddPanel,
|
|
@@ -111118,11 +111486,146 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111118
111486
|
) }),
|
|
111119
111487
|
className: "ant-tabs-tab-toggle-view"
|
|
111120
111488
|
};
|
|
111121
|
-
const
|
|
111122
|
-
|
|
111123
|
-
|
|
111124
|
-
|
|
111125
|
-
|
|
111489
|
+
const handleSelectTab = (tabName) => {
|
|
111490
|
+
if (tabName === activeTab) return;
|
|
111491
|
+
captureViewContext(activeTab);
|
|
111492
|
+
setActiveTab(tabName);
|
|
111493
|
+
saveTabToState(tabName);
|
|
111494
|
+
};
|
|
111495
|
+
const scrollTabRail = (direction) => {
|
|
111496
|
+
const list = tabRailListRef.current;
|
|
111497
|
+
if (!list) return;
|
|
111498
|
+
const distance = Math.max(120, Math.floor(list.clientHeight * 0.6));
|
|
111499
|
+
list.scrollBy({
|
|
111500
|
+
top: direction === "up" ? -distance : distance,
|
|
111501
|
+
behavior: "smooth"
|
|
111502
|
+
});
|
|
111503
|
+
window.setTimeout(updateTabRailScrollState, 260);
|
|
111504
|
+
};
|
|
111505
|
+
const renderProfileRailActions = () => /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "describo-tab-rail-actions", children: [
|
|
111506
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Tooltip2, { title: iconView ? t2("switch_to_label_view") : t2("switch_to_icon_view"), children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111507
|
+
Button$1,
|
|
111508
|
+
{
|
|
111509
|
+
type: iconView ? "primary" : "default",
|
|
111510
|
+
shape: "circle",
|
|
111511
|
+
icon: iconView ? /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$9, {}) : /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon, {}),
|
|
111512
|
+
"aria-pressed": iconView,
|
|
111513
|
+
onClick: (e3) => {
|
|
111514
|
+
e3.stopPropagation();
|
|
111515
|
+
toggleIconView();
|
|
111516
|
+
}
|
|
111517
|
+
}
|
|
111518
|
+
) }),
|
|
111519
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Tooltip2, { title: t2("add_profile_button_tooltip"), children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111520
|
+
Button$1,
|
|
111521
|
+
{
|
|
111522
|
+
type: "default",
|
|
111523
|
+
shape: "circle",
|
|
111524
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$n, {}),
|
|
111525
|
+
"aria-label": "Add Profile",
|
|
111526
|
+
"aria-controls": "add-property-panel",
|
|
111527
|
+
"aria-expanded": showAddPanel,
|
|
111528
|
+
onClick: handleAddNewProfile
|
|
111529
|
+
}
|
|
111530
|
+
) })
|
|
111531
|
+
] });
|
|
111532
|
+
const renderProfileActionRail = () => /* @__PURE__ */ jsxRuntimeExports.jsx("nav", { className: "describo-tab-rail describo-tab-rail-actions-only", "aria-label": "Profile actions", children: renderProfileRailActions() });
|
|
111533
|
+
const renderProfileTabRail = () => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
111534
|
+
"nav",
|
|
111535
|
+
{
|
|
111536
|
+
className: `describo-tab-rail ${tabRailScrollState.canScrollUp ? "describo-tab-rail-can-scroll-up" : ""} ${tabRailScrollState.canScrollDown ? "describo-tab-rail-can-scroll-down" : ""}`,
|
|
111537
|
+
"aria-label": "Profile sections",
|
|
111538
|
+
children: [
|
|
111539
|
+
renderProfileRailActions(),
|
|
111540
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111541
|
+
"div",
|
|
111542
|
+
{
|
|
111543
|
+
ref: tabRailListRef,
|
|
111544
|
+
className: "describo-tab-rail-list",
|
|
111545
|
+
role: "tablist",
|
|
111546
|
+
"aria-orientation": "vertical",
|
|
111547
|
+
onScroll: updateTabRailScrollState,
|
|
111548
|
+
children: tabs.map((tab, idx) => {
|
|
111549
|
+
const isActive2 = tab.name === activeTab;
|
|
111550
|
+
const canRemove = !(["about", "overflow", "other"].includes((tab.name || "").toLowerCase()) || ["about", "other"].includes((tab.label || tab.name || "").toLowerCase()));
|
|
111551
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111552
|
+
"div",
|
|
111553
|
+
{
|
|
111554
|
+
role: "tab",
|
|
111555
|
+
tabIndex: 0,
|
|
111556
|
+
"aria-selected": isActive2,
|
|
111557
|
+
className: `describo-tab-rail-item ${isActive2 ? "describo-tab-rail-item-active" : ""} ${iconView ? "describo-tab-rail-item-icon" : ""}`,
|
|
111558
|
+
onClick: () => handleSelectTab(tab.name),
|
|
111559
|
+
onKeyDown: (e3) => {
|
|
111560
|
+
if (e3.key === "Enter" || e3.key === " ") {
|
|
111561
|
+
e3.preventDefault();
|
|
111562
|
+
handleSelectTab(tab.name);
|
|
111563
|
+
}
|
|
111564
|
+
},
|
|
111565
|
+
onMouseEnter: () => setHoveredTabKey(tab.name),
|
|
111566
|
+
onMouseLeave: () => setHoveredTabKey(null),
|
|
111567
|
+
children: iconView ? /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "describo-tab-icon", children: idx + 1 }) : /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
111568
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "describo-tab-rail-row", children: [
|
|
111569
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "describo-tab-rail-title", children: tab.label || tab.name }),
|
|
111570
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: "describo-tab-rail-status", children: [
|
|
111571
|
+
tab.missingRequiredData && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-red-600", children: /* @__PURE__ */ jsxRuntimeExports.jsx(FontAwesomeIcon, { icon: faCircleXmark, size: "lg" }) }),
|
|
111572
|
+
tab.hasData && !tab.missingRequiredData && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-green-600", children: /* @__PURE__ */ jsxRuntimeExports.jsx(FontAwesomeIcon, { icon: faCircleCheck, size: "lg" }) }),
|
|
111573
|
+
canRemove && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111574
|
+
Button$1,
|
|
111575
|
+
{
|
|
111576
|
+
"aria-label": "Remove profile",
|
|
111577
|
+
type: "text",
|
|
111578
|
+
size: "small",
|
|
111579
|
+
className: "describo-tab-rail-remove-button",
|
|
111580
|
+
style: {
|
|
111581
|
+
visibility: hoveredTabKey === tab.name ? "visible" : "hidden",
|
|
111582
|
+
opacity: hoveredTabKey === tab.name ? 1 : 0,
|
|
111583
|
+
pointerEvents: hoveredTabKey === tab.name ? "auto" : "none"
|
|
111584
|
+
},
|
|
111585
|
+
onClick: (e3) => {
|
|
111586
|
+
e3.stopPropagation();
|
|
111587
|
+
handleRemoveProfile(tab);
|
|
111588
|
+
},
|
|
111589
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$d, { style: { color: "oklch(57.7% 0.245 27.325)" } })
|
|
111590
|
+
}
|
|
111591
|
+
)
|
|
111592
|
+
] })
|
|
111593
|
+
] }),
|
|
111594
|
+
tab.description && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "describo-tab-rail-description", children: tab.description })
|
|
111595
|
+
] })
|
|
111596
|
+
},
|
|
111597
|
+
tab.name
|
|
111598
|
+
);
|
|
111599
|
+
})
|
|
111600
|
+
}
|
|
111601
|
+
),
|
|
111602
|
+
tabRailScrollState.canScrollUp && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111603
|
+
Button$1,
|
|
111604
|
+
{
|
|
111605
|
+
type: "default",
|
|
111606
|
+
shape: "circle",
|
|
111607
|
+
size: "small",
|
|
111608
|
+
className: "describo-tab-rail-scroll-button describo-tab-rail-scroll-button-up",
|
|
111609
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$m, {}),
|
|
111610
|
+
"aria-label": "Scroll profile tabs up",
|
|
111611
|
+
onClick: () => scrollTabRail("up")
|
|
111612
|
+
}
|
|
111613
|
+
),
|
|
111614
|
+
tabRailScrollState.canScrollDown && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111615
|
+
Button$1,
|
|
111616
|
+
{
|
|
111617
|
+
type: "default",
|
|
111618
|
+
shape: "circle",
|
|
111619
|
+
size: "small",
|
|
111620
|
+
className: "describo-tab-rail-scroll-button describo-tab-rail-scroll-button-down",
|
|
111621
|
+
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(RefIcon$r, {}),
|
|
111622
|
+
"aria-label": "Scroll profile tabs down",
|
|
111623
|
+
onClick: () => scrollTabRail("down")
|
|
111624
|
+
}
|
|
111625
|
+
)
|
|
111626
|
+
]
|
|
111627
|
+
}
|
|
111628
|
+
);
|
|
111126
111629
|
if (!entity || !entity["@id"]) {
|
|
111127
111630
|
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { children: "No entity selected" });
|
|
111128
111631
|
}
|
|
@@ -111164,23 +111667,11 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111164
111667
|
setTabPaneWidth(w2);
|
|
111165
111668
|
persistTabWidth(w2);
|
|
111166
111669
|
}, children: [
|
|
111167
|
-
((_e2 = state.configuration) == null ? void 0 : _e2.tabLocation) === "left" && /* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { minSize: iconView ?
|
|
111168
|
-
|
|
111169
|
-
Tabs,
|
|
111170
|
-
{
|
|
111171
|
-
className: "describo-add-only-tabs",
|
|
111172
|
-
tabPosition: "left",
|
|
111173
|
-
items: [
|
|
111174
|
-
toggleViewTabItem,
|
|
111175
|
-
addProfileTabItem
|
|
111176
|
-
],
|
|
111177
|
-
style: { width: "100%" },
|
|
111178
|
-
tabBarStyle: { width: "100%" }
|
|
111179
|
-
}
|
|
111180
|
-
),
|
|
111670
|
+
((_e2 = state.configuration) == null ? void 0 : _e2.tabLocation) === "left" && /* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { minSize: iconView ? 80 : 100, maxSize: iconView ? 80 : 250, preferredSize: iconView ? 80 : tabPaneWidth, children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative group h-full border-r border-slate-200", children: [
|
|
111671
|
+
renderProfileActionRail(),
|
|
111181
111672
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute right-0 top-0 bottom-0 w-1 bg-slate-300 opacity-0 group-hover:opacity-100" })
|
|
111182
111673
|
] }) }),
|
|
111183
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { ref: activeContentRef, className: "flex-1 overflow-y-auto scroll-smooth min-h-0 p-3", children: [
|
|
111674
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { ref: activeContentRef, className: "describo-editor-scroll flex-1 overflow-y-auto scroll-smooth min-h-0 p-3", children: [
|
|
111184
111675
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-row space-x-2 my-2 p-2", children: [
|
|
111185
111676
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111186
111677
|
"div",
|
|
@@ -111211,6 +111702,7 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111211
111702
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111212
111703
|
"div",
|
|
111213
111704
|
{
|
|
111705
|
+
"data-recrate-property": property,
|
|
111214
111706
|
className: `my-2 hover:bg-sky-100 ${savedProperty === property ? "bg-green-200 hover:bg-green-200" : ""}`,
|
|
111215
111707
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111216
111708
|
EntityProperty,
|
|
@@ -111236,20 +111728,8 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111236
111728
|
return null;
|
|
111237
111729
|
})
|
|
111238
111730
|
] }) }),
|
|
111239
|
-
((_g = state.configuration) == null ? void 0 : _g.tabLocation) === "right" && /* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { minSize: iconView ?
|
|
111240
|
-
|
|
111241
|
-
Tabs,
|
|
111242
|
-
{
|
|
111243
|
-
className: "describo-add-only-tabs",
|
|
111244
|
-
tabPosition: "right",
|
|
111245
|
-
items: [
|
|
111246
|
-
toggleViewTabItem,
|
|
111247
|
-
addProfileTabItem
|
|
111248
|
-
],
|
|
111249
|
-
style: { width: "100%" },
|
|
111250
|
-
tabBarStyle: { width: "100%" }
|
|
111251
|
-
}
|
|
111252
|
-
),
|
|
111731
|
+
((_g = state.configuration) == null ? void 0 : _g.tabLocation) === "right" && /* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { minSize: iconView ? 80 : 100, maxSize: iconView ? 80 : 250, preferredSize: iconView ? 80 : tabPaneWidth, children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative group h-full border-l border-slate-200", children: [
|
|
111732
|
+
renderProfileActionRail(),
|
|
111253
111733
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute left-0 top-0 bottom-0 w-1 bg-slate-300 opacity-0 group-hover:opacity-100" })
|
|
111254
111734
|
] }) })
|
|
111255
111735
|
] }) }) : /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { ref: contentContainerRef, className: "flex min-h-0 overflow-hidden", style: {
|
|
@@ -111268,7 +111748,7 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111268
111748
|
tabBarStyle: { width: "100%" }
|
|
111269
111749
|
}
|
|
111270
111750
|
) }),
|
|
111271
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { ref: activeContentRef, className: "h-full overflow-y-auto scroll-smooth min-h-0 p-3", children: [
|
|
111751
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { ref: activeContentRef, className: "describo-editor-scroll h-full overflow-y-auto scroll-smooth min-h-0 p-3", children: [
|
|
111272
111752
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-row space-x-2 my-2 p-2", children: [
|
|
111273
111753
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111274
111754
|
"div",
|
|
@@ -111299,6 +111779,7 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111299
111779
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111300
111780
|
"div",
|
|
111301
111781
|
{
|
|
111782
|
+
"data-recrate-property": property,
|
|
111302
111783
|
className: `my-2 hover:bg-sky-100 ${savedProperty === property ? "bg-green-200 hover:bg-green-200" : ""}`,
|
|
111303
111784
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111304
111785
|
EntityProperty,
|
|
@@ -111331,27 +111812,12 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111331
111812
|
setTabPaneWidth(w2);
|
|
111332
111813
|
persistTabWidth(w2);
|
|
111333
111814
|
}, children: [
|
|
111334
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { minSize: iconView ?
|
|
111335
|
-
|
|
111336
|
-
Tabs,
|
|
111337
|
-
{
|
|
111338
|
-
className: "describo-tabs-vertical-center-add",
|
|
111339
|
-
activeKey: activeTab,
|
|
111340
|
-
onChange: (key) => {
|
|
111341
|
-
captureViewContext(activeTab);
|
|
111342
|
-
setActiveTab(key);
|
|
111343
|
-
saveTabToState(key);
|
|
111344
|
-
},
|
|
111345
|
-
tabPosition: ((_i = state.configuration) == null ? void 0 : _i.tabLocation) === "left" ? "left" : ((_j = state.configuration) == null ? void 0 : _j.tabLocation) === "right" ? "right" : "top",
|
|
111346
|
-
style: { width: "100%" },
|
|
111347
|
-
tabBarStyle: ((_k = state.configuration) == null ? void 0 : _k.tabLocation) === "left" || ((_l = state.configuration) == null ? void 0 : _l.tabLocation) === "right" ? { width: "100%" } : void 0,
|
|
111348
|
-
items: tabItems
|
|
111349
|
-
}
|
|
111350
|
-
),
|
|
111815
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { minSize: iconView ? 80 : 100, maxSize: iconView ? 80 : 250, preferredSize: iconView ? 80 : tabPaneWidth, children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative group h-full", children: [
|
|
111816
|
+
renderProfileTabRail(),
|
|
111351
111817
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute right-0 top-0 bottom-0 w-1 bg-slate-300 opacity-0 group-hover:opacity-100" })
|
|
111352
111818
|
] }) }),
|
|
111353
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { ref: activeContentRef, className: "h-full overflow-y-auto scroll-smooth min-h-0 p-3", children: [
|
|
111354
|
-
!((
|
|
111819
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Ve.Pane, { children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { ref: activeContentRef, className: "describo-editor-scroll h-full overflow-y-auto scroll-smooth min-h-0 p-3", children: [
|
|
111820
|
+
!((_i = state.configuration) == null ? void 0 : _i.readonly) && ((_j = tabs.find((t22) => t22.name === activeTab)) == null ? void 0 : _j.missingRequiredData) && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-red-600 float-right mb-2", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111355
111821
|
"button",
|
|
111356
111822
|
{
|
|
111357
111823
|
className: "bg-red-500 hover:bg-red-700 text-white font-bold py-2 px-4 rounded text-sm",
|
|
@@ -111375,25 +111841,33 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111375
111841
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(EntityName, { entity: contextEntity, onUpdate: handleUpdateEntity })
|
|
111376
111842
|
}
|
|
111377
111843
|
),
|
|
111378
|
-
(
|
|
111844
|
+
(_k = tabs.find((tab) => tab.name === "about")) == null ? void 0 : _k.inputs.map((input) => {
|
|
111379
111845
|
if (!["@id", "@type", "name", "@reverse"].includes(input.name)) {
|
|
111380
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111381
|
-
|
|
111846
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111847
|
+
"div",
|
|
111382
111848
|
{
|
|
111383
|
-
|
|
111384
|
-
|
|
111385
|
-
|
|
111386
|
-
|
|
111387
|
-
|
|
111388
|
-
|
|
111389
|
-
|
|
111390
|
-
|
|
111391
|
-
|
|
111392
|
-
|
|
111393
|
-
|
|
111394
|
-
|
|
111395
|
-
|
|
111396
|
-
|
|
111849
|
+
"data-recrate-property": input.name,
|
|
111850
|
+
className: `p-2 hover:bg-sky-100 ${savedProperty === input.name ? "bg-green-200 hover:bg-green-200" : ""}`,
|
|
111851
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111852
|
+
EntityProperty,
|
|
111853
|
+
{
|
|
111854
|
+
entity: contextEntity,
|
|
111855
|
+
property: input.name,
|
|
111856
|
+
values: Array.isArray(contextEntity[input.name]) ? contextEntity[input.name] : [contextEntity[input.name]],
|
|
111857
|
+
highlightRequired: highlightRequiredProperties,
|
|
111858
|
+
savedProperty: savedProperty === input.name,
|
|
111859
|
+
onLoadEntity: handleLoadEntityWithContext,
|
|
111860
|
+
onCreateEntity: handleCreateEntity,
|
|
111861
|
+
onLinkEntity: handleLinkEntity,
|
|
111862
|
+
onUnlinkEntity: handleUnlinkEntity,
|
|
111863
|
+
onCreateProperty: handleCreateProperty,
|
|
111864
|
+
onSaveProperty: handleUpdateEntity,
|
|
111865
|
+
onDeleteProperty: handleDeleteProperty
|
|
111866
|
+
}
|
|
111867
|
+
)
|
|
111868
|
+
},
|
|
111869
|
+
input.name
|
|
111870
|
+
);
|
|
111397
111871
|
}
|
|
111398
111872
|
return null;
|
|
111399
111873
|
})
|
|
@@ -111405,6 +111879,7 @@ const RenderEntity = forwardRef((props, ref) => {
|
|
|
111405
111879
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111406
111880
|
"div",
|
|
111407
111881
|
{
|
|
111882
|
+
"data-recrate-property": input.name,
|
|
111408
111883
|
className: `p-2 hover:bg-sky-100 ${savedProperty === input.name ? "bg-green-200 hover:bg-green-200" : ""}`,
|
|
111409
111884
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
111410
111885
|
EntityProperty,
|
|
@@ -119780,7 +120255,7 @@ var EmotionCacheContext = /* @__PURE__ */ React.createContext(
|
|
|
119780
120255
|
}) : null
|
|
119781
120256
|
);
|
|
119782
120257
|
var CacheProvider = EmotionCacheContext.Provider;
|
|
119783
|
-
const version = "0.1.
|
|
120258
|
+
const version = "0.1.25";
|
|
119784
120259
|
const pkg = {
|
|
119785
120260
|
version
|
|
119786
120261
|
};
|