@govtechsg/sgds-web-component 3.30.1-rc.7 → 3.30.1-rc.8
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/Mainnav/index.umd.min.js +1 -1
- package/components/Mainnav/index.umd.min.js.map +1 -1
- package/components/Mainnav/mainnav-item.js +1 -1
- package/components/Mainnav/mainnav-item.js.map +1 -1
- package/components/Mainnav/sgds-mainnav-item.js +1 -1
- package/components/Mainnav/sgds-mainnav-item.js.map +1 -1
- package/components/Sidenav/index.umd.min.js +4 -2
- package/components/Sidenav/index.umd.min.js.map +1 -1
- package/components/Sidenav/sgds-sidenav-item.js +3 -1
- package/components/Sidenav/sgds-sidenav-item.js.map +1 -1
- package/components/Sidenav/sidenav-item.js +1 -1
- package/components/Sidenav/sidenav-item.js.map +1 -1
- package/components/Table/index.umd.min.js +1 -1
- package/components/Table/index.umd.min.js.map +1 -1
- package/components/Table/table-cell.js +1 -1
- package/components/Table/table-cell.js.map +1 -1
- package/components/Table/table-row.js +1 -1
- package/components/Table/table-row.js.map +1 -1
- package/components/index.umd.min.js +7 -5
- package/components/index.umd.min.js.map +1 -1
- package/custom-elements.json +1 -1
- package/index.umd.min.js +6 -4
- package/index.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/react/components/Mainnav/mainnav-item.cjs.js +1 -1
- package/react/components/Mainnav/mainnav-item.cjs.js.map +1 -1
- package/react/components/Mainnav/mainnav-item.js +1 -1
- package/react/components/Mainnav/mainnav-item.js.map +1 -1
- package/react/components/Mainnav/sgds-mainnav-item.cjs.js +1 -1
- package/react/components/Mainnav/sgds-mainnav-item.cjs.js.map +1 -1
- package/react/components/Mainnav/sgds-mainnav-item.js +1 -1
- package/react/components/Mainnav/sgds-mainnav-item.js.map +1 -1
- package/react/components/Sidenav/sgds-sidenav-item.cjs.js +3 -1
- package/react/components/Sidenav/sgds-sidenav-item.cjs.js.map +1 -1
- package/react/components/Sidenav/sgds-sidenav-item.js +3 -1
- package/react/components/Sidenav/sgds-sidenav-item.js.map +1 -1
- package/react/components/Sidenav/sidenav-item.cjs.js +1 -1
- package/react/components/Sidenav/sidenav-item.cjs.js.map +1 -1
- package/react/components/Sidenav/sidenav-item.js +1 -1
- package/react/components/Sidenav/sidenav-item.js.map +1 -1
- package/react/components/Table/table-cell.cjs.js +1 -1
- package/react/components/Table/table-cell.cjs.js.map +1 -1
- package/react/components/Table/table-cell.js +1 -1
- package/react/components/Table/table-cell.js.map +1 -1
- package/react/components/Table/table-row.cjs.js +1 -1
- package/react/components/Table/table-row.cjs.js.map +1 -1
- package/react/components/Table/table-row.js +1 -1
- package/react/components/Table/table-row.js.map +1 -1
package/custom-elements.json
CHANGED
|
@@ -32053,7 +32053,7 @@
|
|
|
32053
32053
|
"package": {
|
|
32054
32054
|
"name": "@govtechsg/sgds-web-component",
|
|
32055
32055
|
"description": "",
|
|
32056
|
-
"version": "3.30.1-rc.
|
|
32056
|
+
"version": "3.30.1-rc.8",
|
|
32057
32057
|
"author": "GovTechSG",
|
|
32058
32058
|
"license": "MIT"
|
|
32059
32059
|
}
|
package/index.umd.min.js
CHANGED
|
@@ -3368,7 +3368,7 @@ super(`context-provider`,{bubbles:!0,composed:!0}),this.context=e,this.contextTa
|
|
|
3368
3368
|
<sgds-icon name="chevron-down" size="md"></sgds-icon>
|
|
3369
3369
|
</button>
|
|
3370
3370
|
<slot @slotchange=${this._handleDesktopSlotChange}></slot>
|
|
3371
|
-
</sgds-dropdown>`;return this._breakpointReached?e:t}};T([wv({context:Ov,subscribe:!0}),S()],Pv.prototype,`_breakpointReached`,void 0),T([wv({context:kv,subscribe:!0}),S()],Pv.prototype,`expanded`,void 0),T([C(`.nav-link`)],Pv.prototype,`navLink`,void 0),T([C(`.dropdown-items`)],Pv.prototype,`dropdownItems`,void 0),T([C(`.dropdown-items a`)],Pv.prototype,`menuHeaderButton`,void 0),T([C(`.dropdown-items span`)],Pv.prototype,`menuHeaderText`,void 0),T([x({type:Boolean})],Pv.prototype,`active`,void 0),T([x({type:Boolean,reflect:!0})],Pv.prototype,`disabled`,void 0),T([x({type:String})],Pv.prototype,`ariaLabel`,void 0),T([w({slot:`toggler`})],Pv.prototype,`togglerNodes`,void 0),T([w()],Pv.prototype,`defaultNodes`,void 0),b();var Fv=l`:host([expand=always]) ::slotted(*){border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}@media screen and (min-width:512px){:host([expand=sm]) ::slotted(*){border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}:host(:not([disabled])[active][expand=sm]) ::slotted(*){border-color:var(--sgds-primary-border-color-default)}}@media screen and (min-width:768px){:host([expand=md]) ::slotted(*){border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}:host(:not([disabled])[active][expand=md]) ::slotted(*){border-color:var(--sgds-primary-border-color-default)}}@media screen and (min-width:1024px){:host([expand=lg]) ::slotted(*){border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}:host(:not([disabled])[active][expand=lg]) ::slotted(*){border-color:var(--sgds-primary-border-color-default)}}@media screen and (min-width:1280px){:host([expand=xl]) ::slotted(*){border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}:host(:not([disabled])[active][expand=xl]) ::slotted(*){border-color:var(--sgds-primary-border-color-default)}}@media screen and (min-width:1440px){:host([expand=xxl]) ::slotted(*){border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}:host(:not([disabled])[active][expand=xxl]) ::slotted(*){border-color:var(--sgds-primary-border-color-default)}}@media screen and (max-width:511px){:host(:not([disabled])[active][expand=sm]) ::slotted(*){background-color:var(--sgds-bg-translucent-subtle)}}@media screen and (max-width:767px){:host(:not([disabled])[active][expand=md]) ::slotted(*){background-color:var(--sgds-bg-translucent-subtle)}}@media screen and (max-width:1023px){:host(:not([disabled])[active][expand=lg]) ::slotted(*){background-color:var(--sgds-bg-translucent-subtle)}}@media screen and (max-width:1279px){:host(:not([disabled])[active][expand=xl]) ::slotted(*){background-color:var(--sgds-bg-translucent-subtle)}}@media screen and (max-width:1439px){:host(:not([disabled])[active][expand=xxl]) ::slotted(*){background-color:var(--sgds-bg-translucent-subtle)}}::slotted(*){--sgds-link-color-default:var(--sgds-color-default);--sgds-link-color-emphasis:var(--sgds-color-default);align-items:center;box-sizing:border-box;color:var(--sgds-color-default)!important;cursor:pointer;display:flex;font-size:var(--sgds-font-size-label-sm);height:auto!important;line-height:var(--sgds-line-height-2-xs,20px);padding:var(--sgds-padding-sm) var(--sgds-mainnav-mobile-padding-x);text-decoration:none!important}:host([tone=brand][expand=always]) ::slotted(*),:host([tone^=gradient][expand=always]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}:host([tone=brand][expand=always]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=always]:not([disabled])[active]) ::slotted(*){border-color:var(--sgds-color-fixed-light)}@media screen and (min-width:512px){:host([tone=brand][expand=sm]) ::slotted(*),:host([tone^=gradient][expand=sm]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}:host([tone=brand][expand=sm]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=sm]:not([disabled])[active]) ::slotted(*){border-color:var(--sgds-color-fixed-light)}}@media screen and (min-width:768px){:host([tone=brand][expand=md]) ::slotted(*),:host([tone^=gradient][expand=md]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}:host([tone=brand][expand=md]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=md]:not([disabled])[active]) ::slotted(*){border-color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1024px){:host([tone=brand][expand=lg]) ::slotted(*),:host([tone^=gradient][expand=lg]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}:host([tone=brand][expand=lg]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=lg]:not([disabled])[active]) ::slotted(*){border-color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1280px){:host([tone=brand][expand=xl]) ::slotted(*),:host([tone^=gradient][expand=xl]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}:host([tone=brand][expand=xl]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=xl]:not([disabled])[active]) ::slotted(*){border-color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1440px){:host([tone=brand][expand=xxl]) ::slotted(*),:host([tone^=gradient][expand=xxl]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}:host([tone=brand][expand=xxl]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=xxl]:not([disabled])[active]) ::slotted(*){border-color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1024px){::slotted(*){padding:var(--sgds-padding-sm) var(--sgds-mainnav-padding-x)}}:host(:not([disabled])[active]) ::slotted(*){--sgds-link-color-default:var(--sgds-primary-color-default);--sgds-link-color-emphasis:var(--sgds-primary-color-default);color:var(--sgds-primary-color-default)!important}:host(:not([disabled]):not([active])) ::slotted(a:hover){--sgds-link-color-emphasis:var(--sgds-color-default);color:var(--sgds-color-default)!important}:host(:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-emphasis:var(--sgds-primary-color-default);color:var(--sgds-primary-color-default)!important}:host([tone=brand][expand=always]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=always]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=always]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=always]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}@media screen and (min-width:512px){:host([tone=brand][expand=sm]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=sm]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=sm]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=sm]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:768px){:host([tone=brand][expand=md]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=md]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=md]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=md]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1024px){:host([tone=brand][expand=lg]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=lg]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=lg]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=lg]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1280px){:host([tone=brand][expand=xl]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=xl]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=xl]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=xl]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1440px){:host([tone=brand][expand=xxl]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=xxl]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=xxl]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=xxl]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}:host([disabled]) ::slotted(a:hover){--sgds-link-color-emphasis:var(--sgds-color-default);color:var(--sgds-color-default)!important}:host(:not([disabled]):not([active])) ::slotted(a:active){color:var(--sgds-color-default)!important}:host(:not([disabled])[active]) ::slotted(a:active){color:var(--sgds-primary-color-default)!important}::slotted(a:focus-visible){--sgds-link-color-emphasis:var(--sgds-primary-color-default);color:var(--sgds-primary-color-default)!important;outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}:host([disabled]) ::slotted(*){cursor:not-allowed;opacity:var(--sgds-opacity-40)}`;b();var Iv=class extends E{constructor(...e){super(...e),this.active=!1,this.disabled=!1}static{this.styles=[...E.styles,Fv]}_handleDisabled(){this.setAttribute(`aria-disabled`,`${this.disabled}`)}_handleSlotChange(e){let t=e.target,n=t.assignedElements({flatten:!0}).filter(e=>e.tagName.toLowerCase()===`a`||e.tagName.toLowerCase()===`sgds-link`);if(n.length>1){console.error(`More than one anchor tag is added to sgds-mainnav-item`);return}if(n.length===0&&t.assignedNodes({flatten:!0}).forEach(e=>{if(e.nodeType===Node.TEXT_NODE){let t=document.createElement(`a`);t.textContent=e.textContent,e.parentNode.replaceChild(t,e)}}),n.length===1){let e=n[0];if(this.active&&e.setAttribute(`aria-current`,`true`),this.disabled){e.setAttribute(`href`,`javascript:void(0)`),e.setAttribute(`tabindex`,`-1`);return}e.addEventListener(`click`,e=>{e.target.closest(`sgds-mainnav`).hide()})}}render(){return v`<slot @slotchange=${this._handleSlotChange}></slot>`}};T([x({type:Boolean,reflect:!0})],Iv.prototype,`active`,void 0),T([x({type:Boolean,reflect:!0})],Iv.prototype,`disabled`,void 0),T([P(`disabled`)],Iv.prototype,`_handleDisabled`,null),b();var Lv=l`:host([expand=always]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}@media (min-width:512px){:host([expand=sm]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}@media (min-width:768px){:host([expand=md]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}@media (min-width:1024px){:host(:not([expand])) .nav-link,:host([expand=lg]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}@media (min-width:1280px){:host([expand=xl]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}@media (min-width:1440px){:host([expand=xxl]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}button.nav-link{appearance:none;background:none;border:none;font-family:inherit}.nav-link{align-items:center;box-sizing:border-box;color:var(--sgds-color-default);cursor:pointer;display:flex;font-size:var(--sgds-font-size-label-sm);gap:var(--sgds-gap-xs);line-height:var(--sgds-line-height-2-xs,20px);padding:var(--sgds-padding-sm) var(--sgds-mainnav-mobile-padding-x);text-decoration:none}.nav-link:not(.disabled):hover{color:var(--sgds-primary-color-default)}.nav-link:not(.disabled):focus-visible{color:var(--sgds-primary-color-default);outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}.nav-link.disabled{cursor:not-allowed;opacity:var(--sgds-opacity-40)}.nav-link.read-only,.profile-avatar-mobile.read-only{cursor:default;pointer-events:none}:host([tone=brand][expand=always]) .nav-link,:host([tone^=gradient][expand=always]) .nav-link{color:var(--sgds-color-fixed-light)}@media screen and (min-width:512px){:host([tone=brand][expand=sm]) .nav-link,:host([tone^=gradient][expand=sm]) .nav-link{color:var(--sgds-color-fixed-light)}}@media screen and (min-width:768px){:host([tone=brand][expand=md]) .nav-link,:host([tone^=gradient][expand=md]) .nav-link{color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1024px){:host([tone=brand][expand=lg]) .nav-link,:host([tone^=gradient][expand=lg]) .nav-link{color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1280px){:host([tone=brand][expand=xl]) .nav-link,:host([tone^=gradient][expand=xl]) .nav-link{color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1440px){:host([tone=brand][expand=xxl]) .nav-link,:host([tone^=gradient][expand=xxl]) .nav-link{color:var(--sgds-color-fixed-light)}}.profile-text{display:flex;flex:1;flex-direction:column;gap:var(--sgds-gap-text-2-xs,2px);text-align:left}.profile-label{font-weight:var(--sgds-font-weight-semibold)}.profile-label,.profile-secondary-text{font-size:var(--sgds-font-size-body-xs);line-height:var(--sgds-line-height-3-xs,16px)}sgds-dropdown{display:block;height:100%}.profile-avatar-mobile{align-items:center;background:none;border:none;border-radius:var(--sgds-border-radius-full);color:inherit;cursor:pointer;display:flex;font:inherit;height:100%;margin:0;padding:0}.profile-avatar-mobile:focus-visible{outline:none}.profile-avatar-mobile:focus-visible ::slotted(*){border-radius:var(--sgds-border-radius-full);outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}.profile-mobile-panel{animation:profile-panel-show .2s ease-in-out;background-color:var(--sgds-surface-default);border-top:var(--sgds-border-width-1) solid var(--sgds-border-color-translucent);box-shadow:0 2px 4px 0 hsla(0,0%,5%,.08);left:0;padding:var(--sgds-padding-md) 0;position:absolute;top:100%;width:100%;z-index:var(--sgds-z-index-floating)}.profile-mobile-panel[hidden]{display:none}@keyframes profile-panel-show{0%{max-height:0;opacity:0}to{max-height:100dvh;opacity:1}}.profile-mobile-items{display:flex;flex-direction:column;height:100dvh;margin:auto;max-width:var(--sgds-mainnav-max-width,1440px);overflow-y:auto;width:100%}@media screen and (min-width:1024px){.nav-link{padding:var(--sgds-padding-sm) var(--sgds-mainnav-padding-x)}}`;b();var Rv=class extends E{constructor(...e){super(...e),this._breakpointReached=!0,this._mobileMenuOpen=!1,this._hasDropdownItems=!1,this.label=``,this.secondaryText=``,this.disabled=!1,this.ariaLabel=``,this.close=`default`,this.togglerId=kg(`profile`,`button`),this._handleMobileToggle=()=>{this._mobileMenuOpen=!this._mobileMenuOpen},this._handleClickOutside=e=>{this._mobileMenuOpen&&this.close!==`inside`&&(e.composedPath().includes(this)||(this._mobileMenuOpen=!1))},this._handleSlotChange=()=>{this._hasDropdownItems=this._defaultSlotElements.length>0},this._handleKeydown=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),this._handleMobileToggle())}}static{this.styles=[...E.styles,Lv]}static{this.dependencies={"sgds-dropdown":Pg,"sgds-icon":L}}connectedCallback(){super.connectedCallback(),window.addEventListener(`click`,this._handleClickOutside)}disconnectedCallback(){super.disconnectedCallback(),window.removeEventListener(`click`,this._handleClickOutside)}render(){return this._breakpointReached?this._hasDropdownItems?v`
|
|
3371
|
+
</sgds-dropdown>`;return this._breakpointReached?e:t}};T([wv({context:Ov,subscribe:!0}),S()],Pv.prototype,`_breakpointReached`,void 0),T([wv({context:kv,subscribe:!0}),S()],Pv.prototype,`expanded`,void 0),T([C(`.nav-link`)],Pv.prototype,`navLink`,void 0),T([C(`.dropdown-items`)],Pv.prototype,`dropdownItems`,void 0),T([C(`.dropdown-items a`)],Pv.prototype,`menuHeaderButton`,void 0),T([C(`.dropdown-items span`)],Pv.prototype,`menuHeaderText`,void 0),T([x({type:Boolean})],Pv.prototype,`active`,void 0),T([x({type:Boolean,reflect:!0})],Pv.prototype,`disabled`,void 0),T([x({type:String})],Pv.prototype,`ariaLabel`,void 0),T([w({slot:`toggler`})],Pv.prototype,`togglerNodes`,void 0),T([w()],Pv.prototype,`defaultNodes`,void 0),b();var Fv=l`.mainnav-item{align-items:center;box-sizing:border-box;display:flex;font-size:var(--sgds-font-size-label-sm);line-height:var(--sgds-line-height-2-xs,20px)}:host([expand=always]) .mainnav-item{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%}@media screen and (min-width:512px){:host([expand=sm]) .mainnav-item{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%}:host(:not([disabled])[active][expand=sm]) .mainnav-item{border-color:var(--sgds-primary-border-color-default)}}@media screen and (min-width:768px){:host([expand=md]) .mainnav-item{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%}:host(:not([disabled])[active][expand=md]) .mainnav-item{border-color:var(--sgds-primary-border-color-default)}}@media screen and (min-width:1024px){:host([expand=lg]) .mainnav-item{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%}:host(:not([disabled])[active][expand=lg]) .mainnav-item{border-color:var(--sgds-primary-border-color-default)}}@media screen and (min-width:1280px){:host([expand=xl]) .mainnav-item{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%}:host(:not([disabled])[active][expand=xl]) .mainnav-item{border-color:var(--sgds-primary-border-color-default)}}@media screen and (min-width:1440px){:host([expand=xxl]) .mainnav-item{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%}:host(:not([disabled])[active][expand=xxl]) .mainnav-item{border-color:var(--sgds-primary-border-color-default)}}@media screen and (max-width:511px){:host(:not([disabled])[active][expand=sm]) .mainnav-item{background-color:var(--sgds-bg-translucent-subtle)}}@media screen and (max-width:767px){:host(:not([disabled])[active][expand=md]) .mainnav-item{background-color:var(--sgds-bg-translucent-subtle)}}@media screen and (max-width:1023px){:host(:not([disabled])[active][expand=lg]) .mainnav-item{background-color:var(--sgds-bg-translucent-subtle)}}@media screen and (max-width:1279px){:host(:not([disabled])[active][expand=xl]) .mainnav-item{background-color:var(--sgds-bg-translucent-subtle)}}@media screen and (max-width:1439px){:host(:not([disabled])[active][expand=xxl]) .mainnav-item{background-color:var(--sgds-bg-translucent-subtle)}}:host([tone=brand][expand=always]:not([disabled])[active]) .mainnav-item,:host([tone^=gradient][expand=always]:not([disabled])[active]) .mainnav-item{border-color:var(--sgds-color-fixed-light)}@media screen and (min-width:512px){:host([tone=brand][expand=sm]:not([disabled])[active]) .mainnav-item,:host([tone^=gradient][expand=sm]:not([disabled])[active]) .mainnav-item{border-color:var(--sgds-color-fixed-light)}}@media screen and (min-width:768px){:host([tone=brand][expand=md]:not([disabled])[active]) .mainnav-item,:host([tone^=gradient][expand=md]:not([disabled])[active]) .mainnav-item{border-color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1024px){:host([tone=brand][expand=lg]:not([disabled])[active]) .mainnav-item,:host([tone^=gradient][expand=lg]:not([disabled])[active]) .mainnav-item{border-color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1280px){:host([tone=brand][expand=xl]:not([disabled])[active]) .mainnav-item,:host([tone^=gradient][expand=xl]:not([disabled])[active]) .mainnav-item{border-color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1440px){:host([tone=brand][expand=xxl]:not([disabled])[active]) .mainnav-item,:host([tone^=gradient][expand=xxl]:not([disabled])[active]) .mainnav-item{border-color:var(--sgds-color-fixed-light)}}:host([disabled]) .mainnav-item{opacity:var(--sgds-opacity-40)}::slotted(*){--sgds-link-color-default:var(--sgds-color-default);--sgds-link-color-emphasis:var(--sgds-color-default);align-items:center;color:var(--sgds-color-default)!important;cursor:pointer;display:flex;height:auto!important;padding:var(--sgds-padding-sm) var(--sgds-mainnav-mobile-padding-x);text-decoration:none!important}:host([expand=always]) ::slotted(*){padding:0 var(--sgds-padding-md)}@media screen and (min-width:512px){:host([expand=sm]) ::slotted(*){padding:0 var(--sgds-padding-md)}}@media screen and (min-width:768px){:host([expand=md]) ::slotted(*){padding:0 var(--sgds-padding-md)}}@media screen and (min-width:1024px){:host([expand=lg]) ::slotted(*){padding:0 var(--sgds-padding-md)}}@media screen and (min-width:1280px){:host([expand=xl]) ::slotted(*){padding:0 var(--sgds-padding-md)}}@media screen and (min-width:1440px){:host([expand=xxl]) ::slotted(*){padding:0 var(--sgds-padding-md)}}:host([tone=brand][expand=always]) ::slotted(*),:host([tone^=gradient][expand=always]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}@media screen and (min-width:512px){:host([tone=brand][expand=sm]) ::slotted(*),:host([tone^=gradient][expand=sm]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:768px){:host([tone=brand][expand=md]) ::slotted(*),:host([tone^=gradient][expand=md]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1024px){:host([tone=brand][expand=lg]) ::slotted(*),:host([tone^=gradient][expand=lg]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1280px){:host([tone=brand][expand=xl]) ::slotted(*),:host([tone^=gradient][expand=xl]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1440px){:host([tone=brand][expand=xxl]) ::slotted(*),:host([tone^=gradient][expand=xxl]) ::slotted(*){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1024px){::slotted(*){padding:var(--sgds-padding-sm) var(--sgds-mainnav-padding-x)}}:host(:not([disabled])[active]) ::slotted(*){--sgds-link-color-default:var(--sgds-primary-color-default);--sgds-link-color-emphasis:var(--sgds-primary-color-default);color:var(--sgds-primary-color-default)!important}:host(:not([disabled]):not([active])) ::slotted(a:hover){--sgds-link-color-emphasis:var(--sgds-color-default);color:var(--sgds-color-default)!important}:host(:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-emphasis:var(--sgds-primary-color-default);color:var(--sgds-primary-color-default)!important}:host([tone=brand][expand=always]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=always]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=always]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=always]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}@media screen and (min-width:512px){:host([tone=brand][expand=sm]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=sm]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=sm]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=sm]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:768px){:host([tone=brand][expand=md]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=md]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=md]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=md]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1024px){:host([tone=brand][expand=lg]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=lg]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=lg]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=lg]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1280px){:host([tone=brand][expand=xl]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=xl]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=xl]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=xl]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}@media screen and (min-width:1440px){:host([tone=brand][expand=xxl]:not([disabled])[active]) ::slotted(*),:host([tone=brand][expand=xxl]:not([disabled])[active]) ::slotted(a:hover),:host([tone^=gradient][expand=xxl]:not([disabled])[active]) ::slotted(*),:host([tone^=gradient][expand=xxl]:not([disabled])[active]) ::slotted(a:hover){--sgds-link-color-default:var(--sgds-color-fixed-light);--sgds-link-color-emphasis:var(--sgds-color-fixed-light);color:var(--sgds-color-fixed-light)!important}}:host([disabled]) ::slotted(a:hover){--sgds-link-color-emphasis:var(--sgds-color-default);color:var(--sgds-color-default)!important}:host(:not([disabled]):not([active])) ::slotted(a:active){color:var(--sgds-color-default)!important}:host(:not([disabled])[active]) ::slotted(a:active){color:var(--sgds-primary-color-default)!important}::slotted(a:focus-visible){--sgds-link-color-emphasis:var(--sgds-primary-color-default);color:var(--sgds-primary-color-default)!important;outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}:host([disabled]) ::slotted(*){cursor:not-allowed}`;b();var Iv=class extends E{constructor(...e){super(...e),this.active=!1,this.disabled=!1}static{this.styles=[...E.styles,Fv]}_handleDisabled(){this.setAttribute(`aria-disabled`,`${this.disabled}`)}_handleSlotChange(e){let t=e.target,n=t.assignedElements({flatten:!0}).filter(e=>e.tagName.toLowerCase()===`a`||e.tagName.toLowerCase()===`sgds-link`);if(n.length>1){console.error(`More than one anchor tag is added to sgds-mainnav-item`);return}if(n.length===0&&t.assignedNodes({flatten:!0}).forEach(e=>{if(e.nodeType===Node.TEXT_NODE){let t=document.createElement(`a`);t.textContent=e.textContent,e.parentNode.replaceChild(t,e)}}),n.length===1){let e=n[0];if(this.active&&e.setAttribute(`aria-current`,`true`),this.disabled){e.setAttribute(`href`,`javascript:void(0)`),e.setAttribute(`tabindex`,`-1`);return}e.addEventListener(`click`,e=>{e.target.closest(`sgds-mainnav`).hide()})}}render(){return v`<div class="mainnav-item"><slot @slotchange=${this._handleSlotChange}></slot></div>`}};T([x({type:Boolean,reflect:!0})],Iv.prototype,`active`,void 0),T([x({type:Boolean,reflect:!0})],Iv.prototype,`disabled`,void 0),T([P(`disabled`)],Iv.prototype,`_handleDisabled`,null),b();var Lv=l`:host([expand=always]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}@media (min-width:512px){:host([expand=sm]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}@media (min-width:768px){:host([expand=md]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}@media (min-width:1024px){:host(:not([expand])) .nav-link,:host([expand=lg]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}@media (min-width:1280px){:host([expand=xl]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}@media (min-width:1440px){:host([expand=xxl]) .nav-link{border-bottom:var(--sgds-border-width-4) solid transparent;min-height:100%;padding:0 var(--sgds-padding-md)}}button.nav-link{appearance:none;background:none;border:none;font-family:inherit}.nav-link{align-items:center;box-sizing:border-box;color:var(--sgds-color-default);cursor:pointer;display:flex;font-size:var(--sgds-font-size-label-sm);gap:var(--sgds-gap-xs);line-height:var(--sgds-line-height-2-xs,20px);padding:var(--sgds-padding-sm) var(--sgds-mainnav-mobile-padding-x);text-decoration:none}.nav-link:not(.disabled):hover{color:var(--sgds-primary-color-default)}.nav-link:not(.disabled):focus-visible{color:var(--sgds-primary-color-default);outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}.nav-link.disabled{cursor:not-allowed;opacity:var(--sgds-opacity-40)}.nav-link.read-only,.profile-avatar-mobile.read-only{cursor:default;pointer-events:none}:host([tone=brand][expand=always]) .nav-link,:host([tone^=gradient][expand=always]) .nav-link{color:var(--sgds-color-fixed-light)}@media screen and (min-width:512px){:host([tone=brand][expand=sm]) .nav-link,:host([tone^=gradient][expand=sm]) .nav-link{color:var(--sgds-color-fixed-light)}}@media screen and (min-width:768px){:host([tone=brand][expand=md]) .nav-link,:host([tone^=gradient][expand=md]) .nav-link{color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1024px){:host([tone=brand][expand=lg]) .nav-link,:host([tone^=gradient][expand=lg]) .nav-link{color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1280px){:host([tone=brand][expand=xl]) .nav-link,:host([tone^=gradient][expand=xl]) .nav-link{color:var(--sgds-color-fixed-light)}}@media screen and (min-width:1440px){:host([tone=brand][expand=xxl]) .nav-link,:host([tone^=gradient][expand=xxl]) .nav-link{color:var(--sgds-color-fixed-light)}}.profile-text{display:flex;flex:1;flex-direction:column;gap:var(--sgds-gap-text-2-xs,2px);text-align:left}.profile-label{font-weight:var(--sgds-font-weight-semibold)}.profile-label,.profile-secondary-text{font-size:var(--sgds-font-size-body-xs);line-height:var(--sgds-line-height-3-xs,16px)}sgds-dropdown{display:block;height:100%}.profile-avatar-mobile{align-items:center;background:none;border:none;border-radius:var(--sgds-border-radius-full);color:inherit;cursor:pointer;display:flex;font:inherit;height:100%;margin:0;padding:0}.profile-avatar-mobile:focus-visible{outline:none}.profile-avatar-mobile:focus-visible ::slotted(*){border-radius:var(--sgds-border-radius-full);outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}.profile-mobile-panel{animation:profile-panel-show .2s ease-in-out;background-color:var(--sgds-surface-default);border-top:var(--sgds-border-width-1) solid var(--sgds-border-color-translucent);box-shadow:0 2px 4px 0 hsla(0,0%,5%,.08);left:0;padding:var(--sgds-padding-md) 0;position:absolute;top:100%;width:100%;z-index:var(--sgds-z-index-floating)}.profile-mobile-panel[hidden]{display:none}@keyframes profile-panel-show{0%{max-height:0;opacity:0}to{max-height:100dvh;opacity:1}}.profile-mobile-items{display:flex;flex-direction:column;height:100dvh;margin:auto;max-width:var(--sgds-mainnav-max-width,1440px);overflow-y:auto;width:100%}@media screen and (min-width:1024px){.nav-link{padding:var(--sgds-padding-sm) var(--sgds-mainnav-padding-x)}}`;b();var Rv=class extends E{constructor(...e){super(...e),this._breakpointReached=!0,this._mobileMenuOpen=!1,this._hasDropdownItems=!1,this.label=``,this.secondaryText=``,this.disabled=!1,this.ariaLabel=``,this.close=`default`,this.togglerId=kg(`profile`,`button`),this._handleMobileToggle=()=>{this._mobileMenuOpen=!this._mobileMenuOpen},this._handleClickOutside=e=>{this._mobileMenuOpen&&this.close!==`inside`&&(e.composedPath().includes(this)||(this._mobileMenuOpen=!1))},this._handleSlotChange=()=>{this._hasDropdownItems=this._defaultSlotElements.length>0},this._handleKeydown=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),this._handleMobileToggle())}}static{this.styles=[...E.styles,Lv]}static{this.dependencies={"sgds-dropdown":Pg,"sgds-icon":L}}connectedCallback(){super.connectedCallback(),window.addEventListener(`click`,this._handleClickOutside)}disconnectedCallback(){super.disconnectedCallback(),window.removeEventListener(`click`,this._handleClickOutside)}render(){return this._breakpointReached?this._hasDropdownItems?v`
|
|
3372
3372
|
<button
|
|
3373
3373
|
class="profile-avatar-mobile"
|
|
3374
3374
|
aria-label=${this.ariaLabel||`Toggle navigation`}
|
|
@@ -3856,7 +3856,7 @@ super(`context-provider`,{bubbles:!0,composed:!0}),this.context=e,this.contextTa
|
|
|
3856
3856
|
<slot @click=${this.onToggle}></slot>
|
|
3857
3857
|
</div>
|
|
3858
3858
|
</nav>
|
|
3859
|
-
`}};T([x({type:Boolean,attribute:!0})],sy.prototype,`sticky`,void 0),T([w()],sy.prototype,`defaultNodes`,void 0),b();var cy=l`:host([class^=second-level]) .sidenav-btn{font-weight:var(--sgds-font-weight-regular);padding-left:var(--sgds-padding-3-xl)}button{all:unset}.sidenav-btn{background:0;border:0;border-radius:var(--sgds-interactive-border-radius);display:flex;font-size:var(--sgds-font-size-label-md);font-weight:var(--sgds-font-weight-semibold);gap:var(--sgds-gap-xs);line-height:var(--sgds-line-height-xs);padding:var(--sgds-padding-sm) var(--sgds-padding-sm) var(--sgds-padding-sm) calc(var(--sgds-padding-sm) + var(--sgds-padding-2-xs));text-align:initial;width:100%;.caret-icon,slot[name=caret-icon]::slotted(*){margin-bottom:auto;margin-left:auto;transform:rotate(180deg);transition:all .3s ease-in-out}}.sidenav-btn:hover:not(.disabled){background-color:var(--sgds-bg-translucent-subtle)}.sidenav-btn.active{color:var(--sgds-color-default)}.sidenav-btn.disabled{opacity:var(--sgds-opacity-40);pointer-events:none}.sidenav-btn:not(.active){.caret-icon,slot[name=caret-icon]::slotted(*){transform:rotate(0deg)}}.sidenav-btn:focus-visible:not(.disabled){background-color:var(--sgds-bg-translucent-subtle)}.sidenav-btn:focus-visible:not(.disabled){outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}.no-menu-
|
|
3859
|
+
`}};T([x({type:Boolean,attribute:!0})],sy.prototype,`sticky`,void 0),T([w()],sy.prototype,`defaultNodes`,void 0),b();var cy=l`:host([class^=second-level]) .sidenav-btn{font-weight:var(--sgds-font-weight-regular);padding-left:var(--sgds-padding-3-xl)}button{all:unset}.sidenav-btn{background:0;border:0;border-radius:var(--sgds-interactive-border-radius);display:flex;font-size:var(--sgds-font-size-label-md);font-weight:var(--sgds-font-weight-semibold);gap:var(--sgds-gap-xs);line-height:var(--sgds-line-height-xs);padding:var(--sgds-padding-sm) var(--sgds-padding-sm) var(--sgds-padding-sm) calc(var(--sgds-padding-sm) + var(--sgds-padding-2-xs));text-align:initial;width:100%;.caret-icon,slot[name=caret-icon]::slotted(*){margin-bottom:auto;margin-left:auto;transform:rotate(180deg);transition:all .3s ease-in-out}}.sidenav-btn:hover:not(.disabled){background-color:var(--sgds-bg-translucent-subtle)}.sidenav-btn.active{color:var(--sgds-color-default)}.sidenav-btn.disabled{opacity:var(--sgds-opacity-40);pointer-events:none}.sidenav-btn:not(.active){.caret-icon,slot[name=caret-icon]::slotted(*){transform:rotate(0deg)}}.sidenav-btn:focus-visible:not(.disabled){background-color:var(--sgds-bg-translucent-subtle)}.sidenav-btn:focus-visible:not(.disabled){outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}.no-menu-wrapper{background:0;border:0;border-radius:var(--sgds-interactive-border-radius);display:flex;font-size:var(--sgds-font-size-label-md);font-weight:var(--sgds-font-weight-semibold);gap:var(--sgds-gap-xs);line-height:var(--sgds-line-height-xs);padding:var(--sgds-padding-sm) var(--sgds-padding-sm) var(--sgds-padding-sm) calc(var(--sgds-padding-sm) + var(--sgds-padding-2-xs))}.no-menu-wrapper:hover{background-color:var(--sgds-bg-translucent-subtle)}.no-menu-wrapper:focus-within{background-color:var(--sgds-bg-translucent-subtle);outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}:host([class^=first-level][active]) .no-menu-wrapper{background-color:var(--sgds-primary-surface-translucent);color:var(--sgds-primary-color-emphasis)}:host([class^=first-level][disabled]) .no-menu-wrapper{opacity:var(--sgds-opacity-40);pointer-events:none}.no-menu-default::slotted(a){color:inherit!important;font-weight:inherit!important;text-decoration:none!important}.no-menu-default::slotted(a:focus-visible){outline:none}`;b();var ly=class extends E{constructor(...e){super(...e),this.active=!1,this.disabled=!1,this.isLink=!1,this._collapseId=kg(`sidenav`,`collapse`),this._buttonId=kg(`sidenav`,`button`),this._levelId=kg(`sidenav`,`this`),this._firstLevelId=`first-level-`+this._levelId,this._secondLevelId=`second-level-`+this._levelId,this._thirdLevelId=`third-level-`+this._levelId,this.index=`-1`}static{this.styles=[...E.styles,cy]}static{this.dependencies={"sgds-icon":L}}_onToggle(){this.emit(`sgds-toggle`,{detail:{index:this.index}})}async show(){if(!this.isLink&&!this.active)return this.active=!0,N(this,`sgds-after-show`)}async hide(){if(!this.isLink&&this.active)return this.active=!1,N(this,`sgds-after-hide`)}connectedCallback(){super.connectedCallback(),this.classList.add(this._firstLevelId)}firstUpdated(e){super.firstUpdated(e),this.isLink||(this.body.hidden=!this.active,this.body.style.height=this.active?`auto`:`0`),this._handleOpenMenu()}_handleOpenMenu(){this.active||=this._items.some(e=>e.active)}_handleSummaryClick(){this.active?this.hide():this.show(),this._onToggle(),this.header.focus()}_handleSummaryKeyDown(e){(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),this.active?this.hide():this.show()),(e.key===`ArrowUp`||e.key===`ArrowLeft`)&&(e.preventDefault(),this.hide()),(e.key===`ArrowDown`||e.key===`ArrowRight`)&&(e.preventDefault(),this.show())}async _handleOpenChange(){if(!this.isLink){if(this.active){if(this.emit(`sgds-show`,{cancelable:!0}).defaultPrevented){this.active=!1;return}await A(this.body),this.body.hidden=!1;let{keyframes:e,options:t}=j(this,`sidenav.show`);await k(this.body,ht(e,this.body.scrollHeight),t),this.body.style.height=`auto`,this.emit(`sgds-after-show`)}else{if(this.emit(`sgds-hide`,{cancelable:!0}).defaultPrevented){this.active=!0;return}await A(this.body);let{keyframes:e,options:t}=j(this,`sidenav.hide`);await k(this.body,ht(e,this.body.scrollHeight),t),this.body.hidden=!0,this.body.style.height=`auto`,this.emit(`sgds-after-hide`)}}}_handleSlotChange(e){let t=e.target.assignedElements({flatten:!0}).filter(e=>e.tagName.toLowerCase()===`a`);if(t.length>1)return console.error(`More than one anchor tag is added to sgds-sidenav-item`);if(t.length===1){let e=t[0];return this.disabled&&e.setAttribute(`tabindex`,`-1`),this.active&&e.setAttribute(`aria-current`,`true`),this.isLink=!0}e.target.assignedElements({flatten:!0}).filter(e=>e.tagName.toLowerCase()===`sgds-sidenav-item`).forEach(e=>{let t=Array.from(e.classList).filter(e=>e.startsWith(`first-level`))[0];e.classList.replace(t,this._secondLevelId)}),Array.from(this.classList).some(e=>e.startsWith(`second-level`))&&this._items.forEach(e=>e.classList.add(this._thirdLevelId)),this._handleOpenMenu()}render(){let e=v`
|
|
3860
3860
|
<button
|
|
3861
3861
|
@click=${this._handleSummaryClick}
|
|
3862
3862
|
@keydown=${this._handleSummaryKeyDown}
|
|
@@ -3880,7 +3880,9 @@ super(`context-provider`,{bubbles:!0,composed:!0}),this.context=e,this.contextTa
|
|
|
3880
3880
|
<slot class="default" @slotchange=${this._handleSlotChange}></slot>
|
|
3881
3881
|
</div>
|
|
3882
3882
|
</div>
|
|
3883
|
-
`,t=v
|
|
3883
|
+
`,t=v`<div class="no-menu-wrapper">
|
|
3884
|
+
<slot @slotchange=${this._handleSlotChange} class="no-menu-default"></slot>
|
|
3885
|
+
</div>`;return v`
|
|
3884
3886
|
<div class="sidenav-item" aria-haspopup="${!this.isLink}">${this.isLink?t:e}</div>
|
|
3885
3887
|
`}};T([C(`.sidenav-body`)],ly.prototype,`body`,void 0),T([C(`.sidenav-btn`)],ly.prototype,`header`,void 0),T([x({type:Boolean,reflect:!0})],ly.prototype,`active`,void 0),T([x({type:Boolean,reflect:!0})],ly.prototype,`disabled`,void 0),T([x({type:String})],ly.prototype,`ariaLabel`,void 0),T([S()],ly.prototype,`isLink`,void 0),T([P(`active`,{waitUntilFirstUpdate:!0})],ly.prototype,`_handleOpenChange`,null),T([w()],ly.prototype,`_items`,void 0),M(`sidenav.show`,{keyframes:[{height:`0`,opacity:`0`},{height:`auto`,opacity:`1`}],options:{duration:200,easing:`ease-in-out`}}),M(`sidenav.hide`,{keyframes:[{height:`auto`,opacity:`1`},{height:`0`,opacity:`0`}],options:{duration:200,easing:`ease-in-out`}}),b();var uy=l`:host([class^=third-level]) ::slotted(a){padding-left:calc(var(--sgds-padding-xl) + var(--sgds-padding-3-xl))}::slotted(a){--sgds-link-color-default:var(--sgds-color-default);border-radius:var(--sgds-interactive-border-radius);color:var(--sgds-color-default,var(--sgds-link-color-default));display:block;padding:var(--sgds-padding-sm) var(--sgds-padding-sm) var(--sgds-padding-sm) var(--sgds-padding-3-xl);text-decoration:none!important}:host([active]) ::slotted(a){--sgds-link-color-default:var(--sgds-primary-color-emphasis);background-color:var(--sgds-primary-surface-translucent);color:var(--sgds-primary-color-emphasis,var(--sgds-link-color-default))}:host(:not([disabled]):not([active])) ::slotted(a:hover){background-color:var(--sgds-bg-translucent-subtle)}::slotted(a:focus),::slotted(a:focus-visible),::slotted(a:hover){--sgds-link-color-emphasis:var(--sgds-color-default);color:var(--sgds-color-default,var(--sgds-link-color-emphasis))}:host([active]) ::slotted(a:focus),:host([active]) ::slotted(a:focus-visible),:host([active]) ::slotted(a:hover){--sgds-link-color-emphasis:var(--sgds-primary-color-emphasis);color:var(--sgds-primary-color-emphasis,var(--sgds-link-color-emphasis))}:host([disabled]) ::slotted(a){opacity:var(--sgds-opacity-40);pointer-events:none}:host([disabled]) ::slotted(a:focus-visible){outline:0}::slotted(a:focus-visible){background-color:var(--sgds-bg-translucent-subtle)}::slotted(a:focus-visible){outline:var(--sgds-outline-focus);outline-offset:var(--sgds-outline-offset-focus)}:host([active]) ::slotted(a:focus-visible){background-color:var(--sgds-primary-bg-translucent)}`;b();var dy=class extends E{constructor(...e){super(...e),this.active=!1,this.disabled=!1}static{this.styles=[...E.styles,uy]}connectedCallback(){super.connectedCallback(),this.setAttribute(`aria-disabled`,`${this.disabled}`)}_handleDisabled(){this.setAttribute(`aria-disabled`,`${this.disabled}`),this._anchor[0].setAttribute(`aria-disabled`,`${this.disabled}`),this.disabled||this._anchor[0].removeAttribute(`tabindex`)}_handleSlotChange(){this._anchor[0].setAttribute(`aria-disabled`,`${this.disabled}`),this.disabled&&(this._anchor[0].setAttribute(`tabindex`,`-1`),this._anchor[0].removeAttribute(`href`),this._anchor[0].setAttribute(`role`,`link`))}render(){return v` <slot @slotchange=${this._handleSlotChange}></slot> `}};T([x({type:Boolean,reflect:!0})],dy.prototype,`active`,void 0),T([x({type:Boolean,reflect:!0})],dy.prototype,`disabled`,void 0),T([w({flatten:!0})],dy.prototype,`_anchor`,void 0),T([P(`disabled`,{waitUntilFirstUpdate:!0})],dy.prototype,`_handleDisabled`,null),F(`sgds-sidenav`,sy),F(`sgds-sidenav-item`,ly),F(`sgds-sidenav-link`,dy),b();var fy=l`.skeleton{--bg:var(--sgds-bg-translucent-subtle);background-color:var(--bg);border-radius:var(--sgds-border-radius-sm);display:flex;flex-direction:column;gap:var(--sgds-gap-xs);max-width:100%}.skeleton.skeleton-paragraph{background-color:transparent}.skeleton.skeleton-paragraph.auto-size-rows>div[class*=skeleton-row]{background-color:var(--sgds-bg-translucent);border-radius:var(--sgds-border-radius-sm);height:-webkit-fill-available}.sheen{--sheen-color:var(--sgds-bg-translucent);animation:sheen 8s ease-in-out infinite;background:linear-gradient(270deg,var(--bg) 0,var(--sheen-color) 33.33%,var(--sheen-color) 66.67%,var(--bg) 100%);background-size:400% 100%}@keyframes sheen{0%{background-position:200% 0}to{background-position:-200% 0}}`;b();var py=class extends E{constructor(...e){super(...e),this.width=``,this.height=``,this.borderRadius=``,this.sheen=!1}static{this.styles=[fy]}render(){let e={width:this.width||void 0,height:this.height||void 0,borderRadius:this.borderRadius||void 0};return v`
|
|
3886
3888
|
<div
|
|
@@ -4096,7 +4098,7 @@ super(`context-provider`,{bubbles:!0,composed:!0}),this.context=e,this.contextTa
|
|
|
4096
4098
|
class=${D({"table-head":!0,"header-background":this._headerBackground})}
|
|
4097
4099
|
>
|
|
4098
4100
|
<slot></slot>
|
|
4099
|
-
</div>`}};T([wv({context:Iy,subscribe:!0}),S()],zy.prototype,`_headerBackground`,void 0),T([P(`_headerBackground`)],zy.prototype,`_handleHeaderBackground`,null),b();var By=l`:host{display:table-row;width:100%}:host([tableBorder]:last-of-type) .table-row::slotted(*){border-bottom:0}`;b();var Vy=class extends E{constructor(...e){super(...e),this.tableBorder=!1}static{this.styles=[...E.styles,By]}connectedCallback(){super.connectedCallback(),this.setAttribute(`role`,`row`)}render(){return v`<slot class="table-row"></slot>`}};T([wv({context:Fy,subscribe:!0}),x({type:Boolean,reflect:!0})],Vy.prototype,`tableBorder`,void 0),b();var Hy=l`:host{border-bottom:var(--sgds-border-width-1) solid var(--sgds-border-color-muted);display:
|
|
4101
|
+
</div>`}};T([wv({context:Iy,subscribe:!0}),S()],zy.prototype,`_headerBackground`,void 0),T([P(`_headerBackground`)],zy.prototype,`_handleHeaderBackground`,null),b();var By=l`:host{display:table-row;width:100%}:host([tableBorder]:last-of-type) .table-row::slotted(*){--table-cell-border-bottom:0}`;b();var Vy=class extends E{constructor(...e){super(...e),this.tableBorder=!1}static{this.styles=[...E.styles,By]}connectedCallback(){super.connectedCallback(),this.setAttribute(`role`,`row`)}render(){return v`<slot class="table-row"></slot>`}};T([wv({context:Fy,subscribe:!0}),x({type:Boolean,reflect:!0})],Vy.prototype,`tableBorder`,void 0),b();var Hy=l`:host{display:table-cell}.table-cell{align-items:center;border-bottom:var(--table-cell-border-bottom,var(--sgds-border-width-1) solid var(--sgds-border-color-muted));display:flex;min-height:var(--sgds-dimension-56);padding:var(--sgds-padding-sm) var(--sgds-padding-md);vertical-align:middle}`;b();var Uy=class extends E{static{this.styles=[...E.styles,Hy]}connectedCallback(){super.connectedCallback(),this.setAttribute(`role`,`cell`)}render(){return v`<div class="table-cell"><slot></slot></div>`}};F(`sgds-table`,Ly),F(`sgds-table-head`,zy),F(`sgds-table-row`,Vy),F(`sgds-table-cell`,Uy),b();var Wy=l`textarea{font-family:inherit;font-size:inherit;line-height:inherit;margin:0;resize:vertical}textarea.form-control-group{height:auto;min-height:var(--sgds-dimension-136);overflow:auto;padding:var(--sgds-form-padding-y) var(--sgds-form-padding-x)}.textarea-resize-none{resize:none}.textarea-resize-vertical{resize:vertical}.textarea-resize-auto{height:auto;overflow-y:hidden;resize:none}.textarea-info-container{display:flex;justify-content:space-between}.word-count{margin-left:auto}`;b();var Z=class extends s_(H){constructor(...e){super(...e),this.value=``,this.spellcheck=!1,this.rows=4,this.placeholder=`Placeholder`,this.invalidFeedback=``,this.autofocus=!1,this.readonly=!1,this.resize=`vertical`,this.defaultValue=``,this.hasFeedback=!1,this.required=!1,this.noValidate=!1,this.hintText=``,this._isTouched=!1}static{this.styles=[...H.styles,i_,Wy]}focus(e){this.textarea.focus(e)}blur(){this.textarea.blur()}reportValidity(){return this._mixinReportValidity()}checkValidity(){return this._mixinCheckValidity()}get validity(){return this._mixinGetValidity()}get validationMessage(){return this._mixinGetValidationMessage()}select(){this.textarea.select()}_handleInvalid(e){e.preventDefault(),this.invalid=!0}_handleChange(e){this.value=this.input.value,this.emit(`sgds-change`),super._mixinHandleChange(e)}_handleInputChange(e){this.value=this.input.value,this.emit(`sgds-input`),super._mixinHandleInputChange(e)}_handleFocus(){this.emit(`sgds-focus`)}_handleBlur(){let e=this.emit(`sgds-blur`,{cancelable:!0});this._mixinShouldSkipSgdsValidation()||e.defaultPrevented||(this.setInvalid(!this._mixinCheckValidity()),this._isTouched=!0)}_handleRowsChange(){this._setTextareaHeight()}_setTextareaHeight(){this.resize===`auto`?(this.textarea.style.height=`auto`,this.textarea.style.height=`${this.textarea.scrollHeight}px`):this.textarea.style.height=void 0}_handleIsTouched(){this._mixinShouldSkipSgdsValidation()||this._isTouched&&this.setInvalid(!this._mixinCheckValidity())}_handleDisabledChange(){this.setInvalid(!1)}async _handleValueChange(){this._mixinSetFormValue(),await this.updateComplete,this._setTextareaHeight(),!this._mixinShouldSkipSgdsValidation()&&this._mixinValidate(this.input)}_renderHintText(){let e=I` <div id="${this._controlId}Help" class="form-text">${this.hintText}</div> `;return this.hintText&&e}_wordCount(){return I`
|
|
4100
4102
|
<div
|
|
4101
4103
|
class="form-text word-count ${D({"invalid-feedback":this.invalid&&this.hasFeedback})}"
|
|
4102
4104
|
>
|