carbon-components-angular 5.57.3 → 5.57.5
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/contained-list/contained-list.component.d.ts +5 -1
- package/docs/documentation/components/ContainedList.html +49 -15
- package/docs/documentation/components/Dropdown.html +119 -121
- package/docs/documentation/coverage.html +3 -3
- package/docs/documentation/js/search/search_index.js +2 -2
- package/docs/documentation/modules/ComboBoxModule/dependencies.svg +4 -4
- package/docs/documentation/modules/ComboBoxModule.html +4 -4
- package/docs/documentation/modules/DatePickerInputModule/dependencies.svg +41 -37
- package/docs/documentation/modules/DatePickerInputModule.html +41 -37
- package/docs/documentation/modules/DialogModule/dependencies.svg +34 -34
- package/docs/documentation/modules/DialogModule.html +34 -34
- package/docs/documentation/modules/FileUploaderModule/dependencies.svg +36 -36
- package/docs/documentation/modules/FileUploaderModule.html +36 -36
- package/docs/documentation/modules/NumberModule/dependencies.svg +4 -4
- package/docs/documentation/modules/NumberModule.html +4 -4
- package/docs/documentation/modules/RadioModule/dependencies.svg +48 -48
- package/docs/documentation/modules/RadioModule.html +48 -48
- package/docs/documentation/modules/SelectModule/dependencies.svg +43 -43
- package/docs/documentation/modules/SelectModule.html +43 -43
- package/docs/documentation/modules/SliderModule/dependencies.svg +4 -4
- package/docs/documentation/modules/SliderModule.html +4 -4
- package/docs/documentation/modules/TabsModule/dependencies.svg +69 -69
- package/docs/documentation/modules/TabsModule.html +69 -69
- package/docs/documentation/modules/TagModule/dependencies.svg +37 -37
- package/docs/documentation/modules/TagModule.html +37 -37
- package/docs/documentation/modules/ThemeModule/dependencies.svg +14 -14
- package/docs/documentation/modules/ThemeModule.html +14 -14
- package/docs/documentation/modules/TilesModule/dependencies.svg +91 -91
- package/docs/documentation/modules/TilesModule.html +91 -91
- package/docs/documentation/modules/TimePickerModule/dependencies.svg +18 -18
- package/docs/documentation/modules/TimePickerModule.html +18 -18
- package/docs/documentation/modules/TimePickerSelectModule/dependencies.svg +23 -23
- package/docs/documentation/modules/TimePickerSelectModule.html +23 -23
- package/docs/documentation/modules/ToggleModule/dependencies.svg +6 -6
- package/docs/documentation/modules/ToggleModule.html +6 -6
- package/docs/documentation/modules/ToggletipModule/dependencies.svg +4 -4
- package/docs/documentation/modules/ToggletipModule.html +4 -4
- package/docs/documentation/modules/TooltipModule/dependencies.svg +29 -29
- package/docs/documentation/modules/TooltipModule.html +29 -29
- package/docs/documentation/modules/TreeviewModule/dependencies.svg +30 -30
- package/docs/documentation/modules/TreeviewModule.html +30 -30
- package/docs/documentation/modules/UIShellModule/dependencies.svg +4 -4
- package/docs/documentation/modules/UIShellModule.html +4 -4
- package/docs/documentation.json +179 -169
- package/docs/storybook/3224.9801f536.iframe.bundle.js +1 -0
- package/docs/storybook/contained-list-contained-list-stories.b7913db8.iframe.bundle.js +1 -0
- package/docs/storybook/iframe.html +2 -2
- package/docs/storybook/main.575135b9.iframe.bundle.js +1 -0
- package/docs/storybook/project.json +1 -1
- package/docs/storybook/{runtime~main.9e428f42.iframe.bundle.js → runtime~main.d377732d.iframe.bundle.js} +1 -1
- package/esm2020/contained-list/contained-list.component.mjs +6 -4
- package/esm2020/dropdown/dropdown.component.mjs +1 -3
- package/fesm2015/carbon-components-angular-contained-list.mjs +5 -3
- package/fesm2015/carbon-components-angular-contained-list.mjs.map +1 -1
- package/fesm2015/carbon-components-angular-dropdown.mjs +0 -2
- package/fesm2015/carbon-components-angular-dropdown.mjs.map +1 -1
- package/fesm2020/carbon-components-angular-contained-list.mjs +5 -3
- package/fesm2020/carbon-components-angular-contained-list.mjs.map +1 -1
- package/fesm2020/carbon-components-angular-dropdown.mjs +0 -2
- package/fesm2020/carbon-components-angular-dropdown.mjs.map +1 -1
- package/package.json +1 -1
- package/docs/storybook/3224.9896492c.iframe.bundle.js +0 -1
- package/docs/storybook/contained-list-contained-list-stories.b87addfb.iframe.bundle.js +0 -1
- package/docs/storybook/main.23328ef9.iframe.bundle.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkcarbon_components_angular=self.webpackChunkcarbon_components_angular||[]).push([[3224],{"./src/dropdown/index.ts":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{jq:()=>AbstractDropdownView,Lt:()=>Dropdown,kW:()=>DropdownModule,Vn:()=>DropdownService});var tslib_es6=__webpack_require__("./node_modules/tslib/tslib.es6.js"),core=__webpack_require__("./node_modules/@angular/core/fesm2020/core.mjs"),fesm2020_forms=__webpack_require__("./node_modules/@angular/forms/fesm2020/forms.mjs"),Subscription=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/Subscription.js"),of=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/observable/of.js");let AbstractDropdownView=class AbstractDropdownView{constructor(){this.type="single",this.size="md"}set items(value){}get items(){}getNextItem(){}hasNextElement(){}getNextElement(){}getPrevItem(){}hasPrevElement(){}getPrevElement(){}getSelected(){}getCurrentItem(){}getCurrentElement(){}getListItems(){}propagateSelected(value){}filterBy(value){}initFocus(){}onItemsReady(subcription){}reorderSelected(moveFocus){}};AbstractDropdownView.propDecorators={items:[{type:core.Input}],select:[{type:core.Output}],blurIntent:[{type:core.Output}]},AbstractDropdownView=(0,tslib_es6.gn)([(0,core.Directive)({selector:"[cdsAbstractDropdownView], [ibmAbstractDropdownView]"})],AbstractDropdownView);var i18n=__webpack_require__("./src/i18n/index.ts"),placeholder=__webpack_require__("./src/placeholder/index.ts"),utils_position=__webpack_require__("./node_modules/@carbon/utils-position/index.js"),utils=__webpack_require__("./src/utils/index.ts");const defaultOffset={top:0,left:0};let DropdownService=class DropdownService{constructor(placeholderService,animationFrameService){this.placeholderService=placeholderService,this.animationFrameService=animationFrameService,this.animationFrameSubscription=new Subscription.w0,this._offset=defaultOffset}set offset(value){this._offset=Object.assign({},defaultOffset,value)}get offset(){return this._offset}appendToBody(parentRef,menuRef,classList){menuRef.style.display="block";const dropdownWrapper=document.createElement("div");return dropdownWrapper.className=`dropdown ${classList}`,dropdownWrapper.style.width=parentRef.offsetWidth+"px",dropdownWrapper.style.position="absolute",dropdownWrapper.appendChild(menuRef),this.placeholderService.hasPlaceholderRef()?this.placeholderService.appendElement(dropdownWrapper):document.body.appendChild(dropdownWrapper),this.menuInstance=dropdownWrapper,this.animationFrameSubscription=this.animationFrameService.tick.subscribe((()=>{this.positionDropdown(parentRef,dropdownWrapper)})),this.positionDropdown(parentRef,dropdownWrapper),dropdownWrapper}appendToDropdown(hostRef){if(!this.menuInstance)return;const instance=this.menuInstance,menu=instance.firstElementChild;return this.menuInstance=null,menu.style.display="none",hostRef.appendChild(menu),this.animationFrameSubscription.unsubscribe(),this.placeholderService.hasPlaceholderRef()&&this.placeholderService.hasElement(instance)?this.placeholderService.removeElement(instance):document.body.contains(instance)&&document.body.removeChild(instance),instance}updatePosition(parentRef){this.positionDropdown(parentRef,this.menuInstance)}ngOnDestroy(){this.animationFrameSubscription.unsubscribe()}positionDropdown(parentRef,menuRef){if(!menuRef)return;let leftOffset=0;const boxMenu=menuRef.querySelector(".cds--list-box__menu");if(boxMenu)if(parentRef.getBoundingClientRect().left!==boxMenu.getBoundingClientRect().left){parentRef.getBoundingClientRect().left-boxMenu.getBoundingClientRect().left+boxMenu.getBoundingClientRect().right>(window.innerWidth||document.documentElement.clientWidth)&&(leftOffset=parentRef.offsetWidth-boxMenu.offsetWidth)}else boxMenu.getBoundingClientRect().right>(window.innerWidth||document.documentElement.clientWidth)&&(leftOffset=parentRef.offsetWidth-boxMenu.offsetWidth);const closestMenuWithPos=(0,utils._K)("position",["relative","fixed","absolute"],menuRef.parentElement),topPos=closestMenuWithPos?-1*closestMenuWithPos.getBoundingClientRect().top:this.offset.top,leftPos=closestMenuWithPos?-1*closestMenuWithPos.getBoundingClientRect().left:this.offset.left+leftOffset;let pos=utils_position.FK.findAbsolute(parentRef,menuRef,"bottom");pos=utils_position.FK.addOffset(pos,topPos,leftPos),utils_position.FK.setElement(menuRef,pos)}};DropdownService.ctorParameters=()=>[{type:placeholder.Q_},{type:utils.NV}],DropdownService=(0,tslib_es6.gn)([(0,core.Injectable)()],DropdownService);let Dropdown=class Dropdown{constructor(elementRef,i18n,dropdownService,elementService){this.elementRef=elementRef,this.i18n=i18n,this.dropdownService=dropdownService,this.elementService=elementService,this.id="dropdown-"+Dropdown.dropdownCount++,this.hideLabel=!1,this.placeholder="",this.displayValue="",this.clearText=this.i18n.get().DROPDOWN.CLEAR,this.size="md",this.type="single",this.theme="dark",this.disabled=!1,this.readonly=!1,this.skeleton=!1,this.inline=!1,this.disableArrowKeys=!1,this.invalid=!1,this.warn=!1,this.appendInline=null,this.selectionFeedback="top-after-reopen",this.menuButtonLabel=this.i18n.get().DROPDOWN.OPEN,this.selectedLabel=this.i18n.get().DROPDOWN.SELECTED,this.selected=new core.EventEmitter,this.onClose=new core.EventEmitter,this.close=new core.EventEmitter,this.hostClass=!0,this.hostWrapperClass=!0,this.fluid=!1,this.menuIsClosed=!0,this._dropUp=!1,this.noop=this._noop.bind(this),this.outsideClick=this._outsideClick.bind(this),this.outsideKey=this._outsideKey.bind(this),this.keyboardNav=this._keyboardNav.bind(this),this.visibilitySubscription=new Subscription.w0,this.onTouchedCallback=this._noop,this._isFocused=!1,this._writtenValue=[],this.propagateChange=_=>{}}get fluidInvalidClass(){return this.invalid&&this.fluid}get fluidFocusClass(){return this.fluid&&this._isFocused&&this.menuIsClosed}get writtenValue(){return this._writtenValue}set writtenValue(val){val&&0===val.length&&this.clearSelected(),this._writtenValue=val}ngOnInit(){this.view&&(this.view.type=this.type)}ngAfterContentInit(){if(!this.view)return;(this.writtenValue&&this.writtenValue.length||"number"==typeof this.writtenValue)&&this.writeValue(this.writtenValue),this.view.type=this.type,this.view.size=this.size;const isUpdate=event=>event&&event.isUpdate;this.view.select.subscribe((event=>{if("single"!==this.type||isUpdate(event)||Array.isArray(event)||(this.closeMenu(),event.item&&event.item.selected?this.itemValueKey?this.propagateChange(event.item[this.itemValueKey]):this.propagateChange(event.item):this.propagateChange(null)),"multi"===this.type&&!isUpdate(event))if(this.itemValueKey&&this.view.getSelected()){const values=this.view.getSelected().map((item=>item[this.itemValueKey]));this.propagateChange(values)}else this.propagateChange(this.view.getSelected());isUpdate(event)||(this.checkForReorder(),this.selected.emit(event))}))}ngAfterViewInit(){null===this.appendInline&&(0,utils.OQ)(this.elementRef.nativeElement)?this.appendInline=!1:null===this.appendInline&&(this.appendInline=!0),this.checkForReorder()}ngOnDestroy(){this.appendInline||this._appendToDropdown()}writeValue(value){this.writtenValue=value,this.view.onItemsReady((()=>{if(value)if("single"===this.type)if(this.itemValueKey){const newValue=Object.assign({},this.view.getListItems().find((item=>item[this.itemValueKey]===value)));newValue.selected=!0,this.view.propagateSelected([newValue])}else this.view.propagateSelected([value]);else if(this.itemValueKey){let newValues=[];for(const v of value)for(const item of this.view.getListItems())item[this.itemValueKey]===v&&newValues.push(Object.assign({},item,{selected:!0}));this.view.propagateSelected(newValues)}else this.view.propagateSelected(value);else this.view.propagateSelected([value]);this.checkForReorder()}))}onBlur(){this.onTouchedCallback()}registerOnChange(fn){this.propagateChange=fn}registerOnTouched(fn){this.onTouchedCallback=fn}setDisabledState(isDisabled){this.disabled=isDisabled}onKeyDown(event){if(!this.readonly){if("Escape"!==event.key||this.menuIsClosed||event.stopImmediatePropagation(),"Escape"===event.key)event.preventDefault(),this.closeMenu(),this.dropdownButton.nativeElement.focus();else if(this.menuIsClosed&&(" "===event.key||"ArrowDown"===event.key||"ArrowUp"===event.key)){if(this.disableArrowKeys&&("ArrowDown"===event.key||"ArrowUp"===event.key))return;event.preventDefault(),this.openMenu()}!this.menuIsClosed&&"Tab"===event.key&&this.dropdownMenu.nativeElement.contains(event.target)&&this.closeMenu(),!this.menuIsClosed&&"Tab"===event.key&&event.shiftKey&&this.closeMenu(),"multi"!==this.type&&this.menuIsClosed&&this.closedDropdownNavigation(event)}}closedDropdownNavigation(event){if("ArrowDown"===event.key){event.preventDefault(),this.view.getCurrentItem().selected=!1;let item=this.view.getNextItem();item&&(item.selected=!0)}else if("ArrowUp"===event.key){event.preventDefault(),this.view.getCurrentItem().selected=!1;let item=this.view.getPrevItem();item&&(item.selected=!0)}}getDisplayStringValue(){if(!this.view||this.skeleton)return;let selected=this.view.getSelected();return!selected.length||this.displayValue&&this.isRenderString()?selected.length&&this.isRenderString()?(0,of.of)(this.displayValue):(0,of.of)(this.placeholder):"multi"===this.type?(0,of.of)(this.placeholder):(0,of.of)(selected[0].content)}isRenderString(){return"string"==typeof this.displayValue}getRenderTemplateContext(){if(!this.view)return;let selected=this.view.getSelected();return"multi"===this.type?{items:selected}:selected&&selected.length>0?{item:selected[0]}:{}}getSelectedCount(){if(this.view.getSelected())return this.view.getSelected().length}clearSelected(){if(!this.disabled&&0!==this.getSelectedCount()){for(const item of this.view.getListItems())item.selected=!1;this.selected.emit([]),this.propagateChange([])}}valueSelected(){return!!this.view.getSelected()}_noop(){}_outsideClick(event){this.elementRef.nativeElement.contains(event.target)||this.dropdownMenu.nativeElement.contains(event.target)||this.closeMenu()}_outsideKey(event){!this.menuIsClosed&&"Tab"===event.key&&this.dropdownMenu.nativeElement.contains(event.target)&&this.closeMenu()}_keyboardNav(event){"Escape"!==event.key||this.menuIsClosed||event.stopImmediatePropagation(),"Escape"===event.key?(event.preventDefault(),this.closeMenu(),this.dropdownButton.nativeElement.focus()):this.menuIsClosed||"Tab"!==event.key||(this.dropdownButton.nativeElement.focus(),this.dropdownButton.nativeElement.dispatchEvent(new KeyboardEvent("keydown",{bubbles:!0,cancelable:!0,key:"Tab"})),this.closeMenu())}_appendToDropdown(){this.dropdownService.appendToDropdown(this.elementRef.nativeElement),this.dropdownMenu.nativeElement.removeEventListener("keydown",this.keyboardNav,!0)}_appendToBody(){const lightClass="light"===this.theme?" cds--list-box--light":"",expandedClass=this.menuIsClosed?"":" cds--list-box--expanded";this.dropdownService.appendToBody(this.dropdownButton.nativeElement,this.dropdownMenu.nativeElement,`${this.elementRef.nativeElement.className}${lightClass}${expandedClass}`),this.dropdownMenu.nativeElement.addEventListener("keydown",this.keyboardNav,!0)}_shouldDropUp(){const menu=this.dropdownMenu&&this.dropdownMenu.nativeElement.querySelector(".cds--list-box__menu"),menuRect=menu&&menu.getBoundingClientRect();if(menu&&menuRect){return(0,utils.O3)(menu).reduce(((shouldDropUp,parent)=>{const parentRect=parent.getBoundingClientRect(),isBelowParent=!(menuRect.bottom<=parentRect.bottom);return shouldDropUp||isBelowParent}),!1)}return!1}openMenu(){if(0!==this.view.getListItems().length){if(this._dropUp=!1,this.menuIsClosed=!1,!this.appendInline){const target=this.dropdownButton.nativeElement,parent=this.elementRef.nativeElement;this.visibilitySubscription=this.elementService.visibility(target,parent).subscribe((value=>{value.visible||this.closeMenu()})),this._appendToBody()}setTimeout((()=>{null!==this.dropUp&&void 0!==this.dropUp||(this._dropUp=this._shouldDropUp())}),0),document.body.firstElementChild.addEventListener("click",this.noop,!0),document.body.firstElementChild.addEventListener("keydown",this.noop,!0),document.addEventListener("click",this.outsideClick,!0),document.addEventListener("keydown",this.outsideKey,!0),setTimeout((()=>this.view.initFocus()),0)}}closeMenu(){this.menuIsClosed||(this.menuIsClosed=!0,this.checkForReorder(),this.onClose.emit(),this.close.emit(),this.dropdownButton.nativeElement.focus(),this.view.disableScroll&&this.view.disableScroll(),this.appendInline||(this.visibilitySubscription.unsubscribe(),this._appendToDropdown()),document.body.firstElementChild.removeEventListener("click",this.noop,!0),document.body.firstElementChild.removeEventListener("keydown",this.noop,!0),document.removeEventListener("click",this.outsideClick,!0),document.removeEventListener("keydown",this.outsideKey,!0))}toggleMenu(){this.menuIsClosed?this.openMenu():this.closeMenu()}isTemplate(value){return value instanceof core.TemplateRef}handleFocus(event){this._isFocused="focus"===event.type,"blur"===event.type&&this.onBlur()}checkForReorder(){const topAfterReopen=this.menuIsClosed&&"top-after-reopen"===this.selectionFeedback;"multi"!==this.type||!topAfterReopen&&"top"!==this.selectionFeedback||this.view.reorderSelected()}};Dropdown.dropdownCount=0,Dropdown.ctorParameters=()=>[{type:core.ElementRef},{type:i18n.oc},{type:DropdownService},{type:utils.d2}],Dropdown.propDecorators={fluidInvalidClass:[{type:core.HostBinding,args:["class.cds--list-box__wrapper--fluid--invalid"]}],fluidFocusClass:[{type:core.HostBinding,args:["class.cds--list-box__wrapper--fluid--focus"]}],id:[{type:core.Input}],label:[{type:core.Input}],hideLabel:[{type:core.Input}],helperText:[{type:core.Input}],placeholder:[{type:core.Input}],displayValue:[{type:core.Input}],clearText:[{type:core.Input}],size:[{type:core.Input}],type:[{type:core.Input}],theme:[{type:core.Input}],disabled:[{type:core.Input}],readonly:[{type:core.Input}],skeleton:[{type:core.Input}],inline:[{type:core.Input}],disableArrowKeys:[{type:core.Input}],invalid:[{type:core.Input}],invalidText:[{type:core.Input}],warn:[{type:core.Input}],warnText:[{type:core.Input}],appendInline:[{type:core.Input}],scrollableContainer:[{type:core.Input}],itemValueKey:[{type:core.Input}],selectionFeedback:[{type:core.Input}],menuButtonLabel:[{type:core.Input}],selectedLabel:[{type:core.Input}],dropUp:[{type:core.Input}],selected:[{type:core.Output}],onClose:[{type:core.Output}],close:[{type:core.Output}],view:[{type:core.ContentChild,args:[AbstractDropdownView,{static:!0}]}],dropdownButton:[{type:core.ViewChild,args:["dropdownButton",{static:!0}]}],dropdownMenu:[{type:core.ViewChild,args:["dropdownMenu",{static:!0}]}],hostClass:[{type:core.HostBinding,args:["class.cds--dropdown__wrapper"]}],hostWrapperClass:[{type:core.HostBinding,args:["class.cds--list-box__wrapper"]}],fluid:[{type:core.HostBinding,args:["class.cds--list-box__wrapper--fluid"]},{type:core.Input}],onKeyDown:[{type:core.HostListener,args:["keydown",["$event"]]}]},Dropdown=(0,tslib_es6.gn)([(0,core.Component)({selector:"cds-dropdown, ibm-dropdown",template:'\n\t<label\n\t\t*ngIf="label && !skeleton"\n\t\t[for]="id"\n\t\tclass="cds--label"\n\t\t[ngClass]="{\n\t\t\t\'cds--label--disabled\': disabled,\n\t\t\t\'cds--visually-hidden\': hideLabel\n\t\t}">\n\t\t<ng-container *ngIf="!isTemplate(label)">{{label}}</ng-container>\n\t\t<ng-template *ngIf="isTemplate(label)" [ngTemplateOutlet]="label"></ng-template>\n\t</label>\n\t<div\n\t\tclass="cds--list-box"\n\t\t[ngClass]="{\n\t\t\t\'cds--dropdown\': type !== \'multi\' && !(skeleton && fluid),\n\t\t\t\'cds--multiselect\': type === \'multi\',\n\t\t\t\'cds--multi-select--selected\': type === \'multi\' && getSelectedCount() > 0,\n\t\t\t\'cds--dropdown--light\': theme === \'light\',\n\t\t\t\'cds--list-box--light\': theme === \'light\',\n\t\t\t\'cds--list-box--inline\': inline,\n\t\t\t\'cds--skeleton\': skeleton,\n\t\t\t\'cds--dropdown--disabled cds--list-box--disabled\': disabled,\n\t\t\t\'cds--dropdown--readonly\': readonly,\n\t\t\t\'cds--dropdown--invalid\': invalid,\n\t\t\t\'cds--dropdown--warning cds--list-box--warning\': warn,\n\t\t\t\'cds--dropdown--sm cds--list-box--sm\': size === \'sm\',\n\t\t\t\'cds--dropdown--md cds--list-box--md\': size === \'md\',\n\t\t\t\'cds--dropdown--lg cds--list-box--lg\': size === \'lg\',\n\t\t\t\'cds--list-box--expanded\': !menuIsClosed,\n\t\t\t\'cds--list-box--invalid\': invalid\n\t\t}"\n\t\t[attr.data-invalid]="invalid ? true : null">\n\t\t<div *ngIf="skeleton && fluid" class="cds--list-box__label"></div>\n\t\t<button\n\t\t\t#dropdownButton\n\t\t\t[id]="id"\n\t\t\ttype="button"\n\t\t\tclass="cds--list-box__field"\n\t\t\t[ngClass]="{\'a\': !menuIsClosed}"\n\t\t\t[attr.aria-expanded]="!menuIsClosed"\n\t\t\t[attr.aria-disabled]="disabled"\n\t\t\t[attr.aria-readonly]="readonly"\n\t\t\taria-haspopup="listbox"\n\t\t\t(click)="disabled || readonly ? $event.stopPropagation() : toggleMenu()"\n\t\t\t(focus)="fluid ? handleFocus($event) : null"\n\t\t\t(blur)="fluid ? handleFocus($event) : onBlur()"\n\t\t\t[attr.disabled]="disabled ? true : null">\n\t\t\t<div\n\t\t\t\t(click)="clearSelected()"\n\t\t\t\t(keydown.enter)="clearSelected()"\n\t\t\t\t*ngIf="type === \'multi\' && getSelectedCount() > 0"\n\t\t\t\tclass="cds--list-box__selection cds--tag--filter cds--list-box__selection--multi"\n\t\t\t\ttabindex="0"\n\t\t\t\t[title]="clearText">\n\t\t\t\t{{getSelectedCount()}}\n\t\t\t\t<svg\n\t\t\t\t\tfocusable="false"\n\t\t\t\t\tpreserveAspectRatio="xMidYMid meet"\n\t\t\t\t\tstyle="will-change: transform;"\n\t\t\t\t\trole="img"\n\t\t\t\t\txmlns="http://www.w3.org/2000/svg"\n\t\t\t\t\twidth="16"\n\t\t\t\t\theight="16"\n\t\t\t\t\tviewBox="0 0 16 16"\n\t\t\t\t\taria-hidden="true">\n\t\t\t\t\t<path d="M12 4.7l-.7-.7L8 7.3 4.7 4l-.7.7L7.3 8 4 11.3l.7.7L8 8.7l3.3 3.3.7-.7L8.7 8z"></path>\n\t\t\t\t</svg>\n\t\t\t</div>\n\t\t\t<span *ngIf="isRenderString()" class="cds--list-box__label">{{getDisplayStringValue() | async}}</span>\n\t\t\t<ng-template\n\t\t\t\t*ngIf="!isRenderString()"\n\t\t\t\t[ngTemplateOutletContext]="getRenderTemplateContext()"\n\t\t\t\t[ngTemplateOutlet]="displayValue">\n\t\t\t</ng-template>\n\t\t\t<span class="cds--list-box__menu-icon">\n\t\t\t\t<svg\n\t\t\t\t\t*ngIf="!skeleton"\n\t\t\t\t\tcdsIcon="chevron--down"\n\t\t\t\t\tsize="16"\n\t\t\t\t\t[attr.aria-label]="menuButtonLabel"\n\t\t\t\t\t[ngClass]="{\'cds--list-box__menu-icon--open\': !menuIsClosed }">\n\t\t\t\t</svg>\n\t\t\t</span>\n\t\t</button>\n\t\t<svg\n\t\t\t*ngIf="invalid"\n\t\t\tclass="cds--list-box__invalid-icon"\n\t\t\tcdsIcon="warning--filled"\n\t\t\tsize="16">\n\t\t</svg>\n\t\t<svg\n\t\t\t*ngIf="!invalid && warn"\n\t\t\tcdsIcon="warning--alt--filled"\n\t\t\tsize="16"\n\t\t\tclass="cds--list-box__invalid-icon cds--list-box__invalid-icon--warning">\n\t\t</svg>\n\t\t<div\n\t\t\t#dropdownMenu\n\t\t\t[ngClass]="{\n\t\t\t\t\'cds--list-box--up\': this.dropUp !== null && this.dropUp !== undefined ? dropUp : _dropUp\n\t\t\t}">\n\t\t\t<ng-content *ngIf="!menuIsClosed"></ng-content>\n\t\t</div>\n\t</div>\n\t<hr *ngIf="fluid" class="cds--list-box__divider" />\n\t<div\n\t\t*ngIf="helperText && !invalid && !warn && !skeleton && !fluid"\n\t\tclass="cds--form__helper-text"\n\t\t[ngClass]="{\n\t\t\t\'cds--form__helper-text--disabled\': disabled\n\t\t}">\n\t\t<ng-container *ngIf="!isTemplate(helperText)">{{helperText}}</ng-container>\n\t\t<ng-template *ngIf="isTemplate(helperText)" [ngTemplateOutlet]="helperText"></ng-template>\n\t</div>\n\t<div *ngIf="invalid" class="cds--form-requirement">\n\t\t<ng-container *ngIf="!isTemplate(invalidText)">{{ invalidText }}</ng-container>\n\t\t<ng-template *ngIf="isTemplate(invalidText)" [ngTemplateOutlet]="invalidText"></ng-template>\n\t</div>\n\t<div *ngIf="!invalid && warn" class="cds--form-requirement">\n\t\t<ng-container *ngIf="!isTemplate(warnText)">{{warnText}}</ng-container>\n\t\t<ng-template *ngIf="isTemplate(warnText)" [ngTemplateOutlet]="warnText"></ng-template>\n\t</div>\n\t',providers:[{provide:fesm2020_forms.JU,useExisting:Dropdown,multi:!0}]})],Dropdown);var isObservable=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/util/isObservable.js"),Observable=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/Observable.js"),first=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/operators/first.js"),fromEvent=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/observable/fromEvent.js"),debounceTime=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/operators/debounceTime.js"),map=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/operators/map.js"),filter=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/operators/filter.js");let DropdownList=class DropdownList{constructor(elementRef,i18n,appRef){this.elementRef=elementRef,this.i18n=i18n,this.appRef=appRef,this.ariaLabel=this.i18n.get().DROPDOWN_LIST.LABEL,this.listTpl=null,this.select=new core.EventEmitter,this.scroll=new core.EventEmitter,this.blurIntent=new core.EventEmitter,this.type="single",this.showTitles=!0,this.size="md",this.listId="listbox-"+DropdownList.listCount++,this.highlightedItem=null,this.displayItems=[],this.index=-1,this._items=[]}set items(value){(0,isObservable.b)(value)?(this._itemsSubscription&&this._itemsSubscription.unsubscribe(),this._itemsReady=new Observable.y((observer=>{this._itemsSubscription=value.subscribe((v=>{this.updateList(v),observer.next(!0),observer.complete()}))})),this.onItemsReady(null)):this.updateList(value),this._originalItems=value}get items(){return this._originalItems}ngAfterViewInit(){this.index=this.getListItems().findIndex((item=>item.selected)),this.setupFocusObservable(),setTimeout((()=>{this.doEmitSelect(!0)}))}ngOnDestroy(){this.focusJump&&this.focusJump.unsubscribe(),this._itemsSubscription&&this._itemsSubscription.unsubscribe()}doEmitSelect(isUpdate=!0){if("single"===this.type)this.select.emit({item:this._items.find((item=>item.selected)),isUpdate});else{const selected=this.getSelected()||[];selected.isUpdate=isUpdate,this.select.emit(selected)}}getItemId(index){return`${this.listId}-${index}`}updateList(items){this._items=items.map((item=>Object.assign({},item))),this.displayItems=this._items,this.updateIndex(),this.setupFocusObservable(),this.doEmitSelect()}filterBy(query=""){query?(this.displayItems=this.getListItems().filter((item=>item.content.toLowerCase().includes(query.toLowerCase()))),this.displayItems&&(this.index=0)):this.displayItems=this.getListItems(),this.updateIndex()}setupFocusObservable(){if(!this.list)return;this.focusJump&&this.focusJump.unsubscribe();let elList=Array.from(this.list.nativeElement.querySelectorAll("li"));this.focusJump=function watchFocusJump(target,elements){return(0,fromEvent.R)(target,"keydown").pipe((0,debounceTime.b)(150),(0,map.U)((ev=>{let el=elements.find((itemEl=>itemEl.textContent.trim().toLowerCase().startsWith(ev.key)));if(el)return el})),(0,filter.h)((el=>!!el)))}(this.list.nativeElement,elList).subscribe((el=>{el.focus()}))}getNextItem(){return this.index<this.displayItems.length-1&&this.index++,this.displayItems[this.index]}hasNextElement(){return this.index<this.displayItems.length-1&&(!(this.index===this.displayItems.length-2)||!this.displayItems[this.index+1].disabled)}getNextElement(){const elemList=this.listElementList?this.listElementList.toArray():[];if(!elemList.length)return null;for(let i=this.index+1;i<elemList.length;i++)if(!this.displayItems[i].disabled)return this.index=i,elemList[i].nativeElement;return elemList[this.index]?.nativeElement}getPrevItem(){return this.index>0&&this.index--,this.displayItems[this.index]}hasPrevElement(){return this.index>0&&(!(1===this.index)||!this.displayItems[0].disabled)}getPrevElement(){const elemList=this.listElementList?this.listElementList.toArray():[];if(!elemList.length)return null;for(let i=this.index-1;i<this.index&&i>=0;i--)if(!this.displayItems[i].disabled)return this.index=i,elemList[i].nativeElement;return elemList[this.index].nativeElement}getCurrentItem(){return this.index<0?this.displayItems[0]:this.displayItems[this.index]}getCurrentElement(){return this.index<0?this.listElementList.first.nativeElement:this.listElementList.toArray()[this.index].nativeElement}getListItems(){return this._items}getSelected(){let selected=this.getListItems().filter((item=>item.selected));return 0===selected.length?[]:selected}propagateSelected(value){Array.isArray(value)||console.error(`${this.constructor.name}.propagateSelected expects an Array<ListItem>, got ${JSON.stringify(value)}`),this.onItemsReady((()=>{const selectedNewItems=[];for(let newItem of value)if(newItem&&newItem.selected){let tempNewItem=Object.assign({},newItem);delete tempNewItem.selected,tempNewItem=JSON.stringify(tempNewItem),selectedNewItems.push(tempNewItem)}for(let oldItem of this.getListItems()){if(0===selectedNewItems.length){oldItem.selected=!1;continue}let tempOldItem=Object.assign({},oldItem);delete tempOldItem.selected,tempOldItem=JSON.stringify(tempOldItem);for(let selectedNewItem of selectedNewItems){if(tempOldItem.includes(selectedNewItem)){oldItem.selected=!0;break}oldItem.selected=!1}}}))}initFocus(){this.index<0&&this.updateIndex(),this.list.nativeElement.focus(),setTimeout((()=>{this.highlightedItem=this.getItemId(this.index)}))}updateIndex(){const selected=this.getSelected();selected.length?this.index=this.displayItems.indexOf(selected[0]):this.hasNextElement()&&this.getNextElement()}navigateList(event){"Enter"===event.key||" "===event.key?(this.listElementList.some((option=>option.nativeElement===event.target))&&event.preventDefault(),"Enter"===event.key&&this.doClick(event,this.getCurrentItem())):"ArrowDown"!==event.key&&"ArrowUp"!==event.key||(event.preventDefault(),"ArrowDown"===event.key?this.hasNextElement()?this.getNextElement()?.scrollIntoView({block:"end"}):this.blurIntent.emit("bottom"):"ArrowUp"===event.key&&(this.hasPrevElement()?this.getPrevElement().scrollIntoView({block:"nearest"}):this.blurIntent.emit("top")),setTimeout((()=>{this.highlightedItem=this.getItemId(this.index)})))}doClick(event,item){if(event.preventDefault(),item&&!item.disabled){if(this.list.nativeElement.focus(),"single"===this.type){item.selected=!0;for(let otherItem of this.getListItems())item!==otherItem&&(otherItem.selected=!1)}else item.selected=!item.selected;this.index=this.displayItems.indexOf(item),this.highlightedItem=this.getItemId(this.index),this.doEmitSelect(!1),this.appRef.tick()}}onItemFocus(index){const element=this.listElementList.toArray()[index].nativeElement;element.classList.add("cds--list-box__menu-item--highlighted"),element.tabIndex=0}onItemBlur(index){const element=this.listElementList.toArray()[index].nativeElement;element.classList.remove("cds--list-box__menu-item--highlighted"),element.tabIndex=-1}emitScroll(event){const customScrollEvent={atTop:0===event.srcElement.scrollTop,atBottom:event.srcElement.scrollHeight-event.srcElement.scrollTop===event.srcElement.clientHeight,event};this.scroll.emit(customScrollEvent)}onItemsReady(subcription){(this._itemsReady||(0,of.of)(!0)).pipe((0,first.P)()).subscribe(subcription)}reorderSelected(moveFocus=!0){this.displayItems=[...this.getSelected(),...this.getListItems().filter((item=>!item.selected))],moveFocus&&setTimeout((()=>{this.updateIndex(),this.highlightedItem=this.getItemId(this.index)}))}};DropdownList.listCount=0,DropdownList.ctorParameters=()=>[{type:core.ElementRef},{type:i18n.oc},{type:core.ApplicationRef}],DropdownList.propDecorators={ariaLabel:[{type:core.Input}],items:[{type:core.Input}],listTpl:[{type:core.Input}],select:[{type:core.Output}],scroll:[{type:core.Output}],blurIntent:[{type:core.Output}],list:[{type:core.ViewChild,args:["list",{static:!0}]}],type:[{type:core.Input}],showTitles:[{type:core.Input}],listElementList:[{type:core.ViewChildren,args:["listItem"]}]},DropdownList=(0,tslib_es6.gn)([(0,core.Component)({selector:"cds-dropdown-list, ibm-dropdown-list",template:'\n\t\t<ul\n\t\t\t#list\n\t\t\t[id]="listId"\n\t\t\trole="listbox"\n\t\t\tclass="cds--list-box__menu cds--multi-select"\n\t\t\t(scroll)="emitScroll($event)"\n\t\t\t(keydown)="navigateList($event)"\n\t\t\ttabindex="-1"\n\t\t\t[attr.aria-label]="ariaLabel"\n\t\t\t[attr.aria-activedescendant]="highlightedItem">\n\t\t\t<li\n\t\t\t\trole="option"\n\t\t\t\t*ngFor="let item of displayItems; let i = index"\n\t\t\t\t(click)="doClick($event, item)"\n\t\t\t\tclass="cds--list-box__menu-item"\n\t\t\t\t[attr.aria-selected]="item.selected"\n\t\t\t\t[id]="getItemId(i)"\n\t\t\t\t[attr.title]=" showTitles ? item.content : null"\n\t\t\t\t[attr.disabled]="item.disabled ? true : null"\n\t\t\t\t[ngClass]="{\n\t\t\t\t\t\'cds--list-box__menu-item--active\': item.selected,\n\t\t\t\t\t\'cds--list-box__menu-item--highlighted\': highlightedItem === getItemId(i)\n\t\t\t\t}">\n\t\t\t\t<div\n\t\t\t\t\t#listItem\n\t\t\t\t\ttabindex="-1"\n\t\t\t\t\tclass="cds--list-box__menu-item__option">\n\t\t\t\t\t<div\n\t\t\t\t\t\t*ngIf="!listTpl && type === \'multi\'"\n\t\t\t\t\t\tclass="cds--form-item cds--checkbox-wrapper">\n\t\t\t\t\t\t<label\n\t\t\t\t\t\t\t[attr.data-contained-checkbox-state]="item.selected"\n\t\t\t\t\t\t\tclass="cds--checkbox-label">\n\t\t\t\t\t\t\t<input\n\t\t\t\t\t\t\t\tclass="cds--checkbox"\n\t\t\t\t\t\t\t\ttype="checkbox"\n\t\t\t\t\t\t\t\t[checked]="item.selected"\n\t\t\t\t\t\t\t\t[disabled]="item.disabled"\n\t\t\t\t\t\t\t\ttabindex="-1">\n\t\t\t\t\t\t\t<span class="cds--checkbox-appearance"></span>\n\t\t\t\t\t\t\t<span class="cds--checkbox-label-text">{{item.content}}</span>\n\t\t\t\t\t\t</label>\n\t\t\t\t\t</div>\n\t\t\t\t\t<ng-container *ngIf="!listTpl && type === \'single\'">{{item.content}}</ng-container>\n\t\t\t\t\t<svg\n\t\t\t\t\t\t*ngIf="!listTpl && type === \'single\'"\n\t\t\t\t\t\tcdsIcon="checkmark"\n\t\t\t\t\t\tsize="16"\n\t\t\t\t\t\tclass="cds--list-box__menu-item__selected-icon">\n\t\t\t\t\t</svg>\n\t\t\t\t\t<ng-template\n\t\t\t\t\t\t*ngIf="listTpl"\n\t\t\t\t\t\t[ngTemplateOutletContext]="{item: item}"\n\t\t\t\t\t\t[ngTemplateOutlet]="listTpl">\n\t\t\t\t\t</ng-template>\n\t\t\t\t</div>\n\t\t\t</li>\n\t\t</ul>',providers:[{provide:AbstractDropdownView,useExisting:DropdownList}]})],DropdownList);let ScrollableList=class ScrollableList{constructor(elementRef){this.elementRef=elementRef,this.nScrollableList=null,this.scrollEnabled=!0,this.scrollBy=10,this.canScrollUp=!1,this.canScrollDown=!1,this.list=this.elementRef.nativeElement}ngOnChanges(changes){changes.scrollEnabled&&(changes.scrollEnabled.currentValue?(this.list.style.overflow="hidden",this.scrollUpTarget.style.display="flex",this.scrollDownTarget.style.display="flex",this.canScrollUp=!0,this.canScrollDown=!0,this.updateScrollHeight(),this.checkScrollArrows(),setTimeout((()=>{this.checkScrollArrows()}))):(this.scrollUpTarget.style.display="none",this.scrollDownTarget.style.display="none",this.canScrollUp=!1,this.canScrollDown=!1,this.list.style.height=null,this.list.style.overflow=null,clearInterval(this.hoverScrollInterval)))}ngAfterViewInit(){this.nScrollableList&&(this.list=this.elementRef.nativeElement.querySelector(this.nScrollableList)),this.scrollUpTarget.addEventListener("mouseover",(()=>this.onHoverUp(!0))),this.scrollUpTarget.addEventListener("mouseout",(()=>this.onHoverUp(!1))),this.scrollDownTarget.addEventListener("mouseover",(()=>this.onHoverDown(!0))),this.scrollDownTarget.addEventListener("mouseout",(()=>this.onHoverDown(!1)))}updateScrollHeight(){if(this.scrollEnabled){const containerRect=this.elementRef.nativeElement.parentElement.getBoundingClientRect(),innerHeightDiff=this.list.getBoundingClientRect().top-containerRect.top,height=containerRect.height-(containerRect.bottom-window.innerHeight)-innerHeightDiff-40;this.list.style.height=`${height}px`}}checkScrollArrows(){const scrollUpHeight=this.scrollUpTarget.offsetHeight,scrollDownHeight=this.scrollDownTarget.offsetHeight;0===this.list.scrollTop?(this.canScrollUp&&(this.list.style.height=`${parseInt(this.list.style.height,10)+scrollUpHeight}px`),this.scrollUpTarget.style.display="none",this.canScrollUp=!1):this.list.scrollTop===this.list.scrollTopMax?(this.canScrollDown&&(this.list.style.height=`${parseInt(this.list.style.height,10)+scrollDownHeight}px`),this.scrollDownTarget.style.display="none",this.canScrollDown=!1):(this.canScrollUp||(this.list.style.height=parseInt(this.list.style.height,10)-scrollUpHeight+"px"),this.canScrollDown||(this.list.style.height=parseInt(this.list.style.height,10)-scrollDownHeight+"px"),this.scrollUpTarget.style.display="flex",this.scrollDownTarget.style.display="flex",this.canScrollUp=!0,this.canScrollDown=!0)}onWheel(event){event.deltaY<0?this.list.scrollTop-=this.scrollBy:this.list.scrollTop+=this.scrollBy,this.list.scrollTop!==this.list.scrollTopMax&&0!==this.list.scrollTop&&(event.preventDefault(),event.stopPropagation()),this.checkScrollArrows()}onTouchStart(event){event.touches[0]&&(this.lastTouch=event.touches[0].clientY)}onTouchMove(event){if(event.preventDefault(),event.stopPropagation(),event.touches[0]){const touch=event.touches[0];this.list.scrollTop+=this.lastTouch-touch.clientY,this.lastTouch=touch.clientY,this.checkScrollArrows()}}hoverScrollBy(hovering,amount){hovering?this.hoverScrollInterval=setInterval((()=>{this.list.scrollTop+=amount,this.checkScrollArrows()}),1):clearInterval(this.hoverScrollInterval)}onHoverUp(hovering){this.hoverScrollBy(hovering,-3)}onHoverDown(hovering){this.hoverScrollBy(hovering,3)}onKeyDown(event){"ArrowDown"!==event.key&&"ArrowUp"!==event.key||this.checkScrollArrows()}};ScrollableList.ctorParameters=()=>[{type:core.ElementRef}],ScrollableList.propDecorators={nScrollableList:[{type:core.Input}],scrollEnabled:[{type:core.Input}],scrollUpTarget:[{type:core.Input}],scrollDownTarget:[{type:core.Input}],scrollBy:[{type:core.Input}],onWheel:[{type:core.HostListener,args:["wheel",["$event"]]}],onTouchStart:[{type:core.HostListener,args:["touchstart",["$event"]]}],onTouchMove:[{type:core.HostListener,args:["touchmove",["$event"]]}],onKeyDown:[{type:core.HostListener,args:["keydown",["$event"]]}]},ScrollableList=(0,tslib_es6.gn)([(0,core.Directive)({selector:"[cdsScrollableList], [ibmScrollableList]",exportAs:"scrollable-list"})],ScrollableList);var common=__webpack_require__("./node_modules/@angular/common/fesm2020/common.mjs"),icon=__webpack_require__("./src/icon/index.ts");let DropdownModule=class DropdownModule{};DropdownModule=(0,tslib_es6.gn)([(0,core.NgModule)({declarations:[Dropdown,DropdownList,ScrollableList,AbstractDropdownView],exports:[Dropdown,DropdownList,ScrollableList,AbstractDropdownView],imports:[common.CommonModule,fesm2020_forms.u5,i18n.LU,placeholder.Qq,utils.As,icon.QX],providers:[DropdownService]})],DropdownModule)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkcarbon_components_angular=self.webpackChunkcarbon_components_angular||[]).push([[3523],{"./node_modules/@carbon/icons/es/apple/16.js":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{Z:()=>_16});var _16={elem:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",width:16,height:16},content:[{elem:"path",attrs:{d:"M21.7788,8a11.4843,11.4843,0,0,0-3.0547.5342,14.5665,14.5665,0,0,1-1.8225.4126A6.0054,6.0054,0,0,0,11,4V6a3.9933,3.9933,0,0,1,3.8267,2.9c-.5181-.0879-1.0569-.2207-1.6172-.3648A12.89,12.89,0,0,0,10.0317,8C6.311,8,4,11.0652,4,16c0,7.51,4.0679,11.999,8.0005,12h.0015a7.1576,7.1576,0,0,0,2.49-.59A5.0128,5.0128,0,0,1,16,27a5.0266,5.0266,0,0,1,1.5112.41A7.15,7.15,0,0,0,20,28h0c3.9307-.001,8-4.49,8-12C28,12.3094,26.3706,8,21.7788,8ZM20,26h0a5.5038,5.5038,0,0,1-1.7905-.4639A6.4168,6.4168,0,0,0,16,25a6.4043,6.4043,0,0,0-2.2061.5361A5.5343,5.5343,0,0,1,12,26h.0015C9.0513,25.9988,6,22.2586,6,16c0-1.8037.3931-6,4.0317-6a11.2363,11.2363,0,0,1,2.6807.4726A12.9819,12.9819,0,0,0,15.7612,11h.4922a11.7955,11.7955,0,0,0,2.9956-.5361A9.8483,9.8483,0,0,1,21.7788,10C25.7964,10,26,14.9978,26,16,26,22.2586,22.9482,25.9988,20,26Z"}},{elem:"path",attrs:{d:"M18,7H17V6a2.0021,2.0021,0,0,1,2-2h1V5A2.0021,2.0021,0,0,1,18,7Z"}}],name:"apple",size:16}},"./node_modules/@carbon/icons/es/fish/16.js":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{Z:()=>_16});var _16={elem:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",width:16,height:16},content:[{elem:"circle",attrs:{cx:"24",cy:"7",r:"1"}},{elem:"path",attrs:{d:"M26,2A16.0183,16.0183,0,0,0,10,18v2H3a1,1,0,0,0-.707,1.707l8,8A1,1,0,0,0,12,29V22h2A16.0183,16.0183,0,0,0,30,6V2ZM10,26.5857,5.4141,22H10ZM12,20V18a13.9394,13.9394,0,0,1,3.908-9.6777l7.77,7.7695A13.94,13.94,0,0,1,14,20ZM28,6a13.9163,13.9163,0,0,1-2.98,8.6055L17.3945,6.98A13.9163,13.9163,0,0,1,26,4h2Z"}}],name:"fish",size:16}},"./node_modules/@carbon/icons/es/strawberry/16.js":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{Z:()=>_16});var _16={elem:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",width:16,height:16},content:[{elem:"path",attrs:{d:"M9 10H11V12H9zM9 14H11V16H9zM13 12H15V14H13z"}},{elem:"path",attrs:{d:"M9 28a5.169 5.169 0 01-.7441-.054A5.0935 5.0935 0 014 22.8669V11.1985a7.1615 7.1615 0 016.31-7.1653 6.9607 6.9607 0 014.4643 1.0706l7.9688 4.9807a6.98 6.98 0 01-.6885 12.19l-10.88 5.2285A4.9765 4.9765 0 019 28zM11.002 6q-.2484 0-.5005.0241A5.1463 5.1463 0 006 11.1985V22.8669a3.0839 3.0839 0 002.5435 3.1 3.0266 3.0266 0 001.7622-.2649l10.8828-5.23a4.9807 4.9807 0 00.4887-8.6958L13.7046 6.7935A4.9687 4.9687 0 0011.002 6zM26 7H22a4.0045 4.0045 0 01-4-4V2h2V3a2.0021 2.0021 0 002 2h4z"}}],name:"strawberry",size:16}},"./node_modules/@carbon/icons/es/subtract--alt/16.js":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{Z:()=>_16});var _16={elem:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",width:16,height:16},content:[{elem:"path",attrs:{d:"M16,4c6.6,0,12,5.4,12,12s-5.4,12-12,12S4,22.6,4,16S9.4,4,16,4 M16,2C8.3,2,2,8.3,2,16s6.3,14,14,14s14-6.3,14-14\tS23.7,2,16,2z"}},{elem:"path",attrs:{d:"M8 15H24V17H8z"}}],name:"subtract--alt",size:16}},"./node_modules/@carbon/icons/es/wheat/16.js":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{Z:()=>_16});var _16={elem:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",width:16,height:16},content:[{elem:"path",attrs:{d:"M21,3V5.5857l-4,4V1H15V9.5857l-4-4V3H9V19a7.004,7.004,0,0,0,6,6.92V30h2V25.92A7.004,7.004,0,0,0,23,19V3ZM15,23.8987A5.008,5.008,0,0,1,11,19v-2.586l4,4Zm0-6.313-4-4V8.4138l4,4Zm2-5.1719,4-4v5.1719l-4,4Zm0,11.4849V20.4138l4-4V19A5.008,5.008,0,0,1,17,23.8987Z"}}],name:"wheat",size:16}},"./node_modules/@carbon/utils-position/index.js":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{var _a,PLACEMENTS;__webpack_require__.d(__webpack_exports__,{FK:()=>position,ZP:()=>__WEBPACK_DEFAULT_EXPORT__}),function(PLACEMENTS){PLACEMENTS.LEFT="left",PLACEMENTS.RIGHT="right",PLACEMENTS.TOP="top",PLACEMENTS.BOTTOM="bottom"}(PLACEMENTS||(PLACEMENTS={}));var defaultPositions=((_a={})[PLACEMENTS.LEFT]=function(referenceOffset,target,referenceRect){return{top:referenceOffset.top-Math.round(target.offsetHeight/2)+Math.round(referenceRect.height/2),left:Math.round(referenceOffset.left-target.offsetWidth)}},_a[PLACEMENTS.RIGHT]=function(referenceOffset,target,referenceRect){return{top:referenceOffset.top-Math.round(target.offsetHeight/2)+Math.round(referenceRect.height/2),left:Math.round(referenceOffset.left+referenceRect.width)}},_a[PLACEMENTS.TOP]=function(referenceOffset,target,referenceRect){return{top:Math.round(referenceOffset.top-target.offsetHeight),left:referenceOffset.left-Math.round(target.offsetWidth/2)+Math.round(referenceRect.width/2)}},_a[PLACEMENTS.BOTTOM]=function(referenceOffset,target,referenceRect){return{top:Math.round(referenceOffset.top+referenceRect.height),left:referenceOffset.left-Math.round(target.offsetWidth/2)+Math.round(referenceRect.width/2)}},_a),windowRef="undefined"!=typeof window?window:{innerHeight:0,scrollY:0,innerWidth:0,scrollX:0},Position=function(){function Position(positions){void 0===positions&&(positions={}),this.positions=defaultPositions,this.positions=Object.assign({},defaultPositions,positions)}return Position.prototype.getRelativeOffset=function(target){for(var offsets={left:target.offsetLeft,top:target.offsetTop};target.offsetParent&&"static"===getComputedStyle(target.offsetParent).position;)offsets.left+=target.offsetLeft,offsets.top+=target.offsetTop,target=target.offsetParent;return offsets},Position.prototype.getAbsoluteOffset=function(target){for(var currentNode=target,margins={top:0,left:0};currentNode.offsetParent;){var computed=getComputedStyle(currentNode.offsetParent);"static"===computed.position&&computed.marginLeft&&computed.marginTop&&(parseInt(computed.marginTop,10)&&(margins.top+=parseInt(computed.marginTop,10)),parseInt(computed.marginLeft,10)&&(margins.left+=parseInt(computed.marginLeft,10))),currentNode=currentNode.offsetParent}var targetRect=target.getBoundingClientRect(),relativeRect=document.body.getBoundingClientRect();return{top:targetRect.top-relativeRect.top+margins.top,left:targetRect.left-relativeRect.left+margins.left}},Position.prototype.findRelative=function(reference,target,placement){var referenceOffset=this.getRelativeOffset(reference),referenceRect=reference.getBoundingClientRect();return this.calculatePosition(referenceOffset,referenceRect,target,placement)},Position.prototype.findAbsolute=function(reference,target,placement){var referenceOffset=this.getAbsoluteOffset(reference),referenceRect=reference.getBoundingClientRect();return this.calculatePosition(referenceOffset,referenceRect,target,placement)},Position.prototype.findPosition=function(reference,target,placement,offsetFunction){void 0===offsetFunction&&(offsetFunction=this.getAbsoluteOffset.bind(this));var referenceOffset=offsetFunction(reference),referenceRect=reference.getBoundingClientRect();return this.calculatePosition(referenceOffset,referenceRect,target,placement)},Position.prototype.findPositionAt=function(offset,target,placement){return this.calculatePosition(offset,{top:0,left:0,height:0,width:0},target,placement)},Position.prototype.getPlacementBox=function(target,position){var targetBottom=target.offsetHeight+position.top,targetRight=target.offsetWidth+position.left;return{top:position.top,bottom:targetBottom,left:position.left,right:targetRight}},Position.prototype.addOffset=function(position,top,left){return void 0===top&&(top=0),void 0===left&&(left=0),Object.assign({},position,{top:position.top+top,left:position.left+left})},Position.prototype.setElement=function(element,position){element.style.top=position.top+"px",element.style.left=position.left+"px"},Position.prototype.findBestPlacement=function(reference,target,placements,containerFunction,positionFunction){var _this=this;void 0===containerFunction&&(containerFunction=this.defaultContainerFunction.bind(this)),void 0===positionFunction&&(positionFunction=this.findPosition.bind(this));var weightedPlacements=placements.map((function(placement){var pos=positionFunction(reference,target,placement),box=_this.getPlacementBox(target,pos),hiddenHeight=0,hiddenWidth=0,container=containerFunction();box.top<container.top?hiddenHeight=container.top-box.top:box.bottom>container.height&&(hiddenHeight=box.bottom-container.height),box.left<container.left?hiddenWidth=container.left-box.left:box.right>container.width&&(hiddenWidth=box.right-container.width),hiddenHeight&&!hiddenWidth?hiddenWidth=1:hiddenWidth&&!hiddenHeight&&(hiddenHeight=1);var area=target.offsetHeight*target.offsetWidth;return{placement,weight:(area-hiddenHeight*hiddenWidth)/area}}));return weightedPlacements.sort((function(a,b){return b.weight-a.weight})),weightedPlacements[0].placement},Position.prototype.findBestPlacementAt=function(offset,target,placements,containerFunction){var _this=this;void 0===containerFunction&&(containerFunction=this.defaultContainerFunction.bind(this));return this.findBestPlacement(null,target,placements,containerFunction,(function(_,target,placement){return _this.findPositionAt(offset,target,placement)}))},Position.prototype.defaultContainerFunction=function(){return{top:0,left:0,height:windowRef.innerHeight,width:windowRef.innerWidth}},Position.prototype.calculatePosition=function(referenceOffset,referenceRect,target,placement){return this.positions[placement]?this.positions[placement](referenceOffset,target,referenceRect):(console.error("No function found for placement, defaulting to 0,0"),{left:0,top:0})},Position}(),position=new Position;const __WEBPACK_DEFAULT_EXPORT__=Position},"./src/layer/index.ts":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{A:()=>LayerDirective,D:()=>LayerModule});var tslib_es6=__webpack_require__("./node_modules/tslib/tslib.es6.js"),core=__webpack_require__("./node_modules/@angular/core/fesm2020/core.mjs");let LayerDirective=class LayerDirective{set ibmLayer(level){this.cdsLayer=level}set cdsLayer(level){"number"==typeof level&&(this._passedLevel=level,this.layer=level)}get cdsLayer(){return this._passedLevel}set layer(level){"number"==typeof level&&(this._level=Math.max(0,Math.min(level,2)),this.layerChildren&&this.layerChildren.forEach((layer=>{layer!==this&&(layer.layer="number"==typeof layer._passedLevel?layer._passedLevel:this.layer+1)})))}get layer(){return this._level}get layerOneClass(){return 0===this.layer}get layerTwoClass(){return 1===this.layer}get layerThreeClass(){return 2===this.layer}ngAfterContentInit(){"number"!=typeof this.cdsLayer&&(this.layer=1)}};LayerDirective.propDecorators={ibmLayer:[{type:core.Input}],cdsLayer:[{type:core.Input}],layerOneClass:[{type:core.HostBinding,args:["class.cds--layer-one"]}],layerTwoClass:[{type:core.HostBinding,args:["class.cds--layer-two"]}],layerThreeClass:[{type:core.HostBinding,args:["class.cds--layer-three"]}],layerChildren:[{type:core.ContentChildren,args:[LayerDirective,{descendants:!1}]}]},LayerDirective=(0,tslib_es6.gn)([(0,core.Directive)({selector:"[cdsLayer], [ibmLayer]",exportAs:"layer"})],LayerDirective);var common=__webpack_require__("./node_modules/@angular/common/fesm2020/common.mjs");let LayerModule=class LayerModule{};LayerModule=(0,tslib_es6.gn)([(0,core.NgModule)({declarations:[LayerDirective],exports:[LayerDirective],imports:[common.CommonModule]})],LayerModule)},"./src/layout/index.ts":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{x:()=>LayoutModule,s:()=>StackDirective});var tslib_es6=__webpack_require__("./node_modules/tslib/tslib.es6.js"),core=__webpack_require__("./node_modules/@angular/core/fesm2020/core.mjs"),common=__webpack_require__("./node_modules/@angular/common/fesm2020/common.mjs");let StackDirective=class StackDirective{constructor(render,hostElement){this.render=render,this.hostElement=hostElement,this.cdsStack="vertical"}get isHorizontal(){return"horizontal"===this.cdsStack}get isVertical(){return"vertical"===this.cdsStack||!this.cdsStack}set ibmStack(type){this.cdsStack=type}set gap(num){void 0!==num&&(this.render.removeClass(this.hostElement.nativeElement,`cds--stack-scale-${this._gap}`),this.render.addClass(this.hostElement.nativeElement,`cds--stack-scale-${num}`),this._gap=num)}};StackDirective.ctorParameters=()=>[{type:core.Renderer2},{type:core.ElementRef}],StackDirective.propDecorators={isHorizontal:[{type:core.HostBinding,args:["class.cds--stack-horizontal"]}],isVertical:[{type:core.HostBinding,args:["class.cds--stack-vertical"]}],ibmStack:[{type:core.Input}],cdsStack:[{type:core.Input}],gap:[{type:core.Input}]},StackDirective=(0,tslib_es6.gn)([(0,core.Directive)({selector:"[cdsStack], [ibmStack]"})],StackDirective);let LayoutModule=class LayoutModule{};LayoutModule=(0,tslib_es6.gn)([(0,core.NgModule)({declarations:[StackDirective],exports:[StackDirective],imports:[common.CommonModule]})],LayoutModule)},"./src/search/index.ts":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{o:()=>Search,t:()=>SearchModule});var tslib_es6=__webpack_require__("./node_modules/tslib/tslib.es6.js"),search_componentngResource=__webpack_require__("./src/search/search.component.html?ngResource"),core=__webpack_require__("./node_modules/@angular/core/fesm2020/core.mjs"),fesm2020_forms=__webpack_require__("./node_modules/@angular/forms/fesm2020/forms.mjs"),i18n=__webpack_require__("./src/i18n/index.ts");let Search=class Search{constructor(elementRef,i18n){this.elementRef=elementRef,this.i18n=i18n,this.theme="dark",this.size="md",this.disabled=!1,this.toolbar=!1,this.expandable=!1,this.skeleton=!1,this.active=!1,this.tableSearch=!1,this.id=`search-${Search.searchCount}`,this.value="",this.autocomplete="on",this.label=this.i18n.get().SEARCH.LABEL,this.placeholder=this.i18n.get().SEARCH.PLACEHOLDER,this.clearButtonTitle=this.i18n.get().SEARCH.CLEAR_BUTTON,this.searchTitle="",this.fluid=!1,this.valueChange=new core.EventEmitter,this.open=new core.EventEmitter,this.clear=new core.EventEmitter,this.search=new core.EventEmitter,this.isComposing=!1,this.onTouched=()=>{},this.propagateChange=_=>{},Search.searchCount++}get containerClass(){return!(this.toolbar||this.expandable)}get fluidSkeletonClass(){return this.skeleton&&this.fluid}writeValue(value){this.value=value}registerOnChange(fn){this.propagateChange=fn}registerOnTouched(fn){this.onTouched=fn}onSearch(search){this.isComposing||(this.value=search,this.doValueChange())}onEnter(){this.search.emit(this.value)}clearSearch(){this.value="",this.clear.emit(),this.propagateChange(this.value)}doValueChange(){this.valueChange.emit(this.value),this.propagateChange(this.value)}openSearch(){this.active=!0,this.open.emit(this.active),setTimeout((()=>this.inputRef.nativeElement.focus()))}keyDown(event){(this.toolbar||this.expandable)&&("Escape"===event.key?""===this.value&&(this.active=!1,this.open.emit(this.active)):"Enter"===event.key&&this.openSearch()),"Escape"===event.key&&""!==this.value&&this.clearSearch()}focusOut(event){this.onTouched(),(this.expandable||this.toolbar)&&this.inputRef&&""===this.inputRef.nativeElement.value&&!this.elementRef.nativeElement.contains(event.relatedTarget)&&(this.active=!1,this.open.emit(this.active))}focusIn(event){this.onTouched(),!this.expandable&&!this.toolbar||!this.inputRef||event.relatedTarget||this.elementRef.nativeElement.contains(event.relatedTarget)||this.openSearch()}compositionStart(event){this.isComposing=!0}compositionEnd(event){this.isComposing=!1,this.onSearch(this.value+event.data)}};Search.searchCount=0,Search.ctorParameters=()=>[{type:core.ElementRef},{type:i18n.oc}],Search.propDecorators={containerClass:[{type:core.HostBinding,args:["class.cds--form-item"]}],fluidSkeletonClass:[{type:core.HostBinding,args:["class.cds--text-input--fluid__skeleton"]}],theme:[{type:core.Input}],size:[{type:core.Input}],disabled:[{type:core.Input}],toolbar:[{type:core.Input}],expandable:[{type:core.Input}],skeleton:[{type:core.Input}],active:[{type:core.Input}],tableSearch:[{type:core.Input}],name:[{type:core.Input}],id:[{type:core.Input}],required:[{type:core.Input}],value:[{type:core.Input}],autocomplete:[{type:core.Input}],label:[{type:core.Input}],placeholder:[{type:core.Input}],clearButtonTitle:[{type:core.Input}],searchTitle:[{type:core.Input}],ariaLabel:[{type:core.Input}],fluid:[{type:core.Input}],valueChange:[{type:core.Output}],open:[{type:core.Output}],clear:[{type:core.Output}],search:[{type:core.Output}],inputRef:[{type:core.ViewChild,args:["input"]}],keyDown:[{type:core.HostListener,args:["keydown",["$event"]]}],focusOut:[{type:core.HostListener,args:["focusout",["$event"]]}],focusIn:[{type:core.HostListener,args:["focusin",["$event"]]}],compositionStart:[{type:core.HostListener,args:["compositionstart",["$event"]]}],compositionEnd:[{type:core.HostListener,args:["compositionend",["$event"]]}]},Search=(0,tslib_es6.gn)([(0,core.Component)({selector:"cds-search, ibm-search",template:search_componentngResource,providers:[{provide:fesm2020_forms.JU,useExisting:Search,multi:!0}]})],Search);var common=__webpack_require__("./node_modules/@angular/common/fesm2020/common.mjs"),icon=__webpack_require__("./src/icon/index.ts");let SearchModule=class SearchModule{};SearchModule=(0,tslib_es6.gn)([(0,core.NgModule)({declarations:[Search],exports:[Search],imports:[fesm2020_forms.u5,common.CommonModule,i18n.LU,icon.QX]})],SearchModule)},"./src/tag/index.ts":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{Vp:()=>Tag,Wh:()=>TagModule});var tslib_es6=__webpack_require__("./node_modules/tslib/tslib.es6.js"),core=__webpack_require__("./node_modules/@angular/core/fesm2020/core.mjs");let Tag=class Tag{constructor(){this.type="gray",this.size="md",this.class="",this.skeleton=!1}get attrClass(){const skeletonClass=this.skeleton?"cds--skeleton":"",sizeClass=`cds--tag--${this.size} cds--layout--size-${this.size}`;return`cds--tag cds--tag--${this.type} ${sizeClass} ${skeletonClass} ${this.class}`}};Tag.propDecorators={type:[{type:core.Input}],size:[{type:core.Input}],class:[{type:core.Input}],skeleton:[{type:core.Input}],attrClass:[{type:core.HostBinding,args:["attr.class"]}]},Tag=(0,tslib_es6.gn)([(0,core.Component)({selector:"cds-tag, ibm-tag",template:'\n\t\t<ng-container *ngIf="!skeleton">\n\t\t\t<ng-content select="[cdsTagIcon],[ibmTagIcon]"></ng-content>\n\t\t\t<span class="cds--tag__label">\n\t\t\t\t<ng-content></ng-content>\n\t\t\t</span>\n\t\t</ng-container>\n\t'})],Tag);let TagFilter=class TagFilter extends Tag{constructor(){super(...arguments),this.closeButtonLabel="Clear Filter",this.disabled=!1,this.close=new core.EventEmitter,this.click=new core.EventEmitter}onClick(event){event.stopImmediatePropagation(),this.disabled||this.click.emit({action:"click"})}onClose(event){event.stopImmediatePropagation(),this.click.emit({action:"close"}),this.close.emit()}get attrClass(){const disabledClass=this.disabled?"cds--tag--disabled":"",sizeClass=`cds--tag--${this.size} cds--layout--size-${this.size}`,skeletonClass=this.skeleton?"cds--skeleton":"";return`cds--tag cds--tag--filter cds--tag--${this.type} ${disabledClass} ${sizeClass} ${skeletonClass} ${this.class}`}get attrAriaLabel(){return`${this.title||""} ${this.closeButtonLabel}`.trim()}};TagFilter.propDecorators={closeButtonLabel:[{type:core.Input}],disabled:[{type:core.Input}],title:[{type:core.Input}],close:[{type:core.Output}],click:[{type:core.Output}],attrClass:[{type:core.HostBinding,args:["attr.class"]}],attrAriaLabel:[{type:core.HostBinding,args:["attr.aria-label"]}]},TagFilter=(0,tslib_es6.gn)([(0,core.Component)({selector:"cds-tag-filter, ibm-tag-filter",template:'\n\t\t<ng-container *ngIf="!skeleton">\n\t\t\t<ng-content select="[cdsTagIcon],[ibmTagIcon]"></ng-content>\n\t\t\t<span\n\t\t\t\tclass="cds--tag__label"\n\t\t\t\t[attr.title]="title ? title : null"\n\t\t\t\t(click)="onClick($event)">\n\t\t\t\t<ng-content></ng-content>\n\t\t\t</span>\n\t\t\t<button\n\t\t\t\tclass="cds--tag__close-icon"\n\t\t\t\t(click)="onClose($event)"\n\t\t\t\t[disabled]="disabled"\n\t\t\t\t[title]="closeButtonLabel">\n\t\t\t\t<span class="cds--visually-hidden">{{closeButtonLabel}}</span>\n\t\t\t\t<svg cdsIcon="close" size="16"></svg>\n\t\t\t</button>\n\t\t</ng-container>\n\t'})],TagFilter);let TagIconDirective=class TagIconDirective{constructor(){this.tagIcon=!0}};TagIconDirective.propDecorators={tagIcon:[{type:core.HostBinding,args:["class.cds--tag__custom-icon"]}]},TagIconDirective=(0,tslib_es6.gn)([(0,core.Directive)({selector:"[cdsTagIcon], [ibmTagIcon]"})],TagIconDirective);let TagSelectableComponent=class TagSelectableComponent{constructor(){this.role="button",this.buttonType="button",this.tabIndex=0,this.size="md",this.skeleton=!1,this.disabled=!1,this.class="",this.selected=!1,this.selectedChange=new core.EventEmitter}get ariaPressed(){return this.selected}onClick(){this.selected=!this.selected,this.selectedChange.emit(this.selected)}get attrClass(){const disabledClass=this.disabled?"cds--tag--disabled":"",sizeClass=`cds--tag--${this.size} cds--layout--size-${this.size}`,skeletonClass=this.skeleton?"cds--skeleton":"";return`cds--tag cds--tag--selectable ${this.selected?"cds--tag--selectable-selected":""} ${disabledClass} ${sizeClass} ${skeletonClass} ${this.class}`}};TagSelectableComponent.propDecorators={role:[{type:core.HostBinding,args:["attr.role"]}],buttonType:[{type:core.HostBinding,args:["attr.type"]}],tabIndex:[{type:core.HostBinding,args:["attr.tabindex"]}],ariaPressed:[{type:core.HostBinding,args:["attr.aria-pressed"]}],size:[{type:core.Input}],skeleton:[{type:core.Input}],disabled:[{type:core.Input}],class:[{type:core.Input}],selected:[{type:core.Input}],selectedChange:[{type:core.Output}],onClick:[{type:core.HostListener,args:["click"]}],attrClass:[{type:core.HostBinding,args:["attr.class"]}]},TagSelectableComponent=(0,tslib_es6.gn)([(0,core.Component)({selector:"cds-tag-selectable, ibm-tag-selectable",template:'\n\t\t<ng-container *ngIf="!skeleton">\n\t\t\t<ng-content select="[cdsTagIcon],[ibmTagIcon]"></ng-content>\n\t\t\t<span class="cds--tag__label">\n\t\t\t\t<ng-content></ng-content>\n\t\t\t</span>\n\t\t</ng-container>\n\t',changeDetection:core.ChangeDetectionStrategy.OnPush})],TagSelectableComponent);let TagOperationalComponent=class TagOperationalComponent extends Tag{constructor(){super(...arguments),this.role="button",this.buttonType="button",this.tabIndex=0,this.disabled=!1}get attrClass(){const disabledClass=this.disabled?"cds--tag--disabled":"",sizeClass=`cds--tag--${this.size} cds--layout--size-${this.size}`,skeletonClass=this.skeleton?"cds--skeleton":"";return`cds--tag cds--tag--operational cds--tag--${this.type} ${disabledClass} ${sizeClass} ${skeletonClass} ${this.class}`}};TagOperationalComponent.propDecorators={role:[{type:core.HostBinding,args:["attr.role"]}],buttonType:[{type:core.HostBinding,args:["attr.type"]}],tabIndex:[{type:core.HostBinding,args:["attr.tabindex"]}],disabled:[{type:core.Input}],attrClass:[{type:core.HostBinding,args:["attr.class"]}]},TagOperationalComponent=(0,tslib_es6.gn)([(0,core.Component)({selector:"cds-tag-operational, ibm-tag-operational",template:'\n\t\t<ng-container *ngIf="!skeleton">\n\t\t\t<ng-content select="[cdsTagIcon],[ibmTagIcon]"></ng-content>\n\t\t\t<span class="cds--tag__label">\n\t\t\t\t<ng-content></ng-content>\n\t\t\t</span>\n\t\t</ng-container>\n\t',changeDetection:core.ChangeDetectionStrategy.OnPush})],TagOperationalComponent);var common=__webpack_require__("./node_modules/@angular/common/fesm2020/common.mjs"),icon=__webpack_require__("./src/icon/index.ts");let TagModule=class TagModule{};TagModule=(0,tslib_es6.gn)([(0,core.NgModule)({declarations:[Tag,TagFilter,TagIconDirective,TagSelectableComponent,TagOperationalComponent],exports:[Tag,TagFilter,TagIconDirective,TagSelectableComponent,TagOperationalComponent],imports:[common.CommonModule,icon.QX]})],TagModule)},"./src/contained-list/contained-list.stories.ts":(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{__namedExportsOrder:()=>__namedExportsOrder,basic:()=>basic,default:()=>contained_list_stories,disclosed:()=>disclosed,usageExamples:()=>usageExamples,withActions:()=>withActions,withActionsAndContextData:()=>withActionsAndContextData,withIcons:()=>withIcons,withInteractiveItems:()=>withInteractiveItems,withInteractiveItemsAndActions:()=>withInteractiveItemsAndActions,withLayer:()=>withLayer,withListTitleDecorators:()=>withListTitleDecorators});var ContainedListSize,ContainedListKind,dist=__webpack_require__("./node_modules/@storybook/angular/dist/index.mjs"),tslib_es6=__webpack_require__("./node_modules/tslib/tslib.es6.js"),core=__webpack_require__("./node_modules/@angular/core/fesm2020/core.mjs");!function(ContainedListSize){ContainedListSize.Small="sm",ContainedListSize.Medium="md",ContainedListSize.Large="lg",ContainedListSize.ExtraLarge="xl"}(ContainedListSize||(ContainedListSize={})),function(ContainedListKind){ContainedListKind.OnPage="on-page",ContainedListKind.Disclosed="disclosed"}(ContainedListKind||(ContainedListKind={}));let ContainedList=class ContainedList{constructor(){this.isInset=!1,this.kind=ContainedListKind.OnPage,this.size=ContainedListSize.Large,this.labelId=`contained-list-${ContainedList.count++}-header`,this.ContainedListSize=ContainedListSize,this.ContainedListKind=ContainedListKind}isTemplate(value){return value instanceof core.TemplateRef}};ContainedList.count=0,ContainedList.propDecorators={action:[{type:core.Input}],isInset:[{type:core.Input}],kind:[{type:core.Input}],label:[{type:core.Input}],size:[{type:core.Input}],labelId:[{type:core.Input}]},ContainedList=(0,tslib_es6.gn)([(0,core.Component)({selector:"cds-contained-list, ibm-contained-list",template:'\n\t\t<div\n\t\t\tclass="cds--contained-list"\n\t\t\t[ngClass]="{\n\t\t\t\t\'cds--contained-list--inset-rulers\': isInset,\n\t\t\t\t\'cds--contained-list--on-page\': kind === ContainedListKind.OnPage,\n\t\t\t\t\'cds--contained-list--disclosed\': kind === ContainedListKind.Disclosed,\n\t\t\t\t\'cds--contained-list--sm\': size === ContainedListSize.Small,\n\t\t\t\t\'cds--contained-list--md\': size === ContainedListSize.Medium,\n\t\t\t\t\'cds--contained-list--lg\': size === ContainedListSize.Large,\n\t\t\t\t\'cds--contained-list--xl\': size === ContainedListSize.ExtraLarge,\n\t\t\t\t\'cds--layout--size-sm\': size === ContainedListSize.Small,\n\t\t\t\t\'cds--layout--size-md\': size === ContainedListSize.Medium,\n\t\t\t\t\'cds--layout--size-lg\': size === ContainedListSize.Large,\n\t\t\t\t\'cds--layout--size-xl\': size === ContainedListSize.ExtraLarge\n\t\t\t}">\n\t\t\t<div class="cds--contained-list__header">\n\t\t\t\t<div [id]="labelId" class="cds--contained-list__label">\n\t\t\t\t\t<ng-container *ngIf="!isTemplate(label)">{{ label }}</ng-container>\n\t\t\t\t\t<ng-template *ngIf="isTemplate(label)" [ngTemplateOutlet]="label"></ng-template>\n\t\t\t\t</div>\n\n\t\t\t\t<div class="cds--contained-list__action" *ngIf="action">\n\t\t\t\t\t<ng-template [ngTemplateOutlet]="action"></ng-template>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div role="list" [attr.aria-labelledby]="labelId">\n\t\t\t\t<ng-content></ng-content>\n\t\t\t</div>\n\t\t</div>\n\t',changeDetection:core.ChangeDetectionStrategy.OnPush})],ContainedList);let ContainedListItem=class ContainedListItem{constructor(){this.disabled=!1,this.click=new core.EventEmitter,this.itemClass=!0,this.role="listitem"}get itemClickableClass(){return this.clickable}get itemWithIconClass(){return!!this.icon}onClick(){this.click.emit()}isTemplate(value){return value instanceof core.TemplateRef}};ContainedListItem.propDecorators={action:[{type:core.Input}],actionData:[{type:core.Input}],disabled:[{type:core.Input}],clickable:[{type:core.Input}],icon:[{type:core.Input}],click:[{type:core.Output}],itemClass:[{type:core.HostBinding,args:["class.cds--contained-list-item"]}],role:[{type:core.HostBinding,args:["attr.role"]}],itemClickableClass:[{type:core.HostBinding,args:["class.cds--contained-list-item--clickable"]}],itemWithIconClass:[{type:core.HostBinding,args:["class.cds--contained-list-item--with-icon"]}]},ContainedListItem=(0,tslib_es6.gn)([(0,core.Component)({selector:"cds-contained-list-item, ibm-contained-list-item",template:'\n\t\t<ng-container *ngIf="clickable">\n\t\t\t<button\n\t\t\t\tclass="cds--contained-list-item__content"\n\t\t\t\ttype="button"\n\t\t\t\t[disabled]="disabled"\n\t\t\t\t(click)="onClick()">\n\t\t\t\t<ng-content select="[cdsContainedListItemButton],[ibmContainedListItemButton]"></ng-content>\n\t\t\t</button>\n\t\t</ng-container>\n\t\t<ng-container *ngIf="!clickable">\n\t\t\t<div class="cds--contained-list-item__content">\n\t\t\t\t<div *ngIf="icon" class="cds--contained-list-item__icon">\n\t\t\t\t\t<ng-container *ngIf="!isTemplate(icon)"><svg [ibmIcon]="icon" size="16"></svg></ng-container>\n\t\t\t\t\t<ng-template *ngIf="isTemplate(icon)" [ngTemplateOutlet]="icon"></ng-template>\n\t\t\t\t</div>\n\t\t\t\t<ng-content></ng-content>\n\t\t\t</div>\n\t\t</ng-container>\n\t\t<div class="cds--contained-list-item__action" *ngIf="action">\n\t\t\t<ng-template [ngTemplateOutlet]="action" [ngTemplateOutletContext]="{ $implicit: actionData }"></ng-template>\n\t\t</div>\n\t',changeDetection:core.ChangeDetectionStrategy.OnPush})],ContainedListItem);var common=__webpack_require__("./node_modules/@angular/common/fesm2020/common.mjs"),icon=__webpack_require__("./src/icon/index.ts");let ContainedListModule=class ContainedListModule{};ContainedListModule=(0,tslib_es6.gn)([(0,core.NgModule)({declarations:[ContainedList,ContainedListItem],exports:[ContainedList,ContainedListItem],imports:[common.CommonModule,icon.QX]})],ContainedListModule);var src_button=__webpack_require__("./src/button/index.ts"),src_layer=__webpack_require__("./src/layer/index.ts"),layout=__webpack_require__("./src/layout/index.ts"),tag=__webpack_require__("./src/tag/index.ts"),dialog=__webpack_require__("./src/dialog/index.ts"),tooltip=__webpack_require__("./src/tooltip/index.ts"),search=__webpack_require__("./src/search/index.ts"),icon_service=__webpack_require__("./src/icon/icon.service.ts"),_16=__webpack_require__("./node_modules/@carbon/icons/es/apple/16.js"),fish_16=__webpack_require__("./node_modules/@carbon/icons/es/fish/16.js"),strawberry_16=__webpack_require__("./node_modules/@carbon/icons/es/strawberry/16.js"),subtract_alt_16=__webpack_require__("./node_modules/@carbon/icons/es/subtract--alt/16.js"),wheat_16=__webpack_require__("./node_modules/@carbon/icons/es/wheat/16.js");let ContainedListStoryModule=class ContainedListStoryModule{constructor(iconService){this.iconService=iconService,this.iconService.registerAll([_16.Z,fish_16.Z,strawberry_16.Z,subtract_alt_16.Z,wheat_16.Z])}};ContainedListStoryModule.ctorParameters=()=>[{type:icon_service.C6}],ContainedListStoryModule=(0,tslib_es6.gn)([(0,core.NgModule)({imports:[common.CommonModule]})],ContainedListStoryModule);const contained_list_stories={title:"Components/Contained List",decorators:[(0,dist.moduleMetadata)({imports:[ContainedListModule,ContainedListStoryModule,src_button.hJ,icon.QX,src_layer.D,layout.x,tag.Wh,dialog.Su,tooltip.z8,search.t]})],component:ContainedList,subcomponents:{ContainedListItem},args:{isInset:!1,kind:ContainedListKind.OnPage,label:"List title",size:ContainedListSize.Large},argTypes:{label:{type:{name:"string",required:!0}},action:{table:{disable:!0}}}},basic=(()=>({template:'\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n '})).bind({}),usageExamples=(()=>({template:'\n <ng-template #add let-item>\n <ibm-icon-button\n type="button"\n kind="primary"\n align="left"\n description="Add">\n <svg class="cds--btn__icon" ibmIcon="add" size="16"></svg>\n </ibm-icon-button>\n </ng-template>\n <ng-template #overflowMenu let-item>\n <ibm-tooltip class="cds--icon-tooltip" description="Options" align="left">\n <ibm-overflow-menu [flip]="true" [customTrigger]="customTrigger" triggerClass="cds--toolbar-action" [offset]="{ x: 0, y: 0 }">\n <ibm-overflow-menu-option>View details</ibm-overflow-menu-option>\n <ibm-overflow-menu-option>Edit</ibm-overflow-menu-option>\n <ibm-overflow-menu-option [divider]="true" type="danger">Remove</ibm-overflow-menu-option>\n </ibm-overflow-menu>\n </ibm-tooltip>\n </ng-template>\n <cds-contained-list label="List title" [action]="add">\n <cds-contained-list-item [action]="overflowMenu">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="overflowMenu">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="overflowMenu">List item</cds-contained-list-item>\n </cds-contained-list>\n\n <ng-template #addGhost let-item>\n <ibm-icon-button\n type="button"\n kind="ghost"\n align="left"\n description="Add">\n <svg class="cds--btn__icon" ibmIcon="add" size="16"></svg>\n </ibm-icon-button>\n </ng-template>\n <cds-contained-list label="List title" [action]="addGhost">\n <cds-contained-list-item>\n List item\n <br />\n <span class="cds--label cds--label--no-margin">\n Description text\n </span>\n </cds-contained-list-item>\n <cds-contained-list-item>\n List item\n <br />\n <span class="cds--label cds--label--no-margin">\n Description text\n </span>\n </cds-contained-list-item>\n <cds-contained-list-item>\n List item\n <br />\n <span class="cds--label cds--label--no-margin">\n Description text\n </span>\n </cds-contained-list-item>\n </cds-contained-list>\n\n <cds-contained-list label="List title">\n <cds-contained-list-item>\n <div style="display: \'grid\'; gridTemplateColumns: repeat(3, 1fr); columnGap: 1rem">\n <span>List item</span>\n <span>List item details</span>\n <span>List item details</span>\n </div>\n </cds-contained-list-item>\n <cds-contained-list-item>\n <div style="display: \'grid\'; gridTemplateColumns: repeat(3, 1fr); columnGap: 1rem">\n <span>List item</span>\n <span>List item details</span>\n <span>List item details</span>\n </div>\n </cds-contained-list-item>\n <cds-contained-list-item>\n <div style="display: \'grid\'; gridTemplateColumns: repeat(3, 1fr); columnGap: 1rem">\n <span>List item</span>\n <span>List item details</span>\n <span>List item details</span>\n </div>\n </cds-contained-list-item>\n </cds-contained-list>\n '})).bind({}),disclosed=(()=>({template:'\n <cds-contained-list label="List title" kind="disclosed">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n <cds-contained-list label="List title" kind="disclosed">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n '})).bind({}),withActions=(()=>({template:'\n <ng-template #action let-item>\n <button\n ibmButton="ghost"\n aria-label="Action"\n iconOnly="true">\n <svg ibmIcon="subtract--alt" size="16" class="cds--btn__icon"></svg>\n </button>\n </ng-template>\n\n <cds-contained-list label="List title" [size]="size">\n <cds-contained-list-item [action]="action">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="action">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="action">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="action">List item</cds-contained-list-item>\n </cds-contained-list>\n '})).bind({}),withActionsAndContextData=args=>({props:args={...args,items:[{id:1,label:"List Item"},{id:2,label:"List Item"},{id:3,label:"List Item"},{id:4,label:"List Item"}],onActionClick:item=>{alert(`${item.label} ${item.id} action click triggered`)}},template:'\n <ng-template #actionWithClick let-actionData>\n <button\n ibmButton="ghost"\n aria-label="Action"\n iconOnly="true"\n (click)="onActionClick(actionData)">\n <svg ibmIcon="add" size="16" class="cds--btn__icon"></svg>\n </button>\n </ng-template>\n <cds-contained-list label="List title" [size]="size">\n <cds-contained-list-item\n *ngFor="let item of items"\n [action]="actionWithClick"\n [actionData]="item">\n {{ item.label }} {{ item.id }}\n </cds-contained-list-item>\n </cds-contained-list>\n '}),withIcons=(()=>({template:'\n <ng-template #apple let-icon>\n <svg ibmIcon="apple" size="16"></svg>\n </ng-template>\n\n <ng-template #wheat let-icon>\n <svg ibmIcon="wheat" size="16"></svg>\n </ng-template>\n\n <cds-contained-list label="List title">\n <cds-contained-list-item [icon]="apple">List item</cds-contained-list-item>\n <cds-contained-list-item [icon]="wheat">List item</cds-contained-list-item>\n <cds-contained-list-item icon="strawberry">List item</cds-contained-list-item>\n <cds-contained-list-item icon="fish">List item</cds-contained-list-item>\n </cds-contained-list>\n '})).bind({}),withInteractiveItems=(()=>({template:'\n <cds-contained-list label="List title">\n <cds-contained-list-item [clickable]="true">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true" [disabled]="true">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n </cds-contained-list>\n '})).bind({}),withInteractiveItemsAndActions=(()=>({template:'\n <ng-template #action let-item>\n <button\n aria-label="Action"\n ibmButton="ghost"\n iconOnly="true">\n <svg ibmIcon="subtract--alt" size="16" class="cds--btn__icon"></svg>\n </button>\n </ng-template>\n <ng-template #search>\n <cds-search [expandable]="true" size="lg"></cds-search>\n </ng-template>\n <cds-contained-list label="List title" [action]="search">\n <cds-contained-list-item [clickable]="true" [action]="action">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true" [action]="action">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true" [action]="action">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true" [action]="action">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n </cds-contained-list>\n '})).bind({}),withLayer=(()=>({template:'\n <div ibmStack="vertical" [gap]="5">\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n <div [ibmLayer]="1">\n <div ibmStack="vertical" [gap]="5">\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n <div [ibmLayer]="2">\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n </div>\n </div>\n </div>\n </div>\n '})).bind({}),withListTitleDecorators=(()=>({template:'\n <ng-template #label let-item>\n <div style="display: flex; alignItems: center; justifyContent: space-between">\n <span>List title</span>\n <ibm-tag size="sm">4</ibm-tag>\n </div>\n </ng-template>\n <cds-contained-list [label]="label">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n '})).bind({});basic.parameters={...basic.parameters,docs:{...basic.parameters?.docs,source:{originalSource:'() => ({\n template: `\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n `\n})',...basic.parameters?.docs?.source}}},usageExamples.parameters={...usageExamples.parameters,docs:{...usageExamples.parameters?.docs,source:{originalSource:'() => ({\n template: `\n <ng-template #add let-item>\n <ibm-icon-button\n type="button"\n kind="primary"\n align="left"\n description="Add">\n <svg class="cds--btn__icon" ibmIcon="add" size="16"></svg>\n </ibm-icon-button>\n </ng-template>\n <ng-template #overflowMenu let-item>\n <ibm-tooltip class="cds--icon-tooltip" description="Options" align="left">\n <ibm-overflow-menu [flip]="true" [customTrigger]="customTrigger" triggerClass="cds--toolbar-action" [offset]="{ x: 0, y: 0 }">\n <ibm-overflow-menu-option>View details</ibm-overflow-menu-option>\n <ibm-overflow-menu-option>Edit</ibm-overflow-menu-option>\n <ibm-overflow-menu-option [divider]="true" type="danger">Remove</ibm-overflow-menu-option>\n </ibm-overflow-menu>\n </ibm-tooltip>\n </ng-template>\n <cds-contained-list label="List title" [action]="add">\n <cds-contained-list-item [action]="overflowMenu">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="overflowMenu">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="overflowMenu">List item</cds-contained-list-item>\n </cds-contained-list>\n\n <ng-template #addGhost let-item>\n <ibm-icon-button\n type="button"\n kind="ghost"\n align="left"\n description="Add">\n <svg class="cds--btn__icon" ibmIcon="add" size="16"></svg>\n </ibm-icon-button>\n </ng-template>\n <cds-contained-list label="List title" [action]="addGhost">\n <cds-contained-list-item>\n List item\n <br />\n <span class="cds--label cds--label--no-margin">\n Description text\n </span>\n </cds-contained-list-item>\n <cds-contained-list-item>\n List item\n <br />\n <span class="cds--label cds--label--no-margin">\n Description text\n </span>\n </cds-contained-list-item>\n <cds-contained-list-item>\n List item\n <br />\n <span class="cds--label cds--label--no-margin">\n Description text\n </span>\n </cds-contained-list-item>\n </cds-contained-list>\n\n <cds-contained-list label="List title">\n <cds-contained-list-item>\n <div style="display: \'grid\'; gridTemplateColumns: repeat(3, 1fr); columnGap: 1rem">\n <span>List item</span>\n <span>List item details</span>\n <span>List item details</span>\n </div>\n </cds-contained-list-item>\n <cds-contained-list-item>\n <div style="display: \'grid\'; gridTemplateColumns: repeat(3, 1fr); columnGap: 1rem">\n <span>List item</span>\n <span>List item details</span>\n <span>List item details</span>\n </div>\n </cds-contained-list-item>\n <cds-contained-list-item>\n <div style="display: \'grid\'; gridTemplateColumns: repeat(3, 1fr); columnGap: 1rem">\n <span>List item</span>\n <span>List item details</span>\n <span>List item details</span>\n </div>\n </cds-contained-list-item>\n </cds-contained-list>\n `\n})',...usageExamples.parameters?.docs?.source}}},disclosed.parameters={...disclosed.parameters,docs:{...disclosed.parameters?.docs,source:{originalSource:'() => ({\n template: `\n <cds-contained-list label="List title" kind="disclosed">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n <cds-contained-list label="List title" kind="disclosed">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n `\n})',...disclosed.parameters?.docs?.source}}},withActions.parameters={...withActions.parameters,docs:{...withActions.parameters?.docs,source:{originalSource:'() => ({\n template: `\n <ng-template #action let-item>\n <button\n ibmButton="ghost"\n aria-label="Action"\n iconOnly="true">\n <svg ibmIcon="subtract--alt" size="16" class="cds--btn__icon"></svg>\n </button>\n </ng-template>\n\n <cds-contained-list label="List title" [size]="size">\n <cds-contained-list-item [action]="action">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="action">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="action">List item</cds-contained-list-item>\n <cds-contained-list-item [action]="action">List item</cds-contained-list-item>\n </cds-contained-list>\n `\n})',...withActions.parameters?.docs?.source}}},withActionsAndContextData.parameters={...withActionsAndContextData.parameters,docs:{...withActionsAndContextData.parameters?.docs,source:{originalSource:'args => {\n args = {\n ...args,\n items: [{\n id: 1,\n label: "List Item"\n }, {\n id: 2,\n label: "List Item"\n }, {\n id: 3,\n label: "List Item"\n }, {\n id: 4,\n label: "List Item"\n }],\n onActionClick: (item: any) => {\n alert(`${item.label} ${item.id} action click triggered`);\n }\n };\n return {\n props: args,\n template: `\n <ng-template #actionWithClick let-actionData>\n <button\n ibmButton="ghost"\n aria-label="Action"\n iconOnly="true"\n (click)="onActionClick(actionData)">\n <svg ibmIcon="add" size="16" class="cds--btn__icon"></svg>\n </button>\n </ng-template>\n <cds-contained-list label="List title" [size]="size">\n <cds-contained-list-item\n *ngFor="let item of items"\n [action]="actionWithClick"\n [actionData]="item">\n {{ item.label }} {{ item.id }}\n </cds-contained-list-item>\n </cds-contained-list>\n `\n };\n}',...withActionsAndContextData.parameters?.docs?.source}}},withIcons.parameters={...withIcons.parameters,docs:{...withIcons.parameters?.docs,source:{originalSource:'() => ({\n template: `\n <ng-template #apple let-icon>\n <svg ibmIcon="apple" size="16"></svg>\n </ng-template>\n\n <ng-template #wheat let-icon>\n <svg ibmIcon="wheat" size="16"></svg>\n </ng-template>\n\n <cds-contained-list label="List title">\n <cds-contained-list-item [icon]="apple">List item</cds-contained-list-item>\n <cds-contained-list-item [icon]="wheat">List item</cds-contained-list-item>\n <cds-contained-list-item icon="strawberry">List item</cds-contained-list-item>\n <cds-contained-list-item icon="fish">List item</cds-contained-list-item>\n </cds-contained-list>\n `\n})',...withIcons.parameters?.docs?.source}}},withInteractiveItems.parameters={...withInteractiveItems.parameters,docs:{...withInteractiveItems.parameters?.docs,source:{originalSource:'() => ({\n template: `\n <cds-contained-list label="List title">\n <cds-contained-list-item [clickable]="true">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true" [disabled]="true">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n </cds-contained-list>\n `\n})',...withInteractiveItems.parameters?.docs?.source}}},withInteractiveItemsAndActions.parameters={...withInteractiveItemsAndActions.parameters,docs:{...withInteractiveItemsAndActions.parameters?.docs,source:{originalSource:'() => ({\n template: `\n <ng-template #action let-item>\n <button\n aria-label="Action"\n ibmButton="ghost"\n iconOnly="true">\n <svg ibmIcon="subtract--alt" size="16" class="cds--btn__icon"></svg>\n </button>\n </ng-template>\n <ng-template #search>\n <cds-search [expandable]="true" size="lg"></cds-search>\n </ng-template>\n <cds-contained-list label="List title" [action]="search">\n <cds-contained-list-item [clickable]="true" [action]="action">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true" [action]="action">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true" [action]="action">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n <cds-contained-list-item [clickable]="true" [action]="action">\n <ng-container ibmContainedListItemButton>List item</ng-container>\n </cds-contained-list-item>\n </cds-contained-list>\n `\n})',...withInteractiveItemsAndActions.parameters?.docs?.source}}},withLayer.parameters={...withLayer.parameters,docs:{...withLayer.parameters?.docs,source:{originalSource:'() => ({\n template: `\n <div ibmStack="vertical" [gap]="5">\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n <div [ibmLayer]="1">\n <div ibmStack="vertical" [gap]="5">\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n <div [ibmLayer]="2">\n <cds-contained-list label="List title">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n </div>\n </div>\n </div>\n </div>\n `\n})',...withLayer.parameters?.docs?.source}}},withListTitleDecorators.parameters={...withListTitleDecorators.parameters,docs:{...withListTitleDecorators.parameters?.docs,source:{originalSource:'() => ({\n template: `\n <ng-template #label let-item>\n <div style="display: flex; alignItems: center; justifyContent: space-between">\n <span>List title</span>\n <ibm-tag size="sm">4</ibm-tag>\n </div>\n </ng-template>\n <cds-contained-list [label]="label">\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n <cds-contained-list-item>List item</cds-contained-list-item>\n </cds-contained-list>\n `\n})',...withListTitleDecorators.parameters?.docs?.source}}};const __namedExportsOrder=["basic","usageExamples","disclosed","withActions","withActionsAndContextData","withIcons","withInteractiveItems","withInteractiveItemsAndActions","withLayer","withListTitleDecorators"]},"./src/search/search.component.html?ngResource":module=>{module.exports='<div\n\tclass="cds--search"\n\t[ngClass]="{\n\t\t\'cds--search--sm\': size === \'sm\',\n\t\t\'cds--search--md\': size === \'md\',\n\t\t\'cds--search--lg\': size === \'lg\',\n\t\t\'cds--search--light\': theme === \'light\',\n\t\t\'cds--skeleton\': skeleton && !fluid,\n\t\t\'cds--search--expandable\': expandable && !tableSearch,\n\t\t\'cds--search--expanded\': expandable && !tableSearch && active,\n\t\t\'cds--toolbar-search\': toolbar && !expandable,\n\t\t\'cds--toolbar-search--active\': toolbar && !expandable && active,\n\t\t\'cds--toolbar-search-container-persistent\': tableSearch && !expandable,\n\t\t\'cds--toolbar-search-container-expandable\': tableSearch && expandable,\n\t\t\'cds--toolbar-search-container-active\': tableSearch && expandable && active,\n\t\t\'cds--search--fluid\': fluid,\n\t\t\'cds--search--disabled\': disabled\n\t}"\n\trole="search"\n\t[attr.aria-label]="ariaLabel"\n\t(click)="openSearch()">\n\t<label\n\t\tclass="cds--label"\n\t\t[for]="id"\n\t\t[ngClass]="{ \'cds--skeleton\': skeleton && fluid }">\n\t\t{{ !skeleton ? label : \'\'}}\n\t</label>\n\n\t<div *ngIf="skeleton; else enableInput" class="cds--text-input cds--skeleton"></div>\n\t<ng-template #enableInput>\n\t\t<input\n\t\t\t#input\n\t\t\tclass="cds--search-input"\n\t\t\t[type]="tableSearch || !toolbar ? \'text\' : \'search\'"\n\t\t\t[id]="id"\n\t\t\t[value]="value"\n\t\t\t[autocomplete]="autocomplete"\n\t\t\t[placeholder]="placeholder"\n\t\t\t[disabled]="disabled"\n\t\t\t[required]="required"\n\t\t\t(input)="onSearch($event.target.value)"\n\t\t\t(keyup.enter)="onEnter()"/>\n\t\t<button\n\t\t\t*ngIf="!tableSearch && toolbar"\n\t\t\tclass="cds--toolbar-search__btn"\n\t\t\t(click)="openSearch()"\n\t\t\taria-label="Open search">\n\t\t\t<svg cdsIcon="search" size="16" class="cds--search-magnifier-icon"></svg>\n\t\t</button>\n\t\t<svg\n\t\t\tcdsIcon="search"\n\t\t\t*ngIf="tableSearch || !toolbar"\n\t\t\tclass="cds--search-magnifier-icon"\n\t\t\tsize="16">\n\t\t</svg>\n\t</ng-template>\n\n\t<button\n\t\t*ngIf="tableSearch || !toolbar"\n\t\tclass="cds--search-close"\n\t\t[ngClass]="{\n\t\t\t\'cds--search-close--hidden\': !value || value.length === 0\n\t\t}"\n\t\t[title]="clearButtonTitle"\n\t\t(click)="clearSearch()">\n\t\t<span class="cds--visually-hidden">{{ clearButtonTitle }}</span>\n\t\t<svg cdsIcon="close" size="16"></svg>\n\t</button>\n</div>\n'}}]);
|