@cloud-app-dev/vidc 3.2.37 → 3.2.39
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/.dumirc.ts +7 -11
- package/.fatherrc.ts +0 -1
- package/es/CheckGroupFixed/demo.js +2 -3
- package/es/CheckGroupFixed/index.js +4 -7
- package/es/Config/index.js +10 -9
- package/es/Config/interface.d.ts +2 -3
- package/es/CustomRenderSelect/index.js +2 -3
- package/es/DynamicList/demo.js +3 -4
- package/es/DynamicList/index.js +2 -3
- package/es/ErrorFallback/index.js +3 -6
- package/es/FrontendPlayer/index.d.ts +4 -2
- package/es/List/index.d.ts +0 -13
- package/es/List/index.js +1 -19
- package/es/LoaderScript/utils.d.ts +0 -1
- package/es/LoaderScript/utils.js +1 -36
- package/es/Map/FindPio/index.js +2 -3
- package/es/Map/LevelCenter/demo.js +2 -4
- package/es/Map/ResetTools/index.js +4 -5
- package/es/Picture/component/Tools/index.d.ts +1 -2
- package/es/Picture/component/Tools/index.js +7 -14
- package/es/Picture/demo.js +14 -28
- package/es/Picture/index.d.ts +1 -1
- package/es/Picture/index.js +91 -141
- package/es/Picture/index.less +7 -2
- package/es/Picture/utils.d.ts +6 -0
- package/es/Picture/utils.js +57 -2
- package/es/Player/api/index.js +2 -1
- package/es/Player/contraller_bar/volume.js +3 -6
- package/es/Player/demo.js +28 -58
- package/es/Player/frontend_timeline.js +1 -1
- package/es/Player/segment_timeline.js +3 -5
- package/es/Player/single_player.js +1 -1
- package/es/Player/util.d.ts +0 -1
- package/es/Player/util.js +2 -40
- package/es/PlayerExt/demo.js +12 -20
- package/es/Progress/index.js +4 -6
- package/es/RefDrawer/Footer.d.ts +9 -0
- package/es/{Drawer → RefDrawer}/Footer.js +3 -5
- package/es/{Drawer/Demo.d.ts → RefDrawer/demo.d.ts} +0 -0
- package/es/RefDrawer/demo.js +35 -0
- package/es/RefDrawer/index.d.ts +26 -0
- package/es/{Input → RefDrawer}/index.js +54 -58
- package/es/{Input → RefModal}/demo.d.ts +0 -0
- package/es/RefModal/demo.js +35 -0
- package/es/RefModal/index.d.ts +17 -0
- package/es/RefModal/index.js +71 -0
- package/es/ScreenPlayer/PlayerWithExt.js +1 -1
- package/es/ScreenPlayer/RatePick.js +8 -9
- package/es/ScreenPlayer/ScreenSelect.js +2 -3
- package/es/ScreenPlayer/SegmentTimeLine.js +3 -11
- package/es/ScreenPlayer/TimeMode.js +3 -4
- package/es/ScreenPlayer/TimeSelect.js +14 -39
- package/es/ScreenPlayer/demo.js +2 -3
- package/es/ScreenPlayer/demo2.js +8 -28
- package/es/ScreenPlayer/useTimeSlider.js +1 -1
- package/es/Service/http.js +6 -8
- package/es/TableLayout/index.d.ts +0 -3
- package/es/TableLayout/index.js +8 -10
- package/es/ThemeAntd/demo.js +21 -40
- package/es/ThemeAntd/index.js +16 -2
- package/es/ThemeAntd/index.less +0 -12
- package/es/Timeout/index.js +2 -2
- package/es/core.d.ts +0 -149
- package/es/index.d.ts +2 -6
- package/es/index.js +2 -6
- package/es/useDrawROI/index.js +4 -4
- package/es/utils.d.ts +1 -12
- package/es/utils.js +0 -56
- package/package.json +24 -24
- package/theme-config.ts +3 -1
- package/typings/global.d.ts +4 -4
- package/es/Api/index.d.ts +0 -12
- package/es/Api/index.js +0 -267
- package/es/Box/BetweenBox/index.d.ts +0 -12
- package/es/Box/BetweenBox/index.js +0 -31
- package/es/Box/BetweenBox/index.less +0 -5
- package/es/Box/InfoBox/index.d.ts +0 -12
- package/es/Box/InfoBox/index.js +0 -30
- package/es/Box/InfoBox/index.less +0 -24
- package/es/Box/TwoColumnBox/index.d.ts +0 -10
- package/es/Box/TwoColumnBox/index.js +0 -54
- package/es/Box/TwoColumnBox/index.less +0 -80
- package/es/Box/deps/content-grid.d.ts +0 -9
- package/es/Box/deps/content-grid.js +0 -9
- package/es/Box/deps/grid-factory.d.ts +0 -10
- package/es/Box/deps/grid-factory.js +0 -72
- package/es/Box/deps/simple-grid.d.ts +0 -9
- package/es/Box/deps/simple-grid.js +0 -8
- package/es/Box/index.d.ts +0 -14
- package/es/Box/index.js +0 -39
- package/es/Box/index.less +0 -10
- package/es/Drawer/Demo.js +0 -109
- package/es/Drawer/Footer.d.ts +0 -5
- package/es/Drawer/index.d.ts +0 -38
- package/es/Drawer/index.js +0 -207
- package/es/Drawer/index.less +0 -42
- package/es/Drawer/interface.d.ts +0 -22
- package/es/Input/demo.js +0 -16
- package/es/Input/index.d.ts +0 -19
- package/es/Input/index.less +0 -12
- package/es/Modal/demo.d.ts +0 -3
- package/es/Modal/demo.js +0 -106
- package/es/Modal/index.d.ts +0 -44
- package/es/Modal/index.js +0 -197
- package/es/Modal/index.less +0 -44
- package/es/Modal/interface.d.ts +0 -23
- package/es/Picture/dragBound.d.ts +0 -5
- package/es/Picture/dragBound.js +0 -77
- package/es/Service/fetch-adapter.d.ts +0 -12
- package/es/Service/fetch-adapter.js +0 -203
- package/es/ThemeAntd/style/button.less +0 -67
- package/es/ThemeAntd/style/checkbox.less +0 -72
- package/es/ThemeAntd/style/form.less +0 -12
- package/es/ThemeAntd/style/input.less +0 -83
- package/es/ThemeAntd/style/pagination.less +0 -96
- package/es/ThemeAntd/style/picker.less +0 -106
- package/es/ThemeAntd/style/popover.less +0 -5
- package/es/ThemeAntd/style/radio.less +0 -87
- package/es/ThemeAntd/style/scrollbar.less +0 -23
- package/es/ThemeAntd/style/select.less +0 -81
- package/es/ThemeAntd/style/table.less +0 -57
- package/es/ThemeAntd/style/tree.less +0 -18
- package/es/Tree/demo.d.ts +0 -3
- package/es/Tree/demo.js +0 -32
- package/es/Tree/index.d.ts +0 -24
- package/es/Tree/index.js +0 -100
- package/es/Tree/index.less +0 -60
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
div {
|
|
2
|
-
.@{ant-prefix}-radio{
|
|
3
|
-
color:inherit
|
|
4
|
-
}
|
|
5
|
-
.@{ant-prefix}-radio-group{
|
|
6
|
-
color:inherit
|
|
7
|
-
}
|
|
8
|
-
.@{ant-prefix}-radio-button-wrapper {
|
|
9
|
-
outline: unset;
|
|
10
|
-
}
|
|
11
|
-
.@{ant-prefix}-radio-button-wrapper-checked:not(.@{ant-prefix}-radio-button-wrapper-disabled):hover {
|
|
12
|
-
border-color: var(--form-active-bg);
|
|
13
|
-
color: var(--form-active-bg);
|
|
14
|
-
}
|
|
15
|
-
.@{ant-prefix}-radio-button-wrapper-checked:not(.@{ant-prefix}-radio-button-wrapper-disabled) {
|
|
16
|
-
border-color: var(--form-active-bg);
|
|
17
|
-
color: var(--form-active-bg);
|
|
18
|
-
box-shadow: -1px 0 0 0 var(--form-active-bg);
|
|
19
|
-
}
|
|
20
|
-
.@{ant-prefix}-radio-button-wrapper-checked:not(.@{ant-prefix}-radio-button-wrapper-disabled):first-child {
|
|
21
|
-
border-color: var(--form-active-bg);
|
|
22
|
-
}
|
|
23
|
-
.@{ant-prefix}-radio-disabled .@{ant-prefix}-radio-inner::after {
|
|
24
|
-
background-color: var(--form-bg);;
|
|
25
|
-
}
|
|
26
|
-
.@{ant-prefix}-radio-disabled .@{ant-prefix}-radio-inner {
|
|
27
|
-
background-color: var(--form-bg);;
|
|
28
|
-
opacity: .8;
|
|
29
|
-
}
|
|
30
|
-
.@{ant-prefix}-radio-button-wrapper:hover {
|
|
31
|
-
color: var(--form-active-bg);
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
.@{ant-prefix}-radio-checked .@{ant-prefix}-radio-inner {
|
|
35
|
-
border-color: var(--form-active-bg);
|
|
36
|
-
}
|
|
37
|
-
.@{ant-prefix}-radio-inner {
|
|
38
|
-
background-color: var(--form-bg);;
|
|
39
|
-
}
|
|
40
|
-
.@{ant-prefix}-radio-inner::after {
|
|
41
|
-
background-color: var(--form-active-bg);
|
|
42
|
-
}
|
|
43
|
-
.@{ant-prefix}-radio-checked::after {
|
|
44
|
-
border-color: var(--form-active-bg);
|
|
45
|
-
}
|
|
46
|
-
.@{ant-prefix}-radio-wrapper {
|
|
47
|
-
color: inherit;
|
|
48
|
-
}
|
|
49
|
-
.@{ant-prefix}-radio-disabled + span {
|
|
50
|
-
color: inherit;
|
|
51
|
-
opacity: .8;
|
|
52
|
-
}
|
|
53
|
-
.@{ant-prefix}-radio-wrapper:hover .@{ant-prefix}-radio,
|
|
54
|
-
.@{ant-prefix}-radio:hover .@{ant-prefix}-radio-inner,
|
|
55
|
-
.@{ant-prefix}-radio-input:focus + .@{ant-prefix}-radio-inner {
|
|
56
|
-
border-color: var(--form-active-bg);
|
|
57
|
-
}
|
|
58
|
-
.@{ant-prefix}-radio-button-wrapper-checked:not(.@{ant-prefix}-radio-button-wrapper-disabled)::before {
|
|
59
|
-
background-color: var(--form-active-bg) !important;
|
|
60
|
-
opacity: unset;
|
|
61
|
-
}
|
|
62
|
-
.@{ant-prefix}-radio-group-solid .@{ant-prefix}-radio-button-wrapper-checked:not(.@{ant-prefix}-radio-button-wrapper-disabled) {
|
|
63
|
-
background-color: var(--form-active-bg);
|
|
64
|
-
border-color: var(--form-active-bg);
|
|
65
|
-
}
|
|
66
|
-
.@{ant-prefix}-radio-group-solid .@{ant-prefix}-radio-button-wrapper-checked:not(.@{ant-prefix}-radio-button-wrapper-disabled):hover {
|
|
67
|
-
background-color: var(--form-active-bg-dark);
|
|
68
|
-
border-color: var(--form-active-bg-dark);
|
|
69
|
-
box-shadow: -1px 0 0 0 var(--form-active-bg);
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
.@{ant-prefix}-radio-button-wrapper-checked:not([class*=' cloudapp-radio-button-wrapper-disabled']).@{ant-prefix}-radio-button-wrapper:first-child {
|
|
73
|
-
border-right-color: var(--form-active-bg);
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
.@{ant-prefix}-radio-button-wrapper:last-child {
|
|
77
|
-
border-radius: 0 var(--form-redius) var(--form-redius) 0;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.@{ant-prefix}-radio-button-wrapper:first-child {
|
|
81
|
-
border-radius: var(--form-redius) 0 0 var(--radius1);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
.@{ant-prefix}-radio-input:focus + .@{ant-prefix}-radio-inner{
|
|
85
|
-
box-shadow: unset;
|
|
86
|
-
}
|
|
87
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
// 滚动条整体宽度
|
|
2
|
-
::-webkit-scrollbar {
|
|
3
|
-
width: var(--scrollbar-width);
|
|
4
|
-
height: var(--scrollbar-width);
|
|
5
|
-
} // 滚动条滑槽样式
|
|
6
|
-
::-webkit-scrollbar-track {
|
|
7
|
-
box-shadow: var(--scrollbar-track-shadow);
|
|
8
|
-
border-radius: var(--scrollbar-width);
|
|
9
|
-
}
|
|
10
|
-
// 滚动条样式
|
|
11
|
-
::-webkit-scrollbar-thumb {
|
|
12
|
-
background: var(--scrollbar-thumb-bg);
|
|
13
|
-
border-radius: var(--scrollbar-width);
|
|
14
|
-
box-shadow: var(--scrollbar-thumb-shadow);
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
::-webkit-scrollbar-thumb:hover {
|
|
18
|
-
background: var(--scrollbar-thumb-hover-bg);
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
::-webkit-scrollbar-thumb:active {
|
|
22
|
-
background: var(--scrollbar-thumb-bg);
|
|
23
|
-
} // 浏览器失焦的样式
|
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
div {
|
|
2
|
-
.@{ant-prefix}-select-single:not(.@{ant-prefix}-select-customize-input) .@{ant-prefix}-select-selector {
|
|
3
|
-
background-color: var(--form-bg);
|
|
4
|
-
border-radius: var(--radius1);
|
|
5
|
-
border-color: var(--form-bd);
|
|
6
|
-
}
|
|
7
|
-
.@{ant-prefix}-select-multiple .@{ant-prefix}-select-selector {
|
|
8
|
-
background-color: var(--form-bg);
|
|
9
|
-
border-radius: var(--radius1);
|
|
10
|
-
border-color: var(--form-bd);
|
|
11
|
-
}
|
|
12
|
-
.@{ant-prefix}-select-multiple .@{ant-prefix}-select-selection-item {
|
|
13
|
-
background-color: var(--form-bg);
|
|
14
|
-
border-radius: var(--radius1);
|
|
15
|
-
border-color: var(--form-bd);
|
|
16
|
-
}
|
|
17
|
-
.@{ant-prefix}-select:not(.@{ant-prefix}-select-disabled):hover .@{ant-prefix}-select-selector {
|
|
18
|
-
border-color: var(--form-active-bg);
|
|
19
|
-
}
|
|
20
|
-
.@{ant-prefix}-select-focused.@{ant-prefix}-select-single:not(.@{ant-prefix}-select-customize-input) .@{ant-prefix}-select-selector {
|
|
21
|
-
border-color: var(--form-active-bg);
|
|
22
|
-
}
|
|
23
|
-
.@{ant-prefix}-select-focused.@{ant-prefix}-select-multiple .@{ant-prefix}-select-selector {
|
|
24
|
-
border-color: var(--form-active-bg);
|
|
25
|
-
}
|
|
26
|
-
.@{ant-prefix}-select-multiple .@{ant-prefix}-select-selection-item-remove {
|
|
27
|
-
color: inherit;
|
|
28
|
-
}
|
|
29
|
-
.@{ant-prefix}-select-multiple .@{ant-prefix}-select-selection-item-remove:hover {
|
|
30
|
-
color: var(--form-active-bg);
|
|
31
|
-
}
|
|
32
|
-
.@{ant-prefix}-select {
|
|
33
|
-
font-size: var(--fs);
|
|
34
|
-
color: inherit;
|
|
35
|
-
}
|
|
36
|
-
.@{ant-prefix}-select-arrow {
|
|
37
|
-
color: inherit;
|
|
38
|
-
}
|
|
39
|
-
.@{ant-prefix}-select-dropdown {
|
|
40
|
-
color: inherit;
|
|
41
|
-
background-color: var(--form-bg);
|
|
42
|
-
}
|
|
43
|
-
.@{ant-prefix}-select-item {
|
|
44
|
-
color: inherit;
|
|
45
|
-
}
|
|
46
|
-
.@{ant-prefix}-select-item-option-active:not(.@{ant-prefix}-select-item-option-disabled) {
|
|
47
|
-
background-color: var(--form-bg);
|
|
48
|
-
}
|
|
49
|
-
.@{ant-prefix}-select-item-option-selected:not(.@{ant-prefix}-select-item-option-disabled) .@{ant-prefix}-select-item-option-state {
|
|
50
|
-
color: var(--form-active-bg);
|
|
51
|
-
}
|
|
52
|
-
.@{ant-prefix}-select-item-option-selected:not(.@{ant-prefix}-select-item-option-disabled) {
|
|
53
|
-
color: var(--form-active-bg);
|
|
54
|
-
background-color: transparent;
|
|
55
|
-
}
|
|
56
|
-
.@{ant-prefix}-select-focused:not(.@{ant-prefix}-select-disabled).@{ant-prefix}-select-single:not(.@{ant-prefix}-select-customize-input)
|
|
57
|
-
.@{ant-prefix}-select-selector {
|
|
58
|
-
border-color: var(--form-active-bg);
|
|
59
|
-
box-shadow: unset;
|
|
60
|
-
}
|
|
61
|
-
.@{ant-prefix}-select:not(.@{ant-prefix}-select-customize-input) .@{ant-prefix}-select-selector{
|
|
62
|
-
background-color: var(--form-bg);
|
|
63
|
-
border-radius: var(--radius1);
|
|
64
|
-
border-color: var(--form-bd);
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
.@{ant-prefix}-select-focused:not(.@{ant-prefix}-select-disabled).@{ant-prefix}-select:not(.@{ant-prefix}-select-customize-input) .@{ant-prefix}-select-selector{
|
|
68
|
-
box-shadow: unset;
|
|
69
|
-
border-color: var(--form-active-bg);
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
.@{ant-prefix}-select-disabled.@{ant-prefix}-select:not(.@{ant-prefix}-select-customize-input) .@{ant-prefix}-select-selector{
|
|
73
|
-
color:inherit;
|
|
74
|
-
border-color: var(--form-bd);
|
|
75
|
-
background-color: var(--form-bg);
|
|
76
|
-
opacity: .8;
|
|
77
|
-
}
|
|
78
|
-
.@{ant-prefix}-select-status-error.@{ant-prefix}-select:not(.@{ant-prefix}-select-disabled):not(.@{ant-prefix}-select-customize-input):not(.@{ant-prefix}-pagination-size-changer) .@{ant-prefix}-select-selector{
|
|
79
|
-
background-color: var(--form-bg);
|
|
80
|
-
}
|
|
81
|
-
}
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
div {
|
|
2
|
-
.@{ant-prefix}-table {
|
|
3
|
-
font-size: var(--fs);
|
|
4
|
-
color: inherit;
|
|
5
|
-
background-color: var(--table-bg);
|
|
6
|
-
}
|
|
7
|
-
.@{ant-prefix}-table-tbody > tr.@{ant-prefix}-table-row:hover > td {
|
|
8
|
-
background: var(--table-row-hover-color);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
.@{ant-prefix}-table-tbody > tr.@{ant-prefix}-table-row-selected > td {
|
|
12
|
-
background: var(--table-row-hover-color);
|
|
13
|
-
border-bottom-color: var(--table-bd);
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.@{ant-prefix}-table-thead > tr > th:not(.@{ant-prefix}-table-cell-scrollbar) {
|
|
17
|
-
color: inherit;
|
|
18
|
-
background-color: var(--table-head-bg);
|
|
19
|
-
border-bottom-color: var(--table-bd);
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
.@{ant-prefix}-table-thead > tr > th.@{ant-prefix}-table-cell-scrollbar {
|
|
23
|
-
box-shadow: none;
|
|
24
|
-
background-color: var(--table-head-bg);
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
.@{ant-prefix}-table-cell-fix-left,
|
|
28
|
-
.@{ant-prefix}-table-cell-fix-right {
|
|
29
|
-
background-color: var(--table-bg);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
.@{ant-prefix}-table-tbody > tr > td {
|
|
33
|
-
border-bottom-color: var(--table-bd);
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
tr.@{ant-prefix}-table-expanded-row > td,
|
|
37
|
-
tr.@{ant-prefix}-table-expanded-row:hover > td {
|
|
38
|
-
background-color: var(--table-row-hover-color);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
.@{ant-prefix}-table-row-expand-icon {
|
|
42
|
-
color: var(--primary);
|
|
43
|
-
border-radius: var(--radius1);
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.@{ant-prefix}-table-row-expand-icon:focus,
|
|
47
|
-
.@{ant-prefix}-table-row-expand-icon:hover {
|
|
48
|
-
color: var(--primary-dark);
|
|
49
|
-
}
|
|
50
|
-
.@{ant-prefix}-empty-normal {
|
|
51
|
-
color: inherit;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
.@{ant-prefix}-table-tbody > tr.@{ant-prefix}-table-placeholder:hover > td {
|
|
55
|
-
background-color: var(--table-row-hover-color);
|
|
56
|
-
}
|
|
57
|
-
}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
div {
|
|
2
|
-
.@{ant-prefix}-tree {
|
|
3
|
-
color: inherit;
|
|
4
|
-
background: transparent;
|
|
5
|
-
}
|
|
6
|
-
.@{ant-prefix}-tree .@{ant-prefix}-tree-node-content-wrapper:hover {
|
|
7
|
-
background-color: transparent;
|
|
8
|
-
border-bottom: 1px solid var(--secondary2);
|
|
9
|
-
}
|
|
10
|
-
.@{ant-prefix} .@{ant-prefix}-node-content-wrapper.@{ant-prefix}-node-selected {
|
|
11
|
-
background-color: transparent;
|
|
12
|
-
border-bottom: 1px solid var(--secondary2);
|
|
13
|
-
}
|
|
14
|
-
.@{ant-prefix}-tree-checkbox-inner{
|
|
15
|
-
background-color: var(--form-bg);
|
|
16
|
-
border-color: var(--form-bd);
|
|
17
|
-
}
|
|
18
|
-
}
|
package/es/Tree/demo.d.ts
DELETED
package/es/Tree/demo.js
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import "antd/lib/config-provider/style";
|
|
2
|
-
import _ConfigProvider from "antd/lib/config-provider";
|
|
3
|
-
import React from 'react';
|
|
4
|
-
import BsTree from "./index";
|
|
5
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
6
|
-
|
|
7
|
-
function App() {
|
|
8
|
-
return /*#__PURE__*/_jsx(_ConfigProvider, {
|
|
9
|
-
prefixCls: "cloudapp",
|
|
10
|
-
children: /*#__PURE__*/_jsx("div", {
|
|
11
|
-
style: {
|
|
12
|
-
padding: 20,
|
|
13
|
-
height: 400,
|
|
14
|
-
display: 'flex'
|
|
15
|
-
},
|
|
16
|
-
children: /*#__PURE__*/_jsx(BsTree, {
|
|
17
|
-
checkable: true,
|
|
18
|
-
checkStrictly: true,
|
|
19
|
-
treeData: [{
|
|
20
|
-
id: 1,
|
|
21
|
-
name: 'aaa',
|
|
22
|
-
children: [{
|
|
23
|
-
id: 2,
|
|
24
|
-
name: 'bbb'
|
|
25
|
-
}]
|
|
26
|
-
}]
|
|
27
|
-
})
|
|
28
|
-
})
|
|
29
|
-
});
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
export default App;
|
package/es/Tree/index.d.ts
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* tree 基础组件支持各种自定义其他tree可用过它来拓展
|
|
3
|
-
*/
|
|
4
|
-
import React from 'react';
|
|
5
|
-
import type { DataNode, TreeProps } from 'antd/lib/tree';
|
|
6
|
-
import './index.less';
|
|
7
|
-
export interface ITreeNodeProps {
|
|
8
|
-
prefix?: (node: DataNode) => JSX.Element;
|
|
9
|
-
suffix?: (node: DataNode) => JSX.Element;
|
|
10
|
-
keyword?: string;
|
|
11
|
-
key?: string;
|
|
12
|
-
nameKey?: string;
|
|
13
|
-
RenderTreeTitle?: (node: DataNode) => JSX.Element;
|
|
14
|
-
}
|
|
15
|
-
export interface BaseTreeProps extends Omit<TreeProps, 'icon'> {
|
|
16
|
-
checkable?: boolean;
|
|
17
|
-
className?: string;
|
|
18
|
-
treeData?: DataNode[] | any[];
|
|
19
|
-
showIcon?: boolean;
|
|
20
|
-
treeNodeProps?: ITreeNodeProps;
|
|
21
|
-
icon?: (node: DataNode) => JSX.Element;
|
|
22
|
-
}
|
|
23
|
-
declare const BTree: React.ForwardRefExoticComponent<BaseTreeProps & React.RefAttributes<any>>;
|
|
24
|
-
export default BTree;
|
package/es/Tree/index.js
DELETED
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
import "antd/lib/tree/style";
|
|
2
|
-
import _Tree from "antd/lib/tree";
|
|
3
|
-
var _excluded = ["treeData", "className", "showIcon", "treeNodeProps", "icon"];
|
|
4
|
-
|
|
5
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
6
|
-
|
|
7
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
8
|
-
|
|
9
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
10
|
-
|
|
11
|
-
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
12
|
-
|
|
13
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* tree 基础组件支持各种自定义其他tree可用过它来拓展
|
|
17
|
-
*/
|
|
18
|
-
import React, { useImperativeHandle, useMemo, useRef } from 'react';
|
|
19
|
-
import IconFont from "../IconFont";
|
|
20
|
-
import HightLevel from "../HightLevel";
|
|
21
|
-
import "./index.less";
|
|
22
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
23
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
24
|
-
|
|
25
|
-
function BaseTree(_ref, ref) {
|
|
26
|
-
var treeData = _ref.treeData,
|
|
27
|
-
className = _ref.className,
|
|
28
|
-
showIcon = _ref.showIcon,
|
|
29
|
-
treeNodeProps = _ref.treeNodeProps,
|
|
30
|
-
icon = _ref.icon,
|
|
31
|
-
props = _objectWithoutProperties(_ref, _excluded);
|
|
32
|
-
|
|
33
|
-
var prefix = treeNodeProps.prefix,
|
|
34
|
-
suffix = treeNodeProps.suffix,
|
|
35
|
-
keyword = treeNodeProps.keyword,
|
|
36
|
-
_treeNodeProps$key = treeNodeProps.key,
|
|
37
|
-
key = _treeNodeProps$key === void 0 ? 'id' : _treeNodeProps$key,
|
|
38
|
-
_treeNodeProps$nameKe = treeNodeProps.nameKey,
|
|
39
|
-
nameKey = _treeNodeProps$nameKe === void 0 ? 'name' : _treeNodeProps$nameKe,
|
|
40
|
-
RenderTreeTitle = treeNodeProps.RenderTreeTitle;
|
|
41
|
-
var treeRef = useRef(null);
|
|
42
|
-
useImperativeHandle(ref, function () {
|
|
43
|
-
return {
|
|
44
|
-
getCheckedKeys: function getCheckedKeys() {
|
|
45
|
-
if (!props.checkable || !treeRef.current) {
|
|
46
|
-
return [];
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
return treeRef.current.tree.state.checkedKeys;
|
|
50
|
-
}
|
|
51
|
-
};
|
|
52
|
-
}, [props.checkable]);
|
|
53
|
-
|
|
54
|
-
function defaultRenderTitle(node) {
|
|
55
|
-
return /*#__PURE__*/_jsxs("span", {
|
|
56
|
-
title: node[nameKey],
|
|
57
|
-
className: "tree-item-title",
|
|
58
|
-
children: [/*#__PURE__*/_jsxs("span", {
|
|
59
|
-
children: [showIcon && (icon === null || icon === void 0 ? void 0 : icon(node)), prefix === null || prefix === void 0 ? void 0 : prefix(node), /*#__PURE__*/_jsx(HightLevel, {
|
|
60
|
-
keyword: keyword,
|
|
61
|
-
name: node[nameKey]
|
|
62
|
-
})]
|
|
63
|
-
}), suffix === null || suffix === void 0 ? void 0 : suffix(node)]
|
|
64
|
-
});
|
|
65
|
-
} // eslint-disable-next-line react-hooks/exhaustive-deps
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
var titleRender = useMemo(function () {
|
|
69
|
-
return RenderTreeTitle !== null && RenderTreeTitle !== void 0 ? RenderTreeTitle : defaultRenderTitle;
|
|
70
|
-
}, []);
|
|
71
|
-
return /*#__PURE__*/_jsx(_Tree, _objectSpread({
|
|
72
|
-
className: "cloudapp-c-base-tree-component ".concat(className),
|
|
73
|
-
ref: treeRef,
|
|
74
|
-
showIcon: showIcon,
|
|
75
|
-
switcherIcon: /*#__PURE__*/_jsx(IconFont, {
|
|
76
|
-
style: {
|
|
77
|
-
fontSize: 20,
|
|
78
|
-
verticalAlign: '-0.4em'
|
|
79
|
-
},
|
|
80
|
-
type: "lm-player-S_Arrow_SmallDown"
|
|
81
|
-
}),
|
|
82
|
-
treeData: treeData,
|
|
83
|
-
fieldNames: {
|
|
84
|
-
key: key,
|
|
85
|
-
title: nameKey
|
|
86
|
-
},
|
|
87
|
-
titleRender: titleRender
|
|
88
|
-
}, props), keyword);
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
var BTree = /*#__PURE__*/React.forwardRef(BaseTree);
|
|
92
|
-
BTree.defaultProps = {
|
|
93
|
-
treeData: [],
|
|
94
|
-
className: '',
|
|
95
|
-
treeNodeProps: {
|
|
96
|
-
nameKey: 'name',
|
|
97
|
-
key: 'id'
|
|
98
|
-
}
|
|
99
|
-
};
|
|
100
|
-
export default BTree;
|
package/es/Tree/index.less
DELETED
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
.@{ant-prefix}-c-base-tree-component {
|
|
2
|
-
padding: 10px 0;
|
|
3
|
-
user-select: none;
|
|
4
|
-
.@{ant-prefix}-tree-switcher {
|
|
5
|
-
position: relative;
|
|
6
|
-
top: -2px;
|
|
7
|
-
left: 8px;
|
|
8
|
-
z-index: 2;
|
|
9
|
-
margin-right: 5px;
|
|
10
|
-
}
|
|
11
|
-
.@{ant-prefix}-tree-title {
|
|
12
|
-
font-size: var(--fs-small);
|
|
13
|
-
flex: 1 1;
|
|
14
|
-
}
|
|
15
|
-
.@{ant-prefix}-tree-treenode {
|
|
16
|
-
position: relative;
|
|
17
|
-
display: inline-flex;
|
|
18
|
-
width: calc(100% - 32px);
|
|
19
|
-
min-width: max-content;
|
|
20
|
-
font-size: var(--fs-small);
|
|
21
|
-
white-space: nowrap;
|
|
22
|
-
span.@{ant-prefix}-tree-node-content-wrapper {
|
|
23
|
-
position: relative;
|
|
24
|
-
display: inline-flex;
|
|
25
|
-
width: calc(~'100% - 32px');
|
|
26
|
-
min-width: max-content;
|
|
27
|
-
font-size: var(--fs-small);
|
|
28
|
-
&:hover,
|
|
29
|
-
&.@{ant-prefix}-tree-node-selected {
|
|
30
|
-
position: relative;
|
|
31
|
-
color: var(--primary);
|
|
32
|
-
background: transparent;
|
|
33
|
-
|
|
34
|
-
&::after {
|
|
35
|
-
position: absolute;
|
|
36
|
-
bottom: 0;
|
|
37
|
-
left: 0;
|
|
38
|
-
width: 100%;
|
|
39
|
-
content: '';
|
|
40
|
-
border-bottom: 1px solid var(--primary);
|
|
41
|
-
}
|
|
42
|
-
.@{ant-prefix}-tree-switcher,
|
|
43
|
-
.@{ant-prefix}-tree-iconEle {
|
|
44
|
-
color: var(--primary);
|
|
45
|
-
|
|
46
|
-
.anticon {
|
|
47
|
-
color: var(--primary);
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
.@{ant-prefix}-tree-treenode-switcher-open,
|
|
54
|
-
.@{ant-prefix}-tree-treenode-switcher-close {
|
|
55
|
-
.@{ant-prefix}-tree-switcher,
|
|
56
|
-
.@{ant-prefix}-tree-iconEle {
|
|
57
|
-
color: var(--icon);
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
}
|