@gitlab/ui 123.10.1 → 123.11.1
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/bin/migrate_custom_utils_to_tw.bundled.mjs +97145 -89869
- package/dist/components/base/form/form_fields/form_fields.js +14 -4
- package/dist/index.css +2 -2
- package/dist/index.css.map +1 -1
- package/dist/tokens/build/js/tokens.dark.js +2 -1
- package/dist/tokens/build/js/tokens.js +2 -1
- package/dist/tokens/css/tokens.css +1 -0
- package/dist/tokens/css/tokens.dark.css +1 -0
- package/dist/tokens/figma/contextual.tokens.json +12 -0
- package/dist/tokens/js/tokens.dark.js +1 -0
- package/dist/tokens/js/tokens.js +1 -0
- package/dist/tokens/json/tokens.dark.json +33 -0
- package/dist/tokens/json/tokens.json +33 -0
- package/dist/tokens/scss/_tokens.dark.scss +1 -0
- package/dist/tokens/scss/_tokens.scss +1 -0
- package/dist/tokens/scss/_tokens_custom_properties.scss +1 -0
- package/dist/tokens/tailwind/tokens.cjs +531 -110
- package/package.json +6 -6
- package/src/components/base/filtered_search/filtered_search_token.scss +2 -2
- package/src/components/base/form/form_fields/form_fields.vue +16 -4
- package/src/components/base/token/token.scss +1 -1
- package/src/tokens/build/css/tokens.css +1 -0
- package/src/tokens/build/css/tokens.dark.css +1 -0
- package/src/tokens/build/figma/contextual.tokens.json +12 -0
- package/src/tokens/build/js/tokens.dark.js +1 -0
- package/src/tokens/build/js/tokens.js +1 -0
- package/src/tokens/build/json/tokens.dark.json +33 -0
- package/src/tokens/build/json/tokens.json +33 -0
- package/src/tokens/build/scss/_tokens.dark.scss +1 -0
- package/src/tokens/build/scss/_tokens.scss +1 -0
- package/src/tokens/build/scss/_tokens_custom_properties.scss +1 -0
- package/src/tokens/contextual/token.tokens.json +12 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gitlab/ui",
|
|
3
|
-
"version": "123.
|
|
3
|
+
"version": "123.11.1",
|
|
4
4
|
"description": "GitLab UI Components",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -101,10 +101,10 @@
|
|
|
101
101
|
"@babel/preset-react": "^7.27.1",
|
|
102
102
|
"@cypress/grep": "^4.1.1",
|
|
103
103
|
"@gitlab/fonts": "^1.3.1",
|
|
104
|
-
"@gitlab/svgs": "
|
|
104
|
+
"@gitlab/svgs": "*",
|
|
105
105
|
"@jest/test-sequencer": "30.2.0",
|
|
106
106
|
"@rollup/plugin-commonjs": "^28.0.6",
|
|
107
|
-
"@rollup/plugin-node-resolve": "^16.0.
|
|
107
|
+
"@rollup/plugin-node-resolve": "^16.0.3",
|
|
108
108
|
"@rollup/plugin-replace": "^6.0.2",
|
|
109
109
|
"@storybook/addon-a11y": "^7.6.20",
|
|
110
110
|
"@storybook/addon-docs": "^7.6.20",
|
|
@@ -136,8 +136,8 @@
|
|
|
136
136
|
"cypress": "14.5.4",
|
|
137
137
|
"cypress-real-events": "^1.15.0",
|
|
138
138
|
"dompurify": "^3.1.2",
|
|
139
|
-
"emoji-regex": "^10.
|
|
140
|
-
"esbuild": "^0.25.
|
|
139
|
+
"emoji-regex": "^10.6.0",
|
|
140
|
+
"esbuild": "^0.25.11",
|
|
141
141
|
"gitlab-api-async-iterator": "^1.3.1",
|
|
142
142
|
"glob": "11.0.3",
|
|
143
143
|
"globby": "^14.1.0",
|
|
@@ -169,7 +169,7 @@
|
|
|
169
169
|
"start-server-and-test": "^2.1.2",
|
|
170
170
|
"storybook": "^7.6.20",
|
|
171
171
|
"storybook-dark-mode": "4.0.2",
|
|
172
|
-
"style-dictionary": "^5.1.
|
|
172
|
+
"style-dictionary": "^5.1.1",
|
|
173
173
|
"style-loader": "^4",
|
|
174
174
|
"tailwindcss": "3.4.18",
|
|
175
175
|
"vue": "2.7.16",
|
|
@@ -47,9 +47,9 @@
|
|
|
47
47
|
|
|
48
48
|
&.gl-filtered-search-token-data {
|
|
49
49
|
@apply gl-h-6;
|
|
50
|
-
@apply gl-rounded-tr-small;
|
|
51
|
-
@apply gl-rounded-br-small;
|
|
52
50
|
background-color: var(--gl-filtered-search-token-data-background-color-default);
|
|
51
|
+
border-top-right-radius: var(--gl-token-border-radius);
|
|
52
|
+
border-bottom-right-radius: var(--gl-token-border-radius);
|
|
53
53
|
|
|
54
54
|
.gl-filtered-search-token-data-content {
|
|
55
55
|
@apply gl-inline-flex;
|
|
@@ -67,6 +67,7 @@ export default {
|
|
|
67
67
|
return {
|
|
68
68
|
fieldDirtyStatuses: {},
|
|
69
69
|
fieldValidations: {},
|
|
70
|
+
fieldIds: {},
|
|
70
71
|
};
|
|
71
72
|
},
|
|
72
73
|
computed: {
|
|
@@ -98,7 +99,7 @@ export default {
|
|
|
98
99
|
},
|
|
99
100
|
fieldsToRender() {
|
|
100
101
|
return mapValues(this.fields, (field, fieldName) => {
|
|
101
|
-
const id =
|
|
102
|
+
const id = this.memoizeAndReturnFieldId(field, fieldName);
|
|
102
103
|
|
|
103
104
|
const inputSlotName = `input(${fieldName})`;
|
|
104
105
|
const groupPassthroughSlotName = `group(${fieldName})-`;
|
|
@@ -173,6 +174,18 @@ export default {
|
|
|
173
174
|
|
|
174
175
|
return val;
|
|
175
176
|
},
|
|
177
|
+
memoizeAndReturnFieldId(field, fieldName) {
|
|
178
|
+
const memoizedId = this.fieldIds[fieldName];
|
|
179
|
+
|
|
180
|
+
if (memoizedId) {
|
|
181
|
+
return memoizedId;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
const id = field.id || uniqueId('gl-form-field-');
|
|
185
|
+
this.fieldIds[fieldName] = id;
|
|
186
|
+
|
|
187
|
+
return id;
|
|
188
|
+
},
|
|
176
189
|
onFieldValidationUpdate(fieldName, invalidFeedback) {
|
|
177
190
|
this.fieldValidations = setObjectProperty(this.fieldValidations, fieldName, invalidFeedback);
|
|
178
191
|
|
|
@@ -221,8 +234,7 @@ export default {
|
|
|
221
234
|
|
|
222
235
|
<template>
|
|
223
236
|
<div>
|
|
224
|
-
<
|
|
225
|
-
<!-- eslint-disable-next-line vue/valid-v-for -->
|
|
237
|
+
<div v-for="(field, fieldName) in fieldsToRender" :key="field.id">
|
|
226
238
|
<gl-form-group
|
|
227
239
|
v-bind="field.groupAttrs"
|
|
228
240
|
:label="field.label"
|
|
@@ -258,6 +270,6 @@ export default {
|
|
|
258
270
|
</gl-form-group>
|
|
259
271
|
<!-- @slot Can be used to add content the form group of a field. The name of the slot is `after(<fieldName>)`.-->
|
|
260
272
|
<slot :name="field.afterSlotName"></slot>
|
|
261
|
-
</
|
|
273
|
+
</div>
|
|
262
274
|
</div>
|
|
263
275
|
</template>
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
.gl-token {
|
|
2
2
|
color: var(--gl-token-foreground-color);
|
|
3
3
|
background-color: var(--gl-token-background-color);
|
|
4
|
-
@apply gl-rounded-sm;
|
|
5
4
|
@apply gl-pl-3;
|
|
6
5
|
@apply gl-inline-flex;
|
|
7
6
|
@apply gl-flex-col;
|
|
8
7
|
@apply gl-justify-center;
|
|
8
|
+
border-radius: var(--gl-token-border-radius);
|
|
9
9
|
|
|
10
10
|
&.gl-token-view-only {
|
|
11
11
|
@apply gl-py-2;
|
|
@@ -1123,6 +1123,7 @@
|
|
|
1123
1123
|
--gl-dropdown-option-text-color-active: var(--gl-action-neutral-foreground-color-active); /** Used for the text of a dropdown option in the active state. */
|
|
1124
1124
|
--gl-toggle-switch-icon-color-unchecked-focus: var(--gl-action-strong-neutral-background-color-focus); /** Used for the icon color of an unchecked toggle switch in the focus state. */
|
|
1125
1125
|
--gl-toggle-switch-icon-color-checked-focus: var(--gl-action-strong-confirm-background-color-focus); /** Used for the icon color of a checked toggle switch in the focus state. */
|
|
1126
|
+
--gl-token-border-radius: var(--gl-border-radius-default); /** Used for token border radius. */
|
|
1126
1127
|
--gl-action-selected-foreground-color-focus: var(--gl-action-selected-foreground-color-hover); /** Used for the foreground of a selected action in the focus state. */
|
|
1127
1128
|
--gl-action-selected-border-color-focus: var(--gl-action-selected-background-color-focus); /** Used for the border of a selected action in the focus state. */
|
|
1128
1129
|
--gl-action-strong-confirm-foreground-color-focus: var(--gl-action-strong-confirm-foreground-color-hover); /** Used for the foreground of a strong confirm action in the focus state. */
|
|
@@ -1125,6 +1125,7 @@
|
|
|
1125
1125
|
--gl-dropdown-option-text-color-active: var(--gl-action-neutral-foreground-color-active); /** Used for the text of a dropdown option in the active state. */
|
|
1126
1126
|
--gl-toggle-switch-icon-color-unchecked-focus: var(--gl-action-strong-neutral-background-color-focus); /** Used for the icon color of an unchecked toggle switch in the focus state. */
|
|
1127
1127
|
--gl-toggle-switch-icon-color-checked-focus: var(--gl-action-strong-confirm-background-color-focus); /** Used for the icon color of a checked toggle switch in the focus state. */
|
|
1128
|
+
--gl-token-border-radius: var(--gl-border-radius-default); /** Used for token border radius. */
|
|
1128
1129
|
--gl-action-selected-foreground-color-focus: var(--gl-action-selected-foreground-color-hover); /** Used for the foreground of a selected action in the focus state. */
|
|
1129
1130
|
--gl-action-selected-border-color-focus: var(--gl-action-selected-background-color-focus); /** Used for the border of a selected action in the focus state. */
|
|
1130
1131
|
--gl-action-strong-confirm-foreground-color-focus: var(--gl-action-strong-confirm-foreground-color-hover); /** Used for the foreground of a strong confirm action in the focus state. */
|
|
@@ -5881,6 +5881,18 @@
|
|
|
5881
5881
|
}
|
|
5882
5882
|
},
|
|
5883
5883
|
"token": {
|
|
5884
|
+
"border": {
|
|
5885
|
+
"radius": {
|
|
5886
|
+
"$value": "{border.radius.default}",
|
|
5887
|
+
"$type": "dimension",
|
|
5888
|
+
"$description": "Used for token border radius.",
|
|
5889
|
+
"$extensions": {
|
|
5890
|
+
"com.figma.scope": [
|
|
5891
|
+
"CORNER_RADIUS"
|
|
5892
|
+
]
|
|
5893
|
+
}
|
|
5894
|
+
}
|
|
5895
|
+
},
|
|
5884
5896
|
"foreground": {
|
|
5885
5897
|
"color": {
|
|
5886
5898
|
"$value": "{text.color.default}",
|
|
@@ -830,6 +830,7 @@ export const GL_TOGGLE_SWITCH_ICON_COLOR_CHECKED_FOCUS = '#9dc7f1';
|
|
|
830
830
|
export const GL_TOGGLE_SWITCH_ICON_COLOR_CHECKED_ACTIVE = '#428fdc';
|
|
831
831
|
export const GL_TOGGLE_SWITCH_ICON_COLOR_DISABLED = '#28272d';
|
|
832
832
|
export const GL_TOKEN_SELECTOR_TOKEN_CONTAINER_TOKEN_BACKGROUND_COLOR_FOCUS = '#626168';
|
|
833
|
+
export const GL_TOKEN_BORDER_RADIUS = '0.25rem';
|
|
833
834
|
export const GL_TOKEN_FOREGROUND_COLOR = '#ececef';
|
|
834
835
|
export const GL_TOKEN_BACKGROUND_COLOR = '#3a383f';
|
|
835
836
|
export const DATA_VIZ_GREEN_50 = '#133a03';
|
|
@@ -830,6 +830,7 @@ export const GL_TOGGLE_SWITCH_ICON_COLOR_CHECKED_FOCUS = '#2f68b4';
|
|
|
830
830
|
export const GL_TOGGLE_SWITCH_ICON_COLOR_CHECKED_ACTIVE = '#2f5ca0';
|
|
831
831
|
export const GL_TOGGLE_SWITCH_ICON_COLOR_DISABLED = '#ececef';
|
|
832
832
|
export const GL_TOKEN_SELECTOR_TOKEN_CONTAINER_TOKEN_BACKGROUND_COLOR_FOCUS = '#a4a3a8';
|
|
833
|
+
export const GL_TOKEN_BORDER_RADIUS = '0.25rem';
|
|
833
834
|
export const GL_TOKEN_FOREGROUND_COLOR = '#3a383f';
|
|
834
835
|
export const GL_TOKEN_BACKGROUND_COLOR = '#dcdcde';
|
|
835
836
|
export const DATA_VIZ_GREEN_50 = '#ddfab7';
|
|
@@ -23559,6 +23559,39 @@
|
|
|
23559
23559
|
}
|
|
23560
23560
|
},
|
|
23561
23561
|
"token": {
|
|
23562
|
+
"border": {
|
|
23563
|
+
"radius": {
|
|
23564
|
+
"key": "{token.border.radius}",
|
|
23565
|
+
"$value": "0.25rem",
|
|
23566
|
+
"$type": "dimension",
|
|
23567
|
+
"$description": "Used for token border radius.",
|
|
23568
|
+
"$extensions": {
|
|
23569
|
+
"com.figma.scope": [
|
|
23570
|
+
"CORNER_RADIUS"
|
|
23571
|
+
]
|
|
23572
|
+
},
|
|
23573
|
+
"filePath": "src/tokens/contextual/token.tokens.json",
|
|
23574
|
+
"isSource": true,
|
|
23575
|
+
"original": {
|
|
23576
|
+
"$value": "{border.radius.default}",
|
|
23577
|
+
"$type": "dimension",
|
|
23578
|
+
"$description": "Used for token border radius.",
|
|
23579
|
+
"$extensions": {
|
|
23580
|
+
"com.figma.scope": [
|
|
23581
|
+
"CORNER_RADIUS"
|
|
23582
|
+
]
|
|
23583
|
+
},
|
|
23584
|
+
"key": "{token.border.radius}"
|
|
23585
|
+
},
|
|
23586
|
+
"name": "TOKEN_BORDER_RADIUS",
|
|
23587
|
+
"attributes": {},
|
|
23588
|
+
"path": [
|
|
23589
|
+
"token",
|
|
23590
|
+
"border",
|
|
23591
|
+
"radius"
|
|
23592
|
+
]
|
|
23593
|
+
}
|
|
23594
|
+
},
|
|
23562
23595
|
"foreground": {
|
|
23563
23596
|
"color": {
|
|
23564
23597
|
"key": "{token.foreground.color}",
|
|
@@ -23559,6 +23559,39 @@
|
|
|
23559
23559
|
}
|
|
23560
23560
|
},
|
|
23561
23561
|
"token": {
|
|
23562
|
+
"border": {
|
|
23563
|
+
"radius": {
|
|
23564
|
+
"key": "{token.border.radius}",
|
|
23565
|
+
"$value": "0.25rem",
|
|
23566
|
+
"$type": "dimension",
|
|
23567
|
+
"$description": "Used for token border radius.",
|
|
23568
|
+
"$extensions": {
|
|
23569
|
+
"com.figma.scope": [
|
|
23570
|
+
"CORNER_RADIUS"
|
|
23571
|
+
]
|
|
23572
|
+
},
|
|
23573
|
+
"filePath": "src/tokens/contextual/token.tokens.json",
|
|
23574
|
+
"isSource": true,
|
|
23575
|
+
"original": {
|
|
23576
|
+
"$value": "{border.radius.default}",
|
|
23577
|
+
"$type": "dimension",
|
|
23578
|
+
"$description": "Used for token border radius.",
|
|
23579
|
+
"$extensions": {
|
|
23580
|
+
"com.figma.scope": [
|
|
23581
|
+
"CORNER_RADIUS"
|
|
23582
|
+
]
|
|
23583
|
+
},
|
|
23584
|
+
"key": "{token.border.radius}"
|
|
23585
|
+
},
|
|
23586
|
+
"name": "TOKEN_BORDER_RADIUS",
|
|
23587
|
+
"attributes": {},
|
|
23588
|
+
"path": [
|
|
23589
|
+
"token",
|
|
23590
|
+
"border",
|
|
23591
|
+
"radius"
|
|
23592
|
+
]
|
|
23593
|
+
}
|
|
23594
|
+
},
|
|
23562
23595
|
"foreground": {
|
|
23563
23596
|
"color": {
|
|
23564
23597
|
"key": "{token.foreground.color}",
|
|
@@ -1123,6 +1123,7 @@ $gl-dropdown-option-text-color-focus: $gl-action-neutral-foreground-color-focus;
|
|
|
1123
1123
|
$gl-dropdown-option-text-color-active: $gl-action-neutral-foreground-color-active; // Used for the text of a dropdown option in the active state.
|
|
1124
1124
|
$gl-toggle-switch-icon-color-unchecked-focus: $gl-action-strong-neutral-background-color-focus; // Used for the icon color of an unchecked toggle switch in the focus state.
|
|
1125
1125
|
$gl-toggle-switch-icon-color-checked-focus: $gl-action-strong-confirm-background-color-focus; // Used for the icon color of a checked toggle switch in the focus state.
|
|
1126
|
+
$gl-token-border-radius: $gl-border-radius-default; // Used for token border radius.
|
|
1126
1127
|
$gl-action-selected-foreground-color-focus: $gl-action-selected-foreground-color-hover; // Used for the foreground of a selected action in the focus state.
|
|
1127
1128
|
$gl-action-selected-border-color-focus: $gl-action-selected-background-color-focus; // Used for the border of a selected action in the focus state.
|
|
1128
1129
|
$gl-action-strong-confirm-foreground-color-focus: $gl-action-strong-confirm-foreground-color-hover; // Used for the foreground of a strong confirm action in the focus state.
|
|
@@ -1121,6 +1121,7 @@ $gl-dropdown-option-text-color-focus: $gl-action-neutral-foreground-color-focus;
|
|
|
1121
1121
|
$gl-dropdown-option-text-color-active: $gl-action-neutral-foreground-color-active; // Used for the text of a dropdown option in the active state.
|
|
1122
1122
|
$gl-toggle-switch-icon-color-unchecked-focus: $gl-action-strong-neutral-background-color-focus; // Used for the icon color of an unchecked toggle switch in the focus state.
|
|
1123
1123
|
$gl-toggle-switch-icon-color-checked-focus: $gl-action-strong-confirm-background-color-focus; // Used for the icon color of a checked toggle switch in the focus state.
|
|
1124
|
+
$gl-token-border-radius: $gl-border-radius-default; // Used for token border radius.
|
|
1124
1125
|
$gl-action-selected-foreground-color-focus: $gl-action-selected-foreground-color-hover; // Used for the foreground of a selected action in the focus state.
|
|
1125
1126
|
$gl-action-selected-border-color-focus: $gl-action-selected-background-color-focus; // Used for the border of a selected action in the focus state.
|
|
1126
1127
|
$gl-action-strong-confirm-foreground-color-focus: $gl-action-strong-confirm-foreground-color-hover; // Used for the foreground of a strong confirm action in the focus state.
|
|
@@ -744,6 +744,7 @@ $gl-toggle-switch-icon-color-checked-focus: var(--gl-toggle-switch-icon-color-ch
|
|
|
744
744
|
$gl-toggle-switch-icon-color-checked-active: var(--gl-toggle-switch-icon-color-checked-active);
|
|
745
745
|
$gl-toggle-switch-icon-color-disabled: var(--gl-toggle-switch-icon-color-disabled);
|
|
746
746
|
$gl-token-selector-token-container-token-background-color-focus: var(--gl-token-selector-token-container-token-background-color-focus);
|
|
747
|
+
$gl-token-border-radius: var(--gl-token-border-radius);
|
|
747
748
|
$gl-token-foreground-color: var(--gl-token-foreground-color);
|
|
748
749
|
$gl-token-background-color: var(--gl-token-background-color);
|
|
749
750
|
$data-viz-green-50: var(--data-viz-green-50);
|
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"token": {
|
|
3
|
+
"border": {
|
|
4
|
+
"radius": {
|
|
5
|
+
"$value": "{border.radius.default}",
|
|
6
|
+
"$type": "dimension",
|
|
7
|
+
"$description": "Used for token border radius.",
|
|
8
|
+
"$extensions": {
|
|
9
|
+
"com.figma.scope": [
|
|
10
|
+
"CORNER_RADIUS"
|
|
11
|
+
]
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
},
|
|
3
15
|
"foreground": {
|
|
4
16
|
"color": {
|
|
5
17
|
"$value": "{text.color.default}",
|