@lion/ui 0.8.0 → 0.8.2
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/README.md +7 -7
- package/components/calendar/src/LionCalendar.js +6 -0
- package/components/core/src/DisabledWithTabIndexMixin.js +7 -0
- package/components/core/src/ScopedElementsMixin.js +58 -37
- package/components/core/test/ScopedElementsMixin.test.js +131 -0
- package/components/core/test/ssr-definitions/ScopedElementsHost.define.js +1 -0
- package/components/form/src/LionForm.js +3 -12
- package/components/form/test/lion-form.test.js +88 -1
- package/components/form-core/src/FormControlMixin.js +6 -0
- package/components/form-core/src/registration/FormRegisteringMixin.js +1 -1
- package/components/form-core/src/utils/SyncUpdatableMixin.js +7 -0
- package/components/form-core/src/validate/LionValidationFeedback.js +4 -2
- package/components/form-core/test/validate/lion-validation-feedback.test.js +12 -0
- package/components/form-core/types/registration/FormRegisteringMixinTypes.ts +1 -1
- package/components/icon/src/LionIcon.js +6 -0
- package/components/listbox/test-suites/ListboxMixin.suite.js +2 -2
- package/components/localize/src/LocalizeManager.js +259 -204
- package/components/overlays/src/OverlayController.js +1 -1
- package/components/overlays/src/OverlayMixin.js +7 -0
- package/components/progress-indicator/src/LionProgressIndicator.js +6 -0
- package/components/steps/src/LionStep.js +6 -0
- package/components/steps/src/LionSteps.js +6 -0
- package/components/tabs/src/LionTabs.js +6 -0
- package/components/tooltip/src/LionTooltip.js +6 -0
- package/custom-elements.json +792 -330
- package/dist-types/components/calendar/src/LionCalendar.d.ts +5 -0
- package/dist-types/components/calendar/src/LionCalendar.d.ts.map +1 -1
- package/dist-types/components/core/src/DisabledWithTabIndexMixin.d.ts.map +1 -1
- package/dist-types/components/core/src/ScopedElementsMixin.d.ts +43 -6
- package/dist-types/components/core/src/ScopedElementsMixin.d.ts.map +1 -1
- package/dist-types/components/core/test/ScopedElementsMixin.test.d.ts +2 -0
- package/dist-types/components/core/test/ScopedElementsMixin.test.d.ts.map +1 -0
- package/dist-types/components/core/test/ssr-definitions/ScopedElementsHost.define.d.ts +2 -0
- package/dist-types/components/core/test/ssr-definitions/ScopedElementsHost.define.d.ts.map +1 -0
- package/dist-types/components/form/src/LionForm.d.ts.map +1 -1
- package/dist-types/components/form/test/lion-form.test.d.ts.map +1 -1
- package/dist-types/components/form-core/src/FormControlMixin.d.ts.map +1 -1
- package/dist-types/components/form-core/src/utils/SyncUpdatableMixin.d.ts.map +1 -1
- package/dist-types/components/form-core/src/validate/LionValidationFeedback.d.ts.map +1 -1
- package/dist-types/components/form-core/types/registration/FormRegisteringMixinTypes.d.ts +1 -1
- package/dist-types/components/form-integrations/test/helpers/helpers.d.ts +3 -3
- package/dist-types/components/form-integrations/test/helpers/helpers.d.ts.map +1 -1
- package/dist-types/components/icon/src/LionIcon.d.ts +5 -0
- package/dist-types/components/icon/src/LionIcon.d.ts.map +1 -1
- package/dist-types/components/input-datepicker/src/LionInputDatepicker.d.ts +1 -1
- package/dist-types/components/input-file/src/LionInputFile.d.ts +1 -1
- package/dist-types/components/input-file/src/LionSelectedFileList.d.ts +1 -1
- package/dist-types/components/localize/src/LocalizeManager.d.ts +109 -112
- package/dist-types/components/localize/src/LocalizeManager.d.ts.map +1 -1
- package/dist-types/components/overlays/src/OverlayMixin.d.ts.map +1 -1
- package/dist-types/components/progress-indicator/src/LionProgressIndicator.d.ts +5 -0
- package/dist-types/components/progress-indicator/src/LionProgressIndicator.d.ts.map +1 -1
- package/dist-types/components/select-rich/src/LionSelectRich.d.ts +1 -1
- package/dist-types/components/steps/src/LionStep.d.ts +5 -0
- package/dist-types/components/steps/src/LionStep.d.ts.map +1 -1
- package/dist-types/components/steps/src/LionSteps.d.ts +5 -0
- package/dist-types/components/steps/src/LionSteps.d.ts.map +1 -1
- package/dist-types/components/switch/src/LionSwitch.d.ts +1 -1
- package/dist-types/components/tabs/src/LionTabs.d.ts +5 -0
- package/dist-types/components/tabs/src/LionTabs.d.ts.map +1 -1
- package/dist-types/components/tooltip/src/LionTooltip.d.ts +5 -0
- package/dist-types/components/tooltip/src/LionTooltip.d.ts.map +1 -1
- package/dist-types/tsconfig.tsbuildinfo +1 -1
- package/docs/components/checkbox-group/api-table.md +2 -2
- package/docs/components/checkbox-group/overview.md +2 -2
- package/docs/components/collapsible/overview.md +1 -1
- package/docs/components/combobox/overview.md +1 -1
- package/docs/components/combobox/use-cases.md +1 -1
- package/docs/components/dialog/overview.md +1 -1
- package/docs/components/fieldset/overview.md +5 -5
- package/docs/components/form/overview.md +3 -3
- package/docs/components/icon/use-cases.md +1 -1
- package/docs/components/input/api-table.md +2 -2
- package/docs/components/input/overview.md +1 -1
- package/docs/components/input-amount/api-table.md +2 -2
- package/docs/components/input-amount/overview.md +3 -3
- package/docs/components/input-date/api-table.md +2 -2
- package/docs/components/input-date/overview.md +3 -3
- package/docs/components/input-datepicker/api-table.md +2 -2
- package/docs/components/input-datepicker/overview.md +5 -5
- package/docs/components/input-email/api-table.md +2 -2
- package/docs/components/input-email/overview.md +2 -2
- package/docs/components/input-file/api-table.md +2 -2
- package/docs/components/input-file/overview.md +1 -1
- package/docs/components/input-iban/api-table.md +2 -2
- package/docs/components/input-iban/overview.md +2 -2
- package/docs/components/input-range/api-table.md +2 -2
- package/docs/components/input-range/overview.md +2 -2
- package/docs/components/input-stepper/api-table.md +2 -2
- package/docs/components/input-stepper/overview.md +1 -1
- package/docs/components/input-tel/api-table.md +2 -2
- package/docs/components/input-tel/overview.md +1 -1
- package/docs/components/input-tel/use-cases.md +6 -6
- package/docs/components/input-tel-dropdown/api-table.md +2 -2
- package/docs/components/input-tel-dropdown/overview.md +1 -1
- package/docs/components/listbox/api-table.md +1 -1
- package/docs/components/listbox/use-cases.md +1 -1
- package/docs/components/radio-group/api-table.md +2 -2
- package/docs/components/radio-group/overview.md +3 -3
- package/docs/components/select/api-table.md +2 -2
- package/docs/components/select/use-cases.md +1 -1
- package/docs/components/select-rich/api-table.md +1 -1
- package/docs/components/select-rich/use-cases.md +1 -1
- package/docs/components/switch/api-table.md +2 -2
- package/docs/components/tabs/examples.md +1 -1
- package/docs/components/textarea/api-table.md +2 -2
- package/docs/fundamentals/index.md +4 -4
- package/docs/fundamentals/node-tools/providence-analytics/LocalConfiguration.md +1 -1
- package/docs/fundamentals/node-tools/providence-analytics/QueryResult.md +1 -1
- package/docs/fundamentals/node-tools/providence-analytics/analyzer.md +1 -1
- package/docs/fundamentals/node-tools/providence-analytics/dashboard.md +1 -1
- package/docs/fundamentals/node-tools/providence-analytics/overview.md +3 -3
- package/docs/fundamentals/node-tools/publish-docs/overview.md +3 -3
- package/docs/fundamentals/node-tools/rocket-preset-extend-lion-docs/overview.md +2 -2
- package/docs/fundamentals/rationales/accessibility.md +1 -1
- package/docs/fundamentals/systems/core/SlotMixin.md +1 -1
- package/docs/fundamentals/systems/core/overview.md +1 -1
- package/docs/fundamentals/systems/form/api-table.md +1 -1
- package/docs/fundamentals/systems/form/formatting-and-parsing.md +4 -4
- package/docs/fundamentals/systems/form/model-value.md +1 -1
- package/docs/fundamentals/systems/form/overview.md +28 -28
- package/docs/fundamentals/systems/form/validate.md +2 -2
- package/docs/fundamentals/systems/localize/api-table.md +38 -40
- package/docs/fundamentals/systems/localize/overview.md +4 -4
- package/docs/fundamentals/systems/overlays/configuration.md +2 -2
- package/docs/fundamentals/systems/overlays/overview.md +5 -5
- package/docs/fundamentals/systems/overlays/use-cases.md +2 -2
- package/docs/fundamentals/tools/helpers/overview.md +1 -1
- package/docs/fundamentals/tools/singleton-manager/overview.md +4 -4
- package/docs/guides/how-to/create-a-custom-field.md +5 -5
- package/docs/guides/how-to/create-a-form.md +4 -4
- package/docs/guides/how-to/extend-a-native-input.md +2 -2
- package/docs/guides/index.md +8 -8
- package/docs/guides/principles/index.md +5 -5
- package/docs/guides/principles/styling.md +1 -1
- package/package.json +1 -1
|
@@ -75,6 +75,11 @@ export class LionCalendar extends LionCalendar_base {
|
|
|
75
75
|
};
|
|
76
76
|
};
|
|
77
77
|
static get styles(): import("lit").CSSResult[];
|
|
78
|
+
/**
|
|
79
|
+
* // TODO: check if this is a false positive or if we can improve
|
|
80
|
+
* @configure ReactiveElement
|
|
81
|
+
*/
|
|
82
|
+
static enabledWarnings: import("lit").WarningKind[];
|
|
78
83
|
/** @type {{months: Month[]}}
|
|
79
84
|
* @private
|
|
80
85
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LionCalendar.d.ts","sourceRoot":"","sources":["../../../../components/calendar/src/LionCalendar.js"],"names":[],"mappings":";AAoCA;;GAEG;AACH;IAkEE;QAEI;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;;WAGG;;;;QAGH;;;;WAIG;;;;QAGH;;;;WAIG;;;;QAGH;;;;;;WAMG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;MAGN;IA4CD,+CAEC;
|
|
1
|
+
{"version":3,"file":"LionCalendar.d.ts","sourceRoot":"","sources":["../../../../components/calendar/src/LionCalendar.js"],"names":[],"mappings":";AAoCA;;GAEG;AACH;IAkEE;QAEI;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;;WAGG;;;;QAGH;;;;WAIG;;;;QAGH;;;;WAIG;;;;QAGH;;;;;;WAMG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;QAGH;;WAEG;;;;MAGN;IA4CD,+CAEC;IA+JD;;;OAGG;IACH,oDAA4F;IA7M1F;;OAEG;IACH,eAA4B;IAC5B,cAA0B;IAE1B,cAAyC;IACzC,uBAAuB;IACvB,uBADY,GAAG,mCACkB;IAEjC,wBAAwB;IAExB,oBAFY,IAAI,aAEgB;IAEhC,uBAAuB;IACvB,8BAAoC;IACpC,eAAe;IACf,gBAA4C;IAC5C,mBAAmB;IACnB,aADW,IAAI,CACgB;IAC/B;;;OAGG;IACH,sBAAyB;IACzB,eAAe;IACf,gCAAoC;IACpC,eAAe;IACf,sBAA0B;IAC1B,eAAgB;IAChB,eAAe;IACf,uCAA+E;IAC/E,eAAe;IACf,mCAAuE;IACvE,eAAe;IACf,mCAAuE;IACvE,eAAe;IACf,kCAAsE;IAOxE,+CAMC;IAED,+BAEC;IAED,sBAEC;IAED,0BAEC;IAED,qBAEC;IAED,yBAEC;IAED;;OAEG;IACH,gBAFW,IAAI,iBAMd;IAED,yBAOC;IAED,mCAIC;IAED,mCAkCC;IATG,uDAEC;IAkBL,6BAaC;IAUD;;;;;OAKG;IACH,oDAJW,OAAO,sEAEL,IAAI,CAkBhB;IAED;;;OAGG;IACH,wBAOC;IAQD;;OAEG;IACH,sCASC;IAFC,mBAAmB;IACnB,uCAA4C;IAG9C;;;;OAIG;IACH,gCAkBC;IAED;;;;OAIG;IACH,+BAWC;IAED;;OAEG;IACH,2BAQC;IAED;;OAEG;IACH,qBAeC;IAED;;;;;OAKG;IACH,8BAiBC;IAED;;;;;OAKG;IACH,0BAiBC;IAED;;;;;OAKG;IAEH,uCANW,MAAM,iBACN,MAAM,gBACN,MAAM,wCA0BhB;IAGD,8DAEC;IAED;;;;;OAKG;IAEH,mCANW,MAAM,aACN,MAAM,YACN,MAAM,wCA0BhB;IAGD,0DAEC;IAED;;;;;;;OAOG;IACH,6BAEC;IAED;;;OAGG;IACH,iCAuBC;IAED;;;;;OAKG;IACH,8BA0CC;IAED;;;OAGG;IACH,qBAkBC;IAED;;;OAGG;IACH,6BAUC;IATC,+BAAgC;IAWlC;;OAEG;IACH,6BAIC;IAED;;;OAGG;IACH,mDAGC;IAED;;;OAGG;IACH,uDAGC;IAED;;;OAGG;IACH,sDAGC;IAED;;;OAGG;IACH,wBAGC;IAED;;;;;OAKG;IACH,iCAmCC;IAED;;;OAGG;IACH,8BAKC;IAED;;OAEG;IACH,8BASC;IAED;;OAEG;IACH,6BASC;IAED;;;OAGG;IACH,6BAIC;IAED;;;OAGG;IACH,kCAsDC;IAED;;;;;;;OAOG;IACH,qBAeC;IAED;;OAEG;IACH,oBAEC;CACF;kBAh6BY,OAAO,iBAAiB,EAAE,GAAG;mBAC7B,OAAO,iBAAiB,EAAE,IAAI;oBAC9B,OAAO,iBAAiB,EAAE,KAAK"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DisabledWithTabIndexMixin.d.ts","sourceRoot":"","sources":["../../../../components/core/src/DisabledWithTabIndexMixin.js"],"names":[],"mappings":"wCAIa,OAAO,4CAA4C,EAAE,yBAAyB;
|
|
1
|
+
{"version":3,"file":"DisabledWithTabIndexMixin.d.ts","sourceRoot":"","sources":["../../../../components/core/src/DisabledWithTabIndexMixin.js"],"names":[],"mappings":"wCAIa,OAAO,4CAA4C,EAAE,yBAAyB;AAuG3F,4IAA8F"}
|
|
@@ -1,15 +1,52 @@
|
|
|
1
1
|
/**
|
|
2
|
+
* @typedef {import('../../form-core/types/validate/ValidateMixinTypes.js').ScopedElementsMap} ScopedElementsMap
|
|
3
|
+
* @typedef {import('@open-wc/dedupe-mixin').Constructor<ScopedElementsHost>} ScopedElementsHostConstructor
|
|
4
|
+
* @typedef {import('@open-wc/scoped-elements/lit-element.js').ScopedElementsHost} ScopedElementsHost
|
|
5
|
+
* @typedef {import('./types.js').ScopedElementsHostV2Constructor} ScopedElementsHostV2Constructor
|
|
6
|
+
* @typedef {import('@open-wc/dedupe-mixin').Constructor<LitElement>} LitElementConstructor
|
|
7
|
+
* @typedef {import('lit').CSSResultOrNative} CSSResultOrNative
|
|
8
|
+
* @typedef {typeof import('lit').LitElement} TypeofLitElement
|
|
9
|
+
* @typedef {import('lit').LitElement} LitElement
|
|
10
|
+
*/
|
|
11
|
+
export function supportsScopedRegistry(): boolean;
|
|
12
|
+
/**
|
|
13
|
+
* This file is combination of '@open-wc/scoped-elements@v3/lit-element.js' and '@open-wc/scoped-elements@v3/html-element.js'.
|
|
14
|
+
* Then on top of those, some code from '@open-wc/scoped-elements@v2' is brought to to make polyfill not mandatory.
|
|
15
|
+
* This can be a great help for ssr scenarios, allowing elements to be consumed without needing knowledge about internall
|
|
16
|
+
* consumption.
|
|
17
|
+
* (N.B. at this point in time, this is limited to the scenario where there's one version of lion on the page).
|
|
18
|
+
*
|
|
19
|
+
* ## Considerations
|
|
20
|
+
* In its current state, the [scoped-custom-element-registry](https://github.com/webcomponents/polyfills/tree/master/packages/scoped-custom-element-registry) draft spec has uncertainties:
|
|
21
|
+
* - the spec is not yet final; it's not clear how long it will be dependent on a polyfill
|
|
22
|
+
* - the polyfill conflicts with new browser functionality (form-associated custom elements in Safari, ShadowRoot.createElement in Chrome Canary, etc.).
|
|
23
|
+
* - the spsc is not compatible with SSR and it remains unclear if it will be in the future
|
|
24
|
+
*
|
|
25
|
+
* Also see: https://github.com/webcomponents/polyfills/issues?q=scoped-custom-element-registry
|
|
26
|
+
*
|
|
27
|
+
* In previous considerations (last year), we betted on the spec to evolve quickly and the polyfill to be stable.
|
|
28
|
+
* Till this day, little progress has been made. In the meantime. @lit-labs/ssr (incompatible with the spec) is released as well.
|
|
29
|
+
*
|
|
30
|
+
* This file aims to achieve two things:
|
|
31
|
+
* = being up to date with the latest version of @open-wc/scoped-elements (v3)
|
|
32
|
+
* - make the impact of this change for lion as minimal as possible
|
|
33
|
+
*
|
|
34
|
+
* In order to achieve the latter, we keep the ability to opt out of the polyfill.
|
|
35
|
+
* This can be beneficial for performance, bundle size, ease of use and SSR capabilities.
|
|
36
|
+
*
|
|
37
|
+
* We will keep a close eye on developments in spec and polyfill, and will re-evaluate the scoped-elements approach when the time is right.
|
|
38
|
+
*
|
|
2
39
|
* @template {LitElementConstructor} T
|
|
3
40
|
* @param {T} superclass
|
|
4
41
|
* @return {T & ScopedElementsHostConstructor & ScopedElementsHostV2Constructor}
|
|
5
42
|
*/
|
|
6
|
-
export function ScopedElementsMixin<T extends
|
|
7
|
-
export type ScopedElementsHost = import('@open-wc/scoped-elements/lit-element.js').ScopedElementsHost;
|
|
43
|
+
export function ScopedElementsMixin<T extends import("@open-wc/dedupe-mixin").Constructor<import("lit").LitElement>>(superclass: T): T & import("@open-wc/dedupe-mixin").Constructor<import("../../../../../node_modules/@open-wc/scoped-elements/types.js").ScopedElementsHost> & import("./types.js").ScopedElementsHostV2Constructor;
|
|
8
44
|
export type ScopedElementsMap = import('../../form-core/types/validate/ValidateMixinTypes.js').ScopedElementsMap;
|
|
9
|
-
export type CSSResultOrNative = import('lit').CSSResultOrNative;
|
|
10
|
-
export type LitElement = import('lit').LitElement;
|
|
11
|
-
export type TypeofLitElement = typeof import('lit').LitElement;
|
|
12
|
-
export type LitElementConstructor = import('@open-wc/dedupe-mixin').Constructor<LitElement>;
|
|
13
45
|
export type ScopedElementsHostConstructor = import('@open-wc/dedupe-mixin').Constructor<ScopedElementsHost>;
|
|
46
|
+
export type ScopedElementsHost = import('@open-wc/scoped-elements/lit-element.js').ScopedElementsHost;
|
|
14
47
|
export type ScopedElementsHostV2Constructor = import('./types.js').ScopedElementsHostV2Constructor;
|
|
48
|
+
export type LitElementConstructor = import('@open-wc/dedupe-mixin').Constructor<LitElement>;
|
|
49
|
+
export type CSSResultOrNative = import('lit').CSSResultOrNative;
|
|
50
|
+
export type TypeofLitElement = typeof import('lit').LitElement;
|
|
51
|
+
export type LitElement = import('lit').LitElement;
|
|
15
52
|
//# sourceMappingURL=ScopedElementsMixin.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ScopedElementsMixin.d.ts","sourceRoot":"","sources":["../../../../components/core/src/ScopedElementsMixin.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ScopedElementsMixin.d.ts","sourceRoot":"","sources":["../../../../components/core/src/ScopedElementsMixin.js"],"names":[],"mappings":"AAIA;;;;;;;;;GASG;AAEH,kDAKC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,wUAiHG;gCAjKU,OAAO,sDAAsD,EAAE,iBAAiB;4CAChF,OAAO,uBAAuB,EAAE,WAAW,CAAC,kBAAkB,CAAC;iCAC/D,OAAO,yCAAyC,EAAE,kBAAkB;8CACpE,OAAO,YAAY,EAAE,+BAA+B;oCACpD,OAAO,uBAAuB,EAAE,WAAW,CAAC,UAAU,CAAC;gCACvD,OAAO,KAAK,EAAE,iBAAiB;+BAC/B,cAAc,KAAK,EAAE,UAAU;yBAC/B,OAAO,KAAK,EAAE,UAAU"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ScopedElementsMixin.test.d.ts","sourceRoot":"","sources":["../../../../components/core/test/ScopedElementsMixin.test.js"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ScopedElementsHost.define.d.ts","sourceRoot":"","sources":["../../../../../components/core/test/ssr-definitions/ScopedElementsHost.define.js"],"names":[],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LionForm.d.ts","sourceRoot":"","sources":["../../../../components/form/src/LionForm.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"LionForm.d.ts","sourceRoot":"","sources":["../../../../components/form/src/LionForm.js"],"names":[],"mappings":"AAYA;;;;GAIG;AAEH;IAoCE;;;OAGG;IACH,sBAHW,KAAK,QAYf;IAUD;;;OAGG;IACH,qBAHW,KAAK,QAQf;IA3DD,0BAMC;IAOD,iCAEC;IAED,eAQC;IAiBD,cAMC;IAaD;;;OAGG;IACH,wDAHW,iBAAiB,QAa3B;IAED,eAAe;IACf,oCAGC;IAED,eAAe;IACf,oCAGC;CACF;gCAhHY,OAAO,+DAA+D,EAAE,iBAAiB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lion-form.test.d.ts","sourceRoot":"","sources":["../../../../components/form/test/lion-form.test.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"lion-form.test.d.ts","sourceRoot":"","sources":["../../../../components/form/test/lion-form.test.js"],"names":[],"mappings":"uBAwBa,OAAO,oBAAoB,EAAE,QAAQ;6BACrC,OAAO,KAAK,EAAE,cAAc"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormControlMixin.d.ts","sourceRoot":"","sources":["../../../../components/form-core/src/FormControlMixin.js"],"names":[],"mappings":"+BAgBa,OAAO,mCAAmC,EAAE,gBAAgB;
|
|
1
|
+
{"version":3,"file":"FormControlMixin.d.ts","sourceRoot":"","sources":["../../../../components/form-core/src/FormControlMixin.js"],"names":[],"mappings":"+BAgBa,OAAO,mCAAmC,EAAE,gBAAgB;AA+7BzE,4GAA4E;6BAv8B/D,OAAO,KAAK,EAAE,cAAc;wBAC5B,OAAO,KAAK,EAAE,SAAS;6BACvB,OAAO,KAAK,EAAE,cAAc;uBAC5B,OAAO,oCAAoC,EAAE,QAAQ;qCACrD,OAAO,sCAAsC,EAAE,sBAAsB;8BACrE,OAAO,gDAAgD,EAAE,eAAe;8BACxE,OAAO,mCAAmC,EAAE,eAAe;mCAC3D,OAAO,mCAAmC,EAAE,oBAAoB;qCAEhE,OAAO,mCAAmC,EAAE,sBAAsB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SyncUpdatableMixin.d.ts","sourceRoot":"","sources":["../../../../../components/form-core/src/utils/SyncUpdatableMixin.js"],"names":[],"mappings":"iCAKa,OAAO,8CAA8C,EAAE,kBAAkB;
|
|
1
|
+
{"version":3,"file":"SyncUpdatableMixin.d.ts","sourceRoot":"","sources":["../../../../../components/form-core/src/utils/SyncUpdatableMixin.js"],"names":[],"mappings":"iCAKa,OAAO,8CAA8C,EAAE,kBAAkB;AA+ItF,2HAAgF;qCA9InE,OAAO,8CAA8C,EAAE,sBAAsB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LionValidationFeedback.d.ts","sourceRoot":"","sources":["../../../../../components/form-core/src/validate/LionValidationFeedback.js"],"names":[],"mappings":";AAeA;;;GAGG;AACH;IACE;;;;MAIC;IAED,qGAGE;IAEF,+CAiBC;IAED;;;;;;;OAOG;IAEH;QANiD,OAAO,EAA7C,MAAM,GAAG,IAAI,GAAG,cAAc;QAChB,IAAI;QACD,SAAS;uCAMpC;IASG,gCAA4C;IAK1C,kCAIQ;IAFN,gCAAgC;IAChC,iGAAsB;IAQ9B,+
|
|
1
|
+
{"version":3,"file":"LionValidationFeedback.d.ts","sourceRoot":"","sources":["../../../../../components/form-core/src/validate/LionValidationFeedback.js"],"names":[],"mappings":";AAeA;;;GAGG;AACH;IACE;;;;MAIC;IAED,qGAGE;IAEF,+CAiBC;IAED;;;;;;;OAOG;IAEH;QANiD,OAAO,EAA7C,MAAM,GAAG,IAAI,GAAG,cAAc;QAChB,IAAI;QACD,SAAS;uCAMpC;IASG,gCAA4C;IAK1C,kCAIQ;IAFN,gCAAgC;IAChC,iGAAsB;IAQ9B,+CAcC;CACF;wBAhGY,OAAO,gBAAgB,EAAE,SAAS;6BAClC,OAAO,KAAK,EAAE,cAAc;8BAC5B,OAAO,4CAA4C,EAAE,eAAe"}
|
|
@@ -13,7 +13,7 @@ export declare class FormRegisteringHost {
|
|
|
13
13
|
* do not pierce through shadow roots. This forces the developer to create form groups and fieldsets that
|
|
14
14
|
* automatically allow the creation of accessible relationships in the same dom tree.
|
|
15
15
|
* Use this option if you know what you're doing. It will then be possible to nest FormControls
|
|
16
|
-
* inside shadow dom. See https://lion
|
|
16
|
+
* inside shadow dom. See https://lion.js.org/fundamentals/rationales/accessibility#shadow-roots-and-accessibility
|
|
17
17
|
*/
|
|
18
18
|
allowCrossRootRegistration: boolean;
|
|
19
19
|
/**
|
|
@@ -5,15 +5,15 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* @param {LionForm} formGroupEl
|
|
7
7
|
*/
|
|
8
|
-
export function getAllFormElements(formGroupEl: LionForm): any;
|
|
8
|
+
export function getAllFormElements(formGroupEl: LionForm): any[];
|
|
9
9
|
/**
|
|
10
10
|
* @param {LionForm} formGroupEl
|
|
11
11
|
*/
|
|
12
|
-
export function getAllTagNames(formGroupEl: LionForm): any;
|
|
12
|
+
export function getAllTagNames(formGroupEl: LionForm): any[];
|
|
13
13
|
/**
|
|
14
14
|
* @param {LionForm} formGroupEl
|
|
15
15
|
*/
|
|
16
|
-
export function getAllFieldsAndFormGroups(formGroupEl: LionForm): any;
|
|
16
|
+
export function getAllFieldsAndFormGroups(formGroupEl: LionForm): any[];
|
|
17
17
|
export type LionForm = import('../../../form/src/LionForm.js').LionForm;
|
|
18
18
|
export type LionField = import('../../../form-core/src/LionField.js').LionField;
|
|
19
19
|
//# sourceMappingURL=helpers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../components/form-integrations/test/helpers/helpers.js"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,gDAFW,QAAQ,
|
|
1
|
+
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../components/form-integrations/test/helpers/helpers.js"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,gDAFW,QAAQ,SAWlB;AAED;;GAEG;AACH,4CAFW,QAAQ,SAWlB;AAED;;GAEG;AACH,uDAFW,QAAQ,SAKlB;uBAtCY,OAAO,+BAA+B,EAAE,QAAQ;wBAChD,OAAO,qCAAqC,EAAE,SAAS"}
|
|
@@ -29,6 +29,11 @@ export class LionIcon extends LitElement {
|
|
|
29
29
|
};
|
|
30
30
|
};
|
|
31
31
|
static get styles(): import("lit").CSSResult[];
|
|
32
|
+
/**
|
|
33
|
+
* TODO: check if this is a false positive or if we can improve
|
|
34
|
+
* @configure ReactiveElement
|
|
35
|
+
*/
|
|
36
|
+
static enabledWarnings: import("lit").WarningKind[];
|
|
32
37
|
ariaLabel: string;
|
|
33
38
|
iconId: string;
|
|
34
39
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LionIcon.d.ts","sourceRoot":"","sources":["../../../../components/icon/src/LionIcon.js"],"names":[],"mappings":"AA6BA;;GAEG;AACH;IACE;QAEI;;;WAGG;;;;QAIH;;;WAGG;;;;;;QAMH;;;WAGG;;;;;MAMN;IAED,+CA6BC;
|
|
1
|
+
{"version":3,"file":"LionIcon.d.ts","sourceRoot":"","sources":["../../../../components/icon/src/LionIcon.js"],"names":[],"mappings":"AA6BA;;GAEG;AACH;IACE;QAEI;;;WAGG;;;;QAIH;;;WAGG;;;;;;QAMH;;;WAGG;;;;;MAMN;IAED,+CA6BC;IAaD;;;OAGG;IACH,oDAA4F;IAb1F,kBAAmB;IACnB,eAAgB;IAChB;;;OAGG;IACH,cAAoB;IAqBtB,+CAEC;IASD;;;;OAIG;IACH,0FAOC;IAED;;OAEG;IACH,uFAEC;IAED,iBAAiB;IACjB,kCAOC;IAED;;;OAGG;IACH,gCAHW,cAAc,iBAAU,QASlC;IAED,iBAAiB;IAEjB,kCAEC;IAED;;;OAGG;IACH,uCAHW,MAAM,iBAyBhB;CACF;6BA5MY,OAAO,KAAK,EAAE,cAAc;0CACZ,oBAAoB,WAAY,MAAM,EAAE,KAAK,MAAM,KAAK,MAAM"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const LionInputDatepicker_base: typeof LionInputDate & import("@open-wc/dedupe-mixin").Constructor<import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost> & Pick<typeof import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost, "prototype" | "localizeNamespaces" | "waitForLocalizeNamespaces"> & Pick<typeof import("lit").LitElement, typeof Symbol.metadata | "prototype" | "_$litElement$" | "enabledWarnings" | "enableWarning" | "disableWarning" | "addInitializer" | "_initializers" | "elementProperties" | "properties" | "elementStyles" | "styles" | "observedAttributes" | "createProperty" | "getPropertyOptions" | "shadowRootOptions"> & import("@open-wc/dedupe-mixin").Constructor<import("../../overlays/types/OverlayMixinTypes.js").OverlayHost> & Pick<typeof import("../../overlays/types/OverlayMixinTypes.js").OverlayHost, "prototype"> & import("@open-wc/dedupe-mixin").Constructor<import("../../overlays/types/ArrowMixinTypes.js").ArrowHost> & Pick<typeof import("../../overlays/types/ArrowMixinTypes.js").ArrowHost, "prototype" | "properties" | "styles"> & import("
|
|
1
|
+
declare const LionInputDatepicker_base: typeof LionInputDate & import("@open-wc/dedupe-mixin").Constructor<import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost> & Pick<typeof import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost, "prototype" | "localizeNamespaces" | "waitForLocalizeNamespaces"> & Pick<typeof import("lit").LitElement, typeof Symbol.metadata | "prototype" | "_$litElement$" | "enabledWarnings" | "enableWarning" | "disableWarning" | "addInitializer" | "_initializers" | "elementProperties" | "properties" | "elementStyles" | "styles" | "observedAttributes" | "createProperty" | "getPropertyOptions" | "shadowRootOptions"> & import("@open-wc/dedupe-mixin").Constructor<import("../../overlays/types/OverlayMixinTypes.js").OverlayHost> & Pick<typeof import("../../overlays/types/OverlayMixinTypes.js").OverlayHost, "prototype"> & import("@open-wc/dedupe-mixin").Constructor<import("../../overlays/types/ArrowMixinTypes.js").ArrowHost> & Pick<typeof import("../../overlays/types/ArrowMixinTypes.js").ArrowHost, "prototype" | "properties" | "styles"> & import("@open-wc/dedupe-mixin").Constructor<import("../../../../../node_modules/@open-wc/scoped-elements/types.js").ScopedElementsHost> & import("../../core/src/types.js").ScopedElementsHostV2Constructor;
|
|
2
2
|
/**
|
|
3
3
|
* @typedef {import('../../form-core/src/validate/Validator.js').Validator} Validator
|
|
4
4
|
* @typedef {import('lit').RenderOptions} RenderOptions
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const LionInputFile_base: typeof LionField & import("@open-wc/dedupe-mixin").Constructor<import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost> & Pick<typeof import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost, "prototype" | "localizeNamespaces" | "waitForLocalizeNamespaces"> & Pick<typeof import("lit").LitElement, typeof Symbol.metadata | "prototype" | "_$litElement$" | "enabledWarnings" | "enableWarning" | "disableWarning" | "addInitializer" | "_initializers" | "elementProperties" | "properties" | "elementStyles" | "styles" | "observedAttributes" | "createProperty" | "getPropertyOptions" | "shadowRootOptions"> & import("
|
|
1
|
+
declare const LionInputFile_base: typeof LionField & import("@open-wc/dedupe-mixin").Constructor<import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost> & Pick<typeof import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost, "prototype" | "localizeNamespaces" | "waitForLocalizeNamespaces"> & Pick<typeof import("lit").LitElement, typeof Symbol.metadata | "prototype" | "_$litElement$" | "enabledWarnings" | "enableWarning" | "disableWarning" | "addInitializer" | "_initializers" | "elementProperties" | "properties" | "elementStyles" | "styles" | "observedAttributes" | "createProperty" | "getPropertyOptions" | "shadowRootOptions"> & import("@open-wc/dedupe-mixin").Constructor<import("../../../../../node_modules/@open-wc/scoped-elements/types.js").ScopedElementsHost> & import("../../core/src/types.js").ScopedElementsHostV2Constructor;
|
|
2
2
|
export class LionInputFile extends LionInputFile_base {
|
|
3
3
|
static get scopedElements(): {
|
|
4
4
|
'lion-selected-file-list': typeof LionSelectedFileList;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const LionSelectedFileList_base: typeof LitElement & import("
|
|
1
|
+
declare const LionSelectedFileList_base: typeof LitElement & import("@open-wc/dedupe-mixin").Constructor<import("../../../../../node_modules/@open-wc/scoped-elements/types.js").ScopedElementsHost> & import("../../core/src/types.js").ScopedElementsHostV2Constructor & import("@open-wc/dedupe-mixin").Constructor<import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost> & Pick<typeof import("../../localize/types/LocalizeMixinTypes.js").LocalizeMixinHost, "prototype" | "localizeNamespaces" | "waitForLocalizeNamespaces"> & Pick<typeof LitElement, typeof Symbol.metadata | "prototype" | "_$litElement$" | "enabledWarnings" | "enableWarning" | "disableWarning" | "addInitializer" | "_initializers" | "elementProperties" | "properties" | "elementStyles" | "styles" | "observedAttributes" | "createProperty" | "getPropertyOptions" | "shadowRootOptions">;
|
|
2
2
|
/**
|
|
3
3
|
* @typedef {import('lit').TemplateResult} TemplateResult
|
|
4
4
|
* @typedef {import('../types/input-file.js').InputFile} InputFile
|
|
@@ -1,112 +1,71 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @typedef {import('../types/LocalizeMixinTypes.js').NamespaceObject} NamespaceObject
|
|
3
|
-
*/
|
|
4
|
-
/** @typedef {import('../types/LocalizeMixinTypes.js').DatePostProcessor} DatePostProcessor */
|
|
5
|
-
/** @typedef {import('../types/LocalizeMixinTypes.js').NumberPostProcessor} NumberPostProcessor */
|
|
6
1
|
/**
|
|
7
2
|
* `LocalizeManager` manages your translations (includes loading)
|
|
8
3
|
*/
|
|
9
|
-
export class LocalizeManager {
|
|
10
|
-
constructor({
|
|
4
|
+
export class LocalizeManager extends EventTarget {
|
|
5
|
+
constructor({ allowOverridesForExistingNamespaces, autoLoadOnLocaleChange, showKeyAsFallback, fallbackLocale, }?: {
|
|
6
|
+
allowOverridesForExistingNamespaces?: boolean | undefined;
|
|
11
7
|
autoLoadOnLocaleChange?: boolean | undefined;
|
|
12
|
-
fallbackLocale?: string | undefined;
|
|
13
8
|
showKeyAsFallback?: boolean | undefined;
|
|
14
|
-
|
|
9
|
+
fallbackLocale?: string | undefined;
|
|
15
10
|
});
|
|
16
|
-
/** @private */
|
|
17
|
-
private __delegationTarget;
|
|
18
|
-
/** @protected */
|
|
19
|
-
protected _autoLoadOnLocaleChange: boolean;
|
|
20
|
-
/** @protected */
|
|
21
|
-
protected _fallbackLocale: string;
|
|
22
|
-
/** @protected */
|
|
23
|
-
protected _showKeyAsFallback: boolean;
|
|
24
|
-
/** @private */
|
|
25
|
-
private __allowOverridesForExistingNamespaces;
|
|
26
11
|
/**
|
|
27
|
-
*
|
|
12
|
+
* The localize system uses (normalized) Intl for formatting numbers.
|
|
13
|
+
* It's possible to customize this output per locale
|
|
14
|
+
*/
|
|
15
|
+
formatNumberOptions: {
|
|
16
|
+
returnIfNaN: string;
|
|
17
|
+
/** @type {Map<string, NumberPostProcessor>} */
|
|
18
|
+
postProcessors: Map<string, NumberPostProcessor>;
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* The localize system uses (normalized) Intl for formatting dates.
|
|
22
|
+
* It's possible to customize this output per locale
|
|
23
|
+
*/
|
|
24
|
+
formatDateOptions: {
|
|
25
|
+
/** @type {Map<string, DatePostProcessor>} */
|
|
26
|
+
postProcessors: Map<string, DatePostProcessor>;
|
|
27
|
+
};
|
|
28
|
+
/**
|
|
29
|
+
* @type {Object<string, Object<string, Object>>}
|
|
28
30
|
* @private
|
|
29
31
|
*/
|
|
30
32
|
private __storage;
|
|
31
33
|
/**
|
|
32
|
-
* @type {Map
|
|
34
|
+
* @type {Map<RegExp|string, function>}
|
|
33
35
|
* @private
|
|
34
36
|
*/
|
|
35
37
|
private __namespacePatternsMap;
|
|
36
38
|
/**
|
|
37
|
-
* @type {Object
|
|
39
|
+
* @type {Object<string, function|null>}
|
|
38
40
|
* @private
|
|
39
41
|
*/
|
|
40
42
|
private __namespaceLoadersCache;
|
|
41
43
|
/**
|
|
42
|
-
* @type {Object
|
|
44
|
+
* @type {Object<string, Object<string, Promise<Object|void>>>}
|
|
43
45
|
* @private
|
|
44
46
|
*/
|
|
45
47
|
private __namespaceLoaderPromisesCache;
|
|
46
|
-
formatNumberOptions: {
|
|
47
|
-
returnIfNaN: string;
|
|
48
|
-
/** @type {Map<string,DatePostProcessor>} */
|
|
49
|
-
postProcessors: Map<string, DatePostProcessor>;
|
|
50
|
-
};
|
|
51
|
-
formatDateOptions: {
|
|
52
|
-
/** @type {Map<string,DatePostProcessor>} */
|
|
53
|
-
postProcessors: Map<string, DatePostProcessor>;
|
|
54
|
-
};
|
|
55
|
-
/** @protected */
|
|
56
|
-
protected _supportExternalTranslationTools: boolean;
|
|
57
48
|
/**
|
|
58
|
-
* @param {string}
|
|
49
|
+
* @param {string} newLocale
|
|
59
50
|
*/
|
|
60
51
|
set locale(arg: string);
|
|
61
52
|
/**
|
|
62
53
|
* @returns {string}
|
|
63
54
|
*/
|
|
64
55
|
get locale(): string;
|
|
65
|
-
/** @protected */
|
|
66
|
-
protected _setupTranslationToolSupport(): void;
|
|
67
|
-
/**
|
|
68
|
-
* This value allows for support for Google Translate (or other 3rd parties taking control
|
|
69
|
-
* of the html[lang] attribute).
|
|
70
|
-
*
|
|
71
|
-
* Have the following scenario in mind:
|
|
72
|
-
* 1. locale is initialized by developer via html[data-localize-lang="en-US"] and
|
|
73
|
-
* html[lang="en-US"]. When localize is loaded (note that this also can be after step 2 below),
|
|
74
|
-
* it will sync its initial state from html[data-localize-lang]
|
|
75
|
-
* 2. Google Translate kicks in for the French language. It will set html[lang="fr"].
|
|
76
|
-
* This new language is not one known by us, so we most likely don't have translations for
|
|
77
|
-
* this file. Therefore, we do NOT sync this value to LocalizeManager. The manager should
|
|
78
|
-
* still ask for known resources (in this case for locale 'en-US')
|
|
79
|
-
* 3. locale is changed (think of a language dropdown)
|
|
80
|
-
* It's a bit of a weird case, because we would not expect an end user to do this. If he/she
|
|
81
|
-
* does, make sure that we do not go against Google Translate, so we maintain accessibility
|
|
82
|
-
* (by not altering html[lang]). We detect this by reading _langAttrSetByTranslationTool:
|
|
83
|
-
* when its value is null, we consider Google translate 'not active'.
|
|
84
|
-
*
|
|
85
|
-
* When Google Translate is turned off by the user (html[lang=auto]),
|
|
86
|
-
* `localize.locale` will be synced to html[lang] again
|
|
87
|
-
*
|
|
88
|
-
* Keep in mind that all of the above also works with other tools than Google Translate,
|
|
89
|
-
* but this is the most widely used tool and therefore used as an example.
|
|
90
|
-
*/
|
|
91
|
-
_langAttrSetByTranslationTool: string | null | undefined;
|
|
92
|
-
teardown(): void;
|
|
93
|
-
__locale: string | undefined;
|
|
94
|
-
/**
|
|
95
|
-
* @param {string} locale
|
|
96
|
-
* @protected
|
|
97
|
-
*/
|
|
98
|
-
protected _setHtmlLangAttribute(locale: string): void;
|
|
99
56
|
/**
|
|
100
|
-
* @
|
|
101
|
-
* @
|
|
102
|
-
* @private
|
|
57
|
+
* @readonly
|
|
58
|
+
* @returns {Promise<Object|void>}
|
|
103
59
|
*/
|
|
104
|
-
|
|
105
|
-
/**
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
60
|
+
readonly get loadingComplete(): Promise<void | Object>;
|
|
61
|
+
/** @private */
|
|
62
|
+
private __allowOverridesForExistingNamespaces;
|
|
63
|
+
/** @protected */
|
|
64
|
+
protected _autoLoadOnLocaleChange: boolean;
|
|
65
|
+
/** @protected */
|
|
66
|
+
protected _showKeyAsFallback: boolean;
|
|
67
|
+
/** @protected */
|
|
68
|
+
protected _fallbackLocale: string;
|
|
110
69
|
/**
|
|
111
70
|
* @param {string} locale
|
|
112
71
|
* @param {string} namespace
|
|
@@ -124,7 +83,7 @@ export class LocalizeManager {
|
|
|
124
83
|
* @param {NamespaceObject[]} namespaces
|
|
125
84
|
* @param {Object} options
|
|
126
85
|
* @param {string} [options.locale]
|
|
127
|
-
* @returns {Promise
|
|
86
|
+
* @returns {Promise<Object>}
|
|
128
87
|
*/
|
|
129
88
|
loadNamespaces(namespaces: NamespaceObject[], { locale }?: {
|
|
130
89
|
locale?: string | undefined;
|
|
@@ -133,14 +92,14 @@ export class LocalizeManager {
|
|
|
133
92
|
* @param {NamespaceObject} namespaceObj
|
|
134
93
|
* @param {Object} options
|
|
135
94
|
* @param {string} [options.locale]
|
|
136
|
-
* @returns {Promise
|
|
95
|
+
* @returns {Promise<Object|void>}
|
|
137
96
|
*/
|
|
138
97
|
loadNamespace(namespaceObj: NamespaceObject, { locale }?: {
|
|
139
98
|
locale?: string | undefined;
|
|
140
99
|
}): Promise<Object | void>;
|
|
141
100
|
/**
|
|
142
101
|
* @param {string | string[]} keys
|
|
143
|
-
* @param {Object
|
|
102
|
+
* @param {Object<string,?>} [vars]
|
|
144
103
|
* @param {Object} [opts]
|
|
145
104
|
* @param {string} [opts.locale]
|
|
146
105
|
* @returns {string}
|
|
@@ -150,6 +109,53 @@ export class LocalizeManager {
|
|
|
150
109
|
} | undefined, opts?: {
|
|
151
110
|
locale?: string | undefined;
|
|
152
111
|
} | undefined): string;
|
|
112
|
+
teardown(): void;
|
|
113
|
+
reset(): void;
|
|
114
|
+
/**
|
|
115
|
+
* @param {{locale:string, postProcessor:DatePostProcessor}} options
|
|
116
|
+
*/
|
|
117
|
+
setDatePostProcessorForLocale({ locale, postProcessor }: {
|
|
118
|
+
locale: string;
|
|
119
|
+
postProcessor: DatePostProcessor;
|
|
120
|
+
}): void;
|
|
121
|
+
/**
|
|
122
|
+
* @param {{locale:string, postProcessor:NumberPostProcessor}} options
|
|
123
|
+
*/
|
|
124
|
+
setNumberPostProcessorForLocale({ locale, postProcessor }: {
|
|
125
|
+
locale: string;
|
|
126
|
+
postProcessor: NumberPostProcessor;
|
|
127
|
+
}): void;
|
|
128
|
+
/**
|
|
129
|
+
* This value allows for support for Google Translate (or other 3rd parties taking control
|
|
130
|
+
* of the html[lang] attribute).
|
|
131
|
+
*
|
|
132
|
+
* Have the following scenario in mind:
|
|
133
|
+
* 1. locale is initialized by developer via html[data-localize-lang="en-US"] and
|
|
134
|
+
* html[lang="en-US"]. When localize is loaded (note that this also can be after step 2 below),
|
|
135
|
+
* it will sync its initial state from html[data-localize-lang]
|
|
136
|
+
* 2. Google Translate kicks in for the French language. It will set html[lang="fr"].
|
|
137
|
+
* This new language is not one known by us, so we most likely don't have translations for
|
|
138
|
+
* this file. Therefore, we do NOT sync this value to LocalizeManager. The manager should
|
|
139
|
+
* still ask for known resources (in this case for locale 'en-US')
|
|
140
|
+
* 3. locale is changed (think of a language dropdown)
|
|
141
|
+
* It's a bit of a weird case, because we would not expect an end user to do this. If he/she
|
|
142
|
+
* does, make sure that we do not go against Google Translate, so we maintain accessibility
|
|
143
|
+
* (by not altering html[lang]). We detect this by reading #localeSetByTranslationTool:
|
|
144
|
+
* when its value is null, we consider Google translate 'not active'.
|
|
145
|
+
*
|
|
146
|
+
* When Google Translate is turned off by the user (html[lang=auto]),
|
|
147
|
+
* `localize.locale` will be synced to html[lang] again
|
|
148
|
+
*
|
|
149
|
+
* Keep in mind that all of the above also works with other tools than Google Translate,
|
|
150
|
+
* but this is the most widely used tool and therefore used as an example.
|
|
151
|
+
* @protected
|
|
152
|
+
*/
|
|
153
|
+
protected _setupTranslationToolSupport(): void;
|
|
154
|
+
/**
|
|
155
|
+
* @param {string} locale
|
|
156
|
+
* @protected
|
|
157
|
+
*/
|
|
158
|
+
protected _setHtmlLangAttribute(locale: string): void;
|
|
153
159
|
/** @protected */
|
|
154
160
|
protected _setupHtmlLangAttributeObserver(): void;
|
|
155
161
|
_htmlLangAttributeObserver: MutationObserver | undefined;
|
|
@@ -172,7 +178,7 @@ export class LocalizeManager {
|
|
|
172
178
|
* @param {NamespaceObject} namespaceObj
|
|
173
179
|
* @param {boolean} isDynamicImport
|
|
174
180
|
* @param {string} namespace
|
|
175
|
-
* @returns {Promise
|
|
181
|
+
* @returns {Promise<Object|void>}
|
|
176
182
|
* @protected
|
|
177
183
|
*/
|
|
178
184
|
protected _loadNamespaceData(locale: string, namespaceObj: NamespaceObject, isDynamicImport: boolean, namespace: string): Promise<Object | void>;
|
|
@@ -189,7 +195,7 @@ export class LocalizeManager {
|
|
|
189
195
|
* @param {string} locale
|
|
190
196
|
* @param {string} namespace
|
|
191
197
|
* @param {string} [fallbackLocale]
|
|
192
|
-
* @returns {Promise
|
|
198
|
+
* @returns {Promise<any>}
|
|
193
199
|
* @throws {Error} Data for namespace and (locale or fallback locale) could not be loaded.
|
|
194
200
|
* @protected
|
|
195
201
|
*/
|
|
@@ -197,7 +203,7 @@ export class LocalizeManager {
|
|
|
197
203
|
/**
|
|
198
204
|
* @param {string} locale
|
|
199
205
|
* @param {string} namespace
|
|
200
|
-
* @param {Promise
|
|
206
|
+
* @param {Promise<Object|void>} promise
|
|
201
207
|
* @protected
|
|
202
208
|
*/
|
|
203
209
|
protected _cacheNamespaceLoaderPromise(locale: string, namespace: string, promise: Promise<Object | void>): void;
|
|
@@ -213,22 +219,6 @@ export class LocalizeManager {
|
|
|
213
219
|
* @protected
|
|
214
220
|
*/
|
|
215
221
|
protected _getLangFromLocale(locale: string): string;
|
|
216
|
-
/**
|
|
217
|
-
* @param {string} type
|
|
218
|
-
* @param {EventListener} listener
|
|
219
|
-
* @param {...Object} options
|
|
220
|
-
*/
|
|
221
|
-
addEventListener(type: string, listener: EventListener, ...options: Object[]): void;
|
|
222
|
-
/**
|
|
223
|
-
* @param {string} type
|
|
224
|
-
* @param {EventListener} listener
|
|
225
|
-
* @param {...Object} options
|
|
226
|
-
*/
|
|
227
|
-
removeEventListener(type: string, listener: EventListener, ...options: Object[]): void;
|
|
228
|
-
/**
|
|
229
|
-
* @param {CustomEvent} event
|
|
230
|
-
*/
|
|
231
|
-
dispatchEvent(event: CustomEvent): void;
|
|
232
222
|
/**
|
|
233
223
|
* @param {string} newLocale
|
|
234
224
|
* @param {string} oldLocale
|
|
@@ -259,21 +249,28 @@ export class LocalizeManager {
|
|
|
259
249
|
*/
|
|
260
250
|
protected _getMessageForKey(key: string | undefined, locale: string): string;
|
|
261
251
|
/**
|
|
262
|
-
* @
|
|
252
|
+
* @deprecated
|
|
253
|
+
* @protected
|
|
263
254
|
*/
|
|
264
|
-
|
|
265
|
-
locale: string;
|
|
266
|
-
postProcessor: DatePostProcessor;
|
|
267
|
-
}): void;
|
|
255
|
+
protected set _supportExternalTranslationTools(arg: boolean);
|
|
268
256
|
/**
|
|
269
|
-
* @
|
|
257
|
+
* @deprecated
|
|
258
|
+
* @protected
|
|
270
259
|
*/
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
260
|
+
protected get _supportExternalTranslationTools(): boolean;
|
|
261
|
+
/**
|
|
262
|
+
* @deprecated
|
|
263
|
+
* @protected
|
|
264
|
+
*/
|
|
265
|
+
protected set _langAttrSetByTranslationTool(arg: string);
|
|
266
|
+
/**
|
|
267
|
+
* @deprecated
|
|
268
|
+
* @protected
|
|
269
|
+
*/
|
|
270
|
+
protected get _langAttrSetByTranslationTool(): string;
|
|
271
|
+
#private;
|
|
275
272
|
}
|
|
276
|
-
export type NamespaceObject = import('../types/LocalizeMixinTypes.js').NamespaceObject;
|
|
277
|
-
export type DatePostProcessor = import('../types/LocalizeMixinTypes.js').DatePostProcessor;
|
|
278
273
|
export type NumberPostProcessor = import('../types/LocalizeMixinTypes.js').NumberPostProcessor;
|
|
274
|
+
export type DatePostProcessor = import('../types/LocalizeMixinTypes.js').DatePostProcessor;
|
|
275
|
+
export type NamespaceObject = import('../types/LocalizeMixinTypes.js').NamespaceObject;
|
|
279
276
|
//# sourceMappingURL=LocalizeManager.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LocalizeManager.d.ts","sourceRoot":"","sources":["../../../../components/localize/src/LocalizeManager.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"LocalizeManager.d.ts","sourceRoot":"","sources":["../../../../components/localize/src/LocalizeManager.js"],"names":[],"mappings":"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"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OverlayMixin.d.ts","sourceRoot":"","sources":["../../../../components/overlays/src/OverlayMixin.js"],"names":[],"mappings":"AAIA;;;;GAIG;AAEH;;;GAGG;AACH,yCAHU,YAAY,
|
|
1
|
+
{"version":3,"file":"OverlayMixin.d.ts","sourceRoot":"","sources":["../../../../components/overlays/src/OverlayMixin.js"],"names":[],"mappings":"AAIA;;;;GAIG;AAEH;;;GAGG;AACH,yCAHU,YAAY,CA0XlB;2BA9XS,OAAO,+BAA+B,EAAE,YAAY;AA+XjE,gGAAoE;4BAjYvD,OAAO,2BAA2B,EAAE,aAAa;kCACjD,OAAO,+BAA+B,EAAE,mBAAmB"}
|
|
@@ -25,6 +25,11 @@ export class LionProgressIndicator extends LionProgressIndicator_base {
|
|
|
25
25
|
static get localizeNamespaces(): {
|
|
26
26
|
'lion-progress-indicator': (locale: string) => Promise<typeof import("../translations/bg.js")>;
|
|
27
27
|
}[];
|
|
28
|
+
/**
|
|
29
|
+
* // TODO: check if this is a false positive or if we can improve
|
|
30
|
+
* @configure ReactiveElement
|
|
31
|
+
*/
|
|
32
|
+
static enabledWarnings: import("lit").WarningKind[];
|
|
28
33
|
/**
|
|
29
34
|
* @readonly
|
|
30
35
|
* @type {boolean}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LionProgressIndicator.d.ts","sourceRoot":"","sources":["../../../../components/progress-indicator/src/LionProgressIndicator.js"],"names":[],"mappings":";AAIA;;GAEG;AACH;IACE;;;;;;;;;;;;;;;;;;MAcC;IAED;4CAG6C,MAAM;QA0DlD;
|
|
1
|
+
{"version":3,"file":"LionProgressIndicator.d.ts","sourceRoot":"","sources":["../../../../components/progress-indicator/src/LionProgressIndicator.js"],"names":[],"mappings":";AAIA;;GAEG;AACH;IACE;;;;;;;;;;;;;;;;;;MAcC;IAED;4CAG6C,MAAM;QA0DlD;IAUD;;;OAGG;IACH,oDAA4F;IAZ5F;;;OAGG;IACH,sCAEC;IAQD;;;;;;;OAOG;IACH,8CAKC;IAIC,cAAc;IACd,YAAY;IACZ,YAAc;IACd,mBAAoB;IACpB,wBAAyB;IACzB,8BAAiC;IAGnC,iBAAiB;IAEjB,qCAEC;IAED,iBAEC;IAED,0BAGC;IAyDD,kCAIC;IAED,yBAQC;CACF;6BA9MY,OAAO,KAAK,EAAE,cAAc"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const LionSelectRich_base: typeof LionListbox & import("@open-wc/dedupe-mixin").Constructor<import("../../overlays/types/OverlayMixinTypes.js").OverlayHost> & Pick<typeof import("../../overlays/types/OverlayMixinTypes.js").OverlayHost, "prototype"> & Pick<typeof import("lit").LitElement, typeof Symbol.metadata | "prototype" | "_$litElement$" | "enabledWarnings" | "enableWarning" | "disableWarning" | "addInitializer" | "_initializers" | "elementProperties" | "properties" | "elementStyles" | "styles" | "observedAttributes" | "createProperty" | "getPropertyOptions" | "shadowRootOptions"> & import("
|
|
1
|
+
declare const LionSelectRich_base: typeof LionListbox & import("@open-wc/dedupe-mixin").Constructor<import("../../overlays/types/OverlayMixinTypes.js").OverlayHost> & Pick<typeof import("../../overlays/types/OverlayMixinTypes.js").OverlayHost, "prototype"> & Pick<typeof import("lit").LitElement, typeof Symbol.metadata | "prototype" | "_$litElement$" | "enabledWarnings" | "enableWarning" | "disableWarning" | "addInitializer" | "_initializers" | "elementProperties" | "properties" | "elementStyles" | "styles" | "observedAttributes" | "createProperty" | "getPropertyOptions" | "shadowRootOptions"> & import("@open-wc/dedupe-mixin").Constructor<import("../../../../../node_modules/@open-wc/scoped-elements/types.js").ScopedElementsHost> & import("../../core/src/types.js").ScopedElementsHostV2Constructor & import("@open-wc/dedupe-mixin").Constructor<import("../../core/types/SlotMixinTypes.js").SlotHost> & Pick<typeof import("../../core/types/SlotMixinTypes.js").SlotHost, "prototype">;
|
|
2
2
|
/**
|
|
3
3
|
* LionSelectRich: wraps the <lion-listbox> element
|
|
4
4
|
*/
|
|
@@ -52,6 +52,11 @@ export class LionStep extends LitElement {
|
|
|
52
52
|
};
|
|
53
53
|
};
|
|
54
54
|
static get styles(): import("lit").CSSResult[];
|
|
55
|
+
/**
|
|
56
|
+
* // TODO: check if this is a false positive or if we can improve
|
|
57
|
+
* @configure ReactiveElement
|
|
58
|
+
*/
|
|
59
|
+
static enabledWarnings: import("lit").WarningKind[];
|
|
55
60
|
status: string;
|
|
56
61
|
condition: (data?: Object | undefined) => boolean;
|
|
57
62
|
invertCondition: boolean;
|