lu-lowcode-package-form 0.11.65 → 0.11.66

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lu-lowcode-package-form",
3
- "version": "0.11.65",
3
+ "version": "0.11.66",
4
4
  "dependencies": {
5
5
  "@ant-design/icons": "^4.8.1",
6
6
  "@dnd-kit/core": "^6.1.0",
@@ -33,7 +33,7 @@ const DragHead = ({ childrenDesc, initialWidth, changeWidth, showAction, showLab
33
33
  left: var(--drag-position);
34
34
  width: 2px;
35
35
  height: 100vh;
36
- background-color: #1890ff;
36
+ background-color: #1290ff;
37
37
  pointer-events: none;
38
38
  z-index: 9999;
39
39
  display: none;
@@ -54,8 +54,8 @@ const DragHead = ({ childrenDesc, initialWidth, changeWidth, showAction, showLab
54
54
  return (e, data) => {
55
55
  e.stopPropagation();
56
56
  document.getElementById('column-drag-indicator').style.display = 'block';
57
- setIsDragging(true);
58
- setResizingColumn(index);
57
+ // setIsDragging(true);
58
+ // setResizingColumn(index);
59
59
  document.documentElement.style.setProperty('--drag-position', `${e.clientX}px`);
60
60
  startPositionRef.current = e.clientX;
61
61
  }
@@ -89,31 +89,12 @@ const DragHead = ({ childrenDesc, initialWidth, changeWidth, showAction, showLab
89
89
  typeof changeWidth === 'function' && changeWidth(newHeadWidths);
90
90
 
91
91
  // 重置拖动状态
92
- setIsDragging(false);
93
- setResizingColumn(null);
92
+ // setIsDragging(false);
93
+ // setResizingColumn(null);
94
94
  }
95
95
  }
96
96
 
97
- // 虚拟指示线组件
98
- const DragIndicator = () => {
99
- if (!isDragging) return null
100
97
 
101
- const style = {
102
- position: 'fixed',
103
- top: 0,
104
- left: `${dragPosition}px`,
105
- width: '2px',
106
- height: '100vh',
107
- backgroundColor: '#1890ff',
108
- pointerEvents: 'none',
109
- zIndex: 9999
110
- }
111
-
112
- return createPortal(
113
- <div style={style}></div>,
114
- document.body
115
- )
116
- }
117
98
 
118
99
  return <><div className="fflex flex-nowrap fmin-w-full fabsolute">
119
100
  {childrenDesc.map((child, childIndex) => {
@@ -88,9 +88,11 @@ const Table = ({ children, onTableAddRow, disabled, readonly, onTableRemoveRow,
88
88
  },[headWidths])
89
89
 
90
90
  useEffect(()=>{
91
- const childrenDesc = React.Children.map(children, (child) => {
92
- return {id:child.props.componentId || child.props.__id,label:child.props.label}
91
+ let childrenDesc = React.Children.map(children, (child) => {
92
+ const hidden = (child?.props?.calcHidden || !getDependencyMapShow(child?.props?.componentId || child?.props?.__id)) && mode != "desgin";
93
+ return {id:child.props.componentId || child.props.__id,label:child.props.label, hidden }
93
94
  })
95
+ childrenDesc = childrenDesc.filter(item=>!item.hidden)
94
96
  console.log("Emit Table childrenDesc", childrenDesc)
95
97
  eventEmitter.emit("tableChildrenDesc", childrenDesc)
96
98
  setChildrenDesc(childrenDesc)