-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WC-2835]: RTE implementation of Quill-Table-Better #1506
base: main
Are you sure you want to change the base?
Conversation
a42830a
to
3a4ce62
Compare
3a4ce62
to
8b801ae
Compare
leftIcon.setAttribute("src", left); | ||
dropDown.appendChild(leftIcon); | ||
if (isDropDown) { | ||
const rightIcon = document.createElement("img"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
seems like it is possible to not use svg and use rich text font icons here.
i have notify Ana to update RTE font icons.
and we can reduce bundle size
} | ||
|
||
createMenu(left: string, right: string, isDropDown: boolean) { | ||
const container = document.createElement("div"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
update all document
into this.quill.root.ownerDocument
or this.root.ownerDocument
this is safer if rich text being put into iframe.
const EXTRA: MenusDefaults = { | ||
copy: { | ||
content: useLanguage("copyTable"), | ||
icon: copyIcon, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if using RTE font icons, this probably changed into iconClassName
} | ||
|
||
createDragTable(table: Element) { | ||
const dragTable = document.createElement("div"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here, change document into ownerDocument
: false | ||
table: false, | ||
"table-better": { | ||
language: "en_US", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we are using hardcoded language here.
let's confirm with @takumagott first.
otherwise, we can use ownerDocument.documentElement.lang
to check for browser's language.
but note that we don't support all languages.
Pull request type
Description