@swisspost/design-system-components 7.2.0 → 7.3.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.
Files changed (204) hide show
  1. package/dist/cjs/_commonjsHelpers-8f2c79cd.js +31 -0
  2. package/dist/cjs/check-type-64af82a9.js +16 -0
  3. package/dist/cjs/{index-0fc0bf5f.js → index-1cc8e4e1.js} +522 -224
  4. package/dist/cjs/{index-a1440961.js → index-f32e5185.js} +2 -15
  5. package/dist/cjs/index.cjs.js +21 -17
  6. package/dist/cjs/loader.cjs.js +2 -2
  7. package/dist/cjs/{package-b133ab48.js → package-04f2043d.js} +1 -1
  8. package/dist/cjs/{post-accordion-a079c21b.js → post-accordion-37fd4f78.js} +2 -2
  9. package/dist/cjs/{post-accordion-item-30c6ec06.js → post-accordion-item-1c83fc7c.js} +4 -4
  10. package/dist/cjs/post-accordion-item.cjs.entry.js +5 -4
  11. package/dist/cjs/post-accordion.cjs.entry.js +3 -3
  12. package/dist/cjs/{post-alert-b5cfc4c6.js → post-alert-6fb69a85.js} +8 -7
  13. package/dist/cjs/post-alert.cjs.entry.js +5 -4
  14. package/dist/cjs/post-card-control-b4d765d4.js +315 -0
  15. package/dist/cjs/post-card-control.cjs.entry.js +3 -3
  16. package/dist/cjs/{post-collapsible-9bcaf6f1.js → post-collapsible-d1afbfc7.js} +14 -10
  17. package/dist/cjs/post-collapsible-trigger-ed6c0795.js +188280 -0
  18. package/dist/cjs/post-collapsible-trigger.cjs.entry.js +14 -0
  19. package/dist/cjs/post-collapsible.cjs.entry.js +5 -4
  20. package/dist/cjs/post-components.cjs.js +3 -3
  21. package/dist/cjs/{post-icon-87e7972e.js → post-icon-8bc01581.js} +6 -5
  22. package/dist/cjs/post-icon.cjs.entry.js +5 -4
  23. package/dist/cjs/{post-popover-0a73553e.js → post-popover-bdcc2f7d.js} +4 -4
  24. package/dist/cjs/post-popover.cjs.entry.js +3 -3
  25. package/dist/cjs/{post-popovercontainer-a1df1705.js → post-popovercontainer-e63276d4.js} +44 -37
  26. package/dist/cjs/post-popovercontainer.cjs.entry.js +3 -3
  27. package/dist/cjs/{post-rating-2337c023.js → post-rating-26fda1b8.js} +3 -3
  28. package/dist/cjs/post-rating.cjs.entry.js +3 -3
  29. package/dist/cjs/post-tab-header-b367fb5e.js +32 -0
  30. package/dist/cjs/post-tab-header.cjs.entry.js +3 -3
  31. package/dist/cjs/{post-tab-panel-307eacef.js → post-tab-panel-68c379af.js} +3 -3
  32. package/dist/cjs/post-tab-panel.cjs.entry.js +3 -3
  33. package/dist/cjs/{post-tabs-92435b40.js → post-tabs-cb1407ec.js} +8 -10
  34. package/dist/cjs/post-tabs.cjs.entry.js +3 -3
  35. package/dist/cjs/{post-tag-0237216a.js → post-tag-8f03cbff.js} +3 -3
  36. package/dist/cjs/post-tag.cjs.entry.js +3 -3
  37. package/dist/cjs/{post-tooltip-7fcd3f15.js → post-tooltip-75b6872c.js} +25 -12
  38. package/dist/cjs/post-tooltip.cjs.entry.js +8 -3
  39. package/dist/collection/collection-manifest.json +2 -1
  40. package/dist/collection/components/post-accordion-item/post-accordion-item.css +1 -1
  41. package/dist/collection/components/post-alert/post-alert.css +2 -2
  42. package/dist/collection/components/post-alert/post-alert.js +1 -1
  43. package/dist/collection/components/post-card-control/post-card-control.css +1 -1
  44. package/dist/collection/components/post-collapsible/post-collapsible.css +1 -1
  45. package/dist/collection/components/post-collapsible/post-collapsible.js +10 -11
  46. package/dist/collection/components/post-collapsible-trigger/post-collapsible-trigger.js +153 -0
  47. package/dist/collection/components/post-icon/post-icon.js +1 -1
  48. package/dist/collection/components/post-popover/post-popover.css +1 -1
  49. package/dist/collection/components/post-popover/post-popover.js +2 -2
  50. package/dist/collection/components/post-popovercontainer/post-popovercontainer.css +1 -1
  51. package/dist/collection/components/post-popovercontainer/post-popovercontainer.js +14 -17
  52. package/dist/collection/components/post-rating/post-rating.js +1 -1
  53. package/dist/collection/components/post-tab-header/post-tab-header.css +1 -1
  54. package/dist/collection/components/post-tab-header/post-tab-header.js +1 -1
  55. package/dist/collection/components/post-tab-panel/post-tab-panel.js +1 -1
  56. package/dist/collection/components/post-tabs/post-tabs.js +8 -8
  57. package/dist/collection/components/post-tag/post-tag.js +1 -1
  58. package/dist/collection/components/post-tooltip/post-tooltip.css +1 -1
  59. package/dist/collection/components/post-tooltip/post-tooltip.js +37 -2
  60. package/dist/collection/index.js +1 -0
  61. package/dist/collection/utils/debounce.js +8 -0
  62. package/dist/collection/utils/index.js +2 -0
  63. package/dist/collection/utils/timeout.js +3 -0
  64. package/dist/components/_commonjsHelpers.js +26 -0
  65. package/dist/components/check-type.js +14 -0
  66. package/dist/components/index.js +1 -0
  67. package/dist/components/index2.js +2 -14
  68. package/dist/components/package.js +1 -1
  69. package/dist/components/post-accordion-item2.js +1 -1
  70. package/dist/components/post-alert2.js +4 -3
  71. package/dist/components/post-card-control2.js +1 -1
  72. package/dist/components/post-collapsible-trigger.d.ts +11 -0
  73. package/dist/components/post-collapsible-trigger.js +6 -0
  74. package/dist/components/post-collapsible-trigger2.js +188297 -0
  75. package/dist/components/post-collapsible2.js +12 -9
  76. package/dist/components/post-icon2.js +3 -2
  77. package/dist/components/post-popover2.js +2 -2
  78. package/dist/components/post-popovercontainer2.js +43 -37
  79. package/dist/components/post-rating2.js +1 -1
  80. package/dist/components/post-tab-header2.js +2 -2
  81. package/dist/components/post-tab-panel2.js +1 -1
  82. package/dist/components/post-tabs2.js +6 -8
  83. package/dist/components/post-tag2.js +1 -1
  84. package/dist/components/post-tooltip2.js +22 -6
  85. package/dist/docs.json +120 -15
  86. package/dist/esm/_commonjsHelpers-24671825.js +26 -0
  87. package/dist/esm/check-type-8828dbe4.js +14 -0
  88. package/dist/esm/{index-d1eba94c.js → index-29d17d6d.js} +2 -14
  89. package/dist/esm/{index-d9331ff3.js → index-9ace3232.js} +522 -224
  90. package/dist/esm/index.js +20 -17
  91. package/dist/esm/loader.js +3 -3
  92. package/dist/esm/{package-37b02bc3.js → package-4d20f60f.js} +1 -1
  93. package/dist/esm/{post-accordion-7eaa090e.js → post-accordion-62014c92.js} +2 -2
  94. package/dist/esm/{post-accordion-item-d5466ca0.js → post-accordion-item-cbac29b5.js} +4 -4
  95. package/dist/esm/post-accordion-item.entry.js +5 -4
  96. package/dist/esm/post-accordion.entry.js +3 -3
  97. package/dist/esm/{post-alert-5bc0d11c.js → post-alert-c4debfa4.js} +6 -5
  98. package/dist/esm/post-alert.entry.js +5 -4
  99. package/dist/esm/post-card-control-00a5376b.js +313 -0
  100. package/dist/esm/post-card-control.entry.js +3 -3
  101. package/dist/esm/{post-collapsible-0bb7ca9a.js → post-collapsible-8d4694d4.js} +14 -10
  102. package/dist/esm/post-collapsible-trigger-84e583ca.js +188278 -0
  103. package/dist/esm/post-collapsible-trigger.entry.js +6 -0
  104. package/dist/esm/post-collapsible.entry.js +5 -4
  105. package/dist/esm/post-components.js +4 -4
  106. package/dist/esm/{post-icon-8d59faf7.js → post-icon-a7fc703c.js} +5 -4
  107. package/dist/esm/post-icon.entry.js +5 -4
  108. package/dist/esm/{post-popover-0ebc24f5.js → post-popover-e4e3c7e9.js} +4 -4
  109. package/dist/esm/post-popover.entry.js +3 -3
  110. package/dist/esm/{post-popovercontainer-5c0ba050.js → post-popovercontainer-012763bb.js} +44 -37
  111. package/dist/esm/post-popovercontainer.entry.js +3 -3
  112. package/dist/esm/{post-rating-40195437.js → post-rating-65f2a6f5.js} +3 -3
  113. package/dist/esm/post-rating.entry.js +3 -3
  114. package/dist/esm/post-tab-header-6c4e751f.js +30 -0
  115. package/dist/esm/post-tab-header.entry.js +3 -3
  116. package/dist/esm/{post-tab-panel-d40b9704.js → post-tab-panel-0a00a0db.js} +3 -3
  117. package/dist/esm/post-tab-panel.entry.js +3 -3
  118. package/dist/esm/{post-tabs-6ee5542b.js → post-tabs-ce296f51.js} +8 -10
  119. package/dist/esm/post-tabs.entry.js +3 -3
  120. package/dist/esm/{post-tag-e76f88e5.js → post-tag-08829103.js} +3 -3
  121. package/dist/esm/post-tag.entry.js +3 -3
  122. package/dist/esm/{post-tooltip-990b8b2b.js → post-tooltip-f649a3f5.js} +21 -8
  123. package/dist/esm/post-tooltip.entry.js +8 -3
  124. package/dist/post-components/index.esm.js +1 -1
  125. package/dist/post-components/{p-3f2c54ad.js → p-0397588f.js} +1 -1
  126. package/dist/post-components/p-03bd02f3.entry.js +1 -0
  127. package/dist/post-components/p-07e54337.js +1 -0
  128. package/dist/post-components/p-0a7a9ff0.entry.js +1 -0
  129. package/dist/post-components/p-12ad573b.entry.js +1 -0
  130. package/dist/post-components/p-12c4e001.entry.js +1 -0
  131. package/dist/post-components/p-1c2d6fa3.entry.js +1 -0
  132. package/dist/post-components/p-1e103e24.entry.js +1 -0
  133. package/dist/post-components/{p-69bd634e.js → p-28a16293.js} +1 -1
  134. package/dist/post-components/{p-0637689e.js → p-2bb82301.js} +1 -1
  135. package/dist/post-components/p-3a4c029f.js +1 -0
  136. package/dist/post-components/p-489390f4.js +1 -0
  137. package/dist/post-components/p-4a3f67ab.js +1 -0
  138. package/dist/post-components/p-4ced5f5f.entry.js +1 -0
  139. package/dist/post-components/p-5a47caeb.js +1 -0
  140. package/dist/post-components/p-6712c712.entry.js +1 -0
  141. package/dist/post-components/p-6b2156ed.js +1 -0
  142. package/dist/post-components/p-73a63423.js +1 -0
  143. package/dist/post-components/{p-aef9ee8b.js → p-7751bd1f.js} +1 -1
  144. package/dist/post-components/p-7f35c77d.js +1 -0
  145. package/dist/post-components/p-80afd42d.entry.js +1 -0
  146. package/dist/post-components/p-8771fd61.js +1 -0
  147. package/dist/post-components/p-8c7f0075.js +2 -0
  148. package/dist/post-components/p-94c3e483.js +20 -0
  149. package/dist/post-components/p-94e75021.js +15 -0
  150. package/dist/post-components/p-aab2780d.entry.js +1 -0
  151. package/dist/post-components/p-aba21874.entry.js +1 -0
  152. package/dist/post-components/p-ac500761.js +1 -0
  153. package/dist/post-components/p-b0ac8313.entry.js +1 -0
  154. package/dist/post-components/{p-f86b2ea1.js → p-c3abf86d.js} +1 -1
  155. package/dist/post-components/p-cb13d0e2.entry.js +1 -0
  156. package/dist/post-components/p-d8534a90.entry.js +1 -0
  157. package/dist/post-components/p-da8cdd71.js +1 -0
  158. package/dist/post-components/p-f0fbe328.entry.js +1 -0
  159. package/dist/post-components/p-ff86b519.js +1 -0
  160. package/dist/post-components/post-components.esm.js +1 -1
  161. package/dist/types/components/post-collapsible/post-collapsible.d.ts +4 -3
  162. package/dist/types/components/post-collapsible-trigger/post-collapsible-trigger.d.ts +47 -0
  163. package/dist/types/components/post-popovercontainer/post-popovercontainer.d.ts +0 -1
  164. package/dist/types/components/post-tabs/post-tabs.d.ts +2 -0
  165. package/dist/types/components/post-tooltip/post-tooltip.d.ts +6 -0
  166. package/dist/types/components.d.ts +33 -0
  167. package/dist/types/index.d.ts +1 -0
  168. package/dist/types/stencil-public-runtime.d.ts +0 -2
  169. package/dist/types/utils/debounce.d.ts +1 -0
  170. package/dist/types/utils/index.d.ts +2 -0
  171. package/dist/types/utils/timeout.d.ts +1 -0
  172. package/loader/index.d.ts +3 -0
  173. package/package.json +10 -10
  174. package/dist/cjs/post-card-control-80ff0fbb.js +0 -315
  175. package/dist/cjs/post-tab-header-ac4137cb.js +0 -32
  176. package/dist/collection/index.spec.js +0 -27
  177. package/dist/esm/post-card-control-d64be740.js +0 -313
  178. package/dist/esm/post-tab-header-ff165ebb.js +0 -30
  179. package/dist/post-components/p-0ba99d76.entry.js +0 -1
  180. package/dist/post-components/p-0e97fb19.entry.js +0 -1
  181. package/dist/post-components/p-19ee1efc.entry.js +0 -1
  182. package/dist/post-components/p-23e7f6e3.entry.js +0 -1
  183. package/dist/post-components/p-287f66b9.js +0 -1
  184. package/dist/post-components/p-305ab60c.js +0 -1
  185. package/dist/post-components/p-3ce051c9.js +0 -1
  186. package/dist/post-components/p-62229794.entry.js +0 -1
  187. package/dist/post-components/p-7dc73c43.entry.js +0 -1
  188. package/dist/post-components/p-7e59cbd2.js +0 -1
  189. package/dist/post-components/p-8559d3c0.entry.js +0 -1
  190. package/dist/post-components/p-941e5ef0.js +0 -1
  191. package/dist/post-components/p-95003bde.entry.js +0 -1
  192. package/dist/post-components/p-a1da0539.js +0 -1
  193. package/dist/post-components/p-a5d9115f.entry.js +0 -1
  194. package/dist/post-components/p-a9aa57f0.entry.js +0 -1
  195. package/dist/post-components/p-c21da8cb.js +0 -1
  196. package/dist/post-components/p-c655db7c.entry.js +0 -1
  197. package/dist/post-components/p-ca2ff4bb.entry.js +0 -1
  198. package/dist/post-components/p-d2eafe06.entry.js +0 -1
  199. package/dist/post-components/p-d6e0e495.js +0 -1
  200. package/dist/post-components/p-d9eab6d9.js +0 -2
  201. package/dist/post-components/p-deb19ca0.js +0 -1
  202. package/dist/post-components/p-ee12644d.js +0 -15
  203. package/dist/post-components/p-f91c0e1b.js +0 -1
  204. package/dist/post-components/p-ff0b0a9a.entry.js +0 -1
@@ -1,6 +1,6 @@
1
1
  import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
2
2
  import { v as version } from './package.js';
3
- import { d as checkEmptyOrType } from './index2.js';
3
+ import { b as checkEmptyOrType } from './index2.js';
4
4
 
5
5
  function isMotionReduced() {
6
6
  return window.matchMedia('(prefers-reduced-motion: reduce)').matches;
@@ -24,7 +24,7 @@ const expand = (el) => {
24
24
  return el.animate([collapsedKeyframe, expandedKeyframe, finalKeyframe], animationOptions);
25
25
  };
26
26
 
27
- const postCollapsibleCss = ":host{display:block}.collapse{overflow:hidden}";
27
+ const postCollapsibleCss = ":host{display:block;overflow:hidden}";
28
28
  const PostCollapsibleStyle0 = postCollapsibleCss;
29
29
 
30
30
  const PostCollapsible = /*@__PURE__*/ proxyCustomElement(class PostCollapsible extends HTMLElement {
@@ -35,7 +35,6 @@ const PostCollapsible = /*@__PURE__*/ proxyCustomElement(class PostCollapsible e
35
35
  this.postToggle = createEvent(this, "postToggle", 7);
36
36
  this.isLoaded = false;
37
37
  this.isOpen = true;
38
- this.id = undefined;
39
38
  this.collapsed = false;
40
39
  }
41
40
  validateCollapsed(newValue = this.collapsed) {
@@ -44,13 +43,11 @@ const PostCollapsible = /*@__PURE__*/ proxyCustomElement(class PostCollapsible e
44
43
  connectedCallback() {
45
44
  this.validateCollapsed();
46
45
  }
47
- componentWillRender() {
48
- this.id = this.host.id || `c${crypto.randomUUID()}`;
49
- }
50
46
  componentDidLoad() {
51
47
  if (this.collapsed)
52
48
  void this.toggle(false);
53
49
  this.isLoaded = true;
50
+ this.updateTriggers();
54
51
  }
55
52
  /**
56
53
  * Triggers the collapse programmatically.
@@ -63,15 +60,22 @@ const PostCollapsible = /*@__PURE__*/ proxyCustomElement(class PostCollapsible e
63
60
  this.isOpen = !this.isOpen;
64
61
  if (this.isLoaded)
65
62
  this.postToggle.emit(this.isOpen);
66
- const animation = open ? expand(this.collapsible) : collapse(this.collapsible);
63
+ const animation = open ? expand(this.host) : collapse(this.host);
67
64
  if (!this.isLoaded || isMotionReduced())
68
65
  animation.finish();
69
66
  await animation.finished;
70
67
  animation.commitStyles();
71
68
  return this.isOpen;
72
69
  }
70
+ /**
71
+ * Update all post-collapsible-trigger elements referring to the collapsible
72
+ */
73
+ updateTriggers() {
74
+ const triggers = document.querySelectorAll(`post-collapsible-trigger[for=${this.host.id}]`);
75
+ triggers.forEach(trigger => trigger.update());
76
+ }
73
77
  render() {
74
- return (h(Host, { key: 'a4c0bed771143ee6aa8683c75296ef1ecdc462dd', id: this.id, "data-version": version }, h("div", { key: 'f2e76d252d572b7054d99ff605ce6d9f3b86a395', class: "collapse", id: `${this.id}--collapse`, ref: el => (this.collapsible = el) }, h("slot", { key: '94c957e18aaa8a990d5edda77e63226fefe76cd9' }))));
78
+ return (h(Host, { key: 'c24a0524427d6ec5a3a57e12300a5af4cc047a71', "data-version": version }, h("slot", { key: '4d41b67a18ca43acfa0e9ef208c07fa7882baba2' })));
75
79
  }
76
80
  get host() { return this; }
77
81
  static get watchers() { return {
@@ -80,7 +84,6 @@ const PostCollapsible = /*@__PURE__*/ proxyCustomElement(class PostCollapsible e
80
84
  static get style() { return PostCollapsibleStyle0; }
81
85
  }, [1, "post-collapsible", {
82
86
  "collapsed": [4],
83
- "id": [32],
84
87
  "toggle": [64]
85
88
  }, undefined, {
86
89
  "collapsed": ["validateCollapsed"]
@@ -1,7 +1,8 @@
1
1
  import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
2
- import { c as checkEmptyOrOneOf, d as checkEmptyOrType, a as checkType } from './index2.js';
2
+ import { c as checkEmptyOrOneOf, b as checkEmptyOrType } from './index2.js';
3
3
  import { v as version } from './package.js';
4
4
  import { c as checkNonEmpty } from './check-non-empty.js';
5
+ import { c as checkType } from './check-type.js';
5
6
 
6
7
  const postIconCss = ":host{display:inline-block;width:1em;height:1em;vertical-align:-0.15em}span{display:block;width:100%;height:100%;fill:currentColor;forced-color-adjust:preserve-parent-color;background-color:currentColor;-webkit-mask-position:center center;mask-position:center center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-size:100%;mask-size:100%}:host([flip-h]:not([flip-h=false])){scale:-1 1}:host([flip-v]:not([flip-v=false])){scale:1 -1}:host([flip-h][flip-v]:not([flip-h=false],[flip-v=false])){scale:-1}:host([animation]){transform-origin:center}:host([animation=cylon]){animation:icon-animation-cylon .75s ease-in-out infinite alternate}:host([animation=cylon-vertical]){animation:icon-animation-cylon-vertical .75s ease-in-out infinite alternate}:host([animation=spin]){animation:icon-animation-spin 2s linear infinite normal}:host([animation=spin-reverse]){animation:icon-animation-spin 2s linear infinite reverse}:host([animation=fade]){animation:icon-animation-fade .75s ease-in-out infinite alternate}:host([animation=throb]){animation:icon-animation-throb .75s ease-in-out infinite alternate}@keyframes icon-animation-cylon{from{transform:translateX(-25%)}to{transform:translateX(25%)}}@keyframes icon-animation-cylon-vertical{from{transform:translateY(25%)}to{transform:translateY(-25%)}}@keyframes icon-animation-fade{from{opacity:.1}to{opacity:1}}@keyframes icon-animation-spin{from{transform:rotate(0deg)}to{transform:rotate(359deg)}}@keyframes icon-animation-throb{from{opacity:.5;transform:scale(0.5)}to{opacity:1;transform:scale(1)}}";
7
8
  const PostIconStyle0 = postIconCss;
@@ -86,7 +87,7 @@ const PostIcon = /*@__PURE__*/ proxyCustomElement(class PostIcon extends HTMLEle
86
87
  })
87
88
  .filter(([_key, value]) => value !== null)
88
89
  .reduce((styles, [key, value]) => Object.assign(styles, { [key]: value }), {});
89
- return (h(Host, { key: '95fa0f7a09d3430bb5d621e01b57188742920eb4', "data-version": version }, h("span", { key: 'c824e3705dc83665bb6f7649381654e6d1e07dfb', style: svgStyles })));
90
+ return (h(Host, { key: 'c046b74af0d3cc42dcddfbd4aa029ca07be26bf8', "data-version": version }, h("span", { key: 'c49c4d2de0222c665acf1db46f8a13db26f6a26e', style: svgStyles })));
90
91
  }
91
92
  get host() { return this; }
92
93
  static get watchers() { return {
@@ -3,7 +3,7 @@ import { v as version } from './package.js';
3
3
  import { g as getAttributeObserver } from './attribute-observer.js';
4
4
  import { d as defineCustomElement$1 } from './post-popovercontainer2.js';
5
5
 
6
- const postPopoverCss = "/*!\n * Bootstrap Utilities v5.1.3 (https://getbootstrap.com/)\n * Copyright 2011-2021 The Bootstrap Authors\n * Copyright 2011-2021 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n\n * The MIT License (MIT)\n\n * Copyright (c) 2011-2020 Twitter, Inc.\n * Copyright (c) 2011-2020 The Bootstrap Authors\n\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *//*!\n * Copyright 2021 by Swiss Post, Information Technology\n */.btn-close{padding:0;overflow:visible;border:0;background:none;color:inherit;font:inherit;-webkit-user-select:none;user-select:none;appearance:button;border-radius:4px;color:var(--post-gray-80);transition:opacity 250ms,border-color 250ms,background-color 250ms,color 250ms;cursor:pointer}.btn-close{outline-style:none !important;outline-offset:2px !important;outline-width:2px !important;outline-color:var(--post-focus-color) !important}.btn-close:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-style:solid !important;border-radius:4px}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){.btn-close:is(:focus-visible,:focus-within,.pretend-focus){outline-style:solid !important;border-radius:4px}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}.btn-close::before{-webkit-mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m16.267 16.667 6.667-6.533-.933-1.067-6.667 6.667-6.667-6.667-.933 1.067 6.667 6.533-6.667 6.667 1.067.933 6.533-6.667 6.667 6.667.933-1.067z'/%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m16.267 16.667 6.667-6.533-.933-1.067-6.667 6.667-6.667-6.667-.933 1.067 6.667 6.533-6.667 6.667 1.067.933 6.533-6.667 6.667 6.667.933-1.067z'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;content:\"\";display:block;height:1.5rem;width:1.5rem}:is(.bg-dark,.bg-black,.bg-primary,.bg-secondary,.bg-success,.bg-error,.bg-nightblue,.bg-nightblue-bright,.bg-petrol,.bg-coral,.bg-olive,.bg-purple,.bg-purple-bright,.bg-aubergine,.bg-aubergine-bright,.alert-primary,post-alert[type=primary],.alert-success,post-alert[type=success],.alert-danger,post-alert[type=danger],.alert-notification,post-alert[type=notification],.alert-error,post-alert[type=error]) .btn-close{color:var(--post-contrast-color)}.btn-close:focus,.btn-close:not(:disabled):hover,.pretend-hover.btn-close{color:var(--post-contrast-color)}.btn-close:disabled{color:var(--post-gray-40)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close{color:CanvasText;forced-color-adjust:none}.btn-close:focus,.btn-close:not(:disabled):hover,.pretend-hover.btn-close{color:Highlight}}.btn-close-white{color:#e6e6e6}.btn-close-white:focus,.btn-close-white:not(:disabled):hover,.btn-close-white.pretend-hover{color:#fff}.btn-close-white:disabled{color:#999}*{box-sizing:border-box}:host{--post-contrast-color:#fff;--post-bg-rgb:51, 51, 51;display:block}.visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0}.popover-container{display:flex;align-items:self-start;padding:.5em;min-width:160px;max-width:280px}@media (max-width: 599.98px){.popover-container{max-width:100%}}.popover-content{padding:.5em;flex-grow:1}";
6
+ const postPopoverCss = "/*!\n * Bootstrap Utilities v5.1.3 (https://getbootstrap.com/)\n * Copyright 2011-2021 The Bootstrap Authors\n * Copyright 2011-2021 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n\n * The MIT License (MIT)\n\n * Copyright (c) 2011-2020 Twitter, Inc.\n * Copyright (c) 2011-2020 The Bootstrap Authors\n\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *//*!\n * Copyright 2021 by Swiss Post, Information Technology\n */.btn-close{padding:0;overflow:visible;border:0;background:none;color:inherit;font:inherit;-webkit-user-select:none;user-select:none;appearance:button;border-radius:4px;color:var(--post-gray-80);transition:opacity 250ms,border-color 250ms,background-color 250ms,color 250ms;cursor:pointer}.btn-close{outline-style:none !important;outline-offset:2px !important;outline-width:2px !important;outline-color:var(--post-focus-color) !important}.btn-close:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-style:solid !important;border-radius:4px}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close:is(:focus-visible,:has(:focus-visible),.pretend-focus){outline-color:Highlight !important}}@supports not selector(:has(:focus-visible)){.btn-close:is(:focus-visible,:focus-within,.pretend-focus){outline-style:solid !important;border-radius:4px}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close:is(:focus-visible,:focus-within,.pretend-focus){outline-color:Highlight !important}}}.btn-close::before{-webkit-mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m16.267 16.667 6.667-6.533-.933-1.067-6.667 6.667-6.667-6.667-.933 1.067 6.667 6.533-6.667 6.667 1.067.933 6.533-6.667 6.667 6.667.933-1.067z'/%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m16.267 16.667 6.667-6.533-.933-1.067-6.667 6.667-6.667-6.667-.933 1.067 6.667 6.533-6.667 6.667 1.067.933 6.533-6.667 6.667 6.667.933-1.067z'/%3E%3C/svg%3E\");background-color:currentColor;color:currentColor;forced-color-adjust:preserve-parent-color;content:\"\";display:block;height:1.5rem;width:1.5rem}:where(.bg-dark,.bg-black,.bg-primary,.bg-secondary,.bg-success,.bg-error,.bg-nightblue,.bg-nightblue-bright,.bg-petrol,.bg-coral,.bg-olive,.bg-purple,.bg-purple-bright,.bg-aubergine,.bg-aubergine-bright,.alert-primary,post-alert[type=primary],.alert-success,post-alert[type=success],.alert-danger,post-alert[type=danger],.alert-notification,post-alert[type=notification],.alert-error,post-alert[type=error]) .btn-close{color:var(--post-contrast-color)}.btn-close:focus,.btn-close:not(:disabled):hover,.pretend-hover.btn-close{color:var(--post-contrast-color)}.btn-close:disabled{color:var(--post-gray-40)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.btn-close{color:CanvasText;forced-color-adjust:none}.btn-close:focus,.btn-close:not(:disabled):hover,.pretend-hover.btn-close{color:Highlight}}.btn-close-white{color:#e6e6e6}.btn-close-white:focus,.btn-close-white:not(:disabled):hover,.btn-close-white.pretend-hover{color:#fff}.btn-close-white:disabled{color:#999}*{box-sizing:border-box}:host{--post-contrast-color:#fff;--post-bg-rgb:51, 51, 51;display:block}.visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0}.popover-container{display:flex;align-items:self-start;padding:.5em;min-width:160px;max-width:280px}@media (max-width: 599.98px){.popover-container{max-width:100%}}.popover-content{padding:.5em;flex-grow:1}.btn-close{color:inherit}";
7
7
  const PostPopoverStyle0 = postPopoverCss;
8
8
 
9
9
  /**
@@ -96,7 +96,7 @@ const PostPopover = /*@__PURE__*/ proxyCustomElement(class PostPopover extends H
96
96
  this.triggers.forEach(trigger => trigger.setAttribute('aria-expanded', 'false'));
97
97
  }
98
98
  render() {
99
- return (h(Host, { key: '97db4a92db81f3a84ca272af8f79981cf181024d', "data-version": version }, h("post-popovercontainer", { key: '291247845dc11572a5722aa949c1dfa74e521edd', arrow: this.arrow, placement: this.placement, ref: e => (this.popoverRef = e) }, h("div", { key: '92137bf8c92633c8578c89c7b0c8252b0b59e2fa', class: "popover-container" }, h("div", { key: '06f79f59e90ca439b552380af0e151084adadf03', class: "popover-content" }, h("slot", { key: 'c37c742ac7cf24f9440ac3b862761fcd937f7658' })), h("button", { key: '0e6f316574720e0f901af56e0dbb99f86e36c5b4', class: "btn-close", onClick: () => this.hide() }, h("span", { key: '77c41e8e8df74649ce9ca21740c77e78336905e6', class: "visually-hidden" }, this.closeButtonCaption))))));
99
+ return (h(Host, { key: '943dbb1a0a290d281ebe0f346ccd531f8acbbb5e', "data-version": version }, h("post-popovercontainer", { key: 'aa6bf3a2cc395ce612342b78bee23bcd1b68db5e', arrow: this.arrow, placement: this.placement, ref: e => (this.popoverRef = e) }, h("div", { key: '3ba6f039088615157ba47ebc448770fd9128efa0', class: "popover-container" }, h("div", { key: '0472f76d0cf51269029534c29f155e0f71d649fb', class: "popover-content" }, h("slot", { key: '1d722457c871c0aac9297b0517fe077c32e73794' })), h("button", { key: '430fa605ce81aad6b8709c22a31da62cdf6022e5', class: "btn-close", onClick: () => this.hide() }, h("span", { key: '37169089662c8ef1edd8de6389c55f9eee4e1a9e', class: "visually-hidden" }, this.closeButtonCaption))))));
100
100
  }
101
101
  get host() { return this; }
102
102
  static get style() { return PostPopoverStyle0; }
@@ -120,12 +120,21 @@ function getPaddingObject(padding) {
120
120
  };
121
121
  }
122
122
  function rectToClientRect(rect) {
123
+ const {
124
+ x,
125
+ y,
126
+ width,
127
+ height
128
+ } = rect;
123
129
  return {
124
- ...rect,
125
- top: rect.y,
126
- left: rect.x,
127
- right: rect.x + rect.width,
128
- bottom: rect.y + rect.height
130
+ width,
131
+ height,
132
+ top: y,
133
+ left: x,
134
+ right: x + width,
135
+ bottom: y + height,
136
+ x,
137
+ y
129
138
  };
130
139
  }
131
140
 
@@ -1192,6 +1201,15 @@ function isOverflowElement(element) {
1192
1201
  function isTableElement(element) {
1193
1202
  return ['table', 'td', 'th'].includes(getNodeName(element));
1194
1203
  }
1204
+ function isTopLayer(element) {
1205
+ return [':popover-open', ':modal'].some(selector => {
1206
+ try {
1207
+ return element.matches(selector);
1208
+ } catch (e) {
1209
+ return false;
1210
+ }
1211
+ });
1212
+ }
1195
1213
  function isContainingBlock(element) {
1196
1214
  const webkit = isWebKit();
1197
1215
  const css = getComputedStyle(element);
@@ -1202,11 +1220,13 @@ function isContainingBlock(element) {
1202
1220
  function getContainingBlock(element) {
1203
1221
  let currentNode = getParentNode(element);
1204
1222
  while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
1223
+ if (isTopLayer(currentNode)) {
1224
+ return null;
1225
+ }
1205
1226
  if (isContainingBlock(currentNode)) {
1206
1227
  return currentNode;
1207
- } else {
1208
- currentNode = getParentNode(currentNode);
1209
1228
  }
1229
+ currentNode = getParentNode(currentNode);
1210
1230
  }
1211
1231
  return null;
1212
1232
  }
@@ -1228,8 +1248,8 @@ function getNodeScroll(element) {
1228
1248
  };
1229
1249
  }
1230
1250
  return {
1231
- scrollLeft: element.pageXOffset,
1232
- scrollTop: element.pageYOffset
1251
+ scrollLeft: element.scrollX,
1252
+ scrollTop: element.scrollY
1233
1253
  };
1234
1254
  }
1235
1255
  function getParentNode(node) {
@@ -1401,17 +1421,6 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
1401
1421
  });
1402
1422
  }
1403
1423
 
1404
- const topLayerSelectors = [':popover-open', ':modal'];
1405
- function isTopLayer(element) {
1406
- return topLayerSelectors.some(selector => {
1407
- try {
1408
- return element.matches(selector);
1409
- } catch (e) {
1410
- return false;
1411
- }
1412
- });
1413
- }
1414
-
1415
1424
  function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
1416
1425
  let {
1417
1426
  elements,
@@ -2031,7 +2040,7 @@ const computePosition = (reference, floating, options) => {
2031
2040
  }
2032
2041
  `,E=null;function I(e){if(E===null)try{E=new CSSStyleSheet,E.replaceSync(C);}catch{E=!1;}if(E===!1){let t=document.createElement("style");t.textContent=C,e instanceof Document?e.head.prepend(t):e.prepend(t);}else e.adoptedStyleSheets=[E,...e.adoptedStyleSheets];}function K(){window.ToggleEvent=window.ToggleEvent||c;function e(n){return n?.includes(":popover-open")&&(n=n.replace(J,"$1.\\:popover-open")),n}f(Document.prototype,"querySelector",e),f(Document.prototype,"querySelectorAll",e),f(Element.prototype,"querySelector",e),f(Element.prototype,"querySelectorAll",e),f(Element.prototype,"matches",e),f(Element.prototype,"closest",e),f(DocumentFragment.prototype,"querySelectorAll",e),f(DocumentFragment.prototype,"querySelectorAll",e),Object.defineProperties(HTMLElement.prototype,{popover:{enumerable:!0,configurable:!0,get(){if(!this.hasAttribute("popover"))return null;let n=(this.getAttribute("popover")||"").toLowerCase();return n===""||n=="auto"?"auto":"manual"},set(n){this.setAttribute("popover",n);}},showPopover:{enumerable:!0,configurable:!0,value(){S(this);}},hidePopover:{enumerable:!0,configurable:!0,value(){m(this,!0,!0);}},togglePopover:{enumerable:!0,configurable:!0,value(n){h.get(this)==="showing"&&n===void 0||n===!1?m(this,!0,!0):(n===void 0||n===!0)&&S(this);}}});let t=Element.prototype.attachShadow;t&&Object.defineProperties(Element.prototype,{attachShadow:{enumerable:!0,configurable:!0,writable:!0,value(n){let s=t.call(this,n);return I(s),s}}});let o=HTMLElement.prototype.attachInternals;o&&Object.defineProperties(HTMLElement.prototype,{attachInternals:{enumerable:!0,configurable:!0,writable:!0,value(){let n=o.call(this);return n.shadowRoot&&I(n.shadowRoot),n}}});let r=new WeakMap;function i(n){Object.defineProperties(n.prototype,{popoverTargetElement:{enumerable:!0,configurable:!0,set(s){if(s===null)this.removeAttribute("popovertarget"),r.delete(this);else if(s instanceof Element)this.setAttribute("popovertarget",""),r.set(this,s);else throw new TypeError("popoverTargetElement must be an element or null")},get(){if(this.localName!=="button"&&this.localName!=="input"||this.localName==="input"&&this.type!=="reset"&&this.type!=="image"&&this.type!=="button"||this.disabled||this.form&&this.type==="submit")return null;let s=r.get(this);if(s&&s.isConnected)return s;if(s&&!s.isConnected)return r.delete(this),null;let u=v(this),w=this.getAttribute("popovertarget");return (u instanceof Document||u instanceof B)&&w&&u.getElementById(w)||null}},popoverTargetAction:{enumerable:!0,configurable:!0,get(){let s=(this.getAttribute("popovertargetaction")||"").toLowerCase();return s==="show"||s==="hide"?s:"toggle"},set(s){this.setAttribute("popovertargetaction",s);}}});}i(HTMLButtonElement),i(HTMLInputElement);let l=n=>{if(!n.isTrusted)return;let s=n.composedPath()[0];if(!(s instanceof Element)||s?.shadowRoot)return;let u=v(s);if(!(u instanceof B||u instanceof Document))return;let w=s.closest("[popovertargetaction],[popovertarget]");if(w){O(w),n.preventDefault();return}},a=n=>{let s=n.key,u=n.target;!n.defaultPrevented&&u&&(s==="Escape"||s==="Esc")&&T(u.ownerDocument,!0,!0);};(n=>{n.addEventListener("click",l),n.addEventListener("keydown",a),n.addEventListener("pointerdown",x),n.addEventListener("pointerup",x);})(document),I(document);}j()||K();})();
2033
2042
 
2034
- const postPopovercontainerCss = "@layer polyfill{@supports not selector(:popover-open){[popover]:not(.\\:popover-open){display:none}}}.popover{box-shadow:.5px 3px 4px rgba(0,0,0,.1),2px 4px 10px 4px rgba(0,0,0,.12);position:fixed;z-index:1060;width:max-content;margin:0;padding:0;box-sizing:border-box;color:var(--post-contrast-color);background-color:rgb(var(--post-bg-rgb));border:2px solid rgba(0,0,0,0);border-radius:4px;overflow:visible}.arrow{position:absolute;width:.5825rem;height:.5825rem;background-color:inherit;rotate:45deg;pointer-events:none;z-index:-1}.arrow.top{border-left:2px solid rgba(0,0,0,0);border-top:2px solid rgba(0,0,0,0)}.arrow.right{border-right:2px solid rgba(0,0,0,0);border-top:2px solid rgba(0,0,0,0)}.arrow.left{border-left:2px solid rgba(0,0,0,0);border-bottom:2px solid rgba(0,0,0,0)}.arrow.bottom{border-right:2px solid rgba(0,0,0,0);border-bottom:2px solid rgba(0,0,0,0)}";
2043
+ const postPopovercontainerCss = "@layer polyfill{@supports not selector(:popover-open){[popover]:not(.\\:popover-open){display:none}}}:where(post-popovercontainer){box-shadow:.5px 3px 4px rgba(0,0,0,.1),2px 4px 10px 4px rgba(0,0,0,.12);position:fixed;z-index:1060;width:max-content;margin:0;padding:0;box-sizing:border-box;color:var(--post-contrast-color);background-color:rgb(var(--post-bg-rgb));border:2px solid rgba(0,0,0,0);border-radius:4px;overflow:visible}:where(post-popovercontainer) .arrow{position:absolute;width:.5825rem;height:.5825rem;background-color:inherit;rotate:45deg;pointer-events:none;z-index:-1}:where(post-popovercontainer) .arrow.top{border-left:2px solid rgba(0,0,0,0);border-top:2px solid rgba(0,0,0,0)}:where(post-popovercontainer) .arrow.right{border-right:2px solid rgba(0,0,0,0);border-top:2px solid rgba(0,0,0,0)}:where(post-popovercontainer) .arrow.left{border-left:2px solid rgba(0,0,0,0);border-bottom:2px solid rgba(0,0,0,0)}:where(post-popovercontainer) .arrow.bottom{border-right:2px solid rgba(0,0,0,0);border-bottom:2px solid rgba(0,0,0,0)}";
2035
2044
  const PostPopovercontainerStyle0 = postPopovercontainerCss;
2036
2045
 
2037
2046
  const SIDE_MAP = {
@@ -2044,18 +2053,15 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
2044
2053
  constructor() {
2045
2054
  super();
2046
2055
  this.__registerHost();
2047
- this.__attachShadow();
2048
2056
  this.postToggle = createEvent(this, "postToggle", 7);
2049
2057
  this.placement = 'top';
2050
2058
  this.arrow = false;
2051
2059
  }
2052
2060
  componentDidLoad() {
2053
- this.popoverRef.setAttribute('popover', '');
2054
- this.popoverRef.addEventListener('beforetoggle', this.handleToggle.bind(this));
2061
+ this.host.setAttribute('popover', '');
2062
+ this.host.addEventListener('beforetoggle', this.handleToggle.bind(this));
2055
2063
  }
2056
2064
  disconnectedCallback() {
2057
- if (this.popoverRef)
2058
- this.popoverRef.removeEventListener('beforetoggle', e => this.toggle(e.target));
2059
2065
  if (typeof this.clearAutoUpdate === 'function')
2060
2066
  this.clearAutoUpdate();
2061
2067
  }
@@ -2067,7 +2073,7 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
2067
2073
  if (!this.toggleTimeoutId) {
2068
2074
  this.eventTarget = target;
2069
2075
  this.calculatePosition();
2070
- this.popoverRef.showPopover();
2076
+ this.host.showPopover();
2071
2077
  }
2072
2078
  }
2073
2079
  /**
@@ -2076,7 +2082,7 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
2076
2082
  async hide() {
2077
2083
  if (!this.toggleTimeoutId) {
2078
2084
  this.eventTarget = null;
2079
- this.popoverRef.hidePopover();
2085
+ this.host.hidePopover();
2080
2086
  }
2081
2087
  }
2082
2088
  /**
@@ -2089,10 +2095,10 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
2089
2095
  if (!this.toggleTimeoutId) {
2090
2096
  this.eventTarget = target;
2091
2097
  this.calculatePosition();
2092
- this.popoverRef.togglePopover(force);
2098
+ this.host.togglePopover(force);
2093
2099
  this.toggleTimeoutId = null;
2094
2100
  }
2095
- return this.popoverRef.matches(':popover-open');
2101
+ return this.host.matches(':where(:popover-open, .popover-open');
2096
2102
  }
2097
2103
  /**
2098
2104
  * Start or stop auto updates based on tooltip events.
@@ -2117,7 +2123,7 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
2117
2123
  * an influence on tooltip positioning
2118
2124
  */
2119
2125
  startAutoupdates() {
2120
- this.clearAutoUpdate = autoUpdate(this.eventTarget, this.popoverRef, this.calculatePosition.bind(this));
2126
+ this.clearAutoUpdate = autoUpdate(this.eventTarget, this.host, this.calculatePosition.bind(this));
2121
2127
  }
2122
2128
  async calculatePosition() {
2123
2129
  const middleware = [
@@ -2143,14 +2149,14 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
2143
2149
  if (this.arrow) {
2144
2150
  middleware.push(arrow({ element: this.arrowRef, padding: 8 }));
2145
2151
  }
2146
- const { x, y, middlewareData, placement: currentPlacement, } = await computePosition(this.eventTarget, this.popoverRef, {
2152
+ const { x, y, middlewareData, placement: currentPlacement, } = await computePosition(this.eventTarget, this.host, {
2147
2153
  placement: this.placement || 'top',
2148
2154
  strategy: 'fixed',
2149
2155
  middleware,
2150
2156
  });
2151
2157
  // Tooltip
2152
- this.popoverRef.style.left = `${x}px`;
2153
- this.popoverRef.style.top = `${y}px`;
2158
+ this.host.style.left = `${x}px`;
2159
+ this.host.style.top = `${y}px`;
2154
2160
  // Arrow
2155
2161
  if (this.arrow) {
2156
2162
  // Tutorial: https://codesandbox.io/s/mystifying-kare-ee3hmh?file=/src/index.js
@@ -2169,13 +2175,13 @@ const PostPopovercontainer = /*@__PURE__*/ proxyCustomElement(class PostPopoverc
2169
2175
  }
2170
2176
  }
2171
2177
  render() {
2172
- return (h(Host, { key: '1707db71258eef7c95c13d738561d9d55df540fc', "data-version": version }, h("div", { key: 'd1d89bfc31529c803b04f2395509fe96b38d7d7a', class: "popover", part: "popover", ref: (el) => (this.popoverRef = el) }, this.arrow && (h("span", { key: 'd85fc5f68be0ff8060b3be823e22744873395775', class: "arrow", ref: el => {
2178
+ return (h(Host, { key: '944364458c19e3a11171571402f183449dafff24', "data-version": version }, this.arrow && (h("span", { key: 'f77a61b4b6f4f4ceb861ef8eb7d16f71f45642ec', class: "arrow", ref: el => {
2173
2179
  this.arrowRef = el;
2174
- } })), h("slot", { key: '7bd455d61d270b9d6cdc132ffb7a00f0259164e7' }))));
2180
+ } })), h("slot", { key: 'feeedfe09388dca41ee1048c8702c68bd0a91d33' })));
2175
2181
  }
2176
2182
  get host() { return this; }
2177
2183
  static get style() { return PostPopovercontainerStyle0; }
2178
- }, [1, "post-popovercontainer", {
2184
+ }, [4, "post-popovercontainer", {
2179
2185
  "placement": [1],
2180
2186
  "arrow": [4],
2181
2187
  "show": [64],
@@ -74,7 +74,7 @@ const PostRating = /*@__PURE__*/ proxyCustomElement(class PostRating extends HTM
74
74
  }
75
75
  }
76
76
  render() {
77
- return (h(Host, { key: '64081561d0b0819ed5fbe31c0bc7974b996ec582', "data-version": version }, h("div", { key: 'eaed95cef70f1dfa815a77e3d630ac933d2c1eff', role: "slider", class: "rating", tabindex: "0", "aria-label": this.label, "aria-valuemin": "0", "aria-valuemax": this.stars, "aria-valuenow": this.currentRating, "aria-valuetext": `${this.currentRating} out of ${this.stars}`, "aria-readonly": this.readonly ? 'true' : 'false', onKeyDown: this.keydownHandler, onBlur: this.blurHandler }, Array.from({ length: this.stars }).map((v, i) => (h("div", { key: `star-${v}`, "aria-hidden": "true", class: {
77
+ return (h(Host, { key: 'b175b250377f4bf9be92ad05fb14f7e4a8f7c12f', "data-version": version }, h("div", { key: 'b12eb5ff191d5a4ac5270845f120360f61e0fce0', role: "slider", class: "rating", tabindex: "0", "aria-label": this.label, "aria-valuemin": "0", "aria-valuemax": this.stars, "aria-valuenow": this.currentRating, "aria-valuetext": `${this.currentRating} out of ${this.stars}`, "aria-readonly": this.readonly ? 'true' : 'false', onKeyDown: this.keydownHandler, onBlur: this.blurHandler }, Array.from({ length: this.stars }).map((v, i) => (h("div", { key: `star-${v}`, "aria-hidden": "true", class: {
78
78
  'star': true,
79
79
  'before-hover': i < this.hoveredIndex,
80
80
  'active': i < Math.round(this.currentRating),
@@ -2,7 +2,7 @@ import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal
2
2
  import { v as version } from './package.js';
3
3
  import { c as checkNonEmpty } from './check-non-empty.js';
4
4
 
5
- const postTabHeaderCss = ".tab-title[role=tab]{display:inline-block;cursor:pointer;position:relative;box-sizing:border-box;padding:1rem;transition:background-color 100ms;border-right:1px solid rgba(0,0,0,0);border-left:1px solid rgba(0,0,0,0);outline-color:currentColor;opacity:.7;color:var(--post-contrast-color);text-decoration:none;background-color:rgba(0,0,0,0)}.tab-title[role=tab]:focus{background-color:unset;color:var(--post-contrast-color)}.tab-title[role=tab]:hover{opacity:1;background-color:rgba(var(--post-contrast-color-rgb), 0.6);color:var(--post-contrast-color-inverted)}.tab-title[role=tab]:focus-visible{outline:rgba(0,0,0,0);opacity:1;background-color:rgba(var(--post-contrast-color-rgb), 0.6);color:var(--post-contrast-color-inverted);box-shadow:none}.tab-title[role=tab]:focus-visible::after{content:\"\";display:block;position:absolute;top:2px;right:1px;bottom:0;left:1px;box-shadow:0 0 0 1px #fff,0 0 0 2px #333}.tab-title[role=tab].active{z-index:1;border-right-color:#ccc;border-left-color:#ccc;opacity:1;background-color:var(--post-contrast-color-inverted);color:var(--post-contrast-color);font-weight:700}.tab-title[role=tab].active::before{content:\"\";display:block;position:absolute;top:0;right:-1px;left:-1px;height:.25rem;background-color:#fc0}:is(.bg-dark,.bg-black,.bg-primary,.bg-secondary,.bg-success,.bg-error,.bg-nightblue,.bg-nightblue-bright,.bg-petrol,.bg-coral,.bg-olive,.bg-purple,.bg-purple-bright,.bg-aubergine,.bg-aubergine-bright,.alert-primary,post-alert[type=primary],.alert-success,post-alert[type=success],.alert-danger,post-alert[type=danger],.alert-notification,post-alert[type=notification],.alert-error,post-alert[type=error]) .tab-title[role=tab]:hover{background-color:rgba(255,255,255,.2)}:is(.bg-dark,.bg-black,.bg-primary,.bg-secondary,.bg-success,.bg-error,.bg-nightblue,.bg-nightblue-bright,.bg-petrol,.bg-coral,.bg-olive,.bg-purple,.bg-purple-bright,.bg-aubergine,.bg-aubergine-bright,.alert-primary,post-alert[type=primary],.alert-success,post-alert[type=success],.alert-danger,post-alert[type=danger],.alert-notification,post-alert[type=notification],.alert-error,post-alert[type=error]) .tab-title[role=tab]:focus-visible{background-color:rgba(255,255,255,.2)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.tab-title[role=tab]{opacity:1;border-left-color:Canvas;border-right-color:Canvas;color:LinkText}.tab-title[role=tab]:hover,.tab-title[role=tab]:focus,.tab-title[role=tab]:focus-within,.tab-title[role=tab]:focus-visible{outline:2px solid Highlight;outline-offset:-0.25rem}.tab-title[role=tab].active{border-left-color:ButtonText;border-right-color:ButtonText;color:Highlight}.tab-title[role=tab].active::before{background-color:Highlight}}.bg-yellow .tab-title{background-color:#fc0}.bg-yellow .tab-title.active{background-color:#fc0}.bg-yellow .nav-item{background-color:#fc0}.bg-white .tab-title{background-color:#fff}.bg-white .tab-title.active{background-color:#fff}.bg-white .nav-item{background-color:#fff}.bg-light .tab-title{background-color:#faf9f8}.bg-light .tab-title.active{background-color:#faf9f8}.bg-light .nav-item{background-color:#faf9f8}.bg-gray .tab-title{background-color:#f4f3f1}.bg-gray .tab-title.active{background-color:#f4f3f1}.bg-gray .nav-item{background-color:#f4f3f1}.bg-dark .tab-title{background-color:#333}.bg-dark .tab-title.active{background-color:#333}.bg-dark .nav-item{background-color:#333}.bg-black .tab-title{background-color:#000}.bg-black .tab-title.active{background-color:#000}.bg-black .nav-item{background-color:#000}.bg-primary .tab-title{background-color:#333}.bg-primary .tab-title.active{background-color:#333}.bg-primary .nav-item{background-color:#333}.bg-secondary .tab-title{background-color:#666}.bg-secondary .tab-title.active{background-color:#666}.bg-secondary .nav-item{background-color:#666}.bg-success .tab-title{background-color:#2c871d}.bg-success .tab-title.active{background-color:#2c871d}.bg-success .nav-item{background-color:#2c871d}.bg-warning .tab-title{background-color:#f49e00}.bg-warning .tab-title.active{background-color:#f49e00}.bg-warning .nav-item{background-color:#f49e00}.bg-error .tab-title{background-color:#a51728}.bg-error .tab-title.active{background-color:#a51728}.bg-error .nav-item{background-color:#a51728}.bg-info .tab-title{background-color:#cce4ee}.bg-info .tab-title.active{background-color:#cce4ee}.bg-info .nav-item{background-color:#cce4ee}.bg-success-background .tab-title{background-color:#c0debb}.bg-success-background .tab-title.active{background-color:#c0debb}.bg-success-background .nav-item{background-color:#c0debb}.bg-warning-background .tab-title{background-color:#fce2b2}.bg-warning-background .tab-title.active{background-color:#fce2b2}.bg-warning-background .nav-item{background-color:#fce2b2}.bg-error-background .tab-title{background-color:#ffdade}.bg-error-background .tab-title.active{background-color:#ffdade}.bg-error-background .nav-item{background-color:#ffdade}.bg-nightblue .tab-title{background-color:#004976}.bg-nightblue .tab-title.active{background-color:#004976}.bg-nightblue .nav-item{background-color:#004976}.bg-nightblue-bright .tab-title{background-color:#0076a8}.bg-nightblue-bright .tab-title.active{background-color:#0076a8}.bg-nightblue-bright .nav-item{background-color:#0076a8}.bg-petrol .tab-title{background-color:#006d68}.bg-petrol .tab-title.active{background-color:#006d68}.bg-petrol .nav-item{background-color:#006d68}.bg-petrol-bright .tab-title{background-color:#00968f}.bg-petrol-bright .tab-title.active{background-color:#00968f}.bg-petrol-bright .nav-item{background-color:#00968f}.bg-coral .tab-title{background-color:#9e2a2f}.bg-coral .tab-title.active{background-color:#9e2a2f}.bg-coral .nav-item{background-color:#9e2a2f}.bg-coral-bright .tab-title{background-color:#e03c31}.bg-coral-bright .tab-title.active{background-color:#e03c31}.bg-coral-bright .nav-item{background-color:#e03c31}.bg-olive .tab-title{background-color:#716135}.bg-olive .tab-title.active{background-color:#716135}.bg-olive .nav-item{background-color:#716135}.bg-olive-bright .tab-title{background-color:#aa9d2e}.bg-olive-bright .tab-title.active{background-color:#aa9d2e}.bg-olive-bright .nav-item{background-color:#aa9d2e}.bg-purple .tab-title{background-color:#80276c}.bg-purple .tab-title.active{background-color:#80276c}.bg-purple .nav-item{background-color:#80276c}.bg-purple-bright .tab-title{background-color:#c5299b}.bg-purple-bright .tab-title.active{background-color:#c5299b}.bg-purple-bright .nav-item{background-color:#c5299b}.bg-aubergine .tab-title{background-color:#523178}.bg-aubergine .tab-title.active{background-color:#523178}.bg-aubergine .nav-item{background-color:#523178}.bg-aubergine-bright .tab-title{background-color:#7566a0}.bg-aubergine-bright .tab-title.active{background-color:#7566a0}.bg-aubergine-bright .nav-item{background-color:#7566a0}[class*=bg-] .tab-title.active:focus::after{background-color:rgba(255,255,255,.2)}@supports selector(*:focus-visible){[class*=bg-] .tab-title.active:focus::after{background-color:unset}[class*=bg-] .tab-title.active:focus-visible::after{background-color:rgba(255,255,255,.2)}}/*!\n * Bootstrap Utilities v5.1.3 (https://getbootstrap.com/)\n * Copyright 2011-2021 The Bootstrap Authors\n * Copyright 2011-2021 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n\n * The MIT License (MIT)\n\n * Copyright (c) 2011-2020 Twitter, Inc.\n * Copyright (c) 2011-2020 The Bootstrap Authors\n\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *//*!\n * Copyright 2021 by Swiss Post, Information Technology\n */:host{display:block}.tab-title{padding:0;overflow:visible;border:0;background:none;color:inherit;font:inherit;-webkit-user-select:none;user-select:none;appearance:button}";
5
+ const postTabHeaderCss = ".tab-title[role=tab]{display:inline-block;cursor:pointer;position:relative;box-sizing:border-box;padding:1rem;transition:background-color 100ms;border-right:1px solid rgba(0,0,0,0);border-left:1px solid rgba(0,0,0,0);outline-color:currentColor;opacity:.7;color:var(--post-contrast-color);text-decoration:none;background-color:rgba(0,0,0,0)}.tab-title[role=tab]:focus{background-color:unset;color:var(--post-contrast-color)}.tab-title[role=tab]:hover{opacity:1;background-color:rgba(var(--post-contrast-color-rgb), 0.6);color:var(--post-contrast-color-inverted)}.tab-title[role=tab]:focus-visible{outline:rgba(0,0,0,0);opacity:1;background-color:rgba(var(--post-contrast-color-rgb), 0.6);color:var(--post-contrast-color-inverted);box-shadow:none}.tab-title[role=tab]:focus-visible::after{content:\"\";display:block;position:absolute;top:2px;right:1px;bottom:0;left:1px;box-shadow:0 0 0 1px #fff,0 0 0 2px #333}.tab-title[role=tab].active{z-index:1;border-right-color:#ccc;border-left-color:#ccc;opacity:1;background-color:var(--post-contrast-color-inverted);color:var(--post-contrast-color);font-weight:700}.tab-title[role=tab].active::before{content:\"\";display:block;position:absolute;top:0;right:-1px;left:-1px;height:.25rem;background-color:#fc0}:where(.bg-dark,.bg-black,.bg-primary,.bg-secondary,.bg-success,.bg-error,.bg-nightblue,.bg-nightblue-bright,.bg-petrol,.bg-coral,.bg-olive,.bg-purple,.bg-purple-bright,.bg-aubergine,.bg-aubergine-bright,.alert-primary,post-alert[type=primary],.alert-success,post-alert[type=success],.alert-danger,post-alert[type=danger],.alert-notification,post-alert[type=notification],.alert-error,post-alert[type=error]) .tab-title[role=tab]:hover{background-color:rgba(255,255,255,.2)}:where(.bg-dark,.bg-black,.bg-primary,.bg-secondary,.bg-success,.bg-error,.bg-nightblue,.bg-nightblue-bright,.bg-petrol,.bg-coral,.bg-olive,.bg-purple,.bg-purple-bright,.bg-aubergine,.bg-aubergine-bright,.alert-primary,post-alert[type=primary],.alert-success,post-alert[type=success],.alert-danger,post-alert[type=danger],.alert-notification,post-alert[type=notification],.alert-error,post-alert[type=error]) .tab-title[role=tab]:focus-visible{background-color:rgba(255,255,255,.2)}@media (forced-colors: active),(-ms-high-contrast: active),(-ms-high-contrast: white-on-black){.tab-title[role=tab]{opacity:1;border-left-color:Canvas;border-right-color:Canvas;color:LinkText}.tab-title[role=tab]:hover,.tab-title[role=tab]:focus,.tab-title[role=tab]:focus-within,.tab-title[role=tab]:focus-visible{outline:2px solid Highlight;outline-offset:-0.25rem}.tab-title[role=tab].active{border-left-color:ButtonText;border-right-color:ButtonText;color:Highlight}.tab-title[role=tab].active::before{background-color:Highlight}}.bg-yellow .tab-title{background-color:#fc0}.bg-yellow .tab-title.active{background-color:#fc0}.bg-yellow .nav-item{background-color:#fc0}.bg-white .tab-title{background-color:#fff}.bg-white .tab-title.active{background-color:#fff}.bg-white .nav-item{background-color:#fff}.bg-light .tab-title{background-color:#faf9f8}.bg-light .tab-title.active{background-color:#faf9f8}.bg-light .nav-item{background-color:#faf9f8}.bg-gray .tab-title{background-color:#f4f3f1}.bg-gray .tab-title.active{background-color:#f4f3f1}.bg-gray .nav-item{background-color:#f4f3f1}.bg-dark .tab-title{background-color:#333}.bg-dark .tab-title.active{background-color:#333}.bg-dark .nav-item{background-color:#333}.bg-black .tab-title{background-color:#000}.bg-black .tab-title.active{background-color:#000}.bg-black .nav-item{background-color:#000}.bg-primary .tab-title{background-color:#333}.bg-primary .tab-title.active{background-color:#333}.bg-primary .nav-item{background-color:#333}.bg-secondary .tab-title{background-color:#666}.bg-secondary .tab-title.active{background-color:#666}.bg-secondary .nav-item{background-color:#666}.bg-success .tab-title{background-color:#2c871d}.bg-success .tab-title.active{background-color:#2c871d}.bg-success .nav-item{background-color:#2c871d}.bg-warning .tab-title{background-color:#f49e00}.bg-warning .tab-title.active{background-color:#f49e00}.bg-warning .nav-item{background-color:#f49e00}.bg-error .tab-title{background-color:#a51728}.bg-error .tab-title.active{background-color:#a51728}.bg-error .nav-item{background-color:#a51728}.bg-info .tab-title{background-color:#cce4ee}.bg-info .tab-title.active{background-color:#cce4ee}.bg-info .nav-item{background-color:#cce4ee}.bg-success-background .tab-title{background-color:#c0debb}.bg-success-background .tab-title.active{background-color:#c0debb}.bg-success-background .nav-item{background-color:#c0debb}.bg-warning-background .tab-title{background-color:#fce2b2}.bg-warning-background .tab-title.active{background-color:#fce2b2}.bg-warning-background .nav-item{background-color:#fce2b2}.bg-error-background .tab-title{background-color:#ffdade}.bg-error-background .tab-title.active{background-color:#ffdade}.bg-error-background .nav-item{background-color:#ffdade}.bg-nightblue .tab-title{background-color:#004976}.bg-nightblue .tab-title.active{background-color:#004976}.bg-nightblue .nav-item{background-color:#004976}.bg-nightblue-bright .tab-title{background-color:#0076a8}.bg-nightblue-bright .tab-title.active{background-color:#0076a8}.bg-nightblue-bright .nav-item{background-color:#0076a8}.bg-petrol .tab-title{background-color:#006d68}.bg-petrol .tab-title.active{background-color:#006d68}.bg-petrol .nav-item{background-color:#006d68}.bg-petrol-bright .tab-title{background-color:#00968f}.bg-petrol-bright .tab-title.active{background-color:#00968f}.bg-petrol-bright .nav-item{background-color:#00968f}.bg-coral .tab-title{background-color:#9e2a2f}.bg-coral .tab-title.active{background-color:#9e2a2f}.bg-coral .nav-item{background-color:#9e2a2f}.bg-coral-bright .tab-title{background-color:#e03c31}.bg-coral-bright .tab-title.active{background-color:#e03c31}.bg-coral-bright .nav-item{background-color:#e03c31}.bg-olive .tab-title{background-color:#716135}.bg-olive .tab-title.active{background-color:#716135}.bg-olive .nav-item{background-color:#716135}.bg-olive-bright .tab-title{background-color:#aa9d2e}.bg-olive-bright .tab-title.active{background-color:#aa9d2e}.bg-olive-bright .nav-item{background-color:#aa9d2e}.bg-purple .tab-title{background-color:#80276c}.bg-purple .tab-title.active{background-color:#80276c}.bg-purple .nav-item{background-color:#80276c}.bg-purple-bright .tab-title{background-color:#c5299b}.bg-purple-bright .tab-title.active{background-color:#c5299b}.bg-purple-bright .nav-item{background-color:#c5299b}.bg-aubergine .tab-title{background-color:#523178}.bg-aubergine .tab-title.active{background-color:#523178}.bg-aubergine .nav-item{background-color:#523178}.bg-aubergine-bright .tab-title{background-color:#7566a0}.bg-aubergine-bright .tab-title.active{background-color:#7566a0}.bg-aubergine-bright .nav-item{background-color:#7566a0}[class*=bg-] .tab-title.active:focus::after{background-color:rgba(255,255,255,.2)}@supports selector(*:focus-visible){[class*=bg-] .tab-title.active:focus::after{background-color:unset}[class*=bg-] .tab-title.active:focus-visible::after{background-color:rgba(255,255,255,.2)}}/*!\n * Bootstrap Utilities v5.1.3 (https://getbootstrap.com/)\n * Copyright 2011-2021 The Bootstrap Authors\n * Copyright 2011-2021 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n\n * The MIT License (MIT)\n\n * Copyright (c) 2011-2020 Twitter, Inc.\n * Copyright (c) 2011-2020 The Bootstrap Authors\n\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *//*!\n * Copyright 2021 by Swiss Post, Information Technology\n */:host{display:block}.tab-title{padding:0;overflow:visible;border:0;background:none;color:inherit;font:inherit;-webkit-user-select:none;user-select:none;appearance:button}";
6
6
  const PostTabHeaderStyle0 = postTabHeaderCss;
7
7
 
8
8
  const PostTabHeader = /*@__PURE__*/ proxyCustomElement(class PostTabHeader extends HTMLElement {
@@ -20,7 +20,7 @@ const PostTabHeader = /*@__PURE__*/ proxyCustomElement(class PostTabHeader exten
20
20
  this.tabId = `tab-${this.host.id || crypto.randomUUID()}`;
21
21
  }
22
22
  render() {
23
- return (h(Host, { key: 'eb6ac6a67f4cbf571d38f1de1c8d428a9dea5a53', id: this.tabId, role: "tab", "data-version": version, "aria-selected": "false", tabindex: "-1", class: "tab-title" }, h("slot", { key: 'd6559dbcc76ecc8d253fcd4a115b4bc4f78fd496' })));
23
+ return (h(Host, { key: '543284f0251b7edff35b0fc4f260c7ba1447d57a', id: this.tabId, role: "tab", "data-version": version, "aria-selected": "false", tabindex: "-1", class: "tab-title" }, h("slot", { key: 'c8ed807ea7fbd6fd5ab0e06724fd49852c5e15bf' })));
24
24
  }
25
25
  get host() { return this; }
26
26
  static get watchers() { return {
@@ -17,7 +17,7 @@ const PostTabPanel = /*@__PURE__*/ proxyCustomElement(class PostTabPanel extends
17
17
  this.panelId = `panel-${this.host.id || crypto.randomUUID()}`;
18
18
  }
19
19
  render() {
20
- return (h(Host, { key: 'cd74acf8889af916b9b32b57b483bbd74d5a6e20', "data-version": version, id: this.panelId, role: "tabpanel" }, h("slot", { key: '9d2c3f42b1dd9214aeeee35efc1179372851af13' })));
20
+ return (h(Host, { key: '2b7e8f1853df072796345126b60ed2b6315362a2', "data-version": version, id: this.panelId, role: "tabpanel" }, h("slot", { key: '77c2b1c1f7d141fd3f9b71c504cdd9a5ce61260b' })));
21
21
  }
22
22
  get host() { return this; }
23
23
  static get style() { return PostTabPanelStyle0; }
@@ -43,19 +43,17 @@ const PostTabs = /*@__PURE__*/ proxyCustomElement(class PostTabs extends HTMLEle
43
43
  this.showing.finish();
44
44
  }
45
45
  // hide the currently visible panel only if no other animation is running
46
- if (previousTab && !this.showing && !this.hiding) {
46
+ if (previousTab && !this.showing && !this.hiding)
47
47
  this.hidePanel(previousTab.panel);
48
- }
49
48
  // wait for any hiding animation to complete before showing the selected tab
50
- if (this.hiding) {
49
+ if (this.hiding)
51
50
  await this.hiding.finished;
52
- }
53
51
  this.showSelectedPanel();
54
52
  // wait for any display animation to complete for the returned promise to fully resolve
55
- if (this.showing) {
53
+ if (this.showing)
56
54
  await this.showing.finished;
57
- }
58
- this.postChange.emit(this.activeTab.panel);
55
+ if (this.isLoaded)
56
+ this.postChange.emit(this.activeTab.panel);
59
57
  }
60
58
  moveMisplacedTabs() {
61
59
  if (!this.tabs)
@@ -145,7 +143,7 @@ const PostTabs = /*@__PURE__*/ proxyCustomElement(class PostTabs extends HTMLEle
145
143
  nextTab.focus();
146
144
  }
147
145
  render() {
148
- return (h(Host, { key: '38a0e3f686dab8cc1ea9dc23cc6e275fe0e6b45d', "data-version": version }, h("div", { key: 'c67273069e5d3ba858bd6c5da8684bbd2f8c398b', class: "tabs-wrapper" }, h("div", { key: 'fc3e725607107f3b5d3c969e4107c229ca8f8c66', class: "tabs", role: "tablist" }, h("slot", { key: 'caf8d1a6901327d0b8faebb36ce239d7368e2a22', name: "tabs", onSlotchange: () => this.enableTabs() }))), h("div", { key: 'f8cf7c8c8cbb3fd308cebc34513b16926f8e5c81', class: "tab-content" }, h("slot", { key: '7f7ff954545f85e6caab71d7265017607e25262b', onSlotchange: () => this.moveMisplacedTabs() }))));
146
+ return (h(Host, { key: '365b2794cfb46631277341ea23afb2070c9d3ad1', "data-version": version }, h("div", { key: '70df13385ecc9c067527b80e2dd7b3a9b245e745', class: "tabs-wrapper", part: "tabs" }, h("div", { key: 'cae4d18aff0c890e0e8d76c1b8e321322abbeccd', class: "tabs", role: "tablist" }, h("slot", { key: '2b6ca3e01e45e541950ddc2c1cdc680b28ea96b9', name: "tabs", onSlotchange: () => this.enableTabs() }))), h("div", { key: '7352582d9c738af9b8bf3b71e0a153132fd23dcd', class: "tab-content", part: "content" }, h("slot", { key: '4845c39bf9b9cbc42aa8689c7ae99cc2e75d7907', onSlotchange: () => this.moveMisplacedTabs() }))));
149
147
  }
150
148
  get host() { return this; }
151
149
  static get style() { return PostTabsStyle0; }
@@ -35,7 +35,7 @@ const PostTag = /*@__PURE__*/ proxyCustomElement(class PostTag extends HTMLEleme
35
35
  this.setClasses();
36
36
  }
37
37
  render() {
38
- return (h(Host, { key: '932992b2aa41e1082bf1617c7f6c74419febb143', "data-version": version }, h("div", { key: '3d5b82975cf95f1439299326347886a8b74e2d3d', class: this.classes }, this.icon ? h("post-icon", { name: this.icon }) : null, h("div", { key: '96dac1715f1ddfe799cb2cb443f57d2a4082d90e', class: "tag-text" }, h("slot", { key: 'bb886b44ae76b71096c9938dacd708d80b602790' })))));
38
+ return (h(Host, { key: '0292c0d7a103bd987511cb67d66bc3de60800bf1', "data-version": version }, h("div", { key: 'b3b1934c9c3ec3490b1dad8829b15f63490677ba', class: this.classes }, this.icon ? h("post-icon", { name: this.icon }) : null, h("div", { key: '0cb543c65dfe1d61756aecf67de9b2cdae3f78e5', class: "tag-text" }, h("slot", { key: '020b0b7191f0b6051c958253ef6cb52bc660d5e2' })))));
39
39
  }
40
40
  get host() { return this; }
41
41
  static get watchers() { return {
@@ -1,12 +1,12 @@
1
1
  import { proxyCustomElement, HTMLElement as HTMLElement$1, h, Host } from '@stencil/core/internal/client';
2
2
  import { v as version$1 } from './package.js';
3
+ import { a as commonjsGlobal, b as getDefaultExportFromCjs } from './_commonjsHelpers.js';
3
4
  import { g as getAttributeObserver } from './attribute-observer.js';
5
+ import { b as checkEmptyOrType } from './index2.js';
4
6
  import { d as defineCustomElement$1 } from './post-popovercontainer2.js';
5
7
 
6
- var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
7
-
8
- function getDefaultExportFromCjs (x) {
9
- return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
8
+ function timeout(delay) {
9
+ return new Promise(resolve => setTimeout(resolve, delay));
10
10
  }
11
11
 
12
12
  var focusable = {exports: {}};
@@ -4772,9 +4772,10 @@ const isFocusable = /*@__PURE__*/getDefaultExportFromCjs(focusable.exports);
4772
4772
 
4773
4773
  }(window, document));
4774
4774
 
4775
- const postTooltipCss = ":host{--post-contrast-color:#fff;--post-bg-rgb:51, 51, 51}post-popovercontainer::part(popover){padding:.25rem .5rem;max-width:13.5rem;min-height:1rem}post-popovercontainer.has-arrow::part(popover)::after{position:absolute;content:\"\";inset:-13px;z-index:-1}";
4775
+ const postTooltipCss = ":host{--post-contrast-color:#fff;--post-bg-rgb:51, 51, 51}post-popovercontainer{padding:.25rem .5rem;max-width:13.5rem;min-height:1rem}post-popovercontainer[arrow]::after{position:absolute;content:\"\";inset:-13px;z-index:-1}";
4776
4776
  const PostTooltipStyle0 = postTooltipCss;
4777
4777
 
4778
+ const OPEN_DELAY = 650; // matches HTML title delay
4778
4779
  /**
4779
4780
  * @slot default - Slot for the content of the tooltip.
4780
4781
  */
@@ -4858,6 +4859,13 @@ const PostTooltip = /*@__PURE__*/ proxyCustomElement(class PostTooltip extends H
4858
4859
  this.__attachShadow();
4859
4860
  this.placement = 'top';
4860
4861
  this.arrow = true;
4862
+ this.delayed = false;
4863
+ }
4864
+ validateDelayed() {
4865
+ checkEmptyOrType(this.delayed, 'boolean', 'The post-tooltip "delayed" property should be a boolean.');
4866
+ }
4867
+ connectedCallback() {
4868
+ this.validateDelayed();
4861
4869
  }
4862
4870
  componentDidLoad() {
4863
4871
  if (!this.host.id) {
@@ -4910,6 +4918,8 @@ const PostTooltip = /*@__PURE__*/ proxyCustomElement(class PostTooltip extends H
4910
4918
  * @param target An element with [data-tooltip-target="id"] where the tooltip should be shown
4911
4919
  */
4912
4920
  async show(target) {
4921
+ if (this.delayed)
4922
+ await timeout(OPEN_DELAY);
4913
4923
  this.popoverRef.show(target);
4914
4924
  }
4915
4925
  /**
@@ -4943,16 +4953,22 @@ const PostTooltip = /*@__PURE__*/ proxyCustomElement(class PostTooltip extends H
4943
4953
  }
4944
4954
  render() {
4945
4955
  const popoverClass = `${this.arrow ? ' has-arrow' : ''}`;
4946
- return (h(Host, { key: 'b0d7189566ac508ebd711e563a045d1797b06afb', "data-version": version$1, role: "tooltip", onPointerOver: this.handleInterest, onPointerOut: this.handleInterestLost, onFocusIn: this.handleInterest, onFocusOut: this.handleInterestLost }, h("post-popovercontainer", { key: 'e8e4eba9431feb03fd2209884f129d6fe46516a8', class: popoverClass, arrow: this.arrow, placement: this.placement, ref: (el) => (this.popoverRef = el) }, h("slot", { key: '8ab50141cce24665aa10b9b31db5b14342de2040' }))));
4956
+ return (h(Host, { key: 'de8f7f40645168240a3bcb70fd014ea2cfefbeb6', "data-version": version$1, role: "tooltip", onPointerOver: this.handleInterest, onPointerOut: this.handleInterestLost, onFocusIn: this.handleInterest, onFocusOut: this.handleInterestLost }, h("post-popovercontainer", { key: '4cecbb91117c4dd46c7aea6f084a84de995c25b7', class: popoverClass, arrow: this.arrow, placement: this.placement, ref: (el) => (this.popoverRef = el) }, h("slot", { key: 'c023b8f26189ed2c0dc4573914e92ce65f50ac18' }))));
4947
4957
  }
4948
4958
  get host() { return this; }
4959
+ static get watchers() { return {
4960
+ "delayed": ["validateDelayed"]
4961
+ }; }
4949
4962
  static get style() { return PostTooltipStyle0; }
4950
4963
  }, [1, "post-tooltip", {
4951
4964
  "placement": [1],
4952
4965
  "arrow": [4],
4966
+ "delayed": [4],
4953
4967
  "show": [64],
4954
4968
  "hide": [64],
4955
4969
  "toggle": [64]
4970
+ }, undefined, {
4971
+ "delayed": ["validateDelayed"]
4956
4972
  }]);
4957
4973
  function defineCustomElement() {
4958
4974
  if (typeof customElements === "undefined") {