maerkchen 1.0.1 → 1.0.3
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/dist/main.d.ts +2 -2
- package/dist/main.js +3 -3
- package/package.json +1 -1
package/dist/main.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { MaerkchenEditor } from './maerkchen-editor';
|
|
2
|
-
import { parse_markdown, sanitize_html } from 'wasm-md';
|
|
3
|
-
export { MaerkchenEditor, parse_markdown, sanitize_html };
|
|
2
|
+
import { parse_markdown, sanitize_html, default as init } from 'wasm-md';
|
|
3
|
+
export { MaerkchenEditor, parse_markdown, sanitize_html, init };
|
package/dist/main.js
CHANGED
|
@@ -123,7 +123,7 @@ var _ = class extends HTMLElement {
|
|
|
123
123
|
return this._markdownText;
|
|
124
124
|
}
|
|
125
125
|
set markdownText(e) {
|
|
126
|
-
this._markdownText = e, this.updatePreview();
|
|
126
|
+
this._markdownText = e, this.setAttribute("markdownText", e), this.updatePreview(), this.dispatchEvent(new Event("change"));
|
|
127
127
|
}
|
|
128
128
|
get label() {
|
|
129
129
|
return this._label;
|
|
@@ -153,7 +153,7 @@ var _ = class extends HTMLElement {
|
|
|
153
153
|
super();
|
|
154
154
|
}
|
|
155
155
|
async connectedCallback() {
|
|
156
|
-
await g(), this.markdownText = this.getAttribute("markdownText") ?? "";
|
|
156
|
+
await g(), this.markdownText = this.markdownText ? this.markdownText : this.getAttribute("markdownText") ?? "";
|
|
157
157
|
let t = this.attachShadow({ mode: "open" });
|
|
158
158
|
t.innerHTML = `
|
|
159
159
|
<div class="maerkchen-editor">
|
|
@@ -325,4 +325,4 @@ var _ = class extends HTMLElement {
|
|
|
325
325
|
};
|
|
326
326
|
customElements.define("maerkchen-editor", _);
|
|
327
327
|
//#endregion
|
|
328
|
-
export { _ as MaerkchenEditor, e as parse_markdown, t as sanitize_html };
|
|
328
|
+
export { _ as MaerkchenEditor, g as init, e as parse_markdown, t as sanitize_html };
|