screenreader-speech-capture 0.9.0 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -0
- package/dist/cli.mjs +1 -1
- package/dist/ui/adapter-node.js +1 -1
- package/dist/ui/client/ui/_app/immutable/assets/{0.CnPCLsGJ.css → 0.DH3e8XLu.css} +1 -1
- package/dist/ui/client/ui/_app/immutable/assets/0.DH3e8XLu.css.br +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/0.DH3e8XLu.css.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/2.DSVNnDlO.css +1 -0
- package/dist/ui/client/ui/_app/immutable/assets/2.DSVNnDlO.css.br +3 -0
- package/dist/ui/client/ui/_app/immutable/assets/2.DSVNnDlO.css.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/4.DIE1qdmp.css +1 -0
- package/dist/ui/client/ui/_app/immutable/assets/4.DIE1qdmp.css.br +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/4.DIE1qdmp.css.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/5.DCMlxwLh.css +1 -0
- package/dist/ui/client/ui/_app/immutable/assets/5.DCMlxwLh.css.br +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/5.DCMlxwLh.css.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/6.C0Nhvs_m.css +1 -0
- package/dist/ui/client/ui/_app/immutable/assets/6.C0Nhvs_m.css.br +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/6.C0Nhvs_m.css.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/ExternalLink.CYXazpKA.css +1 -0
- package/dist/ui/client/ui/_app/immutable/assets/ExternalLink.CYXazpKA.css.br +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/ExternalLink.CYXazpKA.css.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/Pane.Co7gxzxw.css +1 -0
- package/dist/ui/client/ui/_app/immutable/assets/Pane.Co7gxzxw.css.br +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/Pane.Co7gxzxw.css.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/{Cba3ZwaX.js → 4R6qUa-I.js} +12 -13
- package/dist/ui/client/ui/_app/immutable/chunks/4R6qUa-I.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/4R6qUa-I.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BC9D66S_.js +2 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BC9D66S_.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BC9D66S_.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BCiTXg3M.js +138 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BCiTXg3M.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BCiTXg3M.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BGgW64O2.js +1 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BGgW64O2.js.br +2 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BGgW64O2.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/Bvlvl8SZ.js +1 -0
- package/dist/ui/client/ui/_app/immutable/chunks/Bvlvl8SZ.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/Bvlvl8SZ.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/ByQTEKOy.js +3 -0
- package/dist/ui/client/ui/_app/immutable/chunks/ByQTEKOy.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/ByQTEKOy.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/C-UVUBR9.js +3 -0
- package/dist/ui/client/ui/_app/immutable/chunks/C-UVUBR9.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/C-UVUBR9.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/C1Z3Vlq6.js +3 -0
- package/dist/ui/client/ui/_app/immutable/chunks/C1Z3Vlq6.js.br +11 -0
- package/dist/ui/client/ui/_app/immutable/chunks/C1Z3Vlq6.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/CSj31z2g.js +1 -0
- package/dist/ui/client/ui/_app/immutable/chunks/CSj31z2g.js.br +2 -0
- package/dist/ui/client/ui/_app/immutable/chunks/CSj31z2g.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/D7Lf2nU5.js +48 -0
- package/dist/ui/client/ui/_app/immutable/chunks/D7Lf2nU5.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/D7Lf2nU5.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/D8AQra8V.js +3 -0
- package/dist/ui/client/ui/_app/immutable/chunks/D8AQra8V.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/D8AQra8V.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DLBNPxq0.js +1 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DLBNPxq0.js.br +3 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DLBNPxq0.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DMXmTTni.js +1 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DMXmTTni.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DMXmTTni.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DVjfBgOA.js +1 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DVjfBgOA.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DVjfBgOA.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/EBfbaSFC.js +40 -0
- package/dist/ui/client/ui/_app/immutable/chunks/EBfbaSFC.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/EBfbaSFC.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/HjKxdHgL.js +4 -0
- package/dist/ui/client/ui/_app/immutable/chunks/HjKxdHgL.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/HjKxdHgL.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/y62iQtQV.js +1 -0
- package/dist/ui/client/ui/_app/immutable/chunks/y62iQtQV.js.br +1 -0
- package/dist/ui/client/ui/_app/immutable/chunks/y62iQtQV.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/entry/app.BRCyy_aP.js +2 -0
- package/dist/ui/client/ui/_app/immutable/entry/app.BRCyy_aP.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/entry/app.BRCyy_aP.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/entry/start.ujo8oI9U.js +2 -0
- package/dist/ui/client/ui/_app/immutable/entry/start.ujo8oI9U.js.br +5 -0
- package/dist/ui/client/ui/_app/immutable/entry/start.ujo8oI9U.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/0.CYE8I_uA.js +1 -0
- package/dist/ui/client/ui/_app/immutable/nodes/0.CYE8I_uA.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/0.CYE8I_uA.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/1.DTsysZRk.js +1 -0
- package/dist/ui/client/ui/_app/immutable/nodes/1.DTsysZRk.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/1.DTsysZRk.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/2.hev1nfuM.js +1 -0
- package/dist/ui/client/ui/_app/immutable/nodes/2.hev1nfuM.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/2.hev1nfuM.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/3.CApflji6.js +5 -0
- package/dist/ui/client/ui/_app/immutable/nodes/3.CApflji6.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/3.CApflji6.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/4.BkefkGQL.js +160 -0
- package/dist/ui/client/ui/_app/immutable/nodes/4.BkefkGQL.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/4.BkefkGQL.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/5.CDYh05RH.js +6 -0
- package/dist/ui/client/ui/_app/immutable/nodes/5.CDYh05RH.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/5.CDYh05RH.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/6.DwISzDQO.js +6 -0
- package/dist/ui/client/ui/_app/immutable/nodes/6.DwISzDQO.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/6.DwISzDQO.js.gz +0 -0
- package/dist/ui/client/ui/_app/version.json +1 -1
- package/dist/ui/client/ui/_app/version.json.br +0 -0
- package/dist/ui/client/ui/_app/version.json.gz +0 -0
- package/dist/ui/server/.vite/manifest.json +193 -10
- package/dist/ui/server/_app/immutable/assets/ExternalLink.CYXazpKA.css +1 -0
- package/dist/ui/server/_app/immutable/assets/Pane.Co7gxzxw.css +1 -0
- package/dist/ui/server/_app/immutable/assets/{_layout.CnPCLsGJ.css → _layout.DH3e8XLu.css} +1 -1
- package/dist/ui/server/_app/immutable/assets/_layout.DSVNnDlO.css +1 -0
- package/dist/ui/server/_app/immutable/assets/_page.C0Nhvs_m.css +1 -0
- package/dist/ui/server/_app/immutable/assets/_page.DCMlxwLh.css +1 -0
- package/dist/ui/server/_app/immutable/assets/_page.DIE1qdmp.css +1 -0
- package/dist/ui/server/chunks/ExternalLink.js +12 -0
- package/dist/ui/server/chunks/ExternalLink.js.map +1 -0
- package/dist/ui/server/chunks/Pane.js +13 -0
- package/dist/ui/server/chunks/Pane.js.map +1 -0
- package/dist/ui/server/chunks/composition.js +462 -120
- package/dist/ui/server/chunks/composition.js.map +1 -1
- package/dist/ui/server/chunks/config-state.js +21 -0
- package/dist/ui/server/chunks/config-state.js.map +1 -0
- package/dist/ui/server/chunks/dialog.js +592 -0
- package/dist/ui/server/chunks/dialog.js.map +1 -0
- package/dist/ui/server/chunks/filled-button.js +116 -0
- package/dist/ui/server/chunks/filled-button.js.map +1 -0
- package/dist/ui/server/chunks/icon-button.js +2 -46
- package/dist/ui/server/chunks/icon-button.js.map +1 -1
- package/dist/ui/server/chunks/icon.js +49 -0
- package/dist/ui/server/chunks/icon.js.map +1 -0
- package/dist/ui/server/chunks/index-server.js +5 -1
- package/dist/ui/server/chunks/index-server.js.map +1 -0
- package/dist/ui/server/chunks/instance.js +5 -5
- package/dist/ui/server/chunks/internal.js +1 -1
- package/dist/ui/server/chunks/navigation.js +9 -13
- package/dist/ui/server/chunks/navigation.js.map +1 -1
- package/dist/ui/server/chunks/navigation2.js +15 -0
- package/dist/ui/server/chunks/navigation2.js.map +1 -0
- package/dist/ui/server/chunks/outlined-text-field.js +11 -398
- package/dist/ui/server/chunks/outlined-text-field.js.map +1 -1
- package/dist/ui/server/chunks/paths.js +2 -0
- package/dist/ui/server/chunks/redispatch-event.js +91 -0
- package/dist/ui/server/chunks/redispatch-event.js.map +1 -0
- package/dist/ui/server/chunks/server2.js +11 -1
- package/dist/ui/server/chunks/server2.js.map +1 -1
- package/dist/ui/server/chunks/src.js +112 -3
- package/dist/ui/server/chunks/src.js.map +1 -1
- package/dist/ui/server/chunks/state.js +1 -1
- package/dist/ui/server/chunks/static-html.js +38 -0
- package/dist/ui/server/chunks/static-html.js.map +1 -0
- package/dist/ui/server/chunks/text-button.js +307 -0
- package/dist/ui/server/chunks/text-button.js.map +1 -0
- package/dist/ui/server/entries/endpoints/api/config/_server.ts.js +4 -17
- package/dist/ui/server/entries/endpoints/api/config/_server.ts.js.map +1 -1
- package/dist/ui/server/entries/endpoints/api/input/keys/_server.ts.js +14 -0
- package/dist/ui/server/entries/endpoints/api/input/keys/_server.ts.js.map +1 -0
- package/dist/ui/server/entries/endpoints/api/markers/_server.ts.js +1 -1
- package/dist/ui/server/entries/endpoints/api/speech/_server.ts.js +1 -1
- package/dist/ui/server/entries/fallbacks/error.svelte.js +1 -1
- package/dist/ui/server/entries/hooks.server.js +4 -1
- package/dist/ui/server/entries/hooks.server.js.map +1 -1
- package/dist/ui/server/entries/pages/_layout.svelte.js +5 -10
- package/dist/ui/server/entries/pages/_layout.svelte.js.map +1 -1
- package/dist/ui/server/entries/pages/_page.svelte.js +15 -597
- package/dist/ui/server/entries/pages/_page.svelte.js.map +1 -1
- package/dist/ui/server/entries/pages/settings/_page.server.ts.js +12 -0
- package/dist/ui/server/entries/pages/settings/_page.server.ts.js.map +1 -0
- package/dist/ui/server/entries/pages/settings/_page.svelte.js +3470 -70
- package/dist/ui/server/entries/pages/settings/_page.svelte.js.map +1 -1
- package/dist/ui/server/entries/pages/setup/_layout.svelte.js +51 -0
- package/dist/ui/server/entries/pages/setup/_layout.svelte.js.map +1 -0
- package/dist/ui/server/entries/pages/setup/_page.svelte.js +225 -3
- package/dist/ui/server/entries/pages/setup/_page.svelte.js.map +1 -1
- package/dist/ui/server/entries/pages/setup/instructions/_page.server.ts.js +12 -0
- package/dist/ui/server/entries/pages/setup/instructions/_page.server.ts.js.map +1 -0
- package/dist/ui/server/entries/pages/setup/instructions/_page.svelte.js +271 -0
- package/dist/ui/server/entries/pages/setup/instructions/_page.svelte.js.map +1 -0
- package/dist/ui/server/manifest-full.js +21 -5
- package/dist/ui/server/manifest.js +21 -5
- package/dist/ui/server/nodes/0.js +2 -2
- package/dist/ui/server/nodes/1.js +1 -1
- package/dist/ui/server/nodes/2.js +4 -6
- package/dist/ui/server/nodes/3.js +6 -4
- package/dist/ui/server/nodes/4.js +6 -4
- package/dist/ui/server/nodes/5.js +8 -0
- package/dist/ui/server/nodes/6.js +10 -0
- package/dist/ui/server/server.js +21 -5
- package/package.json +1 -1
- package/dist/ui/client/ui/_app/immutable/assets/0.CnPCLsGJ.css.br +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/0.CnPCLsGJ.css.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/3.CK2Biket.css +0 -1
- package/dist/ui/client/ui/_app/immutable/assets/3.CK2Biket.css.br +0 -0
- package/dist/ui/client/ui/_app/immutable/assets/3.CK2Biket.css.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/0YgL1EU2.js +0 -179
- package/dist/ui/client/ui/_app/immutable/chunks/0YgL1EU2.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/0YgL1EU2.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BYvlzyV8.js +0 -1
- package/dist/ui/client/ui/_app/immutable/chunks/BYvlzyV8.js.br +0 -2
- package/dist/ui/client/ui/_app/immutable/chunks/BYvlzyV8.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BfvDkxmG.js +0 -3
- package/dist/ui/client/ui/_app/immutable/chunks/BfvDkxmG.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/BfvDkxmG.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/Cba3ZwaX.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/Cba3ZwaX.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DErxe_FC.js +0 -3
- package/dist/ui/client/ui/_app/immutable/chunks/DErxe_FC.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/DErxe_FC.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/Dqufijaz.js +0 -1
- package/dist/ui/client/ui/_app/immutable/chunks/Dqufijaz.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/Dqufijaz.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/WpCriteK.js +0 -1
- package/dist/ui/client/ui/_app/immutable/chunks/WpCriteK.js.br +0 -1
- package/dist/ui/client/ui/_app/immutable/chunks/WpCriteK.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/wbLSPbHY.js +0 -4
- package/dist/ui/client/ui/_app/immutable/chunks/wbLSPbHY.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/chunks/wbLSPbHY.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/entry/app.B6hhDf4F.js +0 -2
- package/dist/ui/client/ui/_app/immutable/entry/app.B6hhDf4F.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/entry/app.B6hhDf4F.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/entry/start.Dluk7nQO.js +0 -2
- package/dist/ui/client/ui/_app/immutable/entry/start.Dluk7nQO.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/entry/start.Dluk7nQO.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/0.D-lhv0Us.js +0 -1
- package/dist/ui/client/ui/_app/immutable/nodes/0.D-lhv0Us.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/0.D-lhv0Us.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/1.Cs4GAsCO.js +0 -1
- package/dist/ui/client/ui/_app/immutable/nodes/1.Cs4GAsCO.js.br +0 -2
- package/dist/ui/client/ui/_app/immutable/nodes/1.Cs4GAsCO.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/2.CmuzlN_T.js +0 -52
- package/dist/ui/client/ui/_app/immutable/nodes/2.CmuzlN_T.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/2.CmuzlN_T.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/3.DMXXeBbC.js +0 -5
- package/dist/ui/client/ui/_app/immutable/nodes/3.DMXXeBbC.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/3.DMXXeBbC.js.gz +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/4.CMHCNMDn.js +0 -1
- package/dist/ui/client/ui/_app/immutable/nodes/4.CMHCNMDn.js.br +0 -0
- package/dist/ui/client/ui/_app/immutable/nodes/4.CMHCNMDn.js.gz +0 -0
- package/dist/ui/server/_app/immutable/assets/_page.CK2Biket.css +0 -1
- /package/dist/ui/client/ui/_app/immutable/assets/{2.ChCvyBVk.css → 3.ChCvyBVk.css} +0 -0
- /package/dist/ui/client/ui/_app/immutable/assets/{2.ChCvyBVk.css.br → 3.ChCvyBVk.css.br} +0 -0
- /package/dist/ui/client/ui/_app/immutable/assets/{2.ChCvyBVk.css.gz → 3.ChCvyBVk.css.gz} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"_page.svelte.js","names":["sharedStyles","sharedElevationStyles","filledStyles","customElement","$.derived","$.attr","$.escape","$.ensure_array_like","$.attr","$.stringify","$.escape"],"sources":["../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/internal/filled-button.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/internal/filled-styles.cssresult.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/button/filled-button.js","../../../../../src/lib/components/TcpPortSetting/TcpPortSetting.svelte","../../../../../src/lib/components/ThemeSetting/ThemeSetting.svelte","../../../../../src/routes/settings/+page.svelte"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport '../../elevation/elevation.js';\nimport { html } from 'lit';\nimport { Button } from './button.js';\n/**\n * A filled button component.\n */\nexport class FilledButton extends Button {\n renderElevationOrOutline() {\n return html `<md-elevation part=\"elevation\"></md-elevation>`;\n }\n}\n//# sourceMappingURL=filled-button.js.map","/**\n * @license\n * Copyright 2026 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n// Generated stylesheet for ./button/internal/filled-styles.css.\nimport { css } from 'lit';\nexport const styles = css `:host{--_container-color: var(--md-filled-button-container-color, var(--md-sys-color-primary, #6750a4));--_container-elevation: var(--md-filled-button-container-elevation, 0);--_container-height: var(--md-filled-button-container-height, 40px);--_container-shadow-color: var(--md-filled-button-container-shadow-color, var(--md-sys-color-shadow, #000));--_disabled-container-color: var(--md-filled-button-disabled-container-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-container-elevation: var(--md-filled-button-disabled-container-elevation, 0);--_disabled-container-opacity: var(--md-filled-button-disabled-container-opacity, 0.12);--_disabled-label-text-color: var(--md-filled-button-disabled-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-label-text-opacity: var(--md-filled-button-disabled-label-text-opacity, 0.38);--_focus-container-elevation: var(--md-filled-button-focus-container-elevation, 0);--_focus-label-text-color: var(--md-filled-button-focus-label-text-color, var(--md-sys-color-on-primary, #fff));--_hover-container-elevation: var(--md-filled-button-hover-container-elevation, 1);--_hover-label-text-color: var(--md-filled-button-hover-label-text-color, var(--md-sys-color-on-primary, #fff));--_hover-state-layer-color: var(--md-filled-button-hover-state-layer-color, var(--md-sys-color-on-primary, #fff));--_hover-state-layer-opacity: var(--md-filled-button-hover-state-layer-opacity, 0.08);--_label-text-color: var(--md-filled-button-label-text-color, var(--md-sys-color-on-primary, #fff));--_label-text-font: var(--md-filled-button-label-text-font, var(--md-sys-typescale-label-large-font, var(--md-ref-typeface-plain, Roboto)));--_label-text-line-height: var(--md-filled-button-label-text-line-height, var(--md-sys-typescale-label-large-line-height, 1.25rem));--_label-text-size: var(--md-filled-button-label-text-size, var(--md-sys-typescale-label-large-size, 0.875rem));--_label-text-weight: var(--md-filled-button-label-text-weight, var(--md-sys-typescale-label-large-weight, var(--md-ref-typeface-weight-medium, 500)));--_pressed-container-elevation: var(--md-filled-button-pressed-container-elevation, 0);--_pressed-label-text-color: var(--md-filled-button-pressed-label-text-color, var(--md-sys-color-on-primary, #fff));--_pressed-state-layer-color: var(--md-filled-button-pressed-state-layer-color, var(--md-sys-color-on-primary, #fff));--_pressed-state-layer-opacity: var(--md-filled-button-pressed-state-layer-opacity, 0.12);--_disabled-icon-color: var(--md-filled-button-disabled-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-icon-opacity: var(--md-filled-button-disabled-icon-opacity, 0.38);--_focus-icon-color: var(--md-filled-button-focus-icon-color, var(--md-sys-color-on-primary, #fff));--_hover-icon-color: var(--md-filled-button-hover-icon-color, var(--md-sys-color-on-primary, #fff));--_icon-color: var(--md-filled-button-icon-color, var(--md-sys-color-on-primary, #fff));--_icon-size: var(--md-filled-button-icon-size, 18px);--_pressed-icon-color: var(--md-filled-button-pressed-icon-color, var(--md-sys-color-on-primary, #fff));--_container-shape-start-start: var(--md-filled-button-container-shape-start-start, var(--md-filled-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_container-shape-start-end: var(--md-filled-button-container-shape-start-end, var(--md-filled-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_container-shape-end-end: var(--md-filled-button-container-shape-end-end, var(--md-filled-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_container-shape-end-start: var(--md-filled-button-container-shape-end-start, var(--md-filled-button-container-shape, var(--md-sys-shape-corner-full, 9999px)));--_leading-space: var(--md-filled-button-leading-space, 24px);--_trailing-space: var(--md-filled-button-trailing-space, 24px);--_with-leading-icon-leading-space: var(--md-filled-button-with-leading-icon-leading-space, 16px);--_with-leading-icon-trailing-space: var(--md-filled-button-with-leading-icon-trailing-space, 24px);--_with-trailing-icon-leading-space: var(--md-filled-button-with-trailing-icon-leading-space, 24px);--_with-trailing-icon-trailing-space: var(--md-filled-button-with-trailing-icon-trailing-space, 16px)}\n`;\nexport default styles.styleSheet;\n//# sourceMappingURL=filled-styles.cssresult.js.map","/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { __decorate } from \"tslib\";\nimport { customElement } from 'lit/decorators.js';\nimport { FilledButton } from './internal/filled-button.js';\nimport { styles as filledStyles } from './internal/filled-styles.cssresult.js';\nimport { styles as sharedElevationStyles } from './internal/shared-elevation-styles.cssresult.js';\nimport { styles as sharedStyles } from './internal/shared-styles.cssresult.js';\n/**\n * @summary Buttons help people take action, such as sending an email, sharing a\n * document, or liking a comment.\n *\n * @description\n * __Emphasis:__ High emphasis – For the primary, most important, or most common\n * action on a screen\n *\n * __Rationale:__ The filled button’s contrasting surface color makes it the\n * most prominent button after the FAB. It’s used for final or unblocking\n * actions in a flow.\n *\n * __Example usages:__\n * - Save\n * - Confirm\n * - Done\n *\n * @final\n * @suppress {visibility}\n */\nlet MdFilledButton = class MdFilledButton extends FilledButton {\n};\nMdFilledButton.styles = [\n sharedStyles,\n sharedElevationStyles,\n filledStyles,\n];\nMdFilledButton = __decorate([\n customElement('md-filled-button')\n], MdFilledButton);\nexport { MdFilledButton };\n//# sourceMappingURL=filled-button.js.map","<script lang=\"ts\">\n import '@material/web/button/filled-button.js';\n import '@material/web/button/text-button.js';\n import '@material/web/textfield/outlined-text-field.js';\n import { parsePort } from '#lib/core/config.js';\n\n type Props = {\n /** The port the bridge listens on now. */\n active: number;\n /** The port the next start will use. */\n saved: number;\n /** What sets the port (`--tcp-port`) when a flag or variable does: it can't be changed here. */\n overriddenBy: string | null;\n /** Rejects with a message to show; resolves when the port is saved. */\n onSave: (port: number) => Promise<void>;\n };\n\n let { active, saved, overriddenBy, onSave }: Props = $props();\n\n /** What was typed; `null` until the person edits, so the field follows the saved port. */\n let draft = $state<string | null>(null);\n let fieldError = $state('');\n let failure = $state('');\n let busy = $state(false);\n\n const shown = $derived(draft ?? String(saved));\n const changed = $derived(draft !== null && draft.trim() !== String(saved));\n const pending = $derived(saved !== active);\n\n function revert(): void {\n draft = null;\n fieldError = '';\n failure = '';\n }\n\n async function save(): Promise<void> {\n if (busy || !changed) return;\n const parsed = parsePort(shown);\n if (!parsed.ok) {\n fieldError = parsed.message;\n failure = '';\n return;\n }\n fieldError = '';\n failure = '';\n busy = true;\n try {\n await onSave(parsed.port);\n draft = null;\n } catch (cause) {\n failure = cause instanceof Error ? cause.message : 'The port could not be saved.';\n } finally {\n busy = false;\n }\n }\n</script>\n\n<form\n novalidate\n onsubmit={(event) => {\n event.preventDefault();\n void save();\n }}\n>\n <!-- svelte-ignore a11y_no_static_element_interactions -->\n <md-outlined-text-field\n label=\"TCP port\"\n inputmode=\"numeric\"\n autocomplete=\"off\"\n supporting-text=\"The port the screen reader's speech voice sends to. Default 4449.\"\n value={shown}\n disabled={overriddenBy !== null}\n error={fieldError !== ''}\n error-text={fieldError}\n onkeydown={(event: KeyboardEvent) => {\n // Enter saves, whatever the text field does with the form around it.\n if (event.key !== 'Enter') return;\n event.preventDefault();\n void save();\n }}\n oninput={(event: Event) => {\n draft = (event.target as HTMLInputElement).value;\n fieldError = '';\n }}\n ></md-outlined-text-field>\n\n {#if overriddenBy !== null}\n <p class=\"note\">\n Set by <code>{overriddenBy}</code> when the bridge starts, so a saved port has no effect. Remove\n it to change the port here.\n </p>\n {:else}\n <div class=\"actions\">\n <md-filled-button type=\"submit\" disabled={!changed || busy}>Save</md-filled-button>\n <!-- svelte-ignore a11y_click_events_have_key_events, a11y_no_static_element_interactions -->\n <md-text-button type=\"button\" disabled={!changed || busy} onclick={revert}\n >Revert</md-text-button\n >\n </div>\n {/if}\n\n <p class=\"note\">In use: {active}</p>\n\n <!-- A live region that is always there, so the notice is announced when it appears. -->\n <div role=\"status\" class=\"status\">\n {#if pending}\n <div class=\"pending\">\n <strong>Restart the bridge to use port {saved}.</strong>\n It still listens on {active} until it is restarted. The speech voice on the VM sends to a fixed\n port, so also add a voice for {saved} (<code>text-to-socket-engine-add-voice</code>) and\n select it in the screen reader.\n </div>\n {/if}\n </div>\n\n {#if failure !== ''}<p role=\"alert\" class=\"failure\">{failure}</p>{/if}\n</form>\n\n<style>\n form {\n display: flex;\n flex-direction: column;\n gap: 12px;\n max-width: 480px;\n }\n\n .actions {\n display: flex;\n gap: 8px;\n }\n\n .note {\n margin: 0;\n color: var(--md-sys-color-on-surface-variant);\n font-size: 13px;\n line-height: 18px;\n }\n\n .pending {\n padding: 12px 16px;\n border-radius: 12px;\n background: var(--app-warning-container);\n color: var(--app-on-warning-container);\n font-size: 14px;\n line-height: 20px;\n }\n\n .failure {\n margin: 0;\n color: var(--md-sys-color-error);\n font-size: 14px;\n line-height: 20px;\n }\n\n code {\n font-family: var(--app-mono-font, monospace);\n font-size: 0.95em;\n }\n</style>\n","<script lang=\"ts\">\n import { THEMES, type Theme } from '#lib/core/theme.js';\n\n type Props = { value: Theme; onChange: (theme: Theme) => void };\n\n let { value, onChange }: Props = $props();\n</script>\n\n<fieldset>\n <legend>Color theme</legend>\n <p class=\"hint\">Stored in this browser only. Applied immediately.</p>\n <div class=\"options\">\n {#each THEMES as theme (theme.value)}\n <label class=\"option\">\n <input\n type=\"radio\"\n name=\"color-theme\"\n value={theme.value}\n checked={value === theme.value}\n aria-describedby=\"theme-{theme.value}-description\"\n onchange={() => onChange(theme.value)}\n />\n <span class=\"mark\" aria-hidden=\"true\"></span>\n <span class=\"swatch\" data-theme={theme.value} aria-hidden=\"true\">\n <span class=\"bar\"></span>\n <span class=\"aa\">Aa</span>\n <span class=\"chip\"></span>\n </span>\n <span class=\"text\">\n <span class=\"label\">{theme.label}</span>\n <span class=\"description\" id=\"theme-{theme.value}-description\">{theme.description}</span>\n </span>\n <span class=\"selected\" aria-hidden=\"true\">\n <svg\n width=\"18\"\n height=\"18\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"2\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n >\n <path d=\"M5 12.5l4.5 4.5L19 7.5\" />\n </svg>\n Selected\n </span>\n </label>\n {/each}\n </div>\n</fieldset>\n\n<style>\n fieldset {\n min-width: 0;\n margin: 0;\n padding: 0;\n border: 0;\n }\n\n legend {\n padding: 0;\n color: var(--md-sys-color-on-surface);\n font-size: 14px;\n font-weight: 500;\n line-height: 20px;\n }\n\n .hint {\n margin: 2px 0 12px;\n color: var(--md-sys-color-on-surface-variant);\n font-size: 13px;\n line-height: 18px;\n }\n\n .options {\n display: flex;\n flex-direction: column;\n gap: 8px;\n }\n\n .option {\n position: relative;\n display: flex;\n align-items: center;\n gap: 12px;\n min-height: 64px;\n padding: 8px 16px 8px 12px;\n border: 1px solid var(--md-sys-color-outline);\n border-radius: 12px;\n box-sizing: border-box;\n background: var(--md-sys-color-surface);\n color: var(--md-sys-color-on-surface);\n cursor: pointer;\n }\n\n .option:hover {\n background: var(--md-sys-color-surface-container-high);\n }\n\n /* The native radio stays the real control and covers the whole card. */\n input {\n position: absolute;\n inset: 0;\n margin: 0;\n opacity: 0;\n cursor: pointer;\n }\n\n .mark {\n display: grid;\n flex: none;\n place-items: center;\n width: 20px;\n height: 20px;\n border: 2px solid var(--md-sys-color-outline);\n border-radius: 50%;\n box-sizing: border-box;\n }\n\n .option:has(input:checked) {\n padding: 6px 14px 6px 10px;\n border: 3px solid var(--md-sys-color-primary);\n background: var(--md-sys-color-primary-container);\n color: var(--md-sys-color-on-primary-container);\n }\n\n .option:has(input:checked) .mark {\n border-color: var(--md-sys-color-primary);\n }\n\n .option:has(input:checked) .mark::after {\n width: 10px;\n height: 10px;\n border-radius: 50%;\n background: var(--md-sys-color-primary);\n content: '';\n }\n\n .option:has(input:focus-visible) {\n outline: var(--md-sys-state-focus-indicator-thickness) solid var(--md-sys-color-primary);\n outline-offset: 2px;\n }\n\n .text {\n display: flex;\n flex: 1;\n flex-direction: column;\n min-width: 0;\n }\n\n .label {\n font-size: 16px;\n font-weight: 500;\n line-height: 24px;\n }\n\n .description {\n font-size: 13px;\n line-height: 18px;\n }\n\n .option:not(:has(input:checked)) .description {\n color: var(--md-sys-color-on-surface-variant);\n }\n\n .selected {\n display: none;\n align-items: center;\n gap: 4px;\n color: var(--md-sys-color-on-primary-container);\n font-size: 12px;\n font-weight: 600;\n }\n\n .option:has(input:checked) .selected {\n display: inline-flex;\n }\n\n /* Each swatch carries its own theme's tokens (tokens.css has bare [data-theme] selectors). */\n .swatch {\n position: relative;\n display: block;\n flex: none;\n width: 72px;\n height: 44px;\n border: 2px solid var(--md-sys-color-outline);\n border-radius: 8px;\n box-sizing: border-box;\n overflow: hidden;\n background: var(--md-sys-color-surface);\n }\n\n .bar {\n position: absolute;\n inset: 0 0 auto;\n height: 10px;\n background: var(--md-sys-color-primary);\n }\n\n .aa {\n position: absolute;\n bottom: 5px;\n left: 8px;\n color: var(--md-sys-color-on-surface);\n font:\n 600 15px/16px system-ui,\n sans-serif;\n }\n\n .chip {\n position: absolute;\n right: 7px;\n bottom: 7px;\n width: 20px;\n height: 12px;\n border-radius: 6px;\n background: var(--md-sys-color-primary);\n }\n</style>\n","<script lang=\"ts\">\n import { onMount } from 'svelte';\n import type { Theme } from '#lib/core/theme.js';\n import { appStores } from '#lib/composition.js';\n import TcpPortSetting from '#lib/components/TcpPortSetting/TcpPortSetting.svelte';\n import ThemeSetting from '#lib/components/ThemeSetting/ThemeSetting.svelte';\n\n const { config: configStore, theme: themeStore } = appStores();\n\n onMount(() => {\n void configStore.refresh();\n });\n</script>\n\n<svelte:head>\n <title>Settings · Speech Capture</title>\n</svelte:head>\n\n<!-- One pane like the speech log; every setting is a section in it. The page heading is only for\n screen readers: the sections name themselves. -->\n<div class=\"page\">\n <div class=\"pane\">\n <h1 class=\"visually-hidden\">Settings</h1>\n\n <section aria-labelledby=\"capture-heading\">\n <h2 id=\"capture-heading\">Speech capture</h2>\n <p class=\"scope\">Saved on the bridge. A change takes effect when the bridge is restarted.</p>\n {#if configStore.active !== null && configStore.saved !== null}\n <TcpPortSetting\n active={configStore.active.tcp.port}\n saved={configStore.saved.tcp.port}\n overriddenBy={configStore.overrides['tcp.port'] ?? null}\n onSave={(port: number) => configStore.save({ tcp: { port } })}\n />\n {:else if !configStore.reachable}\n <p class=\"scope\" role=\"alert\">\n The bridge is not reachable, so its settings can't be read.\n <button type=\"button\" onclick={() => void configStore.refresh()}>Try again</button>\n </p>\n {:else}\n <p class=\"scope\">Reading the bridge settings…</p>\n {/if}\n </section>\n\n <section aria-labelledby=\"appearance-heading\">\n <h2 id=\"appearance-heading\">Appearance</h2>\n <ThemeSetting value={themeStore.current} onChange={(theme: Theme) => themeStore.set(theme)} />\n </section>\n </div>\n</div>\n\n<style>\n /* The same gutter above and below as the Monitor page, so the pane lines up with the rail. */\n .page {\n box-sizing: border-box;\n height: 100%;\n padding: var(--app-gutter) 0;\n }\n\n .pane {\n box-sizing: border-box;\n height: 100%;\n min-height: 0;\n overflow: auto;\n padding: 16px 24px 24px;\n border: 1px solid var(--md-sys-color-outline-variant);\n border-width: max(1px, var(--app-border-width));\n border-radius: 16px;\n background: var(--md-sys-color-surface-container-lowest);\n }\n\n section {\n max-width: 720px;\n }\n\n section + section {\n margin-top: 32px;\n padding-top: 24px;\n border-top: 1px solid var(--md-sys-color-outline-variant);\n }\n\n .scope {\n margin: 0 0 12px;\n color: var(--md-sys-color-on-surface-variant);\n font-size: 13px;\n line-height: 18px;\n }\n\n h2 {\n margin: 0 0 8px;\n color: var(--md-sys-color-on-surface);\n font-size: 22px;\n font-weight: 500;\n line-height: 28px;\n }\n\n .visually-hidden {\n position: absolute;\n width: 1px;\n height: 1px;\n overflow: hidden;\n clip-path: inset(50%);\n white-space: nowrap;\n }\n</style>\n"],"ignoreList":[0,1,2],"mappings":";;;;;;;;;;;;;AAWA,IAAa,eAAb,cAAkC,OAAO;CACrC,2BAA2B;EACvB,OAAO,CAAK;CAChB;AACJ;;;;;;;ACRA,IAAa,SAAS,CAAI;;AAEX,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;ACsBtB,IAAI,iBAAiB,MAAM,uBAAuB,aAAa,CAC/D;AACA,eAAe,SAAS;CACpBA;CACAC;CACAC;AACJ;AACA,iBAAiB,WAAW,CACxBC,EAAc,kBAAkB,CACpC,GAAG,cAAc;;;CCxCjB,WAAA,WAAA,eAAA;;;;;EAiBE,IAAI,EAAE,QAAQ,OAAO,cAAc,WAAe;EAIlD,IAAI,aAAoB;EAExB,IAAI,OAAc;EAElB,MAAM,QAAKC,cAAqB,OAAO,KAAK,CAAC;EAC7C,MAAM,UAAOA,cAAY,KAAgD;EACzE,MAAM,UAAOA,cAAY,UAAU,MAAM;EA2ChC,WAAA,KAAA,gNAAAC,KAAA,SAAA,MAAK,CAAA,IAAAA,KAAA,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I,EAAE,CAAE;;EAEtD,OAAA,IAAA,CAAC,YAAY,W;;;;GAYF,OAAA,WAAW;GAAmB,WAAC,UAAiB,WAAW,IAAI,KAAK;;;CAlCvF,CAAA"}
|
|
1
|
+
{"version":3,"file":"_page.svelte.js","names":["t","t","$.escape","$.ensure_array_like","LitElement","classMap","styleMap","nothing","query","property","queryAssignedElements","state","styles","styles","customElement","LitElement","classMap","nothing","styleMap","property","state","query","queryAssignedElements","styles","styles","sharedStyles","styles","customElement","styles","LitElement","property","queryAll","customElement","LitElement","nothing","classMap","property","query","queryAssignedElements","queryAssignedNodes","styles","customElement","$.props_id","$.attr","$.escape","$.derived","$.escape","$.attr_class","$.attr","$.ensure_array_like","$.derived","$.ensure_array_like","$.attr","$.stringify","$.escape","$.ensure_array_like","$.attr","$.stringify","$.escape","$.derived"],"sources":["../../../../../../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/query-all.js","../../../../../../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/query-assigned-nodes.js","../../../../../src/lib/core/settings.ts","../../../../../src/lib/components/RestartSummary/RestartSummary.svelte","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/list/internal/list-navigation-helpers.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/list/internal/list-controller.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/menu/internal/controllers/shared.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/menu/internal/controllers/surfacePositionController.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/menu/internal/controllers/typeaheadController.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/menu/internal/menu.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/menu/internal/menu-styles.cssresult.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/menu/menu.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/labs/behaviors/validators/select-validator.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/select/internal/shared.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/select/internal/select.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/select/internal/outlined-select.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/select/internal/outlined-select-styles.cssresult.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/select/internal/shared-styles.cssresult.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/select/outlined-select.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/menu/internal/menuitem/menu-item-styles.cssresult.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/labs/item/internal/item.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/labs/item/internal/item-styles.cssresult.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/labs/item/item.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/menu/internal/controllers/menuItemController.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/select/internal/selectoption/selectOptionController.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/select/internal/selectoption/select-option.js","../../../../../../../node_modules/.pnpm/@material+web@2.5.0/node_modules/@material/web/select/select-option.js","../../../../../src/lib/components/CheckboxField/CheckboxField.svelte","../../../../../src/lib/components/SettingField/SettingField.svelte","../../../../../src/lib/components/SettingsForm/SettingsForm.svelte","../../../../../src/lib/components/ThemeSetting/ThemeSetting.svelte","../../../../../src/routes/settings/+page.svelte"],"sourcesContent":["import{desc as t}from\"./base.js\";\n/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nlet e;function r(r){return(n,o)=>t(n,o,{get(){return(this.renderRoot??(e??=document.createDocumentFragment())).querySelectorAll(r)}})}export{r as queryAll};\n//# sourceMappingURL=query-all.js.map\n","import{desc as t}from\"./base.js\";\n/**\n * @license\n * Copyright 2017 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */function n(n){return(o,r)=>{const{slot:e}=n??{},s=\"slot\"+(e?`[name=${e}]`:\":not([name])\");return t(o,r,{get(){const t=this.renderRoot?.querySelector(s);return t?.assignedNodes(n)??[]}})}}export{n as queryAssignedNodes};\n//# sourceMappingURL=query-assigned-nodes.js.map\n","import {\n LOG_LEVELS,\n type ConfigDto,\n type ConfigPatchDto,\n type LogLevel,\n} from '@screenreader-speech-capture/shared';\nimport {\n parseMaxEntries,\n parsePlaywrightVersion,\n parsePort,\n pendingFields,\n SettingRejected,\n} from './config.js';\n\n// The bridge settings the Settings page edits, as data: what each one is called, how its value is\n// shown and read, and what to say about it. The components only render this.\n\n/** The settings with a UI element, by dotted path. */\nexport type SettingPath =\n | 'tcp.port'\n | 'tcp.encoding'\n | 'buffer.maxEntries'\n | 'playwright.enabled'\n | 'playwright.version'\n | 'mcp.enabled'\n | 'log.level';\n\nexport type SettingValue = string | number | boolean | null;\n\n/** What the texts of a setting need besides its value. */\nexport interface SettingContext {\n /** The version the Playwright server runs (from the status); `null` while unknown. */\n runningPlaywright: string | null;\n /** The saved configuration turns the Playwright server off. */\n playwrightOff?: boolean;\n}\n\n/** A piece of a text: plain, or a command name. */\nexport type Fragment = string | { code: string };\n\nexport type Parsed<T> = { ok: true; value: T } | { ok: false; message: string };\n\n/** One choice of a select. */\nexport interface Option {\n value: string;\n label: string;\n}\n\nexport type Control =\n | { kind: 'text'; inputmode: 'text' | 'numeric'; suffix?: string }\n | { kind: 'select'; options: readonly Option[] }\n /** On or off; the control holds `true` or `false`. */\n | { kind: 'checkbox' };\n\nexport interface Setting<T = SettingValue> {\n path: SettingPath;\n label: string;\n control: Control;\n /** The text under the control; `active` is the value in use. */\n help(active: T, context: SettingContext): string;\n /** A value as the control holds it. */\n format(value: T): string;\n /** Reads what the control holds; a refused text has a message and is not saved. */\n parse(text: string): Parsed<T>;\n /** A value in words. */\n describe(value: T, context: SettingContext): string;\n /** What to know before the restart that applies `saved` instead of `active`. */\n consequence(saved: T, active: T): Fragment[];\n}\n\nexport const TCP_PORT: Setting<number> = {\n path: 'tcp.port',\n label: 'TCP port',\n control: { kind: 'text', inputmode: 'numeric' },\n help: () => \"The port the screen reader's speech voice sends to. Default 4449.\",\n format: String,\n parse(text) {\n const parsed = parsePort(text);\n return parsed.ok ? { ok: true, value: parsed.port } : parsed;\n },\n describe: String,\n consequence: (saved) => [\n `The speech voice on the VM sends to a fixed port, so also add a voice for ${saved} (`,\n { code: 'text-to-socket-engine-add-voice' },\n ') and select it in the screen reader.',\n ],\n};\n\n/** The ANSI code pages Windows has, plus UTF-8: what a speech voice on the VM can send. */\nconst ENCODINGS: readonly Option[] = (\n [\n ['windows-874', 'Thai'],\n ['windows-1250', 'Central European'],\n ['windows-1251', 'Cyrillic'],\n ['windows-1252', 'Western European'],\n ['windows-1253', 'Greek'],\n ['windows-1254', 'Turkish'],\n ['windows-1255', 'Hebrew'],\n ['windows-1256', 'Arabic'],\n ['windows-1257', 'Baltic'],\n ['windows-1258', 'Vietnamese'],\n ['shift_jis', 'Japanese'],\n ['gbk', 'Simplified Chinese'],\n ['euc-kr', 'Korean'],\n ['big5', 'Traditional Chinese'],\n ['utf-8', 'Unicode'],\n ] as const\n).map(([value, name]) => ({ value, label: `${value} (${name})` }));\n\n/**\n * The options of a select that holds `value`. A saved value outside the list (an alias such as\n * `cp1252`) is added, so showing it never changes it.\n */\nexport function selectOptions(options: readonly Option[], value: string): readonly Option[] {\n return options.some((option) => option.value === value)\n ? options\n : [...options, { value, label: value }];\n}\n\nexport const TEXT_ENCODING: Setting<string> = {\n path: 'tcp.encoding',\n label: 'Text encoding',\n control: { kind: 'select', options: ENCODINGS },\n help: () =>\n \"The code page the speech voice sends: the VM's ANSI code page. Default windows-1252.\",\n format: (encoding) => encoding,\n parse: (text) => ({ ok: true, value: text }),\n describe: (encoding) => encoding,\n consequence: () => [],\n};\n\nexport const BUFFER_SIZE: Setting<number> = {\n path: 'buffer.maxEntries',\n label: 'Speech buffer size',\n control: { kind: 'text', inputmode: 'numeric', suffix: 'entries' },\n help: () =>\n 'How many speech entries the bridge keeps; then the oldest are dropped. Default 10000.',\n format: String,\n parse(text) {\n const parsed = parseMaxEntries(text);\n return parsed.ok ? { ok: true, value: parsed.entries } : parsed;\n },\n describe: String,\n consequence: () => [],\n};\n\n/** What every on / off setting shares. */\nconst onOff = {\n control: { kind: 'checkbox' },\n format: String,\n parse: (text: string): Parsed<boolean> => ({ ok: true, value: text === 'true' }),\n describe: (on: boolean) => (on ? 'On' : 'Off'),\n} as const;\n\n/** What to know before a restart that turns a child service on. */\nconst INSTALLS = 'The first start installs what is missing, which can take a minute or two.';\n\nexport const PLAYWRIGHT_ENABLED: Setting<boolean> = {\n ...onOff,\n path: 'playwright.enabled',\n label: 'Playwright server',\n help: () => 'Tests connect to it to drive a browser on the VM.',\n consequence: (saved) => [\n saved ? INSTALLS : \"Tests can't connect to a browser on the VM while it is off.\",\n ],\n};\n\nconst bundled = ({ runningPlaywright }: SettingContext) =>\n runningPlaywright === null ? 'bundled version' : `bundled version (${runningPlaywright})`;\n\nexport const PLAYWRIGHT_VERSION: Setting<string | null> = {\n path: 'playwright.version',\n label: 'Playwright version',\n control: { kind: 'text', inputmode: 'text' },\n // The running version is the bundled one only while no version is configured.\n help: (active, { runningPlaywright, playwrightOff }) =>\n 'The exact version of the Playwright server, like 1.65.0. Use the version your tests use. ' +\n 'Leave empty for the bundled version' +\n (active === null && runningPlaywright !== null ? ` (${runningPlaywright}).` : '.') +\n (playwrightOff === true ? ' Applies when the server is turned on.' : ''),\n format: (version) => version ?? '',\n parse(text) {\n const parsed = parsePlaywrightVersion(text);\n return parsed.ok ? { ok: true, value: parsed.version } : parsed;\n },\n describe: (version, context) => version ?? bundled(context),\n consequence: () => [\n 'The first start of a new version installs it, which can take a minute or two. Your test ' +\n 'projects need the same version.',\n ],\n};\n\n/** The value of a setting in a configuration. */\nexport function readSetting(config: ConfigDto, path: SettingPath): SettingValue {\n const [section, key] = path.split('.') as [keyof ConfigDto, string];\n return (config[section] as Record<string, SettingValue>)[key];\n}\n\n/** What was typed or chosen, by setting; a setting nobody touched has no draft. */\nexport type Drafts = Partial<Record<SettingPath, string>>;\n\n/** The settings whose draft differs from the saved value. */\nexport function changedSettings(\n settings: readonly Setting[],\n drafts: Drafts,\n saved: ConfigDto,\n): Setting[] {\n return settings.filter((setting) => {\n const draft = drafts[setting.path];\n return draft !== undefined && draft.trim() !== setting.format(readSetting(saved, setting.path));\n });\n}\n\nexport type PatchResult =\n { ok: true; patch: ConfigPatchDto } | { ok: false; errors: Partial<Record<SettingPath, string>> };\n\n/**\n * The patch that saves the changed settings, and only those: an untouched value must not end up in\n * the config file. One unreadable draft means nothing is saved.\n */\nexport function buildPatch(\n settings: readonly Setting[],\n drafts: Drafts,\n saved: ConfigDto,\n): PatchResult {\n const patch: Record<string, Record<string, SettingValue>> = {};\n const errors: Partial<Record<SettingPath, string>> = {};\n for (const setting of changedSettings(settings, drafts, saved)) {\n const parsed = setting.parse(drafts[setting.path]!);\n if (!parsed.ok) {\n errors[setting.path] = parsed.message;\n continue;\n }\n const [section, key] = setting.path.split('.') as [string, string];\n (patch[section] ??= {})[key] = parsed.value;\n }\n return Object.keys(errors).length > 0 ? { ok: false, errors } : { ok: true, patch };\n}\n\nexport const MCP_ENABLED: Setting<boolean> = {\n ...onOff,\n path: 'mcp.enabled',\n label: 'Playwright MCP',\n help: () => 'AI agents connect to it to drive a browser on the VM.',\n consequence: (saved) => [\n saved ? INSTALLS : \"AI agents can't connect to a browser through it while it is off.\",\n ],\n};\n\n/** What each level of the bridge log holds. */\nconst LEVELS: Record<LogLevel, string> = {\n error: 'errors only',\n warn: 'errors and warnings',\n info: 'normal operation',\n debug: 'everything, with the speech',\n};\n\nexport const LOG_LEVEL: Setting<LogLevel> = {\n path: 'log.level',\n label: 'Log level',\n control: {\n kind: 'select',\n options: LOG_LEVELS.map((value) => ({ value, label: `${value} (${LEVELS[value]})` })),\n },\n help: () =>\n 'How much the bridge writes to its log. At debug that includes everything the screen reader ' +\n 'says, in the log file. Default info.',\n format: (level) => level,\n parse: (text) => ({ ok: true, value: text as LogLevel }),\n describe: (level) => level,\n consequence: (saved) =>\n saved === 'debug' ? ['What the screen reader says is then written to the log file.'] : [],\n};\n\n/** The settings with a UI element. */\nexport const SETTINGS: readonly Setting[] = [\n TCP_PORT,\n TEXT_ENCODING,\n BUFFER_SIZE,\n PLAYWRIGHT_ENABLED,\n PLAYWRIGHT_VERSION,\n MCP_ENABLED,\n LOG_LEVEL,\n];\n\n/** Whether the saved value of a setting waits for a restart. A flag or variable keeps winning. */\nexport function isPending(\n path: SettingPath,\n active: ConfigDto,\n saved: ConfigDto,\n overrides: Readonly<Record<string, string>>,\n): boolean {\n return overrides[path] === undefined && readSetting(active, path) !== readSetting(saved, path);\n}\n\n/** A saved change that the next start of the bridge applies. */\nexport interface PendingChange {\n path: string;\n /** The setting's label, or its dotted path if the page has no field for it. */\n label: string;\n from: string;\n to: string;\n consequence: Fragment[];\n}\n\nconst valueAt = (config: ConfigDto, path: string): unknown => {\n const [section, key] = path.split('.') as [keyof ConfigDto, string];\n return (config[section] as Record<string, unknown>)[key];\n};\n\n/**\n * Everything that waits for a restart, also settings saved through the API that have no field\n * here.\n */\nexport function waitingForRestart(\n active: ConfigDto,\n saved: ConfigDto,\n overrides: Readonly<Record<string, string>>,\n context: SettingContext,\n): PendingChange[] {\n return pendingFields(active, saved)\n .filter((path) => overrides[path] === undefined)\n .map((path) => {\n const setting = SETTINGS.find((candidate) => candidate.path === path);\n if (setting === undefined) {\n const text = (config: ConfigDto) => JSON.stringify(valueAt(config, path));\n return { path, label: path, from: text(active), to: text(saved), consequence: [] };\n }\n const from = readSetting(active, setting.path);\n const to = readSetting(saved, setting.path);\n return {\n path,\n label: setting.label,\n from: setting.describe(from, context),\n // What runs now says nothing about the next start.\n to: setting.describe(to, { ...context, runningPlaywright: null }),\n consequence: setting.consequence(to, from),\n };\n });\n}\n\n/** Why a save failed: on the field it is about, or for the form as a whole. */\nexport interface Rejection {\n field: SettingPath | null;\n message: string;\n}\n\n/**\n * Puts a failed save into the form's terms. The bridge names one setting (`details.field`) by its\n * dotted path, which isn't always the one that was changed: two listeners on one port are reported\n * on the later one. So the field is the named one if the form has it, else one the message names.\n */\nexport function explainRejection(cause: unknown, settings: readonly Setting[]): Rejection {\n if (!(cause instanceof Error))\n return { field: null, message: 'The settings could not be saved.' };\n if (!(cause instanceof SettingRejected) || cause.field === undefined) {\n return { field: null, message: cause.message };\n }\n const target =\n settings.find((setting) => setting.path === cause.field) ??\n settings.find((setting) => cause.message.includes(setting.path));\n const readable = SETTINGS.reduce(\n (message, setting) => message.replaceAll(setting.path, setting.label),\n cause.message,\n );\n return { field: target?.path ?? null, message: `${readable}. Nothing was saved.` };\n}\n","<script lang=\"ts\">\n import '@material/web/button/outlined-button.js';\n import { tick } from 'svelte';\n import type { PendingChange } from '#lib/core/settings.js';\n\n type Props = {\n changes: PendingChange[];\n /** Whether the last read of the configuration worked. */\n reachable: boolean;\n /** Reads the configuration and the status again, after a restart. */\n onCheck: () => Promise<void>;\n };\n\n let { changes, reachable, onCheck }: Props = $props();\n\n /** What the last check found; empty until someone checks. */\n let result = $state('');\n let message: HTMLParagraphElement;\n\n const counted = (count: number) =>\n count === 1 ? '1 change waits for a restart' : `${count} changes wait for a restart`;\n\n async function check(): Promise<void> {\n result = '';\n await onCheck();\n result = !reachable\n ? 'The bridge is not reachable.'\n : changes.length === 0\n ? 'No changes wait for a restart.'\n : `Checked: ${counted(changes.length)}.`;\n await tick();\n // The button goes away with the last change: keep the focus where the answer is.\n if (changes.length === 0) message.focus();\n }\n</script>\n\n{#if changes.length > 0}\n <!-- Not a live region: the form that saved says so, once. -->\n <section aria-labelledby=\"restart-heading\">\n <h2 id=\"restart-heading\">{counted(changes.length)}</h2>\n <ul>\n {#each changes as change (change.path)}\n <li>\n <strong>{change.label}:</strong>\n {change.from} → {change.to}.\n {#each change.consequence as fragment, index (index)}{#if typeof fragment === 'string'}{fragment}{:else}<code\n >{fragment.code}</code\n >{/if}{/each}\n </li>\n {/each}\n </ul>\n <p>Restarting the bridge empties the recorded speech and sessions.</p>\n <!-- svelte-ignore a11y_click_events_have_key_events, a11y_no_static_element_interactions -->\n <md-outlined-button type=\"button\" onclick={() => void check()}>Check again</md-outlined-button>\n </section>\n{/if}\n\n<p role=\"status\" tabindex=\"-1\" class=\"result\" bind:this={message}>{result}</p>\n\n<style>\n section {\n box-sizing: border-box;\n max-width: 720px;\n padding: 16px;\n border-radius: 12px;\n background: var(--app-warning-container);\n color: var(--app-on-warning-container);\n font-size: 14px;\n line-height: 20px;\n overflow-wrap: anywhere;\n }\n\n h2 {\n margin: 0 0 8px;\n font-size: 16px;\n font-weight: 500;\n line-height: 24px;\n }\n\n ul {\n margin: 0;\n padding-left: 20px;\n }\n\n li + li {\n margin-top: 4px;\n }\n\n p {\n margin: 8px 0;\n }\n\n /* The button's text and outline in the box's own colour, so it reads in every theme. */\n md-outlined-button {\n --md-outlined-button-label-text-color: var(--app-on-warning-container);\n --md-outlined-button-hover-label-text-color: var(--app-on-warning-container);\n --md-outlined-button-focus-label-text-color: var(--app-on-warning-container);\n --md-outlined-button-pressed-label-text-color: var(--app-on-warning-container);\n --md-outlined-button-outline-color: var(--app-on-warning-container);\n }\n\n .result {\n margin: 8px 0 0;\n color: var(--md-sys-color-on-surface-variant);\n font-size: 13px;\n line-height: 18px;\n }\n\n .result:empty {\n margin: 0;\n }\n\n code {\n font-family: var(--app-mono-font, monospace);\n font-size: 0.95em;\n }\n</style>\n","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n/**\n * Activates the first non-disabled item of a given array of items.\n *\n * @param items {Array<ListItem>} The items from which to activate the\n * first item.\n * @param isActivatable Function to determine if an item can be activated.\n * Defaults to non-disabled items.\n */\nexport function activateFirstItem(items, isActivatable = (isItemNotDisabled)) {\n // NOTE: These selector functions are static and not on the instance such\n // that multiple operations can be chained and we do not have to re-query\n // the DOM\n const firstItem = getFirstActivatableItem(items, isActivatable);\n if (firstItem) {\n firstItem.tabIndex = 0;\n firstItem.focus();\n }\n return firstItem;\n}\n/**\n * Activates the last non-disabled item of a given array of items.\n *\n * @param items {Array<ListItem>} The items from which to activate the\n * last item.\n * @param isActivatable Function to determine if an item can be activated.\n * Defaults to non-disabled items.\n * @nocollapse\n */\nexport function activateLastItem(items, isActivatable = (isItemNotDisabled)) {\n const lastItem = getLastActivatableItem(items, isActivatable);\n if (lastItem) {\n lastItem.tabIndex = 0;\n lastItem.focus();\n }\n return lastItem;\n}\n/**\n * Deactivates the currently active item of a given array of items.\n *\n * @param items {Array<ListItem>} The items from which to deactivate the\n * active item.\n * @param isActivatable Function to determine if an item can be activated.\n * Defaults to non-disabled items.\n * @return A record of the deleselcted activated item including the item and\n * the index of the item or `null` if none are deactivated.\n * @nocollapse\n */\nexport function deactivateActiveItem(items, isActivatable = (isItemNotDisabled)) {\n const activeItem = getActiveItem(items, isActivatable);\n if (activeItem) {\n activeItem.item.tabIndex = -1;\n }\n return activeItem;\n}\n/**\n * Retrieves the first activated item of a given array of items.\n *\n * @param items {Array<ListItem>} The items to search.\n * @param isActivatable Function to determine if an item can be activated.\n * Defaults to non-disabled items.\n * @return A record of the first activated item including the item and the\n * index of the item or `null` if none are activated.\n * @nocollapse\n */\nexport function getActiveItem(items, isActivatable = (isItemNotDisabled)) {\n for (let i = 0; i < items.length; i++) {\n const item = items[i];\n if (item.tabIndex === 0 && isActivatable(item)) {\n return {\n item,\n index: i,\n };\n }\n }\n return null;\n}\n/**\n * Retrieves the first non-disabled item of a given array of items. This\n * the first item that is not disabled.\n *\n * @param items {Array<ListItem>} The items to search.\n * @param isActivatable Function to determine if an item can be activated.\n * Defaults to non-disabled items.\n * @return The first activatable item or `null` if none are activatable.\n * @nocollapse\n */\nexport function getFirstActivatableItem(items, isActivatable = (isItemNotDisabled)) {\n for (const item of items) {\n if (isActivatable(item)) {\n return item;\n }\n }\n return null;\n}\n/**\n * Retrieves the last non-disabled item of a given array of items.\n *\n * @param items {Array<ListItem>} The items to search.\n * @param isActivatable Function to determine if an item can be activated.\n * Defaults to non-disabled items.\n * @return The last activatable item or `null` if none are activatable.\n * @nocollapse\n */\nexport function getLastActivatableItem(items, isActivatable = (isItemNotDisabled)) {\n for (let i = items.length - 1; i >= 0; i--) {\n const item = items[i];\n if (isActivatable(item)) {\n return item;\n }\n }\n return null;\n}\n/**\n * Retrieves the next non-disabled item of a given array of items.\n *\n * @param items {Array<ListItem>} The items to search.\n * @param index {{index: number}} The index to search from.\n * @param isActivatable Function to determine if an item can be activated.\n * Defaults to non-disabled items.\n * @param wrap If true, then the next item at the end of the list is the first\n * item. Defaults to true.\n * @return The next activatable item or `null` if none are activatable.\n */\nexport function getNextItem(items, index, isActivatable = (isItemNotDisabled), wrap = true) {\n for (let i = 1; i < items.length; i++) {\n const nextIndex = (i + index) % items.length;\n if (nextIndex < index && !wrap) {\n // Return if the index loops back to the beginning and not wrapping.\n return null;\n }\n const item = items[nextIndex];\n if (isActivatable(item)) {\n return item;\n }\n }\n return items[index] ? items[index] : null;\n}\n/**\n * Retrieves the previous non-disabled item of a given array of items.\n *\n * @param items {Array<ListItem>} The items to search.\n * @param index {{index: number}} The index to search from.\n * @param isActivatable Function to determine if an item can be activated.\n * Defaults to non-disabled items.\n * @param wrap If true, then the previous item at the beginning of the list is\n * the last item. Defaults to true.\n * @return The previous activatable item or `null` if none are activatable.\n */\nexport function getPrevItem(items, index, isActivatable = (isItemNotDisabled), wrap = true) {\n for (let i = 1; i < items.length; i++) {\n const prevIndex = (index - i + items.length) % items.length;\n if (prevIndex > index && !wrap) {\n // Return if the index loops back to the end and not wrapping.\n return null;\n }\n const item = items[prevIndex];\n if (isActivatable(item)) {\n return item;\n }\n }\n return items[index] ? items[index] : null;\n}\n/**\n * Activates the next item and focuses it. If nothing is currently activated,\n * activates the first item.\n */\nexport function activateNextItem(items, activeItemRecord, isActivatable = (isItemNotDisabled), wrap = true) {\n if (activeItemRecord) {\n const next = getNextItem(items, activeItemRecord.index, isActivatable, wrap);\n if (next) {\n next.tabIndex = 0;\n next.focus();\n }\n return next;\n }\n else {\n return activateFirstItem(items, isActivatable);\n }\n}\n/**\n * Activates the previous item and focuses it. If nothing is currently\n * activated, activates the last item.\n */\nexport function activatePreviousItem(items, activeItemRecord, isActivatable = (isItemNotDisabled), wrap = true) {\n if (activeItemRecord) {\n const prev = getPrevItem(items, activeItemRecord.index, isActivatable, wrap);\n if (prev) {\n prev.tabIndex = 0;\n prev.focus();\n }\n return prev;\n }\n else {\n return activateLastItem(items, isActivatable);\n }\n}\n/**\n * Creates an event that requests the parent md-list to deactivate all other\n * items.\n */\nexport function createDeactivateItemsEvent() {\n return new Event('deactivate-items', { bubbles: true, composed: true });\n}\n/**\n * Creates an event that requests the menu to set `tabindex=0` on the item and\n * focus it. We use this pattern because List keeps track of what element is\n * active in the List by maintaining tabindex. We do not want list items\n * to set tabindex on themselves or focus themselves so that we can organize all\n * that logic in the parent List and Menus, and list item stays as dumb as\n * possible.\n */\nexport function createRequestActivationEvent() {\n return new Event('request-activation', { bubbles: true, composed: true });\n}\n/**\n * The default `isActivatable` function, which checks if an item is not\n * disabled.\n *\n * @param item The item to check.\n * @return true if `item.disabled` is `false.\n */\nfunction isItemNotDisabled(item) {\n return !item.disabled;\n}\n//# sourceMappingURL=list-navigation-helpers.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { activateFirstItem, activateLastItem, activateNextItem, activatePreviousItem, getActiveItem, getFirstActivatableItem, } from './list-navigation-helpers.js';\n// TODO: move this file to List and make List use this\n/**\n * Default keys that trigger navigation.\n */\n// tslint:disable:enforce-name-casing Following Enum style\nexport const NavigableKeys = {\n ArrowDown: 'ArrowDown',\n ArrowLeft: 'ArrowLeft',\n ArrowUp: 'ArrowUp',\n ArrowRight: 'ArrowRight',\n Home: 'Home',\n End: 'End',\n};\n/**\n * A controller that handles list keyboard navigation and item management.\n */\nexport class ListController {\n constructor(config) {\n /**\n * Handles keyboard navigation. Should be bound to the node that will act as\n * the List.\n */\n this.handleKeydown = (event) => {\n const key = event.key;\n if (event.defaultPrevented || !this.isNavigableKey(key)) {\n return;\n }\n // do not use this.items directly in upcoming calculations so we don't\n // re-query the DOM unnecessarily\n const items = this.items;\n if (!items.length) {\n return;\n }\n const activeItemRecord = getActiveItem(items, this.isActivatable);\n event.preventDefault();\n const isRtl = this.isRtl();\n const inlinePrevious = isRtl\n ? NavigableKeys.ArrowRight\n : NavigableKeys.ArrowLeft;\n const inlineNext = isRtl\n ? NavigableKeys.ArrowLeft\n : NavigableKeys.ArrowRight;\n let nextActiveItem = null;\n switch (key) {\n // Activate the next item\n case NavigableKeys.ArrowDown:\n case inlineNext:\n nextActiveItem = activateNextItem(items, activeItemRecord, this.isActivatable, this.wrapNavigation());\n break;\n // Activate the previous item\n case NavigableKeys.ArrowUp:\n case inlinePrevious:\n nextActiveItem = activatePreviousItem(items, activeItemRecord, this.isActivatable, this.wrapNavigation());\n break;\n // Activate the first item\n case NavigableKeys.Home:\n nextActiveItem = activateFirstItem(items, this.isActivatable);\n break;\n // Activate the last item\n case NavigableKeys.End:\n nextActiveItem = activateLastItem(items, this.isActivatable);\n break;\n default:\n break;\n }\n if (nextActiveItem &&\n activeItemRecord &&\n activeItemRecord.item !== nextActiveItem) {\n // If a new item was activated, remove the tabindex of the previous\n // activated item.\n activeItemRecord.item.tabIndex = -1;\n }\n };\n /**\n * Listener to be bound to the `deactivate-items` item event.\n */\n this.onDeactivateItems = () => {\n const items = this.items;\n for (const item of items) {\n this.deactivateItem(item);\n }\n };\n /**\n * Listener to be bound to the `request-activation` item event..\n */\n this.onRequestActivation = (event) => {\n this.onDeactivateItems();\n const target = event.target;\n this.activateItem(target);\n target.focus();\n };\n /**\n * Listener to be bound to the `slotchange` event for the slot that renders\n * the items.\n */\n this.onSlotchange = () => {\n const items = this.items;\n // Whether we have encountered an item that has been activated\n let encounteredActivated = false;\n for (const item of items) {\n const isActivated = !item.disabled && item.tabIndex > -1;\n if (isActivated && !encounteredActivated) {\n encounteredActivated = true;\n item.tabIndex = 0;\n continue;\n }\n // Deactivate the rest including disabled\n item.tabIndex = -1;\n }\n if (encounteredActivated) {\n return;\n }\n const firstActivatableItem = getFirstActivatableItem(items, this.isActivatable);\n if (!firstActivatableItem) {\n return;\n }\n firstActivatableItem.tabIndex = 0;\n };\n const { isItem, getPossibleItems, isRtl, deactivateItem, activateItem, isNavigableKey, isActivatable, wrapNavigation, } = config;\n this.isItem = isItem;\n this.getPossibleItems = getPossibleItems;\n this.isRtl = isRtl;\n this.deactivateItem = deactivateItem;\n this.activateItem = activateItem;\n this.isNavigableKey = isNavigableKey;\n this.isActivatable = isActivatable;\n this.wrapNavigation = wrapNavigation ?? (() => true);\n }\n /**\n * The items being managed by the list. Additionally, attempts to see if the\n * object has a sub-item in the `.item` property.\n */\n get items() {\n const maybeItems = this.getPossibleItems();\n const items = [];\n for (const itemOrParent of maybeItems) {\n const isItem = this.isItem(itemOrParent);\n // if the item is a list item, add it to the list of items\n if (isItem) {\n items.push(itemOrParent);\n continue;\n }\n // If the item exposes an `item` property check if it is a list item.\n const subItem = itemOrParent.item;\n if (subItem && this.isItem(subItem)) {\n items.push(subItem);\n }\n }\n return items;\n }\n /**\n * Activates the next item in the list. If at the end of the list, the first\n * item will be activated.\n *\n * @return The activated list item or `null` if there are no items.\n */\n activateNextItem() {\n const items = this.items;\n const activeItemRecord = getActiveItem(items, this.isActivatable);\n if (activeItemRecord) {\n activeItemRecord.item.tabIndex = -1;\n }\n return activateNextItem(items, activeItemRecord, this.isActivatable, this.wrapNavigation());\n }\n /**\n * Activates the previous item in the list. If at the start of the list, the\n * last item will be activated.\n *\n * @return The activated list item or `null` if there are no items.\n */\n activatePreviousItem() {\n const items = this.items;\n const activeItemRecord = getActiveItem(items, this.isActivatable);\n if (activeItemRecord) {\n activeItemRecord.item.tabIndex = -1;\n }\n return activatePreviousItem(items, activeItemRecord, this.isActivatable, this.wrapNavigation());\n }\n}\n//# sourceMappingURL=list-controller.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n/**\n * Creates an event that closes any parent menus.\n */\nexport function createCloseMenuEvent(initiator, reason) {\n return new CustomEvent('close-menu', {\n bubbles: true,\n composed: true,\n detail: { initiator, reason, itemPath: [initiator] },\n });\n}\n/**\n * Creates an event that signals to the menu that it should stay open on the\n * focusout event.\n */\nexport function createStayOpenOnFocusoutEvent() {\n return new Event('stay-open-on-focusout', { bubbles: true, composed: true });\n}\n/**\n * Creates an event that signals to the menu that it should close open on the\n * focusout event.\n */\nexport function createCloseOnFocusoutEvent() {\n return new Event('close-on-focusout', { bubbles: true, composed: true });\n}\n/**\n * Creates a default close menu event used by md-menu.\n */\nexport const createDefaultCloseMenuEvent = (createCloseMenuEvent);\n/**\n * Creates an event that requests the given item be selected.\n */\nexport function createDeactivateTypeaheadEvent() {\n return new Event('deactivate-typeahead', { bubbles: true, composed: true });\n}\n/**\n * Creates an event that requests the typeahead functionality of containing menu\n * be activated.\n */\nexport function createActivateTypeaheadEvent() {\n return new Event('activate-typeahead', { bubbles: true, composed: true });\n}\n/**\n * Keys that are used to navigate menus.\n */\n// tslint:disable-next-line:enforce-name-casing We are mimicking enum style\nexport const NavigableKey = {\n UP: 'ArrowUp',\n DOWN: 'ArrowDown',\n RIGHT: 'ArrowRight',\n LEFT: 'ArrowLeft',\n};\n/**\n * Keys that are used for selection in menus.\n */\n// tslint:disable-next-line:enforce-name-casing We are mimicking enum style\nexport const SelectionKey = {\n SPACE: 'Space',\n ENTER: 'Enter',\n};\n/**\n * Default close `Reason` kind values.\n */\n// tslint:disable-next-line:enforce-name-casing We are mimicking enum style\nexport const CloseReason = {\n CLICK_SELECTION: 'click-selection',\n KEYDOWN: 'keydown',\n};\n/**\n * Keys that can close menus.\n */\n// tslint:disable-next-line:enforce-name-casing We are mimicking enum style\nexport const KeydownCloseKey = {\n ESCAPE: 'Escape',\n SPACE: SelectionKey.SPACE,\n ENTER: SelectionKey.ENTER,\n};\n/**\n * Determines whether the given key code is a key code that should close the\n * menu.\n *\n * @param code The KeyboardEvent code to check.\n * @return Whether or not the key code is in the predetermined list to close the\n * menu.\n */\nexport function isClosableKey(code) {\n return Object.values(KeydownCloseKey).some((value) => value === code);\n}\n/**\n * Determines whether the given key code is a key code that should select a menu\n * item.\n *\n * @param code They KeyboardEvent code to check.\n * @return Whether or not the key code is in the predetermined list to select a\n * menu item.\n */\nexport function isSelectableKey(code) {\n return Object.values(SelectionKey).some((value) => value === code);\n}\n/**\n * Determines whether a target element is contained inside another element's\n * composed tree.\n *\n * @param target The potential contained element.\n * @param container The potential containing element of the target.\n * @returns Whether the target element is contained inside the container's\n * composed subtree\n */\nexport function isElementInSubtree(target, container) {\n // Dispatch a composed, bubbling event to check its path to see if the\n // newly-focused element is contained in container's subtree\n const focusEv = new Event('md-contains', { bubbles: true, composed: true });\n let composedPath = [];\n const listener = (ev) => {\n composedPath = ev.composedPath();\n };\n container.addEventListener('md-contains', listener);\n target.dispatchEvent(focusEv);\n container.removeEventListener('md-contains', listener);\n const isContained = composedPath.length > 0;\n return isContained;\n}\n/**\n * Element to focus on when menu is first opened.\n */\n// tslint:disable-next-line:enforce-name-casing We are mimicking enum style\nexport const FocusState = {\n NONE: 'none',\n LIST_ROOT: 'list-root',\n FIRST_ITEM: 'first-item',\n LAST_ITEM: 'last-item',\n};\n//# sourceMappingURL=shared.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n/**\n * An enum of supported Menu corners\n */\n// tslint:disable-next-line:enforce-name-casing We are mimicking enum style\nexport const Corner = {\n END_START: 'end-start',\n END_END: 'end-end',\n START_START: 'start-start',\n START_END: 'start-end',\n};\n/**\n * Given a surface, an anchor, corners, and some options, this surface will\n * calculate the position of a surface to align the two given corners and keep\n * the surface inside the window viewport. It also provides a StyleInfo map that\n * can be applied to the surface to handle visiblility and position.\n */\nexport class SurfacePositionController {\n /**\n * @param host The host to connect the controller to.\n * @param getProperties A function that returns the properties for the\n * controller.\n */\n constructor(host, getProperties) {\n this.host = host;\n this.getProperties = getProperties;\n // The current styles to apply to the surface.\n this.surfaceStylesInternal = {\n 'display': 'none',\n };\n // Previous values stored for change detection. Open change detection is\n // calculated separately so initialize it here.\n this.lastValues = {\n isOpen: false,\n };\n this.host.addController(this);\n }\n /**\n * The StyleInfo map to apply to the surface via Lit's stylemap\n */\n get surfaceStyles() {\n return this.surfaceStylesInternal;\n }\n /**\n * Calculates the surface's new position required so that the surface's\n * `surfaceCorner` aligns to the anchor's `anchorCorner` while keeping the\n * surface inside the window viewport. This positioning also respects RTL by\n * checking `getComputedStyle()` on the surface element.\n */\n async position() {\n const { surfaceEl, anchorEl, anchorCorner: anchorCornerRaw, surfaceCorner: surfaceCornerRaw, positioning, xOffset, yOffset, disableBlockFlip, disableInlineFlip, repositionStrategy, } = this.getProperties();\n const anchorCorner = anchorCornerRaw.toLowerCase().trim();\n const surfaceCorner = surfaceCornerRaw.toLowerCase().trim();\n if (!surfaceEl || !anchorEl) {\n return;\n }\n // Store these before we potentially resize the window with the next set of\n // lines\n const windowInnerWidth = window.innerWidth;\n const windowInnerHeight = window.innerHeight;\n const div = document.createElement('div');\n div.style.opacity = '0';\n div.style.position = 'fixed';\n div.style.display = 'block';\n div.style.inset = '0';\n document.body.appendChild(div);\n const scrollbarTestRect = div.getBoundingClientRect();\n div.remove();\n // Calculate the widths of the scrollbars in the inline and block directions\n // to account for window-relative calculations.\n const blockScrollbarHeight = window.innerHeight - scrollbarTestRect.bottom;\n const inlineScrollbarWidth = window.innerWidth - scrollbarTestRect.right;\n // Paint the surface transparently so that we can get the position and the\n // rect info of the surface.\n this.surfaceStylesInternal = {\n 'display': 'block',\n 'opacity': '0',\n };\n // Wait for it to be visible.\n this.host.requestUpdate();\n await this.host.updateComplete;\n // Safari has a bug that makes popovers render incorrectly if the node is\n // made visible + Animation Frame before calling showPopover().\n // https://bugs.webkit.org/show_bug.cgi?id=264069\n // also the cast is required due to differing TS types in Google and OSS.\n if (surfaceEl.popover &&\n surfaceEl.isConnected) {\n surfaceEl.showPopover();\n }\n const surfaceRect = surfaceEl.getSurfacePositionClientRect\n ? surfaceEl.getSurfacePositionClientRect()\n : surfaceEl.getBoundingClientRect();\n const anchorRect = anchorEl.getSurfacePositionClientRect\n ? anchorEl.getSurfacePositionClientRect()\n : anchorEl.getBoundingClientRect();\n const [surfaceBlock, surfaceInline] = surfaceCorner.split('-');\n const [anchorBlock, anchorInline] = anchorCorner.split('-');\n // LTR depends on the direction of the SURFACE not the anchor.\n const isLTR = getComputedStyle(surfaceEl).direction === 'ltr';\n /*\n * For more on inline and block dimensions, see MDN article:\n * https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_logical_properties_and_values\n *\n * ┌───── inline/blockDocumentOffset inlineScrollbarWidth\n * │ │ │\n * │ ┌─▼─────┐ │Document\n * │ ┌┼───────┴──────────────────────────────┼────────┐\n * │ ││ │ │\n * └──► ││ ┌───── inline/blockWindowOffset │ │\n * ││ │ │ ▼ │\n * ││ │ ┌─▼───┐ Window┌┐ │\n * └┤ │ ┌┼─────┴───────────────────────┼│ │\n * │ │ ││ ││ │\n * │ └──► ││ ┌──inline/blockAnchorOffset││ │\n * │ ││ │ │ ││ │\n * │ └┤ │ ┌──▼───┐ ││ │\n * │ │ │ ┌┼──────┤ ││ │\n * │ │ └─►│Anchor│ ││ │\n * │ │ └┴──────┘ ││ │\n * │ │ ││ │\n * │ │ ┌───────────────────────┼┼────┐ │\n * │ │ │ Surface ││ │ │\n * │ │ │ ││ │ │\n * │ │ │ ││ │ │\n * │ │ │ ││ │ │\n * │ │ │ ││ │ │\n * │ ┌┼─────┼───────────────────────┼│ │ │\n * │ ┌─►┴──────┼────────────────────────┘ ├┐ │\n * │ │ │ inline/blockOOBCorrection ││ │\n * │ │ │ │ ││ │\n * │ │ │ ├──►├│ │\n * │ │ │ │ ││ │\n * │ │ └────────────────────────┐▼───┼┘ │\n * │ blockScrollbarHeight └────┘ │\n * │ │\n * └───────────────────────────────────────────────┘\n */\n // Calculate the block positioning properties\n let { blockInset, blockOutOfBoundsCorrection, surfaceBlockProperty } = this.calculateBlock({\n surfaceRect,\n anchorRect,\n anchorBlock,\n surfaceBlock,\n yOffset,\n positioning,\n windowInnerHeight,\n blockScrollbarHeight,\n });\n // If the surface should be out of bounds in the block direction, flip the\n // surface and anchor corner block values and recalculate\n if (blockOutOfBoundsCorrection && !disableBlockFlip) {\n const flippedSurfaceBlock = surfaceBlock === 'start' ? 'end' : 'start';\n const flippedAnchorBlock = anchorBlock === 'start' ? 'end' : 'start';\n const flippedBlock = this.calculateBlock({\n surfaceRect,\n anchorRect,\n anchorBlock: flippedAnchorBlock,\n surfaceBlock: flippedSurfaceBlock,\n yOffset,\n positioning,\n windowInnerHeight,\n blockScrollbarHeight,\n });\n // In the case that the flipped verion would require less out of bounds\n // correcting, use the flipped corner block values\n if (blockOutOfBoundsCorrection > flippedBlock.blockOutOfBoundsCorrection) {\n blockInset = flippedBlock.blockInset;\n blockOutOfBoundsCorrection = flippedBlock.blockOutOfBoundsCorrection;\n surfaceBlockProperty = flippedBlock.surfaceBlockProperty;\n }\n }\n // Calculate the inline positioning properties\n let { inlineInset, inlineOutOfBoundsCorrection, surfaceInlineProperty } = this.calculateInline({\n surfaceRect,\n anchorRect,\n anchorInline,\n surfaceInline,\n xOffset,\n positioning,\n isLTR,\n windowInnerWidth,\n inlineScrollbarWidth,\n });\n // If the surface should be out of bounds in the inline direction, flip the\n // surface and anchor corner inline values and recalculate\n if (inlineOutOfBoundsCorrection && !disableInlineFlip) {\n const flippedSurfaceInline = surfaceInline === 'start' ? 'end' : 'start';\n const flippedAnchorInline = anchorInline === 'start' ? 'end' : 'start';\n const flippedInline = this.calculateInline({\n surfaceRect,\n anchorRect,\n anchorInline: flippedAnchorInline,\n surfaceInline: flippedSurfaceInline,\n xOffset,\n positioning,\n isLTR,\n windowInnerWidth,\n inlineScrollbarWidth,\n });\n // In the case that the flipped verion would require less out of bounds\n // correcting, use the flipped corner inline values\n if (Math.abs(inlineOutOfBoundsCorrection) >\n Math.abs(flippedInline.inlineOutOfBoundsCorrection)) {\n inlineInset = flippedInline.inlineInset;\n inlineOutOfBoundsCorrection = flippedInline.inlineOutOfBoundsCorrection;\n surfaceInlineProperty = flippedInline.surfaceInlineProperty;\n }\n }\n // If we are simply repositioning the surface back inside the viewport,\n // subtract the out of bounds correction values from the positioning.\n if (repositionStrategy === 'move') {\n blockInset = blockInset - blockOutOfBoundsCorrection;\n inlineInset = inlineInset - inlineOutOfBoundsCorrection;\n }\n this.surfaceStylesInternal = {\n 'display': 'block',\n 'opacity': '1',\n [surfaceBlockProperty]: `${blockInset}px`,\n [surfaceInlineProperty]: `${inlineInset}px`,\n };\n // In the case that we are resizing the surface to stay inside the viewport\n // we need to set height and width on the surface.\n if (repositionStrategy === 'resize') {\n // Add a height property to the styles if there is block height correction\n if (blockOutOfBoundsCorrection) {\n this.surfaceStylesInternal['height'] = `${surfaceRect.height - blockOutOfBoundsCorrection}px`;\n }\n // Add a width property to the styles if there is block height correction\n if (inlineOutOfBoundsCorrection) {\n this.surfaceStylesInternal['width'] = `${surfaceRect.width - inlineOutOfBoundsCorrection}px`;\n }\n }\n this.host.requestUpdate();\n }\n /**\n * Calculates the css property, the inset, and the out of bounds correction\n * for the surface in the block direction.\n */\n calculateBlock(config) {\n const { surfaceRect, anchorRect, anchorBlock, surfaceBlock, yOffset, positioning, windowInnerHeight, blockScrollbarHeight, } = config;\n // We use number booleans to multiply values rather than `if` / ternary\n // statements because it _heavily_ cuts down on nesting and readability\n const relativeToWindow = positioning === 'fixed' || positioning === 'document' ? 1 : 0;\n const relativeToDocument = positioning === 'document' ? 1 : 0;\n const isSurfaceBlockStart = surfaceBlock === 'start' ? 1 : 0;\n const isSurfaceBlockEnd = surfaceBlock === 'end' ? 1 : 0;\n const isOneBlockEnd = anchorBlock !== surfaceBlock ? 1 : 0;\n // Whether or not to apply the height of the anchor\n const blockAnchorOffset = isOneBlockEnd * anchorRect.height + yOffset;\n // The absolute block position of the anchor relative to window\n const blockTopLayerOffset = isSurfaceBlockStart * anchorRect.top +\n isSurfaceBlockEnd *\n (windowInnerHeight - anchorRect.bottom - blockScrollbarHeight);\n const blockDocumentOffset = isSurfaceBlockStart * window.scrollY - isSurfaceBlockEnd * window.scrollY;\n // If the surface's block would be out of bounds of the window, move it back\n // in\n const blockOutOfBoundsCorrection = Math.abs(Math.min(0, windowInnerHeight -\n blockTopLayerOffset -\n blockAnchorOffset -\n surfaceRect.height));\n // The block logical value of the surface\n const blockInset = relativeToWindow * blockTopLayerOffset +\n relativeToDocument * blockDocumentOffset +\n blockAnchorOffset;\n const surfaceBlockProperty = surfaceBlock === 'start' ? 'inset-block-start' : 'inset-block-end';\n return { blockInset, blockOutOfBoundsCorrection, surfaceBlockProperty };\n }\n /**\n * Calculates the css property, the inset, and the out of bounds correction\n * for the surface in the inline direction.\n */\n calculateInline(config) {\n const { isLTR: isLTRBool, surfaceInline, anchorInline, anchorRect, surfaceRect, xOffset, positioning, windowInnerWidth, inlineScrollbarWidth, } = config;\n // We use number booleans to multiply values rather than `if` / ternary\n // statements because it _heavily_ cuts down on nesting and readability\n const relativeToWindow = positioning === 'fixed' || positioning === 'document' ? 1 : 0;\n const relativeToDocument = positioning === 'document' ? 1 : 0;\n const isLTR = isLTRBool ? 1 : 0;\n const isRTL = isLTRBool ? 0 : 1;\n const isSurfaceInlineStart = surfaceInline === 'start' ? 1 : 0;\n const isSurfaceInlineEnd = surfaceInline === 'end' ? 1 : 0;\n const isOneInlineEnd = anchorInline !== surfaceInline ? 1 : 0;\n // Whether or not to apply the width of the anchor\n const inlineAnchorOffset = isOneInlineEnd * anchorRect.width + xOffset;\n // The inline position of the anchor relative to window in LTR\n const inlineTopLayerOffsetLTR = isSurfaceInlineStart * anchorRect.left +\n isSurfaceInlineEnd *\n (windowInnerWidth - anchorRect.right - inlineScrollbarWidth);\n // The inline position of the anchor relative to window in RTL\n const inlineTopLayerOffsetRTL = isSurfaceInlineStart *\n (windowInnerWidth - anchorRect.right - inlineScrollbarWidth) +\n isSurfaceInlineEnd * anchorRect.left;\n // The inline position of the anchor relative to window\n const inlineTopLayerOffset = isLTR * inlineTopLayerOffsetLTR + isRTL * inlineTopLayerOffsetRTL;\n // The inline position of the anchor relative to window in LTR\n const inlineDocumentOffsetLTR = isSurfaceInlineStart * window.scrollX -\n isSurfaceInlineEnd * window.scrollX;\n // The inline position of the anchor relative to window in RTL\n const inlineDocumentOffsetRTL = isSurfaceInlineEnd * window.scrollX -\n isSurfaceInlineStart * window.scrollX;\n // The inline position of the anchor relative to window\n const inlineDocumentOffset = isLTR * inlineDocumentOffsetLTR + isRTL * inlineDocumentOffsetRTL;\n // If the surface's inline would be out of bounds of the window, move it\n // back in\n const inlineOutOfBoundsCorrection = Math.abs(Math.min(0, windowInnerWidth -\n inlineTopLayerOffset -\n inlineAnchorOffset -\n surfaceRect.width));\n // The inline logical value of the surface\n const inlineInset = relativeToWindow * inlineTopLayerOffset +\n inlineAnchorOffset +\n relativeToDocument * inlineDocumentOffset;\n let surfaceInlineProperty = surfaceInline === 'start' ? 'inset-inline-start' : 'inset-inline-end';\n // There are cases where the element is RTL but the root of the page is not.\n // In these cases we want to not use logical properties.\n if (positioning === 'document' || positioning === 'fixed') {\n if ((surfaceInline === 'start' && isLTRBool) ||\n (surfaceInline === 'end' && !isLTRBool)) {\n surfaceInlineProperty = 'left';\n }\n else {\n surfaceInlineProperty = 'right';\n }\n }\n return {\n inlineInset,\n inlineOutOfBoundsCorrection,\n surfaceInlineProperty,\n };\n }\n hostUpdate() {\n this.onUpdate();\n }\n hostUpdated() {\n this.onUpdate();\n }\n /**\n * Checks whether the properties passed into the controller have changed since\n * the last positioning. If so, it will reposition if the surface is open or\n * close it if the surface should close.\n */\n async onUpdate() {\n const props = this.getProperties();\n let hasChanged = false;\n for (const [key, value] of Object.entries(props)) {\n // tslint:disable-next-line\n hasChanged = hasChanged || value !== this.lastValues[key];\n if (hasChanged)\n break;\n }\n const openChanged = this.lastValues.isOpen !== props.isOpen;\n const hasAnchor = !!props.anchorEl;\n const hasSurface = !!props.surfaceEl;\n if (hasChanged && hasAnchor && hasSurface) {\n // Only update isOpen, because if it's closed, we do not want to waste\n // time on a useless reposition calculation. So save the other \"dirty\"\n // values until next time it opens.\n this.lastValues.isOpen = props.isOpen;\n if (props.isOpen) {\n // We are going to do a reposition, so save the prop values for future\n // dirty checking.\n this.lastValues = props;\n await this.position();\n props.onOpen();\n }\n else if (openChanged) {\n await props.beforeClose();\n this.close();\n props.onClose();\n }\n }\n }\n /**\n * Hides the surface.\n */\n close() {\n this.surfaceStylesInternal = {\n 'display': 'none',\n };\n this.host.requestUpdate();\n const surfaceEl = this.getProperties().surfaceEl;\n // The following type casts are required due to differing TS types in Google\n // and open source.\n if (surfaceEl?.popover &&\n surfaceEl?.isConnected) {\n surfaceEl.hidePopover();\n }\n }\n}\n//# sourceMappingURL=surfacePositionController.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n/**\n * Indicies to access the TypeaheadRecord tuple type.\n */\nexport const TYPEAHEAD_RECORD = {\n INDEX: 0,\n ITEM: 1,\n TEXT: 2,\n};\n/**\n * This controller listens to `keydown` events and searches the header text of\n * an array of `MenuItem`s with the corresponding entered keys within the buffer\n * time and activates the item.\n *\n * @example\n * ```ts\n * const typeaheadController = new TypeaheadController(() => ({\n * typeaheadBufferTime: 50,\n * getItems: () => Array.from(document.querySelectorAll('md-menu-item'))\n * }));\n * html`\n * <div\n * @keydown=${typeaheadController.onKeydown}\n * tabindex=\"0\"\n * class=\"activeItemText\">\n * <!-- focusable element that will receive keydown events -->\n * Apple\n * </div>\n * <div>\n * <md-menu-item active header=\"Apple\"></md-menu-item>\n * <md-menu-item header=\"Apricot\"></md-menu-item>\n * <md-menu-item header=\"Banana\"></md-menu-item>\n * <md-menu-item header=\"Olive\"></md-menu-item>\n * <md-menu-item header=\"Orange\"></md-menu-item>\n * </div>\n * `;\n * ```\n */\nexport class TypeaheadController {\n /**\n * @param getProperties A function that returns the options of the typeahead\n * controller:\n *\n * {\n * getItems: A function that returns an array of menu items to be searched.\n * typeaheadBufferTime: The maximum time between each keystroke to keep the\n * current type buffer alive.\n * }\n */\n constructor(getProperties) {\n this.getProperties = getProperties;\n /**\n * Array of tuples that helps with indexing.\n */\n this.typeaheadRecords = [];\n /**\n * Currently-typed text since last buffer timeout\n */\n this.typaheadBuffer = '';\n /**\n * The timeout id from the current buffer's setTimeout\n */\n this.cancelTypeaheadTimeout = 0;\n /**\n * If we are currently \"typing\"\n */\n this.isTypingAhead = false;\n /**\n * The record of the last active item.\n */\n this.lastActiveRecord = null;\n /**\n * Apply this listener to the element that will receive `keydown` events that\n * should trigger this controller.\n *\n * @param event The native browser `KeyboardEvent` from the `keydown` event.\n */\n this.onKeydown = (event) => {\n if (this.isTypingAhead) {\n this.typeahead(event);\n }\n else {\n this.beginTypeahead(event);\n }\n };\n /**\n * Ends the current typeahead and clears the buffer.\n */\n this.endTypeahead = () => {\n this.isTypingAhead = false;\n this.typaheadBuffer = '';\n this.typeaheadRecords = [];\n };\n }\n get items() {\n return this.getProperties().getItems();\n }\n get active() {\n return this.getProperties().active;\n }\n /**\n * Sets up typingahead\n */\n beginTypeahead(event) {\n if (!this.active) {\n return;\n }\n // We don't want to typeahead if the _beginning_ of the typeahead is a menu\n // navigation, or a selection. We will handle \"Space\" only if it's in the\n // middle of a typeahead\n if (event.code === 'Space' ||\n event.code === 'Enter' ||\n event.code.startsWith('Arrow') ||\n event.code === 'Escape') {\n return;\n }\n this.isTypingAhead = true;\n // Generates the record array data structure which is the index, the element\n // and a normalized header.\n this.typeaheadRecords = this.items.map((el, index) => [\n index,\n el,\n el.typeaheadText.trim().toLowerCase(),\n ]);\n this.lastActiveRecord =\n this.typeaheadRecords.find((record) => record[TYPEAHEAD_RECORD.ITEM].tabIndex === 0) ?? null;\n if (this.lastActiveRecord) {\n this.lastActiveRecord[TYPEAHEAD_RECORD.ITEM].tabIndex = -1;\n }\n this.typeahead(event);\n }\n /**\n * Performs the typeahead. Based on the normalized items and the current text\n * buffer, finds the _next_ item with matching text and activates it.\n *\n * @example\n *\n * items: Apple, Banana, Olive, Orange, Cucumber\n * buffer: ''\n * user types: o\n *\n * activates Olive\n *\n * @example\n *\n * items: Apple, Banana, Olive (active), Orange, Cucumber\n * buffer: 'o'\n * user types: l\n *\n * activates Olive\n *\n * @example\n *\n * items: Apple, Banana, Olive (active), Orange, Cucumber\n * buffer: ''\n * user types: o\n *\n * activates Orange\n *\n * @example\n *\n * items: Apple, Banana, Olive, Orange (active), Cucumber\n * buffer: ''\n * user types: o\n *\n * activates Olive\n */\n typeahead(event) {\n if (event.defaultPrevented)\n return;\n clearTimeout(this.cancelTypeaheadTimeout);\n // Stop typingahead if one of the navigation or selection keys (except for\n // Space) are pressed\n if (event.code === 'Enter' ||\n event.code.startsWith('Arrow') ||\n event.code === 'Escape') {\n this.endTypeahead();\n if (this.lastActiveRecord) {\n this.lastActiveRecord[TYPEAHEAD_RECORD.ITEM].tabIndex = -1;\n }\n return;\n }\n // If Space is pressed, prevent it from selecting and closing the menu\n if (event.code === 'Space') {\n event.preventDefault();\n }\n // Start up a new keystroke buffer timeout\n this.cancelTypeaheadTimeout = setTimeout(this.endTypeahead, this.getProperties().typeaheadBufferTime);\n this.typaheadBuffer += event.key.toLowerCase();\n const lastActiveIndex = this.lastActiveRecord\n ? this.lastActiveRecord[TYPEAHEAD_RECORD.INDEX]\n : -1;\n const numRecords = this.typeaheadRecords.length;\n /**\n * Sorting function that will resort the items starting with the given index\n *\n * @example\n *\n * this.typeaheadRecords =\n * 0: [0, <reference>, 'apple']\n * 1: [1, <reference>, 'apricot']\n * 2: [2, <reference>, 'banana']\n * 3: [3, <reference>, 'olive'] <-- lastActiveIndex\n * 4: [4, <reference>, 'orange']\n * 5: [5, <reference>, 'strawberry']\n *\n * this.typeaheadRecords.sort((a,b) => rebaseIndexOnActive(a)\n * - rebaseIndexOnActive(b)) ===\n * 0: [3, <reference>, 'olive'] <-- lastActiveIndex\n * 1: [4, <reference>, 'orange']\n * 2: [5, <reference>, 'strawberry']\n * 3: [0, <reference>, 'apple']\n * 4: [1, <reference>, 'apricot']\n * 5: [2, <reference>, 'banana']\n */\n const rebaseIndexOnActive = (record) => {\n return ((record[TYPEAHEAD_RECORD.INDEX] + numRecords - lastActiveIndex) %\n numRecords);\n };\n // records filtered and sorted / rebased around the last active index\n const matchingRecords = this.typeaheadRecords\n .filter((record) => !record[TYPEAHEAD_RECORD.ITEM].disabled &&\n record[TYPEAHEAD_RECORD.TEXT].startsWith(this.typaheadBuffer))\n .sort((a, b) => rebaseIndexOnActive(a) - rebaseIndexOnActive(b));\n // Just leave if there's nothing that matches. Native select will just\n // choose the first thing that starts with the next letter in the alphabet\n // but that's out of scope and hard to localize\n if (matchingRecords.length === 0) {\n clearTimeout(this.cancelTypeaheadTimeout);\n if (this.lastActiveRecord) {\n this.lastActiveRecord[TYPEAHEAD_RECORD.ITEM].tabIndex = -1;\n }\n this.endTypeahead();\n return;\n }\n const isNewQuery = this.typaheadBuffer.length === 1;\n let nextRecord;\n // This is likely the case that someone is trying to \"tab\" through different\n // entries that start with the same letter\n if (this.lastActiveRecord === matchingRecords[0] && isNewQuery) {\n nextRecord = matchingRecords[1] ?? matchingRecords[0];\n }\n else {\n nextRecord = matchingRecords[0];\n }\n if (this.lastActiveRecord) {\n this.lastActiveRecord[TYPEAHEAD_RECORD.ITEM].tabIndex = -1;\n }\n this.lastActiveRecord = nextRecord;\n nextRecord[TYPEAHEAD_RECORD.ITEM].tabIndex = 0;\n nextRecord[TYPEAHEAD_RECORD.ITEM].focus();\n return;\n }\n}\n//# sourceMappingURL=typeaheadController.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { __decorate } from \"tslib\";\nimport '../../elevation/elevation.js';\nimport '../../focus/md-focus-ring.js';\nimport { LitElement, html, isServer, nothing } from 'lit';\nimport { property, query, queryAssignedElements, state } from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { styleMap } from 'lit/directives/style-map.js';\nimport { EASING, createAnimationSignal } from '../../internal/motion/animation.js';\nimport { ListController, NavigableKeys, } from '../../list/internal/list-controller.js';\nimport { getActiveItem, getFirstActivatableItem, getLastActivatableItem, } from '../../list/internal/list-navigation-helpers.js';\nimport { FocusState, isClosableKey, isElementInSubtree, } from './controllers/shared.js';\nimport { Corner, SurfacePositionController, } from './controllers/surfacePositionController.js';\nimport { TypeaheadController } from './controllers/typeaheadController.js';\nexport { Corner } from './controllers/surfacePositionController.js';\n/**\n * The default value for the typeahead buffer time in Milliseconds.\n */\nexport const DEFAULT_TYPEAHEAD_BUFFER_TIME = 200;\nconst submenuNavKeys = new Set([\n NavigableKeys.ArrowDown,\n NavigableKeys.ArrowUp,\n NavigableKeys.Home,\n NavigableKeys.End,\n]);\nconst menuNavKeys = new Set([\n NavigableKeys.ArrowLeft,\n NavigableKeys.ArrowRight,\n ...submenuNavKeys,\n]);\n/**\n * Gets the currently focused element on the page.\n *\n * @param activeDoc The document or shadowroot from which to start the search.\n * Defaults to `window.document`\n * @return Returns the currently deeply focused element or `null` if none.\n */\nfunction getFocusedElement(activeDoc = document) {\n let activeEl = activeDoc.activeElement;\n // Check for activeElement in the case that an element with a shadow root host\n // is currently focused.\n while (activeEl && activeEl?.shadowRoot?.activeElement) {\n activeEl = activeEl.shadowRoot.activeElement;\n }\n return activeEl;\n}\n/**\n * @fires opening {Event} Fired before the opening animation begins\n * @fires opened {Event} Fired once the menu is open, after any animations\n * @fires closing {Event} Fired before the closing animation begins\n * @fires closed {Event} Fired once the menu is closed, after any animations\n */\nexport class Menu extends LitElement {\n /**\n * Whether the menu is animating upwards or downwards when opening. This is\n * helpful for calculating some animation calculations.\n */\n get openDirection() {\n const menuCornerBlock = this.menuCorner.split('-')[0];\n return menuCornerBlock === 'start' ? 'DOWN' : 'UP';\n }\n /**\n * The element which the menu should align to. If `anchor` is set to a\n * non-empty idref string, then `anchorEl` will resolve to the element with\n * the given id in the same root node. Otherwise, `null`.\n */\n get anchorElement() {\n if (this.anchor) {\n return this.getRootNode().querySelector(`#${this.anchor}`);\n }\n return this.currentAnchorElement;\n }\n set anchorElement(element) {\n this.currentAnchorElement = element;\n this.requestUpdate('anchorElement');\n }\n constructor() {\n super();\n /**\n * The ID of the element in the same root node in which the menu should align\n * to. Overrides setting `anchorElement = elementReference`.\n *\n * __NOTE__: anchor or anchorElement must either be an HTMLElement or resolve\n * to an HTMLElement in order for menu to open.\n */\n this.anchor = '';\n /**\n * Whether the positioning algorithm should calculate relative to the parent\n * of the anchor element (`absolute`), relative to the window (`fixed`), or\n * relative to the document (`document`). `popover` will use the popover API\n * to render the menu in the top-layer. If your browser does not support the\n * popover API, it will fall back to `fixed`.\n *\n * __Examples for `position = 'fixed'`:__\n *\n * - If there is no `position:relative` in the given parent tree and the\n * surface is `position:absolute`\n * - If the surface is `position:fixed`\n * - If the surface is in the \"top layer\"\n * - The anchor and the surface do not share a common `position:relative`\n * ancestor\n *\n * When using `positioning=fixed`, in most cases, the menu should position\n * itself above most other `position:absolute` or `position:fixed` elements\n * when placed inside of them. e.g. using a menu inside of an `md-dialog`.\n *\n * __NOTE__: Fixed menus will not scroll with the page and will be fixed to\n * the window instead.\n *\n * __Examples for `position = 'document'`:__\n *\n * - There is no parent that creates a relative positioning context e.g.\n * `position: relative`, `position: absolute`, `transform: translate(x, y)`,\n * etc.\n * - You put the effort into hoisting the menu to the top of the DOM like the\n * end of the `<body>` to render over everything or in a top-layer.\n * - You are reusing a single `md-menu` element that dynamically renders\n * content.\n *\n * __Examples for `position = 'popover'`:__\n *\n * - Your browser supports `popover`.\n * - Most cases. Once popover is in browsers, this will become the default.\n */\n this.positioning = 'absolute';\n /**\n * Skips the opening and closing animations.\n */\n this.quick = false;\n /**\n * Displays overflow content like a submenu. Not required in most cases when\n * using `positioning=\"popover\"`.\n *\n * __NOTE__: This may cause adverse effects if you set\n * `md-menu {max-height:...}`\n * and have items overflowing items in the \"y\" direction.\n */\n this.hasOverflow = false;\n /**\n * Opens the menu and makes it visible. Alternative to the `.show()` and\n * `.close()` methods\n */\n this.open = false;\n /**\n * Offsets the menu's inline alignment from the anchor by the given number in\n * pixels. This value is direction aware and will follow the LTR / RTL\n * direction.\n *\n * e.g. LTR: positive -> right, negative -> left\n * RTL: positive -> left, negative -> right\n */\n this.xOffset = 0;\n /**\n * Offsets the menu's block alignment from the anchor by the given number in\n * pixels.\n *\n * e.g. positive -> down, negative -> up\n */\n this.yOffset = 0;\n /**\n * Disable the `flip` behavior that usually happens on the horizontal axis\n * when the surface would render outside the viewport.\n */\n this.noHorizontalFlip = false;\n /**\n * Disable the `flip` behavior that usually happens on the vertical axis when\n * the surface would render outside the viewport.\n */\n this.noVerticalFlip = false;\n /**\n * The max time between the keystrokes of the typeahead menu behavior before\n * it clears the typeahead buffer.\n */\n this.typeaheadDelay = DEFAULT_TYPEAHEAD_BUFFER_TIME;\n /**\n * The corner of the anchor which to align the menu in the standard logical\n * property style of <block>-<inline> e.g. `'end-start'`.\n *\n * NOTE: This value may not be respected by the menu positioning algorithm\n * if the menu would render outisde the viewport.\n * Use `no-horizontal-flip` or `no-vertical-flip` to force the usage of the value\n */\n this.anchorCorner = Corner.END_START;\n /**\n * The corner of the menu which to align the anchor in the standard logical\n * property style of <block>-<inline> e.g. `'start-start'`.\n *\n * NOTE: This value may not be respected by the menu positioning algorithm\n * if the menu would render outisde the viewport.\n * Use `no-horizontal-flip` or `no-vertical-flip` to force the usage of the value\n */\n this.menuCorner = Corner.START_START;\n /**\n * Keeps the user clicks outside the menu.\n *\n * NOTE: clicking outside may still cause focusout to close the menu so see\n * `stayOpenOnFocusout`.\n */\n this.stayOpenOnOutsideClick = false;\n /**\n * Keeps the menu open when focus leaves the menu's composed subtree.\n *\n * NOTE: Focusout behavior will stop propagation of the focusout event. Set\n * this property to true to opt-out of menu's focusout handling altogether.\n */\n this.stayOpenOnFocusout = false;\n /**\n * After closing, does not restore focus to the last focused element before\n * the menu was opened.\n */\n this.skipRestoreFocus = false;\n /**\n * The element that should be focused by default once opened.\n *\n * NOTE: When setting default focus to 'LIST_ROOT', remember to change\n * `tabindex` to `0` and change md-menu's display to something other than\n * `display: contents` when necessary.\n */\n this.defaultFocus = FocusState.FIRST_ITEM;\n /**\n * Turns off navigation wrapping. By default, navigating past the end of the\n * menu items will wrap focus back to the beginning and vice versa. Use this\n * for ARIA patterns that do not wrap focus, like combobox.\n */\n this.noNavigationWrap = false;\n this.typeaheadActive = true;\n /**\n * Whether or not the current menu is a submenu and should not handle specific\n * navigation keys.\n *\n * @export\n */\n this.isSubmenu = false;\n /**\n * The event path of the last window pointerdown event.\n */\n this.pointerPath = [];\n /**\n * Whether or not the menu is repositoining due to window / document resize\n */\n this.isRepositioning = false;\n this.openCloseAnimationSignal = createAnimationSignal();\n this.listController = new ListController({\n isItem: (maybeItem) => {\n return maybeItem.hasAttribute('md-menu-item');\n },\n getPossibleItems: () => this.slotItems,\n isRtl: () => getComputedStyle(this).direction === 'rtl',\n deactivateItem: (item) => {\n item.selected = false;\n item.tabIndex = -1;\n },\n activateItem: (item) => {\n item.selected = true;\n item.tabIndex = 0;\n },\n isNavigableKey: (key) => {\n if (!this.isSubmenu) {\n return menuNavKeys.has(key);\n }\n const isRtl = getComputedStyle(this).direction === 'rtl';\n // we want md-submenu to handle the submenu's left/right arrow exit\n // key so it can close the menu instead of navigate the list.\n // Therefore we need to include all keys but left/right arrow close\n // key\n const arrowOpen = isRtl\n ? NavigableKeys.ArrowLeft\n : NavigableKeys.ArrowRight;\n if (key === arrowOpen) {\n return true;\n }\n return submenuNavKeys.has(key);\n },\n wrapNavigation: () => !this.noNavigationWrap,\n });\n /**\n * The element that was focused before the menu opened.\n */\n this.lastFocusedElement = null;\n /**\n * Handles typeahead navigation through the menu.\n */\n this.typeaheadController = new TypeaheadController(() => {\n return {\n getItems: () => this.items,\n typeaheadBufferTime: this.typeaheadDelay,\n active: this.typeaheadActive,\n };\n });\n this.currentAnchorElement = null;\n this.internals = \n // Cast needed for closure\n this.attachInternals();\n /**\n * Handles positioning the surface and aligning it to the anchor as well as\n * keeping it in the viewport.\n */\n this.menuPositionController = new SurfacePositionController(this, () => {\n return {\n anchorCorner: this.anchorCorner,\n surfaceCorner: this.menuCorner,\n surfaceEl: this.surfaceEl,\n anchorEl: this.anchorElement,\n positioning: this.positioning === 'popover' ? 'document' : this.positioning,\n isOpen: this.open,\n xOffset: this.xOffset,\n yOffset: this.yOffset,\n disableBlockFlip: this.noVerticalFlip,\n disableInlineFlip: this.noHorizontalFlip,\n onOpen: this.onOpened,\n beforeClose: this.beforeClose,\n onClose: this.onClosed,\n // We can't resize components that have overflow like menus with\n // submenus because the overflow-y will show menu items / content\n // outside the bounds of the menu. Popover API fixes this because each\n // submenu is hoisted to the top-layer and are not considered overflow\n // content.\n repositionStrategy: this.hasOverflow && this.positioning !== 'popover'\n ? 'move'\n : 'resize',\n };\n });\n this.onWindowResize = () => {\n if (this.isRepositioning ||\n (this.positioning !== 'document' &&\n this.positioning !== 'fixed' &&\n this.positioning !== 'popover')) {\n return;\n }\n this.isRepositioning = true;\n this.reposition();\n this.isRepositioning = false;\n };\n this.handleFocusout = async (event) => {\n const anchorEl = this.anchorElement;\n // Do not close if we focused out by clicking on the anchor element. We\n // can't assume anchor buttons can be the related target because of iOS does\n // not focus buttons.\n if (this.stayOpenOnFocusout ||\n !this.open ||\n this.pointerPath.includes(anchorEl)) {\n return;\n }\n if (event.relatedTarget) {\n // Don't close the menu if we are switching focus between menu,\n // md-menu-item, and md-list or if the anchor was click focused, but check\n // if length of pointerPath is 0 because that means something was at least\n // clicked (shift+tab case).\n if (isElementInSubtree(event.relatedTarget, this) ||\n (this.pointerPath.length !== 0 &&\n isElementInSubtree(event.relatedTarget, anchorEl))) {\n return;\n }\n }\n else if (this.pointerPath.includes(this)) {\n // If menu tabindex == -1 and the user clicks on the menu or a divider, we\n // want to keep the menu open.\n return;\n }\n const oldRestoreFocus = this.skipRestoreFocus;\n // allow focus to continue to the next focused object rather than returning\n this.skipRestoreFocus = true;\n this.close();\n // await for close\n await this.updateComplete;\n // return to previous behavior\n this.skipRestoreFocus = oldRestoreFocus;\n };\n /**\n * Saves the last focused element focuses the new element based on\n * `defaultFocus`, and animates open.\n */\n this.onOpened = async () => {\n this.lastFocusedElement = getFocusedElement();\n const items = this.items;\n const activeItemRecord = getActiveItem(items);\n if (activeItemRecord && this.defaultFocus !== FocusState.NONE) {\n activeItemRecord.item.tabIndex = -1;\n }\n let animationAborted = !this.quick;\n if (this.quick) {\n this.dispatchEvent(new Event('opening'));\n }\n else {\n animationAborted = !!(await this.animateOpen());\n }\n // This must come after the opening animation or else it may focus one of\n // the items before the animation has begun and causes the list to slide\n // (block-padding-of-the-menu)px at the end of the animation\n switch (this.defaultFocus) {\n case FocusState.FIRST_ITEM:\n const first = getFirstActivatableItem(items);\n if (first) {\n first.tabIndex = 0;\n first.focus();\n await first.updateComplete;\n }\n break;\n case FocusState.LAST_ITEM:\n const last = getLastActivatableItem(items);\n if (last) {\n last.tabIndex = 0;\n last.focus();\n await last.updateComplete;\n }\n break;\n case FocusState.LIST_ROOT:\n this.focus();\n break;\n default:\n case FocusState.NONE:\n // Do nothing.\n break;\n }\n if (!animationAborted) {\n this.dispatchEvent(new Event('opened'));\n }\n };\n /**\n * Animates closed.\n */\n this.beforeClose = async () => {\n this.open = false;\n if (!this.skipRestoreFocus) {\n this.lastFocusedElement?.focus?.();\n }\n if (!this.quick) {\n await this.animateClose();\n }\n };\n /**\n * Focuses the last focused element.\n */\n this.onClosed = () => {\n if (this.quick) {\n this.dispatchEvent(new Event('closing'));\n this.dispatchEvent(new Event('closed'));\n }\n };\n this.onWindowPointerdown = (event) => {\n this.pointerPath = event.composedPath();\n };\n /**\n * We cannot listen to window click because Safari on iOS will not bubble a\n * click event on window if the item clicked is not a \"clickable\" item such as\n * <body>\n */\n this.onDocumentClick = (event) => {\n if (!this.open) {\n return;\n }\n const path = event.composedPath();\n if (!this.stayOpenOnOutsideClick &&\n !path.includes(this) &&\n !path.includes(this.anchorElement)) {\n this.open = false;\n }\n };\n if (!isServer) {\n this.internals.role = 'menu';\n this.addEventListener('keydown', this.handleKeydown);\n // Capture so that we can grab the event before it reaches the menu item\n // istelf. Specifically useful for the case where typeahead encounters a\n // space and we don't want the menu item to close the menu.\n this.addEventListener('keydown', this.captureKeydown, { capture: true });\n this.addEventListener('focusout', this.handleFocusout);\n }\n }\n /**\n * The menu items associated with this menu. The items must be `MenuItem`s and\n * have both the `md-menu-item` and `md-list-item` attributes.\n */\n get items() {\n return this.listController.items;\n }\n willUpdate(changed) {\n if (!changed.has('open')) {\n return;\n }\n if (this.open) {\n this.removeAttribute('aria-hidden');\n return;\n }\n this.setAttribute('aria-hidden', 'true');\n }\n update(changed) {\n if (changed.has('open')) {\n if (this.open) {\n this.setUpGlobalEventListeners();\n }\n else {\n this.cleanUpGlobalEventListeners();\n }\n }\n // Firefox does not support popover. Fall-back to using fixed.\n if (changed.has('positioning') &&\n this.positioning === 'popover' &&\n // type required for Google JS conformance\n !this.showPopover) {\n this.positioning = 'fixed';\n }\n super.update(changed);\n }\n connectedCallback() {\n super.connectedCallback();\n if (this.open) {\n this.setUpGlobalEventListeners();\n }\n }\n disconnectedCallback() {\n super.disconnectedCallback();\n this.cleanUpGlobalEventListeners();\n }\n getBoundingClientRect() {\n if (!this.surfaceEl) {\n return super.getBoundingClientRect();\n }\n return this.surfaceEl.getBoundingClientRect();\n }\n getClientRects() {\n if (!this.surfaceEl) {\n return super.getClientRects();\n }\n return this.surfaceEl.getClientRects();\n }\n render() {\n return this.renderSurface();\n }\n /**\n * Renders the positionable surface element and its contents.\n */\n renderSurface() {\n return html `\n <div\n class=\"menu ${classMap(this.getSurfaceClasses())}\"\n style=${styleMap(this.menuPositionController.surfaceStyles)}\n popover=${this.positioning === 'popover' ? 'manual' : nothing}>\n ${this.renderElevation()}\n <div class=\"items\">\n <div class=\"item-padding\"> ${this.renderMenuItems()} </div>\n </div>\n </div>\n `;\n }\n /**\n * Renders the menu items' slot\n */\n renderMenuItems() {\n return html `<slot\n @close-menu=${this.onCloseMenu}\n @deactivate-items=${this.onDeactivateItems}\n @request-activation=${this.onRequestActivation}\n @deactivate-typeahead=${this.handleDeactivateTypeahead}\n @activate-typeahead=${this.handleActivateTypeahead}\n @stay-open-on-focusout=${this.handleStayOpenOnFocusout}\n @close-on-focusout=${this.handleCloseOnFocusout}\n @slotchange=${this.listController.onSlotchange}></slot>`;\n }\n /**\n * Renders the elevation component.\n */\n renderElevation() {\n return html `<md-elevation part=\"elevation\"></md-elevation>`;\n }\n getSurfaceClasses() {\n return {\n open: this.open,\n fixed: this.positioning === 'fixed',\n 'has-overflow': this.hasOverflow,\n };\n }\n captureKeydown(event) {\n if (event.target === this &&\n !event.defaultPrevented &&\n isClosableKey(event.code)) {\n event.preventDefault();\n this.close();\n }\n this.typeaheadController.onKeydown(event);\n }\n /**\n * Performs the opening animation:\n *\n * https://direct.googleplex.com/#/spec/295000003+271060003\n *\n * @return A promise that resolve to `true` if the animation was aborted,\n * `false` if it was not aborted.\n */\n async animateOpen() {\n const surfaceEl = this.surfaceEl;\n const slotEl = this.slotEl;\n if (!surfaceEl || !slotEl)\n return true;\n const openDirection = this.openDirection;\n this.dispatchEvent(new Event('opening'));\n // needs to be imperative because we don't want to mix animation and Lit\n // render timing\n surfaceEl.classList.toggle('animating', true);\n const signal = this.openCloseAnimationSignal.start();\n const height = surfaceEl.offsetHeight;\n const openingUpwards = openDirection === 'UP';\n const children = this.items;\n const FULL_DURATION = 500;\n const SURFACE_OPACITY_DURATION = 50;\n const ITEM_OPACITY_DURATION = 250;\n // We want to fit every child fade-in animation within the full duration of\n // the animation.\n const DELAY_BETWEEN_ITEMS = (FULL_DURATION - ITEM_OPACITY_DURATION) / children.length;\n const surfaceHeightAnimation = surfaceEl.animate([{ height: '0px' }, { height: `${height}px` }], {\n duration: FULL_DURATION,\n easing: EASING.EMPHASIZED,\n });\n // When we are opening upwards, we want to make sure the last item is always\n // in view, so we need to translate it upwards the opposite direction of the\n // height animation\n const upPositionCorrectionAnimation = slotEl.animate([\n { transform: openingUpwards ? `translateY(-${height}px)` : '' },\n { transform: '' },\n ], { duration: FULL_DURATION, easing: EASING.EMPHASIZED });\n const surfaceOpacityAnimation = surfaceEl.animate([{ opacity: 0 }, { opacity: 1 }], SURFACE_OPACITY_DURATION);\n const childrenAnimations = [];\n for (let i = 0; i < children.length; i++) {\n // If we are animating upwards, then reverse the children list.\n const directionalIndex = openingUpwards ? children.length - 1 - i : i;\n const child = children[directionalIndex];\n const animation = child.animate([{ opacity: 0 }, { opacity: 1 }], {\n duration: ITEM_OPACITY_DURATION,\n delay: DELAY_BETWEEN_ITEMS * i,\n });\n // Make them all initially hidden and then clean up at the end of each\n // animation.\n child.classList.toggle('md-menu-hidden', true);\n animation.addEventListener('finish', () => {\n child.classList.toggle('md-menu-hidden', false);\n });\n childrenAnimations.push([child, animation]);\n }\n let resolveAnimation = (value) => { };\n const animationFinished = new Promise((resolve) => {\n resolveAnimation = resolve;\n });\n signal.addEventListener('abort', () => {\n surfaceHeightAnimation.cancel();\n upPositionCorrectionAnimation.cancel();\n surfaceOpacityAnimation.cancel();\n childrenAnimations.forEach(([child, animation]) => {\n child.classList.toggle('md-menu-hidden', false);\n animation.cancel();\n });\n resolveAnimation(true);\n });\n surfaceHeightAnimation.addEventListener('finish', () => {\n surfaceEl.classList.toggle('animating', false);\n this.openCloseAnimationSignal.finish();\n resolveAnimation(false);\n });\n return await animationFinished;\n }\n /**\n * Performs the closing animation:\n *\n * https://direct.googleplex.com/#/spec/295000003+271060003\n */\n animateClose() {\n let resolve;\n // This promise blocks the surface position controller from setting\n // display: none on the surface which will interfere with this animation.\n const animationEnded = new Promise((res) => {\n resolve = res;\n });\n const surfaceEl = this.surfaceEl;\n const slotEl = this.slotEl;\n if (!surfaceEl || !slotEl) {\n resolve(false);\n return animationEnded;\n }\n const openDirection = this.openDirection;\n const closingDownwards = openDirection === 'UP';\n this.dispatchEvent(new Event('closing'));\n // needs to be imperative because we don't want to mix animation and Lit\n // render timing\n surfaceEl.classList.toggle('animating', true);\n const signal = this.openCloseAnimationSignal.start();\n const height = surfaceEl.offsetHeight;\n const children = this.items;\n const FULL_DURATION = 150;\n const SURFACE_OPACITY_DURATION = 50;\n // The surface fades away at the very end\n const SURFACE_OPACITY_DELAY = FULL_DURATION - SURFACE_OPACITY_DURATION;\n const ITEM_OPACITY_DURATION = 50;\n const ITEM_OPACITY_INITIAL_DELAY = 50;\n const END_HEIGHT_PERCENTAGE = 0.35;\n // We want to fit every child fade-out animation within the full duration of\n // the animation.\n const DELAY_BETWEEN_ITEMS = (FULL_DURATION - ITEM_OPACITY_INITIAL_DELAY - ITEM_OPACITY_DURATION) /\n children.length;\n // The mock has the animation shrink to 35%\n const surfaceHeightAnimation = surfaceEl.animate([\n { height: `${height}px` },\n { height: `${height * END_HEIGHT_PERCENTAGE}px` },\n ], {\n duration: FULL_DURATION,\n easing: EASING.EMPHASIZED_ACCELERATE,\n });\n // When we are closing downwards, we want to make sure the last item is\n // always in view, so we need to translate it upwards the opposite direction\n // of the height animation\n const downPositionCorrectionAnimation = slotEl.animate([\n { transform: '' },\n {\n transform: closingDownwards\n ? `translateY(-${height * (1 - END_HEIGHT_PERCENTAGE)}px)`\n : '',\n },\n ], { duration: FULL_DURATION, easing: EASING.EMPHASIZED_ACCELERATE });\n const surfaceOpacityAnimation = surfaceEl.animate([{ opacity: 1 }, { opacity: 0 }], { duration: SURFACE_OPACITY_DURATION, delay: SURFACE_OPACITY_DELAY });\n const childrenAnimations = [];\n for (let i = 0; i < children.length; i++) {\n // If the animation is closing upwards, then reverse the list of\n // children so that we animate in the opposite direction.\n const directionalIndex = closingDownwards ? i : children.length - 1 - i;\n const child = children[directionalIndex];\n const animation = child.animate([{ opacity: 1 }, { opacity: 0 }], {\n duration: ITEM_OPACITY_DURATION,\n delay: ITEM_OPACITY_INITIAL_DELAY + DELAY_BETWEEN_ITEMS * i,\n });\n // Make sure the items stay hidden at the end of each child animation.\n // We clean this up at the end of the overall animation.\n animation.addEventListener('finish', () => {\n child.classList.toggle('md-menu-hidden', true);\n });\n childrenAnimations.push([child, animation]);\n }\n signal.addEventListener('abort', () => {\n surfaceHeightAnimation.cancel();\n downPositionCorrectionAnimation.cancel();\n surfaceOpacityAnimation.cancel();\n childrenAnimations.forEach(([child, animation]) => {\n animation.cancel();\n child.classList.toggle('md-menu-hidden', false);\n });\n resolve(false);\n });\n surfaceHeightAnimation.addEventListener('finish', () => {\n surfaceEl.classList.toggle('animating', false);\n childrenAnimations.forEach(([child]) => {\n child.classList.toggle('md-menu-hidden', false);\n });\n this.openCloseAnimationSignal.finish();\n this.dispatchEvent(new Event('closed'));\n resolve(true);\n });\n return animationEnded;\n }\n handleKeydown(event) {\n // At any key event, the pointer interaction is done so we need to clear our\n // cached pointerpath. This handles the case where the user clicks on the\n // anchor, and then hits shift+tab\n this.pointerPath = [];\n this.listController.handleKeydown(event);\n }\n setUpGlobalEventListeners() {\n document.addEventListener('click', this.onDocumentClick, { capture: true });\n window.addEventListener('pointerdown', this.onWindowPointerdown);\n document.addEventListener('resize', this.onWindowResize, { passive: true });\n window.addEventListener('resize', this.onWindowResize, { passive: true });\n }\n cleanUpGlobalEventListeners() {\n document.removeEventListener('click', this.onDocumentClick, {\n capture: true,\n });\n window.removeEventListener('pointerdown', this.onWindowPointerdown);\n document.removeEventListener('resize', this.onWindowResize);\n window.removeEventListener('resize', this.onWindowResize);\n }\n onCloseMenu() {\n this.close();\n }\n onDeactivateItems(event) {\n event.stopPropagation();\n this.listController.onDeactivateItems();\n }\n onRequestActivation(event) {\n event.stopPropagation();\n this.listController.onRequestActivation(event);\n }\n handleDeactivateTypeahead(event) {\n // stopPropagation so that this does not deactivate any typeaheads in menus\n // nested above it e.g. md-sub-menu\n event.stopPropagation();\n this.typeaheadActive = false;\n }\n handleActivateTypeahead(event) {\n // stopPropagation so that this does not activate any typeaheads in menus\n // nested above it e.g. md-sub-menu\n event.stopPropagation();\n this.typeaheadActive = true;\n }\n handleStayOpenOnFocusout(event) {\n event.stopPropagation();\n this.stayOpenOnFocusout = true;\n }\n handleCloseOnFocusout(event) {\n event.stopPropagation();\n this.stayOpenOnFocusout = false;\n }\n close() {\n this.open = false;\n const maybeSubmenu = this.slotItems;\n maybeSubmenu.forEach((item) => {\n item.close?.();\n });\n }\n show() {\n this.open = true;\n }\n /**\n * Activates the next item in the menu. If at the end of the menu, the first\n * item will be activated.\n *\n * @return The activated menu item or `null` if there are no items.\n */\n activateNextItem() {\n return this.listController.activateNextItem() ?? null;\n }\n /**\n * Activates the previous item in the menu. If at the start of the menu, the\n * last item will be activated.\n *\n * @return The activated menu item or `null` if there are no items.\n */\n activatePreviousItem() {\n return this.listController.activatePreviousItem() ?? null;\n }\n /**\n * Repositions the menu if it is open.\n *\n * Useful for the case where document or window-positioned menus have their\n * anchors moved while open.\n */\n reposition() {\n if (this.open) {\n this.menuPositionController.position();\n }\n }\n}\n__decorate([\n query('.menu')\n], Menu.prototype, \"surfaceEl\", void 0);\n__decorate([\n query('slot')\n], Menu.prototype, \"slotEl\", void 0);\n__decorate([\n property()\n], Menu.prototype, \"anchor\", void 0);\n__decorate([\n property()\n], Menu.prototype, \"positioning\", void 0);\n__decorate([\n property({ type: Boolean })\n], Menu.prototype, \"quick\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'has-overflow' })\n], Menu.prototype, \"hasOverflow\", void 0);\n__decorate([\n property({ type: Boolean, reflect: true })\n], Menu.prototype, \"open\", void 0);\n__decorate([\n property({ type: Number, attribute: 'x-offset' })\n], Menu.prototype, \"xOffset\", void 0);\n__decorate([\n property({ type: Number, attribute: 'y-offset' })\n], Menu.prototype, \"yOffset\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'no-horizontal-flip' })\n], Menu.prototype, \"noHorizontalFlip\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'no-vertical-flip' })\n], Menu.prototype, \"noVerticalFlip\", void 0);\n__decorate([\n property({ type: Number, attribute: 'typeahead-delay' })\n], Menu.prototype, \"typeaheadDelay\", void 0);\n__decorate([\n property({ attribute: 'anchor-corner' })\n], Menu.prototype, \"anchorCorner\", void 0);\n__decorate([\n property({ attribute: 'menu-corner' })\n], Menu.prototype, \"menuCorner\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'stay-open-on-outside-click' })\n], Menu.prototype, \"stayOpenOnOutsideClick\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'stay-open-on-focusout' })\n], Menu.prototype, \"stayOpenOnFocusout\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'skip-restore-focus' })\n], Menu.prototype, \"skipRestoreFocus\", void 0);\n__decorate([\n property({ attribute: 'default-focus' })\n], Menu.prototype, \"defaultFocus\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'no-navigation-wrap' })\n], Menu.prototype, \"noNavigationWrap\", void 0);\n__decorate([\n queryAssignedElements({ flatten: true })\n], Menu.prototype, \"slotItems\", void 0);\n__decorate([\n state()\n], Menu.prototype, \"typeaheadActive\", void 0);\n//# sourceMappingURL=menu.js.map","/**\n * @license\n * Copyright 2026 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n// Generated stylesheet for ./menu/internal/menu-styles.css.\nimport { css } from 'lit';\nexport const styles = css `:host{--md-elevation-level: var(--md-menu-container-elevation, 2);--md-elevation-shadow-color: var(--md-menu-container-shadow-color, var(--md-sys-color-shadow, #000));min-width:112px;color:unset;display:contents}md-focus-ring{--md-focus-ring-shape: var(--md-menu-container-shape, var(--md-sys-shape-corner-extra-small, 4px))}.menu{border-radius:var(--md-menu-container-shape, var(--md-sys-shape-corner-extra-small, 4px));display:none;inset:auto;border:none;padding:0px;overflow:visible;background-color:rgba(0,0,0,0);color:inherit;opacity:0;z-index:20;position:absolute;user-select:none;max-height:inherit;height:inherit;min-width:inherit;max-width:inherit;scrollbar-width:inherit}.menu::backdrop{display:none}.fixed{position:fixed}.items{display:block;list-style-type:none;margin:0;outline:none;box-sizing:border-box;background-color:var(--md-menu-container-color, var(--md-sys-color-surface-container, #f3edf7));height:inherit;max-height:inherit;overflow:auto;min-width:inherit;max-width:inherit;border-radius:inherit;scrollbar-width:inherit}.item-padding{padding-block:var(--md-menu-top-space, 8px) var(--md-menu-bottom-space, 8px)}.has-overflow:not([popover]) .items{overflow:visible}.has-overflow.animating .items,.animating .items{overflow:hidden}.has-overflow.animating .items{pointer-events:none}.animating ::slotted(.md-menu-hidden){opacity:0}slot{display:block;height:inherit;max-height:inherit}::slotted(:is(md-divider,[role=separator])){margin:8px 0}@media(forced-colors: active){.menu{border-style:solid;border-color:CanvasText;border-width:1px}}\n`;\nexport default styles.styleSheet;\n//# sourceMappingURL=menu-styles.cssresult.js.map","/**\n * @license\n * Copyright 2022 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { __decorate } from \"tslib\";\nimport { customElement } from 'lit/decorators.js';\nimport { Menu } from './internal/menu.js';\nimport { styles } from './internal/menu-styles.cssresult.js';\nexport { CloseReason, FocusState, } from './internal/controllers/shared.js';\nexport { Corner } from './internal/menu.js';\n/**\n * @summary Menus display a list of choices on a temporary surface.\n *\n * @description\n * Menus appear when users interact with a button, action, or other control.\n *\n * They can be opened from a variety of elements, most commonly icon buttons,\n * buttons, and text fields.\n *\n * md-menu listens for the `close-menu` and `deselect-items` events.\n *\n * - `close-menu` closes the menu when dispatched from a child element.\n * - `deselect-items` deselects all of its immediate menu-item children.\n *\n * @example\n * ```html\n * <div style=\"position:relative;\">\n * <button\n * id=\"anchor\"\n * @click=${() => this.menuRef.value.show()}>\n * Click to open menu\n * </button>\n * <!--\n * `has-overflow` is required when using a submenu which overflows the\n * menu's contents.\n *\n * Additionally, `anchor` ingests an idref which do not pass through shadow\n * roots. You can also set `.anchorElement` to an element reference if\n * necessary.\n * -->\n * <md-menu anchor=\"anchor\" has-overflow ${ref(menuRef)}>\n * <md-menu-item headline=\"This is a headline\"></md-menu-item>\n * <md-sub-menu>\n * <md-menu-item\n * slot=\"item\"\n * headline=\"this is a submenu item\">\n * </md-menu-item>\n * <md-menu slot=\"menu\">\n * <md-menu-item headline=\"This is an item inside a submenu\">\n * </md-menu-item>\n * </md-menu>\n * </md-sub-menu>\n * </md-menu>\n * </div>\n * ```\n *\n * @final\n * @suppress {visibility}\n */\nlet MdMenu = class MdMenu extends Menu {\n};\nMdMenu.styles = [styles];\nMdMenu = __decorate([\n customElement('md-menu')\n], MdMenu);\nexport { MdMenu };\n//# sourceMappingURL=menu.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { html, render } from 'lit';\nimport { Validator } from './validator.js';\n/**\n * A validator that provides constraint validation that emulates `<select>`\n * validation.\n */\nexport class SelectValidator extends Validator {\n computeValidity(state) {\n if (!this.selectControl) {\n // Lazily create the platform select\n this.selectControl = document.createElement('select');\n }\n render(html `<option value=${state.value}></option>`, this.selectControl);\n this.selectControl.value = state.value;\n this.selectControl.required = state.required;\n return {\n validity: this.selectControl.validity,\n validationMessage: this.selectControl.validationMessage,\n };\n }\n equals(prev, next) {\n return prev.value === next.value && prev.required === next.required;\n }\n copy({ value, required }) {\n return { value, required };\n }\n}\n//# sourceMappingURL=select-validator.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n/**\n * Given a list of select options, this function will return an array of\n * SelectOptionRecords that are selected.\n *\n * @return An array of SelectOptionRecords describing the options that are\n * selected.\n */\nexport function getSelectedItems(items) {\n const selectedItemRecords = [];\n for (let i = 0; i < items.length; i++) {\n const item = items[i];\n if (item.selected) {\n selectedItemRecords.push([item, i]);\n }\n }\n return selectedItemRecords;\n}\n//# sourceMappingURL=shared.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nvar _a;\nimport { __decorate } from \"tslib\";\nimport '../../menu/menu.js';\nimport { html, isServer, LitElement, nothing } from 'lit';\nimport { property, query, queryAssignedElements, state } from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { styleMap } from 'lit/directives/style-map.js';\nimport { html as staticHtml } from 'lit/static-html.js';\nimport { mixinDelegatesAria } from '../../internal/aria/delegate.js';\nimport { redispatchEvent } from '../../internal/events/redispatch-event.js';\nimport { createValidator, getValidityAnchor, mixinConstraintValidation, } from '../../labs/behaviors/constraint-validation.js';\nimport { mixinElementInternals } from '../../labs/behaviors/element-internals.js';\nimport { getFormValue, mixinFormAssociated, } from '../../labs/behaviors/form-associated.js';\nimport { mixinOnReportValidity, onReportValidity, } from '../../labs/behaviors/on-report-validity.js';\nimport { SelectValidator } from '../../labs/behaviors/validators/select-validator.js';\nimport { getActiveItem } from '../../list/internal/list-navigation-helpers.js';\nimport { FocusState, isElementInSubtree, isSelectableKey, } from '../../menu/internal/controllers/shared.js';\nimport { TYPEAHEAD_RECORD } from '../../menu/internal/controllers/typeaheadController.js';\nimport { DEFAULT_TYPEAHEAD_BUFFER_TIME } from '../../menu/internal/menu.js';\nimport { getSelectedItems } from './shared.js';\nconst VALUE = Symbol('value');\n// Separate variable needed for closure.\nconst selectBaseClass = mixinDelegatesAria(mixinOnReportValidity(mixinConstraintValidation(mixinFormAssociated(mixinElementInternals(LitElement)))));\n/**\n * @fires change {Event} The native `change` event on\n * [`<input>`](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/change_event)\n * --bubbles\n * @fires input {InputEvent} The native `input` event on\n * [`<input>`](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/input_event)\n * --bubbles --composed\n * @fires opening {Event} Fired when the select's menu is about to open.\n * @fires opened {Event} Fired when the select's menu has finished animations\n * and opened.\n * @fires closing {Event} Fired when the select's menu is about to close.\n * @fires closed {Event} Fired when the select's menu has finished animations\n * and closed.\n */\nexport class Select extends selectBaseClass {\n /**\n * The value of the currently selected option.\n *\n * Note: For SSR, set `[selected]` on the requested option and `displayText`\n * rather than setting `value` setting `value` will incur a DOM query.\n */\n get value() {\n return this[VALUE];\n }\n set value(value) {\n if (isServer)\n return;\n this.lastUserSetValue = value;\n this.select(value);\n }\n get options() {\n // NOTE: this does a DOM query.\n return (this.menu?.items ?? []);\n }\n /**\n * The index of the currently selected option.\n *\n * Note: For SSR, set `[selected]` on the requested option and `displayText`\n * rather than setting `selectedIndex` setting `selectedIndex` will incur a\n * DOM query.\n */\n get selectedIndex() {\n // tslint:disable-next-line:enforce-name-casing\n const [_option, index] = (this.getSelectedOptions() ?? [])[0] ?? [];\n return index ?? -1;\n }\n set selectedIndex(index) {\n this.lastUserSetSelectedIndex = index;\n this.selectIndex(index);\n }\n /**\n * Returns an array of selected options.\n *\n * NOTE: md-select only supports single selection.\n */\n get selectedOptions() {\n return (this.getSelectedOptions() ?? []).map(([option]) => option);\n }\n get hasError() {\n return this.error || this.nativeError;\n }\n constructor() {\n super();\n /**\n * Opens the menu synchronously with no animation.\n */\n this.quick = false;\n /**\n * Whether or not the select is required.\n */\n this.required = false;\n /**\n * The error message that replaces supporting text when `error` is true. If\n * `errorText` is an empty string, then the supporting text will continue to\n * show.\n *\n * This error message overrides the error message displayed by\n * `reportValidity()`.\n */\n this.errorText = '';\n /**\n * The floating label for the field.\n */\n this.label = '';\n /**\n * Disables the asterisk on the floating label, when the select is\n * required.\n */\n this.noAsterisk = false;\n /**\n * Conveys additional information below the select, such as how it should\n * be used.\n */\n this.supportingText = '';\n /**\n * Gets or sets whether or not the select is in a visually invalid state.\n *\n * This error state overrides the error state controlled by\n * `reportValidity()`.\n */\n this.error = false;\n /**\n * Whether or not the underlying md-menu should be position: fixed to display\n * in a top-level manner, or position: absolute.\n *\n * position:fixed is useful for cases where select is inside of another\n * element with stacking context and hidden overflows such as `md-dialog`.\n */\n this.menuPositioning = 'popover';\n /**\n * Clamps the menu-width to the width of the select.\n */\n this.clampMenuWidth = false;\n /**\n * The max time between the keystrokes of the typeahead select / menu behavior\n * before it clears the typeahead buffer.\n */\n this.typeaheadDelay = DEFAULT_TYPEAHEAD_BUFFER_TIME;\n /**\n * Whether or not the text field has a leading icon. Used for SSR.\n */\n this.hasLeadingIcon = false;\n /**\n * Text to display in the field. Only set for SSR.\n */\n this.displayText = '';\n /**\n * Whether the menu should be aligned to the start or the end of the select's\n * textbox.\n */\n this.menuAlign = 'start';\n this[_a] = '';\n /**\n * Used for initializing select when the user sets the `value` directly.\n */\n this.lastUserSetValue = null;\n /**\n * Used for initializing select when the user sets the `selectedIndex`\n * directly.\n */\n this.lastUserSetSelectedIndex = null;\n /**\n * Used for `input` and `change` event change detection.\n */\n this.lastSelectedOption = null;\n // tslint:disable-next-line:enforce-name-casing\n this.lastSelectedOptionRecords = [];\n /**\n * Whether or not a native error has been reported via `reportValidity()`.\n */\n this.nativeError = false;\n /**\n * The validation message displayed from a native error via\n * `reportValidity()`.\n */\n this.nativeErrorText = '';\n this.focused = false;\n this.open = false;\n this.defaultFocus = FocusState.NONE;\n // Have to keep track of previous open because it's state and private and thus\n // cannot be tracked in PropertyValues<this> map.\n this.prevOpen = this.open;\n this.selectWidth = 0;\n if (isServer) {\n return;\n }\n this.addEventListener('focus', this.handleFocus.bind(this));\n this.addEventListener('blur', this.handleBlur.bind(this));\n }\n /**\n * Selects an option given the value of the option, and updates MdSelect's\n * value.\n */\n select(value) {\n const optionToSelect = this.options.find((option) => option.value === value);\n if (optionToSelect) {\n this.selectItem(optionToSelect);\n }\n }\n /**\n * Selects an option given the index of the option, and updates MdSelect's\n * value.\n */\n selectIndex(index) {\n const optionToSelect = this.options[index];\n if (optionToSelect) {\n this.selectItem(optionToSelect);\n }\n }\n /**\n * Reset the select to its default value.\n */\n reset() {\n for (const option of this.options) {\n option.selected = option.hasAttribute('selected');\n }\n this.updateValueAndDisplayText();\n this.nativeError = false;\n this.nativeErrorText = '';\n }\n /** Shows the picker. If it's already open, this is a no-op. */\n showPicker() {\n this.open = true;\n }\n [(_a = VALUE, onReportValidity)](invalidEvent) {\n // Prevent default pop-up behavior.\n invalidEvent?.preventDefault();\n const prevMessage = this.getErrorText();\n this.nativeError = !!invalidEvent;\n this.nativeErrorText = this.validationMessage;\n if (prevMessage === this.getErrorText()) {\n this.field?.reannounceError();\n }\n }\n update(changed) {\n // In SSR the options will be ready to query, so try to figure out what\n // the value and display text should be.\n if (!this.hasUpdated) {\n this.initUserSelection();\n }\n // We have just opened the menu.\n // We are only able to check for the select's rect in `update()` instead of\n // having to wait for `updated()` because the menu can never be open on\n // first render since it is not settable and Lit SSR does not support click\n // events which would open the menu.\n if (this.prevOpen !== this.open && this.open) {\n const selectRect = this.getBoundingClientRect();\n this.selectWidth = selectRect.width;\n }\n this.prevOpen = this.open;\n super.update(changed);\n }\n render() {\n return html `\n <span\n class=\"select ${classMap(this.getRenderClasses())}\"\n @focusout=${this.handleFocusout}>\n ${this.renderField()} ${this.renderMenu()}\n </span>\n `;\n }\n async firstUpdated(changed) {\n await this.menu?.updateComplete;\n // If this has been handled on update already due to SSR, try again.\n if (!this.lastSelectedOptionRecords.length) {\n this.initUserSelection();\n }\n // Case for when the DOM is streaming, there are no children, and a child\n // has [selected] set on it, we need to wait for DOM to render something.\n if (!this.lastSelectedOptionRecords.length &&\n !isServer &&\n !this.options.length) {\n setTimeout(() => {\n this.updateValueAndDisplayText();\n });\n }\n super.firstUpdated(changed);\n }\n getRenderClasses() {\n return {\n 'disabled': this.disabled,\n 'error': this.error,\n 'open': this.open,\n };\n }\n renderField() {\n const ariaLabel = this.ariaLabel || this.label;\n return staticHtml `\n <${this.fieldTag}\n aria-haspopup=\"listbox\"\n role=\"combobox\"\n part=\"field\"\n id=\"field\"\n tabindex=${this.disabled ? '-1' : '0'}\n aria-label=${ariaLabel || nothing}\n aria-describedby=\"description\"\n aria-expanded=${this.open ? 'true' : 'false'}\n aria-controls=\"listbox\"\n class=\"field\"\n label=${this.label}\n ?no-asterisk=${this.noAsterisk}\n .focused=${this.focused || this.open}\n .populated=${!!this.displayText}\n .disabled=${this.disabled}\n .required=${this.required}\n .error=${this.hasError}\n ?has-start=${this.hasLeadingIcon}\n has-end\n supporting-text=${this.supportingText}\n error-text=${this.getErrorText()}\n @keydown=${this.handleKeydown}\n @click=${this.handleClick}>\n ${this.renderFieldContent()}\n <div id=\"description\" slot=\"aria-describedby\"></div>\n </${this.fieldTag}>`;\n }\n renderFieldContent() {\n return [\n this.renderLeadingIcon(),\n this.renderLabel(),\n this.renderTrailingIcon(),\n ];\n }\n renderLeadingIcon() {\n return html `\n <span class=\"icon leading\" slot=\"start\">\n <slot name=\"leading-icon\" @slotchange=${this.handleIconChange}></slot>\n </span>\n `;\n }\n renderTrailingIcon() {\n return html `\n <span class=\"icon trailing\" slot=\"end\">\n <slot name=\"trailing-icon\" @slotchange=${this.handleIconChange}>\n <svg height=\"5\" viewBox=\"7 10 10 5\" focusable=\"false\">\n <polygon\n class=\"down\"\n stroke=\"none\"\n fill-rule=\"evenodd\"\n points=\"7 10 12 15 17 10\"></polygon>\n <polygon\n class=\"up\"\n stroke=\"none\"\n fill-rule=\"evenodd\"\n points=\"7 15 12 10 17 15\"></polygon>\n </svg>\n </slot>\n </span>\n `;\n }\n renderLabel() {\n // need to render so that line-height can apply and give it a\n // non-zero height\n return html `<div id=\"label\">${this.displayText || html ` `}</div>`;\n }\n renderMenu() {\n const ariaLabel = this.label || this.ariaLabel;\n return html `<div class=\"menu-wrapper\">\n <md-menu\n id=\"listbox\"\n .defaultFocus=${this.defaultFocus}\n role=\"listbox\"\n tabindex=\"-1\"\n aria-label=${ariaLabel || nothing}\n stay-open-on-focusout\n part=\"menu\"\n exportparts=\"focus-ring: menu-focus-ring\"\n anchor=\"field\"\n style=${styleMap({\n '--__menu-min-width': `${this.selectWidth}px`,\n '--__menu-max-width': this.clampMenuWidth\n ? `${this.selectWidth}px`\n : undefined,\n })}\n no-navigation-wrap\n .open=${this.open}\n .quick=${this.quick}\n .positioning=${this.menuPositioning}\n .typeaheadDelay=${this.typeaheadDelay}\n .anchorCorner=${this.menuAlign === 'start' ? 'end-start' : 'end-end'}\n .menuCorner=${this.menuAlign === 'start' ? 'start-start' : 'start-end'}\n @opening=${this.handleOpening}\n @opened=${this.redispatchEvent}\n @closing=${this.redispatchEvent}\n @closed=${this.handleClosed}\n @close-menu=${this.handleCloseMenu}\n @request-selection=${this.handleRequestSelection}\n @request-deselection=${this.handleRequestDeselection}>\n ${this.renderMenuContent()}\n </md-menu>\n </div>`;\n }\n renderMenuContent() {\n return html `<slot></slot>`;\n }\n /**\n * Handles opening the select on keydown and typahead selection when the menu\n * is closed.\n */\n handleKeydown(event) {\n if (this.open || this.disabled || !this.menu) {\n return;\n }\n const typeaheadController = this.menu.typeaheadController;\n const isOpenKey = event.code === 'Space' ||\n event.code === 'ArrowDown' ||\n event.code === 'ArrowUp' ||\n event.code === 'End' ||\n event.code === 'Home' ||\n event.code === 'Enter';\n // Do not open if currently typing ahead because the user may be typing the\n // spacebar to match a word with a space\n if (!typeaheadController.isTypingAhead && isOpenKey) {\n event.preventDefault();\n this.open = true;\n // https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-select-only/#kbd_label\n switch (event.code) {\n case 'Space':\n case 'ArrowDown':\n case 'Enter':\n // We will handle focusing last selected item in this.handleOpening()\n this.defaultFocus = FocusState.NONE;\n break;\n case 'End':\n this.defaultFocus = FocusState.LAST_ITEM;\n break;\n case 'ArrowUp':\n case 'Home':\n this.defaultFocus = FocusState.FIRST_ITEM;\n break;\n default:\n break;\n }\n return;\n }\n const isPrintableKey = event.key.length === 1;\n // Handles typing ahead when the menu is closed by delegating the event to\n // the underlying menu's typeaheadController\n if (isPrintableKey) {\n typeaheadController.onKeydown(event);\n event.preventDefault();\n const { lastActiveRecord } = typeaheadController;\n if (!lastActiveRecord) {\n return;\n }\n this.labelEl?.setAttribute?.('aria-live', 'polite');\n const hasChanged = this.selectItem(lastActiveRecord[TYPEAHEAD_RECORD.ITEM]);\n if (hasChanged) {\n this.dispatchInteractionEvents();\n }\n }\n }\n handleClick() {\n this.open = !this.open;\n }\n handleFocus() {\n this.focused = true;\n }\n handleBlur() {\n this.focused = false;\n }\n /**\n * Handles closing the menu when the focus leaves the select's subtree.\n */\n handleFocusout(event) {\n // Don't close the menu if we are switching focus between menu,\n // select-option, and field\n if (event.relatedTarget && isElementInSubtree(event.relatedTarget, this)) {\n return;\n }\n this.open = false;\n }\n /**\n * Gets a list of all selected select options as a list item record array.\n *\n * @return An array of selected list option records.\n */\n getSelectedOptions() {\n if (!this.menu) {\n this.lastSelectedOptionRecords = [];\n return null;\n }\n const items = this.menu.items;\n this.lastSelectedOptionRecords = getSelectedItems(items);\n return this.lastSelectedOptionRecords;\n }\n async getUpdateComplete() {\n await this.menu?.updateComplete;\n return super.getUpdateComplete();\n }\n /**\n * Gets the selected options from the DOM, and updates the value and display\n * text to the first selected option's value and headline respectively.\n *\n * @return Whether or not the selected option has changed since last update.\n */\n updateValueAndDisplayText() {\n const selectedOptions = this.getSelectedOptions() ?? [];\n // Used to determine whether or not we need to fire an input / change event\n // which fire whenever the option element changes (value or selectedIndex)\n // on user interaction.\n let hasSelectedOptionChanged = false;\n if (selectedOptions.length) {\n const [firstSelectedOption] = selectedOptions[0];\n hasSelectedOptionChanged =\n this.lastSelectedOption !== firstSelectedOption;\n this.lastSelectedOption = firstSelectedOption;\n this[VALUE] = firstSelectedOption.value;\n this.displayText = firstSelectedOption.displayText;\n }\n else {\n hasSelectedOptionChanged = this.lastSelectedOption !== null;\n this.lastSelectedOption = null;\n this[VALUE] = '';\n this.displayText = '';\n }\n return hasSelectedOptionChanged;\n }\n /**\n * Focuses and activates the last selected item upon opening, and resets other\n * active items.\n */\n async handleOpening(e) {\n this.labelEl?.removeAttribute?.('aria-live');\n this.redispatchEvent(e);\n // FocusState.NONE means we want to handle focus ourselves and focus the\n // last selected item.\n if (this.defaultFocus !== FocusState.NONE) {\n return;\n }\n const items = this.menu.items;\n const activeItem = getActiveItem(items)?.item;\n let [selectedItem] = this.lastSelectedOptionRecords[0] ?? [null];\n // This is true if the user keys through the list but clicks out of the menu\n // thus no close-menu event is fired by an item and we can't clean up in\n // handleCloseMenu.\n if (activeItem && activeItem !== selectedItem) {\n activeItem.tabIndex = -1;\n }\n // in the case that nothing is selected, focus the first item\n selectedItem = selectedItem ?? items[0];\n if (selectedItem) {\n selectedItem.tabIndex = 0;\n selectedItem.focus();\n }\n }\n redispatchEvent(e) {\n redispatchEvent(this, e);\n }\n handleClosed(e) {\n this.open = false;\n this.redispatchEvent(e);\n }\n /**\n * Determines the reason for closing, and updates the UI accordingly.\n */\n handleCloseMenu(event) {\n const reason = event.detail.reason;\n const item = event.detail.itemPath[0];\n this.open = false;\n let hasChanged = false;\n if (reason.kind === 'click-selection') {\n hasChanged = this.selectItem(item);\n }\n else if (reason.kind === 'keydown' && isSelectableKey(reason.key)) {\n hasChanged = this.selectItem(item);\n }\n else {\n // This can happen on ESC being pressed\n item.tabIndex = -1;\n item.blur();\n }\n // Dispatch interaction events since selection has been made via keyboard\n // or mouse.\n if (hasChanged) {\n this.dispatchInteractionEvents();\n }\n }\n /**\n * Selects a given option, deselects other options, and updates the UI.\n *\n * @return Whether the last selected option has changed.\n */\n selectItem(item) {\n const selectedOptions = this.getSelectedOptions() ?? [];\n selectedOptions.forEach(([option]) => {\n if (item !== option) {\n option.selected = false;\n option.tabIndex = -1;\n }\n });\n item.selected = true;\n item.tabIndex = 0;\n return this.updateValueAndDisplayText();\n }\n /**\n * Handles updating selection when an option element requests selection via\n * property / attribute change.\n */\n handleRequestSelection(event) {\n const requestingOptionEl = event.target;\n // No-op if this item is already selected.\n if (this.lastSelectedOptionRecords.some(([option]) => option === requestingOptionEl)) {\n return;\n }\n this.selectItem(requestingOptionEl);\n }\n /**\n * Handles updating selection when an option element requests deselection via\n * property / attribute change.\n */\n handleRequestDeselection(event) {\n const requestingOptionEl = event.target;\n // No-op if this item is not even in the list of tracked selected items.\n if (!this.lastSelectedOptionRecords.some(([option]) => option === requestingOptionEl)) {\n return;\n }\n this.updateValueAndDisplayText();\n }\n /**\n * Attempts to initialize the selected option from user-settable values like\n * SSR, setting `value`, or `selectedIndex` at startup.\n */\n initUserSelection() {\n // User has set `.value` directly, but internals have not yet booted up.\n if (this.lastUserSetValue && !this.lastSelectedOptionRecords.length) {\n this.select(this.lastUserSetValue);\n // User has set `.selectedIndex` directly, but internals have not yet\n // booted up.\n }\n else if (this.lastUserSetSelectedIndex !== null &&\n !this.lastSelectedOptionRecords.length) {\n this.selectIndex(this.lastUserSetSelectedIndex);\n // Regular boot up!\n }\n else {\n this.updateValueAndDisplayText();\n }\n }\n handleIconChange() {\n this.hasLeadingIcon = this.leadingIcons.length > 0;\n }\n /**\n * Dispatches the `input` and `change` events.\n */\n dispatchInteractionEvents() {\n this.dispatchEvent(new Event('input', { bubbles: true, composed: true }));\n this.dispatchEvent(new Event('change', { bubbles: true }));\n }\n getErrorText() {\n return this.error ? this.errorText : this.nativeErrorText;\n }\n [getFormValue]() {\n return this.value;\n }\n formResetCallback() {\n this.reset();\n }\n formStateRestoreCallback(state) {\n this.value = state;\n }\n click() {\n this.field?.click();\n }\n [createValidator]() {\n return new SelectValidator(() => this);\n }\n [getValidityAnchor]() {\n return this.field;\n }\n}\n/** @nocollapse */\nSelect.shadowRootOptions = {\n ...LitElement.shadowRootOptions,\n delegatesFocus: true,\n};\n__decorate([\n property({ type: Boolean })\n], Select.prototype, \"quick\", void 0);\n__decorate([\n property({ type: Boolean })\n], Select.prototype, \"required\", void 0);\n__decorate([\n property({ type: String, attribute: 'error-text' })\n], Select.prototype, \"errorText\", void 0);\n__decorate([\n property()\n], Select.prototype, \"label\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'no-asterisk' })\n], Select.prototype, \"noAsterisk\", void 0);\n__decorate([\n property({ type: String, attribute: 'supporting-text' })\n], Select.prototype, \"supportingText\", void 0);\n__decorate([\n property({ type: Boolean, reflect: true })\n], Select.prototype, \"error\", void 0);\n__decorate([\n property({ attribute: 'menu-positioning' })\n], Select.prototype, \"menuPositioning\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'clamp-menu-width' })\n], Select.prototype, \"clampMenuWidth\", void 0);\n__decorate([\n property({ type: Number, attribute: 'typeahead-delay' })\n], Select.prototype, \"typeaheadDelay\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'has-leading-icon' })\n], Select.prototype, \"hasLeadingIcon\", void 0);\n__decorate([\n property({ attribute: 'display-text' })\n], Select.prototype, \"displayText\", void 0);\n__decorate([\n property({ attribute: 'menu-align' })\n], Select.prototype, \"menuAlign\", void 0);\n__decorate([\n property()\n], Select.prototype, \"value\", null);\n__decorate([\n property({ type: Number, attribute: 'selected-index' })\n], Select.prototype, \"selectedIndex\", null);\n__decorate([\n state()\n], Select.prototype, \"nativeError\", void 0);\n__decorate([\n state()\n], Select.prototype, \"nativeErrorText\", void 0);\n__decorate([\n state()\n], Select.prototype, \"focused\", void 0);\n__decorate([\n state()\n], Select.prototype, \"open\", void 0);\n__decorate([\n state()\n], Select.prototype, \"defaultFocus\", void 0);\n__decorate([\n query('.field')\n], Select.prototype, \"field\", void 0);\n__decorate([\n query('md-menu')\n], Select.prototype, \"menu\", void 0);\n__decorate([\n query('#label')\n], Select.prototype, \"labelEl\", void 0);\n__decorate([\n queryAssignedElements({ slot: 'leading-icon', flatten: true })\n], Select.prototype, \"leadingIcons\", void 0);\n//# sourceMappingURL=select.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport '../../field/outlined-field.js';\nimport { literal } from 'lit/static-html.js';\nimport { Select } from './select.js';\n// tslint:disable-next-line:enforce-comments-on-exported-symbols\nexport class OutlinedSelect extends Select {\n constructor() {\n super(...arguments);\n this.fieldTag = literal `md-outlined-field`;\n }\n}\n//# sourceMappingURL=outlined-select.js.map","/**\n * @license\n * Copyright 2026 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n// Generated stylesheet for ./select/internal/outlined-select-styles.css.\nimport { css } from 'lit';\nexport const styles = css `:host{--_text-field-disabled-input-text-color: var(--md-outlined-select-text-field-disabled-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-disabled-input-text-opacity: var(--md-outlined-select-text-field-disabled-input-text-opacity, 0.38);--_text-field-disabled-label-text-color: var(--md-outlined-select-text-field-disabled-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-disabled-label-text-opacity: var(--md-outlined-select-text-field-disabled-label-text-opacity, 0.38);--_text-field-disabled-leading-icon-color: var(--md-outlined-select-text-field-disabled-leading-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-disabled-leading-icon-opacity: var(--md-outlined-select-text-field-disabled-leading-icon-opacity, 0.38);--_text-field-disabled-outline-color: var(--md-outlined-select-text-field-disabled-outline-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-disabled-outline-opacity: var(--md-outlined-select-text-field-disabled-outline-opacity, 0.12);--_text-field-disabled-outline-width: var(--md-outlined-select-text-field-disabled-outline-width, 1px);--_text-field-disabled-supporting-text-color: var(--md-outlined-select-text-field-disabled-supporting-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-disabled-supporting-text-opacity: var(--md-outlined-select-text-field-disabled-supporting-text-opacity, 0.38);--_text-field-disabled-trailing-icon-color: var(--md-outlined-select-text-field-disabled-trailing-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-disabled-trailing-icon-opacity: var(--md-outlined-select-text-field-disabled-trailing-icon-opacity, 0.38);--_text-field-error-focus-input-text-color: var(--md-outlined-select-text-field-error-focus-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-error-focus-label-text-color: var(--md-outlined-select-text-field-error-focus-label-text-color, var(--md-sys-color-error, #b3261e));--_text-field-error-focus-leading-icon-color: var(--md-outlined-select-text-field-error-focus-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-error-focus-outline-color: var(--md-outlined-select-text-field-error-focus-outline-color, var(--md-sys-color-error, #b3261e));--_text-field-error-focus-supporting-text-color: var(--md-outlined-select-text-field-error-focus-supporting-text-color, var(--md-sys-color-error, #b3261e));--_text-field-error-focus-trailing-icon-color: var(--md-outlined-select-text-field-error-focus-trailing-icon-color, var(--md-sys-color-error, #b3261e));--_text-field-error-hover-input-text-color: var(--md-outlined-select-text-field-error-hover-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-error-hover-label-text-color: var(--md-outlined-select-text-field-error-hover-label-text-color, var(--md-sys-color-on-error-container, #410e0b));--_text-field-error-hover-leading-icon-color: var(--md-outlined-select-text-field-error-hover-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-error-hover-outline-color: var(--md-outlined-select-text-field-error-hover-outline-color, var(--md-sys-color-on-error-container, #410e0b));--_text-field-error-hover-supporting-text-color: var(--md-outlined-select-text-field-error-hover-supporting-text-color, var(--md-sys-color-error, #b3261e));--_text-field-error-hover-trailing-icon-color: var(--md-outlined-select-text-field-error-hover-trailing-icon-color, var(--md-sys-color-on-error-container, #410e0b));--_text-field-error-input-text-color: var(--md-outlined-select-text-field-error-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-error-label-text-color: var(--md-outlined-select-text-field-error-label-text-color, var(--md-sys-color-error, #b3261e));--_text-field-error-leading-icon-color: var(--md-outlined-select-text-field-error-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-error-outline-color: var(--md-outlined-select-text-field-error-outline-color, var(--md-sys-color-error, #b3261e));--_text-field-error-supporting-text-color: var(--md-outlined-select-text-field-error-supporting-text-color, var(--md-sys-color-error, #b3261e));--_text-field-error-trailing-icon-color: var(--md-outlined-select-text-field-error-trailing-icon-color, var(--md-sys-color-error, #b3261e));--_text-field-focus-input-text-color: var(--md-outlined-select-text-field-focus-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-focus-label-text-color: var(--md-outlined-select-text-field-focus-label-text-color, var(--md-sys-color-primary, #6750a4));--_text-field-focus-leading-icon-color: var(--md-outlined-select-text-field-focus-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-focus-outline-color: var(--md-outlined-select-text-field-focus-outline-color, var(--md-sys-color-primary, #6750a4));--_text-field-focus-outline-width: var(--md-outlined-select-text-field-focus-outline-width, 3px);--_text-field-focus-supporting-text-color: var(--md-outlined-select-text-field-focus-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-focus-trailing-icon-color: var(--md-outlined-select-text-field-focus-trailing-icon-color, var(--md-sys-color-primary, #6750a4));--_text-field-hover-input-text-color: var(--md-outlined-select-text-field-hover-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-hover-label-text-color: var(--md-outlined-select-text-field-hover-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-hover-leading-icon-color: var(--md-outlined-select-text-field-hover-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-hover-outline-color: var(--md-outlined-select-text-field-hover-outline-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-hover-outline-width: var(--md-outlined-select-text-field-hover-outline-width, 1px);--_text-field-hover-supporting-text-color: var(--md-outlined-select-text-field-hover-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-hover-trailing-icon-color: var(--md-outlined-select-text-field-hover-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-input-text-color: var(--md-outlined-select-text-field-input-text-color, var(--md-sys-color-on-surface, #1d1b20));--_text-field-input-text-font: var(--md-outlined-select-text-field-input-text-font, var(--md-sys-typescale-body-large-font, var(--md-ref-typeface-plain, Roboto)));--_text-field-input-text-line-height: var(--md-outlined-select-text-field-input-text-line-height, var(--md-sys-typescale-body-large-line-height, 1.5rem));--_text-field-input-text-size: var(--md-outlined-select-text-field-input-text-size, var(--md-sys-typescale-body-large-size, 1rem));--_text-field-input-text-weight: var(--md-outlined-select-text-field-input-text-weight, var(--md-sys-typescale-body-large-weight, var(--md-ref-typeface-weight-regular, 400)));--_text-field-label-text-color: var(--md-outlined-select-text-field-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-label-text-font: var(--md-outlined-select-text-field-label-text-font, var(--md-sys-typescale-body-large-font, var(--md-ref-typeface-plain, Roboto)));--_text-field-label-text-line-height: var(--md-outlined-select-text-field-label-text-line-height, var(--md-sys-typescale-body-large-line-height, 1.5rem));--_text-field-label-text-populated-line-height: var(--md-outlined-select-text-field-label-text-populated-line-height, var(--md-sys-typescale-body-small-line-height, 1rem));--_text-field-label-text-populated-size: var(--md-outlined-select-text-field-label-text-populated-size, var(--md-sys-typescale-body-small-size, 0.75rem));--_text-field-label-text-size: var(--md-outlined-select-text-field-label-text-size, var(--md-sys-typescale-body-large-size, 1rem));--_text-field-label-text-weight: var(--md-outlined-select-text-field-label-text-weight, var(--md-sys-typescale-body-large-weight, var(--md-ref-typeface-weight-regular, 400)));--_text-field-leading-icon-color: var(--md-outlined-select-text-field-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-leading-icon-size: var(--md-outlined-select-text-field-leading-icon-size, 24px);--_text-field-outline-color: var(--md-outlined-select-text-field-outline-color, var(--md-sys-color-outline, #79747e));--_text-field-outline-width: var(--md-outlined-select-text-field-outline-width, 1px);--_text-field-supporting-text-color: var(--md-outlined-select-text-field-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-supporting-text-font: var(--md-outlined-select-text-field-supporting-text-font, var(--md-sys-typescale-body-small-font, var(--md-ref-typeface-plain, Roboto)));--_text-field-supporting-text-line-height: var(--md-outlined-select-text-field-supporting-text-line-height, var(--md-sys-typescale-body-small-line-height, 1rem));--_text-field-supporting-text-size: var(--md-outlined-select-text-field-supporting-text-size, var(--md-sys-typescale-body-small-size, 0.75rem));--_text-field-supporting-text-weight: var(--md-outlined-select-text-field-supporting-text-weight, var(--md-sys-typescale-body-small-weight, var(--md-ref-typeface-weight-regular, 400)));--_text-field-trailing-icon-color: var(--md-outlined-select-text-field-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_text-field-trailing-icon-size: var(--md-outlined-select-text-field-trailing-icon-size, 24px);--_text-field-container-shape-start-start: var(--md-outlined-select-text-field-container-shape-start-start, var(--md-outlined-select-text-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_text-field-container-shape-start-end: var(--md-outlined-select-text-field-container-shape-start-end, var(--md-outlined-select-text-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_text-field-container-shape-end-end: var(--md-outlined-select-text-field-container-shape-end-end, var(--md-outlined-select-text-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--_text-field-container-shape-end-start: var(--md-outlined-select-text-field-container-shape-end-start, var(--md-outlined-select-text-field-container-shape, var(--md-sys-shape-corner-extra-small, 4px)));--md-outlined-field-container-shape-end-end: var(--_text-field-container-shape-end-end);--md-outlined-field-container-shape-end-start: var(--_text-field-container-shape-end-start);--md-outlined-field-container-shape-start-end: var(--_text-field-container-shape-start-end);--md-outlined-field-container-shape-start-start: var(--_text-field-container-shape-start-start);--md-outlined-field-content-color: var(--_text-field-input-text-color);--md-outlined-field-content-font: var(--_text-field-input-text-font);--md-outlined-field-content-line-height: var(--_text-field-input-text-line-height);--md-outlined-field-content-size: var(--_text-field-input-text-size);--md-outlined-field-content-weight: var(--_text-field-input-text-weight);--md-outlined-field-disabled-content-color: var(--_text-field-disabled-input-text-color);--md-outlined-field-disabled-content-opacity: var(--_text-field-disabled-input-text-opacity);--md-outlined-field-disabled-label-text-color: var(--_text-field-disabled-label-text-color);--md-outlined-field-disabled-label-text-opacity: var(--_text-field-disabled-label-text-opacity);--md-outlined-field-disabled-leading-content-color: var(--_text-field-disabled-leading-icon-color);--md-outlined-field-disabled-leading-content-opacity: var(--_text-field-disabled-leading-icon-opacity);--md-outlined-field-disabled-outline-color: var(--_text-field-disabled-outline-color);--md-outlined-field-disabled-outline-opacity: var(--_text-field-disabled-outline-opacity);--md-outlined-field-disabled-outline-width: var(--_text-field-disabled-outline-width);--md-outlined-field-disabled-supporting-text-color: var(--_text-field-disabled-supporting-text-color);--md-outlined-field-disabled-supporting-text-opacity: var(--_text-field-disabled-supporting-text-opacity);--md-outlined-field-disabled-trailing-content-color: var(--_text-field-disabled-trailing-icon-color);--md-outlined-field-disabled-trailing-content-opacity: var(--_text-field-disabled-trailing-icon-opacity);--md-outlined-field-error-content-color: var(--_text-field-error-input-text-color);--md-outlined-field-error-focus-content-color: var(--_text-field-error-focus-input-text-color);--md-outlined-field-error-focus-label-text-color: var(--_text-field-error-focus-label-text-color);--md-outlined-field-error-focus-leading-content-color: var(--_text-field-error-focus-leading-icon-color);--md-outlined-field-error-focus-outline-color: var(--_text-field-error-focus-outline-color);--md-outlined-field-error-focus-supporting-text-color: var(--_text-field-error-focus-supporting-text-color);--md-outlined-field-error-focus-trailing-content-color: var(--_text-field-error-focus-trailing-icon-color);--md-outlined-field-error-hover-content-color: var(--_text-field-error-hover-input-text-color);--md-outlined-field-error-hover-label-text-color: var(--_text-field-error-hover-label-text-color);--md-outlined-field-error-hover-leading-content-color: var(--_text-field-error-hover-leading-icon-color);--md-outlined-field-error-hover-outline-color: var(--_text-field-error-hover-outline-color);--md-outlined-field-error-hover-supporting-text-color: var(--_text-field-error-hover-supporting-text-color);--md-outlined-field-error-hover-trailing-content-color: var(--_text-field-error-hover-trailing-icon-color);--md-outlined-field-error-label-text-color: var(--_text-field-error-label-text-color);--md-outlined-field-error-leading-content-color: var(--_text-field-error-leading-icon-color);--md-outlined-field-error-outline-color: var(--_text-field-error-outline-color);--md-outlined-field-error-supporting-text-color: var(--_text-field-error-supporting-text-color);--md-outlined-field-error-trailing-content-color: var(--_text-field-error-trailing-icon-color);--md-outlined-field-focus-content-color: var(--_text-field-focus-input-text-color);--md-outlined-field-focus-label-text-color: var(--_text-field-focus-label-text-color);--md-outlined-field-focus-leading-content-color: var(--_text-field-focus-leading-icon-color);--md-outlined-field-focus-outline-color: var(--_text-field-focus-outline-color);--md-outlined-field-focus-outline-width: var(--_text-field-focus-outline-width);--md-outlined-field-focus-supporting-text-color: var(--_text-field-focus-supporting-text-color);--md-outlined-field-focus-trailing-content-color: var(--_text-field-focus-trailing-icon-color);--md-outlined-field-hover-content-color: var(--_text-field-hover-input-text-color);--md-outlined-field-hover-label-text-color: var(--_text-field-hover-label-text-color);--md-outlined-field-hover-leading-content-color: var(--_text-field-hover-leading-icon-color);--md-outlined-field-hover-outline-color: var(--_text-field-hover-outline-color);--md-outlined-field-hover-outline-width: var(--_text-field-hover-outline-width);--md-outlined-field-hover-supporting-text-color: var(--_text-field-hover-supporting-text-color);--md-outlined-field-hover-trailing-content-color: var(--_text-field-hover-trailing-icon-color);--md-outlined-field-label-text-color: var(--_text-field-label-text-color);--md-outlined-field-label-text-font: var(--_text-field-label-text-font);--md-outlined-field-label-text-line-height: var(--_text-field-label-text-line-height);--md-outlined-field-label-text-populated-line-height: var(--_text-field-label-text-populated-line-height);--md-outlined-field-label-text-populated-size: var(--_text-field-label-text-populated-size);--md-outlined-field-label-text-size: var(--_text-field-label-text-size);--md-outlined-field-label-text-weight: var(--_text-field-label-text-weight);--md-outlined-field-leading-content-color: var(--_text-field-leading-icon-color);--md-outlined-field-outline-color: var(--_text-field-outline-color);--md-outlined-field-outline-width: var(--_text-field-outline-width);--md-outlined-field-supporting-text-color: var(--_text-field-supporting-text-color);--md-outlined-field-supporting-text-font: var(--_text-field-supporting-text-font);--md-outlined-field-supporting-text-line-height: var(--_text-field-supporting-text-line-height);--md-outlined-field-supporting-text-size: var(--_text-field-supporting-text-size);--md-outlined-field-supporting-text-weight: var(--_text-field-supporting-text-weight);--md-outlined-field-trailing-content-color: var(--_text-field-trailing-icon-color)}[has-start] .icon.leading{font-size:var(--_text-field-leading-icon-size);height:var(--_text-field-leading-icon-size);width:var(--_text-field-leading-icon-size)}.icon.trailing{font-size:var(--_text-field-trailing-icon-size);height:var(--_text-field-trailing-icon-size);width:var(--_text-field-trailing-icon-size)}\n`;\nexport default styles.styleSheet;\n//# sourceMappingURL=outlined-select-styles.cssresult.js.map","/**\n * @license\n * Copyright 2026 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n// Generated stylesheet for ./select/internal/shared-styles.css.\nimport { css } from 'lit';\nexport const styles = css `:host{color:unset;min-width:210px;display:flex}.field{cursor:default;outline:none}.select{position:relative;flex-direction:column}.icon.trailing svg,.icon ::slotted(*){fill:currentColor}.icon ::slotted(*){width:inherit;height:inherit;font-size:inherit}.icon slot{display:flex;height:100%;width:100%;align-items:center;justify-content:center}.icon.trailing :is(.up,.down){opacity:0;transition:opacity 75ms linear 75ms}.select:not(.open) .down,.select.open .up{opacity:1}.field,.select,md-menu{min-width:inherit;width:inherit;max-width:inherit;display:flex}md-menu{min-width:var(--__menu-min-width);max-width:var(--__menu-max-width, inherit)}.menu-wrapper{width:0px;height:0px;max-width:inherit}md-menu ::slotted(:not[disabled]){cursor:pointer}.field,.select{width:100%}:host{display:inline-flex}:host([disabled]){pointer-events:none}\n`;\nexport default styles.styleSheet;\n//# sourceMappingURL=shared-styles.cssresult.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { __decorate } from \"tslib\";\nimport { customElement } from 'lit/decorators.js';\nimport { OutlinedSelect } from './internal/outlined-select.js';\nimport { styles } from './internal/outlined-select-styles.cssresult.js';\nimport { styles as sharedStyles } from './internal/shared-styles.cssresult.js';\n/**\n * @summary\n * Select menus display a list of choices on temporary surfaces and display the\n * currently selected menu item above the menu.\n *\n * @description\n * The select component allows users to choose a value from a fixed list of\n * available options. Composed of an interactive anchor button and a menu, it is\n * analogous to the native HTML `<select>` element. This is the \"outlined\"\n * variant.\n *\n * @example\n * ```html\n * <md-outlined-select label=\"fruits\">\n * <!-- An empty selected option will give select an \"un-filled\" state -->\n * <md-select-option selected></md-select-option>\n * <md-select-option value=\"apple\" headline=\"Apple\"></md-select-option>\n * <md-select-option value=\"banana\" headline=\"Banana\"></md-select-option>\n * <md-select-option value=\"kiwi\" headline=\"Kiwi\"></md-select-option>\n * <md-select-option value=\"orange\" headline=\"Orange\"></md-select-option>\n * <md-select-option value=\"tomato\" headline=\"Tomato\"></md-select-option>\n * </md-outlined-select>\n * ```\n *\n * @final\n * @suppress {visibility}\n */\nlet MdOutlinedSelect = class MdOutlinedSelect extends OutlinedSelect {\n};\nMdOutlinedSelect.styles = [sharedStyles, styles];\nMdOutlinedSelect = __decorate([\n customElement('md-outlined-select')\n], MdOutlinedSelect);\nexport { MdOutlinedSelect };\n//# sourceMappingURL=outlined-select.js.map","/**\n * @license\n * Copyright 2026 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n// Generated stylesheet for ./menu/internal/menuitem/menu-item-styles.css.\nimport { css } from 'lit';\nexport const styles = css `:host{display:flex;gap:16px;--md-ripple-hover-color: var(--md-menu-item-hover-state-layer-color, var(--md-sys-color-on-surface, #1d1b20));--md-ripple-hover-opacity: var(--md-menu-item-hover-state-layer-opacity, 0.08);--md-ripple-pressed-color: var(--md-menu-item-pressed-state-layer-color, var(--md-sys-color-on-surface, #1d1b20));--md-ripple-pressed-opacity: var(--md-menu-item-pressed-state-layer-opacity, 0.12)}:host([disabled]){opacity:var(--md-menu-item-disabled-opacity, 0.3);pointer-events:none}md-focus-ring{z-index:1;--md-focus-ring-shape: 8px}a,button,li{background:none;border:none;padding:0;margin:0;text-align:unset;text-decoration:none}.list-item{border-radius:inherit;display:flex;flex:1;gap:inherit;max-width:inherit;min-width:inherit;outline:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}.list-item:not(.disabled){cursor:pointer}[slot=container]{pointer-events:none}md-ripple{border-radius:inherit}md-item{border-radius:inherit;flex:1;color:var(--md-menu-item-label-text-color, var(--md-sys-color-on-surface, #1d1b20));font-family:var(--md-menu-item-label-text-font, var(--md-sys-typescale-body-large-font, var(--md-ref-typeface-plain, Roboto)));font-size:var(--md-menu-item-label-text-size, var(--md-sys-typescale-body-large-size, 1rem));line-height:var(--md-menu-item-label-text-line-height, var(--md-sys-typescale-body-large-line-height, 1.5rem));font-weight:var(--md-menu-item-label-text-weight, var(--md-sys-typescale-body-large-weight, var(--md-ref-typeface-weight-regular, 400)));min-height:var(--md-menu-item-one-line-container-height, 56px);padding-top:var(--md-menu-item-top-space, 12px);padding-bottom:var(--md-menu-item-bottom-space, 12px);padding-inline-start:var(--md-menu-item-leading-space, 16px);padding-inline-end:var(--md-menu-item-trailing-space, 16px);gap:inherit}md-item[multiline]{min-height:var(--md-menu-item-two-line-container-height, 72px)}[slot=supporting-text]{color:var(--md-menu-item-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));font-family:var(--md-menu-item-supporting-text-font, var(--md-sys-typescale-body-medium-font, var(--md-ref-typeface-plain, Roboto)));font-size:var(--md-menu-item-supporting-text-size, var(--md-sys-typescale-body-medium-size, 0.875rem));line-height:var(--md-menu-item-supporting-text-line-height, var(--md-sys-typescale-body-medium-line-height, 1.25rem));font-weight:var(--md-menu-item-supporting-text-weight, var(--md-sys-typescale-body-medium-weight, var(--md-ref-typeface-weight-regular, 400)))}[slot=trailing-supporting-text]{color:var(--md-menu-item-trailing-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));font-family:var(--md-menu-item-trailing-supporting-text-font, var(--md-sys-typescale-label-small-font, var(--md-ref-typeface-plain, Roboto)));font-size:var(--md-menu-item-trailing-supporting-text-size, var(--md-sys-typescale-label-small-size, 0.6875rem));line-height:var(--md-menu-item-trailing-supporting-text-line-height, var(--md-sys-typescale-label-small-line-height, 1rem));font-weight:var(--md-menu-item-trailing-supporting-text-weight, var(--md-sys-typescale-label-small-weight, var(--md-ref-typeface-weight-medium, 500)))}:is([slot=start],[slot=end])::slotted(*){fill:currentColor}[slot=start]{color:var(--md-menu-item-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f))}[slot=end]{color:var(--md-menu-item-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f))}.list-item{background-color:var(--md-menu-item-container-color, transparent)}.list-item.selected{background-color:var(--md-menu-item-selected-container-color, var(--md-sys-color-secondary-container, #e8def8))}.selected:not(.disabled) ::slotted(*){color:var(--md-menu-item-selected-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b))}@media(forced-colors: active){:host([disabled]),:host([disabled]) slot{color:GrayText;opacity:1}.list-item{position:relative}.list-item.selected::before{content:\"\";position:absolute;inset:0;box-sizing:border-box;border-radius:inherit;pointer-events:none;border:3px double CanvasText}}\n`;\nexport default styles.styleSheet;\n//# sourceMappingURL=menu-item-styles.cssresult.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { __decorate } from \"tslib\";\nimport { html, LitElement } from 'lit';\nimport { property, queryAll } from 'lit/decorators.js';\n/**\n * An item layout component.\n */\nexport class Item extends LitElement {\n constructor() {\n super(...arguments);\n /**\n * Only needed for SSR.\n *\n * Add this attribute when an item has two lines to avoid a Flash Of Unstyled\n * Content. This attribute is not needed for single line items or items with\n * three or more lines.\n */\n this.multiline = false;\n }\n render() {\n return html `\n <slot name=\"container\"></slot>\n <slot class=\"non-text\" name=\"start\"></slot>\n <div class=\"text\">\n <slot name=\"overline\" @slotchange=${this.handleTextSlotChange}></slot>\n <slot\n class=\"default-slot\"\n @slotchange=${this.handleTextSlotChange}></slot>\n <slot name=\"headline\" @slotchange=${this.handleTextSlotChange}></slot>\n <slot\n name=\"supporting-text\"\n @slotchange=${this.handleTextSlotChange}></slot>\n </div>\n <slot class=\"non-text\" name=\"trailing-supporting-text\"></slot>\n <slot class=\"non-text\" name=\"end\"></slot>\n `;\n }\n handleTextSlotChange() {\n // Check if there's more than one text slot with content. If so, the item is\n // multiline, which has a different min-height than single line items.\n let isMultiline = false;\n let slotsWithContent = 0;\n for (const slot of this.textSlots) {\n if (slotHasContent(slot)) {\n slotsWithContent += 1;\n }\n if (slotsWithContent > 1) {\n isMultiline = true;\n break;\n }\n }\n this.multiline = isMultiline;\n }\n}\n__decorate([\n property({ type: Boolean, reflect: true })\n], Item.prototype, \"multiline\", void 0);\n__decorate([\n queryAll('.text slot')\n], Item.prototype, \"textSlots\", void 0);\nfunction slotHasContent(slot) {\n for (const node of slot.assignedNodes({ flatten: true })) {\n // Assume there's content if there's an element slotted in\n const isElement = node.nodeType === Node.ELEMENT_NODE;\n // If there's only text nodes for the default slot, check if there's\n // non-whitespace.\n const isTextWithContent = node.nodeType === Node.TEXT_NODE && node.textContent?.match(/\\S/);\n if (isElement || isTextWithContent) {\n return true;\n }\n }\n return false;\n}\n//# sourceMappingURL=item.js.map","/**\n * @license\n * Copyright 2026 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n// Generated stylesheet for ./labs/item/internal/item-styles.css.\nimport { css } from 'lit';\nexport const styles = css `:host{color:var(--md-sys-color-on-surface, #1d1b20);font-family:var(--md-sys-typescale-body-large-font, var(--md-ref-typeface-plain, Roboto));font-size:var(--md-sys-typescale-body-large-size, 1rem);font-weight:var(--md-sys-typescale-body-large-weight, var(--md-ref-typeface-weight-regular, 400));line-height:var(--md-sys-typescale-body-large-line-height, 1.5rem);align-items:center;box-sizing:border-box;display:flex;gap:16px;min-height:56px;overflow:hidden;padding:12px 16px;position:relative;text-overflow:ellipsis}:host([multiline]){min-height:72px}[name=overline]{color:var(--md-sys-color-on-surface-variant, #49454f);font-family:var(--md-sys-typescale-label-small-font, var(--md-ref-typeface-plain, Roboto));font-size:var(--md-sys-typescale-label-small-size, 0.6875rem);font-weight:var(--md-sys-typescale-label-small-weight, var(--md-ref-typeface-weight-medium, 500));line-height:var(--md-sys-typescale-label-small-line-height, 1rem)}[name=supporting-text]{color:var(--md-sys-color-on-surface-variant, #49454f);font-family:var(--md-sys-typescale-body-medium-font, var(--md-ref-typeface-plain, Roboto));font-size:var(--md-sys-typescale-body-medium-size, 0.875rem);font-weight:var(--md-sys-typescale-body-medium-weight, var(--md-ref-typeface-weight-regular, 400));line-height:var(--md-sys-typescale-body-medium-line-height, 1.25rem)}[name=trailing-supporting-text]{color:var(--md-sys-color-on-surface-variant, #49454f);font-family:var(--md-sys-typescale-label-small-font, var(--md-ref-typeface-plain, Roboto));font-size:var(--md-sys-typescale-label-small-size, 0.6875rem);font-weight:var(--md-sys-typescale-label-small-weight, var(--md-ref-typeface-weight-medium, 500));line-height:var(--md-sys-typescale-label-small-line-height, 1rem)}[name=container]::slotted(*){inset:0;position:absolute}.default-slot{display:inline}.default-slot,.text ::slotted(*){overflow:hidden;text-overflow:ellipsis}.text{display:flex;flex:1;flex-direction:column;overflow:hidden}\n`;\nexport default styles.styleSheet;\n//# sourceMappingURL=item-styles.cssresult.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { __decorate } from \"tslib\";\nimport { customElement } from 'lit/decorators.js';\nimport { Item } from './internal/item.js';\nimport { styles } from './internal/item-styles.cssresult.js';\n/**\n * An item layout component that can be used inside list items to give them\n * their customizable structure.\n *\n * `<md-item>` does not have any functionality, which must be added by the\n * component using it.\n *\n * All text will wrap unless `white-space: nowrap` is set on the item or any of\n * its children.\n *\n * Slots available:\n * - `<default>`: The headline, or custom content.\n * - `headline`: The first line.\n * - `supporting-text`: Supporting text lines underneath the headline.\n * - `trailing-supporting-text`: A small text snippet at the end of the item.\n * - `start`: Any leading content, such as icons, avatars, or checkboxes.\n * - `end`: Any trailing content, such as icons and buttons.\n * - `container`: Background container content, intended for adding additional\n * styles, such as ripples or focus rings.\n *\n * @example\n * ```html\n * <md-item>Single line</md-item>\n *\n * <md-item>\n * <div class=\"custom-content\">...</div>\n * </md-item>\n *\n * <!-- Classic 1 to 3+ line list items -->\n * <md-item>\n * <md-icon slot=\"start\">image</md-icon>\n * <div slot=\"overline\">Overline</div>\n * <div slot=\"headline\">Headline</div>\n * <div=\"supporting-text\">Supporting text</div>\n * <div=\"trailing-supporting-text\">Trailing</div>\n * <md-icon slot=\"end\">image</md-icon>\n * </md-item>\n * ```\n *\n * When wrapping `<md-item>`, forward the available slots to use the same slot\n * structure for the wrapping component (this is what `<md-list-item>` does).\n *\n * @example\n * ```html\n * <md-item>\n * <slot></slot>\n * <slot name=\"overline\" slot=\"overline\"></slot>\n * <slot name=\"headline\" slot=\"headline\"></slot>\n * <slot name=\"supporting-text\" slot=\"supporting-text\"></slot>\n * <slot name=\"trailing-supporting-text\"\n * slot=\"trailing-supporting-text\"></slot>\n * <slot name=\"start\" slot=\"start\"></slot>\n * <slot name=\"end\" slot=\"end\"></slot>\n * </md-item>\n * ```\n *\n * @final\n * @suppress {visibility}\n */\nlet MdItem = class MdItem extends Item {\n};\nMdItem.styles = [styles];\nMdItem = __decorate([\n customElement('md-item')\n], MdItem);\nexport { MdItem };\n//# sourceMappingURL=item.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { CloseReason, createDefaultCloseMenuEvent, isClosableKey, } from './shared.js';\n/**\n * A controller that provides most functionality of an element that implements\n * the MenuItem interface.\n */\nexport class MenuItemController {\n /**\n * @param host The MenuItem in which to attach this controller to.\n * @param config The object that configures this controller's behavior.\n */\n constructor(host, config) {\n this.host = host;\n this.internalTypeaheadText = null;\n /**\n * Bind this click listener to the interactive element. Handles closing the\n * menu.\n */\n this.onClick = () => {\n if (this.host.keepOpen)\n return;\n this.host.dispatchEvent(createDefaultCloseMenuEvent(this.host, {\n kind: CloseReason.CLICK_SELECTION,\n }));\n };\n /**\n * Bind this click listener to the interactive element. Handles closing the\n * menu.\n */\n this.onKeydown = (event) => {\n // Check if the interactive element is an anchor tag. If so, click it.\n if (this.host.href && event.code === 'Enter') {\n const interactiveElement = this.getInteractiveElement();\n if (interactiveElement instanceof HTMLAnchorElement) {\n interactiveElement.click();\n }\n }\n if (event.defaultPrevented)\n return;\n // If the host has keepOpen = true we should ignore clicks & Space/Enter,\n // however we always maintain the ability to close a menu with a explicit\n // `escape` keypress.\n const keyCode = event.code;\n if (this.host.keepOpen && keyCode !== 'Escape')\n return;\n if (isClosableKey(keyCode)) {\n event.preventDefault();\n this.host.dispatchEvent(createDefaultCloseMenuEvent(this.host, {\n kind: CloseReason.KEYDOWN,\n key: keyCode,\n }));\n }\n };\n this.getHeadlineElements = config.getHeadlineElements;\n this.getSupportingTextElements = config.getSupportingTextElements;\n this.getDefaultElements = config.getDefaultElements;\n this.getInteractiveElement = config.getInteractiveElement;\n this.host.addController(this);\n }\n /**\n * The text that is selectable via typeahead. If not set, defaults to the\n * innerText of the item slotted into the `\"headline\"` slot, and if there are\n * no slotted elements into headline, then it checks the _default_ slot, and\n * then the `\"supporting-text\"` slot if nothing is in _default_.\n */\n get typeaheadText() {\n if (this.internalTypeaheadText !== null) {\n return this.internalTypeaheadText;\n }\n const headlineElements = this.getHeadlineElements();\n const textParts = [];\n headlineElements.forEach((headlineElement) => {\n if (headlineElement.textContent && headlineElement.textContent.trim()) {\n textParts.push(headlineElement.textContent.trim());\n }\n });\n // If there are no headline elements, check the default slot's text content\n if (textParts.length === 0) {\n this.getDefaultElements().forEach((defaultElement) => {\n if (defaultElement.textContent && defaultElement.textContent.trim()) {\n textParts.push(defaultElement.textContent.trim());\n }\n });\n }\n // If there are no headline nor default slot elements, check the\n //supporting-text slot's text content\n if (textParts.length === 0) {\n this.getSupportingTextElements().forEach((supportingTextElement) => {\n if (supportingTextElement.textContent &&\n supportingTextElement.textContent.trim()) {\n textParts.push(supportingTextElement.textContent.trim());\n }\n });\n }\n return textParts.join(' ');\n }\n /**\n * The recommended tag name to render as the list item.\n */\n get tagName() {\n const type = this.host.type;\n switch (type) {\n case 'link':\n return 'a';\n case 'button':\n return 'button';\n default:\n case 'menuitem':\n case 'option':\n return 'li';\n }\n }\n /**\n * The recommended role of the menu item.\n */\n get role() {\n return this.host.type === 'option' ? 'option' : 'menuitem';\n }\n hostConnected() {\n this.host.toggleAttribute('md-menu-item', true);\n }\n hostUpdate() {\n if (this.host.href) {\n this.host.type = 'link';\n }\n }\n /**\n * Use to set the typeaheadText when it changes.\n */\n setTypeaheadText(text) {\n this.internalTypeaheadText = text;\n }\n}\n//# sourceMappingURL=menuItemController.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { MenuItemController, } from '../../../menu/internal/controllers/menuItemController.js';\n/**\n * Creates an event fired by a SelectOption to request selection from md-select.\n * Typically fired after `selected` changes from `false` to `true`.\n */\nexport function createRequestSelectionEvent() {\n return new Event('request-selection', {\n bubbles: true,\n composed: true,\n });\n}\n/**\n * Creates an event fired by a SelectOption to request deselection from\n * md-select. Typically fired after `selected` changes from `true` to `false`.\n */\nexport function createRequestDeselectionEvent() {\n return new Event('request-deselection', {\n bubbles: true,\n composed: true,\n });\n}\n/**\n * A controller that provides most functionality and md-select compatibility for\n * an element that implements the SelectOption interface.\n */\nexport class SelectOptionController {\n /**\n * The recommended role of the select option.\n */\n get role() {\n return this.menuItemController.role;\n }\n /**\n * The text that is selectable via typeahead. If not set, defaults to the\n * innerText of the item slotted into the `\"headline\"` slot, and if there are\n * no slotted elements into headline, then it checks the _default_ slot, and\n * then the `\"supporting-text\"` slot if nothing is in _default_.\n */\n get typeaheadText() {\n return this.menuItemController.typeaheadText;\n }\n setTypeaheadText(text) {\n this.menuItemController.setTypeaheadText(text);\n }\n /**\n * The text that is displayed in the select field when selected. If not set,\n * defaults to the textContent of the item slotted into the `\"headline\"` slot,\n * and if there are no slotted elements into headline, then it checks the\n * _default_ slot, and then the `\"supporting-text\"` slot if nothing is in\n * _default_.\n */\n get displayText() {\n if (this.internalDisplayText !== null) {\n return this.internalDisplayText;\n }\n return this.menuItemController.typeaheadText;\n }\n setDisplayText(text) {\n this.internalDisplayText = text;\n }\n /**\n * @param host The SelectOption in which to attach this controller to.\n * @param config The object that configures this controller's behavior.\n */\n constructor(host, config) {\n this.host = host;\n this.internalDisplayText = null;\n this.firstUpdate = true;\n /**\n * Bind this click listener to the interactive element. Handles closing the\n * menu.\n */\n this.onClick = () => {\n this.menuItemController.onClick();\n };\n /**\n * Bind this click listener to the interactive element. Handles closing the\n * menu.\n */\n this.onKeydown = (e) => {\n this.menuItemController.onKeydown(e);\n };\n this.lastSelected = this.host.selected;\n this.menuItemController = new MenuItemController(host, config);\n host.addController(this);\n }\n hostUpdate() {\n if (this.lastSelected !== this.host.selected) {\n this.host.ariaSelected = this.host.selected ? 'true' : 'false';\n }\n }\n hostUpdated() {\n // Do not dispatch event on first update / boot-up.\n if (this.lastSelected !== this.host.selected && !this.firstUpdate) {\n // This section is really useful for when the user sets selected on the\n // option programmatically. Most other cases (click and keyboard) are\n // handled by md-select because it needs to coordinate the\n // single-selection behavior.\n if (this.host.selected) {\n this.host.dispatchEvent(createRequestSelectionEvent());\n }\n else {\n this.host.dispatchEvent(createRequestDeselectionEvent());\n }\n }\n this.lastSelected = this.host.selected;\n this.firstUpdate = false;\n }\n}\n//# sourceMappingURL=selectOptionController.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { __decorate } from \"tslib\";\nimport '../../../focus/md-focus-ring.js';\nimport '../../../labs/item/item.js';\nimport '../../../ripple/ripple.js';\nimport { html, LitElement, nothing } from 'lit';\nimport { property, query, queryAssignedElements, queryAssignedNodes, } from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { mixinDelegatesAria } from '../../../internal/aria/delegate.js';\nimport { SelectOptionController } from './selectOptionController.js';\n// Separate variable needed for closure.\nconst selectOptionBaseClass = mixinDelegatesAria(LitElement);\n/**\n * @fires close-menu {CustomEvent<{initiator: SelectOption, reason: Reason, itemPath: SelectOption[]}>}\n * Closes the encapsulating menu on closable interaction. --bubbles --composed\n * @fires request-selection {Event} Requests the parent md-select to select this\n * element (and deselect others if single-selection) when `selected` changed to\n * `true`. --bubbles --composed\n * @fires request-deselection {Event} Requests the parent md-select to deselect\n * this element when `selected` changed to `false`. --bubbles --composed\n */\nexport class SelectOptionEl extends selectOptionBaseClass {\n constructor() {\n super(...arguments);\n /**\n * Disables the item and makes it non-selectable and non-interactive.\n */\n this.disabled = false;\n /**\n * READONLY: self-identifies as a menu item and sets its identifying attribute\n */\n this.isMenuItem = true;\n /**\n * Sets the item in the selected visual state when a submenu is opened.\n */\n this.selected = false;\n /**\n * Form value of the option.\n */\n this.value = '';\n this.type = 'option';\n this.selectOptionController = new SelectOptionController(this, {\n getHeadlineElements: () => {\n return this.headlineElements;\n },\n getSupportingTextElements: () => {\n return this.supportingTextElements;\n },\n getDefaultElements: () => {\n return this.defaultElements;\n },\n getInteractiveElement: () => this.listItemRoot,\n });\n }\n /**\n * The text that is selectable via typeahead. If not set, defaults to the\n * innerText of the item slotted into the `\"headline\"` slot.\n */\n get typeaheadText() {\n return this.selectOptionController.typeaheadText;\n }\n set typeaheadText(text) {\n this.selectOptionController.setTypeaheadText(text);\n }\n /**\n * The text that is displayed in the select field when selected. If not set,\n * defaults to the textContent of the item slotted into the `\"headline\"` slot.\n */\n get displayText() {\n return this.selectOptionController.displayText;\n }\n set displayText(text) {\n this.selectOptionController.setDisplayText(text);\n }\n render() {\n return this.renderListItem(html `\n <md-item>\n <div slot=\"container\">\n ${this.renderRipple()} ${this.renderFocusRing()}\n </div>\n <slot name=\"start\" slot=\"start\"></slot>\n <slot name=\"end\" slot=\"end\"></slot>\n ${this.renderBody()}\n </md-item>\n `);\n }\n /**\n * Renders the root list item.\n *\n * @param content the child content of the list item.\n */\n renderListItem(content) {\n return html `\n <li\n id=\"item\"\n tabindex=${this.disabled ? -1 : 0}\n role=${this.selectOptionController.role}\n aria-label=${this.ariaLabel || nothing}\n aria-selected=${this.ariaSelected || nothing}\n aria-checked=${this.ariaChecked || nothing}\n aria-expanded=${this.ariaExpanded || nothing}\n aria-haspopup=${this.ariaHasPopup || nothing}\n class=\"list-item ${classMap(this.getRenderClasses())}\"\n @click=${this.selectOptionController.onClick}\n @keydown=${this.selectOptionController.onKeydown}\n >${content}</li\n >\n `;\n }\n /**\n * Handles rendering of the ripple element.\n */\n renderRipple() {\n return html ` <md-ripple\n part=\"ripple\"\n for=\"item\"\n ?disabled=${this.disabled}></md-ripple>`;\n }\n /**\n * Handles rendering of the focus ring.\n */\n renderFocusRing() {\n return html ` <md-focus-ring\n part=\"focus-ring\"\n for=\"item\"\n inward></md-focus-ring>`;\n }\n /**\n * Classes applied to the list item root.\n */\n getRenderClasses() {\n return {\n 'disabled': this.disabled,\n 'selected': this.selected,\n };\n }\n /**\n * Handles rendering the headline and supporting text.\n */\n renderBody() {\n return html `\n <slot></slot>\n <slot name=\"overline\" slot=\"overline\"></slot>\n <slot name=\"headline\" slot=\"headline\"></slot>\n <slot name=\"supporting-text\" slot=\"supporting-text\"></slot>\n <slot\n name=\"trailing-supporting-text\"\n slot=\"trailing-supporting-text\"></slot>\n `;\n }\n focus() {\n // TODO(b/300334509): needed for some cases where delegatesFocus doesn't\n // work programmatically like in FF and select-option\n this.listItemRoot?.focus();\n }\n}\n/** @nocollapse */\nSelectOptionEl.shadowRootOptions = {\n ...LitElement.shadowRootOptions,\n delegatesFocus: true,\n};\n__decorate([\n property({ type: Boolean, reflect: true })\n], SelectOptionEl.prototype, \"disabled\", void 0);\n__decorate([\n property({ type: Boolean, attribute: 'md-menu-item', reflect: true })\n], SelectOptionEl.prototype, \"isMenuItem\", void 0);\n__decorate([\n property({ type: Boolean })\n], SelectOptionEl.prototype, \"selected\", void 0);\n__decorate([\n property()\n], SelectOptionEl.prototype, \"value\", void 0);\n__decorate([\n query('.list-item')\n], SelectOptionEl.prototype, \"listItemRoot\", void 0);\n__decorate([\n queryAssignedElements({ slot: 'headline' })\n], SelectOptionEl.prototype, \"headlineElements\", void 0);\n__decorate([\n queryAssignedElements({ slot: 'supporting-text' })\n], SelectOptionEl.prototype, \"supportingTextElements\", void 0);\n__decorate([\n queryAssignedNodes({ slot: '' })\n], SelectOptionEl.prototype, \"defaultElements\", void 0);\n__decorate([\n property({ attribute: 'typeahead-text' })\n], SelectOptionEl.prototype, \"typeaheadText\", null);\n__decorate([\n property({ attribute: 'display-text' })\n], SelectOptionEl.prototype, \"displayText\", null);\n//# sourceMappingURL=select-option.js.map","/**\n * @license\n * Copyright 2023 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nimport { __decorate } from \"tslib\";\nimport { customElement } from 'lit/decorators.js';\nimport { styles } from '../menu/internal/menuitem/menu-item-styles.cssresult.js';\nimport { SelectOptionEl } from './internal/selectoption/select-option.js';\n/**\n * @summary\n * Select menus display a list of choices on temporary surfaces and display the\n * currently selected menu item above the menu.\n *\n * @description\n * The select component allows users to choose a value from a fixed list of\n * available options. Composed of an interactive anchor button and a menu, it is\n * analogous to the native HTML `<select>` element. This is the option that\n * can be placed inside of an md-select.\n *\n * This component is a subclass of `md-menu-item` and can accept the same slots,\n * properties, and events as `md-menu-item`.\n *\n * @example\n * ```html\n * <md-outlined-select label=\"fruits\">\n * <!-- An empty selected option will give select an \"un-filled\" state -->\n * <md-select-option selected></md-select-option>\n * <md-select-option value=\"apple\" headline=\"Apple\"></md-select-option>\n * <md-select-option value=\"banana\" headline=\"Banana\"></md-select-option>\n * <md-select-option value=\"kiwi\" headline=\"Kiwi\"></md-select-option>\n * <md-select-option value=\"orange\" headline=\"Orange\"></md-select-option>\n * <md-select-option value=\"tomato\" headline=\"Tomato\"></md-select-option>\n * </md-outlined-select>\n * ```\n *\n * @final\n * @suppress {visibility}\n */\nlet MdSelectOption = class MdSelectOption extends SelectOptionEl {\n};\nMdSelectOption.styles = [styles];\nMdSelectOption = __decorate([\n customElement('md-select-option')\n], MdSelectOption);\nexport { MdSelectOption };\n//# sourceMappingURL=select-option.js.map","<script lang=\"ts\">\n // A native checkbox, not `md-checkbox`: that passes only its name to the control inside, so the\n // text under it would not be announced with it.\n type Props = {\n path: string;\n label: string;\n checked: boolean;\n /** The text under the checkbox, announced with it. */\n help: string;\n /** Why the value was refused; empty if it wasn't. */\n error: string;\n onChange: (checked: boolean) => void;\n };\n\n let { path, label, checked, help, error, onChange }: Props = $props();\n\n const id = $props.id();\n</script>\n\n<div>\n <label>\n <input\n type=\"checkbox\"\n data-setting={path}\n {checked}\n aria-describedby={error === '' ? `${id}-help` : `${id}-error ${id}-help`}\n aria-invalid={error === '' ? undefined : true}\n onchange={(event) => onChange(event.currentTarget.checked)}\n />\n <span>{label}</span>\n </label>\n <p class=\"help\" id=\"{id}-help\">{help}</p>\n {#if error !== ''}<p class=\"error\" id=\"{id}-error\" role=\"alert\">{error}</p>{/if}\n</div>\n\n<style>\n /* The row leaves 4px under the 20px box: as far as a text field's supporting text is from its\n field. */\n label {\n display: flex;\n align-items: center;\n gap: 12px;\n min-height: 28px;\n color: var(--md-sys-color-on-surface);\n font-size: 16px;\n line-height: 24px;\n cursor: pointer;\n }\n\n input {\n flex: none;\n width: 20px;\n height: 20px;\n margin: 0;\n accent-color: var(--md-sys-color-primary);\n cursor: pointer;\n }\n\n input:focus-visible {\n outline: var(--md-sys-state-focus-indicator-thickness) solid var(--md-sys-color-primary);\n outline-offset: 2px;\n }\n\n /* Indented like a text field's supporting text. */\n .help,\n .error {\n margin: 0;\n padding: 0 16px;\n color: var(--md-sys-color-on-surface-variant);\n font-size: 13px;\n line-height: 18px;\n }\n\n .error {\n color: var(--md-sys-color-error);\n }\n</style>\n","<script lang=\"ts\">\n import '@material/web/select/outlined-select.js';\n import '@material/web/select/select-option.js';\n import '@material/web/textfield/outlined-text-field.js';\n import CheckboxField from '#lib/components/CheckboxField/CheckboxField.svelte';\n import { selectOptions, type Setting } from '#lib/core/settings.js';\n\n type Props = {\n setting: Setting;\n /** What the control holds: the draft, or the saved value. */\n value: string;\n /** The saved value, as the control holds it. */\n savedValue: string;\n /** The text under the control. */\n help: string;\n /** The value in use while the saved one waits for a restart. */\n pendingValue?: string | undefined;\n /** Why the value was refused; empty if it wasn't. */\n error: string;\n /**\n * Set when a flag or variable sets the setting: it can't be changed here, so the field is a\n * read-only row with the value in use.\n */\n fixed?: { by: string; value: string } | undefined;\n onInput: (value: string) => void;\n /** Enter in a text field. */\n onSubmit: () => void;\n };\n\n let { setting, value, savedValue, help, pendingValue, error, fixed, onInput, onSubmit }: Props =\n $props();\n\n // In the supporting text, so a screen reader says it when the field gets the focus.\n const supporting = $derived(\n pendingValue === undefined ? help : `Restart pending, in use: ${pendingValue}. ${help}`,\n );\n</script>\n\n{#if fixed !== undefined}\n <!-- Text, not a disabled control: Tab skips those, and the value in use is what counts. -->\n <dl>\n <dt>{setting.label}</dt>\n <dd class=\"value\">{fixed.value}</dd>\n <dd class=\"note\">Set by <code>{fixed.by}</code>. Change it where the bridge is started.</dd>\n </dl>\n{:else}\n <div class:pending={pendingValue !== undefined}>\n {#if setting.control.kind === 'checkbox'}\n <CheckboxField\n path={setting.path}\n label={setting.label}\n checked={value === 'true'}\n help={supporting}\n {error}\n onChange={(checked: boolean) => onInput(String(checked))}\n />\n {:else if setting.control.kind === 'select'}\n <md-outlined-select\n data-setting={setting.path}\n label={setting.label}\n supporting-text={supporting}\n {value}\n error={error !== '' ? true : undefined}\n error-text={error}\n onchange={(event: Event) => onInput((event.target as HTMLSelectElement).value)}\n >\n {#each selectOptions(setting.control.options, savedValue) as option (option.value)}\n <md-select-option\n value={option.value}\n selected={option.value === value ? true : undefined}\n >\n <div slot=\"headline\">{option.label}</div>\n </md-select-option>\n {/each}\n </md-outlined-select>\n {:else}\n <!-- svelte-ignore a11y_no_static_element_interactions -->\n <md-outlined-text-field\n data-setting={setting.path}\n label={setting.label}\n inputmode={setting.control.inputmode}\n suffix-text={setting.control.suffix}\n autocomplete=\"off\"\n supporting-text={supporting}\n {value}\n error={error !== '' ? true : undefined}\n error-text={error}\n onkeydown={(event: KeyboardEvent) => {\n // Enter saves, whatever the text field does with the form around it.\n if (event.key !== 'Enter') return;\n event.preventDefault();\n onSubmit();\n }}\n oninput={(event: Event) => onInput((event.target as HTMLInputElement).value)}\n ></md-outlined-text-field>\n {/if}\n </div>\n{/if}\n\n<style>\n md-outlined-text-field,\n md-outlined-select {\n width: 100%;\n min-width: 0;\n }\n\n .pending {\n padding-left: 12px;\n border-left: 4px solid var(--app-warning);\n }\n\n dl {\n margin: 0;\n }\n\n dt,\n .note {\n color: var(--md-sys-color-on-surface-variant);\n font-size: 13px;\n line-height: 18px;\n }\n\n dd {\n margin: 0;\n }\n\n .value {\n margin: 2px 0;\n color: var(--md-sys-color-on-surface);\n font-size: 16px;\n line-height: 24px;\n }\n\n code {\n font-family: var(--app-mono-font, monospace);\n font-size: 0.95em;\n }\n</style>\n","<script lang=\"ts\">\n import '@material/web/button/filled-button.js';\n import '@material/web/button/text-button.js';\n import { tick } from 'svelte';\n import type { ConfigDto, ConfigPatchDto } from '@screenreader-speech-capture/shared';\n import SettingField from '#lib/components/SettingField/SettingField.svelte';\n import {\n buildPatch,\n changedSettings,\n explainRejection,\n isPending,\n readSetting,\n type Drafts,\n type Setting,\n type SettingContext,\n type SettingPath,\n } from '#lib/core/settings.js';\n\n type Props = {\n /** What the form's buttons are about, for their accessible names (`speech capture`). */\n name: string;\n /** In order, one per grid cell; settings that belong together share a cell, stacked. */\n settings: (Setting | Setting[])[];\n /** The configuration in use. */\n active: ConfigDto;\n /** The configuration the next start will use. */\n saved: ConfigDto;\n /** What sets a setting (`--tcp-port`) when a flag or variable does: it can't be changed here. */\n overrides: Readonly<Record<string, string>>;\n settingContext: SettingContext;\n /** Rejects with a message to show; resolves when the patch is saved. */\n onSave: (patch: ConfigPatchDto) => Promise<void>;\n };\n\n let { name, settings, active, saved, overrides, settingContext, onSave }: Props = $props();\n\n /** What was typed; a field without a draft follows the saved value. */\n let drafts = $state<Drafts>({});\n let errors = $state<Partial<Record<SettingPath, string>>>({});\n let failure = $state('');\n let busy = $state(false);\n /**\n * Set while the last thing that happened to this form is a save that worked: whether it left\n * something waiting for a restart.\n */\n let justSaved = $state<{ waited: boolean } | null>(null);\n let form: HTMLFormElement;\n\n const cells = $derived(settings.map((cell) => [cell].flat()));\n const editable = $derived(\n cells.flat().filter((setting) => overrides[setting.path] === undefined),\n );\n const changed = $derived(changedSettings(editable, drafts, saved));\n const idle = $derived(changed.length === 0 || busy);\n const waits = $derived(\n editable.some((setting) => isPending(setting.path, active, saved, overrides)),\n );\n // After the restart there is nothing left to say: the message goes, it doesn't change.\n const savedMessage = $derived.by(() => {\n if (justSaved === null) return '';\n if (!justSaved.waited) return 'Saved.';\n return waits ? 'Saved. Restart the bridge to apply.' : '';\n });\n\n function revert(): void {\n drafts = {};\n errors = {};\n failure = '';\n justSaved = null;\n }\n\n async function focusField(path: SettingPath): Promise<void> {\n await tick();\n form.querySelector<HTMLElement>(`[data-setting=\"${path}\"]`)?.focus();\n }\n\n async function save(): Promise<void> {\n if (busy || changed.length === 0) return;\n const result = buildPatch(editable, drafts, saved);\n failure = '';\n justSaved = null;\n if (!result.ok) {\n errors = result.errors;\n const first = editable.find((setting) => result.errors[setting.path] !== undefined)!;\n await focusField(first.path);\n return;\n }\n errors = {};\n busy = true;\n try {\n await onSave(result.patch);\n drafts = {};\n justSaved = { waited: waits };\n } catch (cause) {\n const rejection = explainRejection(cause, editable);\n if (rejection.field === null) {\n failure = rejection.message;\n } else {\n errors = { [rejection.field]: rejection.message };\n await focusField(rejection.field);\n }\n } finally {\n busy = false;\n }\n }\n</script>\n\n<form\n bind:this={form}\n novalidate\n onsubmit={(event) => {\n event.preventDefault();\n void save();\n }}\n>\n <div class=\"fields\">\n {#each cells as cell (cell[0].path)}\n <div class=\"cell\">\n {#each cell as setting (setting.path)}\n {@const overriddenBy = overrides[setting.path]}\n {@const inUse = readSetting(active, setting.path)}\n <SettingField\n {setting}\n value={drafts[setting.path] ?? setting.format(readSetting(saved, setting.path))}\n savedValue={setting.format(readSetting(saved, setting.path))}\n help={setting.help(inUse, settingContext)}\n pendingValue={isPending(setting.path, active, saved, overrides)\n ? setting.describe(inUse, settingContext)\n : undefined}\n error={errors[setting.path] ?? ''}\n fixed={overriddenBy === undefined\n ? undefined\n : { by: overriddenBy, value: setting.describe(inUse, settingContext) }}\n onInput={(value: string) => {\n drafts[setting.path] = value;\n delete errors[setting.path];\n justSaved = null;\n }}\n onSubmit={() => void save()}\n />\n {/each}\n </div>\n {/each}\n </div>\n\n {#if editable.length > 0}\n <!-- Soft-disabled: a disabled button would drop the focus it has after a save. -->\n <div class=\"actions\">\n <md-filled-button\n type=\"submit\"\n aria-label=\"Save {name} settings\"\n soft-disabled={idle ? true : undefined}>Save</md-filled-button\n >\n <!-- svelte-ignore a11y_click_events_have_key_events, a11y_no_static_element_interactions -->\n <md-text-button\n type=\"button\"\n aria-label=\"Revert {name} settings\"\n soft-disabled={idle ? true : undefined}\n onclick={revert}>Revert</md-text-button\n >\n </div>\n {/if}\n\n <!-- A live region that is always there, so the message is announced when it appears. -->\n <p role=\"status\" class=\"note\">{savedMessage}</p>\n\n {#if failure !== ''}<p role=\"alert\" class=\"failure\">{failure}</p>{/if}\n</form>\n\n<style>\n /* Wide enough for two columns of fields, not three. */\n form {\n display: flex;\n flex-direction: column;\n gap: 12px;\n max-width: 720px;\n padding: 8px;\n }\n\n /* Two columns when the form has room for them. A column holds the longest option of a select. */\n .fields {\n display: grid;\n grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));\n align-items: start;\n gap: 12px 24px;\n }\n\n .cell {\n display: flex;\n flex-direction: column;\n gap: 12px;\n min-width: 0;\n max-width: 480px;\n }\n\n .actions {\n display: flex;\n flex-wrap: wrap;\n gap: 8px;\n }\n\n .note {\n margin: 0;\n color: var(--md-sys-color-on-surface-variant);\n font-size: 13px;\n line-height: 18px;\n }\n\n .failure {\n margin: 0;\n color: var(--md-sys-color-error);\n font-size: 14px;\n line-height: 20px;\n }\n</style>\n","<script lang=\"ts\">\n import { THEMES, type Theme } from '#lib/core/theme.js';\n\n type Props = { value: Theme; onChange: (theme: Theme) => void };\n\n let { value, onChange }: Props = $props();\n</script>\n\n<fieldset>\n <legend>Color theme</legend>\n <p class=\"hint\">Stored in this browser only. Applied immediately.</p>\n <div class=\"options\">\n {#each THEMES as theme (theme.value)}\n <label class=\"option\">\n <input\n type=\"radio\"\n name=\"color-theme\"\n value={theme.value}\n checked={value === theme.value}\n aria-describedby=\"theme-{theme.value}-description\"\n onchange={() => onChange(theme.value)}\n />\n <span class=\"mark\" aria-hidden=\"true\"></span>\n <span class=\"swatch\" data-theme={theme.value} aria-hidden=\"true\">\n <span class=\"bar\"></span>\n <span class=\"aa\">Aa</span>\n <span class=\"chip\"></span>\n </span>\n <span class=\"text\">\n <span class=\"label\">{theme.label}</span>\n <span class=\"description\" id=\"theme-{theme.value}-description\">{theme.description}</span>\n </span>\n <span class=\"selected\" aria-hidden=\"true\">\n <svg\n width=\"18\"\n height=\"18\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"2\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n >\n <path d=\"M5 12.5l4.5 4.5L19 7.5\" />\n </svg>\n Selected\n </span>\n </label>\n {/each}\n </div>\n</fieldset>\n\n<style>\n fieldset {\n min-width: 0;\n margin: 0;\n padding: 0;\n border: 0;\n }\n\n legend {\n padding: 0;\n color: var(--md-sys-color-on-surface);\n font-size: 14px;\n font-weight: 500;\n line-height: 20px;\n }\n\n .hint {\n margin: 2px 0 12px;\n color: var(--md-sys-color-on-surface-variant);\n font-size: 13px;\n line-height: 18px;\n }\n\n .options {\n display: flex;\n flex-direction: column;\n gap: 8px;\n }\n\n .option {\n position: relative;\n display: flex;\n align-items: center;\n gap: 12px;\n min-height: 64px;\n padding: 8px 16px 8px 12px;\n border: 1px solid var(--md-sys-color-outline);\n border-radius: 12px;\n box-sizing: border-box;\n background: var(--md-sys-color-surface);\n color: var(--md-sys-color-on-surface);\n cursor: pointer;\n }\n\n .option:hover {\n background: var(--md-sys-color-surface-container-high);\n }\n\n /* The native radio stays the real control and covers the whole card. */\n input {\n position: absolute;\n inset: 0;\n margin: 0;\n opacity: 0;\n cursor: pointer;\n }\n\n .mark {\n display: grid;\n flex: none;\n place-items: center;\n width: 20px;\n height: 20px;\n border: 2px solid var(--md-sys-color-outline);\n border-radius: 50%;\n box-sizing: border-box;\n }\n\n .option:has(input:checked) {\n padding: 6px 14px 6px 10px;\n border: 3px solid var(--md-sys-color-primary);\n background: var(--md-sys-color-primary-container);\n color: var(--md-sys-color-on-primary-container);\n }\n\n .option:has(input:checked) .mark {\n border-color: var(--md-sys-color-primary);\n }\n\n .option:has(input:checked) .mark::after {\n width: 10px;\n height: 10px;\n border-radius: 50%;\n background: var(--md-sys-color-primary);\n content: '';\n }\n\n .option:has(input:focus-visible) {\n outline: var(--md-sys-state-focus-indicator-thickness) solid var(--md-sys-color-primary);\n outline-offset: 2px;\n }\n\n .text {\n display: flex;\n flex: 1;\n flex-direction: column;\n min-width: 0;\n }\n\n .label {\n font-size: 16px;\n font-weight: 500;\n line-height: 24px;\n }\n\n .description {\n font-size: 13px;\n line-height: 18px;\n }\n\n .option:not(:has(input:checked)) .description {\n color: var(--md-sys-color-on-surface-variant);\n }\n\n .selected {\n display: none;\n align-items: center;\n gap: 4px;\n color: var(--md-sys-color-on-primary-container);\n font-size: 12px;\n font-weight: 600;\n }\n\n .option:has(input:checked) .selected {\n display: inline-flex;\n }\n\n /* Each swatch carries its own theme's tokens (tokens.css has bare [data-theme] selectors). */\n .swatch {\n position: relative;\n display: block;\n flex: none;\n width: 72px;\n height: 44px;\n border: 2px solid var(--md-sys-color-outline);\n border-radius: 8px;\n box-sizing: border-box;\n overflow: hidden;\n background: var(--md-sys-color-surface);\n }\n\n .bar {\n position: absolute;\n inset: 0 0 auto;\n height: 10px;\n background: var(--md-sys-color-primary);\n }\n\n .aa {\n position: absolute;\n bottom: 5px;\n left: 8px;\n color: var(--md-sys-color-on-surface);\n font:\n 600 15px/16px system-ui,\n sans-serif;\n }\n\n .chip {\n position: absolute;\n right: 7px;\n bottom: 7px;\n width: 20px;\n height: 12px;\n border-radius: 6px;\n background: var(--md-sys-color-primary);\n }\n\n /* On a narrow screen the decorative swatch makes room for the name and \"Selected\". */\n @media (max-width: 400px) {\n .swatch {\n display: none;\n }\n }\n</style>\n","<script lang=\"ts\">\n import { onMount, untrack } from 'svelte';\n import type { ConfigPatchDto } from '@screenreader-speech-capture/shared';\n import {\n BUFFER_SIZE,\n LOG_LEVEL,\n MCP_ENABLED,\n PLAYWRIGHT_ENABLED,\n PLAYWRIGHT_VERSION,\n TCP_PORT,\n TEXT_ENCODING,\n waitingForRestart,\n } from '#lib/core/settings.js';\n import type { Theme } from '#lib/core/theme.js';\n import { appStores } from '#lib/composition.js';\n import Pane from '#lib/components/Pane/Pane.svelte';\n import RestartSummary from '#lib/components/RestartSummary/RestartSummary.svelte';\n import SettingsForm from '#lib/components/SettingsForm/SettingsForm.svelte';\n import ThemeSetting from '#lib/components/ThemeSetting/ThemeSetting.svelte';\n import type { PageProps } from './$types';\n\n let { data }: PageProps = $props();\n\n const { config: configStore, status: statusStore, theme: themeStore } = appStores();\n\n // The config the load read (`+page.server.ts`), already while rendering, so the server's HTML has\n // the settings.\n untrack(() => configStore.seed(data.config));\n\n // On the server the header's status store is still empty, the layout's load has the status.\n const settingContext = $derived({\n runningPlaywright: (statusStore.status ?? data.status)?.playwright.version ?? null,\n playwrightOff: configStore.saved?.playwright.enabled === false,\n });\n\n const waiting = $derived(\n configStore.active === null || configStore.saved === null\n ? []\n : waitingForRestart(\n configStore.active,\n configStore.saved,\n configStore.overrides,\n settingContext,\n ),\n );\n\n async function checkAgain(): Promise<void> {\n await Promise.all([configStore.refresh(), statusStore.retry()]);\n }\n\n onMount(() => {\n // Only if the load failed: try from the browser, which then says that the bridge is gone.\n if (data.config === null) void configStore.refresh();\n });\n</script>\n\n<svelte:head>\n <title>Settings · Speech Capture</title>\n</svelte:head>\n\n<Pane heading=\"Settings\">\n <p class=\"scope intro\">\n Bridge settings apply when the bridge is restarted. Appearance applies at once and is kept in\n this browser.\n </p>\n\n {#if configStore.active !== null && configStore.saved !== null}\n <RestartSummary changes={waiting} reachable={configStore.reachable} onCheck={checkAgain} />\n\n <section class=\"part\" aria-labelledby=\"capture-heading\">\n <h2 id=\"capture-heading\">Speech capture</h2>\n <SettingsForm\n name=\"speech capture\"\n settings={[TCP_PORT, TEXT_ENCODING, BUFFER_SIZE]}\n active={configStore.active}\n saved={configStore.saved}\n overrides={configStore.overrides}\n {settingContext}\n onSave={(patch: ConfigPatchDto) => configStore.save(patch)}\n />\n </section>\n\n <section class=\"part\" aria-labelledby=\"playwright-heading\">\n <h2 id=\"playwright-heading\">Playwright and MCP</h2>\n <SettingsForm\n name=\"Playwright and MCP\"\n settings={[[PLAYWRIGHT_ENABLED, PLAYWRIGHT_VERSION], MCP_ENABLED]}\n active={configStore.active}\n saved={configStore.saved}\n overrides={configStore.overrides}\n {settingContext}\n onSave={(patch: ConfigPatchDto) => configStore.save(patch)}\n />\n </section>\n\n <section class=\"part\" aria-labelledby=\"log-heading\">\n <h2 id=\"log-heading\">Bridge log</h2>\n <SettingsForm\n name=\"bridge log\"\n settings={[LOG_LEVEL]}\n active={configStore.active}\n saved={configStore.saved}\n overrides={configStore.overrides}\n {settingContext}\n onSave={(patch: ConfigPatchDto) => configStore.save(patch)}\n />\n </section>\n {:else if !configStore.reachable}\n <p class=\"scope\" role=\"alert\">\n The bridge is not reachable, so its settings can't be read.\n <button type=\"button\" onclick={() => void configStore.refresh()}>Try again</button>\n </p>\n {:else}\n <p class=\"scope\">Reading the bridge settings…</p>\n {/if}\n\n <section class=\"part\" aria-labelledby=\"appearance-heading\">\n <h2 id=\"appearance-heading\">Appearance</h2>\n <ThemeSetting value={themeStore.current} onChange={(theme: Theme) => themeStore.set(theme)} />\n </section>\n</Pane>\n"],"ignoreList":[0,1,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26],"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