Commit c1754417 by firesong1337

img resizing

parent 21b0191c
...@@ -38,7 +38,6 @@ import IframeModal from './modals/IframeModal' ...@@ -38,7 +38,6 @@ import IframeModal from './modals/IframeModal'
import IframeCustomModal from './modals/IframeCustomModal' import IframeCustomModal from './modals/IframeCustomModal'
import { isMobile } from 'react-device-detect' import { isMobile } from 'react-device-detect'
import Resizable from './extensions/Resizing' import Resizable from './extensions/Resizing'
import { isChangedAlignment } from './extensions/Resizing'
const initialBubbleItems = [ const initialBubbleItems = [
'bold', 'bold',
...@@ -296,8 +295,6 @@ const QEditor = ({ ...@@ -296,8 +295,6 @@ const QEditor = ({
onClick: () => { onClick: () => {
editor.commands.setTextAlign('center') editor.commands.setTextAlign('center')
editor.chain().focus() editor.chain().focus()
isChangedAlignment.set(true)
} }
}, },
alignRight: { alignRight: {
......
import { Extension } from "@tiptap/core"; import { Extension } from "@tiptap/core";
export let isChangedAlignment = {
current: null,
get() {return this.current},
set(value) {this.current = value}
};
// loads with editor // loads with editor
export default Extension.create({ export default Extension.create({
...@@ -136,7 +130,7 @@ export default Extension.create({ ...@@ -136,7 +130,7 @@ export default Extension.create({
if (currentPosition.x === 0) { if (currentPosition.x === 0) {
console.log("changed pos"); console.log("changed pos");
resizeLayer.style.display = "none"; //resizeLayer.style.display = "none";
} }
console.log(entry.target.parentNode) console.log(entry.target.parentNode)
console.log("target: ", entry.target) console.log("target: ", entry.target)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment