@ember-eui/validated-form 15.0.0 → 16.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE.md CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2021
3
+ Copyright (c) 2020-present Alberto Cantu and Ember EUI contributors
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
6
6
 
@@ -17,7 +17,7 @@ export interface FieldComboBoxSignature {
17
17
  formId?: string;
18
18
  /** Accessible label of the control. */
19
19
  ariaLabel?: string;
20
- /** Focuses the control on render. */
20
+ /** Focuses the control on render (same as `@autoFocus`). */
21
21
  autofocus?: boolean;
22
22
  /** Called with the selected options. */
23
23
  onChange?: (options: any[]) => void;
@@ -1 +1 @@
1
- {"version":3,"file":"field-combo-box.d.ts","sourceRoot":"","sources":["../../../src/components/validated-form/field-combo-box.gts"],"names":[],"mappings":"AAsJA,OAAO,sBAAsB,MAAM,kBAAkB,CAAC;AAEtD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAC3D,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,0CAA0C,CAAC;AACrF,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,yCAAyC,CAAC;AAEnF;;;GAGG;AACH,MAAM,WAAW,sBAAsB;IACrC,OAAO,EAAE,oBAAoB,CAAC,SAAS,CAAC,CAAC;IACzC,IAAI,EAAE,kBAAkB,CAAC,MAAM,CAAC,GAC9B,mBAAmB,CAAC,MAAM,CAAC,GAC3B,oBAAoB,CAAC,MAAM,CAAC,GAAG;QAC7B,kCAAkC;QAClC,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,+BAA+B;QAC/B,YAA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
  import { argOrDefault } from '@ember-eui/core/helpers';
8
8
  import optional from '@nullvoxpopuli/ember-composable-helpers/helpers/optional';
9
9
  import queue from '@nullvoxpopuli/ember-composable-helpers/helpers/queue';
10
- import { not } from 'ember-truth-helpers';
10
+ import { or, not } from 'ember-truth-helpers';
11
11
  import randomId from '../../-private/random-id.js';
12
12
  import ValidatedFormFieldBase from './field-base.js';
13
13
  import { precompileTemplate } from '@ember/template-compilation';
@@ -25,7 +25,7 @@ class ValidatedFormFieldComboBox extends ValidatedFormFieldBase {
25
25
  n(this.prototype, "handleChange", [action]);
26
26
  }
27
27
  static {
28
- setComponentTemplate(precompileTemplate("{{#let (argOrDefault @id (randomId)) as |theId|}}\n <EuiFormRow class={{this.rowClasses}} @labelType={{@labelType}} @display={{@display}} @hasEmptyLabelSpace={{@hasEmptyLabelSpace}} @fullWidth={{@fullWidth}} @hasChildLabel={{@hasChildLabel}} @label={{this.label}} @labelAppend={{@labelAppend}} @id={{theId}} @isInvalid={{this.isInvalidAndTouched}} @error={{this.validationErrorMessages}} @helpText={{@helpText}} @errorClasses={{@errorClasses}} @isFakeLabelBlock={{not (has-block \"label\")}} @isFakeHelpTextBlock={{not (has-block \"helpText\")}} {{didInsert this.setValidationMessages}} {{didUpdate this.didUpdateValue @validations}} {{didUpdate this.didUpdateValue @selectedOptions}}>\n <:label>\n {{yield to=\"label\"}}\n </:label>\n <:field>\n <EuiComboBox class={{@fieldClasses}} @onChange={{this.handleChange}} @dropdownClass={{@dropdownClass}} @placeholder={{@placeholder}} @options={{this.options}} @singleSelection={{@singleSelection}} @selectedOptions={{@selectedOptions}} @searchEnabled={{argOrDefault @searchEnabled true}} @placeholderComponent={{@placeholderComponent}} @searchMessageComponent={{@searchMessageComponent}} @loadingMessage={{@loadingMessage}} @beforeOptionsComponent={{@beforeOptionsComponent}} @afterOptionsComponent={{@afterOptionsComponent}} @searchField={{@searchField}} @searchMessage={{@searchMessage}} @search={{@search}} aria-label={{@ariaLabel}} @isInvalid={{this.isInvalidAndTouched}} @isClearable={{@isClearable}} @fullWidth={{@fullWidth}} @isLoading={{@isLoading}} @readOnly={{@readOnly}} @compressed={{@compressed}} @onCreateOption={{@onCreateOption}} @matchTriggerWidth={{@matchTriggerWidth}} @customOptionText={{@customOptionText}} @onBlur={{queue (fn this.setIsTouched true) (optional @onBlur)}} @onFocus={{@onFocus}} @onClose={{@onClose}} @onOpen={{@onOpen}} @isDisabled={{@isDisabled}} @renderInPlace={{@renderInPlace}} @extra={{@extra}} ...attributes as |opt index select|>\n {{yield opt index select}}\n </EuiComboBox>\n </:field>\n <:helpText as |helpText|>\n {{yield helpText to=\"helpText\"}}\n </:helpText>\n </EuiFormRow>\n{{/let}}", {
28
+ setComponentTemplate(precompileTemplate("{{#let (argOrDefault @id (randomId)) as |theId|}}\n <EuiFormRow class={{this.rowClasses}} @labelType={{@labelType}} @display={{@display}} @hasEmptyLabelSpace={{@hasEmptyLabelSpace}} @fullWidth={{@fullWidth}} @hasChildLabel={{@hasChildLabel}} @label={{this.label}} @labelAppend={{@labelAppend}} @id={{theId}} @isInvalid={{this.isInvalidAndTouched}} @error={{this.validationErrorMessages}} @helpText={{@helpText}} @errorClasses={{@errorClasses}} @isFakeLabelBlock={{not (has-block \"label\")}} @isFakeHelpTextBlock={{not (has-block \"helpText\")}} {{didInsert this.setValidationMessages}} {{didUpdate this.didUpdateValue @validations}} {{didUpdate this.didUpdateValue @selectedOptions}}>\n <:label>\n {{yield to=\"label\"}}\n </:label>\n <:field>\n {{#let (component EuiComboBox onChange=this.handleChange options=this.options singleSelection=@singleSelection selectedOptions=@selectedOptions searchEnabled=(argOrDefault @searchEnabled true) searchField=@searchField search=@search searchMessage=@searchMessage searchMessageComponent=@searchMessageComponent searchPlaceholder=@searchPlaceholder placeholder=@placeholder placeholderComponent=@placeholderComponent loadingMessage=@loadingMessage noMatchesMessage=@noMatchesMessage noMatchesMessageComponent=@noMatchesMessageComponent beforeOptionsComponent=@beforeOptionsComponent afterOptionsComponent=@afterOptionsComponent selectedItemComponent=@selectedItemComponent dropdownClass=@dropdownClass optionsClass=@optionsClass onCreateOption=@onCreateOption alwaysShowCreateOption=@alwaysShowCreateOption customOptionText=@customOptionText delimiter=@delimiter isCaseSensitive=@isCaseSensitive sortMatchesBy=@sortMatchesBy matcher=@matcher optionMatcher=@optionMatcher typeAheadOptionMatcher=@typeAheadOptionMatcher async=@async onSearchChange=@onSearchChange noSuggestions=@noSuggestions truncationProps=@truncationProps rowHeight=@rowHeight onFocusBadge=@onFocusBadge prepend=@prepend append=@append triggerIcon=@triggerIcon isInvalid=this.isInvalidAndTouched isClearable=@isClearable isLoading=@isLoading isDisabled=@isDisabled readOnly=@readOnly fullWidth=@fullWidth compressed=@compressed closeOnSelect=@closeOnSelect autoFocus=(or @autoFocus @autofocus) initiallyOpen=@initiallyOpen defaultHighlighted=@defaultHighlighted matchTriggerWidth=@matchTriggerWidth renderInPlace=@renderInPlace horizontalPosition=@horizontalPosition verticalPosition=@verticalPosition destination=@destination preventScroll=@preventScroll calculatePosition=@calculatePosition eventType=@eventType tabindex=@tabindex ariaLabel=@ariaLabel ariaLabelledBy=@ariaLabelledBy required=@required triggerRole=@triggerRole title=@title triggerId=@triggerId removeTag=@removeTag onInput=@onInput onKeydown=@onKeydown registerApi=@registerApi onBlur=(queue (fn this.setIsTouched true) (optional @onBlur)) onFocus=@onFocus onClose=@onClose onOpen=@onOpen extra=@extra) as |ComboBox|}}\n {{#if (has-block)}}\n <ComboBox class={{@fieldClasses}} ...attributes as |opt index search|>\n {{yield opt index search}}\n </ComboBox>\n {{else}}\n {{!-- without a block, EuiComboBox renders the option labels --}}\n <ComboBox class={{@fieldClasses}} ...attributes />\n {{/if}}\n {{/let}}\n </:field>\n <:helpText as |helpText|>\n {{yield helpText to=\"helpText\"}}\n </:helpText>\n </EuiFormRow>\n{{/let}}", {
29
29
  strictMode: true,
30
30
  scope: () => ({
31
31
  argOrDefault,
@@ -35,6 +35,7 @@ class ValidatedFormFieldComboBox extends ValidatedFormFieldBase {
35
35
  didInsert,
36
36
  didUpdate,
37
37
  EuiComboBox,
38
+ or,
38
39
  queue,
39
40
  fn,
40
41
  optional
@@ -1 +1 @@
1
- {"version":3,"file":"field-combo-box.js","sources":["../../../src/components/validated-form/field-combo-box.gts"],"sourcesContent":["import { fn } from '@ember/helper';\nimport { action } from '@ember/object';\nimport didInsert from '@ember/render-modifiers/modifiers/did-insert';\nimport didUpdate from '@ember/render-modifiers/modifiers/did-update';\nimport EuiComboBox from '@ember-eui/core/components/eui-combo-box';\nimport EuiFormRow from '@ember-eui/core/components/eui-form-row';\nimport { argOrDefault } from '@ember-eui/core/helpers';\n\nimport optional from '@nullvoxpopuli/ember-composable-helpers/helpers/optional';\nimport queue from '@nullvoxpopuli/ember-composable-helpers/helpers/queue';\nimport { not } from 'ember-truth-helpers';\n\nimport randomId from '../../-private/random-id.ts';\nimport ValidatedFormFieldBase from './field-base.gts';\n\nimport type { FieldBaseSignature } from './field-base.gts';\nimport type { EuiComboBoxSignature } from '@ember-eui/core/components/eui-combo-box';\nimport type { EuiFormRowSignature } from '@ember-eui/core/components/eui-form-row';\n\n/**\n * A validated combo box in an EuiFormRow. Takes FieldBase's, EuiFormRow's and\n * the control's args.\n */\nexport interface FieldComboBoxSignature {\n Element: EuiComboBoxSignature['Element'];\n Args: FieldBaseSignature['Args'] &\n EuiFormRowSignature['Args'] &\n EuiComboBoxSignature['Args'] & {\n /** Classes for the EuiFormRow. */\n rowClasses?: string;\n /** Classes for the control. */\n fieldClasses?: string;\n /** @private Set by ValidatedForm. */\n formId?: string;\n /** Accessible label of the control. */\n ariaLabel?: string;\n /** Focuses the control on render. */\n autofocus?: boolean;\n /** Called with the selected options. */\n onChange?: (options: any[]) => void;\n /** Placeholder text. */\n placeholder?: string;\n /** The options, see the control. */\n options?: EuiComboBoxSignature['Args']['options'];\n /** The selected options. */\n selectedOptions?: EuiComboBoxSignature['Args']['selectedOptions'];\n };\n Blocks: {\n label: EuiFormRowSignature['Blocks']['label'];\n helpText: EuiFormRowSignature['Blocks']['helpText'];\n default: EuiComboBoxSignature['Blocks']['default'];\n };\n}\n\nexport default class ValidatedFormFieldComboBox extends ValidatedFormFieldBase<FieldComboBoxSignature> {\n validationProperty = 'args.selectedOptions';\n\n @action\n //@ts-expect-error\n handleChange(options: any[]) {\n this.args.onChange(options);\n this.notifyValidityChange();\n }\n\n <template>\n {{#let (argOrDefault @id (randomId)) as |theId|}}\n <EuiFormRow\n class={{this.rowClasses}}\n @labelType={{@labelType}}\n @display={{@display}}\n @hasEmptyLabelSpace={{@hasEmptyLabelSpace}}\n @fullWidth={{@fullWidth}}\n @hasChildLabel={{@hasChildLabel}}\n @label={{this.label}}\n @labelAppend={{@labelAppend}}\n @id={{theId}}\n @isInvalid={{this.isInvalidAndTouched}}\n @error={{this.validationErrorMessages}}\n @helpText={{@helpText}}\n @errorClasses={{@errorClasses}}\n @isFakeLabelBlock={{not (has-block \"label\")}}\n @isFakeHelpTextBlock={{not (has-block \"helpText\")}}\n {{didInsert this.setValidationMessages}}\n {{didUpdate this.didUpdateValue @validations}}\n {{didUpdate this.didUpdateValue @selectedOptions}}\n >\n <:label>\n {{yield to=\"label\"}}\n </:label>\n <:field>\n <EuiComboBox\n class={{@fieldClasses}}\n @onChange={{this.handleChange}}\n @dropdownClass={{@dropdownClass}}\n @placeholder={{@placeholder}}\n @options={{this.options}}\n @singleSelection={{@singleSelection}}\n @selectedOptions={{@selectedOptions}}\n @searchEnabled={{argOrDefault @searchEnabled true}}\n @placeholderComponent={{@placeholderComponent}}\n @searchMessageComponent={{@searchMessageComponent}}\n @loadingMessage={{@loadingMessage}}\n @beforeOptionsComponent={{@beforeOptionsComponent}}\n @afterOptionsComponent={{@afterOptionsComponent}}\n @searchField={{@searchField}}\n @searchMessage={{@searchMessage}}\n @search={{@search}}\n aria-label={{@ariaLabel}}\n @isInvalid={{this.isInvalidAndTouched}}\n @isClearable={{@isClearable}}\n @fullWidth={{@fullWidth}}\n @isLoading={{@isLoading}}\n @readOnly={{@readOnly}}\n @compressed={{@compressed}}\n @onCreateOption={{@onCreateOption}}\n @matchTriggerWidth={{@matchTriggerWidth}}\n @customOptionText={{@customOptionText}}\n @onBlur={{queue (fn this.setIsTouched true) (optional @onBlur)}}\n @onFocus={{@onFocus}}\n @onClose={{@onClose}}\n @onOpen={{@onOpen}}\n @isDisabled={{@isDisabled}}\n @renderInPlace={{@renderInPlace}}\n @extra={{@extra}}\n ...attributes\n as |opt index select|\n >\n {{yield opt index select}}\n </EuiComboBox>\n </:field>\n <:helpText as |helpText|>\n {{yield helpText to=\"helpText\"}}\n </:helpText>\n </EuiFormRow>\n {{/let}}\n </template>\n}\n"],"names":["ValidatedFormFieldComboBox","ValidatedFormFieldBase","validationProperty","handleChange","options","args","onChange","notifyValidityChange","n","prototype","action","setComponentTemplate","precompileTemplate","strictMode","scope","argOrDefault","randomId","EuiFormRow","not","didInsert","didUpdate","EuiComboBox","queue","fn","optional"],"mappings":";;;;;;;;;;;;;;;;AAsDe,MAAMA,mCAAmCC,sBAAA,CAAuB;AAC7EC,EAAAA,kBAAA,GAAqB,sBAAA;AAGrB;EACAC,YAAAA,CAAaC,OAAc,EAAE;AAC3B,IAAA,IAAI,CAACC,IAAI,CAACC,QAAQ,CAACF,OAAA,CAAA;IACnB,IAAI,CAACG,oBAAoB,EAAA;AAC3B,EAAA;AAAA,EAAA;IAAAC,CAAA,CAAA,IAAA,CAAAC,SAAA,EAAA,cAAA,EAAA,CALCC,MAAA,CAAA,CAAA;AAAA;AAOD,EAAA;IAAAC,oBAAA,CAAAC,kBAAA,CAAA,olEAAA,EAuEA;MAAAC,UAAA,EAAA,IAAA;AAAAC,MAAAA,KAAA,EAAAA,OAAA;QAAAC,YAAA;QAAAC,QAAA;QAAAC,UAAA;QAAAC,GAAA;QAAAC,SAAA;QAAAC,SAAA;QAAAC,WAAA;QAAAC,KAAA;QAAAC,EAAA;AAAAC,QAAAA;AAAA,OAAA;KAAU,CAAA,EAAV,IAAW,CAAA;AAAD;AACZ;;"}
1
+ {"version":3,"file":"field-combo-box.js","sources":["../../../src/components/validated-form/field-combo-box.gts"],"sourcesContent":["import { fn } from '@ember/helper';\nimport { action } from '@ember/object';\nimport didInsert from '@ember/render-modifiers/modifiers/did-insert';\nimport didUpdate from '@ember/render-modifiers/modifiers/did-update';\nimport EuiComboBox from '@ember-eui/core/components/eui-combo-box';\nimport EuiFormRow from '@ember-eui/core/components/eui-form-row';\nimport { argOrDefault } from '@ember-eui/core/helpers';\n\nimport optional from '@nullvoxpopuli/ember-composable-helpers/helpers/optional';\nimport queue from '@nullvoxpopuli/ember-composable-helpers/helpers/queue';\nimport { not, or } from 'ember-truth-helpers';\n\nimport randomId from '../../-private/random-id.ts';\nimport ValidatedFormFieldBase from './field-base.gts';\n\nimport type { FieldBaseSignature } from './field-base.gts';\nimport type { EuiComboBoxSignature } from '@ember-eui/core/components/eui-combo-box';\nimport type { EuiFormRowSignature } from '@ember-eui/core/components/eui-form-row';\n\n/**\n * A validated combo box in an EuiFormRow. Takes FieldBase's, EuiFormRow's and\n * the control's args.\n */\nexport interface FieldComboBoxSignature {\n Element: EuiComboBoxSignature['Element'];\n Args: FieldBaseSignature['Args'] &\n EuiFormRowSignature['Args'] &\n EuiComboBoxSignature['Args'] & {\n /** Classes for the EuiFormRow. */\n rowClasses?: string;\n /** Classes for the control. */\n fieldClasses?: string;\n /** @private Set by ValidatedForm. */\n formId?: string;\n /** Accessible label of the control. */\n ariaLabel?: string;\n /** Focuses the control on render (same as `@autoFocus`). */\n autofocus?: boolean;\n /** Called with the selected options. */\n onChange?: (options: any[]) => void;\n /** Placeholder text. */\n placeholder?: string;\n /** The options, see the control. */\n options?: EuiComboBoxSignature['Args']['options'];\n /** The selected options. */\n selectedOptions?: EuiComboBoxSignature['Args']['selectedOptions'];\n };\n Blocks: {\n label: EuiFormRowSignature['Blocks']['label'];\n helpText: EuiFormRowSignature['Blocks']['helpText'];\n default: EuiComboBoxSignature['Blocks']['default'];\n };\n}\n\nexport default class ValidatedFormFieldComboBox extends ValidatedFormFieldBase<FieldComboBoxSignature> {\n validationProperty = 'args.selectedOptions';\n\n @action\n //@ts-expect-error\n handleChange(options: any[]) {\n this.args.onChange(options);\n this.notifyValidityChange();\n }\n\n <template>\n {{#let (argOrDefault @id (randomId)) as |theId|}}\n <EuiFormRow\n class={{this.rowClasses}}\n @labelType={{@labelType}}\n @display={{@display}}\n @hasEmptyLabelSpace={{@hasEmptyLabelSpace}}\n @fullWidth={{@fullWidth}}\n @hasChildLabel={{@hasChildLabel}}\n @label={{this.label}}\n @labelAppend={{@labelAppend}}\n @id={{theId}}\n @isInvalid={{this.isInvalidAndTouched}}\n @error={{this.validationErrorMessages}}\n @helpText={{@helpText}}\n @errorClasses={{@errorClasses}}\n @isFakeLabelBlock={{not (has-block \"label\")}}\n @isFakeHelpTextBlock={{not (has-block \"helpText\")}}\n {{didInsert this.setValidationMessages}}\n {{didUpdate this.didUpdateValue @validations}}\n {{didUpdate this.didUpdateValue @selectedOptions}}\n >\n <:label>\n {{yield to=\"label\"}}\n </:label>\n <:field>\n {{#let\n (component\n EuiComboBox\n onChange=this.handleChange\n options=this.options\n singleSelection=@singleSelection\n selectedOptions=@selectedOptions\n searchEnabled=(argOrDefault @searchEnabled true)\n searchField=@searchField\n search=@search\n searchMessage=@searchMessage\n searchMessageComponent=@searchMessageComponent\n searchPlaceholder=@searchPlaceholder\n placeholder=@placeholder\n placeholderComponent=@placeholderComponent\n loadingMessage=@loadingMessage\n noMatchesMessage=@noMatchesMessage\n noMatchesMessageComponent=@noMatchesMessageComponent\n beforeOptionsComponent=@beforeOptionsComponent\n afterOptionsComponent=@afterOptionsComponent\n selectedItemComponent=@selectedItemComponent\n dropdownClass=@dropdownClass\n optionsClass=@optionsClass\n onCreateOption=@onCreateOption\n alwaysShowCreateOption=@alwaysShowCreateOption\n customOptionText=@customOptionText\n delimiter=@delimiter\n isCaseSensitive=@isCaseSensitive\n sortMatchesBy=@sortMatchesBy\n matcher=@matcher\n optionMatcher=@optionMatcher\n typeAheadOptionMatcher=@typeAheadOptionMatcher\n async=@async\n onSearchChange=@onSearchChange\n noSuggestions=@noSuggestions\n truncationProps=@truncationProps\n rowHeight=@rowHeight\n onFocusBadge=@onFocusBadge\n prepend=@prepend\n append=@append\n triggerIcon=@triggerIcon\n isInvalid=this.isInvalidAndTouched\n isClearable=@isClearable\n isLoading=@isLoading\n isDisabled=@isDisabled\n readOnly=@readOnly\n fullWidth=@fullWidth\n compressed=@compressed\n closeOnSelect=@closeOnSelect\n autoFocus=(or @autoFocus @autofocus)\n initiallyOpen=@initiallyOpen\n defaultHighlighted=@defaultHighlighted\n matchTriggerWidth=@matchTriggerWidth\n renderInPlace=@renderInPlace\n horizontalPosition=@horizontalPosition\n verticalPosition=@verticalPosition\n destination=@destination\n preventScroll=@preventScroll\n calculatePosition=@calculatePosition\n eventType=@eventType\n tabindex=@tabindex\n ariaLabel=@ariaLabel\n ariaLabelledBy=@ariaLabelledBy\n required=@required\n triggerRole=@triggerRole\n title=@title\n triggerId=@triggerId\n removeTag=@removeTag\n onInput=@onInput\n onKeydown=@onKeydown\n registerApi=@registerApi\n onBlur=(queue (fn this.setIsTouched true) (optional @onBlur))\n onFocus=@onFocus\n onClose=@onClose\n onOpen=@onOpen\n extra=@extra\n )\n as |ComboBox|\n }}\n {{#if (has-block)}}\n <ComboBox class={{@fieldClasses}} ...attributes as |opt index search|>\n {{yield opt index search}}\n </ComboBox>\n {{else}}\n {{! without a block, EuiComboBox renders the option labels }}\n <ComboBox class={{@fieldClasses}} ...attributes />\n {{/if}}\n {{/let}}\n </:field>\n <:helpText as |helpText|>\n {{yield helpText to=\"helpText\"}}\n </:helpText>\n </EuiFormRow>\n {{/let}}\n </template>\n}\n"],"names":["ValidatedFormFieldComboBox","ValidatedFormFieldBase","validationProperty","handleChange","options","args","onChange","notifyValidityChange","n","prototype","action","setComponentTemplate","precompileTemplate","strictMode","scope","argOrDefault","randomId","EuiFormRow","not","didInsert","didUpdate","EuiComboBox","or","queue","fn","optional"],"mappings":";;;;;;;;;;;;;;;;AAsDe,MAAMA,mCAAmCC,sBAAA,CAAuB;AAC7EC,EAAAA,kBAAA,GAAqB,sBAAA;AAGrB;EACAC,YAAAA,CAAaC,OAAc,EAAE;AAC3B,IAAA,IAAI,CAACC,IAAI,CAACC,QAAQ,CAACF,OAAA,CAAA;IACnB,IAAI,CAACG,oBAAoB,EAAA;AAC3B,EAAA;AAAA,EAAA;IAAAC,CAAA,CAAA,IAAA,CAAAC,SAAA,EAAA,cAAA,EAAA,CALCC,MAAA,CAAA,CAAA;AAAA;AAOD,EAAA;IAAAC,oBAAA,CAAAC,kBAAA,CAAA,01GAAA,EAwHA;MAAAC,UAAA,EAAA,IAAA;AAAAC,MAAAA,KAAA,EAAAA,OAAA;QAAAC,YAAA;QAAAC,QAAA;QAAAC,UAAA;QAAAC,GAAA;QAAAC,SAAA;QAAAC,SAAA;QAAAC,WAAA;QAAAC,EAAA;QAAAC,KAAA;QAAAC,EAAA;AAAAC,QAAAA;AAAA,OAAA;KAAU,CAAA,EAAV,IAAW,CAAA;AAAD;AACZ;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ember-eui/validated-form",
3
- "version": "15.0.0",
3
+ "version": "16.0.0",
4
4
  "description": "The default blueprint for ember-cli addons.",
5
5
  "keywords": [
6
6
  "ember-addon"
@@ -45,7 +45,7 @@
45
45
  "ember-validators": "^5.0.0"
46
46
  },
47
47
  "peerDependencies": {
48
- "@ember-eui/core": "^15.0.0",
48
+ "@ember-eui/core": "^16.0.0",
49
49
  "@glimmer/component": "^2.0.0",
50
50
  "ember-source": ">= 7.1.0"
51
51
  },
@@ -55,7 +55,7 @@
55
55
  "@babel/plugin-proposal-decorators": "^7.25.9",
56
56
  "@babel/plugin-transform-typescript": "^7.12.13",
57
57
  "@babel/preset-typescript": "^7.18.6",
58
- "@ember-eui/core": "15.0.0",
58
+ "@ember-eui/core": "16.0.0",
59
59
  "@ember/optional-features": "^2.2.0",
60
60
  "@ember/test-helpers": "^5.2.1",
61
61
  "@ember/test-waiters": "^4.1.1",