baseui 0.0.0-next-42ee3cb → 0.0.0-next-fceb4f9
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/dnd-list/list.js +1 -2
- package/dnd-list/list.js.flow +1 -1
- package/dnd-list/styled-components.js +1 -1
- package/dnd-list/styled-components.js.flow +1 -0
- package/es/dnd-list/list.js +1 -2
- package/es/dnd-list/styled-components.js +1 -0
- package/es/layer/layer.js +8 -0
- package/esm/dnd-list/list.js +1 -2
- package/esm/dnd-list/styled-components.js +1 -1
- package/esm/layer/layer.js +8 -0
- package/layer/layer.js +8 -0
- package/layer/layer.js.flow +9 -0
- package/package.json +1 -1
package/dnd-list/list.js
CHANGED
|
@@ -220,8 +220,7 @@ var StatelessList = /*#__PURE__*/function (_React$Component) {
|
|
|
220
220
|
display: 'flex'
|
|
221
221
|
})
|
|
222
222
|
}), /*#__PURE__*/React.createElement(DragHandle, _extends({}, sharedProps, dragHandleProps), /*#__PURE__*/React.createElement(_grab.default, {
|
|
223
|
-
size: 24
|
|
224
|
-
color: "#CCC"
|
|
223
|
+
size: 24
|
|
225
224
|
})), /*#__PURE__*/React.createElement(Label, _extends({}, sharedProps, labelProps), value), removable && /*#__PURE__*/React.createElement(CloseHandle, _extends({}, sharedProps, {
|
|
226
225
|
onClick: function onClick(evt) {
|
|
227
226
|
evt.preventDefault();
|
package/dnd-list/list.js.flow
CHANGED
|
@@ -136,7 +136,7 @@ class StatelessList extends React.Component<
|
|
|
136
136
|
style={{...props.style, display: 'flex'}}
|
|
137
137
|
>
|
|
138
138
|
<DragHandle {...sharedProps} {...dragHandleProps}>
|
|
139
|
-
<Grab size={24}
|
|
139
|
+
<Grab size={24} />
|
|
140
140
|
</DragHandle>
|
|
141
141
|
<Label {...sharedProps} {...labelProps}>
|
|
142
142
|
{value}
|
|
@@ -94,7 +94,7 @@ var DragHandle = (0, _index.styled)('div', function (_ref4) {
|
|
|
94
94
|
|
|
95
95
|
var $theme = _ref4.$theme;
|
|
96
96
|
var marginDir = $theme.direction === 'rtl' ? 'marginLeft' : 'marginRight';
|
|
97
|
-
return _ref5 = {}, _defineProperty(_ref5, marginDir, $theme.sizing.scale600), _defineProperty(_ref5, "width", $theme.sizing.scale800), _defineProperty(_ref5, "display", 'flex'), _defineProperty(_ref5, "alignItems", 'center'), _ref5;
|
|
97
|
+
return _ref5 = {}, _defineProperty(_ref5, marginDir, $theme.sizing.scale600), _defineProperty(_ref5, "width", $theme.sizing.scale800), _defineProperty(_ref5, "color", '#CCC'), _defineProperty(_ref5, "display", 'flex'), _defineProperty(_ref5, "alignItems", 'center'), _ref5;
|
|
98
98
|
});
|
|
99
99
|
exports.DragHandle = DragHandle;
|
|
100
100
|
DragHandle.displayName = "DragHandle";
|
package/es/dnd-list/list.js
CHANGED
|
@@ -127,8 +127,7 @@ class StatelessList extends React.Component {
|
|
|
127
127
|
display: 'flex'
|
|
128
128
|
}
|
|
129
129
|
}), /*#__PURE__*/React.createElement(DragHandle, _extends({}, sharedProps, dragHandleProps), /*#__PURE__*/React.createElement(Grab, {
|
|
130
|
-
size: 24
|
|
131
|
-
color: "#CCC"
|
|
130
|
+
size: 24
|
|
132
131
|
})), /*#__PURE__*/React.createElement(Label, _extends({}, sharedProps, labelProps), value), removable && /*#__PURE__*/React.createElement(CloseHandle, _extends({}, sharedProps, {
|
|
133
132
|
onClick: evt => {
|
|
134
133
|
evt.preventDefault();
|
package/es/layer/layer.js
CHANGED
|
@@ -94,6 +94,14 @@ class LayerComponent extends React.Component {
|
|
|
94
94
|
if (host && host !== prevProps.host && prevProps.host === null) {
|
|
95
95
|
this.addContainer(host);
|
|
96
96
|
}
|
|
97
|
+
|
|
98
|
+
if (prevProps.isHoverLayer != this.props.isHoverLayer) {
|
|
99
|
+
if (this.props.isHoverLayer) {
|
|
100
|
+
this.context.removeDocClickHandler(this.onDocumentClick);
|
|
101
|
+
} else {
|
|
102
|
+
this.context.addDocClickHandler(this.onDocumentClick);
|
|
103
|
+
}
|
|
104
|
+
}
|
|
97
105
|
}
|
|
98
106
|
|
|
99
107
|
componentWillUnmount() {
|
package/esm/dnd-list/list.js
CHANGED
|
@@ -206,8 +206,7 @@ var StatelessList = /*#__PURE__*/function (_React$Component) {
|
|
|
206
206
|
display: 'flex'
|
|
207
207
|
})
|
|
208
208
|
}), /*#__PURE__*/React.createElement(DragHandle, _extends({}, sharedProps, dragHandleProps), /*#__PURE__*/React.createElement(Grab, {
|
|
209
|
-
size: 24
|
|
210
|
-
color: "#CCC"
|
|
209
|
+
size: 24
|
|
211
210
|
})), /*#__PURE__*/React.createElement(Label, _extends({}, sharedProps, labelProps), value), removable && /*#__PURE__*/React.createElement(CloseHandle, _extends({}, sharedProps, {
|
|
212
211
|
onClick: function onClick(evt) {
|
|
213
212
|
evt.preventDefault();
|
|
@@ -90,7 +90,7 @@ export var DragHandle = styled('div', function (_ref4) {
|
|
|
90
90
|
|
|
91
91
|
var $theme = _ref4.$theme;
|
|
92
92
|
var marginDir = $theme.direction === 'rtl' ? 'marginLeft' : 'marginRight';
|
|
93
|
-
return _ref5 = {}, _defineProperty(_ref5, marginDir, $theme.sizing.scale600), _defineProperty(_ref5, "width", $theme.sizing.scale800), _defineProperty(_ref5, "display", 'flex'), _defineProperty(_ref5, "alignItems", 'center'), _ref5;
|
|
93
|
+
return _ref5 = {}, _defineProperty(_ref5, marginDir, $theme.sizing.scale600), _defineProperty(_ref5, "width", $theme.sizing.scale800), _defineProperty(_ref5, "color", '#CCC'), _defineProperty(_ref5, "display", 'flex'), _defineProperty(_ref5, "alignItems", 'center'), _ref5;
|
|
94
94
|
});
|
|
95
95
|
DragHandle.displayName = "DragHandle";
|
|
96
96
|
DragHandle.displayName = 'StyledDragHandle';
|
package/esm/layer/layer.js
CHANGED
|
@@ -132,6 +132,14 @@ var LayerComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
132
132
|
if (host && host !== prevProps.host && prevProps.host === null) {
|
|
133
133
|
this.addContainer(host);
|
|
134
134
|
}
|
|
135
|
+
|
|
136
|
+
if (prevProps.isHoverLayer != this.props.isHoverLayer) {
|
|
137
|
+
if (this.props.isHoverLayer) {
|
|
138
|
+
this.context.removeDocClickHandler(this.onDocumentClick);
|
|
139
|
+
} else {
|
|
140
|
+
this.context.addDocClickHandler(this.onDocumentClick);
|
|
141
|
+
}
|
|
142
|
+
}
|
|
135
143
|
}
|
|
136
144
|
}, {
|
|
137
145
|
key: "componentWillUnmount",
|
package/layer/layer.js
CHANGED
|
@@ -141,6 +141,14 @@ var LayerComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
141
141
|
if (host && host !== prevProps.host && prevProps.host === null) {
|
|
142
142
|
this.addContainer(host);
|
|
143
143
|
}
|
|
144
|
+
|
|
145
|
+
if (prevProps.isHoverLayer != this.props.isHoverLayer) {
|
|
146
|
+
if (this.props.isHoverLayer) {
|
|
147
|
+
this.context.removeDocClickHandler(this.onDocumentClick);
|
|
148
|
+
} else {
|
|
149
|
+
this.context.addDocClickHandler(this.onDocumentClick);
|
|
150
|
+
}
|
|
151
|
+
}
|
|
144
152
|
}
|
|
145
153
|
}, {
|
|
146
154
|
key: "componentWillUnmount",
|
package/layer/layer.js.flow
CHANGED
|
@@ -61,9 +61,18 @@ class LayerComponent extends React.Component<
|
|
|
61
61
|
if (mountNode) {
|
|
62
62
|
return;
|
|
63
63
|
}
|
|
64
|
+
|
|
64
65
|
if (host && host !== prevProps.host && prevProps.host === null) {
|
|
65
66
|
this.addContainer(host);
|
|
66
67
|
}
|
|
68
|
+
|
|
69
|
+
if (prevProps.isHoverLayer != this.props.isHoverLayer) {
|
|
70
|
+
if (this.props.isHoverLayer) {
|
|
71
|
+
this.context.removeDocClickHandler(this.onDocumentClick);
|
|
72
|
+
} else {
|
|
73
|
+
this.context.addDocClickHandler(this.onDocumentClick);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
67
76
|
}
|
|
68
77
|
|
|
69
78
|
componentWillUnmount() {
|