/**
 * @license
 * Copyright 2023 Tyler Technologies, Inc. 
 * License: Apache-2.0
 */
import{a as u}from"./chunk.UWYANU5D.js";import{a as o}from"./chunk.KTGSZEAG.js";import{a as d,b as k}from"./chunk.DL7NX432.js";import{a as g,e as b,g as h,l as f}from"./chunk.LJLEPTLU.js";import{k as c}from"./chunk.J2M2MXP2.js";import{f as a}from"./chunk.MCIQXNKY.js";var _=`${k}stack`,A={DEFAULT:"forge-stack"},x={ROOT:`.${A.DEFAULT}`},S={INLINE:"inline",WRAP:"wrap",STRETCH:"stretch",GAP:"gap",ALIGNMENT:"alignment"},T={DEFAULT_GAP:"16"},e={elementName:_,classes:A,attributes:S,selectors:x,strings:T},E=(n=>(n.Start="start",n.Center="center",n.End="end",n))(E||{});var l=class extends u{constructor(r){super(r);this._rootElement=h(r,e.selectors.ROOT)}setGap(r){let n=/^\d+$/.test(r)?`${r}px`:r;this._rootElement.style.gap=`var(--forge-stack-gap, ${n})`}};var p=class{constructor(t){this._adapter=t;this._inline=!1;this._wrap=!1;this._stretch=!1;this._gap=e.strings.DEFAULT_GAP;this._alignment="start"}get inline(){return this._inline}set inline(t){t=Boolean(t),this._inline!==t&&(this._inline=t,this._adapter.toggleHostAttribute(e.attributes.INLINE,this._inline))}get wrap(){return this._wrap}set wrap(t){t=Boolean(t),this._wrap!==t&&(this._wrap=t,this._adapter.toggleHostAttribute(e.attributes.WRAP,this._wrap))}get stretch(){return this._stretch}set stretch(t){t=Boolean(t),this._stretch!==t&&(this._stretch=t,this._adapter.toggleHostAttribute(e.attributes.STRETCH,this._stretch))}get gap(){return this._gap}set gap(t){this._gap!==t&&(this._gap=t,this._adapter.setGap(this._gap),this._adapter.setHostAttribute(e.attributes.GAP,this._gap))}get alignment(){return this._alignment}set alignment(t){this._alignment!==t&&(this._alignment=t,this._adapter.setHostAttribute(e.attributes.ALIGNMENT,this._alignment))}};var I='<template><div class="forge-stack" part="root"><slot></slot></div></template>',N=".forge-stack{display:-webkit-box;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;flex-direction:column;width:100%;gap:16px;gap:var(--forge-stack-gap,16px);height:100%;height:var(--forge-stack-height,100%)}.forge-stack ::slotted(*){-webkit-box-flex:var(--forge-stack-stretch,initial);flex:var(--forge-stack-stretch,initial)}:host{display:block}:host([inline]) .forge-stack{-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row;--forge-stack-height:auto}:host([inline][wrap]) .forge-stack{flex-wrap:wrap}:host([stretch]:not([inline])){height:100%}:host([stretch]){--forge-stack-stretch:1}:host([alignment=start]) .forge-stack{-webkit-box-pack:start;justify-content:start}:host([alignment=center]) .forge-stack{-webkit-box-pack:center;justify-content:center}:host([alignment=end]) .forge-stack{-webkit-box-pack:end;justify-content:end}",i=class extends f{constructor(){super();b(this,I,N),this._foundation=new p(new l(this))}static get observedAttributes(){return[e.attributes.INLINE,e.attributes.WRAP,e.attributes.STRETCH,e.attributes.GAP,e.attributes.ALIGNMENT]}attributeChangedCallback(r,n,s){switch(r){case e.attributes.INLINE:this.inline=c(s);break;case e.attributes.WRAP:this.wrap=c(s);break;case e.attributes.STRETCH:this.stretch=c(s);break;case e.attributes.GAP:this.gap=s;break;case e.attributes.ALIGNMENT:this.alignment=s;break}}};a([o()],i.prototype,"inline",2),a([o()],i.prototype,"wrap",2),a([o()],i.prototype,"stretch",2),a([o()],i.prototype,"gap",2),a([o()],i.prototype,"alignment",2),i=a([d({name:e.elementName})],i);function q(){g(i)}export{e as a,E as b,l as c,p as d,i as e,q as f};
//# sourceMappingURL=chunk.AM65KICK.js.map
