@nethserver/ns8-ui-lib 0.1.11 → 0.1.12

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.
@@ -20772,6 +20772,10 @@ var script$5 = {
20772
20772
  type: Boolean,
20773
20773
  default: false
20774
20774
  },
20775
+ showItemDescription: {
20776
+ type: Boolean,
20777
+ default: false
20778
+ },
20775
20779
  // use cv-tag color
20776
20780
  selectedItemsColor: {
20777
20781
  type: String,
@@ -21151,6 +21155,20 @@ var script$5 = {
21151
21155
 
21152
21156
  inputFocus() {
21153
21157
  this.doOpen(true);
21158
+ },
21159
+
21160
+ getItemLabel(item) {
21161
+ let label = item.label;
21162
+
21163
+ if (this.showItemType && item.type) {
21164
+ label += ` [${item.type}]`;
21165
+ }
21166
+
21167
+ if (this.showItemDescription && item.description) {
21168
+ label += ` ${item.description}`;
21169
+ }
21170
+
21171
+ return label;
21154
21172
  }
21155
21173
 
21156
21174
  }
@@ -21389,7 +21407,7 @@ var __vue_render__$c = function () {
21389
21407
  "value": item.value,
21390
21408
  "name": item.name,
21391
21409
  "data-test": item.name,
21392
- "label": _vm.showItemType && item.type ? item.label + ' - ' + item.type : item.label
21410
+ "label": _vm.getItemLabel(item)
21393
21411
  },
21394
21412
  model: {
21395
21413
  value: _vm.dataValue,
@@ -21435,11 +21453,11 @@ var __vue_staticRenderFns__$c = [];
21435
21453
 
21436
21454
  const __vue_inject_styles__$d = function (inject) {
21437
21455
  if (!inject) return;
21438
- inject("data-v-6bbe779f_0", {
21439
- source: ".bx--multi-select--filterable .bx--tag.selected-item[data-v-6bbe779f]{margin-left:0;margin-bottom:.25rem}.margin-bottom-on-open[data-v-6bbe779f]{margin-bottom:14rem}.label-with-tooltip[data-v-6bbe779f]{display:flex;align-items:baseline}",
21456
+ inject("data-v-aa321368_0", {
21457
+ source: ".bx--multi-select--filterable .bx--tag.selected-item[data-v-aa321368]{margin-left:0;margin-bottom:.25rem}.margin-bottom-on-open[data-v-aa321368]{margin-bottom:14rem}.label-with-tooltip[data-v-aa321368]{display:flex;align-items:baseline}",
21440
21458
  map: undefined,
21441
21459
  media: undefined
21442
- }), inject("data-v-6bbe779f_1", {
21460
+ }), inject("data-v-aa321368_1", {
21443
21461
  source: ".selected-item button.bx--tag__close-icon{position:relative;right:1px}.ns-multi-select .bx--tooltip__label .bx--tooltip__trigger{margin-left:.25rem}",
21444
21462
  map: undefined,
21445
21463
  media: undefined
@@ -21448,7 +21466,7 @@ const __vue_inject_styles__$d = function (inject) {
21448
21466
  /* scoped */
21449
21467
 
21450
21468
 
21451
- const __vue_scope_id__$d = "data-v-6bbe779f";
21469
+ const __vue_scope_id__$d = "data-v-aa321368";
21452
21470
  /* module identifier */
21453
21471
 
21454
21472
  const __vue_module_identifier__$d = undefined;
@@ -21533,6 +21551,10 @@ var script$4 = {
21533
21551
  type: Boolean,
21534
21552
  default: false
21535
21553
  },
21554
+ showItemDescription: {
21555
+ type: Boolean,
21556
+ default: false
21557
+ },
21536
21558
  marginBottomOnOpen: {
21537
21559
  type: Boolean,
21538
21560
  default: false
@@ -21879,6 +21901,20 @@ var script$4 = {
21879
21901
  inputFocus() {
21880
21902
  if (this.disabled) return;
21881
21903
  this.doOpen(true);
21904
+ },
21905
+
21906
+ getItemLabel(item) {
21907
+ let label = item.label;
21908
+
21909
+ if (this.showItemType && item.type) {
21910
+ label += ` [${item.type}]`;
21911
+ }
21912
+
21913
+ if (this.showItemDescription && item.description) {
21914
+ label += ` ${item.description}`;
21915
+ }
21916
+
21917
+ return label;
21882
21918
  }
21883
21919
 
21884
21920
  }
@@ -22094,7 +22130,7 @@ var __vue_render__$b = function () {
22094
22130
  }
22095
22131
  }, [_c('div', {
22096
22132
  class: [_vm.carbonPrefix + "--list-box__menu-item__option"]
22097
- }, [_vm._v("\n " + _vm._s(_vm.showItemType && item.type ? item.label + " - " + item.type : item.label) + "\n ")])]);
22133
+ }, [_vm._v("\n " + _vm._s(_vm.getItemLabel(item)) + "\n ")])]);
22098
22134
  }), 0)], 1), _vm._v(" "), _vm.isInvalid ? _c('div', {
22099
22135
  class: [_vm.carbonPrefix + "--form-requirement"]
22100
22136
  }, [_vm._t("invalid-message", function () {
@@ -22111,11 +22147,11 @@ var __vue_staticRenderFns__$b = [];
22111
22147
 
22112
22148
  const __vue_inject_styles__$c = function (inject) {
22113
22149
  if (!inject) return;
22114
- inject("data-v-05ab085e_0", {
22115
- source: ".margin-bottom-on-open[data-v-05ab085e]{margin-bottom:14rem}.label-with-tooltip[data-v-05ab085e]{display:flex;align-items:baseline}",
22150
+ inject("data-v-fc861686_0", {
22151
+ source: ".margin-bottom-on-open[data-v-fc861686]{margin-bottom:14rem}.label-with-tooltip[data-v-fc861686]{display:flex;align-items:baseline}",
22116
22152
  map: undefined,
22117
22153
  media: undefined
22118
- }), inject("data-v-05ab085e_1", {
22154
+ }), inject("data-v-fc861686_1", {
22119
22155
  source: ".ns-combo-box .bx--tooltip__label .bx--tooltip__trigger{margin-left:.25rem}",
22120
22156
  map: undefined,
22121
22157
  media: undefined
@@ -22124,7 +22160,7 @@ const __vue_inject_styles__$c = function (inject) {
22124
22160
  /* scoped */
22125
22161
 
22126
22162
 
22127
- const __vue_scope_id__$c = "data-v-05ab085e";
22163
+ const __vue_scope_id__$c = "data-v-fc861686";
22128
22164
  /* module identifier */
22129
22165
 
22130
22166
  const __vue_module_identifier__$c = undefined;