@kyndryl-design-system/shidoka-applications 2.76.1 → 2.78.0
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/components/global/header/headerCategory.d.ts +2 -0
- package/components/global/header/headerCategory.d.ts.map +1 -1
- package/components/global/header/headerCategory.js +17 -6
- package/components/global/header/headerCategory.js.map +1 -1
- package/components/global/header/headerLink.js +1 -0
- package/components/global/header/headerLink.js.map +1 -1
- package/components/reusable/search/search.js +1 -1
- package/components/reusable/search/search.js.map +1 -1
- package/components/reusable/table/story-helpers/ultils.sample.d.ts +8 -0
- package/components/reusable/table/story-helpers/ultils.sample.d.ts.map +1 -1
- package/components/reusable/table/table-header.d.ts +1 -0
- package/components/reusable/table/table-header.d.ts.map +1 -1
- package/components/reusable/table/table-header.js +20 -7
- package/components/reusable/table/table-header.js.map +1 -1
- package/package.json +3 -3
|
@@ -10,6 +10,8 @@ export declare class HeaderCategory extends LitElement {
|
|
|
10
10
|
accessor heading: string;
|
|
11
11
|
/** Add left padding when icon is not provided to align text with links that do have icons. */
|
|
12
12
|
accessor leftPadding: boolean;
|
|
13
|
+
/** Show bottom border/divider. */
|
|
14
|
+
accessor showDivider: boolean;
|
|
13
15
|
render(): import("lit-html").TemplateResult<1>;
|
|
14
16
|
}
|
|
15
17
|
declare global {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"headerCategory.d.ts","sourceRoot":"","sources":["../../../../src/components/global/header/headerCategory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAmB,MAAM,KAAK,CAAC;AAIlD;;;;GAIG;AACH,qBACa,cAAe,SAAQ,UAAU;IAC5C,OAAgB,MAAM,0BAAiC;IAEvD,qBAAqB;IAErB,QAAQ,CAAC,OAAO,SAAM;IAEtB,8FAA8F;IAE9F,QAAQ,CAAC,WAAW,UAAS;IAEpB,MAAM;
|
|
1
|
+
{"version":3,"file":"headerCategory.d.ts","sourceRoot":"","sources":["../../../../src/components/global/header/headerCategory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAmB,MAAM,KAAK,CAAC;AAIlD;;;;GAIG;AACH,qBACa,cAAe,SAAQ,UAAU;IAC5C,OAAgB,MAAM,0BAAiC;IAEvD,qBAAqB;IAErB,QAAQ,CAAC,OAAO,SAAM;IAEtB,8FAA8F;IAE9F,QAAQ,CAAC,WAAW,UAAS;IAE7B,kCAAkC;IAElC,QAAQ,CAAC,WAAW,UAAS;IAEpB,MAAM;CAehB;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,qBAAqB,EAAE,cAAc,CAAC;KACvC;CACF"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{__setFunctionName as e,__esDecorate as t,__runInitializers as i,__classPrivateFieldGet as a,__classPrivateFieldSet as n}from"tslib";import{css as
|
|
1
|
+
import{__setFunctionName as e,__esDecorate as t,__runInitializers as i,__classPrivateFieldGet as a,__classPrivateFieldSet as n}from"tslib";import{css as r,LitElement as d,unsafeCSS as l,html as o}from"lit";import{customElement as s,property as h}from"lit/decorators.js";var g=r`*,
|
|
2
2
|
*::before,
|
|
3
3
|
*::after {
|
|
4
4
|
box-sizing: border-box;
|
|
@@ -41,6 +41,15 @@ import{__setFunctionName as e,__esDecorate as t,__runInitializers as i,__classPr
|
|
|
41
41
|
flex-direction: column;
|
|
42
42
|
gap: 2px;
|
|
43
43
|
}
|
|
44
|
+
.category.divider::after {
|
|
45
|
+
content: "";
|
|
46
|
+
display: block;
|
|
47
|
+
background: none;
|
|
48
|
+
border: none;
|
|
49
|
+
margin: 6px 8px;
|
|
50
|
+
height: 1px;
|
|
51
|
+
background: var(--kd-color-border-level-tertiary);
|
|
52
|
+
}
|
|
44
53
|
|
|
45
54
|
.category__links {
|
|
46
55
|
display: flex;
|
|
@@ -60,7 +69,7 @@ import{__setFunctionName as e,__esDecorate as t,__runInitializers as i,__classPr
|
|
|
60
69
|
color: var(--kd-color-text-variant-brand);
|
|
61
70
|
font-weight: var(--kd-font-weight-medium);
|
|
62
71
|
text-transform: uppercase;
|
|
63
|
-
padding:
|
|
72
|
+
padding: 7px 6px 7px 8px;
|
|
64
73
|
}
|
|
65
74
|
@media (min-width: 42rem) {
|
|
66
75
|
.heading {
|
|
@@ -96,9 +105,11 @@ slot[name=icon]::slotted(*) {
|
|
|
96
105
|
justify-content: center;
|
|
97
106
|
width: 16px;
|
|
98
107
|
height: 16px;
|
|
99
|
-
}`;let m=(()=>{var
|
|
100
|
-
<div class="category">
|
|
101
|
-
<div
|
|
108
|
+
}`;let m=(()=>{var r,m,c;let p,f,v,u,k,y=[s("kyn-header-category")],x=[],b=d,w=[],z=[],P=[],D=[],S=[],j=[];return f=class extends b{get heading(){return a(this,r,"f")}set heading(e){n(this,r,e,"f")}get leftPadding(){return a(this,m,"f")}set leftPadding(e){n(this,m,e,"f")}get showDivider(){return a(this,c,"f")}set showDivider(e){n(this,c,e,"f")}render(){return o`
|
|
109
|
+
<div class="category ${this.showDivider?"divider":""}"">
|
|
110
|
+
<div
|
|
111
|
+
class="heading ${this.leftPadding?"left-padding":""}
|
|
112
|
+
>
|
|
102
113
|
<slot name="icon"></slot>
|
|
103
114
|
${this.heading}
|
|
104
115
|
</div>
|
|
@@ -106,5 +117,5 @@ slot[name=icon]::slotted(*) {
|
|
|
106
117
|
<slot></slot>
|
|
107
118
|
</div>
|
|
108
119
|
</div>
|
|
109
|
-
`}constructor(){super(...arguments),
|
|
120
|
+
`}constructor(){super(...arguments),r.set(this,i(this,w,"")),m.set(this,(i(this,z),i(this,P,!1))),c.set(this,(i(this,D),i(this,S,!1))),i(this,j)}},r=new WeakMap,m=new WeakMap,c=new WeakMap,e(f,"HeaderCategory"),(()=>{var e;const i="function"==typeof Symbol&&Symbol.metadata?Object.create(null!==(e=b[Symbol.metadata])&&void 0!==e?e:null):void 0;v=[h({type:String})],u=[h({type:Boolean})],k=[h({type:Boolean})],t(f,null,v,{kind:"accessor",name:"heading",static:!1,private:!1,access:{has:e=>"heading"in e,get:e=>e.heading,set:(e,t)=>{e.heading=t}},metadata:i},w,z),t(f,null,u,{kind:"accessor",name:"leftPadding",static:!1,private:!1,access:{has:e=>"leftPadding"in e,get:e=>e.leftPadding,set:(e,t)=>{e.leftPadding=t}},metadata:i},P,D),t(f,null,k,{kind:"accessor",name:"showDivider",static:!1,private:!1,access:{has:e=>"showDivider"in e,get:e=>e.showDivider,set:(e,t)=>{e.showDivider=t}},metadata:i},S,j),t(null,p={value:f},y,{kind:"class",name:f.name,metadata:i},null,x),f=p.value,i&&Object.defineProperty(f,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:i})})(),f.styles=l(g),i(f,x),f})();export{m as HeaderCategory};
|
|
110
121
|
//# sourceMappingURL=headerCategory.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"headerCategory.js","sources":["../../../../src/components/global/header/headerCategory.ts"],"sourcesContent":["import { LitElement, html, unsafeCSS } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport HeaderCategoryScss from './headerCategory.scss?inline';\n\n/**\n * Header link category\n * @slot unnamed - Slot for links.\n * @slot icon - Slot for icon.\n */\n@customElement('kyn-header-category')\nexport class HeaderCategory extends LitElement {\n static override styles = unsafeCSS(HeaderCategoryScss);\n\n /** Category text. */\n @property({ type: String })\n accessor heading = '';\n\n /** Add left padding when icon is not provided to align text with links that do have icons. */\n @property({ type: Boolean })\n accessor leftPadding = false;\n\n override render() {\n return html`\n <div class=\"category\">\n <div
|
|
1
|
+
{"version":3,"file":"headerCategory.js","sources":["../../../../src/components/global/header/headerCategory.ts"],"sourcesContent":["import { LitElement, html, unsafeCSS } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport HeaderCategoryScss from './headerCategory.scss?inline';\n\n/**\n * Header link category\n * @slot unnamed - Slot for links.\n * @slot icon - Slot for icon.\n */\n@customElement('kyn-header-category')\nexport class HeaderCategory extends LitElement {\n static override styles = unsafeCSS(HeaderCategoryScss);\n\n /** Category text. */\n @property({ type: String })\n accessor heading = '';\n\n /** Add left padding when icon is not provided to align text with links that do have icons. */\n @property({ type: Boolean })\n accessor leftPadding = false;\n\n /** Show bottom border/divider. */\n @property({ type: Boolean })\n accessor showDivider = false;\n\n override render() {\n return html`\n <div class=\"category ${this.showDivider ? 'divider' : ''}\"\">\n <div\n class=\"heading ${this.leftPadding ? 'left-padding' : ''}\n >\n <slot name=\"icon\"></slot>\n ${this.heading}\n </div>\n <div class=\"category__links\">\n <slot></slot>\n </div>\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'kyn-header-category': HeaderCategory;\n }\n}\n"],"names":["HeaderCategory","customElement","LitElement","_classThis","_classSuper","heading","__classPrivateFieldGet","this","_HeaderCategory_heading_accessor_storage","value","__classPrivateFieldSet","leftPadding","_HeaderCategory_leftPadding_accessor_storage","showDivider","_HeaderCategory_showDivider_accessor_storage","render","html","set","__runInitializers","_heading_initializers","_heading_extraInitializers","_leftPadding_initializers","_leftPadding_extraInitializers","_showDivider_initializers","_heading_decorators","property","type","String","_leftPadding_decorators","Boolean","_showDivider_decorators","__esDecorate","kind","name","static","private","access","has","obj","get","metadata","_metadata","_showDivider_extraInitializers","_classDescriptor","_classDecorators","_classExtraInitializers","styles","unsafeCSS","HeaderCategoryScss"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAUaA,EAAc,iCAD1BC,EAAc,+BACqBC,uCAARC,EAAA,cAAQC,EAKlC,WAASC,GAAO,OAAAC,EAAAC,KAAAC,EAAA,IAAA,CAAhB,WAASH,CAAOI,GAAAC,EAAAH,KAAAC,EAAAC,EAAA,IAAA,CAIhB,eAASE,GAAW,OAAAL,EAAAC,KAAAK,EAAA,IAAA,CAApB,eAASD,CAAWF,GAAAC,EAAAH,KAAA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EAASzB,YAAWI,IAAA,CAAAqB,EAAA7B,KAAA6B,EAAXzB,YAAWJ,CAAA,GAAA+B,SAAAC,GAAAlB,EAAAmB,GAbtBX,EAAA,KAAAY,EAAA,CAAAlC,MAAAN,GAAAyC,EAAA,CAAAZ,KAAA,QAAAC,KAAA9B,EAAA8B,KAAAO,SAAAC,GAAA,KAAAI,iHACkB1C,EAAA2C,OAASC,EAAUC,GADxB9B,EAAAf,EAAA0C,MAAc"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"headerLink.js","sources":["../../../../src/components/global/header/headerLink.ts"],"sourcesContent":["import { unsafeSVG } from 'lit-html/directives/unsafe-svg.js';\nimport { LitElement, html, unsafeCSS } from 'lit';\nimport {\n customElement,\n property,\n state,\n queryAssignedElements,\n} from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { styleMap } from 'lit/directives/style-map.js';\nimport { debounce } from '../../../common/helpers/helpers';\nimport HeaderLinkScss from './headerLink.scss?inline';\nimport '../../reusable/textInput';\nimport arrowIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/16/chevron-right.svg';\nimport backIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/16/arrow-left.svg';\nimport searchIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/16/search.svg';\n\nexport type HeaderLinkTarget = '_self' | '_blank' | '_parent' | '_top';\n\n/**\n * Component for navigation links within the Header.\n * @fires on-click - Captures the click event and emits the original event details. `detail:{ origEvent: Event ,defaultPrevented: boolean}`\n * @slot unnamed - Slot for link text/content.\n * @slot links - Slot for sublinks (up to two levels).\n * @slot icon - Slot for icon.\n */\n@customElement('kyn-header-link')\nexport class HeaderLink extends LitElement {\n static override styles = unsafeCSS(HeaderLinkScss);\n\n /** Link open state.\n * @internal\n */\n @property({ type: Boolean, reflect: true })\n accessor open = false;\n\n /** Link url. */\n @property({ type: String })\n accessor href = '';\n\n /** Defines a target attribute for where to load the URL. Possible options include \"_self\" (default), \"_blank\", \"_parent\", \"_top\" */\n @property({ type: String })\n accessor target: HeaderLinkTarget = '_self';\n\n /** Defines a relationship between a linked resource and the document. An empty string (default) means no particular relationship */\n @property({ type: String })\n accessor rel = '';\n\n /** Link active state, for example when URL path matches link href. */\n @property({ type: Boolean })\n accessor isActive = false;\n\n /** Link level, supports two levels.\n * @ignore\n */\n @state()\n accessor level = 1;\n\n /** DEPRECATED. Adds a 1px shadow to the bottom of the link. */\n @property({ type: Boolean })\n accessor divider = false;\n\n /** Label for sub-menu link search input, which is visible with > 5 sub-links. */\n @property({ type: String })\n accessor searchLabel = 'Search';\n\n /** Number of child links required to show search input. */\n @property({ type: Number })\n accessor searchThreshold = 6;\n\n /** Text for mobile \"Back\" button. */\n @property({ type: String })\n accessor backText = 'Back';\n\n /** Add left padding when icon is not provided to align text with links that do have icons. */\n @property({ type: Boolean })\n accessor leftPadding = false;\n\n /** Text for mobile \"Back\" button. */\n @state()\n accessor _searchTerm = '';\n\n /**\n * Queries any slotted HTML elements.\n * @ignore\n */\n @queryAssignedElements({ slot: 'links' })\n accessor slottedEls!: Array<HTMLElement>;\n\n /** Timeout function to delay flyout open.\n * @internal\n */\n _enterTimer: any;\n\n /** Timeout function to delay flyout close.\n * @internal\n */\n @state()\n accessor _leaveTimer: any;\n\n /** Menu positioning\n * @internal\n */\n @state()\n accessor menuPosition: any = {};\n\n override render() {\n const classes = {\n menu: this.slottedEls.length,\n [`level--${this.level}`]: true,\n divider: this.divider,\n open: this.open || (this.level === 1 && this.isActive),\n };\n\n const linkClasses = {\n 'nav-link': true,\n active: this.isActive,\n interactive: this.level == 1,\n 'padding-left': this.leftPadding,\n };\n\n const menuClasses = {\n menu__content: true,\n slotted: this.slottedEls.length,\n };\n\n const Links = this.querySelectorAll(\n ':scope > kyn-header-link, :scope > kyn-header-category > kyn-header-link'\n );\n\n return html`\n <div\n class=\"${classMap(classes)}\"\n @pointerleave=${(e: PointerEvent) => this.handlePointerLeave(e)}\n @pointerenter=${(e: PointerEvent) => this.handlePointerEnter(e)}\n >\n <a\n target=${this.target}\n rel=${this.rel}\n href=${this.href}\n class=${classMap(linkClasses)}\n @click=${(e: Event) => this.handleClick(e)}\n @pointerenter=${(e: PointerEvent) => this.handlePointerEnter(e)}\n >\n <slot></slot>\n\n ${this.slottedEls.length\n ? html` <span class=\"arrow\">${unsafeSVG(arrowIcon)}</span> `\n : null}\n </a>\n\n <div\n class=${classMap(menuClasses)}\n style=${styleMap(this.menuPosition)}\n >\n <div class=\"wrapper\">\n <button\n class=\"go-back\"\n type=\"button\"\n @click=${(e: Event) => this._handleBack(e)}\n >\n <span>${unsafeSVG(backIcon)}</span>\n ${this.backText}\n </button>\n ${Links.length >= this.searchThreshold\n ? html`\n <kyn-text-input\n hideLabel\n size=\"sm\"\n type=\"search\"\n label=${this.searchLabel}\n placeholder=${this.searchLabel}\n value=${this._searchTerm}\n @on-input=${(e: Event) => this._handleSearch(e)}\n >\n <span slot=\"icon\" class=\"search-icon\">\n ${unsafeSVG(searchIcon)}\n </span>\n ${this.searchLabel}\n </kyn-text-input>\n `\n : null}\n\n <slot\n name=\"links\"\n @slotchange=${this._handleLinksSlotChange}\n ></slot>\n </div>\n </div>\n </div>\n `;\n }\n\n private _handleSearch(e: any) {\n this._searchTerm = e.detail.value.toLowerCase();\n this._searchFilter();\n }\n\n private _searchFilter() {\n const Links: any = this.querySelectorAll(\n ':scope > kyn-header-link, :scope > kyn-header-category > kyn-header-link'\n );\n\n Links.forEach((link: any) => {\n // get link text\n const nodes: any = link.shadowRoot?.querySelector('slot')?.assignedNodes({\n flatten: true,\n });\n let linkText = '';\n for (let i = 0; i < nodes.length; i++) {\n linkText += nodes[i].textContent.trim();\n }\n\n if (linkText.toLowerCase().includes(this._searchTerm)) {\n link.style.display = 'block';\n } else {\n link.style.display = 'none';\n }\n });\n\n this._positionMenu();\n }\n\n private _handleBack(e?: Event) {\n if (e) {\n e.preventDefault();\n e.stopPropagation();\n }\n\n // detect if we're inside the categorized/mega nav variant\n const headerCategories = this.closest('kyn-header-categories') as\n | (HTMLElement & { handleBackClick?: (evt?: Event) => void })\n | null;\n\n if (headerCategories?.handleBackClick) {\n headerCategories.handleBackClick(e);\n\n // Close any open header links under this nav\n const navRoot =\n (this.closest('kyn-header-nav') as HTMLElement | null) ??\n headerCategories;\n\n const links = navRoot.querySelectorAll<HTMLElement & { open?: boolean }>(\n 'kyn-header-link[open]'\n );\n\n links.forEach((link) => {\n link.removeAttribute('open');\n if ('open' in link) {\n (link as any).open = false;\n }\n });\n\n // Clear local search for this column\n this._searchTerm = '';\n this._searchFilter();\n\n return;\n }\n\n // BASIC NAV:\n // Preserve original behavior: go up one level\n this.open = false;\n this._searchTerm = '';\n this._searchFilter();\n }\n\n private _handleLinksSlotChange() {\n this.requestUpdate();\n }\n\n private get _isDesktopViewport(): boolean {\n if (typeof window === 'undefined') return true;\n return window.innerWidth >= 672;\n }\n\n private handlePointerEnter(e: PointerEvent) {\n if (\n e.pointerType === 'mouse' &&\n this.slottedEls.length &&\n this._isDesktopViewport\n ) {\n clearTimeout(this._leaveTimer);\n\n this._enterTimer = setTimeout(() => {\n this.open = true;\n }, 150);\n }\n }\n\n private handlePointerLeave(e: PointerEvent) {\n if (\n e.pointerType === 'mouse' &&\n this.slottedEls.length &&\n this._searchTerm === '' &&\n this._isDesktopViewport\n ) {\n clearTimeout(this._enterTimer);\n this._leaveTimer = setTimeout(() => {\n this.open = false;\n }, 150);\n }\n }\n\n private handleClick(e: Event) {\n let preventDefault = false;\n\n if (this.slottedEls.length) {\n preventDefault = true;\n e.preventDefault();\n this.open = !this.open;\n }\n\n const event = new CustomEvent('on-click', {\n detail: { origEvent: e, defaultPrevented: preventDefault },\n });\n this.dispatchEvent(event);\n }\n\n private handleClickOut(e: Event) {\n if (!e.composedPath().includes(this)) {\n this.open = false;\n this._searchTerm = '';\n this._searchFilter();\n }\n }\n\n private determineLevel() {\n let level = 1;\n let node: any = this.parentNode;\n\n // Traverse up the DOM tree\n while (node) {\n if (node.nodeName === 'KYN-HEADER-LINK') {\n level = (node.level ?? 1) + 1;\n break;\n } else if (\n node.nodeName === 'KYN-HEADER-CATEGORY' &&\n node.parentNode?.nodeName === 'KYN-HEADER-LINK'\n ) {\n level = (node.parentNode.level ?? 1) + 1;\n break;\n } else if (\n window.innerWidth < 672 &&\n node.nodeName === 'KYN-HEADER-FLYOUT'\n ) {\n level = 2;\n break;\n }\n node = node.parentNode;\n }\n\n this.level = level;\n }\n\n private _positionMenu() {\n const linkBounds = this.getBoundingClientRect?.();\n const menuEl =\n this.shadowRoot?.querySelector<HTMLElement>('.menu__content');\n const menuBounds = menuEl?.getBoundingClientRect?.();\n\n if (!linkBounds || !menuBounds) {\n return;\n }\n\n const Padding = 12;\n const HeaderHeight = 64;\n\n const linkHalf = linkBounds.top + linkBounds.height / 2;\n const menuHalf = menuBounds.height / 2;\n\n const topCandidate =\n linkHalf + menuHalf > window.innerHeight\n ? linkHalf - menuHalf - (linkHalf + menuHalf - window.innerHeight) - 16\n : linkHalf - menuHalf;\n\n if (this.level === 1) {\n // get the height of the level 1 menu to use as submenu min-height\n let navMenuHeight = 0;\n const headerNav = this.closest('kyn-header-nav') as HTMLElement | null;\n if (headerNav) {\n const navMenu = headerNav.shadowRoot?.querySelector(\n '.menu__content'\n ) as HTMLElement | null;\n if (navMenu) {\n navMenuHeight = navMenu.offsetHeight;\n }\n }\n\n this.menuPosition = {\n top: HeaderHeight + 'px',\n left: '0px',\n minHeight: navMenuHeight + 'px',\n };\n } else {\n const top = topCandidate < HeaderHeight ? HeaderHeight : topCandidate;\n this.menuPosition = {\n top: top + 'px',\n left: linkBounds.right + Padding + 'px',\n };\n }\n }\n\n /** @internal */\n private _debounceResize = debounce(() => {\n this.determineLevel();\n });\n\n override firstUpdated() {\n this.determineLevel();\n }\n\n override willUpdate(changedProps: any) {\n if (changedProps.has('open') && this.open) {\n this._positionMenu();\n }\n }\n\n private _handleDocumentClick = (e: Event) => this.handleClickOut(e);\n\n override connectedCallback() {\n super.connectedCallback();\n document.addEventListener('click', this._handleDocumentClick);\n window.addEventListener('resize', this._debounceResize);\n }\n\n override disconnectedCallback() {\n // clear timers to avoid callbacks after unmount\n if (this._enterTimer) {\n clearTimeout(this._enterTimer);\n this._enterTimer = undefined;\n }\n if (this._leaveTimer) {\n clearTimeout(this._leaveTimer);\n this._leaveTimer = undefined;\n }\n\n document.removeEventListener('click', this._handleDocumentClick);\n window.removeEventListener('resize', this._debounceResize);\n super.disconnectedCallback();\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'kyn-header-link': HeaderLink;\n }\n}\n"],"names":["HeaderLink","customElement","LitElement","_classThis","_classSuper","_HeaderLink_open_accessor_storage","set","this","__runInitializers","_open_initializers","_HeaderLink_href_accessor_storage","_open_extraInitializers","_href_initializers","_HeaderLink_target_accessor_storage","_href_extraInitializers","_target_initializers","_HeaderLink_rel_accessor_storage","_target_extraInitializers","_rel_initializers","_HeaderLink_isActive_accessor_storage","_rel_extraInitializers","_isActive_initializers","_HeaderLink_level_accessor_storage","_isActive_extraInitializers","_level_initializers","_HeaderLink_divider_accessor_storage","_level_extraInitializers","_divider_initializers","_HeaderLink_searchLabel_accessor_storage","_divider_extraInitializers","_searchLabel_initializers","_HeaderLink_searchThreshold_accessor_storage","_searchLabel_extraInitializers","_searchThreshold_initializers","_HeaderLink_backText_accessor_storage","_searchThreshold_extraInitializers","_backText_initializers","_HeaderLink_leftPadding_accessor_storage","_backText_extraInitializers","_leftPadding_initializers","_HeaderLink__searchTerm_accessor_storage","_leftPadding_extraInitializers","__searchTerm_initializers","_HeaderLink_slottedEls_accessor_storage","__searchTerm_extraInitializers","_slottedEls_initializers","_enterTimer","_slottedEls_extraInitializers","_HeaderLink__leaveTimer_accessor_storage","__leaveTimer_initializers","_HeaderLink_menuPosition_accessor_storage","__leaveTimer_extraInitializers","_menuPosition_initializers","_debounceResize","_menuPosition_extraInitializers","debounce","determineLevel","_handleDocumentClick","e","handleClickOut","open","__classPrivateFieldGet","value","__classPrivateFieldSet","href","target","rel","isActive","level","divider","searchLabel","searchThreshold","backText","leftPadding","_searchTerm","slottedEls","_leaveTimer","menuPosition","render","classes","menu","length","linkClasses","active","interactive","menuClasses","menu__content","slotted","Links","querySelectorAll","html","classMap","handlePointerLeave","handlePointerEnter","handleClick","unsafeSVG","arrowIcon","styleMap","_handleBack","backIcon","_handleSearch","searchIcon","_handleLinksSlotChange","detail","toLowerCase","_searchFilter","forEach","link","nodes","_b","_a","shadowRoot","querySelector","assignedNodes","flatten","linkText","i","textContent","trim","includes","style","display","_positionMenu","preventDefault","stopPropagation","headerCategories","closest","handleBackClick","removeAttribute","requestUpdate","_isDesktopViewport","window","innerWidth","pointerType","clearTimeout","setTimeout","event","CustomEvent","origEvent","defaultPrevented","dispatchEvent","composedPath","node","parentNode","nodeName","_c","linkBounds","getBoundingClientRect","menuEl","menuBounds","call","linkHalf","top","height","menuHalf","topCandidate","innerHeight","navMenuHeight","headerNav","navMenu","_d","offsetHeight","HeaderHeight","left","minHeight","right","firstUpdated","willUpdate","changedProps","has","connectedCallback","super","document","addEventListener","disconnectedCallback","undefined","removeEventListener","property","type","Boolean","reflect","_href_decorators","String","_target_decorators","_rel_decorators","_isActive_decorators","_level_decorators","state","_divider_decorators","_searchLabel_decorators","_searchThreshold_decorators","Number","_backText_decorators","_leftPadding_decorators","__searchTerm_decorators","_slottedEls_decorators","queryAssignedElements","slot","__leaveTimer_decorators","_menuPosition_decorators","__esDecorate","_open_decorators","kind","name","static","private","access","obj","get","metadata","_metadata","_classDescriptor","_classDecorators","_classExtraInitializers","styles","unsafeCSS","HeaderLinkScss"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AAAC,OAAA,CAAArC,IAAAsC,GAAA,iBAAAA,EAAAC,IAAAD,GAAAA,EAASlI,aAAYvE,IAAA,CAAAyM,EAAAjJ,KAAAiJ,EAAZlI,aAAYf,CAAA,GAAAmJ,SAAAC,GAAA9J,GAAAE,IA7EvBkJ,EAAA,KAAAW,EAAA,CAAArJ,MAAA3D,GAAAiN,EAAA,CAAAV,KAAA,QAAAC,KAAAxM,EAAAwM,KAAAM,SAAAC,GAAA,KAAAG,iHACkBlN,EAAAmN,OAASC,EAAUC,GADxBhN,EAAAL,EAAAkN,MAAU"}
|
|
1
|
+
{"version":3,"file":"headerLink.js","sources":["../../../../src/components/global/header/headerLink.ts"],"sourcesContent":["import { unsafeSVG } from 'lit-html/directives/unsafe-svg.js';\nimport { LitElement, html, unsafeCSS } from 'lit';\nimport {\n customElement,\n property,\n state,\n queryAssignedElements,\n} from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { styleMap } from 'lit/directives/style-map.js';\nimport { debounce } from '../../../common/helpers/helpers';\nimport HeaderLinkScss from './headerLink.scss?inline';\nimport '../../reusable/textInput';\nimport arrowIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/16/chevron-right.svg';\nimport backIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/16/arrow-left.svg';\nimport searchIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/16/search.svg';\n\nexport type HeaderLinkTarget = '_self' | '_blank' | '_parent' | '_top';\n\n/**\n * Component for navigation links within the Header.\n * @fires on-click - Captures the click event and emits the original event details. `detail:{ origEvent: Event ,defaultPrevented: boolean}`\n * @slot unnamed - Slot for link text/content.\n * @slot links - Slot for sublinks (up to two levels).\n * @slot icon - Slot for icon.\n */\n@customElement('kyn-header-link')\nexport class HeaderLink extends LitElement {\n static override styles = unsafeCSS(HeaderLinkScss);\n\n /** Link open state.\n * @internal\n */\n @property({ type: Boolean, reflect: true })\n accessor open = false;\n\n /** Link url. */\n @property({ type: String })\n accessor href = '';\n\n /** Defines a target attribute for where to load the URL. Possible options include \"_self\" (default), \"_blank\", \"_parent\", \"_top\" */\n @property({ type: String })\n accessor target: HeaderLinkTarget = '_self';\n\n /** Defines a relationship between a linked resource and the document. An empty string (default) means no particular relationship */\n @property({ type: String })\n accessor rel = '';\n\n /** Link active state, for example when URL path matches link href. */\n @property({ type: Boolean })\n accessor isActive = false;\n\n /** Link level, supports two levels.\n * @ignore\n */\n @state()\n accessor level = 1;\n\n /** DEPRECATED. Adds a 1px shadow to the bottom of the link. */\n @property({ type: Boolean })\n accessor divider = false;\n\n /** Label for sub-menu link search input, which is visible with > 5 sub-links. */\n @property({ type: String })\n accessor searchLabel = 'Search';\n\n /** Number of child links required to show search input. */\n @property({ type: Number })\n accessor searchThreshold = 6;\n\n /** Text for mobile \"Back\" button. */\n @property({ type: String })\n accessor backText = 'Back';\n\n /** Add left padding when icon is not provided to align text with links that do have icons. */\n @property({ type: Boolean })\n accessor leftPadding = false;\n\n /** Text for mobile \"Back\" button. */\n @state()\n accessor _searchTerm = '';\n\n /**\n * Queries any slotted HTML elements.\n * @ignore\n */\n @queryAssignedElements({ slot: 'links' })\n accessor slottedEls!: Array<HTMLElement>;\n\n /** Timeout function to delay flyout open.\n * @internal\n */\n _enterTimer: any;\n\n /** Timeout function to delay flyout close.\n * @internal\n */\n @state()\n accessor _leaveTimer: any;\n\n /** Menu positioning\n * @internal\n */\n @state()\n accessor menuPosition: any = {};\n\n override render() {\n const classes = {\n menu: this.slottedEls.length,\n [`level--${this.level}`]: true,\n divider: this.divider,\n open: this.open || (this.level === 1 && this.isActive),\n };\n\n const linkClasses = {\n 'nav-link': true,\n active: this.isActive,\n interactive: this.level == 1,\n 'padding-left': this.leftPadding,\n };\n\n const menuClasses = {\n menu__content: true,\n slotted: this.slottedEls.length,\n };\n\n const Links = this.querySelectorAll(\n ':scope > kyn-header-link, :scope > kyn-header-category > kyn-header-link'\n );\n\n return html`\n <div\n class=\"${classMap(classes)}\"\n @pointerleave=${(e: PointerEvent) => this.handlePointerLeave(e)}\n @pointerenter=${(e: PointerEvent) => this.handlePointerEnter(e)}\n >\n <a\n target=${this.target}\n rel=${this.rel}\n href=${this.href}\n class=${classMap(linkClasses)}\n @click=${(e: Event) => this.handleClick(e)}\n @pointerenter=${(e: PointerEvent) => this.handlePointerEnter(e)}\n >\n <slot></slot>\n\n ${this.slottedEls.length\n ? html` <span class=\"arrow\">${unsafeSVG(arrowIcon)}</span> `\n : null}\n </a>\n\n <div\n class=${classMap(menuClasses)}\n style=${styleMap(this.menuPosition)}\n >\n <div class=\"wrapper\">\n <button\n class=\"go-back\"\n type=\"button\"\n @click=${(e: Event) => this._handleBack(e)}\n >\n <span>${unsafeSVG(backIcon)}</span>\n ${this.backText}\n </button>\n ${Links.length >= this.searchThreshold\n ? html`\n <kyn-text-input\n hideLabel\n size=\"sm\"\n type=\"search\"\n label=${this.searchLabel}\n placeholder=${this.searchLabel}\n value=${this._searchTerm}\n @on-input=${(e: Event) => this._handleSearch(e)}\n >\n <span slot=\"icon\" class=\"search-icon\">\n ${unsafeSVG(searchIcon)}\n </span>\n ${this.searchLabel}\n </kyn-text-input>\n `\n : null}\n\n <slot\n name=\"links\"\n @slotchange=${this._handleLinksSlotChange}\n ></slot>\n </div>\n </div>\n </div>\n `;\n }\n\n private _handleSearch(e: any) {\n this._searchTerm = e.detail.value.toLowerCase();\n this._searchFilter();\n }\n\n private _searchFilter() {\n const Links: any = this.querySelectorAll(\n ':scope > kyn-header-link, :scope > kyn-header-category > kyn-header-link'\n );\n\n Links.forEach((link: any) => {\n // get link text\n const nodes: any = link.shadowRoot?.querySelector('slot')?.assignedNodes({\n flatten: true,\n });\n let linkText = '';\n for (let i = 0; i < nodes.length; i++) {\n linkText += nodes[i].textContent.trim();\n }\n\n if (linkText.toLowerCase().includes(this._searchTerm)) {\n link.style.display = 'block';\n } else {\n link.style.display = 'none';\n }\n });\n\n this._positionMenu();\n }\n\n private _handleBack(e?: Event) {\n if (e) {\n e.preventDefault();\n e.stopPropagation();\n }\n\n // detect if we're inside the categorized/mega nav variant\n const headerCategories = this.closest('kyn-header-categories') as\n | (HTMLElement & { handleBackClick?: (evt?: Event) => void })\n | null;\n\n if (headerCategories?.handleBackClick) {\n headerCategories.handleBackClick(e);\n\n // Close any open header links under this nav\n const navRoot =\n (this.closest('kyn-header-nav') as HTMLElement | null) ??\n headerCategories;\n\n const links = navRoot.querySelectorAll<HTMLElement & { open?: boolean }>(\n 'kyn-header-link[open]'\n );\n\n links.forEach((link) => {\n link.removeAttribute('open');\n if ('open' in link) {\n (link as any).open = false;\n }\n });\n\n // Clear local search for this column\n this._searchTerm = '';\n this._searchFilter();\n\n return;\n }\n\n // BASIC NAV:\n // Preserve original behavior: go up one level\n this.open = false;\n this._searchTerm = '';\n this._searchFilter();\n }\n\n private _handleLinksSlotChange() {\n this.requestUpdate();\n }\n\n private get _isDesktopViewport(): boolean {\n if (typeof window === 'undefined') return true;\n return window.innerWidth >= 672;\n }\n\n private handlePointerEnter(e: PointerEvent) {\n if (\n e.pointerType === 'mouse' &&\n this.slottedEls.length &&\n this._isDesktopViewport\n ) {\n clearTimeout(this._leaveTimer);\n\n this._enterTimer = setTimeout(() => {\n this.open = true;\n }, 150);\n }\n }\n\n private handlePointerLeave(e: PointerEvent) {\n if (\n e.pointerType === 'mouse' &&\n this.slottedEls.length &&\n this._searchTerm === '' &&\n this._isDesktopViewport\n ) {\n clearTimeout(this._enterTimer);\n this._leaveTimer = setTimeout(() => {\n this.open = false;\n }, 150);\n }\n }\n\n private handleClick(e: Event) {\n let preventDefault = false;\n\n if (this.slottedEls.length) {\n preventDefault = true;\n e.preventDefault();\n this.open = !this.open;\n }\n\n const event = new CustomEvent('on-click', {\n detail: { origEvent: e, defaultPrevented: preventDefault },\n });\n this.dispatchEvent(event);\n }\n\n private handleClickOut(e: Event) {\n if (!e.composedPath().includes(this)) {\n this.open = false;\n this._searchTerm = '';\n this._searchFilter();\n }\n }\n\n private determineLevel() {\n let level = 1;\n let node: any = this.parentNode;\n\n // Traverse up the DOM tree\n while (node) {\n if (node.nodeName === 'KYN-HEADER-LINK') {\n level = (node.level ?? 1) + 1;\n break;\n } else if (\n node.nodeName === 'KYN-HEADER-CATEGORY' &&\n node.parentNode?.nodeName === 'KYN-HEADER-LINK'\n ) {\n level = (node.parentNode.level ?? 1) + 1;\n break;\n } else if (\n window.innerWidth < 672 &&\n node.nodeName === 'KYN-HEADER-FLYOUT'\n ) {\n level = 2;\n break;\n }\n node = node.parentNode;\n }\n\n this.level = level;\n }\n\n private _positionMenu() {\n const linkBounds = this.getBoundingClientRect?.();\n const menuEl =\n this.shadowRoot?.querySelector<HTMLElement>('.menu__content');\n const menuBounds = menuEl?.getBoundingClientRect?.();\n\n if (!linkBounds || !menuBounds) {\n return;\n }\n\n const Padding = 12;\n const HeaderHeight = 64;\n\n const linkHalf = linkBounds.top + linkBounds.height / 2;\n const menuHalf = menuBounds.height / 2;\n\n const topCandidate =\n linkHalf + menuHalf > window.innerHeight\n ? linkHalf - menuHalf - (linkHalf + menuHalf - window.innerHeight) - 16\n : linkHalf - menuHalf;\n\n if (this.level === 1) {\n // get the height of the level 1 menu to use as submenu min-height\n let navMenuHeight = 0;\n const headerNav = this.closest('kyn-header-nav') as HTMLElement | null;\n if (headerNav) {\n const navMenu = headerNav.shadowRoot?.querySelector(\n '.menu__content'\n ) as HTMLElement | null;\n if (navMenu) {\n navMenuHeight = navMenu.offsetHeight;\n }\n }\n\n this.menuPosition = {\n top: HeaderHeight + 'px',\n left: '0px',\n minHeight: navMenuHeight + 'px',\n };\n } else {\n const top = topCandidate < HeaderHeight ? HeaderHeight : topCandidate;\n this.menuPosition = {\n top: top + 'px',\n left: linkBounds.right + Padding + 'px',\n };\n }\n }\n\n /** @internal */\n private _debounceResize = debounce(() => {\n this.determineLevel();\n });\n\n override firstUpdated() {\n this.determineLevel();\n }\n\n override willUpdate(changedProps: any) {\n if (changedProps.has('open') && this.open) {\n this._positionMenu();\n }\n }\n\n private _handleDocumentClick = (e: Event) => this.handleClickOut(e);\n\n override connectedCallback() {\n super.connectedCallback();\n document.addEventListener('click', this._handleDocumentClick);\n window.addEventListener('resize', this._debounceResize);\n }\n\n override disconnectedCallback() {\n // clear timers to avoid callbacks after unmount\n if (this._enterTimer) {\n clearTimeout(this._enterTimer);\n this._enterTimer = undefined;\n }\n if (this._leaveTimer) {\n clearTimeout(this._leaveTimer);\n this._leaveTimer = undefined;\n }\n\n document.removeEventListener('click', this._handleDocumentClick);\n window.removeEventListener('resize', this._debounceResize);\n super.disconnectedCallback();\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'kyn-header-link': HeaderLink;\n }\n}\n"],"names":["HeaderLink","customElement","LitElement","_classThis","_classSuper","_HeaderLink_open_accessor_storage","set","this","__runInitializers","_open_initializers","_HeaderLink_href_accessor_storage","_open_extraInitializers","_href_initializers","_HeaderLink_target_accessor_storage","_href_extraInitializers","_target_initializers","_HeaderLink_rel_accessor_storage","_target_extraInitializers","_rel_initializers","_HeaderLink_isActive_accessor_storage","_rel_extraInitializers","_isActive_initializers","_HeaderLink_level_accessor_storage","_isActive_extraInitializers","_level_initializers","_HeaderLink_divider_accessor_storage","_level_extraInitializers","_divider_initializers","_HeaderLink_searchLabel_accessor_storage","_divider_extraInitializers","_searchLabel_initializers","_HeaderLink_searchThreshold_accessor_storage","_searchLabel_extraInitializers","_searchThreshold_initializers","_HeaderLink_backText_accessor_storage","_searchThreshold_extraInitializers","_backText_initializers","_HeaderLink_leftPadding_accessor_storage","_backText_extraInitializers","_leftPadding_initializers","_HeaderLink__searchTerm_accessor_storage","_leftPadding_extraInitializers","__searchTerm_initializers","_HeaderLink_slottedEls_accessor_storage","__searchTerm_extraInitializers","_slottedEls_initializers","_enterTimer","_slottedEls_extraInitializers","_HeaderLink__leaveTimer_accessor_storage","__leaveTimer_initializers","_HeaderLink_menuPosition_accessor_storage","__leaveTimer_extraInitializers","_menuPosition_initializers","_debounceResize","_menuPosition_extraInitializers","debounce","determineLevel","_handleDocumentClick","e","handleClickOut","open","__classPrivateFieldGet","value","__classPrivateFieldSet","href","target","rel","isActive","level","divider","searchLabel","searchThreshold","backText","leftPadding","_searchTerm","slottedEls","_leaveTimer","menuPosition","render","classes","menu","length","linkClasses","active","interactive","menuClasses","menu__content","slotted","Links","querySelectorAll","html","classMap","handlePointerLeave","handlePointerEnter","handleClick","unsafeSVG","arrowIcon","styleMap","_handleBack","backIcon","_handleSearch","searchIcon","_handleLinksSlotChange","detail","toLowerCase","_searchFilter","forEach","link","nodes","_b","_a","shadowRoot","querySelector","assignedNodes","flatten","linkText","i","textContent","trim","includes","style","display","_positionMenu","preventDefault","stopPropagation","headerCategories","closest","handleBackClick","removeAttribute","requestUpdate","_isDesktopViewport","window","innerWidth","pointerType","clearTimeout","setTimeout","event","CustomEvent","origEvent","defaultPrevented","dispatchEvent","composedPath","node","parentNode","nodeName","_c","linkBounds","getBoundingClientRect","menuEl","menuBounds","call","linkHalf","top","height","menuHalf","topCandidate","innerHeight","navMenuHeight","headerNav","navMenu","_d","offsetHeight","HeaderHeight","left","minHeight","right","firstUpdated","willUpdate","changedProps","has","connectedCallback","super","document","addEventListener","disconnectedCallback","undefined","removeEventListener","property","type","Boolean","reflect","_href_decorators","String","_target_decorators","_rel_decorators","_isActive_decorators","_level_decorators","state","_divider_decorators","_searchLabel_decorators","_searchThreshold_decorators","Number","_backText_decorators","_leftPadding_decorators","__searchTerm_decorators","_slottedEls_decorators","queryAssignedElements","slot","__leaveTimer_decorators","_menuPosition_decorators","__esDecorate","_open_decorators","kind","name","static","private","access","obj","get","metadata","_metadata","_classDescriptor","_classDecorators","_classExtraInitializers","styles","unsafeCSS","HeaderLinkScss"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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G,KAAA,WAAAC,KAAA,eAAAC,QAAA,EAAAC,SAAA,EAAAC,OAAA,CAAArC,IAAAsC,GAAA,iBAAAA,EAAAC,IAAAD,GAAAA,EAASlI,aAAYvE,IAAA,CAAAyM,EAAAjJ,KAAAiJ,EAAZlI,aAAYf,CAAA,GAAAmJ,SAAAC,GAAA9J,GAAAE,IA7EvBkJ,EAAA,KAAAW,EAAA,CAAArJ,MAAA3D,GAAAiN,EAAA,CAAAV,KAAA,QAAAC,KAAAxM,EAAAwM,KAAAM,SAAAC,GAAA,KAAAG,iHACkBlN,EAAAmN,OAASC,EAAUC,GADxBhN,EAAAL,EAAAkN,MAAU"}
|
|
@@ -214,7 +214,7 @@ span[slot=icon] {
|
|
|
214
214
|
${this._assistiveText}
|
|
215
215
|
</div>
|
|
216
216
|
</div>
|
|
217
|
-
`}_buttonSizeMap(){switch(this.size){case"sm":return"small";case"lg":return"large";default:return"medium"}}_handleFocus(){this._focused=!0,this.enableSearchHistory&&(this._expanded=!0)}_handleButtonClick(){this._expanded=!0,setTimeout((()=>{var e,t;null===(t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector("kyn-text-input"))||void 0===t||t.focus()}),0)}_handleInput(e){this.value=e.detail.value,this._focused=!0,this._checkForMatchingSuggestions();const t={value:e.detail.value};e.detail.origEvent&&(t.origEvent=e.detail.origEvent);const s=new CustomEvent("on-input",{detail:t});this.dispatchEvent(s)}_handleSuggestionClick(e,t){"click"!==e.type&&(this.value=t,this._assistiveText=`${this._assistiveTextStrings.selected} ${this.value}`)}_handleSuggestionWithMouseUp(e){var t,s;this.value=e,this._assistiveText=`${this._assistiveTextStrings.selected} ${this.value}`,null===(s=null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector("kyn-text-input"))||void 0===s||s.setValueAndNotify(this.value),this._focused=!1}_handleSuggestionWithMouseDown(e){e.preventDefault()}handleSearchKeydown(e){e.stopPropagation(),this.handleKeyboard(e,e.keyCode,"input")}handleListKeydown(e){9!==e.keyCode&&e.preventDefault(),this.handleKeyboard(e,e.keyCode,"list")}handleKeyboard(e,t,s){var i,a,n;const
|
|
217
|
+
`}_buttonSizeMap(){switch(this.size){case"sm":return"small";case"lg":return"large";default:return"medium"}}_handleFocus(){this._focused=!0,this.enableSearchHistory&&(this._expanded=!0)}_handleButtonClick(){this._expanded=!0,setTimeout((()=>{var e,t;null===(t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector("kyn-text-input"))||void 0===t||t.focus()}),0)}_handleInput(e){this.value=e.detail.value,this._focused=!0,this._checkForMatchingSuggestions();const t={value:e.detail.value};e.detail.origEvent&&(t.origEvent=e.detail.origEvent);const s=new CustomEvent("on-input",{detail:t});this.dispatchEvent(s)}_handleSuggestionClick(e,t){"click"!==e.type&&(this.value=t,this._assistiveText=`${this._assistiveTextStrings.selected} ${this.value}`)}_handleSuggestionWithMouseUp(e){var t,s;this.value=e,this._assistiveText=`${this._assistiveTextStrings.selected} ${this.value}`,null===(s=null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector("kyn-text-input"))||void 0===s||s.setValueAndNotify(this.value),this._focused=!1}_handleSuggestionWithMouseDown(e){e.preventDefault()}handleSearchKeydown(e){e.stopPropagation(),this.handleKeyboard(e,e.keyCode,"input")}handleListKeydown(e){9!==e.keyCode&&e.preventDefault(),this.handleKeyboard(e,e.keyCode,"list")}handleKeyboard(e,t,s){var i,a,n,o;const r=[...null===(i=this.shadowRoot)||void 0===i?void 0:i.querySelectorAll(".suggestion")],l=r.find((e=>e.getAttribute("highlighted"))),h=l?r.indexOf(l):0;switch(t){case 13:{e.preventDefault();const t=null===(a=r[h])||void 0===a?void 0:a.innerText;return null===(o=null===(n=this.shadowRoot)||void 0===n?void 0:n.querySelector("kyn-text-input"))||void 0===o||o.setValueAndNotify(t),"input"===s&&(this._assistiveText=`${this._assistiveTextStrings.selected} ${t}`),this._focused=!1,void(this._expanded=!1)}case 40:{const e=l?h===r.length-1?0:h+1:0;return r[h].removeAttribute("highlighted"),r[e].setAttribute("highlighted",!0),r[e].scrollIntoView({block:"nearest"}),void(this._assistiveText=`${this.suggestions[e]}`)}case 38:{const e=0===h?r.length-1:h-1;return r[h].removeAttribute("highlighted"),r[e].setAttribute("highlighted",!0),r[e].scrollIntoView({block:"nearest"}),void(this._assistiveText=`${this.suggestions[e]}`)}default:return}}_checkForMatchingSuggestions(){var e;if(""===this.value)return void(this._assistiveText=this._assistiveTextStrings.searchSuggestions);const t=[...null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelectorAll(".suggestion")],s=this.suggestions.findIndex((e=>e.toLowerCase().includes(this.value.toLowerCase())));t.forEach((e=>{e.removeAttribute("highlighted")})),-1!==s?(t[s].scrollIntoView({block:"nearest"}),this._assistiveText=`${this._assistiveTextStrings.found} ${this.suggestions[s]}`):this._assistiveText=`${this._assistiveTextStrings.noMatches} ${this.value}`}willUpdate(e){e.has("assistiveTextStrings")&&(this._assistiveTextStrings=f(b,this.assistiveTextStrings))}_renderSuggestionContent(e,t){const s=t||this.searchHistory.includes(e)?h`<span style="display:flex">${n(x)}</span>`:null;if(t)return h`
|
|
218
218
|
<div class="suggestion-content">
|
|
219
219
|
${s}
|
|
220
220
|
<span>${e}</span>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"search.js","sources":["../../../../src/components/reusable/search/search.ts"],"sourcesContent":["import { unsafeSVG } from 'lit-html/directives/unsafe-svg.js';\nimport { LitElement, html, unsafeCSS } from 'lit';\nimport { customElement, property, state, query } from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\nimport Styles from './search.scss?inline';\nimport '../textInput';\nimport '../button';\nimport searchIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/20/search.svg';\nimport historyIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/20/history.svg';\nimport { deepmerge } from 'deepmerge-ts';\n\nconst _defaultTextStrings = {\n searchSuggestions: 'Search suggestions.',\n noMatches: 'No matches found for',\n selected: 'Selected',\n found: 'Found',\n recentSearches: 'Recent searches',\n};\n\n/**\n * Search\n * @fires on-input - Emits the value on text input/clear.`detail:{ origEvent: InputEvent,value: string }`\n */\n@customElement('kyn-search')\nexport class Search extends LitElement {\n static override styles = unsafeCSS(Styles);\n\n /** Input name. */\n @property({ type: String })\n accessor name = '';\n\n /** Label text. */\n @property({ type: String })\n accessor label = 'Search';\n\n /** Expandable style search. */\n @property({ type: Boolean })\n accessor expandable = false;\n\n /** Input value. */\n @property({ type: String })\n accessor value = '';\n\n /** Input & button size. */\n @property({ type: String })\n accessor size = 'md';\n\n /** Disabled state. */\n @property({ type: Boolean })\n accessor disabled = false;\n\n /** Auto-suggest array of strings that should match the current value. Update this array externally after on-input. */\n @property({ type: Array })\n accessor suggestions: Array<string> = [];\n\n /** Auto-suggest history array of strings. Update this array externally after on-input. */\n @property({ type: Array })\n accessor searchHistory: Array<string> = [];\n\n /** Expandable style search button description (Required to support accessibility). */\n @property({ type: String })\n accessor expandableSearchBtnDescription = '';\n\n /** Assistive text strings. */\n @property({ type: Object })\n accessor assistiveTextStrings = _defaultTextStrings;\n\n /** To show history searches in suggestion panel */\n @property({ type: Boolean })\n accessor enableSearchHistory = false;\n\n /**\n * Internal assistive text strings.\n * @internal\n * */\n @state()\n accessor _assistiveTextStrings = _defaultTextStrings;\n\n /**\n * Assistive text for screen readers.\n * @internal\n */\n @state()\n accessor _assistiveText = 'Search suggestions.';\n\n /** Input focused state.\n * @internal\n */\n @state()\n accessor _focused = false;\n\n /** Expanded state.\n * @internal\n */\n @state()\n accessor _expanded = false;\n\n /** Expanded state.\n * @internal\n */\n @query('kyn-text-input')\n accessor _textInput!: any;\n\n override render() {\n const classes = {\n search: true,\n expanded: this._expanded,\n expandable: this.expandable,\n focused: this._focused,\n 'has-value': this.value !== '' || this.enableSearchHistory,\n };\n\n return html`\n <div class=\"${classMap(classes)}\">\n <kyn-button\n kind=\"secondary\"\n size=${this._buttonSizeMap()}\n description=${ifDefined(this.expandableSearchBtnDescription)}\n ?disabled=${this.disabled}\n @on-click=${this._handleButtonClick}\n >\n <span slot=\"icon\">${unsafeSVG(searchIcon)}</span>\n </kyn-button>\n\n <kyn-text-input\n name=${this.name}\n type=\"search\"\n placeholder=${this.label}\n hideLabel\n value=${this.value}\n size=${this.size}\n ?disabled=${this.disabled}\n @on-input=${(e: CustomEvent) => this._handleInput(e)}\n @focus=${this._handleFocus}\n autoComplete=\"off\"\n @keydown=${(e: any) => this.handleSearchKeydown(e)}\n >\n ${this.label}\n <span slot=\"icon\">${unsafeSVG(searchIcon)}</span>\n </kyn-text-input>\n\n <div\n class=\"suggestions\"\n @keydown=${(e: any) => this.handleListKeydown(e)}\n >\n ${(() => {\n const isSearchHistory =\n this.value === '' && this.enableSearchHistory;\n const listToRender = isSearchHistory\n ? this.searchHistory\n : this.suggestions;\n\n return html`\n ${isSearchHistory\n ? html`<div class=\"suggestion-title\">\n ${this.assistiveTextStrings.recentSearches}\n </div>`\n : null}\n ${listToRender.map(\n (suggestion) => html`\n <div\n class=\"suggestion\"\n @click=${(e: any) =>\n this._handleSuggestionClick(e, suggestion)}\n @mouseup=${() =>\n this._handleSuggestionWithMouseUp(suggestion)}\n @mousedown=${(e: any) =>\n this._handleSuggestionWithMouseDown(e)}\n >\n ${this._renderSuggestionContent(\n suggestion,\n isSearchHistory\n )}\n </div>\n `\n )}\n `;\n })()}\n </div>\n <div\n class=\"assistive-text\"\n role=\"status\"\n aria-live=\"assertive\"\n aria-relevant=\"additions text\"\n >\n ${this._assistiveText}\n </div>\n </div>\n `;\n }\n\n private _buttonSizeMap() {\n switch (this.size) {\n case 'sm':\n return 'small';\n case 'lg':\n return 'large';\n case 'md':\n default:\n return 'medium';\n }\n }\n\n private _handleFocus() {\n this._focused = true;\n\n if (this.enableSearchHistory) {\n this._expanded = true;\n }\n }\n\n private _handleButtonClick() {\n this._expanded = true;\n\n setTimeout(() => {\n this.shadowRoot?.querySelector('kyn-text-input')?.focus();\n }, 0);\n }\n\n private _handleInput(e: CustomEvent) {\n this.value = e.detail.value;\n this._focused = true;\n\n this._checkForMatchingSuggestions();\n\n const Detail: any = {\n value: e.detail.value,\n };\n\n if (e.detail.origEvent) {\n Detail.origEvent = e.detail.origEvent;\n }\n\n const event = new CustomEvent('on-input', {\n detail: Detail,\n });\n this.dispatchEvent(event);\n }\n\n private _handleSuggestionClick(e: any, suggestion: string) {\n if (e.type !== 'click') {\n this.value = suggestion;\n this._assistiveText = `${this._assistiveTextStrings.selected} ${this.value}`;\n }\n }\n\n private _handleSuggestionWithMouseUp(suggestion: string) {\n this.value = suggestion;\n this._assistiveText = `${this._assistiveTextStrings.selected} ${this.value}`;\n this.shadowRoot\n ?.querySelector('kyn-text-input')\n ?.setValueAndNotify(this.value);\n this._focused = false;\n }\n\n private _handleSuggestionWithMouseDown(e: any) {\n e.preventDefault();\n }\n\n private handleSearchKeydown(e: any) {\n e.stopPropagation();\n this.handleKeyboard(e, e.keyCode, 'input');\n }\n\n private handleListKeydown(e: any) {\n const TAB_KEY_CODE = 9;\n if (e.keyCode !== TAB_KEY_CODE) {\n e.preventDefault();\n }\n\n this.handleKeyboard(e, e.keyCode, 'list');\n }\n\n private handleKeyboard(e: any, keyCode: number, target: string) {\n // const SPACEBAR_KEY_CODE = [0, 32];\n const ENTER_KEY_CODE = 13;\n const DOWN_ARROW_KEY_CODE = 40;\n const UP_ARROW_KEY_CODE = 38;\n\n // get highlighted element + index and selected element\n const Els: any = this.shadowRoot?.querySelectorAll('.suggestion');\n const suggestionEls: any = [...Els];\n const highlightedEl = suggestionEls.find((option: any) =>\n option.getAttribute('highlighted')\n );\n const highlightedIndex = highlightedEl\n ? suggestionEls.indexOf(highlightedEl)\n : 0;\n\n // prevent page scroll on spacebar press\n // if (SPACEBAR_KEY_CODE.includes(keyCode)) {\n // e.preventDefault();\n // }\n\n switch (keyCode) {\n case ENTER_KEY_CODE: {\n // select highlighted option\n e.preventDefault();\n const selectedValue = suggestionEls[highlightedIndex].innerText;\n this.shadowRoot\n ?.querySelector('kyn-text-input')\n ?.setValueAndNotify(selectedValue);\n if (target === 'input')\n this._assistiveText = `${this._assistiveTextStrings.selected} ${selectedValue}`;\n this._focused = false;\n this._expanded = false;\n return;\n }\n case DOWN_ARROW_KEY_CODE: {\n // go to next option\n const nextIndex = !highlightedEl\n ? 0\n : highlightedIndex === suggestionEls.length - 1\n ? 0\n : highlightedIndex + 1;\n\n suggestionEls[highlightedIndex].removeAttribute('highlighted');\n suggestionEls[nextIndex].setAttribute('highlighted', true);\n\n // scroll to option\n suggestionEls[nextIndex].scrollIntoView({ block: 'nearest' });\n this._assistiveText = `${this.suggestions[nextIndex]}`;\n return;\n }\n case UP_ARROW_KEY_CODE: {\n // go to previous option\n const nextIndex =\n highlightedIndex === 0\n ? suggestionEls.length - 1\n : highlightedIndex - 1;\n\n suggestionEls[highlightedIndex].removeAttribute('highlighted');\n suggestionEls[nextIndex].setAttribute('highlighted', true);\n\n // scroll to option\n suggestionEls[nextIndex].scrollIntoView({ block: 'nearest' });\n this._assistiveText = `${this.suggestions[nextIndex]}`;\n return;\n }\n default: {\n return;\n }\n }\n }\n\n private _checkForMatchingSuggestions() {\n if (this.value === '') {\n this._assistiveText = this._assistiveTextStrings.searchSuggestions;\n return;\n }\n const Els: any = this.shadowRoot?.querySelectorAll('.suggestion');\n const suggestionEls: any = [...Els];\n const matchedOptionIndex = this.suggestions.findIndex((option) => {\n return option.toLowerCase().includes(this.value.toLowerCase());\n });\n suggestionEls.forEach((option: any) => {\n option.removeAttribute('highlighted');\n });\n if (matchedOptionIndex === -1) {\n this._assistiveText = `${this._assistiveTextStrings.noMatches} ${this.value}`;\n return;\n }\n suggestionEls[matchedOptionIndex].scrollIntoView({ block: 'nearest' });\n this._assistiveText = `${this._assistiveTextStrings.found} ${this.suggestions[matchedOptionIndex]}`;\n }\n\n override willUpdate(changedProps: any) {\n if (changedProps.has('assistiveTextStrings')) {\n this._assistiveTextStrings = deepmerge(\n _defaultTextStrings,\n this.assistiveTextStrings\n );\n }\n }\n\n private _renderSuggestionContent(\n suggestion: string,\n isSearchHistory: boolean\n ) {\n const showHistoryIcon =\n isSearchHistory || this.searchHistory.includes(suggestion);\n\n const iconTemplate = showHistoryIcon\n ? html`<span style=\"display:flex\">${unsafeSVG(historyIcon)}</span>`\n : null;\n\n if (isSearchHistory) {\n return html`\n <div class=\"suggestion-content\">\n ${iconTemplate}\n <span>${suggestion}</span>\n </div>\n `;\n }\n\n const escapedValue = this.value\n .trim()\n .replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\$&');\n const trailingSpace = this.value.endsWith(' ');\n\n const valueRegex = new RegExp(\n `(${escapedValue.replace(/\\s+/g, '\\\\s+')})`,\n 'ig'\n );\n\n if (!valueRegex.test(suggestion)) {\n return html`\n <div class=\"suggestion-content\">\n ${iconTemplate}\n <span>${suggestion}</span>\n </div>\n `;\n }\n\n const result = [];\n let lastIndex = 0;\n\n suggestion.replace(valueRegex, (match, _p1, offset) => {\n if (offset > lastIndex) {\n const textBefore = suggestion.slice(lastIndex, offset);\n result.push(this._wrapTextWithSpaces(textBefore));\n }\n result.push(html`<span class=\"bold-text\">${match}</span>`);\n lastIndex = offset + match.length;\n return match;\n });\n\n if (lastIndex < suggestion.length) {\n const textAfter = suggestion.slice(lastIndex);\n result.push(this._wrapTextWithSpaces(textAfter));\n }\n\n if (trailingSpace) {\n result.push(html`<span> </span>`);\n }\n\n return html`\n <div class=\"suggestion-content\">\n ${iconTemplate}\n <span class=\"text-parts\">${result}</span>\n </div>\n `;\n }\n\n private _wrapTextWithSpaces(text: string) {\n return html`${text\n .split(/(\\s)/)\n .map((part) =>\n part === ' '\n ? html`<span> </span>`\n : html`<span class=\"light-text\">${part}</span>`\n )}`;\n }\n\n private _handleClickOut(e: Event) {\n if (!e.composedPath().includes(this)) {\n setTimeout(() => {\n this._focused = false;\n if (this.value === '') {\n this._expanded = false;\n }\n }, 100);\n }\n }\n\n override connectedCallback() {\n super.connectedCallback();\n document.addEventListener('click', (e) => this._handleClickOut(e), true);\n }\n\n override disconnectedCallback() {\n super.disconnectedCallback();\n document.removeEventListener('click', (e) => this._handleClickOut(e), true);\n }\n}\n"],"names":["_defaultTextStrings","searchSuggestions","noMatches","selected","found","recentSearches","Search","customElement","LitElement","_classThis","_classSuper","name","__classPrivateFieldGet","this","_Search_name_accessor_storage","value","__classPrivateFieldSet","label","_Search_label_accessor_storage","expandable","_Search_expandable_accessor_storage","_Search_value_accessor_storage","size","_Search_size_accessor_storage","disabled","_Search_disabled_accessor_storage","suggestions","_Search_suggestions_accessor_storage","searchHistory","_Search_searchHistory_accessor_storage","expandableSearchBtnDescription","_Search_expandableSearchBtnDescription_accessor_storage","assistiveTextStrings","_Search_assistiveTextStrings_accessor_storage","enableSearchHistory","_Search_enableSearchHistory_accessor_storage","_assistiveTextStrings","_Search__assistiveTextStrings_accessor_storage","_assistiveText","_Search__assistiveText_accessor_storage","_focused","_Search__focused_accessor_storage","_expanded","_Search__expanded_accessor_storage","_textInput","_Search__textInput_accessor_storage","render","classes","search","expanded","focused","html","classMap","_buttonSizeMap","ifDefined","_handleButtonClick","unsafeSVG","searchIcon","e","_handleInput","_handleFocus","handleSearchKeydown","handleListKeydown","isSearchHistory","listToRender","map","suggestion","_handleSuggestionClick","_handleSuggestionWithMouseUp","_handleSuggestionWithMouseDown","_renderSuggestionContent","setTimeout","_b","_a","shadowRoot","querySelector","focus","detail","_checkForMatchingSuggestions","Detail","origEvent","event","CustomEvent","dispatchEvent","type","setValueAndNotify","preventDefault","stopPropagation","handleKeyboard","keyCode","target","suggestionEls","querySelectorAll","highlightedEl","find","option","getAttribute","highlightedIndex","indexOf","selectedValue","innerText","_c","nextIndex","length","removeAttribute","setAttribute","scrollIntoView","block","matchedOptionIndex","findIndex","toLowerCase","includes","forEach","willUpdate","changedProps","has","deepmerge","iconTemplate","historyIcon","escapedValue","trim","replace","trailingSpace","endsWith","valueRegex","RegExp","test","result","lastIndex","match","_p1","offset","textBefore","slice","push","_wrapTextWithSpaces","textAfter","text","split","part","_handleClickOut","composedPath","connectedCallback","super","document","addEventListener","disconnectedCallback","removeEventListener","set","__runInitializers","_name_initializers","_name_extraInitializers","_label_initializers","_label_extraInitializers","_expandable_initializers","_expandable_extraInitializers","_value_initializers","_value_extraInitializers","_size_initializers","_size_extraInitializers","_disabled_initializers","_disabled_extraInitializers","_suggestions_initializers","_suggestions_extraInitializers","_searchHistory_initializers","_searchHistory_extraInitializers","_expandableSearchBtnDescription_initializers","_expandableSearchBtnDescription_extraInitializers","_assistiveTextStrings_initializers","_assistiveTextStrings_extraInitializers","_enableSearchHistory_initializers","_enableSearchHistory_extraInitializers","__assistiveTextStrings_initializers","__assistiveTextStrings_extraInitializers","__assistiveText_initializers","__assistiveText_extraInitializers","__focused_initializers","__focused_extraInitializers","__expanded_initializers","__expanded_extraInitializers","__textInput_initializers","_name_decorators","property","String","_label_decorators","_expandable_decorators","Boolean","_value_decorators","_size_decorators","_disabled_decorators","_suggestions_decorators","Array","_searchHistory_decorators","_expandableSearchBtnDescription_decorators","_assistiveTextStrings_decorators","Object","_enableSearchHistory_decorators","__assistiveTextStrings_decorators","state","__assistiveText_decorators","__focused_decorators","__expanded_decorators","query","__esDecorate","kind","static","private","access","obj","get","metadata","_metadata","__textInput_decorators","__textInput_extraInitializers","_classDescriptor","_classDecorators","_classExtraInitializers","styles","unsafeCSS","Styles"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAYA,MAAMA,EAAsB,CAC1BC,kBAAmB,sBACnBC,UAAW,uBACXC,SAAU,WACVC,MAAO,QACPC,eAAgB,uBAQLC,EAAM,sFADlBC,EAAc,wBACaC,yMAARC,EAAA,cAAQC,GAK1B,QAASC,GAAI,OAAAC,EA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AAAA,EAAAC,IAAAD,GAAAA,EAAS1K,eAAc8G,IAAA,CAAA4D,EAAAjM,KAAAiM,EAAd1K,eAAcvB,CAAA,GAAAmM,SAAAC,GAAArC,GAAAC,IAMvB4B,EAAAlM,EAAA,KAAA+L,EAAA,CAAAI,KAAA,WAAAjM,KAAA,WAAAkM,QAAA,EAAAC,SAAA,EAAAC,OAAA,CAAA5F,IAAA6F,GAAA,aAAAA,EAAAC,IAAAD,GAAAA,EAASxK,SAAQ4G,IAAA,CAAA4D,EAAAjM,KAAAiM,EAARxK,SAAQzB,CAAA,GAAAmM,SAAAC,GAAAnC,GAAAC,IAMjB0B,EAAAlM,EAAA,KAAAgM,EAAA,CAAAG,KAAA,WAAAjM,KAAA,YAAAkM,QAAA,EAAAC,SAAA,EAAAC,OAAA,CAAA5F,IAAA6F,GAAA,cAAAA,EAAAC,IAAAD,GAAAA,EAAStK,UAAS0G,IAAA,CAAA4D,EAAAjM,KAAAiM,EAATtK,UAAS3B,CAAA,GAAAmM,SAAAC,GAAAjC,GAAAC,IAMlBwB,EAAAlM,EAAA,KAAA2M,EAAA,CAAAR,KAAA,WAAAjM,KAAA,aAAAkM,QAAA,EAAAC,SAAA,EAAAC,OAAA,CAAA5F,IAAA6F,GAAA,eAAAA,EAAAC,IAAAD,GAAAA,EAASpK,WAAUwG,IAAA,CAAA4D,EAAAjM,KAAAiM,EAAVpK,WAAU7B,CAAA,GAAAmM,SAAAC,GAAA/B,GAAAiC,IA7ErBV,EAAA,KAAAW,EAAA,CAAAvM,MAAAN,GAAA8M,GAAA,CAAAX,KAAA,QAAAjM,KAAAF,EAAAE,KAAAuM,SAAAC,GAAA,KAAAK,kHACkB/M,EAAAgN,OAASC,EAAUC,GADxBtE,EAAA5I,EAAA+M,OAAM"}
|
|
1
|
+
{"version":3,"file":"search.js","sources":["../../../../src/components/reusable/search/search.ts"],"sourcesContent":["import { unsafeSVG } from 'lit-html/directives/unsafe-svg.js';\nimport { LitElement, html, unsafeCSS } from 'lit';\nimport { customElement, property, state, query } from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\nimport Styles from './search.scss?inline';\nimport '../textInput';\nimport '../button';\nimport searchIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/20/search.svg';\nimport historyIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/20/history.svg';\nimport { deepmerge } from 'deepmerge-ts';\n\nconst _defaultTextStrings = {\n searchSuggestions: 'Search suggestions.',\n noMatches: 'No matches found for',\n selected: 'Selected',\n found: 'Found',\n recentSearches: 'Recent searches',\n};\n\n/**\n * Search\n * @fires on-input - Emits the value on text input/clear.`detail:{ origEvent: InputEvent,value: string }`\n */\n@customElement('kyn-search')\nexport class Search extends LitElement {\n static override styles = unsafeCSS(Styles);\n\n /** Input name. */\n @property({ type: String })\n accessor name = '';\n\n /** Label text. */\n @property({ type: String })\n accessor label = 'Search';\n\n /** Expandable style search. */\n @property({ type: Boolean })\n accessor expandable = false;\n\n /** Input value. */\n @property({ type: String })\n accessor value = '';\n\n /** Input & button size. */\n @property({ type: String })\n accessor size = 'md';\n\n /** Disabled state. */\n @property({ type: Boolean })\n accessor disabled = false;\n\n /** Auto-suggest array of strings that should match the current value. Update this array externally after on-input. */\n @property({ type: Array })\n accessor suggestions: Array<string> = [];\n\n /** Auto-suggest history array of strings. Update this array externally after on-input. */\n @property({ type: Array })\n accessor searchHistory: Array<string> = [];\n\n /** Expandable style search button description (Required to support accessibility). */\n @property({ type: String })\n accessor expandableSearchBtnDescription = '';\n\n /** Assistive text strings. */\n @property({ type: Object })\n accessor assistiveTextStrings = _defaultTextStrings;\n\n /** To show history searches in suggestion panel */\n @property({ type: Boolean })\n accessor enableSearchHistory = false;\n\n /**\n * Internal assistive text strings.\n * @internal\n * */\n @state()\n accessor _assistiveTextStrings = _defaultTextStrings;\n\n /**\n * Assistive text for screen readers.\n * @internal\n */\n @state()\n accessor _assistiveText = 'Search suggestions.';\n\n /** Input focused state.\n * @internal\n */\n @state()\n accessor _focused = false;\n\n /** Expanded state.\n * @internal\n */\n @state()\n accessor _expanded = false;\n\n /** Expanded state.\n * @internal\n */\n @query('kyn-text-input')\n accessor _textInput!: any;\n\n override render() {\n const classes = {\n search: true,\n expanded: this._expanded,\n expandable: this.expandable,\n focused: this._focused,\n 'has-value': this.value !== '' || this.enableSearchHistory,\n };\n\n return html`\n <div class=\"${classMap(classes)}\">\n <kyn-button\n kind=\"secondary\"\n size=${this._buttonSizeMap()}\n description=${ifDefined(this.expandableSearchBtnDescription)}\n ?disabled=${this.disabled}\n @on-click=${this._handleButtonClick}\n >\n <span slot=\"icon\">${unsafeSVG(searchIcon)}</span>\n </kyn-button>\n\n <kyn-text-input\n name=${this.name}\n type=\"search\"\n placeholder=${this.label}\n hideLabel\n value=${this.value}\n size=${this.size}\n ?disabled=${this.disabled}\n @on-input=${(e: CustomEvent) => this._handleInput(e)}\n @focus=${this._handleFocus}\n autoComplete=\"off\"\n @keydown=${(e: any) => this.handleSearchKeydown(e)}\n >\n ${this.label}\n <span slot=\"icon\">${unsafeSVG(searchIcon)}</span>\n </kyn-text-input>\n\n <div\n class=\"suggestions\"\n @keydown=${(e: any) => this.handleListKeydown(e)}\n >\n ${(() => {\n const isSearchHistory =\n this.value === '' && this.enableSearchHistory;\n const listToRender = isSearchHistory\n ? this.searchHistory\n : this.suggestions;\n\n return html`\n ${isSearchHistory\n ? html`<div class=\"suggestion-title\">\n ${this.assistiveTextStrings.recentSearches}\n </div>`\n : null}\n ${listToRender.map(\n (suggestion) => html`\n <div\n class=\"suggestion\"\n @click=${(e: any) =>\n this._handleSuggestionClick(e, suggestion)}\n @mouseup=${() =>\n this._handleSuggestionWithMouseUp(suggestion)}\n @mousedown=${(e: any) =>\n this._handleSuggestionWithMouseDown(e)}\n >\n ${this._renderSuggestionContent(\n suggestion,\n isSearchHistory\n )}\n </div>\n `\n )}\n `;\n })()}\n </div>\n <div\n class=\"assistive-text\"\n role=\"status\"\n aria-live=\"assertive\"\n aria-relevant=\"additions text\"\n >\n ${this._assistiveText}\n </div>\n </div>\n `;\n }\n\n private _buttonSizeMap() {\n switch (this.size) {\n case 'sm':\n return 'small';\n case 'lg':\n return 'large';\n case 'md':\n default:\n return 'medium';\n }\n }\n\n private _handleFocus() {\n this._focused = true;\n\n if (this.enableSearchHistory) {\n this._expanded = true;\n }\n }\n\n private _handleButtonClick() {\n this._expanded = true;\n\n setTimeout(() => {\n this.shadowRoot?.querySelector('kyn-text-input')?.focus();\n }, 0);\n }\n\n private _handleInput(e: CustomEvent) {\n this.value = e.detail.value;\n this._focused = true;\n\n this._checkForMatchingSuggestions();\n\n const Detail: any = {\n value: e.detail.value,\n };\n\n if (e.detail.origEvent) {\n Detail.origEvent = e.detail.origEvent;\n }\n\n const event = new CustomEvent('on-input', {\n detail: Detail,\n });\n this.dispatchEvent(event);\n }\n\n private _handleSuggestionClick(e: any, suggestion: string) {\n if (e.type !== 'click') {\n this.value = suggestion;\n this._assistiveText = `${this._assistiveTextStrings.selected} ${this.value}`;\n }\n }\n\n private _handleSuggestionWithMouseUp(suggestion: string) {\n this.value = suggestion;\n this._assistiveText = `${this._assistiveTextStrings.selected} ${this.value}`;\n this.shadowRoot\n ?.querySelector('kyn-text-input')\n ?.setValueAndNotify(this.value);\n this._focused = false;\n }\n\n private _handleSuggestionWithMouseDown(e: any) {\n e.preventDefault();\n }\n\n private handleSearchKeydown(e: any) {\n e.stopPropagation();\n this.handleKeyboard(e, e.keyCode, 'input');\n }\n\n private handleListKeydown(e: any) {\n const TAB_KEY_CODE = 9;\n if (e.keyCode !== TAB_KEY_CODE) {\n e.preventDefault();\n }\n\n this.handleKeyboard(e, e.keyCode, 'list');\n }\n\n private handleKeyboard(e: any, keyCode: number, target: string) {\n // const SPACEBAR_KEY_CODE = [0, 32];\n const ENTER_KEY_CODE = 13;\n const DOWN_ARROW_KEY_CODE = 40;\n const UP_ARROW_KEY_CODE = 38;\n\n // get highlighted element + index and selected element\n const Els: any = this.shadowRoot?.querySelectorAll('.suggestion');\n const suggestionEls: any = [...Els];\n const highlightedEl = suggestionEls.find((option: any) =>\n option.getAttribute('highlighted')\n );\n const highlightedIndex = highlightedEl\n ? suggestionEls.indexOf(highlightedEl)\n : 0;\n\n // prevent page scroll on spacebar press\n // if (SPACEBAR_KEY_CODE.includes(keyCode)) {\n // e.preventDefault();\n // }\n\n switch (keyCode) {\n case ENTER_KEY_CODE: {\n // select highlighted option\n e.preventDefault();\n const selectedValue = suggestionEls[highlightedIndex]?.innerText;\n this.shadowRoot\n ?.querySelector('kyn-text-input')\n ?.setValueAndNotify(selectedValue);\n if (target === 'input')\n this._assistiveText = `${this._assistiveTextStrings.selected} ${selectedValue}`;\n this._focused = false;\n this._expanded = false;\n return;\n }\n case DOWN_ARROW_KEY_CODE: {\n // go to next option\n const nextIndex = !highlightedEl\n ? 0\n : highlightedIndex === suggestionEls.length - 1\n ? 0\n : highlightedIndex + 1;\n\n suggestionEls[highlightedIndex].removeAttribute('highlighted');\n suggestionEls[nextIndex].setAttribute('highlighted', true);\n\n // scroll to option\n suggestionEls[nextIndex].scrollIntoView({ block: 'nearest' });\n this._assistiveText = `${this.suggestions[nextIndex]}`;\n return;\n }\n case UP_ARROW_KEY_CODE: {\n // go to previous option\n const nextIndex =\n highlightedIndex === 0\n ? suggestionEls.length - 1\n : highlightedIndex - 1;\n\n suggestionEls[highlightedIndex].removeAttribute('highlighted');\n suggestionEls[nextIndex].setAttribute('highlighted', true);\n\n // scroll to option\n suggestionEls[nextIndex].scrollIntoView({ block: 'nearest' });\n this._assistiveText = `${this.suggestions[nextIndex]}`;\n return;\n }\n default: {\n return;\n }\n }\n }\n\n private _checkForMatchingSuggestions() {\n if (this.value === '') {\n this._assistiveText = this._assistiveTextStrings.searchSuggestions;\n return;\n }\n const Els: any = this.shadowRoot?.querySelectorAll('.suggestion');\n const suggestionEls: any = [...Els];\n const matchedOptionIndex = this.suggestions.findIndex((option) => {\n return option.toLowerCase().includes(this.value.toLowerCase());\n });\n suggestionEls.forEach((option: any) => {\n option.removeAttribute('highlighted');\n });\n if (matchedOptionIndex === -1) {\n this._assistiveText = `${this._assistiveTextStrings.noMatches} ${this.value}`;\n return;\n }\n suggestionEls[matchedOptionIndex].scrollIntoView({ block: 'nearest' });\n this._assistiveText = `${this._assistiveTextStrings.found} ${this.suggestions[matchedOptionIndex]}`;\n }\n\n override willUpdate(changedProps: any) {\n if (changedProps.has('assistiveTextStrings')) {\n this._assistiveTextStrings = deepmerge(\n _defaultTextStrings,\n this.assistiveTextStrings\n );\n }\n }\n\n private _renderSuggestionContent(\n suggestion: string,\n isSearchHistory: boolean\n ) {\n const showHistoryIcon =\n isSearchHistory || this.searchHistory.includes(suggestion);\n\n const iconTemplate = showHistoryIcon\n ? html`<span style=\"display:flex\">${unsafeSVG(historyIcon)}</span>`\n : null;\n\n if (isSearchHistory) {\n return html`\n <div class=\"suggestion-content\">\n ${iconTemplate}\n <span>${suggestion}</span>\n </div>\n `;\n }\n\n const escapedValue = this.value\n .trim()\n .replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\$&');\n const trailingSpace = this.value.endsWith(' ');\n\n const valueRegex = new RegExp(\n `(${escapedValue.replace(/\\s+/g, '\\\\s+')})`,\n 'ig'\n );\n\n if (!valueRegex.test(suggestion)) {\n return html`\n <div class=\"suggestion-content\">\n ${iconTemplate}\n <span>${suggestion}</span>\n </div>\n `;\n }\n\n const result = [];\n let lastIndex = 0;\n\n suggestion.replace(valueRegex, (match, _p1, offset) => {\n if (offset > lastIndex) {\n const textBefore = suggestion.slice(lastIndex, offset);\n result.push(this._wrapTextWithSpaces(textBefore));\n }\n result.push(html`<span class=\"bold-text\">${match}</span>`);\n lastIndex = offset + match.length;\n return match;\n });\n\n if (lastIndex < suggestion.length) {\n const textAfter = suggestion.slice(lastIndex);\n result.push(this._wrapTextWithSpaces(textAfter));\n }\n\n if (trailingSpace) {\n result.push(html`<span> </span>`);\n }\n\n return html`\n <div class=\"suggestion-content\">\n ${iconTemplate}\n <span class=\"text-parts\">${result}</span>\n </div>\n `;\n }\n\n private _wrapTextWithSpaces(text: string) {\n return html`${text\n .split(/(\\s)/)\n .map((part) =>\n part === ' '\n ? html`<span> </span>`\n : html`<span class=\"light-text\">${part}</span>`\n )}`;\n }\n\n private _handleClickOut(e: Event) {\n if (!e.composedPath().includes(this)) {\n setTimeout(() => {\n this._focused = false;\n if (this.value === '') {\n this._expanded = false;\n }\n }, 100);\n }\n }\n\n override connectedCallback() {\n super.connectedCallback();\n document.addEventListener('click', (e) => this._handleClickOut(e), true);\n }\n\n override disconnectedCallback() {\n super.disconnectedCallback();\n document.removeEventListener('click', (e) => this._handleClickOut(e), true);\n }\n}\n"],"names":["_defaultTextStrings","searchSuggestions","noMatches","selected","found","recentSearches","Search","customElement","LitElement","_classThis","_classSuper","name","__classPrivateFieldGet","this","_Search_name_accessor_storage","value","__classPrivateFieldSet","label","_Search_label_accessor_storage","expandable","_Search_expandable_accessor_storage","_Search_value_accessor_storage","size","_Search_size_accessor_storage","disabled","_Search_disabled_accessor_storage","suggestions","_Search_suggestions_accessor_storage","searchHistory","_Search_searchHistory_accessor_storage","expandableSearchBtnDescription","_Search_expandableSearchBtnDescription_accessor_storage","assistiveTextStrings","_Search_assistiveTextStrings_accessor_storage","enableSearchHistory","_Search_enableSearchHistory_accessor_storage","_assistiveTextStrings","_Search__assistiveTextStrings_accessor_storage","_assistiveText","_Search__assistiveText_accessor_storage","_focused","_Search__focused_accessor_storage","_expanded","_Search__expanded_accessor_storage","_textInput","_Search__textInput_accessor_storage","render","classes","search","expanded","focused","html","classMap","_buttonSizeMap","ifDefined","_handleButtonClick","unsafeSVG","searchIcon","e","_handleInput","_handleFocus","handleSearchKeydown","handleListKeydown","isSearchHistory","listToRender","map","suggestion","_handleSuggestionClick","_handleSuggestionWithMouseUp","_handleSuggestionWithMouseDown","_renderSuggestionContent","setTimeout","_b","_a","shadowRoot","querySelector","focus","detail","_checkForMatchingSuggestions","Detail","origEvent","event","CustomEvent","dispatchEvent","type","setValueAndNotify","preventDefault","stopPropagation","handleKeyboard","keyCode","target","suggestionEls","querySelectorAll","highlightedEl","find","option","getAttribute","highlightedIndex","indexOf","selectedValue","innerText","_d","_c","nextIndex","length","removeAttribute","setAttribute","scrollIntoView","block","matchedOptionIndex","findIndex","toLowerCase","includes","forEach","willUpdate","changedProps","has","deepmerge","iconTemplate","historyIcon","escapedValue","trim","replace","trailingSpace","endsWith","valueRegex","RegExp","test","result","lastIndex","match","_p1","offset","textBefore","slice","push","_wrapTextWithSpaces","textAfter","text","split","part","_handleClickOut","composedPath","connectedCallback","super","document","addEventListener","disconnectedCallback","removeEventListener","set","__runInitializers","_name_initializers","_name_extraInitializers","_label_initializers","_label_extraInitializers","_expandable_initializers","_expandable_extraInitializers","_value_initializers","_value_extraInitializers","_size_initializers","_size_extraInitializers","_disabled_initializers","_disabled_extraInitializers","_suggestions_initializers","_suggestions_extraInitializers","_searchHistory_initializers","_searchHistory_extraInitializers","_expandableSearchBtnDescription_initializers","_expandableSearchBtnDescription_extraInitializers","_assistiveTextStrings_initializers","_assistiveTextStrings_extraInitializers","_enableSearchHistory_initializers","_enableSearchHistory_extraInitializers","__assistiveTextStrings_initializers","__assistiveTextStrings_extraInitializers","__assistiveText_initializers","__assistiveText_extraInitializers","__focused_initializers","__focused_extraInitializers","__expanded_initializers","__expanded_extraInitializers","__textInput_initializers","_name_decorators","property","String","_label_decorators","_expandable_decorators","Boolean","_value_decorators","_size_decorators","_disabled_decorators","_suggestions_decorators","Array","_searchHistory_decorators","_expandableSearchBtnDescription_decorators","_assistiveTextStrings_decorators","Object","_enableSearchHistory_decorators","__assistiveTextStrings_decorators","state","__assistiveText_decorators","__focused_decorators","__expanded_decorators","query","__esDecorate","kind","static","private","access","obj","get","metadata","_metadata","__textInput_decorators","__textInput_extraInitializers","_classDescriptor","_classDecorators","_classExtraInitializers","styles","unsafeCSS","Styles"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;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AAAlM,KAAAkM,EAAVrK,WAAU7B,CAAA,GAAAoM,SAAAC,GAAA/B,GAAAiC,IA7ErBV,EAAA,KAAAW,EAAA,CAAAxM,MAAAN,GAAA+M,GAAA,CAAAX,KAAA,QAAAlM,KAAAF,EAAAE,KAAAwM,SAAAC,GAAA,KAAAK,kHACkBhN,EAAAiN,OAASC,EAAUC,GADxBtE,EAAA7I,EAAAgN,OAAM"}
|
|
@@ -70,5 +70,13 @@ export declare const dataForColumns: {
|
|
|
70
70
|
col19: string;
|
|
71
71
|
col20: string;
|
|
72
72
|
}[];
|
|
73
|
+
export declare const dataForColumnsFilter: {
|
|
74
|
+
ticketPriority: string;
|
|
75
|
+
applnName: string;
|
|
76
|
+
businessService: string;
|
|
77
|
+
businessGroups: string;
|
|
78
|
+
ticketStatus: string;
|
|
79
|
+
criticalityRisk: number;
|
|
80
|
+
}[];
|
|
73
81
|
export {};
|
|
74
82
|
//# sourceMappingURL=ultils.sample.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ultils.sample.d.ts","sourceRoot":"","sources":["../../../../../src/components/reusable/table/story-helpers/ultils.sample.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AACzC,UAAU,MAAM;IACd,EAAE,EAAE,MAAM,CAAC;IACX,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;IACjB,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,eAAO,MAAM,WAAW,GAAI,eAAe,cAAc,MAC/C,GAAG,MAAM,EAAE,GAAG,MAAM,WAK7B,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,eAAe,cAAc,MAC/C,GAAG,MAAM,EAAE,GAAG,MAAM,WAK7B,CAAC;AAEF,eAAO,MAAM,QAAQ,GAAI,eAAe,cAAc,MAC5C,GAAG,M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,MAC9C,GAAG,MAAM,EAAE,GAAG,MAAM,WAY7B,CAAC;AAEF,eAAO,MAAM,WAAW,GACtB,WAAW,GAAG,EACd,YAAY,MAAM,EAClB,UAAU,MAAM,QAKjB,CAAC;AAEF,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAqDtB,CAAC;AAEF,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;GAoH1B,CAAC;AAEF,eAAO,MAAM,oBAAoB;;;;;;;GAyDhC,CAAC"}
|
|
@@ -9,6 +9,7 @@ import { SORT_DIRECTION, TABLE_CELL_ALIGN } from './defs';
|
|
|
9
9
|
*
|
|
10
10
|
* @fires on-sort-changed - Dispatched when the sort direction is changed. `detail: {sortDirection: string, sortKey: string } `
|
|
11
11
|
* @slot unnamed - The content slot for adding header text or content.
|
|
12
|
+
* @slot column-filter - slot for column filter.
|
|
12
13
|
*/
|
|
13
14
|
export declare class TableHeader extends LitElement {
|
|
14
15
|
static styles: import("lit").CSSResult;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"table-header.d.ts","sourceRoot":"","sources":["../../../../src/components/reusable/table/table-header.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAmB,cAAc,EAAE,MAAM,KAAK,CAAC;AAWlE,OAAO,EAAgB,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAKjE,OAAO,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AAE1D
|
|
1
|
+
{"version":3,"file":"table-header.d.ts","sourceRoot":"","sources":["../../../../src/components/reusable/table/table-header.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAmB,cAAc,EAAE,MAAM,KAAK,CAAC;AAWlE,OAAO,EAAgB,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAKjE,OAAO,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AAE1D;;;;;;;;;GASG;AACH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.js";import{css as
|
|
1
|
+
import{__setFunctionName as t,__esDecorate as e,__runInitializers as i,__classPrivateFieldGet as s,__classPrivateFieldSet as r}from"tslib";import{unsafeSVG as a}from"lit-html/directives/unsafe-svg.js";import{css as o,LitElement as n,unsafeCSS as l,html as h}from"lit";import{customElement as d,property as c,state as m,queryAssignedNodes as v}from"lit/decorators.js";import{classMap as g}from"lit-html/directives/class-map.js";import{ifDefined as p}from"lit/directives/if-defined.js";import{ContextConsumer as f}from"@lit/context";import{tableContext as u}from"./table-context.js";import{w as k}from"../../../vendor/@kyndryl-design-system/shidoka-icons-oqOblwTK.js";import{SORT_DIRECTION as b,TABLE_CELL_ALIGN as y}from"./defs.js";var x=o`*,
|
|
2
2
|
*::before,
|
|
3
3
|
*::after {
|
|
4
4
|
box-sizing: border-box;
|
|
@@ -138,12 +138,12 @@ import{__setFunctionName as t,__esDecorate as e,__runInitializers as i,__classPr
|
|
|
138
138
|
transform: rotate(180deg);
|
|
139
139
|
}
|
|
140
140
|
|
|
141
|
-
:host([sortable]:hover
|
|
141
|
+
:host([sortable]) .container:hover {
|
|
142
142
|
transition: background-color 0.3s;
|
|
143
143
|
color: var(--kd-color-text-level-tertiary);
|
|
144
144
|
cursor: pointer;
|
|
145
145
|
}
|
|
146
|
-
:host([sortable]:hover
|
|
146
|
+
:host([sortable]) .container:hover .sort-icon {
|
|
147
147
|
color: var(--kd-color-text-level-tertiary);
|
|
148
148
|
}
|
|
149
149
|
|
|
@@ -180,19 +180,31 @@ import{__setFunctionName as t,__esDecorate as e,__runInitializers as i,__classPr
|
|
|
180
180
|
position: absolute;
|
|
181
181
|
white-space: nowrap;
|
|
182
182
|
width: 1px;
|
|
183
|
-
}
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
::slotted([slot=column-filter]) {
|
|
186
|
+
display: flex;
|
|
187
|
+
align-items: center;
|
|
188
|
+
flex: 1;
|
|
189
|
+
min-width: 0;
|
|
190
|
+
gap: 8px;
|
|
191
|
+
align-self: stretch;
|
|
192
|
+
padding: 8px;
|
|
193
|
+
border-top: 1px solid var(--kd-color-border-variants-inverse);
|
|
194
|
+
border-bottom: 1px solid var(--kd-color-border-level-tertiary);
|
|
195
|
+
}`;let w=(()=>{var o,w,W,D,T,C,S,$,L,M,E,j,K,z;let H,A,I,_,F,P,U,B,O,N,X,q,G,J,Q,R,V=[d("kyn-th")],Y=[],Z=n,tt=[],et=[],it=[],st=[],rt=[],at=[],ot=[],nt=[],lt=[],ht=[],dt=[],ct=[],mt=[],vt=[],gt=[],pt=[],ft=[],ut=[],kt=[],bt=[],yt=[],xt=[],wt=[],Wt=[],Dt=[],Tt=[],Ct=[],St=[];return A=class extends Z{get role(){return s(this,o,"f")}set role(t){r(this,o,t,"f")}get dense(){return s(this,w,"f")}set dense(t){r(this,w,t,"f")}get _contextConsumer(){return s(this,W,"f")}set _contextConsumer(t){r(this,W,t,"f")}get align(){return s(this,D,"f")}set align(t){r(this,D,t,"f")}get sortable(){return s(this,T,"f")}set sortable(t){r(this,T,t,"f")}get sortDirection(){return s(this,C,"f")}set sortDirection(t){r(this,C,t,"f")}get headerLabel(){return s(this,S,"f")}set headerLabel(t){r(this,S,t,"f")}get sortKey(){return s(this,$,"f")}set sortKey(t){r(this,$,t,"f")}get visiblyHidden(){return s(this,L,"f")}set visiblyHidden(t){r(this,L,t,"f")}get width(){return s(this,M,"f")}set width(t){r(this,M,t,"f")}get maxWidth(){return s(this,E,"f")}set maxWidth(t){r(this,E,t,"f")}get minWidth(){return s(this,j,"f")}set minWidth(t){r(this,j,t,"f")}get listItems(){return s(this,K,"f")}set listItems(t){r(this,K,t,"f")}resetSort(){this.sortDirection=b.DEFAULT}get assistiveText(){return s(this,z,"f")}set assistiveText(t){r(this,z,t,"f")}toggleSortDirection(){if(this.sortKey){switch(this.sortDirection){case b.DEFAULT:case b.DESC:{this.sortDirection=b.ASC;const t=`Column header ${this.sortKey} sorted in ascending order`;this.assistiveText=""===this.assistiveText||this.assistiveText===t?`${t}.`:t;break}case b.ASC:{this.sortDirection=b.DESC;const t=`Column header ${this.sortKey} sorted in descending order`;this.assistiveText=""===this.assistiveText||this.assistiveText===t?`${t}.`:t;break}}this.dispatchEvent(new CustomEvent("on-sort-changed",{bubbles:!0,composed:!0,detail:{sortDirection:this.sortDirection,sortKey:this.sortKey}}))}else console.error("sortKey is missing for a sortable column.")}updated(t){this.getTextContent(),super.updated(t),this.maxWidth&&t.has("maxWidth")&&this.style.setProperty("--kyn-th-max-width",this.maxWidth),this.width&&t.has("width")&&this.style.setProperty("--kyn-th-width",this.width),this.minWidth&&t.has("minWidth")&&this.style.setProperty("--kyn-th-min-width",this.minWidth)}getTextContent(){var t;const e=this.listItems.filter((t=>{var e;return(null==t?void 0:t.nodeType)!==Node.TEXT_NODE||""!==(null===(e=null==t?void 0:t.textContent)||void 0===e?void 0:e.trim())}));this.headerLabel=(null===(t=e[0])||void 0===t?void 0:t.textContent)||""}render(){const t={"sort-icon":!0,"sort-icon--sorting":this.sortDirection!==b.DEFAULT,"sort-icon--sorting-asc":this.sortDirection===b.ASC,"sort-icon--sorting-desc":this.sortDirection===b.DESC},e={"slot-wrapper":!0,"sr-only":this.visiblyHidden},i=this.sortable?"button":void 0,s=this.sortable&&this.headerLabel?`Sort by ${this.headerLabel}`:void 0,r=this.sortable?0:void 0,o=this.sortable?t=>{"Enter"!==t.key&&" "!==t.key||this.toggleSortDirection()}:void 0;return h`
|
|
184
196
|
<div
|
|
185
197
|
class="container"
|
|
186
198
|
role=${p(i)}
|
|
187
199
|
@click=${this.sortable?()=>this.toggleSortDirection():void 0}
|
|
188
200
|
aria-label=${p(s)}
|
|
189
201
|
tabindex=${p(r)}
|
|
190
|
-
@keydown=${
|
|
202
|
+
@keydown=${o}
|
|
191
203
|
>
|
|
192
204
|
<div class=${g(e)}>
|
|
193
205
|
<slot></slot>
|
|
194
206
|
</div>
|
|
195
|
-
${this.sortable?
|
|
207
|
+
${this.sortable?h`<span class=${g(t)}
|
|
196
208
|
>${a(k)}</span
|
|
197
209
|
>`:null}
|
|
198
210
|
|
|
@@ -205,5 +217,6 @@ import{__setFunctionName as t,__esDecorate as e,__runInitializers as i,__classPr
|
|
|
205
217
|
${this.assistiveText}
|
|
206
218
|
</div>
|
|
207
219
|
</div>
|
|
208
|
-
|
|
220
|
+
<slot name="column-filter"> </slot>
|
|
221
|
+
`}constructor(){super(...arguments),o.set(this,i(this,tt,"columnheader")),w.set(this,(i(this,et),i(this,it,!1))),W.set(this,(i(this,st),i(this,rt,new f(this,u,(t=>{t&&this.handleContextChange(t)}),!0)))),this.handleContextChange=(i(this,at),({dense:t})=>{"boolean"==typeof t&&(this.dense=t)}),D.set(this,i(this,ot,y.LEFT)),T.set(this,(i(this,nt),i(this,lt,!1))),C.set(this,(i(this,ht),i(this,dt,b.DEFAULT))),S.set(this,(i(this,ct),i(this,mt,""))),$.set(this,(i(this,vt),i(this,gt,""))),L.set(this,(i(this,pt),i(this,ft,!1))),M.set(this,(i(this,ut),i(this,kt,""))),E.set(this,(i(this,bt),i(this,yt,""))),j.set(this,(i(this,xt),i(this,wt,""))),K.set(this,(i(this,Wt),i(this,Dt,void 0))),z.set(this,(i(this,Tt),i(this,Ct,""))),i(this,St)}},o=new WeakMap,w=new WeakMap,W=new WeakMap,D=new WeakMap,T=new WeakMap,C=new WeakMap,S=new WeakMap,$=new WeakMap,L=new WeakMap,M=new WeakMap,E=new WeakMap,j=new WeakMap,K=new WeakMap,z=new WeakMap,t(A,"TableHeader"),(()=>{var t;const i="function"==typeof Symbol&&Symbol.metadata?Object.create(null!==(t=Z[Symbol.metadata])&&void 0!==t?t:null):void 0;I=[c({type:String,reflect:!0})],_=[c({type:Boolean,reflect:!0})],F=[m()],P=[c({type:String,reflect:!0})],U=[c({type:Boolean,reflect:!0})],B=[c({type:String,reflect:!0})],O=[c({type:String})],N=[c({type:String})],X=[c({type:Boolean})],q=[c({type:String,reflect:!0})],G=[c({type:String,reflect:!0})],J=[c({type:String,reflect:!0})],Q=[v({flatten:!0})],R=[m()],e(A,null,I,{kind:"accessor",name:"role",static:!1,private:!1,access:{has:t=>"role"in t,get:t=>t.role,set:(t,e)=>{t.role=e}},metadata:i},tt,et),e(A,null,_,{kind:"accessor",name:"dense",static:!1,private:!1,access:{has:t=>"dense"in t,get:t=>t.dense,set:(t,e)=>{t.dense=e}},metadata:i},it,st),e(A,null,F,{kind:"accessor",name:"_contextConsumer",static:!1,private:!1,access:{has:t=>"_contextConsumer"in t,get:t=>t._contextConsumer,set:(t,e)=>{t._contextConsumer=e}},metadata:i},rt,at),e(A,null,P,{kind:"accessor",name:"align",static:!1,private:!1,access:{has:t=>"align"in t,get:t=>t.align,set:(t,e)=>{t.align=e}},metadata:i},ot,nt),e(A,null,U,{kind:"accessor",name:"sortable",static:!1,private:!1,access:{has:t=>"sortable"in t,get:t=>t.sortable,set:(t,e)=>{t.sortable=e}},metadata:i},lt,ht),e(A,null,B,{kind:"accessor",name:"sortDirection",static:!1,private:!1,access:{has:t=>"sortDirection"in t,get:t=>t.sortDirection,set:(t,e)=>{t.sortDirection=e}},metadata:i},dt,ct),e(A,null,O,{kind:"accessor",name:"headerLabel",static:!1,private:!1,access:{has:t=>"headerLabel"in t,get:t=>t.headerLabel,set:(t,e)=>{t.headerLabel=e}},metadata:i},mt,vt),e(A,null,N,{kind:"accessor",name:"sortKey",static:!1,private:!1,access:{has:t=>"sortKey"in t,get:t=>t.sortKey,set:(t,e)=>{t.sortKey=e}},metadata:i},gt,pt),e(A,null,X,{kind:"accessor",name:"visiblyHidden",static:!1,private:!1,access:{has:t=>"visiblyHidden"in t,get:t=>t.visiblyHidden,set:(t,e)=>{t.visiblyHidden=e}},metadata:i},ft,ut),e(A,null,q,{kind:"accessor",name:"width",static:!1,private:!1,access:{has:t=>"width"in t,get:t=>t.width,set:(t,e)=>{t.width=e}},metadata:i},kt,bt),e(A,null,G,{kind:"accessor",name:"maxWidth",static:!1,private:!1,access:{has:t=>"maxWidth"in t,get:t=>t.maxWidth,set:(t,e)=>{t.maxWidth=e}},metadata:i},yt,xt),e(A,null,J,{kind:"accessor",name:"minWidth",static:!1,private:!1,access:{has:t=>"minWidth"in t,get:t=>t.minWidth,set:(t,e)=>{t.minWidth=e}},metadata:i},wt,Wt),e(A,null,Q,{kind:"accessor",name:"listItems",static:!1,private:!1,access:{has:t=>"listItems"in t,get:t=>t.listItems,set:(t,e)=>{t.listItems=e}},metadata:i},Dt,Tt),e(A,null,R,{kind:"accessor",name:"assistiveText",static:!1,private:!1,access:{has:t=>"assistiveText"in t,get:t=>t.assistiveText,set:(t,e)=>{t.assistiveText=e}},metadata:i},Ct,St),e(null,H={value:A},V,{kind:"class",name:A.name,metadata:i},null,Y),A=H.value,i&&Object.defineProperty(A,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:i})})(),A.styles=l(x),i(A,Y),A})();export{w as TableHeader};
|
|
209
222
|
//# sourceMappingURL=table-header.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"table-header.js","sources":["../../../../src/components/reusable/table/table-header.ts"],"sourcesContent":["import { unsafeSVG } from 'lit-html/directives/unsafe-svg.js';\nimport { LitElement, html, unsafeCSS, PropertyValues } from 'lit';\nimport {\n customElement,\n property,\n queryAssignedNodes,\n state,\n} from 'lit/decorators.js';\nimport { classMap } from 'lit-html/directives/class-map.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\n\nimport { ContextConsumer } from '@lit/context';\nimport { tableContext, TableContextType } from './table-context';\n\nimport arrowUpIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/16/arrow-up.svg';\nimport styles from './table-header.scss?inline';\n\nimport { SORT_DIRECTION, TABLE_CELL_ALIGN } from './defs';\n\n/**\n * `kyn-th` Web Component.\n *\n * Represents a custom table header cell (`<th>`) for Shidoka's design system tables.\n * Provides sorting functionality when enabled and allows alignment customization.\n *\n * @fires on-sort-changed - Dispatched when the sort direction is changed. `detail: {sortDirection: string, sortKey: string } `\n * @slot unnamed - The content slot for adding header text or content.\n */\n@customElement('kyn-th')\nexport class TableHeader extends LitElement {\n static override styles = unsafeCSS(styles);\n\n /** aria role.\n * @internal\n */\n @property({ type: String, reflect: true })\n override accessor role = 'columnheader';\n\n /** Determines if the cell should have a denser layout. */\n @property({ type: Boolean, reflect: true })\n accessor dense = false;\n\n /**\n * Context consumer for the table context.\n * Updates the cell's dense properties when the context changes.\n * @private\n * @ignore\n * @type {ContextConsumer<TableContextType, TableHeader>}\n */\n @state()\n // @ts-expect-error - This is a context consumer\n private accessor _contextConsumer = new ContextConsumer(\n this,\n tableContext,\n (context) => {\n if (context) this.handleContextChange(context);\n },\n true\n );\n\n /**\n * Updates the cell's dense properties when the context changes.\n * @param {TableContextType} context - The updated context.\n */\n handleContextChange = ({ dense }: TableContextType) => {\n if (typeof dense == 'boolean') {\n this.dense = dense;\n }\n };\n\n /**\n * Specifies the alignment of the content within the table header.\n * Options: 'left', 'center', 'right'\n */\n @property({ type: String, reflect: true })\n accessor align: TABLE_CELL_ALIGN = TABLE_CELL_ALIGN.LEFT;\n\n /**\n * Specifies if the column is sortable.\n * If set to true, an arrow icon will be displayed unpon hover,\n * allowing the user to toggle sort directions.\n */\n @property({ type: Boolean, reflect: true })\n accessor sortable = false;\n\n /** Specifies the direction of sorting applied to the column. */\n @property({ type: String, reflect: true })\n accessor sortDirection: SORT_DIRECTION = SORT_DIRECTION.DEFAULT;\n\n /**\n * The textual content associated with this component.\n * Represents the primary content or label that will be displayed.\n */\n @property({ type: String })\n accessor headerLabel = '';\n\n /**\n * The unique identifier representing this column header.\n * Used to distinguish between different sortable columns and\n * to ensure that only one column is sorted at a time.\n */\n @property({ type: String })\n accessor sortKey = '';\n\n /**\n * Determines whether the content should be hidden from visual view but remain accessible\n * to screen readers for accessibility purposes. When set to `true`, the content\n * will not be visibly shown, but its content can still be read by screen readers.\n * This is especially useful for providing additional context or information to\n * assistive technologies without cluttering the visual UI.\n */\n @property({ type: Boolean })\n accessor visiblyHidden = false;\n\n /**\n * Sets a fixed width for the cell.\n * Accepts standard CSS width values (e.g., '150px', '50%').\n */\n @property({ type: String, reflect: true })\n accessor width = '';\n\n /**\n * Sets a maximum width for the cell.\n * Accepts standard CSS width values (e.g., '150px', '50%').\n */\n @property({ type: String, reflect: true })\n accessor maxWidth = '';\n\n /**\n * Sets a minimum width for the cell;\n * Accepts standard CSS width values (e.g., '150px', '50%').\n * @type {string}\n */\n @property({ type: String, reflect: true })\n accessor minWidth = '';\n\n /**\n * @ignore\n */\n @queryAssignedNodes({ flatten: true })\n accessor listItems!: Array<Node>;\n\n /**\n * Resets the sorting direction of the component to its default state.\n * Useful for initializing or clearing any applied sorting on the element.\n */\n resetSort() {\n this.sortDirection = SORT_DIRECTION.DEFAULT;\n }\n\n /**\n * Assistive text for screen readers.\n * @ignore\n */\n @state()\n accessor assistiveText = '';\n\n /**\n * Toggles the sort direction between ascending, descending, and default states.\n * It also dispatches an event to notify parent components of the sorting change.\n */\n private toggleSortDirection() {\n if (!this.sortKey) {\n console.error('sortKey is missing for a sortable column.');\n return;\n }\n\n switch (this.sortDirection) {\n case SORT_DIRECTION.DEFAULT:\n case SORT_DIRECTION.DESC: {\n this.sortDirection = SORT_DIRECTION.ASC;\n const assistiveText1 = `Column header ${this.sortKey} sorted in ascending order`;\n this.assistiveText =\n this.assistiveText === '' || this.assistiveText === assistiveText1\n ? `${assistiveText1}.`\n : assistiveText1;\n break;\n }\n case SORT_DIRECTION.ASC: {\n this.sortDirection = SORT_DIRECTION.DESC;\n const assistiveText2 = `Column header ${this.sortKey} sorted in descending order`;\n this.assistiveText =\n this.assistiveText === '' || this.assistiveText === assistiveText2\n ? `${assistiveText2}.`\n : assistiveText2;\n break;\n }\n }\n\n // Dispatch event to notify parent components of the sorting change\n this.dispatchEvent(\n new CustomEvent('on-sort-changed', {\n bubbles: true,\n composed: true,\n detail: { sortDirection: this.sortDirection, sortKey: this.sortKey },\n })\n );\n }\n\n override updated(changedProperties: PropertyValues) {\n this.getTextContent();\n\n super.updated(changedProperties);\n if (this.maxWidth && changedProperties.has('maxWidth')) {\n this.style.setProperty('--kyn-th-max-width', this.maxWidth);\n }\n\n if (this.width && changedProperties.has('width')) {\n this.style.setProperty('--kyn-th-width', this.width);\n }\n\n if (this.minWidth && changedProperties.has('minWidth')) {\n this.style.setProperty('--kyn-th-min-width', this.minWidth);\n }\n }\n\n getTextContent() {\n const nonWhitespaceNodes = this.listItems.filter((node) => {\n return (\n node?.nodeType !== Node.TEXT_NODE || node?.textContent?.trim() !== ''\n );\n });\n\n this.headerLabel = nonWhitespaceNodes[0]?.textContent || '';\n }\n\n override render() {\n const iconClasses = {\n 'sort-icon': true,\n 'sort-icon--sorting': this.sortDirection !== SORT_DIRECTION.DEFAULT,\n 'sort-icon--sorting-asc': this.sortDirection === SORT_DIRECTION.ASC,\n 'sort-icon--sorting-desc': this.sortDirection === SORT_DIRECTION.DESC,\n };\n\n const slotClasses = {\n 'slot-wrapper': true,\n 'sr-only': this.visiblyHidden,\n };\n\n /**\n * Accessibility Enhancements:\n * - role: Sets the appropriate role for interactive headers (e.g., when sortable).\n * - ariaSort: Indicates the sorting direction to assistive technologies.\n * - ariaLabel: Provides a descriptive label to assistive technologies for sortable headers.\n * - tabIndex: Enables keyboard interaction for sortable headers.\n * - onKeyDown: Handles keyboard events for sortable headers to allow sorting via the keyboard.\n */\n const role = this.sortable ? 'button' : undefined;\n // const arialSort = this.sortable ? this.sortDirection : undefined;\n const ariaLabel =\n this.sortable && this.headerLabel\n ? `Sort by ${this.headerLabel}`\n : undefined;\n const tabIndex = this.sortable ? 0 : undefined;\n const onKeyDown = this.sortable\n ? (e: KeyboardEvent) => {\n if (e.key === 'Enter' || e.key === ' ') {\n this.toggleSortDirection();\n }\n }\n : undefined;\n\n return html`\n <div\n class=\"container\"\n role=${ifDefined(role)}\n @click=${this.sortable ? () => this.toggleSortDirection() : undefined}\n aria-label=${ifDefined(ariaLabel)}\n tabindex=${ifDefined(tabIndex)}\n @keydown=${onKeyDown}\n >\n <div class=${classMap(slotClasses)}>\n <slot></slot>\n </div>\n ${this.sortable\n ? html`<span class=${classMap(iconClasses)}\n >${unsafeSVG(arrowUpIcon)}</span\n >`\n : null}\n\n <div\n class=\"assistive-text\"\n role=\"status\"\n aria-live=\"polite\"\n aria-relevant=\"additions text\"\n >\n ${this.assistiveText}\n </div>\n </div>\n `;\n }\n}\n\n// Define the custom element in the global namespace\ndeclare global {\n interface HTMLElementTagNameMap {\n 'kyn-th': TableHeader;\n }\n}\n"],"names":["TableHeader","customElement","LitElement","_classThis","_classSuper","role","__classPrivateFieldGet","this","_TableHeader_role_accessor_storage","value","__classPrivateFieldSet","dense","_TableHeader_dense_accessor_storage","_contextConsumer","_TableHeader__contextConsumer_accessor_storage","align","_TableHeader_align_accessor_storage","sortable","_TableHeader_sortable_accessor_storage","sortDirection","_TableHeader_sortDirection_accessor_storage","headerLabel","_TableHeader_headerLabel_accessor_storage","sortKey","_TableHeader_sortKey_accessor_storage","visiblyHidden","_TableHeader_visiblyHidden_accessor_storage","width","_TableHeader_width_accessor_storage","maxWidth","_TableHeader_maxWidth_accessor_storage","minWidth","_TableHeader_minWidth_accessor_storage","listItems","_TableHeader_listItems_accessor_storage","resetSort","SORT_DIRECTION","DEFAULT","assistiveText","_TableHeader_assistiveText_accessor_storage","toggleSortDirection","DESC","ASC","assistiveText1","assistiveText2","dispatchEvent","CustomEvent","bubbles","composed","detail","console","error","updated","changedProperties","getTextContent","super","has","style","setProperty","nonWhitespaceNodes","filter","node","nodeType","Node","TEXT_NODE","_a","textContent","trim","render","iconClasses","slotClasses","undefined","ariaLabel","tabIndex","onKeyDown","e","key","html","ifDefined","classMap","unsafeSVG","arrowUpIcon","set","__runInitializers","_role_initializers","_role_extraInitializers","_dense_initializers","_dense_extraInitializers","__contextConsumer_initializers","ContextConsumer","tableContext","context","handleContextChange","_align_initializers","TABLE_CELL_ALIGN","LEFT","_align_extraInitializers","_sortable_initializers","_sortable_extraInitializers","_sortDirection_initializers","_sortDirection_extraInitializers","_headerLabel_initializers","_headerLabel_extraInitializers","_sortKey_initializers","_sortKey_extraInitializers","_visiblyHidden_initializers","_visiblyHidden_extraInitializers","_width_initializers","_width_extraInitializers","_maxWidth_initializers","_maxWidth_extraInitializers","_minWidth_initializers","_minWidth_extraInitializers","_listItems_initializers","_listItems_extraInitializers","_assistiveText_initializers","property","type","String","reflect","Boolean","__contextConsumer_decorators","state","_headerLabel_decorators","_sortKey_decorators","_visiblyHidden_decorators","_listItems_decorators","queryAssignedNodes","flatten","_assistiveText_decorators","__esDecorate","_role_decorators","kind","name","static","private","access","obj","get","metadata","_metadata","_dense_decorators","__contextConsumer_extraInitializers","_align_decorators","_sortable_decorators","_sortDirection_decorators","_width_decorators","_maxWidth_decorators","_minWidth_decorators","_assistiveText_extraInitializers","_classDescriptor","_classDecorators","_classExtraInitializers","styles","unsafeCSS"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6BaA,EAAW,6EADvBC,EAAc,kBACkBC,iLAARC,EAAA,cAAQC,EAO/B,QAAkBC,GAAI,OAAAC,EAAAC,KAAAC,EAAA,IAAA,CAAtB,QAAkBH,CAAII,GAAAC,EAAAH,KAAAC,EAAAC,EAAA,IAAA,CAItB,SAASE,GAAK,OAAAL,EAAAC,KAAAK,EAAA,IAAA,CAAd,SAASD,CAAKF,GAAAC,EAAAH,KAAAK,EAAAH,EAAA,IAAA,CAWd,oBAAiBI,GAAgB,OAAAP,EAAAC,KAAAO,EAAA,IAAA,CAAjC,oBAAiBD,CAAgBJ,GAAAC,EAAAH,KAAAO,EAAAL,EAAA,IAAA,CAwBjC,SAASM,GAAK,OAAAT,EAAAC,KAAAS,EAAA,IAAA,CAAd,SAASD,CAAKN,GA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SAAAC,GAAAzB,GAAAkC,IA9HxBnB,EAAA,KAAAoB,EAAA,CAAA7I,MAAAN,GAAAoJ,EAAA,CAAAnB,KAAA,QAAAC,KAAAlI,EAAAkI,KAAAM,SAAAC,GAAA,KAAAY,iHACkBrJ,EAAAsJ,OAASC,EAAUD,GADxBtE,EAAAhF,EAAAqJ,MAAW"}
|
|
1
|
+
{"version":3,"file":"table-header.js","sources":["../../../../src/components/reusable/table/table-header.ts"],"sourcesContent":["import { unsafeSVG } from 'lit-html/directives/unsafe-svg.js';\nimport { LitElement, html, unsafeCSS, PropertyValues } from 'lit';\nimport {\n customElement,\n property,\n queryAssignedNodes,\n state,\n} from 'lit/decorators.js';\nimport { classMap } from 'lit-html/directives/class-map.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\n\nimport { ContextConsumer } from '@lit/context';\nimport { tableContext, TableContextType } from './table-context';\n\nimport arrowUpIcon from '@kyndryl-design-system/shidoka-icons/svg/monochrome/16/arrow-up.svg';\nimport styles from './table-header.scss?inline';\n\nimport { SORT_DIRECTION, TABLE_CELL_ALIGN } from './defs';\n\n/**\n * `kyn-th` Web Component.\n *\n * Represents a custom table header cell (`<th>`) for Shidoka's design system tables.\n * Provides sorting functionality when enabled and allows alignment customization.\n *\n * @fires on-sort-changed - Dispatched when the sort direction is changed. `detail: {sortDirection: string, sortKey: string } `\n * @slot unnamed - The content slot for adding header text or content.\n * @slot column-filter - slot for column filter.\n */\n@customElement('kyn-th')\nexport class TableHeader extends LitElement {\n static override styles = unsafeCSS(styles);\n\n /** aria role.\n * @internal\n */\n @property({ type: String, reflect: true })\n override accessor role = 'columnheader';\n\n /** Determines if the cell should have a denser layout. */\n @property({ type: Boolean, reflect: true })\n accessor dense = false;\n\n /**\n * Context consumer for the table context.\n * Updates the cell's dense properties when the context changes.\n * @private\n * @ignore\n * @type {ContextConsumer<TableContextType, TableHeader>}\n */\n @state()\n // @ts-expect-error - This is a context consumer\n private accessor _contextConsumer = new ContextConsumer(\n this,\n tableContext,\n (context) => {\n if (context) this.handleContextChange(context);\n },\n true\n );\n\n /**\n * Updates the cell's dense properties when the context changes.\n * @param {TableContextType} context - The updated context.\n */\n handleContextChange = ({ dense }: TableContextType) => {\n if (typeof dense == 'boolean') {\n this.dense = dense;\n }\n };\n\n /**\n * Specifies the alignment of the content within the table header.\n * Options: 'left', 'center', 'right'\n */\n @property({ type: String, reflect: true })\n accessor align: TABLE_CELL_ALIGN = TABLE_CELL_ALIGN.LEFT;\n\n /**\n * Specifies if the column is sortable.\n * If set to true, an arrow icon will be displayed unpon hover,\n * allowing the user to toggle sort directions.\n */\n @property({ type: Boolean, reflect: true })\n accessor sortable = false;\n\n /** Specifies the direction of sorting applied to the column. */\n @property({ type: String, reflect: true })\n accessor sortDirection: SORT_DIRECTION = SORT_DIRECTION.DEFAULT;\n\n /**\n * The textual content associated with this component.\n * Represents the primary content or label that will be displayed.\n */\n @property({ type: String })\n accessor headerLabel = '';\n\n /**\n * The unique identifier representing this column header.\n * Used to distinguish between different sortable columns and\n * to ensure that only one column is sorted at a time.\n */\n @property({ type: String })\n accessor sortKey = '';\n\n /**\n * Determines whether the content should be hidden from visual view but remain accessible\n * to screen readers for accessibility purposes. When set to `true`, the content\n * will not be visibly shown, but its content can still be read by screen readers.\n * This is especially useful for providing additional context or information to\n * assistive technologies without cluttering the visual UI.\n */\n @property({ type: Boolean })\n accessor visiblyHidden = false;\n\n /**\n * Sets a fixed width for the cell.\n * Accepts standard CSS width values (e.g., '150px', '50%').\n */\n @property({ type: String, reflect: true })\n accessor width = '';\n\n /**\n * Sets a maximum width for the cell.\n * Accepts standard CSS width values (e.g., '150px', '50%').\n */\n @property({ type: String, reflect: true })\n accessor maxWidth = '';\n\n /**\n * Sets a minimum width for the cell;\n * Accepts standard CSS width values (e.g., '150px', '50%').\n * @type {string}\n */\n @property({ type: String, reflect: true })\n accessor minWidth = '';\n\n /**\n * @ignore\n */\n @queryAssignedNodes({ flatten: true })\n accessor listItems!: Array<Node>;\n\n /**\n * Resets the sorting direction of the component to its default state.\n * Useful for initializing or clearing any applied sorting on the element.\n */\n resetSort() {\n this.sortDirection = SORT_DIRECTION.DEFAULT;\n }\n\n /**\n * Assistive text for screen readers.\n * @ignore\n */\n @state()\n accessor assistiveText = '';\n\n /**\n * Toggles the sort direction between ascending, descending, and default states.\n * It also dispatches an event to notify parent components of the sorting change.\n */\n private toggleSortDirection() {\n if (!this.sortKey) {\n console.error('sortKey is missing for a sortable column.');\n return;\n }\n\n switch (this.sortDirection) {\n case SORT_DIRECTION.DEFAULT:\n case SORT_DIRECTION.DESC: {\n this.sortDirection = SORT_DIRECTION.ASC;\n const assistiveText1 = `Column header ${this.sortKey} sorted in ascending order`;\n this.assistiveText =\n this.assistiveText === '' || this.assistiveText === assistiveText1\n ? `${assistiveText1}.`\n : assistiveText1;\n break;\n }\n case SORT_DIRECTION.ASC: {\n this.sortDirection = SORT_DIRECTION.DESC;\n const assistiveText2 = `Column header ${this.sortKey} sorted in descending order`;\n this.assistiveText =\n this.assistiveText === '' || this.assistiveText === assistiveText2\n ? `${assistiveText2}.`\n : assistiveText2;\n break;\n }\n }\n\n // Dispatch event to notify parent components of the sorting change\n this.dispatchEvent(\n new CustomEvent('on-sort-changed', {\n bubbles: true,\n composed: true,\n detail: { sortDirection: this.sortDirection, sortKey: this.sortKey },\n })\n );\n }\n\n override updated(changedProperties: PropertyValues) {\n this.getTextContent();\n\n super.updated(changedProperties);\n if (this.maxWidth && changedProperties.has('maxWidth')) {\n this.style.setProperty('--kyn-th-max-width', this.maxWidth);\n }\n\n if (this.width && changedProperties.has('width')) {\n this.style.setProperty('--kyn-th-width', this.width);\n }\n\n if (this.minWidth && changedProperties.has('minWidth')) {\n this.style.setProperty('--kyn-th-min-width', this.minWidth);\n }\n }\n\n getTextContent() {\n const nonWhitespaceNodes = this.listItems.filter((node) => {\n return (\n node?.nodeType !== Node.TEXT_NODE || node?.textContent?.trim() !== ''\n );\n });\n\n this.headerLabel = nonWhitespaceNodes[0]?.textContent || '';\n }\n\n override render() {\n const iconClasses = {\n 'sort-icon': true,\n 'sort-icon--sorting': this.sortDirection !== SORT_DIRECTION.DEFAULT,\n 'sort-icon--sorting-asc': this.sortDirection === SORT_DIRECTION.ASC,\n 'sort-icon--sorting-desc': this.sortDirection === SORT_DIRECTION.DESC,\n };\n\n const slotClasses = {\n 'slot-wrapper': true,\n 'sr-only': this.visiblyHidden,\n };\n\n /**\n * Accessibility Enhancements:\n * - role: Sets the appropriate role for interactive headers (e.g., when sortable).\n * - ariaSort: Indicates the sorting direction to assistive technologies.\n * - ariaLabel: Provides a descriptive label to assistive technologies for sortable headers.\n * - tabIndex: Enables keyboard interaction for sortable headers.\n * - onKeyDown: Handles keyboard events for sortable headers to allow sorting via the keyboard.\n */\n const role = this.sortable ? 'button' : undefined;\n // const arialSort = this.sortable ? this.sortDirection : undefined;\n const ariaLabel =\n this.sortable && this.headerLabel\n ? `Sort by ${this.headerLabel}`\n : undefined;\n const tabIndex = this.sortable ? 0 : undefined;\n const onKeyDown = this.sortable\n ? (e: KeyboardEvent) => {\n if (e.key === 'Enter' || e.key === ' ') {\n this.toggleSortDirection();\n }\n }\n : undefined;\n\n return html`\n <div\n class=\"container\"\n role=${ifDefined(role)}\n @click=${this.sortable ? () => this.toggleSortDirection() : undefined}\n aria-label=${ifDefined(ariaLabel)}\n tabindex=${ifDefined(tabIndex)}\n @keydown=${onKeyDown}\n >\n <div class=${classMap(slotClasses)}>\n <slot></slot>\n </div>\n ${this.sortable\n ? html`<span class=${classMap(iconClasses)}\n >${unsafeSVG(arrowUpIcon)}</span\n >`\n : null}\n\n <div\n class=\"assistive-text\"\n role=\"status\"\n aria-live=\"polite\"\n aria-relevant=\"additions text\"\n >\n ${this.assistiveText}\n </div>\n </div>\n <slot name=\"column-filter\"> </slot>\n `;\n }\n}\n\n// Define the custom element in the global namespace\ndeclare global {\n interface HTMLElementTagNameMap {\n 'kyn-th': TableHeader;\n }\n}\n"],"names":["TableHeader","customElement","LitElement","_classThis","_classSuper","role","__classPrivateFieldGet","this","_TableHeader_role_accessor_storage","value","__classPrivateFieldSet","dense","_TableHeader_dense_accessor_storage","_contextConsumer","_TableHeader__contextConsumer_accessor_storage","align","_TableHeader_align_accessor_storage","sortable","_TableHeader_sortable_accessor_storage","sortDirection","_TableHeader_sortDirection_accessor_storage","headerLabel","_TableHeader_headerLabel_accessor_storage","sortKey","_TableHeader_sortKey_accessor_storage","visiblyHidden","_TableHeader_visiblyHidden_accessor_storage","width","_TableHeader_width_accessor_storage","maxWidth","_TableHeader_maxWidth_accessor_storage","minWidth","_TableHeader_minWidth_accessor_storage","listItems","_TableHeader_listItems_accessor_storage","resetSort","SORT_DIRECTION","DEFAULT","assistiveText","_TableHeader_assistiveText_accessor_storage","toggleSortDirection","DESC","ASC","assistiveText1","assistiveText2","dispatchEvent","CustomEvent","bubbles","composed","detail","console","error","updated","changedProperties","getTextContent","super","has","style","setProperty","nonWhitespaceNodes","filter","node","nodeType","Node","TEXT_NODE","_a","textContent","trim","render","iconClasses","slotClasses","undefined","ariaLabel","tabIndex","onKeyDown","e","key","html","ifDefined","classMap","unsafeSVG","arrowUpIcon","set","__runInitializers","_role_initializers","_role_extraInitializers","_dense_initializers","_dense_extraInitializers","__contextConsumer_initializers","ContextConsumer","tableContext","context","handleContextChange","_align_initializers","TABLE_CELL_ALIGN","LEFT","_align_extraInitializers","_sortable_initializers","_sortable_extraInitializers","_sortDirection_initializers","_sortDirection_extraInitializers","_headerLabel_initializers","_headerLabel_extraInitializers","_sortKey_initializers","_sortKey_extraInitializers","_visiblyHidden_initializers","_visiblyHidden_extraInitializers","_width_initializers","_width_extraInitializers","_maxWidth_initializers","_maxWidth_extraInitializers","_minWidth_initializers","_minWidth_extraInitializers","_listItems_initializers","_listItems_extraInitializers","_assistiveText_initializers","property","type","String","reflect","Boolean","__contextConsumer_decorators","state","_headerLabel_decorators","_sortKey_decorators","_visiblyHidden_decorators","_listItems_decorators","queryAssignedNodes","flatten","_assistiveText_decorators","__esDecorate","_role_decorators","kind","name","static","private","access","obj","get","metadata","_metadata","_dense_decorators","__contextConsumer_extraInitializers","_align_decorators","_sortable_decorators","_sortDirection_decorators","_width_decorators","_maxWidth_decorators","_minWidth_decorators","_assistiveText_extraInitializers","_classDescriptor","_classDecorators","_classExtraInitializers","styles","unsafeCSS"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA8BaA,EAAW,6EADvBC,EAAc,kBACkBC,iLAARC,EAAA,cAAQC,EAO/B,QAAkBC,GAAI,OAAAC,EAAAC,KAAAC,EAAA,IAAA,CAAtB,QAAkBH,CAAII,GAAAC,EAAAH,KAAAC,EAAAC,EAAA,IAAA,CAItB,SAASE,GAAK,OAAAL,EAAAC,KAAAK,EAAA,IAAA,CAAd,SAASD,CAAKF,GAAAC,EAAAH,KAAAK,EAAAH,EAAA,IAAA,CAWd,oBAAiBI,GAAgB,OAAAP,EAAAC,KAAAO,EAAA,IAAA,CAAjC,oBAAiBD,CAAgBJ,GAAAC,EAAAH,KAAAO,EAAAL,EAAA,IAAA,CAwBjC,SAASM,GAAK,OAAAT,EAAAC,KAAAS,EAAA,IAAA,CAAd,SAASD,CAAKN,GAAAC,EAAAH,KAAAS,EAAAP,EAAA,IAAA,CAQd,YAASQ,GAAQ,OAAAX,EAAAC,KAAAW,EAAA,IAAA,CAAjB,YAASD,CAAQR,GAAAC,EAAAH,KAAAW,EAAAT,EAAA,IAAA,CAIjB,iBAASU,GAAa,OAAAb,EAAAC,KAAAa,EAAA,IAAA,CAAtB,iBAASD,CAAaV,GAAAC,EAAAH,KAAAa,EAAAX,EAAA,IAAA,CAOtB,eAASY,GAAW,OAAAf,EAA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l-design-system/shidoka-applications",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.78.0",
|
|
4
4
|
"description": "Shidoka Web Components for Applications",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "index.js",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@floating-ui/dom": "^1.7.1",
|
|
33
|
-
"@kyndryl-design-system/shidoka-foundation": "^2.8.
|
|
33
|
+
"@kyndryl-design-system/shidoka-foundation": "^2.8.7",
|
|
34
34
|
"@kyndryl-design-system/shidoka-icons": "^2.19.0",
|
|
35
35
|
"@lit/context": "^1.1.0",
|
|
36
36
|
"deepmerge-ts": "^7.1.0",
|
|
@@ -79,7 +79,7 @@
|
|
|
79
79
|
"husky": "^8.0.3",
|
|
80
80
|
"lint-staged": "^15.4.3",
|
|
81
81
|
"lit-analyzer": "^2.0.3",
|
|
82
|
-
"playwright": "^1.
|
|
82
|
+
"playwright": "^1.58.0",
|
|
83
83
|
"postcss": "^8.4.21",
|
|
84
84
|
"prettier": "^2.8.2",
|
|
85
85
|
"remark-gfm": "^4.0.0",
|