@limetech/lime-elements 37.65.4 → 37.65.5
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/CHANGELOG.md +8 -0
- package/dist/cjs/limel-prosemirror-adapter.cjs.entry.js +17 -19
- package/dist/cjs/limel-prosemirror-adapter.cjs.entry.js.map +1 -1
- package/dist/collection/components/text-editor/utils/markdown-converter.js +3 -1
- package/dist/collection/components/text-editor/utils/markdown-converter.js.map +1 -1
- package/dist/collection/components/text-editor/utils/plugin-factory.js +14 -18
- package/dist/collection/components/text-editor/utils/plugin-factory.js.map +1 -1
- package/dist/esm/limel-prosemirror-adapter.entry.js +17 -19
- package/dist/esm/limel-prosemirror-adapter.entry.js.map +1 -1
- package/dist/lime-elements/lime-elements.esm.js +1 -1
- package/dist/lime-elements/{p-fea2cbd9.entry.js → p-975f1ee3.entry.js} +2 -2
- package/dist/lime-elements/p-975f1ee3.entry.js.map +1 -0
- package/package.json +1 -1
- package/dist/lime-elements/p-fea2cbd9.entry.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,11 @@
|
|
|
1
|
+
## [37.65.5](https://github.com/Lundalogik/lime-elements/compare/v37.65.4...v37.65.5) (2024-11-06)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
* **text-editor:** better support for nested custom elements ([d2889aa](https://github.com/Lundalogik/lime-elements/commit/d2889aa67a3d24217dfa2bd198c8287024268f18)), closes [Lundalogik/crm-feature#4437](https://github.com/Lundalogik/crm-feature/issues/4437)
|
|
8
|
+
|
|
1
9
|
## [37.65.4](https://github.com/Lundalogik/lime-elements/compare/v37.65.3...v37.65.4) (2024-11-05)
|
|
2
10
|
|
|
3
11
|
|
|
@@ -25674,7 +25674,9 @@ const createMarkdownSerializerFunction = (config) => {
|
|
|
25674
25674
|
.join('') +
|
|
25675
25675
|
'>';
|
|
25676
25676
|
const tagClose = `</${config.tagName}>`;
|
|
25677
|
-
state.write(
|
|
25677
|
+
state.write(tagOpen);
|
|
25678
|
+
state.renderContent(node);
|
|
25679
|
+
state.write(tagClose);
|
|
25678
25680
|
};
|
|
25679
25681
|
};
|
|
25680
25682
|
const buildMarkdownSerializer = (plugins) => {
|
|
@@ -26103,30 +26105,26 @@ const createActionBarInteractionPlugin = (menuCommandFactory) => {
|
|
|
26103
26105
|
};
|
|
26104
26106
|
|
|
26105
26107
|
const createNodeSpec = (config) => {
|
|
26106
|
-
const
|
|
26107
|
-
|
|
26108
|
-
|
|
26109
|
-
}, {});
|
|
26108
|
+
const attributeSpecs = {};
|
|
26109
|
+
config.attributes.forEach((attribute) => (attributeSpecs[attribute] = {}));
|
|
26110
|
+
const tag = `${config.tagName}[${config.attributes.map((attr) => attr).join('][')}]`;
|
|
26110
26111
|
return {
|
|
26111
26112
|
group: 'inline',
|
|
26113
|
+
content: '(text* | inline*)',
|
|
26112
26114
|
inline: true,
|
|
26113
|
-
atom:
|
|
26115
|
+
atom: true,
|
|
26114
26116
|
selectable: true,
|
|
26115
|
-
attrs:
|
|
26116
|
-
toDOM: (node) => [
|
|
26117
|
-
config.tagName,
|
|
26118
|
-
config.attributes.reduce((acc, attr) => {
|
|
26119
|
-
acc[attr] = node.attrs[attr];
|
|
26120
|
-
return acc;
|
|
26121
|
-
}, {}),
|
|
26122
|
-
],
|
|
26117
|
+
attrs: attributeSpecs,
|
|
26118
|
+
toDOM: (node) => [config.tagName, node.attrs],
|
|
26123
26119
|
parseDOM: [
|
|
26124
26120
|
{
|
|
26125
|
-
tag:
|
|
26126
|
-
getAttrs: (dom) =>
|
|
26127
|
-
|
|
26128
|
-
|
|
26129
|
-
|
|
26121
|
+
tag: tag,
|
|
26122
|
+
getAttrs: (dom) => {
|
|
26123
|
+
const attributes = {};
|
|
26124
|
+
config.attributes.forEach((attribute) => (attributes[attribute] =
|
|
26125
|
+
dom.getAttribute(attribute)));
|
|
26126
|
+
return attributes;
|
|
26127
|
+
},
|
|
26130
26128
|
},
|
|
26131
26129
|
],
|
|
26132
26130
|
};
|