@zanichelli/albe-web-components 20.0.0-RC1 → 20.0.1

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 (213) hide show
  1. package/CHANGELOG.md +42 -0
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/web-components-library.cjs.js +1 -1
  4. package/dist/cjs/z-app-header_12.cjs.entry.js +29 -7
  5. package/dist/cjs/z-app-header_12.cjs.entry.js.map +1 -1
  6. package/dist/cjs/z-book-card.cjs.entry.js +6 -2
  7. package/dist/cjs/z-book-card.cjs.entry.js.map +1 -1
  8. package/dist/cjs/z-combobox.cjs.entry.js +6 -4
  9. package/dist/cjs/z-combobox.cjs.entry.js.map +1 -1
  10. package/dist/cjs/z-dragdrop-area_2.cjs.entry.js +2 -2
  11. package/dist/cjs/z-file.cjs.entry.js +1 -1
  12. package/dist/cjs/z-table.cjs.entry.js +1 -1
  13. package/dist/cjs/z-table.cjs.entry.js.map +1 -1
  14. package/dist/cjs/z-tbody.cjs.entry.js +1 -1
  15. package/dist/cjs/z-tbody.cjs.entry.js.map +1 -1
  16. package/dist/cjs/z-td.cjs.entry.js +1 -1
  17. package/dist/cjs/z-td.cjs.entry.js.map +1 -1
  18. package/dist/cjs/z-tfoot.cjs.entry.js +1 -1
  19. package/dist/cjs/z-tfoot.cjs.entry.js.map +1 -1
  20. package/dist/cjs/z-th.cjs.entry.js +1 -1
  21. package/dist/cjs/z-th.cjs.entry.js.map +1 -1
  22. package/dist/cjs/z-thead.cjs.entry.js +1 -1
  23. package/dist/cjs/z-thead.cjs.entry.js.map +1 -1
  24. package/dist/cjs/z-tr.cjs.entry.js +1 -1
  25. package/dist/cjs/z-tr.cjs.entry.js.map +1 -1
  26. package/dist/cjs/z-tree-list.cjs.entry.js +1 -1
  27. package/dist/collection/collection-manifest.json +7 -7
  28. package/dist/collection/components/book-card/z-book-card/index.js +7 -3
  29. package/dist/collection/components/book-card/z-book-card/index.js.map +1 -1
  30. package/dist/collection/components/{table → deprecated/table}/cells/z-td/index.js +6 -6
  31. package/dist/collection/components/deprecated/table/cells/z-td/index.js.map +1 -0
  32. package/dist/collection/components/{table → deprecated/table}/cells/z-th/index.js +8 -8
  33. package/dist/collection/components/deprecated/table/cells/z-th/index.js.map +1 -0
  34. package/dist/collection/components/{table → deprecated/table}/z-table/index.js +3 -3
  35. package/dist/collection/components/deprecated/table/z-table/index.js.map +1 -0
  36. package/dist/collection/components/{table → deprecated/table}/z-tbody/index.js +3 -3
  37. package/dist/collection/components/deprecated/table/z-tbody/index.js.map +1 -0
  38. package/dist/collection/components/{table → deprecated/table}/z-tfoot/index.js +3 -3
  39. package/dist/collection/components/deprecated/table/z-tfoot/index.js.map +1 -0
  40. package/dist/collection/components/{table → deprecated/table}/z-thead/index.js +3 -3
  41. package/dist/collection/components/deprecated/table/z-thead/index.js.map +1 -0
  42. package/dist/collection/components/{table → deprecated/table}/z-tr/index.js +4 -4
  43. package/dist/collection/components/deprecated/table/z-tr/index.js.map +1 -0
  44. package/dist/collection/components/file-upload/z-dragdrop-area/index.js +2 -2
  45. package/dist/collection/components/file-upload/z-file/index.js +1 -1
  46. package/dist/collection/components/list/z-list/index.js +1 -1
  47. package/dist/collection/components/list/z-list-element/index.js +1 -1
  48. package/dist/collection/components/list/z-list-group/index.js +2 -2
  49. package/dist/collection/components/list/z-tree-list/index.js +1 -1
  50. package/dist/collection/components/z-combobox/index.js +5 -3
  51. package/dist/collection/components/z-combobox/index.js.map +1 -1
  52. package/dist/collection/components/z-combobox/styles.css +1 -1
  53. package/dist/collection/components/z-input/index.js +45 -2
  54. package/dist/collection/components/z-input/index.js.map +1 -1
  55. package/dist/collection/components/z-input/styles-checkbox-radio.css +2 -2
  56. package/dist/components/index.d.ts +7 -7
  57. package/dist/components/index10.js +1 -1
  58. package/dist/components/index19.js +1 -1
  59. package/dist/components/index6.js +1 -1
  60. package/dist/components/index6.js.map +1 -1
  61. package/dist/components/index8.js +1 -1
  62. package/dist/components/index9.js +1 -1
  63. package/dist/components/z-book-card.js +1 -1
  64. package/dist/components/z-book-card.js.map +1 -1
  65. package/dist/components/z-combobox.js +1 -1
  66. package/dist/components/z-combobox.js.map +1 -1
  67. package/dist/components/z-file.js +1 -1
  68. package/dist/components/z-table.js +1 -1
  69. package/dist/components/z-table.js.map +1 -1
  70. package/dist/components/z-tbody.js +1 -1
  71. package/dist/components/z-tbody.js.map +1 -1
  72. package/dist/components/z-td.js +1 -1
  73. package/dist/components/z-td.js.map +1 -1
  74. package/dist/components/z-tfoot.js +1 -1
  75. package/dist/components/z-tfoot.js.map +1 -1
  76. package/dist/components/z-th.js +1 -1
  77. package/dist/components/z-th.js.map +1 -1
  78. package/dist/components/z-thead.js +1 -1
  79. package/dist/components/z-thead.js.map +1 -1
  80. package/dist/components/z-tr.js +1 -1
  81. package/dist/components/z-tr.js.map +1 -1
  82. package/dist/components/z-tree-list.js +1 -1
  83. package/dist/esm/loader.js +1 -1
  84. package/dist/esm/web-components-library.js +1 -1
  85. package/dist/esm/z-app-header_12.entry.js +29 -7
  86. package/dist/esm/z-app-header_12.entry.js.map +1 -1
  87. package/dist/esm/z-book-card.entry.js +6 -2
  88. package/dist/esm/z-book-card.entry.js.map +1 -1
  89. package/dist/esm/z-combobox.entry.js +6 -4
  90. package/dist/esm/z-combobox.entry.js.map +1 -1
  91. package/dist/esm/z-dragdrop-area_2.entry.js +2 -2
  92. package/dist/esm/z-file.entry.js +1 -1
  93. package/dist/esm/z-table.entry.js +1 -1
  94. package/dist/esm/z-table.entry.js.map +1 -1
  95. package/dist/esm/z-tbody.entry.js +1 -1
  96. package/dist/esm/z-tbody.entry.js.map +1 -1
  97. package/dist/esm/z-td.entry.js +1 -1
  98. package/dist/esm/z-td.entry.js.map +1 -1
  99. package/dist/esm/z-tfoot.entry.js +1 -1
  100. package/dist/esm/z-tfoot.entry.js.map +1 -1
  101. package/dist/esm/z-th.entry.js +1 -1
  102. package/dist/esm/z-th.entry.js.map +1 -1
  103. package/dist/esm/z-thead.entry.js +1 -1
  104. package/dist/esm/z-thead.entry.js.map +1 -1
  105. package/dist/esm/z-tr.entry.js +1 -1
  106. package/dist/esm/z-tr.entry.js.map +1 -1
  107. package/dist/esm/z-tree-list.entry.js +1 -1
  108. package/dist/types/components/book-card/z-book-card/index.d.ts +5 -1
  109. package/dist/types/components/{table → deprecated/table}/cells/z-td/index.d.ts +2 -2
  110. package/dist/types/components/{table → deprecated/table}/cells/z-th/index.d.ts +2 -2
  111. package/dist/types/components/{table → deprecated/table}/z-table/index.d.ts +1 -1
  112. package/dist/types/components/{table → deprecated/table}/z-tbody/index.d.ts +1 -1
  113. package/dist/types/components/{table → deprecated/table}/z-tfoot/index.d.ts +1 -1
  114. package/dist/types/components/{table → deprecated/table}/z-thead/index.d.ts +1 -1
  115. package/dist/types/components/{table → deprecated/table}/z-tr/index.d.ts +1 -1
  116. package/dist/types/components/z-input/index.d.ts +4 -0
  117. package/dist/types/components.d.ts +13 -2
  118. package/dist/web-components-library/p-1bd296f5.entry.js +2 -0
  119. package/dist/web-components-library/p-1bd296f5.entry.js.map +1 -0
  120. package/dist/web-components-library/p-1d050092.entry.js +2 -0
  121. package/dist/web-components-library/{p-b7620e80.entry.js → p-2cc3ac9f.entry.js} +2 -2
  122. package/dist/web-components-library/p-2cc3ac9f.entry.js.map +1 -0
  123. package/dist/web-components-library/{p-8f4fcd01.entry.js → p-2e398b4d.entry.js} +2 -2
  124. package/dist/web-components-library/p-3f787c19.entry.js +2 -0
  125. package/dist/web-components-library/p-3f787c19.entry.js.map +1 -0
  126. package/dist/web-components-library/{p-121f224a.entry.js → p-53943e9a.entry.js} +2 -2
  127. package/dist/web-components-library/{p-51ebf661.entry.js → p-59651b67.entry.js} +2 -2
  128. package/dist/web-components-library/p-59651b67.entry.js.map +1 -0
  129. package/{www/build/p-ccedd440.entry.js → dist/web-components-library/p-65c404bc.entry.js} +2 -2
  130. package/dist/web-components-library/p-65c404bc.entry.js.map +1 -0
  131. package/{www/build/p-53c51bf4.entry.js → dist/web-components-library/p-6b816b15.entry.js} +2 -2
  132. package/{www/build/p-53c51bf4.entry.js.map → dist/web-components-library/p-6b816b15.entry.js.map} +1 -1
  133. package/dist/web-components-library/{p-1ef66142.entry.js → p-6e49b67e.entry.js} +2 -2
  134. package/dist/web-components-library/p-6e49b67e.entry.js.map +1 -0
  135. package/dist/web-components-library/{p-3748979c.entry.js → p-8e1363c6.entry.js} +2 -2
  136. package/dist/web-components-library/p-8e1363c6.entry.js.map +1 -0
  137. package/dist/web-components-library/{p-a52b3dd1.entry.js → p-a1eb1dfd.entry.js} +2 -2
  138. package/dist/web-components-library/p-a1eb1dfd.entry.js.map +1 -0
  139. package/{www/build/p-904c7fdd.entry.js → dist/web-components-library/p-f841b50f.entry.js} +2 -2
  140. package/dist/web-components-library/p-f841b50f.entry.js.map +1 -0
  141. package/dist/web-components-library/web-components-library.esm.js +1 -1
  142. package/package.json +2 -3
  143. package/www/build/p-1bd296f5.entry.js +2 -0
  144. package/www/build/p-1bd296f5.entry.js.map +1 -0
  145. package/www/build/p-1d050092.entry.js +2 -0
  146. package/www/build/{p-b7620e80.entry.js → p-2cc3ac9f.entry.js} +2 -2
  147. package/www/build/p-2cc3ac9f.entry.js.map +1 -0
  148. package/www/build/{p-8f4fcd01.entry.js → p-2e398b4d.entry.js} +2 -2
  149. package/www/build/p-3f787c19.entry.js +2 -0
  150. package/www/build/p-3f787c19.entry.js.map +1 -0
  151. package/www/build/{p-121f224a.entry.js → p-53943e9a.entry.js} +2 -2
  152. package/www/build/{p-51ebf661.entry.js → p-59651b67.entry.js} +2 -2
  153. package/www/build/p-59651b67.entry.js.map +1 -0
  154. package/{dist/web-components-library/p-ccedd440.entry.js → www/build/p-65c404bc.entry.js} +2 -2
  155. package/www/build/p-65c404bc.entry.js.map +1 -0
  156. package/{dist/web-components-library/p-53c51bf4.entry.js → www/build/p-6b816b15.entry.js} +2 -2
  157. package/{dist/web-components-library/p-53c51bf4.entry.js.map → www/build/p-6b816b15.entry.js.map} +1 -1
  158. package/www/build/{p-1ef66142.entry.js → p-6e49b67e.entry.js} +2 -2
  159. package/www/build/p-6e49b67e.entry.js.map +1 -0
  160. package/www/build/{p-3748979c.entry.js → p-8e1363c6.entry.js} +2 -2
  161. package/www/build/p-8e1363c6.entry.js.map +1 -0
  162. package/www/build/p-955f0d65.js +2 -0
  163. package/www/build/{p-a52b3dd1.entry.js → p-a1eb1dfd.entry.js} +2 -2
  164. package/www/build/p-a1eb1dfd.entry.js.map +1 -0
  165. package/{dist/web-components-library/p-904c7fdd.entry.js → www/build/p-f841b50f.entry.js} +2 -2
  166. package/www/build/p-f841b50f.entry.js.map +1 -0
  167. package/www/build/web-components-library.esm.js +1 -1
  168. package/www/index.html +1 -1
  169. package/dist/collection/components/table/cells/z-td/index.js.map +0 -1
  170. package/dist/collection/components/table/cells/z-th/index.js.map +0 -1
  171. package/dist/collection/components/table/z-table/index.js.map +0 -1
  172. package/dist/collection/components/table/z-tbody/index.js.map +0 -1
  173. package/dist/collection/components/table/z-tfoot/index.js.map +0 -1
  174. package/dist/collection/components/table/z-thead/index.js.map +0 -1
  175. package/dist/collection/components/table/z-tr/index.js.map +0 -1
  176. package/dist/web-components-library/p-02fb0bf9.entry.js +0 -2
  177. package/dist/web-components-library/p-1ef66142.entry.js.map +0 -1
  178. package/dist/web-components-library/p-3748979c.entry.js.map +0 -1
  179. package/dist/web-components-library/p-51ebf661.entry.js.map +0 -1
  180. package/dist/web-components-library/p-5a43af47.entry.js +0 -2
  181. package/dist/web-components-library/p-5a43af47.entry.js.map +0 -1
  182. package/dist/web-components-library/p-8d2704ee.entry.js +0 -2
  183. package/dist/web-components-library/p-8d2704ee.entry.js.map +0 -1
  184. package/dist/web-components-library/p-904c7fdd.entry.js.map +0 -1
  185. package/dist/web-components-library/p-a52b3dd1.entry.js.map +0 -1
  186. package/dist/web-components-library/p-b7620e80.entry.js.map +0 -1
  187. package/dist/web-components-library/p-ccedd440.entry.js.map +0 -1
  188. package/www/build/p-02fb0bf9.entry.js +0 -2
  189. package/www/build/p-1ef66142.entry.js.map +0 -1
  190. package/www/build/p-3748979c.entry.js.map +0 -1
  191. package/www/build/p-51ebf661.entry.js.map +0 -1
  192. package/www/build/p-5a1df5b1.js +0 -2
  193. package/www/build/p-5a43af47.entry.js +0 -2
  194. package/www/build/p-5a43af47.entry.js.map +0 -1
  195. package/www/build/p-8d2704ee.entry.js +0 -2
  196. package/www/build/p-8d2704ee.entry.js.map +0 -1
  197. package/www/build/p-904c7fdd.entry.js.map +0 -1
  198. package/www/build/p-a52b3dd1.entry.js.map +0 -1
  199. package/www/build/p-b7620e80.entry.js.map +0 -1
  200. package/www/build/p-ccedd440.entry.js.map +0 -1
  201. /package/dist/collection/components/{table → deprecated/table}/cells/z-table-cells.css +0 -0
  202. /package/dist/collection/components/{table → deprecated/table}/cells/z-th/styles.css +0 -0
  203. /package/dist/collection/components/{table → deprecated/table}/z-table/styles.css +0 -0
  204. /package/dist/collection/components/{table → deprecated/table}/z-tbody/styles.css +0 -0
  205. /package/dist/collection/components/{table → deprecated/table}/z-tfoot/styles.css +0 -0
  206. /package/dist/collection/components/{table → deprecated/table}/z-thead/styles.css +0 -0
  207. /package/dist/collection/components/{table → deprecated/table}/z-tr/styles.css +0 -0
  208. /package/dist/web-components-library/{p-02fb0bf9.entry.js.map → p-1d050092.entry.js.map} +0 -0
  209. /package/dist/web-components-library/{p-8f4fcd01.entry.js.map → p-2e398b4d.entry.js.map} +0 -0
  210. /package/dist/web-components-library/{p-121f224a.entry.js.map → p-53943e9a.entry.js.map} +0 -0
  211. /package/www/build/{p-02fb0bf9.entry.js.map → p-1d050092.entry.js.map} +0 -0
  212. /package/www/build/{p-8f4fcd01.entry.js.map → p-2e398b4d.entry.js.map} +0 -0
  213. /package/www/build/{p-121f224a.entry.js.map → p-53943e9a.entry.js.map} +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"names":["stylesCss","ZCombobox","watchItems","this","itemsList","items","JSON","parse","selectedCounter","filter","item","checked","length","updateRenderItemsList","watchSearchValue","filterItems","searchValue","emitComboboxChange","comboboxChange","emit","id","inputid","constructor","hostRef","randomId","disabled","hassearch","noresultslabel","isopen","isfixed","hascheckall","checkalltext","uncheckalltext","maxcheckableitems","size","ControlSize","BIG","renderItemsList","focusedItemId","inputType","InputType","TEXT","toggleComboBox","bind","closeFilterItems","componentWillLoad","componentWillRender","getControlToListSize","X_SMALL","ListSize","SMALL","MEDIUM","LARGE","getOptionId","encodeString","name","getCheckAllOptionId","allOptionsSelected","hasReachedMaxSelections","handleHeaderKeyDown","e","code","KeyboardCode","ENTER","SPACE","preventDefault","checkOption","ESC","ARROW_DOWN","ARROW_UP","handleArrowsNavigation","handleInputKeyDown","TAB","optionId","map","Object","assign","i","includes","stopPropagation","currElem","element","shadowRoot","querySelector","options","Array","from","querySelectorAll","currElemIndex","indexOf","firstElemIndex","lastElemIndex","nextElem","scrollIntoView","block","container","resetRenderItemsList","forEach","push","value","start","toUpperCase","end","newName","substring","getHeaderAriaLabel","label","undefined","suffix","getComboboxA11yAttributes","isZInput","role","ariaExpanded","ariaActivedescendant","ariaControls","htmlAriaLabel","renderHeader","comboboxA11yAttributes","h","class","onClick","onKeyDown","tabindex","renderContent","renderSearchInput","join","renderItems","tabIndex","renderList","renderItem","index","isDisabled","htmlTabindex","dividerType","ListDividerType","ELEMENT","NONE","getPlainText","innerHTML","renderNoSearchResults","hasgroupitems","renderGroups","renderCheckAll","newData","reduce","group","category","zListItem","_a","listGroups","entries","key","slot","htmlid","searchlabel","placeholder","searchplaceholder","htmltitle","searchtitle","type","message","onInputChange","detail","allChecked","isPartiallySelected","dividerColor","render","open","fixed"],"sources":["src/components/css-components/z-label/styles.css?tag=z-combobox&encapsulation=shadow","src/components/z-combobox/styles.css?tag=z-combobox&encapsulation=shadow","src/components/z-combobox/index.tsx"],"sourcesContent":[".z-label {\n display: block;\n padding-bottom: var(--space-unit);\n color: var(--color-default-text);\n font-family: var(--font-family-sans);\n font-size: var(--font-size-1);\n font-weight: var(--font-sb);\n text-align: left;\n text-transform: uppercase;\n}\n",":host {\n display: block;\n min-width: 290px;\n color: var(--color-form-default-text);\n fill: var(--color-form-default-icon);\n font-family: var(--font-family-sans);\n}\n\n:host > div.fixed {\n position: relative;\n}\n\n:host > div > .header {\n position: relative;\n z-index: 10;\n display: flex;\n min-height: 42px;\n align-items: center;\n justify-content: space-between;\n padding: 0 calc(var(--space-unit) * 1.5);\n border: var(--border-size-small) solid var(--color-form-surface04);\n margin: 0;\n background-color: var(--color-form-background);\n border-radius: var(--border-radius-small);\n cursor: pointer;\n}\n\n:host([size=\"small\"]) > div > .header {\n min-height: 34px;\n font-size: var(--font-size-2);\n}\n\n:host([size=\"x-small\"]) > div > .header {\n min-height: 30px;\n font-size: var(--font-size-2);\n}\n\n:host > div > .header:hover {\n outline: var(--border-size-medium) solid var(--color-form-surface04);\n outline-offset: -2px;\n}\n\n:host > div > div.header:focus:focus-visible {\n z-index: 16;\n box-shadow: var(--shadow-focus-primary);\n outline: none;\n}\n\n:host > div > .header > span.body-3 > span {\n font-weight: var(--font-sb);\n}\n\n:host > div > .header > z-icon {\n fill: var(--color-form-default-icon);\n transform: rotate(360deg);\n transition: all 200ms linear;\n}\n\n:host > div > .header > z-icon.small,\n:host > div > .header > z-icon.x-small {\n --z-icon-width: 16px;\n --z-icon-height: 16px;\n}\n\n:host > div.open > .header {\n border: var(--border-size-small) solid var(--color-form-active-primary);\n border-radius: var(--border-radius-small) var(--border-radius-small) 0 0;\n}\n\n:host > div.disabled {\n pointer-events: none;\n}\n\n:host > div.disabled .header {\n border-color: var(--color-form-disabled03);\n fill: var(--color-form-disabled01-icon);\n}\n\n:host > div.disabled .header > span.body-3 {\n color: var(--color-form-disabled03);\n}\n\n:host > div.disabled .header > z-icon:last-child {\n fill: var(--color-form-disabled01-icon);\n}\n\n:host > div.open > .header > z-icon {\n fill: var(--color-form-default-icon);\n transform: rotate(180deg);\n transition: all 200ms linear;\n}\n\n:host > div > div.open-combo-data {\n display: none;\n}\n\n:host > div.open > div.open-combo-data {\n position: relative;\n z-index: 12;\n display: block;\n padding: var(--space-unit) calc(var(--space-unit) * 2);\n border: var(--border-size-small) solid var(--color-form-surface03);\n border-top: 0;\n background-color: var(--color-form-background);\n border-radius: 0;\n box-shadow: var(--shadow-2);\n}\n\n:host .open .open-combo-data z-input .z-label {\n color: var(--color-form-default-text);\n}\n\n:host > div.open > div.open-combo-data > div > div {\n overflow: auto;\n max-height: 235px;\n padding: 0;\n padding-left: var(--space-unit); /* padding left and negative margin in order to enable focus */\n margin-left: calc(var(--space-unit) * -1); /* padding left and negative margin in order to enable focus */\n}\n\n:host > div.open > div.open-combo-data > z-input {\n width: 100%;\n margin-bottom: calc(var(--space-unit) * 2);\n}\n\n:host > div.open > div.open-combo-data > div > div > ul {\n max-height: 235px;\n padding: 0 calc(var(--space-unit) * 0.5); /* needed for checkbox focus shadow */\n margin: 0;\n}\n\n:host .open-combo-data z-list-element {\n --background-color-list-element: var(--color-form-background);\n --background-hover-color-list-element: var(--color-form-surface03);\n --background-active-color-list-element: var(--color-form-surface03);\n}\n\n:host .open-combo-data z-list-element[disabled] {\n pointer-events: none;\n}\n\n:host .open-combo-data z-list-element .option-wrap {\n display: flex;\n flex-direction: row;\n align-items: center;\n cursor: pointer;\n gap: var(--space-unit);\n}\n\n:host .open-combo-data z-list-element[size=\"medium\"] .option-wrap,\n:host .open-combo-data z-list-element[size=\"small\"] .option-wrap {\n --z-icon-width: 16px;\n --z-icon-height: 16px;\n\n font-size: var(--font-size-2);\n gap: calc(var(--space-unit) / 2);\n}\n\n:host .open-combo-data z-list-element .option-wrap > z-icon {\n fill: var(--color-primary01-icon);\n}\n\n:host .open-combo-data z-list-element[disabled] .option-wrap > z-icon {\n fill: var(--color-disabled01);\n}\n\n:host .open-combo-data z-list-element .option-wrap > z-icon.focused {\n border-radius: var(--border-radius-small);\n box-shadow: var(--shadow-focus-primary);\n outline: none;\n}\n\n:host .open-combo-data z-list-element .option-wrap > [role=\"option\"]:focus,\n:host .open-combo-data z-list-element .option-wrap > [role=\"option\"]:focus-visible {\n outline: none;\n}\n\n::-webkit-scrollbar {\n width: 6px;\n background: linear-gradient(to right, transparent 0 1px, var(--gray200) 1px 5px, transparent 5px 6px);\n}\n\n::-webkit-scrollbar-thumb {\n background-color: var(--color-primary01);\n}\n\n::-webkit-scrollbar-thumb:hover {\n background-color: var(--color-hover-primary);\n}\n\n/* Firefox scrollbar */\n@supports not selector(::-webkit-scrollbar-track) {\n :host {\n scrollbar-color: var(--color-primary01) transparent;\n }\n}\n\n:host > div.open > z-input {\n position: relative;\n z-index: 1;\n width: 238px;\n margin: 0 calc(var(--space-unit) * 2);\n color: var(--color-form-active-primary);\n}\n\n:host > div.open > div.open-combo-data > div > div.search {\n overflow: hidden;\n max-height: none;\n margin-top: 0;\n}\n\n:host > div.open > div.open-combo-data > div > div.search > ul {\n overflow: auto;\n max-height: 180px;\n padding: var(--space-unit) calc(var(--space-unit) * 2);\n}\n\n:host .open .open-combo-data .search .no-results {\n display: flex;\n align-items: center;\n column-gap: var(--space-unit);\n}\n\n:host > .open > .open-combo-data .search .close-search {\n display: flex;\n justify-content: center;\n}\n\n:host > div.open > div.open-combo-data > div > div.search .close-search > a {\n display: inline-block;\n height: 44px;\n color: var(--color-form-active-primary);\n cursor: pointer;\n font-size: 14px;\n font-weight: var(--font-sb);\n line-height: 44px;\n text-align: center;\n text-transform: uppercase;\n}\n\n:host > div.open > div.open-combo-data > div > div.search .close-search > a:focus:focus-visible {\n box-shadow: var(--shadow-focus-primary);\n outline: none;\n}\n\n:host > div.open > div.open-combo-data > div > div.check-all-wrapper {\n /* padding left and negative margin in order to enable focus */\n padding: calc(var(--space-unit) * 2) calc(var(--space-unit) * 0.5) calc(var(--space-unit) * 2)\n calc(var(--space-unit) * 1.5);\n border-bottom: var(--border-size-small) solid var(--gray800);\n margin-bottom: var(--space-unit);\n margin-left: calc(var(--space-unit) * -1);\n text-align: left;\n}\n\n:host([size=\"small\"]) > div.open > div.open-combo-data > div > div.check-all-wrapper {\n padding: calc(var(--space-unit) * 1.5) calc(var(--space-unit) * 0.5);\n}\n\n:host([size=\"x-small\"]) > div.open > div.open-combo-data > div > div.check-all-wrapper {\n padding: var(--space-unit) calc(var(--space-unit) * 0.5);\n}\n","import {Component, ComponentInterface, Element, Event, EventEmitter, Prop, State, Watch, h} from \"@stencil/core\";\nimport {ComboItem, ControlSize, InputType, KeyboardCode, ListDividerType, ListSize} from \"../../beans\";\nimport {encodeString, getPlainText, randomId} from \"../../utils/utils\";\nimport {ZInput} from \"../z-input\";\n\n@Component({\n tag: \"z-combobox\",\n styleUrls: [\"../css-components/z-label/styles.css\", \"styles.css\"],\n shadow: true,\n})\nexport class ZCombobox implements ComponentInterface {\n @Element() element: HTMLZComboboxElement;\n\n /** input unique id */\n @Prop()\n inputid = `combo-${randomId()}`;\n\n /** list items array */\n @Prop()\n items: ComboItem[] | string;\n\n /** label text */\n @Prop()\n label: string;\n\n /** the combobox is disabled */\n @Prop({reflect: true})\n disabled?: boolean = false;\n\n /** show search input flag (optional) */\n @Prop()\n hassearch?: boolean = false;\n\n /** search input label text (optional) */\n @Prop()\n searchlabel?: string;\n\n /** search input placeholder text (optional) */\n @Prop()\n searchplaceholder?: string;\n\n /** search input title text (optional) */\n @Prop()\n searchtitle?: string;\n\n /** no result text message */\n @Prop()\n noresultslabel?: string = \"Nessun risultato\";\n\n /** toggle combo list opening flag */\n @Prop({mutable: true})\n isopen = false;\n\n /** fixed style flag */\n @Prop()\n isfixed = false;\n\n /** show \"check all\" checkbox (optional) */\n @Prop()\n hascheckall?: boolean = false;\n\n /** check all label (optional) */\n @Prop()\n checkalltext?: string = \"Seleziona tutti\";\n\n /** uncheck all label (optional) */\n @Prop()\n uncheckalltext?: string = \"Deseleziona tutti\";\n\n /** max number of checkable items (0 = unlimited) */\n @Prop()\n maxcheckableitems = 0;\n\n /** group items by category */\n @Prop()\n hasgroupitems?: boolean;\n\n /** Available sizes: `big`, `small` and `x-small`. Defaults to `big`. */\n @Prop()\n size?: ControlSize = ControlSize.BIG;\n\n /** the combobox aria-label */\n @Prop()\n htmlAriaLabel?: string;\n\n @State()\n searchValue: string;\n\n @State()\n selectedCounter: number;\n\n @State()\n renderItemsList: ComboItem[] = []; // used for render only\n\n @State()\n focusedItemId = \"\";\n\n private itemsList: ComboItem[] = [];\n\n private inputType: InputType = InputType.TEXT;\n\n @Watch(\"items\")\n watchItems(): void {\n this.itemsList = typeof this.items === \"string\" ? JSON.parse(this.items) : this.items;\n this.selectedCounter = this.itemsList.filter((item) => item.checked).length;\n this.updateRenderItemsList();\n }\n\n @Watch(\"searchValue\")\n watchSearchValue(): void {\n this.filterItems(this.searchValue);\n }\n\n /** Emitted when value is checked/unchecked. Returns id, items. */\n @Event()\n comboboxChange: EventEmitter;\n\n private emitComboboxChange(): void {\n this.comboboxChange.emit({id: this.inputid, items: this.itemsList});\n }\n\n constructor() {\n this.toggleComboBox = this.toggleComboBox.bind(this);\n this.closeFilterItems = this.closeFilterItems.bind(this);\n }\n\n componentWillLoad(): void {\n this.watchItems();\n }\n\n componentWillRender(): void {\n this.selectedCounter = this.itemsList.filter((item) => item.checked).length;\n }\n\n private getControlToListSize(): ListSize {\n switch (this.size) {\n case ControlSize.X_SMALL:\n return ListSize.SMALL;\n case ControlSize.SMALL:\n return ListSize.MEDIUM;\n default:\n return ListSize.LARGE;\n }\n }\n\n private getOptionId(item: ComboItem): string {\n return `${this.inputid}-option-${item.id ? encodeString(`${item.id}`) : encodeString(`${item.name}`)}`;\n }\n\n private getCheckAllOptionId(): string {\n return `${this.inputid}-check-all`;\n }\n\n private allOptionsSelected(): boolean {\n return this.selectedCounter === this.itemsList.length;\n }\n\n private hasReachedMaxSelections(): boolean {\n return !!(this.maxcheckableitems && this.selectedCounter >= this.maxcheckableitems);\n }\n\n private handleHeaderKeyDown(e: KeyboardEvent): void {\n if (e.code === KeyboardCode.ENTER && !this.focusedItemId) {\n this.toggleComboBox();\n }\n\n if (!this.isopen || this.hassearch) {\n return;\n }\n\n switch (e.code as KeyboardCode) {\n case KeyboardCode.SPACE:\n case KeyboardCode.ENTER:\n if (this.focusedItemId) {\n e.preventDefault();\n this.checkOption(this.focusedItemId);\n }\n break;\n case KeyboardCode.ESC:\n if (this.focusedItemId) {\n this.focusedItemId = \"\";\n }\n break;\n case KeyboardCode.ARROW_DOWN:\n case KeyboardCode.ARROW_UP:\n this.handleArrowsNavigation(e);\n break;\n }\n }\n\n private handleInputKeyDown(e: KeyboardEvent): void {\n switch (e.code as KeyboardCode) {\n case KeyboardCode.ENTER:\n case KeyboardCode.SPACE:\n if (this.focusedItemId) {\n e.preventDefault();\n this.checkOption(this.focusedItemId);\n break;\n }\n break;\n case KeyboardCode.ARROW_DOWN:\n case KeyboardCode.ARROW_UP:\n this.handleArrowsNavigation(e);\n break;\n case KeyboardCode.ESC:\n if (this.focusedItemId) {\n this.focusedItemId = \"\";\n break;\n }\n this.closeFilterItems();\n break;\n case KeyboardCode.TAB:\n this.focusedItemId = \"\";\n break;\n }\n }\n\n private checkOption(optionId: string): void {\n if (optionId === this.getCheckAllOptionId()) {\n this.itemsList = this.itemsList.map((item: ComboItem) => ({\n ...item,\n checked: !this.allOptionsSelected(),\n }));\n\n this.focusedItemId = this.getCheckAllOptionId();\n } else {\n this.itemsList = this.itemsList.map((i: ComboItem) => {\n if (optionId === this.getOptionId(i)) {\n i.checked = !i.checked;\n }\n\n return i;\n });\n }\n\n this.updateRenderItemsList();\n this.emitComboboxChange();\n }\n\n private handleArrowsNavigation(e: KeyboardEvent): void {\n if (![KeyboardCode.ARROW_DOWN, KeyboardCode.ARROW_UP].includes(e.code as KeyboardCode) || !this.isopen) {\n return;\n }\n\n e.preventDefault();\n e.stopPropagation();\n\n const currElem = this.focusedItemId ? this.element.shadowRoot.querySelector(`#${this.focusedItemId}`) : null;\n const options = Array.from(this.element.shadowRoot.querySelectorAll('[role=\"option\"]'));\n\n if (!options.length) {\n return;\n }\n\n const currElemIndex = currElem ? options.indexOf(currElem) : null;\n const firstElemIndex = 0;\n const lastElemIndex = options.length - 1;\n\n let nextElem = null;\n if (e.code === KeyboardCode.ARROW_DOWN) {\n nextElem =\n currElemIndex === null ? options[firstElemIndex] : options[currElemIndex + 1] || options[lastElemIndex];\n } else if (e.code === KeyboardCode.ARROW_UP) {\n nextElem =\n currElemIndex === null ? options[lastElemIndex] : options[currElemIndex - 1] || options[firstElemIndex];\n }\n\n this.focusedItemId = nextElem.id;\n nextElem.scrollIntoView({block: \"nearest\", container: \"nearest\"});\n }\n\n private updateRenderItemsList(): void {\n if (this.searchValue) {\n this.filterItems(this.searchValue);\n } else {\n this.resetRenderItemsList();\n }\n }\n\n private resetRenderItemsList(): void {\n const renderItemsList = [];\n this.itemsList.forEach((item: ComboItem) => {\n renderItemsList.push({...item});\n });\n this.renderItemsList = renderItemsList;\n }\n\n private filterItems(value: string): void {\n if (!value) {\n return this.closeFilterItems();\n }\n\n this.resetRenderItemsList();\n this.renderItemsList = this.renderItemsList.filter((item) => {\n const start = item.name.toUpperCase().indexOf(value.toUpperCase());\n const end = start + value.length;\n const newName =\n item.name.substring(0, start) +\n \"<strong>\" +\n item.name.substring(start, end) +\n \"</strong>\" +\n item.name.substring(end, item.name.length);\n\n item.name = newName;\n\n return start >= 0;\n });\n }\n\n private closeFilterItems(): void {\n this.searchValue = \"\";\n this.resetRenderItemsList();\n }\n\n private toggleComboBox(): void {\n this.isopen = !this.isopen;\n }\n\n private getHeaderAriaLabel(): string | undefined {\n if (!this.label || this.selectedCounter <= 0) {\n return undefined;\n }\n\n const suffix = this.selectedCounter === 1 ? \"elemento selezionato\" : \"elementi selezionati\";\n\n return `${this.label}: ${this.selectedCounter} ${suffix}`;\n }\n\n private getComboboxA11yAttributes(isZInput: boolean): Record<string, string> {\n const role = \"combobox\";\n const ariaExpanded = this.isopen ? \"true\" : \"false\";\n const ariaActivedescendant = this.isopen ? this.focusedItemId : \"\";\n const ariaControls = `${this.inputid}_list`;\n\n if (isZInput) {\n return {\n \"role\": role,\n \"aria-label\": this.htmlAriaLabel,\n \"html-aria-expanded\": ariaExpanded,\n \"html-aria-activedescendant\": ariaActivedescendant,\n \"html-aria-controls\": ariaControls,\n };\n }\n\n return {\n \"role\": role,\n \"aria-expanded\": ariaExpanded,\n \"aria-activedescendant\": ariaActivedescendant,\n \"aria-controls\": ariaControls,\n };\n }\n\n private renderHeader(): HTMLDivElement {\n const comboboxA11yAttributes = !this.hassearch ? this.getComboboxA11yAttributes(false) : {};\n\n return (\n <div\n class=\"header\"\n onClick={() => this.toggleComboBox()}\n onKeyDown={(e: KeyboardEvent) => this.handleHeaderKeyDown(e)}\n role=\"button\"\n tabindex={0}\n aria-controls=\"open-combo-data\"\n aria-expanded={this.isopen ? \"true\" : \"false\"}\n aria-label={this.getHeaderAriaLabel()}\n {...comboboxA11yAttributes}\n >\n <span class=\"body-3\">\n {this.label}\n <span>{this.selectedCounter > 0 && ` (${this.selectedCounter})`}</span>\n </span>\n <z-icon\n name=\"caret-down\"\n class={this.size}\n />\n </div>\n );\n }\n\n private renderContent(): HTMLDivElement {\n return (\n <div\n id=\"open-combo-data\"\n class=\"open-combo-data\"\n >\n {this.hassearch && this.renderSearchInput()}\n <div\n role=\"listbox\"\n aria-label={this.label}\n aria-multiselectable=\"true\"\n id={`${this.inputid}_list`}\n aria-owns={`${this.hascheckall ? `${this.getCheckAllOptionId()} ` : ``}${this.itemsList.map((item) => this.getOptionId(item)).join(\" \")}`}\n >\n {this.renderItems()}\n </div>\n </div>\n );\n }\n\n private renderItems(): HTMLDivElement {\n return (\n <div\n class={this.searchValue && \"search\"}\n tabIndex={-1}\n role=\"presentation\"\n >\n {this.renderList(this.renderItemsList)}\n </div>\n );\n }\n\n private renderItem(item: ComboItem, index: number, length: number): HTMLZListElement {\n const optionId = this.getOptionId(item);\n const isDisabled = !item.checked && this.hasReachedMaxSelections();\n\n return (\n <z-list-element\n htmlTabindex={-1}\n dividerType={index !== length - 1 ? ListDividerType.ELEMENT : ListDividerType.NONE}\n size={this.getControlToListSize()}\n role=\"presentation\"\n disabled={!!isDisabled}\n >\n <span\n class=\"option-wrap\"\n role=\"presentation\"\n onClick={() => {\n this.focusedItemId = \"\";\n this.checkOption(optionId);\n }}\n >\n <z-icon\n name={item.checked ? \"checkbox-checked\" : \"checkbox\"}\n class={this.focusedItemId === optionId ? \"focused\" : \"\"}\n />\n <span\n id={optionId}\n role={isDisabled ? \"presentation\" : \"option\"}\n aria-selected={item.checked ? \"true\" : \"false\"}\n aria-label={isDisabled ? undefined : getPlainText(item.name)}\n >\n <span\n aria-hidden=\"true\"\n innerHTML={item.name}\n />\n </span>\n </span>\n </z-list-element>\n );\n }\n\n private renderList(items: ComboItem[]): HTMLUListElement {\n if (!items) {\n return;\n }\n if (!items.length && this.searchValue) {\n return this.renderNoSearchResults();\n }\n\n if (this.hasgroupitems) {\n return this.renderGroups(items);\n }\n\n return (\n <ul role=\"presentation\">\n {this.renderCheckAll()}\n {items.map((item, i) => {\n return this.renderItem(item, i, items.length);\n })}\n </ul>\n );\n }\n\n private renderGroups(items: ComboItem[]): HTMLUListElement {\n const newData = items.reduce((group, item, index) => {\n const category = item.category || \"Altra categoria\";\n const zListItem = this.renderItem(item, index, items.length);\n\n group[category] = group[category] ?? [];\n group[category].push(zListItem);\n\n return group;\n }, {});\n\n const listGroups = Object.entries(newData as {[key: string]: HTMLZListElementElement[]}).map(\n ([key, value], index) => {\n return (\n <z-list-group\n size={this.getControlToListSize()}\n divider-type={ListDividerType.ELEMENT}\n aria-labelledby={`${this.inputid}_list_group_${index}`}\n >\n <span\n class=\"body-3-sb z-list-group-title\"\n slot=\"header-title\"\n id={`${this.inputid}_list_group_${index}`}\n aria-hidden=\"true\"\n >\n {key}\n </span>\n {value.map((item) => item)}\n </z-list-group>\n );\n }\n );\n\n return (\n <ul role=\"presentation\">\n {this.renderCheckAll()}\n {listGroups}\n </ul>\n );\n }\n\n private renderNoSearchResults(): HTMLUListElement {\n return (\n <div class=\"no-results\">\n <span>{this.noresultslabel}</span>\n </div>\n );\n }\n\n private renderSearchInput(): ZInput {\n return (\n <z-input\n htmlid={`${this.inputid}_search`}\n label={this.searchlabel}\n placeholder={this.searchplaceholder}\n htmltitle={this.searchtitle}\n type={this.inputType}\n value={this.searchValue}\n message={false}\n size={this.size}\n html-aria-autocomplete=\"list\"\n {...this.getComboboxA11yAttributes(true)}\n onKeyDown={(e: KeyboardEvent) => this.handleInputKeyDown(e)}\n onInputChange={(e: CustomEvent) => {\n this.searchValue = e.detail.value;\n this.focusedItemId = \"\";\n }}\n />\n );\n }\n\n private renderCheckAll(): HTMLDivElement {\n if (!this.hascheckall || this.searchValue) {\n return;\n }\n\n const optionId = this.getCheckAllOptionId();\n const allChecked = this.allOptionsSelected();\n const isPartiallySelected = this.selectedCounter > 0 && !allChecked;\n const isDisabled =\n !allChecked &&\n (this.hasReachedMaxSelections() || (this.maxcheckableitems && this.maxcheckableitems < this.itemsList.length));\n\n return (\n <z-list-element\n class=\"check-all-wrapper\"\n role=\"presentation\"\n htmlTabindex={-1}\n dividerType={ListDividerType.ELEMENT}\n dividerColor=\"gray800\"\n size={this.getControlToListSize()}\n disabled={!!isDisabled}\n >\n <span\n class=\"option-wrap\"\n role=\"presentation\"\n onClick={() => this.checkOption(optionId)}\n >\n <z-icon\n name={isPartiallySelected ? \"indeterminated-checkbox\" : allChecked ? \"checkbox-checked\" : \"checkbox\"}\n class={this.focusedItemId === optionId ? \"focused\" : \"\"}\n />\n <span\n id={optionId}\n role={isDisabled ? \"presentation\" : \"option\"}\n aria-selected={allChecked ? \"true\" : \"false\"}\n >\n {allChecked ? this.uncheckalltext : this.checkalltext}\n </span>\n </span>\n </z-list-element>\n );\n }\n\n render(): HTMLDivElement {\n return (\n <div\n data-action={`combo-${this.inputid}`}\n class={{open: this.isopen, fixed: this.isfixed, disabled: this.disabled}}\n id={this.inputid}\n >\n {this.renderHeader()}\n {!this.disabled && this.renderContent()}\n </div>\n );\n }\n}\n"],"mappings":"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","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- import{r as t,c as e,h as i,H as o,d as n}from"./p-BcDWN4F1.js";import{g as a}from"./p-DdetsoIY.js";import{R as r,F as s}from"./p-BjrC13Q0.js";import"./p-DPrEzmhI.js";import"./p-Q-tWjk7P.js";const l=()=>`:host{position:relative;display:flex;width:100%;height:232px;flex-direction:column;align-items:center;padding:calc(var(--space-unit) * 3);background-color:var(--color-surface02);background-image:repeating-linear-gradient( 0deg, var(--color-surface03), var(--color-surface03) 12px, transparent 12px, transparent 20px ), repeating-linear-gradient( 90deg, var(--color-surface03), var(--color-surface03) 12px, transparent 12px, transparent 20px ), repeating-linear-gradient( 180deg, var(--color-surface03), var(--color-surface03) 12px, transparent 12px, transparent 20px ), repeating-linear-gradient( 270deg, var(--color-surface03), var(--color-surface03) 12px, transparent 12px, transparent 20px );background-position:0 0, 0 0, 100% 0, 0 100%;background-repeat:no-repeat;background-size:2px 100%, 100% 2px, 2px 100%, 100% 2px;border-radius:var(--border-radius-small);color:var(--color-default-text);font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host,*{box-sizing:border-box}:host(.dragover) *{pointer-events:none}.dragover-container{position:absolute;z-index:1;top:0;left:0;display:none;width:100%;height:100%;background-color:var(--color-primary03);box-shadow:var(--shadow-focus-primary)}:host(.dragover) .dragover-container{display:flex;align-items:center;justify-content:center}`;const d=class{constructor(i){t(this,i);this.fileDropped=e(this,"fileDropped",7);this.dragging=false}onDrop(t){t.preventDefault();this.dragging=false;if(t.dataTransfer.files.length){this.fileDropped.emit(t.dataTransfer.files)}}render(){return i(o,{key:"67cb9dfea1cd24f61d1b1c628752d7a770365c5c",class:{dragover:this.dragging},onDragOver:t=>{t.preventDefault();this.dragging=true},onDragLeave:()=>{this.dragging=false},onDrop:this.onDrop.bind(this)},i("div",{key:"38ecbac3eb08bf669a75869c78f6e95dff67941f",class:"dragover-container"},i("z-button",{key:"b0b1e63c600d4e01155ddfb593faf3fd89e55abd"},this.dragAndDropLabel)),i("slot",{key:"6876fc9e23ffc13a39651ee26c92d6355d45aff7"}))}};d.style=l();var c=window.CustomEvent;if(!c||typeof c==="object"){c=function t(e,i){i=i||{};var o=document.createEvent("CustomEvent");o.initCustomEvent(e,!!i.bubbles,!!i.cancelable,i.detail||null);return o};c.prototype=window.Event.prototype}function h(t,e){var i="on"+e.type.toLowerCase();if(typeof t[i]==="function"){t[i](e)}return t.dispatchEvent(e)}function u(t){while(t&&t!==document.body){var e=window.getComputedStyle(t);var i=function(t,i){return!(e[t]===undefined||e[t]===i)};if(e.opacity<1||i("zIndex","auto")||i("transform","none")||i("mixBlendMode","normal")||i("filter","none")||i("perspective","none")||e["isolation"]==="isolate"||e.position==="fixed"||e.webkitOverflowScrolling==="touch"){return true}t=t.parentElement}return false}function f(t){while(t){if(t.localName==="dialog"){return t}if(t.parentElement){t=t.parentElement}else if(t.parentNode){t=t.parentNode.host}else{t=null}}return null}function m(t){while(t&&t.shadowRoot&&t.shadowRoot.activeElement){t=t.shadowRoot.activeElement}if(t&&t.blur&&t!==document.body){t.blur()}}function v(t,e){for(var i=0;i<t.length;++i){if(t[i]===e){return true}}return false}function p(t){if(!t||!t.hasAttribute("method")){return false}return t.getAttribute("method").toLowerCase()==="dialog"}function b(t){var e=["button","input","keygen","select","textarea"];var i=e.map((function(t){return t+":not([disabled])"}));i.push('[tabindex]:not([disabled]):not([tabindex=""])');var o=t.querySelector(i.join(", "));if(!o&&"attachShadow"in Element.prototype){var n=t.querySelectorAll("*");for(var a=0;a<n.length;a++){if(n[a].tagName&&n[a].shadowRoot){o=b(n[a].shadowRoot);if(o){break}}}}return o}function g(t){return t.isConnected||document.body.contains(t)}function w(t){if(t.submitter){return t.submitter}var e=t.target;if(!(e instanceof HTMLFormElement)){return null}var i=x.formSubmitter;if(!i){var o=t.target;var n="getRootNode"in o&&o.getRootNode()||document;i=n.activeElement}if(!i||i.form!==e){return null}return i}function k(t){if(t.defaultPrevented){return}var e=t.target;var i=x.imagemapUseValue;var o=w(t);if(i===null&&o){i=o.value}var n=f(e);if(!n){return}var a=o&&o.getAttribute("formmethod")||e.getAttribute("method");if(a!=="dialog"){return}t.preventDefault();if(i!=null){n.close(i)}else{n.close()}}function y(t){this.dialog_=t;this.replacedStyleTop_=false;this.openAsModal_=false;if(!t.hasAttribute("role")){t.setAttribute("role","dialog")}t.show=this.show.bind(this);t.showModal=this.showModal.bind(this);t.close=this.close.bind(this);t.addEventListener("submit",k,false);if(!("returnValue"in t)){t.returnValue=""}if("MutationObserver"in window){var e=new MutationObserver(this.maybeHideModal.bind(this));e.observe(t,{attributes:true,attributeFilter:["open"]})}else{var i=false;var o=function(){i?this.downgradeModal():this.maybeHideModal();i=false}.bind(this);var n;var a=function(e){if(e.target!==t){return}var a="DOMNodeRemoved";i|=e.type.substr(0,a.length)===a;window.clearTimeout(n);n=window.setTimeout(o,0)};["DOMAttrModified","DOMNodeRemoved","DOMNodeRemovedFromDocument"].forEach((function(e){t.addEventListener(e,a)}))}Object.defineProperty(t,"open",{set:this.setOpen.bind(this),get:t.hasAttribute.bind(t,"open")});this.backdrop_=document.createElement("div");this.backdrop_.className="backdrop";this.backdrop_.addEventListener("mouseup",this.backdropMouseEvent_.bind(this));this.backdrop_.addEventListener("mousedown",this.backdropMouseEvent_.bind(this));this.backdrop_.addEventListener("click",this.backdropMouseEvent_.bind(this))}y.prototype={get dialog(){return this.dialog_},maybeHideModal:function(){if(this.dialog_.hasAttribute("open")&&g(this.dialog_)){return}this.downgradeModal()},downgradeModal:function(){if(!this.openAsModal_){return}this.openAsModal_=false;this.dialog_.style.zIndex="";if(this.replacedStyleTop_){this.dialog_.style.top="";this.replacedStyleTop_=false}this.backdrop_.parentNode&&this.backdrop_.parentNode.removeChild(this.backdrop_);x.dm.removeDialog(this)},setOpen:function(t){if(t){this.dialog_.hasAttribute("open")||this.dialog_.setAttribute("open","")}else{this.dialog_.removeAttribute("open");this.maybeHideModal()}},backdropMouseEvent_:function(t){if(!this.dialog_.hasAttribute("tabindex")){var e=document.createElement("div");this.dialog_.insertBefore(e,this.dialog_.firstChild);e.tabIndex=-1;e.focus();this.dialog_.removeChild(e)}else{this.dialog_.focus()}var i=document.createEvent("MouseEvents");i.initMouseEvent(t.type,t.bubbles,t.cancelable,window,t.detail,t.screenX,t.screenY,t.clientX,t.clientY,t.ctrlKey,t.altKey,t.shiftKey,t.metaKey,t.button,t.relatedTarget);this.dialog_.dispatchEvent(i);t.stopPropagation()},focus_:function(){var t=this.dialog_.querySelector("[autofocus]:not([disabled])");if(!t&&this.dialog_.tabIndex>=0){t=this.dialog_}if(!t){t=b(this.dialog_)}m(document.activeElement);t&&t.focus()},updateZIndex:function(t,e){if(t<e){throw new Error("dialogZ should never be < backdropZ")}this.dialog_.style.zIndex=t;this.backdrop_.style.zIndex=e},show:function(){if(!this.dialog_.open){this.setOpen(true);this.focus_()}},showModal:function(){if(this.dialog_.hasAttribute("open")){throw new Error("Failed to execute 'showModal' on dialog: The element is already open, and therefore cannot be opened modally.")}if(!g(this.dialog_)){throw new Error("Failed to execute 'showModal' on dialog: The element is not in a Document.")}if(!x.dm.pushDialog(this)){throw new Error("Failed to execute 'showModal' on dialog: There are too many open modal dialogs.")}if(u(this.dialog_.parentElement)){console.warn("A dialog is being shown inside a stacking context. "+"This may cause it to be unusable. For more information, see this link: "+"https://github.com/GoogleChrome/dialog-polyfill/#stacking-context")}this.setOpen(true);this.openAsModal_=true;if(x.needsCentering(this.dialog_)){x.reposition(this.dialog_);this.replacedStyleTop_=true}else{this.replacedStyleTop_=false}this.dialog_.parentNode.insertBefore(this.backdrop_,this.dialog_.nextSibling);this.focus_()},close:function(t){if(!this.dialog_.hasAttribute("open")){throw new Error("Failed to execute 'close' on dialog: The element does not have an 'open' attribute, and therefore cannot be closed.")}this.setOpen(false);if(t!==undefined){this.dialog_.returnValue=t}var e=new c("close",{bubbles:false,cancelable:false});h(this.dialog_,e)}};var x={};x.reposition=function(t){var e=document.body.scrollTop||document.documentElement.scrollTop;var i=e+(window.innerHeight-t.offsetHeight)/2;t.style.top=Math.max(e,i)+"px"};x.isInlinePositionSetByStylesheet=function(t){for(var e=0;e<document.styleSheets.length;++e){var i=document.styleSheets[e];var o=null;try{o=i.cssRules}catch(t){}if(!o){continue}for(var n=0;n<o.length;++n){var a=o[n];var r=null;try{r=document.querySelectorAll(a.selectorText)}catch(t){}if(!r||!v(r,t)){continue}var s=a.style.getPropertyValue("top");var l=a.style.getPropertyValue("bottom");if(s&&s!=="auto"||l&&l!=="auto"){return true}}}return false};x.needsCentering=function(t){var e=window.getComputedStyle(t);if(e.position!=="absolute"){return false}if(t.style.top!=="auto"&&t.style.top!==""||t.style.bottom!=="auto"&&t.style.bottom!==""){return false}return!x.isInlinePositionSetByStylesheet(t)};x.forceRegisterDialog=function(t){if(window.HTMLDialogElement||t.showModal){console.warn("This browser already supports <dialog>, the polyfill "+"may not work correctly",t)}if(t.localName!=="dialog"){throw new Error("Failed to register dialog: The element is not a dialog.")}new y(t)};x.registerDialog=function(t){if(!t.showModal){x.forceRegisterDialog(t)}};x.DialogManager=function(){this.pendingDialogStack=[];var t=this.checkDOM_.bind(this);this.overlay=document.createElement("div");this.overlay.className="_dialog_overlay";this.overlay.addEventListener("click",function(e){this.forwardTab_=undefined;e.stopPropagation();t([])}.bind(this));this.handleKey_=this.handleKey_.bind(this);this.handleFocus_=this.handleFocus_.bind(this);this.zIndexLow_=1e5;this.zIndexHigh_=1e5+150;this.forwardTab_=undefined;if("MutationObserver"in window){this.mo_=new MutationObserver((function(e){var i=[];e.forEach((function(t){for(var e=0,o;o=t.removedNodes[e];++e){if(!(o instanceof Element)){continue}else if(o.localName==="dialog"){i.push(o)}i=i.concat(o.querySelectorAll("dialog"))}}));i.length&&t(i)}))}};x.DialogManager.prototype.blockDocument=function(){document.documentElement.addEventListener("focus",this.handleFocus_,true);document.addEventListener("keydown",this.handleKey_);this.mo_&&this.mo_.observe(document,{childList:true,subtree:true})};x.DialogManager.prototype.unblockDocument=function(){document.documentElement.removeEventListener("focus",this.handleFocus_,true);document.removeEventListener("keydown",this.handleKey_);this.mo_&&this.mo_.disconnect()};x.DialogManager.prototype.updateStacking=function(){var t=this.zIndexHigh_;for(var e=0,i;i=this.pendingDialogStack[e];++e){i.updateZIndex(--t,--t);if(e===0){this.overlay.style.zIndex=--t}}var o=this.pendingDialogStack[0];if(o){var n=o.dialog.parentNode||document.body;n.appendChild(this.overlay)}else if(this.overlay.parentNode){this.overlay.parentNode.removeChild(this.overlay)}};x.DialogManager.prototype.containedByTopDialog_=function(t){while(t=f(t)){for(var e=0,i;i=this.pendingDialogStack[e];++e){if(i.dialog===t){return e===0}}t=t.parentElement}return false};x.DialogManager.prototype.handleFocus_=function(t){var e=t.composedPath?t.composedPath()[0]:t.target;if(this.containedByTopDialog_(e)){return}if(document.activeElement===document.documentElement){return}t.preventDefault();t.stopPropagation();m(e);if(this.forwardTab_===undefined){return}var i=this.pendingDialogStack[0];var o=i.dialog;var n=o.compareDocumentPosition(e);if(n&Node.DOCUMENT_POSITION_PRECEDING){if(this.forwardTab_){i.focus_()}else if(e!==document.documentElement){document.documentElement.focus()}}return false};x.DialogManager.prototype.handleKey_=function(t){this.forwardTab_=undefined;if(t.keyCode===27){t.preventDefault();t.stopPropagation();var e=new c("cancel",{bubbles:false,cancelable:true});var i=this.pendingDialogStack[0];if(i&&h(i.dialog,e)){i.dialog.close()}}else if(t.keyCode===9){this.forwardTab_=!t.shiftKey}};x.DialogManager.prototype.checkDOM_=function(t){var e=this.pendingDialogStack.slice();e.forEach((function(e){if(t.indexOf(e.dialog)!==-1){e.downgradeModal()}else{e.maybeHideModal()}}))};x.DialogManager.prototype.pushDialog=function(t){var e=(this.zIndexHigh_-this.zIndexLow_)/2-1;if(this.pendingDialogStack.length>=e){return false}if(this.pendingDialogStack.unshift(t)===1){this.blockDocument()}this.updateStacking();return true};x.DialogManager.prototype.removeDialog=function(t){var e=this.pendingDialogStack.indexOf(t);if(e===-1){return}this.pendingDialogStack.splice(e,1);if(this.pendingDialogStack.length===0){this.unblockDocument()}this.updateStacking()};x.dm=new x.DialogManager;x.formSubmitter=null;x.imagemapUseValue=null;if(window.HTMLDialogElement===undefined){var M=document.createElement("form");M.setAttribute("method","dialog");if(M.method!=="dialog"){var z=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"method");if(z){var E=z.get;z.get=function(){if(p(this)){return"dialog"}return E.call(this)};var C=z.set;z.set=function(t){if(typeof t==="string"&&t.toLowerCase()==="dialog"){return this.setAttribute("method",t)}return C.call(this,t)};Object.defineProperty(HTMLFormElement.prototype,"method",z)}}document.addEventListener("click",(function(t){x.formSubmitter=null;x.imagemapUseValue=null;if(t.defaultPrevented){return}var e=t.target;if("composedPath"in t){var i=t.composedPath();e=i.shift()||e}if(!e||!p(e.form)){return}var o=e.type==="submit"&&["button","input"].indexOf(e.localName)>-1;if(!o){if(!(e.localName==="input"&&e.type==="image")){return}x.imagemapUseValue=t.offsetX+","+t.offsetY}var n=f(e);if(!n){return}x.formSubmitter=e}),false);document.addEventListener("submit",(function(t){var e=t.target;var i=f(e);if(i){return}var o=w(t);var n=o&&o.getAttribute("formmethod")||e.getAttribute("method");if(n==="dialog"){t.preventDefault()}}));var D=HTMLFormElement.prototype.submit;var F=function(){if(!p(this)){return D.call(this)}var t=f(this);t&&t.close()};HTMLFormElement.prototype.submit=F}const O=()=>`:host{font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host>dialog{padding:0;border:none;margin:0;background-color:transparent}:host>dialog:modal{width:100%;max-width:100%;max-height:100%}:host>dialog::backdrop{display:none}:host>dialog+.backdrop{display:none}:host>dialog:not([open]){display:none}:host>dialog[open]{display:block}::slotted([slot="modalContent"]){padding:var(--z-modal-content-padding, calc(var(--space-unit) * 2))}.modal-container{z-index:1010;display:flex;overflow:-moz-scrollbars-none;width:100%;height:100vh;flex-direction:column}.modal-container>.modal-content-scroll-outside{overflow:auto;background:var(--color-surface01)}.modal-container>header{padding:calc(var(--space-unit) * 1.75) calc(var(--space-unit) * 2);background:var(--color-background)}.modal-container>header button{padding:0;border:none;margin:0;margin-left:auto;background:transparent;cursor:pointer}.modal-container>header button:focus-visible{border-radius:50%;box-shadow:var(--shadow-focus-primary);outline:none !important}.modal-container>header button::after{position:absolute;top:6px;right:4px;display:block;width:40px;height:40px;background-color:transparent;content:""}.modal-container>header z-icon{--z-icon-width:calc(var(--space-unit) * 2.25);--z-icon-height:calc(var(--space-unit) * 2.25);display:flex;fill:var(--color-primary01-icon)}.modal-container>header>div{display:flex;width:100%;align-items:baseline;margin-right:calc(var(--space-unit) * 2)}.modal-container>header h1,.modal-container>header .subtitle{padding:0;margin:0;color:var(--color-default-text);font-weight:var(--font-sb)}.modal-container>header h1{font-size:var(--font-size-5);letter-spacing:0;line-height:1.4}.modal-container>header .subtitle{font-size:var(--font-size-3);font-weight:var(--font-rg);letter-spacing:0;line-height:1.5}.modal-container>header>div>h1 *:empty{display:none}.modal-container>header h1+.subtitle{margin-top:calc(var(--space-unit) * 0.5)}.modal-container-scroll-inside>.modal-content-scroll-inside{overflow:hidden auto;flex:1 auto;background:var(--color-surface01)}.modal-container-scroll-inside>.modal-content-scroll-inside::-webkit-scrollbar,.modal-container-scroll-outside>.modal-content-scroll-outside::-webkit-scrollbar{width:6px;background:linear-gradient(to right, transparent 0 1px, var(--gray200) 1px 5px, transparent 5px 6px)}.modal-container-scroll-inside>.modal-content-scroll-inside::-webkit-scrollbar-thumb,.modal-container-scroll-outside>.modal-content-scroll-outside::-webkit-scrollbar-thumb{background-color:var(--color-primary01)}.modal-container-scroll-inside>.modal-content-scroll-inside::-webkit-scrollbar-thumb:hover,.modal-container-scroll-outside>.modal-content-scroll-outside::-webkit-scrollbar-thumb:hover{background-color:var(--color-hover-primary)}@supports not selector(::-webkit-scrollbar-track){.modal-container-scroll-inside .modal-content-scroll-inside,.modal-container-scroll-outside .modal-content-scroll-outside{scrollbar-color:var(--color-primary01) transparent}}@media only screen and (min-width: 768px){.modal-background{position:fixed;top:0;left:0;overflow:hidden;width:100vw;height:100vh;background-color:var(--gray900);opacity:0.7}.modal-background.modal-background-scroll-outside{position:sticky}.modal-container-scroll-inside{position:fixed;top:calc(var(--space-unit) * 6);left:50%;overflow:hidden;width:auto;min-width:calc(var(--space-unit) * 40);height:auto;min-height:calc(var(--space-unit) * 40);max-height:calc(100vh - calc(var(--space-unit) * 6 * 2));border-radius:var(--border-radius);transform:translateX(-50%)}.modal-container-scroll-outside{position:absolute;top:calc(var(--space-unit) * 6);left:50%;display:block;overflow:initial;width:auto;min-width:calc(var(--space-unit) * 40);height:auto;min-height:calc(var(--space-unit) * 40);max-height:calc(100vh - calc(var(--space-unit) * 6 * 2));transform:translateX(-50%)}.modal-container>.modal-content-scroll-outside{overflow:initial}.modal-container-scroll-outside>header,.modal-container-scroll-inside>header{border-top-left-radius:var(--border-radius);border-top-right-radius:var(--border-radius)}.modal-container-scroll-outside::after{display:block;height:calc(var(--space-unit) * 6);content:" "}.modal-dialog{position:fixed;top:0;left:0;height:auto;overflow-x:hidden;overflow-y:auto}.modal-content-scroll-outside{border-bottom-left-radius:var(--border-radius);border-bottom-right-radius:var(--border-radius)}.modal-dialog::-webkit-scrollbar{display:none}}@media (min-width: 1152px){.modal-container>header{padding-top:calc(var(--space-unit) * 1.5);padding-bottom:calc(var(--space-unit) * 1.5)}.modal-container>header h1{font-size:var(--font-size-6);font-weight:var(--font-sb);letter-spacing:0;line-height:1.333}.modal-container>header .subtitle{font-size:var(--font-size-4);font-weight:var(--font-rg);letter-spacing:0;line-height:1.5}.modal-container>header h1+.subtitle{margin-top:0}}`;const j=class extends r{constructor(i){super();t(this,i);this.modalClose=e(this,"modalClose",7);this.modalHeaderActive=e(this,"modalHeaderActive",7);this.modalBackgroundClick=e(this,"modalBackgroundClick",7);this.closeButtonLabel="chiudi modale";this.alertdialog=false;this.closable=true;this.scrollInside=true;this.lockPageScroll=true;this.focusTrapController=new s(this,{isActive:()=>{var t;return!!((t=this.dialog)===null||t===void 0?void 0:t.open)}})}emitModalClose(){if(this.closable){this.modalClose.emit({modalid:this.modalid});this.resetPageScroll()}}emitModalHeaderActive(){this.modalHeaderActive.emit({modalid:this.modalid})}emitBackgroundClick(){if(this.closable){this.modalBackgroundClick.emit({modalid:this.modalid});this.resetPageScroll()}}resetPageScroll(){if(this.lockPageScroll&&document.body.style.overflowY==="hidden"){document.body.style.overflowY=""}}componentDidLoad(){if(typeof window.HTMLDialogElement!=="function"){if(!this.dialog.localName){Object.defineProperty(this.dialog,"localName",{value:"dialog"})}x.registerDialog(this.dialog);this.dialog.setAttribute("open","true")}else{this.open()}if(this.lockPageScroll){requestAnimationFrame((()=>document.body.style.overflowY="hidden"))}super.componentDidLoad()}disconnectedCallback(){this.resetPageScroll();super.disconnectedCallback()}async open(){var t;(t=this.dialog)===null||t===void 0?void 0:t.showModal();this.focusTrapController.sync();if(this.lockPageScroll){document.body.style.overflowY="hidden"}}async close(){var t;if(this.closable){(t=this.dialog)===null||t===void 0?void 0:t.close();this.focusTrapController.sync();this.resetPageScroll()}}handleKeyDown(t){if(t.code===a.ESC&&!this.closable){t.preventDefault();return}this.focusTrapController.handleWrapTab(t)}closeButtonSlot(){if(this.closable){return i("slot",{name:"modalCloseButton"},i("button",{"aria-label":this.closeButtonLabel,onClick:()=>this.close()},i("z-icon",{name:"multiply-circle-filled"})))}}handleEscape(t){if(this.closable){return}t.preventDefault()}render(){return i("dialog",{key:"526d8a729f276a07f3ff7c40566c7e57051485a7",class:{"modal-dialog":!this.scrollInside},"aria-labelledby":"modal-title","aria-describedby":"modal-content",role:this.alertdialog?"alertdialog":undefined,ref:t=>this.dialog=t,onClose:()=>this.emitModalClose(),onCancel:t=>this.handleEscape(t)},i("div",{key:"a2a80ee8d4ea3800715cc2c1b90d6490a6cf681c",class:{"modal-container":true,"modal-container-scroll-inside":this.scrollInside,"modal-container-scroll-outside":!this.scrollInside},id:this.modalid},i("header",{key:"9406127d701e8d8c552732057f1a17c5ea9feaab",onClick:this.emitModalHeaderActive.bind(this)},i("div",{key:"bfcb837521ff1bac75f1f25d4c7c1d8405f0447d"},this.modaltitle&&i("h1",{key:"b5887ad16f0cec7086c47b7eaafa141bef42ad35",id:"modal-title"},this.modaltitle),this.closeButtonSlot()),this.modalsubtitle&&i("div",{key:"b9fdb82ebd831d6e75705b0016549139054e5901",class:"subtitle",id:"modal-subtitle"},this.modalsubtitle)),i("div",{key:"8b53454963abf4a743bf7fe19faeb2333bf8dd9e",class:{"modal-content-scroll-inside":this.scrollInside,"modal-content-scroll-outside":!this.scrollInside},id:"modal-content"},i("slot",{key:"afe97d828fea5d9b2b79d8706508b43eb74e3b5a",name:"modalContent"}))),i("div",{key:"bc6e6b79153b0187a520a75b77558e47de1db312",class:{"modal-background":true,"modal-background-scroll-outside":!this.scrollInside},"data-action":"modalBackground","data-modal":this.modalid,onClick:()=>{this.emitBackgroundClick();this.close()}}))}get host(){return n(this)}};j.style=O();export{d as z_dragdrop_area,j as z_modal};
2
- //# sourceMappingURL=p-121f224a.entry.js.map
1
+ import{r as t,c as e,h as i,H as o,d as a}from"./p-BcDWN4F1.js";import{g as n}from"./p-DdetsoIY.js";import{R as r,F as s}from"./p-BjrC13Q0.js";import"./p-DPrEzmhI.js";import"./p-Q-tWjk7P.js";const l=()=>`:host{position:relative;display:flex;width:100%;height:232px;flex-direction:column;align-items:center;padding:calc(var(--space-unit) * 3);background-color:var(--color-surface02);background-image:repeating-linear-gradient( 0deg, var(--color-surface03), var(--color-surface03) 12px, transparent 12px, transparent 20px ), repeating-linear-gradient( 90deg, var(--color-surface03), var(--color-surface03) 12px, transparent 12px, transparent 20px ), repeating-linear-gradient( 180deg, var(--color-surface03), var(--color-surface03) 12px, transparent 12px, transparent 20px ), repeating-linear-gradient( 270deg, var(--color-surface03), var(--color-surface03) 12px, transparent 12px, transparent 20px );background-position:0 0, 0 0, 100% 0, 0 100%;background-repeat:no-repeat;background-size:2px 100%, 100% 2px, 2px 100%, 100% 2px;border-radius:var(--border-radius-small);color:var(--color-default-text);font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host,*{box-sizing:border-box}:host(.dragover) *{pointer-events:none}.dragover-container{position:absolute;z-index:1;top:0;left:0;display:none;width:100%;height:100%;background-color:var(--color-primary03);box-shadow:var(--shadow-focus-primary)}:host(.dragover) .dragover-container{display:flex;align-items:center;justify-content:center}`;const d=class{constructor(i){t(this,i);this.fileDropped=e(this,"fileDropped",7);this.dragging=false}onDrop(t){t.preventDefault();this.dragging=false;if(t.dataTransfer.files.length){this.fileDropped.emit(t.dataTransfer.files)}}render(){return i(o,{key:"ecf49da8d38f797026ccc5a56c6ccb8f99aa48ce",class:{dragover:this.dragging},onDragOver:t=>{t.preventDefault();this.dragging=true},onDragLeave:()=>{this.dragging=false},onDrop:this.onDrop.bind(this)},i("div",{key:"ef15b62b3e7ab7b0f243c4b3c6138ecacda1c06d",class:"dragover-container"},i("z-button",{key:"ccbc9c3c422bf6603fbe89f48c5fe79c001921e1"},this.dragAndDropLabel)),i("slot",{key:"8478b1c1e7c4f7be161ad95af6a4879a24a05d26"}))}};d.style=l();var c=window.CustomEvent;if(!c||typeof c==="object"){c=function t(e,i){i=i||{};var o=document.createEvent("CustomEvent");o.initCustomEvent(e,!!i.bubbles,!!i.cancelable,i.detail||null);return o};c.prototype=window.Event.prototype}function h(t,e){var i="on"+e.type.toLowerCase();if(typeof t[i]==="function"){t[i](e)}return t.dispatchEvent(e)}function u(t){while(t&&t!==document.body){var e=window.getComputedStyle(t);var i=function(t,i){return!(e[t]===undefined||e[t]===i)};if(e.opacity<1||i("zIndex","auto")||i("transform","none")||i("mixBlendMode","normal")||i("filter","none")||i("perspective","none")||e["isolation"]==="isolate"||e.position==="fixed"||e.webkitOverflowScrolling==="touch"){return true}t=t.parentElement}return false}function f(t){while(t){if(t.localName==="dialog"){return t}if(t.parentElement){t=t.parentElement}else if(t.parentNode){t=t.parentNode.host}else{t=null}}return null}function m(t){while(t&&t.shadowRoot&&t.shadowRoot.activeElement){t=t.shadowRoot.activeElement}if(t&&t.blur&&t!==document.body){t.blur()}}function v(t,e){for(var i=0;i<t.length;++i){if(t[i]===e){return true}}return false}function p(t){if(!t||!t.hasAttribute("method")){return false}return t.getAttribute("method").toLowerCase()==="dialog"}function b(t){var e=["button","input","keygen","select","textarea"];var i=e.map((function(t){return t+":not([disabled])"}));i.push('[tabindex]:not([disabled]):not([tabindex=""])');var o=t.querySelector(i.join(", "));if(!o&&"attachShadow"in Element.prototype){var a=t.querySelectorAll("*");for(var n=0;n<a.length;n++){if(a[n].tagName&&a[n].shadowRoot){o=b(a[n].shadowRoot);if(o){break}}}}return o}function g(t){return t.isConnected||document.body.contains(t)}function w(t){if(t.submitter){return t.submitter}var e=t.target;if(!(e instanceof HTMLFormElement)){return null}var i=x.formSubmitter;if(!i){var o=t.target;var a="getRootNode"in o&&o.getRootNode()||document;i=a.activeElement}if(!i||i.form!==e){return null}return i}function k(t){if(t.defaultPrevented){return}var e=t.target;var i=x.imagemapUseValue;var o=w(t);if(i===null&&o){i=o.value}var a=f(e);if(!a){return}var n=o&&o.getAttribute("formmethod")||e.getAttribute("method");if(n!=="dialog"){return}t.preventDefault();if(i!=null){a.close(i)}else{a.close()}}function y(t){this.dialog_=t;this.replacedStyleTop_=false;this.openAsModal_=false;if(!t.hasAttribute("role")){t.setAttribute("role","dialog")}t.show=this.show.bind(this);t.showModal=this.showModal.bind(this);t.close=this.close.bind(this);t.addEventListener("submit",k,false);if(!("returnValue"in t)){t.returnValue=""}if("MutationObserver"in window){var e=new MutationObserver(this.maybeHideModal.bind(this));e.observe(t,{attributes:true,attributeFilter:["open"]})}else{var i=false;var o=function(){i?this.downgradeModal():this.maybeHideModal();i=false}.bind(this);var a;var n=function(e){if(e.target!==t){return}var n="DOMNodeRemoved";i|=e.type.substr(0,n.length)===n;window.clearTimeout(a);a=window.setTimeout(o,0)};["DOMAttrModified","DOMNodeRemoved","DOMNodeRemovedFromDocument"].forEach((function(e){t.addEventListener(e,n)}))}Object.defineProperty(t,"open",{set:this.setOpen.bind(this),get:t.hasAttribute.bind(t,"open")});this.backdrop_=document.createElement("div");this.backdrop_.className="backdrop";this.backdrop_.addEventListener("mouseup",this.backdropMouseEvent_.bind(this));this.backdrop_.addEventListener("mousedown",this.backdropMouseEvent_.bind(this));this.backdrop_.addEventListener("click",this.backdropMouseEvent_.bind(this))}y.prototype={get dialog(){return this.dialog_},maybeHideModal:function(){if(this.dialog_.hasAttribute("open")&&g(this.dialog_)){return}this.downgradeModal()},downgradeModal:function(){if(!this.openAsModal_){return}this.openAsModal_=false;this.dialog_.style.zIndex="";if(this.replacedStyleTop_){this.dialog_.style.top="";this.replacedStyleTop_=false}this.backdrop_.parentNode&&this.backdrop_.parentNode.removeChild(this.backdrop_);x.dm.removeDialog(this)},setOpen:function(t){if(t){this.dialog_.hasAttribute("open")||this.dialog_.setAttribute("open","")}else{this.dialog_.removeAttribute("open");this.maybeHideModal()}},backdropMouseEvent_:function(t){if(!this.dialog_.hasAttribute("tabindex")){var e=document.createElement("div");this.dialog_.insertBefore(e,this.dialog_.firstChild);e.tabIndex=-1;e.focus();this.dialog_.removeChild(e)}else{this.dialog_.focus()}var i=document.createEvent("MouseEvents");i.initMouseEvent(t.type,t.bubbles,t.cancelable,window,t.detail,t.screenX,t.screenY,t.clientX,t.clientY,t.ctrlKey,t.altKey,t.shiftKey,t.metaKey,t.button,t.relatedTarget);this.dialog_.dispatchEvent(i);t.stopPropagation()},focus_:function(){var t=this.dialog_.querySelector("[autofocus]:not([disabled])");if(!t&&this.dialog_.tabIndex>=0){t=this.dialog_}if(!t){t=b(this.dialog_)}m(document.activeElement);t&&t.focus()},updateZIndex:function(t,e){if(t<e){throw new Error("dialogZ should never be < backdropZ")}this.dialog_.style.zIndex=t;this.backdrop_.style.zIndex=e},show:function(){if(!this.dialog_.open){this.setOpen(true);this.focus_()}},showModal:function(){if(this.dialog_.hasAttribute("open")){throw new Error("Failed to execute 'showModal' on dialog: The element is already open, and therefore cannot be opened modally.")}if(!g(this.dialog_)){throw new Error("Failed to execute 'showModal' on dialog: The element is not in a Document.")}if(!x.dm.pushDialog(this)){throw new Error("Failed to execute 'showModal' on dialog: There are too many open modal dialogs.")}if(u(this.dialog_.parentElement)){console.warn("A dialog is being shown inside a stacking context. "+"This may cause it to be unusable. For more information, see this link: "+"https://github.com/GoogleChrome/dialog-polyfill/#stacking-context")}this.setOpen(true);this.openAsModal_=true;if(x.needsCentering(this.dialog_)){x.reposition(this.dialog_);this.replacedStyleTop_=true}else{this.replacedStyleTop_=false}this.dialog_.parentNode.insertBefore(this.backdrop_,this.dialog_.nextSibling);this.focus_()},close:function(t){if(!this.dialog_.hasAttribute("open")){throw new Error("Failed to execute 'close' on dialog: The element does not have an 'open' attribute, and therefore cannot be closed.")}this.setOpen(false);if(t!==undefined){this.dialog_.returnValue=t}var e=new c("close",{bubbles:false,cancelable:false});h(this.dialog_,e)}};var x={};x.reposition=function(t){var e=document.body.scrollTop||document.documentElement.scrollTop;var i=e+(window.innerHeight-t.offsetHeight)/2;t.style.top=Math.max(e,i)+"px"};x.isInlinePositionSetByStylesheet=function(t){for(var e=0;e<document.styleSheets.length;++e){var i=document.styleSheets[e];var o=null;try{o=i.cssRules}catch(t){}if(!o){continue}for(var a=0;a<o.length;++a){var n=o[a];var r=null;try{r=document.querySelectorAll(n.selectorText)}catch(t){}if(!r||!v(r,t)){continue}var s=n.style.getPropertyValue("top");var l=n.style.getPropertyValue("bottom");if(s&&s!=="auto"||l&&l!=="auto"){return true}}}return false};x.needsCentering=function(t){var e=window.getComputedStyle(t);if(e.position!=="absolute"){return false}if(t.style.top!=="auto"&&t.style.top!==""||t.style.bottom!=="auto"&&t.style.bottom!==""){return false}return!x.isInlinePositionSetByStylesheet(t)};x.forceRegisterDialog=function(t){if(window.HTMLDialogElement||t.showModal){console.warn("This browser already supports <dialog>, the polyfill "+"may not work correctly",t)}if(t.localName!=="dialog"){throw new Error("Failed to register dialog: The element is not a dialog.")}new y(t)};x.registerDialog=function(t){if(!t.showModal){x.forceRegisterDialog(t)}};x.DialogManager=function(){this.pendingDialogStack=[];var t=this.checkDOM_.bind(this);this.overlay=document.createElement("div");this.overlay.className="_dialog_overlay";this.overlay.addEventListener("click",function(e){this.forwardTab_=undefined;e.stopPropagation();t([])}.bind(this));this.handleKey_=this.handleKey_.bind(this);this.handleFocus_=this.handleFocus_.bind(this);this.zIndexLow_=1e5;this.zIndexHigh_=1e5+150;this.forwardTab_=undefined;if("MutationObserver"in window){this.mo_=new MutationObserver((function(e){var i=[];e.forEach((function(t){for(var e=0,o;o=t.removedNodes[e];++e){if(!(o instanceof Element)){continue}else if(o.localName==="dialog"){i.push(o)}i=i.concat(o.querySelectorAll("dialog"))}}));i.length&&t(i)}))}};x.DialogManager.prototype.blockDocument=function(){document.documentElement.addEventListener("focus",this.handleFocus_,true);document.addEventListener("keydown",this.handleKey_);this.mo_&&this.mo_.observe(document,{childList:true,subtree:true})};x.DialogManager.prototype.unblockDocument=function(){document.documentElement.removeEventListener("focus",this.handleFocus_,true);document.removeEventListener("keydown",this.handleKey_);this.mo_&&this.mo_.disconnect()};x.DialogManager.prototype.updateStacking=function(){var t=this.zIndexHigh_;for(var e=0,i;i=this.pendingDialogStack[e];++e){i.updateZIndex(--t,--t);if(e===0){this.overlay.style.zIndex=--t}}var o=this.pendingDialogStack[0];if(o){var a=o.dialog.parentNode||document.body;a.appendChild(this.overlay)}else if(this.overlay.parentNode){this.overlay.parentNode.removeChild(this.overlay)}};x.DialogManager.prototype.containedByTopDialog_=function(t){while(t=f(t)){for(var e=0,i;i=this.pendingDialogStack[e];++e){if(i.dialog===t){return e===0}}t=t.parentElement}return false};x.DialogManager.prototype.handleFocus_=function(t){var e=t.composedPath?t.composedPath()[0]:t.target;if(this.containedByTopDialog_(e)){return}if(document.activeElement===document.documentElement){return}t.preventDefault();t.stopPropagation();m(e);if(this.forwardTab_===undefined){return}var i=this.pendingDialogStack[0];var o=i.dialog;var a=o.compareDocumentPosition(e);if(a&Node.DOCUMENT_POSITION_PRECEDING){if(this.forwardTab_){i.focus_()}else if(e!==document.documentElement){document.documentElement.focus()}}return false};x.DialogManager.prototype.handleKey_=function(t){this.forwardTab_=undefined;if(t.keyCode===27){t.preventDefault();t.stopPropagation();var e=new c("cancel",{bubbles:false,cancelable:true});var i=this.pendingDialogStack[0];if(i&&h(i.dialog,e)){i.dialog.close()}}else if(t.keyCode===9){this.forwardTab_=!t.shiftKey}};x.DialogManager.prototype.checkDOM_=function(t){var e=this.pendingDialogStack.slice();e.forEach((function(e){if(t.indexOf(e.dialog)!==-1){e.downgradeModal()}else{e.maybeHideModal()}}))};x.DialogManager.prototype.pushDialog=function(t){var e=(this.zIndexHigh_-this.zIndexLow_)/2-1;if(this.pendingDialogStack.length>=e){return false}if(this.pendingDialogStack.unshift(t)===1){this.blockDocument()}this.updateStacking();return true};x.DialogManager.prototype.removeDialog=function(t){var e=this.pendingDialogStack.indexOf(t);if(e===-1){return}this.pendingDialogStack.splice(e,1);if(this.pendingDialogStack.length===0){this.unblockDocument()}this.updateStacking()};x.dm=new x.DialogManager;x.formSubmitter=null;x.imagemapUseValue=null;if(window.HTMLDialogElement===undefined){var M=document.createElement("form");M.setAttribute("method","dialog");if(M.method!=="dialog"){var z=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"method");if(z){var E=z.get;z.get=function(){if(p(this)){return"dialog"}return E.call(this)};var C=z.set;z.set=function(t){if(typeof t==="string"&&t.toLowerCase()==="dialog"){return this.setAttribute("method",t)}return C.call(this,t)};Object.defineProperty(HTMLFormElement.prototype,"method",z)}}document.addEventListener("click",(function(t){x.formSubmitter=null;x.imagemapUseValue=null;if(t.defaultPrevented){return}var e=t.target;if("composedPath"in t){var i=t.composedPath();e=i.shift()||e}if(!e||!p(e.form)){return}var o=e.type==="submit"&&["button","input"].indexOf(e.localName)>-1;if(!o){if(!(e.localName==="input"&&e.type==="image")){return}x.imagemapUseValue=t.offsetX+","+t.offsetY}var a=f(e);if(!a){return}x.formSubmitter=e}),false);document.addEventListener("submit",(function(t){var e=t.target;var i=f(e);if(i){return}var o=w(t);var a=o&&o.getAttribute("formmethod")||e.getAttribute("method");if(a==="dialog"){t.preventDefault()}}));var D=HTMLFormElement.prototype.submit;var F=function(){if(!p(this)){return D.call(this)}var t=f(this);t&&t.close()};HTMLFormElement.prototype.submit=F}const O=()=>`:host{font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host>dialog{padding:0;border:none;margin:0;background-color:transparent}:host>dialog:modal{width:100%;max-width:100%;max-height:100%}:host>dialog::backdrop{display:none}:host>dialog+.backdrop{display:none}:host>dialog:not([open]){display:none}:host>dialog[open]{display:block}::slotted([slot="modalContent"]){padding:var(--z-modal-content-padding, calc(var(--space-unit) * 2))}.modal-container{z-index:1010;display:flex;overflow:-moz-scrollbars-none;width:100%;height:100vh;flex-direction:column}.modal-container>.modal-content-scroll-outside{overflow:auto;background:var(--color-surface01)}.modal-container>header{padding:calc(var(--space-unit) * 1.75) calc(var(--space-unit) * 2);background:var(--color-background)}.modal-container>header button{padding:0;border:none;margin:0;margin-left:auto;background:transparent;cursor:pointer}.modal-container>header button:focus-visible{border-radius:50%;box-shadow:var(--shadow-focus-primary);outline:none !important}.modal-container>header button::after{position:absolute;top:6px;right:4px;display:block;width:40px;height:40px;background-color:transparent;content:""}.modal-container>header z-icon{--z-icon-width:calc(var(--space-unit) * 2.25);--z-icon-height:calc(var(--space-unit) * 2.25);display:flex;fill:var(--color-primary01-icon)}.modal-container>header>div{display:flex;width:100%;align-items:baseline;margin-right:calc(var(--space-unit) * 2)}.modal-container>header h1,.modal-container>header .subtitle{padding:0;margin:0;color:var(--color-default-text);font-weight:var(--font-sb)}.modal-container>header h1{font-size:var(--font-size-5);letter-spacing:0;line-height:1.4}.modal-container>header .subtitle{font-size:var(--font-size-3);font-weight:var(--font-rg);letter-spacing:0;line-height:1.5}.modal-container>header>div>h1 *:empty{display:none}.modal-container>header h1+.subtitle{margin-top:calc(var(--space-unit) * 0.5)}.modal-container-scroll-inside>.modal-content-scroll-inside{overflow:hidden auto;flex:1 auto;background:var(--color-surface01)}.modal-container-scroll-inside>.modal-content-scroll-inside::-webkit-scrollbar,.modal-container-scroll-outside>.modal-content-scroll-outside::-webkit-scrollbar{width:6px;background:linear-gradient(to right, transparent 0 1px, var(--gray200) 1px 5px, transparent 5px 6px)}.modal-container-scroll-inside>.modal-content-scroll-inside::-webkit-scrollbar-thumb,.modal-container-scroll-outside>.modal-content-scroll-outside::-webkit-scrollbar-thumb{background-color:var(--color-primary01)}.modal-container-scroll-inside>.modal-content-scroll-inside::-webkit-scrollbar-thumb:hover,.modal-container-scroll-outside>.modal-content-scroll-outside::-webkit-scrollbar-thumb:hover{background-color:var(--color-hover-primary)}@supports not selector(::-webkit-scrollbar-track){.modal-container-scroll-inside .modal-content-scroll-inside,.modal-container-scroll-outside .modal-content-scroll-outside{scrollbar-color:var(--color-primary01) transparent}}@media only screen and (min-width: 768px){.modal-background{position:fixed;top:0;left:0;overflow:hidden;width:100vw;height:100vh;background-color:var(--gray900);opacity:0.7}.modal-background.modal-background-scroll-outside{position:sticky}.modal-container-scroll-inside{position:fixed;top:calc(var(--space-unit) * 6);left:50%;overflow:hidden;width:auto;min-width:calc(var(--space-unit) * 40);height:auto;min-height:calc(var(--space-unit) * 40);max-height:calc(100vh - calc(var(--space-unit) * 6 * 2));border-radius:var(--border-radius);transform:translateX(-50%)}.modal-container-scroll-outside{position:absolute;top:calc(var(--space-unit) * 6);left:50%;display:block;overflow:initial;width:auto;min-width:calc(var(--space-unit) * 40);height:auto;min-height:calc(var(--space-unit) * 40);max-height:calc(100vh - calc(var(--space-unit) * 6 * 2));transform:translateX(-50%)}.modal-container>.modal-content-scroll-outside{overflow:initial}.modal-container-scroll-outside>header,.modal-container-scroll-inside>header{border-top-left-radius:var(--border-radius);border-top-right-radius:var(--border-radius)}.modal-container-scroll-outside::after{display:block;height:calc(var(--space-unit) * 6);content:" "}.modal-dialog{position:fixed;top:0;left:0;height:auto;overflow-x:hidden;overflow-y:auto}.modal-content-scroll-outside{border-bottom-left-radius:var(--border-radius);border-bottom-right-radius:var(--border-radius)}.modal-dialog::-webkit-scrollbar{display:none}}@media (min-width: 1152px){.modal-container>header{padding-top:calc(var(--space-unit) * 1.5);padding-bottom:calc(var(--space-unit) * 1.5)}.modal-container>header h1{font-size:var(--font-size-6);font-weight:var(--font-sb);letter-spacing:0;line-height:1.333}.modal-container>header .subtitle{font-size:var(--font-size-4);font-weight:var(--font-rg);letter-spacing:0;line-height:1.5}.modal-container>header h1+.subtitle{margin-top:0}}`;const j=class extends r{constructor(i){super();t(this,i);this.modalClose=e(this,"modalClose",7);this.modalHeaderActive=e(this,"modalHeaderActive",7);this.modalBackgroundClick=e(this,"modalBackgroundClick",7);this.closeButtonLabel="chiudi modale";this.alertdialog=false;this.closable=true;this.scrollInside=true;this.lockPageScroll=true;this.focusTrapController=new s(this,{isActive:()=>{var t;return!!((t=this.dialog)===null||t===void 0?void 0:t.open)}})}emitModalClose(){if(this.closable){this.modalClose.emit({modalid:this.modalid});this.resetPageScroll()}}emitModalHeaderActive(){this.modalHeaderActive.emit({modalid:this.modalid})}emitBackgroundClick(){if(this.closable){this.modalBackgroundClick.emit({modalid:this.modalid});this.resetPageScroll()}}resetPageScroll(){if(this.lockPageScroll&&document.body.style.overflowY==="hidden"){document.body.style.overflowY=""}}componentDidLoad(){if(typeof window.HTMLDialogElement!=="function"){if(!this.dialog.localName){Object.defineProperty(this.dialog,"localName",{value:"dialog"})}x.registerDialog(this.dialog);this.dialog.setAttribute("open","true")}else{this.open()}if(this.lockPageScroll){requestAnimationFrame((()=>document.body.style.overflowY="hidden"))}super.componentDidLoad()}disconnectedCallback(){this.resetPageScroll();super.disconnectedCallback()}async open(){var t;(t=this.dialog)===null||t===void 0?void 0:t.showModal();this.focusTrapController.sync();if(this.lockPageScroll){document.body.style.overflowY="hidden"}}async close(){var t;if(this.closable){(t=this.dialog)===null||t===void 0?void 0:t.close();this.focusTrapController.sync();this.resetPageScroll()}}handleKeyDown(t){if(t.code===n.ESC&&!this.closable){t.preventDefault();return}this.focusTrapController.handleWrapTab(t)}closeButtonSlot(){if(this.closable){return i("slot",{name:"modalCloseButton"},i("button",{"aria-label":this.closeButtonLabel,onClick:()=>this.close()},i("z-icon",{name:"multiply-circle-filled"})))}}handleEscape(t){if(this.closable){return}t.preventDefault()}render(){return i("dialog",{key:"526d8a729f276a07f3ff7c40566c7e57051485a7",class:{"modal-dialog":!this.scrollInside},"aria-labelledby":"modal-title","aria-describedby":"modal-content",role:this.alertdialog?"alertdialog":undefined,ref:t=>this.dialog=t,onClose:()=>this.emitModalClose(),onCancel:t=>this.handleEscape(t)},i("div",{key:"a2a80ee8d4ea3800715cc2c1b90d6490a6cf681c",class:{"modal-container":true,"modal-container-scroll-inside":this.scrollInside,"modal-container-scroll-outside":!this.scrollInside},id:this.modalid},i("header",{key:"9406127d701e8d8c552732057f1a17c5ea9feaab",onClick:this.emitModalHeaderActive.bind(this)},i("div",{key:"bfcb837521ff1bac75f1f25d4c7c1d8405f0447d"},this.modaltitle&&i("h1",{key:"b5887ad16f0cec7086c47b7eaafa141bef42ad35",id:"modal-title"},this.modaltitle),this.closeButtonSlot()),this.modalsubtitle&&i("div",{key:"b9fdb82ebd831d6e75705b0016549139054e5901",class:"subtitle",id:"modal-subtitle"},this.modalsubtitle)),i("div",{key:"8b53454963abf4a743bf7fe19faeb2333bf8dd9e",class:{"modal-content-scroll-inside":this.scrollInside,"modal-content-scroll-outside":!this.scrollInside},id:"modal-content"},i("slot",{key:"afe97d828fea5d9b2b79d8706508b43eb74e3b5a",name:"modalContent"}))),i("div",{key:"bc6e6b79153b0187a520a75b77558e47de1db312",class:{"modal-background":true,"modal-background-scroll-outside":!this.scrollInside},"data-action":"modalBackground","data-modal":this.modalid,onClick:()=>{this.emitBackgroundClick();this.close()}}))}get host(){return a(this)}};j.style=O();export{d as z_dragdrop_area,j as z_modal};
2
+ //# sourceMappingURL=p-53943e9a.entry.js.map
@@ -1,2 +1,2 @@
1
- import{r as t,h as e,H as r}from"./p-BcDWN4F1.js";const o=()=>`:host{display:block;box-sizing:border-box}`;const a=()=>`z-table,table.z-table{background-color:var(--color-surface01);--z-table--cells-padding:calc(var(--space-unit) * 2)}table.z-table{border-collapse:collapse}z-thead,table.z-table thead{background-color:var(--color-background);--z-table--cells-bottom-border-size:var(--border-size-medium)}z-tfoot,table.z-table tfoot{border-top:var(--border-size-medium) solid var(--color-surface03);border-bottom:var(--border-size-medium) solid var(--color-surface03)}z-tfoot z-tr,table.z-table tfoot tr{border-bottom:calc(var(--z-table--cells-bottom-border-size)) solid var(--color-surface03) !important}z-tr,table.z-table tr{border-bottom:var(--z-table--cells-bottom-border-size, var(--border-size-small)) solid var(--color-surface03)}z-td,z-th,table.z-table td,table.z-table th{padding:var(--z-table--cells-padding, calc(var(--space-unit) * 2));text-align:left}z-th:not(:first-child),z-td:not(:first-child),table.z-table th:not(:first-child),table.z-table td:not(:first-child){border-left:var(--z-table--cell-left-border, none)}z-table[bordered],table.z-table.z-table-bordered{--z-table--cell-left-border:1px solid var(--color-surface03)}table.z-table-hover>tbody>tr:hover>td,table.z-table-hover>tfoot>tr:hover>td{position:relative;background-color:var(--color-surface02)}table.z-table-hover>tbody>tr:hover>td::after,table.z-table-hover>tfoot>tr:hover>td::after{position:absolute;z-index:1;top:0;right:0;bottom:0;left:-1px;box-shadow:inset 0 var(--border-size-small) 0 var(--color-surface04), inset 0 calc(var(--border-size-small) * -1) 0 var(--color-surface04);content:""}table.z-table-hover>tbody>tr:hover>td:first-child::after,table.z-table-hover>thead>tr:hover>th:first-child::after,table.z-table-hover>tfoot>tr:hover>td:first-child::after{left:0}`;const l=class{constructor(e){t(this,e)}render(){return e(r,{key:"494ae067968bb22102d480f32b06f672eb88dcaa",role:"rowgroup"},e("slot",{key:"91b431bc8748313e79673094e668b1fafb2598e5"}))}};l.style=o()+a();export{l as z_tbody};
2
- //# sourceMappingURL=p-51ebf661.entry.js.map
1
+ import{r as t,h as e,H as r}from"./p-BcDWN4F1.js";const o=()=>`:host{display:block;box-sizing:border-box}`;const a=()=>`z-table,table.z-table{background-color:var(--color-surface01);--z-table--cells-padding:calc(var(--space-unit) * 2)}table.z-table{border-collapse:collapse}z-thead,table.z-table thead{background-color:var(--color-background);--z-table--cells-bottom-border-size:var(--border-size-medium)}z-tfoot,table.z-table tfoot{border-top:var(--border-size-medium) solid var(--color-surface03);border-bottom:var(--border-size-medium) solid var(--color-surface03)}z-tfoot z-tr,table.z-table tfoot tr{border-bottom:calc(var(--z-table--cells-bottom-border-size)) solid var(--color-surface03) !important}z-tr,table.z-table tr{border-bottom:var(--z-table--cells-bottom-border-size, var(--border-size-small)) solid var(--color-surface03)}z-td,z-th,table.z-table td,table.z-table th{padding:var(--z-table--cells-padding, calc(var(--space-unit) * 2));text-align:left}z-th:not(:first-child),z-td:not(:first-child),table.z-table th:not(:first-child),table.z-table td:not(:first-child){border-left:var(--z-table--cell-left-border, none)}z-table[bordered],table.z-table.z-table-bordered{--z-table--cell-left-border:1px solid var(--color-surface03)}table.z-table-hover>tbody>tr:hover>td,table.z-table-hover>tfoot>tr:hover>td{position:relative;background-color:var(--color-surface02)}table.z-table-hover>tbody>tr:hover>td::after,table.z-table-hover>tfoot>tr:hover>td::after{position:absolute;z-index:1;top:0;right:0;bottom:0;left:-1px;box-shadow:inset 0 var(--border-size-small) 0 var(--color-surface04), inset 0 calc(var(--border-size-small) * -1) 0 var(--color-surface04);content:""}table.z-table-hover>tbody>tr:hover>td:first-child::after,table.z-table-hover>thead>tr:hover>th:first-child::after,table.z-table-hover>tfoot>tr:hover>td:first-child::after{left:0}`;const l=class{constructor(e){t(this,e)}render(){return e(r,{key:"0799f4ed498e2fc7bff1a0a87e5aeec696bce221",role:"rowgroup"},e("slot",{key:"47b9c73d0dabc8724c213775dc3e1fdbece493f0"}))}};l.style=o()+a();export{l as z_tbody};
2
+ //# sourceMappingURL=p-59651b67.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["stylesCss","ZTbody","render","h","Host","key","role"],"sources":["src/components/deprecated/table/z-tbody/styles.css?tag=z-tbody&encapsulation=shadow","src/components/css-components/z-table/styles.css?tag=z-tbody&encapsulation=shadow","src/components/deprecated/table/z-tbody/index.tsx"],"sourcesContent":[":host {\n display: block;\n box-sizing: border-box;\n}\n","z-table,\ntable.z-table {\n background-color: var(--color-surface01);\n\n --z-table--cells-padding: calc(var(--space-unit) * 2);\n}\n\ntable.z-table {\n border-collapse: collapse;\n}\n\nz-thead,\ntable.z-table thead {\n background-color: var(--color-background);\n\n --z-table--cells-bottom-border-size: var(--border-size-medium);\n}\n\nz-tfoot,\ntable.z-table tfoot {\n border-top: var(--border-size-medium) solid var(--color-surface03);\n border-bottom: var(--border-size-medium) solid var(--color-surface03);\n}\n\nz-tfoot z-tr,\ntable.z-table tfoot tr {\n border-bottom: calc(var(--z-table--cells-bottom-border-size)) solid var(--color-surface03) !important;\n}\n\nz-tr,\ntable.z-table tr {\n border-bottom: var(--z-table--cells-bottom-border-size, var(--border-size-small)) solid var(--color-surface03);\n}\n\nz-td,\nz-th,\ntable.z-table td,\ntable.z-table th {\n padding: var(--z-table--cells-padding, calc(var(--space-unit) * 2));\n text-align: left;\n}\n\nz-th:not(:first-child),\nz-td:not(:first-child),\ntable.z-table th:not(:first-child),\ntable.z-table td:not(:first-child) {\n border-left: var(--z-table--cell-left-border, none);\n}\n\nz-table[bordered],\ntable.z-table.z-table-bordered {\n --z-table--cell-left-border: 1px solid var(--color-surface03);\n}\n\ntable.z-table-hover > tbody > tr:hover > td,\ntable.z-table-hover > tfoot > tr:hover > td {\n position: relative;\n background-color: var(--color-surface02);\n}\n\ntable.z-table-hover > tbody > tr:hover > td::after,\ntable.z-table-hover > tfoot > tr:hover > td::after {\n position: absolute;\n z-index: 1;\n top: 0;\n right: 0;\n bottom: 0;\n left: -1px;\n box-shadow:\n inset 0 var(--border-size-small) 0 var(--color-surface04),\n inset 0 calc(var(--border-size-small) * -1) 0 var(--color-surface04);\n content: \"\";\n}\n\ntable.z-table-hover > tbody > tr:hover > td:first-child::after,\ntable.z-table-hover > thead > tr:hover > th:first-child::after,\ntable.z-table-hover > tfoot > tr:hover > td:first-child::after {\n left: 0;\n}\n","import {Component, ComponentInterface, Host, h} from \"@stencil/core\";\n\n/**\n * ZTbody component.\n * @slot - ZTbody content (`z-tr`).\n */\n@Component({\n tag: \"z-tbody\",\n styleUrls: [\"styles.css\", \"../../../css-components/z-table/styles.css\"],\n shadow: true,\n})\nexport class ZTbody implements ComponentInterface {\n render(): HTMLZTbodyElement {\n return (\n <Host role=\"rowgroup\">\n <slot></slot>\n </Host>\n );\n }\n}\n"],"mappings":"kDAAA,MAAMA,EAAY,IAAM,6CCAxB,MAAMA,EAAY,IAAM,6sD,MCWXC,EAAM,M,yBACjB,MAAAC,GACE,OACEC,EAACC,EAAI,CAAAC,IAAA,2CAACC,KAAK,YACTH,EAAA,QAAAE,IAAA,6C","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- import{r as e,c as t,h as o,H as a,d as r}from"./p-BcDWN4F1.js";import{P as l,e as s,B as c}from"./p-DdetsoIY.js";const i=()=>`:host{position:relative;display:flex;max-width:100%;align-items:center;background-color:var(--color-surface01);gap:calc(var(--space-unit) * 2) var(--space-unit)}:host,*{box-sizing:border-box}:host([sticky]){position:sticky;z-index:1;top:0;left:0;box-shadow:8px 0 16px -8px var(--shadow-color-base)}:host([menu-open]){z-index:2}.cell--content{display:flex;width:100%;height:100%;align-items:center}:host([show-menu]) .cell--content{column-gap:var(--space-unit)}.cell--menu-container{margin-left:auto}:host(:not([show-menu])) .cell--menu-container{opacity:0;pointer-events:none}:host(:is([show-menu],[menu-open])) .cell--menu-container,:host([show-menu]) .cell--menu-container:focus-within{z-index:1;opacity:1;pointer-events:all}:host .cell-popover{z-index:100}@media (min-width: 768px) and (hover: hover){:host([show-menu="hover"]) .cell--menu-container{opacity:0;pointer-events:none}:host([show-menu="hover"]:hover) .cell--menu-container{z-index:1;opacity:1;pointer-events:all}}`;const n=()=>`z-table,table.z-table{background-color:var(--color-surface01);--z-table--cells-padding:calc(var(--space-unit) * 2)}table.z-table{border-collapse:collapse}z-thead,table.z-table thead{background-color:var(--color-background);--z-table--cells-bottom-border-size:var(--border-size-medium)}z-tfoot,table.z-table tfoot{border-top:var(--border-size-medium) solid var(--color-surface03);border-bottom:var(--border-size-medium) solid var(--color-surface03)}z-tfoot z-tr,table.z-table tfoot tr{border-bottom:calc(var(--z-table--cells-bottom-border-size)) solid var(--color-surface03) !important}z-tr,table.z-table tr{border-bottom:var(--z-table--cells-bottom-border-size, var(--border-size-small)) solid var(--color-surface03)}z-td,z-th,table.z-table td,table.z-table th{padding:var(--z-table--cells-padding, calc(var(--space-unit) * 2));text-align:left}z-th:not(:first-child),z-td:not(:first-child),table.z-table th:not(:first-child),table.z-table td:not(:first-child){border-left:var(--z-table--cell-left-border, none)}z-table[bordered],table.z-table.z-table-bordered{--z-table--cell-left-border:1px solid var(--color-surface03)}table.z-table-hover>tbody>tr:hover>td,table.z-table-hover>tfoot>tr:hover>td{position:relative;background-color:var(--color-surface02)}table.z-table-hover>tbody>tr:hover>td::after,table.z-table-hover>tfoot>tr:hover>td::after{position:absolute;z-index:1;top:0;right:0;bottom:0;left:-1px;box-shadow:inset 0 var(--border-size-small) 0 var(--color-surface04), inset 0 calc(var(--border-size-small) * -1) 0 var(--color-surface04);content:""}table.z-table-hover>tbody>tr:hover>td:first-child::after,table.z-table-hover>thead>tr:hover>th:first-child::after,table.z-table-hover>tfoot>tr:hover>td:first-child::after{left:0}`;const b=class{constructor(o){e(this,o);this.colspanChange=t(this,"colspanChange",6);this.sticky=false;this.showMenu=null;this.popoverPosition=l.AUTO;this.isMenuOpen=false}updateColspan(){if(this.colspan){this.host.style.gridColumn=`span ${this.colspan}`}else{this.host.style.removeProperty("grid-column")}this.colspanChange.emit(this.colspan||1)}onMenuButtonClick(e){e.stopPropagation();this.popoverEl.open=!this.popoverEl.open}componentWillLoad(){this.updateColspan()}render(){return o(a,{key:"da91e90c7f553840c642aabd1a4ebf17623791eb",role:"cell","menu-open":this.isMenuOpen},o("div",{key:"89541c4a1c5edccc0c3b940591ffe32e72de44ab",class:"cell--content"},o("slot",{key:"bf3c8b8458d6737f08d731c0e7c15d57a28e54c4"}),this.showMenu&&o("div",{key:"8d4dc82cf51219ef93c8bca773bd24d45ea51a2b",class:"cell--menu-container prevent-expand"},o("z-button",{key:"fc08af544b4403f12a2856b679acb5024dfb1a3b",variant:c.TERTIARY,icon:"contextual-menu",size:s.X_SMALL,ref:e=>this.menuTrigger=e,onClick:this.onMenuButtonClick.bind(this)}),o("z-popover",{key:"9fe54dd192458e543fff45539b59c1c60e1ac67d",class:"cell-popover",ref:e=>this.popoverEl=e,bindTo:this.menuTrigger,onOpenChange:e=>this.isMenuOpen=e.detail.open,position:this.popoverPosition},o("slot",{key:"5ca045abb9e47bf27b391024c940dec3f37b3cff",name:"contextual-menu"})))))}get host(){return r(this)}static get watchers(){return{colspan:[{updateColspan:0}]}}};b.style=i()+n();export{b as z_td};
2
- //# sourceMappingURL=p-ccedd440.entry.js.map
1
+ import{r as e,c as t,h as o,H as a,d as r}from"./p-BcDWN4F1.js";import{P as l,e as s,B as c}from"./p-DdetsoIY.js";const i=()=>`:host{position:relative;display:flex;max-width:100%;align-items:center;background-color:var(--color-surface01);gap:calc(var(--space-unit) * 2) var(--space-unit)}:host,*{box-sizing:border-box}:host([sticky]){position:sticky;z-index:1;top:0;left:0;box-shadow:8px 0 16px -8px var(--shadow-color-base)}:host([menu-open]){z-index:2}.cell--content{display:flex;width:100%;height:100%;align-items:center}:host([show-menu]) .cell--content{column-gap:var(--space-unit)}.cell--menu-container{margin-left:auto}:host(:not([show-menu])) .cell--menu-container{opacity:0;pointer-events:none}:host(:is([show-menu],[menu-open])) .cell--menu-container,:host([show-menu]) .cell--menu-container:focus-within{z-index:1;opacity:1;pointer-events:all}:host .cell-popover{z-index:100}@media (min-width: 768px) and (hover: hover){:host([show-menu="hover"]) .cell--menu-container{opacity:0;pointer-events:none}:host([show-menu="hover"]:hover) .cell--menu-container{z-index:1;opacity:1;pointer-events:all}}`;const n=()=>`z-table,table.z-table{background-color:var(--color-surface01);--z-table--cells-padding:calc(var(--space-unit) * 2)}table.z-table{border-collapse:collapse}z-thead,table.z-table thead{background-color:var(--color-background);--z-table--cells-bottom-border-size:var(--border-size-medium)}z-tfoot,table.z-table tfoot{border-top:var(--border-size-medium) solid var(--color-surface03);border-bottom:var(--border-size-medium) solid var(--color-surface03)}z-tfoot z-tr,table.z-table tfoot tr{border-bottom:calc(var(--z-table--cells-bottom-border-size)) solid var(--color-surface03) !important}z-tr,table.z-table tr{border-bottom:var(--z-table--cells-bottom-border-size, var(--border-size-small)) solid var(--color-surface03)}z-td,z-th,table.z-table td,table.z-table th{padding:var(--z-table--cells-padding, calc(var(--space-unit) * 2));text-align:left}z-th:not(:first-child),z-td:not(:first-child),table.z-table th:not(:first-child),table.z-table td:not(:first-child){border-left:var(--z-table--cell-left-border, none)}z-table[bordered],table.z-table.z-table-bordered{--z-table--cell-left-border:1px solid var(--color-surface03)}table.z-table-hover>tbody>tr:hover>td,table.z-table-hover>tfoot>tr:hover>td{position:relative;background-color:var(--color-surface02)}table.z-table-hover>tbody>tr:hover>td::after,table.z-table-hover>tfoot>tr:hover>td::after{position:absolute;z-index:1;top:0;right:0;bottom:0;left:-1px;box-shadow:inset 0 var(--border-size-small) 0 var(--color-surface04), inset 0 calc(var(--border-size-small) * -1) 0 var(--color-surface04);content:""}table.z-table-hover>tbody>tr:hover>td:first-child::after,table.z-table-hover>thead>tr:hover>th:first-child::after,table.z-table-hover>tfoot>tr:hover>td:first-child::after{left:0}`;const d=class{constructor(o){e(this,o);this.colspanChange=t(this,"colspanChange",6);this.sticky=false;this.showMenu=null;this.popoverPosition=l.AUTO;this.isMenuOpen=false}updateColspan(){if(this.colspan){this.host.style.gridColumn=`span ${this.colspan}`}else{this.host.style.removeProperty("grid-column")}this.colspanChange.emit(this.colspan||1)}onMenuButtonClick(e){e.stopPropagation();this.popoverEl.open=!this.popoverEl.open}componentWillLoad(){this.updateColspan()}render(){return o(a,{key:"b89fd7b33f9d928a6c60b5493ee2732edda4318c",role:"cell","menu-open":this.isMenuOpen},o("div",{key:"ac47204976e01cc5f2371d87faf4e15bbcb9b923",class:"cell--content"},o("slot",{key:"24eddf43aa23971f21dcfcae158111cbab7689e3"}),this.showMenu&&o("div",{key:"8545b4567dcd1a3a3fb8a4e0913753af0cdaaf11",class:"cell--menu-container prevent-expand"},o("z-button",{key:"2b96d9dda4c2794e1f9c7d5dc936ac1701d11ba6",variant:c.TERTIARY,icon:"contextual-menu",size:s.X_SMALL,ref:e=>this.menuTrigger=e,onClick:this.onMenuButtonClick.bind(this)}),o("z-popover",{key:"ebee2d5c76f8573362e9a912b62e238d9eef6d5a",class:"cell-popover",ref:e=>this.popoverEl=e,bindTo:this.menuTrigger,onOpenChange:e=>this.isMenuOpen=e.detail.open,position:this.popoverPosition},o("slot",{key:"b3b6392cf7d0044fc4fc3773817efe7ba46bd598",name:"contextual-menu"})))))}get host(){return r(this)}static get watchers(){return{colspan:[{updateColspan:0}]}}};d.style=i()+n();export{d as z_td};
2
+ //# sourceMappingURL=p-65c404bc.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["zTableCellsCss","stylesCss","ZTd","constructor","hostRef","this","sticky","showMenu","popoverPosition","PopoverPosition","AUTO","isMenuOpen","updateColspan","colspan","host","style","gridColumn","removeProperty","colspanChange","emit","onMenuButtonClick","ev","stopPropagation","popoverEl","open","componentWillLoad","render","h","Host","key","role","class","variant","ButtonVariant","TERTIARY","icon","size","ControlSize","X_SMALL","ref","el","menuTrigger","onClick","bind","bindTo","onOpenChange","event","detail","position","name"],"sources":["src/components/deprecated/table/cells/z-table-cells.css?tag=z-td&encapsulation=shadow","src/components/css-components/z-table/styles.css?tag=z-td&encapsulation=shadow","src/components/deprecated/table/cells/z-td/index.tsx"],"sourcesContent":[":host {\n position: relative;\n display: flex;\n max-width: 100%;\n align-items: center;\n background-color: var(--color-surface01);\n gap: calc(var(--space-unit) * 2) var(--space-unit);\n}\n\n:host,\n* {\n box-sizing: border-box;\n}\n\n:host([sticky]) {\n position: sticky;\n z-index: 1;\n top: 0;\n left: 0;\n box-shadow: 8px 0 16px -8px var(--shadow-color-base);\n}\n\n:host([menu-open]) {\n z-index: 2;\n}\n\n.cell--content {\n display: flex;\n width: 100%;\n height: 100%;\n align-items: center;\n}\n\n:host([show-menu]) .cell--content {\n column-gap: var(--space-unit);\n}\n\n.cell--menu-container {\n margin-left: auto;\n}\n\n:host(:not([show-menu])) .cell--menu-container {\n opacity: 0;\n pointer-events: none;\n}\n\n:host(:is([show-menu], [menu-open])) .cell--menu-container,\n:host([show-menu]) .cell--menu-container:focus-within {\n z-index: 1;\n opacity: 1;\n pointer-events: all;\n}\n\n:host .cell-popover {\n z-index: 100;\n}\n\n@media (min-width: 768px) and (hover: hover) {\n :host([show-menu=\"hover\"]) .cell--menu-container {\n opacity: 0;\n pointer-events: none;\n }\n\n :host([show-menu=\"hover\"]:hover) .cell--menu-container {\n z-index: 1;\n opacity: 1;\n pointer-events: all;\n }\n}\n","z-table,\ntable.z-table {\n background-color: var(--color-surface01);\n\n --z-table--cells-padding: calc(var(--space-unit) * 2);\n}\n\ntable.z-table {\n border-collapse: collapse;\n}\n\nz-thead,\ntable.z-table thead {\n background-color: var(--color-background);\n\n --z-table--cells-bottom-border-size: var(--border-size-medium);\n}\n\nz-tfoot,\ntable.z-table tfoot {\n border-top: var(--border-size-medium) solid var(--color-surface03);\n border-bottom: var(--border-size-medium) solid var(--color-surface03);\n}\n\nz-tfoot z-tr,\ntable.z-table tfoot tr {\n border-bottom: calc(var(--z-table--cells-bottom-border-size)) solid var(--color-surface03) !important;\n}\n\nz-tr,\ntable.z-table tr {\n border-bottom: var(--z-table--cells-bottom-border-size, var(--border-size-small)) solid var(--color-surface03);\n}\n\nz-td,\nz-th,\ntable.z-table td,\ntable.z-table th {\n padding: var(--z-table--cells-padding, calc(var(--space-unit) * 2));\n text-align: left;\n}\n\nz-th:not(:first-child),\nz-td:not(:first-child),\ntable.z-table th:not(:first-child),\ntable.z-table td:not(:first-child) {\n border-left: var(--z-table--cell-left-border, none);\n}\n\nz-table[bordered],\ntable.z-table.z-table-bordered {\n --z-table--cell-left-border: 1px solid var(--color-surface03);\n}\n\ntable.z-table-hover > tbody > tr:hover > td,\ntable.z-table-hover > tfoot > tr:hover > td {\n position: relative;\n background-color: var(--color-surface02);\n}\n\ntable.z-table-hover > tbody > tr:hover > td::after,\ntable.z-table-hover > tfoot > tr:hover > td::after {\n position: absolute;\n z-index: 1;\n top: 0;\n right: 0;\n bottom: 0;\n left: -1px;\n box-shadow:\n inset 0 var(--border-size-small) 0 var(--color-surface04),\n inset 0 calc(var(--border-size-small) * -1) 0 var(--color-surface04);\n content: \"\";\n}\n\ntable.z-table-hover > tbody > tr:hover > td:first-child::after,\ntable.z-table-hover > thead > tr:hover > th:first-child::after,\ntable.z-table-hover > tfoot > tr:hover > td:first-child::after {\n left: 0;\n}\n","import {Component, ComponentInterface, Element, Event, EventEmitter, Host, Prop, State, Watch, h} from \"@stencil/core\";\nimport {ButtonVariant, ControlSize, PopoverPosition, VisibilityCondition} from \"../../../../../beans\";\n\n/**\n * ZTd component.\n * @slot - ZTd content.\n */\n@Component({\n tag: \"z-td\",\n styleUrls: [\"../z-table-cells.css\", \"../../../../css-components/z-table/styles.css\"],\n shadow: true,\n})\nexport class ZTd implements ComponentInterface {\n @Element() host: HTMLZTdElement;\n\n /**\n * Number of columns that the cell should span.\n */\n @Prop()\n colspan: number;\n\n /**\n * Whether the cell should stick.\n */\n @Prop({reflect: true})\n sticky = false;\n\n /**\n * Enables the contextual menu.\n * Can be set to \"hover\" or \"always\" to show the button only on cell hover or always.\n * Set a nullish value to hide the menu button.\n */\n @Prop({reflect: true})\n showMenu: VisibilityCondition = null;\n\n /**\n * Set the popover position, the default is \"auto\".\n */\n @Prop()\n popoverPosition?: PopoverPosition = PopoverPosition.AUTO;\n\n /**\n * Store the open state of the menu.\n */\n @State()\n isMenuOpen = false;\n\n private menuTrigger: HTMLZButtonElement;\n\n private popoverEl: HTMLZPopoverElement;\n\n /**\n * Emitted when the value of the `colspan` changes.\n */\n @Event({\n bubbles: true,\n cancelable: false,\n })\n colspanChange: EventEmitter<number>;\n\n @Watch(\"colspan\")\n protected updateColspan(): void {\n if (this.colspan) {\n this.host.style.gridColumn = `span ${this.colspan}`;\n } else {\n this.host.style.removeProperty(\"grid-column\");\n }\n\n this.colspanChange.emit(this.colspan || 1);\n }\n\n private onMenuButtonClick(ev: MouseEvent): void {\n ev.stopPropagation();\n this.popoverEl.open = !this.popoverEl.open;\n }\n\n componentWillLoad(): void {\n this.updateColspan();\n }\n\n render(): HTMLZTdElement {\n return (\n <Host\n role=\"cell\"\n menu-open={this.isMenuOpen}\n >\n <div class=\"cell--content\">\n <slot></slot>\n {this.showMenu && (\n <div class=\"cell--menu-container prevent-expand\">\n <z-button\n variant={ButtonVariant.TERTIARY}\n icon=\"contextual-menu\"\n size={ControlSize.X_SMALL}\n ref={(el) => (this.menuTrigger = el as HTMLZButtonElement)}\n onClick={this.onMenuButtonClick.bind(this)}\n />\n <z-popover\n class=\"cell-popover\"\n ref={(el) => (this.popoverEl = el as HTMLZPopoverElement)}\n bindTo={this.menuTrigger as HTMLElement}\n onOpenChange={(event) => (this.isMenuOpen = event.detail.open)}\n position={this.popoverPosition}\n >\n <slot name=\"contextual-menu\"></slot>\n </z-popover>\n </div>\n )}\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"kHAAA,MAAMA,EAAiB,IAAM,q9BCA7B,MAAMC,EAAY,IAAM,6sD,MCYXC,EAAG,MALhB,WAAAC,CAAAC,G,uDAkBEC,KAAAC,OAAS,MAQTD,KAAAE,SAAgC,KAMhCF,KAAAG,gBAAoCC,EAAgBC,KAMpDL,KAAAM,WAAa,KAmEd,CAnDW,aAAAC,GACR,GAAIP,KAAKQ,QAAS,CAChBR,KAAKS,KAAKC,MAAMC,WAAa,QAAQX,KAAKQ,S,KACrC,CACLR,KAAKS,KAAKC,MAAME,eAAe,c,CAGjCZ,KAAKa,cAAcC,KAAKd,KAAKQ,SAAW,E,CAGlC,iBAAAO,CAAkBC,GACxBA,EAAGC,kBACHjB,KAAKkB,UAAUC,MAAQnB,KAAKkB,UAAUC,I,CAGxC,iBAAAC,GACEpB,KAAKO,e,CAGP,MAAAc,GACE,OACEC,EAACC,EAAI,CAAAC,IAAA,2CACHC,KAAK,OAAM,YACAzB,KAAKM,YAEhBgB,EAAA,OAAAE,IAAA,2CAAKE,MAAM,iBACTJ,EAAA,QAAAE,IAAA,6CACCxB,KAAKE,UACJoB,EAAA,OAAAE,IAAA,2CAAKE,MAAM,uCACTJ,EAAA,YAAAE,IAAA,2CACEG,QAASC,EAAcC,SACvBC,KAAK,kBACLC,KAAMC,EAAYC,QAClBC,IAAMC,GAAQnC,KAAKoC,YAAcD,EACjCE,QAASrC,KAAKe,kBAAkBuB,KAAKtC,QAEvCsB,EAAA,aAAAE,IAAA,2CACEE,MAAM,eACNQ,IAAMC,GAAQnC,KAAKkB,UAAYiB,EAC/BI,OAAQvC,KAAKoC,YACbI,aAAeC,GAAWzC,KAAKM,WAAamC,EAAMC,OAAOvB,KACzDwB,SAAU3C,KAAKG,iBAEfmB,EAAA,QAAAE,IAAA,2CAAMoB,KAAK,uB","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- import{r as t,c as e,h as i,H as n,d as o}from"./p-BcDWN4F1.js";import{_ as a,e as l}from"./p-DdetsoIY.js";const r=()=>`:host{--z-book-card-portrait-cover-height:378px;--z-book-card-title-lines:2;--z-book-card-title-word-break:initial;--z-book-card-subtitle-lines:1;--z-book-card-subtitle-word-break:break-all;--z-book-card-authors-lines:1;--z-book-card-authors-word-break:break-all;display:flex;width:304px;box-sizing:border-box;flex-direction:column;border:solid var(--border-size-medium) var(--color-surface03);background-color:var(--color-surface01);border-radius:var(--border-radius);color:var(--color-default-text);font-family:var(--font-family-sans)}:host,*{box-sizing:border-box}.main-content{display:flex;height:100%;flex-direction:column;padding:var(--space-unit);gap:var(--space-unit)}.main-content .cover{position:relative;display:flex;overflow:hidden;align-items:flex-end;justify-content:center;border-radius:var(--border-radius)}.main-content .cover z-book-cover{--z-book-cover-height:var(--z-book-card-portrait-cover-height)}.main-content a.cover:focus-visible{box-shadow:var(--shadow-focus-primary);outline:none}.main-content .card-info{display:flex;flex:1;flex-direction:column;justify-content:space-between;gap:var(--space-unit)}.main-content .card-info .top{display:flex;flex-direction:column;gap:calc(var(--space-unit) * 2)}.main-content .card-info .top ::slotted([slot="tags"]){display:flex;flex-wrap:wrap;gap:var(--space-unit)}.main-content .card-info .top ::slotted([slot="data"]){display:flex;justify-content:space-between}.main-content .card-info .top .ellipsis{display:-webkit-box;overflow:hidden;height:1.4rem;-webkit-box-orient:vertical;-webkit-line-clamp:1;line-clamp:1;line-height:1.4rem;text-overflow:ellipsis;word-break:break-all}.main-content .card-info .top .ellipsis.opera-title{height:auto;max-height:calc(1.5rem * var(--z-book-card-title-lines));-webkit-line-clamp:var(--z-book-card-title-lines);line-clamp:var(--z-book-card-title-lines);line-height:1.5rem;word-break:var(--z-book-card-title-word-break)}.main-content .card-info .top .ellipsis.volume-title{height:auto;max-height:calc(1.4rem * var(--z-book-card-subtitle-lines));-webkit-line-clamp:var(--z-book-card-subtitle-lines);line-clamp:var(--z-book-card-subtitle-lines);line-height:1.4rem;word-break:var(--z-book-card-subtitle-word-break)}.main-content .card-info .top .ellipsis.authors{height:auto;max-height:calc(1.4rem * var(--z-book-card-authors-lines));-webkit-line-clamp:var(--z-book-card-authors-lines);line-clamp:var(--z-book-card-authors-lines);line-height:1.4rem;word-break:var(--z-book-card-authors-word-break)}.main-content .card-info .top .opera-title *{all:unset}.main-content .cta-wrapper{display:flex;justify-content:space-between;gap:calc(var(--space-unit) / 2)}.main-content .card-info .top .link-chip-wrapper{display:flex;justify-content:space-between}.main-content .card-info .bottom .ebook{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;padding:var(--space-unit);background-color:var(--color-primary02);border-radius:var(--border-radius);gap:var(--space-unit)}.main-content .card-info .bottom .ebook .app-name{display:flex;align-items:center;padding:calc(var(--space-unit) / 2) 0;font-family:var(--font-family-serif);gap:calc(var(--space-unit) / 2)}.main-content .card-info .bottom .ebook .app-name .ebook-logo{width:1.5rem;height:1.5rem;content:url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 20 20%22 fill=%22none%22 aria-hidden=%22true%22%3E%3Cg clip-path=%22url(%23clip0_11996_224)%22%3E%3Cpath d=%22M14.6644 0.469604H5.00141C2.33305 0.469604 0.169922 2.63274 0.169922 5.3011V14.9641C0.169922 17.6324 2.33305 19.7956 5.00141 19.7956H14.6644C17.3328 19.7956 19.4959 17.6324 19.4959 14.9641V5.3011C19.4959 2.63274 17.3328 0.469604 14.6644 0.469604Z%22 fill=%22%23E2011A%22/%3E%3Cpath d=%22M15.9523 13.3536H12.7313C11.6861 13.3536 10.6683 13.6934 9.83241 14.3199C8.99657 13.6934 7.97873 13.3536 6.93352 13.3536H3.71252V5.30115H6.93352C7.97873 5.30115 8.99657 5.64096 9.83241 6.26745C10.6683 5.64096 11.6861 5.30115 12.7313 5.30115H15.9523V13.3536Z%22 fill=%22white%22/%3E%3Cpath d=%22M15.9523 14.3201H3.71252V14.9643H15.9523V14.3201Z%22 fill=%22black%22/%3E%3Cpath d=%22M8.22229 10.732V8.24543C8.22229 7.97165 8.51057 7.79449 8.75375 7.91689L11.2404 9.16019C11.5109 9.29548 11.5109 9.682 11.2404 9.81728L8.75375 11.0606C8.50896 11.183 8.22229 11.0058 8.22229 10.732Z%22 fill=%22black%22/%3E%3Cpath d=%22M4.35704 7.87826C5.42438 7.87826 6.28963 7.013 6.28963 5.94566C6.28963 4.87831 5.42438 4.01306 4.35704 4.01306C3.28969 4.01306 2.42444 4.87831 2.42444 5.94566C2.42444 7.013 3.28969 7.87826 4.35704 7.87826Z%22 fill=%22black%22/%3E%3Cpath d=%22M5.6454 5.62354H3.0686V6.26773H5.6454V5.62354Z%22 fill=%22white%22/%3E%3Cpath d=%22M4.67917 4.65723H4.03497V7.23402H4.67917V4.65723Z%22 fill=%22white%22/%3E%3C/g%3E%3Cdefs%3E%3CclipPath id=%22clip0_11996_224%22%3E%3Crect width=%2219.326%22 height=%2219.326%22 fill=%22white%22 transform=%22translate(0.169922 0.469604)%22/%3E%3C/clipPath%3E%3C/defs%3E%3C/svg%3E")}:host([variant="landscape"]){width:635px;min-height:max(332px, 20.75rem);padding:0}:host([variant="landscape"]) .main-content{min-height:max(332px, 20.75rem);flex-direction:row;padding:calc(var(--space-unit) * 2);gap:calc(var(--space-unit) * 2)}:host([variant="landscape"]) .main-content .cover z-book-cover{--z-book-cover-height:300px}:host([variant="landscape"]) .main-content .card-info,:host([variant="landscape"]) .main-content .card-info .top{gap:calc(var(--space-unit) / 2)}@media (max-width: 767px){:host([variant="portrait"]){width:100%;max-width:400px}}`;const s=()=>`:root{--font-family-sans:"IBM Plex Sans", sans-serif;--font-family-serif:"IBM Plex Serif", serif;--font-lt:300;--font-rg:400;--font-sb:600;--font-bd:700;--font-size-1:0.75rem;--font-size-2:0.875rem;--font-size-3:1rem;--font-size-4:1.125rem;--font-size-5:1.25rem;--font-size-6:1.5rem;--font-size-7:1.75rem;--font-size-8:2rem;--font-size-9:2.25rem;--font-size-10:2.625rem;--font-size-11:3rem;--font-size-12:3.375rem;--font-size-13:3.75rem;--font-size-14:4.25rem;--font-size-15:4.75rem;--font-size-16:5.25rem;--font-size-17:5.75rem;--section-title-1:var(--font-sb) var(--font-size-11) / 1.083 var(--font-family-serif);--section-title-2:var(--font-sb) var(--font-size-10) / 1.142 var(--font-family-serif);--section-title-3:var(--font-sb) var(--font-size-9) / 1.222 var(--font-family-serif);--section-title-4:var(--font-sb) var(--font-size-8) / 1.25 var(--font-family-serif);--section-title-5:var(--font-sb) var(--font-size-7) / 1.2857 var(--font-family-serif);--section-title-6:var(--font-sb) var(--font-size-6) / 1.333 var(--font-family-serif)}.heading-1,.heading-1-sb,.heading-1-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.heading-2,.heading-2-sb,.heading-2-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.heading-3,.heading-3-sb,.heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.heading-4,.heading-4-sb,.heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.body-1,.body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.body-2,.body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.body-3,.body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.body-4,.body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.body-5,.body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.interactive-1,.interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.interactive-2,.interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.interactive-3,.interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.helper,.helper-sb{font-size:var(--font-size-1);font-style:italic;font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.section-title-1{font:var(--section-title-1)}.section-title-2{font:var(--section-title-2)}.section-title-3{font:var(--section-title-3)}.section-title-4{font:var(--section-title-4)}.section-title-5{font:var(--section-title-5)}.section-title-6{font:var(--section-title-6)}@media (min-width: 1152px){.heading-1,.heading-1-sb,.heading-1-lt{font-size:var(--font-size-8);font-weight:var(--font-rg);line-height:1.25}.heading-2,.heading-2-sb,.heading-2-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}}@media (max-width: 767px){.mobile-heading-1,.mobile-heading-1-sb,.mobile-heading-1-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.mobile-heading-2,.mobile-heading-2-sb,.mobile-heading-2-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.mobile-heading-3,.mobile-heading-3-sb,.mobile-heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.mobile-heading-4,.mobile-heading-4-sb,.mobile-heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.mobile-body-1,.mobile-body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.mobile-body-2,.mobile-body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.mobile-body-3,.mobile-body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.mobile-body-4,.mobile-body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.mobile-body-5,.mobile-body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.mobile-interactive-1,.mobile-interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.mobile-interactive-2,.mobile-interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.mobile-interactive-3,.mobile-interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.mobile-section-title-1{font:var(--section-title-1)}.mobile-section-title-2{font:var(--section-title-2)}.mobile-section-title-3{font:var(--section-title-3)}.mobile-section-title-4{font:var(--section-title-4)}.mobile-section-title-5{font:var(--section-title-5)}.mobile-section-title-6{font:var(--section-title-6)}.mobile-heading-1-lt,.mobile-heading-2-lt,.mobile-heading-3-lt,.mobile-heading-4-lt{font-weight:var(--font-lt)}.mobile-heading-1-sb,.mobile-heading-2-sb,.mobile-heading-3-sb,.mobile-heading-4-sb,.mobile-body-1-sb,.mobile-body-2-sb,.mobile-body-3-sb,.mobile-body-4-sb,.mobile-body-5-sb,.mobile-interactive-1-sb,.mobile-interactive-2-sb,.mobile-interactive-3-sb{font-weight:var(--font-sb)}}@media (min-width: 768px) and (max-width: 1151px){.tablet-heading-1,.tablet-heading-1-sb,.tablet-heading-1-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.tablet-heading-2,.tablet-heading-2-sb,.tablet-heading-2-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.tablet-heading-3,.tablet-heading-3-sb,.tablet-heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.tablet-heading-4,.tablet-heading-4-sb,.tablet-heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.tablet-body-1,.tablet-body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.tablet-body-2,.tablet-body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.tablet-body-3,.tablet-body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.tablet-body-4,.tablet-body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.tablet-body-5,.tablet-body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.tablet-interactive-1,.tablet-interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.tablet-interactive-2,.tablet-interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.tablet-interactive-3,.tablet-interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.tablet-section-title-1{font:var(--section-title-1)}.tablet-section-title-2{font:var(--section-title-2)}.tablet-section-title-3{font:var(--section-title-3)}.tablet-section-title-4{font:var(--section-title-4)}.tablet-section-title-5{font:var(--section-title-5)}.tablet-section-title-6{font:var(--section-title-6)}.tablet-heading-1-lt,.tablet-heading-2-lt,.tablet-heading-3-lt,.tablet-heading-4-lt{font-weight:var(--font-lt)}.tablet-heading-1-sb,.tablet-heading-2-sb,.tablet-heading-3-sb,.tablet-heading-4-sb,.tablet-body-1-sb,.tablet-body-2-sb,.tablet-body-3-sb,.tablet-body-4-sb,.tablet-body-5-sb,.tablet-interactive-1-sb,.tablet-interactive-2-sb,.tablet-interactive-3-sb{font-weight:var(--font-sb)}}@media (min-width: 1152px) and (max-width: 1365px){.desktop-heading-1,.desktop-heading-1-sb,.desktop-heading-1-lt{font-size:var(--font-size-8);font-weight:var(--font-rg);line-height:1.25}.desktop-heading-2,.desktop-heading-2-sb,.desktop-heading-2-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.desktop-heading-3,.desktop-heading-3-sb,.desktop-heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.desktop-heading-4,.desktop-heading-4-sb,.desktop-heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.desktop-body-1,.desktop-body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.desktop-body-2,.desktop-body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.desktop-body-3,.desktop-body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.desktop-body-4,.desktop-body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.desktop-body-5,.desktop-body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.desktop-interactive-1,.desktop-interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.desktop-interactive-2,.desktop-interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.desktop-interactive-3,.desktop-interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.desktop-section-title-1{font:var(--section-title-1)}.desktop-section-title-2{font:var(--section-title-2)}.desktop-section-title-3{font:var(--section-title-3)}.desktop-section-title-4{font:var(--section-title-4)}.desktop-section-title-5{font:var(--section-title-5)}.desktop-section-title-6{font:var(--section-title-6)}.desktop-heading-1-lt,.desktop-heading-2-lt,.desktop-heading-3-lt,.desktop-heading-4-lt{font-weight:var(--font-lt)}.desktop-heading-1-sb,.desktop-heading-2-sb,.desktop-heading-3-sb,.desktop-heading-4-sb,.desktop-body-1-sb,.desktop-body-2-sb,.desktop-body-3-sb,.desktop-body-4-sb,.desktop-body-5-sb,.desktop-interactive-1-sb,.desktop-interactive-2-sb,.desktop-interactive-3-sb{font-weight:var(--font-sb)}}@media (min-width: 1366px){.wide-heading-1,.wide-heading-1-sb,.wide-heading-1-lt{font-size:var(--font-size-8);font-weight:var(--font-rg);line-height:1.25}.wide-heading-2,.wide-heading-2-sb,.wide-heading-2-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.wide-heading-3,.wide-heading-3-sb,.wide-heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.wide-heading-4,.wide-heading-4-sb,.wide-heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.wide-body-1,.wide-body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.wide-body-2,.wide-body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.wide-body-3,.wide-body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.wide-body-4,.wide-body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.wide-body-5,.wide-body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.wide-interactive-1,.wide-interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.wide-interactive-2,.wide-interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.wide-interactive-3,.wide-interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.wide-section-title-1{font:var(--section-title-1)}.wide-section-title-2{font:var(--section-title-2)}.wide-section-title-3{font:var(--section-title-3)}.wide-section-title-4{font:var(--section-title-4)}.wide-section-title-5{font:var(--section-title-5)}.wide-section-title-6{font:var(--section-title-6)}.wide-heading-1-lt,.wide-heading-2-lt,.wide-heading-3-lt,.wide-heading-4-lt{font-weight:var(--font-lt)}.wide-heading-1-sb,.wide-heading-2-sb,.wide-heading-3-sb,.wide-heading-4-sb,.wide-body-1-sb,.wide-body-2-sb,.wide-body-3-sb,.wide-body-4-sb,.wide-body-5-sb,.wide-interactive-1-sb,.wide-interactive-2-sb,.wide-interactive-3-sb{font-weight:var(--font-sb)}}.heading-1-lt,.heading-2-lt,.heading-3-lt,.heading-4-lt{font-weight:var(--font-lt)}.heading-1-sb,.heading-2-sb,.heading-3-sb,.heading-4-sb,.body-1-sb,.body-2-sb,.body-3-sb,.body-4-sb,.body-5-sb,.interactive-1-sb,.interactive-2-sb,.interactive-3-sb,.helper-sb{font-weight:var(--font-sb)}`;const d=()=>`button.z-link{padding:0;border:0;margin:0;background-color:transparent}a.z-link,button.z-link{display:inline-flex;cursor:pointer;font-family:var(--font-family-sans);line-height:inherit;text-decoration:none}a.z-link.z-link-icon,button.z-link.z-link-icon{--z-icon-width:1.125em;--z-icon-height:1.125em;align-items:center;column-gap:0.5em}a.z-link.z-link-sb,button.z-link.z-link-sb{font-weight:var(--font-sb)}a.z-link.z-link-underline,button.z-link.z-link-underline{text-decoration:underline}a.z-link:hover,button.z-link:hover,a.z-link:focus-visible,button.z-link:focus-visible,a.z-link:active,button.z-link:active{text-decoration:underline}a.z-link:focus-visible,button.z-link:focus-visible{box-shadow:var(--shadow-focus-primary);outline:none}a.z-link.z-link-disabled,button.z-link.z-link-disabled{box-shadow:none;color:var(--color-disabled03);cursor:default;fill:var(--color-disabled03);outline:none;pointer-events:none;text-decoration:none}a.z-link,button.z-link,a.z-link.z-link-active,button.z-link.z-link-active,a.z-link:hover,button.z-link:hover,a.z-link.z-link-active:hover,button.z-link.z-link-active:hover,a.z-link:focus-visible,button.z-link:focus-visible,a.z-link.z-link-active:focus-visible,button.z-link.z-link-active:focus-visible,a.z-link:active,button.z-link:active,a.z-link.z-link-active:active,button.z-link.z-link-active:active,a.z-link:visited,button.z-link:visited,a.z-link.z-link-active:visited,button.z-link.z-link-active:visited{color:var(--color-text-link-default);fill:var(--color-text-link-default)}a.z-link.z-link-blue,button.z-link.z-link-blue,a.z-link.z-link-blue.z-link-active,button.z-link.z-link-blue.z-link-active{color:var(--color-text-link-blue);fill:var(--color-text-link-blue)}a.z-link.z-link-red,button.z-link.z-link-red,a.z-link.z-link-red.z-link-active,button.z-link.z-link-red.z-link-active{color:var(--color-text-link-red);fill:var(--color-text-link-red)}a.z-link.z-link-inverse,button.z-link.z-link-inverse,a.z-link.z-link-inverse.z-link-active,button.z-link.z-link-inverse.z-link-active{color:var(--color-text-link-inverse);fill:var(--color-text-link-inverse)}a.z-link.z-link-blue:hover,button.z-link.z-link-blue:hover{color:var(--color-text-link-blue-hover);fill:var(--color-text-link-blue-hover)}a.z-link.z-link-red:hover,button.z-link.z-link-red:hover{color:var(--color-text-link-red-hover);fill:var(--color-text-link-red-hover)}a.z-link.z-link-inverse:hover,button.z-link.z-link-inverse:hover{color:var(--color-text-link-inverse);fill:var(--color-text-link-inverse)}a.z-link.z-link-blue:active,button.z-link.z-link-blue:active,a.z-link.z-link-blue:focus-visible,button.z-link.z-link-blue:focus-visible{color:var(--color-text-link-blue-active);fill:var(--color-text-link-blue-active)}a.z-link.z-link-red:active,button.z-link.z-link-red:active,a.z-link.z-link-red:focus-visible,button.z-link.z-link-red:focus-visible{color:var(--color-text-link-red-active);fill:var(--color-text-link-red-active)}a.z-link.z-link-inverse:active,button.z-link.z-link-inverse:active,a.z-link.z-link-inverse:focus-visible,button.z-link.z-link-inverse:focus-visible{color:var(--color-text-link-inverse);fill:var(--color-text-link-inverse)}a.z-link.z-link-blue:visited,button.z-link.z-link-blue:visited{color:var(--color-text-link-blue-visited);fill:var(--color-text-link-blue-visited)}a.z-link.z-link-red:visited,button.z-link.z-link-red:visited{color:var(--color-text-link-red-visited);fill:var(--color-text-link-red-visited)}a.z-link.z-link-inverse:visited,button.z-link.z-link-inverse:visited{color:var(--color-text-link-inverse);fill:var(--color-text-link-inverse)}`;const b=class{constructor(i){t(this,i);this.ebookClick=e(this,"ebookClick",7);this.coverClick=e(this,"coverClick",7);this.titleClick=e(this,"titleClick",7);this.variant=a.PORTRAIT;this.isbnLabel="";this.linkTarget="_blank";this.hasMultipleCovers=false}emitEbookClick(){this.ebookClick.emit()}emitCoverClick(){this.coverClick.emit()}emitTitleClick(){this.titleClick.emit()}renderCover(){const t=this.ebookUrl?"a":"div";const e=this.ebookUrl?{href:this.ebookUrl,onClick:()=>this.emitCoverClick(),target:this.linkTarget}:{};return i(t,Object.assign({class:"cover"},e),i("z-book-cover",{cover:this.cover,fallbackCover:this.fallbackCover,multiple:this.hasMultipleCovers&&this.variant===a.PORTRAIT},i("slot",{name:"coverOverlay",slot:"coverOverlay"})))}renderYear(){if(!this.year){return null}return i("div",{class:"year ellipsis body-4","aria-description":"anno"},this.year)}renderAuthors(){if(!this.authors){return null}return i("div",{class:"cta-wrapper"},i("div",{class:"authors ellipsis body-4","aria-description":"autori"},this.authors),this.variant===a.LANDSCAPE?this.renderCtaSlot():null)}renderOperaTitle(){const t=this.titleHtmlTag?`<${this.titleHtmlTag}>${this.operaTitle}</${this.titleHtmlTag}>`:this.operaTitle;const e=i("div",{class:"opera-title ellipsis body-2-sb",innerHTML:t});return i("div",{class:"cta-wrapper"},this.ebookUrl?i("a",{class:"z-link",href:this.ebookUrl,onClick:()=>this.emitTitleClick(),target:this.linkTarget},e):e,this.variant===a.PORTRAIT?this.renderCtaSlot():null)}renderVolumeTitle(){if(!this.volumeTitle){return null}return i("div",{class:"volume-title ellipsis body-4"},this.volumeTitle)}renderIsbn(){if(!this.isbn){return null}return i("div",{class:"isbn ellipsis body-4-sb","aria-description":`isbn ${this.isbnLabel}`},this.isbn," ",this.isbnLabel?i("span",{class:"body-4"},this.isbnLabel):null)}renderEbook(){return i("div",{class:"ebook"},i("div",{class:"app-name"},i("img",{class:"ebook-logo","aria-hidden":"true"}),i("div",{class:"body-4-sb"},"laZ Ebook")),i("z-button",{size:l.X_SMALL,href:this.ebookUrl,target:this.linkTarget,onClick:()=>this.emitEbookClick(),htmlRole:"link","aria-description":`leggi l'ebook ${this.operaTitle} su laZ Ebook`},"leggi ebook"))}renderCtaSlot(){return i("slot",{name:"cta"})}render(){return i(n,{key:"51452a17d92d9cf92a12134fff963165748519e3"},i("div",{key:"f5ac7d525b4b25fda20b1772d5508d8e2e528cfd",class:"main-content"},this.renderCover(),i("div",{key:"ea9ef02b1f7acc53a442d5aa03e320a92fe4b57d",class:"card-info"},i("div",{key:"194da8efc4f1f3e9e3a1549a86be1474f68873da",class:"top"},i("div",{key:"522ae3f38eba5d95f1e8fc1239ec59fe7df32935"},this.renderYear(),this.renderAuthors(),this.renderOperaTitle(),this.renderVolumeTitle(),this.renderIsbn()),i("slot",{key:"62869a3e3965c0f7611cc93e16c8c660b369ca17",name:"tags"}),i("slot",{key:"15c733e6644af2de263b0184f4c395ce967d773b",name:"data"})),i("slot",{key:"eab8052dc791068b689e5d3cb95c0031fac19a9e",name:"ebook"},!!this.ebookUrl&&i("div",{key:"688bf22e1da5a8cd330aaccdb8d4fb7974f368bb",class:"bottom"},this.renderEbook())))),i("slot",{key:"50d18fb8b88035ecb1d896eb199e7907c08872f1",name:"apps"}))}get hostElement(){return o(this)}};b.style=r()+(s()+d());export{b as z_book_card};
2
- //# sourceMappingURL=p-53c51bf4.entry.js.map
1
+ import{r as t,c as e,h as i,H as n,d as o}from"./p-BcDWN4F1.js";import{_ as a,e as l}from"./p-DdetsoIY.js";const r=()=>`:host{--z-book-card-portrait-cover-height:378px;--z-book-card-title-lines:2;--z-book-card-title-word-break:initial;--z-book-card-subtitle-lines:1;--z-book-card-subtitle-word-break:break-all;--z-book-card-authors-lines:1;--z-book-card-authors-word-break:break-all;display:flex;width:304px;box-sizing:border-box;flex-direction:column;border:solid var(--border-size-medium) var(--color-surface03);background-color:var(--color-surface01);border-radius:var(--border-radius);color:var(--color-default-text);font-family:var(--font-family-sans)}:host,*{box-sizing:border-box}.main-content{display:flex;height:100%;flex-direction:column;padding:var(--space-unit);gap:var(--space-unit)}.main-content .cover{position:relative;display:flex;overflow:hidden;align-items:flex-end;justify-content:center;border-radius:var(--border-radius)}.main-content .cover z-book-cover{--z-book-cover-height:var(--z-book-card-portrait-cover-height)}.main-content a.cover:focus-visible{box-shadow:var(--shadow-focus-primary);outline:none}.main-content .card-info{display:flex;flex:1;flex-direction:column;justify-content:space-between;gap:var(--space-unit)}.main-content .card-info .top{display:flex;flex-direction:column;gap:calc(var(--space-unit) * 2)}.main-content .card-info .top ::slotted([slot="tags"]){display:flex;flex-wrap:wrap;gap:var(--space-unit)}.main-content .card-info .top ::slotted([slot="data"]){display:flex;justify-content:space-between}.main-content .card-info .top .ellipsis{display:-webkit-box;overflow:hidden;height:1.4rem;-webkit-box-orient:vertical;-webkit-line-clamp:1;line-clamp:1;line-height:1.4rem;text-overflow:ellipsis;word-break:break-all}.main-content .card-info .top .ellipsis.opera-title{height:auto;max-height:calc(1.5rem * var(--z-book-card-title-lines));-webkit-line-clamp:var(--z-book-card-title-lines);line-clamp:var(--z-book-card-title-lines);line-height:1.5rem;word-break:var(--z-book-card-title-word-break)}.main-content .card-info .top .ellipsis.volume-title{height:auto;max-height:calc(1.4rem * var(--z-book-card-subtitle-lines));-webkit-line-clamp:var(--z-book-card-subtitle-lines);line-clamp:var(--z-book-card-subtitle-lines);line-height:1.4rem;word-break:var(--z-book-card-subtitle-word-break)}.main-content .card-info .top .ellipsis.authors{height:auto;max-height:calc(1.4rem * var(--z-book-card-authors-lines));-webkit-line-clamp:var(--z-book-card-authors-lines);line-clamp:var(--z-book-card-authors-lines);line-height:1.4rem;word-break:var(--z-book-card-authors-word-break)}.main-content .card-info .top .opera-title *{all:unset}.main-content .cta-wrapper{display:flex;justify-content:space-between;gap:calc(var(--space-unit) / 2)}.main-content .card-info .top .link-chip-wrapper{display:flex;justify-content:space-between}.main-content .card-info .bottom .ebook{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;padding:var(--space-unit);background-color:var(--color-primary02);border-radius:var(--border-radius);gap:var(--space-unit)}.main-content .card-info .bottom .ebook .app-name{display:flex;align-items:center;padding:calc(var(--space-unit) / 2) 0;font-family:var(--font-family-serif);gap:calc(var(--space-unit) / 2)}.main-content .card-info .bottom .ebook .app-name .ebook-logo{width:1.5rem;height:1.5rem;content:url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 20 20%22 fill=%22none%22 aria-hidden=%22true%22%3E%3Cg clip-path=%22url(%23clip0_11996_224)%22%3E%3Cpath d=%22M14.6644 0.469604H5.00141C2.33305 0.469604 0.169922 2.63274 0.169922 5.3011V14.9641C0.169922 17.6324 2.33305 19.7956 5.00141 19.7956H14.6644C17.3328 19.7956 19.4959 17.6324 19.4959 14.9641V5.3011C19.4959 2.63274 17.3328 0.469604 14.6644 0.469604Z%22 fill=%22%23E2011A%22/%3E%3Cpath d=%22M15.9523 13.3536H12.7313C11.6861 13.3536 10.6683 13.6934 9.83241 14.3199C8.99657 13.6934 7.97873 13.3536 6.93352 13.3536H3.71252V5.30115H6.93352C7.97873 5.30115 8.99657 5.64096 9.83241 6.26745C10.6683 5.64096 11.6861 5.30115 12.7313 5.30115H15.9523V13.3536Z%22 fill=%22white%22/%3E%3Cpath d=%22M15.9523 14.3201H3.71252V14.9643H15.9523V14.3201Z%22 fill=%22black%22/%3E%3Cpath d=%22M8.22229 10.732V8.24543C8.22229 7.97165 8.51057 7.79449 8.75375 7.91689L11.2404 9.16019C11.5109 9.29548 11.5109 9.682 11.2404 9.81728L8.75375 11.0606C8.50896 11.183 8.22229 11.0058 8.22229 10.732Z%22 fill=%22black%22/%3E%3Cpath d=%22M4.35704 7.87826C5.42438 7.87826 6.28963 7.013 6.28963 5.94566C6.28963 4.87831 5.42438 4.01306 4.35704 4.01306C3.28969 4.01306 2.42444 4.87831 2.42444 5.94566C2.42444 7.013 3.28969 7.87826 4.35704 7.87826Z%22 fill=%22black%22/%3E%3Cpath d=%22M5.6454 5.62354H3.0686V6.26773H5.6454V5.62354Z%22 fill=%22white%22/%3E%3Cpath d=%22M4.67917 4.65723H4.03497V7.23402H4.67917V4.65723Z%22 fill=%22white%22/%3E%3C/g%3E%3Cdefs%3E%3CclipPath id=%22clip0_11996_224%22%3E%3Crect width=%2219.326%22 height=%2219.326%22 fill=%22white%22 transform=%22translate(0.169922 0.469604)%22/%3E%3C/clipPath%3E%3C/defs%3E%3C/svg%3E")}:host([variant="landscape"]){width:635px;min-height:max(332px, 20.75rem);padding:0}:host([variant="landscape"]) .main-content{min-height:max(332px, 20.75rem);flex-direction:row;padding:calc(var(--space-unit) * 2);gap:calc(var(--space-unit) * 2)}:host([variant="landscape"]) .main-content .cover z-book-cover{--z-book-cover-height:300px}:host([variant="landscape"]) .main-content .card-info,:host([variant="landscape"]) .main-content .card-info .top{gap:calc(var(--space-unit) / 2)}@media (max-width: 767px){:host([variant="portrait"]){width:100%;max-width:400px}}`;const s=()=>`:root{--font-family-sans:"IBM Plex Sans", sans-serif;--font-family-serif:"IBM Plex Serif", serif;--font-lt:300;--font-rg:400;--font-sb:600;--font-bd:700;--font-size-1:0.75rem;--font-size-2:0.875rem;--font-size-3:1rem;--font-size-4:1.125rem;--font-size-5:1.25rem;--font-size-6:1.5rem;--font-size-7:1.75rem;--font-size-8:2rem;--font-size-9:2.25rem;--font-size-10:2.625rem;--font-size-11:3rem;--font-size-12:3.375rem;--font-size-13:3.75rem;--font-size-14:4.25rem;--font-size-15:4.75rem;--font-size-16:5.25rem;--font-size-17:5.75rem;--section-title-1:var(--font-sb) var(--font-size-11) / 1.083 var(--font-family-serif);--section-title-2:var(--font-sb) var(--font-size-10) / 1.142 var(--font-family-serif);--section-title-3:var(--font-sb) var(--font-size-9) / 1.222 var(--font-family-serif);--section-title-4:var(--font-sb) var(--font-size-8) / 1.25 var(--font-family-serif);--section-title-5:var(--font-sb) var(--font-size-7) / 1.2857 var(--font-family-serif);--section-title-6:var(--font-sb) var(--font-size-6) / 1.333 var(--font-family-serif)}.heading-1,.heading-1-sb,.heading-1-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.heading-2,.heading-2-sb,.heading-2-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.heading-3,.heading-3-sb,.heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.heading-4,.heading-4-sb,.heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.body-1,.body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.body-2,.body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.body-3,.body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.body-4,.body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.body-5,.body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.interactive-1,.interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.interactive-2,.interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.interactive-3,.interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.helper,.helper-sb{font-size:var(--font-size-1);font-style:italic;font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.section-title-1{font:var(--section-title-1)}.section-title-2{font:var(--section-title-2)}.section-title-3{font:var(--section-title-3)}.section-title-4{font:var(--section-title-4)}.section-title-5{font:var(--section-title-5)}.section-title-6{font:var(--section-title-6)}@media (min-width: 1152px){.heading-1,.heading-1-sb,.heading-1-lt{font-size:var(--font-size-8);font-weight:var(--font-rg);line-height:1.25}.heading-2,.heading-2-sb,.heading-2-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}}@media (max-width: 767px){.mobile-heading-1,.mobile-heading-1-sb,.mobile-heading-1-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.mobile-heading-2,.mobile-heading-2-sb,.mobile-heading-2-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.mobile-heading-3,.mobile-heading-3-sb,.mobile-heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.mobile-heading-4,.mobile-heading-4-sb,.mobile-heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.mobile-body-1,.mobile-body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.mobile-body-2,.mobile-body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.mobile-body-3,.mobile-body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.mobile-body-4,.mobile-body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.mobile-body-5,.mobile-body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.mobile-interactive-1,.mobile-interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.mobile-interactive-2,.mobile-interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.mobile-interactive-3,.mobile-interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.mobile-section-title-1{font:var(--section-title-1)}.mobile-section-title-2{font:var(--section-title-2)}.mobile-section-title-3{font:var(--section-title-3)}.mobile-section-title-4{font:var(--section-title-4)}.mobile-section-title-5{font:var(--section-title-5)}.mobile-section-title-6{font:var(--section-title-6)}.mobile-heading-1-lt,.mobile-heading-2-lt,.mobile-heading-3-lt,.mobile-heading-4-lt{font-weight:var(--font-lt)}.mobile-heading-1-sb,.mobile-heading-2-sb,.mobile-heading-3-sb,.mobile-heading-4-sb,.mobile-body-1-sb,.mobile-body-2-sb,.mobile-body-3-sb,.mobile-body-4-sb,.mobile-body-5-sb,.mobile-interactive-1-sb,.mobile-interactive-2-sb,.mobile-interactive-3-sb{font-weight:var(--font-sb)}}@media (min-width: 768px) and (max-width: 1151px){.tablet-heading-1,.tablet-heading-1-sb,.tablet-heading-1-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.tablet-heading-2,.tablet-heading-2-sb,.tablet-heading-2-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.tablet-heading-3,.tablet-heading-3-sb,.tablet-heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.tablet-heading-4,.tablet-heading-4-sb,.tablet-heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.tablet-body-1,.tablet-body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.tablet-body-2,.tablet-body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.tablet-body-3,.tablet-body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.tablet-body-4,.tablet-body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.tablet-body-5,.tablet-body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.tablet-interactive-1,.tablet-interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.tablet-interactive-2,.tablet-interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.tablet-interactive-3,.tablet-interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.tablet-section-title-1{font:var(--section-title-1)}.tablet-section-title-2{font:var(--section-title-2)}.tablet-section-title-3{font:var(--section-title-3)}.tablet-section-title-4{font:var(--section-title-4)}.tablet-section-title-5{font:var(--section-title-5)}.tablet-section-title-6{font:var(--section-title-6)}.tablet-heading-1-lt,.tablet-heading-2-lt,.tablet-heading-3-lt,.tablet-heading-4-lt{font-weight:var(--font-lt)}.tablet-heading-1-sb,.tablet-heading-2-sb,.tablet-heading-3-sb,.tablet-heading-4-sb,.tablet-body-1-sb,.tablet-body-2-sb,.tablet-body-3-sb,.tablet-body-4-sb,.tablet-body-5-sb,.tablet-interactive-1-sb,.tablet-interactive-2-sb,.tablet-interactive-3-sb{font-weight:var(--font-sb)}}@media (min-width: 1152px) and (max-width: 1365px){.desktop-heading-1,.desktop-heading-1-sb,.desktop-heading-1-lt{font-size:var(--font-size-8);font-weight:var(--font-rg);line-height:1.25}.desktop-heading-2,.desktop-heading-2-sb,.desktop-heading-2-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.desktop-heading-3,.desktop-heading-3-sb,.desktop-heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.desktop-heading-4,.desktop-heading-4-sb,.desktop-heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.desktop-body-1,.desktop-body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.desktop-body-2,.desktop-body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.desktop-body-3,.desktop-body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.desktop-body-4,.desktop-body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.desktop-body-5,.desktop-body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.desktop-interactive-1,.desktop-interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.desktop-interactive-2,.desktop-interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.desktop-interactive-3,.desktop-interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.desktop-section-title-1{font:var(--section-title-1)}.desktop-section-title-2{font:var(--section-title-2)}.desktop-section-title-3{font:var(--section-title-3)}.desktop-section-title-4{font:var(--section-title-4)}.desktop-section-title-5{font:var(--section-title-5)}.desktop-section-title-6{font:var(--section-title-6)}.desktop-heading-1-lt,.desktop-heading-2-lt,.desktop-heading-3-lt,.desktop-heading-4-lt{font-weight:var(--font-lt)}.desktop-heading-1-sb,.desktop-heading-2-sb,.desktop-heading-3-sb,.desktop-heading-4-sb,.desktop-body-1-sb,.desktop-body-2-sb,.desktop-body-3-sb,.desktop-body-4-sb,.desktop-body-5-sb,.desktop-interactive-1-sb,.desktop-interactive-2-sb,.desktop-interactive-3-sb{font-weight:var(--font-sb)}}@media (min-width: 1366px){.wide-heading-1,.wide-heading-1-sb,.wide-heading-1-lt{font-size:var(--font-size-8);font-weight:var(--font-rg);line-height:1.25}.wide-heading-2,.wide-heading-2-sb,.wide-heading-2-lt{font-size:var(--font-size-7);font-weight:var(--font-rg);line-height:1.28}.wide-heading-3,.wide-heading-3-sb,.wide-heading-3-lt{font-size:var(--font-size-6);font-weight:var(--font-rg);line-height:1.333}.wide-heading-4,.wide-heading-4-sb,.wide-heading-4-lt{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.wide-body-1,.wide-body-1-sb{font-size:var(--font-size-5);font-weight:var(--font-rg);line-height:1.4}.wide-body-2,.wide-body-2-sb{font-size:var(--font-size-4);font-weight:var(--font-rg);line-height:1.5}.wide-body-3,.wide-body-3-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.wide-body-4,.wide-body-4-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.wide-body-5,.wide-body-5-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.wide-interactive-1,.wide-interactive-1-sb{font-size:var(--font-size-3);font-weight:var(--font-rg);line-height:1.5}.wide-interactive-2,.wide-interactive-2-sb{font-size:var(--font-size-2);font-weight:var(--font-rg);letter-spacing:0.16px;line-height:1.4}.wide-interactive-3,.wide-interactive-3-sb{font-size:var(--font-size-1);font-weight:var(--font-rg);letter-spacing:0.32px;line-height:1.333}.wide-section-title-1{font:var(--section-title-1)}.wide-section-title-2{font:var(--section-title-2)}.wide-section-title-3{font:var(--section-title-3)}.wide-section-title-4{font:var(--section-title-4)}.wide-section-title-5{font:var(--section-title-5)}.wide-section-title-6{font:var(--section-title-6)}.wide-heading-1-lt,.wide-heading-2-lt,.wide-heading-3-lt,.wide-heading-4-lt{font-weight:var(--font-lt)}.wide-heading-1-sb,.wide-heading-2-sb,.wide-heading-3-sb,.wide-heading-4-sb,.wide-body-1-sb,.wide-body-2-sb,.wide-body-3-sb,.wide-body-4-sb,.wide-body-5-sb,.wide-interactive-1-sb,.wide-interactive-2-sb,.wide-interactive-3-sb{font-weight:var(--font-sb)}}.heading-1-lt,.heading-2-lt,.heading-3-lt,.heading-4-lt{font-weight:var(--font-lt)}.heading-1-sb,.heading-2-sb,.heading-3-sb,.heading-4-sb,.body-1-sb,.body-2-sb,.body-3-sb,.body-4-sb,.body-5-sb,.interactive-1-sb,.interactive-2-sb,.interactive-3-sb,.helper-sb{font-weight:var(--font-sb)}`;const d=()=>`button.z-link{padding:0;border:0;margin:0;background-color:transparent}a.z-link,button.z-link{display:inline-flex;cursor:pointer;font-family:var(--font-family-sans);line-height:inherit;text-decoration:none}a.z-link.z-link-icon,button.z-link.z-link-icon{--z-icon-width:1.125em;--z-icon-height:1.125em;align-items:center;column-gap:0.5em}a.z-link.z-link-sb,button.z-link.z-link-sb{font-weight:var(--font-sb)}a.z-link.z-link-underline,button.z-link.z-link-underline{text-decoration:underline}a.z-link:hover,button.z-link:hover,a.z-link:focus-visible,button.z-link:focus-visible,a.z-link:active,button.z-link:active{text-decoration:underline}a.z-link:focus-visible,button.z-link:focus-visible{box-shadow:var(--shadow-focus-primary);outline:none}a.z-link.z-link-disabled,button.z-link.z-link-disabled{box-shadow:none;color:var(--color-disabled03);cursor:default;fill:var(--color-disabled03);outline:none;pointer-events:none;text-decoration:none}a.z-link,button.z-link,a.z-link.z-link-active,button.z-link.z-link-active,a.z-link:hover,button.z-link:hover,a.z-link.z-link-active:hover,button.z-link.z-link-active:hover,a.z-link:focus-visible,button.z-link:focus-visible,a.z-link.z-link-active:focus-visible,button.z-link.z-link-active:focus-visible,a.z-link:active,button.z-link:active,a.z-link.z-link-active:active,button.z-link.z-link-active:active,a.z-link:visited,button.z-link:visited,a.z-link.z-link-active:visited,button.z-link.z-link-active:visited{color:var(--color-text-link-default);fill:var(--color-text-link-default)}a.z-link.z-link-blue,button.z-link.z-link-blue,a.z-link.z-link-blue.z-link-active,button.z-link.z-link-blue.z-link-active{color:var(--color-text-link-blue);fill:var(--color-text-link-blue)}a.z-link.z-link-red,button.z-link.z-link-red,a.z-link.z-link-red.z-link-active,button.z-link.z-link-red.z-link-active{color:var(--color-text-link-red);fill:var(--color-text-link-red)}a.z-link.z-link-inverse,button.z-link.z-link-inverse,a.z-link.z-link-inverse.z-link-active,button.z-link.z-link-inverse.z-link-active{color:var(--color-text-link-inverse);fill:var(--color-text-link-inverse)}a.z-link.z-link-blue:hover,button.z-link.z-link-blue:hover{color:var(--color-text-link-blue-hover);fill:var(--color-text-link-blue-hover)}a.z-link.z-link-red:hover,button.z-link.z-link-red:hover{color:var(--color-text-link-red-hover);fill:var(--color-text-link-red-hover)}a.z-link.z-link-inverse:hover,button.z-link.z-link-inverse:hover{color:var(--color-text-link-inverse);fill:var(--color-text-link-inverse)}a.z-link.z-link-blue:active,button.z-link.z-link-blue:active,a.z-link.z-link-blue:focus-visible,button.z-link.z-link-blue:focus-visible{color:var(--color-text-link-blue-active);fill:var(--color-text-link-blue-active)}a.z-link.z-link-red:active,button.z-link.z-link-red:active,a.z-link.z-link-red:focus-visible,button.z-link.z-link-red:focus-visible{color:var(--color-text-link-red-active);fill:var(--color-text-link-red-active)}a.z-link.z-link-inverse:active,button.z-link.z-link-inverse:active,a.z-link.z-link-inverse:focus-visible,button.z-link.z-link-inverse:focus-visible{color:var(--color-text-link-inverse);fill:var(--color-text-link-inverse)}a.z-link.z-link-blue:visited,button.z-link.z-link-blue:visited{color:var(--color-text-link-blue-visited);fill:var(--color-text-link-blue-visited)}a.z-link.z-link-red:visited,button.z-link.z-link-red:visited{color:var(--color-text-link-red-visited);fill:var(--color-text-link-red-visited)}a.z-link.z-link-inverse:visited,button.z-link.z-link-inverse:visited{color:var(--color-text-link-inverse);fill:var(--color-text-link-inverse)}`;const b=class{constructor(i){t(this,i);this.ebookClick=e(this,"ebookClick",7);this.coverClick=e(this,"coverClick",7);this.titleClick=e(this,"titleClick",7);this.variant=a.PORTRAIT;this.isbnLabel="";this.linkTarget="_blank";this.hasMultipleCovers=false}emitEbookClick(){this.ebookClick.emit()}emitCoverClick(){this.coverClick.emit()}emitTitleClick(){this.titleClick.emit()}renderCover(){const t=this.ebookUrl?"a":"div";const e=this.ebookUrl?{href:this.ebookUrl,onClick:()=>this.emitCoverClick(),target:this.linkTarget}:{};return i(t,Object.assign({class:"cover"},e),i("z-book-cover",{cover:this.cover,fallbackCover:this.fallbackCover,multiple:this.hasMultipleCovers&&this.variant===a.PORTRAIT},i("slot",{name:"coverOverlay",slot:"coverOverlay"})))}renderYear(){if(!this.year){return null}return i("div",{class:"year ellipsis body-4","aria-description":"anno"},this.year)}renderAuthors(){if(!this.authors){return null}return i("div",{class:"cta-wrapper"},i("div",{class:"authors ellipsis body-4","aria-description":"autori"},this.authors),this.variant===a.LANDSCAPE?this.renderCtaSlot():null)}renderOperaTitle(){const t=this.titleHtmlTag?`<${this.titleHtmlTag}>${this.operaTitle}</${this.titleHtmlTag}>`:this.operaTitle;const e=i("div",{class:"opera-title ellipsis body-2-sb",innerHTML:t});return i("div",{class:"cta-wrapper"},this.ebookUrl?i("a",{class:"z-link",href:this.ebookUrl,onClick:()=>this.emitTitleClick(),target:this.linkTarget},e):e,this.variant===a.PORTRAIT?this.renderCtaSlot():null)}renderVolumeTitle(){if(!this.volumeTitle){return null}return i("div",{class:"volume-title ellipsis body-4"},this.volumeTitle)}renderIsbn(){if(!this.isbn){return null}return i("div",{class:"isbn ellipsis body-4-sb","aria-description":`isbn ${this.isbnLabel}`},this.isbn," ",this.isbnLabel?i("span",{class:"body-4"},this.isbnLabel):null)}renderEbook(){return i("div",{class:"ebook"},i("div",{class:"app-name"},i("img",{class:"ebook-logo","aria-hidden":"true"}),i("div",{class:"body-4-sb"},"laZ Ebook")),i("z-button",{size:l.X_SMALL,href:this.ebookUrl,target:this.linkTarget,onClick:()=>this.emitEbookClick(),htmlRole:"link","aria-description":`leggi l'ebook ${this.operaTitle} su laZ Ebook`},"leggi ebook"))}renderCtaSlot(){return i("slot",{name:"cta"})}render(){return i(n,{key:"8740c7a7f7611c13c0b87ef9354418d4a7a2a9db"},i("div",{key:"8c87599e1edda794143dd81223529001f3c2044a",class:"main-content"},this.renderCover(),i("div",{key:"510c2d7625eeef37b8ad7f540db7fa5782d7fa6d",class:"card-info"},i("div",{key:"50fb759793762547eb0c82247ff9a3fc9029d6e1",class:"top"},i("div",{key:"d9e0372e46d5d2cc26b5823e2335764336376566"},this.renderYear(),this.renderAuthors(),this.renderOperaTitle(),this.renderVolumeTitle(),this.renderIsbn()),i("slot",{key:"900a1778db6c06d5bc23a37400416b61a61a27e2",name:"tags"}),i("slot",{key:"9e53b87038cd44171613ab6c54a68d88aada3e74",name:"data"})),i("slot",{key:"53dd0d14ad5f3ad8b66d48d187d6e0898ed7a490",name:"ebook"},!!this.ebookUrl&&i("div",{key:"3edf0a447799584a766e159b019f8b5f48e1170a",class:"bottom"},this.renderEbook())))),i("slot",{key:"b1a58f989315ba1346f20686fb1077ad0ba1ae44",name:"apps"}))}get hostElement(){return o(this)}};b.style=r()+(s()+d());export{b as z_book_card};
2
+ //# sourceMappingURL=p-6b816b15.entry.js.map