@goodfellow-cms/admin 0.8.0 → 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -0
- package/dist/admin-text-sources-BTZJPlVK.js +273 -0
- package/dist/{plugin-protocol-BgYL9WSm.js → custom-font-faces-DJ2AF2oN.js} +75 -7
- package/dist/editor.js +664 -60
- package/dist/entry-values-FcVgwQkJ.js +5005 -0
- package/dist/{es-Dxyy-khR.js → es-ChxY0KVH.js} +429 -480
- package/dist/es-labels-DBu66eln.js +520 -0
- package/dist/index.d.ts +2 -1579
- package/dist/index.js +7403 -3608
- package/dist/plugin.js +7 -2
- package/dist/strings-CWaRN_0v.d.ts +1999 -0
- package/dist/strings-D94noZrv.js +2018 -0
- package/dist/text.d.ts +52 -0
- package/dist/text.js +22 -0
- package/package.json +16 -7
- package/styles.css +533 -0
- package/dist/entry-values-Bu8ljnoX.js +0 -5438
package/dist/plugin.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { _ as mediaUrl, a as showMediaInPreview, n as PLUGIN_READY_MESSAGE, r as createMediaPreviews, s as createChannel, t as installCustomFonts } from "./custom-font-faces-DJ2AF2oN.js";
|
|
2
2
|
import { MEDIA_DIR } from "@goodfellow-cms/core";
|
|
3
3
|
//#region src/plugin.ts
|
|
4
4
|
/**
|
|
@@ -84,7 +84,12 @@ async function openEditor(admin, channel, init, element, api) {
|
|
|
84
84
|
}),
|
|
85
85
|
sharePreview: (root) => channel.call("editor.sharePreview", { root }),
|
|
86
86
|
draw: (block) => channel.call("editor.draw", { block }),
|
|
87
|
-
|
|
87
|
+
fields: (block) => channel.call("editor.fields", { block }),
|
|
88
|
+
styles: async () => {
|
|
89
|
+
const styles = await channel.call("editor.styles");
|
|
90
|
+
installCustomFonts(document, styles.customFonts ?? [], async (url) => await channel.call("media.bytes", url) ?? void 0);
|
|
91
|
+
return styles;
|
|
92
|
+
},
|
|
88
93
|
showsMedia: true
|
|
89
94
|
};
|
|
90
95
|
document.documentElement.classList.add("gfa-plugin-editor");
|