acud 0.0.72 → 0.0.73
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/CHANGELOG.md +4 -0
- package/dist/acud.css +1947 -1947
- package/dist/acud.css.map +1 -1
- package/dist/acud.js +1313 -1595
- package/dist/acud.js.map +1 -1
- package/dist/acud.min.css +1 -1
- package/dist/acud.min.css.map +1 -1
- package/dist/acud.min.js +6 -9
- package/dist/acud.min.js.map +1 -1
- package/es/cascader/style/css.js +5 -1
- package/es/cascader/style/index.d.ts +4 -0
- package/es/cascader/style/index.js +5 -1
- package/es/date-picker/src/PickerPanel.js +1 -0
- package/es/date-picker/src/RangePicker.js +1 -0
- package/es/input-number/src/hooks/useFrame.d.ts +1 -1
- package/es/modal/style/css.js +3 -1
- package/es/modal/style/index.d.ts +1 -0
- package/es/modal/style/index.js +3 -1
- package/es/select/style/css.js +2 -1
- package/es/select/style/index.d.ts +1 -0
- package/es/select/style/index.js +2 -1
- package/es/virtual-list/List.js +7 -0
- package/lib/cascader/style/css.js +9 -1
- package/lib/cascader/style/index.d.ts +4 -0
- package/lib/cascader/style/index.js +9 -1
- package/lib/date-picker/src/PickerPanel.js +1 -0
- package/lib/date-picker/src/RangePicker.js +1 -0
- package/lib/input-number/src/hooks/useFrame.d.ts +1 -1
- package/lib/modal/style/css.js +3 -1
- package/lib/modal/style/index.d.ts +1 -0
- package/lib/modal/style/index.js +3 -1
- package/lib/select/style/css.js +3 -1
- package/lib/select/style/index.d.ts +1 -0
- package/lib/select/style/index.js +3 -1
- package/lib/virtual-list/List.js +7 -0
- package/package.json +1 -1
package/es/cascader/style/css.js
CHANGED
|
@@ -2,4 +2,8 @@ import '../../style/index.css';
|
|
|
2
2
|
import './index.css'; // style dependencies
|
|
3
3
|
|
|
4
4
|
import '../../empty/style/css';
|
|
5
|
-
import '../../input/style/css';
|
|
5
|
+
import '../../input/style/css';
|
|
6
|
+
import '../../tag/style/css';
|
|
7
|
+
import '../../tooltip/style/css';
|
|
8
|
+
import '../../clear/style/css';
|
|
9
|
+
import '../../checkbox/style/css';
|
|
@@ -2,4 +2,8 @@ import '../../style/index.less';
|
|
|
2
2
|
import './index.less'; // style dependencies
|
|
3
3
|
|
|
4
4
|
import '../../empty/style';
|
|
5
|
-
import '../../input/style';
|
|
5
|
+
import '../../input/style';
|
|
6
|
+
import '../../tag/style';
|
|
7
|
+
import '../../tooltip/style';
|
|
8
|
+
import '../../clear/style';
|
|
9
|
+
import '../../checkbox/style';
|
|
@@ -122,6 +122,7 @@ function PickerPanel(props) {
|
|
|
122
122
|
var now = generateConfig.getNow();
|
|
123
123
|
if (!date) return now; // When value is null and set showTime
|
|
124
124
|
|
|
125
|
+
// When value is null and set showTime
|
|
125
126
|
if (!mergedValue && showTime) {
|
|
126
127
|
if (_typeof(showTime) === 'object') {
|
|
127
128
|
return setDateTime(generateConfig, date, showTime.defaultValue || now);
|
|
@@ -172,6 +172,7 @@ function InnerRangePicker(props) {
|
|
|
172
172
|
} // Fill disabled unit
|
|
173
173
|
|
|
174
174
|
|
|
175
|
+
// Fill disabled unit
|
|
175
176
|
for (var i = 0; i < 2; i += 1) {
|
|
176
177
|
if (mergedDisabled[i] && !getValue(postValues, i) && !getValue(allowEmpty, i)) {
|
|
177
178
|
postValues = updateValues(postValues, generateConfig.getNow(), i);
|
package/es/modal/style/css.js
CHANGED
package/es/modal/style/index.js
CHANGED
package/es/select/style/css.js
CHANGED
package/es/select/style/index.js
CHANGED
package/es/virtual-list/List.js
CHANGED
|
@@ -135,6 +135,7 @@ export function RawList(props, ref) {
|
|
|
135
135
|
} // Always use virtual scroll bar in avoid shaking
|
|
136
136
|
|
|
137
137
|
|
|
138
|
+
// Always use virtual scroll bar in avoid shaking
|
|
138
139
|
if (!inVirtual) {
|
|
139
140
|
return {
|
|
140
141
|
scrollHeight: ((_a = fillerInnerRef.current) === null || _a === void 0 ? void 0 : _a.offsetHeight) || 0,
|
|
@@ -156,12 +157,14 @@ export function RawList(props, ref) {
|
|
|
156
157
|
var cacheHeight = heights.get(key);
|
|
157
158
|
var currentItemBottom = itemTop + (cacheHeight === undefined ? itemHeight : cacheHeight); // Check item top in the range
|
|
158
159
|
|
|
160
|
+
// Check item top in the range
|
|
159
161
|
if (currentItemBottom >= scrollTop && startIndex === undefined) {
|
|
160
162
|
startIndex = i;
|
|
161
163
|
startOffset = itemTop;
|
|
162
164
|
} // Check item bottom in the range. We will render additional one item for motion usage
|
|
163
165
|
|
|
164
166
|
|
|
167
|
+
// Check item bottom in the range. We will render additional one item for motion usage
|
|
165
168
|
if (currentItemBottom > scrollTop + height && endIndex === undefined) {
|
|
166
169
|
endIndex = i;
|
|
167
170
|
}
|
|
@@ -172,6 +175,9 @@ export function RawList(props, ref) {
|
|
|
172
175
|
/* istanbul ignore next */
|
|
173
176
|
|
|
174
177
|
|
|
178
|
+
// Fallback to normal if not match. This code should never reach
|
|
179
|
+
|
|
180
|
+
/* istanbul ignore next */
|
|
175
181
|
if (startIndex === undefined) {
|
|
176
182
|
startIndex = 0;
|
|
177
183
|
startOffset = 0;
|
|
@@ -182,6 +188,7 @@ export function RawList(props, ref) {
|
|
|
182
188
|
} // Give cache to improve scroll experience
|
|
183
189
|
|
|
184
190
|
|
|
191
|
+
// Give cache to improve scroll experience
|
|
185
192
|
endIndex = Math.min(endIndex + 1, mergedData.length);
|
|
186
193
|
return {
|
|
187
194
|
scrollHeight: itemTop,
|
|
@@ -6,4 +6,12 @@ require("./index.css");
|
|
|
6
6
|
|
|
7
7
|
require("../../empty/style/css");
|
|
8
8
|
|
|
9
|
-
require("../../input/style/css");
|
|
9
|
+
require("../../input/style/css");
|
|
10
|
+
|
|
11
|
+
require("../../tag/style/css");
|
|
12
|
+
|
|
13
|
+
require("../../tooltip/style/css");
|
|
14
|
+
|
|
15
|
+
require("../../clear/style/css");
|
|
16
|
+
|
|
17
|
+
require("../../checkbox/style/css");
|
|
@@ -6,4 +6,12 @@ require("./index.less");
|
|
|
6
6
|
|
|
7
7
|
require("../../empty/style");
|
|
8
8
|
|
|
9
|
-
require("../../input/style");
|
|
9
|
+
require("../../input/style");
|
|
10
|
+
|
|
11
|
+
require("../../tag/style");
|
|
12
|
+
|
|
13
|
+
require("../../tooltip/style");
|
|
14
|
+
|
|
15
|
+
require("../../clear/style");
|
|
16
|
+
|
|
17
|
+
require("../../checkbox/style");
|
|
@@ -159,6 +159,7 @@ function PickerPanel(props) {
|
|
|
159
159
|
var now = generateConfig.getNow();
|
|
160
160
|
if (!date) return now; // When value is null and set showTime
|
|
161
161
|
|
|
162
|
+
// When value is null and set showTime
|
|
162
163
|
if (!mergedValue && showTime) {
|
|
163
164
|
if ((0, _typeof2["default"])(showTime) === 'object') {
|
|
164
165
|
return (0, _timeUtil.setDateTime)(generateConfig, date, showTime.defaultValue || now);
|
|
@@ -212,6 +212,7 @@ function InnerRangePicker(props) {
|
|
|
212
212
|
} // Fill disabled unit
|
|
213
213
|
|
|
214
214
|
|
|
215
|
+
// Fill disabled unit
|
|
215
216
|
for (var i = 0; i < 2; i += 1) {
|
|
216
217
|
if (mergedDisabled[i] && !(0, _miscUtil.getValue)(postValues, i) && !(0, _miscUtil.getValue)(allowEmpty, i)) {
|
|
217
218
|
postValues = (0, _miscUtil.updateValues)(postValues, generateConfig.getNow(), i);
|
package/lib/modal/style/css.js
CHANGED
package/lib/modal/style/index.js
CHANGED
package/lib/select/style/css.js
CHANGED
package/lib/virtual-list/List.js
CHANGED
|
@@ -165,6 +165,7 @@ function RawList(props, ref) {
|
|
|
165
165
|
} // Always use virtual scroll bar in avoid shaking
|
|
166
166
|
|
|
167
167
|
|
|
168
|
+
// Always use virtual scroll bar in avoid shaking
|
|
168
169
|
if (!inVirtual) {
|
|
169
170
|
return {
|
|
170
171
|
scrollHeight: ((_a = fillerInnerRef.current) === null || _a === void 0 ? void 0 : _a.offsetHeight) || 0,
|
|
@@ -186,12 +187,14 @@ function RawList(props, ref) {
|
|
|
186
187
|
var cacheHeight = heights.get(key);
|
|
187
188
|
var currentItemBottom = itemTop + (cacheHeight === undefined ? itemHeight : cacheHeight); // Check item top in the range
|
|
188
189
|
|
|
190
|
+
// Check item top in the range
|
|
189
191
|
if (currentItemBottom >= scrollTop && startIndex === undefined) {
|
|
190
192
|
startIndex = i;
|
|
191
193
|
startOffset = itemTop;
|
|
192
194
|
} // Check item bottom in the range. We will render additional one item for motion usage
|
|
193
195
|
|
|
194
196
|
|
|
197
|
+
// Check item bottom in the range. We will render additional one item for motion usage
|
|
195
198
|
if (currentItemBottom > scrollTop + height && endIndex === undefined) {
|
|
196
199
|
endIndex = i;
|
|
197
200
|
}
|
|
@@ -202,6 +205,9 @@ function RawList(props, ref) {
|
|
|
202
205
|
/* istanbul ignore next */
|
|
203
206
|
|
|
204
207
|
|
|
208
|
+
// Fallback to normal if not match. This code should never reach
|
|
209
|
+
|
|
210
|
+
/* istanbul ignore next */
|
|
205
211
|
if (startIndex === undefined) {
|
|
206
212
|
startIndex = 0;
|
|
207
213
|
startOffset = 0;
|
|
@@ -212,6 +218,7 @@ function RawList(props, ref) {
|
|
|
212
218
|
} // Give cache to improve scroll experience
|
|
213
219
|
|
|
214
220
|
|
|
221
|
+
// Give cache to improve scroll experience
|
|
215
222
|
endIndex = Math.min(endIndex + 1, mergedData.length);
|
|
216
223
|
return {
|
|
217
224
|
scrollHeight: itemTop,
|