@covalent/components 6.0.3 → 6.0.5

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 (304) hide show
  1. package/action-ribbon/action-ribbon-base.d.ts.map +1 -0
  2. package/{src/action-ribbon → action-ribbon}/action-ribbon.d.ts +1 -0
  3. package/action-ribbon/action-ribbon.d.ts.map +1 -0
  4. package/action-ribbon.js +18 -0
  5. package/action-ribbon.mjs +13 -11
  6. package/alert/alert-base.d.ts.map +1 -0
  7. package/{src/alert → alert}/alert.d.ts +1 -0
  8. package/alert/alert.d.ts.map +1 -0
  9. package/alert.js +21 -0
  10. package/alert.mjs +14 -12
  11. package/{src/app-shell → app-shell}/app-shell.d.ts +1 -0
  12. package/app-shell/app-shell.d.ts.map +1 -0
  13. package/app-shell.js +41 -0
  14. package/app-shell.mjs +19 -17
  15. package/aria-property.mjs +2 -38
  16. package/base-element.mjs +2 -25
  17. package/{src/button → button}/button.d.ts +3 -2
  18. package/button/button.d.ts.map +1 -0
  19. package/button.js +44 -0
  20. package/button.mjs +11 -9
  21. package/card/card-base.d.ts.map +1 -0
  22. package/{src/card → card}/card.d.ts +3 -2
  23. package/card/card.d.ts.map +1 -0
  24. package/card.js +19 -0
  25. package/card.mjs +3 -1
  26. package/check-list-item.js +27 -0
  27. package/check-list-item.mjs +17 -15
  28. package/{src/checkbox → checkbox}/checkbox.d.ts +3 -2
  29. package/checkbox/checkbox.d.ts.map +1 -0
  30. package/checkbox.js +2 -0
  31. package/checkbox.mjs +15 -13
  32. package/chips/chip-base.d.ts.map +1 -0
  33. package/chips/chip-set-base.d.ts.map +1 -0
  34. package/{src/chips → chips}/chip-set.d.ts +1 -0
  35. package/chips/chip-set.d.ts.map +1 -0
  36. package/{src/chips → chips}/chip.d.ts +1 -0
  37. package/chips/chip.d.ts.map +1 -0
  38. package/chips/foundation.d.ts.map +1 -0
  39. package/circular-progress/circular-progress.d.ts +11 -0
  40. package/circular-progress/circular-progress.d.ts.map +1 -0
  41. package/circular-progress.js +65 -0
  42. package/circular-progress.mjs +11 -9
  43. package/class-map.mjs +3 -56
  44. package/{src/code-snippet → code-snippet}/code-snippet.d.ts +3 -2
  45. package/code-snippet/code-snippet.d.ts.map +1 -0
  46. package/code-snippet.js +13 -0
  47. package/code-snippet.mjs +36 -34
  48. package/{src/dialog → dialog}/dialog.d.ts +3 -2
  49. package/dialog/dialog.d.ts.map +1 -0
  50. package/dialog.js +1 -0
  51. package/dialog.mjs +15 -608
  52. package/dialog2.mjs +750 -0
  53. package/directive-helpers.mjs +2 -8
  54. package/{src/drawer → drawer}/drawer.d.ts +3 -2
  55. package/drawer/drawer.d.ts.map +1 -0
  56. package/drawer.js +6 -0
  57. package/drawer.mjs +11 -9
  58. package/{src/empty-state → empty-state}/empty-state.d.ts +3 -2
  59. package/empty-state/empty-state.d.ts.map +1 -0
  60. package/empty-state.js +27 -0
  61. package/empty-state.mjs +17 -15
  62. package/event-options.mjs +2 -11
  63. package/form-element.mjs +2 -47
  64. package/{src/formfield → formfield}/formfield.d.ts +3 -2
  65. package/formfield/formfield.d.ts.map +1 -0
  66. package/foundation.mjs +3 -112
  67. package/foundation2.mjs +2 -40
  68. package/{src/icon → icon}/icon.d.ts +1 -0
  69. package/icon/icon.d.ts.map +1 -0
  70. package/{src/icon-button → icon-button}/icon-button.d.ts +3 -2
  71. package/icon-button/icon-button.d.ts.map +1 -0
  72. package/icon-button.js +32 -0
  73. package/icon-button.mjs +23 -21
  74. package/icon-check-toggle.js +15 -0
  75. package/icon-check-toggle.mjs +5 -5
  76. package/{src/icon-checkbox → icon-checkbox}/icon-check-toggle.d.ts +3 -2
  77. package/icon-checkbox/icon-check-toggle.d.ts.map +1 -0
  78. package/{src/icon-radio → icon-radio}/icon-radio-toggle.d.ts +3 -2
  79. package/icon-radio/icon-radio-toggle.d.ts.map +1 -0
  80. package/icon-radio-toggle.js +14 -0
  81. package/icon-radio-toggle.mjs +19 -19
  82. package/icon.js +5 -0
  83. package/icon.mjs +11 -9
  84. package/if-defined.mjs +2 -7
  85. package/index.d.ts +46 -0
  86. package/index.d.ts.map +1 -0
  87. package/index.js +1 -0
  88. package/index.mjs +126 -0
  89. package/inert.esm.mjs +3 -615
  90. package/linear-progress/linear-progress.d.ts +11 -0
  91. package/linear-progress/linear-progress.d.ts.map +1 -0
  92. package/linear-progress.js +36 -0
  93. package/linear-progress.mjs +21 -19
  94. package/list/check-list-item.d.ts +11 -0
  95. package/list/check-list-item.d.ts.map +1 -0
  96. package/{src/list → list}/list-expansion.d.ts +5 -4
  97. package/list/list-expansion.d.ts.map +1 -0
  98. package/{src/list → list}/list-item.d.ts +3 -2
  99. package/list/list-item.d.ts.map +1 -0
  100. package/{src/list → list}/list.d.ts +3 -2
  101. package/list/list.d.ts.map +1 -0
  102. package/{src/list → list}/nav-list-item.d.ts +3 -2
  103. package/list/nav-list-item.d.ts.map +1 -0
  104. package/list/radio-list-item.d.ts +11 -0
  105. package/list/radio-list-item.d.ts.map +1 -0
  106. package/list-expansion.js +9 -0
  107. package/list-expansion.mjs +20 -18
  108. package/list-item.js +1 -0
  109. package/list-item.mjs +8 -48
  110. package/list-item2.mjs +43 -0
  111. package/list.js +1 -0
  112. package/list.mjs +2 -27
  113. package/list2.mjs +25 -0
  114. package/{src/menu → menu}/menu.d.ts +3 -2
  115. package/menu/menu.d.ts.map +1 -0
  116. package/menu.js +5 -0
  117. package/menu.mjs +11 -9
  118. package/mwc-checkbox-base.mjs +11 -168
  119. package/mwc-checkbox.css.mjs +2 -7
  120. package/mwc-drawer-base.mjs +12 -242
  121. package/mwc-icon.mjs +3 -20
  122. package/mwc-line-ripple-directive.mjs +16 -452
  123. package/mwc-list-base.mjs +26 -755
  124. package/mwc-list-item-base.mjs +9 -183
  125. package/mwc-list-item.css.mjs +3 -11
  126. package/mwc-menu-base.mjs +21 -976
  127. package/mwc-radio-base.mjs +11 -438
  128. package/mwc-radio.css.mjs +2 -7
  129. package/mwc-slider.css.mjs +23 -794
  130. package/mwc-tab-base.mjs +25 -503
  131. package/mwc-top-app-bar-base.mjs +12 -282
  132. package/nav-list-item.js +10 -0
  133. package/nav-list-item.mjs +26 -24
  134. package/observer.mjs +2 -29
  135. package/package.json +226 -5
  136. package/property.mjs +2 -17
  137. package/query-assigned-elements.mjs +9 -591
  138. package/query-assigned-nodes.mjs +2 -14
  139. package/query.mjs +2 -22
  140. package/{src/radio → radio}/radio.d.ts +3 -2
  141. package/radio/radio.d.ts.map +1 -0
  142. package/radio-list-item.js +27 -0
  143. package/radio-list-item.mjs +17 -15
  144. package/radio.js +2 -0
  145. package/radio.mjs +12 -10
  146. package/ripple-handlers.mjs +12 -666
  147. package/{src/select → select}/select.d.ts +3 -2
  148. package/select/select.d.ts.map +1 -0
  149. package/select.js +272 -0
  150. package/select.mjs +124 -122
  151. package/{src/side-sheet → side-sheet}/side-sheet.d.ts +2 -2
  152. package/side-sheet/side-sheet.d.ts.map +1 -0
  153. package/side-sheet.js +4 -0
  154. package/side-sheet.mjs +3 -3
  155. package/slider/slider-range.d.ts +11 -0
  156. package/slider/slider-range.d.ts.map +1 -0
  157. package/{src/slider → slider}/slider.d.ts +3 -2
  158. package/slider/slider.d.ts.map +1 -0
  159. package/slider-range.js +64 -0
  160. package/slider-range.mjs +23 -21
  161. package/slider.js +14 -0
  162. package/slider.mjs +16 -14
  163. package/{src/snackbar → snackbar}/snackbar.d.ts +3 -2
  164. package/snackbar/snackbar.d.ts.map +1 -0
  165. package/snackbar.js +93 -0
  166. package/snackbar.mjs +12 -10
  167. package/state.mjs +2 -9
  168. package/status-header/status-header-base.d.ts.map +1 -0
  169. package/{src/status-header → status-header}/status-header-item.d.ts +1 -0
  170. package/status-header/status-header-item.d.ts.map +1 -0
  171. package/{src/status-header → status-header}/status-header.d.ts +1 -0
  172. package/status-header/status-header.d.ts.map +1 -0
  173. package/status-header-item.js +4 -0
  174. package/status-header-item.mjs +17 -15
  175. package/status-header.js +24 -0
  176. package/status-header.mjs +17 -15
  177. package/style-map.mjs +2 -37
  178. package/style.css +1 -0
  179. package/{src/switch → switch}/switch.d.ts +3 -2
  180. package/switch/switch.d.ts.map +1 -0
  181. package/switch.js +174 -0
  182. package/switch.mjs +10 -8
  183. package/{src/tab → tab}/tab-bar.d.ts +3 -2
  184. package/tab/tab-bar.d.ts.map +1 -0
  185. package/{src/tab → tab}/tab.d.ts +3 -2
  186. package/tab/tab.d.ts.map +1 -0
  187. package/tab-bar.js +278 -0
  188. package/tab-bar.mjs +23 -21
  189. package/tab.js +6 -0
  190. package/tab.mjs +11 -9
  191. package/{src/text-lockup → text-lockup}/text-lockup.d.ts +1 -0
  192. package/text-lockup/text-lockup.d.ts.map +1 -0
  193. package/text-lockup.js +7 -0
  194. package/text-lockup.mjs +11 -9
  195. package/{src/textarea → textarea}/textarea.d.ts +3 -2
  196. package/textarea/textarea.d.ts.map +1 -0
  197. package/textarea.js +40 -0
  198. package/textarea.mjs +14 -12
  199. package/{src/textfield → textfield}/textfield.d.ts +3 -2
  200. package/textfield/textfield.d.ts.map +1 -0
  201. package/textfield.js +7 -0
  202. package/textfield.mjs +132 -39
  203. package/textfield2.mjs +1 -1
  204. package/{src/toolbar → toolbar}/toolbar.d.ts +3 -2
  205. package/toolbar/toolbar.d.ts.map +1 -0
  206. package/toolbar.js +4 -0
  207. package/toolbar.mjs +11 -9
  208. package/{src/tooltip → tooltip}/tooltip.d.ts +3 -2
  209. package/tooltip/tooltip.d.ts.map +1 -0
  210. package/tooltip.js +126 -0
  211. package/tooltip.mjs +66 -64
  212. package/top-app-bar/top-app-bar-fixed.d.ts +11 -0
  213. package/top-app-bar/top-app-bar-fixed.d.ts.map +1 -0
  214. package/{src/top-app-bar → top-app-bar}/top-app-bar.d.ts +3 -2
  215. package/top-app-bar/top-app-bar.d.ts.map +1 -0
  216. package/top-app-bar-fixed.js +28 -0
  217. package/top-app-bar-fixed.mjs +16 -14
  218. package/top-app-bar.js +3 -0
  219. package/top-app-bar.mjs +6 -28
  220. package/{src/tree-list → tree-list}/tree-list-item.d.ts +1 -0
  221. package/tree-list/tree-list-item.d.ts.map +1 -0
  222. package/{src/tree-list → tree-list}/tree-list.d.ts +1 -0
  223. package/tree-list/tree-list.d.ts.map +1 -0
  224. package/tree-list-item.js +26 -0
  225. package/tree-list-item.mjs +7 -5
  226. package/tree-list.js +10 -0
  227. package/tree-list.mjs +13 -12
  228. package/tslib.es6.mjs +1 -82
  229. package/{src/typography → typography}/typography.d.ts +1 -0
  230. package/typography/typography.d.ts.map +1 -0
  231. package/typography.js +4 -0
  232. package/typography.mjs +16 -14
  233. package/utils.mjs +2 -49
  234. package/covalent.mjs +0 -44
  235. package/covalent.umd.js +0 -3501
  236. package/src/action-ribbon/action-ribbon-base.d.ts.map +0 -1
  237. package/src/action-ribbon/action-ribbon.d.ts.map +0 -1
  238. package/src/alert/alert-base.d.ts.map +0 -1
  239. package/src/alert/alert.d.ts.map +0 -1
  240. package/src/app-shell/app-shell.d.ts.map +0 -1
  241. package/src/button/button.d.ts.map +0 -1
  242. package/src/card/card-base.d.ts.map +0 -1
  243. package/src/card/card.d.ts.map +0 -1
  244. package/src/checkbox/checkbox.d.ts.map +0 -1
  245. package/src/chips/chip-base.d.ts.map +0 -1
  246. package/src/chips/chip-set-base.d.ts.map +0 -1
  247. package/src/chips/chip-set.d.ts.map +0 -1
  248. package/src/chips/chip.d.ts.map +0 -1
  249. package/src/chips/foundation.d.ts.map +0 -1
  250. package/src/circular-progress/circular-progress.d.ts +0 -10
  251. package/src/circular-progress/circular-progress.d.ts.map +0 -1
  252. package/src/code-snippet/code-snippet.d.ts.map +0 -1
  253. package/src/dialog/dialog.d.ts.map +0 -1
  254. package/src/drawer/drawer.d.ts.map +0 -1
  255. package/src/empty-state/empty-state.d.ts.map +0 -1
  256. package/src/formfield/formfield.d.ts.map +0 -1
  257. package/src/icon/icon.d.ts.map +0 -1
  258. package/src/icon-button/icon-button.d.ts.map +0 -1
  259. package/src/icon-checkbox/icon-check-toggle.d.ts.map +0 -1
  260. package/src/icon-radio/icon-radio-toggle.d.ts.map +0 -1
  261. package/src/index.d.ts +0 -3
  262. package/src/index.d.ts.map +0 -1
  263. package/src/linear-progress/linear-progress.d.ts +0 -10
  264. package/src/linear-progress/linear-progress.d.ts.map +0 -1
  265. package/src/list/check-list-item.d.ts +0 -10
  266. package/src/list/check-list-item.d.ts.map +0 -1
  267. package/src/list/list-expansion.d.ts.map +0 -1
  268. package/src/list/list-item.d.ts.map +0 -1
  269. package/src/list/list.d.ts.map +0 -1
  270. package/src/list/nav-list-item.d.ts.map +0 -1
  271. package/src/list/radio-list-item.d.ts +0 -10
  272. package/src/list/radio-list-item.d.ts.map +0 -1
  273. package/src/menu/menu.d.ts.map +0 -1
  274. package/src/radio/radio.d.ts.map +0 -1
  275. package/src/select/select.d.ts.map +0 -1
  276. package/src/side-sheet/side-sheet.d.ts.map +0 -1
  277. package/src/slider/slider-range.d.ts +0 -10
  278. package/src/slider/slider-range.d.ts.map +0 -1
  279. package/src/slider/slider.d.ts.map +0 -1
  280. package/src/snackbar/snackbar.d.ts.map +0 -1
  281. package/src/status-header/status-header-base.d.ts.map +0 -1
  282. package/src/status-header/status-header-item.d.ts.map +0 -1
  283. package/src/status-header/status-header.d.ts.map +0 -1
  284. package/src/switch/switch.d.ts.map +0 -1
  285. package/src/tab/tab-bar.d.ts.map +0 -1
  286. package/src/tab/tab.d.ts.map +0 -1
  287. package/src/text-lockup/text-lockup.d.ts.map +0 -1
  288. package/src/textarea/textarea.d.ts.map +0 -1
  289. package/src/textfield/textfield.d.ts.map +0 -1
  290. package/src/toolbar/toolbar.d.ts.map +0 -1
  291. package/src/tooltip/tooltip.d.ts.map +0 -1
  292. package/src/top-app-bar/top-app-bar-fixed.d.ts +0 -10
  293. package/src/top-app-bar/top-app-bar-fixed.d.ts.map +0 -1
  294. package/src/top-app-bar/top-app-bar.d.ts.map +0 -1
  295. package/src/tree-list/tree-list-item.d.ts.map +0 -1
  296. package/src/tree-list/tree-list.d.ts.map +0 -1
  297. package/src/typography/typography.d.ts.map +0 -1
  298. /package/{src/action-ribbon → action-ribbon}/action-ribbon-base.d.ts +0 -0
  299. /package/{src/alert → alert}/alert-base.d.ts +0 -0
  300. /package/{src/card → card}/card-base.d.ts +0 -0
  301. /package/{src/chips → chips}/chip-base.d.ts +0 -0
  302. /package/{src/chips → chips}/chip-set-base.d.ts +0 -0
  303. /package/{src/chips → chips}/foundation.d.ts +0 -0
  304. /package/{src/status-header → status-header}/status-header-base.d.ts +0 -0
package/mwc-menu-base.mjs CHANGED
@@ -1,32 +1,12 @@
1
- import { b as o, _ as U, a as B, c as q } from "./tslib.es6.mjs";
2
- import { i as V, e as K, y as F } from "./query-assigned-elements.mjs";
3
- import { L as Q } from "./mwc-list-base.mjs";
4
- import { B as j } from "./base-element.mjs";
5
- import { o as g } from "./observer.mjs";
6
- import { a as Y, d as Z, b as J } from "./utils.mjs";
7
- import { e as a } from "./property.mjs";
8
- import { t as b } from "./state.mjs";
9
- import { i as D } from "./query.mjs";
10
- import { o as P } from "./class-map.mjs";
11
- import { i as tt } from "./style-map.mjs";
12
- /**
1
+ "use strict";const o=require("./tslib.es6.mjs"),A=require("./query-assigned-elements.mjs"),K=require("./mwc-list-base.mjs"),U=require("./base-element.mjs"),E=require("./observer.mjs"),N=require("./utils.mjs"),a=require("./property.mjs"),v=require("./state.mjs"),F=require("./query.mjs"),P=require("./class-map.mjs"),j=require("./style-map.mjs");/**
13
2
  * @license
14
3
  * Copyright 2021 Google LLC
15
4
  * SPDX-LIcense-Identifier: Apache-2.0
16
- */
17
- const et = V`@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}:host{display:block}.mdc-deprecated-list{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:1rem;font-size:var(--mdc-typography-subtitle1-font-size, 1rem);line-height:1.75rem;line-height:var(--mdc-typography-subtitle1-line-height, 1.75rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);line-height:1.5rem;margin:0;padding:8px 0;list-style-type:none;color:rgba(0, 0, 0, 0.87);color:var(--mdc-theme-text-primary-on-background, rgba(0, 0, 0, 0.87));padding:var(--mdc-list-vertical-padding, 8px) 0}.mdc-deprecated-list:focus{outline:none}.mdc-deprecated-list-item{height:48px}.mdc-deprecated-list--dense{padding-top:4px;padding-bottom:4px;font-size:.812rem}.mdc-deprecated-list ::slotted([divider]){height:0;margin:0;border:none;border-bottom-width:1px;border-bottom-style:solid;border-bottom-color:rgba(0, 0, 0, 0.12)}.mdc-deprecated-list ::slotted([divider][padded]){margin:0 var(--mdc-list-side-padding, 16px)}.mdc-deprecated-list ::slotted([divider][inset]){margin-left:var(--mdc-list-inset-margin, 72px);margin-right:0;width:calc( 100% - var(--mdc-list-inset-margin, 72px) )}[dir=rtl] .mdc-deprecated-list ::slotted([divider][inset]),.mdc-deprecated-list ::slotted([divider][inset][dir=rtl]){margin-left:0;margin-right:var(--mdc-list-inset-margin, 72px)}.mdc-deprecated-list ::slotted([divider][inset][padded]){width:calc( 100% - var(--mdc-list-inset-margin, 72px) - var(--mdc-list-side-padding, 16px) )}.mdc-deprecated-list--dense ::slotted([mwc-list-item]){height:40px}.mdc-deprecated-list--dense ::slotted([mwc-list]){--mdc-list-item-graphic-size: 20px}.mdc-deprecated-list--two-line.mdc-deprecated-list--dense ::slotted([mwc-list-item]),.mdc-deprecated-list--avatar-list.mdc-deprecated-list--dense ::slotted([mwc-list-item]){height:60px}.mdc-deprecated-list--avatar-list.mdc-deprecated-list--dense ::slotted([mwc-list]){--mdc-list-item-graphic-size: 36px}:host([noninteractive]){pointer-events:none;cursor:default}.mdc-deprecated-list--dense ::slotted(.mdc-deprecated-list-item__primary-text){display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-deprecated-list--dense ::slotted(.mdc-deprecated-list-item__primary-text)::before{display:inline-block;width:0;height:24px;content:"";vertical-align:0}.mdc-deprecated-list--dense ::slotted(.mdc-deprecated-list-item__primary-text)::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}`;
18
- /**
5
+ */const W=A.i`@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}:host{display:block}.mdc-deprecated-list{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:1rem;font-size:var(--mdc-typography-subtitle1-font-size, 1rem);line-height:1.75rem;line-height:var(--mdc-typography-subtitle1-line-height, 1.75rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);line-height:1.5rem;margin:0;padding:8px 0;list-style-type:none;color:rgba(0, 0, 0, 0.87);color:var(--mdc-theme-text-primary-on-background, rgba(0, 0, 0, 0.87));padding:var(--mdc-list-vertical-padding, 8px) 0}.mdc-deprecated-list:focus{outline:none}.mdc-deprecated-list-item{height:48px}.mdc-deprecated-list--dense{padding-top:4px;padding-bottom:4px;font-size:.812rem}.mdc-deprecated-list ::slotted([divider]){height:0;margin:0;border:none;border-bottom-width:1px;border-bottom-style:solid;border-bottom-color:rgba(0, 0, 0, 0.12)}.mdc-deprecated-list ::slotted([divider][padded]){margin:0 var(--mdc-list-side-padding, 16px)}.mdc-deprecated-list ::slotted([divider][inset]){margin-left:var(--mdc-list-inset-margin, 72px);margin-right:0;width:calc( 100% - var(--mdc-list-inset-margin, 72px) )}[dir=rtl] .mdc-deprecated-list ::slotted([divider][inset]),.mdc-deprecated-list ::slotted([divider][inset][dir=rtl]){margin-left:0;margin-right:var(--mdc-list-inset-margin, 72px)}.mdc-deprecated-list ::slotted([divider][inset][padded]){width:calc( 100% - var(--mdc-list-inset-margin, 72px) - var(--mdc-list-side-padding, 16px) )}.mdc-deprecated-list--dense ::slotted([mwc-list-item]){height:40px}.mdc-deprecated-list--dense ::slotted([mwc-list]){--mdc-list-item-graphic-size: 20px}.mdc-deprecated-list--two-line.mdc-deprecated-list--dense ::slotted([mwc-list-item]),.mdc-deprecated-list--avatar-list.mdc-deprecated-list--dense ::slotted([mwc-list-item]){height:60px}.mdc-deprecated-list--avatar-list.mdc-deprecated-list--dense ::slotted([mwc-list]){--mdc-list-item-graphic-size: 36px}:host([noninteractive]){pointer-events:none;cursor:default}.mdc-deprecated-list--dense ::slotted(.mdc-deprecated-list-item__primary-text){display:block;margin-top:0;line-height:normal;margin-bottom:-20px}.mdc-deprecated-list--dense ::slotted(.mdc-deprecated-list-item__primary-text)::before{display:inline-block;width:0;height:24px;content:"";vertical-align:0}.mdc-deprecated-list--dense ::slotted(.mdc-deprecated-list-item__primary-text)::after{display:inline-block;width:0;height:20px;content:"";vertical-align:-20px}`;/**
19
6
  * @license
20
7
  * Copyright 2020 Google LLC
21
8
  * SPDX-License-Identifier: Apache-2.0
22
- */
23
- let k = class extends Q {
24
- };
25
- k.styles = [et];
26
- k = o([
27
- K("mwc-list")
28
- ], k);
29
- /**
9
+ */let k=class extends K.ListBase{};k.styles=[W];k=o.__decorate([A.e("mwc-list")],k);/**
30
10
  * @license
31
11
  * Copyright 2018 Google Inc.
32
12
  *
@@ -47,59 +27,7 @@ k = o([
47
27
  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
48
28
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
49
29
  * THE SOFTWARE.
50
- */
51
- var it = {
52
- ANCHOR: "mdc-menu-surface--anchor",
53
- ANIMATING_CLOSED: "mdc-menu-surface--animating-closed",
54
- ANIMATING_OPEN: "mdc-menu-surface--animating-open",
55
- FIXED: "mdc-menu-surface--fixed",
56
- IS_OPEN_BELOW: "mdc-menu-surface--is-open-below",
57
- OPEN: "mdc-menu-surface--open",
58
- ROOT: "mdc-menu-surface"
59
- }, nt = {
60
- CLOSED_EVENT: "MDCMenuSurface:closed",
61
- CLOSING_EVENT: "MDCMenuSurface:closing",
62
- OPENED_EVENT: "MDCMenuSurface:opened",
63
- OPENING_EVENT: "MDCMenuSurface:opening",
64
- FOCUSABLE_ELEMENTS: [
65
- "button:not(:disabled)",
66
- '[href]:not([aria-disabled="true"])',
67
- "input:not(:disabled)",
68
- "select:not(:disabled)",
69
- "textarea:not(:disabled)",
70
- '[tabindex]:not([tabindex="-1"]):not([aria-disabled="true"])'
71
- ].join(", ")
72
- }, M = {
73
- /** Total duration of menu-surface open animation. */
74
- TRANSITION_OPEN_DURATION: 120,
75
- /** Total duration of menu-surface close animation. */
76
- TRANSITION_CLOSE_DURATION: 75,
77
- /**
78
- * Margin left to the edge of the viewport when menu-surface is at maximum
79
- * possible height. Also used as a viewport margin.
80
- */
81
- MARGIN_TO_EDGE: 32,
82
- /**
83
- * Ratio of anchor width to menu-surface width for switching from corner
84
- * positioning to center positioning.
85
- */
86
- ANCHOR_TO_MENU_SURFACE_WIDTH_RATIO: 0.67,
87
- /**
88
- * Amount of time to wait before restoring focus when closing the menu
89
- * surface. This is important because if a touch event triggered the menu
90
- * close, and the subsequent mouse event occurs after focus is restored, then
91
- * the restored focus would be lost.
92
- */
93
- TOUCH_EVENT_WAIT_MS: 30
94
- }, c;
95
- (function(n) {
96
- n[n.BOTTOM = 1] = "BOTTOM", n[n.CENTER = 2] = "CENTER", n[n.RIGHT = 4] = "RIGHT", n[n.FLIP_RTL = 8] = "FLIP_RTL";
97
- })(c || (c = {}));
98
- var m;
99
- (function(n) {
100
- n[n.TOP_LEFT = 0] = "TOP_LEFT", n[n.TOP_RIGHT = 4] = "TOP_RIGHT", n[n.BOTTOM_LEFT = 1] = "BOTTOM_LEFT", n[n.BOTTOM_RIGHT = 5] = "BOTTOM_RIGHT", n[n.TOP_START = 8] = "TOP_START", n[n.TOP_END = 12] = "TOP_END", n[n.BOTTOM_START = 9] = "BOTTOM_START", n[n.BOTTOM_END = 13] = "BOTTOM_END";
101
- })(m || (m = {}));
102
- /**
30
+ */var X={ANCHOR:"mdc-menu-surface--anchor",ANIMATING_CLOSED:"mdc-menu-surface--animating-closed",ANIMATING_OPEN:"mdc-menu-surface--animating-open",FIXED:"mdc-menu-surface--fixed",IS_OPEN_BELOW:"mdc-menu-surface--is-open-below",OPEN:"mdc-menu-surface--open",ROOT:"mdc-menu-surface"},Q={CLOSED_EVENT:"MDCMenuSurface:closed",CLOSING_EVENT:"MDCMenuSurface:closing",OPENED_EVENT:"MDCMenuSurface:opened",OPENING_EVENT:"MDCMenuSurface:opening",FOCUSABLE_ELEMENTS:["button:not(:disabled)",'[href]:not([aria-disabled="true"])',"input:not(:disabled)","select:not(:disabled)","textarea:not(:disabled)",'[tabindex]:not([tabindex="-1"]):not([aria-disabled="true"])'].join(", ")},L={TRANSITION_OPEN_DURATION:120,TRANSITION_CLOSE_DURATION:75,MARGIN_TO_EDGE:32,ANCHOR_TO_MENU_SURFACE_WIDTH_RATIO:.67,TOUCH_EVENT_WAIT_MS:30},l;(function(n){n[n.BOTTOM=1]="BOTTOM",n[n.CENTER=2]="CENTER",n[n.RIGHT=4]="RIGHT",n[n.FLIP_RTL=8]="FLIP_RTL"})(l||(l={}));var m;(function(n){n[n.TOP_LEFT=0]="TOP_LEFT",n[n.TOP_RIGHT=4]="TOP_RIGHT",n[n.BOTTOM_LEFT=1]="BOTTOM_LEFT",n[n.BOTTOM_RIGHT=5]="BOTTOM_RIGHT",n[n.TOP_START=8]="TOP_START",n[n.TOP_END=12]="TOP_END",n[n.BOTTOM_START=9]="BOTTOM_START",n[n.BOTTOM_END=13]="BOTTOM_END"})(m||(m={}));/**
103
31
  * @license
104
32
  * Copyright 2016 Google Inc.
105
33
  *
@@ -120,43 +48,7 @@ var m;
120
48
  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
121
49
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
122
50
  * THE SOFTWARE.
123
- */
124
- var W = (
125
- /** @class */
126
- function() {
127
- function n(e) {
128
- e === void 0 && (e = {}), this.adapter = e;
129
- }
130
- return Object.defineProperty(n, "cssClasses", {
131
- get: function() {
132
- return {};
133
- },
134
- enumerable: !1,
135
- configurable: !0
136
- }), Object.defineProperty(n, "strings", {
137
- get: function() {
138
- return {};
139
- },
140
- enumerable: !1,
141
- configurable: !0
142
- }), Object.defineProperty(n, "numbers", {
143
- get: function() {
144
- return {};
145
- },
146
- enumerable: !1,
147
- configurable: !0
148
- }), Object.defineProperty(n, "defaultAdapter", {
149
- get: function() {
150
- return {};
151
- },
152
- enumerable: !1,
153
- configurable: !0
154
- }), n.prototype.init = function() {
155
- }, n.prototype.destroy = function() {
156
- }, n;
157
- }()
158
- );
159
- /**
51
+ */var q=function(){function n(t){t===void 0&&(t={}),this.adapter=t}return Object.defineProperty(n,"cssClasses",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(n,"strings",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(n,"numbers",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(n,"defaultAdapter",{get:function(){return{}},enumerable:!1,configurable:!0}),n.prototype.init=function(){},n.prototype.destroy=function(){},n}();/**
160
52
  * @license
161
53
  * Copyright 2018 Google Inc.
162
54
  *
@@ -177,479 +69,27 @@ var W = (
177
69
  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
178
70
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
179
71
  * THE SOFTWARE.
180
- */
181
- var X = (
182
- /** @class */
183
- function(n) {
184
- U(e, n);
185
- function e(t) {
186
- var i = n.call(this, B(B({}, e.defaultAdapter), t)) || this;
187
- return i.isSurfaceOpen = !1, i.isQuickOpen = !1, i.isHoistedElement = !1, i.isFixedPosition = !1, i.isHorizontallyCenteredOnViewport = !1, i.maxHeight = 0, i.openBottomBias = 0, i.openAnimationEndTimerId = 0, i.closeAnimationEndTimerId = 0, i.animationRequestId = 0, i.anchorCorner = m.TOP_START, i.originCorner = m.TOP_START, i.anchorMargin = { top: 0, right: 0, bottom: 0, left: 0 }, i.position = { x: 0, y: 0 }, i;
188
- }
189
- return Object.defineProperty(e, "cssClasses", {
190
- get: function() {
191
- return it;
192
- },
193
- enumerable: !1,
194
- configurable: !0
195
- }), Object.defineProperty(e, "strings", {
196
- get: function() {
197
- return nt;
198
- },
199
- enumerable: !1,
200
- configurable: !0
201
- }), Object.defineProperty(e, "numbers", {
202
- get: function() {
203
- return M;
204
- },
205
- enumerable: !1,
206
- configurable: !0
207
- }), Object.defineProperty(e, "Corner", {
208
- get: function() {
209
- return m;
210
- },
211
- enumerable: !1,
212
- configurable: !0
213
- }), Object.defineProperty(e, "defaultAdapter", {
214
- /**
215
- * @see {@link MDCMenuSurfaceAdapter} for typing information on parameters and return types.
216
- */
217
- get: function() {
218
- return {
219
- addClass: function() {
220
- },
221
- removeClass: function() {
222
- },
223
- hasClass: function() {
224
- return !1;
225
- },
226
- hasAnchor: function() {
227
- return !1;
228
- },
229
- isElementInContainer: function() {
230
- return !1;
231
- },
232
- isFocused: function() {
233
- return !1;
234
- },
235
- isRtl: function() {
236
- return !1;
237
- },
238
- getInnerDimensions: function() {
239
- return { height: 0, width: 0 };
240
- },
241
- getAnchorDimensions: function() {
242
- return null;
243
- },
244
- getWindowDimensions: function() {
245
- return { height: 0, width: 0 };
246
- },
247
- getBodyDimensions: function() {
248
- return { height: 0, width: 0 };
249
- },
250
- getWindowScroll: function() {
251
- return { x: 0, y: 0 };
252
- },
253
- setPosition: function() {
254
- },
255
- setMaxHeight: function() {
256
- },
257
- setTransformOrigin: function() {
258
- },
259
- saveFocus: function() {
260
- },
261
- restoreFocus: function() {
262
- },
263
- notifyClose: function() {
264
- },
265
- notifyClosing: function() {
266
- },
267
- notifyOpen: function() {
268
- },
269
- notifyOpening: function() {
270
- }
271
- };
272
- },
273
- enumerable: !1,
274
- configurable: !0
275
- }), e.prototype.init = function() {
276
- var t = e.cssClasses, i = t.ROOT, s = t.OPEN;
277
- if (!this.adapter.hasClass(i))
278
- throw new Error(i + " class required in root element.");
279
- this.adapter.hasClass(s) && (this.isSurfaceOpen = !0);
280
- }, e.prototype.destroy = function() {
281
- clearTimeout(this.openAnimationEndTimerId), clearTimeout(this.closeAnimationEndTimerId), cancelAnimationFrame(this.animationRequestId);
282
- }, e.prototype.setAnchorCorner = function(t) {
283
- this.anchorCorner = t;
284
- }, e.prototype.flipCornerHorizontally = function() {
285
- this.originCorner = this.originCorner ^ c.RIGHT;
286
- }, e.prototype.setAnchorMargin = function(t) {
287
- this.anchorMargin.top = t.top || 0, this.anchorMargin.right = t.right || 0, this.anchorMargin.bottom = t.bottom || 0, this.anchorMargin.left = t.left || 0;
288
- }, e.prototype.setIsHoisted = function(t) {
289
- this.isHoistedElement = t;
290
- }, e.prototype.setFixedPosition = function(t) {
291
- this.isFixedPosition = t;
292
- }, e.prototype.isFixed = function() {
293
- return this.isFixedPosition;
294
- }, e.prototype.setAbsolutePosition = function(t, i) {
295
- this.position.x = this.isFinite(t) ? t : 0, this.position.y = this.isFinite(i) ? i : 0;
296
- }, e.prototype.setIsHorizontallyCenteredOnViewport = function(t) {
297
- this.isHorizontallyCenteredOnViewport = t;
298
- }, e.prototype.setQuickOpen = function(t) {
299
- this.isQuickOpen = t;
300
- }, e.prototype.setMaxHeight = function(t) {
301
- this.maxHeight = t;
302
- }, e.prototype.setOpenBottomBias = function(t) {
303
- this.openBottomBias = t;
304
- }, e.prototype.isOpen = function() {
305
- return this.isSurfaceOpen;
306
- }, e.prototype.open = function() {
307
- var t = this;
308
- this.isSurfaceOpen || (this.adapter.notifyOpening(), this.adapter.saveFocus(), this.isQuickOpen ? (this.isSurfaceOpen = !0, this.adapter.addClass(e.cssClasses.OPEN), this.dimensions = this.adapter.getInnerDimensions(), this.autoposition(), this.adapter.notifyOpen()) : (this.adapter.addClass(e.cssClasses.ANIMATING_OPEN), this.animationRequestId = requestAnimationFrame(function() {
309
- t.dimensions = t.adapter.getInnerDimensions(), t.autoposition(), t.adapter.addClass(e.cssClasses.OPEN), t.openAnimationEndTimerId = setTimeout(function() {
310
- t.openAnimationEndTimerId = 0, t.adapter.removeClass(e.cssClasses.ANIMATING_OPEN), t.adapter.notifyOpen();
311
- }, M.TRANSITION_OPEN_DURATION);
312
- }), this.isSurfaceOpen = !0));
313
- }, e.prototype.close = function(t) {
314
- var i = this;
315
- if (t === void 0 && (t = !1), !!this.isSurfaceOpen) {
316
- if (this.adapter.notifyClosing(), this.isQuickOpen) {
317
- this.isSurfaceOpen = !1, t || this.maybeRestoreFocus(), this.adapter.removeClass(e.cssClasses.OPEN), this.adapter.removeClass(e.cssClasses.IS_OPEN_BELOW), this.adapter.notifyClose();
318
- return;
319
- }
320
- this.adapter.addClass(e.cssClasses.ANIMATING_CLOSED), requestAnimationFrame(function() {
321
- i.adapter.removeClass(e.cssClasses.OPEN), i.adapter.removeClass(e.cssClasses.IS_OPEN_BELOW), i.closeAnimationEndTimerId = setTimeout(function() {
322
- i.closeAnimationEndTimerId = 0, i.adapter.removeClass(e.cssClasses.ANIMATING_CLOSED), i.adapter.notifyClose();
323
- }, M.TRANSITION_CLOSE_DURATION);
324
- }), this.isSurfaceOpen = !1, t || this.maybeRestoreFocus();
325
- }
326
- }, e.prototype.handleBodyClick = function(t) {
327
- var i = t.target;
328
- this.adapter.isElementInContainer(i) || this.close();
329
- }, e.prototype.handleKeydown = function(t) {
330
- var i = t.keyCode, s = t.key, r = s === "Escape" || i === 27;
331
- r && this.close();
332
- }, e.prototype.autoposition = function() {
333
- var t;
334
- this.measurements = this.getAutoLayoutmeasurements();
335
- var i = this.getoriginCorner(), s = this.getMenuSurfaceMaxHeight(i), r = this.hasBit(i, c.BOTTOM) ? "bottom" : "top", l = this.hasBit(i, c.RIGHT) ? "right" : "left", f = this.getHorizontalOriginOffset(i), R = this.getVerticalOriginOffset(i), I = this.measurements, _ = I.anchorSize, S = I.surfaceSize, p = (t = {}, t[l] = f, t[r] = R, t);
336
- _.width / S.width > M.ANCHOR_TO_MENU_SURFACE_WIDTH_RATIO && (l = "center"), (this.isHoistedElement || this.isFixedPosition) && this.adjustPositionForHoistedElement(p), this.adapter.setTransformOrigin(l + " " + r), this.adapter.setPosition(p), this.adapter.setMaxHeight(s ? s + "px" : ""), this.hasBit(i, c.BOTTOM) || this.adapter.addClass(e.cssClasses.IS_OPEN_BELOW);
337
- }, e.prototype.getAutoLayoutmeasurements = function() {
338
- var t = this.adapter.getAnchorDimensions(), i = this.adapter.getBodyDimensions(), s = this.adapter.getWindowDimensions(), r = this.adapter.getWindowScroll();
339
- return t || (t = {
340
- top: this.position.y,
341
- right: this.position.x,
342
- bottom: this.position.y,
343
- left: this.position.x,
344
- width: 0,
345
- height: 0
346
- }), {
347
- anchorSize: t,
348
- bodySize: i,
349
- surfaceSize: this.dimensions,
350
- viewportDistance: {
351
- // tslint:disable:object-literal-sort-keys Positional properties are more readable when they're grouped together
352
- top: t.top,
353
- right: s.width - t.right,
354
- bottom: s.height - t.bottom,
355
- left: t.left
356
- // tslint:enable:object-literal-sort-keys
357
- },
358
- viewportSize: s,
359
- windowScroll: r
360
- };
361
- }, e.prototype.getoriginCorner = function() {
362
- var t = this.originCorner, i = this.measurements, s = i.viewportDistance, r = i.anchorSize, l = i.surfaceSize, f = e.numbers.MARGIN_TO_EDGE, R = this.hasBit(this.anchorCorner, c.BOTTOM), I, _;
363
- R ? (I = s.top - f + this.anchorMargin.bottom, _ = s.bottom - f - this.anchorMargin.bottom) : (I = s.top - f + this.anchorMargin.top, _ = s.bottom - f + r.height - this.anchorMargin.top);
364
- var S = _ - l.height > 0;
365
- !S && I > _ + this.openBottomBias && (t = this.setBit(t, c.BOTTOM));
366
- var p = this.adapter.isRtl(), T = this.hasBit(this.anchorCorner, c.FLIP_RTL), E = this.hasBit(this.anchorCorner, c.RIGHT) || this.hasBit(t, c.RIGHT), A = !1;
367
- p && T ? A = !E : A = E;
368
- var L, w;
369
- A ? (L = s.left + r.width + this.anchorMargin.right, w = s.right - this.anchorMargin.right) : (L = s.left + this.anchorMargin.left, w = s.right + r.width - this.anchorMargin.left);
370
- var N = L - l.width > 0, G = w - l.width > 0, $ = this.hasBit(t, c.FLIP_RTL) && this.hasBit(t, c.RIGHT);
371
- return G && $ && p || !N && $ ? t = this.unsetBit(t, c.RIGHT) : (N && A && p || N && !A && E || !G && L >= w) && (t = this.setBit(t, c.RIGHT)), t;
372
- }, e.prototype.getMenuSurfaceMaxHeight = function(t) {
373
- if (this.maxHeight > 0)
374
- return this.maxHeight;
375
- var i = this.measurements.viewportDistance, s = 0, r = this.hasBit(t, c.BOTTOM), l = this.hasBit(this.anchorCorner, c.BOTTOM), f = e.numbers.MARGIN_TO_EDGE;
376
- return r ? (s = i.top + this.anchorMargin.top - f, l || (s += this.measurements.anchorSize.height)) : (s = i.bottom - this.anchorMargin.bottom + this.measurements.anchorSize.height - f, l && (s -= this.measurements.anchorSize.height)), s;
377
- }, e.prototype.getHorizontalOriginOffset = function(t) {
378
- var i = this.measurements.anchorSize, s = this.hasBit(t, c.RIGHT), r = this.hasBit(this.anchorCorner, c.RIGHT);
379
- if (s) {
380
- var l = r ? i.width - this.anchorMargin.left : this.anchorMargin.right;
381
- return this.isHoistedElement || this.isFixedPosition ? l - (this.measurements.viewportSize.width - this.measurements.bodySize.width) : l;
382
- }
383
- return r ? i.width - this.anchorMargin.right : this.anchorMargin.left;
384
- }, e.prototype.getVerticalOriginOffset = function(t) {
385
- var i = this.measurements.anchorSize, s = this.hasBit(t, c.BOTTOM), r = this.hasBit(this.anchorCorner, c.BOTTOM), l = 0;
386
- return s ? l = r ? i.height - this.anchorMargin.top : -this.anchorMargin.bottom : l = r ? i.height + this.anchorMargin.bottom : this.anchorMargin.top, l;
387
- }, e.prototype.adjustPositionForHoistedElement = function(t) {
388
- var i, s, r = this.measurements, l = r.windowScroll, f = r.viewportDistance, R = r.surfaceSize, I = r.viewportSize, _ = Object.keys(t);
389
- try {
390
- for (var S = q(_), p = S.next(); !p.done; p = S.next()) {
391
- var T = p.value, E = t[T] || 0;
392
- if (this.isHorizontallyCenteredOnViewport && (T === "left" || T === "right")) {
393
- t[T] = (I.width - R.width) / 2;
394
- continue;
395
- }
396
- E += f[T], this.isFixedPosition || (T === "top" ? E += l.y : T === "bottom" ? E -= l.y : T === "left" ? E += l.x : E -= l.x), t[T] = E;
397
- }
398
- } catch (A) {
399
- i = { error: A };
400
- } finally {
401
- try {
402
- p && !p.done && (s = S.return) && s.call(S);
403
- } finally {
404
- if (i)
405
- throw i.error;
406
- }
407
- }
408
- }, e.prototype.maybeRestoreFocus = function() {
409
- var t = this, i = this.adapter.isFocused(), s = this.adapter.getOwnerDocument ? this.adapter.getOwnerDocument() : document, r = s.activeElement && this.adapter.isElementInContainer(s.activeElement);
410
- (i || r) && setTimeout(function() {
411
- t.adapter.restoreFocus();
412
- }, M.TOUCH_EVENT_WAIT_MS);
413
- }, e.prototype.hasBit = function(t, i) {
414
- return Boolean(t & i);
415
- }, e.prototype.setBit = function(t, i) {
416
- return t | i;
417
- }, e.prototype.unsetBit = function(t, i) {
418
- return t ^ i;
419
- }, e.prototype.isFinite = function(t) {
420
- return typeof t == "number" && isFinite(t);
421
- }, e;
422
- }(W)
423
- );
424
- const st = X;
425
- /**
72
+ */var V=function(n){o.__extends(t,n);function t(e){var i=n.call(this,o.__assign(o.__assign({},t.defaultAdapter),e))||this;return i.isSurfaceOpen=!1,i.isQuickOpen=!1,i.isHoistedElement=!1,i.isFixedPosition=!1,i.isHorizontallyCenteredOnViewport=!1,i.maxHeight=0,i.openBottomBias=0,i.openAnimationEndTimerId=0,i.closeAnimationEndTimerId=0,i.animationRequestId=0,i.anchorCorner=m.TOP_START,i.originCorner=m.TOP_START,i.anchorMargin={top:0,right:0,bottom:0,left:0},i.position={x:0,y:0},i}return Object.defineProperty(t,"cssClasses",{get:function(){return X},enumerable:!1,configurable:!0}),Object.defineProperty(t,"strings",{get:function(){return Q},enumerable:!1,configurable:!0}),Object.defineProperty(t,"numbers",{get:function(){return L},enumerable:!1,configurable:!0}),Object.defineProperty(t,"Corner",{get:function(){return m},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!1},hasAnchor:function(){return!1},isElementInContainer:function(){return!1},isFocused:function(){return!1},isRtl:function(){return!1},getInnerDimensions:function(){return{height:0,width:0}},getAnchorDimensions:function(){return null},getWindowDimensions:function(){return{height:0,width:0}},getBodyDimensions:function(){return{height:0,width:0}},getWindowScroll:function(){return{x:0,y:0}},setPosition:function(){},setMaxHeight:function(){},setTransformOrigin:function(){},saveFocus:function(){},restoreFocus:function(){},notifyClose:function(){},notifyClosing:function(){},notifyOpen:function(){},notifyOpening:function(){}}},enumerable:!1,configurable:!0}),t.prototype.init=function(){var e=t.cssClasses,i=e.ROOT,s=e.OPEN;if(!this.adapter.hasClass(i))throw new Error(i+" class required in root element.");this.adapter.hasClass(s)&&(this.isSurfaceOpen=!0)},t.prototype.destroy=function(){clearTimeout(this.openAnimationEndTimerId),clearTimeout(this.closeAnimationEndTimerId),cancelAnimationFrame(this.animationRequestId)},t.prototype.setAnchorCorner=function(e){this.anchorCorner=e},t.prototype.flipCornerHorizontally=function(){this.originCorner=this.originCorner^l.RIGHT},t.prototype.setAnchorMargin=function(e){this.anchorMargin.top=e.top||0,this.anchorMargin.right=e.right||0,this.anchorMargin.bottom=e.bottom||0,this.anchorMargin.left=e.left||0},t.prototype.setIsHoisted=function(e){this.isHoistedElement=e},t.prototype.setFixedPosition=function(e){this.isFixedPosition=e},t.prototype.isFixed=function(){return this.isFixedPosition},t.prototype.setAbsolutePosition=function(e,i){this.position.x=this.isFinite(e)?e:0,this.position.y=this.isFinite(i)?i:0},t.prototype.setIsHorizontallyCenteredOnViewport=function(e){this.isHorizontallyCenteredOnViewport=e},t.prototype.setQuickOpen=function(e){this.isQuickOpen=e},t.prototype.setMaxHeight=function(e){this.maxHeight=e},t.prototype.setOpenBottomBias=function(e){this.openBottomBias=e},t.prototype.isOpen=function(){return this.isSurfaceOpen},t.prototype.open=function(){var e=this;this.isSurfaceOpen||(this.adapter.notifyOpening(),this.adapter.saveFocus(),this.isQuickOpen?(this.isSurfaceOpen=!0,this.adapter.addClass(t.cssClasses.OPEN),this.dimensions=this.adapter.getInnerDimensions(),this.autoposition(),this.adapter.notifyOpen()):(this.adapter.addClass(t.cssClasses.ANIMATING_OPEN),this.animationRequestId=requestAnimationFrame(function(){e.dimensions=e.adapter.getInnerDimensions(),e.autoposition(),e.adapter.addClass(t.cssClasses.OPEN),e.openAnimationEndTimerId=setTimeout(function(){e.openAnimationEndTimerId=0,e.adapter.removeClass(t.cssClasses.ANIMATING_OPEN),e.adapter.notifyOpen()},L.TRANSITION_OPEN_DURATION)}),this.isSurfaceOpen=!0))},t.prototype.close=function(e){var i=this;if(e===void 0&&(e=!1),!!this.isSurfaceOpen){if(this.adapter.notifyClosing(),this.isQuickOpen){this.isSurfaceOpen=!1,e||this.maybeRestoreFocus(),this.adapter.removeClass(t.cssClasses.OPEN),this.adapter.removeClass(t.cssClasses.IS_OPEN_BELOW),this.adapter.notifyClose();return}this.adapter.addClass(t.cssClasses.ANIMATING_CLOSED),requestAnimationFrame(function(){i.adapter.removeClass(t.cssClasses.OPEN),i.adapter.removeClass(t.cssClasses.IS_OPEN_BELOW),i.closeAnimationEndTimerId=setTimeout(function(){i.closeAnimationEndTimerId=0,i.adapter.removeClass(t.cssClasses.ANIMATING_CLOSED),i.adapter.notifyClose()},L.TRANSITION_CLOSE_DURATION)}),this.isSurfaceOpen=!1,e||this.maybeRestoreFocus()}},t.prototype.handleBodyClick=function(e){var i=e.target;this.adapter.isElementInContainer(i)||this.close()},t.prototype.handleKeydown=function(e){var i=e.keyCode,s=e.key,r=s==="Escape"||i===27;r&&this.close()},t.prototype.autoposition=function(){var e;this.measurements=this.getAutoLayoutmeasurements();var i=this.getoriginCorner(),s=this.getMenuSurfaceMaxHeight(i),r=this.hasBit(i,l.BOTTOM)?"bottom":"top",c=this.hasBit(i,l.RIGHT)?"right":"left",f=this.getHorizontalOriginOffset(i),M=this.getVerticalOriginOffset(i),y=this.measurements,I=y.anchorSize,S=y.surfaceSize,p=(e={},e[c]=f,e[r]=M,e);I.width/S.width>L.ANCHOR_TO_MENU_SURFACE_WIDTH_RATIO&&(c="center"),(this.isHoistedElement||this.isFixedPosition)&&this.adjustPositionForHoistedElement(p),this.adapter.setTransformOrigin(c+" "+r),this.adapter.setPosition(p),this.adapter.setMaxHeight(s?s+"px":""),this.hasBit(i,l.BOTTOM)||this.adapter.addClass(t.cssClasses.IS_OPEN_BELOW)},t.prototype.getAutoLayoutmeasurements=function(){var e=this.adapter.getAnchorDimensions(),i=this.adapter.getBodyDimensions(),s=this.adapter.getWindowDimensions(),r=this.adapter.getWindowScroll();return e||(e={top:this.position.y,right:this.position.x,bottom:this.position.y,left:this.position.x,width:0,height:0}),{anchorSize:e,bodySize:i,surfaceSize:this.dimensions,viewportDistance:{top:e.top,right:s.width-e.right,bottom:s.height-e.bottom,left:e.left},viewportSize:s,windowScroll:r}},t.prototype.getoriginCorner=function(){var e=this.originCorner,i=this.measurements,s=i.viewportDistance,r=i.anchorSize,c=i.surfaceSize,f=t.numbers.MARGIN_TO_EDGE,M=this.hasBit(this.anchorCorner,l.BOTTOM),y,I;M?(y=s.top-f+this.anchorMargin.bottom,I=s.bottom-f-this.anchorMargin.bottom):(y=s.top-f+this.anchorMargin.top,I=s.bottom-f+r.height-this.anchorMargin.top);var S=I-c.height>0;!S&&y>I+this.openBottomBias&&(e=this.setBit(e,l.BOTTOM));var p=this.adapter.isRtl(),T=this.hasBit(this.anchorCorner,l.FLIP_RTL),_=this.hasBit(this.anchorCorner,l.RIGHT)||this.hasBit(e,l.RIGHT),C=!1;p&&T?C=!_:C=_;var w,B;C?(w=s.left+r.width+this.anchorMargin.right,B=s.right-this.anchorMargin.right):(w=s.left+this.anchorMargin.left,B=s.right+r.width-this.anchorMargin.left);var D=w-c.width>0,G=B-c.width>0,$=this.hasBit(e,l.FLIP_RTL)&&this.hasBit(e,l.RIGHT);return G&&$&&p||!D&&$?e=this.unsetBit(e,l.RIGHT):(D&&C&&p||D&&!C&&_||!G&&w>=B)&&(e=this.setBit(e,l.RIGHT)),e},t.prototype.getMenuSurfaceMaxHeight=function(e){if(this.maxHeight>0)return this.maxHeight;var i=this.measurements.viewportDistance,s=0,r=this.hasBit(e,l.BOTTOM),c=this.hasBit(this.anchorCorner,l.BOTTOM),f=t.numbers.MARGIN_TO_EDGE;return r?(s=i.top+this.anchorMargin.top-f,c||(s+=this.measurements.anchorSize.height)):(s=i.bottom-this.anchorMargin.bottom+this.measurements.anchorSize.height-f,c&&(s-=this.measurements.anchorSize.height)),s},t.prototype.getHorizontalOriginOffset=function(e){var i=this.measurements.anchorSize,s=this.hasBit(e,l.RIGHT),r=this.hasBit(this.anchorCorner,l.RIGHT);if(s){var c=r?i.width-this.anchorMargin.left:this.anchorMargin.right;return this.isHoistedElement||this.isFixedPosition?c-(this.measurements.viewportSize.width-this.measurements.bodySize.width):c}return r?i.width-this.anchorMargin.right:this.anchorMargin.left},t.prototype.getVerticalOriginOffset=function(e){var i=this.measurements.anchorSize,s=this.hasBit(e,l.BOTTOM),r=this.hasBit(this.anchorCorner,l.BOTTOM),c=0;return s?c=r?i.height-this.anchorMargin.top:-this.anchorMargin.bottom:c=r?i.height+this.anchorMargin.bottom:this.anchorMargin.top,c},t.prototype.adjustPositionForHoistedElement=function(e){var i,s,r=this.measurements,c=r.windowScroll,f=r.viewportDistance,M=r.surfaceSize,y=r.viewportSize,I=Object.keys(e);try{for(var S=o.__values(I),p=S.next();!p.done;p=S.next()){var T=p.value,_=e[T]||0;if(this.isHorizontallyCenteredOnViewport&&(T==="left"||T==="right")){e[T]=(y.width-M.width)/2;continue}_+=f[T],this.isFixedPosition||(T==="top"?_+=c.y:T==="bottom"?_-=c.y:T==="left"?_+=c.x:_-=c.x),e[T]=_}}catch(C){i={error:C}}finally{try{p&&!p.done&&(s=S.return)&&s.call(S)}finally{if(i)throw i.error}}},t.prototype.maybeRestoreFocus=function(){var e=this,i=this.adapter.isFocused(),s=this.adapter.getOwnerDocument?this.adapter.getOwnerDocument():document,r=s.activeElement&&this.adapter.isElementInContainer(s.activeElement);(i||r)&&setTimeout(function(){e.adapter.restoreFocus()},L.TOUCH_EVENT_WAIT_MS)},t.prototype.hasBit=function(e,i){return Boolean(e&i)},t.prototype.setBit=function(e,i){return e|i},t.prototype.unsetBit=function(e,i){return e^i},t.prototype.isFinite=function(e){return typeof e=="number"&&isFinite(e)},t}(q);const Y=V;/**
426
73
  * @license
427
74
  * Copyright 2020 Google LLC
428
75
  * SPDX-License-Identifier: Apache-2.0
429
- */
430
- const ot = {
431
- TOP_LEFT: m.TOP_LEFT,
432
- TOP_RIGHT: m.TOP_RIGHT,
433
- BOTTOM_LEFT: m.BOTTOM_LEFT,
434
- BOTTOM_RIGHT: m.BOTTOM_RIGHT,
435
- TOP_START: m.TOP_START,
436
- TOP_END: m.TOP_END,
437
- BOTTOM_START: m.BOTTOM_START,
438
- BOTTOM_END: m.BOTTOM_END
439
- };
440
- class u extends j {
441
- constructor() {
442
- super(...arguments), this.mdcFoundationClass = st, this.absolute = !1, this.fullwidth = !1, this.fixed = !1, this.x = null, this.y = null, this.quick = !1, this.open = !1, this.stayOpenOnBodyClick = !1, this.bitwiseCorner = m.TOP_START, this.previousMenuCorner = null, this.menuCorner = "START", this.corner = "TOP_START", this.styleTop = "", this.styleLeft = "", this.styleRight = "", this.styleBottom = "", this.styleMaxHeight = "", this.styleTransformOrigin = "", this.anchor = null, this.previouslyFocused = null, this.previousAnchor = null, this.onBodyClickBound = () => {
443
- };
444
- }
445
- render() {
446
- return this.renderSurface();
447
- }
448
- renderSurface() {
449
- const e = this.getRootClasses(), t = this.getRootStyles();
450
- return F`
76
+ */const Z={TOP_LEFT:m.TOP_LEFT,TOP_RIGHT:m.TOP_RIGHT,BOTTOM_LEFT:m.BOTTOM_LEFT,BOTTOM_RIGHT:m.BOTTOM_RIGHT,TOP_START:m.TOP_START,TOP_END:m.TOP_END,BOTTOM_START:m.BOTTOM_START,BOTTOM_END:m.BOTTOM_END};class h extends U.BaseElement{constructor(){super(...arguments),this.mdcFoundationClass=Y,this.absolute=!1,this.fullwidth=!1,this.fixed=!1,this.x=null,this.y=null,this.quick=!1,this.open=!1,this.stayOpenOnBodyClick=!1,this.bitwiseCorner=m.TOP_START,this.previousMenuCorner=null,this.menuCorner="START",this.corner="TOP_START",this.styleTop="",this.styleLeft="",this.styleRight="",this.styleBottom="",this.styleMaxHeight="",this.styleTransformOrigin="",this.anchor=null,this.previouslyFocused=null,this.previousAnchor=null,this.onBodyClickBound=()=>{}}render(){return this.renderSurface()}renderSurface(){const t=this.getRootClasses(),e=this.getRootStyles();return A.y`
451
77
  <div
452
- class=${P(e)}
453
- style="${tt(t)}"
78
+ class=${P.o(t)}
79
+ style="${j.i(e)}"
454
80
  @keydown=${this.onKeydown}
455
81
  @opened=${this.registerBodyClick}
456
82
  @closed=${this.deregisterBodyClick}>
457
83
  ${this.renderContent()}
458
- </div>`;
459
- }
460
- getRootClasses() {
461
- return {
462
- "mdc-menu-surface": !0,
463
- "mdc-menu-surface--fixed": this.fixed,
464
- "mdc-menu-surface--fullwidth": this.fullwidth
465
- };
466
- }
467
- getRootStyles() {
468
- return {
469
- top: this.styleTop,
470
- left: this.styleLeft,
471
- right: this.styleRight,
472
- bottom: this.styleBottom,
473
- "max-height": this.styleMaxHeight,
474
- "transform-origin": this.styleTransformOrigin
475
- };
476
- }
477
- renderContent() {
478
- return F`<slot></slot>`;
479
- }
480
- createAdapter() {
481
- return Object.assign(Object.assign({}, Y(this.mdcRoot)), { hasAnchor: () => !!this.anchor, notifyClose: () => {
482
- const e = { bubbles: !0, composed: !0 }, t = new CustomEvent("closed", e);
483
- this.open = !1, this.mdcRoot.dispatchEvent(t);
484
- }, notifyClosing: () => {
485
- const e = { bubbles: !0, composed: !0 }, t = new CustomEvent("closing", e);
486
- this.mdcRoot.dispatchEvent(t);
487
- }, notifyOpen: () => {
488
- const e = { bubbles: !0, composed: !0 }, t = new CustomEvent("opened", e);
489
- this.open = !0, this.mdcRoot.dispatchEvent(t);
490
- }, notifyOpening: () => {
491
- const e = { bubbles: !0, composed: !0 }, t = new CustomEvent("opening", e);
492
- this.mdcRoot.dispatchEvent(t);
493
- }, isElementInContainer: () => !1, isRtl: () => this.mdcRoot ? getComputedStyle(this.mdcRoot).direction === "rtl" : !1, setTransformOrigin: (e) => {
494
- this.mdcRoot && (this.styleTransformOrigin = e);
495
- }, isFocused: () => Z(this), saveFocus: () => {
496
- const e = J(), t = e.length;
497
- t || (this.previouslyFocused = null), this.previouslyFocused = e[t - 1];
498
- }, restoreFocus: () => {
499
- this.previouslyFocused && "focus" in this.previouslyFocused && this.previouslyFocused.focus();
500
- }, getInnerDimensions: () => {
501
- const e = this.mdcRoot;
502
- return e ? { width: e.offsetWidth, height: e.offsetHeight } : { width: 0, height: 0 };
503
- }, getAnchorDimensions: () => {
504
- const e = this.anchor;
505
- return e ? e.getBoundingClientRect() : null;
506
- }, getBodyDimensions: () => ({
507
- width: document.body.clientWidth,
508
- height: document.body.clientHeight
509
- }), getWindowDimensions: () => ({
510
- width: window.innerWidth,
511
- height: window.innerHeight
512
- }), getWindowScroll: () => ({
513
- x: window.pageXOffset,
514
- y: window.pageYOffset
515
- }), setPosition: (e) => {
516
- this.mdcRoot && (this.styleLeft = "left" in e ? `${e.left}px` : "", this.styleRight = "right" in e ? `${e.right}px` : "", this.styleTop = "top" in e ? `${e.top}px` : "", this.styleBottom = "bottom" in e ? `${e.bottom}px` : "");
517
- }, setMaxHeight: async (e) => {
518
- this.mdcRoot && (this.styleMaxHeight = e, await this.updateComplete, this.styleMaxHeight = `var(--mdc-menu-max-height, ${e})`);
519
- } });
520
- }
521
- onKeydown(e) {
522
- this.mdcFoundation && this.mdcFoundation.handleKeydown(e);
523
- }
524
- onBodyClick(e) {
525
- if (this.stayOpenOnBodyClick)
526
- return;
527
- e.composedPath().indexOf(this) === -1 && this.close();
528
- }
529
- registerBodyClick() {
530
- this.onBodyClickBound = this.onBodyClick.bind(this), document.body.addEventListener("click", this.onBodyClickBound, { passive: !0, capture: !0 });
531
- }
532
- deregisterBodyClick() {
533
- document.body.removeEventListener("click", this.onBodyClickBound, { capture: !0 });
534
- }
535
- onOpenChanged(e, t) {
536
- this.mdcFoundation && (e ? this.mdcFoundation.open() : t !== void 0 && this.mdcFoundation.close());
537
- }
538
- close() {
539
- this.open = !1;
540
- }
541
- show() {
542
- this.open = !0;
543
- }
544
- }
545
- o([
546
- D(".mdc-menu-surface")
547
- ], u.prototype, "mdcRoot", void 0);
548
- o([
549
- D("slot")
550
- ], u.prototype, "slotElement", void 0);
551
- o([
552
- a({ type: Boolean }),
553
- g(function(n) {
554
- this.mdcFoundation && !this.fixed && this.mdcFoundation.setIsHoisted(n);
555
- })
556
- ], u.prototype, "absolute", void 0);
557
- o([
558
- a({ type: Boolean })
559
- ], u.prototype, "fullwidth", void 0);
560
- o([
561
- a({ type: Boolean }),
562
- g(function(n) {
563
- this.mdcFoundation && !this.absolute && this.mdcFoundation.setFixedPosition(n);
564
- })
565
- ], u.prototype, "fixed", void 0);
566
- o([
567
- a({ type: Number }),
568
- g(function(n) {
569
- this.mdcFoundation && this.y !== null && n !== null && (this.mdcFoundation.setAbsolutePosition(n, this.y), this.mdcFoundation.setAnchorMargin({ left: n, top: this.y, right: -n, bottom: this.y }));
570
- })
571
- ], u.prototype, "x", void 0);
572
- o([
573
- a({ type: Number }),
574
- g(function(n) {
575
- this.mdcFoundation && this.x !== null && n !== null && (this.mdcFoundation.setAbsolutePosition(this.x, n), this.mdcFoundation.setAnchorMargin({ left: this.x, top: n, right: -this.x, bottom: n }));
576
- })
577
- ], u.prototype, "y", void 0);
578
- o([
579
- a({ type: Boolean }),
580
- g(function(n) {
581
- this.mdcFoundation && this.mdcFoundation.setQuickOpen(n);
582
- })
583
- ], u.prototype, "quick", void 0);
584
- o([
585
- a({ type: Boolean, reflect: !0 }),
586
- g(function(n, e) {
587
- this.onOpenChanged(n, e);
588
- })
589
- ], u.prototype, "open", void 0);
590
- o([
591
- a({ type: Boolean })
592
- ], u.prototype, "stayOpenOnBodyClick", void 0);
593
- o([
594
- b(),
595
- g(function(n) {
596
- this.mdcFoundation && (n ? this.mdcFoundation.setAnchorCorner(n) : this.mdcFoundation.setAnchorCorner(n));
597
- })
598
- ], u.prototype, "bitwiseCorner", void 0);
599
- o([
600
- a({ type: String }),
601
- g(function(n) {
602
- if (this.mdcFoundation) {
603
- const e = n === "START" || n === "END", t = this.previousMenuCorner === null, i = !t && n !== this.previousMenuCorner;
604
- e && (i || t && n === "END") && (this.bitwiseCorner = this.bitwiseCorner ^ c.RIGHT, this.mdcFoundation.flipCornerHorizontally(), this.previousMenuCorner = n);
605
- }
606
- })
607
- ], u.prototype, "menuCorner", void 0);
608
- o([
609
- a({ type: String }),
610
- g(function(n) {
611
- if (this.mdcFoundation && n) {
612
- let e = ot[n];
613
- this.menuCorner === "END" && (e = e ^ c.RIGHT), this.bitwiseCorner = e;
614
- }
615
- })
616
- ], u.prototype, "corner", void 0);
617
- o([
618
- b()
619
- ], u.prototype, "styleTop", void 0);
620
- o([
621
- b()
622
- ], u.prototype, "styleLeft", void 0);
623
- o([
624
- b()
625
- ], u.prototype, "styleRight", void 0);
626
- o([
627
- b()
628
- ], u.prototype, "styleBottom", void 0);
629
- o([
630
- b()
631
- ], u.prototype, "styleMaxHeight", void 0);
632
- o([
633
- b()
634
- ], u.prototype, "styleTransformOrigin", void 0);
635
- /**
84
+ </div>`}getRootClasses(){return{"mdc-menu-surface":!0,"mdc-menu-surface--fixed":this.fixed,"mdc-menu-surface--fullwidth":this.fullwidth}}getRootStyles(){return{top:this.styleTop,left:this.styleLeft,right:this.styleRight,bottom:this.styleBottom,"max-height":this.styleMaxHeight,"transform-origin":this.styleTransformOrigin}}renderContent(){return A.y`<slot></slot>`}createAdapter(){return Object.assign(Object.assign({},N.addHasRemoveClass(this.mdcRoot)),{hasAnchor:()=>!!this.anchor,notifyClose:()=>{const t={bubbles:!0,composed:!0},e=new CustomEvent("closed",t);this.open=!1,this.mdcRoot.dispatchEvent(e)},notifyClosing:()=>{const t={bubbles:!0,composed:!0},e=new CustomEvent("closing",t);this.mdcRoot.dispatchEvent(e)},notifyOpen:()=>{const t={bubbles:!0,composed:!0},e=new CustomEvent("opened",t);this.open=!0,this.mdcRoot.dispatchEvent(e)},notifyOpening:()=>{const t={bubbles:!0,composed:!0},e=new CustomEvent("opening",t);this.mdcRoot.dispatchEvent(e)},isElementInContainer:()=>!1,isRtl:()=>this.mdcRoot?getComputedStyle(this.mdcRoot).direction==="rtl":!1,setTransformOrigin:t=>{this.mdcRoot&&(this.styleTransformOrigin=t)},isFocused:()=>N.doesElementContainFocus(this),saveFocus:()=>{const t=N.deepActiveElementPath(),e=t.length;e||(this.previouslyFocused=null),this.previouslyFocused=t[e-1]},restoreFocus:()=>{this.previouslyFocused&&"focus"in this.previouslyFocused&&this.previouslyFocused.focus()},getInnerDimensions:()=>{const t=this.mdcRoot;return t?{width:t.offsetWidth,height:t.offsetHeight}:{width:0,height:0}},getAnchorDimensions:()=>{const t=this.anchor;return t?t.getBoundingClientRect():null},getBodyDimensions:()=>({width:document.body.clientWidth,height:document.body.clientHeight}),getWindowDimensions:()=>({width:window.innerWidth,height:window.innerHeight}),getWindowScroll:()=>({x:window.pageXOffset,y:window.pageYOffset}),setPosition:t=>{this.mdcRoot&&(this.styleLeft="left"in t?`${t.left}px`:"",this.styleRight="right"in t?`${t.right}px`:"",this.styleTop="top"in t?`${t.top}px`:"",this.styleBottom="bottom"in t?`${t.bottom}px`:"")},setMaxHeight:async t=>{this.mdcRoot&&(this.styleMaxHeight=t,await this.updateComplete,this.styleMaxHeight=`var(--mdc-menu-max-height, ${t})`)}})}onKeydown(t){this.mdcFoundation&&this.mdcFoundation.handleKeydown(t)}onBodyClick(t){if(this.stayOpenOnBodyClick)return;t.composedPath().indexOf(this)===-1&&this.close()}registerBodyClick(){this.onBodyClickBound=this.onBodyClick.bind(this),document.body.addEventListener("click",this.onBodyClickBound,{passive:!0,capture:!0})}deregisterBodyClick(){document.body.removeEventListener("click",this.onBodyClickBound,{capture:!0})}onOpenChanged(t,e){this.mdcFoundation&&(t?this.mdcFoundation.open():e!==void 0&&this.mdcFoundation.close())}close(){this.open=!1}show(){this.open=!0}}o.__decorate([F.i(".mdc-menu-surface")],h.prototype,"mdcRoot",void 0);o.__decorate([F.i("slot")],h.prototype,"slotElement",void 0);o.__decorate([a.e({type:Boolean}),E.observer(function(n){this.mdcFoundation&&!this.fixed&&this.mdcFoundation.setIsHoisted(n)})],h.prototype,"absolute",void 0);o.__decorate([a.e({type:Boolean})],h.prototype,"fullwidth",void 0);o.__decorate([a.e({type:Boolean}),E.observer(function(n){this.mdcFoundation&&!this.absolute&&this.mdcFoundation.setFixedPosition(n)})],h.prototype,"fixed",void 0);o.__decorate([a.e({type:Number}),E.observer(function(n){this.mdcFoundation&&this.y!==null&&n!==null&&(this.mdcFoundation.setAbsolutePosition(n,this.y),this.mdcFoundation.setAnchorMargin({left:n,top:this.y,right:-n,bottom:this.y}))})],h.prototype,"x",void 0);o.__decorate([a.e({type:Number}),E.observer(function(n){this.mdcFoundation&&this.x!==null&&n!==null&&(this.mdcFoundation.setAbsolutePosition(this.x,n),this.mdcFoundation.setAnchorMargin({left:this.x,top:n,right:-this.x,bottom:n}))})],h.prototype,"y",void 0);o.__decorate([a.e({type:Boolean}),E.observer(function(n){this.mdcFoundation&&this.mdcFoundation.setQuickOpen(n)})],h.prototype,"quick",void 0);o.__decorate([a.e({type:Boolean,reflect:!0}),E.observer(function(n,t){this.onOpenChanged(n,t)})],h.prototype,"open",void 0);o.__decorate([a.e({type:Boolean})],h.prototype,"stayOpenOnBodyClick",void 0);o.__decorate([v.t(),E.observer(function(n){this.mdcFoundation&&(n?this.mdcFoundation.setAnchorCorner(n):this.mdcFoundation.setAnchorCorner(n))})],h.prototype,"bitwiseCorner",void 0);o.__decorate([a.e({type:String}),E.observer(function(n){if(this.mdcFoundation){const t=n==="START"||n==="END",e=this.previousMenuCorner===null,i=!e&&n!==this.previousMenuCorner;t&&(i||e&&n==="END")&&(this.bitwiseCorner=this.bitwiseCorner^l.RIGHT,this.mdcFoundation.flipCornerHorizontally(),this.previousMenuCorner=n)}})],h.prototype,"menuCorner",void 0);o.__decorate([a.e({type:String}),E.observer(function(n){if(this.mdcFoundation&&n){let t=Z[n];this.menuCorner==="END"&&(t=t^l.RIGHT),this.bitwiseCorner=t}})],h.prototype,"corner",void 0);o.__decorate([v.t()],h.prototype,"styleTop",void 0);o.__decorate([v.t()],h.prototype,"styleLeft",void 0);o.__decorate([v.t()],h.prototype,"styleRight",void 0);o.__decorate([v.t()],h.prototype,"styleBottom",void 0);o.__decorate([v.t()],h.prototype,"styleMaxHeight",void 0);o.__decorate([v.t()],h.prototype,"styleTransformOrigin",void 0);/**
636
85
  * @license
637
86
  * Copyright 2021 Google LLC
638
87
  * SPDX-LIcense-Identifier: Apache-2.0
639
- */
640
- const rt = V`.mdc-menu-surface{display:none;position:absolute;box-sizing:border-box;max-width:calc(100vw - 32px);max-width:var(--mdc-menu-max-width, calc(100vw - 32px));max-height:calc(100vh - 32px);max-height:var(--mdc-menu-max-height, calc(100vh - 32px));margin:0;padding:0;transform:scale(1);transform-origin:top left;opacity:0;overflow:auto;will-change:transform,opacity;z-index:8;transition:opacity .03s linear,transform .12s cubic-bezier(0, 0, 0.2, 1),height 250ms cubic-bezier(0, 0, 0.2, 1);box-shadow:0px 5px 5px -3px rgba(0, 0, 0, 0.2),0px 8px 10px 1px rgba(0, 0, 0, 0.14),0px 3px 14px 2px rgba(0,0,0,.12);background-color:#fff;background-color:var(--mdc-theme-surface, #fff);color:#000;color:var(--mdc-theme-on-surface, #000);border-radius:4px;border-radius:var(--mdc-shape-medium, 4px);transform-origin-left:top left;transform-origin-right:top right}.mdc-menu-surface:focus{outline:none}.mdc-menu-surface--animating-open{display:inline-block;transform:scale(0.8);opacity:0}.mdc-menu-surface--open{display:inline-block;transform:scale(1);opacity:1}.mdc-menu-surface--animating-closed{display:inline-block;opacity:0;transition:opacity .075s linear}[dir=rtl] .mdc-menu-surface,.mdc-menu-surface[dir=rtl]{transform-origin-left:top right;transform-origin-right:top left}.mdc-menu-surface--anchor{position:relative;overflow:visible}.mdc-menu-surface--fixed{position:fixed}.mdc-menu-surface--fullwidth{width:100%}:host(:not([open])){display:none}.mdc-menu-surface{z-index:8;z-index:var(--mdc-menu-z-index, 8);min-width:112px;min-width:var(--mdc-menu-min-width, 112px)}`;
641
- /**
88
+ */const J=A.i`.mdc-menu-surface{display:none;position:absolute;box-sizing:border-box;max-width:calc(100vw - 32px);max-width:var(--mdc-menu-max-width, calc(100vw - 32px));max-height:calc(100vh - 32px);max-height:var(--mdc-menu-max-height, calc(100vh - 32px));margin:0;padding:0;transform:scale(1);transform-origin:top left;opacity:0;overflow:auto;will-change:transform,opacity;z-index:8;transition:opacity .03s linear,transform .12s cubic-bezier(0, 0, 0.2, 1),height 250ms cubic-bezier(0, 0, 0.2, 1);box-shadow:0px 5px 5px -3px rgba(0, 0, 0, 0.2),0px 8px 10px 1px rgba(0, 0, 0, 0.14),0px 3px 14px 2px rgba(0,0,0,.12);background-color:#fff;background-color:var(--mdc-theme-surface, #fff);color:#000;color:var(--mdc-theme-on-surface, #000);border-radius:4px;border-radius:var(--mdc-shape-medium, 4px);transform-origin-left:top left;transform-origin-right:top right}.mdc-menu-surface:focus{outline:none}.mdc-menu-surface--animating-open{display:inline-block;transform:scale(0.8);opacity:0}.mdc-menu-surface--open{display:inline-block;transform:scale(1);opacity:1}.mdc-menu-surface--animating-closed{display:inline-block;opacity:0;transition:opacity .075s linear}[dir=rtl] .mdc-menu-surface,.mdc-menu-surface[dir=rtl]{transform-origin-left:top right;transform-origin-right:top left}.mdc-menu-surface--anchor{position:relative;overflow:visible}.mdc-menu-surface--fixed{position:fixed}.mdc-menu-surface--fullwidth{width:100%}:host(:not([open])){display:none}.mdc-menu-surface{z-index:8;z-index:var(--mdc-menu-z-index, 8);min-width:112px;min-width:var(--mdc-menu-min-width, 112px)}`;/**
642
89
  * @license
643
90
  * Copyright 2020 Google LLC
644
91
  * SPDX-License-Identifier: Apache-2.0
645
- */
646
- let z = class extends u {
647
- };
648
- z.styles = [rt];
649
- z = o([
650
- K("mwc-menu-surface")
651
- ], z);
652
- /**
92
+ */let z=class extends h{};z.styles=[J];z=o.__decorate([A.e("mwc-menu-surface")],z);/**
653
93
  * @license
654
94
  * Copyright 2018 Google Inc.
655
95
  *
@@ -670,25 +110,7 @@ z = o([
670
110
  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
671
111
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
672
112
  * THE SOFTWARE.
673
- */
674
- var H = {
675
- MENU_SELECTED_LIST_ITEM: "mdc-menu-item--selected",
676
- MENU_SELECTION_GROUP: "mdc-menu__selection-group",
677
- ROOT: "mdc-menu"
678
- }, v = {
679
- ARIA_CHECKED_ATTR: "aria-checked",
680
- ARIA_DISABLED_ATTR: "aria-disabled",
681
- CHECKBOX_SELECTOR: 'input[type="checkbox"]',
682
- LIST_SELECTOR: ".mdc-list,.mdc-deprecated-list",
683
- SELECTED_EVENT: "MDCMenu:selected",
684
- SKIP_RESTORE_FOCUS: "data-menu-item-skip-restore-focus"
685
- }, at = {
686
- FOCUS_ROOT_INDEX: -1
687
- }, C;
688
- (function(n) {
689
- n[n.NONE = 0] = "NONE", n[n.LIST_ROOT = 1] = "LIST_ROOT", n[n.FIRST_ITEM = 2] = "FIRST_ITEM", n[n.LAST_ITEM = 3] = "LAST_ITEM";
690
- })(C || (C = {}));
691
- /**
113
+ */var H={MENU_SELECTED_LIST_ITEM:"mdc-menu-item--selected",MENU_SELECTION_GROUP:"mdc-menu__selection-group",ROOT:"mdc-menu"},x={ARIA_CHECKED_ATTR:"aria-checked",ARIA_DISABLED_ATTR:"aria-disabled",CHECKBOX_SELECTOR:'input[type="checkbox"]',LIST_SELECTOR:".mdc-list,.mdc-deprecated-list",SELECTED_EVENT:"MDCMenu:selected",SKIP_RESTORE_FOCUS:"data-menu-item-skip-restore-focus"},ee={FOCUS_ROOT_INDEX:-1},b;(function(n){n[n.NONE=0]="NONE",n[n.LIST_ROOT=1]="LIST_ROOT",n[n.FIRST_ITEM=2]="FIRST_ITEM",n[n.LAST_ITEM=3]="LAST_ITEM"})(b||(b={}));/**
692
114
  * @license
693
115
  * Copyright 2018 Google Inc.
694
116
  *
@@ -709,20 +131,7 @@ var H = {
709
131
  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
710
132
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
711
133
  * THE SOFTWARE.
712
- */
713
- var O, y, d = {
714
- LIST_ITEM_ACTIVATED_CLASS: "mdc-list-item--activated",
715
- LIST_ITEM_CLASS: "mdc-list-item",
716
- LIST_ITEM_DISABLED_CLASS: "mdc-list-item--disabled",
717
- LIST_ITEM_SELECTED_CLASS: "mdc-list-item--selected",
718
- LIST_ITEM_TEXT_CLASS: "mdc-list-item__text",
719
- LIST_ITEM_PRIMARY_TEXT_CLASS: "mdc-list-item__primary-text",
720
- ROOT: "mdc-list"
721
- };
722
- O = {}, O["" + d.LIST_ITEM_ACTIVATED_CLASS] = "mdc-list-item--activated", O["" + d.LIST_ITEM_CLASS] = "mdc-list-item", O["" + d.LIST_ITEM_DISABLED_CLASS] = "mdc-list-item--disabled", O["" + d.LIST_ITEM_SELECTED_CLASS] = "mdc-list-item--selected", O["" + d.LIST_ITEM_PRIMARY_TEXT_CLASS] = "mdc-list-item__primary-text", O["" + d.ROOT] = "mdc-list";
723
- var x = (y = {}, y["" + d.LIST_ITEM_ACTIVATED_CLASS] = "mdc-deprecated-list-item--activated", y["" + d.LIST_ITEM_CLASS] = "mdc-deprecated-list-item", y["" + d.LIST_ITEM_DISABLED_CLASS] = "mdc-deprecated-list-item--disabled", y["" + d.LIST_ITEM_SELECTED_CLASS] = "mdc-deprecated-list-item--selected", y["" + d.LIST_ITEM_TEXT_CLASS] = "mdc-deprecated-list-item__text", y["" + d.LIST_ITEM_PRIMARY_TEXT_CLASS] = "mdc-deprecated-list-item__primary-text", y["" + d.ROOT] = "mdc-deprecated-list", y);
724
- "" + d.LIST_ITEM_CLASS + d.LIST_ITEM_CLASS + x[d.LIST_ITEM_CLASS] + x[d.LIST_ITEM_CLASS], "" + d.LIST_ITEM_CLASS + d.LIST_ITEM_CLASS + d.LIST_ITEM_CLASS + d.LIST_ITEM_CLASS + x[d.LIST_ITEM_CLASS] + x[d.LIST_ITEM_CLASS] + x[d.LIST_ITEM_CLASS] + x[d.LIST_ITEM_CLASS];
725
- /**
134
+ */var O,g,d={LIST_ITEM_ACTIVATED_CLASS:"mdc-list-item--activated",LIST_ITEM_CLASS:"mdc-list-item",LIST_ITEM_DISABLED_CLASS:"mdc-list-item--disabled",LIST_ITEM_SELECTED_CLASS:"mdc-list-item--selected",LIST_ITEM_TEXT_CLASS:"mdc-list-item__text",LIST_ITEM_PRIMARY_TEXT_CLASS:"mdc-list-item__primary-text",ROOT:"mdc-list"};O={},O[""+d.LIST_ITEM_ACTIVATED_CLASS]="mdc-list-item--activated",O[""+d.LIST_ITEM_CLASS]="mdc-list-item",O[""+d.LIST_ITEM_DISABLED_CLASS]="mdc-list-item--disabled",O[""+d.LIST_ITEM_SELECTED_CLASS]="mdc-list-item--selected",O[""+d.LIST_ITEM_PRIMARY_TEXT_CLASS]="mdc-list-item__primary-text",O[""+d.ROOT]="mdc-list";var R=(g={},g[""+d.LIST_ITEM_ACTIVATED_CLASS]="mdc-deprecated-list-item--activated",g[""+d.LIST_ITEM_CLASS]="mdc-deprecated-list-item",g[""+d.LIST_ITEM_DISABLED_CLASS]="mdc-deprecated-list-item--disabled",g[""+d.LIST_ITEM_SELECTED_CLASS]="mdc-deprecated-list-item--selected",g[""+d.LIST_ITEM_TEXT_CLASS]="mdc-deprecated-list-item__text",g[""+d.LIST_ITEM_PRIMARY_TEXT_CLASS]="mdc-deprecated-list-item__primary-text",g[""+d.ROOT]="mdc-deprecated-list",g);""+d.LIST_ITEM_CLASS+d.LIST_ITEM_CLASS+R[d.LIST_ITEM_CLASS]+R[d.LIST_ITEM_CLASS],""+d.LIST_ITEM_CLASS+d.LIST_ITEM_CLASS+d.LIST_ITEM_CLASS+d.LIST_ITEM_CLASS+R[d.LIST_ITEM_CLASS]+R[d.LIST_ITEM_CLASS]+R[d.LIST_ITEM_CLASS]+R[d.LIST_ITEM_CLASS];/**
726
135
  * @license
727
136
  * Copyright 2018 Google Inc.
728
137
  *
@@ -743,158 +152,11 @@ var x = (y = {}, y["" + d.LIST_ITEM_ACTIVATED_CLASS] = "mdc-deprecated-list-item
743
152
  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
744
153
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
745
154
  * THE SOFTWARE.
746
- */
747
- var dt = (
748
- /** @class */
749
- function(n) {
750
- U(e, n);
751
- function e(t) {
752
- var i = n.call(this, B(B({}, e.defaultAdapter), t)) || this;
753
- return i.closeAnimationEndTimerId = 0, i.defaultFocusState = C.LIST_ROOT, i.selectedIndex = -1, i;
754
- }
755
- return Object.defineProperty(e, "cssClasses", {
756
- get: function() {
757
- return H;
758
- },
759
- enumerable: !1,
760
- configurable: !0
761
- }), Object.defineProperty(e, "strings", {
762
- get: function() {
763
- return v;
764
- },
765
- enumerable: !1,
766
- configurable: !0
767
- }), Object.defineProperty(e, "numbers", {
768
- get: function() {
769
- return at;
770
- },
771
- enumerable: !1,
772
- configurable: !0
773
- }), Object.defineProperty(e, "defaultAdapter", {
774
- /**
775
- * @see {@link MDCMenuAdapter} for typing information on parameters and return types.
776
- */
777
- get: function() {
778
- return {
779
- addClassToElementAtIndex: function() {
780
- },
781
- removeClassFromElementAtIndex: function() {
782
- },
783
- addAttributeToElementAtIndex: function() {
784
- },
785
- removeAttributeFromElementAtIndex: function() {
786
- },
787
- getAttributeFromElementAtIndex: function() {
788
- return null;
789
- },
790
- elementContainsClass: function() {
791
- return !1;
792
- },
793
- closeSurface: function() {
794
- },
795
- getElementIndex: function() {
796
- return -1;
797
- },
798
- notifySelected: function() {
799
- },
800
- getMenuItemCount: function() {
801
- return 0;
802
- },
803
- focusItemAtIndex: function() {
804
- },
805
- focusListRoot: function() {
806
- },
807
- getSelectedSiblingOfItemAtIndex: function() {
808
- return -1;
809
- },
810
- isSelectableItemAtIndex: function() {
811
- return !1;
812
- }
813
- };
814
- },
815
- enumerable: !1,
816
- configurable: !0
817
- }), e.prototype.destroy = function() {
818
- this.closeAnimationEndTimerId && clearTimeout(this.closeAnimationEndTimerId), this.adapter.closeSurface();
819
- }, e.prototype.handleKeydown = function(t) {
820
- var i = t.key, s = t.keyCode, r = i === "Tab" || s === 9;
821
- r && this.adapter.closeSurface(
822
- /** skipRestoreFocus */
823
- !0
824
- );
825
- }, e.prototype.handleItemAction = function(t) {
826
- var i = this, s = this.adapter.getElementIndex(t);
827
- if (!(s < 0)) {
828
- this.adapter.notifySelected({ index: s });
829
- var r = this.adapter.getAttributeFromElementAtIndex(s, v.SKIP_RESTORE_FOCUS) === "true";
830
- this.adapter.closeSurface(r), this.closeAnimationEndTimerId = setTimeout(function() {
831
- var l = i.adapter.getElementIndex(t);
832
- l >= 0 && i.adapter.isSelectableItemAtIndex(l) && i.setSelectedIndex(l);
833
- }, X.numbers.TRANSITION_CLOSE_DURATION);
834
- }
835
- }, e.prototype.handleMenuSurfaceOpened = function() {
836
- switch (this.defaultFocusState) {
837
- case C.FIRST_ITEM:
838
- this.adapter.focusItemAtIndex(0);
839
- break;
840
- case C.LAST_ITEM:
841
- this.adapter.focusItemAtIndex(this.adapter.getMenuItemCount() - 1);
842
- break;
843
- case C.NONE:
844
- break;
845
- default:
846
- this.adapter.focusListRoot();
847
- break;
848
- }
849
- }, e.prototype.setDefaultFocusState = function(t) {
850
- this.defaultFocusState = t;
851
- }, e.prototype.getSelectedIndex = function() {
852
- return this.selectedIndex;
853
- }, e.prototype.setSelectedIndex = function(t) {
854
- if (this.validatedIndex(t), !this.adapter.isSelectableItemAtIndex(t))
855
- throw new Error("MDCMenuFoundation: No selection group at specified index.");
856
- var i = this.adapter.getSelectedSiblingOfItemAtIndex(t);
857
- i >= 0 && (this.adapter.removeAttributeFromElementAtIndex(i, v.ARIA_CHECKED_ATTR), this.adapter.removeClassFromElementAtIndex(i, H.MENU_SELECTED_LIST_ITEM)), this.adapter.addClassToElementAtIndex(t, H.MENU_SELECTED_LIST_ITEM), this.adapter.addAttributeToElementAtIndex(t, v.ARIA_CHECKED_ATTR, "true"), this.selectedIndex = t;
858
- }, e.prototype.setEnabled = function(t, i) {
859
- this.validatedIndex(t), i ? (this.adapter.removeClassFromElementAtIndex(t, d.LIST_ITEM_DISABLED_CLASS), this.adapter.addAttributeToElementAtIndex(t, v.ARIA_DISABLED_ATTR, "false")) : (this.adapter.addClassToElementAtIndex(t, d.LIST_ITEM_DISABLED_CLASS), this.adapter.addAttributeToElementAtIndex(t, v.ARIA_DISABLED_ATTR, "true"));
860
- }, e.prototype.validatedIndex = function(t) {
861
- var i = this.adapter.getMenuItemCount(), s = t >= 0 && t < i;
862
- if (!s)
863
- throw new Error("MDCMenuFoundation: No list item at specified index.");
864
- }, e;
865
- }(W)
866
- );
867
- const lt = dt;
868
- /**
155
+ */var te=function(n){o.__extends(t,n);function t(e){var i=n.call(this,o.__assign(o.__assign({},t.defaultAdapter),e))||this;return i.closeAnimationEndTimerId=0,i.defaultFocusState=b.LIST_ROOT,i.selectedIndex=-1,i}return Object.defineProperty(t,"cssClasses",{get:function(){return H},enumerable:!1,configurable:!0}),Object.defineProperty(t,"strings",{get:function(){return x},enumerable:!1,configurable:!0}),Object.defineProperty(t,"numbers",{get:function(){return ee},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{addClassToElementAtIndex:function(){},removeClassFromElementAtIndex:function(){},addAttributeToElementAtIndex:function(){},removeAttributeFromElementAtIndex:function(){},getAttributeFromElementAtIndex:function(){return null},elementContainsClass:function(){return!1},closeSurface:function(){},getElementIndex:function(){return-1},notifySelected:function(){},getMenuItemCount:function(){return 0},focusItemAtIndex:function(){},focusListRoot:function(){},getSelectedSiblingOfItemAtIndex:function(){return-1},isSelectableItemAtIndex:function(){return!1}}},enumerable:!1,configurable:!0}),t.prototype.destroy=function(){this.closeAnimationEndTimerId&&clearTimeout(this.closeAnimationEndTimerId),this.adapter.closeSurface()},t.prototype.handleKeydown=function(e){var i=e.key,s=e.keyCode,r=i==="Tab"||s===9;r&&this.adapter.closeSurface(!0)},t.prototype.handleItemAction=function(e){var i=this,s=this.adapter.getElementIndex(e);if(!(s<0)){this.adapter.notifySelected({index:s});var r=this.adapter.getAttributeFromElementAtIndex(s,x.SKIP_RESTORE_FOCUS)==="true";this.adapter.closeSurface(r),this.closeAnimationEndTimerId=setTimeout(function(){var c=i.adapter.getElementIndex(e);c>=0&&i.adapter.isSelectableItemAtIndex(c)&&i.setSelectedIndex(c)},V.numbers.TRANSITION_CLOSE_DURATION)}},t.prototype.handleMenuSurfaceOpened=function(){switch(this.defaultFocusState){case b.FIRST_ITEM:this.adapter.focusItemAtIndex(0);break;case b.LAST_ITEM:this.adapter.focusItemAtIndex(this.adapter.getMenuItemCount()-1);break;case b.NONE:break;default:this.adapter.focusListRoot();break}},t.prototype.setDefaultFocusState=function(e){this.defaultFocusState=e},t.prototype.getSelectedIndex=function(){return this.selectedIndex},t.prototype.setSelectedIndex=function(e){if(this.validatedIndex(e),!this.adapter.isSelectableItemAtIndex(e))throw new Error("MDCMenuFoundation: No selection group at specified index.");var i=this.adapter.getSelectedSiblingOfItemAtIndex(e);i>=0&&(this.adapter.removeAttributeFromElementAtIndex(i,x.ARIA_CHECKED_ATTR),this.adapter.removeClassFromElementAtIndex(i,H.MENU_SELECTED_LIST_ITEM)),this.adapter.addClassToElementAtIndex(e,H.MENU_SELECTED_LIST_ITEM),this.adapter.addAttributeToElementAtIndex(e,x.ARIA_CHECKED_ATTR,"true"),this.selectedIndex=e},t.prototype.setEnabled=function(e,i){this.validatedIndex(e),i?(this.adapter.removeClassFromElementAtIndex(e,d.LIST_ITEM_DISABLED_CLASS),this.adapter.addAttributeToElementAtIndex(e,x.ARIA_DISABLED_ATTR,"false")):(this.adapter.addClassToElementAtIndex(e,d.LIST_ITEM_DISABLED_CLASS),this.adapter.addAttributeToElementAtIndex(e,x.ARIA_DISABLED_ATTR,"true"))},t.prototype.validatedIndex=function(e){var i=this.adapter.getMenuItemCount(),s=e>=0&&e<i;if(!s)throw new Error("MDCMenuFoundation: No list item at specified index.")},t}(q);const ie=te;/**
869
156
  * @license
870
157
  * Copyright 2020 Google LLC
871
158
  * SPDX-License-Identifier: Apache-2.0
872
- */
873
- class h extends j {
874
- constructor() {
875
- super(...arguments), this.mdcFoundationClass = lt, this.listElement_ = null, this.anchor = null, this.open = !1, this.quick = !1, this.wrapFocus = !1, this.innerRole = "menu", this.innerAriaLabel = null, this.corner = "TOP_START", this.x = null, this.y = null, this.absolute = !1, this.multi = !1, this.activatable = !1, this.fixed = !1, this.forceGroupSelection = !1, this.fullwidth = !1, this.menuCorner = "START", this.stayOpenOnBodyClick = !1, this.defaultFocus = "LIST_ROOT", this._listUpdateComplete = null;
876
- }
877
- get listElement() {
878
- return this.listElement_ ? this.listElement_ : (this.listElement_ = this.renderRoot.querySelector("mwc-list"), this.listElement_);
879
- }
880
- get items() {
881
- const e = this.listElement;
882
- return e ? e.items : [];
883
- }
884
- get index() {
885
- const e = this.listElement;
886
- return e ? e.index : -1;
887
- }
888
- get selected() {
889
- const e = this.listElement;
890
- return e ? e.selected : null;
891
- }
892
- render() {
893
- return this.renderSurface();
894
- }
895
- renderSurface() {
896
- const e = this.getSurfaceClasses();
897
- return F`
159
+ */class u extends U.BaseElement{constructor(){super(...arguments),this.mdcFoundationClass=ie,this.listElement_=null,this.anchor=null,this.open=!1,this.quick=!1,this.wrapFocus=!1,this.innerRole="menu",this.innerAriaLabel=null,this.corner="TOP_START",this.x=null,this.y=null,this.absolute=!1,this.multi=!1,this.activatable=!1,this.fixed=!1,this.forceGroupSelection=!1,this.fullwidth=!1,this.menuCorner="START",this.stayOpenOnBodyClick=!1,this.defaultFocus="LIST_ROOT",this._listUpdateComplete=null}get listElement(){return this.listElement_?this.listElement_:(this.listElement_=this.renderRoot.querySelector("mwc-list"),this.listElement_)}get items(){const t=this.listElement;return t?t.items:[]}get index(){const t=this.listElement;return t?t.index:-1}get selected(){const t=this.listElement;return t?t.selected:null}render(){return this.renderSurface()}renderSurface(){const t=this.getSurfaceClasses();return A.y`
898
160
  <mwc-menu-surface
899
161
  ?hidden=${!this.open}
900
162
  .anchor=${this.anchor}
@@ -908,238 +170,21 @@ class h extends j {
908
170
  .fullwidth=${this.fullwidth}
909
171
  .menuCorner=${this.menuCorner}
910
172
  ?stayOpenOnBodyClick=${this.stayOpenOnBodyClick}
911
- class=${P(e)}
173
+ class=${P.o(t)}
912
174
  @closed=${this.onClosed}
913
175
  @opened=${this.onOpened}
914
176
  @keydown=${this.onKeydown}>
915
177
  ${this.renderList()}
916
- </mwc-menu-surface>`;
917
- }
918
- getSurfaceClasses() {
919
- return {
920
- "mdc-menu": !0,
921
- "mdc-menu-surface": !0
922
- };
923
- }
924
- renderList() {
925
- const e = this.innerRole === "menu" ? "menuitem" : "option", t = this.renderListClasses();
926
- return F`
178
+ </mwc-menu-surface>`}getSurfaceClasses(){return{"mdc-menu":!0,"mdc-menu-surface":!0}}renderList(){const t=this.innerRole==="menu"?"menuitem":"option",e=this.renderListClasses();return A.y`
927
179
  <mwc-list
928
180
  rootTabbable
929
181
  .innerAriaLabel=${this.innerAriaLabel}
930
182
  .innerRole=${this.innerRole}
931
183
  .multi=${this.multi}
932
- class=${P(t)}
933
- .itemRoles=${e}
184
+ class=${P.o(e)}
185
+ .itemRoles=${t}
934
186
  .wrapFocus=${this.wrapFocus}
935
187
  .activatable=${this.activatable}
936
188
  @action=${this.onAction}>
937
189
  <slot></slot>
938
- </mwc-list>`;
939
- }
940
- renderListClasses() {
941
- return {
942
- "mdc-deprecated-list": !0
943
- };
944
- }
945
- createAdapter() {
946
- return {
947
- addClassToElementAtIndex: (e, t) => {
948
- const i = this.listElement;
949
- if (!i)
950
- return;
951
- const s = i.items[e];
952
- s && (t === "mdc-menu-item--selected" ? this.forceGroupSelection && !s.selected && i.toggle(e, !0) : s.classList.add(t));
953
- },
954
- removeClassFromElementAtIndex: (e, t) => {
955
- const i = this.listElement;
956
- if (!i)
957
- return;
958
- const s = i.items[e];
959
- s && (t === "mdc-menu-item--selected" ? s.selected && i.toggle(e, !1) : s.classList.remove(t));
960
- },
961
- addAttributeToElementAtIndex: (e, t, i) => {
962
- const s = this.listElement;
963
- if (!s)
964
- return;
965
- const r = s.items[e];
966
- r && r.setAttribute(t, i);
967
- },
968
- removeAttributeFromElementAtIndex: (e, t) => {
969
- const i = this.listElement;
970
- if (!i)
971
- return;
972
- const s = i.items[e];
973
- s && s.removeAttribute(t);
974
- },
975
- getAttributeFromElementAtIndex: (e, t) => {
976
- const i = this.listElement;
977
- if (!i)
978
- return null;
979
- const s = i.items[e];
980
- return s ? s.getAttribute(t) : null;
981
- },
982
- elementContainsClass: (e, t) => e.classList.contains(t),
983
- closeSurface: () => {
984
- this.open = !1;
985
- },
986
- getElementIndex: (e) => {
987
- const t = this.listElement;
988
- return t ? t.items.indexOf(e) : -1;
989
- },
990
- notifySelected: () => {
991
- },
992
- getMenuItemCount: () => {
993
- const e = this.listElement;
994
- return e ? e.items.length : 0;
995
- },
996
- focusItemAtIndex: (e) => {
997
- const t = this.listElement;
998
- if (!t)
999
- return;
1000
- const i = t.items[e];
1001
- i && i.focus();
1002
- },
1003
- focusListRoot: () => {
1004
- this.listElement && this.listElement.focus();
1005
- },
1006
- getSelectedSiblingOfItemAtIndex: (e) => {
1007
- const t = this.listElement;
1008
- if (!t)
1009
- return -1;
1010
- const i = t.items[e];
1011
- if (!i || !i.group)
1012
- return -1;
1013
- for (let s = 0; s < t.items.length; s++) {
1014
- if (s === e)
1015
- continue;
1016
- const r = t.items[s];
1017
- if (r.selected && r.group === i.group)
1018
- return s;
1019
- }
1020
- return -1;
1021
- },
1022
- isSelectableItemAtIndex: (e) => {
1023
- const t = this.listElement;
1024
- if (!t)
1025
- return !1;
1026
- const i = t.items[e];
1027
- return i ? i.hasAttribute("group") : !1;
1028
- }
1029
- };
1030
- }
1031
- onKeydown(e) {
1032
- this.mdcFoundation && this.mdcFoundation.handleKeydown(e);
1033
- }
1034
- onAction(e) {
1035
- const t = this.listElement;
1036
- if (this.mdcFoundation && t) {
1037
- const i = e.detail.index, s = t.items[i];
1038
- s && this.mdcFoundation.handleItemAction(s);
1039
- }
1040
- }
1041
- onOpened() {
1042
- this.open = !0, this.mdcFoundation && this.mdcFoundation.handleMenuSurfaceOpened();
1043
- }
1044
- onClosed() {
1045
- this.open = !1;
1046
- }
1047
- // tslint:disable:ban-ts-ignore
1048
- async getUpdateComplete() {
1049
- return await this._listUpdateComplete, await super.getUpdateComplete();
1050
- }
1051
- // tslint:enable:ban-ts-ignore
1052
- async firstUpdated() {
1053
- super.firstUpdated();
1054
- const e = this.listElement;
1055
- e && (this._listUpdateComplete = e.updateComplete, await this._listUpdateComplete);
1056
- }
1057
- select(e) {
1058
- const t = this.listElement;
1059
- t && t.select(e);
1060
- }
1061
- close() {
1062
- this.open = !1;
1063
- }
1064
- show() {
1065
- this.open = !0;
1066
- }
1067
- getFocusedItemIndex() {
1068
- const e = this.listElement;
1069
- return e ? e.getFocusedItemIndex() : -1;
1070
- }
1071
- focusItemAtIndex(e) {
1072
- const t = this.listElement;
1073
- t && t.focusItemAtIndex(e);
1074
- }
1075
- layout(e = !0) {
1076
- const t = this.listElement;
1077
- t && t.layout(e);
1078
- }
1079
- }
1080
- o([
1081
- D(".mdc-menu")
1082
- ], h.prototype, "mdcRoot", void 0);
1083
- o([
1084
- D("slot")
1085
- ], h.prototype, "slotElement", void 0);
1086
- o([
1087
- a({ type: Object })
1088
- ], h.prototype, "anchor", void 0);
1089
- o([
1090
- a({ type: Boolean, reflect: !0 })
1091
- ], h.prototype, "open", void 0);
1092
- o([
1093
- a({ type: Boolean })
1094
- ], h.prototype, "quick", void 0);
1095
- o([
1096
- a({ type: Boolean })
1097
- ], h.prototype, "wrapFocus", void 0);
1098
- o([
1099
- a({ type: String })
1100
- ], h.prototype, "innerRole", void 0);
1101
- o([
1102
- a({ type: String })
1103
- ], h.prototype, "innerAriaLabel", void 0);
1104
- o([
1105
- a({ type: String })
1106
- ], h.prototype, "corner", void 0);
1107
- o([
1108
- a({ type: Number })
1109
- ], h.prototype, "x", void 0);
1110
- o([
1111
- a({ type: Number })
1112
- ], h.prototype, "y", void 0);
1113
- o([
1114
- a({ type: Boolean })
1115
- ], h.prototype, "absolute", void 0);
1116
- o([
1117
- a({ type: Boolean })
1118
- ], h.prototype, "multi", void 0);
1119
- o([
1120
- a({ type: Boolean })
1121
- ], h.prototype, "activatable", void 0);
1122
- o([
1123
- a({ type: Boolean })
1124
- ], h.prototype, "fixed", void 0);
1125
- o([
1126
- a({ type: Boolean })
1127
- ], h.prototype, "forceGroupSelection", void 0);
1128
- o([
1129
- a({ type: Boolean })
1130
- ], h.prototype, "fullwidth", void 0);
1131
- o([
1132
- a({ type: String })
1133
- ], h.prototype, "menuCorner", void 0);
1134
- o([
1135
- a({ type: Boolean })
1136
- ], h.prototype, "stayOpenOnBodyClick", void 0);
1137
- o([
1138
- a({ type: String }),
1139
- g(function(n) {
1140
- this.mdcFoundation && this.mdcFoundation.setDefaultFocusState(C[n]);
1141
- })
1142
- ], h.prototype, "defaultFocus", void 0);
1143
- export {
1144
- h as M
1145
- };
190
+ </mwc-list>`}renderListClasses(){return{"mdc-deprecated-list":!0}}createAdapter(){return{addClassToElementAtIndex:(t,e)=>{const i=this.listElement;if(!i)return;const s=i.items[t];s&&(e==="mdc-menu-item--selected"?this.forceGroupSelection&&!s.selected&&i.toggle(t,!0):s.classList.add(e))},removeClassFromElementAtIndex:(t,e)=>{const i=this.listElement;if(!i)return;const s=i.items[t];s&&(e==="mdc-menu-item--selected"?s.selected&&i.toggle(t,!1):s.classList.remove(e))},addAttributeToElementAtIndex:(t,e,i)=>{const s=this.listElement;if(!s)return;const r=s.items[t];r&&r.setAttribute(e,i)},removeAttributeFromElementAtIndex:(t,e)=>{const i=this.listElement;if(!i)return;const s=i.items[t];s&&s.removeAttribute(e)},getAttributeFromElementAtIndex:(t,e)=>{const i=this.listElement;if(!i)return null;const s=i.items[t];return s?s.getAttribute(e):null},elementContainsClass:(t,e)=>t.classList.contains(e),closeSurface:()=>{this.open=!1},getElementIndex:t=>{const e=this.listElement;return e?e.items.indexOf(t):-1},notifySelected:()=>{},getMenuItemCount:()=>{const t=this.listElement;return t?t.items.length:0},focusItemAtIndex:t=>{const e=this.listElement;if(!e)return;const i=e.items[t];i&&i.focus()},focusListRoot:()=>{this.listElement&&this.listElement.focus()},getSelectedSiblingOfItemAtIndex:t=>{const e=this.listElement;if(!e)return-1;const i=e.items[t];if(!i||!i.group)return-1;for(let s=0;s<e.items.length;s++){if(s===t)continue;const r=e.items[s];if(r.selected&&r.group===i.group)return s}return-1},isSelectableItemAtIndex:t=>{const e=this.listElement;if(!e)return!1;const i=e.items[t];return i?i.hasAttribute("group"):!1}}}onKeydown(t){this.mdcFoundation&&this.mdcFoundation.handleKeydown(t)}onAction(t){const e=this.listElement;if(this.mdcFoundation&&e){const i=t.detail.index,s=e.items[i];s&&this.mdcFoundation.handleItemAction(s)}}onOpened(){this.open=!0,this.mdcFoundation&&this.mdcFoundation.handleMenuSurfaceOpened()}onClosed(){this.open=!1}async getUpdateComplete(){return await this._listUpdateComplete,await super.getUpdateComplete()}async firstUpdated(){super.firstUpdated();const t=this.listElement;t&&(this._listUpdateComplete=t.updateComplete,await this._listUpdateComplete)}select(t){const e=this.listElement;e&&e.select(t)}close(){this.open=!1}show(){this.open=!0}getFocusedItemIndex(){const t=this.listElement;return t?t.getFocusedItemIndex():-1}focusItemAtIndex(t){const e=this.listElement;e&&e.focusItemAtIndex(t)}layout(t=!0){const e=this.listElement;e&&e.layout(t)}}o.__decorate([F.i(".mdc-menu")],u.prototype,"mdcRoot",void 0);o.__decorate([F.i("slot")],u.prototype,"slotElement",void 0);o.__decorate([a.e({type:Object})],u.prototype,"anchor",void 0);o.__decorate([a.e({type:Boolean,reflect:!0})],u.prototype,"open",void 0);o.__decorate([a.e({type:Boolean})],u.prototype,"quick",void 0);o.__decorate([a.e({type:Boolean})],u.prototype,"wrapFocus",void 0);o.__decorate([a.e({type:String})],u.prototype,"innerRole",void 0);o.__decorate([a.e({type:String})],u.prototype,"innerAriaLabel",void 0);o.__decorate([a.e({type:String})],u.prototype,"corner",void 0);o.__decorate([a.e({type:Number})],u.prototype,"x",void 0);o.__decorate([a.e({type:Number})],u.prototype,"y",void 0);o.__decorate([a.e({type:Boolean})],u.prototype,"absolute",void 0);o.__decorate([a.e({type:Boolean})],u.prototype,"multi",void 0);o.__decorate([a.e({type:Boolean})],u.prototype,"activatable",void 0);o.__decorate([a.e({type:Boolean})],u.prototype,"fixed",void 0);o.__decorate([a.e({type:Boolean})],u.prototype,"forceGroupSelection",void 0);o.__decorate([a.e({type:Boolean})],u.prototype,"fullwidth",void 0);o.__decorate([a.e({type:String})],u.prototype,"menuCorner",void 0);o.__decorate([a.e({type:Boolean})],u.prototype,"stayOpenOnBodyClick",void 0);o.__decorate([a.e({type:String}),E.observer(function(n){this.mdcFoundation&&this.mdcFoundation.setDefaultFocusState(b[n])})],u.prototype,"defaultFocus",void 0);exports.MenuBase=u;