@opencloud-eu/web-pkg 3.1.0 → 4.0.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.
@@ -1,5 +1,5 @@
1
- import { d as L, u as w, c as r, a as n, _ as v, r as g, b as z, o as s, e as h } from "./index-Djg6Ri2D.js";
2
- import { MdPreview as P, MdEditor as y, config as C, XSSPlugin as I } from "md-editor-v3";
1
+ import { d as L, u as w, c as r, a as n, _ as v, r as g, b as y, o as s, e as h } from "./index-Ctidv9Qe.js";
2
+ import { MdPreview as z, MdEditor as P, config as C, XSSPlugin as I } from "md-editor-v3";
3
3
  import { useGettext as D } from "vue3-gettext";
4
4
  import "@casl/vue";
5
5
  import "@opencloud-eu/web-client";
@@ -16,7 +16,7 @@ import "password-sheriff";
16
16
  import "@uppy/core";
17
17
  import "@uppy/tus";
18
18
  import "@uppy/xhr-upload";
19
- import "@uppy/drop-target";
19
+ import "@uppy/utils";
20
20
  import "pinia";
21
21
  import "oidc-client-ts";
22
22
  import "p-queue";
@@ -691,7 +691,7 @@ const R = {
691
691
  }, B = L({
692
692
  name: "TextEditor",
693
693
  // type casts are needed to ensure type inference works correctly when building web-pkg
694
- components: { MdEditor: y, MdPreview: P },
694
+ components: { MdEditor: P, MdPreview: z },
695
695
  props: {
696
696
  applicationConfig: { type: Object, required: !1 },
697
697
  currentContent: {
@@ -707,10 +707,7 @@ const R = {
707
707
  const d = D(), { currentTheme: u } = w(), m = r(() => {
708
708
  const { showPreviewOnlyMd: a = !0 } = e.applicationConfig;
709
709
  return { showPreviewOnlyMd: a };
710
- }), c = r(() => {
711
- var a;
712
- return e.markdownMode || ["md", "markdown"].includes((a = e.resource) == null ? void 0 : a.extension) || !n(m).showPreviewOnlyMd;
713
- }), o = r(() => n(u).isDark ? "dark" : "light");
710
+ }), c = r(() => e.markdownMode || ["md", "markdown"].includes(e.resource?.extension) || !n(m).showPreviewOnlyMd), o = r(() => n(u).isDark ? "dark" : "light");
714
711
  return C({
715
712
  editorConfig: {
716
713
  languageUserDefined: O
@@ -757,11 +754,11 @@ ${b.join(`
757
754
  }
758
755
  }), K = {
759
756
  id: "text-editor-container",
760
- class: "oc-height-1-1"
757
+ class: "h-full [&_.md-editor-preview]:!font-(family-name:--oc-font-family)"
761
758
  };
762
759
  function G(e, i, d, u, m, c) {
763
760
  const o = g("md-preview"), p = g("md-editor");
764
- return s(), z("div", K, [
761
+ return s(), y("div", K, [
765
762
  e.isReadOnly ? (s(), h(o, {
766
763
  key: 0,
767
764
  id: "text-editor-preview-component",
@@ -779,6 +776,7 @@ function G(e, i, d, u, m, c) {
779
776
  }, null, 8, ["model-value", "language", "theme"])) : (s(), h(p, {
780
777
  key: 1,
781
778
  id: "text-editor-component",
779
+ class: "[&_.cm-content]:!font-(family-name:--oc-font-family)",
782
780
  "model-value": e.currentContent,
783
781
  "no-katex": "",
784
782
  "no-mermaid": "",