@pod-os/elements 0.22.2-0b8a8a5.0 → 0.22.2-735eb6a.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/dist/cjs/{session-6106c9ff.js → BrokenFile-769cb073.js} +23 -1
  2. package/dist/cjs/BrokenFile-769cb073.js.map +1 -0
  3. package/dist/cjs/elements.cjs.js +1 -1
  4. package/dist/cjs/{ion-card_30.cjs.entry.js → ion-card_31.cjs.entry.js} +97 -18
  5. package/dist/cjs/ion-card_31.cjs.entry.js.map +1 -0
  6. package/dist/cjs/loader.cjs.js +1 -1
  7. package/dist/cjs/pos-document.cjs.entry.js +2 -3
  8. package/dist/cjs/pos-document.cjs.entry.js.map +1 -1
  9. package/dist/collection/components/pos-make-findable/pos-make-findable.js +34 -2
  10. package/dist/collection/components/pos-make-findable/pos-make-findable.js.map +1 -1
  11. package/dist/collection/components/pos-navigation-bar/pos-navigation-bar.css +6 -0
  12. package/dist/collection/components/pos-navigation-bar/pos-navigation-bar.js +1 -1
  13. package/dist/collection/components/pos-navigation-bar/pos-navigation-bar.js.map +1 -1
  14. package/dist/collection/components/pos-new-thing-form/pos-new-thing-form.js +1 -1
  15. package/dist/collection/components/pos-rich-link/pos-rich-link.js +2 -2
  16. package/dist/collection/components/pos-router/pos-router.js +1 -1
  17. package/dist/collection/components/pos-select-term/pos-select-term.js +1 -1
  18. package/dist/components/index10.js +1 -1
  19. package/dist/components/pos-app-browser.js +48 -42
  20. package/dist/components/pos-app-browser.js.map +1 -1
  21. package/dist/components/pos-container-contents2.js +1 -1
  22. package/dist/components/pos-make-findable.js +1 -136
  23. package/dist/components/pos-make-findable.js.map +1 -1
  24. package/dist/components/pos-make-findable2.js +152 -0
  25. package/dist/components/pos-make-findable2.js.map +1 -0
  26. package/dist/components/pos-navigation-bar2.js +26 -20
  27. package/dist/components/pos-navigation-bar2.js.map +1 -1
  28. package/dist/components/pos-new-thing-form2.js +1 -1
  29. package/dist/components/pos-rich-link2.js +2 -2
  30. package/dist/components/pos-router2.js +1 -1
  31. package/dist/components/pos-select-term2.js +1 -1
  32. package/dist/elements/elements.esm.js +1 -1
  33. package/dist/elements/elements.esm.js.map +1 -1
  34. package/dist/elements/p-1e173be8.entry.js +2 -0
  35. package/dist/elements/p-1e173be8.entry.js.map +1 -0
  36. package/dist/elements/p-4ccc1b59.js +2 -0
  37. package/dist/elements/p-4ccc1b59.js.map +1 -0
  38. package/dist/elements/p-4e2d793c.entry.js +2 -0
  39. package/dist/elements/{p-a23915ba.entry.js.map → p-4e2d793c.entry.js.map} +1 -1
  40. package/dist/esm/{session-a852782a.js → BrokenFile-5180c05c.js} +24 -3
  41. package/dist/esm/BrokenFile-5180c05c.js.map +1 -0
  42. package/dist/esm/elements.js +1 -1
  43. package/dist/esm/{ion-card_30.entry.js → ion-card_31.entry.js} +90 -12
  44. package/dist/{elements/p-ddba19aa.entry.js.map → esm/ion-card_31.entry.js.map} +1 -1
  45. package/dist/esm/loader.js +1 -1
  46. package/dist/esm/pos-document.entry.js +1 -2
  47. package/dist/esm/pos-document.entry.js.map +1 -1
  48. package/dist/types/components/pos-make-findable/pos-make-findable.d.ts +3 -0
  49. package/dist/types/components.d.ts +2 -0
  50. package/package.json +1 -1
  51. package/dist/cjs/BrokenFile-51b1f89b.js +0 -28
  52. package/dist/cjs/BrokenFile-51b1f89b.js.map +0 -1
  53. package/dist/cjs/ion-card_30.cjs.entry.js.map +0 -1
  54. package/dist/cjs/pos-make-findable.cjs.entry.js +0 -79
  55. package/dist/cjs/pos-make-findable.cjs.entry.js.map +0 -1
  56. package/dist/cjs/session-6106c9ff.js.map +0 -1
  57. package/dist/elements/p-49b70074.js +0 -2
  58. package/dist/elements/p-49b70074.js.map +0 -1
  59. package/dist/elements/p-65ea5489.entry.js +0 -2
  60. package/dist/elements/p-65ea5489.entry.js.map +0 -1
  61. package/dist/elements/p-6c7ca160.js +0 -2
  62. package/dist/elements/p-6c7ca160.js.map +0 -1
  63. package/dist/elements/p-a23915ba.entry.js +0 -2
  64. package/dist/elements/p-ddba19aa.entry.js +0 -2
  65. package/dist/esm/BrokenFile-47b11850.js +0 -26
  66. package/dist/esm/BrokenFile-47b11850.js.map +0 -1
  67. package/dist/esm/ion-card_30.entry.js.map +0 -1
  68. package/dist/esm/pos-make-findable.entry.js +0 -75
  69. package/dist/esm/pos-make-findable.entry.js.map +0 -1
  70. package/dist/esm/session-a852782a.js.map +0 -1
@@ -1,79 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-df9f178c.js');
6
- const index$1 = require('./index-821793d2.js');
7
- const PodOsAware = require('./PodOsAware-a16ddb44.js');
8
- const session = require('./session-6106c9ff.js');
9
-
10
- const posMakeFindableCss = "button.main {\n display: flex;\n transition: width 200ms;\n flex-direction: row;\n overflow: hidden;\n height: var(--size-8);\n width: var(--size-8);\n align-items: center;\n justify-content: center;\n border-radius: var(--radius-xs);\n color: var(--color-grey-500);\n border: var(--size-px) dashed var(--color-grey-500);\n background: none;\n\n p {\n padding: 0;\n margin: 0;\n display: none;\n white-space: nowrap;\n }\n}\n\n.options {\n position: absolute;\n animation: fadeIn 300ms;\n padding: 0;\n margin-top: var(--size-1);\n z-index: var(--layer-top);\n\n ol {\n display: flex;\n flex-direction: column;\n box-shadow: var(--shadow-md);\n backdrop-filter: var(--blur-md);\n border-radius: var(--radius-xs);\n overflow: hidden;\n background-color: var(--color-grey-200);\n padding: 0;\n margin: 0;\n list-style: none;\n button {\n transition: all 300ms var(--ease-in-out-sine);\n margin: 0;\n border: none;\n outline: none;\n padding: var(--size-2);\n width: var(--size-full);\n\n &:hover {\n filter: brightness(80%);\n }\n\n &:active {\n filter: brightness(90%);\n }\n }\n }\n}\n\nsvg {\n display: inline-block;\n height: var(--size-6);\n flex-shrink: 0;\n flex-grow: 0;\n width: var(--size-6);\n}\n\nbutton.main:hover,\nbutton.open {\n width: var(--size-full);\n height: var(--size-8);\n background: var(--color-grey-200);\n color: var(--color-grey-700);\n\n p {\n display: inline-block;\n }\n}\n\n@keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n}\n";
11
- const PosMakeFindableStyle0 = posMakeFindableCss;
12
-
13
- const PosMakeFindable = class {
14
- constructor(hostRef) {
15
- index.registerInstance(this, hostRef);
16
- this.subscribePodOs = index.createEvent(this, "pod-os:init", 7);
17
- this.indexes = [];
18
- this.showOptions = false;
19
- this.receivePodOs = async (os) => {
20
- this.os = os;
21
- this.thing = this.os.store.get(this.uri);
22
- this.getLabelIndexes(session.store.state.profile);
23
- this.unsubscribeSessionChange = session.store.onChange('profile', profile => {
24
- this.getLabelIndexes(profile);
25
- });
26
- };
27
- }
28
- componentWillLoad() {
29
- PodOsAware.subscribePodOs(this);
30
- }
31
- disconnectedCallback() {
32
- this.unsubscribeSessionChange && this.unsubscribeSessionChange();
33
- }
34
- hideOptions(event) {
35
- // @ts-ignore
36
- if (event.target.parentNode !== this.el) {
37
- this.showOptions = false;
38
- }
39
- }
40
- updateUri(uri) {
41
- this.thing = this.os.store.get(uri);
42
- }
43
- getLabelIndexes(profile) {
44
- if (profile) {
45
- this.indexes = profile.getPrivateLabelIndexes().map(it => this.os.store.get(it).assume(index$1.LabelIndex));
46
- }
47
- }
48
- async onClick(e) {
49
- e.preventDefault();
50
- if (this.indexes.length === 1) {
51
- await this.addToLabelIndex(this.indexes[0]);
52
- }
53
- else if (this.indexes.length > 1) {
54
- this.showOptions = true;
55
- }
56
- }
57
- async addToLabelIndex(index) {
58
- await this.os.addToLabelIndex(this.thing, index);
59
- }
60
- render() {
61
- if (!session.store.state.isLoggedIn) {
62
- return null;
63
- }
64
- return (index.h(index.Host, null, index.h("button", { class: { main: true, open: this.showOptions }, onClick: e => this.onClick(e), title: "" }, index.h("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor" }, index.h("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m5.231 13.481L15 17.25m-4.5-15H5.625c-.621 0-1.125.504-1.125 1.125v16.5c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Zm3.75 11.625a2.625 2.625 0 1 1-5.25 0 2.625 2.625 0 0 1 5.25 0Z" })), index.h("p", null, "Make this findable")), this.showOptions && (index.h("div", { class: "options" }, index.h("ol", { role: "listbox" }, this.indexes.map((index$1) => (index.h("li", { role: "option" }, index.h("button", { onClick: e => this.chooseOption(e, index$1) }, index.h("pos-resource", { uri: index$1.uri, lazy: true }, index.h("pos-label", null)))))))))));
65
- }
66
- async chooseOption(e, index) {
67
- e.preventDefault();
68
- await this.addToLabelIndex(index);
69
- }
70
- get el() { return index.getElement(this); }
71
- static get watchers() { return {
72
- "uri": ["updateUri"]
73
- }; }
74
- };
75
- PosMakeFindable.style = PosMakeFindableStyle0;
76
-
77
- exports.pos_make_findable = PosMakeFindable;
78
-
79
- //# sourceMappingURL=pos-make-findable.cjs.entry.js.map
@@ -1 +0,0 @@
1
- {"file":"pos-make-findable.entry.cjs.js","mappings":";;;;;;;;;AAAA,MAAM,kBAAkB,GAAG,wmDAAwmD,CAAC;AACpoD,8BAAe,kBAAkB;;MCQpB,eAAe;IAJ5B;;;QASW,YAAO,GAAiB,EAAE,CAAC;QAM3B,gBAAW,GAAG,KAAK,CAAC;QAyB7B,iBAAY,GAAG,OAAO,EAAS;YAC7B,IAAI,CAAC,EAAE,GAAG,EAAE,CAAC;YACb,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YACzC,IAAI,CAAC,eAAe,CAACA,aAAO,CAAC,KA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AC7C,MAAM,IAAI,CAAC,EAAE,CAAC,eAAe,CAAC,IAAI,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;KAClD;IAED,MAAM;QACJ,IAAI,CAACF,aAAO,CAAC,KAAK,CAAC,UAAU,EAAE;YAC7B,OAAO,IAAI,CAAC;SACb;QAED,QACEG,QAACC,UAAI,QACHD,oBAAQ,KAAK,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,WAAW,EAAE,EAAE,OAAO,EAAE,CAAC,IAAI,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,KAAK,EAAC,EAAE,IAC5FA,iBACE,KAAK,EAAC,4BAA4B,EAClC,IAAI,EAAC,MAAM,EACX,OAAO,EAAC,WAAW,kBACN,KAAK,EAClB,MAAM,EAAC,cAAc,IAErBA,oCACiB,OAAO,qBACN,OAAO,EACvB,CAAC,EAAC,wVAAwV,GAC1V,CACE,EACNA,wCAAyB,CAClB,EACR,IAAI,CAAC,WAAW,KACfA,iBAAK,KAAK,EAAC,SAAS,IAClBA,gBAAI,IAAI,EAAC,SAAS,IACf,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAACE,OAAiB,MAClCF,gBAAI,IAAI,EAAC,QAAQ,IACfA,oBAAQ,OAAO,EAAE,CAAC,IAAI,IAAI,CAAC,YAAY,CAAC,CAAC,EAAEE,OAAK,CAAC,IAC/CF,0BAAc,GAAG,EAAEE,OAAK,CAAC,GAAG,EAAE,IAAI,EAAE,IAAI,IACtCF,0BAAuB,CACV,CACR,CACN,CACN,CAAC,CACC,CACD,CACP,CACI,EACP;KACH;IAEO,MAAM,YAAY,CAAC,CAAa,EAAE,KAAiB;QACzD,CAAC,CAAC,cAAc,EAAE,CAAC;QACnB,MAAM,IAAI,CAAC,eAAe,CAAC,KAAK,CAAC,CAAC;KACnC;;;;;;;;;;","names":["session","subscribePodOs","LabelIndex","h","Host","index"],"sources":["src/components/pos-make-findable/pos-make-findable.css?tag=pos-make-findable","src/components/pos-make-findable/pos-make-findable.tsx"],"sourcesContent":["button.main {\n display: flex;\n transition: width 200ms;\n flex-direction: row;\n overflow: hidden;\n height: var(--size-8);\n width: var(--size-8);\n align-items: center;\n justify-content: center;\n border-radius: var(--radius-xs);\n color: var(--color-grey-500);\n border: var(--size-px) dashed var(--color-grey-500);\n background: none;\n\n p {\n padding: 0;\n margin: 0;\n display: none;\n white-space: nowrap;\n }\n}\n\n.options {\n position: absolute;\n animation: fadeIn 300ms;\n padding: 0;\n margin-top: var(--size-1);\n z-index: var(--layer-top);\n\n ol {\n display: flex;\n flex-direction: column;\n box-shadow: var(--shadow-md);\n backdrop-filter: var(--blur-md);\n border-radius: var(--radius-xs);\n overflow: hidden;\n background-color: var(--color-grey-200);\n padding: 0;\n margin: 0;\n list-style: none;\n button {\n transition: all 300ms var(--ease-in-out-sine);\n margin: 0;\n border: none;\n outline: none;\n padding: var(--size-2);\n width: var(--size-full);\n\n &:hover {\n filter: brightness(80%);\n }\n\n &:active {\n filter: brightness(90%);\n }\n }\n }\n}\n\nsvg {\n display: inline-block;\n height: var(--size-6);\n flex-shrink: 0;\n flex-grow: 0;\n width: var(--size-6);\n}\n\nbutton.main:hover,\nbutton.open {\n width: var(--size-full);\n height: var(--size-8);\n background: var(--color-grey-200);\n color: var(--color-grey-700);\n\n p {\n display: inline-block;\n }\n}\n\n@keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n}\n","import { Component, Element, Event, h, Host, Listen, Prop, State, Watch } from '@stencil/core';\nimport { LabelIndex, PodOS, Thing, WebIdProfile } from '@pod-os/core';\nimport { PodOsAware, PodOsEventEmitter, subscribePodOs } from '../events/PodOsAware';\nimport session from '../../store/session';\n\n@Component({\n tag: 'pos-make-findable',\n styleUrl: 'pos-make-findable.css',\n})\nexport class PosMakeFindable implements PodOsAware {\n @Prop() uri!: string;\n\n @State() os: PodOS;\n @State() thing: Thing;\n @State() indexes: LabelIndex[] = [];\n\n @Event({ eventName: 'pod-os:init' }) subscribePodOs: PodOsEventEmitter;\n\n @State() unsubscribeSessionChange: undefined | (() => void);\n\n @State() showOptions = false;\n\n @Element() el: HTMLElement;\n\n componentWillLoad() {\n subscribePodOs(this);\n }\n\n disconnectedCallback() {\n this.unsubscribeSessionChange && this.unsubscribeSessionChange();\n }\n\n @Listen('click', { target: 'window' })\n hideOptions(event: MouseEvent) {\n // @ts-ignore\n if (event.target.parentNode !== this.el) {\n this.showOptions = false;\n }\n }\n\n @Watch('uri')\n updateUri(uri: string) {\n this.thing = this.os.store.get(uri);\n }\n\n receivePodOs = async (os: PodOS) => {\n this.os = os;\n this.thing = this.os.store.get(this.uri);\n this.getLabelIndexes(session.state.profile);\n this.unsubscribeSessionChange = session.onChange('profile', profile => {\n this.getLabelIndexes(profile);\n });\n };\n\n private getLabelIndexes(profile: WebIdProfile) {\n if (profile) {\n this.indexes = profile.getPrivateLabelIndexes().map(it => this.os.store.get(it).assume(LabelIndex));\n }\n }\n\n private async onClick(e: MouseEvent) {\n e.preventDefault();\n if (this.indexes.length === 1) {\n await this.addToLabelIndex(this.indexes[0]);\n } else if (this.indexes.length > 1) {\n this.showOptions = true;\n }\n }\n\n private async addToLabelIndex(index: LabelIndex) {\n await this.os.addToLabelIndex(this.thing, index);\n }\n\n render() {\n if (!session.state.isLoggedIn) {\n return null;\n }\n\n return (\n <Host>\n <button class={{ main: true, open: this.showOptions }} onClick={e => this.onClick(e)} title=\"\">\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n stroke-width=\"1.5\"\n stroke=\"currentColor\"\n >\n <path\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n d=\"M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m5.231 13.481L15 17.25m-4.5-15H5.625c-.621 0-1.125.504-1.125 1.125v16.5c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Zm3.75 11.625a2.625 2.625 0 1 1-5.25 0 2.625 2.625 0 0 1 5.25 0Z\"\n />\n </svg>\n <p>Make this findable</p>\n </button>\n {this.showOptions && (\n <div class=\"options\">\n <ol role=\"listbox\">\n {this.indexes.map((index: LabelIndex) => (\n <li role=\"option\">\n <button onClick={e => this.chooseOption(e, index)}>\n <pos-resource uri={index.uri} lazy={true}>\n <pos-label></pos-label>\n </pos-resource>\n </button>\n </li>\n ))}\n </ol>\n </div>\n )}\n </Host>\n );\n }\n\n private async chooseOption(e: MouseEvent, index: LabelIndex) {\n e.preventDefault();\n await this.addToLabelIndex(index);\n }\n}\n"],"version":3}
@@ -1 +0,0 @@
1
- {"file":"session-6106c9ff.js","mappings":";;;;AAEA,MAAM,WAAW,GAAG,CAAC,GAAG,EAAE,QAAQ,EAAE,KAAK,KAAK;AAC9C,IAAI,MAAM,KAAK,GAAG,GAAG,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;AACpC,IAAI,IAAI,CAAC,KAAK,EAAE;AAChB,QAAQ,GAAG,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC;AACnC,KAAK;AACL,SAAS,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE;AACrC,QAAQ,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;AAC1B,KAAK;AACL,CAAC,CAAC;AACF,MAAM,QAAQ,GAAG,CAAC,EAAE,EAAE,EAAE,KAAK;AAC7B,IAAI,IAAI,SAAS,CAAC;AAClB,IAAI,OAAO,CAAC,GAAG,IAAI,KAAK;AACxB,QAAQ,IAAI,SAAS,EAAE;AACvB,YAAY,YAAY,CAAC,SAAS,CAAC,CAAC;AACpC,SAAS;AACT,QAAQ,SAAS,GAAG,UAAU,CAAC,MAAM;AACrC,YAAY,SAAS,GAAG,CA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C,GAAG,CAAC,OAAO,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,CAAC;AAClE,KAAK,CAAC;AACN,IAAI,OAAO;AACX,QAAQ,KAAK;AACb,QAAQ,GAAG;AACX,QAAQ,GAAG;AACX,QAAQ,EAAE;AACV,QAAQ,QAAQ;AAChB,QAAQ,GAAG;AACX,QAAQ,OAAO;AACf,QAAQ,KAAK;AACb,QAAQ,WAAW;AACnB,KAAK,CAAC;AACN,CAAC,CAAC;AACF,MAAM,eAAe,GAAG,CAAC,KAAK,EAAE,IAAI,KAAK;AACzC,IAAI,MAAM,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;AACtC,IAAI,IAAI,KAAK,IAAI,CAAC,EAAE;AACpB,QAAQ,KAAK,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;AAC/C,QAAQ,KAAK,CAAC,MAAM,EAAE,CAAC;AACvB,KAAK;AACL,CAAC,CAAC;AACF;AACA,MAAM,WAAW,GAAG,CAAC,YAAY,EAAE,YAAY,KAAK;AACpD,IAAI,MAAM,GAAG,GAAG,mBAAmB,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;AAChE,IAAI,GAAG,CAAC,GAAG,CAAC,mBAAmB,EAAE,CAAC,CAAC;AACnC,IAAI,OAAO,GAAG,CAAC;AACf,CAAC;;MC5LK,KAAK,GAAG,WAAW,CAAC;IACxB,UAAU,EAAE,KAAK;IACjB,KAAK,EAAE,EAAE;IACT,OAAO,EAAE,IAAoB;CAC9B;;;;","names":["getRenderingRef","forceUpdate"],"sources":["../node_modules/@stencil/store/dist/index.mjs","src/store/session.ts"],"sourcesContent":["import { getRenderingRef, forceUpdate } from '@stencil/core';\n\nconst appendToMap = (map, propName, value) => {\n const items = map.get(propName);\n if (!items) {\n map.set(propName, [value]);\n }\n else if (!items.includes(value)) {\n items.push(value);\n }\n};\nconst debounce = (fn, ms) => {\n let timeoutId;\n return (...args) => {\n if (timeoutId) {\n clearTimeout(timeoutId);\n }\n timeoutId = setTimeout(() => {\n timeoutId = 0;\n fn(...args);\n }, ms);\n };\n};\n\n/**\n * Check if a possible element isConnected.\n * The property might not be there, so we check for it.\n *\n * We want it to return true if isConnected is not a property,\n * otherwise we would remove these elements and would not update.\n *\n * Better leak in Edge than to be useless.\n */\nconst isConnected = (maybeElement) => !('isConnected' in maybeElement) || maybeElement.isConnected;\nconst cleanupElements = debounce((map) => {\n for (let key of map.keys()) {\n map.set(key, map.get(key).filter(isConnected));\n }\n}, 2000);\nconst stencilSubscription = () => {\n if (typeof getRenderingRef !== 'function') {\n // If we are not in a stencil project, we do nothing.\n // This function is not really exported by @stencil/core.\n return {};\n }\n const elmsToUpdate = new Map();\n return {\n dispose: () => elmsToUpdate.clear(),\n get: (propName) => {\n const elm = getRenderingRef();\n if (elm) {\n appendToMap(elmsToUpdate, propName, elm);\n }\n },\n set: (propName) => {\n const elements = elmsToUpdate.get(propName);\n if (elements) {\n elmsToUpdate.set(propName, elements.filter(forceUpdate));\n }\n cleanupElements(elmsToUpdate);\n },\n reset: () => {\n elmsToUpdate.forEach((elms) => elms.forEach(forceUpdate));\n cleanupElements(elmsToUpdate);\n },\n };\n};\n\nconst unwrap = (val) => (typeof val === 'function' ? val() : val);\nconst createObservableMap = (defaultState, shouldUpdate = (a, b) => a !== b) => {\n const unwrappedState = unwrap(defaultState);\n let states = new Map(Object.entries(unwrappedState !== null && unwrappedState !== void 0 ? unwrappedState : {}));\n const handlers = {\n dispose: [],\n get: [],\n set: [],\n reset: [],\n };\n const reset = () => {\n var _a;\n // When resetting the state, the default state may be a function - unwrap it to invoke it.\n // otherwise, the state won't be properly reset\n states = new Map(Object.entries((_a = unwrap(defaultState)) !== null && _a !== void 0 ? _a : {}));\n handlers.reset.forEach((cb) => cb());\n };\n const dispose = () => {\n // Call first dispose as resetting the state would\n // cause less updates ;)\n handlers.dispose.forEach((cb) => cb());\n reset();\n };\n const get = (propName) => {\n handlers.get.forEach((cb) => cb(propName));\n return states.get(propName);\n };\n const set = (propName, value) => {\n const oldValue = states.get(propName);\n if (shouldUpdate(value, oldValue, propName)) {\n states.set(propName, value);\n handlers.set.forEach((cb) => cb(propName, value, oldValue));\n }\n };\n const state = (typeof Proxy === 'undefined'\n ? {}\n : new Proxy(unwrappedState, {\n get(_, propName) {\n return get(propName);\n },\n ownKeys(_) {\n return Array.from(states.keys());\n },\n getOwnPropertyDescriptor() {\n return {\n enumerable: true,\n configurable: true,\n };\n },\n has(_, propName) {\n return states.has(propName);\n },\n set(_, propName, value) {\n set(propName, value);\n return true;\n },\n }));\n const on = (eventName, callback) => {\n handlers[eventName].push(callback);\n return () => {\n removeFromArray(handlers[eventName], callback);\n };\n };\n const onChange = (propName, cb) => {\n const unSet = on('set', (key, newValue) => {\n if (key === propName) {\n cb(newValue);\n }\n });\n // We need to unwrap the defaultState because it might be a function.\n // Otherwise we might not be sending the right reset value.\n const unReset = on('reset', () => cb(unwrap(defaultState)[propName]));\n return () => {\n unSet();\n unReset();\n };\n };\n const use = (...subscriptions) => {\n const unsubs = subscriptions.reduce((unsubs, subscription) => {\n if (subscription.set) {\n unsubs.push(on('set', subscription.set));\n }\n if (subscription.get) {\n unsubs.push(on('get', subscription.get));\n }\n if (subscription.reset) {\n unsubs.push(on('reset', subscription.reset));\n }\n if (subscription.dispose) {\n unsubs.push(on('dispose', subscription.dispose));\n }\n return unsubs;\n }, []);\n return () => unsubs.forEach((unsub) => unsub());\n };\n const forceUpdate = (key) => {\n const oldValue = states.get(key);\n handlers.set.forEach((cb) => cb(key, oldValue, oldValue));\n };\n return {\n state,\n get,\n set,\n on,\n onChange,\n use,\n dispose,\n reset,\n forceUpdate,\n };\n};\nconst removeFromArray = (array, item) => {\n const index = array.indexOf(item);\n if (index >= 0) {\n array[index] = array[array.length - 1];\n array.length--;\n }\n};\n\nconst createStore = (defaultState, shouldUpdate) => {\n const map = createObservableMap(defaultState, shouldUpdate);\n map.use(stencilSubscription());\n return map;\n};\n\nexport { createObservableMap, createStore };\n","import { WebIdProfile } from '@pod-os/core';\nimport { createStore } from '@stencil/store';\n\nconst store = createStore({\n isLoggedIn: false,\n webId: '',\n profile: null as WebIdProfile\n});\n\nexport default store;\n"],"version":3}
@@ -1,2 +0,0 @@
1
- import{h as e}from"./p-7a6a7690.js";const c=({file:c})=>{const r=l(c.status);return e("div",null,e("a",{class:"error",href:c.url},e("div",null,e("ion-icon",{name:r})),e("div",{class:"code"},c.status.code),e("div",{class:"text"},c.status.text)))};function l(e){switch(e.code){case 401:case 403:return"lock-closed-outline";case 404:return"help-circle-outline";default:return"alert-circle-outline"}}export{c as B};
2
- //# sourceMappingURL=p-49b70074.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["BrokenFile","file","iconName","iconForStatus","status","h","class","href","url","name","code","text"],"sources":["src/components/broken-file/BrokenFile.tsx"],"sourcesContent":["import { BrokenFile as BrokenFileData, HttpStatus } from '@pod-os/core';\nimport { h } from '@stencil/core';\n\ninterface Props {\n file: BrokenFileData;\n}\n\nexport const BrokenFile = ({ file }: Props) => {\n const iconName = iconForStatus(file.status);\n return (\n <div>\n <a class=\"error\" href={file.url}>\n <div>\n <ion-icon name={iconName}></ion-icon>\n </div>\n <div class=\"code\">{file.status.code}</div>\n <div class=\"text\">{file.status.text}</div>\n </a>\n </div>\n );\n};\n\nfunction iconForStatus(status: HttpStatus): string {\n switch (status.code) {\n case 401:\n case 403:\n return 'lock-closed-outline';\n case 404:\n return 'help-circle-outline';\n default:\n return 'alert-circle-outline';\n }\n}\n"],"mappings":"0CAOaA,EAAa,EAAGC,WAC3B,MAAMC,EAAWC,EAAcF,EAAKG,QACpC,OACEC,EAAA,WACEA,EAAA,KAAGC,MAAM,QAAQC,KAAMN,EAAKO,KAC1BH,EAAA,WACEA,EAAA,YAAUI,KAAMP,KAElBG,EAAA,OAAKC,MAAM,QAAQL,EAAKG,OAAOM,MAC/BL,EAAA,OAAKC,MAAM,QAAQL,EAAKG,OAAOO,OAE7B,EAIV,SAASR,EAAcC,GACrB,OAAQA,EAAOM,MACb,KAAK,IACL,KAAK,IACH,MAAO,sBACT,KAAK,IACH,MAAO,sBACT,QACE,MAAO,uBAEb,Q","ignoreList":[]}
@@ -1,2 +0,0 @@
1
- import{r as n,i,h as t,H as s,d as e}from"./p-7a6a7690.js";import{L as o}from"./p-c984fc73.js";import{s as r}from"./p-182f722d.js";import{s as a}from"./p-6c7ca160.js";const l="button.main {\n display: flex;\n transition: width 200ms;\n flex-direction: row;\n overflow: hidden;\n height: var(--size-8);\n width: var(--size-8);\n align-items: center;\n justify-content: center;\n border-radius: var(--radius-xs);\n color: var(--color-grey-500);\n border: var(--size-px) dashed var(--color-grey-500);\n background: none;\n\n p {\n padding: 0;\n margin: 0;\n display: none;\n white-space: nowrap;\n }\n}\n\n.options {\n position: absolute;\n animation: fadeIn 300ms;\n padding: 0;\n margin-top: var(--size-1);\n z-index: var(--layer-top);\n\n ol {\n display: flex;\n flex-direction: column;\n box-shadow: var(--shadow-md);\n backdrop-filter: var(--blur-md);\n border-radius: var(--radius-xs);\n overflow: hidden;\n background-color: var(--color-grey-200);\n padding: 0;\n margin: 0;\n list-style: none;\n button {\n transition: all 300ms var(--ease-in-out-sine);\n margin: 0;\n border: none;\n outline: none;\n padding: var(--size-2);\n width: var(--size-full);\n\n &:hover {\n filter: brightness(80%);\n }\n\n &:active {\n filter: brightness(90%);\n }\n }\n }\n}\n\nsvg {\n display: inline-block;\n height: var(--size-6);\n flex-shrink: 0;\n flex-grow: 0;\n width: var(--size-6);\n}\n\nbutton.main:hover,\nbutton.open {\n width: var(--size-full);\n height: var(--size-8);\n background: var(--color-grey-200);\n color: var(--color-grey-700);\n\n p {\n display: inline-block;\n }\n}\n\n@keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n}\n";const h=l;const d=class{constructor(t){n(this,t);this.subscribePodOs=i(this,"pod-os:init",7);this.indexes=[];this.showOptions=false;this.receivePodOs=async n=>{this.os=n;this.thing=this.os.store.get(this.uri);this.getLabelIndexes(a.state.profile);this.unsubscribeSessionChange=a.onChange("profile",(n=>{this.getLabelIndexes(n)}))}}componentWillLoad(){r(this)}disconnectedCallback(){this.unsubscribeSessionChange&&this.unsubscribeSessionChange()}hideOptions(n){if(n.target.parentNode!==this.el){this.showOptions=false}}updateUri(n){this.thing=this.os.store.get(n)}getLabelIndexes(n){if(n){this.indexes=n.getPrivateLabelIndexes().map((n=>this.os.store.get(n).assume(o)))}}async onClick(n){n.preventDefault();if(this.indexes.length===1){await this.addToLabelIndex(this.indexes[0])}else if(this.indexes.length>1){this.showOptions=true}}async addToLabelIndex(n){await this.os.addToLabelIndex(this.thing,n)}render(){if(!a.state.isLoggedIn){return null}return t(s,null,t("button",{class:{main:true,open:this.showOptions},onClick:n=>this.onClick(n),title:""},t("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},t("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m5.231 13.481L15 17.25m-4.5-15H5.625c-.621 0-1.125.504-1.125 1.125v16.5c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Zm3.75 11.625a2.625 2.625 0 1 1-5.25 0 2.625 2.625 0 0 1 5.25 0Z"})),t("p",null,"Make this findable")),this.showOptions&&t("div",{class:"options"},t("ol",{role:"listbox"},this.indexes.map((n=>t("li",{role:"option"},t("button",{onClick:i=>this.chooseOption(i,n)},t("pos-resource",{uri:n.uri,lazy:true},t("pos-label",null)))))))))}async chooseOption(n,i){n.preventDefault();await this.addToLabelIndex(i)}get el(){return e(this)}static get watchers(){return{uri:["updateUri"]}}};d.style=h;export{d as pos_make_findable};
2
- //# sourceMappingURL=p-65ea5489.entry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["posMakeFindableCss","PosMakeFindableStyle0","PosMakeFindable","constructor","hostRef","this","indexes","showOptions","receivePodOs","async","os","thing","store","get","uri","getLabelIndexes","session","state","profile","unsubscribeSessionChange","onChange","componentWillLoad","subscribePodOs","disconnectedCallback","hideOptions","event","target","parentNode","el","updateUri","getPrivateLabelIndexes","map","it","assume","LabelIndex","onClick","e","preventDefault","length","addToLabelIndex","index","render","isLoggedIn","h","Host","class","main","open","title","xmlns","fill","viewBox","stroke","d","role","chooseOption","lazy"],"sources":["src/components/pos-make-findable/pos-make-findable.css?tag=pos-make-findable","src/components/pos-make-findable/pos-make-findable.tsx"],"sourcesContent":["button.main {\n display: flex;\n transition: width 200ms;\n flex-direction: row;\n overflow: hidden;\n height: var(--size-8);\n width: var(--size-8);\n align-items: center;\n justify-content: center;\n border-radius: var(--radius-xs);\n color: var(--color-grey-500);\n border: var(--size-px) dashed var(--color-grey-500);\n background: none;\n\n p {\n padding: 0;\n margin: 0;\n display: none;\n white-space: nowrap;\n }\n}\n\n.options {\n position: absolute;\n animation: fadeIn 300ms;\n padding: 0;\n margin-top: var(--size-1);\n z-index: var(--layer-top);\n\n ol {\n display: flex;\n flex-direction: column;\n box-shadow: var(--shadow-md);\n backdrop-filter: var(--blur-md);\n border-radius: var(--radius-xs);\n overflow: hidden;\n background-color: var(--color-grey-200);\n padding: 0;\n margin: 0;\n list-style: none;\n button {\n transition: all 300ms var(--ease-in-out-sine);\n margin: 0;\n border: none;\n outline: none;\n padding: var(--size-2);\n width: var(--size-full);\n\n &:hover {\n filter: brightness(80%);\n }\n\n &:active {\n filter: brightness(90%);\n }\n }\n }\n}\n\nsvg {\n display: inline-block;\n height: var(--size-6);\n flex-shrink: 0;\n flex-grow: 0;\n width: var(--size-6);\n}\n\nbutton.main:hover,\nbutton.open {\n width: var(--size-full);\n height: var(--size-8);\n background: var(--color-grey-200);\n color: var(--color-grey-700);\n\n p {\n display: inline-block;\n }\n}\n\n@keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n}\n","import { Component, Element, Event, h, Host, Listen, Prop, State, Watch } from '@stencil/core';\nimport { LabelIndex, PodOS, Thing, WebIdProfile } from '@pod-os/core';\nimport { PodOsAware, PodOsEventEmitter, subscribePodOs } from '../events/PodOsAware';\nimport session from '../../store/session';\n\n@Component({\n tag: 'pos-make-findable',\n styleUrl: 'pos-make-findable.css',\n})\nexport class PosMakeFindable implements PodOsAware {\n @Prop() uri!: string;\n\n @State() os: PodOS;\n @State() thing: Thing;\n @State() indexes: LabelIndex[] = [];\n\n @Event({ eventName: 'pod-os:init' }) subscribePodOs: PodOsEventEmitter;\n\n @State() unsubscribeSessionChange: undefined | (() => void);\n\n @State() showOptions = false;\n\n @Element() el: HTMLElement;\n\n componentWillLoad() {\n subscribePodOs(this);\n }\n\n disconnectedCallback() {\n this.unsubscribeSessionChange && this.unsubscribeSessionChange();\n }\n\n @Listen('click', { target: 'window' })\n hideOptions(event: MouseEvent) {\n // @ts-ignore\n if (event.target.parentNode !== this.el) {\n this.showOptions = false;\n }\n }\n\n @Watch('uri')\n updateUri(uri: string) {\n this.thing = this.os.store.get(uri);\n }\n\n receivePodOs = async (os: PodOS) => {\n this.os = os;\n this.thing = this.os.store.get(this.uri);\n this.getLabelIndexes(session.state.profile);\n this.unsubscribeSessionChange = session.onChange('profile', profile => {\n this.getLabelIndexes(profile);\n });\n };\n\n private getLabelIndexes(profile: WebIdProfile) {\n if (profile) {\n this.indexes = profile.getPrivateLabelIndexes().map(it => this.os.store.get(it).assume(LabelIndex));\n }\n }\n\n private async onClick(e: MouseEvent) {\n e.preventDefault();\n if (this.indexes.length === 1) {\n await this.addToLabelIndex(this.indexes[0]);\n } else if (this.indexes.length > 1) {\n this.showOptions = true;\n }\n }\n\n private async addToLabelIndex(index: LabelIndex) {\n await this.os.addToLabelIndex(this.thing, index);\n }\n\n render() {\n if (!session.state.isLoggedIn) {\n return null;\n }\n\n return (\n <Host>\n <button class={{ main: true, open: this.showOptions }} onClick={e => this.onClick(e)} title=\"\">\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n stroke-width=\"1.5\"\n stroke=\"currentColor\"\n >\n <path\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n d=\"M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m5.231 13.481L15 17.25m-4.5-15H5.625c-.621 0-1.125.504-1.125 1.125v16.5c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Zm3.75 11.625a2.625 2.625 0 1 1-5.25 0 2.625 2.625 0 0 1 5.25 0Z\"\n />\n </svg>\n <p>Make this findable</p>\n </button>\n {this.showOptions && (\n <div class=\"options\">\n <ol role=\"listbox\">\n {this.indexes.map((index: LabelIndex) => (\n <li role=\"option\">\n <button onClick={e => this.chooseOption(e, index)}>\n <pos-resource uri={index.uri} lazy={true}>\n <pos-label></pos-label>\n </pos-resource>\n </button>\n </li>\n ))}\n </ol>\n </div>\n )}\n </Host>\n );\n }\n\n private async chooseOption(e: MouseEvent, index: LabelIndex) {\n e.preventDefault();\n await this.addToLabelIndex(index);\n }\n}\n"],"mappings":"uKAAA,MAAMA,EAAqB,ymDAC3B,MAAAC,EAAeD,E,MCQFE,EAAe,MAJ5B,WAAAC,CAAAC,G,sDASWC,KAAAC,QAAwB,GAMxBD,KAAAE,YAAc,MAyBvBF,KAAAG,aAAeC,MAAOC,IACpBL,KAAKK,GAAKA,EACVL,KAAKM,MAAQN,KAAKK,GAAGE,MAAMC,IAAIR,KAAKS,KACpCT,KAAKU,gBAAgBC,EAAQC,MAAMC,SACnCb,KAAKc,yBAA2BH,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,EAAGI,IACzCG,EAAA,gBAAc7B,IAAK0B,EAAM1B,IAAK0C,KAAM,MAClCb,EAAA,yB,CAYZ,kBAAMY,CAAanB,EAAeI,GACxCJ,EAAEC,uBACIhC,KAAKkC,gBAAgBC,E","ignoreList":[]}
@@ -1,2 +0,0 @@
1
- import{k as t,j as e}from"./p-7a6a7690.js";const n=(t,e,n)=>{const s=t.get(e);if(!s){t.set(e,[n])}else if(!s.includes(n)){s.push(n)}};const s=(t,e)=>{let n;return(...s)=>{if(n){clearTimeout(n)}n=setTimeout((()=>{n=0;t(...s)}),e)}};const o=t=>!("isConnected"in t)||t.isConnected;const r=s((t=>{for(let e of t.keys()){t.set(e,t.get(e).filter(o))}}),2e3);const c=()=>{if(typeof t!=="function"){return{}}const s=new Map;return{dispose:()=>s.clear(),get:e=>{const o=t();if(o){n(s,e,o)}},set:t=>{const n=s.get(t);if(n){s.set(t,n.filter(e))}r(s)},reset:()=>{s.forEach((t=>t.forEach(e)));r(s)}}};const i=t=>typeof t==="function"?t():t;const u=(t,e=((t,e)=>t!==e))=>{const n=i(t);let s=new Map(Object.entries(n!==null&&n!==void 0?n:{}));const o={dispose:[],get:[],set:[],reset:[]};const r=()=>{var e;s=new Map(Object.entries((e=i(t))!==null&&e!==void 0?e:{}));o.reset.forEach((t=>t()))};const c=()=>{o.dispose.forEach((t=>t()));r()};const u=t=>{o.get.forEach((e=>e(t)));return s.get(t)};const a=(t,n)=>{const r=s.get(t);if(e(n,r,t)){s.set(t,n);o.set.forEach((e=>e(t,n,r)))}};const p=typeof Proxy==="undefined"?{}:new Proxy(n,{get(t,e){return u(e)},ownKeys(t){return Array.from(s.keys())},getOwnPropertyDescriptor(){return{enumerable:true,configurable:true}},has(t,e){return s.has(e)},set(t,e,n){a(e,n);return true}});const l=(t,e)=>{o[t].push(e);return()=>{f(o[t],e)}};const d=(e,n)=>{const s=l("set",((t,s)=>{if(t===e){n(s)}}));const o=l("reset",(()=>n(i(t)[e])));return()=>{s();o()}};const g=(...t)=>{const e=t.reduce(((t,e)=>{if(e.set){t.push(l("set",e.set))}if(e.get){t.push(l("get",e.get))}if(e.reset){t.push(l("reset",e.reset))}if(e.dispose){t.push(l("dispose",e.dispose))}return t}),[]);return()=>e.forEach((t=>t()))};const y=t=>{const e=s.get(t);o.set.forEach((n=>n(t,e,e)))};return{state:p,get:u,set:a,on:l,onChange:d,use:g,dispose:c,reset:r,forceUpdate:y}};const f=(t,e)=>{const n=t.indexOf(e);if(n>=0){t[n]=t[t.length-1];t.length--}};const a=(t,e)=>{const n=u(t,e);n.use(c());return n};const p=a({isLoggedIn:false,webId:"",profile:null});export{p as s};
2
- //# sourceMappingURL=p-6c7ca160.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["appendToMap","map","propName","value","items","get","set","includes","push","debounce","fn","ms","timeoutId","args","clearTimeout","setTimeout","isConnected","maybeElement","cleanupElements","key","keys","filter","stencilSubscription","getRenderingRef","elmsToUpdate","Map","dispose","clear","elm","elements","forceUpdate","reset","forEach","elms","unwrap","val","createObservableMap","defaultState","shouldUpdate","a","b","unwrappedState","states","Object","entries","handlers","_a","cb","oldValue","state","Proxy","_","ownKeys","Array","from","getOwnPropertyDescriptor","enumerable","configurable","has","on","eventName","callback","removeFromArray","onChange","unSet","newValue","unReset","use","subscriptions","unsubs","reduce","subscription","unsub","array","item","index","indexOf","length","createStore","store","isLoggedIn","webId","profile"],"sources":["../node_modules/@stencil/store/dist/index.mjs","src/store/session.ts"],"sourcesContent":["import { getRenderingRef, forceUpdate } from '@stencil/core';\n\nconst appendToMap = (map, propName, value) => {\n const items = map.get(propName);\n if (!items) {\n map.set(propName, [value]);\n }\n else if (!items.includes(value)) {\n items.push(value);\n }\n};\nconst debounce = (fn, ms) => {\n let timeoutId;\n return (...args) => {\n if (timeoutId) {\n clearTimeout(timeoutId);\n }\n timeoutId = setTimeout(() => {\n timeoutId = 0;\n fn(...args);\n }, ms);\n };\n};\n\n/**\n * Check if a possible element isConnected.\n * The property might not be there, so we check for it.\n *\n * We want it to return true if isConnected is not a property,\n * otherwise we would remove these elements and would not update.\n *\n * Better leak in Edge than to be useless.\n */\nconst isConnected = (maybeElement) => !('isConnected' in maybeElement) || maybeElement.isConnected;\nconst cleanupElements = debounce((map) => {\n for (let key of map.keys()) {\n map.set(key, map.get(key).filter(isConnected));\n }\n}, 2000);\nconst stencilSubscription = () => {\n if (typeof getRenderingRef !== 'function') {\n // If we are not in a stencil project, we do nothing.\n // This function is not really exported by @stencil/core.\n return {};\n }\n const elmsToUpdate = new Map();\n return {\n dispose: () => elmsToUpdate.clear(),\n get: (propName) => {\n const elm = getRenderingRef();\n if (elm) {\n appendToMap(elmsToUpdate, propName, elm);\n }\n },\n set: (propName) => {\n const elements = elmsToUpdate.get(propName);\n if (elements) {\n elmsToUpdate.set(propName, elements.filter(forceUpdate));\n }\n cleanupElements(elmsToUpdate);\n },\n reset: () => {\n elmsToUpdate.forEach((elms) => elms.forEach(forceUpdate));\n cleanupElements(elmsToUpdate);\n },\n };\n};\n\nconst unwrap = (val) => (typeof val === 'function' ? val() : val);\nconst createObservableMap = (defaultState, shouldUpdate = (a, b) => a !== b) => {\n const unwrappedState = unwrap(defaultState);\n let states = new Map(Object.entries(unwrappedState !== null && unwrappedState !== void 0 ? unwrappedState : {}));\n const handlers = {\n dispose: [],\n get: [],\n set: [],\n reset: [],\n };\n const reset = () => {\n var _a;\n // When resetting the state, the default state may be a function - unwrap it to invoke it.\n // otherwise, the state won't be properly reset\n states = new Map(Object.entries((_a = unwrap(defaultState)) !== null && _a !== void 0 ? _a : {}));\n handlers.reset.forEach((cb) => cb());\n };\n const dispose = () => {\n // Call first dispose as resetting the state would\n // cause less updates ;)\n handlers.dispose.forEach((cb) => cb());\n reset();\n };\n const get = (propName) => {\n handlers.get.forEach((cb) => cb(propName));\n return states.get(propName);\n };\n const set = (propName, value) => {\n const oldValue = states.get(propName);\n if (shouldUpdate(value, oldValue, propName)) {\n states.set(propName, value);\n handlers.set.forEach((cb) => cb(propName, value, oldValue));\n }\n };\n const state = (typeof Proxy === 'undefined'\n ? {}\n : new Proxy(unwrappedState, {\n get(_, propName) {\n return get(propName);\n },\n ownKeys(_) {\n return Array.from(states.keys());\n },\n getOwnPropertyDescriptor() {\n return {\n enumerable: true,\n configurable: true,\n };\n },\n has(_, propName) {\n return states.has(propName);\n },\n set(_, propName, value) {\n set(propName, value);\n return true;\n },\n }));\n const on = (eventName, callback) => {\n handlers[eventName].push(callback);\n return () => {\n removeFromArray(handlers[eventName], callback);\n };\n };\n const onChange = (propName, cb) => {\n const unSet = on('set', (key, newValue) => {\n if (key === propName) {\n cb(newValue);\n }\n });\n // We need to unwrap the defaultState because it might be a function.\n // Otherwise we might not be sending the right reset value.\n const unReset = on('reset', () => cb(unwrap(defaultState)[propName]));\n return () => {\n unSet();\n unReset();\n };\n };\n const use = (...subscriptions) => {\n const unsubs = subscriptions.reduce((unsubs, subscription) => {\n if (subscription.set) {\n unsubs.push(on('set', subscription.set));\n }\n if (subscription.get) {\n unsubs.push(on('get', subscription.get));\n }\n if (subscription.reset) {\n unsubs.push(on('reset', subscription.reset));\n }\n if (subscription.dispose) {\n unsubs.push(on('dispose', subscription.dispose));\n }\n return unsubs;\n }, []);\n return () => unsubs.forEach((unsub) => unsub());\n };\n const forceUpdate = (key) => {\n const oldValue = states.get(key);\n handlers.set.forEach((cb) => cb(key, oldValue, oldValue));\n };\n return {\n state,\n get,\n set,\n on,\n onChange,\n use,\n dispose,\n reset,\n forceUpdate,\n };\n};\nconst removeFromArray = (array, item) => {\n const index = array.indexOf(item);\n if (index >= 0) {\n array[index] = array[array.length - 1];\n array.length--;\n }\n};\n\nconst createStore = (defaultState, shouldUpdate) => {\n const map = createObservableMap(defaultState, shouldUpdate);\n map.use(stencilSubscription());\n return map;\n};\n\nexport { createObservableMap, createStore };\n","import { WebIdProfile } from '@pod-os/core';\nimport { createStore } from '@stencil/store';\n\nconst store = createStore({\n isLoggedIn: false,\n webId: '',\n profile: null as WebIdProfile\n});\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a6a7690.js";import{s}from"./p-6c7ca160.js";import{B as e}from"./p-49b70074.js";const o="iframe{width:100%;height:100vh}.error{display:flex;opacity:0.8;background:repeating-linear-gradient( -45deg, rgba(150, 0, 0, 0.1), rgba(150, 0, 0, 0.1) 10px, #fff 5px, #fff 25px );flex-direction:column;border:1px solid red;color:black;align-items:center;justify-content:center;word-break:break-all;padding:1rem;box-sizing:border-box}.error ion-icon{color:#282828;--ionicon-stroke-width:calc(var(--width) / 5);font-size:calc(var(--width) / 2)}a{text-decoration:none;width:var(--width);height:var(--height)}.code{font-weight:bold;font-size:calc(var(--width) / 8)}.text{font-size:calc(var(--width) / 20)}";const a=o;const h=class{constructor(r){t(this,r);this.initializeOsEmitter=i(this,"pod-os:init",7);this.resourceLoadedEmitter=i(this,"pod-os:resource-loaded",7);this.loading=true;this.setOs=async t=>{this.os=t}}componentWillLoad(){s.onChange("isLoggedIn",(()=>this.fetchBlob()));this.initializeOsEmitter.emit(this.setOs)}async fetchBlob(){try{this.loading=true;const t=await this.os.fetchFile(this.src);this.resourceLoadedEmitter.emit(this.src);if(t.blob()){this.dataUri=URL.createObjectURL(t.blob());this.error=null}else{this.brokenFile=t}}catch(t){this.error=t}finally{this.loading=false}}render(){if(this.loading){return r("ion-skeleton-text",{animated:true})}if(this.error){return r("div",{class:"error"},this.error.message)}if(this.brokenFile){return r(e,{file:this.brokenFile})}return r("iframe",{src:this.dataUri})}static get watchers(){return{os:["fetchBlob"],src:["fetchBlob"]}}};h.style=a;export{h as pos_document};
2
- //# sourceMappingURL=p-a23915ba.entry.js.map
@@ -1,2 +0,0 @@
1
- import{r as t,h as e,H as r,d as i,e as n,f as o,w as s,i as a,j as c,k as l}from"./p-7a6a7690.js";import{i as d,c as h,d as b,a as u,r as f}from"./p-25270f1a.js";import{o as p,c as g,h as m}from"./p-669fab6c.js";import{g as v,c as y}from"./p-866a6047.js";import{i as w}from"./p-4d0cb38d.js";import{a as k,c as x,b as z,s as _,d as C}from"./p-0ee8b7a7.js";import{s as S}from"./p-6c7ca160.js";import{P as j}from"./p-c984fc73.js";import{s as L}from"./p-f6671856.js";import"./p-98c00bd2.js";import{t as X}from"./p-278bf69e.js";import{B as P}from"./p-49b70074.js";import{s as I}from"./p-182f722d.js";import"./p-7efd6867.js";import"./p-7a33ba37.js";import"./p-8206b1f1.js";import"./p-d6769f21.js";const T=":host{--ion-safe-area-left:0px;--ion-safe-area-right:0px;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:block;position:relative;background:var(--background);color:var(--color);font-family:var(--ion-font-family, inherit);contain:content;overflow:hidden}:host(.ion-color){background:var(--ion-color-base);color:var(--ion-color-contrast)}:host(.card-disabled){cursor:default;opacity:0.3;pointer-events:none}.card-native{font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;display:block;width:100%;min-height:var(--min-height);transition:var(--transition);border-width:var(--border-width);border-style:var(--border-style);border-color:var(--border-color);outline:none;background:inherit}.card-native::-moz-focus-inner{border:0}button,a{cursor:pointer;user-select:none;-webkit-user-drag:none}ion-ripple-effect{color:var(--ripple-color)}:host{--background:var(--ion-card-background, var(--ion-item-background, var(--ion-background-color, #fff)));--color:var(--ion-card-color, var(--ion-item-color, var(--ion-color-step-600, #666666)));-webkit-margin-start:16px;margin-inline-start:16px;-webkit-margin-end:16px;margin-inline-end:16px;margin-top:24px;margin-bottom:24px;border-radius:8px;transition:transform 500ms cubic-bezier(0.12, 0.72, 0.29, 1);font-size:0.875rem;box-shadow:0 4px 16px rgba(0, 0, 0, 0.12)}:host(.ion-activated){transform:scale3d(0.97, 0.97, 1)}";const E=T;const O=":host{--ion-safe-area-left:0px;--ion-safe-area-right:0px;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:block;position:relative;background:var(--background);color:var(--color);font-family:var(--ion-font-family, inherit);contain:content;overflow:hidden}:host(.ion-color){background:var(--ion-color-base);color:var(--ion-color-contrast)}:host(.card-disabled){cursor:default;opacity:0.3;pointer-events:none}.card-native{font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;display:block;width:100%;min-height:var(--min-height);transition:var(--transition);border-width:var(--border-width);border-style:var(--border-style);border-color:var(--border-color);outline:none;background:inherit}.card-native::-moz-focus-inner{border:0}button,a{cursor:pointer;user-select:none;-webkit-user-drag:none}ion-ripple-effect{color:var(--ripple-color)}:host{--background:var(--ion-card-background, var(--ion-item-background, var(--ion-background-color, #fff)));--color:var(--ion-card-color, var(--ion-item-color, var(--ion-color-step-550, #737373)));-webkit-margin-start:10px;margin-inline-start:10px;-webkit-margin-end:10px;margin-inline-end:10px;margin-top:10px;margin-bottom:10px;border-radius:4px;font-size:0.875rem;box-shadow:0 3px 1px -2px rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 1px 5px 0 rgba(0, 0, 0, 0.12)}";const U=O;const A=class{constructor(e){t(this,e);this.inheritedAriaAttributes={};this.color=undefined;this.button=false;this.type="button";this.disabled=false;this.download=undefined;this.href=undefined;this.rel=undefined;this.routerDirection="forward";this.routerAnimation=undefined;this.target=undefined}componentWillLoad(){this.inheritedAriaAttributes=d(this.el,["aria-label"])}isClickable(){return this.href!==undefined||this.button}renderCard(t){const r=this.isClickable();if(!r){return[e("slot",null)]}const{href:i,routerAnimation:n,routerDirection:o,inheritedAriaAttributes:s}=this;const a=r?i===undefined?"button":"a":"div";const c=a==="button"?{type:this.type}:{download:this.download,href:this.href,rel:this.rel,target:this.target};return e(a,Object.assign({},c,s,{class:"card-native",part:"native",disabled:this.disabled,onClick:t=>p(i,t,o,n)}),e("slot",null),r&&t==="md"&&e("ion-ripple-effect",null))}render(){const t=v(this);return e(r,{key:"b92792294360fd974324b31ed2d3db00d3e2f8cd",class:g(this.color,{[t]:true,"card-disabled":this.disabled,"ion-activatable":this.isClickable()})},this.renderCard(t))}get el(){return i(this)}};A.style={ios:E,md:U};const D="ion-card-content{display:block;position:relative}.card-content-ios{-webkit-padding-start:20px;padding-inline-start:20px;-webkit-padding-end:20px;padding-inline-end:20px;padding-top:20px;padding-bottom:20px;font-size:1rem;line-height:1.4}.card-content-ios h1{margin-left:0;margin-right:0;margin-top:0;margin-bottom:2px;font-size:1.5rem;font-weight:normal}.card-content-ios h2{margin-left:0;margin-right:0;margin-top:2px;margin-bottom:2px;font-size:1rem;font-weight:normal}.card-content-ios h3,.card-content-ios h4,.card-content-ios h5,.card-content-ios h6{margin-left:0;margin-right:0;margin-top:2px;margin-bottom:2px;font-size:0.875rem;font-weight:normal}.card-content-ios p{margin-left:0;margin-right:0;margin-top:0;margin-bottom:2px;font-size:0.875rem}ion-card-header+.card-content-ios{padding-top:0}";const M=D;const R="ion-card-content{display:block;position:relative}.card-content-md{-webkit-padding-start:16px;padding-inline-start:16px;-webkit-padding-end:16px;padding-inline-end:16px;padding-top:13px;padding-bottom:13px;font-size:0.875rem;line-height:1.5}.card-content-md h1{margin-left:0;margin-right:0;margin-top:0;margin-bottom:2px;font-size:1.5rem;font-weight:normal}.card-content-md h2{margin-left:0;margin-right:0;margin-top:2px;margin-bottom:2px;font-size:1rem;font-weight:normal}.card-content-md h3,.card-content-md h4,.card-content-md h5,.card-content-md h6{margin-left:0;margin-right:0;margin-top:2px;margin-bottom:2px;font-size:0.875rem;font-weight:normal}.card-content-md p{margin-left:0;margin-right:0;margin-top:0;margin-bottom:2px;font-size:0.875rem;font-weight:normal;line-height:1.5}ion-card-header+.card-content-md{padding-top:0}";const $=R;const B=class{constructor(e){t(this,e)}render(){const t=v(this);return e(r,{key:"dd95806f042fcd124b18126679f671be6e32a021",class:{[t]:true,[`card-content-${t}`]:true}})}};B.style={ios:M,md:$};const W=":host{--background:transparent;--color:inherit;display:flex;position:relative;flex-direction:column;background:var(--background);color:var(--color)}:host(.ion-color){background:var(--ion-color-base);color:var(--ion-color-contrast)}:host{-webkit-padding-start:20px;padding-inline-start:20px;-webkit-padding-end:20px;padding-inline-end:20px;padding-top:20px;padding-bottom:16px;flex-direction:column-reverse}@supports (backdrop-filter: blur(0)){:host(.card-header-translucent){background-color:rgba(var(--ion-background-color-rgb, 255, 255, 255), 0.9);backdrop-filter:saturate(180%) blur(30px)}}";const F=W;const N=":host{--background:transparent;--color:inherit;display:flex;position:relative;flex-direction:column;background:var(--background);color:var(--color)}:host(.ion-color){background:var(--ion-color-base);color:var(--ion-color-contrast)}:host{-webkit-padding-start:16px;padding-inline-start:16px;-webkit-padding-end:16px;padding-inline-end:16px;padding-top:16px;padding-bottom:16px}::slotted(ion-card-title:not(:first-child)),::slotted(ion-card-subtitle:not(:first-child)){margin-top:8px}";const q=N;const V=class{constructor(e){t(this,e);this.color=undefined;this.translucent=false}render(){const t=v(this);return e(r,{key:"44077ad8e3edf7726d0f7a039046e32dc56a83c9",class:g(this.color,{"card-header-translucent":this.translucent,"ion-inherit-color":true,[t]:true})},e("slot",{key:"51b6f4048d25521ece18d79e5361c762af41cae7"}))}};V.style={ios:F,md:q};let H;const G=()=>{if(typeof window==="undefined"){return new Map}else{if(!H){const t=window;t.Ionicons=t.Ionicons||{};H=t.Ionicons.map=t.Ionicons.map||new Map}return H}};const K=t=>{let e=J(t.src);if(e){return e}e=Z(t.name,t.icon,t.mode,t.ios,t.md);if(e){return Y(e,t)}if(t.icon){e=J(t.icon);if(e){return e}e=J(t.icon[t.mode]);if(e){return e}}return null};const Y=(t,e)=>{const r=G().get(t);if(r){return r}try{return n(`svg/${t}.svg`)}catch(r){console.warn(`[Ionicons Warning]: Could not load icon with name "${t}". Ensure that the icon is registered using addIcons or that the icon SVG data is passed directly to the icon component.`,e)}};const Z=(t,e,r,i,n)=>{r=(r&&et(r))==="ios"?"ios":"md";if(i&&r==="ios"){t=et(i)}else if(n&&r==="md"){t=et(n)}else{if(!t&&e&&!Q(e)){t=e}if(tt(t)){t=et(t)}}if(!tt(t)||t.trim()===""){return null}const o=t.replace(/[a-z]|-|\d/gi,"");if(o!==""){return null}return t};const J=t=>{if(tt(t)){t=t.trim();if(Q(t)){return t}}return null};const Q=t=>t.length>0&&/(\/|\.)/.test(t);const tt=t=>typeof t==="string";const et=t=>t.toLowerCase();const rt=(t,e=[])=>{const r={};e.forEach((e=>{if(t.hasAttribute(e)){const i=t.getAttribute(e);if(i!==null){r[e]=t.getAttribute(e)}t.removeAttribute(e)}}));return r};const it=t=>{if(t){if(t.dir!==""){return t.dir.toLowerCase()==="rtl"}}return(document===null||document===void 0?void 0:document.dir.toLowerCase())==="rtl"};const nt=t=>{const e=document.createElement("div");e.innerHTML=t;for(let t=e.childNodes.length-1;t>=0;t--){if(e.childNodes[t].nodeName.toLowerCase()!=="svg"){e.removeChild(e.childNodes[t])}}const r=e.firstElementChild;if(r&&r.nodeName.toLowerCase()==="svg"){const t=r.getAttribute("class")||"";r.setAttribute("class",(t+" s-ion-icon").trim());if(ot(r)){return e.innerHTML}}return""};const ot=t=>{if(t.nodeType===1){if(t.nodeName.toLowerCase()==="script"){return false}for(let e=0;e<t.attributes.length;e++){const r=t.attributes[e].name;if(tt(r)&&r.toLowerCase().indexOf("on")===0){return false}}for(let e=0;e<t.childNodes.length;e++){if(!ot(t.childNodes[e])){return false}}}return true};const st=t=>t.startsWith("data:image/svg+xml");const at=t=>t.indexOf(";utf8,")!==-1;const ct=new Map;const lt=new Map;let dt;const ht=(t,e)=>{let r=lt.get(t);if(!r){if(typeof fetch!=="undefined"&&typeof document!=="undefined"){if(st(t)&&at(t)){if(!dt){dt=new DOMParser}const e=dt.parseFromString(t,"text/html");const r=e.querySelector("svg");if(r){ct.set(t,r.outerHTML)}return Promise.resolve()}else{r=fetch(t).then((r=>{if(r.ok){return r.text().then((r=>{if(r&&e!==false){r=nt(r)}ct.set(t,r||"")}))}ct.set(t,"")}));lt.set(t,r)}}else{ct.set(t,"");return Promise.resolve()}}return r};const bt=":host{display:inline-block;width:1em;height:1em;contain:strict;fill:currentColor;box-sizing:content-box !important}:host .ionicon{stroke:currentColor}.ionicon-fill-none{fill:none}.ionicon-stroke-width{stroke-width:32px;stroke-width:var(--ionicon-stroke-width, 32px)}.icon-inner,.ionicon,svg{display:block;height:100%;width:100%}@supports (background: -webkit-named-image(i)){:host(.icon-rtl) .icon-inner{transform:scaleX(-1)}}@supports not selector(:dir(rtl)) and selector(:host-context([dir='rtl'])){:host(.icon-rtl) .icon-inner{transform:scaleX(-1)}}:host(.flip-rtl):host-context([dir='rtl']) .icon-inner{transform:scaleX(-1)}@supports selector(:dir(rtl)){:host(.flip-rtl:dir(rtl)) .icon-inner{transform:scaleX(-1)}:host(.flip-rtl:dir(ltr)) .icon-inner{transform:scaleX(1)}}:host(.icon-small){font-size:1.125rem !important}:host(.icon-large){font-size:2rem !important}:host(.ion-color){color:var(--ion-color-base) !important}:host(.ion-color-primary){--ion-color-base:var(--ion-color-primary, #3880ff)}:host(.ion-color-secondary){--ion-color-base:var(--ion-color-secondary, #0cd1e8)}:host(.ion-color-tertiary){--ion-color-base:var(--ion-color-tertiary, #f4a942)}:host(.ion-color-success){--ion-color-base:var(--ion-color-success, #10dc60)}:host(.ion-color-warning){--ion-color-base:var(--ion-color-warning, #ffce00)}:host(.ion-color-danger){--ion-color-base:var(--ion-color-danger, #f14141)}:host(.ion-color-light){--ion-color-base:var(--ion-color-light, #f4f5f8)}:host(.ion-color-medium){--ion-color-base:var(--ion-color-medium, #989aa2)}:host(.ion-color-dark){--ion-color-base:var(--ion-color-dark, #222428)}";const ut=bt;const ft=class{constructor(e){t(this,e);this.iconName=null;this.inheritedAttributes={};this.didLoadIcon=false;this.svgContent=undefined;this.isVisible=false;this.mode=pt();this.color=undefined;this.ios=undefined;this.md=undefined;this.flipRtl=undefined;this.name=undefined;this.src=undefined;this.icon=undefined;this.size=undefined;this.lazy=false;this.sanitize=true}componentWillLoad(){this.inheritedAttributes=rt(this.el,["aria-label"])}connectedCallback(){this.waitUntilVisible(this.el,"50px",(()=>{this.isVisible=true;this.loadIcon()}))}componentDidLoad(){if(!this.didLoadIcon){this.loadIcon()}}disconnectedCallback(){if(this.io){this.io.disconnect();this.io=undefined}}waitUntilVisible(t,e,r){if(this.lazy&&typeof window!=="undefined"&&window.IntersectionObserver){const i=this.io=new window.IntersectionObserver((t=>{if(t[0].isIntersecting){i.disconnect();this.io=undefined;r()}}),{rootMargin:e});i.observe(t)}else{r()}}loadIcon(){if(this.isVisible){const t=K(this);if(t){if(ct.has(t)){this.svgContent=ct.get(t)}else{ht(t,this.sanitize).then((()=>this.svgContent=ct.get(t)))}this.didLoadIcon=true}}this.iconName=Z(this.name,this.icon,this.mode,this.ios,this.md)}render(){const{flipRtl:t,iconName:i,inheritedAttributes:n,el:o}=this;const s=this.mode||"md";const a=i?(i.includes("arrow")||i.includes("chevron"))&&t!==false:false;const c=t||a;return e(r,Object.assign({role:"img",class:Object.assign(Object.assign({[s]:true},gt(this.color)),{[`icon-${this.size}`]:!!this.size,"flip-rtl":c,"icon-rtl":c&&it(o)})},n),this.svgContent?e("div",{class:"icon-inner",innerHTML:this.svgContent}):e("div",{class:"icon-inner"}))}static get assetsDirs(){return["svg"]}get el(){return i(this)}static get watchers(){return{name:["loadIcon"],src:["loadIcon"],icon:["loadIcon"],ios:["loadIcon"],md:["loadIcon"]}}};const pt=()=>typeof document!=="undefined"&&document.documentElement.getAttribute("mode")||"md";const gt=t=>t?{"ion-color":true,[`ion-color-${t}`]:true}:null;ft.style=ut;const mt=":host{--background:rgba(var(--ion-color-primary-rgb, 56, 128, 255), 0.3);--progress-background:var(--ion-color-primary, #3880ff);--buffer-background:var(--background);display:block;position:relative;width:100%;contain:strict;direction:ltr;overflow:hidden}.progress,.progress-indeterminate,.indeterminate-bar-primary,.indeterminate-bar-secondary,.progress-buffer-bar{left:0;right:0;top:0;bottom:0;position:absolute;width:100%;height:100%}.buffer-circles-container,.buffer-circles{left:0;right:0;top:0;bottom:0;position:absolute}.buffer-circles{right:-10px;left:-10px;}.progress,.progress-buffer-bar,.buffer-circles-container{transform-origin:left top;transition:transform 150ms linear}.progress,.progress-indeterminate{background:var(--progress-background);z-index:2}.progress-buffer-bar{background:var(--buffer-background);z-index:1}.buffer-circles-container{overflow:hidden}.indeterminate-bar-primary{top:0;right:0;bottom:0;left:-145.166611%;animation:primary-indeterminate-translate 2s infinite linear}.indeterminate-bar-primary .progress-indeterminate{animation:primary-indeterminate-scale 2s infinite linear;animation-play-state:inherit}.indeterminate-bar-secondary{top:0;right:0;bottom:0;left:-54.888891%;animation:secondary-indeterminate-translate 2s infinite linear}.indeterminate-bar-secondary .progress-indeterminate{animation:secondary-indeterminate-scale 2s infinite linear;animation-play-state:inherit}.buffer-circles{background-image:radial-gradient(ellipse at center, var(--buffer-background) 0%, var(--buffer-background) 30%, transparent 30%);background-repeat:repeat-x;background-position:5px center;background-size:10px 10px;z-index:0;animation:buffering 450ms infinite linear}:host(.progress-bar-reversed){transform:scaleX(-1)}:host(.progress-paused) .indeterminate-bar-secondary,:host(.progress-paused) .indeterminate-bar-primary,:host(.progress-paused) .buffer-circles{animation-play-state:paused}:host(.ion-color) .progress-buffer-bar{background:rgba(var(--ion-color-base-rgb), 0.3)}:host(.ion-color) .buffer-circles{background-image:radial-gradient(ellipse at center, rgba(var(--ion-color-base-rgb), 0.3) 0%, rgba(var(--ion-color-base-rgb), 0.3) 30%, transparent 30%)}:host(.ion-color) .progress,:host(.ion-color) .progress-indeterminate{background:var(--ion-color-base)}@keyframes primary-indeterminate-translate{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(83.67142%)}100%{transform:translateX(200.611057%)}}@keyframes primary-indeterminate-scale{0%{transform:scaleX(0.08)}36.65%{animation-timing-function:cubic-bezier(0.334731, 0.12482, 0.785844, 1);transform:scaleX(0.08)}69.15%{animation-timing-function:cubic-bezier(0.06, 0.11, 0.6, 1);transform:scaleX(0.661479)}100%{transform:scaleX(0.08)}}@keyframes secondary-indeterminate-translate{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(37.651913%)}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(84.386165%)}100%{transform:translateX(160.277782%)}}@keyframes secondary-indeterminate-scale{0%{animation-timing-function:cubic-bezier(0.205028, 0.057051, 0.57661, 0.453971);transform:scaleX(0.08)}19.15%{animation-timing-function:cubic-bezier(0.152313, 0.196432, 0.648374, 1.004315);transform:scaleX(0.457104)}44.15%{animation-timing-function:cubic-bezier(0.257759, -0.003163, 0.211762, 1.38179);transform:scaleX(0.72796)}100%{transform:scaleX(0.08)}}@keyframes buffering{to{transform:translateX(-10px)}}:host{height:3px}";const vt=mt;const yt=":host{--background:rgba(var(--ion-color-primary-rgb, 56, 128, 255), 0.3);--progress-background:var(--ion-color-primary, #3880ff);--buffer-background:var(--background);display:block;position:relative;width:100%;contain:strict;direction:ltr;overflow:hidden}.progress,.progress-indeterminate,.indeterminate-bar-primary,.indeterminate-bar-secondary,.progress-buffer-bar{left:0;right:0;top:0;bottom:0;position:absolute;width:100%;height:100%}.buffer-circles-container,.buffer-circles{left:0;right:0;top:0;bottom:0;position:absolute}.buffer-circles{right:-10px;left:-10px;}.progress,.progress-buffer-bar,.buffer-circles-container{transform-origin:left top;transition:transform 150ms linear}.progress,.progress-indeterminate{background:var(--progress-background);z-index:2}.progress-buffer-bar{background:var(--buffer-background);z-index:1}.buffer-circles-container{overflow:hidden}.indeterminate-bar-primary{top:0;right:0;bottom:0;left:-145.166611%;animation:primary-indeterminate-translate 2s infinite linear}.indeterminate-bar-primary .progress-indeterminate{animation:primary-indeterminate-scale 2s infinite linear;animation-play-state:inherit}.indeterminate-bar-secondary{top:0;right:0;bottom:0;left:-54.888891%;animation:secondary-indeterminate-translate 2s infinite linear}.indeterminate-bar-secondary .progress-indeterminate{animation:secondary-indeterminate-scale 2s infinite linear;animation-play-state:inherit}.buffer-circles{background-image:radial-gradient(ellipse at center, var(--buffer-background) 0%, var(--buffer-background) 30%, transparent 30%);background-repeat:repeat-x;background-position:5px center;background-size:10px 10px;z-index:0;animation:buffering 450ms infinite linear}:host(.progress-bar-reversed){transform:scaleX(-1)}:host(.progress-paused) .indeterminate-bar-secondary,:host(.progress-paused) .indeterminate-bar-primary,:host(.progress-paused) .buffer-circles{animation-play-state:paused}:host(.ion-color) .progress-buffer-bar{background:rgba(var(--ion-color-base-rgb), 0.3)}:host(.ion-color) .buffer-circles{background-image:radial-gradient(ellipse at center, rgba(var(--ion-color-base-rgb), 0.3) 0%, rgba(var(--ion-color-base-rgb), 0.3) 30%, transparent 30%)}:host(.ion-color) .progress,:host(.ion-color) .progress-indeterminate{background:var(--ion-color-base)}@keyframes primary-indeterminate-translate{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(83.67142%)}100%{transform:translateX(200.611057%)}}@keyframes primary-indeterminate-scale{0%{transform:scaleX(0.08)}36.65%{animation-timing-function:cubic-bezier(0.334731, 0.12482, 0.785844, 1);transform:scaleX(0.08)}69.15%{animation-timing-function:cubic-bezier(0.06, 0.11, 0.6, 1);transform:scaleX(0.661479)}100%{transform:scaleX(0.08)}}@keyframes secondary-indeterminate-translate{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(37.651913%)}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(84.386165%)}100%{transform:translateX(160.277782%)}}@keyframes secondary-indeterminate-scale{0%{animation-timing-function:cubic-bezier(0.205028, 0.057051, 0.57661, 0.453971);transform:scaleX(0.08)}19.15%{animation-timing-function:cubic-bezier(0.152313, 0.196432, 0.648374, 1.004315);transform:scaleX(0.457104)}44.15%{animation-timing-function:cubic-bezier(0.257759, -0.003163, 0.211762, 1.38179);transform:scaleX(0.72796)}100%{transform:scaleX(0.08)}}@keyframes buffering{to{transform:translateX(-10px)}}:host{height:4px}";const wt=yt;const kt=class{constructor(e){t(this,e);this.type="determinate";this.reversed=false;this.value=0;this.buffer=1;this.color=undefined}render(){const{color:t,type:i,reversed:n,value:o,buffer:s}=this;const a=y.getBoolean("_testing");const c=v(this);return e(r,{key:"944b79ed6fce1b2c0ed48681cd8517a5abbddd80",role:"progressbar","aria-valuenow":i==="determinate"?o:null,"aria-valuemin":"0","aria-valuemax":"1",class:g(t,{[c]:true,[`progress-bar-${i}`]:true,"progress-paused":a,"progress-bar-reversed":document.dir==="rtl"?!n:n})},i==="indeterminate"?xt():zt(o,s))}};const xt=()=>e("div",{part:"track",class:"progress-buffer-bar"},e("div",{class:"indeterminate-bar-primary"},e("span",{part:"progress",class:"progress-indeterminate"})),e("div",{class:"indeterminate-bar-secondary"},e("span",{part:"progress",class:"progress-indeterminate"})));const zt=(t,r)=>{const i=h(0,t,1);const n=h(0,r,1);return[e("div",{part:"progress",class:"progress",style:{transform:`scaleX(${i})`}}),e("div",{class:{"buffer-circles-container":true,"ion-hide":n===1},style:{transform:`translateX(${n*100}%)`}},e("div",{class:"buffer-circles-container",style:{transform:`translateX(-${n*100}%)`}},e("div",{part:"stream",class:"buffer-circles"}))),e("div",{part:"track",class:"progress-buffer-bar",style:{transform:`scaleX(${n})`}})]};kt.style={ios:vt,md:wt};const _t=":host{left:0;right:0;top:0;bottom:0;position:absolute;contain:strict;pointer-events:none}:host(.unbounded){contain:layout size style}.ripple-effect{border-radius:50%;position:absolute;background-color:currentColor;color:inherit;contain:strict;opacity:0;animation:225ms rippleAnimation forwards, 75ms fadeInAnimation forwards;will-change:transform, opacity;pointer-events:none}.fade-out{transform:translate(var(--translate-end)) scale(var(--final-scale, 1));animation:150ms fadeOutAnimation forwards}@keyframes rippleAnimation{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:scale(1)}to{transform:translate(var(--translate-end)) scale(var(--final-scale, 1))}}@keyframes fadeInAnimation{from{animation-timing-function:linear;opacity:0}to{opacity:0.16}}@keyframes fadeOutAnimation{from{animation-timing-function:linear;opacity:0.16}to{opacity:0}}";const Ct=_t;const St=class{constructor(e){t(this,e);this.type="bounded"}async addRipple(t,e){return new Promise((r=>{o((()=>{const i=this.el.getBoundingClientRect();const n=i.width;const o=i.height;const a=Math.sqrt(n*n+o*o);const c=Math.max(o,n);const l=this.unbounded?c:a+Lt;const d=Math.floor(c*Xt);const h=l/d;let b=t-i.left;let u=e-i.top;if(this.unbounded){b=n*.5;u=o*.5}const f=b-d*.5;const p=u-d*.5;const g=n*.5-b;const m=o*.5-u;s((()=>{const t=document.createElement("div");t.classList.add("ripple-effect");const e=t.style;e.top=p+"px";e.left=f+"px";e.width=e.height=d+"px";e.setProperty("--final-scale",`${h}`);e.setProperty("--translate-end",`${g}px, ${m}px`);const i=this.el.shadowRoot||this.el;i.appendChild(t);setTimeout((()=>{r((()=>{jt(t)}))}),225+100)}))}))}))}get unbounded(){return this.type==="unbounded"}render(){const t=v(this);return e(r,{key:"f1129019a6d556b008c754aeb79618c69baea9f8",role:"presentation",class:{[t]:true,unbounded:this.unbounded}})}get el(){return i(this)}};const jt=t=>{t.classList.add("fade-out");setTimeout((()=>{t.remove()}),200)};const Lt=10;const Xt=.5;St.style=Ct;const Pt=".sc-ion-searchbar-ios-h{--placeholder-color:initial;--placeholder-font-style:initial;--placeholder-font-weight:initial;--placeholder-opacity:0.6;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:flex;position:relative;align-items:center;width:100%;color:var(--color);font-family:var(--ion-font-family, inherit);box-sizing:border-box}.ion-color.sc-ion-searchbar-ios-h{color:var(--ion-color-contrast)}.ion-color.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{background:var(--ion-color-base)}.ion-color.sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios,.ion-color.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.ion-color.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{color:inherit}.searchbar-search-icon.sc-ion-searchbar-ios{color:var(--icon-color);pointer-events:none}.searchbar-input-container.sc-ion-searchbar-ios{display:block;position:relative;flex-shrink:1;width:100%}.searchbar-input.sc-ion-searchbar-ios{font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;border-radius:var(--border-radius);display:block;width:100%;min-height:inherit;border:0;outline:none;background:var(--background);font-family:inherit;box-shadow:var(--box-shadow);box-sizing:border-box;appearance:none}.searchbar-input.sc-ion-searchbar-ios::placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.searchbar-input.sc-ion-searchbar-ios::-webkit-search-cancel-button,.searchbar-input.sc-ion-searchbar-ios::-ms-clear{display:none}.searchbar-cancel-button.sc-ion-searchbar-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;display:none;height:100%;border:0;outline:none;color:var(--cancel-button-color);cursor:pointer;appearance:none}.searchbar-cancel-button.sc-ion-searchbar-ios>div.sc-ion-searchbar-ios{display:flex;align-items:center;justify-content:center;width:100%;height:100%}.searchbar-clear-button.sc-ion-searchbar-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;display:none;min-height:0;outline:none;color:var(--clear-button-color);appearance:none}.searchbar-clear-button.sc-ion-searchbar-ios:focus{opacity:0.5}.searchbar-has-value.searchbar-should-show-clear.sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios{display:block}.searchbar-disabled.sc-ion-searchbar-ios-h{cursor:default;opacity:0.4;pointer-events:none}.sc-ion-searchbar-ios-h{--background:rgba(var(--ion-text-color-rgb, 0, 0, 0), 0.07);--border-radius:10px;--box-shadow:none;--cancel-button-color:var(--ion-color-primary, #3880ff);--clear-button-color:var(--ion-color-step-600, #666666);--color:var(--ion-text-color, #000);--icon-color:var(--ion-color-step-600, #666666);-webkit-padding-start:12px;padding-inline-start:12px;-webkit-padding-end:12px;padding-inline-end:12px;padding-top:12px;padding-bottom:12px;min-height:60px;contain:content}.searchbar-input-container.sc-ion-searchbar-ios{min-height:36px}.searchbar-search-icon.sc-ion-searchbar-ios{-webkit-margin-start:calc(50% - 60px);margin-inline-start:calc(50% - 60px);top:0;position:absolute;width:1.375rem;height:100%;contain:strict}@supports (inset-inline-start: 0){.searchbar-search-icon.sc-ion-searchbar-ios{inset-inline-start:5px}}@supports not (inset-inline-start: 0){.searchbar-search-icon.sc-ion-searchbar-ios{left:5px}[dir=rtl].sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,[dir=rtl] .sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{left:unset;right:unset;right:5px}[dir=rtl].sc-ion-searchbar-ios .searchbar-search-icon.sc-ion-searchbar-ios{left:unset;right:unset;right:5px}@supports selector(:dir(rtl)){.searchbar-search-icon.sc-ion-searchbar-ios:dir(rtl){left:unset;right:unset;right:5px}}}.searchbar-input.sc-ion-searchbar-ios{-webkit-padding-start:0px;padding-inline-start:0px;-webkit-padding-end:0px;padding-inline-end:0px;padding-top:6px;padding-bottom:6px;height:100%;font-size:1.0625rem;font-weight:400;contain:strict}.searchbar-has-value.searchbar-should-show-clear.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{-webkit-padding-start:1.75rem;padding-inline-start:1.75rem;-webkit-padding-end:1.75rem;padding-inline-end:1.75rem}.searchbar-clear-button.sc-ion-searchbar-ios{top:0;background-position:center;position:absolute;width:1.875rem;height:100%;border:0;background-color:transparent}@supports (inset-inline-start: 0){.searchbar-clear-button.sc-ion-searchbar-ios{inset-inline-end:0}}@supports not (inset-inline-start: 0){.searchbar-clear-button.sc-ion-searchbar-ios{right:0}[dir=rtl].sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios,[dir=rtl] .sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios{left:unset;right:unset;left:0}[dir=rtl].sc-ion-searchbar-ios .searchbar-clear-button.sc-ion-searchbar-ios{left:unset;right:unset;left:0}@supports selector(:dir(rtl)){.searchbar-clear-button.sc-ion-searchbar-ios:dir(rtl){left:unset;right:unset;left:0}}}.searchbar-clear-icon.sc-ion-searchbar-ios{width:1.125rem;height:100%}.searchbar-cancel-button.sc-ion-searchbar-ios{-webkit-padding-start:8px;padding-inline-start:8px;-webkit-padding-end:0;padding-inline-end:0;padding-top:0;padding-bottom:0;flex-shrink:0;background-color:transparent;font-size:16px}.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{-webkit-margin-start:0;margin-inline-start:0}.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{-webkit-padding-start:1.875rem;padding-inline-start:1.875rem}.searchbar-has-focus.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.searchbar-should-show-cancel.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{display:block}.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{transition:all 300ms ease}.searchbar-animated.searchbar-has-focus.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.searchbar-animated.searchbar-should-show-cancel.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{opacity:1;pointer-events:auto}.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{-webkit-margin-end:-100%;margin-inline-end:-100%;transform:translate3d(0, 0, 0);transition:all 300ms ease;opacity:0;pointer-events:none}.searchbar-no-animate.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,.searchbar-no-animate.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios,.searchbar-no-animate.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{transition-duration:0ms}.ion-color.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{color:var(--ion-color-base)}@media (any-hover: hover){.ion-color.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios:hover{color:var(--ion-color-tint)}}ion-toolbar.sc-ion-searchbar-ios-h,ion-toolbar .sc-ion-searchbar-ios-h{padding-top:1px;padding-bottom:15px;min-height:52px}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color),ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color){color:inherit}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-cancel-button.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-cancel-button.sc-ion-searchbar-ios{color:currentColor}ion-toolbar.ion-color.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{color:currentColor;opacity:0.5}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-input.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-input.sc-ion-searchbar-ios{background:rgba(var(--ion-color-contrast-rgb), 0.07);color:currentColor}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-clear-button.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-clear-button.sc-ion-searchbar-ios{color:currentColor;opacity:0.5}";const It=Pt;const Tt=".sc-ion-searchbar-md-h{--placeholder-color:initial;--placeholder-font-style:initial;--placeholder-font-weight:initial;--placeholder-opacity:0.6;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:flex;position:relative;align-items:center;width:100%;color:var(--color);font-family:var(--ion-font-family, inherit);box-sizing:border-box}.ion-color.sc-ion-searchbar-md-h{color:var(--ion-color-contrast)}.ion-color.sc-ion-searchbar-md-h .searchbar-input.sc-ion-searchbar-md{background:var(--ion-color-base)}.ion-color.sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md,.ion-color.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md,.ion-color.sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md{color:inherit}.searchbar-search-icon.sc-ion-searchbar-md{color:var(--icon-color);pointer-events:none}.searchbar-input-container.sc-ion-searchbar-md{display:block;position:relative;flex-shrink:1;width:100%}.searchbar-input.sc-ion-searchbar-md{font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;border-radius:var(--border-radius);display:block;width:100%;min-height:inherit;border:0;outline:none;background:var(--background);font-family:inherit;box-shadow:var(--box-shadow);box-sizing:border-box;appearance:none}.searchbar-input.sc-ion-searchbar-md::placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.searchbar-input.sc-ion-searchbar-md::-webkit-search-cancel-button,.searchbar-input.sc-ion-searchbar-md::-ms-clear{display:none}.searchbar-cancel-button.sc-ion-searchbar-md{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;display:none;height:100%;border:0;outline:none;color:var(--cancel-button-color);cursor:pointer;appearance:none}.searchbar-cancel-button.sc-ion-searchbar-md>div.sc-ion-searchbar-md{display:flex;align-items:center;justify-content:center;width:100%;height:100%}.searchbar-clear-button.sc-ion-searchbar-md{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;display:none;min-height:0;outline:none;color:var(--clear-button-color);appearance:none}.searchbar-clear-button.sc-ion-searchbar-md:focus{opacity:0.5}.searchbar-has-value.searchbar-should-show-clear.sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md{display:block}.searchbar-disabled.sc-ion-searchbar-md-h{cursor:default;opacity:0.4;pointer-events:none}.sc-ion-searchbar-md-h{--background:var(--ion-background-color, #fff);--border-radius:2px;--box-shadow:0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 3px 1px -2px rgba(0, 0, 0, 0.2), 0 1px 5px 0 rgba(0, 0, 0, 0.12);--cancel-button-color:var(--ion-color-step-900, #1a1a1a);--clear-button-color:initial;--color:var(--ion-color-step-850, #262626);--icon-color:var(--ion-color-step-600, #666666);-webkit-padding-start:8px;padding-inline-start:8px;-webkit-padding-end:8px;padding-inline-end:8px;padding-top:8px;padding-bottom:8px;background:inherit}.searchbar-search-icon.sc-ion-searchbar-md{top:11px;width:1.3125rem;height:1.3125rem}@supports (inset-inline-start: 0){.searchbar-search-icon.sc-ion-searchbar-md{inset-inline-start:16px}}@supports not (inset-inline-start: 0){.searchbar-search-icon.sc-ion-searchbar-md{left:16px}[dir=rtl].sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md{left:unset;right:unset;right:16px}[dir=rtl].sc-ion-searchbar-md .searchbar-search-icon.sc-ion-searchbar-md{left:unset;right:unset;right:16px}@supports selector(:dir(rtl)){.searchbar-search-icon.sc-ion-searchbar-md:dir(rtl){left:unset;right:unset;right:16px}}}.searchbar-cancel-button.sc-ion-searchbar-md{top:0;background-color:transparent;font-size:1.5em}@supports (inset-inline-start: 0){.searchbar-cancel-button.sc-ion-searchbar-md{inset-inline-start:9px}}@supports not (inset-inline-start: 0){.searchbar-cancel-button.sc-ion-searchbar-md{left:9px}[dir=rtl].sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md{left:unset;right:unset;right:9px}[dir=rtl].sc-ion-searchbar-md .searchbar-cancel-button.sc-ion-searchbar-md{left:unset;right:unset;right:9px}@supports selector(:dir(rtl)){.searchbar-cancel-button.sc-ion-searchbar-md:dir(rtl){left:unset;right:unset;right:9px}}}.searchbar-search-icon.sc-ion-searchbar-md,.searchbar-cancel-button.sc-ion-searchbar-md{position:absolute}.searchbar-search-icon.ion-activated.sc-ion-searchbar-md,.searchbar-cancel-button.ion-activated.sc-ion-searchbar-md{background-color:transparent}.searchbar-input.sc-ion-searchbar-md{-webkit-padding-start:3.4375rem;padding-inline-start:3.4375rem;-webkit-padding-end:3.4375rem;padding-inline-end:3.4375rem;padding-top:0.375rem;padding-bottom:0.375rem;background-position:left 8px center;height:auto;font-size:1rem;font-weight:400;line-height:30px}[dir=rtl].sc-ion-searchbar-md-h .searchbar-input.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-input.sc-ion-searchbar-md{background-position:right 8px center}[dir=rtl].sc-ion-searchbar-md .searchbar-input.sc-ion-searchbar-md{background-position:right 8px center}@supports selector(:dir(rtl)){.searchbar-input.sc-ion-searchbar-md:dir(rtl){background-position:right 8px center}}.searchbar-clear-button.sc-ion-searchbar-md{top:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;position:absolute;height:100%;border:0;background-color:transparent}@supports (inset-inline-start: 0){.searchbar-clear-button.sc-ion-searchbar-md{inset-inline-end:13px}}@supports not (inset-inline-start: 0){.searchbar-clear-button.sc-ion-searchbar-md{right:13px}[dir=rtl].sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md{left:unset;right:unset;left:13px}[dir=rtl].sc-ion-searchbar-md .searchbar-clear-button.sc-ion-searchbar-md{left:unset;right:unset;left:13px}@supports selector(:dir(rtl)){.searchbar-clear-button.sc-ion-searchbar-md:dir(rtl){left:unset;right:unset;left:13px}}}.searchbar-clear-button.ion-activated.sc-ion-searchbar-md{background-color:transparent}.searchbar-clear-icon.sc-ion-searchbar-md{width:1.375rem;height:100%}.searchbar-has-focus.sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md{display:block}.searchbar-has-focus.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md,.searchbar-should-show-cancel.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md{display:block}.searchbar-has-focus.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md+.searchbar-search-icon.sc-ion-searchbar-md,.searchbar-should-show-cancel.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md+.searchbar-search-icon.sc-ion-searchbar-md{display:none}ion-toolbar.sc-ion-searchbar-md-h,ion-toolbar .sc-ion-searchbar-md-h{-webkit-padding-start:7px;padding-inline-start:7px;-webkit-padding-end:7px;padding-inline-end:7px;padding-top:3px;padding-bottom:3px}";const Et=Tt;const Ot=class{constructor(e){t(this,e);this.ionInput=a(this,"ionInput",7);this.ionChange=a(this,"ionChange",7);this.ionCancel=a(this,"ionCancel",7);this.ionClear=a(this,"ionClear",7);this.ionBlur=a(this,"ionBlur",7);this.ionFocus=a(this,"ionFocus",7);this.ionStyle=a(this,"ionStyle",7);this.isCancelVisible=false;this.shouldAlignLeft=true;this.inputId=`ion-searchbar-${Ut++}`;this.inheritedAttributes={};this.onClearInput=async t=>{this.ionClear.emit();return new Promise((e=>{setTimeout((()=>{const r=this.getValue();if(r!==""){this.value="";this.emitInputChange();if(t&&!this.focused){this.setFocus();this.focusedValue=r}}e()}),16*4)}))};this.onCancelSearchbar=async t=>{if(t){t.preventDefault();t.stopPropagation()}this.ionCancel.emit();const e=this.getValue();const r=this.focused;await this.onClearInput();if(e&&!r){this.emitValueChange(t)}if(this.nativeInput){this.nativeInput.blur()}};this.onInput=t=>{const e=t.target;if(e){this.value=e.value}this.emitInputChange(t)};this.onChange=t=>{this.emitValueChange(t)};this.onBlur=t=>{this.focused=false;this.ionBlur.emit();this.positionElements();if(this.focusedValue!==this.value){this.emitValueChange(t)}this.focusedValue=undefined};this.onFocus=()=>{this.focused=true;this.focusedValue=this.value;this.ionFocus.emit();this.positionElements()};this.focused=false;this.noAnimate=true;this.color=undefined;this.animated=false;this.autocapitalize="default";this.autocomplete="off";this.autocorrect="off";this.cancelButtonIcon=y.get("backButtonIcon",k);this.cancelButtonText="Cancel";this.clearIcon=undefined;this.debounce=undefined;this.disabled=false;this.inputmode=undefined;this.enterkeyhint=undefined;this.maxlength=undefined;this.minlength=undefined;this.name=this.inputId;this.placeholder="Search";this.searchIcon=undefined;this.showCancelButton="never";this.showClearButton="always";this.spellcheck=false;this.type="search";this.value=""}onLangChanged(t){this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{lang:t});c(this)}onDirChanged(t){this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{dir:t});c(this)}debounceChanged(){const{ionInput:t,debounce:e,originalIonInput:r}=this;this.ionInput=e===undefined?r!==null&&r!==void 0?r:t:b(t,e)}valueChanged(){const t=this.nativeInput;const e=this.getValue();if(t&&t.value!==e){t.value=e}}showCancelButtonChanged(){requestAnimationFrame((()=>{this.positionElements();c(this)}))}connectedCallback(){this.emitStyle()}componentWillLoad(){this.inheritedAttributes=Object.assign({},d(this.el,["lang","dir"]))}componentDidLoad(){this.originalIonInput=this.ionInput;this.positionElements();this.debounceChanged();setTimeout((()=>{this.noAnimate=false}),300)}emitStyle(){this.ionStyle.emit({searchbar:true})}async setFocus(){if(this.nativeInput){this.nativeInput.focus()}}async getInputElement(){if(!this.nativeInput){await new Promise((t=>u(this.el,t)))}return Promise.resolve(this.nativeInput)}emitValueChange(t){const{value:e}=this;const r=e==null?e:e.toString();this.focusedValue=r;this.ionChange.emit({value:r,event:t})}emitInputChange(t){const{value:e}=this;this.ionInput.emit({value:e,event:t})}positionElements(){const t=this.getValue();const e=this.shouldAlignLeft;const r=v(this);const i=!this.animated||t.trim()!==""||!!this.focused;this.shouldAlignLeft=i;if(r!=="ios"){return}if(e!==i){this.positionPlaceholder()}if(this.animated){this.positionCancelButton()}}positionPlaceholder(){const t=this.nativeInput;if(!t){return}const e=w(this.el);const r=(this.el.shadowRoot||this.el).querySelector(".searchbar-search-icon");if(this.shouldAlignLeft){t.removeAttribute("style");r.removeAttribute("style")}else{const i=document;const n=i.createElement("span");n.innerText=this.placeholder||"";i.body.appendChild(n);f((()=>{const i=n.offsetWidth;n.remove();const o="calc(50% - "+i/2+"px)";const s="calc(50% - "+(i/2+r.clientWidth+8)+"px)";if(e){t.style.paddingRight=o;r.style.marginRight=s}else{t.style.paddingLeft=o;r.style.marginLeft=s}}))}}positionCancelButton(){const t=w(this.el);const e=(this.el.shadowRoot||this.el).querySelector(".searchbar-cancel-button");const r=this.shouldShowCancelButton();if(e!==null&&r!==this.isCancelVisible){const i=e.style;this.isCancelVisible=r;if(r){if(t){i.marginLeft="0"}else{i.marginRight="0"}}else{const r=e.offsetWidth;if(r>0){if(t){i.marginLeft=-r+"px"}else{i.marginRight=-r+"px"}}}}}getValue(){return this.value||""}hasValue(){return this.getValue()!==""}shouldShowCancelButton(){if(this.showCancelButton==="never"||this.showCancelButton==="focus"&&!this.focused){return false}return true}shouldShowClearButton(){if(this.showClearButton==="never"||this.showClearButton==="focus"&&!this.focused){return false}return true}render(){const{cancelButtonText:t,autocapitalize:i}=this;const n=this.animated&&y.getBoolean("animated",true);const o=v(this);const s=this.clearIcon||(o==="ios"?x:z);const a=this.searchIcon||(o==="ios"?_:C);const c=this.shouldShowCancelButton();const l=this.showCancelButton!=="never"&&e("button",{key:"9c7b4d2e86d9bcd12e57c9a96723d3da598a3773","aria-label":t,"aria-hidden":c?undefined:"true",type:"button",tabIndex:o==="ios"&&!c?-1:undefined,onMouseDown:this.onCancelSearchbar,onTouchStart:this.onCancelSearchbar,class:"searchbar-cancel-button"},e("div",{key:"1c25268a776134cccd29eb752898cb8ac0eed30f","aria-hidden":"true"},o==="md"?e("ion-icon",{"aria-hidden":"true",mode:o,icon:this.cancelButtonIcon,lazy:false}):t));return e(r,{key:"feef9fc7e405656e134a76dc037aaaa1a4ce36b4",role:"search","aria-disabled":this.disabled?"true":null,class:g(this.color,{[o]:true,"searchbar-animated":n,"searchbar-disabled":this.disabled,"searchbar-no-animate":n&&this.noAnimate,"searchbar-has-value":this.hasValue(),"searchbar-left-aligned":this.shouldAlignLeft,"searchbar-has-focus":this.focused,"searchbar-should-show-clear":this.shouldShowClearButton(),"searchbar-should-show-cancel":this.shouldShowCancelButton()})},e("div",{key:"92e3925dc0de468e5665705902153837105dfa57",class:"searchbar-input-container"},e("input",Object.assign({key:"fb74faf81b347a62338ccdac981525df1c52b322","aria-label":"search text",disabled:this.disabled,ref:t=>this.nativeInput=t,class:"searchbar-input",inputMode:this.inputmode,enterKeyHint:this.enterkeyhint,name:this.name,onInput:this.onInput,onChange:this.onChange,onBlur:this.onBlur,onFocus:this.onFocus,minLength:this.minlength,maxLength:this.maxlength,placeholder:this.placeholder,type:this.type,value:this.getValue(),autoCapitalize:i==="default"?undefined:i,autoComplete:this.autocomplete,autoCorrect:this.autocorrect,spellcheck:this.spellcheck},this.inheritedAttributes)),o==="md"&&l,e("ion-icon",{key:"d58c3636dac1d2e4135989f4c07dc95c51492e60","aria-hidden":"true",mode:o,icon:a,lazy:false,class:"searchbar-search-icon"}),e("button",{key:"1cece7c63ca5ca4b8799e15ee6d2bac100ef0d5e","aria-label":"reset",type:"button","no-blur":true,class:"searchbar-clear-button",onPointerDown:t=>{t.preventDefault()},onClick:()=>this.onClearInput(true)},e("ion-icon",{key:"fe3c2b9cac29002f69e95a89b554c7504e2df050","aria-hidden":"true",mode:o,icon:s,lazy:false,class:"searchbar-clear-icon"}))),o==="ios"&&l)}get el(){return i(this)}static get watchers(){return{lang:["onLangChanged"],dir:["onDirChanged"],debounce:["debounceChanged"],value:["valueChanged"],showCancelButton:["showCancelButtonChanged"]}}};let Ut=0;Ot.style={ios:It,md:Et};const At=":host{--background:rgba(var(--background-rgb, var(--ion-text-color-rgb, 0, 0, 0)), 0.065);border-radius:var(--border-radius, inherit);display:block;width:100%;height:inherit;margin-top:4px;margin-bottom:4px;background:var(--background);line-height:10px;user-select:none;pointer-events:none}span{display:inline-block}:host(.in-media){margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;height:100%}:host(.skeleton-text-animated){position:relative;background:linear-gradient(to right, rgba(var(--background-rgb, var(--ion-text-color-rgb, 0, 0, 0)), 0.065) 8%, rgba(var(--background-rgb, var(--ion-text-color-rgb, 0, 0, 0)), 0.135) 18%, rgba(var(--background-rgb, var(--ion-text-color-rgb, 0, 0, 0)), 0.065) 33%);background-size:800px 104px;animation-duration:1s;animation-fill-mode:forwards;animation-iteration-count:infinite;animation-name:shimmer;animation-timing-function:linear}@keyframes shimmer{0%{background-position:-400px 0}100%{background-position:400px 0}}";const Dt=At;const Mt=class{constructor(e){t(this,e);this.ionStyle=a(this,"ionStyle",7);this.animated=false}componentWillLoad(){this.emitStyle()}emitStyle(){const t={"skeleton-text":true};this.ionStyle.emit(t)}render(){const t=this.animated&&y.getBoolean("animated",true);const i=m("ion-avatar",this.el)||m("ion-thumbnail",this.el);const n=v(this);return e(r,{key:"4dab0fd2de666de12ad8f6dc6ed1e1de0be67ddd",class:{[n]:true,"skeleton-text-animated":t,"in-media":i}},e("span",{key:"f8f908ec24d65e63b14d9a54640a5f18f0fa8fa5"}," "))}get el(){return i(this)}};Mt.style=Dt;const Rt=":host{font-family:var(--font-sans);display:block}button#new{cursor:pointer;display:flex;align-items:center;justify-content:center;border:none;width:var(--scale-5);height:var(--scale-5);background-color:var(--pos-primary-color);color:var(--color-grey-50);font-size:var(--scale-6);border-radius:var(--radius-xs)}button#new:hover,button#new:focus{outline:none;filter:brightness(110%);box-shadow:var(--shadow-sm)}pos-new-thing-form{margin:var(--scale-3)}";const $t=Rt;const Bt=class{constructor(e){t(this,e)}openDialog(){this.dialog.showModal()}render(){return e(r,{key:"35b8629fc9ac9d9e759009f329dc9437307649c3"},e("button",{key:"b6c0b1d06fbed05a079c1e4cb684f227fd40d098",id:"new",title:"Add a new thing",onClick:()=>this.openDialog()},e("ion-icon",{key:"2dfbcff7480dfc7397a5810ca7a33b9e583a77ee",name:"add-circle-outline"})),e("pos-dialog",{key:"a61bf93754ca323fbc23137956a00c39be81cad9",ref:t=>this.dialog=t},e("span",{key:"a4095e3c9ddd26e18ce002a05ef65d8895894589",slot:"title"},"Add a new thing"),e("pos-new-thing-form",{key:"136cfbbab823f5abc313642e1dc04f67d5d81777",slot:"content",referenceUri:this.referenceUri})))}};Bt.style=$t;const Wt=()=>new j;function Ft(t){return typeof t==="function"}function Nt(t){const e=t=>{Error.call(t);t.stack=(new Error).stack};const r=t(e);r.prototype=Object.create(Error.prototype);r.prototype.constructor=r;return r}const qt=Nt((t=>function e(r){t(this);this.message=r?`${r.length} errors occurred during unsubscription:\n${r.map(((t,e)=>`${e+1}) ${t.toString()}`)).join("\n ")}`:"";this.name="UnsubscriptionError";this.errors=r}));function Vt(t,e){if(t){const r=t.indexOf(e);0<=r&&t.splice(r,1)}}class Ht{constructor(t){this.initialTeardown=t;this.closed=false;this._parentage=null;this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=true;const{_parentage:e}=this;if(e){this._parentage=null;if(Array.isArray(e)){for(const t of e){t.remove(this)}}else{e.remove(this)}}const{initialTeardown:r}=this;if(Ft(r)){try{r()}catch(e){t=e instanceof qt?e.errors:[e]}}const{_finalizers:i}=this;if(i){this._finalizers=null;for(const e of i){try{Yt(e)}catch(e){t=t!==null&&t!==void 0?t:[];if(e instanceof qt){t=[...t,...e.errors]}else{t.push(e)}}}}if(t){throw new qt(t)}}}add(t){var e;if(t&&t!==this){if(this.closed){Yt(t)}else{if(t instanceof Ht){if(t.closed||t._hasParent(this)){return}t._addParent(this)}(this._finalizers=(e=this._finalizers)!==null&&e!==void 0?e:[]).push(t)}}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;if(e===t){this._parentage=null}else if(Array.isArray(e)){Vt(e,t)}}remove(t){const{_finalizers:e}=this;e&&Vt(e,t);if(t instanceof Ht){t._removeParent(this)}}}Ht.EMPTY=(()=>{const t=new Ht;t.closed=true;return t})();const Gt=Ht.EMPTY;function Kt(t){return t instanceof Ht||t&&"closed"in t&&Ft(t.remove)&&Ft(t.add)&&Ft(t.unsubscribe)}function Yt(t){if(Ft(t)){t()}else{t.unsubscribe()}}const Zt={onUnhandledError:null,onStoppedNotification:null,Promise:undefined,useDeprecatedSynchronousErrorHandling:false,useDeprecatedNextContext:false};const Jt={setTimeout(t,e,...r){const{delegate:i}=Jt;if(i===null||i===void 0?void 0:i.setTimeout){return i.setTimeout(t,e,...r)}return setTimeout(t,e,...r)},clearTimeout(t){const{delegate:e}=Jt;return((e===null||e===void 0?void 0:e.clearTimeout)||clearTimeout)(t)},delegate:undefined};function Qt(t){Jt.setTimeout((()=>{const{onUnhandledError:e}=Zt;if(e){e(t)}else{throw t}}))}function te(){}const ee=(()=>ne("C",undefined,undefined))();function re(t){return ne("E",undefined,t)}function ie(t){return ne("N",t,undefined)}function ne(t,e,r){return{kind:t,value:e,error:r}}let oe=null;function se(t){if(Zt.useDeprecatedSynchronousErrorHandling){const e=!oe;if(e){oe={errorThrown:false,error:null}}t();if(e){const{errorThrown:t,error:e}=oe;oe=null;if(t){throw e}}}else{t()}}class ae extends Ht{constructor(t){super();this.isStopped=false;if(t){this.destination=t;if(Kt(t)){t.add(this)}}else{this.destination=pe}}static create(t,e,r){return new he(t,e,r)}next(t){if(this.isStopped){fe(ie(t),this)}else{this._next(t)}}error(t){if(this.isStopped){fe(re(t),this)}else{this.isStopped=true;this._error(t)}}complete(){if(this.isStopped){fe(ee,this)}else{this.isStopped=true;this._complete()}}unsubscribe(){if(!this.closed){this.isStopped=true;super.unsubscribe();this.destination=null}}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const ce=Function.prototype.bind;function le(t,e){return ce.call(t,e)}class de{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next){try{e.next(t)}catch(t){be(t)}}}error(t){const{partialObserver:e}=this;if(e.error){try{e.error(t)}catch(t){be(t)}}else{be(t)}}complete(){const{partialObserver:t}=this;if(t.complete){try{t.complete()}catch(t){be(t)}}}}class he extends ae{constructor(t,e,r){super();let i;if(Ft(t)||!t){i={next:t!==null&&t!==void 0?t:undefined,error:e!==null&&e!==void 0?e:undefined,complete:r!==null&&r!==void 0?r:undefined}}else{let e;if(this&&Zt.useDeprecatedNextContext){e=Object.create(t);e.unsubscribe=()=>this.unsubscribe();i={next:t.next&&le(t.next,e),error:t.error&&le(t.error,e),complete:t.complete&&le(t.complete,e)}}else{i=t}}this.destination=new de(i)}}function be(t){{Qt(t)}}function ue(t){throw t}function fe(t,e){const{onStoppedNotification:r}=Zt;r&&Jt.setTimeout((()=>r(t,e)))}const pe={closed:true,next:te,error:ue,complete:te};const ge=(()=>typeof Symbol==="function"&&Symbol.observable||"@@observable")();function me(t){return t}function ve(t){if(t.length===0){return me}if(t.length===1){return t[0]}return function e(r){return t.reduce(((t,e)=>e(t)),r)}}class ye{constructor(t){if(t){this._subscribe=t}}lift(t){const e=new ye;e.source=this;e.operator=t;return e}subscribe(t,e,r){const i=xe(t)?t:new he(t,e,r);se((()=>{const{operator:t,source:e}=this;i.add(t?t.call(i,e):e?this._subscribe(i):this._trySubscribe(i))}));return i}_trySubscribe(t){try{return this._subscribe(t)}catch(e){t.error(e)}}forEach(t,e){e=we(e);return new e(((e,r)=>{const i=new he({next:e=>{try{t(e)}catch(t){r(t);i.unsubscribe()}},error:r,complete:e});this.subscribe(i)}))}_subscribe(t){var e;return(e=this.source)===null||e===void 0?void 0:e.subscribe(t)}[ge](){return this}pipe(...t){return ve(t)(this)}toPromise(t){t=we(t);return new t(((t,e)=>{let r;this.subscribe((t=>r=t),(t=>e(t)),(()=>t(r)))}))}}ye.create=t=>new ye(t);function we(t){var e;return(e=t!==null&&t!==void 0?t:Zt.Promise)!==null&&e!==void 0?e:Promise}function ke(t){return t&&Ft(t.next)&&Ft(t.error)&&Ft(t.complete)}function xe(t){return t&&t instanceof ae||ke(t)&&Kt(t)}function ze(t){return Ft(t===null||t===void 0?void 0:t.lift)}function _e(t){return e=>{if(ze(e)){return e.lift((function(e){try{return t(e,this)}catch(t){this.error(t)}}))}throw new TypeError("Unable to lift unknown Observable type")}}function Ce(t,e,r,i,n){return new Se(t,e,r,i,n)}class Se extends ae{constructor(t,e,r,i,n,o){super(t);this.onFinalize=n;this.shouldUnsubscribe=o;this._next=e?function(r){try{e(r)}catch(e){t.error(e)}}:super._next;this._error=i?function(e){try{i(e)}catch(e){t.error(e)}finally{this.unsubscribe()}}:super._error;this._complete=r?function(){try{r()}catch(e){t.error(e)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe();!e&&((t=this.onFinalize)===null||t===void 0?void 0:t.call(this))}}}const je=Nt((t=>function e(){t(this);this.name="ObjectUnsubscribedError";this.message="object unsubscribed"}));class Le extends ye{constructor(){super();this.closed=false;this.currentObservers=null;this.observers=[];this.isStopped=false;this.hasError=false;this.thrownError=null}lift(t){const e=new Xe(this,this);e.operator=t;return e}_throwIfClosed(){if(this.closed){throw new je}}next(t){se((()=>{this._throwIfClosed();if(!this.isStopped){if(!this.currentObservers){this.currentObservers=Array.from(this.observers)}for(const e of this.currentObservers){e.next(t)}}}))}error(t){se((()=>{this._throwIfClosed();if(!this.isStopped){this.hasError=this.isStopped=true;this.thrownError=t;const{observers:e}=this;while(e.length){e.shift().error(t)}}}))}complete(){se((()=>{this._throwIfClosed();if(!this.isStopped){this.isStopped=true;const{observers:t}=this;while(t.length){t.shift().complete()}}}))}unsubscribe(){this.isStopped=this.closed=true;this.observers=this.currentObservers=null}get observed(){var t;return((t=this.observers)===null||t===void 0?void 0:t.length)>0}_trySubscribe(t){this._throwIfClosed();return super._trySubscribe(t)}_subscribe(t){this._throwIfClosed();this._checkFinalizedStatuses(t);return this._innerSubscribe(t)}_innerSubscribe(t){const{hasError:e,isStopped:r,observers:i}=this;if(e||r){return Gt}this.currentObservers=null;i.push(t);return new Ht((()=>{this.currentObservers=null;Vt(i,t)}))}_checkFinalizedStatuses(t){const{hasError:e,thrownError:r,isStopped:i}=this;if(e){t.error(r)}else if(i){t.complete()}}asObservable(){const t=new ye;t.source=this;return t}}Le.create=(t,e)=>new Xe(t,e);class Xe extends Le{constructor(t,e){super();this.destination=t;this.source=e}next(t){var e,r;(r=(e=this.destination)===null||e===void 0?void 0:e.next)===null||r===void 0?void 0:r.call(e,t)}error(t){var e,r;(r=(e=this.destination)===null||e===void 0?void 0:e.error)===null||r===void 0?void 0:r.call(e,t)}complete(){var t,e;(e=(t=this.destination)===null||t===void 0?void 0:t.complete)===null||e===void 0?void 0:e.call(t)}_subscribe(t){var e,r;return(r=(e=this.source)===null||e===void 0?void 0:e.subscribe(t))!==null&&r!==void 0?r:Gt}}function Pe(t,e,r,i){function n(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,o){function s(t){try{c(i.next(t))}catch(t){o(t)}}function a(t){try{c(i["throw"](t))}catch(t){o(t)}}function c(t){t.done?r(t.value):n(t.value).then(s,a)}c((i=i.apply(t,e||[])).next())}))}function Ie(t){var e=typeof Symbol==="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length==="number")return{next:function(){if(t&&i>=t.length)t=void 0;return{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function Te(t){return this instanceof Te?(this.v=t,this):new Te(t)}function Ee(t,e,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i=r.apply(t,e||[]),n,o=[];return n={},s("next"),s("throw"),s("return"),n[Symbol.asyncIterator]=function(){return this},n;function s(t){if(i[t])n[t]=function(e){return new Promise((function(r,i){o.push([t,e,r,i])>1||a(t,e)}))}}function a(t,e){try{c(i[t](e))}catch(t){h(o[0][3],t)}}function c(t){t.value instanceof Te?Promise.resolve(t.value.v).then(l,d):h(o[0][2],t)}function l(t){a("next",t)}function d(t){a("throw",t)}function h(t,e){if(t(e),o.shift(),o.length)a(o[0][0],o[0][1])}}function Oe(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=t[Symbol.asyncIterator],r;return e?e.call(t):(t=typeof Ie==="function"?Ie(t):t[Symbol.iterator](),r={},i("next"),i("throw"),i("return"),r[Symbol.asyncIterator]=function(){return this},r);function i(e){r[e]=t[e]&&function(r){return new Promise((function(i,o){r=t[e](r),n(i,o,r.done,r.value)}))}}function n(t,e,r,i){Promise.resolve(i).then((function(e){t({value:e,done:r})}),e)}}typeof SuppressedError==="function"?SuppressedError:function(t,e,r){var i=new Error(r);return i.name="SuppressedError",i.error=t,i.suppressed=e,i};const Ue=t=>t&&typeof t.length==="number"&&typeof t!=="function";function Ae(t){return Ft(t===null||t===void 0?void 0:t.then)}function De(t){return Ft(t[ge])}function Me(t){return Symbol.asyncIterator&&Ft(t===null||t===void 0?void 0:t[Symbol.asyncIterator])}function Re(t){return new TypeError(`You provided ${t!==null&&typeof t==="object"?"an invalid object":`'${t}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}function $e(){if(typeof Symbol!=="function"||!Symbol.iterator){return"@@iterator"}return Symbol.iterator}const Be=$e();function We(t){return Ft(t===null||t===void 0?void 0:t[Be])}function Fe(t){return Ee(this,arguments,(function*e(){const r=t.getReader();try{while(true){const{value:t,done:e}=yield Te(r.read());if(e){return yield Te(void 0)}yield yield Te(t)}}finally{r.releaseLock()}}))}function Ne(t){return Ft(t===null||t===void 0?void 0:t.getReader)}function qe(t){if(t instanceof ye){return t}if(t!=null){if(De(t)){return Ve(t)}if(Ue(t)){return He(t)}if(Ae(t)){return Ge(t)}if(Me(t)){return Ye(t)}if(We(t)){return Ke(t)}if(Ne(t)){return Ze(t)}}throw Re(t)}function Ve(t){return new ye((e=>{const r=t[ge]();if(Ft(r.subscribe)){return r.subscribe(e)}throw new TypeError("Provided object does not correctly implement Symbol.observable")}))}function He(t){return new ye((e=>{for(let r=0;r<t.length&&!e.closed;r++){e.next(t[r])}e.complete()}))}function Ge(t){return new ye((e=>{t.then((t=>{if(!e.closed){e.next(t);e.complete()}}),(t=>e.error(t))).then(null,Qt)}))}function Ke(t){return new ye((e=>{for(const r of t){e.next(r);if(e.closed){return}}e.complete()}))}function Ye(t){return new ye((e=>{Je(t,e).catch((t=>e.error(t)))}))}function Ze(t){return Ye(Fe(t))}function Je(t,e){var r,i;var n,o;return Pe(this,void 0,void 0,(function*(){try{for(r=Oe(t);i=yield r.next(),!i.done;){const t=i.value;e.next(t);if(e.closed){return}}}catch(t){n={error:t}}finally{try{if(i&&!i.done&&(o=r.return))yield o.call(r)}finally{if(n)throw n.error}}e.complete()}))}function Qe(t){return _e(((e,r)=>{qe(t).subscribe(Ce(r,(()=>r.complete()),te));!r.closed&&e.subscribe(r)}))}const tr=class{constructor(e){t(this,e);this.sessionRestoredEmitter=a(this,"pod-os:session-restored",7);this.restorePreviousSession=false;this.disconnected$=new Le}componentWillLoad(){this.os=Wt();this.os.onSessionRestore((t=>{this.sessionRestoredEmitter.emit({url:t})}));this.os.handleIncomingRedirect(this.restorePreviousSession);this.os.observeSession().pipe(Qe(this.disconnected$)).subscribe((async t=>{S.state.webId=t.webId;if(t.isLoggedIn){const e=await this.os.fetchProfile(t.webId);S.state.profile=e}S.state.isLoggedIn=t.isLoggedIn}))}disconnectedCallback(){this.disconnected$.next();this.disconnected$.unsubscribe()}async initializeOs(t){t.stopPropagation();t.detail(this.os)}async loadModule(t){t.stopPropagation();if(t.detail.module==="contacts"){const e=await this.os.loadContactsModule();t.detail.receiver(e)}else{throw Error(`Unknown module "${t.detail.module}"`)}}render(){return e("slot",{key:"32436fcf8726f4c6b3079f402c296bd3c6cafd04"})}};const er="pos-router{margin:0;padding:0;display:flex;flex-direction:column;height:100%}pos-navigation-bar{max-width:var(--width-lg);margin:0}pos-add-new-thing,pos-login{flex:0 1 auto;}header,footer{display:flex;gap:var(--size-1);height:auto;justify-content:center;align-items:center;padding:var(--size-1)}footer svg{width:var(--size-5);height:var(--size-5)}footer{font-size:var(--scale-fluid-000)}header{flex-wrap:wrap;padding:0 var(--size-8)}main{flex:1;max-height:100vh;overflow:auto}@media (max-width: 640px){header{padding:0 var(--size-1) var(--size-1);justify-content:space-between}pos-navigation-bar{flex-basis:100%;order:0}pos-add-new-thing,pos-login{order:1}}";const rr=er;const ir=class{constructor(e){t(this,e);this.restorePreviousSession=false;this.mode="standalone";this.uri=""}render(){return e(r,{key:"50b6e91f4e98be29cfa37552eb799883aeb49c9e"},e("pos-app",{key:"652617d5eaf3653caeb58b9e93dff09810a587a3",restorePreviousSession:this.restorePreviousSession},e("pos-error-toast",{key:"f4a29b30c2a4caece50c0da046426bc50a3b402e"},e("pos-router",{key:"d3f2307db47406c4d84c9b27ac767d263ae81c32",mode:this.mode,"onPod-os:route-changed":t=>this.uri=t.detail},e("header",{key:"521c8469dae209a27780d62a5922f8a15d393e07"},e("pos-add-new-thing",{key:"2fdd9716da4b3590fb0983a4b50f8c63eca26dce",referenceUri:this.uri}),e("pos-navigation-bar",{key:"6add9651de9ff5ca8496470c0df1341927683001",uri:this.uri==="pod-os:dashboard"?"":this.uri}),e("pos-login",{key:"87a60cc03fc63a2ca68b294726e7e44a09bdc835"})),e("main",{key:"dd2b3de09ca7f8957b240b030cafeeac37e76c1b"},this.uri.startsWith("pod-os:")?e("pos-internal-router",{uri:this.uri}):e("pos-resource",{key:this.uri,uri:this.uri},e("pos-type-router",null))),e("footer",{key:"ea1444713656c8740d81c5ac777b72bb6e287729"},e(nr,{key:"1bba3eec9e30c30f9132a6524e00ec212169f402"}),e("span",{key:"3b38a5e1704559f271075b60a27d8334f41a09dc"},"PodOS Browser"))))))}};const nr=()=>e("svg",{viewBox:"0 0 400 400",xmlns:"http://www.w3.org/2000/svg"},e("path",{d:"M50 350 L50 100 L200 50 L350 100 L350 350 Z",style:{fill:"#008BF8",stroke:"#008BF8","stroke-width":"70"},"stroke-linejoin":"round"}),e("path",{d:"M100 300 L100 150 L200 120 L300 150 L300 300 L130 300 L130 370 L100 370Z",style:{fill:"white",stroke:"white","stroke-width":"45"},"stroke-linejoin":"round"}),e("path",{d:"M150 250 L150 200 L200 180 L250 200 L250 250 Z",style:{fill:"#DC0073",stroke:"#DC0073","stroke-width":"20"},"stroke-linejoin":"round"}));ir.style=rr;const or=":host{display:grid;grid-template-columns:repeat(auto-fit, minmax(var(--size-12), var(--size-96)));gap:var(--size-4);padding:var(--size-2);justify-content:center;align-items:start;justify-items:stretch;height:100%;background:linear-gradient(230deg, rgb(251, 251, 255) 0%, rgb(215, 223, 252) 100%)}";const sr=or;const ar=class{constructor(e){t(this,e)}render(){return e(r,{key:"238188758d52f7a78180d9dcacf52f64d07990c4"},e("pos-getting-started",{key:"da58685fcdbe522a442675d93270fbd553a8c5db"}),e("pos-example-resources",{key:"538845ab6065040e89abb9fdac166f01e5bfa7b4"}))}};ar.style=sr;const cr=class{constructor(e){t(this,e);this.subscribeResource=a(this,"pod-os:resource",7);this.receiveResource=t=>{this.resource=t}}componentWillLoad(){L(this)}render(){return this.resource?this.resource.description():null}};const lr="dialog{background-color:var(--pos-background-color);border:none;border-radius:var(--radius-md);box-shadow:var(--shadow-md);max-width:var(--width-xs)}dialog header>:first-child{flex-grow:1;font-weight:var(--weight-light);font-size:var(--scale-2);font-family:var(--font-sans);margin:0}dialog header{display:flex;flex-direction:row;justify-content:space-between;align-items:center;gap:var(--scale-0);border-bottom-style:inset;padding:0 0 var(--scale-0) 0}dialog>:last-child{display:block;margin-top:var(--scale-3)}button#close{cursor:pointer;display:flex;align-items:center;justify-content:center;border:none;background:none;font-size:var(--scale-3);color:var(--color-grey-500)}button#close:hover{color:var(--color-grey-800)}";const dr=lr;const hr=class{constructor(e){t(this,e)}async showModal(){this.dialog.showModal()}async close(){this.dialog.close()}render(){return e(r,{key:"c225a4ac0e04d0a71fdb0b98c6b2ec8619f465b2"},e("dialog",{key:"ca442886d0651fce3b9b565dba18a6bda30750cd",ref:t=>this.dialog=t},e("header",{key:"5589443a2551bb8ed14870bacdbaaf0b93b0cfe2"},e("slot",{key:"abad20ea1a223ad2229bebcca6c7f3fe09ee4d05",name:"title"}),e("button",{key:"2da0f8dfc03a15c90dc099ee824369564ac12d72",tabindex:-1,id:"close",title:"Close",onClick:()=>this.close()},e("ion-icon",{key:"bab7a9b15ebbec354e84aab7a84ca34a01e62600",name:"close-outline"}))),e("slot",{key:"51978d27aef2308e0b66374087543705f0ac391c",name:"content"})))}};hr.style=dr;const br=class{constructor(e){t(this,e)}async unhandledRejection(t){await this.showToast(t.reason)}async catchError(t){t.stopPropagation();console.error(t.detail);await this.showToast(t.detail.message)}async showToast(t){const e=await X.create({message:t,duration:1e4,position:"top",color:"danger",buttons:[{text:"Dismiss",role:"cancel"}]});await e.present()}render(){return e("slot",{key:"1abf0983dd843eb8b3342ec1fda0e25d02a2df5a"})}};const ur=":host{border:var(--size-px) solid var(--color-grey-100);border-radius:var(--radius-lg);box-shadow:var(--shadow-md);padding:var(--size-8);max-width:var(--size-96);background:var(--color-white)}.links{display:flex;flex-direction:column;gap:var(--size-3);max-width:80vw}";const fr=ur;const pr=class{constructor(e){t(this,e)}render(){return e(r,{key:"85fd8b16422fb57ad1414804d7cc2c86eee39d02"},e("div",{key:"d446af3cc59ce0b9d372a37650618686aa48b8fb"},e("h2",{key:"3000fbd901554640126f7d6880d56d1bef9ed241"},"Try these... 💡"),e("p",{key:"c89defab8e6e2e7a617898f163ed7234249727d2"},"No idea where to start? Try these example resources, and follow your nose 👃"),e("div",{key:"bc9ed67f429ea468c53b591390b7fba1674b0b7d",class:"links"},e("pos-rich-link",{key:"a5fd0f04c539c2654198a0d825fbb2da891e0d14",uri:"https://pod-os.solidcommunity.net/profile/card#me"}),e("pos-rich-link",{key:"0b8dc4abeecbb4cc0f2d8957aa6e43f6877d84d0",uri:"https://angelo.veltens.org/profile/card#me"}),e("pos-rich-link",{key:"628bd8639c706134274ee3c1cd14616664ba9552",uri:"https://angelo.veltens.org/public/bookmarks"}),e("pos-rich-link",{key:"91efe195ccc2567428ea978390a9845d22beda5e",uri:"https://solidos.solidcommunity.net/profile/card#me"}))))}};pr.style=fr;const gr=":host{border:var(--size-px) solid var(--color-grey-100);border-radius:var(--radius-lg);box-shadow:var(--shadow-md);padding:var(--size-8);max-width:var(--size-96);background:var(--color-white)}.question{font-weight:var(--weight-semibold);color:var(--color-grey-900)}a{font-weight:var(--weight-bold);color:var(--pos-primary-color)}";const mr=gr;const vr=class{constructor(e){t(this,e)}render(){return e(r,{key:"2347ea586342456767e9aba2b30debbd86e0b37e"},e("div",{key:"33da44a3cd289b08384b17933c16cef8063a87e2"},e("h2",{key:"7b08c85b665db29d7d0ceaea5bce32b975180300"},"Getting started 🚀"),e("p",{key:"b582fad4e229353edfe5286a417ed544f8a08659"},"🔎 Enter a URL into the above navigation bar to browse through the web of data. "),e("p",{key:"95a42fe1be9e27e03e1bf1beb9a359720dbfef8a"},"🔐 Sign in to access private resources on your Solid Pod or those of your friends or coworkers.")),e("div",{key:"be49077a2032e6208fbfc8c170ec2a4f2151d792"},e("p",{key:"15ebacbf46ab241c0001aa6df011612e27b14657",class:"question"},"New to Solid?"),e("p",{key:"41366fc5e73c5df8b07dc39236d781f9bdb16a2e"},e("a",{key:"35d1572cf1db045759434e3783c02cac98954c91",href:"https://solidproject.org/for-developers#hosted-pod-services"},"Get a Pod →"))),e("div",{key:"2c4a4d8b7f2a0aded70c541f4b511b96150c4fd4"},e("p",{key:"3a1f2bc0640b9c7a553063d4886d22eee41af0f9",class:"question"},"Want to dig deeper into PodOS?"),e("p",{key:"ec76e0f2dd6feff49ecac2d5bc51d27635412bcc"},e("a",{key:"5c49f338c15f0e9941e3929f5a81baa6521bbb1a",href:"http://pod-os.org"},"Learn more →"))))}};vr.style=mr;const yr=":host{display:flex;background-size:cover;background-repeat:no-repeat;background-position:center;border-radius:inherit}img,ion-skeleton-text,div.error{border-radius:var(--border-radius);width:var(--width);height:var(--height);max-width:var(--max-width);max-height:var(--max-height);object-fit:var(--object-fit)}img{backdrop-filter:var(--blur-xl)}.error{display:flex;opacity:0.8;background:repeating-linear-gradient(-45deg, rgba(150, 0, 0, 0.1), rgba(150, 0, 0, 0.1) 10px, #fff 5px, #fff 25px);flex-direction:column;border:1px solid red;color:black;align-items:center;justify-content:center;word-break:break-all;padding:1rem;box-sizing:border-box}.error ion-icon{color:#282828;--ionicon-stroke-width:calc(var(--width) / 5);font-size:calc(var(--width) / 2)}a.error{text-decoration:none;width:var(--width);height:var(--height)}.code{font-weight:bold;font-size:calc(var(--width) / 8)}.text{font-size:calc(var(--width) / 20)}";const wr=yr;const kr=class{constructor(e){t(this,e);this.initializeOsEmitter=a(this,"pod-os:init",7);this.resourceLoadedEmitter=a(this,"pod-os:resource-loaded",7);this.blurredBackground=false;this.loading=true;this.setOs=async t=>{this.os=t}}componentWillLoad(){S.onChange("isLoggedIn",(()=>this.fetchBlob()));this.initializeOsEmitter.emit(this.setOs)}async fetchBlob(){try{this.loading=true;this.imageError=null;this.networkError=null;this.brokenFile=null;const t=await this.os.fetchFile(this.src);this.resourceLoadedEmitter.emit(this.src);if(t.blob()){this.dataUri=URL.createObjectURL(t.blob())}else{this.brokenFile=t}}catch(t){this.networkError=t}finally{this.loading=false}}onImageError(t){this.networkError=null;this.imageError=t}render(){if(this.loading){return e("ion-skeleton-text",{animated:true})}if(this.networkError){return e("img",{alt:this.alt,src:this.src,onError:t=>this.onImageError(t)})}if(this.brokenFile){return e(P,{file:this.brokenFile})}if(this.imageError){return e("div",{class:"error"},e("a",{href:this.src},this.src))}return e(r,{style:{backgroundImage:this.blurredBackground?`url('${this.dataUri}')`:null}},e("img",{src:this.dataUri,alt:this.alt}))}static get watchers(){return{os:["fetchBlob"],src:["fetchBlob"]}}};kr.style=wr;const xr=class{constructor(e){t(this,e);this.uri="pod-os:dashboard"}render(){return e("pos-app-dashboard",{key:"44741d470c91f1faa732c5932788aa58b56805d4"})}};const zr=class{constructor(e){t(this,e);this.subscribeResource=a(this,"pod-os:resource",7);this.receiveResource=t=>{this.resource=t}}componentWillLoad(){L(this)}render(){return this.resource?this.resource.label():null}};const _r=".container{display:flex;align-items:center;gap:var(--size-2)}.user-data{align-items:center;display:inline-flex;gap:10px}.user-data pos-picture{--width:40px;--height:40px;--border-radius:50%}pos-login-form{margin:var(--size-2)}dialog{margin-top:var(--size-10)}button#login,button#logout{outline:none;font-weight:var(--weight-bold);letter-spacing:var(--letter-xl);border:none;box-sizing:border-box;border-radius:var(--radius-xs);padding:var(--size-2);box-shadow:var(--shadow-sm);color:var(--pos-primary-text-color);background-color:var(--pos-primary-color)}button#login:focus-within,button#logout:focus-within{outline:var(--pos-input-focus-outline)}button#login:focus,button#login:hover,button#logout:focus,button#logout:hover{filter:brightness(110%);box-shadow:var(--shadow-md)}";const Cr=_r;const Sr=class{constructor(e){t(this,e);this.initializeOsEmitter=a(this,"pod-os:init",7);this.setOs=async t=>{this.os=t}}componentWillLoad(){this.initializeOsEmitter.emit(this.setOs)}login(t){const e=t.detail;this.os.login(e)}logout(){this.os.logout()}openDialog(){this.dialog.showModal()}render(){return e(r,{key:"ca905c70af384613b128154be4bb68d2956c309e"},e("div",{key:"1f18fe1812658ab7855da328337ef5a9f6145f15",class:"container"},S.state.isLoggedIn?e("pos-resource",{uri:S.state.webId},e("span",{class:"user-data"},e("pos-picture",null),e("pos-label",null))):"",!S.state.isLoggedIn&&e("button",{key:"09264faa5a12b18a805bb13cf92a9a0b190bd498",id:"login",onClick:()=>this.openDialog()},"Login"),S.state.isLoggedIn&&e("button",{key:"334759c36b3df14e59d1bf7a4ae8dd2b03e52c3a",id:"logout",onClick:()=>this.logout()},"Logout")),e("pos-dialog",{key:"e82f36add5bcd044406996639b22e20b54c39101",ref:t=>this.dialog=t},e("span",{key:"e4ea7b9181981e28222f3dffe6ca1cd1fd18cc79",slot:"title"},"Sign in to your Pod"),e("pos-login-form",{key:"5d99a85a1561178a3091ab5f6a23a856c1a373ad","onPod-os:idp-url-selected":t=>this.login(t),slot:"content"})))}};Sr.style=Cr;const jr=":host{display:block;margin:0}form{display:flex;flex-direction:column;gap:var(--size-4)}input{outline:var(--pos-input-outline);padding:var(--scale-000);border:none;border-radius:var(--radius-xs);width:var(--size-full);box-sizing:border-box}input:focus-within{outline:var(--pos-input-focus-outline)}input#login{outline:none;box-shadow:var(--shadow-sm);cursor:pointer;color:var(--pos-primary-text-color);background-color:var(--pos-primary-color)}input#login:disabled{cursor:default;color:var(--pos-disabled-text-color);background-color:var(--pos-disabled-color);box-shadow:none}input#login:hover:not(:disabled),input#login:focus{filter:brightness(110%);box-shadow:var(--shadow-md)}";const Lr=jr;const Xr=class{constructor(e){t(this,e);this.idpUrlSelected=a(this,"pod-os:idp-url-selected",7);this.idpUrl="";this.canSubmit=false}validate(){this.canSubmit=Boolean(this.idpUrl)}render(){return e("form",{key:"fc3dd44c9d9b1b1d793a7527d8a178d819475ee2",method:"dialog",onSubmit:()=>this.handleSubmit()},e("label",{key:"9cbac18a27fa549063c9aa5fce9a9a8bae15bdb1",htmlFor:"idpUrl"},"Please enter your Identity Provider"),e("input",{key:"e211e1210b6259f481562a70d3ca1843137d0c87",id:"idpUrl",type:"url",value:this.idpUrl,required:true,onInput:t=>this.handleChange(t),list:"suggestedIssuers",placeholder:"Type to search..."}),e("datalist",{key:"070952f3ad16c312992fac7be5e497d92819fbb8",id:"suggestedIssuers"},e("option",{key:"d561a03770b7cf496322966f71f6e81c54ab25b0",value:"https://solidcommunity.net"},"solidcommunity.net"),e("option",{key:"3ecf96f60823fd848344fc77871f4bad3645e19c",value:"https://solidweb.org"},"solidweb.org"),e("option",{key:"7c0c4ea6a4d975f9d7dd298e3b38fd8faa41dd2b",value:"https://solidweb.me"},"solidweb.me"),e("option",{key:"21138fe500353ff7624c20226f92c55f5a553551",value:"https://inrupt.net"},"inrupt.net"),e("option",{key:"6b7edede2e1d51aeab5c6fb6f0e7fd4be72db3c5",value:"https://login.inrupt.com"},"Inrupt PodSpaces"),e("option",{key:"c9cea1f3d258a58b0ca260c25111cd6cd6b6bf30",value:"https://trinpod.us"},"trinpod.us"),e("option",{key:"953f68426bdf806c18cbb78fd7de36ee8dae06db",value:"https://use.id"},"use.id"),e("option",{key:"58b3b5e9b3e145e2f2000028d0edd8263d2a6495",value:"https://solid.redpencil.io"},"redpencil.io"),e("option",{key:"2461aaa1b32e07635d67805a362b2f22bf28a8a7",value:"https://datapod.grant.io"},"Data Pod (grant.io)"),e("option",{key:"6ac6645ccd9f3f2234b3f44349f28f34c9f1d33d",value:"https://teamid.live"},"teamid.live")),e("input",{key:"451b150089145ca6846253067e6e6d393b333d9c",id:"login",type:"submit",value:"Login",disabled:!this.canSubmit}))}handleChange(t){this.validate();this.idpUrl=t.target.value}async handleSubmit(){this.idpUrlSelected.emit(this.idpUrl)}static get delegatesFocus(){return true}static get watchers(){return{idpUrl:["validate"]}}};Xr.style=Lr;const Pr=":host {\n}\n\n.suggestions {\n position: relative;\n}\n\n.suggestions ol {\n border: 1px solid var(--color-grey-200);\n display: flex;\n flex-direction: column;\n position: absolute;\n margin: 0;\n padding: 0;\n z-index: var(--layer-top);\n list-style-type: none;\n box-shadow: var(--shadow-xl);\n}\n\n.suggestions {\n li {\n padding: 1rem;\n background-color: white;\n pos-rich-link {\n --background-color: inherit;\n }\n &.selected {\n background-color: var(--color-blue);\n &:hover {\n background-color: var(--color-blue-700);\n }\n }\n &:hover {\n background-color: var(--color-grey-200);\n }\n }\n}\n\n.suggestions li.selected pos-rich-link {\n --label-color: white;\n --description-color: var(--color-grey-200);\n --uri-color: var(--color-grey-200);\n}\n";const Ir=Pr;const Tr=class{constructor(e){t(this,e);this.subscribePodOs=a(this,"pod-os:init",7);this.linkEmitter=a(this,"pod-os:link",7);this.uri="";this.value=this.uri;this.searchIndex=undefined;this.suggestions=[];this.selectedIndex=-1;this.receivePodOs=async t=>{this.os=t}}componentWillLoad(){I(this);S.onChange("isLoggedIn",(async t=>{var e;if(t){this.searchIndex=await this.os.buildSearchIndex(S.state.profile)}else{(e=this.searchIndex)===null||e===void 0?void 0:e.clear()}}))}onChange(t){this.value=t.detail.value;this.search()}clearSuggestions(){this.suggestions=[];this.selectedIndex=-1}onClickSelf(t){t.stopPropagation()}onFocus(){this.search()}handleKeyDown(t){if(t.key==="Escape"){this.clearSuggestions()}else if(t.key==="ArrowDown"){t.preventDefault();this.selectedIndex=Math.min(this.selectedIndex+1,this.suggestions.length-1)}else if(t.key==="ArrowUp"){t.preventDefault();this.selectedIndex=Math.max(this.selectedIndex-1,0)}}search(){if(this.searchIndex){this.suggestions=this.value?this.searchIndex.search(this.value):[]}}onSubmit(t){t.preventDefault();if(this.suggestions&&this.selectedIndex>-1){this.linkEmitter.emit(this.suggestions[this.selectedIndex].ref)}else{this.linkEmitter.emit(this.value)}}render(){return e("form",{key:"a8f6b83f1cf9ec1f11b33ec7431341a7b386cc7d",onSubmit:t=>this.onSubmit(t)},e("ion-searchbar",{key:"2709e144cd8edd34ba45d3dbdfd356df05f93c36",enterkeyhint:"search",placeholder:"Search or enter URI",value:this.uri,debounce:300,onIonChange:t=>this.onChange(t),onIonInput:t=>this.onChange(t)}),this.suggestions.length>0?e("div",{class:"suggestions"},e("ol",null,this.suggestions.map(((t,r)=>e("li",{class:r===this.selectedIndex?"selected":""},e("pos-rich-link",{uri:t.ref})))))):null)}};Tr.style=Ir;const Er=":host{display:block}form{display:grid;grid-template-columns:var(--size-16) 1fr;grid-gap:var(--scale-0)}label{grid-column:1 / 2;display:flex;align-items:center;justify-content:flex-end}input,pos-select-term,button{grid-column:2 / 3}input,pos-select-term::part(input){outline:var(--pos-input-outline);padding:var(--scale-000);border:none;border-radius:var(--radius-xs);width:var(--size-full);box-sizing:border-box}input:focus-within,pos-select-term::part(input):focus-within{outline:var(--pos-input-focus-outline)}#new-uri{grid-column:1/3;cursor:default;word-break:break-all;color:var(--color-grey-800);font-weight:var(--weight-light);background:var(--color-grey-100);padding:var(--scale-000);border-radius:var(--radius-xs)}input#create{outline:none;box-shadow:var(--shadow-sm);cursor:pointer;color:var(--pos-primary-text-color);background-color:var(--pos-primary-color)}input#create:disabled{cursor:default;color:var(--pos-disabled-text-color);background-color:var(--pos-disabled-color);box-shadow:none}input#create:hover:not(:disabled),input#create:focus{filter:brightness(110%);box-shadow:var(--shadow-md)}";const Or=Er;const Ur=class{constructor(e){t(this,e);this.linkEmitter=a(this,"pod-os:link",7);this.errorEmitter=a(this,"pod-os:error",7);this.subscribePodOs=a(this,"pod-os:init",7);this.canSubmit=false;this.receivePodOs=async t=>{this.os=t}}validate(){this.canSubmit=Boolean(this.name&&this.selectedTypeUri)}componentWillLoad(){I(this)}render(){return e("form",{key:"7ac7302d96ebf9f7d746bfb69c17d3b313141b13",method:"dialog",onSubmit:t=>this.handleSubmit(t)},e("label",{key:"a5a5e460537d8ad7e099cf4f61675853abc9b64e",htmlFor:"type"},"Type"),e("pos-select-term",{key:"7dc2d253ceed94825352e6a42e2f53e04ee362d9",id:"type",placeholder:"",value:this.selectedTypeUri,"onPod-os:term-selected":t=>this.onTermSelected(t)}),e("label",{key:"f7d8613857e5c8d6bd3b7060b5fb0c832ee2a62a",htmlFor:"name"},"Name"),e("input",{key:"74c773c31e4c0102b40ca9e34942ccc63f1e4480",id:"name",type:"text",value:this.name,onInput:t=>this.handleChange(t)}),this.newUri?e("div",{id:"new-uri",title:"This will be the URI of the new thing"},this.newUri):null,e("input",{key:"7c99806729314cc7a70268375fb3da5d22c156b1",id:"create",type:"submit",value:"Create",disabled:!this.canSubmit}))}handleChange(t){this.name=t.target.value;this.newUri=this.os.proposeUriForNewThing(this.referenceUri,this.name)}onTermSelected(t){this.selectedTypeUri=t.detail.uri}async handleSubmit(t){try{await this.os.addNewThing(this.newUri,this.name,this.selectedTypeUri);this.linkEmitter.emit(this.newUri);this.reset()}catch(e){t.preventDefault();this.errorEmitter.emit(e)}}reset(){this.name="";this.newUri="";this.selectedTypeUri=""}static get delegatesFocus(){return true}static get watchers(){return{name:["validate"],selectedTypeUri:["validate"]}}};Ur.style=Or;const Ar=":host{--width:300px;--height:300px;--border-radius:var(--border-radius, 0);--object-fit:var(--object-fit, cover)}";const Dr=Ar;const Mr=class{constructor(e){t(this,e);this.subscribeResource=a(this,"pod-os:resource",7);this.blurredBackground=false;this.receiveResource=t=>{this.resource=t}}componentWillLoad(){L(this)}render(){const t=this.resource?this.resource.picture():null;if(!t)return null;return e("pos-image",{blurredBackground:this.blurredBackground,src:t.url,alt:this.resource.label()})}};Mr.style=Dr;const Rr=class{constructor(e){t(this,e);this.subscribePodOs=a(this,"pod-os:init",7);this.resourceLoadedEmitter=a(this,"pod-os:resource-loaded",7);this.consumers=[];this.lazy=false;this.loading=true;this.receivePodOs=async t=>{this.os=t}}componentWillLoad(){S.onChange("isLoggedIn",(()=>this.loadResource()));I(this)}async provideResource(t){t.stopPropagation();if(this.resource){t.detail(this.resource)}this.consumers.push(t)}async loadResource(){await this.getResource(!this.lazy)}async fetch(){await this.getResource(true)}async getResource(t=false){try{if(t){this.loading=true;await this.os.fetch(this.uri);this.resourceLoadedEmitter.emit(this.uri)}this.resource=this.os.store.get(this.uri);this.error=null;this.consumers.forEach((t=>{t.detail(this.resource)}))}catch(t){this.error=t}finally{this.loading=false}}render(){if(this.loading){return e("ion-progress-bar",{type:"indeterminate"})}if(this.error){return e("ion-card",null,e("ion-card-header",null,e("p",null,"Sorry, something went wrong"),e("p",null,"Status:",this.error.status),e("details",null,this.error.message)),e("ion-card-content",null,e("p",null,"You can try to open the link outside PodOS:"),e("a",{href:this.uri},this.uri)))}return e("slot",null)}static get watchers(){return{os:["loadResource"],uri:["loadResource"]}}};const $r=":host {\n --background-color: inherit;\n --label-color: var(--color-grey-900);\n --description-color: var(--color-grey-900);\n --uri-color: var(--color-grey-600);\n --font-family: var(--font-sans);\n}\n\np.content {\n background-color: var(--background-color);\n line-height: var(--line-xs);\n margin: 0;\n display: flex;\n flex-direction: column;\n align-items: baseline;\n gap: var(--size-1);\n\n .url {\n font-size: var(--scale-fluid-1);\n color: var(--color-grey-500);\n }\n}\n\na {\n color: var(--label-color);\n max-width: var(--prose-lg);\n text-decoration: underline;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n text-decoration-thickness: var(--size-px);\n}\n\npos-label {\n color: var(--label-color);\n font-size: var(--scale-fluid-2);\n margin-bottom: var(--size-1);\n}\n\npos-description {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2;\n text-overflow: ellipsis;\n overflow: hidden;\n font-weight: var(--weight-light);\n color: var(--description-color);\n font-size: var(--scale-fluid-2);\n}\n\n@media (min-width: 640px) {\n pos-label {\n font-size: var(--scale-fluid-0);\n }\n pos-description {\n font-size: var(--scale-fluid-1);\n }\n\n p.content {\n .url {\n font-size: var(--scale-fluid-000);\n }\n }\n}\n";const Br=$r;const Wr=class{constructor(e){t(this,e);this.linkEmitter=a(this,"pod-os:link",7)}render(){return e("pos-resource",{key:"f9ee2a2e6403733db429593ccc0900efa39efc9f",lazy:true,uri:this.uri},e("p",{key:"8d8d575619fb66ee28a357c0a1fbcd7e25fd23c3",class:"content"},e("a",{key:"3c517a107acbbd56865172f90a226f77bcfd052c",href:this.uri,onClick:t=>{t.preventDefault();this.linkEmitter.emit(this.uri)}},e("pos-label",{key:"5e9282156f1906e911b045acb032357ca2d83e43"})),e("span",{key:"535ce92376dd686021f597215ecdd3be62e7e1d3",class:"url"},new URL(this.uri).host),e("pos-description",{key:"c5e58b6ced46ffb76fa61c2a917f157dfbaac58f"})))}};Wr.style=Br;const Fr=(t,e,r)=>{const i=t.get(e);if(!i){t.set(e,[r])}else if(!i.includes(r)){i.push(r)}};const Nr=(t,e)=>{let r;return(...i)=>{if(r){clearTimeout(r)}r=setTimeout((()=>{r=0;t(...i)}),e)}};const qr=t=>!("isConnected"in t)||t.isConnected;const Vr=Nr((t=>{for(let e of t.keys()){t.set(e,t.get(e).filter(qr))}}),2e3);const Hr=()=>{if(typeof l!=="function"){return{}}const t=new Map;return{dispose:()=>t.clear(),get:e=>{const r=l();if(r){Fr(t,e,r)}},set:e=>{const r=t.get(e);if(r){t.set(e,r.filter(c))}Vr(t)},reset:()=>{t.forEach((t=>t.forEach(c)));Vr(t)}}};const Gr=(t,e=((t,e)=>t!==e))=>{let r=new Map(Object.entries(t!==null&&t!==void 0?t:{}));const i={dispose:[],get:[],set:[],reset:[]};const n=()=>{r=new Map(Object.entries(t!==null&&t!==void 0?t:{}));i.reset.forEach((t=>t()))};const o=()=>{i.dispose.forEach((t=>t()));n()};const s=t=>{i.get.forEach((e=>e(t)));return r.get(t)};const a=(t,n)=>{const o=r.get(t);if(e(n,o,t)){r.set(t,n);i.set.forEach((e=>e(t,n,o)))}};const c=typeof Proxy==="undefined"?{}:new Proxy(t,{get(t,e){return s(e)},ownKeys(t){return Array.from(r.keys())},getOwnPropertyDescriptor(){return{enumerable:true,configurable:true}},has(t,e){return r.has(e)},set(t,e,r){a(e,r);return true}});const l=(t,e)=>{i[t].push(e);return()=>{Kr(i[t],e)}};const d=(e,r)=>{const i=l("set",((t,i)=>{if(t===e){r(i)}}));const n=l("reset",(()=>r(t[e])));return()=>{i();n()}};const h=(...t)=>{const e=t.reduce(((t,e)=>{if(e.set){t.push(l("set",e.set))}if(e.get){t.push(l("get",e.get))}if(e.reset){t.push(l("reset",e.reset))}if(e.dispose){t.push(l("dispose",e.dispose))}return t}),[]);return()=>e.forEach((t=>t()))};const b=t=>{const e=r.get(t);i.set.forEach((r=>r(t,e,e)))};return{state:c,get:s,set:a,on:l,onChange:d,use:h,dispose:o,reset:n,forceUpdate:b}};const Kr=(t,e)=>{const r=t.indexOf(e);if(r>=0){t[r]=t[t.length-1];t.length--}};const Yr=(t,e)=>{const r=Gr(t,e);r.use(Hr());return r};const Zr=t=>{var e;const r=window;const i=new URL(r.location.href);const n=(e=t===null||t===void 0?void 0:t.parseURL)!==null&&e!==void 0?e:Qr;const{state:o,onChange:s,dispose:a}=Yr({url:i,activePath:n(i)},((t,e,r)=>{if(r==="url"){return t.href!==e.href}return t!==e}));const c=t=>{history.pushState(null,null,t);const e=new URL(t,document.baseURI);o.url=e;o.activePath=n(e)};const l=t=>{const{activePath:e}=o;for(let r of t){const i=Jr(e,r.path);if(i){if(r.to!=null){const i=typeof r.to==="string"?r.to:r.to(e);c(i);return l(t)}else{return{params:i,route:r}}}}return undefined};const d=()=>{const t=new URL(r.location.href);o.url=t;o.activePath=n(t)};const h=(t,e)=>{const r=l(e);if(r){if(typeof r.route.jsx==="function"){return r.route.jsx(r.params)}else{return r.route.jsx}}};const b=()=>{r.removeEventListener("popstate",d);a()};const u={Switch:h,get url(){return o.url},get activePath(){return o.activePath},push:c,onChange:s,dispose:b};d();r.addEventListener("popstate",d);return u};const Jr=(t,e)=>{if(typeof e==="string"){if(e===t){return{}}}else if(typeof e==="function"){const r=e(t);if(r){return r===true?{}:{...r}}}else{const r=e.exec(t);if(r){e.lastIndex=0;return{...r}}}return undefined};const Qr=t=>t.pathname.toLowerCase();const ti=".toolbar{display:flex;flex-direction:row;gap:0;align-items:center;margin-left:0.5rem}pos-navigation-bar{flex-grow:1}";const ei=ti;const ri=Zr();const ii=class{constructor(e){t(this,e);this.routeChanged=a(this,"pod-os:route-changed",7);this.mode="standalone"}linkClicked(t){this.navigate(t.detail)}sessionRestored(t){ri.push(t.detail.url)}componentWillLoad(){this.updateUri();ri.onChange("url",(()=>{this.updateUri()}))}navigate(t){ri.push("?uri="+encodeURIComponent(t))}updateUri(){this.uri=new URLSearchParams(window.location.search).get("uri")||(this.mode==="standalone"?"pod-os:dashboard":window.location.href);this.routeChanged.emit(this.uri)}render(){return e("slot",{key:"972cd1041f376ae50b45691f2ad3ae7f676ff0df"})}};ii.style=ei;const ni=":host{display:block}input{border:none;padding-top:1rem;padding-bottom:1rem}input:focus{outline:none}";const oi=ni;const si=class{constructor(e){t(this,e);this.subscribePodOs=a(this,"pod-os:init",7);this.termSelected=a(this,"pod-os:term-selected",7);this.placeholder="Type to search...";this.value="";this.terms=[];this.receivePodOs=async t=>{this.os=t}}componentWillLoad(){I(this)}setTerms(){this.terms=this.os.listKnownTerms()}handleChange(t){this.termSelected.emit({uri:t.target.value})}render(){return e(r,{key:"7f8d32e361855f6427b2345f706f363b75a58e57"},e("input",{key:"fb979749ed3fedc072a44ab7ef21196ea60bea3b",part:"input",list:"terms",placeholder:this.placeholder,value:this.value,onChange:t=>this.handleChange(t)}),e("datalist",{key:"6a318290e9229aeb83ea827a7a42ca0519609e89",part:"terms",id:"terms"},this.terms.map((t=>e("option",{value:t.uri},t.shorthand)))))}static get delegatesFocus(){return true}static get watchers(){return{os:["setTerms"]}}};si.style=oi;var ai;(function(t){t["Generic"]="pos-app-generic";t["RdfDocument"]="pos-app-rdf-document";t["DocumentViewer"]="pos-app-document-viewer";t["ImageViewer"]="pos-app-image-viewer";t["LdpContainer"]="pos-app-ldp-container"})(ai||(ai={}));function ci(t,e){return t.some((t=>t.uri===e))}function li(t){if(ci(t,"http://www.w3.org/ns/ldp#Container")){return ai.LdpContainer}else if(ci(t,"http://www.w3.org/2007/ont/link#RDFDocument")){return ai.RdfDocument}else if(ci(t,"http://www.w3.org/ns/iana/media-types/application/pdf#Resource")){return ai.DocumentViewer}else if(ci(t,"http://purl.org/dc/terms/Image")){return ai.ImageViewer}else if(ci(t,"http://www.w3.org/2007/ont/link#Document")){return ai.DocumentViewer}else{return ai.Generic}}const di=class{constructor(e){t(this,e);this.subscribeResource=a(this,"pod-os:resource",7);this.receiveResource=t=>{this.types=t.types()}}componentWillLoad(){L(this)}render(){return this.types?this.renderApp():null}renderApp(){const t=li(this.types);return e(t,null)}};export{A as ion_card,B as ion_card_content,V as ion_card_header,ft as ion_icon,kt as ion_progress_bar,St as ion_ripple_effect,Ot as ion_searchbar,Mt as ion_skeleton_text,Bt as pos_add_new_thing,tr as pos_app,ir as pos_app_browser,ar as pos_app_dashboard,cr as pos_description,hr as pos_dialog,br as pos_error_toast,pr as pos_example_resources,vr as pos_getting_started,kr as pos_image,xr as pos_internal_router,zr as pos_label,Sr as pos_login,Xr as pos_login_form,Tr as pos_navigation_bar,Ur as pos_new_thing_form,Mr as pos_picture,Rr as pos_resource,Wr as pos_rich_link,ii as pos_router,si as pos_select_term,di as pos_type_router};
2
- //# sourceMappingURL=p-ddba19aa.entry.js.map
@@ -1,26 +0,0 @@
1
- import { h } from './index-6cbbcaf9.js';
2
-
3
- const BrokenFile = ({ file }) => {
4
- const iconName = iconForStatus(file.status);
5
- return (h("div", null,
6
- h("a", { class: "error", href: file.url },
7
- h("div", null,
8
- h("ion-icon", { name: iconName })),
9
- h("div", { class: "code" }, file.status.code),
10
- h("div", { class: "text" }, file.status.text))));
11
- };
12
- function iconForStatus(status) {
13
- switch (status.code) {
14
- case 401:
15
- case 403:
16
- return 'lock-closed-outline';
17
- case 404:
18
- return 'help-circle-outline';
19
- default:
20
- return 'alert-circle-outline';
21
- }
22
- }
23
-
24
- export { BrokenFile as B };
25
-
26
- //# sourceMappingURL=BrokenFile-47b11850.js.map
@@ -1 +0,0 @@
1
- {"file":"BrokenFile-47b11850.js","mappings":";;MAOa,UAAU,GAAG,CAAC,EAAE,IAAI,EAAS;IACxC,MAAM,QAAQ,GAAG,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;IAC5C,QACE;QACE,SAAG,KAAK,EAAC,OAAO,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG;YAC7B;gBACE,gBAAU,IAAI,EAAE,QAAQ,GAAa,CACjC;YACN,WAAK,KAAK,EAAC,MAAM,IAAE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAO;YAC1C,WAAK,KAAK,EAAC,MAAM,IAAE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAO,CACxC,CACA,EACN;AACJ,EAAE;AAEF,SAAS,aAAa,CAAC,MAAkB;IACvC,QAAQ,MAAM,CAAC,IAAI;QACjB,KAAK,GAAG,CAAC;QACT,KAAK,GAAG;YACN,OAAO,qBAAqB,CAAC;QAC/B,KAAK,GAAG;YACN,OAAO,qBAAqB,CAAC;QAC/B;YACE,OAAO,sBAAsB,CAAC;KACjC;AACH;;;;","names":[],"sources":["src/components/broken-file/BrokenFile.tsx"],"sourcesContent":["import { BrokenFile as BrokenFileData, HttpStatus } from '@pod-os/core';\nimport { h } from '@stencil/core';\n\ninterface Props {\n file: BrokenFileData;\n}\n\nexport const BrokenFile = ({ file }: Props) => {\n const iconName = iconForStatus(file.status);\n return (\n <div>\n <a class=\"error\" href={file.url}>\n <div>\n <ion-icon name={iconName}></ion-icon>\n </div>\n <div class=\"code\">{file.status.code}</div>\n <div class=\"text\">{file.status.text}</div>\n </a>\n </div>\n );\n};\n\nfunction iconForStatus(status: HttpStatus): string {\n switch (status.code) {\n case 401:\n case 403:\n return 'lock-closed-outline';\n case 404:\n return 'help-circle-outline';\n default:\n return 'alert-circle-outline';\n }\n}\n"],"version":3}