@pod-os/elements 0.37.0-rc.c8b54d1.0 → 0.37.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 (144) hide show
  1. package/dist/cjs/{chunk.URTPIBTY-DdK9pL5v.js → chunk.URTPIBTY-DcQsb_nW.js} +2 -2
  2. package/dist/cjs/{chunk.XQ2OKYYA-DEkhm1i7.js → chunk.XQ2OKYYA-D224sdKt.js} +3 -3
  3. package/dist/cjs/{chunk.ZGGPD2XJ-uKZZdqOH.js → chunk.ZGGPD2XJ-Cj6xUx2M.js} +1 -1
  4. package/dist/cjs/{class-map-DAZXfKKA.js → class-map-Nx8L8ElN.js} +1 -1
  5. package/dist/cjs/elements.cjs.js +3 -3
  6. package/dist/cjs/{index-DCpu_nnH.js → index-Be_lnf0w.js} +547 -2001
  7. package/dist/cjs/{index-FUnpyb19.js → index-OR1wNkjG.js} +1052 -489
  8. package/dist/cjs/{jsonld-V2RB47OZ-BerQ9IRa.js → jsonld-V2RB47OZ-B82QNsYZ.js} +1 -1
  9. package/dist/cjs/loader.cjs.js +2 -2
  10. package/dist/cjs/pos-add-literal-value_3.cjs.entry.js +6 -6
  11. package/dist/cjs/{pos-add-new-thing_31.cjs.entry.js → pos-add-new-thing_32.cjs.entry.js} +411 -227
  12. package/dist/cjs/pos-app-document-viewer.cjs.entry.js +1 -1
  13. package/dist/cjs/pos-app-generic.cjs.entry.js +1 -1
  14. package/dist/cjs/pos-app-image-viewer.cjs.entry.js +1 -1
  15. package/dist/cjs/pos-app-ldp-container.cjs.entry.js +1 -1
  16. package/dist/cjs/pos-app-rdf-document.cjs.entry.js +1 -1
  17. package/dist/cjs/pos-attachments.cjs.entry.js +2 -2
  18. package/dist/cjs/pos-case.cjs.entry.js +24 -0
  19. package/dist/cjs/pos-container-contents.cjs.entry.js +13 -4
  20. package/dist/cjs/pos-container-item_3.cjs.entry.js +4 -4
  21. package/dist/cjs/pos-document.cjs.entry.js +4 -4
  22. package/dist/cjs/pos-list.cjs.entry.js +1 -1
  23. package/dist/cjs/pos-markdown-document.cjs.entry.js +442 -2327
  24. package/dist/cjs/pos-relations_2.cjs.entry.js +1 -1
  25. package/dist/cjs/pos-subjects.cjs.entry.js +2 -2
  26. package/dist/cjs/pos-switch.cjs.entry.js +64 -0
  27. package/dist/cjs/pos-tool-attachments.cjs.entry.js +2 -2
  28. package/dist/cjs/pos-value.cjs.entry.js +1 -1
  29. package/dist/collection/collection-manifest.json +5 -1
  30. package/dist/collection/components/pos-app/pos-app.js +2 -1
  31. package/dist/collection/components/pos-attachments/pos-attachments.js +2 -1
  32. package/dist/collection/components/pos-container-contents/pos-container-contents.js +10 -1
  33. package/dist/collection/components/pos-container-contents/pos-create-new-container-item/pos-create-new-container-item.js +4 -2
  34. package/dist/collection/components/pos-markdown-document/pos-markdown-document.js +2 -1
  35. package/dist/collection/components/pos-navigation/bar/pos-navigation-bar.css +42 -22
  36. package/dist/collection/components/pos-navigation/bar/pos-navigation-bar.js +3 -2
  37. package/dist/collection/components/pos-new-thing-form/pos-new-thing-form.js +1 -1
  38. package/dist/collection/components/pos-router/pos-router.js +1 -1
  39. package/dist/collection/components/pos-select-term/pos-select-term.js +1 -1
  40. package/dist/collection/components/pos-share/openNewTab.js +3 -0
  41. package/dist/collection/components/pos-share/pos-share.css +36 -0
  42. package/dist/collection/components/pos-share/pos-share.js +111 -0
  43. package/dist/collection/components/pos-switch/pos-case/pos-case.js +88 -0
  44. package/dist/collection/components/pos-switch/pos-switch.js +89 -0
  45. package/dist/collection/components/pos-tool-select/pos-tool-select.js +6 -3
  46. package/dist/collection/components/pos-upload/pos-upload.js +7 -4
  47. package/dist/collection/components/pos-user-menu/pos-user-menu.js +1 -1
  48. package/dist/collection/tools/pos-tool-attachments/pos-tool-attachments.js +1 -1
  49. package/dist/components/chunk.IVVHNXMC.js +20 -0
  50. package/dist/components/index.js +1 -1
  51. package/dist/components/index2.js +2 -2
  52. package/dist/components/pos-add-literal-value2.js +1 -1
  53. package/dist/components/pos-app-browser.js +1 -1
  54. package/dist/components/pos-attachments2.js +1 -1
  55. package/dist/components/pos-case.d.ts +11 -0
  56. package/dist/components/pos-case.js +1 -0
  57. package/dist/components/pos-container-contents2.js +1 -1
  58. package/dist/components/pos-make-findable2.js +1 -1
  59. package/dist/components/pos-markdown-document2.js +1 -1
  60. package/dist/components/pos-navigation-bar2.js +1 -1
  61. package/dist/components/pos-navigation2.js +1 -1
  62. package/dist/components/pos-new-thing-form2.js +1 -1
  63. package/dist/components/pos-router2.js +1 -1
  64. package/dist/components/pos-select-term2.js +1 -1
  65. package/dist/components/pos-share.d.ts +11 -0
  66. package/dist/components/pos-share.js +1 -0
  67. package/dist/components/pos-share2.js +1 -0
  68. package/dist/components/pos-switch.d.ts +11 -0
  69. package/dist/components/pos-switch.js +1 -0
  70. package/dist/components/pos-tool-attachments.js +1 -1
  71. package/dist/components/pos-tool-select2.js +1 -1
  72. package/dist/components/pos-type-index-entries2.js +1 -1
  73. package/dist/components/pos-upload2.js +12 -3
  74. package/dist/components/pos-user-menu2.js +6 -25
  75. package/dist/elements/elements.esm.js +1 -1
  76. package/dist/elements/{p-6561f1b7.entry.js → p-03464a71.entry.js} +1 -1
  77. package/dist/elements/{p-52a612ed.entry.js → p-272209e3.entry.js} +1 -1
  78. package/dist/elements/{p-a9a18aa8.entry.js → p-38aa17bc.entry.js} +1 -1
  79. package/dist/elements/p-3a890f5f.entry.js +1 -0
  80. package/dist/elements/{p-9ad80b52.entry.js → p-4cd2f9da.entry.js} +1 -1
  81. package/dist/elements/{p-0e7413e6.entry.js → p-5126fb6e.entry.js} +1 -1
  82. package/dist/elements/p-53610ccd.entry.js +1 -0
  83. package/dist/elements/{p-b5d64c6f.entry.js → p-631976a8.entry.js} +1 -1
  84. package/dist/elements/{p-fe628201.entry.js → p-6d628d74.entry.js} +1 -1
  85. package/dist/elements/{p-b363349c.entry.js → p-7c3785d8.entry.js} +1 -1
  86. package/dist/elements/p-8934c5ea.entry.js +1 -0
  87. package/dist/elements/p-8e76e9dc.entry.js +1 -0
  88. package/dist/elements/{p-3e18b5dd.entry.js → p-9bf6c310.entry.js} +1 -1
  89. package/dist/elements/{p-Doy_38_j.js → p-BLUiM5OK.js} +1 -1
  90. package/dist/elements/{p-BkAnMOpW.js → p-CSTMd_cW.js} +2 -2
  91. package/dist/elements/{p-CrxYqX8r.js → p-CVwgVrbO.js} +7 -7
  92. package/dist/elements/{p-8ggjG2YF.js → p-CnIOZlf7.js} +1 -1
  93. package/dist/elements/p-DHl0QGLf.js +67 -0
  94. package/dist/elements/p-DzbCx-pP.js +2 -0
  95. package/dist/elements/{p-c8ee910c.entry.js → p-a1dd6b42.entry.js} +1 -1
  96. package/dist/elements/p-ab4eba43.entry.js +859 -0
  97. package/dist/elements/{p-dff14248.entry.js → p-c7032012.entry.js} +1 -1
  98. package/dist/elements/{p-a20b72d8.entry.js → p-d396cc56.entry.js} +1 -1
  99. package/dist/elements/p-dc4c38c8.entry.js +1 -0
  100. package/dist/elements/{p-0a087865.entry.js → p-e0660718.entry.js} +1 -1
  101. package/dist/elements/{p-8q-RA2Uq.js → p-mIPOXLnA.js} +3 -3
  102. package/dist/esm/{chunk.URTPIBTY-CNA3-SLq.js → chunk.URTPIBTY-yxgfEQ1K.js} +2 -2
  103. package/dist/esm/{chunk.XQ2OKYYA-CXNlpYUG.js → chunk.XQ2OKYYA-Cr3bMzqn.js} +3 -3
  104. package/dist/esm/{chunk.ZGGPD2XJ-BjT6fS1o.js → chunk.ZGGPD2XJ-SJISSXOc.js} +1 -1
  105. package/dist/esm/{class-map-CUYFUkXU.js → class-map-DEweE_Cr.js} +1 -1
  106. package/dist/esm/elements.js +4 -4
  107. package/dist/esm/{index-DFqG64hG.js → index-CXK32bJz.js} +1052 -489
  108. package/dist/esm/{index-VMHzF3uY.js → index-DzbCx-pP.js} +547 -2001
  109. package/dist/esm/{jsonld-V2RB47OZ-CaIJ08AA.js → jsonld-V2RB47OZ-BbN7F0s8.js} +1 -1
  110. package/dist/esm/loader.js +3 -3
  111. package/dist/esm/pos-add-literal-value_3.entry.js +6 -6
  112. package/dist/esm/{pos-add-new-thing_31.entry.js → pos-add-new-thing_32.entry.js} +411 -228
  113. package/dist/esm/pos-app-document-viewer.entry.js +1 -1
  114. package/dist/esm/pos-app-generic.entry.js +1 -1
  115. package/dist/esm/pos-app-image-viewer.entry.js +1 -1
  116. package/dist/esm/pos-app-ldp-container.entry.js +1 -1
  117. package/dist/esm/pos-app-rdf-document.entry.js +1 -1
  118. package/dist/esm/pos-attachments.entry.js +2 -2
  119. package/dist/esm/pos-case.entry.js +22 -0
  120. package/dist/esm/pos-container-contents.entry.js +12 -3
  121. package/dist/esm/pos-container-item_3.entry.js +4 -4
  122. package/dist/esm/pos-document.entry.js +4 -4
  123. package/dist/esm/pos-list.entry.js +1 -1
  124. package/dist/esm/pos-markdown-document.entry.js +442 -2327
  125. package/dist/esm/pos-relations_2.entry.js +1 -1
  126. package/dist/esm/pos-subjects.entry.js +2 -2
  127. package/dist/esm/pos-switch.entry.js +62 -0
  128. package/dist/esm/pos-tool-attachments.entry.js +2 -2
  129. package/dist/esm/pos-value.entry.js +1 -1
  130. package/dist/jest-setup.js +4 -0
  131. package/dist/types/components/pos-container-contents/pos-container-contents.d.ts +2 -0
  132. package/dist/types/components/pos-share/openNewTab.d.ts +1 -0
  133. package/dist/types/components/pos-share/pos-share.d.ts +28 -0
  134. package/dist/types/components/pos-switch/pos-case/pos-case.d.ts +22 -0
  135. package/dist/types/components/pos-switch/pos-switch.d.ts +19 -0
  136. package/dist/types/components.d.ts +300 -74
  137. package/dist/types/stencil-public-runtime.d.ts +52 -2
  138. package/package.json +13 -12
  139. package/dist/elements/p-637a38d9.entry.js +0 -1
  140. package/dist/elements/p-701f2c84.entry.js +0 -850
  141. package/dist/elements/p-9b74c400.entry.js +0 -1
  142. package/dist/elements/p-LoCE14bN.js +0 -67
  143. package/dist/elements/p-VMHzF3uY.js +0 -2
  144. package/dist/elements/p-ac17ed6a.entry.js +0 -1
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, c as createEvent, h, e as Host } from './index-VMHzF3uY.js';
1
+ import { r as registerInstance, c as createEvent, h, H as Host } from './index-DzbCx-pP.js';
2
2
  import { s as subscribeResource } from './ResourceAware-BW_CkW1K.js';
3
3
 
4
4
  const defaultAppLayoutCss = () => `:host{--gap-size:var(--size-1);display:flex;flex-direction:column;gap:var(--gap-size);margin:var(--gap-size)}section{display:flex;flex-direction:column;gap:var(--gap-size)}@media (min-width: 640px){:host{--gap-size:var(--size-4);flex-direction:row;flex-wrap:wrap;section{&:first-of-type{flex:1}}section:not(:first-of-type){flex:0 0 30%}}}`;
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h, e as Host } from './index-VMHzF3uY.js';
1
+ import { r as registerInstance, h, H as Host } from './index-DzbCx-pP.js';
2
2
 
3
3
  const posAppGenericCss = () => `:host{--gap-size:var(--size-1);display:flex;flex-direction:column;gap:var(--gap-size);margin:var(--gap-size)}article{outline:var(--pos-border-solid);border-radius:var(--radius-sm);box-shadow:var(--shadow-md);background-color:var(--pos-card-background);header{display:flex;flex-direction:column;pos-picture{--object-fit:contain;--width:100%;--height:auto;--max-height:300px;border-radius:var(--radius-sm) var(--radius-sm) 0 0;--border-radius:var(--radius-sm) var(--radius-sm) 0 0}h1,pos-type-badges{margin:var(--size-2)}}main{padding:var(--size-2);pos-description{color:var(--pos-secondary-text-color);font-weight:var(--weight-light)}}}@media (min-width: 640px){:host{flex-direction:row;flex-wrap:wrap;section:first-of-type{flex:0 0 25%}section:not(:first-of-type){flex:1}}}`;
4
4
 
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, c as createEvent, h, e as Host } from './index-VMHzF3uY.js';
1
+ import { r as registerInstance, c as createEvent, h, H as Host } from './index-DzbCx-pP.js';
2
2
  import { s as subscribeResource } from './ResourceAware-BW_CkW1K.js';
3
3
 
4
4
  const posAppImageViewerCss = () => `pos-image{--max-width:100%}`;
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h, e as Host } from './index-VMHzF3uY.js';
1
+ import { r as registerInstance, h, H as Host } from './index-DzbCx-pP.js';
2
2
 
3
3
  const defaultAppLayoutCss = () => `:host{--gap-size:var(--size-1);display:flex;flex-direction:column;gap:var(--gap-size);margin:var(--gap-size)}section{display:flex;flex-direction:column;gap:var(--gap-size)}@media (min-width: 640px){:host{--gap-size:var(--size-4);flex-direction:row;flex-wrap:wrap;section{&:first-of-type{flex:1}}section:not(:first-of-type){flex:0 0 30%}}}`;
4
4
 
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h, e as Host } from './index-VMHzF3uY.js';
1
+ import { r as registerInstance, h, H as Host } from './index-DzbCx-pP.js';
2
2
 
3
3
  const defaultAppLayoutCss = () => `:host{--gap-size:var(--size-1);display:flex;flex-direction:column;gap:var(--gap-size);margin:var(--gap-size)}section{display:flex;flex-direction:column;gap:var(--gap-size)}@media (min-width: 640px){:host{--gap-size:var(--size-4);flex-direction:row;flex-wrap:wrap;section{&:first-of-type{flex:1}}section:not(:first-of-type){flex:0 0 30%}}}`;
4
4
 
@@ -1,7 +1,7 @@
1
- import { r as registerInstance, h, e as Host, a as getElement } from './index-VMHzF3uY.js';
1
+ import { r as registerInstance, h, H as Host, a as getElement } from './index-DzbCx-pP.js';
2
2
  import { u as useResource } from './useResource-yVO4JQ9P.js';
3
3
 
4
- const posAttachmentsCss = () => `:host{--background-base-color:color-mix(in srgb, var(--pos-background-color), var(--color-grey-800) 10%);--background-color-even:hsl(from var(--background-base-color) h s calc(l + 7));--background-color-odd:hsl(from var(--background-base-color) h s calc(l + 10));--border-color:var(--background-base-color);ul{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:var(--size-1);li{padding:var(--size-1);&:nth-child(even){background-color:var(--background-color-even)}&:nth-child(odd){background-color:var(--background-color-odd)}&.new{animation:newItemBounce 0.8s ease-out,\\n highlightFlash 2.5s ease-in-out}}}}@keyframes newItemBounce{0%{transform:scale(0.95);opacity:0}60%{transform:scale(1.02)}100%{transform:scale(1);opacity:1}}@keyframes highlightFlash{0%{box-shadow:0 0 20px var(--pos-primary-color)}100%{box-shadow:0 0 0 transparent}}`;
4
+ const posAttachmentsCss = () => `:host{--background-base-color:color-mix(in srgb, var(--pos-background-color), var(--color-grey-800) 10%);--background-color-even:hsl(from var(--background-base-color) h s calc(l + 7));--background-color-odd:hsl(from var(--background-base-color) h s calc(l + 10));--border-color:var(--background-base-color);ul{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:var(--size-1);li{padding:var(--size-1);&:nth-child(even){background-color:var(--background-color-even)}&:nth-child(odd){background-color:var(--background-color-odd)}&.new{animation:newItemBounce 0.8s ease-out, highlightFlash 2.5s ease-in-out}}}}@keyframes newItemBounce{0%{transform:scale(0.95);opacity:0}60%{transform:scale(1.02)}100%{transform:scale(1);opacity:1}}@keyframes highlightFlash{0%{box-shadow:0 0 20px var(--pos-primary-color)}100%{box-shadow:0 0 0 transparent}}`;
5
5
 
6
6
  const PosAttachments = class {
7
7
  constructor(hostRef) {
@@ -0,0 +1,22 @@
1
+ import { r as registerInstance, a as getElement } from './index-DzbCx-pP.js';
2
+
3
+ const PosCase = class {
4
+ constructor(hostRef) {
5
+ registerInstance(this, hostRef);
6
+ this.error = null;
7
+ }
8
+ componentWillLoad() {
9
+ const templateElement = this.host.querySelector('template');
10
+ if (templateElement == null) {
11
+ this.error = 'No template element found';
12
+ }
13
+ }
14
+ render() {
15
+ if (this.error)
16
+ return this.error;
17
+ return null;
18
+ }
19
+ get host() { return getElement(this); }
20
+ };
21
+
22
+ export { PosCase as pos_case };
@@ -1,6 +1,7 @@
1
- import { r as registerInstance, c as createEvent, h, e as Host } from './index-VMHzF3uY.js';
2
- import { L as LdpContainer } from './index-DFqG64hG.js';
1
+ import { r as registerInstance, c as createEvent, h, H as Host } from './index-DzbCx-pP.js';
2
+ import { L as LdpContainer } from './index-CXK32bJz.js';
3
3
  import { s as subscribeResource } from './ResourceAware-BW_CkW1K.js';
4
+ import { c as cjsExports } from './index-vFMstSdt.js';
4
5
 
5
6
  const posContainerContentsCss = () => `ul{list-style:none;padding:0;margin:0}li{padding:0;margin:0}`;
6
7
 
@@ -11,10 +12,14 @@ const PosContainerContents = class {
11
12
  this.contents = [];
12
13
  this.loading = true;
13
14
  this.createNewItem = null;
15
+ this.disconnected$ = new cjsExports.Subject();
14
16
  this.receiveResource = (resource) => {
15
17
  this.container = resource.assume(LdpContainer);
16
18
  this.loading = false;
17
- this.contents = this.container.contains().sort((a, b) => a.name.localeCompare(b.name));
19
+ this.container
20
+ .observeContains()
21
+ .pipe(cjsExports.takeUntil(this.disconnected$))
22
+ .subscribe(contains => (this.contents = contains.sort((a, b) => a.name.localeCompare(b.name))));
18
23
  };
19
24
  }
20
25
  onCreateNewFile() {
@@ -40,6 +45,10 @@ const PosContainerContents = class {
40
45
  }
41
46
  return (h(Host, null, h("pos-container-toolbar", { "onPod-os:create-new-file": () => this.onCreateNewFile(), "onPod-os:create-new-folder": () => this.onCreateNewFolder() }), items.length > 0 ? h("ul", { "aria-label": "Container contents" }, items) : h("p", null, "The container is empty")));
42
47
  }
48
+ disconnectedCallback() {
49
+ this.disconnected$.next();
50
+ this.disconnected$.unsubscribe();
51
+ }
43
52
  };
44
53
  PosContainerContents.style = posContainerContentsCss();
45
54
 
@@ -1,9 +1,9 @@
1
- import { r as registerInstance, c as createEvent, h, e as Host, a as getElement } from './index-VMHzF3uY.js';
1
+ import { r as registerInstance, c as createEvent, h, H as Host, a as getElement } from './index-DzbCx-pP.js';
2
2
  import { s as subscribeResource } from './ResourceAware-BW_CkW1K.js';
3
- import './chunk.ZGGPD2XJ-BjT6fS1o.js';
4
- import './chunk.URTPIBTY-CNA3-SLq.js';
3
+ import './chunk.ZGGPD2XJ-SJISSXOc.js';
4
+ import './chunk.URTPIBTY-yxgfEQ1K.js';
5
5
  import { u as usePodOS } from './usePodOS-D0uCfr1-.js';
6
- import './class-map-CUYFUkXU.js';
6
+ import './class-map-DEweE_Cr.js';
7
7
 
8
8
  function selectIconForTypes(types) {
9
9
  if (containsType(types, 'http://www.w3.org/ns/ldp#Container')) {
@@ -1,7 +1,7 @@
1
- import { r as registerInstance, c as createEvent, h } from './index-VMHzF3uY.js';
2
- import { s as store, B as BrokenFile } from './chunk.XQ2OKYYA-CXNlpYUG.js';
3
- import './chunk.ZGGPD2XJ-BjT6fS1o.js';
4
- import './class-map-CUYFUkXU.js';
1
+ import { r as registerInstance, c as createEvent, h } from './index-DzbCx-pP.js';
2
+ import { s as store, B as BrokenFile } from './chunk.XQ2OKYYA-Cr3bMzqn.js';
3
+ import './chunk.ZGGPD2XJ-SJISSXOc.js';
4
+ import './class-map-DEweE_Cr.js';
5
5
 
6
6
  const posDocumentCss = () => `iframe{background-color:var(--pos-background-color);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{color:#282828;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)}.skeleton{display:flex;gap:var(--size-2);flex-direction:column;sl-skeleton{&:nth-child(2){width:95%}&:nth-child(4){width:90%}&:last-child{width:50%}}}`;
7
7
 
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, c as createEvent, h, a as getElement } from './index-VMHzF3uY.js';
1
+ import { r as registerInstance, c as createEvent, h, a as getElement } from './index-DzbCx-pP.js';
2
2
  import { s as subscribeResource } from './ResourceAware-BW_CkW1K.js';
3
3
  import { s as subscribePodOs } from './PodOsAware-jlzl8vRd.js';
4
4
  import { c as cjsExports } from './index-vFMstSdt.js';