@gitlab/ui 111.0.0 → 111.1.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/CHANGELOG.md +14 -0
- package/dist/components/base/token_selector/token_container.js +1 -1
- package/dist/components/base/token_selector/token_selector.js +2 -1
- package/dist/components/charts/discrete_scatter/discrete_scatter.js +1 -2
- package/dist/components/charts/heatmap/heatmap.js +4 -4
- package/dist/components/charts/legend/legend.js +1 -2
- package/dist/components/charts/line/line.js +1 -2
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/tailwind.css +1 -1
- package/dist/tailwind.css.map +1 -1
- package/dist/tokens/build/js/tokens.dark.js +8 -1
- package/dist/tokens/build/js/tokens.js +8 -1
- package/dist/tokens/css/tokens.css +8 -1
- package/dist/tokens/css/tokens.dark.css +8 -1
- package/dist/tokens/js/tokens.dark.js +7 -0
- package/dist/tokens/js/tokens.js +7 -0
- package/dist/tokens/json/tokens.dark.json +176 -1
- package/dist/tokens/json/tokens.json +176 -1
- package/dist/tokens/scss/_tokens.dark.scss +8 -1
- package/dist/tokens/scss/_tokens.scss +8 -1
- package/dist/tokens/scss/_tokens_custom_properties.scss +7 -0
- package/dist/utils/charts/theme.js +31 -29
- package/dist/utils/is_slot_empty.js +1 -8
- package/package.json +1 -1
- package/src/components/base/token_selector/token_container.vue +3 -2
- package/src/components/base/token_selector/token_selector.scss +1 -0
- package/src/components/base/token_selector/token_selector.vue +3 -0
- package/src/components/charts/discrete_scatter/discrete_scatter.vue +1 -2
- package/src/components/charts/heatmap/heatmap.vue +4 -4
- package/src/components/charts/legend/legend.vue +1 -2
- package/src/components/charts/line/line.vue +1 -2
- package/src/tokens/build/css/tokens.css +8 -1
- package/src/tokens/build/css/tokens.dark.css +8 -1
- package/src/tokens/build/js/tokens.dark.js +7 -0
- package/src/tokens/build/js/tokens.js +7 -0
- package/src/tokens/build/json/tokens.dark.json +176 -1
- package/src/tokens/build/json/tokens.json +176 -1
- package/src/tokens/build/scss/_tokens.dark.scss +8 -1
- package/src/tokens/build/scss/_tokens.scss +8 -1
- package/src/tokens/build/scss/_tokens_custom_properties.scss +7 -0
- package/src/tokens/contextual/chart.tokens.json +68 -0
- package/src/tokens/contextual/dropdown.tokens.json +2 -0
- package/src/utils/charts/theme.js +150 -153
- package/src/utils/is_slot_empty.js +1 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
## [111.1.1](https://gitlab.com/gitlab-org/gitlab-ui/compare/v111.1.0...v111.1.1) (2025-03-13)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* **DesignTokens:** Add missing dropdown token keys ([1d8b1f5](https://gitlab.com/gitlab-org/gitlab-ui/commit/1d8b1f54fc38694207e45369d514910ed20be2b1))
|
|
7
|
+
|
|
8
|
+
# [111.1.0](https://gitlab.com/gitlab-org/gitlab-ui/compare/v111.0.0...v111.1.0) (2025-03-13)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* **DesignTokens:** define chart contextual design tokens ([57eafc4](https://gitlab.com/gitlab-org/gitlab-ui/commit/57eafc435b47fdec3a57ed8f2e0a6be4ac585ca3))
|
|
14
|
+
|
|
1
15
|
# [111.0.0](https://gitlab.com/gitlab-org/gitlab-ui/compare/v110.1.0...v111.0.0) (2025-03-12)
|
|
2
16
|
|
|
3
17
|
|
|
@@ -130,7 +130,7 @@ var script = {
|
|
|
130
130
|
const __vue_script__ = script;
|
|
131
131
|
|
|
132
132
|
/* template */
|
|
133
|
-
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"gl-flex gl-w-full gl-flex-nowrap gl-items-start"},[_c('div',{ref:"tokenContainer",staticClass:"-gl-mx-1 -gl-my-1 gl-flex gl-w-
|
|
133
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"gl-flex gl-w-full gl-flex-nowrap gl-items-start"},[_c('div',{ref:"tokenContainer",staticClass:"-gl-mx-1 -gl-my-1 gl-flex gl-w-auto gl-list-none gl-flex-wrap gl-items-center gl-p-0",attrs:{"role":"listbox","aria-multiselectable":"false","aria-orientation":"horizontal","aria-invalid":_vm.state === false && 'true',"aria-label":"token list"},on:{"keydown":[function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"left",37,$event.key,["Left","ArrowLeft"])){ return null; }if('button' in $event && $event.button !== 0){ return null; }return _vm.handleLeftArrow.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"right",39,$event.key,["Right","ArrowRight"])){ return null; }if('button' in $event && $event.button !== 2){ return null; }return _vm.handleRightArrow.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"home",undefined,$event.key,undefined)){ return null; }return _vm.handleHome.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"end",undefined,$event.key,undefined)){ return null; }return _vm.handleEnd.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"delete",[8,46],$event.key,["Backspace","Delete","Del"])){ return null; }return _vm.handleDelete.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"esc",27,$event.key,["Esc","Escape"])){ return null; }return _vm.handleEscape.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"tab",9,$event.key,"Tab")){ return null; }if($event.ctrlKey||$event.shiftKey||$event.altKey||$event.metaKey){ return null; }$event.preventDefault();return _vm.handleTab.apply(null, arguments)}]}},_vm._l((_vm.tokens),function(token,index){return _c('div',{key:token.id,ref:"tokens",refInFor:true,staticClass:"gl-token-selector-token-container gl-px-1 gl-py-2 gl-outline-none",attrs:{"data-token-id":token.id,"role":"option","tabindex":"-1"},on:{"focus":function($event){_vm.bindFocusEvent ? _vm.handleTokenFocus(index) : null;}}},[_c('gl-token',{staticClass:"gl-cursor-default",class:token.class,style:(token.style),attrs:{"view-only":_vm.viewOnly},on:{"close":function($event){return _vm.handleClose(token)}}},[_vm._t("token-content",function(){return [_c('span',[_vm._v("\n "+_vm._s(token.name)+"\n ")])]},{"token":token})],2)],1)}),0),_vm._v(" "),_vm._t("text-input"),_vm._v(" "),(_vm.showClearAllButton)?_c('div',{staticClass:"gl-ml-3 gl-p-1"},[_c('gl-button',{attrs:{"size":"small","aria-label":"Clear all","icon":"clear","category":"tertiary","data-testid":"clear-all-button"},on:{"click":function($event){$event.stopPropagation();return _vm.$emit('clear-all')}}})],1):_vm._e()],2)};
|
|
134
134
|
var __vue_staticRenderFns__ = [];
|
|
135
135
|
|
|
136
136
|
/* style */
|
|
@@ -319,6 +319,7 @@ var script = {
|
|
|
319
319
|
* @property {object} token
|
|
320
320
|
*/
|
|
321
321
|
this.$emit('token-add', dropdownItem);
|
|
322
|
+
this.focusTextInput();
|
|
322
323
|
},
|
|
323
324
|
removeToken(token) {
|
|
324
325
|
/**
|
|
@@ -379,7 +380,7 @@ var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=
|
|
|
379
380
|
_vm.containerClass,
|
|
380
381
|
_vm.stateClass ],on:{"click":_vm.handleContainerClick}},[(_vm.showEmptyPlaceholder)?_vm._t("empty-placeholder"):_vm._e(),_vm._v(" "),_c('gl-token-container',{attrs:{"tokens":_vm.selectedTokens,"state":_vm.state,"register-focus-on-token":_vm.registerFocusOnToken,"view-only":_vm.viewOnly,"show-clear-all-button":_vm.showClearAllButton},on:{"token-remove":_vm.removeToken,"cancel-focus":_vm.cancelTokenFocus,"clear-all":_vm.clearAll},scopedSlots:_vm._u([{key:"token-content",fn:function(ref){
|
|
381
382
|
var token = ref.token;
|
|
382
|
-
return [_vm._t("token-content",null,{"token":token})]}},{key:"text-input",fn:function(){return [_c('input',_vm._b({ref:"textInput",staticClass:"gl-token-selector-input gl-h-auto gl-w-4/10 gl-grow gl-border-none gl-bg-transparent gl-px-1 gl-font-regular gl-text-base gl-leading-normal gl-text-default gl-outline-none",attrs:{"type":"text","autocomplete":_vm.autocomplete,"aria-labelledby":_vm.ariaLabelledby,"placeholder":_vm.placeholder,"disabled":_vm.viewOnly},domProps:{"value":_vm.inputText},on:{"input":function($event){_vm.inputText = $event.target.value;},"focus":_vm.handleFocus,"blur":_vm.handleBlur,"keydown":[function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"enter",13,$event.key,"Enter")){ return null; }return _vm.handleEnter.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"esc",27,$event.key,["Esc","Escape"])){ return null; }return _vm.handleEscape.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"delete",[8,46],$event.key,["Backspace","Delete","Del"])){ return null; }return _vm.handleBackspace.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"up",38,$event.key,["Up","ArrowUp"])){ return null; }$event.preventDefault();return _vm.dropdownEventHandlers.handleUpArrow.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"down",40,$event.key,["Down","ArrowDown"])){ return null; }$event.preventDefault();return _vm.dropdownEventHandlers.handleDownArrow.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"home",undefined,$event.key,undefined)){ return null; }return _vm.dropdownEventHandlers.handleHomeKey.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"end",undefined,$event.key,undefined)){ return null; }return _vm.dropdownEventHandlers.handleEndKey.apply(null, arguments)},function($event){$event.stopPropagation();return _vm.$emit('keydown', $event)}],"click":_vm.handleInputClick}},'input',_vm.textInputAttrs,false))]},proxy:true}],null,true)})],2),_vm._v(" "),_c('gl-token-selector-dropdown',{attrs:{"menu-class":_vm.menuClass,"show":_vm.dropdownIsOpen,"loading":_vm.loading,"dropdown-items":_vm.filteredDropdownItems,"selected-tokens":_vm.selectedTokens,"input-text":_vm.inputText,"user-defined-token-can-be-added":_vm.userDefinedTokenCanBeAdded,"component-id":_vm.$options.componentId,"register-dropdown-event-handlers":_vm.registerDropdownEventHandlers,"register-reset-focused-dropdown-item":_vm.registerResetFocusedDropdownItem},on:{"dropdown-item-click":_vm.addToken,"show":_vm.openDropdown},scopedSlots:_vm._u([{key:"loading-content",fn:function(){return [_vm._t("loading-content")]},proxy:true},{key:"user-defined-token-content",fn:function(){return [_vm._t("user-defined-token-content",null,{"inputText":_vm.inputText})]},proxy:true},{key:"no-results-content",fn:function(){return [_vm._t("no-results-content")]},proxy:true},{key:"dropdown-item-content",fn:function(ref){
|
|
383
|
+
return [_vm._t("token-content",null,{"token":token})]}},{key:"text-input",fn:function(){return [_c('input',_vm._b({ref:"textInput",staticClass:"gl-token-selector-input gl-h-auto gl-w-4/10 gl-grow gl-border-none gl-bg-transparent gl-px-1 gl-font-regular gl-text-base gl-leading-normal gl-text-default gl-outline-none",attrs:{"type":"text","aria-label":"token selector","autocomplete":_vm.autocomplete,"aria-labelledby":_vm.ariaLabelledby,"placeholder":_vm.placeholder,"disabled":_vm.viewOnly},domProps:{"value":_vm.inputText},on:{"input":function($event){_vm.inputText = $event.target.value;},"focus":_vm.handleFocus,"blur":_vm.handleBlur,"keydown":[function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"enter",13,$event.key,"Enter")){ return null; }return _vm.handleEnter.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"esc",27,$event.key,["Esc","Escape"])){ return null; }return _vm.handleEscape.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"delete",[8,46],$event.key,["Backspace","Delete","Del"])){ return null; }return _vm.handleBackspace.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"up",38,$event.key,["Up","ArrowUp"])){ return null; }$event.preventDefault();return _vm.dropdownEventHandlers.handleUpArrow.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"down",40,$event.key,["Down","ArrowDown"])){ return null; }$event.preventDefault();return _vm.dropdownEventHandlers.handleDownArrow.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"home",undefined,$event.key,undefined)){ return null; }return _vm.dropdownEventHandlers.handleHomeKey.apply(null, arguments)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"end",undefined,$event.key,undefined)){ return null; }return _vm.dropdownEventHandlers.handleEndKey.apply(null, arguments)},function($event){$event.stopPropagation();return _vm.$emit('keydown', $event)}],"click":_vm.handleInputClick}},'input',_vm.textInputAttrs,false))]},proxy:true}],null,true)})],2),_vm._v(" "),_c('gl-token-selector-dropdown',{attrs:{"menu-class":_vm.menuClass,"show":_vm.dropdownIsOpen,"loading":_vm.loading,"dropdown-items":_vm.filteredDropdownItems,"selected-tokens":_vm.selectedTokens,"input-text":_vm.inputText,"user-defined-token-can-be-added":_vm.userDefinedTokenCanBeAdded,"component-id":_vm.$options.componentId,"register-dropdown-event-handlers":_vm.registerDropdownEventHandlers,"register-reset-focused-dropdown-item":_vm.registerResetFocusedDropdownItem},on:{"dropdown-item-click":_vm.addToken,"show":_vm.openDropdown},scopedSlots:_vm._u([{key:"loading-content",fn:function(){return [_vm._t("loading-content")]},proxy:true},{key:"user-defined-token-content",fn:function(){return [_vm._t("user-defined-token-content",null,{"inputText":_vm.inputText})]},proxy:true},{key:"no-results-content",fn:function(){return [_vm._t("no-results-content")]},proxy:true},{key:"dropdown-item-content",fn:function(ref){
|
|
383
384
|
var dropdownItem = ref.dropdownItem;
|
|
384
385
|
return [_vm._t("dropdown-item-content",null,{"dropdownItem":dropdownItem})]}},{key:"dropdown-footer",fn:function(){return [_vm._t("dropdown-footer")]},proxy:true}],null,true),model:{value:(_vm.focusedDropdownItem),callback:function ($$v) {_vm.focusedDropdownItem=$$v;},expression:"focusedDropdownItem"}})],1)};
|
|
385
386
|
var __vue_staticRenderFns__ = [];
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import merge from 'lodash/merge';
|
|
2
|
-
import { GRAY_200 } from '../../../tokens/build/js/tokens';
|
|
3
2
|
import { defaultChartOptions, dataZoomAdjustments, mergeSeriesToOptions } from '../../../utils/charts/config';
|
|
4
3
|
import { colorFromDefaultPalette } from '../../../utils/charts/theme';
|
|
5
4
|
import { HEIGHT_AUTO_CLASSES } from '../../../utils/charts/constants';
|
|
@@ -98,7 +97,7 @@ var script = {
|
|
|
98
97
|
alignWithLabel: true,
|
|
99
98
|
show: true,
|
|
100
99
|
lineStyle: {
|
|
101
|
-
color:
|
|
100
|
+
color: 'var(--gl-chart-axis-line-color)'
|
|
102
101
|
}
|
|
103
102
|
},
|
|
104
103
|
axisLabel: {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import merge from 'lodash/merge';
|
|
2
|
-
import {
|
|
2
|
+
import { GL_COLOR_NEUTRAL_100, GL_COLOR_NEUTRAL_0 } from '../../../tokens/build/js/tokens';
|
|
3
3
|
import { getTooltipTitle, getTooltipContent } from '../../../utils/charts/config';
|
|
4
4
|
import { HEIGHT_AUTO_CLASSES } from '../../../utils/charts/constants';
|
|
5
5
|
import { heatmapHues } from '../../../utils/charts/theme';
|
|
@@ -139,7 +139,7 @@ var script = {
|
|
|
139
139
|
right: '32px',
|
|
140
140
|
show: true,
|
|
141
141
|
borderWidth: 0,
|
|
142
|
-
backgroundColor:
|
|
142
|
+
backgroundColor: GL_COLOR_NEUTRAL_100
|
|
143
143
|
},
|
|
144
144
|
visualMap: {
|
|
145
145
|
min,
|
|
@@ -163,7 +163,7 @@ var script = {
|
|
|
163
163
|
show: true,
|
|
164
164
|
interval: 0,
|
|
165
165
|
lineStyle: {
|
|
166
|
-
color:
|
|
166
|
+
color: GL_COLOR_NEUTRAL_0,
|
|
167
167
|
width: 2
|
|
168
168
|
}
|
|
169
169
|
},
|
|
@@ -190,7 +190,7 @@ var script = {
|
|
|
190
190
|
show: true,
|
|
191
191
|
interval: 0,
|
|
192
192
|
lineStyle: {
|
|
193
|
-
color:
|
|
193
|
+
color: GL_COLOR_NEUTRAL_0,
|
|
194
194
|
width: 2
|
|
195
195
|
}
|
|
196
196
|
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import * as echarts from 'echarts';
|
|
2
|
-
import { GRAY_200 } from '../../../tokens/build/js/tokens';
|
|
3
2
|
import { defaultFontSize } from '../../../utils/charts/config';
|
|
4
3
|
import { LEGEND_AVERAGE_TEXT, LEGEND_CURRENT_TEXT, LEGEND_MIN_TEXT, LEGEND_MAX_TEXT, LEGEND_LAYOUT_INLINE, LEGEND_LAYOUT_TABLE } from '../../../utils/charts/constants';
|
|
5
4
|
import { engineeringNotation, average } from '../../../utils/number_utils';
|
|
@@ -155,7 +154,7 @@ var script = {
|
|
|
155
154
|
});
|
|
156
155
|
},
|
|
157
156
|
getColor(color, key) {
|
|
158
|
-
return this.disabledSeries[key] ?
|
|
157
|
+
return this.disabledSeries[key] ? 'var(--gl-chart-axis-line-color)' : color;
|
|
159
158
|
},
|
|
160
159
|
suppressLastActiveSeriesLabelToggle(_ref2) {
|
|
161
160
|
let {
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import merge from 'lodash/merge';
|
|
2
|
-
import { GRAY_200 } from '../../../tokens/build/js/tokens';
|
|
3
2
|
import { symbolSize, lineStyle, getThresholdConfig, generateAnnotationSeries, defaultChartOptions, dataZoomAdjustments, mergeSeriesToOptions, mergeAnnotationAxisToOptions, grid } from '../../../utils/charts/config';
|
|
4
3
|
import { LEGEND_AVERAGE_TEXT, LEGEND_MAX_TEXT, LEGEND_MIN_TEXT, LEGEND_CURRENT_TEXT, LEGEND_LAYOUT_INLINE, LEGEND_LAYOUT_TABLE, HEIGHT_AUTO_CLASSES } from '../../../utils/charts/constants';
|
|
5
4
|
import { colorFromDefaultPalette } from '../../../utils/charts/theme';
|
|
@@ -153,7 +152,7 @@ var script = {
|
|
|
153
152
|
alignWithLabel: true,
|
|
154
153
|
show: true,
|
|
155
154
|
lineStyle: {
|
|
156
|
-
color:
|
|
155
|
+
color: 'var(--gl-chart-axis-line-color)'
|
|
157
156
|
}
|
|
158
157
|
}
|
|
159
158
|
},
|