@ncino/web-components 2.1.0-preview.7 → 2.1.0-preview.9

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,4 +1,4 @@
1
- import{a as o,x as t}from"../../../assets/index-chunk2.js";import"../gator/input-label/input-label.gator.js";import"../gator/help-text/help-text.gator.js";import"../../icon/gator/icon.gator.js";import"../../icon/gator/templates/arrow-left.js";import"../../icon/gator/templates/arrow-right.js";import"../../icon/gator/templates/calendar.js";import"../../icon/gator/templates/check-circle.js";import"../../icon/gator/templates/check.js";import"../../icon/gator/templates/checkbox.js";import"../../icon/gator/templates/checkbox-selected.js";import"../../icon/gator/templates/chevron-down.js";import"../../icon/gator/templates/chevron-left.js";import"../../icon/gator/templates/chevron-right.js";import"../../icon/gator/templates/chevron-up.js";import"../../icon/gator/templates/dashboard.js";import"../../icon/gator/templates/exit.js";import"../../icon/gator/templates/exit-circle.js";import"../../icon/gator/templates/eye-crossed.js";import"../../icon/gator/templates/info.js";import"../../icon/gator/templates/link.js";import"../../icon/gator/templates/overflow-menu.js";import"../../icon/gator/templates/percent.js";import"../../icon/gator/templates/picture.js";import"../../icon/gator/templates/shield-lock.js";import"../../icon/gator/templates/radio.js";import"../../icon/gator/templates/radio-selected.js";import"../../icon/gator/templates/restricted.js";import"../../icon/gator/templates/settings.js";import"../../icon/gator/templates/warning.js";import{s as n}from"../../../assets/index-chunk6.js";import{p as a}from"../../../assets/index-chunk5.js";import{I as p}from"./input-base.js";import{e as s}from"../../../assets/index-chunk8.js";import"../../../assets/index-chunk3.js";import"../../../assets/index-chunk.js";import"../../../utils/mixins/attribute-deletion.js";import"../../icon/icon-registry.js";import"../../../utils/components/testable-lit-element/testable-lit-element.js";import"../../../assets/index-chunk9.js";const l='input,textarea{border:none}input:focus,textarea:focus{outline:none}.gator-form-element-control:focus-within{outline:2px solid var(--ngc-input-border-color-focused, #1F1F1F)!important;border:1px solid transparent!important}.gator-form-element{display:block;margin-bottom:1rem}.gator-form-element-control{padding:var(--ngc-input-padding);display:flex;flex-direction:column}.gator-input,.gator-faux-input{display:flex;width:100%;height:100%;font-size:var(--ngc-input-font-size, 1.0625rem);font-family:var(--text-family-sans-serif, "Open Sans", sans-serif)}.gator-form-element-control{margin:.5rem 0;border:1px solid var(--ngc-input-border-color, #BFBFBF);border-radius:var(--ngc-input-border-radius, 2px);flex:1}.gator-form-element-control:hover:not(.gator-disabled){border:1px solid var(--ngc-input-border-color-hovered, #1F1F1F);outline:none}.gator-has-error{border-color:var(--ngc-input-error-border)!important}.gator-disabled{background:var(--color-surface-secondary, #F7F7F7);border:none;cursor:not-allowed}.gator-disabled input,.gator-disabled textarea{background-color:transparent;cursor:not-allowed}.gator-form-element-control-icon-right{display:flex;align-items:center}.gator-input-container{max-width:var(--ngc-input-max-width, 200px);display:flex;align-items:center;position:relative}.gator-input-start,.gator-input-end{display:flex;align-items:center}.gator-input-start{margin-right:.5rem}.gator-cursor-pointer{cursor:pointer}',c=":root,:host{--ngc-input-error-border: var(--color-error, #D0021B);--ngc-input-border-color: var(--color-grey-40, #BFBFBF);--ngc-input-border-color-focused: var(--color-stroke-brand, #1F1F1F);--ngc-input-border-color-hovered: var(--color-stroke-interactive, #0052CC);--ngc-input-min-width: 200px;--ngc-input-padding: var(--spacing-3, .75rem) var(--spacing-4, 1rem);--ngc-input-border-radius: var(--radius-sm, .125rem);--ngc-input-max-width: 100%;--ngc-input-font-size: 17px}",e=class e extends p{constructor(){super(...arguments),this.controlRef=s()}get shouldHaveStartMarkup(){return this.startIcon}get shouldHaveEndMarkup(){return this.endIcon||this.type==="password"}get startIconMarkup(){return this.startIcon?t`<ngc-icon .name="${this.startIcon}"></ngc-icon>`:null}get endIconMarkup(){return this.endIcon?t`
1
+ import{a as o,x as t}from"../../../assets/index-chunk2.js";import"../gator/input-label/input-label.gator.js";import"../gator/help-text/help-text.gator.js";import"../../icon/gator/icon.gator.js";import"../../icon/gator/templates/arrow-left.js";import"../../icon/gator/templates/arrow-right.js";import"../../icon/gator/templates/calendar.js";import"../../icon/gator/templates/check-circle.js";import"../../icon/gator/templates/check.js";import"../../icon/gator/templates/checkbox.js";import"../../icon/gator/templates/checkbox-selected.js";import"../../icon/gator/templates/chevron-down.js";import"../../icon/gator/templates/chevron-left.js";import"../../icon/gator/templates/chevron-right.js";import"../../icon/gator/templates/chevron-up.js";import"../../icon/gator/templates/dashboard.js";import"../../icon/gator/templates/exit.js";import"../../icon/gator/templates/exit-circle.js";import"../../icon/gator/templates/eye-crossed.js";import"../../icon/gator/templates/info.js";import"../../icon/gator/templates/link.js";import"../../icon/gator/templates/overflow-menu.js";import"../../icon/gator/templates/percent.js";import"../../icon/gator/templates/picture.js";import"../../icon/gator/templates/shield-lock.js";import"../../icon/gator/templates/radio.js";import"../../icon/gator/templates/radio-selected.js";import"../../icon/gator/templates/restricted.js";import"../../icon/gator/templates/settings.js";import"../../icon/gator/templates/warning.js";import{s as n}from"../../../assets/index-chunk6.js";import{p as a}from"../../../assets/index-chunk5.js";import{I as p}from"./input-base.js";import{e as s}from"../../../assets/index-chunk8.js";import"../../../assets/index-chunk3.js";import"../../../assets/index-chunk.js";import"../../../utils/mixins/attribute-deletion.js";import"../../icon/icon-registry.js";import"../../../utils/components/testable-lit-element/testable-lit-element.js";import"../../../assets/index-chunk9.js";const l='input,textarea{border:none}input:focus,textarea:focus{outline:none}.gator-form-element-control:focus-within:not(.gator-disabled){outline:2px solid var(--ngc-input-border-color-focused, #1F1F1F)!important;border:1px solid transparent!important}.gator-form-element{display:block;margin-bottom:1rem}.gator-form-element-control{padding:var(--ngc-input-padding);display:flex;flex-direction:column}.gator-input,.gator-faux-input{display:flex;width:100%;height:100%;font-size:var(--ngc-input-font-size, 1.0625rem);font-family:var(--text-family-sans-serif, "Open Sans", sans-serif)}.gator-form-element-control{margin:.5rem 0;border:1px solid var(--ngc-input-border-color, #BFBFBF);border-radius:var(--ngc-input-border-radius, 2px);flex:1}.gator-form-element-control:hover:not(.gator-disabled){border:1px solid var(--ngc-input-border-color-hovered, #1F1F1F);outline:none}.gator-has-error{border-color:var(--ngc-input-error-border)!important}.gator-disabled{background:var(--color-surface-secondary, #F7F7F7);border:none;cursor:not-allowed}.gator-disabled input,.gator-disabled textarea{background-color:transparent;cursor:not-allowed}.gator-form-element-control-icon-right{display:flex;align-items:center}.gator-input-container{max-width:var(--ngc-input-max-width, 200px);display:flex;align-items:center;position:relative}.gator-input-start,.gator-input-end{display:flex;align-items:center}.gator-input-start{margin-right:.5rem}.gator-cursor-pointer{cursor:pointer}',c=":root,:host{--ngc-input-error-border: var(--color-error, #D0021B);--ngc-input-border-color: var(--color-grey-40, #BFBFBF);--ngc-input-border-color-focused: var(--color-stroke-brand, #1F1F1F);--ngc-input-border-color-hovered: var(--color-stroke-interactive, #0052CC);--ngc-input-min-width: 200px;--ngc-input-padding: var(--spacing-3, .75rem) var(--spacing-4, 1rem);--ngc-input-border-radius: var(--radius-sm, .125rem);--ngc-input-max-width: 100%;--ngc-input-font-size: 17px}",e=class e extends p{constructor(){super(...arguments),this.controlRef=s()}get shouldHaveStartMarkup(){return this.startIcon}get shouldHaveEndMarkup(){return this.endIcon||this.type==="password"}get startIconMarkup(){return this.startIcon?t`<ngc-icon .name="${this.startIcon}"></ngc-icon>`:null}get endIconMarkup(){return this.endIcon?t`
2
2
  <ngc-icon .name="${this.endIcon}"></ngc-icon>`:null}get labelMarkup(){return t`
3
3
  <ngc-input-label
4
4
  .for="${this.id}"
@@ -1,18 +1,19 @@
1
- import{a as m,x as d}from"../../../../assets/index-chunk2.js";import"../input-label/input-label.gator.js";import"../help-text/help-text.gator.js";import"../../../icon/gator/icon.gator.js";import"../../../icon/gator/templates/arrow-left.js";import"../../../icon/gator/templates/arrow-right.js";import"../../../icon/gator/templates/calendar.js";import"../../../icon/gator/templates/check-circle.js";import"../../../icon/gator/templates/check.js";import"../../../icon/gator/templates/checkbox.js";import"../../../icon/gator/templates/checkbox-selected.js";import"../../../icon/gator/templates/chevron-down.js";import"../../../icon/gator/templates/chevron-left.js";import"../../../icon/gator/templates/chevron-right.js";import"../../../icon/gator/templates/chevron-up.js";import"../../../icon/gator/templates/dashboard.js";import"../../../icon/gator/templates/exit.js";import"../../../icon/gator/templates/exit-circle.js";import"../../../icon/gator/templates/eye-crossed.js";import"../../../icon/gator/templates/info.js";import"../../../icon/gator/templates/link.js";import"../../../icon/gator/templates/overflow-menu.js";import"../../../icon/gator/templates/percent.js";import"../../../icon/gator/templates/picture.js";import"../../../icon/gator/templates/shield-lock.js";import"../../../icon/gator/templates/radio.js";import"../../../icon/gator/templates/radio-selected.js";import"../../../icon/gator/templates/restricted.js";import"../../../icon/gator/templates/settings.js";import"../../../icon/gator/templates/warning.js";import"../../../list/gator/list/list.gator.js";import"../../../list/gator/list-item/list-item.gator.js";import{t as x}from"../../../../assets/index-chunk3.js";import{n}from"../../../../assets/index-chunk.js";import{r as f}from"../../../../assets/index-chunk4.js";import{e as c,n as p}from"../../../../assets/index-chunk8.js";import{a as y,c as b,b as g}from"../../../../assets/index-chunk12.js";import{K as a}from"../../../../consts/key-constants.js";import{N as w}from"../../base/input-base.gator.js";import{f as $,a as _}from"../../../../utils/places-utils.js";import{f as R}from"../../../../utils/industry-utils.js";import{f as D}from"../../../../utils/phone-utils.js";import{o as v}from"../../../../assets/index-chunk7.js";import"../../../../assets/index-chunk5.js";import"../../../../assets/index-chunk6.js";import"../../../../utils/mixins/attribute-deletion.js";import"../../../icon/icon-registry.js";import"../../../../utils/components/testable-lit-element/testable-lit-element.js";import"../../../divider/gator/divider.gator.js";import"../../../divider/divider.js";import"../../../../assets/index-chunk9.js";import"../../base/input-base.js";const F=':root,:host{--ngc-input-dropdown-list-max-height: 14rem}.gator-dropdown-listbox{position:absolute;width:max-content;top:0;left:0;display:none;max-height:var(--ngc-input-dropdown-list-max-height);overflow-y:scroll;overflow-x:hidden;border-radius:var(--radius-card-medium, .5rem);padding:var(--spacing-padding-margin-8, .5rem) 2px;background:var(--color-surface-primary-white, #FFF);box-shadow:var(--shadow-x-offset-0, 0px) var(--shadow-shadow-3-dropdown-property-1-y-offset, 7px) var(--shadow-shadow-3-dropdown-property-1-blur, 12px) var(--shadow-shadow-3-dropdown-property-1-spread, 0px) var(--shadow-color-10, rgba(31, 31, 31, .1)),var(--shadow-x-offset-0, 0px) var(--shadow-shadow-3-dropdown-property-2-y-offset, 8px) var(--shadow-shadow-3-dropdown-property-2-blur, 16px) var(--shadow-shadow-3-dropdown-property-2-spread, 0px) var(--shadow-color-8, rgba(31, 31, 31, .08)),var(--shadow-x-offset-0, 0px) var(--shadow-shadow-3-dropdown-property-3-y-offset, 9px) var(--shadow-shadow-3-dropdown-property-3-blur, 18px) var(--shadow-shadow-3-dropdown-property-3-spread, 0px) var(--shadow-color-8, rgba(31, 31, 31, .08))}.gator-form-element-control:focus{outline:2px solid var(--ngc-input-border-color-focused, #1F1F1F)!important;border:1px solid transparent!important}.gator-dropdown-listbox_expanded{display:block}.gator-faux-input-placeholder{color:var(--text-color-placeholder, #6D6D6D);font-family:var(--text-family-body, "Open Sans");font-size:var(--text-size-body-1, 1.0625rem);line-height:var(--text-line-height-body-1, 1.5rem);letter-spacing:var(--text-letter-spacing-default, 0rem)}';var k=Object.defineProperty,C=Object.getOwnPropertyDescriptor,I=Object.getPrototypeOf,P=Reflect.get,r=(t,e,i,s)=>{for(var l=s>1?void 0:s?C(e,i):e,h=t.length-1,u;h>=0;h--)(u=t[h])&&(l=(s?u(e,i,l):u(l))||l);return s&&l&&k(e,i,l),l},O=(t,e,i)=>P(I(t),i,e);let o=class extends w{constructor(){super(...arguments),this.options=[],this.autocomplete=!1,this.valueDisplayed=!1,this._expanded=!1,this._searchValue="",this.listboxRef=c(),this.listRef=c(),this.inputRef=c()}render(){return d`
1
+ import{a as m,x as l}from"../../../../assets/index-chunk2.js";import"../input-label/input-label.gator.js";import"../help-text/help-text.gator.js";import"../../../icon/gator/icon.gator.js";import"../../../icon/gator/templates/arrow-left.js";import"../../../icon/gator/templates/arrow-right.js";import"../../../icon/gator/templates/calendar.js";import"../../../icon/gator/templates/check-circle.js";import"../../../icon/gator/templates/check.js";import"../../../icon/gator/templates/checkbox.js";import"../../../icon/gator/templates/checkbox-selected.js";import"../../../icon/gator/templates/chevron-down.js";import"../../../icon/gator/templates/chevron-left.js";import"../../../icon/gator/templates/chevron-right.js";import"../../../icon/gator/templates/chevron-up.js";import"../../../icon/gator/templates/dashboard.js";import"../../../icon/gator/templates/exit.js";import"../../../icon/gator/templates/exit-circle.js";import"../../../icon/gator/templates/eye-crossed.js";import"../../../icon/gator/templates/info.js";import"../../../icon/gator/templates/link.js";import"../../../icon/gator/templates/overflow-menu.js";import"../../../icon/gator/templates/percent.js";import"../../../icon/gator/templates/picture.js";import"../../../icon/gator/templates/shield-lock.js";import"../../../icon/gator/templates/radio.js";import"../../../icon/gator/templates/radio-selected.js";import"../../../icon/gator/templates/restricted.js";import"../../../icon/gator/templates/settings.js";import"../../../icon/gator/templates/warning.js";import"../../../list/gator/list/list.gator.js";import"../../../list/gator/list-item/list-item.gator.js";import{t as b}from"../../../../assets/index-chunk3.js";import{n}from"../../../../assets/index-chunk.js";import{r as f}from"../../../../assets/index-chunk4.js";import{e as c,n as p}from"../../../../assets/index-chunk8.js";import{a as x,c as y,b as g}from"../../../../assets/index-chunk12.js";import{K as o}from"../../../../consts/key-constants.js";import{N as w}from"../../base/input-base.gator.js";import{f as $,a as _}from"../../../../utils/places-utils.js";import{f as R}from"../../../../utils/industry-utils.js";import{f as D}from"../../../../utils/phone-utils.js";import{o as v}from"../../../../assets/index-chunk7.js";import"../../../../assets/index-chunk5.js";import"../../../../assets/index-chunk6.js";import"../../../../utils/mixins/attribute-deletion.js";import"../../../icon/icon-registry.js";import"../../../../utils/components/testable-lit-element/testable-lit-element.js";import"../../../divider/gator/divider.gator.js";import"../../../divider/divider.js";import"../../../../assets/index-chunk9.js";import"../../base/input-base.js";const C=':root,:host{--ngc-input-dropdown-list-max-height: 14rem}.gator-dropdown-listbox{position:absolute;width:max-content;top:0;left:0;display:none;max-height:var(--ngc-input-dropdown-list-max-height);overflow-y:scroll;overflow-x:hidden;border-radius:var(--radius-card-medium, .5rem);padding:var(--spacing-padding-margin-8, .5rem) 2px;background:var(--color-surface-primary-white, #FFF);box-shadow:var(--shadow-x-offset-0, 0px) var(--shadow-shadow-3-dropdown-property-1-y-offset, 7px) var(--shadow-shadow-3-dropdown-property-1-blur, 12px) var(--shadow-shadow-3-dropdown-property-1-spread, 0px) var(--shadow-color-10, rgba(31, 31, 31, .1)),var(--shadow-x-offset-0, 0px) var(--shadow-shadow-3-dropdown-property-2-y-offset, 8px) var(--shadow-shadow-3-dropdown-property-2-blur, 16px) var(--shadow-shadow-3-dropdown-property-2-spread, 0px) var(--shadow-color-8, rgba(31, 31, 31, .08)),var(--shadow-x-offset-0, 0px) var(--shadow-shadow-3-dropdown-property-3-y-offset, 9px) var(--shadow-shadow-3-dropdown-property-3-blur, 18px) var(--shadow-shadow-3-dropdown-property-3-spread, 0px) var(--shadow-color-8, rgba(31, 31, 31, .08))}.gator-form-element-control:focus-visible:not(.gator-disabled){outline:2px solid var(--ngc-input-border-color-focused, #1F1F1F)!important;border:1px solid transparent!important}.gator-dropdown-listbox_expanded{display:block}.gator-faux-input-placeholder{color:var(--text-color-placeholder, #6D6D6D);font-family:var(--text-family-body, "Open Sans");font-size:var(--text-size-body-1, 1.0625rem);line-height:var(--text-line-height-body-1, 1.5rem);letter-spacing:var(--text-letter-spacing-default, 0rem)}';var F=Object.defineProperty,k=Object.getOwnPropertyDescriptor,I=Object.getPrototypeOf,P=Reflect.get,r=(t,e,i,s)=>{for(var d=s>1?void 0:s?k(e,i):e,h=t.length-1,u;h>=0;h--)(u=t[h])&&(d=(s?u(e,i,d):u(d))||d);return s&&d&&F(e,i,d),d},O=(t,e,i)=>P(I(t),i,e);let a=class extends w{constructor(){super(...arguments),this.options=[],this.autocomplete=!1,this.valueDisplayed=!1,this._expanded=!1,this._searchValue="",this.listboxRef=c(),this.listRef=c(),this.inputRef=c()}render(){return l`
2
2
  <div class="gator-form-element">
3
3
  <slot name="label">
4
4
  ${this.label?this.labelMarkup:null}
5
5
  </slot>
6
6
  <div
7
7
  ${p(this.controlRef)}
8
- class="gator-form-element-control ${this.errorClass} gator-cursor-pointer"
8
+ class="gator-form-element-control ${this.errorClass} ${this.disabledClass}"
9
9
  data-testid=${v(this.dataTestid)}-listbox
10
10
  aria-controls="listbox-${this.id}"
11
11
  aria-expanded="${this._expanded}"
12
12
  aria-haspopup="listbox"
13
+ aria-disabled="${this.disabled}"
13
14
  aria-labelledby="dropdown-label-${this.id}"
14
15
  id="listbox-control-${this.id}"
15
- tabindex="0"
16
+ tabindex="${this.disabled?"-1":"0"}"
16
17
  role="combobox"
17
18
  title="${this.id}"
18
19
  @click="${this.toggleListbox}"
@@ -21,11 +22,11 @@ import{a as m,x as d}from"../../../../assets/index-chunk2.js";import"../input-la
21
22
  @focusout="${this._topLevelFocusOut}"
22
23
  >
23
24
  <div class="gator-input-container">
24
- ${this.shouldHaveStartMarkup?d`
25
+ ${this.shouldHaveStartMarkup?l`
25
26
  <div class="gator-input-start">
26
27
  ${this.startIconMarkup}
27
28
  </div>`:null}
28
- ${this.autocomplete?d`
29
+ ${this.autocomplete?l`
29
30
  <input
30
31
  ${p(this.inputRef)}
31
32
  type="${this.type}"
@@ -55,11 +56,11 @@ import{a as m,x as d}from"../../../../assets/index-chunk2.js";import"../input-la
55
56
 
56
57
  ${this.listboxMarkup}
57
58
  </div>
58
- `}_topLevelFocusOut(t){t.relatedTarget||(this._expanded=!1)}_handleControlFocusIn(){var t;this.autocomplete&&((t=this.inputRef.value)==null||t.focus())}firstUpdated(){this._expanded&&this.toggleListbox(a.ENTER,!0)}updated(){var t,e,i,s;this._expanded&&this.value&&((t=this.controlRef.value)==null||t.setAttribute("aria-activedescendant",this.replacedActiveDescendant)),this._expanded&&!this.value&&(this._activeDescendant=(i=(e=this.shadowRoot)==null?void 0:e.querySelector("ngc-list-item"))==null?void 0:i.id,(s=this.controlRef.value)==null||s.setAttribute("aria-activedescendant",this.replacedActiveDescendant))}get fauxInputMarkup(){return d`
59
+ `}_topLevelFocusOut(t){t.relatedTarget||(this._expanded=!1)}_handleControlFocusIn(){var t;this.disabled||this.autocomplete&&((t=this.inputRef.value)==null||t.focus())}firstUpdated(){this._expanded&&this.toggleListbox(o.ENTER,!0)}updated(){var t,e,i,s;this._expanded&&this.value&&((t=this.controlRef.value)==null||t.setAttribute("aria-activedescendant",this.replacedActiveDescendant)),this._expanded&&!this.value&&(this._activeDescendant=(i=(e=this.shadowRoot)==null?void 0:e.querySelector("ngc-list-item"))==null?void 0:i.id,(s=this.controlRef.value)==null||s.setAttribute("aria-activedescendant",this.replacedActiveDescendant))}get fauxInputMarkup(){return l`
59
60
  <div class="gator-faux-input ${this.showPlaceholder?"gator-faux-input-placeholder":null}">
60
61
  ${this.displayedValue||this.placeholder}
61
62
  </div>
62
- `}get displayedValue(){var t;return this.value?this.valueDisplayed?this.value:((t=this.displayedOptions.find(e=>e.value===this.value))==null?void 0:t.label)??this.value:""}get showPlaceholder(){return this.placeholder&&!this.value}get replacedActiveDescendant(){return this._activeDescendant?this._activeDescendant.replace(" ",""):""}get listboxMarkup(){return d`
63
+ `}get displayedValue(){var t;return this.value?this.valueDisplayed?this.value:((t=this.displayedOptions.find(e=>e.value===this.value))==null?void 0:t.label)??this.value:""}get showPlaceholder(){return this.placeholder&&!this.value}get replacedActiveDescendant(){return this._activeDescendant?this._activeDescendant.replace(" ",""):""}get listboxMarkup(){return l`
63
64
  <div
64
65
  ${p(this.listboxRef)}
65
66
  class="gator-dropdown-listbox ${this._expanded?"gator-dropdown-listbox_expanded":""}"
@@ -73,7 +74,7 @@ import{a as m,x as d}from"../../../../assets/index-chunk2.js";import"../input-la
73
74
  .title="${this.id}-list"
74
75
  .aria-labelledby="dropdown-label-${this.id}"
75
76
  >
76
- ${this.displayedOptions.map(t=>d`
77
+ ${this.displayedOptions.map(t=>l`
77
78
  <ngc-list-item
78
79
  text="${t.label}"
79
80
  value="${t.value}"
@@ -84,11 +85,11 @@ import{a as m,x as d}from"../../../../assets/index-chunk2.js";import"../input-la
84
85
  `)}
85
86
  </ngc-list>
86
87
  </div>
87
- `}get displayedOptions(){let t=this.options;return this.dataType==="country"?t=$():this.dataType==="state"&&this.countryCode?t=_(this.countryCode):this.dataType==="naics"?t=R():this.dataType==="phoneCodes"&&(t=D()),this._searchValue?[...t.filter(e=>e.label.toLowerCase().includes(this._searchValue.toLowerCase()))]:t}handleSelected(){var t;this._expanded=!1,this._activeDescendant=void 0,(t=this.controlRef.value)==null||t.removeAttribute("aria-activedescendant")}handleComboboxKeydown(t){var e,i;!this._expanded&&(t.key===a.ENTER||t.key===a.SPACE||t.key===a.DOWN)?this.toggleListbox(t.key,!1):this._expanded&&this.listRef.value&&((t.key===a.ENTER||t.key===a.SPACE)&&this.listRef.value.selectFalseFocusedItem(),t.key===a.DOWN&&(this._activeDescendant=this.listRef.value.falseFocusNextItem(),(e=this.controlRef.value)==null||e.setAttribute("aria-activedescendant",this.replacedActiveDescendant)),t.key===a.UP&&(this._activeDescendant=this.listRef.value.falseFocusPreviousItem(),(i=this.controlRef.value)==null||i.setAttribute("aria-activedescendant",this.replacedActiveDescendant))),t.key===a.ESCAPE&&(this._expanded=!1)}get errorClass(){return this.errorText?"gator-has-error":""}get labelMarkup(){return d`
88
+ `}get displayedOptions(){let t=this.options;return this.dataType==="country"?t=$():this.dataType==="state"&&this.countryCode?t=_(this.countryCode):this.dataType==="naics"?t=R():this.dataType==="phoneCodes"&&(t=D()),this._searchValue?[...t.filter(e=>e.label.toLowerCase().includes(this._searchValue.toLowerCase()))]:t}handleSelected(){var t;this._expanded=!1,this._activeDescendant=void 0,(t=this.controlRef.value)==null||t.removeAttribute("aria-activedescendant")}handleComboboxKeydown(t){var e,i;!this._expanded&&(t.key===o.ENTER||t.key===o.SPACE||t.key===o.DOWN)?this.toggleListbox(t.key,!1):this._expanded&&this.listRef.value&&((t.key===o.ENTER||t.key===o.SPACE)&&this.listRef.value.selectFalseFocusedItem(),t.key===o.DOWN&&(this._activeDescendant=this.listRef.value.falseFocusNextItem(),(e=this.controlRef.value)==null||e.setAttribute("aria-activedescendant",this.replacedActiveDescendant)),t.key===o.UP&&(this._activeDescendant=this.listRef.value.falseFocusPreviousItem(),(i=this.controlRef.value)==null||i.setAttribute("aria-activedescendant",this.replacedActiveDescendant))),t.key===o.ESCAPE&&(this._expanded=!1)}get errorClass(){return this.errorText?"gator-has-error":""}get disabledClass(){return this.disabled?"gator-disabled":"gator-cursor-pointer"}get labelMarkup(){return l`
88
89
  <ngc-input-label
89
90
  .for="dropdown-label-${this.id}"
90
91
  .required="${this.required}"
91
92
  type="div"
92
93
  >
93
94
  ${this.label}
94
- </ngc-input-label>`}toggleListbox(t,e){var i;e||(this._expanded=!this._expanded),setTimeout(()=>{var s;this.assignPosition(),this.listRef.value&&(t==a.DOWN||!this.value)?this._activeDescendant=this.listRef.value.falseFocusFirstItem():this.value&&this.listRef.value&&(this._activeDescendant=this.listRef.value.setFalseFocusToValue(this.value)),this._expanded&&((s=this.controlRef.value)==null||s.setAttribute("aria-activedescendant",this.replacedActiveDescendant))}),this._expanded||(this._activeDescendant=void 0,(i=this.controlRef.value)==null||i.removeAttribute("aria-activedescendant"))}get endIconMarkup(){return d`<ngc-icon .name="${this.endIcon||"chevron-down"}"></ngc-icon>`}assignPosition(){const t=this.controlRef.value;!this.listboxRef||!this.listboxRef.value||!t||(this._cleanup=y(t,this.listboxRef.value,async()=>{if(!this.listboxRef||!this.listboxRef.value||!t)return;const{x:e,y:i,placement:s}=await b(t,this.listboxRef.value,{placement:"bottom-start",middleware:[g({alignment:"start"})]});let l=s==="bottom-start"?4:-4;Object.assign(this.listboxRef.value.style,{left:`${e}px`,top:`${i+l}px`,width:`${this.listWidth??t.clientWidth}px`})}))}handleInput(t){let e=t.target;this._searchValue=e.value,this._expanded=!0}handleInputKeydown(t){if((t.key===a.DOWN||t.key===a.UP)&&t.preventDefault(),t.key===a.SPACE){t.stopPropagation();return}}};o.styles=[...O(o,o,"styles"),m(F)];r([n({type:Array})],o.prototype,"options",2);r([n({type:Boolean})],o.prototype,"autocomplete",2);r([n({type:String,attribute:"data-type"})],o.prototype,"dataType",2);r([n({type:String,attribute:"country-code"})],o.prototype,"countryCode",2);r([n({type:String,attribute:"list-width"})],o.prototype,"listWidth",2);r([n({type:Boolean,attribute:"value-displayed"})],o.prototype,"valueDisplayed",2);r([f()],o.prototype,"_activeDescendant",2);r([f()],o.prototype,"_expanded",2);r([f()],o.prototype,"_searchValue",2);o=r([x("ngc-input-dropdown")],o);
95
+ </ngc-input-label>`}toggleListbox(t,e){var i;this.disabled||(e||(this._expanded=!this._expanded),setTimeout(()=>{var s;this.assignPosition(),this.listRef.value&&(t==o.DOWN||!this.value)?this._activeDescendant=this.listRef.value.falseFocusFirstItem():this.value&&this.listRef.value&&(this._activeDescendant=this.listRef.value.setFalseFocusToValue(this.value)),this._expanded&&((s=this.controlRef.value)==null||s.setAttribute("aria-activedescendant",this.replacedActiveDescendant))}),this._expanded||(this._activeDescendant=void 0,(i=this.controlRef.value)==null||i.removeAttribute("aria-activedescendant")))}get endIconMarkup(){return l`<ngc-icon .name="${this.endIcon||"chevron-down"}"></ngc-icon>`}assignPosition(){const t=this.controlRef.value;!this.listboxRef||!this.listboxRef.value||!t||(this._cleanup=x(t,this.listboxRef.value,async()=>{if(!this.listboxRef||!this.listboxRef.value||!t)return;const{x:e,y:i,placement:s}=await y(t,this.listboxRef.value,{placement:"bottom-start",middleware:[g({alignment:"start"})]});let d=s==="bottom-start"?4:-4;Object.assign(this.listboxRef.value.style,{left:`${e}px`,top:`${i+d}px`,width:`${this.listWidth??t.clientWidth}px`})}))}handleInput(t){let e=t.target;this._searchValue=e.value,this._expanded=!0}handleInputKeydown(t){if((t.key===o.DOWN||t.key===o.UP)&&t.preventDefault(),t.key===o.SPACE){t.stopPropagation();return}}};a.styles=[...O(a,a,"styles"),m(C)];r([n({type:Array})],a.prototype,"options",2);r([n({type:Boolean})],a.prototype,"autocomplete",2);r([n({type:String,attribute:"data-type"})],a.prototype,"dataType",2);r([n({type:String,attribute:"country-code"})],a.prototype,"countryCode",2);r([n({type:String,attribute:"list-width"})],a.prototype,"listWidth",2);r([n({type:Boolean,attribute:"value-displayed"})],a.prototype,"valueDisplayed",2);r([f()],a.prototype,"_activeDescendant",2);r([f()],a.prototype,"_expanded",2);r([f()],a.prototype,"_searchValue",2);a=r([b("ngc-input-dropdown")],a);
@@ -1,36 +1,37 @@
1
- import{T as u,E as b,x as p}from"../../../../assets/index-chunk2.js";import"../input-label/input-label.gator.js";import"../help-text/help-text.gator.js";import"../../../icon/gator/icon.gator.js";import"../../../icon/gator/templates/arrow-left.js";import"../../../icon/gator/templates/arrow-right.js";import"../../../icon/gator/templates/calendar.js";import"../../../icon/gator/templates/check-circle.js";import"../../../icon/gator/templates/check.js";import"../../../icon/gator/templates/checkbox.js";import"../../../icon/gator/templates/checkbox-selected.js";import"../../../icon/gator/templates/chevron-down.js";import"../../../icon/gator/templates/chevron-left.js";import"../../../icon/gator/templates/chevron-right.js";import"../../../icon/gator/templates/chevron-up.js";import"../../../icon/gator/templates/dashboard.js";import"../../../icon/gator/templates/exit.js";import"../../../icon/gator/templates/exit-circle.js";import"../../../icon/gator/templates/eye-crossed.js";import"../../../icon/gator/templates/info.js";import"../../../icon/gator/templates/link.js";import"../../../icon/gator/templates/overflow-menu.js";import"../../../icon/gator/templates/percent.js";import"../../../icon/gator/templates/picture.js";import"../../../icon/gator/templates/shield-lock.js";import"../../../icon/gator/templates/radio.js";import"../../../icon/gator/templates/radio-selected.js";import"../../../icon/gator/templates/restricted.js";import"../../../icon/gator/templates/settings.js";import"../../../icon/gator/templates/warning.js";import{t as $}from"../../../../assets/index-chunk3.js";import{n as h}from"../../../../assets/index-chunk.js";import{r as l}from"../../../../assets/index-chunk4.js";import{f as E,m as T,e as v,n as f}from"../../../../assets/index-chunk8.js";import{N as y}from"../../base/input-base.gator.js";import{o as d}from"../../../../assets/index-chunk7.js";import{e as x,i as _,t as n}from"../../../../assets/index-chunk9.js";import"../../../../assets/index-chunk5.js";import"../../../../assets/index-chunk6.js";import"../../../../utils/mixins/attribute-deletion.js";import"../../../icon/icon-registry.js";import"../../base/input-base.js";import"../../../../utils/components/testable-lit-element/testable-lit-element.js";/**
1
+ import{T as d,E as $,x as p}from"../../../../assets/index-chunk2.js";import"../input-label/input-label.gator.js";import"../help-text/help-text.gator.js";import"../../../icon/gator/icon.gator.js";import"../../../icon/gator/templates/arrow-left.js";import"../../../icon/gator/templates/arrow-right.js";import"../../../icon/gator/templates/calendar.js";import"../../../icon/gator/templates/check-circle.js";import"../../../icon/gator/templates/check.js";import"../../../icon/gator/templates/checkbox.js";import"../../../icon/gator/templates/checkbox-selected.js";import"../../../icon/gator/templates/chevron-down.js";import"../../../icon/gator/templates/chevron-left.js";import"../../../icon/gator/templates/chevron-right.js";import"../../../icon/gator/templates/chevron-up.js";import"../../../icon/gator/templates/dashboard.js";import"../../../icon/gator/templates/exit.js";import"../../../icon/gator/templates/exit-circle.js";import"../../../icon/gator/templates/eye-crossed.js";import"../../../icon/gator/templates/info.js";import"../../../icon/gator/templates/link.js";import"../../../icon/gator/templates/overflow-menu.js";import"../../../icon/gator/templates/percent.js";import"../../../icon/gator/templates/picture.js";import"../../../icon/gator/templates/shield-lock.js";import"../../../icon/gator/templates/radio.js";import"../../../icon/gator/templates/radio-selected.js";import"../../../icon/gator/templates/restricted.js";import"../../../icon/gator/templates/settings.js";import"../../../icon/gator/templates/warning.js";import{t as b}from"../../../../assets/index-chunk3.js";import{n as u}from"../../../../assets/index-chunk.js";import{r as h}from"../../../../assets/index-chunk4.js";import{f as E,m as T,e as v,n as g}from"../../../../assets/index-chunk8.js";import{N as y}from"../../base/input-base.gator.js";import{o as l}from"../../../../assets/index-chunk7.js";import{e as x,i as _,t as n}from"../../../../assets/index-chunk9.js";import"../../../../assets/index-chunk5.js";import"../../../../assets/index-chunk6.js";import"../../../../utils/mixins/attribute-deletion.js";import"../../../icon/icon-registry.js";import"../../base/input-base.js";import"../../../../utils/components/testable-lit-element/testable-lit-element.js";/**
2
2
  * @license
3
3
  * Copyright 2020 Google LLC
4
4
  * SPDX-License-Identifier: BSD-3-Clause
5
- */const g=x(class extends _{constructor(t){if(super(t),t.type!==n.PROPERTY&&t.type!==n.ATTRIBUTE&&t.type!==n.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!E(t))throw Error("`live` bindings can only contain a single expression")}render(t){return t}update(t,[e]){if(e===u||e===b)return e;const r=t.element,o=t.name;if(t.type===n.PROPERTY){if(e===r[o])return u}else if(t.type===n.BOOLEAN_ATTRIBUTE){if(!!e===r.hasAttribute(o))return u}else if(t.type===n.ATTRIBUTE&&r.getAttribute(o)===e+"")return u;return T(t),e}});var I=Object.defineProperty,R=Object.getOwnPropertyDescriptor,s=(t,e,r,o)=>{for(var a=o>1?void 0:o?R(e,r):e,m=t.length-1,c;m>=0;m--)(c=t[m])&&(a=(o?c(e,r,a):c(a))||a);return o&&a&&I(e,r,a),a};let i=class extends y{constructor(){super(...arguments),this.inputRef=v(),this.controlRef=v(),this.for=""}render(){return p`
5
+ */const f=x(class extends _{constructor(t){if(super(t),t.type!==n.PROPERTY&&t.type!==n.ATTRIBUTE&&t.type!==n.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!E(t))throw Error("`live` bindings can only contain a single expression")}render(t){return t}update(t,[e]){if(e===d||e===$)return e;const i=t.element,o=t.name;if(t.type===n.PROPERTY){if(e===i[o])return d}else if(t.type===n.BOOLEAN_ATTRIBUTE){if(!!e===i.hasAttribute(o))return d}else if(t.type===n.ATTRIBUTE&&i.getAttribute(o)===e+"")return d;return T(t),e}});var I=Object.defineProperty,R=Object.getOwnPropertyDescriptor,s=(t,e,i,o)=>{for(var a=o>1?void 0:o?R(e,i):e,m=t.length-1,c;m>=0;m--)(c=t[m])&&(a=(o?c(e,i,a):c(a))||a);return o&&a&&I(e,i,a),a};let r=class extends y{constructor(){super(...arguments),this.inputRef=v(),this.controlRef=v(),this.for=""}render(){return p`
6
6
  <div class="gator-form-element">
7
7
  <slot name="label">
8
8
  ${this.label?this.labelMarkup:null}
9
9
  </slot>
10
- <div ${f(this.controlRef)} class="gator-form-element-control ${this.errorClass} ${this.disabledClass}">
10
+ <div ${g(this.controlRef)} class="gator-form-element-control ${this.errorClass} ${this.disabledClass}">
11
11
  <div class="gator-input-container">
12
12
  ${this.shouldHaveStartMarkup?p`
13
13
  <div class="gator-input-start">
14
14
  ${this.startIconMarkup}
15
15
  </div>`:null}
16
16
  <input
17
- ${f(this.inputRef)}
17
+ ${g(this.inputRef)}
18
18
  type="${this.type}"
19
19
  .id="${this.id}"
20
- data-testid=${d(this.dataTestid)}-input
21
- .placeholder="${g(this._placeholder)}"
20
+ data-testid=${l(this.dataTestid)}-input
21
+ .placeholder="${f(this._placeholder)}"
22
22
  .required="${this.required}"
23
23
  .disabled="${this.disabled}"
24
24
  class="gator-input"
25
25
  aria-invalid="${this.isAriaInvalid}"
26
26
  aria-required="${this.required}"
27
- aria-description="${d(this.ariaDescription)}"
28
- aria-label="${d(this.label)}"
29
- .value="${g(this._value)}"
30
- maxlength="${d(this._maxLength)}"
27
+ aria-description="${l(this.ariaDescription)}"
28
+ aria-label="${l(this.label)}"
29
+ .value="${f(this._value)}"
30
+ maxlength="${l(this._maxLength)}"
31
31
  .min="${this.min}"
32
32
  .max="${this.max}"
33
33
  .step="${this.step}"
34
+ .pattern="${l(this.pattern)}"
34
35
  @input="${this.handleInputEvent}"
35
36
  @change="${this.handleChange}"
36
37
  @click="${this.handleClick}"
@@ -48,7 +49,7 @@ import{T as u,E as b,x as p}from"../../../../assets/index-chunk2.js";import"../i
48
49
 
49
50
  ${this.bottomText}
50
51
  </div>
51
- `}get displayedErrorText(){return this.errorText||this._internalValidationError||this._nativeInputError}get isAriaInvalid(){return this.displayedErrorText?"true":"false"}get errorClass(){return this.displayedErrorText?"gator-has-error":""}get disabledClass(){return this.disabled?"gator-disabled":""}get passwordVisibilityMarkup(){return this.endIconMarkup||this.type!=="password"?null:p`<ngc-icon name="eye-crossed" @click="${this.togglePasswordVisibility}"></ngc-icon>`}connectedCallback(){super.connectedCallback(),this._value=this.value,this._maxLength=this.maxLength,this._placeholder=this.placeholder}handleNativeInputValidation(t){this.inputRef.value&&(this._nativeInputError=this.inputRef.value.validationMessage),t.preventDefault()}handleInputEvent(t){t.preventDefault(),t.stopPropagation();const e=t.target,r=new CustomEvent("input",{bubbles:!0,composed:!0,detail:{value:e.value}});this._value=e.value,this.dispatchEvent(r)}handleChange(t){t.preventDefault(),t.stopPropagation();const e=t.target,r=new CustomEvent("change",{composed:!0,bubbles:!0,detail:{value:e.value}});this._value=e.value,this.dispatchEvent(r)}togglePasswordVisibility(){const t=this.inputRef.value;t&&(t.type=t.type==="password"?"text":"password")}handleInputFocusOut(){var t;super.handleInputFocusOut(),(t=this.inputRef.value)!=null&&t.checkValidity()&&(this._nativeInputError="")}get errorTextMarkup(){return this.displayedErrorText?p`
52
+ `}get displayedErrorText(){return this.errorText||this._internalValidationError||this._nativeInputError}get isAriaInvalid(){return this.displayedErrorText?"true":"false"}get errorClass(){return this.displayedErrorText?"gator-has-error":""}get disabledClass(){return this.disabled?"gator-disabled":""}get passwordVisibilityMarkup(){return this.endIconMarkup||this.type!=="password"?null:p`<ngc-icon name="eye-crossed" @click="${this.togglePasswordVisibility}"></ngc-icon>`}connectedCallback(){super.connectedCallback(),this._value=this.value,this._maxLength=this.maxLength,this._placeholder=this.placeholder}handleNativeInputValidation(t){this.inputRef.value&&(this._nativeInputError=this.inputRef.value.validationMessage),t.preventDefault()}handleInputEvent(t){t.preventDefault(),t.stopPropagation();const e=t.target,i=new CustomEvent("input",{bubbles:!0,composed:!0,detail:{value:e.value}});this._value=e.value,this.dispatchEvent(i)}handleChange(t){t.preventDefault(),t.stopPropagation();const e=t.target,i=new CustomEvent("change",{composed:!0,bubbles:!0,detail:{value:e.value}});this._value=e.value,this.dispatchEvent(i)}togglePasswordVisibility(){const t=this.inputRef.value;t&&(t.type=t.type==="password"?"text":"password")}handleInputFocusOut(){var t;super.handleInputFocusOut(),(t=this.inputRef.value)!=null&&t.checkValidity()&&(this._nativeInputError="")}get errorTextMarkup(){return this.displayedErrorText?p`
52
53
  <ngc-help-text
53
54
  icon
54
55
  error
@@ -56,4 +57,4 @@ import{T as u,E as b,x as p}from"../../../../assets/index-chunk2.js";import"../i
56
57
  >
57
58
  ${this.displayedErrorText}
58
59
  </ngc-help-text>
59
- `:null}};i.shadowRootOptions={...y.shadowRootOptions,delegatesFocus:!0};s([h()],i.prototype,"for",2);s([h({type:Number})],i.prototype,"min",2);s([h({type:Number})],i.prototype,"max",2);s([h({type:Number})],i.prototype,"step",2);s([l()],i.prototype,"_nativeInputError",2);s([l()],i.prototype,"_internalValidationError",2);s([l()],i.prototype,"_value",2);s([l()],i.prototype,"_maxLength",2);s([l()],i.prototype,"_placeholder",2);i=s([$("ngc-input-text")],i);export{i as N};
60
+ `:null}};r.shadowRootOptions={...y.shadowRootOptions,delegatesFocus:!0};s([u()],r.prototype,"for",2);s([u({type:Number})],r.prototype,"min",2);s([u({type:Number})],r.prototype,"max",2);s([u({type:Number})],r.prototype,"step",2);s([u({type:String})],r.prototype,"pattern",2);s([h()],r.prototype,"_nativeInputError",2);s([h()],r.prototype,"_internalValidationError",2);s([h()],r.prototype,"_value",2);s([h()],r.prototype,"_maxLength",2);s([h()],r.prototype,"_placeholder",2);r=s([b("ngc-input-text")],r);export{r as N};
@@ -50,6 +50,7 @@ export declare class NgcInputDropdown extends NgcInputBase {
50
50
  handleSelected(): void;
51
51
  handleComboboxKeydown(e: KeyboardEvent): void;
52
52
  get errorClass(): "" | "gator-has-error";
53
+ get disabledClass(): "gator-disabled" | "gator-cursor-pointer";
53
54
  get labelMarkup(): import('lit').TemplateResult<1>;
54
55
  toggleListbox(key: string, initial: boolean): void;
55
56
  get endIconMarkup(): import('lit').TemplateResult<1>;
@@ -25,6 +25,11 @@ export declare class NgcInputText extends NgcInputBase {
25
25
  * @type {number}
26
26
  */
27
27
  step: number | undefined;
28
+ /**
29
+ * @property {string} pattern - The pattern attribute to be passed to the input
30
+ * @type {string}
31
+ */
32
+ pattern: string | undefined;
28
33
  _nativeInputError: string | undefined;
29
34
  _internalValidationError: string | undefined;
30
35
  protected _value: string | number | undefined | null | Date;
@@ -0,0 +1,70 @@
1
+ export declare const INPUT_BASE_ARGS: {
2
+ errorText: {
3
+ name: string;
4
+ description: string;
5
+ };
6
+ helpText: {
7
+ name: string;
8
+ description: string;
9
+ };
10
+ placeholder: {
11
+ description: string;
12
+ };
13
+ value: {
14
+ description: string;
15
+ };
16
+ label: {
17
+ description: string;
18
+ };
19
+ required: {
20
+ description: string;
21
+ };
22
+ disabled: {
23
+ description: string;
24
+ };
25
+ id: {
26
+ description: string;
27
+ };
28
+ };
29
+ export declare const INPUT_TEXT_ARGS: {
30
+ pattern: {
31
+ description: string;
32
+ control: string;
33
+ table: {
34
+ defaultValue: {
35
+ summary: string;
36
+ };
37
+ };
38
+ };
39
+ };
40
+ export declare const INPUT_NUMERIC_ARGS: {
41
+ min: {
42
+ description: string;
43
+ control: string;
44
+ };
45
+ max: {
46
+ description: string;
47
+ control: string;
48
+ };
49
+ step: {
50
+ description: string;
51
+ control: string;
52
+ table: {
53
+ defaultValue: {
54
+ summary: string;
55
+ };
56
+ };
57
+ };
58
+ };
59
+ export declare const START_ICON_ARG: {
60
+ startIcon: {
61
+ name: string;
62
+ description: string;
63
+ };
64
+ };
65
+ export declare const END_ICON_ARG: {
66
+ endIcon: {
67
+ name: string;
68
+ description: string;
69
+ };
70
+ };
@@ -5,6 +5,7 @@ export declare function getElementsInsideElement(element: HTMLElement, markup: s
5
5
  export declare function getElements(markup: string): NodeListOf<Element>;
6
6
  export declare function getShadowRootHTMLElements(element: HTMLElement | null, markup: string): NodeListOf<Element> | undefined;
7
7
  export declare function getShadowRootHTMLElement(element: HTMLElement | null, markup: string): HTMLElement | null | undefined;
8
+ export declare function getShadowRootElementByDataTestId(element: Element | null | undefined, dataTestId: string): HTMLElement;
8
9
  export declare function getShadowRootElement(element: Element | null | undefined, markup: string): Element | null | undefined;
9
10
  export declare function getSlotTextContent(element: HTMLElement | null | undefined): string | null | undefined;
10
11
  export declare function getNamedSlotTextContent(element: HTMLElement | null, name: string): string | undefined | null;
@@ -0,0 +1 @@
1
+
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@ncino/web-components",
3
3
  "author": "nCino",
4
- "version": "2.1.0-preview.7",
4
+ "version": "2.1.0-preview.9",
5
5
  "license": "(c) Copyright 2023 nCino, Inc., all rights reserved",
6
6
  "publishConfig": {
7
7
  "registry": "https://registry.npmjs.org/"
@@ -65,6 +65,8 @@
65
65
  "lit": "^3.2.1"
66
66
  },
67
67
  "devDependencies": {
68
+ "@actions/core": "^1.11.1",
69
+ "@actions/exec": "^1.1.1",
68
70
  "@custom-elements-manifest/analyzer": "0.10.4",
69
71
  "@geometricpanda/storybook-addon-badges": "^2.0.5",
70
72
  "@lit/react": "^1.0.7",
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json",
3
3
  "name": "@ncino/web-components",
4
- "version": "2.1.0-preview.6",
4
+ "version": "2.1.0-preview.8",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -1506,6 +1506,7 @@
1506
1506
  { "name": "min", "value": { "type": "string" } },
1507
1507
  { "name": "max", "value": { "type": "string" } },
1508
1508
  { "name": "step", "value": { "type": "number" } },
1509
+ { "name": "pattern", "value": { "type": "string" } },
1509
1510
  { "name": "id", "value": { "type": "string", "default": "''" } },
1510
1511
  {
1511
1512
  "name": "required",
@@ -1566,6 +1567,7 @@
1566
1567
  { "name": "min", "type": "string" },
1567
1568
  { "name": "max", "type": "string" },
1568
1569
  { "name": "step", "type": "number" },
1570
+ { "name": "pattern", "type": "string" },
1569
1571
  { "name": "_nativeInputError", "type": "string | undefined" },
1570
1572
  {
1571
1573
  "name": "_internalValidationError",
@@ -1614,6 +1616,7 @@
1614
1616
  { "name": "min", "value": { "type": "string" } },
1615
1617
  { "name": "max", "value": { "type": "string" } },
1616
1618
  { "name": "step", "value": { "type": "number" } },
1619
+ { "name": "pattern", "value": { "type": "string" } },
1617
1620
  { "name": "id", "value": { "type": "string", "default": "''" } },
1618
1621
  {
1619
1622
  "name": "required",
@@ -1674,6 +1677,7 @@
1674
1677
  { "name": "min", "type": "string" },
1675
1678
  { "name": "max", "type": "string" },
1676
1679
  { "name": "step", "type": "number" },
1680
+ { "name": "pattern", "type": "string" },
1677
1681
  { "name": "_nativeInputError", "type": "string | undefined" },
1678
1682
  {
1679
1683
  "name": "_internalValidationError",
@@ -1737,6 +1741,7 @@
1737
1741
  { "name": "min", "value": { "type": "string" } },
1738
1742
  { "name": "max", "value": { "type": "string" } },
1739
1743
  { "name": "step", "value": { "type": "number" } },
1744
+ { "name": "pattern", "value": { "type": "string" } },
1740
1745
  { "name": "id", "value": { "type": "string", "default": "''" } },
1741
1746
  {
1742
1747
  "name": "required",
@@ -1804,6 +1809,7 @@
1804
1809
  { "name": "min", "type": "string" },
1805
1810
  { "name": "max", "type": "string" },
1806
1811
  { "name": "step", "type": "number" },
1812
+ { "name": "pattern", "type": "string" },
1807
1813
  { "name": "_nativeInputError", "type": "string | undefined" },
1808
1814
  {
1809
1815
  "name": "_internalValidationError",
@@ -2084,6 +2090,7 @@
2084
2090
  { "name": "listboxMarkup" },
2085
2091
  { "name": "displayedOptions" },
2086
2092
  { "name": "errorClass" },
2093
+ { "name": "disabledClass" },
2087
2094
  { "name": "labelMarkup" },
2088
2095
  { "name": "endIconMarkup" },
2089
2096
  { "name": "controlRef", "type": "Ref<HTMLDivElement>" },
@@ -3851,6 +3858,7 @@
3851
3858
  { "name": "min", "value": { "type": "string" } },
3852
3859
  { "name": "max", "value": { "type": "string" } },
3853
3860
  { "name": "step", "value": { "type": "number" } },
3861
+ { "name": "pattern", "value": { "type": "string" } },
3854
3862
  { "name": "id", "value": { "type": "string", "default": "''" } },
3855
3863
  {
3856
3864
  "name": "required",
@@ -3931,6 +3939,7 @@
3931
3939
  { "name": "min", "type": "string" },
3932
3940
  { "name": "max", "type": "string" },
3933
3941
  { "name": "step", "type": "number" },
3942
+ { "name": "pattern", "type": "string" },
3934
3943
  { "name": "_nativeInputError", "type": "string | undefined" },
3935
3944
  {
3936
3945
  "name": "_internalValidationError",
@@ -3977,6 +3986,7 @@
3977
3986
  { "name": "min", "value": { "type": "string" } },
3978
3987
  { "name": "max", "value": { "type": "string" } },
3979
3988
  { "name": "step", "value": { "type": "number" } },
3989
+ { "name": "pattern", "value": { "type": "string" } },
3980
3990
  { "name": "id", "value": { "type": "string", "default": "''" } },
3981
3991
  {
3982
3992
  "name": "required",
@@ -4037,6 +4047,7 @@
4037
4047
  { "name": "min", "type": "string" },
4038
4048
  { "name": "max", "type": "string" },
4039
4049
  { "name": "step", "type": "number" },
4050
+ { "name": "pattern", "type": "string" },
4040
4051
  { "name": "_nativeInputError", "type": "string | undefined" },
4041
4052
  {
4042
4053
  "name": "_internalValidationError",
@@ -4077,8 +4088,8 @@
4077
4088
  }
4078
4089
  },
4079
4090
  {
4080
- "name": "ngc-toast-subtitle",
4081
- "description": "\n---\n\n\n### **Slots:**\n - _default_ - The subtitle content",
4091
+ "name": "ngc-toast-title",
4092
+ "description": "\n---\n\n\n### **Slots:**\n - _default_ - The title content",
4082
4093
  "doc-url": "",
4083
4094
  "attributes": [
4084
4095
  {
@@ -4110,7 +4121,7 @@
4110
4121
  "value": { "type": "string", "default": "''" }
4111
4122
  }
4112
4123
  ],
4113
- "slots": [{ "name": "", "description": "The subtitle content" }],
4124
+ "slots": [{ "name": "", "description": "The title content" }],
4114
4125
  "events": [],
4115
4126
  "js": {
4116
4127
  "properties": [
@@ -4129,8 +4140,8 @@
4129
4140
  }
4130
4141
  },
4131
4142
  {
4132
- "name": "ngc-toast-title",
4133
- "description": "\n---\n\n\n### **Slots:**\n - _default_ - The title content",
4143
+ "name": "ngc-toast-subtitle",
4144
+ "description": "\n---\n\n\n### **Slots:**\n - _default_ - The subtitle content",
4134
4145
  "doc-url": "",
4135
4146
  "attributes": [
4136
4147
  {
@@ -4162,7 +4173,7 @@
4162
4173
  "value": { "type": "string", "default": "''" }
4163
4174
  }
4164
4175
  ],
4165
- "slots": [{ "name": "", "description": "The title content" }],
4176
+ "slots": [{ "name": "", "description": "The subtitle content" }],
4166
4177
  "events": [],
4167
4178
  "js": {
4168
4179
  "properties": [