@dialpad/dialtone-vue 2.53.0 → 2.54.0-beta.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.
@@ -7990,17 +7990,17 @@ var collapsible_component = normalizeComponent(
7990
7990
  /* harmony default export */ const collapsible = (collapsible_component.exports);
7991
7991
  ;// CONCATENATED MODULE: ./components/collapsible/index.js
7992
7992
 
7993
- ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/dropdown/dropdown.vue?vue&type=template&id=70cb2bdc&
7994
- var dropdownvue_type_template_id_70cb2bdc_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('dt-popover',_vm._g({ref:"popover",attrs:{"content-width":_vm.contentWidth,"open":_vm.open,"placement":_vm.placement,"initial-focus-element":_vm.openedWithKeyboard ? 'first' : 'dialog',"fallback-placements":_vm.fallbackPlacements,"padding":"none","role":"menu","modal":_vm.modal,"max-height":_vm.maxHeight,"max-width":_vm.maxWidth,"open-with-arrow-keys":true,"open-on-context":_vm.openOnContext},scopedSlots:_vm._u([{key:"anchor",fn:function(ref){
7993
+ ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/dropdown/dropdown.vue?vue&type=template&id=5944f754&
7994
+ var dropdownvue_type_template_id_5944f754_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('dt-popover',_vm._g({ref:"popover",attrs:{"content-width":_vm.contentWidth,"open":_vm.open,"placement":_vm.placement,"initial-focus-element":_vm.openedWithKeyboard ? 'first' : 'dialog',"fallback-placements":_vm.fallbackPlacements,"padding":"none","role":"menu","modal":_vm.modal,"max-height":_vm.maxHeight,"max-width":_vm.maxWidth,"open-with-arrow-keys":_vm.shouldOpenWithArrowKeys,"open-on-context":_vm.openOnContext},scopedSlots:_vm._u([{key:"anchor",fn:function(ref){
7995
7995
  var attrs = ref.attrs;
7996
7996
  return [_vm._t("anchor",null,null,attrs)]}},{key:"content",fn:function(ref){
7997
7997
  var close = ref.close;
7998
7998
  return [_c('ul',{ref:"listWrapper",class:_vm.listClasses,attrs:{"id":_vm.listId,"data-qa":"dt-dropdown-list-wrapper"},on:{"mouseleave":_vm.clearHighlightIndex,"!mousemove":function($event){return _vm.onMouseHighlight.apply(null, arguments)}}},[_vm._t("list",null,{"close":close}),(_vm.showVisuallyHiddenClose)?_c('sr-only-close-button',{attrs:{"visually-hidden-close-label":_vm.visuallyHiddenCloseLabel,"tabindex":_vm.isArrowKeyNav ? -1 : 0},on:{"close":close}}):_vm._e()],2)]}}],null,true)},_vm.dropdownListeners))}
7999
- var dropdownvue_type_template_id_70cb2bdc_staticRenderFns = []
7999
+ var dropdownvue_type_template_id_5944f754_staticRenderFns = []
8000
8000
 
8001
8001
 
8002
- ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/popover/popover.vue?vue&type=template&id=47e76c3e&
8003
- var popovervue_type_template_id_47e76c3e_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[(_vm.modal && _vm.isOpen)?_c('portal',[_c('div',{staticClass:"d-modal--transparent",attrs:{"aria-hidden":_vm.modal && _vm.isOpen ? 'false' : 'true'},on:{"click":function($event){$event.preventDefault();$event.stopPropagation();}}})]):_vm._e(),_c(_vm.elementType,_vm._g({ref:"popover",tag:"component",class:['d-popover', { 'd-popover__anchor--opened': _vm.isOpen }],attrs:{"data-qa":"dt-popover-container"}},_vm.$listeners),[_c('div',{ref:"anchor",attrs:{"id":!_vm.ariaLabelledby && _vm.labelledBy,"data-qa":"dt-popover-anchor","tabindex":_vm.openOnContext ? 0 : undefined},on:{"!click":function($event){return _vm.defaultToggleOpen.apply(null, arguments)},"contextmenu":_vm.onContext,"keydown":[function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"up",38,$event.key,["Up","ArrowUp"])){ return null; }$event.preventDefault();return _vm.onArrowKeyPress.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.onArrowKeyPress.apply(null, arguments)}],"!keydown":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"escape",undefined,$event.key,undefined)){ return null; }return _vm.closePopover.apply(null, arguments)}}},[_vm._t("anchor",null,{"attrs":{
8002
+ ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/popover/popover.vue?vue&type=template&id=8dc20c0e&
8003
+ var popovervue_type_template_id_8dc20c0e_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[(_vm.modal && _vm.isOpen)?_c('portal',[_c('div',{staticClass:"d-modal--transparent",attrs:{"aria-hidden":_vm.modal && _vm.isOpen ? 'false' : 'true'},on:{"click":function($event){$event.preventDefault();$event.stopPropagation();}}})]):_vm._e(),_c(_vm.elementType,_vm._g({ref:"popover",tag:"component",class:['d-popover', { 'd-popover__anchor--opened': _vm.isOpen }],attrs:{"data-qa":"dt-popover-container"}},_vm.$listeners),[_c('div',{ref:"anchor",attrs:{"id":!_vm.ariaLabelledby && _vm.labelledBy,"data-qa":"dt-popover-anchor","tabindex":_vm.openOnContext ? 0 : undefined},on:{"!click":function($event){return _vm.defaultToggleOpen.apply(null, arguments)},"contextmenu":_vm.onContext,"keydown":[function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"up",38,$event.key,["Up","ArrowUp"])){ return null; }$event.preventDefault();return _vm.onArrowKeyPress.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.onArrowKeyPress.apply(null, arguments)}],"!keydown":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"escape",undefined,$event.key,undefined)){ return null; }return _vm.closePopover.apply(null, arguments)}}},[_vm._t("anchor",null,{"attrs":{
8004
8004
  'aria-expanded': _vm.isOpen.toString(),
8005
8005
  'aria-controls': _vm.id,
8006
8006
  'aria-haspopup': _vm.role,
@@ -8011,7 +8011,7 @@ var popovervue_type_template_id_47e76c3e_render = function () {var _vm=this;var
8011
8011
  'd-popover__content',
8012
8012
  _vm.POPOVER_PADDING_CLASSES[_vm.padding],
8013
8013
  _vm.contentClass ],attrs:{"data-qa":"dt-popover-content"}},[_vm._t("content",null,{"close":_vm.closePopover})],2),(_vm.$slots.footerContent)?_c('popover-header-footer',{ref:"popover__footer",class:_vm.POPOVER_HEADER_FOOTER_PADDING_CLASSES[_vm.padding],attrs:{"type":"footer","content-class":_vm.footerClass},scopedSlots:_vm._u([{key:"content",fn:function(){return [_vm._t("footerContent",null,{"close":_vm.closePopover})]},proxy:true}],null,true)}):_vm._e(),(_vm.showVisuallyHiddenClose)?_c('sr-only-close-button',{attrs:{"visually-hidden-close-label":_vm.visuallyHiddenCloseLabel},on:{"close":_vm.closePopover}}):_vm._e()],1)],1)],1)}
8014
- var popovervue_type_template_id_47e76c3e_staticRenderFns = []
8014
+ var popovervue_type_template_id_8dc20c0e_staticRenderFns = []
8015
8015
 
8016
8016
 
8017
8017
  ;// CONCATENATED MODULE: ./node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js
@@ -13431,7 +13431,7 @@ var popover_header_footer_component = normalizeComponent(
13431
13431
  },
13432
13432
 
13433
13433
  mounted() {
13434
- const externalAnchorEl = document.getElementById(this.externalAnchor);
13434
+ const externalAnchorEl = this.externalAnchor ? this.$el.getRootNode().querySelector(`#${this.externalAnchor}`) : null;
13435
13435
  this.anchorEl = externalAnchorEl !== null && externalAnchorEl !== void 0 ? externalAnchorEl : this.$refs.anchor.children[0];
13436
13436
  this.popoverContentEl = this.$refs.content.$el;
13437
13437
 
@@ -13468,7 +13468,7 @@ var popover_header_footer_component = normalizeComponent(
13468
13468
 
13469
13469
  calculateAnchorZindex() {
13470
13470
  // if a modal is currently active render at modal-element z-index, otherwise at popover z-index
13471
- if (document.querySelector('.d-modal[aria-hidden="false"], .d-modal--transparent[aria-hidden="false"]')) {
13471
+ if (this.$el.getRootNode().querySelector('.d-modal[aria-hidden="false"], .d-modal--transparent[aria-hidden="false"]')) {
13472
13472
  return 650;
13473
13473
  } else {
13474
13474
  return 300;
@@ -13722,8 +13722,8 @@ var popovervue_type_style_index_0_lang_less_ = __webpack_require__(230);
13722
13722
 
13723
13723
  var popover_component = normalizeComponent(
13724
13724
  popover_popovervue_type_script_lang_js_,
13725
- popovervue_type_template_id_47e76c3e_render,
13726
- popovervue_type_template_id_47e76c3e_staticRenderFns,
13725
+ popovervue_type_template_id_8dc20c0e_render,
13726
+ popovervue_type_template_id_8dc20c0e_staticRenderFns,
13727
13727
  false,
13728
13728
  null,
13729
13729
  null,
@@ -13996,14 +13996,14 @@ const DROPDOWN_PADDING_CLASSES = {
13996
13996
  switch (eventCode) {
13997
13997
  case EVENT_KEYNAMES.up:
13998
13998
  case EVENT_KEYNAMES.arrowup:
13999
- this.onKeyValidation(event, 'onUpKeyPress');
13999
+ this.onUpKeyPress(event);
14000
14000
  event.stopPropagation();
14001
14001
  event.preventDefault();
14002
14002
  break;
14003
14003
 
14004
14004
  case EVENT_KEYNAMES.down:
14005
14005
  case EVENT_KEYNAMES.arrowdown:
14006
- this.onKeyValidation(event, 'onDownKeyPress');
14006
+ this.onDownKeyPress(event);
14007
14007
  event.stopPropagation();
14008
14008
  event.preventDefault();
14009
14009
  break;
@@ -14018,19 +14018,19 @@ const DROPDOWN_PADDING_CLASSES = {
14018
14018
  break;
14019
14019
 
14020
14020
  case EVENT_KEYNAMES.home:
14021
- this.onKeyValidation(event, 'onHomeKeyPress');
14021
+ this.onHomeKeyPress(event);
14022
14022
  event.stopPropagation();
14023
14023
  event.preventDefault();
14024
14024
  break;
14025
14025
 
14026
14026
  case EVENT_KEYNAMES.end:
14027
- this.onKeyValidation(event, 'onEndKeyPress');
14027
+ this.onEndKeyPress(event);
14028
14028
  event.stopPropagation();
14029
14029
  event.preventDefault();
14030
14030
  break;
14031
14031
 
14032
14032
  default:
14033
- this.onKeyValidation(event, 'onKeyPress');
14033
+ this.onKeyPress(event);
14034
14034
  break;
14035
14035
  }
14036
14036
 
@@ -14059,6 +14059,10 @@ const DROPDOWN_PADDING_CLASSES = {
14059
14059
  return ['d-ps-relative', 'd-stack2', 'd-m4', 'd-px0', DROPDOWN_PADDING_CLASSES[this.padding], this.listClass, {
14060
14060
  'd-context-menu-list': this.openOnContext
14061
14061
  }];
14062
+ },
14063
+
14064
+ shouldOpenWithArrowKeys() {
14065
+ return !this.openOnContext;
14062
14066
  }
14063
14067
 
14064
14068
  },
@@ -14162,14 +14166,6 @@ const DROPDOWN_PADDING_CLASSES = {
14162
14166
  e.stopPropagation();
14163
14167
  e.preventDefault();
14164
14168
  return this.onNavigationKey(e.key);
14165
- },
14166
-
14167
- onKeyValidation(e, eventHandler) {
14168
- if (this.open !== null && !this.openOnContext) {
14169
- return;
14170
- }
14171
-
14172
- this[eventHandler](e);
14173
14169
  }
14174
14170
 
14175
14171
  }
@@ -14191,8 +14187,8 @@ var dropdownvue_type_style_index_0_lang_less_ = __webpack_require__(782);
14191
14187
 
14192
14188
  var dropdown_component = normalizeComponent(
14193
14189
  dropdown_dropdownvue_type_script_lang_js_,
14194
- dropdownvue_type_template_id_70cb2bdc_render,
14195
- dropdownvue_type_template_id_70cb2bdc_staticRenderFns,
14190
+ dropdownvue_type_template_id_5944f754_render,
14191
+ dropdownvue_type_template_id_5944f754_staticRenderFns,
14196
14192
  false,
14197
14193
  null,
14198
14194
  null,
@@ -15801,14 +15797,15 @@ var input_group_component = normalizeComponent(
15801
15797
  /* harmony default export */ const input_group_input_group = (input_group_component.exports);
15802
15798
  ;// CONCATENATED MODULE: ./components/input_group/index.js
15803
15799
 
15804
- ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/modal/modal.vue?vue&type=template&id=e9bf0878&
15805
- var modalvue_type_template_id_e9bf0878_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('dt-lazy-show',_vm._g({class:[
15800
+ ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/modal/modal.vue?vue&type=template&id=a8730b96&
15801
+ var modalvue_type_template_id_a8730b96_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('dt-lazy-show',_vm._g({class:[
15806
15802
  'd-modal',
15807
15803
  _vm.MODAL_KIND_MODIFIERS[_vm.kind],
15808
15804
  _vm.MODAL_SIZE_MODIFIERS[_vm.size],
15809
15805
  _vm.modalClass ],attrs:{"transition":"d-zoom","show":_vm.show,"data-qa":"dt-modal","aria-hidden":_vm.open}},_vm.modalListeners),[(_vm.show && (_vm.$slots.banner || _vm.bannerTitle))?_c('div',{class:[
15810
15806
  'd-modal__banner',
15811
- _vm.bannerClass ],attrs:{"data-qa":"dt-modal-banner"}},[_vm._t("banner",function(){return [_vm._v(" "+_vm._s(_vm.bannerTitle)+" ")]})],2):_vm._e(),_c('transition',{attrs:{"appear":"","name":"d-modal__dialog"}},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.show),expression:"show"}],class:[
15807
+ _vm.bannerClass,
15808
+ _vm.bannerKindClass ],attrs:{"data-qa":"dt-modal-banner"}},[_vm._t("banner",function(){return [_vm._v(" "+_vm._s(_vm.bannerTitle)+" ")]})],2):_vm._e(),_c('transition',{attrs:{"appear":"","name":"d-modal__dialog"}},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.show),expression:"show"}],class:[
15812
15809
  'd-modal__dialog',
15813
15810
  { 'd-modal__dialog--scrollable': _vm.fixedHeaderFooter },
15814
15811
  _vm.dialogClass ],attrs:{"role":"dialog","aria-modal":"true","aria-describedby":_vm.describedById,"aria-labelledby":_vm.labelledById}},[(_vm.$slots.header)?_c('div',{staticClass:"d-modal__header",attrs:{"id":_vm.labelledById,"data-qa":"dt-modal-title"}},[_vm._t("header")],2):_c('h2',{staticClass:"d-modal__header",attrs:{"id":_vm.labelledById,"data-qa":"dt-modal-title"}},[_vm._v(" "+_vm._s(_vm.title)+" ")]),(_vm.$slots.default)?_c('div',{class:[
@@ -15816,7 +15813,7 @@ var modalvue_type_template_id_e9bf0878_render = function () {var _vm=this;var _h
15816
15813
  _vm.contentClass ],attrs:{"data-qa":"dt-modal-copy"}},[_vm._t("default")],2):_c('p',{class:[
15817
15814
  'd-modal__content',
15818
15815
  _vm.contentClass ],attrs:{"data-qa":"dt-modal-copy"}},[_vm._v(" "+_vm._s(_vm.copy)+" ")]),(_vm.hasFooterSlot)?_c('footer',{staticClass:"d-modal__footer"},[_vm._t("footer")],2):_vm._e(),(!_vm.hideClose)?_c('dt-button',_vm._b({staticClass:"d-modal__close",attrs:{"circle":"","size":"lg","importance":"clear","aria-label":_vm.closeButtonProps.ariaLabel},on:{"click":_vm.close},scopedSlots:_vm._u([{key:"icon",fn:function(){return [_c('dt-icon',{attrs:{"name":"close","size":"400"}})]},proxy:true}],null,false,1709155279)},'dt-button',_vm.closeButtonProps,false)):_vm._e(),(_vm.showVisuallyHiddenClose)?_c('sr-only-close-button',{attrs:{"visually-hidden-close-label":_vm.visuallyHiddenCloseLabel},on:{"close":_vm.close}}):_vm._e()],1)])],1)}
15819
- var modalvue_type_template_id_e9bf0878_staticRenderFns = []
15816
+ var modalvue_type_template_id_a8730b96_staticRenderFns = []
15820
15817
 
15821
15818
 
15822
15819
  ;// CONCATENATED MODULE: ./components/modal/modal_constants.js
@@ -15830,6 +15827,208 @@ const MODAL_SIZE_MODIFIERS = {
15830
15827
  default: '',
15831
15828
  full: 'd-modal--full'
15832
15829
  };
15830
+ const MODAL_BANNER_KINDS = {
15831
+ error: 'd-modal__banner--critical',
15832
+ info: 'd-modal__banner--info',
15833
+ success: 'd-modal__banner--success',
15834
+ warning: 'd-modal__banner--warning',
15835
+ base: 'd-modal__banner--general'
15836
+ };
15837
+ ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/notice/notice.vue?vue&type=template&id=bdb2f588&
15838
+ var noticevue_type_template_id_bdb2f588_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('aside',{class:_vm.noticeClass,attrs:{"data-qa":"notice"}},[_c('dt-notice-icon',{attrs:{"kind":_vm.kind}},[_vm._t("icon")],2),_c('dt-notice-content',_vm._g({attrs:{"title-id":_vm.titleId,"content-id":_vm.contentId,"title":_vm.title,"role":_vm.role},scopedSlots:_vm._u([{key:"titleOverride",fn:function(){return [_vm._t("titleOverride")]},proxy:true}],null,true)},_vm.$listeners),[_vm._t("default")],2),_c('dt-notice-action',_vm._g({attrs:{"hide-close":_vm.hideClose,"close-button-props":_vm.closeButtonProps,"visually-hidden-close":_vm.visuallyHiddenClose,"visually-hidden-close-label":_vm.visuallyHiddenCloseLabel}},_vm.$listeners),[_vm._t("action")],2)],1)}
15839
+ var noticevue_type_template_id_bdb2f588_staticRenderFns = []
15840
+
15841
+
15842
+ ;// CONCATENATED MODULE: ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40[0].rules[0].use[1]!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/notice/notice.vue?vue&type=script&lang=js&
15843
+ //
15844
+ //
15845
+ //
15846
+ //
15847
+ //
15848
+ //
15849
+ //
15850
+ //
15851
+ //
15852
+ //
15853
+ //
15854
+ //
15855
+ //
15856
+ //
15857
+ //
15858
+ //
15859
+ //
15860
+ //
15861
+ //
15862
+ //
15863
+ //
15864
+ //
15865
+ //
15866
+ //
15867
+ //
15868
+ //
15869
+ //
15870
+ //
15871
+ //
15872
+ //
15873
+ //
15874
+ //
15875
+ //
15876
+ //
15877
+ //
15878
+ //
15879
+ //
15880
+ //
15881
+ //
15882
+
15883
+
15884
+
15885
+
15886
+
15887
+ /**
15888
+ * A notice is an informational and assistive message that appears inline with content.
15889
+ * @see https://dialpad.design/components/notice.html
15890
+ */
15891
+
15892
+ /* harmony default export */ const noticevue_type_script_lang_js_ = ({
15893
+ name: 'DtNotice',
15894
+ components: {
15895
+ DtNoticeIcon: notice_icon,
15896
+ DtNoticeContent: notice_content,
15897
+ DtNoticeAction: notice_action
15898
+ },
15899
+ mixins: [sr_only_close_button],
15900
+ props: {
15901
+ /**
15902
+ * Sets an ID on the title element of the component. Useful for aria-describedby
15903
+ * or aria-labelledby or any other reason you may need an id to refer to the title.
15904
+ */
15905
+ titleId: {
15906
+ type: String,
15907
+ default: undefined
15908
+ },
15909
+
15910
+ /**
15911
+ * Sets an ID on the content element of the component. Useful for aria-describedby
15912
+ * or aria-labelledby or any other reason you may need an id to refer to the content.
15913
+ */
15914
+ contentId: {
15915
+ type: String,
15916
+ default: undefined
15917
+ },
15918
+
15919
+ /**
15920
+ * Title header of the notice. This can be left blank to remove the title from the notice entirely.
15921
+ */
15922
+ title: {
15923
+ type: String,
15924
+ default: ''
15925
+ },
15926
+
15927
+ /**
15928
+ * Provides a role for the notice. 'status' is used to communicate a message. 'alert' is used to communicate an
15929
+ * important message that does not contain any interactive elements. 'alertdialog' is used to communicate an
15930
+ * important message that does contain interactive elements.
15931
+ * @values alert, alertdialog, status
15932
+ */
15933
+ role: {
15934
+ type: String,
15935
+ default: 'status',
15936
+
15937
+ validate(role) {
15938
+ return NOTICE_ROLES.includes(role);
15939
+ }
15940
+
15941
+ },
15942
+
15943
+ /**
15944
+ * Used in scenarios where the message needs to visually dominate the screen.
15945
+ * This will also change the aria role from status to alert.
15946
+ * @values true, false
15947
+ */
15948
+ important: {
15949
+ type: Boolean,
15950
+ default: false
15951
+ },
15952
+
15953
+ /**
15954
+ * Severity level of the notice, sets the icon and background
15955
+ * @values base, error, info, success, warning
15956
+ */
15957
+ kind: {
15958
+ type: String,
15959
+ default: 'base',
15960
+
15961
+ validate(kind) {
15962
+ return NOTICE_KINDS.includes(kind);
15963
+ }
15964
+
15965
+ },
15966
+
15967
+ /**
15968
+ * Props for the notice close button.
15969
+ */
15970
+ closeButtonProps: {
15971
+ type: Object,
15972
+ default: () => ({})
15973
+ },
15974
+
15975
+ /**
15976
+ * Hides the close button from the notice
15977
+ * @values true, false
15978
+ */
15979
+ hideClose: {
15980
+ type: Boolean,
15981
+ default: false
15982
+ }
15983
+ },
15984
+ emits: [
15985
+ /**
15986
+ * Close button click event
15987
+ *
15988
+ * @event close
15989
+ */
15990
+ 'close'],
15991
+ computed: {
15992
+ noticeClass() {
15993
+ const noticeKinds = {
15994
+ error: 'd-notice--error',
15995
+ info: 'd-notice--info',
15996
+ success: 'd-notice--success',
15997
+ warning: 'd-notice--warning',
15998
+ base: 'd-notice--base'
15999
+ };
16000
+ return ['d-notice', noticeKinds[this.kind], {
16001
+ 'd-notice--important': this.important
16002
+ }];
16003
+ }
16004
+
16005
+ }
16006
+ });
16007
+ ;// CONCATENATED MODULE: ./components/notice/notice.vue?vue&type=script&lang=js&
16008
+ /* harmony default export */ const notice_noticevue_type_script_lang_js_ = (noticevue_type_script_lang_js_);
16009
+ ;// CONCATENATED MODULE: ./components/notice/notice.vue
16010
+
16011
+
16012
+
16013
+
16014
+
16015
+ /* normalize component */
16016
+ ;
16017
+ var notice_component = normalizeComponent(
16018
+ notice_noticevue_type_script_lang_js_,
16019
+ noticevue_type_template_id_bdb2f588_render,
16020
+ noticevue_type_template_id_bdb2f588_staticRenderFns,
16021
+ false,
16022
+ null,
16023
+ null,
16024
+ null
16025
+
16026
+ )
16027
+
16028
+ /* harmony default export */ const notice = (notice_component.exports);
16029
+ ;// CONCATENATED MODULE: ./components/notice/index.js
16030
+
16031
+
15833
16032
  ;// CONCATENATED MODULE: ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40[0].rules[0].use[1]!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/modal/modal.vue?vue&type=script&lang=js&
15834
16033
  //
15835
16034
  //
@@ -15946,6 +16145,8 @@ const MODAL_SIZE_MODIFIERS = {
15946
16145
  //
15947
16146
  //
15948
16147
  //
16148
+ //
16149
+
15949
16150
 
15950
16151
 
15951
16152
 
@@ -16087,6 +16288,20 @@ const MODAL_SIZE_MODIFIERS = {
16087
16288
  default: ''
16088
16289
  },
16089
16290
 
16291
+ /**
16292
+ * Sets the color of the banner.
16293
+ * @values base, error, info, success, warning
16294
+ */
16295
+ bannerKind: {
16296
+ type: String,
16297
+ default: 'warning',
16298
+
16299
+ validate(kind) {
16300
+ return NOTICE_KINDS.includes(kind);
16301
+ }
16302
+
16303
+ },
16304
+
16090
16305
  /**
16091
16306
  * Additional class name for the banner element within the modal.
16092
16307
  * Can accept String, Object, and Array, i.e. has the
@@ -16129,6 +16344,7 @@ const MODAL_SIZE_MODIFIERS = {
16129
16344
  return {
16130
16345
  MODAL_KIND_MODIFIERS: MODAL_KIND_MODIFIERS,
16131
16346
  MODAL_SIZE_MODIFIERS: MODAL_SIZE_MODIFIERS,
16347
+ MODAL_BANNER_KINDS: MODAL_BANNER_KINDS,
16132
16348
  EVENT_KEYNAMES: EVENT_KEYNAMES
16133
16349
  };
16134
16350
  },
@@ -16166,6 +16382,10 @@ const MODAL_SIZE_MODIFIERS = {
16166
16382
 
16167
16383
  hasFooterSlot() {
16168
16384
  return !!this.$slots.footer;
16385
+ },
16386
+
16387
+ bannerKindClass() {
16388
+ return MODAL_BANNER_KINDS[this.bannerKind];
16169
16389
  }
16170
16390
 
16171
16391
  },
@@ -16233,8 +16453,8 @@ const MODAL_SIZE_MODIFIERS = {
16233
16453
  ;
16234
16454
  var modal_component = normalizeComponent(
16235
16455
  modal_modalvue_type_script_lang_js_,
16236
- modalvue_type_template_id_e9bf0878_render,
16237
- modalvue_type_template_id_e9bf0878_staticRenderFns,
16456
+ modalvue_type_template_id_a8730b96_render,
16457
+ modalvue_type_template_id_a8730b96_staticRenderFns,
16238
16458
  false,
16239
16459
  null,
16240
16460
  null,
@@ -16532,201 +16752,6 @@ var list_item_group_component = normalizeComponent(
16532
16752
  ;// CONCATENATED MODULE: ./components/list_item_group/index.js
16533
16753
 
16534
16754
 
16535
- ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/notice/notice.vue?vue&type=template&id=bdb2f588&
16536
- var noticevue_type_template_id_bdb2f588_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('aside',{class:_vm.noticeClass,attrs:{"data-qa":"notice"}},[_c('dt-notice-icon',{attrs:{"kind":_vm.kind}},[_vm._t("icon")],2),_c('dt-notice-content',_vm._g({attrs:{"title-id":_vm.titleId,"content-id":_vm.contentId,"title":_vm.title,"role":_vm.role},scopedSlots:_vm._u([{key:"titleOverride",fn:function(){return [_vm._t("titleOverride")]},proxy:true}],null,true)},_vm.$listeners),[_vm._t("default")],2),_c('dt-notice-action',_vm._g({attrs:{"hide-close":_vm.hideClose,"close-button-props":_vm.closeButtonProps,"visually-hidden-close":_vm.visuallyHiddenClose,"visually-hidden-close-label":_vm.visuallyHiddenCloseLabel}},_vm.$listeners),[_vm._t("action")],2)],1)}
16537
- var noticevue_type_template_id_bdb2f588_staticRenderFns = []
16538
-
16539
-
16540
- ;// CONCATENATED MODULE: ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40[0].rules[0].use[1]!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/notice/notice.vue?vue&type=script&lang=js&
16541
- //
16542
- //
16543
- //
16544
- //
16545
- //
16546
- //
16547
- //
16548
- //
16549
- //
16550
- //
16551
- //
16552
- //
16553
- //
16554
- //
16555
- //
16556
- //
16557
- //
16558
- //
16559
- //
16560
- //
16561
- //
16562
- //
16563
- //
16564
- //
16565
- //
16566
- //
16567
- //
16568
- //
16569
- //
16570
- //
16571
- //
16572
- //
16573
- //
16574
- //
16575
- //
16576
- //
16577
- //
16578
- //
16579
- //
16580
-
16581
-
16582
-
16583
-
16584
-
16585
- /**
16586
- * A notice is an informational and assistive message that appears inline with content.
16587
- * @see https://dialpad.design/components/notice.html
16588
- */
16589
-
16590
- /* harmony default export */ const noticevue_type_script_lang_js_ = ({
16591
- name: 'DtNotice',
16592
- components: {
16593
- DtNoticeIcon: notice_icon,
16594
- DtNoticeContent: notice_content,
16595
- DtNoticeAction: notice_action
16596
- },
16597
- mixins: [sr_only_close_button],
16598
- props: {
16599
- /**
16600
- * Sets an ID on the title element of the component. Useful for aria-describedby
16601
- * or aria-labelledby or any other reason you may need an id to refer to the title.
16602
- */
16603
- titleId: {
16604
- type: String,
16605
- default: undefined
16606
- },
16607
-
16608
- /**
16609
- * Sets an ID on the content element of the component. Useful for aria-describedby
16610
- * or aria-labelledby or any other reason you may need an id to refer to the content.
16611
- */
16612
- contentId: {
16613
- type: String,
16614
- default: undefined
16615
- },
16616
-
16617
- /**
16618
- * Title header of the notice. This can be left blank to remove the title from the notice entirely.
16619
- */
16620
- title: {
16621
- type: String,
16622
- default: ''
16623
- },
16624
-
16625
- /**
16626
- * Provides a role for the notice. 'status' is used to communicate a message. 'alert' is used to communicate an
16627
- * important message that does not contain any interactive elements. 'alertdialog' is used to communicate an
16628
- * important message that does contain interactive elements.
16629
- * @values alert, alertdialog, status
16630
- */
16631
- role: {
16632
- type: String,
16633
- default: 'status',
16634
-
16635
- validate(role) {
16636
- return NOTICE_ROLES.includes(role);
16637
- }
16638
-
16639
- },
16640
-
16641
- /**
16642
- * Used in scenarios where the message needs to visually dominate the screen.
16643
- * This will also change the aria role from status to alert.
16644
- * @values true, false
16645
- */
16646
- important: {
16647
- type: Boolean,
16648
- default: false
16649
- },
16650
-
16651
- /**
16652
- * Severity level of the notice, sets the icon and background
16653
- * @values base, error, info, success, warning
16654
- */
16655
- kind: {
16656
- type: String,
16657
- default: 'base',
16658
-
16659
- validate(kind) {
16660
- return NOTICE_KINDS.includes(kind);
16661
- }
16662
-
16663
- },
16664
-
16665
- /**
16666
- * Props for the notice close button.
16667
- */
16668
- closeButtonProps: {
16669
- type: Object,
16670
- default: () => ({})
16671
- },
16672
-
16673
- /**
16674
- * Hides the close button from the notice
16675
- * @values true, false
16676
- */
16677
- hideClose: {
16678
- type: Boolean,
16679
- default: false
16680
- }
16681
- },
16682
- emits: [
16683
- /**
16684
- * Close button click event
16685
- *
16686
- * @event close
16687
- */
16688
- 'close'],
16689
- computed: {
16690
- noticeClass() {
16691
- const noticeKinds = {
16692
- error: 'd-notice--error',
16693
- info: 'd-notice--info',
16694
- success: 'd-notice--success',
16695
- warning: 'd-notice--warning',
16696
- base: 'd-notice--base'
16697
- };
16698
- return ['d-notice', noticeKinds[this.kind], {
16699
- 'd-notice--important': this.important
16700
- }];
16701
- }
16702
-
16703
- }
16704
- });
16705
- ;// CONCATENATED MODULE: ./components/notice/notice.vue?vue&type=script&lang=js&
16706
- /* harmony default export */ const notice_noticevue_type_script_lang_js_ = (noticevue_type_script_lang_js_);
16707
- ;// CONCATENATED MODULE: ./components/notice/notice.vue
16708
-
16709
-
16710
-
16711
-
16712
-
16713
- /* normalize component */
16714
- ;
16715
- var notice_component = normalizeComponent(
16716
- notice_noticevue_type_script_lang_js_,
16717
- noticevue_type_template_id_bdb2f588_render,
16718
- noticevue_type_template_id_bdb2f588_staticRenderFns,
16719
- false,
16720
- null,
16721
- null,
16722
- null
16723
-
16724
- )
16725
-
16726
- /* harmony default export */ const notice = (notice_component.exports);
16727
- ;// CONCATENATED MODULE: ./components/notice/index.js
16728
-
16729
-
16730
16755
  ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./components/pagination/pagination.vue?vue&type=template&id=8a1dbe50&
16731
16756
  var paginationvue_type_template_id_8a1dbe50_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('nav',{staticClass:"d-d-flex d-fd-row d-gg4 d-ai-center",attrs:{"aria-label":_vm.ariaLabel}},[_c('dt-button',{staticClass:"d-px8",class:_vm.isFirstPage ? 'd-fc-black-300 h:d-fc-black-300 d-bgc-transparent' : 'd-fc-tertiary',attrs:{"data-qa":"dt-pagination-prev","aria-label":_vm.prevAriaLabel,"kind":"muted","importance":_vm.isFirstPage ? 'primary' : 'clear',"disabled":_vm.isFirstPage},on:{"click":function($event){return _vm.changePage(_vm.currentPage - 1)}}},[_c('template',{slot:"icon"},[_c('dt-icon',{attrs:{"name":"chevron-left","size":"300"}})],1)],2),_vm._l((_vm.pages),function(page,index){return _c('div',{key:("page-" + page + "-" + index),class:{ 'd-as-flex-end': isNaN(Number(page)) }},[(isNaN(Number(page)))?_c('div',{staticClass:"d-fc-tertiary d-w24 d-ta-center",attrs:{"data-qa":"dt-pagination-separator"}},[_c('dt-icon',{attrs:{"name":"more-horizontal","size":"300"}})],1):_c('dt-button',{attrs:{"aria-label":_vm.pageNumberAriaLabel(page),"kind":_vm.currentPage === page ? 'default' : 'muted',"importance":_vm.currentPage === page ? 'primary' : 'clear',"label-class":""},on:{"click":function($event){return _vm.changePage(page)}}},[_vm._v(" "+_vm._s(page)+" ")])],1)}),_c('dt-button',{staticClass:"d-px8",class:_vm.isLastPage ? 'd-fc-black-300 h:d-fc-black-300 d-bgc-transparent' : 'd-fc-tertiary',attrs:{"data-qa":"dt-pagination-next","aria-label":_vm.nextAriaLabel,"disabled":_vm.isLastPage,"kind":"muted","importance":_vm.isLastPage ? 'primary' : 'clear'},on:{"click":function($event){return _vm.changePage(_vm.currentPage + 1)}}},[_c('template',{slot:"icon"},[_c('dt-icon',{attrs:{"name":"chevron-right","size":"300"}})],1)],2)],2)}
16732
16757
  var paginationvue_type_template_id_8a1dbe50_staticRenderFns = []
@@ -20418,15 +20443,15 @@ var root_layout_component = normalizeComponent(
20418
20443
  ;// CONCATENATED MODULE: ./components/root_layout/index.js
20419
20444
 
20420
20445
 
20421
- ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./recipes/comboboxes/combobox_with_popover/combobox_with_popover.vue?vue&type=template&id=ad3e7dce&
20422
- var combobox_with_popovervue_type_template_id_ad3e7dce_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('dt-combobox',_vm._g({ref:"combobox",attrs:{"loading":_vm.loading,"label":_vm.label,"label-visible":_vm.labelVisible,"size":_vm.size,"description":_vm.description,"empty-list":_vm.emptyList,"empty-state-message":_vm.emptyStateMessage,"show-list":_vm.isListShown,"on-beginning-of-list":_vm.onBeginningOfList,"on-end-of-list":_vm.onEndOfList,"list-rendered-outside":true,"list-id":_vm.listId,"data-qa":"dt-combobox"},scopedSlots:_vm._u([{key:"input",fn:function(ref){
20446
+ ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./recipes/comboboxes/combobox_with_popover/combobox_with_popover.vue?vue&type=template&id=294704b9&
20447
+ var combobox_with_popovervue_type_template_id_294704b9_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('dt-combobox',_vm._g({ref:"combobox",attrs:{"loading":_vm.loading,"label":_vm.label,"label-visible":_vm.labelVisible,"size":_vm.size,"description":_vm.description,"empty-list":_vm.emptyList,"empty-state-message":_vm.emptyStateMessage,"show-list":_vm.isListShown,"on-beginning-of-list":_vm.onBeginningOfList,"on-end-of-list":_vm.onEndOfList,"list-rendered-outside":true,"list-id":_vm.listId,"append-to":_vm.appendTo,"data-qa":"dt-combobox"},scopedSlots:_vm._u([{key:"input",fn:function(ref){
20423
20448
  var inputProps = ref.inputProps;
20424
20449
  return [_c('div',{ref:"input",attrs:{"id":_vm.externalAnchor},on:{"focusin":_vm.onFocusIn,"keydown":[function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"up",38,$event.key,["Up","ArrowUp"])){ return null; }return _vm.openOnArrowKeyPress($event)},function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"down",40,$event.key,["Down","ArrowDown"])){ return null; }return _vm.openOnArrowKeyPress($event)}]}},[_vm._t("input",null,{"inputProps":inputProps,"onInput":_vm.handleDisplayList})],2)]}},{key:"list",fn:function(ref){
20425
20450
  var opened = ref.opened;
20426
20451
  var listProps = ref.listProps;
20427
20452
  var clearHighlightIndex = ref.clearHighlightIndex;
20428
20453
  return [_c('dt-popover',{ref:"popover",attrs:{"open":_vm.isListShown,"hide-on-click":false,"max-height":_vm.maxHeight,"max-width":_vm.maxWidth,"offset":_vm.popoverOffset,"sticky":_vm.popoverSticky,"placement":"bottom-start","initial-focus-element":"none","padding":"none","role":"listbox","external-anchor":_vm.externalAnchor,"content-width":_vm.contentWidth,"content-tabindex":null,"modal":false,"auto-focus":false,"visually-hidden-close-label":_vm.visuallyHiddenCloseLabel,"visually-hidden-close":_vm.visuallyHiddenClose},on:{"update:open":function($event){_vm.isListShown=$event},"opened":function($event){return opened($event, arguments[1]);}},scopedSlots:_vm._u([{key:"headerContent",fn:function(){return [(_vm.$slots.header)?_c('div',{ref:"header"},[_vm._t("header")],2):_vm._e()]},proxy:true},{key:"content",fn:function(){return [_c('div',{ref:"listWrapper",class:[_vm.DROPDOWN_PADDING_CLASSES[_vm.padding], _vm.listClass],on:{"mouseleave":clearHighlightIndex,"focusout":clearHighlightIndex}},[(_vm.loading)?_c('combobox-loading-list',_vm._b({},'combobox-loading-list',listProps,false)):(_vm.emptyList && _vm.emptyStateMessage)?_c('combobox-empty-list',_vm._b({attrs:{"message":_vm.emptyStateMessage}},'combobox-empty-list',listProps,false)):_vm._t("list",null,{"listProps":listProps})],2)]},proxy:true},{key:"footerContent",fn:function(){return [(_vm.$slots.footer)?_c('div',{ref:"footer"},[_vm._t("footer")],2):_vm._e()]},proxy:true}],null,true)})]}}],null,true)},_vm.comboboxListeners))}
20429
- var combobox_with_popovervue_type_template_id_ad3e7dce_staticRenderFns = []
20454
+ var combobox_with_popovervue_type_template_id_294704b9_staticRenderFns = []
20430
20455
 
20431
20456
 
20432
20457
  ;// CONCATENATED MODULE: ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40[0].rules[0].use[1]!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./recipes/comboboxes/combobox_with_popover/combobox_with_popover.vue?vue&type=script&lang=js&
@@ -20533,6 +20558,8 @@ var combobox_with_popovervue_type_template_id_ad3e7dce_staticRenderFns = []
20533
20558
  //
20534
20559
  //
20535
20560
  //
20561
+ //
20562
+
20536
20563
 
20537
20564
 
20538
20565
 
@@ -20699,6 +20726,18 @@ var combobox_with_popovervue_type_template_id_ad3e7dce_staticRenderFns = []
20699
20726
  default: false
20700
20727
  },
20701
20728
 
20729
+ /**
20730
+ * Sets the element to which the popover is going to append to.
20731
+ * @values 'parent', HTMLElement,
20732
+ */
20733
+ appendTo: {
20734
+ type: [HTMLElement, String],
20735
+ default: () => document.body,
20736
+ validator: appendTo => {
20737
+ return POPOVER_APPEND_TO_VALUES.includes(appendTo) || appendTo instanceof HTMLElement;
20738
+ }
20739
+ },
20740
+
20702
20741
  /**
20703
20742
  * Displays the list when the combobox is focused, before the user has typed anything.
20704
20743
  * When this is enabled the list will not close after selection.
@@ -20894,8 +20933,8 @@ var combobox_with_popovervue_type_template_id_ad3e7dce_staticRenderFns = []
20894
20933
  ;
20895
20934
  var combobox_with_popover_component = normalizeComponent(
20896
20935
  combobox_with_popover_combobox_with_popovervue_type_script_lang_js_,
20897
- combobox_with_popovervue_type_template_id_ad3e7dce_render,
20898
- combobox_with_popovervue_type_template_id_ad3e7dce_staticRenderFns,
20936
+ combobox_with_popovervue_type_template_id_294704b9_render,
20937
+ combobox_with_popovervue_type_template_id_294704b9_staticRenderFns,
20899
20938
  false,
20900
20939
  null,
20901
20940
  null,
@@ -20906,11 +20945,11 @@ var combobox_with_popover_component = normalizeComponent(
20906
20945
  /* harmony default export */ const combobox_with_popover = (combobox_with_popover_component.exports);
20907
20946
  ;// CONCATENATED MODULE: ./recipes/comboboxes/combobox_with_popover/index.js
20908
20947
 
20909
- ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue?vue&type=template&id=97461302&
20910
- var combobox_multi_selectvue_type_template_id_97461302_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('dt-recipe-combobox-with-popover',{ref:"comboboxWithPopover",attrs:{"label":_vm.label,"show-list":_vm.showList,"max-height":_vm.listMaxHeight,"popover-offset":_vm.popoverOffset,"has-suggestion-list":_vm.hasSuggestionList,"visually-hidden-close-label":_vm.visuallyHiddenCloseLabel,"visually-hidden-close":_vm.visuallyHiddenClose,"content-width":"anchor"},on:{"select":_vm.onComboboxSelect},scopedSlots:_vm._u([{key:"input",fn:function(ref){
20948
+ ;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue?vue&type=template&id=8a9854ae&
20949
+ var combobox_multi_selectvue_type_template_id_8a9854ae_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('dt-recipe-combobox-with-popover',{ref:"comboboxWithPopover",attrs:{"label":_vm.label,"show-list":_vm.showList,"max-height":_vm.listMaxHeight,"popover-offset":_vm.popoverOffset,"has-suggestion-list":_vm.hasSuggestionList,"visually-hidden-close-label":_vm.visuallyHiddenCloseLabel,"visually-hidden-close":_vm.visuallyHiddenClose,"append-to":_vm.appendTo,"content-width":"anchor"},on:{"select":_vm.onComboboxSelect},scopedSlots:_vm._u([{key:"input",fn:function(ref){
20911
20950
  var onInput = ref.onInput;
20912
- return [_c('span',{ref:"inputSlotWrapper",staticClass:"d-ps-relative d-d-block"},[_c('span',{ref:"chipsWrapper",staticClass:"d-ps-absolute d-mx2"},_vm._l((_vm.selectedItems),function(item){return _c('dt-chip',_vm._g({key:item.id,ref:"chips",refInFor:true,class:['d-mt4', 'd-mx2', 'd-zi-base1'],attrs:{"label-class":['d-chip__label'],"close-button-props":{ ariaLabel: 'close' },"size":_vm.size},on:{"keyup":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"backspace",undefined,$event.key,undefined)){ return null; }return _vm.onChipRemove(item)},"close":function($event){return _vm.onChipRemove(item)}}},_vm.chipListeners),[_vm._v(" "+_vm._s(item)+" ")])}),1),_c('dt-input',_vm._g({ref:"input",staticClass:"d-fl-grow1",attrs:{"aria-label":_vm.label,"label":_vm.labelVisible ? _vm.label : '',"description":_vm.description,"placeholder":_vm.inputPlaceHolder,"show-messages":_vm.showInputMessages,"messages":_vm.inputMessages,"size":_vm.size},on:{"input":onInput},model:{value:(_vm.value),callback:function ($$v) {_vm.value=$$v},expression:"value"}},_vm.inputListeners)),_c('dt-validation-messages',{attrs:{"validation-messages":_vm.maxSelectedMessage,"show-messages":_vm.showValidationMessages}})],1)]}},{key:"header",fn:function(){return [(_vm.$slots.header)?_c('div',{ref:"header"},[_vm._t("header")],2):_vm._e()]},proxy:true},{key:"list",fn:function(){return [_c('div',{ref:"list",on:{"mousedown":function($event){$event.preventDefault();}}},[(!_vm.loading)?_vm._t("list"):_c('div',{staticClass:"d-ta-center d-py16"},[_vm._v(" "+_vm._s(_vm.loadingMessage)+" ")])],2)]},proxy:true},{key:"footer",fn:function(){return [(_vm.$slots.footer)?_c('div',{ref:"footer"},[_vm._t("footer")],2):_vm._e()]},proxy:true}],null,true)})}
20913
- var combobox_multi_selectvue_type_template_id_97461302_staticRenderFns = []
20951
+ return [_c('span',{ref:"inputSlotWrapper",staticClass:"d-ps-relative d-d-block"},[_c('span',{ref:"chipsWrapper",staticClass:"d-ps-absolute d-mx2"},_vm._l((_vm.selectedItems),function(item){return _c('dt-chip',_vm._g({key:item.id,ref:"chips",refInFor:true,class:['d-mt4', 'd-mx2', 'd-zi-base1'],attrs:{"label-class":['d-chip__label'],"close-button-props":{ ariaLabel: 'close' },"size":_vm.CHIP_SIZES[_vm.size]},on:{"keyup":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"backspace",undefined,$event.key,undefined)){ return null; }return _vm.onChipRemove(item)},"close":function($event){return _vm.onChipRemove(item)}}},_vm.chipListeners),[_vm._v(" "+_vm._s(item)+" ")])}),1),_c('dt-input',_vm._g({ref:"input",staticClass:"d-fl-grow1",attrs:{"aria-label":_vm.label,"label":_vm.labelVisible ? _vm.label : '',"description":_vm.description,"placeholder":_vm.inputPlaceHolder,"show-messages":_vm.showInputMessages,"messages":_vm.inputMessages,"size":_vm.size},on:{"input":onInput},model:{value:(_vm.value),callback:function ($$v) {_vm.value=$$v},expression:"value"}},_vm.inputListeners)),_c('dt-validation-messages',{attrs:{"validation-messages":_vm.maxSelectedMessage,"show-messages":_vm.showValidationMessages}})],1)]}},{key:"header",fn:function(){return [(_vm.$slots.header)?_c('div',{ref:"header"},[_vm._t("header")],2):_vm._e()]},proxy:true},{key:"list",fn:function(){return [_c('div',{ref:"list",on:{"mousedown":function($event){$event.preventDefault();}}},[(!_vm.loading)?_vm._t("list"):_c('div',{staticClass:"d-ta-center d-py16"},[_vm._v(" "+_vm._s(_vm.loadingMessage)+" ")])],2)]},proxy:true},{key:"footer",fn:function(){return [(_vm.$slots.footer)?_c('div',{ref:"footer"},[_vm._t("footer")],2):_vm._e()]},proxy:true}],null,true)})}
20952
+ var combobox_multi_selectvue_type_template_id_8a9854ae_staticRenderFns = []
20914
20953
 
20915
20954
 
20916
20955
  ;// CONCATENATED MODULE: ./recipes/comboboxes/combobox_multi_select/combobox_multi_select_story_constants.js
@@ -21010,6 +21049,16 @@ const MULTI_SELECT_SIZES = {
21010
21049
  SMALL: 'sm',
21011
21050
  DEFAULT: 'md'
21012
21051
  };
21052
+ const CHIP_SIZES = {
21053
+ xs: 'xs',
21054
+ sm: 'xs',
21055
+ md: 'sm'
21056
+ };
21057
+ const CHIP_BOTTOM_POSITION = {
21058
+ xs: 4,
21059
+ sm: 5,
21060
+ md: 5
21061
+ };
21013
21062
  ;// CONCATENATED MODULE: ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40[0].rules[0].use[1]!./node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue?vue&type=script&lang=js&
21014
21063
  //
21015
21064
  //
@@ -21116,6 +21165,8 @@ const MULTI_SELECT_SIZES = {
21116
21165
  //
21117
21166
  //
21118
21167
  //
21168
+ //
21169
+
21119
21170
 
21120
21171
 
21121
21172
 
@@ -21177,6 +21228,18 @@ const MULTI_SELECT_SIZES = {
21177
21228
  }
21178
21229
  },
21179
21230
 
21231
+ /**
21232
+ * Sets the element to which the popover is going to append to.
21233
+ * @values 'parent', HTMLElement,
21234
+ */
21235
+ appendTo: {
21236
+ type: [HTMLElement, String],
21237
+ default: () => document.body,
21238
+ validator: appendTo => {
21239
+ return POPOVER_APPEND_TO_VALUES.includes(appendTo) || appendTo instanceof HTMLElement;
21240
+ }
21241
+ },
21242
+
21180
21243
  /**
21181
21244
  * Show input validation message
21182
21245
  */
@@ -21310,7 +21373,9 @@ const MULTI_SELECT_SIZES = {
21310
21373
  popoverOffset: [0, 4],
21311
21374
  showValidationMessages: false,
21312
21375
  initialInputPadding: {},
21313
- resizeWindowObserver: null
21376
+ resizeWindowObserver: null,
21377
+ originalInputSize: null,
21378
+ CHIP_SIZES: CHIP_SIZES
21314
21379
  };
21315
21380
  },
21316
21381
 
@@ -21359,6 +21424,7 @@ const MULTI_SELECT_SIZES = {
21359
21424
  async handler() {
21360
21425
  await this.$nextTick();
21361
21426
  this.setInputPadding();
21427
+ this.setChipsPosition();
21362
21428
  this.setInputMinWidth();
21363
21429
  this.checkMaxSelected();
21364
21430
  }
@@ -21368,24 +21434,36 @@ const MULTI_SELECT_SIZES = {
21368
21434
  async label() {
21369
21435
  await this.$nextTick(); // Adjust the chips position if label changed
21370
21436
 
21371
- this.setChipsTopPosition();
21437
+ this.setChipsPosition();
21372
21438
  },
21373
21439
 
21374
21440
  async description() {
21375
21441
  await this.$nextTick(); // Adjust the chips position if description changed
21376
21442
 
21377
- this.setChipsTopPosition();
21378
- }
21443
+ this.setChipsPosition();
21444
+ },
21445
+
21446
+ size: {
21447
+ async handler() {
21448
+ await this.$nextTick();
21449
+ const input = this.getInput();
21450
+ this.revertInputPadding(input);
21451
+ this.originalInputSize = input.getBoundingClientRect().height;
21452
+ this.setInputPadding();
21453
+ },
21379
21454
 
21455
+ immediate: true
21456
+ }
21380
21457
  },
21381
21458
 
21382
21459
  mounted() {
21383
- this.setChipsTopPosition(); // Recalculate chip position and input padding when resizing window
21460
+ this.setChipsPosition(); // Recalculate chip position and input padding when resizing window
21384
21461
 
21385
21462
  this.resizeWindowObserver = new ResizeObserver(() => {
21386
- this.setChipsTopPosition();
21463
+ this.setChipsPosition();
21387
21464
  this.setInputPadding();
21388
- }).observe(document.body);
21465
+ });
21466
+ this.resizeWindowObserver.observe(document.body);
21389
21467
  },
21390
21468
 
21391
21469
  beforeDestroy() {
@@ -21504,48 +21582,31 @@ const MULTI_SELECT_SIZES = {
21504
21582
  this.closeComboboxList();
21505
21583
  },
21506
21584
 
21507
- setChipsTopPosition() {
21508
- // To place the chips in the input box
21509
- // The chip "top" position should be the same line as the input box
21510
- if (!this.$refs.input) {
21511
- return;
21512
- }
21513
-
21514
- const input = this.getInput();
21515
- if (!input) return;
21516
- const inputSlotWrapper = this.$refs.inputSlotWrapper;
21517
- const top = input.getBoundingClientRect().top - inputSlotWrapper.getBoundingClientRect().top;
21585
+ setChipsPosition() {
21518
21586
  const chipsWrapper = this.$refs.chipsWrapper;
21519
- chipsWrapper.style.top = top + 'px';
21587
+ chipsWrapper.style.bottom = `${CHIP_BOTTOM_POSITION[this.size]}px`;
21520
21588
  },
21521
21589
 
21522
21590
  setInputPadding() {
21523
21591
  const lastChip = this.getLastChip();
21524
21592
  const input = this.getInput();
21593
+ const chipsWrapper = this.$refs.chipsWrapper;
21525
21594
  if (!input) return;
21526
-
21527
- if (!lastChip) {
21528
- // Revert padding if no chip
21529
- this.revertInputPadding(input);
21530
- return;
21531
- } // Get the position of the last chip
21595
+ this.revertInputPadding(input);
21596
+ this.popoverOffset = [0, 4];
21597
+ if (!lastChip) return; // Get the position of the last chip
21532
21598
  // The input cursor should be the same "top" as that chip and next besides it
21533
21599
 
21534
-
21535
21600
  const left = lastChip.offsetLeft + this.getFullWidth(lastChip);
21536
- input.style.paddingLeft = left + 'px'; // Chip has vertical margin. We add buffer to top center the input text
21601
+ input.style.paddingLeft = left + 'px'; // Get the chip size minus the 4px padding
21537
21602
 
21538
- const top = lastChip.offsetTop + 3;
21539
- input.style.paddingTop = top + 'px'; // TODO: refresh the tippy.js instance in the popover
21540
- // If the new chip goes to the next line and the input box expands,
21541
- // move the popover down to the next line. Same when chips are removed
21603
+ const chipsSize = chipsWrapper.getBoundingClientRect().height - 4; // Get lastChip offsetTop plus 2px of the input padding.
21542
21604
 
21543
- this.popoverOffset = [0, 4];
21544
- },
21605
+ const top = lastChip.offsetTop + 2; // Add padding to Top only if the chips need more space
21545
21606
 
21546
- getFullWidth(el) {
21547
- const styles = window.getComputedStyle(el);
21548
- return el.offsetWidth + parseInt(styles.marginLeft) + parseInt(styles.marginRight);
21607
+ if (chipsSize > this.originalInputSize) {
21608
+ input.style.paddingTop = `${top}px`;
21609
+ }
21549
21610
  },
21550
21611
 
21551
21612
  revertInputPadding(input) {
@@ -21554,6 +21615,11 @@ const MULTI_SELECT_SIZES = {
21554
21615
  input.style.paddingBottom = '';
21555
21616
  },
21556
21617
 
21618
+ getFullWidth(el) {
21619
+ const styles = window.getComputedStyle(el);
21620
+ return el.offsetWidth + parseInt(styles.marginLeft) + parseInt(styles.marginRight);
21621
+ },
21622
+
21557
21623
  setInputMinWidth() {
21558
21624
  // Ensure the width of the input is "slightly bigger" than the width of a single chip
21559
21625
  const firstChip = this.getFirstChip();
@@ -21593,8 +21659,8 @@ const MULTI_SELECT_SIZES = {
21593
21659
  ;
21594
21660
  var combobox_multi_select_component = normalizeComponent(
21595
21661
  combobox_multi_select_combobox_multi_selectvue_type_script_lang_js_,
21596
- combobox_multi_selectvue_type_template_id_97461302_render,
21597
- combobox_multi_selectvue_type_template_id_97461302_staticRenderFns,
21662
+ combobox_multi_selectvue_type_template_id_8a9854ae_render,
21663
+ combobox_multi_selectvue_type_template_id_8a9854ae_staticRenderFns,
21598
21664
  false,
21599
21665
  null,
21600
21666
  null,