@carbon/ibm-products 1.3.0 → 1.6.1
Sign up to get free protection for your applications and to get access to all the features.
- package/css/index-full-carbon.css +5102 -4711
- package/css/index-full-carbon.css.map +1 -1
- package/css/index-full-carbon.min.css +9 -3
- package/css/index-full-carbon.min.css.map +1 -0
- package/css/index-without-carbon-released-only.css +189 -108
- package/css/index-without-carbon-released-only.css.map +1 -1
- package/css/index-without-carbon-released-only.min.css +3 -3
- package/css/index-without-carbon-released-only.min.css.map +1 -0
- package/css/index-without-carbon.css +619 -236
- package/css/index-without-carbon.css.map +1 -1
- package/css/index-without-carbon.min.css +9 -3
- package/css/index-without-carbon.min.css.map +1 -0
- package/css/index.css +950 -567
- package/css/index.css.map +1 -1
- package/css/index.min.css +9 -3
- package/css/index.min.css.map +1 -0
- package/es/components/APIKeyModal/APIKeyModal.js +25 -29
- package/es/components/ActionBar/ActionBar.js +4 -1
- package/es/components/ActionSet/ActionSet.js +22 -10
- package/es/components/ActionSet/actions.js +25 -17
- package/es/components/AddSelect/AddSelect.js +141 -53
- package/es/components/AddSelect/AddSelectBreadcrumbs.js +56 -0
- package/es/components/AddSelect/AddSelectList.js +94 -0
- package/es/components/AddSelect/AddSelectSidebar.js +78 -0
- package/es/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +24 -17
- package/es/components/CancelableTextEdit/CancelableTextEdit.js +62 -24
- package/es/components/Card/Card.js +6 -4
- package/es/components/CreateFullPage/CreateFullPage.js +102 -258
- package/es/components/CreateFullPage/CreateFullPageStep.js +65 -13
- package/es/components/CreateFullPage/index.js +1 -2
- package/es/components/CreateInfluencer/CreateInfluencer.js +40 -220
- package/es/components/CreateTearsheet/CreateTearsheet.js +95 -146
- package/es/components/CreateTearsheet/CreateTearsheetStep.js +70 -20
- package/es/components/CreateTearsheet/index.js +0 -1
- package/es/components/CreateTearsheet/preview-components/MultiStepTearsheet.js +87 -28
- package/es/components/CreateTearsheet/preview-components/MultiStepWithIntro.js +8 -6
- package/es/components/EmptyStates/EmptyState.js +1 -1
- package/es/components/EmptyStates/EmptyStateContent.js +2 -2
- package/es/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +1 -1
- package/es/components/EmptyStates/NoDataEmptyState/NoDataEmptyState.js +1 -1
- package/es/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +1 -1
- package/es/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +1 -1
- package/es/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +1 -1
- package/es/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +1 -1
- package/es/components/ExportModal/ExportModal.js +41 -12
- package/es/components/ImportModal/ImportModal.js +2 -1
- package/es/components/InlineEdit/InlineEdit.js +397 -0
- package/es/components/InlineEdit/index.js +7 -0
- package/es/components/MultiAddSelect/MultiAddSelect.js +16 -0
- package/es/components/MultiAddSelect/index.js +1 -0
- package/es/components/NotificationsPanel/NotificationsPanel.js +16 -3
- package/es/components/OptionsTile/OptionsTile.js +36 -15
- package/es/components/PageHeader/PageHeader.js +59 -35
- package/es/components/PageHeader/PageHeaderTitle.js +82 -7
- package/es/components/PageHeader/PageHeaderUtils.js +21 -2
- package/es/components/RemoveModal/RemoveModal.js +4 -2
- package/es/components/SidePanel/SidePanel.js +33 -16
- package/es/components/SingleAddSelect/SingleAddSelect.js +15 -0
- package/es/components/SingleAddSelect/index.js +1 -0
- package/es/components/TagSet/TagSet.js +4 -1
- package/es/components/Tearsheet/Tearsheet.js +1 -1
- package/es/components/Tearsheet/TearsheetNarrow.js +1 -1
- package/es/components/Tearsheet/TearsheetShell.js +1 -1
- package/es/components/Toolbar/Toolbar.js +69 -8
- package/es/components/WebTerminal/WebTerminal.js +1 -1
- package/es/components/index.js +4 -2
- package/es/global/js/hooks/index.js +1 -0
- package/es/global/js/hooks/useCreateComponentFocus.js +15 -19
- package/es/global/js/hooks/useCreateComponentStepChange.js +69 -79
- package/es/global/js/hooks/useResetCreateComponent.js +7 -4
- package/es/global/js/hooks/useRetrieveStepData.js +51 -0
- package/es/global/js/hooks/useValidCreateStepCount.js +4 -7
- package/es/global/js/package-settings.js +4 -2
- package/es/global/js/utils/lastIndexInArray.js +26 -0
- package/es/settings.js +0 -5
- package/lib/components/APIKeyModal/APIKeyModal.js +25 -29
- package/lib/components/ActionBar/ActionBar.js +4 -1
- package/lib/components/ActionSet/ActionSet.js +22 -10
- package/lib/components/ActionSet/actions.js +25 -17
- package/lib/components/AddSelect/AddSelect.js +141 -50
- package/lib/components/AddSelect/AddSelectBreadcrumbs.js +71 -0
- package/lib/components/AddSelect/AddSelectList.js +112 -0
- package/lib/components/AddSelect/AddSelectSidebar.js +89 -0
- package/lib/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +23 -16
- package/lib/components/CancelableTextEdit/CancelableTextEdit.js +62 -23
- package/lib/components/Card/Card.js +6 -4
- package/lib/components/CreateFullPage/CreateFullPage.js +102 -258
- package/lib/components/CreateFullPage/CreateFullPageStep.js +68 -13
- package/lib/components/CreateFullPage/index.js +1 -9
- package/lib/components/CreateInfluencer/CreateInfluencer.js +38 -231
- package/lib/components/CreateTearsheet/CreateTearsheet.js +97 -148
- package/lib/components/CreateTearsheet/CreateTearsheetStep.js +72 -19
- package/lib/components/CreateTearsheet/index.js +0 -8
- package/lib/components/CreateTearsheet/preview-components/MultiStepTearsheet.js +86 -34
- package/lib/components/CreateTearsheet/preview-components/MultiStepWithIntro.js +8 -6
- package/lib/components/EmptyStates/EmptyState.js +1 -1
- package/lib/components/EmptyStates/EmptyStateContent.js +2 -2
- package/lib/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +1 -1
- package/lib/components/EmptyStates/NoDataEmptyState/NoDataEmptyState.js +1 -1
- package/lib/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +1 -1
- package/lib/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +1 -1
- package/lib/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +1 -1
- package/lib/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +1 -1
- package/lib/components/ExportModal/ExportModal.js +38 -11
- package/lib/components/ImportModal/ImportModal.js +2 -1
- package/lib/components/InlineEdit/InlineEdit.js +413 -0
- package/lib/components/InlineEdit/index.js +13 -0
- package/lib/components/MultiAddSelect/MultiAddSelect.js +37 -0
- package/lib/components/MultiAddSelect/index.js +13 -0
- package/lib/components/NotificationsPanel/NotificationsPanel.js +13 -1
- package/lib/components/OptionsTile/OptionsTile.js +36 -15
- package/lib/components/PageHeader/PageHeader.js +59 -35
- package/lib/components/PageHeader/PageHeaderTitle.js +91 -9
- package/lib/components/PageHeader/PageHeaderUtils.js +21 -2
- package/lib/components/RemoveModal/RemoveModal.js +4 -2
- package/lib/components/SidePanel/SidePanel.js +33 -16
- package/lib/components/SingleAddSelect/SingleAddSelect.js +36 -0
- package/lib/components/SingleAddSelect/index.js +13 -0
- package/lib/components/TagSet/TagSet.js +4 -1
- package/lib/components/Tearsheet/Tearsheet.js +1 -1
- package/lib/components/Tearsheet/TearsheetNarrow.js +1 -1
- package/lib/components/Tearsheet/TearsheetShell.js +1 -1
- package/lib/components/Toolbar/Toolbar.js +69 -6
- package/lib/components/WebTerminal/WebTerminal.js +1 -1
- package/lib/components/index.js +25 -9
- package/lib/global/js/hooks/index.js +8 -0
- package/lib/global/js/hooks/useCreateComponentFocus.js +15 -19
- package/lib/global/js/hooks/useCreateComponentStepChange.js +69 -79
- package/lib/global/js/hooks/useResetCreateComponent.js +7 -4
- package/lib/global/js/hooks/useRetrieveStepData.js +62 -0
- package/lib/global/js/hooks/useValidCreateStepCount.js +4 -7
- package/lib/global/js/package-settings.js +4 -2
- package/lib/global/js/utils/lastIndexInArray.js +35 -0
- package/lib/settings.js +0 -6
- package/package.json +24 -24
- package/scss/components/AddSelect/_add-select.scss +53 -8
- package/scss/components/BreadcrumbWithOverflow/_breadcrumb-with-overflow.scss +19 -15
- package/scss/components/BreadcrumbWithOverflow/_index.scss +1 -1
- package/scss/components/CancelableTextEdit/_cancelable-text-edit.scss +142 -70
- package/scss/components/CancelableTextEdit/_storybook-styles.scss +0 -7
- package/scss/components/CreateFullPage/_create-full-page.scss +4 -11
- package/scss/components/CreateInfluencer/_create-influencer.scss +4 -4
- package/scss/components/CreateTearsheet/_create-tearsheet.scss +6 -10
- package/scss/components/CreateTearsheetNarrow/_storybook-styles.scss +0 -6
- package/scss/components/EditSidePanel/_storybook-styles.scss +0 -8
- package/scss/components/InlineEdit/_index.scss +8 -0
- package/scss/components/InlineEdit/_inline-edit.scss +320 -0
- package/scss/components/InlineEdit/_storybook-styles.scss +21 -0
- package/scss/components/LoadingBar/_storybook-styles.scss +0 -5
- package/scss/components/MultiAddSelect/_index.scss +1 -0
- package/scss/components/MultiAddSelect/_multi-add-select.scss +1 -0
- package/scss/components/MultiAddSelect/_storybook-styles.scss +6 -0
- package/scss/components/NotificationsPanel/_notifications-panel.scss +2 -2
- package/scss/components/OptionsTile/_storybook-styles.scss +0 -7
- package/scss/components/PageHeader/_index.scss +1 -1
- package/scss/components/PageHeader/_page-header.scss +18 -5
- package/scss/components/ProductiveCard/_productive-card.scss +0 -4
- package/scss/components/SidePanel/_side-panel.scss +15 -6
- package/scss/components/SingleAddSelect/_index.scss +1 -0
- package/scss/components/SingleAddSelect/_single-add-select.scss +1 -0
- package/scss/components/SingleAddSelect/_storybook-styles.scss +6 -0
- package/scss/components/StatusIcon/_index.scss +1 -1
- package/scss/components/StatusIcon/_status-icon.scss +6 -4
- package/scss/components/TagSet/_index.scss +1 -1
- package/scss/components/UserProfileImage/_index.scss +1 -1
- package/scss/components/UserProfileImage/_user-profile-image.scss +2 -2
- package/scss/components/WebTerminal/_web-terminal.scss +2 -2
- package/scss/components/_index.scss +3 -1
- package/scss/global/styles/_project-settings.scss +5 -1
- package/es/components/CreateFullPage/CreateFullPageSection.js +0 -53
- package/es/components/CreateFullPage/constants.js +0 -8
- package/es/components/CreateTearsheet/CreateTearsheetSection.js +0 -83
- package/es/components/CreateTearsheet/constants.js +0 -8
- package/es/components/CreateTearsheet/preview-components/MultiStepWithSectionsTearsheet.js +0 -327
- package/es/generated/feature-flags/feature-flags.js +0 -15
- package/es/global/js/utils/hasValidType.js +0 -94
- package/lib/components/CreateFullPage/CreateFullPageSection.js +0 -74
- package/lib/components/CreateFullPage/constants.js +0 -16
- package/lib/components/CreateTearsheet/CreateTearsheetSection.js +0 -105
- package/lib/components/CreateTearsheet/constants.js +0 -17
- package/lib/components/CreateTearsheet/preview-components/MultiStepWithSectionsTearsheet.js +0 -354
- package/lib/generated/feature-flags/feature-flags.js +0 -22
- package/lib/global/js/utils/hasValidType.js +0 -110
- package/scss/generated/feature-flags/_feature-flags.scss +0 -19
@@ -0,0 +1,320 @@
|
|
1
|
+
//
|
2
|
+
// Copyright IBM Corp. 2022, 2022
|
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
|
+
@import '../../global/styles/mixins';
|
11
|
+
|
12
|
+
// Other Carbon settings.
|
13
|
+
// TODO: @import 'carbon-components/scss/globals/grid/grid'; if needed
|
14
|
+
|
15
|
+
// InlineEdit uses the following Carbon components:
|
16
|
+
// TODO: @import(s) of Carbon component styles used by InlineEdit
|
17
|
+
|
18
|
+
// InlineEdit uses the following Carbon for IBM Products components:
|
19
|
+
// TODO: @import(s) of IBM Products component styles used by InlineEdit
|
20
|
+
|
21
|
+
// cut down version borrowed from 'carbon-components/scss/globals/scss/vendor/@carbon/styles/scss/utilities/focus-outline';
|
22
|
+
@mixin input-outline($color: $focus) {
|
23
|
+
outline: $spacing-01 solid $color;
|
24
|
+
outline-offset: calc(-1 * $spacing-01);
|
25
|
+
|
26
|
+
@media screen and (prefers-contrast) {
|
27
|
+
outline-style: dotted;
|
28
|
+
}
|
29
|
+
}
|
30
|
+
|
31
|
+
@function --tooltip-top-bottom-safe-clip() {
|
32
|
+
@return polygon(
|
33
|
+
0 0,
|
34
|
+
-100vw 0,
|
35
|
+
-100vw -100vh,
|
36
|
+
100vw -100vh,
|
37
|
+
100vw 0,
|
38
|
+
100% 0,
|
39
|
+
100% 100%,
|
40
|
+
100vw 100%,
|
41
|
+
100vw 100vh,
|
42
|
+
-100vw 100vh,
|
43
|
+
-100vw 100%,
|
44
|
+
0 100%
|
45
|
+
);
|
46
|
+
}
|
47
|
+
|
48
|
+
@mixin input-button-defaults($block-class) {
|
49
|
+
display: inline-flex;
|
50
|
+
width: var(--#{$block-class}--size);
|
51
|
+
height: 100%;
|
52
|
+
min-height: initial;
|
53
|
+
max-height: var(--#{$block-class}--size);
|
54
|
+
|
55
|
+
// stylelint-disable-next-line carbon/layout-token-use
|
56
|
+
padding: calc(
|
57
|
+
0.5 * (var(--#{$block-class}--size) - var(--#{$block-class}--icon-size)) - #{$spacing-01}
|
58
|
+
);
|
59
|
+
border: 2px solid transparent;
|
60
|
+
}
|
61
|
+
|
62
|
+
// Define all component styles in a mixin which is then exported using
|
63
|
+
// the Carbon import-once mechanism.
|
64
|
+
@mixin inline-edit {
|
65
|
+
// The block part of our conventional BEM class names (blockClass__E--M).
|
66
|
+
$block-class: #{$pkg-prefix}--inline-edit;
|
67
|
+
|
68
|
+
@include block-wrap($block-class) {
|
69
|
+
--#{$block-class}--size: #{$spacing-08};
|
70
|
+
--#{$block-class}--icon-size: #{$spacing-05};
|
71
|
+
--#{$block-class}--background-color: #{$ui-01};
|
72
|
+
|
73
|
+
&.#{$block-class}--light {
|
74
|
+
--#{$block-class}--background-color: transparent;
|
75
|
+
}
|
76
|
+
|
77
|
+
&:hover {
|
78
|
+
--#{$block-class}--background-color: #{$hover-field};
|
79
|
+
// background-color: $background-color;
|
80
|
+
}
|
81
|
+
|
82
|
+
position: relative;
|
83
|
+
display: inline-block;
|
84
|
+
// min-width: 250px; // similar to min input box with room for toolbar
|
85
|
+
max-width: 100%;
|
86
|
+
height: var(--#{$block-class}--size);
|
87
|
+
background-color: var(--#{$block-class}--background-color);
|
88
|
+
cursor: text; // appear to be part of the text box
|
89
|
+
transition: background-color $duration--fast-01 motion(entrance, productive),
|
90
|
+
box-shadow $duration--fast-01 motion(entrance, productive),
|
91
|
+
border-color $duration--fast-01 motion(entrance, productive);
|
92
|
+
|
93
|
+
white-space: nowrap;
|
94
|
+
|
95
|
+
&.#{$block-class}--sm {
|
96
|
+
--#{$block-class}--size: #{$spacing-07};
|
97
|
+
--#{$block-class}--icon-size: #{$spacing-05};
|
98
|
+
}
|
99
|
+
|
100
|
+
&.#{$block-class}--lg {
|
101
|
+
--#{$block-class}--size: #{$spacing-09};
|
102
|
+
--#{$block-class}--icon-size: #{$spacing-05};
|
103
|
+
}
|
104
|
+
|
105
|
+
&.#{$block-class}--editing {
|
106
|
+
@include input-outline($focus);
|
107
|
+
|
108
|
+
background-color: $ui-01;
|
109
|
+
}
|
110
|
+
|
111
|
+
.#{$block-class}--invalid {
|
112
|
+
@include input-outline($support-01);
|
113
|
+
}
|
114
|
+
|
115
|
+
.#{$block-class}__input {
|
116
|
+
display: inline-block;
|
117
|
+
overflow: hidden;
|
118
|
+
// positions text and placeholder including when showing placeholder
|
119
|
+
// NOTE: Using flex does strange things to a caret in content editable
|
120
|
+
min-width: calc(100% - 3 * var(--#{$block-class}--size) - $spacing-05);
|
121
|
+
max-width: calc(100% - 3 * var(--#{$block-class}--size) - $spacing-05);
|
122
|
+
min-height: var(--#{$block-class}--size);
|
123
|
+
// stylelint-disable-next-line carbon/layout-token-use
|
124
|
+
margin-right: calc(3 * var(--#{$block-class}--size));
|
125
|
+
// room for toolbar
|
126
|
+
margin-left: $spacing-05;
|
127
|
+
// stylelint-disable-next-line carbon/type-token-use
|
128
|
+
line-height: var(--#{$block-class}--size);
|
129
|
+
|
130
|
+
&:focus {
|
131
|
+
outline: none;
|
132
|
+
}
|
133
|
+
}
|
134
|
+
|
135
|
+
.#{$block-class}__input::after {
|
136
|
+
position: absolute;
|
137
|
+
top: 0;
|
138
|
+
left: 0;
|
139
|
+
display: block;
|
140
|
+
margin-left: $spacing-05;
|
141
|
+
color: $text-05;
|
142
|
+
content: attr(data-placeholder);
|
143
|
+
opacity: 0;
|
144
|
+
}
|
145
|
+
|
146
|
+
.#{$block-class}__ellipsis {
|
147
|
+
display: inline-block;
|
148
|
+
overflow: hidden;
|
149
|
+
width: 0;
|
150
|
+
height: var(--#{$block-class}--size);
|
151
|
+
// stylelint-disable-next-line carbon/type-token-use
|
152
|
+
line-height: var(--#{$block-class}--size);
|
153
|
+
opacity: 0;
|
154
|
+
pointer-events: none;
|
155
|
+
|
156
|
+
// only transition fade in
|
157
|
+
transition: opacity $duration--moderate-02 motion(standard, productive);
|
158
|
+
}
|
159
|
+
|
160
|
+
&.#{$block-class}--overflows:not(.#{$block-class}--editing)
|
161
|
+
.#{$block-class}__ellipsis {
|
162
|
+
width: initial;
|
163
|
+
opacity: 1;
|
164
|
+
}
|
165
|
+
|
166
|
+
.#{$block-class}__disabled-cover {
|
167
|
+
position: absolute;
|
168
|
+
top: 0;
|
169
|
+
left: 0;
|
170
|
+
width: 100%;
|
171
|
+
height: 100%;
|
172
|
+
pointer-events: none; // act as if not there
|
173
|
+
}
|
174
|
+
|
175
|
+
&.#{$block-class}--disabled .#{$block-class}__disabled-cover {
|
176
|
+
// when disabled prevent pointer events going through to the input
|
177
|
+
cursor: not-allowed;
|
178
|
+
pointer-events: all;
|
179
|
+
}
|
180
|
+
|
181
|
+
.#{$block-class}__input--empty::after {
|
182
|
+
opacity: 1;
|
183
|
+
// only transition fade in
|
184
|
+
transition: opacity $duration--moderate-02 motion(standard, productive);
|
185
|
+
}
|
186
|
+
|
187
|
+
.#{$block-class}__after-input-elements {
|
188
|
+
// not simply flexed in as this causes flexbox to mis-measure the size of the input
|
189
|
+
position: absolute;
|
190
|
+
top: 0;
|
191
|
+
right: 0;
|
192
|
+
display: flex;
|
193
|
+
// width: room for validation, and two buttons
|
194
|
+
width: calc(3 * var(--#{$block-class}--size));
|
195
|
+
height: 100%;
|
196
|
+
justify-content: space-between;
|
197
|
+
cursor: text;
|
198
|
+
}
|
199
|
+
|
200
|
+
.#{$block-class}__toolbar--animation {
|
201
|
+
// makes room for the top clip text but hides the side overflow
|
202
|
+
clip-path: --tooltip-top-bottom-safe-clip();
|
203
|
+
// NOTE: The above allows the tooltip to show through when overflowX: hidden would not when at right edge.
|
204
|
+
// It is used with margin animation of contained buttons
|
205
|
+
}
|
206
|
+
|
207
|
+
&.#{$block-class}--editing .#{$block-class}__toolbar::after {
|
208
|
+
// cover top and bottom when focus within block
|
209
|
+
// doing the same on the buttons is problematic when animating
|
210
|
+
// and causes visual artifacts when the button is hovered without focus
|
211
|
+
// as the buttons leave a 45% join between sides with transparent borders and top/bottom with $focus
|
212
|
+
position: absolute;
|
213
|
+
top: 0;
|
214
|
+
left: 0;
|
215
|
+
display: block;
|
216
|
+
width: 100%;
|
217
|
+
height: 100%;
|
218
|
+
box-sizing: border-box;
|
219
|
+
border: 2px solid $focus;
|
220
|
+
border-left: 0;
|
221
|
+
content: '';
|
222
|
+
pointer-events: none;
|
223
|
+
}
|
224
|
+
|
225
|
+
&.#{$block-class}.#{$block-class} .#{$block-class}__save,
|
226
|
+
&.#{$block-class}.#{$block-class} .#{$block-class}__cancel {
|
227
|
+
@include input-button-defaults($block-class);
|
228
|
+
|
229
|
+
// input does not have focus
|
230
|
+
&:hover {
|
231
|
+
outline: initial;
|
232
|
+
}
|
233
|
+
|
234
|
+
&:focus:active,
|
235
|
+
&:focus {
|
236
|
+
// border focus input does NOT have focus
|
237
|
+
border-color: $focus;
|
238
|
+
box-shadow: initial;
|
239
|
+
outline: initial;
|
240
|
+
}
|
241
|
+
|
242
|
+
&:focus:active:hover {
|
243
|
+
box-shadow: inset 0 0 0 1px $field-01;
|
244
|
+
}
|
245
|
+
|
246
|
+
&::before {
|
247
|
+
background-color: transparent;
|
248
|
+
}
|
249
|
+
|
250
|
+
&[disabled] {
|
251
|
+
border-color: transparent;
|
252
|
+
}
|
253
|
+
}
|
254
|
+
|
255
|
+
&.#{$block-class}--editing
|
256
|
+
.#{$block-class}__toolbar--animation
|
257
|
+
.#{$block-class}__save {
|
258
|
+
// stylelint-disable-next-line carbon/layout-token-use
|
259
|
+
margin-right: calc(-1 * var(--#{$block-class}--size));
|
260
|
+
transition: margin-right $duration--moderate-02
|
261
|
+
motion(standard, productive);
|
262
|
+
}
|
263
|
+
|
264
|
+
&.#{$block-class}--editing
|
265
|
+
.#{$block-class}__toolbar--saveable
|
266
|
+
.#{$block-class}__save {
|
267
|
+
margin-right: 0;
|
268
|
+
}
|
269
|
+
|
270
|
+
&.#{$block-class}.#{$block-class} .#{$block-class}__edit {
|
271
|
+
@include input-button-defaults($block-class);
|
272
|
+
|
273
|
+
// pointer-events: none;
|
274
|
+
|
275
|
+
&:hover,
|
276
|
+
&:active,
|
277
|
+
&:focus {
|
278
|
+
border-color: transparent;
|
279
|
+
background-color: transparent;
|
280
|
+
box-shadow: initial;
|
281
|
+
outline: initial;
|
282
|
+
}
|
283
|
+
}
|
284
|
+
|
285
|
+
.#{$block-class}__edit--hover-visible {
|
286
|
+
opacity: 0;
|
287
|
+
transition: opacity $duration--fast-01 motion(entrance, productive);
|
288
|
+
}
|
289
|
+
|
290
|
+
&:hover .#{$block-class}__edit--hover-visible {
|
291
|
+
opacity: 1;
|
292
|
+
}
|
293
|
+
|
294
|
+
.#{$block-class}__validation-icon {
|
295
|
+
@include input-button-defaults($block-class);
|
296
|
+
}
|
297
|
+
|
298
|
+
&.#{$block-class}--warn .#{$block-class}__validation-icon {
|
299
|
+
color: $support-warning;
|
300
|
+
}
|
301
|
+
|
302
|
+
&.#{$block-class}--invalid .#{$block-class}__validation-icon {
|
303
|
+
color: $support-error;
|
304
|
+
}
|
305
|
+
|
306
|
+
.#{$block-class}__validation-text {
|
307
|
+
display: block;
|
308
|
+
overflow: visible;
|
309
|
+
margin-left: $spacing-05;
|
310
|
+
}
|
311
|
+
|
312
|
+
&.#{$block-class}--invalid .#{$block-class}__validation-text {
|
313
|
+
color: $support-error;
|
314
|
+
}
|
315
|
+
}
|
316
|
+
}
|
317
|
+
|
318
|
+
@include exports('inline-edit') {
|
319
|
+
@include inline-edit;
|
320
|
+
}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
//
|
2
|
+
// Copyright IBM Corp. 2022, 2022
|
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
|
+
.inline-edit-stories__viewport {
|
11
|
+
// width: 300px; // larger than standard size needed by text input at standard font size (html input attribute size)
|
12
|
+
// stylelint-disable-next-line carbon/layout-token-use
|
13
|
+
margin: 100px;
|
14
|
+
}
|
15
|
+
|
16
|
+
$block-class: #{$pkg-prefix}--inline-edit;
|
17
|
+
.component-full-width {
|
18
|
+
.#{$block-class} {
|
19
|
+
width: 100%;
|
20
|
+
}
|
21
|
+
}
|
@@ -12,8 +12,3 @@
|
|
12
12
|
width: 24rem;
|
13
13
|
margin: $spacing-07 $spacing-05 $spacing-05 $spacing-05;
|
14
14
|
}
|
15
|
-
|
16
|
-
// Uncomment next line (which must appear last) to test in storybook
|
17
|
-
// that the SCSS styles for this component are sufficiently specific
|
18
|
-
// to override Carbon whichever order the styles get loaded in.
|
19
|
-
// @import 'carbon-components/css/carbon-components.min';
|
@@ -0,0 +1 @@
|
|
1
|
+
@import './multi-add-select';
|
@@ -0,0 +1 @@
|
|
1
|
+
@import '../AddSelect/add-select';
|
@@ -20,7 +20,7 @@
|
|
20
20
|
|
21
21
|
@mixin notifications-panel {
|
22
22
|
$block-class: #{$pkg-prefix}--notifications-panel;
|
23
|
-
@keyframes
|
23
|
+
@keyframes fade-in {
|
24
24
|
0% {
|
25
25
|
opacity: 0;
|
26
26
|
// stylelint-disable-next-line carbon/layout-token-use
|
@@ -32,7 +32,7 @@
|
|
32
32
|
}
|
33
33
|
}
|
34
34
|
|
35
|
-
@keyframes
|
35
|
+
@keyframes fade-out {
|
36
36
|
0% {
|
37
37
|
opacity: 1;
|
38
38
|
transform: translateY(0);
|
@@ -5,8 +5,6 @@
|
|
5
5
|
// LICENSE file in the root directory of this source tree.
|
6
6
|
//
|
7
7
|
|
8
|
-
@import './index';
|
9
|
-
|
10
8
|
@import '../../global/styles/project-settings';
|
11
9
|
|
12
10
|
$block-class: #{$pkg-prefix}--options-tile;
|
@@ -26,8 +24,3 @@ $block-class: #{$pkg-prefix}--options-tile;
|
|
26
24
|
.#{$block-class}__content .#{$carbon-prefix}--dropdown__wrapper:first-of-type {
|
27
25
|
margin-bottom: $spacing-06;
|
28
26
|
}
|
29
|
-
|
30
|
-
// Uncomment next line (which must appear last) to test in storybook
|
31
|
-
// that the SCSS styles for this component are sufficiently specific
|
32
|
-
// to override Carbon whichever order the styles get loaded in.
|
33
|
-
//@import 'carbon-components/css/carbon-components.min';
|
@@ -80,7 +80,7 @@ $right-section-alt-width: 100% - $left-section-alt-width;
|
|
80
80
|
$duration: 1000ms;
|
81
81
|
|
82
82
|
$animation: background-appear;
|
83
|
-
@if
|
83
|
+
@if $with-shadow {
|
84
84
|
$animation: background-and-shadow-appear;
|
85
85
|
}
|
86
86
|
|
@@ -144,7 +144,7 @@ $right-section-alt-width: 100% - $left-section-alt-width;
|
|
144
144
|
|
145
145
|
.#{$block-class}__breadcrumb-row:not(.#{$block-class}__breadcrumb-row--has-action-bar) {
|
146
146
|
// lifts up page title when there is no action bar
|
147
|
-
|
147
|
+
min-height: $spacing-07;
|
148
148
|
}
|
149
149
|
|
150
150
|
.#{$block-class}__breadcrumb-row--container {
|
@@ -189,7 +189,7 @@ $right-section-alt-width: 100% - $left-section-alt-width;
|
|
189
189
|
transition: all $duration--moderate-01 ease-out;
|
190
190
|
}
|
191
191
|
|
192
|
-
.#{$block-class}__breadcrumb-row--next-to-tabs::after,
|
192
|
+
.#{$block-class}__breadcrumb-row--next-to-tabs:not(.#{$block-class}__has-page-actions-without-action-bar)::after,
|
193
193
|
.#{$block-class}__breadcrumb-row--has-action-bar::after {
|
194
194
|
/* creates a full width box shadow without causing scroll */
|
195
195
|
box-shadow: 25vw 1px 0 0 $ui-03, -25vw 1px 0 0 $ui-03;
|
@@ -408,7 +408,6 @@ $right-section-alt-width: 100% - $left-section-alt-width;
|
|
408
408
|
}
|
409
409
|
|
410
410
|
.#{$block-class}__title-column {
|
411
|
-
overflow: hidden; /* required for ellipsis in title */
|
412
411
|
min-height: 40px;
|
413
412
|
flex: 0 0 100%;
|
414
413
|
|
@@ -421,11 +420,25 @@ $right-section-alt-width: 100% - $left-section-alt-width;
|
|
421
420
|
.#{$block-class}__title {
|
422
421
|
@include carbon--type-style('productive-heading-04');
|
423
422
|
|
424
|
-
overflow: hidden;
|
423
|
+
overflow-x: hidden;
|
425
424
|
text-overflow: ellipsis;
|
426
425
|
white-space: nowrap;
|
427
426
|
}
|
428
427
|
|
428
|
+
.#{$block-class}__title .#{$pkg-prefix}--inline-edit__value {
|
429
|
+
// The heading text sits 2px pixels lower in the inline edit which is aligned center
|
430
|
+
// stylelint-disable-next-line carbon/layout-token-use
|
431
|
+
transform: translateY(-2px);
|
432
|
+
}
|
433
|
+
|
434
|
+
.#{$block-class}__title--editable {
|
435
|
+
display: flex;
|
436
|
+
overflow: visible;
|
437
|
+
// move to match non-editable version position
|
438
|
+
margin-top: calc(-1 * #{$spacing-01});
|
439
|
+
margin-left: calc(-1 * #{$spacing-05});
|
440
|
+
}
|
441
|
+
|
429
442
|
.#{$block-class}__title-skeleton {
|
430
443
|
height: $spacing-07;
|
431
444
|
}
|
@@ -25,7 +25,7 @@ $block-class: #{$pkg-prefix}--side-panel;
|
|
25
25
|
$action-set-block-class: #{$pkg-prefix}--action-set;
|
26
26
|
|
27
27
|
@mixin sidePanelEntranceRight($size: map-get($side-panel-sizes, md)) {
|
28
|
-
@keyframes
|
28
|
+
@keyframes side-panel-entrance-right {
|
29
29
|
0% {
|
30
30
|
opacity: 0;
|
31
31
|
// stylelint-disable-next-line carbon/layout-token-use
|
@@ -39,7 +39,7 @@ $action-set-block-class: #{$pkg-prefix}--action-set;
|
|
39
39
|
}
|
40
40
|
|
41
41
|
@mixin sidePanelEntranceLeft($size: map-get($side-panel-sizes, md)) {
|
42
|
-
@keyframes
|
42
|
+
@keyframes side-panel-entrance-left {
|
43
43
|
0% {
|
44
44
|
opacity: 0;
|
45
45
|
// stylelint-disable-next-line carbon/layout-token-use
|
@@ -90,7 +90,7 @@ $action-set-block-class: #{$pkg-prefix}--action-set;
|
|
90
90
|
}
|
91
91
|
|
92
92
|
@mixin side-panel {
|
93
|
-
@keyframes
|
93
|
+
@keyframes side-panel-exit-left {
|
94
94
|
0% {
|
95
95
|
opacity: 1;
|
96
96
|
transform: translateX(0);
|
@@ -102,7 +102,7 @@ $action-set-block-class: #{$pkg-prefix}--action-set;
|
|
102
102
|
}
|
103
103
|
}
|
104
104
|
|
105
|
-
@keyframes
|
105
|
+
@keyframes side-panel-exit-right {
|
106
106
|
0% {
|
107
107
|
opacity: 1;
|
108
108
|
transform: translateX(0);
|
@@ -186,6 +186,15 @@ $action-set-block-class: #{$pkg-prefix}--action-set;
|
|
186
186
|
&::before {
|
187
187
|
@include setDividerStyles();
|
188
188
|
}
|
189
|
+
&.#{$block-class}__title-container--reduced-motion {
|
190
|
+
z-index: 5;
|
191
|
+
border-bottom: 1px solid $decorative-01;
|
192
|
+
margin-bottom: $spacing-05;
|
193
|
+
}
|
194
|
+
&.#{$block-class}__title-container--reduced-motion.#{$block-class}__title-container--no-title-animation {
|
195
|
+
border-bottom: 0;
|
196
|
+
margin-bottom: 0;
|
197
|
+
}
|
189
198
|
&.#{$block-class}__on-detail-step .#{$block-class}__collapsed-title-text {
|
190
199
|
top: $spacing-09;
|
191
200
|
}
|
@@ -444,7 +453,7 @@ $action-set-block-class: #{$pkg-prefix}--action-set;
|
|
444
453
|
background-color: $field-02;
|
445
454
|
}
|
446
455
|
|
447
|
-
@keyframes
|
456
|
+
@keyframes side-panel-overlay-entrance {
|
448
457
|
0% {
|
449
458
|
opacity: 0;
|
450
459
|
}
|
@@ -453,7 +462,7 @@ $action-set-block-class: #{$pkg-prefix}--action-set;
|
|
453
462
|
}
|
454
463
|
}
|
455
464
|
|
456
|
-
@keyframes
|
465
|
+
@keyframes side-panel-overlay-exit {
|
457
466
|
0% {
|
458
467
|
opacity: 1;
|
459
468
|
}
|
@@ -0,0 +1 @@
|
|
1
|
+
@import './single-add-select';
|
@@ -0,0 +1 @@
|
|
1
|
+
@import '../AddSelect/add-select';
|
@@ -72,7 +72,7 @@ $themes: ('light', 'dark');
|
|
72
72
|
|
73
73
|
$block-class: #{$pkg-prefix}--status-icon;
|
74
74
|
|
75
|
-
@function clr($name, $theme: light) {
|
75
|
+
@function --clr($name, $theme: light) {
|
76
76
|
// stylelint-disable-next-line carbon/theme-token-use
|
77
77
|
$color: map-get(map-get($colors, $name), $theme);
|
78
78
|
@return $color;
|
@@ -111,6 +111,8 @@ $block-class: #{$pkg-prefix}--status-icon;
|
|
111
111
|
@each $theme in $themes {
|
112
112
|
@each $icon in $icons {
|
113
113
|
@each $theme-key in $themes {
|
114
|
+
.#{$prefix}--btn.#{$prefix}--btn--icon-only.#{$prefix}--tooltip__trigger
|
115
|
+
.#{$block-class}--#{$theme}.#{$block-class}--#{$theme-key}-#{$icon},
|
114
116
|
.#{$block-class}--#{$theme}.#{$block-class}--#{$theme-key}-#{$icon} {
|
115
117
|
@if $icon == in-progress {
|
116
118
|
@media (prefers-reduced-motion: reduce) {
|
@@ -119,14 +121,14 @@ $block-class: #{$pkg-prefix}--status-icon;
|
|
119
121
|
// stylelint-disable-next-line carbon/motion-token-use
|
120
122
|
animation: rotating 8000ms infinite linear;
|
121
123
|
// stylelint-disable-next-line carbon/theme-token-use
|
122
|
-
fill: clr($icon, $theme);
|
124
|
+
fill: --clr($icon, $theme);
|
123
125
|
} @else if $icon == running {
|
124
126
|
// stylelint-disable-next-line carbon/theme-token-use
|
125
|
-
fill: clr($icon, $theme);
|
127
|
+
fill: --clr($icon, $theme);
|
126
128
|
transform: scaleY(-1);
|
127
129
|
} @else {
|
128
130
|
// stylelint-disable-next-line carbon/theme-token-use
|
129
|
-
fill: clr($icon, $theme);
|
131
|
+
fill: --clr($icon, $theme);
|
130
132
|
@media (prefers-reduced-motion) {
|
131
133
|
.#{$block-class}--#{$theme}.#{$block-class}--#{$theme-key}-in-progress {
|
132
134
|
animation: none;
|
@@ -44,7 +44,7 @@ $themes: (
|
|
44
44
|
|
45
45
|
$theme-keys: map-keys($themes);
|
46
46
|
|
47
|
-
@function get-background-color($color, $key, $contrast-key) {
|
47
|
+
@function --get-background-color($color, $key, $contrast-key) {
|
48
48
|
@return map-get(
|
49
49
|
$carbon-colors,
|
50
50
|
#{$color}#{map-get(map-get($themes, $key), #{$contrast-key}-contrast)}
|
@@ -60,7 +60,7 @@ $theme-keys: map-keys($themes);
|
|
60
60
|
@each $contrast-key in $theme-keys {
|
61
61
|
.#{$block-class}--#{$key}.#{$block-class}--#{$contrast-key}-#{$color} {
|
62
62
|
// stylelint-disable-next-line carbon/theme-token-use
|
63
|
-
background-color: get-background-color($color, $key, $contrast-key);
|
63
|
+
background-color: --get-background-color($color, $key, $contrast-key);
|
64
64
|
}
|
65
65
|
}
|
66
66
|
}
|
@@ -4,7 +4,7 @@
|
|
4
4
|
$web-terminal-width: 36.5rem;
|
5
5
|
$block-class: #{$pkg-prefix}--web-terminal;
|
6
6
|
|
7
|
-
@keyframes
|
7
|
+
@keyframes web-terminal-entrance {
|
8
8
|
0% {
|
9
9
|
opacity: 0;
|
10
10
|
// stylelint-disable-next-line carbon/layout-token-use
|
@@ -16,7 +16,7 @@ $block-class: #{$pkg-prefix}--web-terminal;
|
|
16
16
|
}
|
17
17
|
}
|
18
18
|
|
19
|
-
@keyframes
|
19
|
+
@keyframes web-terminal-exit {
|
20
20
|
0% {
|
21
21
|
opacity: 1;
|
22
22
|
transform: translateX(0);
|
@@ -9,7 +9,6 @@
|
|
9
9
|
|
10
10
|
@import './_Canary/canary';
|
11
11
|
|
12
|
-
@import './AddSelect/index';
|
13
12
|
@import './APIKeyModal/index';
|
14
13
|
@import './AboutModal/index';
|
15
14
|
@import './ActionSet/index';
|
@@ -28,12 +27,14 @@
|
|
28
27
|
@import './ImportModal/index';
|
29
28
|
@import './LoadingBar/index';
|
30
29
|
@import './ModifiedTabs/index';
|
30
|
+
@import './MultiAddSelect/index';
|
31
31
|
@import './NotificationsPanel/index';
|
32
32
|
@import './PageHeader/index';
|
33
33
|
@import './ProductiveCard/index';
|
34
34
|
@import './RemoveModal/index';
|
35
35
|
@import './Saving/index';
|
36
36
|
@import './SidePanel/index';
|
37
|
+
@import './SingleAddSelect/index';
|
37
38
|
@import './StatusIcon/index';
|
38
39
|
@import './TagSet/index';
|
39
40
|
@import './Tearsheet/index';
|
@@ -43,3 +44,4 @@
|
|
43
44
|
@import './EditSidePanel/index';
|
44
45
|
@import './OptionsTile/index';
|
45
46
|
@import './CancelableTextEdit/index';
|
47
|
+
@import './InlineEdit/index';
|