@lion/ui 0.7.8 → 0.7.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.
Files changed (80) hide show
  1. package/components/accordion/src/LionAccordion.js +22 -16
  2. package/components/accordion/test/lion-accordion.test.js +75 -24
  3. package/components/validate-messages/translations/cs.js +4 -4
  4. package/components/validate-messages/translations/es.js +2 -2
  5. package/components/validate-messages/translations/hu.js +2 -2
  6. package/components/validate-messages/translations/it.js +2 -2
  7. package/components/validate-messages/translations/nl.js +2 -2
  8. package/components/validate-messages/translations/pl.js +2 -2
  9. package/components/validate-messages/translations/ru.js +2 -2
  10. package/components/validate-messages/translations/sk.js +2 -2
  11. package/components/validate-messages/translations/uk.js +2 -2
  12. package/custom-elements.json +51 -31
  13. package/dist-types/components/accordion/src/LionAccordion.d.ts +11 -1
  14. package/dist-types/components/accordion/src/LionAccordion.d.ts.map +1 -1
  15. package/dist-types/tsconfig.tsbuildinfo +1 -1
  16. package/docs/components/accordion/api-table.md +6 -4
  17. package/docs/components/accordion/use-cases.md +43 -4
  18. package/docs/components/checkbox-group/overview.md +2 -2
  19. package/docs/components/checkbox-group/use-cases.md +20 -59
  20. package/docs/components/collapsible/overview.md +1 -1
  21. package/docs/components/combobox/overview.md +1 -1
  22. package/docs/components/combobox/use-cases.md +1 -1
  23. package/docs/components/dialog/overview.md +1 -1
  24. package/docs/components/fieldset/overview.md +5 -5
  25. package/docs/components/fieldset/use-cases.md +9 -2
  26. package/docs/components/form/overview.md +3 -3
  27. package/docs/components/form/use-cases.md +2 -1
  28. package/docs/components/icon/use-cases.md +1 -1
  29. package/docs/components/input/overview.md +1 -1
  30. package/docs/components/input-amount/overview.md +3 -3
  31. package/docs/components/input-amount/use-cases.md +2 -2
  32. package/docs/components/input-date/overview.md +3 -3
  33. package/docs/components/input-date/use-cases.md +3 -1
  34. package/docs/components/input-datepicker/overview.md +5 -5
  35. package/docs/components/input-email/overview.md +2 -2
  36. package/docs/components/input-file/overview.md +1 -1
  37. package/docs/components/input-iban/overview.md +2 -2
  38. package/docs/components/input-range/overview.md +2 -2
  39. package/docs/components/input-stepper/overview.md +1 -1
  40. package/docs/components/input-tel/overview.md +1 -1
  41. package/docs/components/input-tel/use-cases.md +6 -6
  42. package/docs/components/input-tel-dropdown/overview.md +1 -1
  43. package/docs/components/listbox/use-cases.md +1 -1
  44. package/docs/components/pagination/use-cases.md +3 -1
  45. package/docs/components/radio-group/overview.md +3 -3
  46. package/docs/components/select/use-cases.md +1 -1
  47. package/docs/components/select-rich/use-cases.md +1 -1
  48. package/docs/components/steps/overview.md +6 -2
  49. package/docs/components/steps/use-cases.md +9 -3
  50. package/docs/components/tabs/examples.md +1 -1
  51. package/docs/fundamentals/index.md +4 -4
  52. package/docs/fundamentals/node-tools/providence-analytics/LocalConfiguration.md +1 -1
  53. package/docs/fundamentals/node-tools/providence-analytics/QueryResult.md +1 -1
  54. package/docs/fundamentals/node-tools/providence-analytics/analyzer.md +1 -1
  55. package/docs/fundamentals/node-tools/providence-analytics/dashboard.md +1 -1
  56. package/docs/fundamentals/node-tools/providence-analytics/overview.md +3 -3
  57. package/docs/fundamentals/node-tools/publish-docs/overview.md +3 -3
  58. package/docs/fundamentals/node-tools/rocket-preset-extend-lion-docs/overview.md +2 -2
  59. package/docs/fundamentals/rationales/accessibility.md +1 -1
  60. package/docs/fundamentals/systems/core/SlotMixin.md +1 -1
  61. package/docs/fundamentals/systems/core/overview.md +1 -1
  62. package/docs/fundamentals/systems/form/formatting-and-parsing.md +4 -4
  63. package/docs/fundamentals/systems/form/model-value.md +1 -1
  64. package/docs/fundamentals/systems/form/overview.md +28 -28
  65. package/docs/fundamentals/systems/form/use-cases.md +2 -1
  66. package/docs/fundamentals/systems/form/validate.md +2 -2
  67. package/docs/fundamentals/systems/localize/overview.md +4 -4
  68. package/docs/fundamentals/systems/localize/use-cases.md +3 -1
  69. package/docs/fundamentals/systems/overlays/configuration.md +2 -2
  70. package/docs/fundamentals/systems/overlays/overview.md +5 -5
  71. package/docs/fundamentals/systems/overlays/use-cases.md +5 -3
  72. package/docs/fundamentals/tools/helpers/overview.md +1 -1
  73. package/docs/fundamentals/tools/singleton-manager/overview.md +4 -4
  74. package/docs/guides/how-to/create-a-custom-field.md +5 -5
  75. package/docs/guides/how-to/create-a-form.md +4 -4
  76. package/docs/guides/how-to/extend-a-native-input.md +2 -2
  77. package/docs/guides/index.md +8 -8
  78. package/docs/guides/principles/index.md +5 -5
  79. package/docs/guides/principles/styling.md +1 -1
  80. package/package.json +1 -1
@@ -25,15 +25,15 @@ export class LionAccordion extends LitElement {
25
25
  /**
26
26
  * index number of the focused accordion
27
27
  */
28
- focusedIndex: {
29
- type: Number,
30
- },
28
+ focusedIndex: { type: Number },
31
29
  /**
32
30
  * array of indices of the expanded accordions
33
31
  */
34
- expanded: {
35
- type: Array,
36
- },
32
+ expanded: { type: Array },
33
+ /**
34
+ * exclusive property allows only one accordion slot to be open at a time
35
+ */
36
+ exclusive: { type: Boolean },
37
37
  };
38
38
  }
39
39
 
@@ -101,6 +101,11 @@ export class LionAccordion extends LitElement {
101
101
  super();
102
102
  this.styles = {};
103
103
 
104
+ /**
105
+ * @type {boolean}
106
+ */
107
+ this.exclusive = false;
108
+
104
109
  /**
105
110
  * @type {StoreEntry[]}
106
111
  * @private
@@ -437,20 +442,21 @@ export class LionAccordion extends LitElement {
437
442
  }
438
443
 
439
444
  /**
440
- * @param {number} value
445
+ * @param {number} indexClicked
441
446
  * @private
442
447
  */
443
- __toggleExpanded(value) {
444
- const expanded = [...this.expanded];
445
- const index = expanded.indexOf(value);
446
-
447
- if (index === -1) {
448
- expanded.push(value);
449
- } else {
450
- expanded.splice(index, 1);
448
+ __toggleExpanded(indexClicked) {
449
+ const indexFound = this.expanded.indexOf(indexClicked);
450
+ const expandedNewValues = this.exclusive ? [] : [...this.expanded];
451
+
452
+ if (indexFound === -1) {
453
+ expandedNewValues.push(indexClicked);
454
+ } else if (expandedNewValues.includes(indexFound)) {
455
+ expandedNewValues.splice(indexFound, 1);
451
456
  }
452
457
 
453
- this.expanded = expanded;
458
+ // trigger a render
459
+ this.expanded = expandedNewValues;
454
460
  }
455
461
 
456
462
  /**
@@ -33,14 +33,14 @@ function getAccordionChildren(el) {
33
33
  }
34
34
 
35
35
  /**
36
- * @param {Element} el
36
+ * @param {LionAccordion} el
37
37
  */
38
38
  function getInvokers(el) {
39
39
  return getAccordionChildren(el).filter(child => child.classList.contains('invoker'));
40
40
  }
41
41
 
42
42
  /**
43
- * @param {Element} el
43
+ * @param {LionAccordion} el
44
44
  */
45
45
  function getContents(el) {
46
46
  return getAccordionChildren(el).filter(child => child.classList.contains('content'));
@@ -112,6 +112,51 @@ describe('<lion-accordion>', () => {
112
112
  expect(invokers[1].firstElementChild).to.have.attribute('expanded');
113
113
  });
114
114
 
115
+ it('supports [exclusive] attribute, allowing one collapsible to be open at a time', async () => {
116
+ const el = /** @type {LionAccordion} */ (
117
+ await fixture(html`
118
+ <lion-accordion exclusive>
119
+ <h2 slot="invoker"><button>invoker 1</button></h2>
120
+ <div slot="content">content 1</div>
121
+ <h2 slot="invoker"><button>invoker 2</button></h2>
122
+ <div slot="content">content 2</div>
123
+ <h2 slot="invoker"><button>invoker 3</button></h2>
124
+ <div slot="content">content 3</div>
125
+ </lion-accordion>
126
+ `)
127
+ );
128
+
129
+ const invokerButtons = Array.from(getInvokers(el)).map(
130
+ invokerHeadingEl => /** @type {HTMLButtonElement} */ (invokerHeadingEl.firstElementChild),
131
+ );
132
+
133
+ // We open the first... (nothing different from not [exclusive] so far)
134
+ invokerButtons[0].click();
135
+ expect(invokerButtons[0]).to.have.attribute('expanded');
136
+ expect(invokerButtons[1]).to.not.have.attribute('expanded');
137
+ expect(invokerButtons[2]).to.not.have.attribute('expanded');
138
+
139
+ // We click the second...
140
+ invokerButtons[1].click();
141
+ expect(invokerButtons[0]).to.not.have.attribute('expanded');
142
+ expect(invokerButtons[1]).to.have.attribute('expanded');
143
+ expect(invokerButtons[2]).to.not.have.attribute('expanded');
144
+
145
+ // We click the third...
146
+ invokerButtons[2].click();
147
+ expect(invokerButtons[0]).to.not.have.attribute('expanded');
148
+ expect(invokerButtons[1]).to.not.have.attribute('expanded');
149
+ expect(invokerButtons[2]).to.have.attribute('expanded');
150
+
151
+ el.exclusive = false;
152
+
153
+ // We open the first... (behaving as default (not [exclusive]) again)
154
+ invokerButtons[0].click();
155
+ expect(invokerButtons[0]).to.have.attribute('expanded');
156
+ expect(invokerButtons[1]).to.not.have.attribute('expanded');
157
+ expect(invokerButtons[2]).to.have.attribute('expanded');
158
+ });
159
+
115
160
  it('sends event "expanded-changed" for every expanded state change', async () => {
116
161
  const el = /** @type {LionAccordion} */ (await fixture(basicAccordion));
117
162
  const spy = sinon.spy();
@@ -467,14 +512,16 @@ describe('<lion-accordion>', () => {
467
512
 
468
513
  describe('Invokers', () => {
469
514
  it('links ids of content items to invoker first child via [aria-controls]', async () => {
470
- const el = await fixture(html`
471
- <lion-accordion>
472
- <h2 id="h1" slot="invoker"><button>invoker 1</button></h2>
473
- <div id="p1" slot="content">content 1</div>
474
- <h2 id="h2" slot="invoker"><button>invoker 2</button></h2>
475
- <div id="p2" slot="content">content 2</div>
476
- </lion-accordion>
477
- `);
515
+ const el = /** @type {LionAccordion} */ (
516
+ await fixture(html`
517
+ <lion-accordion>
518
+ <h2 id="h1" slot="invoker"><button>invoker 1</button></h2>
519
+ <div id="p1" slot="content">content 1</div>
520
+ <h2 id="h2" slot="invoker"><button>invoker 2</button></h2>
521
+ <div id="p2" slot="content">content 2</div>
522
+ </lion-accordion>
523
+ `)
524
+ );
478
525
  const invokers = getInvokers(el);
479
526
  const contents = getContents(el);
480
527
  expect(invokers[0].firstElementChild?.getAttribute('aria-controls')).to.equal(
@@ -486,12 +533,14 @@ describe('<lion-accordion>', () => {
486
533
  });
487
534
 
488
535
  it('adds aria-expanded="false" to invoker when its content is not expanded', async () => {
489
- const el = await fixture(html`
490
- <lion-accordion>
491
- <h2 slot="invoker"><button>invoker</button></h2>
492
- <div slot="content">content</div>
493
- </lion-accordion>
494
- `);
536
+ const el = /** @type {LionAccordion} */ (
537
+ await fixture(html`
538
+ <lion-accordion>
539
+ <h2 slot="invoker"><button>invoker</button></h2>
540
+ <div slot="content">content</div>
541
+ </lion-accordion>
542
+ `)
543
+ );
495
544
  expect(Array.from(getInvokers(el))[0]?.firstElementChild).to.have.attribute(
496
545
  'aria-expanded',
497
546
  'false',
@@ -517,14 +566,16 @@ describe('<lion-accordion>', () => {
517
566
 
518
567
  describe('Contents', () => {
519
568
  it('adds aria-labelledby referring to invoker ids', async () => {
520
- const el = await fixture(html`
521
- <lion-accordion>
522
- <h2 slot="invoker"><button>invoker 1</button></h2>
523
- <div slot="content">content 1</div>
524
- <h2 slot="invoker"><button>invoker 2</button></h2>
525
- <div slot="content">content 2</div>
526
- </lion-accordion>
527
- `);
569
+ const el = /** @type {LionAccordion} */ (
570
+ await fixture(html`
571
+ <lion-accordion>
572
+ <h2 slot="invoker"><button>invoker 1</button></h2>
573
+ <div slot="content">content 1</div>
574
+ <h2 slot="invoker"><button>invoker 2</button></h2>
575
+ <div slot="content">content 2</div>
576
+ </lion-accordion>
577
+ `)
578
+ );
528
579
  const contents = getContents(el);
529
580
  const invokers = getInvokers(el);
530
581
  expect(contents[0]).to.have.attribute('aria-labelledby', invokers[0].firstElementChild?.id);
@@ -1,8 +1,8 @@
1
1
  export default {
2
2
  error: {
3
3
  Required: 'Zadejte rovněž {fieldName}.',
4
- _RequiredUpload: 'Nahrajte {fieldname}.',
5
- _RequiredSelect: 'Vyberte rovněž {fieldname}.',
4
+ _RequiredUpload: 'Nahrajte {fieldName}.',
5
+ _RequiredSelect: 'Vyberte rovněž {fieldName}.',
6
6
  EqualsLength: 'Zadejte správné {fieldName}, přesně {params} znaků.',
7
7
  MinLength: 'Zadejte správné {fieldName} (alespoň {params}).',
8
8
  MaxLength: 'Zadejte správné {fieldName} (až {params} znaků).',
@@ -23,8 +23,8 @@ export default {
23
23
  },
24
24
  warning: {
25
25
  Required: 'Zadejte rovněž {fieldName}.',
26
- _RequiredUpload: 'Nahrajte {fieldname}.',
27
- _RequiredSelect: 'Vyberte rovněž {fieldname}.',
26
+ _RequiredUpload: 'Nahrajte {fieldName}.',
27
+ _RequiredSelect: 'Vyberte rovněž {fieldName}.',
28
28
  EqualsLength: 'Zadejte správné {fieldName}, přesně {params} znaků.',
29
29
  MinLength: 'Zadejte správné {fieldName} (alespoň {params}).',
30
30
  MaxLength: 'Zadejte správné {fieldName} (až {params} znaků).',
@@ -2,7 +2,7 @@ export default {
2
2
  error: {
3
3
  Required: 'Introduzca también un/a {fieldName}.',
4
4
  _RequiredUpload: 'Cargue un {fieldName}.',
5
- _RequiredSelect: 'Seleccione también un/a {fieldname}.',
5
+ _RequiredSelect: 'Seleccione también un/a {fieldName}.',
6
6
  EqualsLength: 'Introduzca un/a {fieldName} correcto/a de exactamente {params} caracteres.',
7
7
  MinLength: 'Introduzca un/a {fieldName} correcto/a (de al menos {params} caracteres).',
8
8
  MaxLength: 'Introduzca un/a {fieldName} correcto/a (hasta {params} caracteres).',
@@ -26,7 +26,7 @@ export default {
26
26
  warning: {
27
27
  Required: 'Introduzca también un/a {fieldName}.',
28
28
  _RequiredUpload: 'Cargue un {fieldName}.',
29
- _RequiredSelect: 'Seleccione también un/a {fieldname}.',
29
+ _RequiredSelect: 'Seleccione también un/a {fieldName}.',
30
30
  EqualsLength: 'Introduzca un/a {fieldName} correcto/a de exactamente {params} caracteres.',
31
31
  MinLength: 'Introduzca un/a {fieldName} correcto/a (de al menos {params} caracteres).',
32
32
  MaxLength: 'Introduzca un/a {fieldName} correcto/a (hasta {params} caracteres).',
@@ -2,7 +2,7 @@ export default {
2
2
  error: {
3
3
  Required: 'Továbbá adjon meg egy {fieldName} értéket.',
4
4
  _RequiredUpload: 'Töltsön fel egy {fieldName} elemet.',
5
- _RequiredSelect: 'Továbbá válasszon ki egy {fieldname} értéket.',
5
+ _RequiredSelect: 'Továbbá válasszon ki egy {fieldName} értéket.',
6
6
  EqualsLength: 'Adjon meg egy helyes {fieldName} értéket (pontosan {params} karakter).',
7
7
  MinLength: 'Adjon meg egy helyes {fieldName} értéket (legalább {params}).',
8
8
  MaxLength: 'Adjon meg egy helyes {fieldName} értéket (legfeljebb {params} karakter).',
@@ -26,7 +26,7 @@ export default {
26
26
  warning: {
27
27
  Required: 'Továbbá adjon meg egy {fieldName} értéket.',
28
28
  _RequiredUpload: 'Töltsön fel egy {fieldName} elemet.',
29
- _RequiredSelect: 'Továbbá válasszon ki egy {fieldname} értéket.',
29
+ _RequiredSelect: 'Továbbá válasszon ki egy {fieldName} értéket.',
30
30
  EqualsLength: 'Adjon meg egy helyes {fieldName} értéket (pontosan {params} karakter).',
31
31
  MinLength: 'Adjon meg egy helyes {fieldName} értéket (legalább {params}).',
32
32
  MaxLength: 'Adjon meg egy helyes {fieldName} értéket (legfeljebb {params} karakter).',
@@ -2,7 +2,7 @@ export default {
2
2
  error: {
3
3
  Required: 'Inserire anche un(a) {fieldName}.',
4
4
  _RequiredUpload: 'Caricare un {fieldName}.',
5
- _RequiredSelect: 'Selezionare anche un(a) {fieldname}.',
5
+ _RequiredSelect: 'Selezionare anche un(a) {fieldName}.',
6
6
  EqualsLength: 'Inserire un(a) {fieldName} corretto(a) di esattamente {params} caratteri.',
7
7
  MinLength: 'Inserire un(a) {fieldName} corretto(a) (almeno {params}).',
8
8
  MaxLength: 'Inserire un(a) {fieldName} corretto(a) (fino a {params} caratteri).',
@@ -26,7 +26,7 @@ export default {
26
26
  warning: {
27
27
  Required: 'Inserire anche un(a) {fieldName}.',
28
28
  _RequiredUpload: 'Caricare un {fieldName}.',
29
- _RequiredSelect: 'Selezionare anche un(a) {fieldname}.',
29
+ _RequiredSelect: 'Selezionare anche un(a) {fieldName}.',
30
30
  EqualsLength: 'Inserire un(a) {fieldName} corretto(a) di esattamente {params} caratteri.',
31
31
  MinLength: 'Inserire un(a) {fieldName} corretto(a) (almeno {params}).',
32
32
  MaxLength: 'Inserire un(a) {fieldName} corretto(a) (fino a {params} caratteri).',
@@ -2,7 +2,7 @@ export default {
2
2
  error: {
3
3
  Required: 'Vul een {fieldName} in.',
4
4
  _RequiredUpload: 'Upload een {fieldName}.',
5
- _RequiredSelect: 'Selecteer een {fieldname}.',
5
+ _RequiredSelect: 'Selecteer een {fieldName}.',
6
6
  EqualsLength: 'Vul een {fieldName} in gelijk aan {params} karakters.',
7
7
  MinLength: 'Vul een {fieldName} in van minimaal {params} karakters.',
8
8
  MaxLength: 'Vul een {fieldName} in van maximaal {params} karakters.',
@@ -25,7 +25,7 @@ export default {
25
25
  warning: {
26
26
  Required: 'Vul een {fieldName} in.',
27
27
  _RequiredUpload: 'Upload een {fieldName}.',
28
- _RequiredSelect: 'Selecteer een {fieldname}.',
28
+ _RequiredSelect: 'Selecteer een {fieldName}.',
29
29
  EqualsLength: 'Vul een {fieldName} in gelijk aan {params} karakters.',
30
30
  MinLength: 'Vul een {fieldName} in van minimaal {params} karakters.',
31
31
  MaxLength: 'Vul een {fieldName} in van maximaal {params} karakters.',
@@ -2,7 +2,7 @@ export default {
2
2
  error: {
3
3
  Required: 'Proszę również podać wartość {fieldName}.',
4
4
  _RequiredUpload: 'Prześlij plik {fieldName}.',
5
- _RequiredSelect: 'Wprowadź prawidłową wartość w polu {fieldname}.',
5
+ _RequiredSelect: 'Wprowadź prawidłową wartość w polu {fieldName}.',
6
6
  EqualsLength: 'Wprowadź prawidłową wartość w polu {fieldName} (maks. liczba znaków: {params}).',
7
7
  MinLength: 'Proszę podać prawidłową wartość {fieldName} (co najmniej {params} znaków).',
8
8
  MaxLength: 'Proszę podać prawidłową wartość {fieldName} (maks. {params} znaków).',
@@ -25,7 +25,7 @@ export default {
25
25
  warning: {
26
26
  Required: 'Proszę również podać wartość {fieldName}.',
27
27
  _RequiredUpload: 'Prześlij plik {fieldName}.',
28
- _RequiredSelect: 'Wprowadź prawidłową wartość w polu {fieldname}.',
28
+ _RequiredSelect: 'Wprowadź prawidłową wartość w polu {fieldName}.',
29
29
  EqualsLength: 'Wprowadź prawidłową wartość w polu {fieldName} (maks. liczba znaków: {params}).',
30
30
  MinLength: 'Proszę podać prawidłową wartość {fieldName} (co najmniej {params} znaków).',
31
31
  MaxLength: 'Proszę podać prawidłową wartość {fieldName} (maks. {params} znaków).',
@@ -2,7 +2,7 @@ export default {
2
2
  error: {
3
3
  Required: 'Введите значение поля {fieldName}.',
4
4
  _RequiredUpload: 'Загрузите {fieldName}.',
5
- _RequiredSelect: 'Также выберите значение поля {fieldname}.',
5
+ _RequiredSelect: 'Также выберите значение поля {fieldName}.',
6
6
  EqualsLength: 'Введите корректное значение поля {fieldName} — ровно {params} симв.',
7
7
  MinLength: 'Введите корректное значение поля {fieldName} (не менее {params}).',
8
8
  MaxLength: 'Введите корректное значение поля {fieldName} (до {params} симв.).',
@@ -26,7 +26,7 @@ export default {
26
26
  warning: {
27
27
  Required: 'Введите значение поля {fieldName}.',
28
28
  _RequiredUpload: 'Загрузите {fieldName}.',
29
- _RequiredSelect: 'Также выберите значение поля {fieldname}.',
29
+ _RequiredSelect: 'Также выберите значение поля {fieldName}.',
30
30
  EqualsLength: 'Введите корректное значение поля {fieldName} — ровно {paramsn} симв.',
31
31
  MinLength: 'Введите корректное значение поля {fieldName} (не менее {params}).',
32
32
  MaxLength: 'Введите корректное значение поля {fieldName} (до {params} симв.).',
@@ -2,7 +2,7 @@ export default {
2
2
  error: {
3
3
  Required: 'Uveďte aj {fieldName}.',
4
4
  _RequiredUpload: 'Nahrajte pole {fieldName}.',
5
- _RequiredSelect: 'Vyberte aj hodnotu v poli {fieldname}.',
5
+ _RequiredSelect: 'Vyberte aj hodnotu v poli {fieldName}.',
6
6
  EqualsLength: 'Do poľa {fieldName} zadajte platnú hodnotu v dĺžke presne {params} znaky/-ov.',
7
7
  MinLength: 'Uveďte správne {fieldName} (najmenej {params}).',
8
8
  MaxLength: 'Uveďte správne {fieldName} (maximálne {params} znakov).',
@@ -24,7 +24,7 @@ export default {
24
24
  warning: {
25
25
  Required: 'Uveďte aj {fieldName}.',
26
26
  _RequiredUpload: 'Nahrajte pole {fieldName}.',
27
- _RequiredSelect: 'Vyberte aj hodnotu v poli {fieldname}.',
27
+ _RequiredSelect: 'Vyberte aj hodnotu v poli {fieldName}.',
28
28
  EqualsLength: 'Do poľa {fieldName} zadajte platnú hodnotu v dĺžke presne {params} znaky/-ov.',
29
29
  MinLength: 'Uveďte správne {fieldName} (najmenej {params}).',
30
30
  MaxLength: 'Uveďte správne {fieldName} (maximálne {params} znakov).',
@@ -2,7 +2,7 @@ export default {
2
2
  error: {
3
3
  Required: 'Уведіть також значення {fieldName}.',
4
4
  _RequiredUpload: 'Завантажте {fieldName}.',
5
- _RequiredSelect: 'Виберіть також {fieldname}.',
5
+ _RequiredSelect: 'Виберіть також {fieldName}.',
6
6
  EqualsLength:
7
7
  'Введіть правильне значення {fieldName}, кількість символів має бути точно {params}.',
8
8
  MinLength: 'Уведіть правильне значення {fieldName} (щонайменше {params}).',
@@ -27,7 +27,7 @@ export default {
27
27
  warning: {
28
28
  Required: 'Уведіть також значення {fieldName}.',
29
29
  _RequiredUpload: 'Завантажте {fieldName}.',
30
- _RequiredSelect: 'Виберіть також {fieldname}.',
30
+ _RequiredSelect: 'Виберіть також {fieldName}.',
31
31
  EqualsLength:
32
32
  'Введіть правильне значення {fieldName}, кількість символів має бути точно {params}.',
33
33
  MinLength: 'Уведіть правильне значення {fieldName} (щонайменше {params}).',
@@ -2100,36 +2100,6 @@
2100
2100
  }
2101
2101
  ]
2102
2102
  },
2103
- {
2104
- "kind": "javascript-module",
2105
- "path": "exports/define-helpers/sb-action-logger.js",
2106
- "declarations": [],
2107
- "exports": [
2108
- {
2109
- "kind": "custom-element-definition",
2110
- "name": "sb-action-logger",
2111
- "declaration": {
2112
- "name": "SbActionLogger",
2113
- "module": "/exports/helpers.js"
2114
- }
2115
- }
2116
- ]
2117
- },
2118
- {
2119
- "kind": "javascript-module",
2120
- "path": "exports/define-helpers/sb-locale-switcher.js",
2121
- "declarations": [],
2122
- "exports": [
2123
- {
2124
- "kind": "custom-element-definition",
2125
- "name": "sb-locale-switcher",
2126
- "declaration": {
2127
- "name": "SbLocaleSwitcher",
2128
- "module": "/exports/helpers.js"
2129
- }
2130
- }
2131
- ]
2132
- },
2133
2103
  {
2134
2104
  "kind": "javascript-module",
2135
2105
  "path": "exports/define/lion-accordion.js",
@@ -2820,6 +2790,36 @@
2820
2790
  }
2821
2791
  ]
2822
2792
  },
2793
+ {
2794
+ "kind": "javascript-module",
2795
+ "path": "exports/define-helpers/sb-action-logger.js",
2796
+ "declarations": [],
2797
+ "exports": [
2798
+ {
2799
+ "kind": "custom-element-definition",
2800
+ "name": "sb-action-logger",
2801
+ "declaration": {
2802
+ "name": "SbActionLogger",
2803
+ "module": "/exports/helpers.js"
2804
+ }
2805
+ }
2806
+ ]
2807
+ },
2808
+ {
2809
+ "kind": "javascript-module",
2810
+ "path": "exports/define-helpers/sb-locale-switcher.js",
2811
+ "declarations": [],
2812
+ "exports": [
2813
+ {
2814
+ "kind": "custom-element-definition",
2815
+ "name": "sb-locale-switcher",
2816
+ "declaration": {
2817
+ "name": "SbLocaleSwitcher",
2818
+ "module": "/exports/helpers.js"
2819
+ }
2820
+ }
2821
+ ]
2822
+ },
2823
2823
  {
2824
2824
  "kind": "javascript-module",
2825
2825
  "path": "components/accordion/src/LionAccordion.js",
@@ -3031,7 +3031,7 @@
3031
3031
  "name": "__toggleExpanded",
3032
3032
  "parameters": [
3033
3033
  {
3034
- "name": "value",
3034
+ "name": "indexClicked",
3035
3035
  "type": {
3036
3036
  "text": "number"
3037
3037
  }
@@ -3044,6 +3044,17 @@
3044
3044
  "name": "__cleanStore",
3045
3045
  "privacy": "private"
3046
3046
  },
3047
+ {
3048
+ "kind": "field",
3049
+ "name": "exclusive",
3050
+ "privacy": "public",
3051
+ "type": {
3052
+ "text": "boolean"
3053
+ },
3054
+ "description": "exclusive property allows only one accordion slot to be open at a time",
3055
+ "default": "false",
3056
+ "attribute": "exclusive"
3057
+ },
3047
3058
  {
3048
3059
  "kind": "field",
3049
3060
  "name": "__store",
@@ -3104,6 +3115,15 @@
3104
3115
  }
3105
3116
  ],
3106
3117
  "fieldName": "expanded"
3118
+ },
3119
+ {
3120
+ "name": "exclusive",
3121
+ "type": {
3122
+ "text": "boolean"
3123
+ },
3124
+ "description": "exclusive property allows only one accordion slot to be open at a time",
3125
+ "default": "false",
3126
+ "fieldName": "exclusive"
3107
3127
  }
3108
3128
  ],
3109
3129
  "superclass": {
@@ -28,6 +28,12 @@ export class LionAccordion extends LitElement {
28
28
  expanded: {
29
29
  type: ArrayConstructor;
30
30
  };
31
+ /**
32
+ * exclusive property allows only one accordion slot to be open at a time
33
+ */
34
+ exclusive: {
35
+ type: BooleanConstructor;
36
+ };
31
37
  };
32
38
  static get styles(): import("lit").CSSResult[];
33
39
  /**
@@ -43,6 +49,10 @@ export class LionAccordion extends LitElement {
43
49
  get expanded(): number[];
44
50
  __expanded: number[];
45
51
  styles: {};
52
+ /**
53
+ * @type {boolean}
54
+ */
55
+ exclusive: boolean;
46
56
  /**
47
57
  * @type {StoreEntry[]}
48
58
  * @private
@@ -127,7 +137,7 @@ export class LionAccordion extends LitElement {
127
137
  */
128
138
  private __updateExpanded;
129
139
  /**
130
- * @param {number} value
140
+ * @param {number} indexClicked
131
141
  * @private
132
142
  */
133
143
  private __toggleExpanded;
@@ -1 +1 @@
1
- {"version":3,"file":"LionAccordion.d.ts","sourceRoot":"","sources":["../../../../components/accordion/src/LionAccordion.js"],"names":[],"mappings":"AAIA;;;;;;;;;GASG;AAEH;;;;;GAKG;AACH;IACE;QAEI;;WAEG;;;;QAIH;;WAEG;;;;MAKN;IAED,+CA4BC;IAED;;OAEG;IACH,8BAMC;IAED,2BAEC;IARC,gBAoCU,MAAM,CApCW;IAU7B;;OAEG;IACH,4BAMC;IAED,yBAEC;IARC,YA2BU,MAAM,EAAE,CA3BK;IAYvB,WAAgB;IAEhB;;;OAGG;IACH,gBAAiB;IAqBnB,+CAQC;IAED;;OAEG;IACH,qBAeC;IAED;;OAEG;IACH,qBAiDC;IAED;;;;;OAKG;IACH,sCAqBC;IAED;;;OAGG;IACH,oCAKC;IAED;;;OAGG;IACH,oCAOC;IAED;;;OAGG;IACH,+BA2BC;IAED;;OAEG;IACH,yBAEC;IAED;;;OAGG;IACH,+BAHW,UAAU,QAQpB;IAED;;;OAGG;IACH,+BAHW,UAAU,QAcpB;IAED;;;OAGG;IACH,+BAHW,UAAU,QAapB;IAED;;;OAGG;IACH,+BAHW,UAAU,QAUpB;IAED;;;OAGG;IACH,iCAHW,UAAU,QASpB;IAED;;;OAGG;IACH,2BAHW,UAAU,QAYpB;IAED;;;OAGG;IACH,yBAHW,UAAU,QAYpB;IAED;;OAEG;IACH,wBAWC;IAED;;OAEG;IACH,yBAaC;IAED;;;OAGG;IACH,yBAWC;IAED;;OAEG;IACH,qBAQC;CACF;;;;;SA7ca,MAAM;;;;WACN,MAAM;;;;aACN,WAAW;;;;aACX,WAAW;;;;0BACH,KAAK,KAAK,OAAO;;;;4BACjB,KAAK,KAAK,OAAO;;;;0BACjB,KAAK,KAAK,OAAO"}
1
+ {"version":3,"file":"LionAccordion.d.ts","sourceRoot":"","sources":["../../../../components/accordion/src/LionAccordion.js"],"names":[],"mappings":"AAIA;;;;;;;;;GASG;AAEH;;;;;GAKG;AACH;IACE;QAEI;;WAEG;;;;QAEH;;WAEG;;;;QAEH;;WAEG;;;;MAGN;IAED,+CA4BC;IAED;;OAEG;IACH,8BAMC;IAED,2BAEC;IARC,gBAyCU,MAAM,CAzCW;IAU7B;;OAEG;IACH,4BAMC;IAED,yBAEC;IARC,YAgCU,MAAM,EAAE,CAhCK;IAYvB,WAAgB;IAEhB;;OAEG;IACH,WAFU,OAAO,CAEK;IAEtB;;;OAGG;IACH,gBAAiB;IAqBnB,+CAQC;IAED;;OAEG;IACH,qBAeC;IAED;;OAEG;IACH,qBAiDC;IAED;;;;;OAKG;IACH,sCAqBC;IAED;;;OAGG;IACH,oCAKC;IAED;;;OAGG;IACH,oCAOC;IAED;;;OAGG;IACH,+BA2BC;IAED;;OAEG;IACH,yBAEC;IAED;;;OAGG;IACH,+BAHW,UAAU,QAQpB;IAED;;;OAGG;IACH,+BAHW,UAAU,QAcpB;IAED;;;OAGG;IACH,+BAHW,UAAU,QAapB;IAED;;;OAGG;IACH,+BAHW,UAAU,QAUpB;IAED;;;OAGG;IACH,iCAHW,UAAU,QASpB;IAED;;;OAGG;IACH,2BAHW,UAAU,QAYpB;IAED;;;OAGG;IACH,yBAHW,UAAU,QAYpB;IAED;;OAEG;IACH,wBAWC;IAED;;OAEG;IACH,yBAaC;IAED;;;OAGG;IACH,yBAYC;IAED;;OAEG;IACH,qBAQC;CACF;;;;;SAnda,MAAM;;;;WACN,MAAM;;;;aACN,WAAW;;;;aACX,WAAW;;;;0BACH,KAAK,KAAK,OAAO;;;;4BACjB,KAAK,KAAK,OAAO;;;;0BACjB,KAAK,KAAK,OAAO"}