@qn-pandora/pandora-component 3.0.2 → 4.0.0
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.json +20 -0
- package/CHANGELOG.md +9 -1
- package/es/components/AutoComplete/style.css +25 -29
- package/es/components/Button/index.d.ts +0 -8
- package/es/components/Button/index.js +4 -4
- package/es/components/Button/style.css +100 -104
- package/es/components/Button/style.less +3 -14
- package/es/components/Card/style.css +28 -2
- package/es/components/CheckTransformList/Item/index.js +7 -3
- package/es/components/CheckTransformList/style.css +50 -21
- package/es/components/Checkbox/style.css +1 -1
- package/es/components/CheckboxList/index.d.ts +2 -0
- package/es/components/CheckboxList/index.js +2 -2
- package/es/components/CheckboxList/style.css +5 -3
- package/es/components/CheckboxList/style.less +4 -2
- package/es/components/Collapse/Panel/index.d.ts +8 -40
- package/es/components/Collapse/Panel/index.js +34 -45
- package/es/components/Collapse/index.d.ts +15 -20
- package/es/components/Collapse/index.js +44 -18
- package/es/components/Collapse/style.css +214 -0
- package/es/components/Collapse/style.less +57 -0
- package/es/components/CollapsiblePanel/style.css +4 -4
- package/es/components/CollapsiblePanel/style.less +4 -4
- package/es/components/DateTimePicker/Base/index.d.ts +1 -0
- package/es/components/DateTimePicker/Base/index.js +29 -13
- package/es/components/DateTimePicker/Base/relativeTimePicker.d.ts +1 -0
- package/es/components/DateTimePicker/Base/relativeTimePicker.js +16 -3
- package/es/components/DateTimePicker/Base/style.css +378 -49
- package/es/components/DateTimePicker/Base/style.less +37 -41
- package/es/components/DateTimePicker/BaseMobile/Absolute/index.d.ts +1 -0
- package/es/components/DateTimePicker/BaseMobile/Absolute/index.js +8 -3
- package/es/components/DateTimePicker/BaseMobile/index.d.ts +2 -0
- package/es/components/DateTimePicker/BaseMobile/index.js +7 -2
- package/es/components/DateTimePicker/BaseMobile/style.css +4 -4
- package/es/components/DateTimePicker/BaseMobile/style.less +4 -4
- package/es/components/DateTimePicker/Collapse/Panel/index.d.ts +41 -0
- package/es/components/DateTimePicker/Collapse/Panel/index.js +51 -0
- package/es/components/{Collapse → DateTimePicker/Collapse}/Panel/style.css +0 -0
- package/es/components/{Collapse → DateTimePicker/Collapse}/Panel/style.less +1 -1
- package/es/components/DateTimePicker/Collapse/index.d.ts +24 -0
- package/es/components/DateTimePicker/Collapse/index.js +42 -0
- package/es/components/DateTimePicker/DisplayInput/index.d.ts +1 -0
- package/es/components/DateTimePicker/DisplayInput/index.js +4 -1
- package/es/components/DateTimePicker/DisplayInput/style.css +47 -16
- package/es/components/DateTimePicker/constants.d.ts +5 -6
- package/es/components/DateTimePicker/constants.js +56 -50
- package/es/components/DateTimePicker/index.js +1 -1
- package/es/components/DateTimePicker/style.css +7 -7
- package/es/components/DateTimePicker/style.less +12 -10
- package/es/components/DateTimePicker/time.d.ts +2 -2
- package/es/components/DateTimePicker/time.js +17 -11
- package/es/components/DateTimePicker/transform.d.ts +4 -0
- package/es/components/DateTimePicker/transform.js +52 -0
- package/es/components/Drawer/style.css +45 -45
- package/es/components/Input/index.d.ts +1 -2
- package/es/components/Input/index.js +0 -2
- package/es/components/Input/style.css +47 -16
- package/es/components/InputNumber/index.d.ts +1 -8
- package/es/components/InputNumber/index.js +1 -35
- package/es/components/Menu/Option.d.ts +4 -0
- package/es/components/Menu/Option.js +2 -1
- package/es/components/Menu/index.d.ts +1 -1
- package/es/components/Menu/style.css +20 -10
- package/es/components/Menu/style.less +10 -0
- package/es/components/NameLimiter/style.css +2 -4
- package/es/components/NameLimiter/style.less +2 -4
- package/es/components/OptionList/OptionItem/style.css +2 -2
- package/es/components/OptionList/OptionItem/style.less +2 -2
- package/es/components/OptionList/style.css +2 -2
- package/es/components/RadioGroup/index.d.ts +53 -0
- package/es/components/RadioGroup/index.js +31 -0
- package/es/components/{SolidRadioGroup → RadioGroup}/style.css +43 -49
- package/es/components/RadioGroup/style.less +32 -0
- package/es/components/RangeInput/index.js +13 -7
- package/es/components/RangeInput/style.css +427 -27
- package/es/components/RemarkName/style.css +2 -4
- package/es/components/Selector/index.js +2 -2
- package/es/components/Selector/style.css +25 -29
- package/es/components/Selector/style.less +27 -28
- package/es/components/SolidRadioGroup/index.d.ts +3 -45
- package/es/components/SolidRadioGroup/index.js +13 -25
- package/es/components/Spin/style.css +0 -1
- package/es/components/Steps/ControlButton/index.js +8 -2
- package/es/components/Steps/style.css +8 -11
- package/es/components/Steps/style.less +9 -12
- package/es/components/Table/index.d.ts +1 -0
- package/es/components/Table/index.js +14 -5
- package/es/components/Table/style.css +91 -25
- package/es/components/Table/style.less +20 -20
- package/es/components/Tabs/style.css +29 -1
- package/es/components/Tabs/style.less +3 -1
- package/es/components/TagList/style.css +10 -10
- package/es/components/TagList/style.less +1 -1
- package/es/components/Timeline/TimelineItem/index.js +6 -4
- package/es/components/Timeline/TimelineItem/style.css +1 -2
- package/es/components/Timeline/TimelineItem/style.less +1 -2
- package/es/components/Transfer/List/index.js +10 -5
- package/es/components/Transfer/List/style.css +3 -0
- package/es/components/Transfer/List/style.less +4 -0
- package/es/components/Transfer/style.css +3 -0
- package/es/components/TreeSelector/style.css +64 -20
- package/es/components/TreeSelector/style.less +9 -7
- package/es/constants/language/check_transform_list/en.d.ts +2 -0
- package/es/constants/language/check_transform_list/en.js +5 -0
- package/es/constants/language/check_transform_list/type.d.ts +6 -0
- package/es/constants/language/check_transform_list/type.js +3 -0
- package/es/constants/language/check_transform_list/zh.d.ts +2 -0
- package/es/constants/language/check_transform_list/zh.js +5 -0
- package/es/constants/language/datetime/en.d.ts +2 -0
- package/es/constants/language/datetime/en.js +79 -0
- package/es/constants/language/datetime/type.d.ts +80 -0
- package/es/constants/language/datetime/type.js +3 -0
- package/es/constants/language/datetime/zh.d.ts +2 -0
- package/es/constants/language/datetime/zh.js +79 -0
- package/es/constants/language/en.d.ts +2 -0
- package/es/constants/language/en.js +14 -0
- package/es/constants/language/range_input/en.d.ts +2 -0
- package/es/constants/language/range_input/en.js +7 -0
- package/es/constants/language/range_input/type.d.ts +8 -0
- package/es/constants/language/range_input/type.js +3 -0
- package/es/constants/language/range_input/zh.d.ts +2 -0
- package/es/constants/language/range_input/zh.js +7 -0
- package/es/constants/language/steps/en.d.ts +2 -0
- package/es/constants/language/steps/en.js +4 -0
- package/es/constants/language/steps/type.d.ts +5 -0
- package/es/constants/language/steps/type.js +3 -0
- package/es/constants/language/steps/zh.d.ts +2 -0
- package/es/constants/language/steps/zh.js +4 -0
- package/es/constants/language/table/en.d.ts +2 -0
- package/es/constants/language/table/en.js +4 -0
- package/es/constants/language/table/type.d.ts +5 -0
- package/es/constants/language/table/type.js +3 -0
- package/es/constants/language/table/zh.d.ts +2 -0
- package/es/constants/language/table/zh.js +4 -0
- package/es/constants/language/transfer/en.d.ts +2 -0
- package/es/constants/language/transfer/en.js +4 -0
- package/es/constants/language/transfer/type.d.ts +5 -0
- package/es/constants/language/transfer/type.js +3 -0
- package/es/constants/language/transfer/zh.d.ts +2 -0
- package/es/constants/language/transfer/zh.js +4 -0
- package/es/constants/language/type.d.ts +15 -0
- package/es/constants/language/type.js +3 -0
- package/es/constants/language/zh.d.ts +2 -0
- package/es/constants/language/zh.js +14 -0
- package/es/index.css +3570 -2886
- package/es/index.d.ts +3 -2
- package/es/index.js +2 -1
- package/es/index.less +4 -5
- package/es/style/theme.less +9 -0
- package/es/utils/language.d.ts +1 -0
- package/es/utils/language.js +15 -0
- package/es/utils/languageLocale.d.ts +1 -0
- package/es/utils/languageLocale.js +9 -0
- package/lib/components/AutoComplete/style.css +25 -29
- package/lib/components/Button/index.d.ts +0 -8
- package/lib/components/Button/index.js +4 -4
- package/lib/components/Button/style.css +100 -104
- package/lib/components/Button/style.less +3 -14
- package/lib/components/Card/style.css +28 -2
- package/lib/components/CheckTransformList/Item/index.js +7 -3
- package/lib/components/CheckTransformList/style.css +50 -21
- package/lib/components/Checkbox/style.css +1 -1
- package/lib/components/CheckboxList/index.d.ts +2 -0
- package/lib/components/CheckboxList/index.js +2 -2
- package/lib/components/CheckboxList/style.css +5 -3
- package/lib/components/CheckboxList/style.less +4 -2
- package/lib/components/Collapse/Panel/index.d.ts +8 -40
- package/lib/components/Collapse/Panel/index.js +35 -46
- package/lib/components/Collapse/index.d.ts +15 -20
- package/lib/components/Collapse/index.js +47 -20
- package/lib/components/Collapse/style.css +214 -0
- package/lib/components/Collapse/style.less +57 -0
- package/lib/components/CollapsiblePanel/style.css +4 -4
- package/lib/components/CollapsiblePanel/style.less +4 -4
- package/lib/components/DateTimePicker/Base/index.d.ts +1 -0
- package/lib/components/DateTimePicker/Base/index.js +29 -13
- package/lib/components/DateTimePicker/Base/relativeTimePicker.d.ts +1 -0
- package/lib/components/DateTimePicker/Base/relativeTimePicker.js +16 -3
- package/lib/components/DateTimePicker/Base/style.css +378 -49
- package/lib/components/DateTimePicker/Base/style.less +37 -41
- package/lib/components/DateTimePicker/BaseMobile/Absolute/index.d.ts +1 -0
- package/lib/components/DateTimePicker/BaseMobile/Absolute/index.js +8 -3
- package/lib/components/DateTimePicker/BaseMobile/index.d.ts +2 -0
- package/lib/components/DateTimePicker/BaseMobile/index.js +7 -2
- package/lib/components/DateTimePicker/BaseMobile/style.css +4 -4
- package/lib/components/DateTimePicker/BaseMobile/style.less +4 -4
- package/lib/components/DateTimePicker/Collapse/Panel/index.d.ts +41 -0
- package/lib/components/DateTimePicker/Collapse/Panel/index.js +64 -0
- package/lib/components/{Collapse → DateTimePicker/Collapse}/Panel/style.css +0 -0
- package/lib/components/{Collapse → DateTimePicker/Collapse}/Panel/style.less +1 -1
- package/lib/components/DateTimePicker/Collapse/index.d.ts +24 -0
- package/lib/components/DateTimePicker/Collapse/index.js +54 -0
- package/lib/components/DateTimePicker/DisplayInput/index.d.ts +1 -0
- package/lib/components/DateTimePicker/DisplayInput/index.js +4 -1
- package/lib/components/DateTimePicker/DisplayInput/style.css +47 -16
- package/lib/components/DateTimePicker/constants.d.ts +5 -6
- package/lib/components/DateTimePicker/constants.js +56 -50
- package/lib/components/DateTimePicker/index.js +1 -1
- package/lib/components/DateTimePicker/style.css +7 -7
- package/lib/components/DateTimePicker/style.less +12 -10
- package/lib/components/DateTimePicker/time.d.ts +2 -2
- package/lib/components/DateTimePicker/time.js +16 -10
- package/lib/components/DateTimePicker/transform.d.ts +4 -0
- package/lib/components/DateTimePicker/transform.js +53 -0
- package/lib/components/Drawer/style.css +45 -45
- package/lib/components/Input/index.d.ts +1 -2
- package/lib/components/Input/index.js +0 -2
- package/lib/components/Input/style.css +47 -16
- package/lib/components/InputNumber/index.d.ts +1 -8
- package/lib/components/InputNumber/index.js +1 -38
- package/lib/components/Menu/Option.d.ts +4 -0
- package/lib/components/Menu/Option.js +2 -1
- package/lib/components/Menu/index.d.ts +1 -1
- package/lib/components/Menu/style.css +20 -10
- package/lib/components/Menu/style.less +10 -0
- package/lib/components/NameLimiter/style.css +2 -4
- package/lib/components/NameLimiter/style.less +2 -4
- package/lib/components/OptionList/OptionItem/style.css +2 -2
- package/lib/components/OptionList/OptionItem/style.less +2 -2
- package/lib/components/OptionList/style.css +2 -2
- package/lib/components/RadioGroup/index.d.ts +53 -0
- package/lib/components/RadioGroup/index.js +44 -0
- package/lib/components/{SolidRadioGroup → RadioGroup}/style.css +43 -49
- package/lib/components/RadioGroup/style.less +32 -0
- package/lib/components/RangeInput/index.js +13 -7
- package/lib/components/RangeInput/style.css +427 -27
- package/lib/components/RemarkName/style.css +2 -4
- package/lib/components/Selector/index.js +1 -1
- package/lib/components/Selector/style.css +25 -29
- package/lib/components/Selector/style.less +27 -28
- package/lib/components/SolidRadioGroup/index.d.ts +3 -45
- package/lib/components/SolidRadioGroup/index.js +13 -25
- package/lib/components/Spin/style.css +0 -1
- package/lib/components/Steps/ControlButton/index.js +8 -2
- package/lib/components/Steps/style.css +8 -11
- package/lib/components/Steps/style.less +9 -12
- package/lib/components/Table/index.d.ts +1 -0
- package/lib/components/Table/index.js +14 -5
- package/lib/components/Table/style.css +91 -25
- package/lib/components/Table/style.less +20 -20
- package/lib/components/Tabs/style.css +29 -1
- package/lib/components/Tabs/style.less +3 -1
- package/lib/components/TagList/style.css +10 -10
- package/lib/components/TagList/style.less +1 -1
- package/lib/components/Timeline/TimelineItem/index.js +6 -4
- package/lib/components/Timeline/TimelineItem/style.css +1 -2
- package/lib/components/Timeline/TimelineItem/style.less +1 -2
- package/lib/components/Transfer/List/index.js +9 -4
- package/lib/components/Transfer/List/style.css +3 -0
- package/lib/components/Transfer/List/style.less +4 -0
- package/lib/components/Transfer/style.css +3 -0
- package/lib/components/TreeSelector/style.css +64 -20
- package/lib/components/TreeSelector/style.less +9 -7
- package/lib/constants/language/check_transform_list/en.d.ts +2 -0
- package/lib/constants/language/check_transform_list/en.js +7 -0
- package/lib/constants/language/check_transform_list/type.d.ts +6 -0
- package/lib/constants/language/check_transform_list/type.js +5 -0
- package/lib/constants/language/check_transform_list/zh.d.ts +2 -0
- package/lib/constants/language/check_transform_list/zh.js +7 -0
- package/lib/constants/language/datetime/en.d.ts +2 -0
- package/lib/constants/language/datetime/en.js +81 -0
- package/lib/constants/language/datetime/type.d.ts +80 -0
- package/lib/constants/language/datetime/type.js +5 -0
- package/lib/constants/language/datetime/zh.d.ts +2 -0
- package/lib/constants/language/datetime/zh.js +81 -0
- package/lib/constants/language/en.d.ts +2 -0
- package/lib/constants/language/en.js +16 -0
- package/lib/constants/language/range_input/en.d.ts +2 -0
- package/lib/constants/language/range_input/en.js +9 -0
- package/lib/constants/language/range_input/type.d.ts +8 -0
- package/lib/constants/language/range_input/type.js +5 -0
- package/lib/constants/language/range_input/zh.d.ts +2 -0
- package/lib/constants/language/range_input/zh.js +9 -0
- package/lib/constants/language/steps/en.d.ts +2 -0
- package/lib/constants/language/steps/en.js +6 -0
- package/lib/constants/language/steps/type.d.ts +5 -0
- package/lib/constants/language/steps/type.js +5 -0
- package/lib/constants/language/steps/zh.d.ts +2 -0
- package/lib/constants/language/steps/zh.js +6 -0
- package/lib/constants/language/table/en.d.ts +2 -0
- package/lib/constants/language/table/en.js +6 -0
- package/lib/constants/language/table/type.d.ts +5 -0
- package/lib/constants/language/table/type.js +5 -0
- package/lib/constants/language/table/zh.d.ts +2 -0
- package/lib/constants/language/table/zh.js +6 -0
- package/lib/constants/language/transfer/en.d.ts +2 -0
- package/lib/constants/language/transfer/en.js +6 -0
- package/lib/constants/language/transfer/type.d.ts +5 -0
- package/lib/constants/language/transfer/type.js +5 -0
- package/lib/constants/language/transfer/zh.d.ts +2 -0
- package/lib/constants/language/transfer/zh.js +6 -0
- package/lib/constants/language/type.d.ts +15 -0
- package/lib/constants/language/type.js +5 -0
- package/lib/constants/language/zh.d.ts +2 -0
- package/lib/constants/language/zh.js +16 -0
- package/lib/index.css +3637 -2953
- package/lib/index.d.ts +3 -2
- package/lib/index.js +3 -0
- package/lib/index.less +7 -8
- package/lib/style/theme.less +9 -0
- package/lib/utils/language.d.ts +1 -0
- package/lib/utils/language.js +21 -0
- package/lib/utils/languageLocale.d.ts +1 -0
- package/lib/utils/languageLocale.js +12 -0
- package/package.json +15 -41
- package/es/components/Collapse/stories/style.stories.css +0 -12
- package/es/components/Collapse/stories/style.stories.less +0 -7
- package/es/components/Input/NumberInput/index.d.ts +0 -29
- package/es/components/Input/NumberInput/index.js +0 -116
- package/es/components/InputNumber/style.css +0 -400
- package/es/components/InputNumber/style.less +0 -45
- package/es/components/SolidRadioGroup/style.less +0 -39
- package/lib/components/Collapse/stories/style.stories.css +0 -12
- package/lib/components/Collapse/stories/style.stories.less +0 -7
- package/lib/components/Input/NumberInput/index.d.ts +0 -29
- package/lib/components/Input/NumberInput/index.js +0 -121
- package/lib/components/InputNumber/style.css +0 -400
- package/lib/components/InputNumber/style.less +0 -45
- package/lib/components/SolidRadioGroup/style.less +0 -39
@@ -43,7 +43,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
43
43
|
return t;
|
44
44
|
};
|
45
45
|
import * as React from 'react';
|
46
|
-
import { isArray, concat } from 'lodash';
|
46
|
+
import { isArray, concat, isNumber, toString } from 'lodash';
|
47
47
|
import classnames from 'classnames';
|
48
48
|
import { Checkbox, Select } from 'antd';
|
49
49
|
import PropTypes from 'prop-types';
|
@@ -74,7 +74,7 @@ var formatOptions = function (options) {
|
|
74
74
|
var getOptionComponent = function (options) {
|
75
75
|
return options.map(function (option) {
|
76
76
|
var key = option.key, value = option.value, disabled = option.disabled, text = option.text;
|
77
|
-
return (React.createElement(Select.Option, { key: key || value, value: value, disabled: disabled }, text));
|
77
|
+
return (React.createElement(Select.Option, { key: key || value, value: value, disabled: disabled }, isNumber(text) ? toString(text) : text));
|
78
78
|
});
|
79
79
|
};
|
80
80
|
var getGroupComponent = function (options, groupOptions) {
|
@@ -379,11 +379,11 @@
|
|
379
379
|
cursor: auto;
|
380
380
|
}
|
381
381
|
.ant-select-focused:not(.ant-select-disabled).ant-select:not(.ant-select-customize-input) .ant-select-selector {
|
382
|
-
border-color: #
|
382
|
+
border-color: #9ca0a6;
|
383
|
+
-webkit-box-shadow: 0 0 0 2px rgba(122, 134, 154, 0.2);
|
384
|
+
box-shadow: 0 0 0 2px rgba(122, 134, 154, 0.2);
|
383
385
|
border-right-width: 1px !important;
|
384
386
|
outline: 0;
|
385
|
-
-webkit-box-shadow: 0 0 0 2px rgba(44, 109, 210, 0.2);
|
386
|
-
box-shadow: 0 0 0 2px rgba(44, 109, 210, 0.2);
|
387
387
|
}
|
388
388
|
.ant-select-disabled.ant-select:not(.ant-select-customize-input) .ant-select-selector {
|
389
389
|
color: rgba(0, 0, 0, 0.25);
|
@@ -408,6 +408,7 @@
|
|
408
408
|
}
|
409
409
|
.ant-select:not(.ant-select-customize-input) .ant-select-selector .ant-select-selection-search-input::-webkit-search-cancel-button {
|
410
410
|
display: none;
|
411
|
+
/* stylelint-disable-next-line property-no-vendor-prefix */
|
411
412
|
-webkit-appearance: none;
|
412
413
|
}
|
413
414
|
.ant-select:not(.ant-select-disabled):hover .ant-select-selector {
|
@@ -419,6 +420,7 @@
|
|
419
420
|
-ms-flex: 1;
|
420
421
|
flex: 1;
|
421
422
|
overflow: hidden;
|
423
|
+
font-weight: normal;
|
422
424
|
white-space: nowrap;
|
423
425
|
text-overflow: ellipsis;
|
424
426
|
}
|
@@ -803,7 +805,7 @@
|
|
803
805
|
.ant-checkbox-inner::after {
|
804
806
|
position: absolute;
|
805
807
|
top: 50%;
|
806
|
-
left:
|
808
|
+
left: 21.5%;
|
807
809
|
display: table;
|
808
810
|
width: 5.71428571px;
|
809
811
|
height: 9.14285714px;
|
@@ -984,16 +986,13 @@
|
|
984
986
|
.pandora-sdk-selector .ant-select-selection:hover .ant-select-selection__clear + .ant-select-arrow {
|
985
987
|
opacity: 0;
|
986
988
|
}
|
987
|
-
.pandora-sdk-selector .ant-select-
|
988
|
-
color: #666
|
989
|
-
background: #f5f5f5
|
989
|
+
.pandora-sdk-selector.ant-select-multiple .ant-select-selection-item {
|
990
|
+
color: #666;
|
991
|
+
background: #f5f5f5;
|
990
992
|
border: none;
|
991
993
|
}
|
992
|
-
.pandora-sdk-selector .ant-select-
|
993
|
-
color: #d9d9d9
|
994
|
-
}
|
995
|
-
.pandora-sdk-selector .ant-select-selection__choice__remove i {
|
996
|
-
font-size: 12px;
|
994
|
+
.pandora-sdk-selector .ant-select-selection-item-remove {
|
995
|
+
color: #d9d9d9;
|
997
996
|
}
|
998
997
|
.pandora-sdk-selector .ant-select-selection--single {
|
999
998
|
height: 32px;
|
@@ -1008,17 +1007,6 @@
|
|
1008
1007
|
.pandora-sdk-selector .ant-select-selection__clear i {
|
1009
1008
|
color: inherit;
|
1010
1009
|
}
|
1011
|
-
.pandora-sdk-selector-dropdown .pandora-sdk-selector-create-option {
|
1012
|
-
color: #2c6dd2 !important;
|
1013
|
-
cursor: default !important;
|
1014
|
-
}
|
1015
|
-
.pandora-sdk-selector-dropdown .pandora-sdk-selector-create-option::before,
|
1016
|
-
.pandora-sdk-selector-dropdown .pandora-sdk-selector-create-option::after {
|
1017
|
-
content: none !important;
|
1018
|
-
}
|
1019
|
-
.pandora-sdk-selector-dropdown .pandora-sdk-selector-create-option a {
|
1020
|
-
color: #2c6dd2;
|
1021
|
-
}
|
1022
1010
|
.pandora-sdk-selector-dropdown .ant-select-dropdown-menu {
|
1023
1011
|
margin: 0;
|
1024
1012
|
}
|
@@ -1046,15 +1034,12 @@
|
|
1046
1034
|
background: transparent;
|
1047
1035
|
}
|
1048
1036
|
.pandora-sdk-selector-dropdown .ant-select-item-option-disabled {
|
1049
|
-
color: #d9d9d9
|
1037
|
+
color: #d9d9d9;
|
1050
1038
|
}
|
1051
1039
|
.pandora-sdk-selector-dropdown .ant-select-item-option-selected {
|
1052
1040
|
color: #2c6dd2;
|
1053
1041
|
font-weight: 400;
|
1054
1042
|
}
|
1055
|
-
.pandora-sdk-selector-dropdown .ant-select-item-option-selected::after {
|
1056
|
-
color: #2c6dd2 !important;
|
1057
|
-
}
|
1058
1043
|
.pandora-sdk-selector-dropdown .ant-select-item-option:hover {
|
1059
1044
|
color: #2c6dd2;
|
1060
1045
|
}
|
@@ -1069,8 +1054,19 @@
|
|
1069
1054
|
overflow: unset;
|
1070
1055
|
text-overflow: unset;
|
1071
1056
|
}
|
1072
|
-
.pandora-sdk-selector-dropdown
|
1073
|
-
color:
|
1057
|
+
.pandora-sdk-selector-dropdown .pandora-sdk-selector-create-option {
|
1058
|
+
color: #2c6dd2;
|
1059
|
+
cursor: default;
|
1060
|
+
}
|
1061
|
+
.pandora-sdk-selector-dropdown .pandora-sdk-selector-create-option::before,
|
1062
|
+
.pandora-sdk-selector-dropdown .pandora-sdk-selector-create-option::after {
|
1063
|
+
content: none;
|
1064
|
+
}
|
1065
|
+
.pandora-sdk-selector-dropdown .pandora-sdk-selector-create-option a {
|
1066
|
+
color: #2c6dd2;
|
1067
|
+
}
|
1068
|
+
.pandora-sdk-selector-dropdown .ant-select-item-option-selected:not(.ant-select-item-option-disabled) .ant-select-item-option-state .anticon-check.anticon {
|
1069
|
+
color: #2c6dd2;
|
1074
1070
|
}
|
1075
1071
|
.pandora-sdk-selector-create-lint {
|
1076
1072
|
display: block;
|
@@ -14,17 +14,16 @@
|
|
14
14
|
}
|
15
15
|
}
|
16
16
|
}
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
.@{ant-prefix}-select-selection__choice__remove {
|
23
|
-
color: @font-disable-color !important;
|
24
|
-
i {
|
25
|
-
font-size: 12px;
|
17
|
+
&.@{ant-prefix}-select-multiple {
|
18
|
+
.@{ant-prefix}-select-selection-item {
|
19
|
+
color: @font-color-6;
|
20
|
+
background: @select-selection-bg;
|
21
|
+
border: none;
|
26
22
|
}
|
27
23
|
}
|
24
|
+
.@{ant-prefix}-select-selection-item-remove {
|
25
|
+
color: @font-disable-color;
|
26
|
+
}
|
28
27
|
.@{ant-prefix}-select-selection--single {
|
29
28
|
height: 32px;
|
30
29
|
}
|
@@ -41,30 +40,16 @@
|
|
41
40
|
}
|
42
41
|
|
43
42
|
.@{sdk-prefix}-selector-dropdown {
|
44
|
-
.@{sdk-prefix}-selector-create-option {
|
45
|
-
color: @theme-color!important;
|
46
|
-
cursor: default !important;
|
47
|
-
&::before,
|
48
|
-
&::after {
|
49
|
-
content: none !important;
|
50
|
-
}
|
51
|
-
a {
|
52
|
-
color: @theme-color;
|
53
|
-
}
|
54
|
-
}
|
55
43
|
.@{ant-prefix}-select-dropdown-menu {
|
56
44
|
margin: 0;
|
57
45
|
.scrollbar();
|
58
46
|
}
|
59
47
|
.@{ant-prefix}-select-item-option-disabled {
|
60
|
-
color: @font-disable-color
|
48
|
+
color: @font-disable-color;
|
61
49
|
}
|
62
50
|
.@{ant-prefix}-select-item-option-selected {
|
63
51
|
color: @theme-color;
|
64
52
|
font-weight: 400;
|
65
|
-
&::after {
|
66
|
-
color: @theme-color!important;
|
67
|
-
}
|
68
53
|
}
|
69
54
|
.@{ant-prefix}-select-item-option:hover {
|
70
55
|
color: @theme-color;
|
@@ -84,10 +69,24 @@
|
|
84
69
|
}
|
85
70
|
}
|
86
71
|
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
72
|
+
.@{sdk-prefix}-selector-create-option {
|
73
|
+
color: @theme-color;
|
74
|
+
cursor: default;
|
75
|
+
&::before,
|
76
|
+
&::after {
|
77
|
+
content: none;
|
78
|
+
}
|
79
|
+
a {
|
80
|
+
color: @theme-color;
|
81
|
+
}
|
82
|
+
}
|
83
|
+
.@{ant-prefix}-select-item-option-selected:not(.@{ant-prefix}-select-item-option-disabled)
|
84
|
+
.@{ant-prefix}-select-item-option-state {
|
85
|
+
.anticon-check {
|
86
|
+
&.anticon {
|
87
|
+
color: @theme-color;
|
88
|
+
}
|
89
|
+
}
|
91
90
|
}
|
92
91
|
}
|
93
92
|
|
@@ -1,49 +1,7 @@
|
|
1
1
|
import * as React from 'react';
|
2
|
-
|
3
|
-
export
|
4
|
-
|
5
|
-
* 选项的值
|
6
|
-
*/
|
7
|
-
value: T;
|
8
|
-
/**
|
9
|
-
* 选项的展示形式:string类型或者React组件
|
10
|
-
*/
|
11
|
-
item: string | React.ReactNode;
|
12
|
-
/**
|
13
|
-
* 禁用选项
|
14
|
-
*/
|
15
|
-
disabled?: boolean;
|
16
|
-
}
|
17
|
-
export interface ISolidRadioGroupProps<T = BasicType> {
|
18
|
-
/**
|
19
|
-
* 当前值
|
20
|
-
*/
|
21
|
-
value?: T;
|
22
|
-
/**
|
23
|
-
* 选中变化回调
|
24
|
-
*/
|
25
|
-
onChange?: (value: any) => void;
|
26
|
-
/**
|
27
|
-
* 容器样式
|
28
|
-
*/
|
29
|
-
className?: string;
|
30
|
-
/**
|
31
|
-
* 按钮样式
|
32
|
-
*/
|
33
|
-
buttonClassName?: string;
|
34
|
-
/**
|
35
|
-
* 按钮大小
|
36
|
-
*/
|
37
|
-
size?: 'small' | 'middle' | 'large';
|
38
|
-
/**
|
39
|
-
* 禁用
|
40
|
-
*/
|
41
|
-
disabled?: boolean;
|
42
|
-
/**
|
43
|
-
* 可选线列表
|
44
|
-
*/
|
45
|
-
options?: Array<IOption<T>> | IKeyValues<string | React.ReactNode>;
|
46
|
-
children?: any;
|
2
|
+
import { IRadioGroupProps, IOption } from '../RadioGroup';
|
3
|
+
export { IOption };
|
4
|
+
export interface ISolidRadioGroupProps<T = any> extends Omit<IRadioGroupProps<T>, 'optionType'> {
|
47
5
|
}
|
48
6
|
declare function SolidRadioGroup(props: ISolidRadioGroupProps): JSX.Element;
|
49
7
|
declare namespace SolidRadioGroup {
|
@@ -1,30 +1,18 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
import * as React from 'react';
|
2
|
-
import { isArray, isUndefined } from 'lodash';
|
3
13
|
import Radio from 'antd/es/radio';
|
4
|
-
import
|
5
|
-
import { SDK_PREFIX } from '../../constants/style';
|
6
|
-
var useCallback = React.useCallback, useMemo = React.useMemo;
|
14
|
+
import { default as RadioGroup } from '../RadioGroup';
|
7
15
|
export default function SolidRadioGroup(props) {
|
8
|
-
|
9
|
-
var handleChange = useCallback(function (e) {
|
10
|
-
if (onChange) {
|
11
|
-
onChange(e.target.value);
|
12
|
-
}
|
13
|
-
}, [onChange]);
|
14
|
-
var radioOptions = useMemo(function () {
|
15
|
-
return isArray(options)
|
16
|
-
? options
|
17
|
-
: Object.keys(options).map(function (key) { return ({ value: key, item: options[key] }); });
|
18
|
-
}, [options]);
|
19
|
-
return (React.createElement(Radio.Group, { className: classnames(SDK_PREFIX + "-solid-radio-group", className), value: value, onChange: handleChange, size: size },
|
20
|
-
radioOptions.map(function (option) {
|
21
|
-
var _a;
|
22
|
-
var value = option.value, item = option.item;
|
23
|
-
var disableRealVal = isUndefined(option.disabled)
|
24
|
-
? disabled
|
25
|
-
: option.disabled;
|
26
|
-
return (React.createElement(Radio.Button, { key: value.toString(), value: value, disabled: disableRealVal, className: classnames((_a = {}, _a[SDK_PREFIX + "-solid-radio-item"] = !disableRealVal, _a), buttonClassName) }, item));
|
27
|
-
}),
|
28
|
-
children));
|
16
|
+
return React.createElement(RadioGroup, __assign({ optionType: "button" }, props));
|
29
17
|
}
|
30
18
|
SolidRadioGroup.Button = Radio.Button;
|
@@ -1,10 +1,14 @@
|
|
1
1
|
import * as React from 'react';
|
2
|
+
import { ConfigContext } from 'antd/es/config-provider';
|
2
3
|
import Button from '../../Button';
|
4
|
+
import { formatString } from '../../../utils/language';
|
3
5
|
import { SDK_PREFIX } from '../../../constants/style';
|
6
|
+
import { StepsLocale } from '../../../constants/language/steps/type';
|
4
7
|
import { StepsContext } from '../context';
|
5
8
|
function ControlButton(props) {
|
6
9
|
var lastStepText = props.lastStepText, nextDisabled = props.nextDisabled, onStepChange = props.onStepChange, onStepLast = props.onStepLast;
|
7
10
|
var _a = React.useContext(StepsContext), stepCount = _a.count, current = _a.current;
|
11
|
+
var locale = React.useContext(ConfigContext).locale;
|
8
12
|
var isLastStep = current === stepCount - 1;
|
9
13
|
var handlePreStep = function () {
|
10
14
|
if (current > 0 && onStepChange) {
|
@@ -20,7 +24,9 @@ function ControlButton(props) {
|
|
20
24
|
}
|
21
25
|
};
|
22
26
|
return (React.createElement(React.Fragment, null,
|
23
|
-
React.createElement(Button, { className: SDK_PREFIX + "-prev-button", onClick: handlePreStep, disabled: current === 0 },
|
24
|
-
React.createElement(Button, { className: SDK_PREFIX + "-next-button", type: "primary", onClick: handleNextStep, disabled: nextDisabled || (isLastStep && !lastStepText) }, isLastStep && lastStepText
|
27
|
+
React.createElement(Button, { className: SDK_PREFIX + "-prev-button", onClick: handlePreStep, disabled: current === 0 }, formatString(StepsLocale.previous_step, locale)),
|
28
|
+
React.createElement(Button, { className: SDK_PREFIX + "-next-button", type: "primary", onClick: handleNextStep, disabled: nextDisabled || (isLastStep && !lastStepText) }, isLastStep && lastStepText
|
29
|
+
? lastStepText
|
30
|
+
: formatString(StepsLocale.next_step, locale))));
|
25
31
|
}
|
26
32
|
export default React.memo(ControlButton);
|
@@ -479,12 +479,12 @@
|
|
479
479
|
left: 0;
|
480
480
|
}
|
481
481
|
.ant-steps-vertical.ant-steps-dot .ant-steps-item-icon {
|
482
|
-
margin-top:
|
482
|
+
margin-top: 13px;
|
483
483
|
margin-left: 0;
|
484
484
|
background: none;
|
485
485
|
}
|
486
486
|
.ant-steps-vertical.ant-steps-dot .ant-steps-item > .ant-steps-item-container > .ant-steps-item-tail {
|
487
|
-
top:
|
487
|
+
top: 6.5px;
|
488
488
|
left: -9px;
|
489
489
|
margin: 0;
|
490
490
|
padding: 22px 0 4px;
|
@@ -496,7 +496,8 @@
|
|
496
496
|
width: inherit;
|
497
497
|
}
|
498
498
|
.ant-steps-vertical.ant-steps-dot .ant-steps-item-process .ant-steps-item-container .ant-steps-item-icon .ant-steps-icon-dot {
|
499
|
-
|
499
|
+
top: -1px;
|
500
|
+
left: -1px;
|
500
501
|
}
|
501
502
|
.ant-steps-navigation {
|
502
503
|
padding-top: 12px;
|
@@ -767,9 +768,8 @@
|
|
767
768
|
.pandora-sdk-steps .ant-steps-item-icon {
|
768
769
|
width: 24px;
|
769
770
|
height: 24px;
|
770
|
-
line-height: 28px;
|
771
|
-
margin-top: 2px;
|
772
771
|
font-size: 12px;
|
772
|
+
line-height: 24px;
|
773
773
|
}
|
774
774
|
.pandora-sdk-steps .ant-steps-item-icon .ant-steps-icon {
|
775
775
|
font-size: 10px;
|
@@ -785,18 +785,15 @@
|
|
785
785
|
background: #2c6dd2;
|
786
786
|
border: none;
|
787
787
|
}
|
788
|
-
.pandora-sdk-steps .ant-steps-item .ant-steps-item-icon .ant-steps-icon {
|
789
|
-
top: -1px;
|
790
|
-
}
|
791
788
|
.pandora-sdk-steps .ant-steps-item.ant-steps-item-finish .ant-steps-item-icon .ant-steps-icon {
|
792
789
|
color: #ffffff;
|
793
790
|
}
|
794
|
-
.pandora-sdk-steps .ant-steps-item.ant-steps-item-finish .ant-steps-item-icon .ant-steps-icon .
|
795
|
-
color: #ffffff
|
791
|
+
.pandora-sdk-steps .ant-steps-item.ant-steps-item-finish .ant-steps-item-icon .ant-steps-icon span.anticon.anticon-check.ant-steps-finish-icon {
|
792
|
+
color: #ffffff;
|
796
793
|
}
|
797
794
|
.pandora-sdk-steps .ant-steps-item.ant-steps-item-wait .ant-steps-item-icon {
|
798
795
|
background: #eee;
|
799
796
|
}
|
800
797
|
.pandora-sdk-steps .ant-steps-item.ant-steps-item-wait .ant-steps-item-icon .ant-steps-icon {
|
801
|
-
color: #bfbfbf
|
798
|
+
color: #bfbfbf;
|
802
799
|
}
|
@@ -5,9 +5,8 @@
|
|
5
5
|
.@{ant-prefix}-steps-item-icon {
|
6
6
|
width: 24px;
|
7
7
|
height: 24px;
|
8
|
-
line-height: 28px;
|
9
|
-
margin-top: 2px;
|
10
8
|
font-size: 12px;
|
9
|
+
line-height: 24px;
|
11
10
|
.@{ant-prefix}-steps-icon {
|
12
11
|
font-size: 10px;
|
13
12
|
}
|
@@ -27,16 +26,14 @@
|
|
27
26
|
border-radius: 2px;
|
28
27
|
background: @theme-color;
|
29
28
|
border: none;
|
30
|
-
.@{ant-prefix}-steps-icon {
|
31
|
-
top: -1px;
|
32
|
-
}
|
33
29
|
}
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
30
|
+
&.@{ant-prefix}-steps-item-finish {
|
31
|
+
.@{ant-prefix}-steps-item-icon {
|
32
|
+
.@{ant-prefix}-steps-icon {
|
33
|
+
color: @normal-color;
|
34
|
+
span.anticon.anticon-check.@{ant-prefix}-steps-finish-icon {
|
35
|
+
color: @normal-color;
|
36
|
+
}
|
40
37
|
}
|
41
38
|
}
|
42
39
|
}
|
@@ -44,7 +41,7 @@
|
|
44
41
|
&.@{ant-prefix}-steps-item-wait .@{ant-prefix}-steps-item-icon {
|
45
42
|
background: @button-disabled-bg;
|
46
43
|
.@{ant-prefix}-steps-icon {
|
47
|
-
color: @icon-color
|
44
|
+
color: @icon-color;
|
48
45
|
}
|
49
46
|
}
|
50
47
|
}
|
@@ -40,6 +40,7 @@ declare class Table<T = any> extends React.Component<ITableProps<T>, any> {
|
|
40
40
|
title?: string | undefined;
|
41
41
|
tagClassName?: string | undefined;
|
42
42
|
}) => JSX.Element;
|
43
|
+
static contextType: React.Context<import("antd/es/config-provider").ConfigConsumerProps>;
|
43
44
|
indeterminate: boolean;
|
44
45
|
checkAll: boolean;
|
45
46
|
UNSAFE_componentWillReceiveProps(nextProps: ITableProps<T>): void;
|
@@ -63,13 +63,17 @@ var __spread = (this && this.__spread) || function () {
|
|
63
63
|
return ar;
|
64
64
|
};
|
65
65
|
import * as React from 'react';
|
66
|
-
import { Table as AntTable, Checkbox } from 'antd';
|
67
66
|
import classnames from 'classnames';
|
67
|
+
import { observer } from 'mobx-react';
|
68
68
|
import { observable, action, computed } from 'mobx';
|
69
69
|
import { size, xor, union, unionBy, differenceBy, get } from 'lodash';
|
70
|
-
import {
|
70
|
+
import { Table as AntTable, Checkbox } from 'antd';
|
71
|
+
import { ConfigContext } from 'antd/es/config-provider';
|
72
|
+
import { EmptyIcon } from '@qn-pandora/pandora-component-icons';
|
71
73
|
import bind from '../../utils/bind';
|
74
|
+
import { formatString } from '../../utils/language';
|
72
75
|
import { SDK_PREFIX } from '../../constants/style';
|
76
|
+
import { TableLocale } from '../../constants/language/table/type';
|
73
77
|
import { ColumnTag } from './ColumnTag/ColumnTag';
|
74
78
|
/**
|
75
79
|
* pandora2.0风格的表格
|
@@ -228,9 +232,12 @@ var Table = /** @class */ (function (_super) {
|
|
228
232
|
Table.prototype.render = function () {
|
229
233
|
var _a, _b;
|
230
234
|
var _this = this;
|
231
|
-
var _c = this.props, className = _c.className, batchOptions = _c.batchOptions, scroll = _c.scroll, restProps = __rest(_c, ["className", "batchOptions", "scroll"]);
|
235
|
+
var _c = this.props, className = _c.className, batchOptions = _c.batchOptions, scroll = _c.scroll, locale = _c.locale, restProps = __rest(_c, ["className", "batchOptions", "scroll", "locale"]);
|
232
236
|
return (React.createElement("div", null,
|
233
|
-
React.createElement(AntTable, __assign({ scroll: scroll
|
237
|
+
React.createElement(AntTable, __assign({ scroll: scroll, locale: __assign({ emptyText: (React.createElement("div", { className: SDK_PREFIX + "-table-empty" },
|
238
|
+
React.createElement("div", { className: SDK_PREFIX + "-table-empty-icon" },
|
239
|
+
React.createElement(EmptyIcon, null)),
|
240
|
+
React.createElement("div", { className: SDK_PREFIX + "-table-empty-text" }, formatString(TableLocale.empty, this.context.locale)))) }, locale) }, restProps, { className: classnames(SDK_PREFIX + "-table-wrapper", (_a = {}, _a[SDK_PREFIX + "-table-scrollX"] = get(scroll, 'x'), _a), (_b = {}, _b[SDK_PREFIX + "-table-scrollY"] = get(scroll, 'y'), _b), className),
|
234
241
|
// 涉及到权限
|
235
242
|
// getCheckboxProps只能放到tableBatchWrapper里,因为selectedRowKeys在那个组件计算
|
236
243
|
rowSelection: batchOptions && this.props.rowSelection
|
@@ -242,7 +249,8 @@ var Table = /** @class */ (function (_super) {
|
|
242
249
|
this.props.dataSource.length > 0 ? (React.createElement("div", { className: SDK_PREFIX + "-table-batch-opt" },
|
243
250
|
React.createElement(Checkbox, { indeterminate: this.indeterminate, onChange: this.handleCheckAllChange, checked: this.checkAll, disabled: size(this.undisabledData) === 0 }),
|
244
251
|
React.createElement("span", { className: SDK_PREFIX + "-table-batch-opt-label" },
|
245
|
-
|
252
|
+
formatString(TableLocale.selected, this.context.locale),
|
253
|
+
' ',
|
246
254
|
this.selectedRowKeys.length),
|
247
255
|
React.createElement("span", null, (batchOptions || []).map(function (option, index) {
|
248
256
|
var _a;
|
@@ -254,6 +262,7 @@ var Table = /** @class */ (function (_super) {
|
|
254
262
|
};
|
255
263
|
Table.Column = AntTable.Column;
|
256
264
|
Table.ColumnTag = ColumnTag;
|
265
|
+
Table.contextType = ConfigContext;
|
257
266
|
__decorate([
|
258
267
|
observable,
|
259
268
|
__metadata("design:type", Object)
|