@carbon/ibm-products 1.47.0 → 1.49.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/css/index-full-carbon.css +1424 -29
- package/css/index-full-carbon.css.map +1 -1
- package/css/index-full-carbon.min.css +5 -5
- package/css/index-full-carbon.min.css.map +1 -1
- package/css/index-without-carbon-released-only.css +37 -15
- package/css/index-without-carbon-released-only.css.map +1 -1
- package/css/index-without-carbon-released-only.min.css +2 -2
- package/css/index-without-carbon-released-only.min.css.map +1 -1
- package/css/index-without-carbon.css +1424 -29
- package/css/index-without-carbon.css.map +1 -1
- package/css/index-without-carbon.min.css +5 -5
- package/css/index-without-carbon.min.css.map +1 -1
- package/css/index.css +1424 -29
- package/css/index.css.map +1 -1
- package/css/index.min.css +5 -5
- package/css/index.min.css.map +1 -1
- package/es/components/AddSelect/AddSelectBreadcrumbs.js +6 -4
- package/es/components/AddSelect/AddSelectList.js +15 -26
- package/es/components/CreateFullPage/CreateFullPage.js +3 -2
- package/es/components/Datagrid/Datagrid/DatagridContent.js +1 -1
- package/es/components/Datagrid/Datagrid/DatagridToolbar.js +1 -1
- package/es/components/Datagrid/Datagrid/DatagridVirtualBody.js +14 -5
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.js +6 -3
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.js +15 -56
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +5 -8
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.js +105 -0
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/TearsheetWrapper.js +1 -0
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +17 -5
- package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +11 -0
- package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +8 -8
- package/es/components/Datagrid/index.js +8 -7
- package/es/components/Datagrid/useOnRowClick.js +3 -3
- package/es/components/Datagrid/useSortableColumns.js +26 -9
- package/es/components/Datagrid/utils/getAutoSizedColumnWidth.js +27 -0
- package/es/components/InlineEditV2/InlineEditV2.js +6 -3
- package/es/components/NonLinearReading/NonLinearReading.js +87 -0
- package/es/components/NonLinearReading/index.js +8 -0
- package/es/components/SidePanel/SidePanel.js +3 -4
- package/es/components/index.js +3 -2
- package/es/global/js/package-settings.js +3 -1
- package/es/global/js/utils/story-helper.js +9 -0
- package/lib/components/AddSelect/AddSelectBreadcrumbs.js +6 -4
- package/lib/components/AddSelect/AddSelectList.js +14 -25
- package/lib/components/CreateFullPage/CreateFullPage.js +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridContent.js +1 -1
- package/lib/components/Datagrid/Datagrid/DatagridToolbar.js +1 -1
- package/lib/components/Datagrid/Datagrid/DatagridVirtualBody.js +13 -4
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.js +6 -3
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.js +15 -56
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +5 -8
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.js +113 -0
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/TearsheetWrapper.js +1 -0
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +17 -5
- package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +11 -0
- package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +3 -1
- package/lib/components/Datagrid/index.js +8 -1
- package/lib/components/Datagrid/useOnRowClick.js +3 -3
- package/lib/components/Datagrid/useSortableColumns.js +26 -9
- package/lib/components/Datagrid/utils/getAutoSizedColumnWidth.js +35 -0
- package/lib/components/InlineEditV2/InlineEditV2.js +6 -3
- package/lib/components/NonLinearReading/NonLinearReading.js +90 -0
- package/lib/components/NonLinearReading/index.js +12 -0
- package/lib/components/SidePanel/SidePanel.js +2 -3
- package/lib/components/index.js +14 -1
- package/lib/global/js/package-settings.js +3 -1
- package/lib/global/js/utils/story-helper.js +12 -2
- package/package.json +2 -2
- package/scss/components/AddSelect/_add-select.scss +0 -10
- package/scss/components/Datagrid/styles/_datagrid.scss +5 -1
- package/scss/components/Datagrid/styles/_useSortableColumns.scss +8 -4
- package/scss/components/InlineEditV1/_inline-edit-v1.scss +1 -5
- package/scss/components/InlineEditV2/_inline-edit-v2.scss +41 -3
- package/scss/components/NonLinearReading/_index.scss +8 -0
- package/scss/components/NonLinearReading/_non-linear-reading.scss +157 -0
- package/scss/components/NonLinearReading/_storybook-styles.scss +13 -0
- package/scss/components/SidePanel/_side-panel.scss +7 -15
- package/scss/components/_index.scss +1 -0
|
@@ -72,16 +72,6 @@
|
|
|
72
72
|
justify-content: center;
|
|
73
73
|
}
|
|
74
74
|
|
|
75
|
-
&-cell:hover .#{$block-class}__selections-hidden-hover,
|
|
76
|
-
.#{$carbon-prefix}--structured-list-row:focus-within
|
|
77
|
-
.#{$block-class}__selections-hidden-hover {
|
|
78
|
-
visibility: visible;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
&-hidden-hover {
|
|
82
|
-
visibility: hidden;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
75
|
&-row--selected.#{$carbon-prefix}--structured-list-row {
|
|
86
76
|
border-bottom: 1px solid $selected-ui;
|
|
87
77
|
background-color: $selected-ui;
|
|
@@ -428,7 +428,7 @@
|
|
|
428
428
|
position: relative;
|
|
429
429
|
width: 100%;
|
|
430
430
|
max-height: 100%;
|
|
431
|
-
overflow-y:
|
|
431
|
+
overflow-y: auto;
|
|
432
432
|
}
|
|
433
433
|
|
|
434
434
|
.#{$block-class}__carbon-row-expanded {
|
|
@@ -613,3 +613,7 @@
|
|
|
613
613
|
padding: 0 $spacing-03;
|
|
614
614
|
}
|
|
615
615
|
}
|
|
616
|
+
|
|
617
|
+
.#{$block-class} .#{$pkg-prefix}--datagrid__head-wrap {
|
|
618
|
+
background-color: $ui-03;
|
|
619
|
+
}
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
.#{$carbon-prefix}--table-header-label .#{$carbon-prefix}--table-sort:active,
|
|
22
22
|
.#{$carbon-prefix}--table-header-label
|
|
23
23
|
.#{$carbon-prefix}--table-sort:focus
|
|
24
|
-
|
|
24
|
+
.#{$block-class}__sortable-icon {
|
|
25
25
|
/* stylelint-disable-next-line declaration-no-important */
|
|
26
26
|
background: none !important;
|
|
27
27
|
/* stylelint-disable-next-line declaration-no-important */
|
|
@@ -44,7 +44,9 @@
|
|
|
44
44
|
color: $text-01 !important;
|
|
45
45
|
font: inherit;
|
|
46
46
|
}
|
|
47
|
-
.#{$carbon-prefix}--table-header-label
|
|
47
|
+
.#{$carbon-prefix}--table-header-label
|
|
48
|
+
.#{$carbon-prefix}--table-sort
|
|
49
|
+
.#{$block-class}__sortable-icon {
|
|
48
50
|
fill: $text-01;
|
|
49
51
|
opacity: 0;
|
|
50
52
|
transition: transform $duration--fast-02 motion(standard, productive);
|
|
@@ -60,12 +62,14 @@
|
|
|
60
62
|
.#{$block-class}__sortableColumn:hover,
|
|
61
63
|
.#{$block-class}__sortableColumn:focus-within,
|
|
62
64
|
.#{$block-class}__sortableColumn.#{$block-class}__isSorted {
|
|
63
|
-
.#{$carbon-prefix}--table-header-label
|
|
65
|
+
.#{$carbon-prefix}--table-header-label .#{$block-class}__sortable-icon {
|
|
64
66
|
opacity: 1;
|
|
65
67
|
visibility: visible;
|
|
66
68
|
}
|
|
67
69
|
}
|
|
68
70
|
|
|
69
|
-
.#{$block-class}__sortableColumn
|
|
71
|
+
.#{$block-class}__sortableColumn
|
|
72
|
+
.#{$block-class}--table-sort--desc
|
|
73
|
+
.#{$block-class}__sortable-icon {
|
|
70
74
|
transform: rotate(180deg);
|
|
71
75
|
}
|
|
@@ -60,7 +60,6 @@
|
|
|
60
60
|
|
|
61
61
|
&:hover {
|
|
62
62
|
--#{$block-class}--background-color: #{$hover-field};
|
|
63
|
-
// background-color: $background-color;
|
|
64
63
|
}
|
|
65
64
|
|
|
66
65
|
position: relative;
|
|
@@ -116,6 +115,7 @@
|
|
|
116
115
|
margin-right: var(--#{$block-class}--toolbar-width);
|
|
117
116
|
// room for toolbar
|
|
118
117
|
margin-left: $spacing-05;
|
|
118
|
+
color: $text-01;
|
|
119
119
|
// stylelint-disable-next-line carbon/type-token-use
|
|
120
120
|
line-height: var(--#{$block-class}--size);
|
|
121
121
|
|
|
@@ -206,10 +206,6 @@
|
|
|
206
206
|
--#{$block-class}--toolbar-width: calc(3 * var(--#{$block-class}--size));
|
|
207
207
|
}
|
|
208
208
|
|
|
209
|
-
.#{$block-class}__toolbar--animation {
|
|
210
|
-
// width: ;
|
|
211
|
-
}
|
|
212
|
-
|
|
213
209
|
&.#{$block-class}--editing .#{$block-class}__toolbar::after {
|
|
214
210
|
// cover top and bottom when focus within block
|
|
215
211
|
// doing the same on the buttons is problematic when animating
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
visibility: hidden;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
|
|
39
|
+
&--focused {
|
|
40
40
|
background: $field-01;
|
|
41
41
|
outline: 2px solid $focus;
|
|
42
42
|
}
|
|
@@ -50,8 +50,7 @@
|
|
|
50
50
|
}
|
|
51
51
|
|
|
52
52
|
&__warning-icon {
|
|
53
|
-
|
|
54
|
-
margin-right: 0.4375rem;
|
|
53
|
+
margin: $spacing-03;
|
|
55
54
|
color: $support-01;
|
|
56
55
|
}
|
|
57
56
|
|
|
@@ -81,6 +80,45 @@
|
|
|
81
80
|
.#{$block-class}__text-input.#{$carbon-input}:active {
|
|
82
81
|
outline: none;
|
|
83
82
|
}
|
|
83
|
+
|
|
84
|
+
.#{$block-class}__toolbar {
|
|
85
|
+
--toolbar-width: #{$spacing-07};
|
|
86
|
+
--toolbar-width-focussed: #{$spacing-10};
|
|
87
|
+
|
|
88
|
+
// animation div
|
|
89
|
+
display: inline-flex;
|
|
90
|
+
overflow: hidden;
|
|
91
|
+
width: var(--toolbar-width);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.#{$block-class}--invalid .#{$block-class}__toolbar {
|
|
95
|
+
--toolbar-width: #{$spacing-07};
|
|
96
|
+
--toolbar-width-focussed: #{$spacing-12};
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
@keyframes slide-in {
|
|
100
|
+
0% {
|
|
101
|
+
overflow: hidden;
|
|
102
|
+
width: var(--toolbar-width);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
99% {
|
|
106
|
+
overflow: hidden;
|
|
107
|
+
width: var(--toolbar-width-focussed);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
100% {
|
|
111
|
+
overflow: visible;
|
|
112
|
+
width: var(--toolbar-width-focussed);
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.#{$block-class}--focused .#{$block-class}__toolbar {
|
|
117
|
+
overflow: initial;
|
|
118
|
+
width: var(--toolbar-width-focussed);
|
|
119
|
+
|
|
120
|
+
animation: slide-in $duration--moderate-01 motion(entrance, productive);
|
|
121
|
+
}
|
|
84
122
|
}
|
|
85
123
|
|
|
86
124
|
@include exports('inline-edit-v2') {
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright IBM Corp. 2023, 2023
|
|
3
|
+
//
|
|
4
|
+
// This source code is licensed under the Apache-2.0 license found in the
|
|
5
|
+
// LICENSE file in the root directory of this source tree.
|
|
6
|
+
//
|
|
7
|
+
|
|
8
|
+
// Standard imports.
|
|
9
|
+
@import '../../global/styles/project-settings';
|
|
10
|
+
|
|
11
|
+
@mixin term-closed-defaults {
|
|
12
|
+
// stylelint-disable-next-line carbon/layout-token-use
|
|
13
|
+
padding: rem(1px) $spacing-03 rem(1px) $spacing-03;
|
|
14
|
+
border: none;
|
|
15
|
+
border-radius: $spacing-04;
|
|
16
|
+
background-color: $interactive-02;
|
|
17
|
+
white-space: nowrap;
|
|
18
|
+
|
|
19
|
+
&:hover {
|
|
20
|
+
background-color: $hover-secondary;
|
|
21
|
+
cursor: pointer;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
@mixin term-open-defaults {
|
|
25
|
+
@include term-closed-defaults();
|
|
26
|
+
|
|
27
|
+
padding-right: 0;
|
|
28
|
+
|
|
29
|
+
svg {
|
|
30
|
+
// stylelint-disable-next-line carbon/layout-token-use
|
|
31
|
+
padding-top: rem(1px);
|
|
32
|
+
margin: 0 $spacing-02 0 $spacing-01;
|
|
33
|
+
vertical-align: text-top;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
@mixin body-defaults {
|
|
37
|
+
@include carbon--type-style('body-long-01');
|
|
38
|
+
|
|
39
|
+
display: block;
|
|
40
|
+
padding: $spacing-03 $spacing-04;
|
|
41
|
+
border-left-width: rem(1.25px);
|
|
42
|
+
border-left-style: solid;
|
|
43
|
+
margin: $spacing-02 0;
|
|
44
|
+
// Novice to pro does not always use Carbon defaults/tokens
|
|
45
|
+
// stylelint-disable-next-line carbon/motion-duration-use, carbon/motion-easing-use
|
|
46
|
+
animation: fade 600ms;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
// Other Carbon settings.
|
|
50
|
+
// TODO: @import 'carbon-components/scss/globals/grid/grid'; if needed
|
|
51
|
+
// NonLinearReading uses the following Carbon components:
|
|
52
|
+
// TODO: @import(s) of Carbon component styles used by NonLinearReading
|
|
53
|
+
// NonLinearReading uses the following Carbon for IBM Products components:
|
|
54
|
+
// TODO: @import(s) of IBM Products component styles used by NonLinearReading
|
|
55
|
+
// Define all component styles in a mixin which is then exported using
|
|
56
|
+
// the Carbon import-once mechanism.
|
|
57
|
+
@mixin non-linear-reading {
|
|
58
|
+
// The block part of our conventional BEM class names (blockClass__E--M).
|
|
59
|
+
$block-class: #{$pkg-prefix}--non-linear-reading;
|
|
60
|
+
|
|
61
|
+
@keyframes fade {
|
|
62
|
+
0% {
|
|
63
|
+
opacity: 0;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
15% {
|
|
67
|
+
opacity: 0;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
100% {
|
|
71
|
+
opacity: 1;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.#{$block-class} {
|
|
76
|
+
&__term {
|
|
77
|
+
&-light {
|
|
78
|
+
&--closed {
|
|
79
|
+
@include term-closed-defaults();
|
|
80
|
+
|
|
81
|
+
background-color: $interactive-02;
|
|
82
|
+
color: $inverse-01;
|
|
83
|
+
|
|
84
|
+
&:hover {
|
|
85
|
+
background-color: $hover-secondary;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
&--open {
|
|
90
|
+
@include term-open-defaults();
|
|
91
|
+
|
|
92
|
+
// Novice to pro does not always use Carbon defaults/tokens
|
|
93
|
+
// stylelint-disable-next-line carbon/theme-token-use
|
|
94
|
+
background-color: $purple-20;
|
|
95
|
+
color: $text-01;
|
|
96
|
+
|
|
97
|
+
&:hover {
|
|
98
|
+
// stylelint-disable-next-line carbon/theme-token-use
|
|
99
|
+
background-color: #dcc7ff;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
&-dark {
|
|
105
|
+
&--closed {
|
|
106
|
+
@include carbon--theme($carbon--theme--g100, true);
|
|
107
|
+
@include term-closed-defaults();
|
|
108
|
+
|
|
109
|
+
background-color: $interactive-02;
|
|
110
|
+
color: $text-04;
|
|
111
|
+
|
|
112
|
+
&:hover {
|
|
113
|
+
background-color: $hover-secondary;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
&--open {
|
|
118
|
+
@include carbon--theme($carbon--theme--g100, true);
|
|
119
|
+
@include term-open-defaults();
|
|
120
|
+
|
|
121
|
+
// stylelint-disable-next-line carbon/theme-token-use
|
|
122
|
+
background-color: #491d8b;
|
|
123
|
+
color: $text-04;
|
|
124
|
+
|
|
125
|
+
&:hover {
|
|
126
|
+
// stylelint-disable-next-line carbon/theme-token-use
|
|
127
|
+
background-color: #7f3ae7;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
&--body {
|
|
134
|
+
&-light {
|
|
135
|
+
@include body-defaults();
|
|
136
|
+
|
|
137
|
+
// stylelint-disable-next-line carbon/theme-token-use
|
|
138
|
+
border-left-color: #6929c4;
|
|
139
|
+
// stylelint-disable-next-line carbon/theme-token-use
|
|
140
|
+
color: #6929c4;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
&-dark {
|
|
144
|
+
@include carbon--theme($carbon--theme--g100, true);
|
|
145
|
+
@include body-defaults();
|
|
146
|
+
|
|
147
|
+
// stylelint-disable-next-line carbon/theme-token-use
|
|
148
|
+
border-left-color: #d4bbff;
|
|
149
|
+
// stylelint-disable-next-line carbon/theme-token-use
|
|
150
|
+
color: #d4bbff;
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
@include exports('non-linear-reading') {
|
|
156
|
+
@include non-linear-reading;
|
|
157
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright IBM Corp. 2023, 2023
|
|
3
|
+
//
|
|
4
|
+
// This source code is licensed under the Apache-2.0 license found in the
|
|
5
|
+
// LICENSE file in the root directory of this source tree.
|
|
6
|
+
//
|
|
7
|
+
|
|
8
|
+
@import '../../global/styles/project-settings';
|
|
9
|
+
|
|
10
|
+
// For demo purposes, have text surrounding component match styling in component.
|
|
11
|
+
#root {
|
|
12
|
+
@include carbon--type-style('body-long-01');
|
|
13
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//
|
|
2
|
-
// Copyright IBM Corp. 2020,
|
|
2
|
+
// Copyright IBM Corp. 2020, 2023
|
|
3
3
|
//
|
|
4
4
|
// This source code is licensed under the Apache-2.0 license found in the
|
|
5
5
|
// LICENSE file in the root directory of this source tree.
|
|
@@ -309,19 +309,10 @@ $action-set-block-class: #{$pkg-prefix}--action-set;
|
|
|
309
309
|
margin-bottom: $spacing-03;
|
|
310
310
|
background-color: $ui-01;
|
|
311
311
|
transition: transform $duration--moderate-01 carbon--motion(standard);
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
color: $text-01;
|
|
317
|
-
}
|
|
318
|
-
&.#{$block-class}__action-toolbar-icon-only-button svg {
|
|
319
|
-
margin-left: $spacing-03;
|
|
320
|
-
}
|
|
321
|
-
&.#{$block-class}__action-toolbar-leading-button {
|
|
322
|
-
margin-right: $spacing-03;
|
|
323
|
-
}
|
|
324
|
-
}
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
.#{$block-class}__action-toolbar-leading-button {
|
|
315
|
+
margin-right: $spacing-03;
|
|
325
316
|
}
|
|
326
317
|
|
|
327
318
|
.#{$carbon-prefix}--btn.#{$block-class}__navigation-back-button {
|
|
@@ -336,6 +327,7 @@ $action-set-block-class: #{$pkg-prefix}--action-set;
|
|
|
336
327
|
padding: 0;
|
|
337
328
|
color: $text-01;
|
|
338
329
|
}
|
|
330
|
+
|
|
339
331
|
.#{$carbon-prefix}--btn.#{$block-class}__close-button {
|
|
340
332
|
position: absolute;
|
|
341
333
|
z-index: 5;
|
|
@@ -344,8 +336,8 @@ $action-set-block-class: #{$pkg-prefix}--action-set;
|
|
|
344
336
|
display: flex;
|
|
345
337
|
align-items: center;
|
|
346
338
|
justify-content: center;
|
|
347
|
-
background-color: $ui-01;
|
|
348
339
|
}
|
|
340
|
+
|
|
349
341
|
.#{$carbon-prefix}--btn.#{$block-class}__close-button
|
|
350
342
|
.#{$carbon-prefix}--btn__icon {
|
|
351
343
|
margin: 0;
|