shineout 3.2.0-rc.2 → 3.2.0-rc.4
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/cjs/index.js +1 -1
- package/dist/shineout.js +121 -36
- package/dist/shineout.js.map +1 -1
- package/dist/shineout.min.js +1 -1
- package/dist/shineout.min.js.map +1 -1
- package/esm/index.js +1 -1
- package/package.json +5 -5
package/cjs/index.js
CHANGED
|
@@ -476,5 +476,5 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
476
476
|
// 此文件由脚本自动生成,请勿直接修改。
|
|
477
477
|
// This file was generated automatically by a script. Please do not modify it directly.
|
|
478
478
|
var _default = exports.default = {
|
|
479
|
-
version: '3.2.0-rc.
|
|
479
|
+
version: '3.2.0-rc.4'
|
|
480
480
|
};
|
package/dist/shineout.js
CHANGED
|
@@ -11949,7 +11949,7 @@ var handleStyle = function handleStyle(style) {
|
|
|
11949
11949
|
};
|
|
11950
11950
|
/* harmony default export */ var jss_style_handleStyle = (handleStyle);
|
|
11951
11951
|
;// CONCATENATED MODULE: ../shineout-style/src/version.ts
|
|
11952
|
-
/* harmony default export */ var version = ('3.2.0-rc.
|
|
11952
|
+
/* harmony default export */ var version = ('3.2.0-rc.4');
|
|
11953
11953
|
;// CONCATENATED MODULE: ../shineout-style/src/jss-style/index.tsx
|
|
11954
11954
|
|
|
11955
11955
|
|
|
@@ -12425,6 +12425,7 @@ var Token = {
|
|
|
12425
12425
|
|
|
12426
12426
|
// @ts-ignore
|
|
12427
12427
|
var CommonToken = {};
|
|
12428
|
+
var CommonTokenMap = (/* unused pure expression or super */ null && (Token));
|
|
12428
12429
|
Object.keys(Token).forEach(function (key) {
|
|
12429
12430
|
var _getConfig = getConfig(),
|
|
12430
12431
|
prefix = _getConfig.prefix;
|
|
@@ -12771,19 +12772,19 @@ var buttonTokens = {
|
|
|
12771
12772
|
buttonLinkFocusBackgroundColor: 'transparent',
|
|
12772
12773
|
buttonLinkFocusBorderColor: 'transparent',
|
|
12773
12774
|
buttonFontSize: 'Font-14',
|
|
12774
|
-
buttonBorderRadius: 'Radius-
|
|
12775
|
+
buttonBorderRadius: 'Radius-default',
|
|
12775
12776
|
buttonPaddingX: 'Spacing-12',
|
|
12776
12777
|
buttonPaddingY: 'Spacing-5',
|
|
12777
12778
|
buttonHeight: 'Size-16',
|
|
12778
12779
|
buttonFontWeight: 'Weight-regular',
|
|
12779
12780
|
buttonSmallFontSize: 'Font-12',
|
|
12780
|
-
buttonSmallBorderRadius: 'Radius-
|
|
12781
|
+
buttonSmallBorderRadius: 'Radius-default',
|
|
12781
12782
|
buttonSmallPaddingX: 'Spacing-8',
|
|
12782
12783
|
buttonSmallPaddingY: 'Spacing-2',
|
|
12783
12784
|
buttonSmallHeight: 'Size-12',
|
|
12784
12785
|
buttonSmallFontWeight: 'Weight-regular',
|
|
12785
12786
|
buttonLargeFontSize: 'Font-16',
|
|
12786
|
-
buttonLargeBorderRadius: 'Radius-
|
|
12787
|
+
buttonLargeBorderRadius: 'Radius-default',
|
|
12787
12788
|
buttonLargePaddingX: 'Spacing-16',
|
|
12788
12789
|
buttonLargePaddingY: 'Spacing-8',
|
|
12789
12790
|
buttonLargeHeight: 'Size-20',
|
|
@@ -12866,12 +12867,12 @@ var buttonTokens = {
|
|
|
12866
12867
|
buttonRoundBorderRadius: 'Radius-full',
|
|
12867
12868
|
buttonCircleBorderRadius: 'Radius-circle',
|
|
12868
12869
|
buttonSquareBorderRadius: 'Radius-default',
|
|
12869
|
-
buttonSmallRoundBorderRadius: 'Radius-
|
|
12870
|
+
buttonSmallRoundBorderRadius: 'Radius-full',
|
|
12870
12871
|
buttonSmallCircleBorderRadius: 'Radius-circle',
|
|
12871
12872
|
buttonSmallSquareBorderRadius: 'Radius-default',
|
|
12872
|
-
buttonLargeRoundBorderRadius: 'Radius-
|
|
12873
|
-
buttonLargeCircleBorderRadius: 'Radius-
|
|
12874
|
-
buttonLargeSquareBorderRadius: 'Radius-
|
|
12873
|
+
buttonLargeRoundBorderRadius: 'Radius-full',
|
|
12874
|
+
buttonLargeCircleBorderRadius: 'Radius-circle',
|
|
12875
|
+
buttonLargeSquareBorderRadius: 'Radius-default',
|
|
12875
12876
|
buttonNearlyMargin: 'Spacing-8',
|
|
12876
12877
|
buttonSpinMargin: 'Spacing-4'
|
|
12877
12878
|
};
|
|
@@ -13013,6 +13014,8 @@ var cascaderTokens = {
|
|
|
13013
13014
|
cascaderPanelRadius: 'Radius-4',
|
|
13014
13015
|
cascaderPanelBorder: 'Neutral-border-1',
|
|
13015
13016
|
cascaderOptionHeight: 'Size-16',
|
|
13017
|
+
cascaderOptionFontColor: 'Neutral-text-5',
|
|
13018
|
+
cascaderOptionBackgroundColor: 'Neutral-fill-1',
|
|
13016
13019
|
cascaderOptionPaddingX: 'Spacing-4',
|
|
13017
13020
|
cascaderOptionPaddingY: 'Spacing-1',
|
|
13018
13021
|
cascaderOptionActiveColor: 'Brand-6',
|
|
@@ -13023,6 +13026,7 @@ var cascaderTokens = {
|
|
|
13023
13026
|
cascaderOptionInnerBorderRadius: 'Radius-2',
|
|
13024
13027
|
cascaderOptionIconColor: 'Neutral-text-4',
|
|
13025
13028
|
cascaderOptionHoverBackgroundColor: 'Neutral-fill-2',
|
|
13029
|
+
cascaderOptionHoverFontColor: 'Neutral-text-5',
|
|
13026
13030
|
cascaderOptionDisabledColor: 'Neutral-text-2',
|
|
13027
13031
|
cascaderOptionDisabledBackgroundColor: 'Neutral-fill-1',
|
|
13028
13032
|
cascaderMorePaddingX: 'Spacing-16',
|
|
@@ -13482,6 +13486,7 @@ var inputTokens = {
|
|
|
13482
13486
|
inputLargePaddingX: 'Spacing-12',
|
|
13483
13487
|
inputLargePaddingY: 'Spacing-7',
|
|
13484
13488
|
inputPlaceholderColor: 'Neutral-text-2',
|
|
13489
|
+
inputPlaceholderFontWeight: 'Weight-regular',
|
|
13485
13490
|
inputBackgroundColor: 'Neutral-fill-1',
|
|
13486
13491
|
inputClearColor: 'Neutral-text-3',
|
|
13487
13492
|
inputToggleColor: 'Neutral-text-4',
|
|
@@ -13489,6 +13494,7 @@ var inputTokens = {
|
|
|
13489
13494
|
inputHoverBackgroundColor: 'Neutral-fill-1',
|
|
13490
13495
|
inputHoverClearColor: 'Neutral-text-4',
|
|
13491
13496
|
inputHoverToggleColor: 'Neutral-text-5',
|
|
13497
|
+
inputHoverIconColor: 'Brand-6',
|
|
13492
13498
|
inputFocusBorderColor: 'Brand-7',
|
|
13493
13499
|
inputFocusBackgroundColor: 'Neutral-fill-1',
|
|
13494
13500
|
inputFocusShadow: 'Brand-2',
|
|
@@ -13503,6 +13509,8 @@ var inputTokens = {
|
|
|
13503
13509
|
inputErrorFocusBorderColor: 'Danger-6',
|
|
13504
13510
|
inputErrorFocusBackgroundColor: 'Neutral-fill-1',
|
|
13505
13511
|
inputErrorFocusShadow: 'Danger-1',
|
|
13512
|
+
inputGroupFontColor: 'Neutral-text-5',
|
|
13513
|
+
inputGroupFontBackgroundColor: 'Neutral-fill-2',
|
|
13506
13514
|
inputInfoFontColor: 'Brand-6',
|
|
13507
13515
|
inputInfoBackgroundColor: 'Neutral-fill-1',
|
|
13508
13516
|
inputInfoBorderColor: 'Neutral-border-2',
|
|
@@ -14080,12 +14088,24 @@ var tableTokens = {
|
|
|
14080
14088
|
tableCellPaddingX: 'Spacing-12',
|
|
14081
14089
|
tableCellPaddingY: 'Spacing-8',
|
|
14082
14090
|
tableCellBorderColor: 'Neutral-border-1',
|
|
14091
|
+
tableCellFontSize: 'Font-14',
|
|
14092
|
+
tableCellFontWeight: 'Weight-regular',
|
|
14093
|
+
tableSmallTheadFontSize: 'Font-14',
|
|
14094
|
+
tableSmallTheadFontWeight: 'Weight-medium',
|
|
14083
14095
|
tableSmallCellPaddingX: 'Spacing-8',
|
|
14084
14096
|
tableSmallCellPaddingY: 'Spacing-4',
|
|
14097
|
+
tableSmallCellFontSize: 'Font-14',
|
|
14098
|
+
tableSmallCellFontWeight: 'Weight-regular',
|
|
14099
|
+
tableLargeTheadFontSize: 'Font-14',
|
|
14100
|
+
tableLargeTheadFontWeight: 'Weight-medium',
|
|
14085
14101
|
tableLargeCellPaddingX: 'Spacing-16',
|
|
14086
14102
|
tableLargeCellPaddingY: 'Spacing-16',
|
|
14103
|
+
tableLargeCellFontSize: 'Font-14',
|
|
14104
|
+
tableLargeCellFontWeight: 'Weight-regular',
|
|
14087
14105
|
tableFixedShadow: 'rgba(2,11,24,.1)',
|
|
14088
14106
|
tableTheadBackgroundColor: 'Neutral-fill-2',
|
|
14107
|
+
tableTheadFontSize: 'Font-14',
|
|
14108
|
+
tableTheadFontWeight: 'Weight-medium',
|
|
14089
14109
|
tableTheadFontColor: 'Neutral-text-5',
|
|
14090
14110
|
tableTbodyBackgroundColor: 'Neutral-fill-1',
|
|
14091
14111
|
tableTbodyStripedBackgroundColor: 'Neutral-fill-2',
|
|
@@ -14094,6 +14114,7 @@ var tableTokens = {
|
|
|
14094
14114
|
tableTbodyFontColor: 'Neutral-text-5',
|
|
14095
14115
|
tableTfootBackgroundColor: 'Neutral-fill-2',
|
|
14096
14116
|
tableTfootFontColor: 'Neutral-text-5',
|
|
14117
|
+
tableTfootFontWeight: 'Weight-regular',
|
|
14097
14118
|
tableExpandIconSize: 'Size-7',
|
|
14098
14119
|
tableExpandIconColor: 'Neutral-text-2',
|
|
14099
14120
|
tableExpandIconHoverBackgroundColor: 'Neutral-fill-3',
|
|
@@ -14577,7 +14598,9 @@ var treeTokens = {
|
|
|
14577
14598
|
treeSmallLineHeight: 'Size-14',
|
|
14578
14599
|
treeLargeFontSize: 'Font-16',
|
|
14579
14600
|
treeLargeLineHeight: 'Size-22',
|
|
14601
|
+
treeFontWeight: 'Weight-regular',
|
|
14580
14602
|
treeFontColor: 'Neutral-text-5',
|
|
14603
|
+
treeLineBackgroundColor: 'Neutral-fill-2',
|
|
14581
14604
|
treePaddingX: 'Spacing-8',
|
|
14582
14605
|
treePaddingY: 'Spacing-1',
|
|
14583
14606
|
treeItemFontColor: 'Neutral-text-4',
|
|
@@ -16562,6 +16585,7 @@ var cascaderStyle = objectSpread2_default()(objectSpread2_default()({
|
|
|
16562
16585
|
// hover
|
|
16563
16586
|
'&:not($optionDisabled):hover': {
|
|
16564
16587
|
'& $optionInner': {
|
|
16588
|
+
color: src.cascaderOptionHoverFontColor,
|
|
16565
16589
|
backgroundColor: src.cascaderOptionHoverBackgroundColor
|
|
16566
16590
|
}
|
|
16567
16591
|
}
|
|
@@ -16586,7 +16610,9 @@ var cascaderStyle = objectSpread2_default()(objectSpread2_default()({
|
|
|
16586
16610
|
whiteSpace: 'nowrap',
|
|
16587
16611
|
minWidth: 44,
|
|
16588
16612
|
display: 'flex',
|
|
16613
|
+
color: src.cascaderOptionFontColor,
|
|
16589
16614
|
fontSize: src.cascaderFontSize,
|
|
16615
|
+
background: src.cascaderOptionBackgroundColor,
|
|
16590
16616
|
lineHeight: src.lineHeightDynamic,
|
|
16591
16617
|
padding: "".concat(src.cascaderOptionInnerPaddingY, " ").concat(src.cascaderOptionInnerPaddingX),
|
|
16592
16618
|
paddingRight: 30,
|
|
@@ -18999,8 +19025,9 @@ var groupSpace = function groupSpace(gap) {
|
|
|
18999
19025
|
alignItems: 'center',
|
|
19000
19026
|
border: "1px solid ".concat(src.inputBorderColor),
|
|
19001
19027
|
borderWidth: '0 1px',
|
|
19002
|
-
background: src.
|
|
19028
|
+
background: src.inputGroupFontBackgroundColor,
|
|
19003
19029
|
fontWeight: 'normal',
|
|
19030
|
+
color: src.inputGroupFontColor,
|
|
19004
19031
|
'&:first-child': {
|
|
19005
19032
|
borderLeftColor: 'inherit',
|
|
19006
19033
|
marginLeft: '-1px'
|
|
@@ -19061,7 +19088,9 @@ var input_input = objectSpread2_default()(objectSpread2_default()(objectSpread2_
|
|
|
19061
19088
|
outline: 'none',
|
|
19062
19089
|
backgroundColor: 'transparent',
|
|
19063
19090
|
boxSizing: 'border-box',
|
|
19091
|
+
fontWeight: 'inherit',
|
|
19064
19092
|
'&::placeholder': {
|
|
19093
|
+
fontWeight: src.inputPlaceholderFontWeight,
|
|
19065
19094
|
color: src.inputPlaceholderColor,
|
|
19066
19095
|
fontSize: 'inherit'
|
|
19067
19096
|
}
|
|
@@ -19141,7 +19170,7 @@ var input_input = objectSpread2_default()(objectSpread2_default()(objectSpread2_
|
|
|
19141
19170
|
color: src.inputIconColor,
|
|
19142
19171
|
'&:hover': {
|
|
19143
19172
|
'$wrapper:not($wrapperDisabled) &': {
|
|
19144
|
-
color: src.
|
|
19173
|
+
color: src.inputHoverIconColor
|
|
19145
19174
|
}
|
|
19146
19175
|
},
|
|
19147
19176
|
'&:first-child': {
|
|
@@ -23689,6 +23718,8 @@ var tableStyle = objectSpread2_default()(objectSpread2_default()({}, globalStyle
|
|
|
23689
23718
|
'& td': {
|
|
23690
23719
|
background: src.tableTbodyBackgroundColor,
|
|
23691
23720
|
color: src.tableTbodyFontColor,
|
|
23721
|
+
fontSize: src.tableCellFontSize,
|
|
23722
|
+
fontWeight: src.tableCellFontWeight,
|
|
23692
23723
|
'&[data-soui-table-selection]::before': {
|
|
23693
23724
|
content: '""',
|
|
23694
23725
|
position: 'absolute',
|
|
@@ -23704,12 +23735,14 @@ var tableStyle = objectSpread2_default()(objectSpread2_default()({}, globalStyle
|
|
|
23704
23735
|
verticalAlign: 'middle',
|
|
23705
23736
|
background: src.tableTheadBackgroundColor,
|
|
23706
23737
|
color: src.tableTheadFontColor,
|
|
23707
|
-
|
|
23708
|
-
|
|
23738
|
+
boxSizing: 'border-box',
|
|
23739
|
+
fontWeight: src.tableTheadFontWeight,
|
|
23740
|
+
fontSize: src.tableTheadFontSize
|
|
23709
23741
|
},
|
|
23710
23742
|
'& tfoot td': {
|
|
23711
23743
|
background: src.tableTfootBackgroundColor,
|
|
23712
|
-
color: src.tableTfootFontColor
|
|
23744
|
+
color: src.tableTfootFontColor,
|
|
23745
|
+
fontWeight: src.tableTfootFontWeight
|
|
23713
23746
|
},
|
|
23714
23747
|
'&bordered tr:last-child td': {
|
|
23715
23748
|
borderBottom: 'none'
|
|
@@ -23737,11 +23770,27 @@ var tableStyle = objectSpread2_default()(objectSpread2_default()({}, globalStyle
|
|
|
23737
23770
|
small: {
|
|
23738
23771
|
'& th, & td': {
|
|
23739
23772
|
padding: "".concat(src.tableSmallCellPaddingY, " ").concat(src.tableSmallCellPaddingX)
|
|
23773
|
+
},
|
|
23774
|
+
'& table th': {
|
|
23775
|
+
fontSize: src.tableSmallTheadFontSize,
|
|
23776
|
+
fontWeight: src.tableSmallTheadFontWeight
|
|
23777
|
+
},
|
|
23778
|
+
'& table td': {
|
|
23779
|
+
fontSize: src.tableSmallCellFontSize,
|
|
23780
|
+
fontWeight: src.tableSmallCellFontWeight
|
|
23740
23781
|
}
|
|
23741
23782
|
},
|
|
23742
23783
|
large: {
|
|
23743
23784
|
'& th, & td': {
|
|
23744
23785
|
padding: "".concat(src.tableLargeCellPaddingY, " ").concat(src.tableLargeCellPaddingX)
|
|
23786
|
+
},
|
|
23787
|
+
'& table th': {
|
|
23788
|
+
fontSize: src.tableLargeTheadFontSize,
|
|
23789
|
+
fontWeight: src.tableLargeTheadFontWeight
|
|
23790
|
+
},
|
|
23791
|
+
'& table td': {
|
|
23792
|
+
fontSize: src.tableLargeCellFontSize,
|
|
23793
|
+
fontWeight: src.tableLargeCellFontWeight
|
|
23745
23794
|
}
|
|
23746
23795
|
},
|
|
23747
23796
|
bordered: {
|
|
@@ -25742,7 +25791,7 @@ var treeStyle = {
|
|
|
25742
25791
|
top: -6,
|
|
25743
25792
|
height: 'calc(100% + 6px)',
|
|
25744
25793
|
width: 1,
|
|
25745
|
-
background:
|
|
25794
|
+
background: src.treeLineBackgroundColor
|
|
25746
25795
|
},
|
|
25747
25796
|
'&[dir=ltr]::after': {
|
|
25748
25797
|
left: 0
|
|
@@ -25756,7 +25805,7 @@ var treeStyle = {
|
|
|
25756
25805
|
top: 18,
|
|
25757
25806
|
height: 1,
|
|
25758
25807
|
width: 16,
|
|
25759
|
-
background:
|
|
25808
|
+
background: src.treeLineBackgroundColor
|
|
25760
25809
|
}
|
|
25761
25810
|
},
|
|
25762
25811
|
'& $node:first-child': {},
|
|
@@ -25864,6 +25913,7 @@ var treeStyle = {
|
|
|
25864
25913
|
fontSize: src.treeFontSize,
|
|
25865
25914
|
lineHeight: src.lineHeightDynamic,
|
|
25866
25915
|
color: src.treeFontColor,
|
|
25916
|
+
fontWeight: src.treeFontWeight,
|
|
25867
25917
|
paddingTop: src.treeTextPaddingY,
|
|
25868
25918
|
paddingBottom: src.treeTextPaddingY
|
|
25869
25919
|
},
|
|
@@ -34159,18 +34209,14 @@ function castImmutable(value) {
|
|
|
34159
34209
|
}
|
|
34160
34210
|
|
|
34161
34211
|
;// CONCATENATED MODULE: ../hooks/src/utils/immer.ts
|
|
34162
|
-
// import { produce as produce2, getSnapshot } from '@shined/reactive/vanilla';
|
|
34163
|
-
|
|
34164
|
-
// export const produce = ((...args: any) => {
|
|
34165
|
-
// return produce2.apply(null, args);
|
|
34166
|
-
// }) as typeof produce2;
|
|
34167
|
-
|
|
34168
|
-
// export const current = getSnapshot;
|
|
34169
|
-
|
|
34170
34212
|
|
|
34171
34213
|
|
|
34172
|
-
var utils_immer_produce = function produce(
|
|
34173
|
-
|
|
34214
|
+
var utils_immer_produce = function produce() {
|
|
34215
|
+
setAutoFreeze(false);
|
|
34216
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
34217
|
+
args[_key] = arguments[_key];
|
|
34218
|
+
}
|
|
34219
|
+
return immer_produce.apply(null, args);
|
|
34174
34220
|
};
|
|
34175
34221
|
;// CONCATENATED MODULE: ../hooks/src/utils/clone.ts
|
|
34176
34222
|
|
|
@@ -46891,7 +46937,7 @@ var Scroll = function Scroll(props) {
|
|
|
46891
46937
|
position: 'sticky'
|
|
46892
46938
|
}, isRtl ? 'right' : 'left', 0), "top", 0);
|
|
46893
46939
|
var placeStyle = defineProperty_default()(defineProperty_default()(defineProperty_default()(defineProperty_default()({
|
|
46894
|
-
marginTop: Math.max(0, scrollHeight - height)
|
|
46940
|
+
marginTop: Math.max(0, Math.floor(scrollHeight - height))
|
|
46895
46941
|
}, "margin".concat(isRtl ? 'Left' : 'Right'), scrollWidth), "height", 0), "width", 0), "overflow", 'hidden');
|
|
46896
46942
|
var handleScroll = usePersistFn(function (e) {
|
|
46897
46943
|
var target = e.currentTarget;
|
|
@@ -47918,7 +47964,7 @@ var Node = function Node(props) {
|
|
|
47918
47964
|
var children = data[childrenKey];
|
|
47919
47965
|
var hasChildren = children && children.length > 0;
|
|
47920
47966
|
var contentStyle = (jssStyle === null || jssStyle === void 0 ? void 0 : jssStyle.tree()) || {};
|
|
47921
|
-
var rootClass = classnames_default()(contentStyle.node, isLeaf() && leafClass, isString(nodeClass) && nodeClass, isFunc(nodeClass) && nodeClass(data), defineProperty_default()({}, contentStyle.leaf, !hasChildren));
|
|
47967
|
+
var rootClass = classnames_default()(contentStyle.node, isLeaf() && (isString(leafClass) ? leafClass : isFunc(leafClass) && leafClass(data)), isString(nodeClass) && nodeClass, isFunc(nodeClass) && nodeClass(data), defineProperty_default()({}, contentStyle.leaf, !hasChildren));
|
|
47922
47968
|
if (placeElement) {
|
|
47923
47969
|
placeElement.className = contentStyle.placement;
|
|
47924
47970
|
}
|
|
@@ -48413,6 +48459,10 @@ var Tree = function Tree(props) {
|
|
|
48413
48459
|
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
|
|
48414
48460
|
handleUpdateExpanded(expanded);
|
|
48415
48461
|
}, [expanded]);
|
|
48462
|
+
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
|
|
48463
|
+
if (!active) return;
|
|
48464
|
+
handleUpdateActive(active);
|
|
48465
|
+
}, [active]);
|
|
48416
48466
|
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
|
|
48417
48467
|
if (getDatum) getDatum(datum);
|
|
48418
48468
|
}, []);
|
|
@@ -54164,7 +54214,8 @@ var useTableLayout = function useTableLayout(props) {
|
|
|
54164
54214
|
changeColGroup(newCols, false);
|
|
54165
54215
|
});
|
|
54166
54216
|
var checkFloat = use_persist_fn(function () {
|
|
54167
|
-
var scrollEl = scrollRef.current;
|
|
54217
|
+
var scrollEl = scrollRef === null || scrollRef === void 0 ? void 0 : scrollRef.current;
|
|
54218
|
+
if (!scrollEl) return;
|
|
54168
54219
|
var max = scrollEl.scrollWidth - scrollEl.clientWidth;
|
|
54169
54220
|
var min = 0;
|
|
54170
54221
|
var left = scrollEl.scrollLeft;
|
|
@@ -55773,10 +55824,12 @@ var Tr = function Tr(props) {
|
|
|
55773
55824
|
|
|
55774
55825
|
|
|
55775
55826
|
|
|
55827
|
+
|
|
55776
55828
|
var tfoot_isArray = isArray;
|
|
55777
55829
|
/* harmony default export */ var tfoot = (function (props) {
|
|
55778
55830
|
var _props$jssStyle, _props$jssStyle$table;
|
|
55779
55831
|
var tableClasses = (_props$jssStyle = props.jssStyle) === null || _props$jssStyle === void 0 || (_props$jssStyle$table = _props$jssStyle.table) === null || _props$jssStyle$table === void 0 ? void 0 : _props$jssStyle$table.call(_props$jssStyle);
|
|
55832
|
+
var config = useConfig();
|
|
55780
55833
|
var getFixedStyle = function getFixedStyle(fixed, index, colSpan) {
|
|
55781
55834
|
var colgroup = props.colgroup;
|
|
55782
55835
|
if (fixed === 'left') {
|
|
@@ -55829,9 +55882,10 @@ var tfoot_isArray = isArray;
|
|
|
55829
55882
|
}
|
|
55830
55883
|
}
|
|
55831
55884
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("td", {
|
|
55885
|
+
dir: config.direction,
|
|
55832
55886
|
colSpan: colSpan,
|
|
55833
55887
|
style: getFixedStyle(fixed.fixed, index, colSpan),
|
|
55834
|
-
className: classnames_default()(fixed['fixed'] === 'left' && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellFixedLeft), fixed['fixed'] === 'right' && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellFixedRight), (fixed.lastFixed || fixed.firstFixed) && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellFixedLast), isLast && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellIgnoreBorder)),
|
|
55888
|
+
className: classnames_default()(fixed['fixed'] === 'left' && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellFixedLeft), fixed['fixed'] === 'right' && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellFixedRight), fixed.firstFixed && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellFixedLeft), fixed.lastFixed && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellFixedRight), (fixed.lastFixed || fixed.firstFixed) && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellFixedLast), isLast && (tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.cellIgnoreBorder)),
|
|
55835
55889
|
children: content
|
|
55836
55890
|
}, index);
|
|
55837
55891
|
};
|
|
@@ -55896,6 +55950,9 @@ var virtualScrollerStyle = {
|
|
|
55896
55950
|
overflow: 'auto',
|
|
55897
55951
|
width: '100%'
|
|
55898
55952
|
};
|
|
55953
|
+
var table_emptyStyle = objectSpread2_default()(objectSpread2_default()({}, virtualScrollerStyle), {}, {
|
|
55954
|
+
height: 0
|
|
55955
|
+
});
|
|
55899
55956
|
var scrollWrapperStyle = {
|
|
55900
55957
|
flex: 1,
|
|
55901
55958
|
minHeight: 0,
|
|
@@ -56066,6 +56123,18 @@ var emptyRef = {
|
|
|
56066
56123
|
e.preventDefault();
|
|
56067
56124
|
scrollEl.scrollLeft = Math.min(Math.max(scrollLeft, 0), max);
|
|
56068
56125
|
});
|
|
56126
|
+
var handleBodyScroll = usePersistFn(function (e) {
|
|
56127
|
+
var target = e.currentTarget;
|
|
56128
|
+
if (!target) return;
|
|
56129
|
+
layoutFunc.checkFloat();
|
|
56130
|
+
if (props.onScroll && typeof props.onScroll === 'function') {
|
|
56131
|
+
var maxWidth = target.scrollWidth - target.clientWidth;
|
|
56132
|
+
var maxHeight = target.scrollHeight - target.clientHeight;
|
|
56133
|
+
var x = Math.min(target.scrollLeft / maxWidth, 1);
|
|
56134
|
+
var y = Math.min(target.scrollTop / maxHeight, 1);
|
|
56135
|
+
props.onScroll(x, y, target.scrollLeft);
|
|
56136
|
+
}
|
|
56137
|
+
});
|
|
56069
56138
|
var handleVirtualScroll = usePersistFn(function (info) {
|
|
56070
56139
|
virtualInfo.handleScroll(info);
|
|
56071
56140
|
layoutFunc.checkFloat();
|
|
@@ -56084,7 +56153,7 @@ var emptyRef = {
|
|
|
56084
56153
|
});
|
|
56085
56154
|
};
|
|
56086
56155
|
var renderTable = function renderTable() {
|
|
56087
|
-
var _props$summary, _sticky$top;
|
|
56156
|
+
var _props$summary, _sticky$top, _props$data3, _props$data4;
|
|
56088
56157
|
var Group = /*#__PURE__*/(0,jsx_runtime.jsx)(table_colgroup, {
|
|
56089
56158
|
colgroup: colgroup,
|
|
56090
56159
|
columns: columns,
|
|
@@ -56157,6 +56226,20 @@ var emptyRef = {
|
|
|
56157
56226
|
css: sticky === null || sticky === void 0 ? void 0 : sticky.css,
|
|
56158
56227
|
parent: tableRef === null || tableRef === void 0 ? void 0 : tableRef.current
|
|
56159
56228
|
};
|
|
56229
|
+
if (!virtual && !isScrollY && !props.sticky && (_props$data3 = props.data) !== null && _props$data3 !== void 0 && _props$data3.length) {
|
|
56230
|
+
return /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
56231
|
+
ref: scrollRef,
|
|
56232
|
+
className: tableClasses === null || tableClasses === void 0 ? void 0 : tableClasses.bodyWrapper,
|
|
56233
|
+
onScroll: handleBodyScroll,
|
|
56234
|
+
children: /*#__PURE__*/(0,jsx_runtime.jsxs)("table", {
|
|
56235
|
+
style: {
|
|
56236
|
+
width: width
|
|
56237
|
+
},
|
|
56238
|
+
ref: tbodyRef,
|
|
56239
|
+
children: [Group, !props.hideHeader && /*#__PURE__*/(0,jsx_runtime.jsx)(thead, objectSpread2_default()({}, headCommonProps)), /*#__PURE__*/(0,jsx_runtime.jsx)(tbody, objectSpread2_default()({}, bodyCommonProps)), /*#__PURE__*/(0,jsx_runtime.jsx)(tfoot, objectSpread2_default()({}, footCommonProps))]
|
|
56240
|
+
})
|
|
56241
|
+
});
|
|
56242
|
+
}
|
|
56160
56243
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)(jsx_runtime.Fragment, {
|
|
56161
56244
|
children: [!props.hideHeader && /*#__PURE__*/(0,jsx_runtime.jsx)(Wrapper, objectSpread2_default()(objectSpread2_default()({}, props.sticky ? stickyProps : {}), {}, {
|
|
56162
56245
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
@@ -56175,7 +56258,7 @@ var emptyRef = {
|
|
|
56175
56258
|
})
|
|
56176
56259
|
})), /*#__PURE__*/(0,jsx_runtime.jsx)(virtual_scroll_scroll, {
|
|
56177
56260
|
style: scrollWrapperStyle,
|
|
56178
|
-
scrollerStyle: virtualScrollerStyle,
|
|
56261
|
+
scrollerStyle: (_props$data4 = props.data) !== null && _props$data4 !== void 0 && _props$data4.length ? virtualScrollerStyle : table_emptyStyle,
|
|
56179
56262
|
wrapperRef: scrollRef,
|
|
56180
56263
|
scrollWidth: width || 1,
|
|
56181
56264
|
scrollHeight: virtual ? virtualInfo.scrollHeight : tbodyHeight,
|
|
@@ -58177,13 +58260,13 @@ var useTreeSelect = function useTreeSelect(props) {
|
|
|
58177
58260
|
}
|
|
58178
58261
|
if (!multiple && isArray(v)) {
|
|
58179
58262
|
onChange === null || onChange === void 0 || onChange.apply(void 0, [v[0]].concat(reset));
|
|
58180
|
-
}
|
|
58181
|
-
if (multiple && !isArray(v)) {
|
|
58263
|
+
} else if (multiple && !isArray(v)) {
|
|
58182
58264
|
if (v === undefined || v === null) {
|
|
58183
58265
|
onChange === null || onChange === void 0 || onChange.apply(void 0, [[]].concat(reset));
|
|
58184
58266
|
} else onChange === null || onChange === void 0 || onChange.apply(void 0, [[v]].concat(reset));
|
|
58267
|
+
} else {
|
|
58268
|
+
onChange === null || onChange === void 0 || onChange.apply(void 0, [v].concat(reset));
|
|
58185
58269
|
}
|
|
58186
|
-
onChange === null || onChange === void 0 || onChange.apply(void 0, [v].concat(reset));
|
|
58187
58270
|
});
|
|
58188
58271
|
return {
|
|
58189
58272
|
value: valueArr,
|
|
@@ -58347,6 +58430,7 @@ var TreeSelect = function TreeSelect(props0) {
|
|
|
58347
58430
|
data: data,
|
|
58348
58431
|
unmatch: unmatch,
|
|
58349
58432
|
disabled: disabled,
|
|
58433
|
+
active: multiple ? undefined : value[0],
|
|
58350
58434
|
childrenKey: childrenKey,
|
|
58351
58435
|
keygen: keygen,
|
|
58352
58436
|
onExpand: onExpand,
|
|
@@ -58712,7 +58796,7 @@ var TreeSelect = function TreeSelect(props0) {
|
|
|
58712
58796
|
} else {
|
|
58713
58797
|
treeProps.onClick = handleTreeClick;
|
|
58714
58798
|
treeProps.renderItem = renderActive;
|
|
58715
|
-
treeProps.active = value;
|
|
58799
|
+
treeProps.active = value[0];
|
|
58716
58800
|
}
|
|
58717
58801
|
if ('expanded' in props) {
|
|
58718
58802
|
treeProps.expanded = expanded;
|
|
@@ -58733,6 +58817,7 @@ var TreeSelect = function TreeSelect(props0) {
|
|
|
58733
58817
|
keygen: keygen,
|
|
58734
58818
|
unmatch: unmatch,
|
|
58735
58819
|
value: value,
|
|
58820
|
+
highlight: true,
|
|
58736
58821
|
loader: loader,
|
|
58737
58822
|
onExpand: onExpandTree,
|
|
58738
58823
|
expanded: controlExpanded,
|
|
@@ -62370,7 +62455,7 @@ var upload_interface = __webpack_require__(4412);
|
|
|
62370
62455
|
|
|
62371
62456
|
|
|
62372
62457
|
/* harmony default export */ var src_0 = ({
|
|
62373
|
-
version: '3.2.0-rc.
|
|
62458
|
+
version: '3.2.0-rc.4'
|
|
62374
62459
|
});
|
|
62375
62460
|
}();
|
|
62376
62461
|
/******/ return __webpack_exports__;
|