@tiptap/core 2.0.3 → 2.0.4
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/index.cjs +3 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/index.umd.js +3 -3
- package/dist/index.umd.js.map +1 -1
- package/dist/packages/core/src/utilities/createStyleTag.d.ts +1 -1
- package/package.json +2 -2
- package/src/utilities/createStyleTag.ts +3 -3
package/dist/index.cjs
CHANGED
|
@@ -3276,8 +3276,8 @@ img.ProseMirror-separator {
|
|
|
3276
3276
|
opacity: 0
|
|
3277
3277
|
}`;
|
|
3278
3278
|
|
|
3279
|
-
function createStyleTag(style, nonce) {
|
|
3280
|
-
const tiptapStyleTag = document.querySelector(
|
|
3279
|
+
function createStyleTag(style, nonce, suffix) {
|
|
3280
|
+
const tiptapStyleTag = document.querySelector(`style[data-tiptap-style${suffix ? `-${suffix}` : ''}]`);
|
|
3281
3281
|
if (tiptapStyleTag !== null) {
|
|
3282
3282
|
return tiptapStyleTag;
|
|
3283
3283
|
}
|
|
@@ -3285,7 +3285,7 @@ function createStyleTag(style, nonce) {
|
|
|
3285
3285
|
if (nonce) {
|
|
3286
3286
|
styleNode.setAttribute('nonce', nonce);
|
|
3287
3287
|
}
|
|
3288
|
-
styleNode.setAttribute(
|
|
3288
|
+
styleNode.setAttribute(`data-tiptap-style${suffix ? `-${suffix}` : ''}`, '');
|
|
3289
3289
|
styleNode.innerHTML = style;
|
|
3290
3290
|
document.getElementsByTagName('head')[0].appendChild(styleNode);
|
|
3291
3291
|
return styleNode;
|