@docen/docx 0.4.0 → 0.4.1
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.
|
@@ -361,6 +361,7 @@ const Image = Image$1.extend({
|
|
|
361
361
|
...isRemoteImage(attrs.src) ? REMOTE_IMG_ATTRS : {}
|
|
362
362
|
};
|
|
363
363
|
const styles = renderImageStyles(attrs);
|
|
364
|
+
if (attrs.width == null && attrs.height == null) styles.push("width:100%", "aspect-ratio:4/3");
|
|
364
365
|
if (styles.length > 0) htmlAttrs.style = styles.join(";");
|
|
365
366
|
attachRawAttrs(htmlAttrs, attrs);
|
|
366
367
|
if (floatAnchor) htmlAttrs["data-float-anchor"] = floatAnchor;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@docen/docx",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "DOCX editor and converter powered by @office-open/docx with Tiptap editing layer, supporting bidirectional conversion between DOCX, HTML, and Markdown",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"converter",
|