ztxkui 3.9.2 → 3.9.3

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.
@@ -44,7 +44,7 @@ var PrintModal = function (_a) {
44
44
  onChange && onChange(value);
45
45
  };
46
46
  return (React.createElement(Modal, { title: "\u8FB9\u8DDD\u8C03\u6574", visible: visible, loading: false, width: "90%", onCancel: onCancel, onOk: onSure },
47
- React.createElement("div", null,
47
+ React.createElement("div", { style: { position: 'relative', zIndex: 1000 } },
48
48
  "\u4E0A\u8FB9\u8DDD\uFF1A",
49
49
  React.createElement(Slider, { min: -180, max: 200, step: 0.01, value: (value === null || value === void 0 ? void 0 : value.top) || 0, onChange: function (value) {
50
50
  if (value < 0) {
@@ -57,7 +57,7 @@ var PrintModal = function (_a) {
57
57
  }
58
58
  setValue(function (preValue) { return (__assign(__assign({}, (preValue || {})), { top: value })); });
59
59
  } })),
60
- React.createElement("div", null,
60
+ React.createElement("div", { style: { position: 'relative', zIndex: 1000 } },
61
61
  "\u5DE6\u8FB9\u8DDD\uFF1A",
62
62
  React.createElement(Slider, { min: -180, max: 200, step: 0.01, value: (value === null || value === void 0 ? void 0 : value.left) || 0, onChange: function (value) {
63
63
  if (value < 0) {
@@ -317,7 +317,6 @@ export function setPositionDeviation(value) {
317
317
  };
318
318
  }
319
319
  export function setMinusPosition(dom, style) {
320
- var _a, _b;
321
320
  try {
322
321
  var childrenDom = dom.querySelectorAll('.set-box');
323
322
  if (childrenDom) {
@@ -327,15 +326,16 @@ export function setMinusPosition(dom, style) {
327
326
  var left = childrenDom[0].dataset.left
328
327
  ? parseInt(childrenDom[0].dataset.left)
329
328
  : 0;
330
- var resultTop = top_1;
331
- var resultLeft = left;
332
329
  if (style.top) {
330
+ var resultTop = top_1;
333
331
  resultTop += style.top;
332
+ childrenDom[0].style.top = resultTop + "px";
334
333
  }
335
334
  if (style.left) {
335
+ var resultLeft = left;
336
336
  resultLeft += style.left;
337
+ childrenDom[0].style.left = resultLeft + "px";
337
338
  }
338
- (_b = (_a = childrenDom[0]) === null || _a === void 0 ? void 0 : _a.setAttribute) === null || _b === void 0 ? void 0 : _b.call(_a, 'style', "top: " + resultTop + "px; left: " + resultLeft + "px");
339
339
  }
340
340
  }
341
341
  catch (err) {
@@ -362,18 +362,22 @@ export function initMinusPosition(dom) {
362
362
  }
363
363
  }
364
364
  export function reductionMinusPostion(dom, type) {
365
- var _a, _b, _c, _d, _e, _f;
366
365
  try {
367
366
  var childrenDom = dom.querySelectorAll('.set-box');
368
367
  if (childrenDom) {
369
368
  if (type === 'top') {
370
- (_b = (_a = childrenDom[0]) === null || _a === void 0 ? void 0 : _a.setAttribute) === null || _b === void 0 ? void 0 : _b.call(_a, 'style', "top: " + childrenDom[0].dataset.top + "; ");
369
+ childrenDom[0].style.top = childrenDom[0].dataset.top;
371
370
  }
372
371
  else if (type === 'left') {
373
- (_d = (_c = childrenDom[0]) === null || _c === void 0 ? void 0 : _c.setAttribute) === null || _d === void 0 ? void 0 : _d.call(_c, 'style', "left: " + childrenDom[0].dataset.left + "; ");
372
+ childrenDom[0].style.left = childrenDom[0].dataset.left;
374
373
  }
375
374
  else {
376
- (_f = (_e = childrenDom[0]) === null || _e === void 0 ? void 0 : _e.setAttribute) === null || _f === void 0 ? void 0 : _f.call(_e, 'style', "top: " + childrenDom[0].dataset.top + "; left: " + childrenDom[0].dataset.left);
375
+ childrenDom[0].style.top = childrenDom[0].dataset.top;
376
+ childrenDom[0].style.left = childrenDom[0].dataset.left;
377
+ // childrenDom[0]?.setAttribute?.(
378
+ // 'style',
379
+ // `top: ${childrenDom[0].dataset.top}; left: ${childrenDom[0].dataset.left}`
380
+ // );
377
381
  }
378
382
  }
379
383
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ztxkui",
3
- "version": "3.9.2",
3
+ "version": "3.9.3",
4
4
  "private": false,
5
5
  "description": "React components library",
6
6
  "author": "zt-front-end",