@cargosense/cargo-design-system 1.0.1 → 1.0.4

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.
@@ -1,9 +1,4 @@
1
- "use strict";var k=Object.defineProperty;var $=(i,t,r)=>t in i?k(i,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):i[t]=r;var o=(i,t,r)=>$(i,typeof t!="symbol"?t+"":t,r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../assets/Counter.cjs.js");require("../fonts/index.cjs.js");e.registerIcon();class c extends e.i{firstUpdated(){const t=document.getElementById(this.form);this.shadowRoot.querySelector("button").addEventListener("click",()=>{t instanceof HTMLFormElement&&(console.log("Form found, submitting..."),t.requestSubmit())})}constructor(){super(),this.link=void 0,this.target=void 0,this.disabled=!1,this.size="md",this.expand="",this._variant="primary",this.name=void 0,this.button="button",this.form=void 0,this.square=""}render(){return e.x`
2
- <a href='${e.o(this.link)}' target="${e.o(this.target)}" tabindex="-1" class="${this.expand}">
3
- <button form="${this.form}" type="${this.button}" class="button ${this.square} ${this.variant} ${this.size} ${this.expand} ${this.disabled?"disabled":""}" .name="${this.name}" tabindex="${this.disabled?"-1":0}" @click='${this.handleClick}'>
4
- <slot name='start'></slot> <slot></slot> <slot name='end'></slot>
5
- </button>
6
- </a> `}handleClick(t){if(this.disabled){t.preventDefault(),t.stopPropagation();return}this.dispatchEvent(new CustomEvent("button-click",{detail:{value:this.value,name:this.name},bubbles:!0,composed:!0}))}}o(c,"styles",e.i$1`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../assets/Counter.cjs.js");require("../fonts/index.cjs.js");e.registerIcon();class a extends e.i{static styles=e.i$1`
7
2
  @font-face {
8
3
  font-family: 'Geist';
9
4
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -119,17 +114,12 @@
119
114
  outline: none;
120
115
  }
121
116
 
122
- `),o(c,"properties",{variant:{type:String,reflect:!0,converter:t=>["classic","secondary","primary"].includes(t)?t:"classic"},size:{type:String,reflect:!0,attribute:"size",converter:t=>["sm","md","lg"].includes(t)?t:"md"},disabled:{type:Boolean,reflect:!0,attribute:"disabled"},link:{type:String,reflect:!0,attribute:"link"},target:{type:String,reflect:!0,attribute:"target",converter:t=>["_blank","_self","_parent","_top"].includes(t)?t:"_self"},expand:{type:Boolean,reflect:!0,attribute:"full-width",converter:t=>t==""?"expand":""},value:{type:String,reflect:!0,attribute:"value",defaultValue:""},type:{type:String,reflect:!0,attribute:"type",converter:t=>["button","submit","reset"].includes(t)?t:"button"},square:{type:Boolean,reflect:!0,attribute:"square",converter:t=>t===""?"square":""},form:{type:String,reflect:!0,attribute:"form"}});function y(){typeof window<"u"&&!customElements.get("cd-button")&&customElements.define("cd-button",c)}e.registerIcon();class d extends e.i{constructor(){super(),this.icon="",this.title=""}render(){return e.x`
123
- <header class="header">
124
- <div class='left'>
125
- <cd-icon name="${this.icon}" size="md"></cd-icon>
126
- <span class="title">${this.title}</span>
127
- </div>
128
- <div class='right'>
129
- <slot></slot>
130
- </div>
131
- </header>
132
- `}}o(d,"styles",e.i$1`
117
+ `;static properties={variant:{type:String,reflect:!0,converter:t=>["classic","secondary","primary"].includes(t)?t:"classic"},size:{type:String,reflect:!0,attribute:"size",converter:t=>["sm","md","lg"].includes(t)?t:"md"},disabled:{type:Boolean,reflect:!0,attribute:"disabled"},link:{type:String,reflect:!0,attribute:"link"},target:{type:String,reflect:!0,attribute:"target",converter:t=>["_blank","_self","_parent","_top"].includes(t)?t:"_self"},expand:{type:Boolean,reflect:!0,attribute:"full-width",converter:t=>t==""?"expand":""},value:{type:String,reflect:!0,attribute:"value",defaultValue:""},type:{type:String,reflect:!0,attribute:"type",converter:t=>["button","submit","reset"].includes(t)?t:"button"},square:{type:Boolean,reflect:!0,attribute:"square",converter:t=>t===""?"square":""},form:{type:String,reflect:!0,attribute:"form"}};firstUpdated(){const t=document.getElementById(this.form);this.shadowRoot.querySelector("button").addEventListener("click",()=>{t instanceof HTMLFormElement&&(console.log("Form found, submitting..."),t.requestSubmit())})}constructor(){super(),this.link=void 0,this.target=void 0,this.disabled=!1,this.size="md",this.expand="",this._variant="primary",this.name=void 0,this.button="button",this.form=void 0,this.square=""}render(){return e.x`
118
+ <a href='${e.o(this.link)}' target="${e.o(this.target)}" tabindex="-1" class="${this.expand}">
119
+ <button form="${this.form}" type="${this.button}" class="button ${this.square} ${this.variant} ${this.size} ${this.expand} ${this.disabled?"disabled":""}" .name="${this.name}" tabindex="${this.disabled?"-1":0}" @click='${this.handleClick}'>
120
+ <slot name='start'></slot> <slot></slot> <slot name='end'></slot>
121
+ </button>
122
+ </a> `}handleClick(t){if(this.disabled){t.preventDefault(),t.stopPropagation();return}this.dispatchEvent(new CustomEvent("button-click",{detail:{value:this.value,name:this.name},bubbles:!0,composed:!0}))}}function i(){typeof window<"u"&&!customElements.get("cd-button")&&customElements.define("cd-button",a)}e.registerIcon();class n extends e.i{static styles=e.i$1`
133
123
  @font-face {
134
124
  font-family: 'Geist';
135
125
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -169,11 +159,17 @@
169
159
  padding: 0 16px;
170
160
 
171
161
  }
172
- `),o(d,"properties",{icon:{type:String,reflect:!0,attribute:"icon"},title:{type:String,reflect:!0,attribute:"title"}});function E(){!customElements.get("cd-header")&&typeof window<"u"&&customElements.define("cd-header",d)}e.registerIcon();class l extends e.i{handleKeyPress(t){return this.dispatchEvent(new CustomEvent("keypress",{detail:{value:t.target.value,key:t.keyCode}})),t.key==="Enter"&&this.dispatchEvent(new CustomEvent("onenter",{detail:{value:t.target.value}})),this.dispatchEvent(new CustomEvent("onkeyup",{detail:{value:t.target.value,key:t.keyCode}})),this._internals.setFormValue(t.target.value),this.value=t.target.value,t.target.value}handleInput(t){return this.dispatchEvent(new CustomEvent("input",{detail:{value:t.target.value}})),this._internals.setFormValue(t.target.value),this.value=t.target.value,t.target.value}handleChange(t){return this.dispatchEvent(new CustomEvent("onchange",{detail:{value:t.target.value}})),this._internals.setFormValue(t.target.value),this.value=t.target.value,t.target.value}handleFocus(t){return this.dispatchEvent(new CustomEvent("onblur",{detail:{value:t.target.value}})),this._internals.setFormValue(t.target.value),this.value=t.target.value,t.target}constructor(){super(),this.value="",this.placeholder="",this.pattern="",this.variant="solid",this.size="md",this._internals=this.attachInternals()}render(){return e.x`
173
- ${this.iconLeft?e.x`<span class="icon-left-container"><cd-icon name="${this.iconLeft}" size="sm" class="icon-left"></cd-icon></span>`:""}
174
- <input id='${this.name}' class="${this.iconLeft?"icon-spacing-left":""} ${this.iconRight?" icon-spacing-right":""} ${this.disabled?" disabled":""} ${this.error?" input-error":""} ${this.fullWidth?" full-width":""} ${this.variant==="dashed"?" dashed":this.variant=="dotted"?" dotted":""} ${this.size}" type="${this.type}" placeholder="${this.placeholder}" ?required=${this.required} .value="${this.value}" ?readonly=${this.readOnly} ?disabled=${this.disabled} .pattern="${this.pattern}" @input="${this.handleInput}" @change="${this.handleChange}" @blur="${this.handleFocus}" @keypress=${this.handleKeyPress}/>
175
- ${this.iconRight?e.x`<span class="icon-right-container"><cd-icon name="${this.iconRight}" size="sm" class="icon-right"></cd-icon></span>`:""}
176
- `}focus(){if(!this.shadowRoot){console.warn("Input element is not yet connected to the DOM.");return}if(!this.shadowRoot.querySelector("input")){console.warn("Input element is not found in the shadow DOM.");return}this.shadowRoot.querySelector("input").focus()}}o(l,"formAssociated",!0),o(l,"styles",e.i$1`
162
+ `;static properties={icon:{type:String,reflect:!0,attribute:"icon"},title:{type:String,reflect:!0,attribute:"title"}};constructor(){super(),this.icon="",this.title=""}render(){return e.x`
163
+ <header class="header">
164
+ <div class='left'>
165
+ <cd-icon name="${this.icon}" size="md"></cd-icon>
166
+ <span class="title">${this.title}</span>
167
+ </div>
168
+ <div class='right'>
169
+ <slot></slot>
170
+ </div>
171
+ </header>
172
+ `}}function y(){!customElements.get("cd-header")&&typeof window<"u"&&customElements.define("cd-header",n)}e.registerIcon();class s extends e.i{static formAssociated=!0;static styles=e.i$1`
177
173
  @font-face {
178
174
  font-family: 'Geist';
179
175
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -295,19 +291,11 @@
295
291
 
296
292
 
297
293
 
298
- `),o(l,"properties",{name:{type:String,reflect:!0},type:{type:String,reflect:!0,converter:t=>["text","date","time","number","tel","url","phone","email","password"].includes(t)?t:"text"},disabled:{type:Boolean,reflect:!0},placeholder:{type:String,reflect:!0},readOnly:{type:Boolean,reflect:!0,attribute:"read-only"},required:{type:Boolean,reflect:!0},pattern:{type:String},error:{type:Boolean,reflect:!0},value:{type:String,reflect:!0},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"},variant:{type:String,reflect:!0},size:{type:String,reflect:!0,converter:t=>["sm","md","lg"].includes(t)?t:"md"},iconLeft:{type:String,reflect:!0,attribute:"icon-left"},iconRight:{type:String,reflect:!0,attribute:"icon-right"}});function z(){typeof window<"u"&&!customElements.get("cd-input")&&customElements.define("cd-input",l)}e.registerNavImage();class u extends e.i{constructor(){super(),this.image="",this.name=""}render(){return e.x`
299
- <nav class="navbar ${this.small?"small":""}">
300
- ${this.image!=""&&this.name!=""?e.x` <div class="image">
301
- <cd-nav-image src="${this.image}" alt="Logo" name="${this.name}"></cd-nav-image>
302
- </div>`:""}
303
-
304
- <div class="items">
305
- <slot name="start"></slot>
306
- <slot></slot>
307
- <slot name="end"></slot>
308
- </div>
309
- </nav>
310
- `}}o(u,"styles",e.i$1`
294
+ `;static properties={name:{type:String,reflect:!0},type:{type:String,reflect:!0,converter:t=>["text","date","time","number","tel","url","phone","email","password"].includes(t)?t:"text"},disabled:{type:Boolean,reflect:!0},placeholder:{type:String,reflect:!0},readOnly:{type:Boolean,reflect:!0,attribute:"read-only"},required:{type:Boolean,reflect:!0},pattern:{type:String},error:{type:Boolean,reflect:!0},value:{type:String,reflect:!0},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"},variant:{type:String,reflect:!0},size:{type:String,reflect:!0,converter:t=>["sm","md","lg"].includes(t)?t:"md"},iconLeft:{type:String,reflect:!0,attribute:"icon-left"},iconRight:{type:String,reflect:!0,attribute:"icon-right"}};handleKeyPress(t){return this.dispatchEvent(new CustomEvent("keypress",{detail:{value:t.target.value,key:t.keyCode}})),t.key==="Enter"&&this.dispatchEvent(new CustomEvent("onenter",{detail:{value:t.target.value}})),this.dispatchEvent(new CustomEvent("onkeyup",{detail:{value:t.target.value,key:t.keyCode}})),this._internals.setFormValue(t.target.value),this.value=t.target.value,t.target.value}handleInput(t){return this.dispatchEvent(new CustomEvent("input",{detail:{value:t.target.value}})),this._internals.setFormValue(t.target.value),this.value=t.target.value,t.target.value}handleChange(t){return this.dispatchEvent(new CustomEvent("onchange",{detail:{value:t.target.value}})),this._internals.setFormValue(t.target.value),this.value=t.target.value,t.target.value}handleFocus(t){return this.dispatchEvent(new CustomEvent("onblur",{detail:{value:t.target.value}})),this._internals.setFormValue(t.target.value),this.value=t.target.value,t.target}constructor(){super(),this.value="",this.placeholder="",this.pattern="",this.variant="solid",this.size="md",this._internals=this.attachInternals()}render(){return e.x`
295
+ ${this.iconLeft?e.x`<span class="icon-left-container"><cd-icon name="${this.iconLeft}" size="sm" class="icon-left"></cd-icon></span>`:""}
296
+ <input id='${this.name}' class="${this.iconLeft?"icon-spacing-left":""} ${this.iconRight?" icon-spacing-right":""} ${this.disabled?" disabled":""} ${this.error?" input-error":""} ${this.fullWidth?" full-width":""} ${this.variant==="dashed"?" dashed":this.variant=="dotted"?" dotted":""} ${this.size}" type="${this.type}" placeholder="${this.placeholder}" ?required=${this.required} .value="${this.value}" ?readonly=${this.readOnly} ?disabled=${this.disabled} .pattern="${this.pattern}" @input="${this.handleInput}" @change="${this.handleChange}" @blur="${this.handleFocus}" @keypress=${this.handleKeyPress}/>
297
+ ${this.iconRight?e.x`<span class="icon-right-container"><cd-icon name="${this.iconRight}" size="sm" class="icon-right"></cd-icon></span>`:""}
298
+ `}focus(){if(!this.shadowRoot){console.warn("Input element is not yet connected to the DOM.");return}if(!this.shadowRoot.querySelector("input")){console.warn("Input element is not found in the shadow DOM.");return}this.shadowRoot.querySelector("input").focus()}}function w(){typeof window<"u"&&!customElements.get("cd-input")&&customElements.define("cd-input",s)}e.registerNavImage();class l extends e.i{static styles=e.i$1`
311
299
  @font-face {
312
300
  font-family: 'Geist';
313
301
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -364,18 +352,19 @@
364
352
  flex-direction: column;
365
353
  gap: 8px;
366
354
  }
367
- `),o(u,"properties",{image:{type:String,reflect:!0,attribute:"image",defaultValue:""},name:{type:String,reflect:!0,attribute:"name",defaultValue:""},small:{type:Boolean,reflect:!0,attribute:"sidebar",defaultValue:!1}});function S(){typeof window<"u"&&!customElements.get("cd-nav-bar")&&customElements.define("cd-nav-bar",u)}e.registerCounter();e.registerIcon();class p extends e.i{constructor(){super(),this.icon="",this.name="",this.variant="none",this.amount=0,this.maxCount=99,this.important=!1,this.dropdown=!1,this.active=!1,this.selected=!1,this.link=void 0}render(){return e.x`
368
- <a href="${e.o(this.link)}" class="nav-item ${this.active?"active":""} ${this.select?"selected":""}" tabindex="0">
369
- <slot name="before" class="${this.amount>0&&!this.select?"standout":""} ${this.select?"selected":""}"></slot>
370
- <p>${this.name}</p>
371
- ${this.variant=="dropdown"?e.x`<cd-icon class='caret' name='caret-down' size='sm'></cd-icon>`:""}
372
- ${this.variant=="link"?e.x`<cd-icon name='external' size='sm'></cd-icon>`:""}
373
- ${this.variant=="number"?e.x`<cd-counter count='${this.amount}' max-count='${this.maxCount}' important='${this.important}'></cd-notification-counter>`:""}
374
- </a>
375
- <div class="children ${this.active?"children-active":""}">
376
- <slot></slot>
377
- </div>
378
- `}setSelectState(t){if(typeof t!="boolean")throw new Error("Select must be a boolean value");this.select!==t&&(this.select=t,this.requestUpdate())}setActiveState(t){if(typeof t!="boolean")throw new Error("Active must be a boolean value");this.active!==t&&(this.active=t,this.requestUpdate())}toggleSelect(){this.select=!this.select,this.requestUpdate()}toggleActive(){this.active=!this.active,this.requestUpdate()}}o(p,"styles",e.i$1`
355
+ `;static properties={image:{type:String,reflect:!0,attribute:"image",defaultValue:""},name:{type:String,reflect:!0,attribute:"name",defaultValue:""},small:{type:Boolean,reflect:!0,attribute:"sidebar",defaultValue:!1}};constructor(){super(),this.image="",this.name=""}render(){return e.x`
356
+ <nav class="navbar ${this.small?"small":""}">
357
+ ${this.image!=""&&this.name!=""?e.x` <div class="image">
358
+ <cd-nav-image src="${this.image}" alt="Logo" name="${this.name}"></cd-nav-image>
359
+ </div>`:""}
360
+
361
+ <div class="items">
362
+ <slot name="start"></slot>
363
+ <slot></slot>
364
+ <slot name="end"></slot>
365
+ </div>
366
+ </nav>
367
+ `}}function k(){typeof window<"u"&&!customElements.get("cd-nav-bar")&&customElements.define("cd-nav-bar",l)}e.registerCounter();e.registerIcon();class c extends e.i{static styles=e.i$1`
379
368
  @font-face {
380
369
  font-family: 'Geist';
381
370
  src: url('${e.r(e.fontURL)}') format('woff');
@@ -469,9 +458,18 @@
469
458
  --icon-stroke: var(--base-color-teal-900);
470
459
  --icon-background-primary: var(--base-color-teal-300);
471
460
  }
472
- `),o(p,"properties",{name:{type:String,reflect:!0,attribute:"name"},variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["dropdown","link","number"].includes(t)?t:"none"},amount:{type:Number,reflect:!0,attribute:"amount",converter:t=>isNaN(t)?0:t},maxCount:{type:Number,reflect:!0,attribute:"max-count",converter:t=>isNaN(t)?99:t},important:{type:Boolean,reflect:!0,attribute:"important"},link:{type:String,reflect:!0,attribute:"link"},icon:{type:String,reflect:!0,attribute:"icon"},active:{type:Boolean,reflect:!0,attribute:"active"},select:{type:Boolean,reflect:!0,attribute:"selected"}});function A(){typeof window<"u"&&!customElements.get("cd-nav-item")&&customElements.define("cd-nav-item",p)}class h extends e.i{constructor(){super()}render(){return e.x`
461
+ `;static properties={name:{type:String,reflect:!0,attribute:"name"},variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["dropdown","link","number"].includes(t)?t:"none"},amount:{type:Number,reflect:!0,attribute:"amount",converter:t=>isNaN(t)?0:t},maxCount:{type:Number,reflect:!0,attribute:"max-count",converter:t=>isNaN(t)?99:t},important:{type:Boolean,reflect:!0,attribute:"important"},link:{type:String,reflect:!0,attribute:"link"},icon:{type:String,reflect:!0,attribute:"icon"},active:{type:Boolean,reflect:!0,attribute:"active"},select:{type:Boolean,reflect:!0,attribute:"selected"}};constructor(){super(),this.icon="",this.name="",this.variant="none",this.amount=0,this.maxCount=99,this.important=!1,this.dropdown=!1,this.active=!1,this.selected=!1,this.link=void 0}render(){return e.x`
462
+ <a href="${e.o(this.link)}" class="nav-item ${this.active?"active":""} ${this.select?"selected":""}" tabindex="0">
463
+ <slot name="before" class="${this.amount>0&&!this.select?"standout":""} ${this.select?"selected":""}"></slot>
464
+ <p>${this.name}</p>
465
+ ${this.variant=="dropdown"?e.x`<cd-icon class='caret' name='caret-down' size='sm'></cd-icon>`:""}
466
+ ${this.variant=="link"?e.x`<cd-icon name='external' size='sm'></cd-icon>`:""}
467
+ ${this.variant=="number"?e.x`<cd-counter count='${this.amount}' max-count='${this.maxCount}' important='${this.important}'></cd-notification-counter>`:""}
468
+ </a>
469
+ <div class="children ${this.active?"children-active":""}">
473
470
  <slot></slot>
474
- `}}o(h,"styles",e.i$1`
471
+ </div>
472
+ `}setSelectState(t){if(typeof t!="boolean")throw new Error("Select must be a boolean value");this.select!==t&&(this.select=t,this.requestUpdate())}setActiveState(t){if(typeof t!="boolean")throw new Error("Active must be a boolean value");this.active!==t&&(this.active=t,this.requestUpdate())}toggleSelect(){this.select=!this.select,this.requestUpdate()}toggleActive(){this.active=!this.active,this.requestUpdate()}}function $(){typeof window<"u"&&!customElements.get("cd-nav-item")&&customElements.define("cd-nav-item",c)}class d extends e.i{static styles=e.i$1`
475
473
  @font-face {
476
474
  font-family: 'Geist';
477
475
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -483,18 +481,9 @@
483
481
  width: 100%;
484
482
  }
485
483
 
486
- `),o(h,"properties",{});function C(){typeof window<"u"&&!customElements.get("cd-table")&&customElements.define("cd-table",h)}class v extends e.i{constructor(){super(),this.text="",this.content=!1,this.position="top"}render(){return e.x`
487
- <div class="tooltip-container">
488
- <div class="tooltip ${this.position}">
489
- <div class="${this.content?"tooltip-content":"none"} ${this.text?"":"no-border"}">
490
- <slot></slot>
491
- </div>
492
- <div class="${this.text?"tooltip-text":"none"}">
493
- ${this.text}
494
- </div>
495
- </div>
496
- </div>
497
- `}}o(v,"styles",e.i$1`
484
+ `;static properties={};constructor(){super()}render(){return e.x`
485
+ <slot></slot>
486
+ `}}function E(){typeof window<"u"&&!customElements.get("cd-table")&&customElements.define("cd-table",d)}class u extends e.i{static styles=e.i$1`
498
487
  @font-face {
499
488
  font-family: 'Geist';
500
489
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -559,16 +548,18 @@
559
548
  .no-border {
560
549
  border-bottom: none;
561
550
  }
562
- `),o(v,"properties",{text:{type:String,reflect:!0},position:{type:String,reflect:!0,attribute:"position",converter:t=>["top","right","bottom","left"].includes(t)?t:"top"},content:{type:Boolean,reflect:!0}});function R(){typeof window<"u"&&!customElements.get("cd-tool-tip")&&customElements.define("cd-tool-tip",v)}e.registerIcon();class b extends e.i{constructor(){super(),this.primaryText="",this.secondaryText="",this.icon="hart"}render(){return e.x`
563
- <div class="profile-stack">
564
- <div class="text-stack">
565
- <span class="name">${this.primaryText}</span>
566
- ${this.secondaryText!=""?e.x`<span class="org"><cd-icon name="${this.icon}" size="sm"></cd-icon>${this.secondaryText}</span>`:""}
551
+ `;static properties={text:{type:String,reflect:!0},position:{type:String,reflect:!0,attribute:"position",converter:t=>["top","right","bottom","left"].includes(t)?t:"top"},content:{type:Boolean,reflect:!0}};constructor(){super(),this.text="",this.content=!1,this.position="top"}render(){return e.x`
552
+ <div class="tooltip-container">
553
+ <div class="tooltip ${this.position}">
554
+ <div class="${this.content?"tooltip-content":"none"} ${this.text?"":"no-border"}">
555
+ <slot></slot>
556
+ </div>
557
+ <div class="${this.text?"tooltip-text":"none"}">
558
+ ${this.text}
559
+ </div>
567
560
  </div>
568
- <cd-icon name="caret-down" size="sm"></cd-icon>
569
561
  </div>
570
-
571
- `}}o(b,"styles",e.i$1`
562
+ `}}function z(){typeof window<"u"&&!customElements.get("cd-tool-tip")&&customElements.define("cd-tool-tip",u)}e.registerIcon();class p extends e.i{static styles=e.i$1`
572
563
  @font-face {
573
564
  font-family: 'Geist';
574
565
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -610,11 +601,16 @@
610
601
  gap: 6px;
611
602
  align-items: center;
612
603
  }
613
- `),o(b,"properties",{primaryText:{type:String,reflect:!0,attribute:"name",defaultValue:""},secondaryText:{type:String,reflect:!0,attribute:"org",defaultValue:""},icon:{type:String,reflect:!0,attribute:"icon",defaultValue:""}});function L(){typeof window<"u"&&!customElements.get("cd-nav-profile")&&customElements.define("cd-nav-profile",b)}e.registerIcon();class f extends e.i{constructor(){super(),this.variant="default",this.link=void 0}render(){return e.x`
614
- ${this.variant==="default"?e.x`<a href="${e.o(this.link)}" class="value"><slot></slot></a>`:""}
615
- ${this.variant==="dropdown"?e.x`<span class="dropdown-value"><slot></slot></span>`:""}
616
- ${this.variant==="arrow"?e.x`<a href="${e.o(this.link)}" class="arrow-value"><slot></slot><cd-icon name="arrow" size="sm"></cd-icon></a>`:""}
617
- `}}o(f,"styles",e.i$1`
604
+ `;static properties={primaryText:{type:String,reflect:!0,attribute:"name",defaultValue:""},secondaryText:{type:String,reflect:!0,attribute:"org",defaultValue:""},icon:{type:String,reflect:!0,attribute:"icon",defaultValue:""}};constructor(){super(),this.primaryText="",this.secondaryText="",this.icon="hart"}render(){return e.x`
605
+ <div class="profile-stack">
606
+ <div class="text-stack">
607
+ <span class="name">${this.primaryText}</span>
608
+ ${this.secondaryText!=""?e.x`<span class="org"><cd-icon name="${this.icon}" size="sm"></cd-icon>${this.secondaryText}</span>`:""}
609
+ </div>
610
+ <cd-icon name="caret-down" size="sm"></cd-icon>
611
+ </div>
612
+
613
+ `}}function S(){typeof window<"u"&&!customElements.get("cd-nav-profile")&&customElements.define("cd-nav-profile",p)}e.registerIcon();class h extends e.i{static styles=e.i$1`
618
614
  @font-face {
619
615
  font-family: 'Geist';
620
616
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -691,29 +687,11 @@
691
687
  outline: 2px solid var(--input-border-color-focus);
692
688
  border-radius: 4px;
693
689
  }
694
- `),o(f,"properties",{variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["default","dropdown","arrow"].includes(t)?t:"default"},link:{type:String,reflect:!0,attribute:"link"}});function B(){typeof window<"u"&&!customElements.get("cd-value")&&customElements.define("cd-value",f)}e.registerIcon();class g extends e.i{handleBlur(t){return this.dispatchEvent(new CustomEvent("blur",{detail:{value:t.target.value},bubbles:!0,composed:!0})),this.value=t.target.value,t.target.value}handleFocus(t){return this.expandInput(),this.dispatchEvent(new CustomEvent("focus",{detail:{value:t.target.value},bubbles:!0,composed:!0})),this.value=t.target.value,t.target.value}handleKeyPress(t){return this.dispatchEvent(new CustomEvent("keypress",{detail:{value:t.target.value,key:t.target.keyCode},bubbles:!0,composed:!0})),this.value=t.target.value,t.target.value}handleInput(t){return this.dispatchEvent(new CustomEvent("input",{detail:{value:t.target.value},bubbles:!0,composed:!0})),this.value=t.target.value,t.target.value}constructor(){super(),this.placeholder="Search",this.value="",this.disabled=!1,this.collapsed=!1,this.iconLeft=!1,this.iconRight=!1,this.size="md",this.closeIcon=!1,this.label="",this.labelPosition="left",this.name="",this.fullWidth=!1,this._internals=this.attachInternals()}render(){return e.x`
695
- <div class="search-container ${this.labelPosition}">
696
- ${this.label?e.x`<label for="search-input">${this.label}</label>`:""}
697
- ${this.iconLeft&&!this.collapsed?e.x`<span class="icon-left-container"><cd-icon name="search" class="icon-left" variant="light-slate"></cd-icon></span>`:""}
698
-
699
- <input
700
- id="search-input"
701
- type="text"
702
- class="search-input ${this.collapsed?"collapsed":"expanded"} ${this.iconLeft?"icon-spacing-left":""} ${this.iconRight?"icon-spacing-right":""} ${this.size} ${this.fullWidth&&!this.collapsed?"full-width":""}"
703
- placeholder="${this.placeholder}"
704
- .value="${this.value}"
705
- ?disabled="${this.disabled}"
706
- @input="${this.handleInput}"
707
- @focus="${this.handleFocus}"
708
- @blur="${this.handleBlur}"
709
- @keypress="${this.handleKeyPress}"
710
- @click="${this.expandInput}"
711
- name="${this.name}"
712
- >
713
- ${this.iconRight||this.collapsed?e.x`<span @click="${this.expandInput}" class="${this.collapsed?"icon-collapsed-container":"icon-right-container"}"><cd-icon name="search" class="${this.collapsed?"icon-collapsed "+this.size:"icon-right"}" variant="light-slate"></cd-icon></span>`:""}
714
- ${this.closeIcon?e.x`<span class="${this.collapsed?"hidden":"active"}" id='closeIcon' tabindex='0'><cd-icon name="exit" id="close-icon" class="icon close ${this.collapsed?"hidden-icon":"active-icon"}" @click="${this.collapseInput}"></cd-icon></span>`:""}
715
- </div>
716
- `}firstUpdated(){if(!this.shadowRoot){console.warn("Shadow DOM is not available.");return}this.shadowRoot.querySelector(".active")&&(console.log("Adding event listener to active element"),this.shadowRoot.querySelector(".active").addEventListener("keydown",t=>{console.log("test"),t.keyCode===13&&this.collapseInput()}))}focus(){if(!this.shadowRoot){console.warn("Input element is not yet connected to the DOM.");return}if(!this.shadowRoot.querySelector("input")){console.warn("Input element is not found in the shadow DOM.");return}this.shadowRoot.querySelector("#search-input").focus()}expandInput(){this.collapsed&&(this.collapsed=!1,this.shadowRoot.querySelector("#search-input").focus(),this.shadowRoot.querySelector("#close-icon").classList.remove("hidden-icon"),this.shadowRoot.querySelector("#close-icon").classList.remove("hidden"),this.shadowRoot.querySelector("#close-icon").classList.add("active-icon"),this.shadowRoot.querySelector("#close-icon").classList.add("active"),this.requestUpdate(),this.shadowRoot.querySelector("#closeIcon").addEventListener("keydown",t=>{t.key==="Enter"&&this.collapseInput()}))}collapseInput(){this.collapsed||(this.collapsed=!0,this.value="",this.shadowRoot.querySelector("#close-icon").classList.add("hidden-icon"),this.shadowRoot.querySelector("#close-icon").classList.add("hidden"),this.shadowRoot.querySelector("#close-icon").classList.remove("active"),this.shadowRoot.querySelector("#close-icon").classList.remove("active-icon"),this.dispatchEvent(new CustomEvent("collapsed",{detail:{closed:!0},bubbles:!0,composed:!0})),this.requestUpdate())}}o(g,"styles",e.i$1`
690
+ `;static properties={variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["default","dropdown","arrow"].includes(t)?t:"default"},link:{type:String,reflect:!0,attribute:"link"}};constructor(){super(),this.variant="default",this.link=void 0}render(){return e.x`
691
+ ${this.variant==="default"?e.x`<a href="${e.o(this.link)}" class="value"><slot></slot></a>`:""}
692
+ ${this.variant==="dropdown"?e.x`<span class="dropdown-value"><slot></slot></span>`:""}
693
+ ${this.variant==="arrow"?e.x`<a href="${e.o(this.link)}" class="arrow-value"><slot></slot><cd-icon name="arrow" size="sm"></cd-icon></a>`:""}
694
+ `}}function A(){typeof window<"u"&&!customElements.get("cd-value")&&customElements.define("cd-value",h)}e.registerIcon();class v extends e.i{static styles=e.i$1`
717
695
  @font-face {
718
696
  font-family: 'Geist';
719
697
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -897,15 +875,29 @@
897
875
  opacity: 0;
898
876
  transition: opacity 0.5s ease-in-out;
899
877
  }
900
- `),o(g,"properties",{placeholder:{type:String,reflect:!0},value:{type:String,reflect:!0},disabled:{type:Boolean,reflect:!0},collapsed:{type:Boolean,reflect:!0},iconLeft:{type:Boolean,reflect:!0,attribute:"icon-left"},iconRight:{type:Boolean,reflect:!0,attribute:"icon-right"},size:{type:String,reflect:!0},closeIcon:{type:Boolean,reflect:!0,attribute:"close-icon"},label:{type:String,reflect:!0},labelPosition:{type:String,reflect:!0,attribute:"label-position"},name:{type:String,reflect:!0},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"}});function q(){typeof window<"u"&&!customElements.get("cd-search")&&customElements.define("cd-search",g)}e.registerIcon();class m extends e.i{constructor(){super(),this.label="",this.active=!1,this.disabled=!1,this.variant="default",this.size="md"}render(){return e.x`
901
- <div class="tab-outer ${this.variant} ${this.active?"active":""}" >
902
- <div class='tab ${this.variant} ${this.size} ${this.disabled?"disabled":""} ${this.active?"active":""}' tabindex="${this.disabled?-1:0}">
903
- <slot name="start"></slot>
904
- <span class="label">${this.label}</span>
905
- <slot name="end"></slot>
878
+ `;static properties={placeholder:{type:String,reflect:!0},value:{type:String,reflect:!0},disabled:{type:Boolean,reflect:!0},collapsed:{type:Boolean,reflect:!0},iconLeft:{type:Boolean,reflect:!0,attribute:"icon-left"},iconRight:{type:Boolean,reflect:!0,attribute:"icon-right"},size:{type:String,reflect:!0},closeIcon:{type:Boolean,reflect:!0,attribute:"close-icon"},label:{type:String,reflect:!0},labelPosition:{type:String,reflect:!0,attribute:"label-position"},name:{type:String,reflect:!0},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"}};handleBlur(t){return this.dispatchEvent(new CustomEvent("blur",{detail:{value:t.target.value},bubbles:!0,composed:!0})),this.value=t.target.value,t.target.value}handleFocus(t){return this.expandInput(),this.dispatchEvent(new CustomEvent("focus",{detail:{value:t.target.value},bubbles:!0,composed:!0})),this.value=t.target.value,t.target.value}handleKeyPress(t){return this.dispatchEvent(new CustomEvent("keypress",{detail:{value:t.target.value,key:t.target.keyCode},bubbles:!0,composed:!0})),this.value=t.target.value,t.target.value}handleInput(t){return this.dispatchEvent(new CustomEvent("input",{detail:{value:t.target.value},bubbles:!0,composed:!0})),this.value=t.target.value,t.target.value}constructor(){super(),this.placeholder="Search",this.value="",this.disabled=!1,this.collapsed=!1,this.iconLeft=!1,this.iconRight=!1,this.size="md",this.closeIcon=!1,this.label="",this.labelPosition="left",this.name="",this.fullWidth=!1,this._internals=this.attachInternals()}render(){return e.x`
879
+ <div class="search-container ${this.labelPosition}">
880
+ ${this.label?e.x`<label for="search-input">${this.label}</label>`:""}
881
+ ${this.iconLeft&&!this.collapsed?e.x`<span class="icon-left-container"><cd-icon name="search" class="icon-left" variant="light-slate"></cd-icon></span>`:""}
882
+
883
+ <input
884
+ id="search-input"
885
+ type="text"
886
+ class="search-input ${this.collapsed?"collapsed":"expanded"} ${this.iconLeft?"icon-spacing-left":""} ${this.iconRight?"icon-spacing-right":""} ${this.size} ${this.fullWidth&&!this.collapsed?"full-width":""}"
887
+ placeholder="${this.placeholder}"
888
+ .value="${this.value}"
889
+ ?disabled="${this.disabled}"
890
+ @input="${this.handleInput}"
891
+ @focus="${this.handleFocus}"
892
+ @blur="${this.handleBlur}"
893
+ @keypress="${this.handleKeyPress}"
894
+ @click="${this.expandInput}"
895
+ name="${this.name}"
896
+ >
897
+ ${this.iconRight||this.collapsed?e.x`<span @click="${this.expandInput}" class="${this.collapsed?"icon-collapsed-container":"icon-right-container"}"><cd-icon name="search" class="${this.collapsed?"icon-collapsed "+this.size:"icon-right"}" variant="light-slate"></cd-icon></span>`:""}
898
+ ${this.closeIcon?e.x`<span class="${this.collapsed?"hidden":"active"}" id='closeIcon' tabindex='0'><cd-icon name="exit" id="close-icon" class="icon close ${this.collapsed?"hidden-icon":"active-icon"}" @click="${this.collapseInput}"></cd-icon></span>`:""}
906
899
  </div>
907
- </div>
908
- `}toggleActive(){this.active=!this.active}setActive(t){if(typeof t!="boolean")throw new TypeError("Active must be a boolean");if(this.disabled)throw new Error("Cannot set active state when the tab is disabled");this.active=t}setDisabled(t){if(typeof t!="boolean")throw new TypeError("Disabled must be a boolean");if(this.active&&t)throw new Error("Cannot disable an active tab");this.disabled=t}}o(m,"styles",e.i$1`
900
+ `}firstUpdated(){if(!this.shadowRoot){console.warn("Shadow DOM is not available.");return}this.shadowRoot.querySelector(".active")&&(console.log("Adding event listener to active element"),this.shadowRoot.querySelector(".active").addEventListener("keydown",t=>{console.log("test"),t.keyCode===13&&this.collapseInput()}))}focus(){if(!this.shadowRoot){console.warn("Input element is not yet connected to the DOM.");return}if(!this.shadowRoot.querySelector("input")){console.warn("Input element is not found in the shadow DOM.");return}this.shadowRoot.querySelector("#search-input").focus()}expandInput(){this.collapsed&&(this.collapsed=!1,this.shadowRoot.querySelector("#search-input").focus(),this.shadowRoot.querySelector("#close-icon").classList.remove("hidden-icon"),this.shadowRoot.querySelector("#close-icon").classList.remove("hidden"),this.shadowRoot.querySelector("#close-icon").classList.add("active-icon"),this.shadowRoot.querySelector("#close-icon").classList.add("active"),this.requestUpdate(),this.shadowRoot.querySelector("#closeIcon").addEventListener("keydown",t=>{t.key==="Enter"&&this.collapseInput()}))}collapseInput(){this.collapsed||(this.collapsed=!0,this.value="",this.shadowRoot.querySelector("#close-icon").classList.add("hidden-icon"),this.shadowRoot.querySelector("#close-icon").classList.add("hidden"),this.shadowRoot.querySelector("#close-icon").classList.remove("active"),this.shadowRoot.querySelector("#close-icon").classList.remove("active-icon"),this.dispatchEvent(new CustomEvent("collapsed",{detail:{closed:!0},bubbles:!0,composed:!0})),this.requestUpdate())}}function C(){typeof window<"u"&&!customElements.get("cd-search")&&customElements.define("cd-search",v)}e.registerIcon();class b extends e.i{static styles=e.i$1`
909
901
  @font-face {
910
902
  font-family: 'Geist';
911
903
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -1010,11 +1002,15 @@
1010
1002
  .tab:focus {
1011
1003
  outline: 2px solid var(--input-border-color-focus);
1012
1004
  }
1013
- `),o(m,"properties",{label:{type:String,reflect:!0},active:{type:Boolean,reflect:!0},disabled:{type:Boolean,reflect:!0},variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["default","pill","outline"].includes(t)?t:"default"},size:{type:String,reflect:!0}});function _(){typeof window<"u"&&!customElements.get("cd-tab")&&customElements.define("cd-tab",m)}class x extends e.i{render(){return e.x`
1014
- <div class='container ${this.variant}'>
1015
- <slot></slot>
1005
+ `;static properties={label:{type:String,reflect:!0},active:{type:Boolean,reflect:!0},disabled:{type:Boolean,reflect:!0},variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["default","pill","outline"].includes(t)?t:"default"},size:{type:String,reflect:!0}};constructor(){super(),this.label="",this.active=!1,this.disabled=!1,this.variant="default",this.size="md"}render(){return e.x`
1006
+ <div class="tab-outer ${this.variant} ${this.active?"active":""}" >
1007
+ <div class='tab ${this.variant} ${this.size} ${this.disabled?"disabled":""} ${this.active?"active":""}' tabindex="${this.disabled?-1:0}">
1008
+ <slot name="start"></slot>
1009
+ <span class="label">${this.label}</span>
1010
+ <slot name="end"></slot>
1011
+ </div>
1016
1012
  </div>
1017
- `}}o(x,"styles",e.i$1`
1013
+ `}toggleActive(){this.active=!this.active}setActive(t){if(typeof t!="boolean")throw new TypeError("Active must be a boolean");if(this.disabled)throw new Error("Cannot set active state when the tab is disabled");this.active=t}setDisabled(t){if(typeof t!="boolean")throw new TypeError("Disabled must be a boolean");if(this.active&&t)throw new Error("Cannot disable an active tab");this.disabled=t}}function T(){typeof window<"u"&&!customElements.get("cd-tab")&&customElements.define("cd-tab",b)}class f extends e.i{static styles=e.i$1`
1018
1014
  @font-face {
1019
1015
  font-family: 'Geist';
1020
1016
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -1037,13 +1033,11 @@
1037
1033
 
1038
1034
 
1039
1035
 
1040
- `),o(x,"properties",{variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["default","pill","outline"].includes(t)?t:"default",defaultValue:"default"}});function I(){typeof window<"u"&&!customElements.get("cd-tab-container")&&customElements.define("cd-tab-container",x)}y();class a extends e.i{constructor(){super();o(this,"handleChange",r=>(this.value=r.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value));o(this,"handleInput",r=>(this.value=r.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("input",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value));o(this,"handleFocus",r=>(this.value=r.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("focus",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value));o(this,"handleBlur",r=>(this.value=r.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("blur",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value));this.value="",this.shortcut=void 0,this.disabled=void 0,this.form=void 0,this.size="md",this.fullWidth=!1,this.variant="default",this.timezone="America/New_York",this._internals=this.attachInternals(),this._internals.setValidity({customError:this.errorText&&this.errorText.length>0||!1})}render(){return e.x`
1041
- <div class='container'>
1042
- <input class='${this.error?"input-error":""} ${this.disabled?"disabled":""} ${this.fullWidth?"full-width":""} ${this.variant} ${this.size}' type='date' id='${this.name|"date"}' name='${this.name|"date"}' .value='${this.value}' @change='${this.handleChange}' @focus='${this.handleFocus}' @blur='${this.handleBlur}' @input='${this.handleInput}' ?disabled='${this.disabled}' />
1043
- ${this.shortcut?e.x`<cd-button variant='primary' ?disabled='${this.disabled}'>${this.shortcut}</cd-button>`:""}
1036
+ `;static properties={variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["default","pill","outline"].includes(t)?t:"default",defaultValue:"default"}};render(){return e.x`
1037
+ <div class='container ${this.variant}'>
1038
+ <slot></slot>
1044
1039
  </div>
1045
-
1046
- `}firstUpdated(){if(!this.shadowRoot){console.warn("Shadow DOM not available, DateComponent may not render correctly.");return}this.shadowRoot.querySelector("cd-button")&&this.shadowRoot.querySelector("cd-button").addEventListener("button-click",()=>{this.setValue(this.dateNow()),this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value},bubbles:!0,composed:!0}))})}dateNow(){let r=new Date().toLocaleString("en-US",{timeZone:this.timezone});return new Date(r).toISOString().slice(0,10)}setValue(r){this.value=r,this._internals.setFormValue(r),this.requestUpdate()}setError(r){if(typeof r!="error"){console.warn("Error text must be a string");return}this.error=r,this._internals.setValidity({customError:r}),this.requestUpdate()}setDisabled(r){this.disabled=r,this._internals.setValidity({customError:r}),this.requestUpdate()}}o(a,"formAssociated",!0),o(a,"distinctTimezones",["Etc/GMT+12","Pacific/Pago_Pago","Pacific/Honolulu","America/Anchorage","America/Los_Angeles","America/Denver","America/Chicago","America/New_York","America/Halifax","America/Argentina/Buenos_Aires","America/Noronha","Atlantic/Azores","Europe/London","Europe/Paris","Europe/Bucharest","Europe/Moscow","Asia/Tehran","Asia/Dubai","Asia/Kabul","Asia/Karachi","Asia/Kolkata","Asia/Kathmandu","Asia/Dhaka","Asia/Yangon","Asia/Bangkok","Asia/Shanghai","Australia/Eucla","Asia/Tokyo","Australia/Darwin","Australia/Sydney","Australia/Lord_Howe","Pacific/Noumea","Pacific/Auckland","Pacific/Chatham","Pacific/Tongatapu","Pacific/Kiritimati"]),o(a,"styles",e.i$1`
1040
+ `}}function B(){typeof window<"u"&&!customElements.get("cd-tab-container")&&customElements.define("cd-tab-container",f)}i();class g extends e.i{static formAssociated=!0;static distinctTimezones=["Etc/GMT+12","Pacific/Pago_Pago","Pacific/Honolulu","America/Anchorage","America/Los_Angeles","America/Denver","America/Chicago","America/New_York","America/Halifax","America/Argentina/Buenos_Aires","America/Noronha","Atlantic/Azores","Europe/London","Europe/Paris","Europe/Bucharest","Europe/Moscow","Asia/Tehran","Asia/Dubai","Asia/Kabul","Asia/Karachi","Asia/Kolkata","Asia/Kathmandu","Asia/Dhaka","Asia/Yangon","Asia/Bangkok","Asia/Shanghai","Australia/Eucla","Asia/Tokyo","Australia/Darwin","Australia/Sydney","Australia/Lord_Howe","Pacific/Noumea","Pacific/Auckland","Pacific/Chatham","Pacific/Tongatapu","Pacific/Kiritimati"];static styles=e.i$1`
1047
1041
  @font-face {
1048
1042
  font-family: 'Geist';
1049
1043
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -1135,10 +1129,13 @@
1135
1129
  flex-direction: row;
1136
1130
  align-items: center;
1137
1131
  }
1138
- `),o(a,"properties",{value:{type:String,reflect:!0},shortcut:{type:String,reflect:!0},error:{type:Boolean,reflect:!0,attribute:"error"},disabled:{type:Boolean,reflect:!0},form:{type:String,reflect:!0,attribute:"form"},size:{type:String,reflect:!0,attribute:"size",converter:r=>["sm","md","lg"].includes(r)?r:"md"},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"},variant:{type:String,reflect:!0,attribute:"variant",converter:r=>["dashed","dotted"].includes(r)?r:"default"},timezone:{type:String,reflect:!0,attribute:"timezone",converter:r=>distinctTimezones.includes(r)?r:"America/New_York"}});function T(){typeof window<"u"&&!customElements.get("cd-date")&&customElements.define("cd-date",a)}y();class n extends e.i{constructor(){super();o(this,"handleChange",r=>(this.value=r.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value));o(this,"handleInput",r=>(this.value=r.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("input",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value));o(this,"handleFocus",r=>(this.value=r.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("focus",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value));o(this,"handleBlur",r=>(this.value=r.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("blur",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value));this.value="",this.shortcut=void 0,this.error=!1,this.disabled=void 0,this.form=void 0,this.size="md",this.fullWidth=!1,this.variant="default",this.timezone="America/New_York",this._internals=this.attachInternals(),this._internals.setValidity({customError:this.errorText&&this.errorText.length>0||!1})}render(){return e.x`
1139
- <input class='${this.error?"input-error":""} ${this.disabled?"disabled":""} ${this.fullWidth?"full-width":""} ${this.variant} ${this.size}' type='time' id='${this.name|"time"}' name='${this.name|"time"}' .value='${this.value}' @change='${this.handleChange}' @focus='${this.handleFocus}' @blur='${this.handleBlur}' @input='${this.handleInput}' ?disabled='${this.disabled}' />
1140
- ${this.shortcut?e.x`<cd-button variant='primary' ?disabled='${this.disabled}'>${this.shortcut}</cd-button>`:""}
1141
- `}firstUpdated(){if(!this.shadowRoot){console.warn("Shadow DOM not available, TimeComponent may not render correctly.");return}this.shadowRoot.querySelector("cd-button")&&this.shadowRoot.querySelector("cd-button").addEventListener("button-click",()=>{this.setValue(this.timeNow()),this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value},bubbles:!0,composed:!0}))})}timeNow(){console.log(this.timezone);let r=new Date().toLocaleString("en-US",{timeZone:this.timezone||"America/New_York"});if(console.log(r),console.log(r.split(" ")[2]),r.split(" ")[2]==="PM"){let s=r.split(" ");console.log(s),r=Number(s[1].split(":")[0])+12+":"+s[1].split(":")[1]+":"+s[1].split(":")[2]}else r=r.split(" ")[1];return r}setValue(r){this.value=r,this._internals.setFormValue(r),this.requestUpdate()}setError(r){if(typeof r!="error"){console.warn("Error text must be a string");return}this.error=r,this._internals.setValidity({customError:r}),this.requestUpdate()}setDisabled(r){this.disabled=r,this._internals.setValidity({customError:r}),this.requestUpdate()}}o(n,"formAssociated",!0),o(n,"distinctTimezones",["Etc/GMT+12","Pacific/Pago_Pago","Pacific/Honolulu","America/Anchorage","America/Los_Angeles","America/Denver","America/Chicago","America/New_York","America/Halifax","America/Argentina/Buenos_Aires","America/Noronha","Atlantic/Azores","Europe/London","Europe/Paris","Europe/Bucharest","Europe/Moscow","Asia/Tehran","Asia/Dubai","Asia/Kabul","Asia/Karachi","Asia/Kolkata","Asia/Kathmandu","Asia/Dhaka","Asia/Yangon","Asia/Bangkok","Asia/Shanghai","Australia/Eucla","Asia/Tokyo","Australia/Darwin","Australia/Sydney","Australia/Lord_Howe","Pacific/Noumea","Pacific/Auckland","Pacific/Chatham","Pacific/Tongatapu","Pacific/Kiritimati"]),o(n,"styles",e.i$1`
1132
+ `;static properties={value:{type:String,reflect:!0},shortcut:{type:String,reflect:!0},error:{type:Boolean,reflect:!0,attribute:"error"},disabled:{type:Boolean,reflect:!0},form:{type:String,reflect:!0,attribute:"form"},size:{type:String,reflect:!0,attribute:"size",converter:t=>["sm","md","lg"].includes(t)?t:"md"},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"},variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["dashed","dotted"].includes(t)?t:"default"},timezone:{type:String,reflect:!0,attribute:"timezone",converter:t=>distinctTimezones.includes(t)?t:"America/New_York"}};constructor(){super(),this.value="",this.shortcut=void 0,this.disabled=void 0,this.form=void 0,this.size="md",this.fullWidth=!1,this.variant="default",this.timezone="America/New_York",this._internals=this.attachInternals(),this._internals.setValidity({customError:this.errorText&&this.errorText.length>0||!1})}handleChange=t=>(this.value=t.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value);handleInput=t=>(this.value=t.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("input",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value);handleFocus=t=>(this.value=t.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("focus",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value);handleBlur=t=>(this.value=t.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("blur",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value);render(){return e.x`
1133
+ <div class='container'>
1134
+ <input class='${this.error?"input-error":""} ${this.disabled?"disabled":""} ${this.fullWidth?"full-width":""} ${this.variant} ${this.size}' type='date' id='${this.name|"date"}' name='${this.name|"date"}' .value='${this.value}' @change='${this.handleChange}' @focus='${this.handleFocus}' @blur='${this.handleBlur}' @input='${this.handleInput}' ?disabled='${this.disabled}' />
1135
+ ${this.shortcut?e.x`<cd-button variant='primary' ?disabled='${this.disabled}'>${this.shortcut}</cd-button>`:""}
1136
+ </div>
1137
+
1138
+ `}firstUpdated(){if(!this.shadowRoot){console.warn("Shadow DOM not available, DateComponent may not render correctly.");return}this.shadowRoot.querySelector("cd-button")&&this.shadowRoot.querySelector("cd-button").addEventListener("button-click",()=>{this.setValue(this.dateNow()),this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value},bubbles:!0,composed:!0}))})}dateNow(){let t=new Date().toLocaleString("en-US",{timeZone:this.timezone});return new Date(t).toISOString().slice(0,10)}setValue(t){this.value=t,this._internals.setFormValue(t),this.requestUpdate()}setError(t){if(typeof t!="error"){console.warn("Error text must be a string");return}this.error=t,this._internals.setValidity({customError:t}),this.requestUpdate()}setDisabled(t){this.disabled=t,this._internals.setValidity({customError:t}),this.requestUpdate()}}function I(){typeof window<"u"&&!customElements.get("cd-date")&&customElements.define("cd-date",g)}i();class m extends e.i{static formAssociated=!0;static distinctTimezones=["Etc/GMT+12","Pacific/Pago_Pago","Pacific/Honolulu","America/Anchorage","America/Los_Angeles","America/Denver","America/Chicago","America/New_York","America/Halifax","America/Argentina/Buenos_Aires","America/Noronha","Atlantic/Azores","Europe/London","Europe/Paris","Europe/Bucharest","Europe/Moscow","Asia/Tehran","Asia/Dubai","Asia/Kabul","Asia/Karachi","Asia/Kolkata","Asia/Kathmandu","Asia/Dhaka","Asia/Yangon","Asia/Bangkok","Asia/Shanghai","Australia/Eucla","Asia/Tokyo","Australia/Darwin","Australia/Sydney","Australia/Lord_Howe","Pacific/Noumea","Pacific/Auckland","Pacific/Chatham","Pacific/Tongatapu","Pacific/Kiritimati"];static styles=e.i$1`
1142
1139
  @font-face {
1143
1140
  font-family: 'Geist';
1144
1141
  src: url(${e.r(e.fontURL)}) format('woff');
@@ -1223,5 +1220,8 @@
1223
1220
  height: 36px;
1224
1221
  padding: 0 var(--input-horizontal-inline-padding-sm, 12px);
1225
1222
  }
1226
- `),o(n,"properties",{value:{type:String,reflect:!0},shortcut:{type:String,reflect:!0},error:{type:Boolean,reflect:!0,attribute:"error"},disabled:{type:Boolean,reflect:!0},form:{type:String,reflect:!0,attribute:"form"},size:{type:String,reflect:!0,attribute:"size",converter:r=>["sm","md","lg"].includes(r)?r:"md"},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"},variant:{type:String,reflect:!0,attribute:"variant",converter:r=>["dashed","dotted"].includes(r)?r:"default"},timezone:{type:String,reflect:!0,attribute:"timezone",converter:r=>distinctTimezones.includes(r)?r:"America/New_York"}});function V(){typeof window<"u"&&!customElements.get("cd-time")&&customElements.define("cd-time",n)}exports.Button=c;exports.DateComponent=a;exports.Header=d;exports.Input=l;exports.NavBar=u;exports.NavItem=p;exports.NavProfile=b;exports.Search=g;exports.Tab=m;exports.TabContainer=x;exports.Table=h;exports.TimeComponent=n;exports.ToolTip=v;exports.Value=f;exports.registerButton=y;exports.registerDate=T;exports.registerHeader=E;exports.registerInput=z;exports.registerNavBar=S;exports.registerNavItem=A;exports.registerNavProfile=L;exports.registerSearch=q;exports.registerTab=_;exports.registerTabContainer=I;exports.registerTable=C;exports.registerTime=V;exports.registerToolTip=R;exports.registerValue=B;
1223
+ `;static properties={value:{type:String,reflect:!0},shortcut:{type:String,reflect:!0},error:{type:Boolean,reflect:!0,attribute:"error"},disabled:{type:Boolean,reflect:!0},form:{type:String,reflect:!0,attribute:"form"},size:{type:String,reflect:!0,attribute:"size",converter:t=>["sm","md","lg"].includes(t)?t:"md"},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"},variant:{type:String,reflect:!0,attribute:"variant",converter:t=>["dashed","dotted"].includes(t)?t:"default"},timezone:{type:String,reflect:!0,attribute:"timezone",converter:t=>distinctTimezones.includes(t)?t:"America/New_York"}};constructor(){super(),this.value="",this.shortcut=void 0,this.error=!1,this.disabled=void 0,this.form=void 0,this.size="md",this.fullWidth=!1,this.variant="default",this.timezone="America/New_York",this._internals=this.attachInternals(),this._internals.setValidity({customError:this.errorText&&this.errorText.length>0||!1})}handleChange=t=>(this.value=t.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value);handleInput=t=>(this.value=t.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("input",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value);handleFocus=t=>(this.value=t.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("focus",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value);handleBlur=t=>(this.value=t.target.value,this._internals.setFormValue(this.value),this.dispatchEvent(new CustomEvent("blur",{detail:{value:this.value},bubbles:!0,composed:!0})),this.value);render(){return e.x`
1224
+ <input class='${this.error?"input-error":""} ${this.disabled?"disabled":""} ${this.fullWidth?"full-width":""} ${this.variant} ${this.size}' type='time' id='${this.name|"time"}' name='${this.name|"time"}' .value='${this.value}' @change='${this.handleChange}' @focus='${this.handleFocus}' @blur='${this.handleBlur}' @input='${this.handleInput}' ?disabled='${this.disabled}' />
1225
+ ${this.shortcut?e.x`<cd-button variant='primary' ?disabled='${this.disabled}'>${this.shortcut}</cd-button>`:""}
1226
+ `}firstUpdated(){if(!this.shadowRoot){console.warn("Shadow DOM not available, TimeComponent may not render correctly.");return}this.shadowRoot.querySelector("cd-button")&&this.shadowRoot.querySelector("cd-button").addEventListener("button-click",()=>{this.setValue(this.timeNow()),this.dispatchEvent(new CustomEvent("change",{detail:{value:this.value},bubbles:!0,composed:!0}))})}timeNow(){console.log(this.timezone);let t=new Date().toLocaleString("en-US",{timeZone:this.timezone||"America/New_York"});if(console.log(t),console.log(t.split(" ")[2]),t.split(" ")[2]==="PM"){let o=t.split(" ");console.log(o),t=Number(o[1].split(":")[0])+12+":"+o[1].split(":")[1]+":"+o[1].split(":")[2]}else t=t.split(" ")[1];return t}setValue(t){this.value=t,this._internals.setFormValue(t),this.requestUpdate()}setError(t){if(typeof t!="error"){console.warn("Error text must be a string");return}this.error=t,this._internals.setValidity({customError:t}),this.requestUpdate()}setDisabled(t){this.disabled=t,this._internals.setValidity({customError:t}),this.requestUpdate()}}function R(){typeof window<"u"&&!customElements.get("cd-time")&&customElements.define("cd-time",m)}exports.Button=a;exports.DateComponent=g;exports.Header=n;exports.Input=s;exports.NavBar=l;exports.NavItem=c;exports.NavProfile=p;exports.Search=v;exports.Tab=b;exports.TabContainer=f;exports.Table=d;exports.TimeComponent=m;exports.ToolTip=u;exports.Value=h;exports.registerButton=i;exports.registerDate=I;exports.registerHeader=y;exports.registerInput=w;exports.registerNavBar=k;exports.registerNavItem=$;exports.registerNavProfile=S;exports.registerSearch=C;exports.registerTab=T;exports.registerTabContainer=B;exports.registerTable=E;exports.registerTime=R;exports.registerToolTip=z;exports.registerValue=A;
1227
1227
  //# sourceMappingURL=index.cjs.js.map