szld-libs 0.4.41 → 0.4.42

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.
@@ -18,6 +18,7 @@ export interface IformConfigItem {
18
18
  }
19
19
 
20
20
  export interface Ijson {
21
+ extraDescObj?: Record<string, any>;
21
22
  hidden?: boolean; // 是否隐藏属性
22
23
  'auto-generate'?: boolean; // 是否自动生成时间
23
24
  'auto-generate-type'?: string; // 自动生成时间类型
@@ -301,7 +301,7 @@ function useDynamicForm(props) {
301
301
  formListField,
302
302
  isShowLabel = true
303
303
  }) => {
304
- var _a, _b, _c, _d, _e, _f, _g, _h;
304
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
305
305
  const hidden = (_a = itemWithJson.json) == null ? void 0 : _a.hidden;
306
306
  if (((_b = itemWithJson.json) == null ? void 0 : _b.hide) === true) {
307
307
  return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, {});
@@ -335,6 +335,13 @@ function useDynamicForm(props) {
335
335
  {
336
336
  label: (_d = itemWithJson == null ? void 0 : itemWithJson.json) == null ? void 0 : _d["combination-name"],
337
337
  required: ((_e = itemWithJson.json) == null ? void 0 : _e.must) && !hidden,
338
+ extra: /* @__PURE__ */ jsxRuntime.jsx(
339
+ "span",
340
+ {
341
+ style: { marginTop: 10, display: "inline-block", color: (_g = (_f = itemWithJson.json) == null ? void 0 : _f.extraDescObj) == null ? void 0 : _g.color },
342
+ children: (_i = (_h = itemWithJson.json) == null ? void 0 : _h.extraDescObj) == null ? void 0 : _i.info
343
+ }
344
+ ),
338
345
  children: /* @__PURE__ */ jsxRuntime.jsx(antd.Space.Compact, { children: combinations.map((item, index) => {
339
346
  var _a2, _b2, _c2, _d2, _e2;
340
347
  let initValue = func.handleSetFormItemInitialValue(item);
@@ -400,17 +407,18 @@ function useDynamicForm(props) {
400
407
  label: isShowLabel && handleDealInstruction(itemWithJson, instructionShowMode) || null,
401
408
  initialValue,
402
409
  hidden,
410
+ extra: /* @__PURE__ */ jsxRuntime.jsx("span", { style: { marginTop: 10, display: "inline-block", color: (_k = (_j = itemWithJson.json) == null ? void 0 : _j.extraDescObj) == null ? void 0 : _k.color }, children: (_m = (_l = itemWithJson.json) == null ? void 0 : _l.extraDescObj) == null ? void 0 : _m.info }),
403
411
  rules: [
404
- ...((_f = itemWithJson.json) == null ? void 0 : _f.must) && !hidden ? [
412
+ ...((_n = itemWithJson.json) == null ? void 0 : _n.must) && !hidden ? [
405
413
  {
406
414
  required: true,
407
415
  message: `${placeholder}${itemWithJson.attrname}`
408
416
  }
409
417
  ] : [],
410
- ...((_g = itemWithJson.json) == null ? void 0 : _g.regexp) ? [
418
+ ...((_o = itemWithJson.json) == null ? void 0 : _o.regexp) ? [
411
419
  {
412
420
  pattern: new RegExp(itemWithJson.json.regexp.replace(/^\/|\/$/g, "")),
413
- message: ((_h = itemWithJson.json) == null ? void 0 : _h["regexp-message"]) || `${itemWithJson.attrname}${langId === "10001" ? "格式不正确" : "Format is incorrect"}`
421
+ message: ((_p = itemWithJson.json) == null ? void 0 : _p["regexp-message"]) || `${itemWithJson.attrname}${langId === "10001" ? "格式不正确" : "Format is incorrect"}`
414
422
  }
415
423
  ] : []
416
424
  ],
@@ -254,7 +254,7 @@ function useDynamicForm(props) {
254
254
  formListField,
255
255
  isShowLabel = true
256
256
  }) => {
257
- var _a, _b, _c, _d, _e, _f, _g;
257
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
258
258
  const hidden = (_a = itemWithJson.json) == null ? void 0 : _a.hidden;
259
259
  if (((_b = itemWithJson.json) == null ? void 0 : _b.hide) === true || (hideAttrList == null ? void 0 : hideAttrList.includes(itemWithJson.attrid))) {
260
260
  return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, {});
@@ -285,7 +285,7 @@ function useDynamicForm(props) {
285
285
  const { combinations = [] } = itemWithJson.json || {};
286
286
  if (combinations == null ? void 0 : combinations.length) {
287
287
  return /* @__PURE__ */ jsxRuntime.jsx(antd.Flex, { children: combinations.map((item, index) => {
288
- var _a2, _b2, _c2, _d2, _e2, _f2, _g2;
288
+ var _a2, _b2, _c2, _d2, _e2, _f2, _g2, _h2, _i2, _j2, _k2;
289
289
  let initValue = func.handleSetFormItemInitialValue(item);
290
290
  let width = defaultWidth;
291
291
  const mode = item.json.input || "text";
@@ -324,6 +324,17 @@ function useDynamicForm(props) {
324
324
  }
325
325
  ] : []
326
326
  ],
327
+ intro: /* @__PURE__ */ jsxRuntime.jsx(
328
+ "span",
329
+ {
330
+ style: {
331
+ marginTop: 10,
332
+ display: "inline-block",
333
+ color: (_i2 = (_h2 = itemWithJson.json) == null ? void 0 : _h2.extraDescObj) == null ? void 0 : _i2.color
334
+ },
335
+ children: (_k2 = (_j2 = itemWithJson.json) == null ? void 0 : _j2.extraDescObj) == null ? void 0 : _k2.info
336
+ }
337
+ ),
327
338
  ...handleSetFormItemProps(item),
328
339
  children: handleRenderItemInputMode({
329
340
  item,
@@ -369,6 +380,7 @@ function useDynamicForm(props) {
369
380
  ] : []
370
381
  ],
371
382
  ...handleSetFormItemProps(itemWithJson),
383
+ intro: /* @__PURE__ */ jsxRuntime.jsx("span", { style: { marginTop: 10, display: "inline-block", color: (_i = (_h = itemWithJson.json) == null ? void 0 : _h.extraDescObj) == null ? void 0 : _i.color }, children: (_k = (_j = itemWithJson.json) == null ? void 0 : _j.extraDescObj) == null ? void 0 : _k.info }),
372
384
  children: handleRenderItemInputMode({
373
385
  item: itemWithJson,
374
386
  readonly,