@zipify/wysiwyg 1.0.0-dev.74 → 1.0.0-dev.77
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/wysiwyg.mjs +12 -2
- package/lib/Wysiwyg.vue +2 -1
- package/lib/components/base/colorPicker/ColorPicker.vue +1 -0
- package/lib/components/base/composables/useModalToggler.js +1 -0
- package/lib/composables/useToolbar.js +1 -0
- package/lib/index.js +1 -0
- package/lib/utils/index.js +1 -0
- package/lib/utils/isWysiwygContent.js +7 -0
- package/package.json +2 -2
package/dist/wysiwyg.mjs
CHANGED
|
@@ -14391,6 +14391,12 @@ function importIcon(name) {
|
|
|
14391
14391
|
}
|
|
14392
14392
|
return icon;
|
|
14393
14393
|
}
|
|
14394
|
+
function isWysiwygContent(content) {
|
|
14395
|
+
return typeof content === "object" && content.__wswg__;
|
|
14396
|
+
}
|
|
14397
|
+
function markWysiwygContent(content) {
|
|
14398
|
+
return { ...content, __wswg__: true };
|
|
14399
|
+
}
|
|
14394
14400
|
var render$E = function __render__6() {
|
|
14395
14401
|
var _vm = this;
|
|
14396
14402
|
var _h = _vm.$createElement;
|
|
@@ -18963,6 +18969,7 @@ function useModalToggler({ onBeforeOpened, onClosed, wrapperRef, modalRef } = {}
|
|
|
18963
18969
|
const modalEl = useElementRef(modalRef);
|
|
18964
18970
|
popper2 = createPopper(wrapperEl.value, modalEl.value, {
|
|
18965
18971
|
placement: "bottom",
|
|
18972
|
+
strategy: "fixed",
|
|
18966
18973
|
modifiers: [
|
|
18967
18974
|
{
|
|
18968
18975
|
name: "offset",
|
|
@@ -20484,6 +20491,7 @@ var render$q = function __render__20() {
|
|
|
20484
20491
|
ref: "pickerRef",
|
|
20485
20492
|
attrs: {
|
|
20486
20493
|
"placement": "bottom-end",
|
|
20494
|
+
"placement-strategy": "fixed",
|
|
20487
20495
|
"favorite-colors": _vm.favoriteColors,
|
|
20488
20496
|
"window": _vm.window
|
|
20489
20497
|
},
|
|
@@ -22797,6 +22805,7 @@ function useToolbar({ wrapperRef, offsets, isActiveRef }) {
|
|
|
22797
22805
|
function mount(element) {
|
|
22798
22806
|
popper2 = createPopper(wrapperEl.value, element, {
|
|
22799
22807
|
placement: "top-start",
|
|
22808
|
+
strategy: "fixed",
|
|
22800
22809
|
modifiers: [
|
|
22801
22810
|
{
|
|
22802
22811
|
name: "offset",
|
|
@@ -25952,7 +25961,7 @@ const __vue2_script = {
|
|
|
25952
25961
|
});
|
|
25953
25962
|
const updateToolbar = () => toolbar.update();
|
|
25954
25963
|
function onChange(content) {
|
|
25955
|
-
emit("input", content);
|
|
25964
|
+
emit("input", markWysiwygContent(content));
|
|
25956
25965
|
updateToolbar();
|
|
25957
25966
|
}
|
|
25958
25967
|
const pageBlocks = toRef(props, "pageBlocks");
|
|
@@ -26020,5 +26029,6 @@ export {
|
|
|
26020
26029
|
NodeFactory,
|
|
26021
26030
|
NodeTypes,
|
|
26022
26031
|
TextSettings,
|
|
26023
|
-
Wysiwyg
|
|
26032
|
+
Wysiwyg,
|
|
26033
|
+
isWysiwygContent
|
|
26024
26034
|
};
|
package/lib/Wysiwyg.vue
CHANGED
|
@@ -21,6 +21,7 @@ import { ContextWindow, FavoriteColors, Storage } from './services';
|
|
|
21
21
|
import { Devices } from './enums';
|
|
22
22
|
import { outClick } from './directives';
|
|
23
23
|
import { Font } from './models';
|
|
24
|
+
import { markWysiwygContent } from './utils';
|
|
24
25
|
|
|
25
26
|
const MIN_FONT_SIZE = 5;
|
|
26
27
|
const MAX_FONT_SIZE = 112;
|
|
@@ -150,7 +151,7 @@ export default {
|
|
|
150
151
|
const updateToolbar = () => toolbar.update();
|
|
151
152
|
|
|
152
153
|
function onChange(content) {
|
|
153
|
-
emit('input', content);
|
|
154
|
+
emit('input', markWysiwygContent(content));
|
|
154
155
|
updateToolbar();
|
|
155
156
|
}
|
|
156
157
|
|
package/lib/index.js
CHANGED
package/lib/utils/index.js
CHANGED
|
@@ -7,3 +7,4 @@ export { convertLineHeight } from './convertLineHeight';
|
|
|
7
7
|
export { convertFontSize } from './convertFontSize';
|
|
8
8
|
export { convertAlignment } from './convertAlignment';
|
|
9
9
|
export { importIcon } from './importIcon';
|
|
10
|
+
export { isWysiwygContent, markWysiwygContent } from './isWysiwygContent';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zipify/wysiwyg",
|
|
3
|
-
"version": "1.0.0-dev.
|
|
3
|
+
"version": "1.0.0-dev.77",
|
|
4
4
|
"description": "Zipify modification of TipTap text editor",
|
|
5
5
|
"main": "dist/wysiwyg.mjs",
|
|
6
6
|
"repository": {
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"simplebar": "^5.3.8"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {
|
|
46
|
-
"@zipify/colorpicker": "^2.
|
|
46
|
+
"@zipify/colorpicker": "^2.2",
|
|
47
47
|
"vue": "^2.7"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|