@maily-to/core 2.0.0-beta.22 → 2.0.0-beta.23

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.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { B as MAX_SPACER_HEIGHT, G as getVariableSuggestions, H as SPACER_SPACING, I as addColumn, J as Document, L as getColumnWidths, M as VISIBILITY_SUPPORTED_TYPES, Q as getShellNodes, R as removeColumn, U as SPACING_PRESETS, V as MIN_SPACER_HEIGHT, W as VariableExtension, X as getNodeStyleState, Z as getNodeTheme, at as TooltipTrigger, ct as FloatingElement, dt as FLOATING_ELEMENT_ORDER, et as Tooltip, ft as useOnSelectionUpdate, g as VisuallyHidden, gt as useValueAsRef, ht as ArrowIcon, i as mergeExtensions, it as TooltipProvider, j as ProtectVariableTrigger, lt as clearInitialNodeSelection, mt as useEditorInstance, n as useMailyEditor, nt as TooltipPopup, ot as FLOATING_ELEMENT_HEIGHT, pt as useFloatingStore, q as filterVariableSuggestions, r as getNormalizedHtml, rt as TooltipPositioner, st as FLOATING_ELEMENT_PADDING, t as DEFAULT_EXTENSIONS, tt as TooltipArrow, ut as FLOATING_ELEMENT_IDS, z as updateColumnWidth } from "./use-maily-editor-DYEIrsrg.mjs";
1
+ import { B as MAX_SPACER_HEIGHT, G as getVariableSuggestions, H as SPACER_SPACING, I as addColumn, J as Document, L as getColumnWidths, M as VISIBILITY_SUPPORTED_TYPES, Q as getShellNodes, R as removeColumn, U as SPACING_PRESETS, V as MIN_SPACER_HEIGHT, W as VariableExtension, X as getNodeStyleState, Z as getNodeTheme, at as TooltipTrigger, ct as FloatingElement, dt as FLOATING_ELEMENT_ORDER, et as Tooltip, ft as useOnSelectionUpdate, g as VisuallyHidden, gt as useValueAsRef, ht as ArrowIcon, i as mergeExtensions, it as TooltipProvider, j as ProtectVariableTrigger, lt as clearInitialNodeSelection, mt as useEditorInstance, n as useMailyEditor, nt as TooltipPopup, ot as FLOATING_ELEMENT_HEIGHT, pt as useFloatingStore, q as filterVariableSuggestions, r as getNormalizedHtml, rt as TooltipPositioner, st as FLOATING_ELEMENT_PADDING, t as DEFAULT_EXTENSIONS, tt as TooltipArrow, ut as FLOATING_ELEMENT_IDS, z as updateColumnWidth } from "./use-maily-editor-DJgV489s.mjs";
2
2
  import { c } from "react/compiler-runtime";
3
3
  import { ColorPicker as ColorPicker$1 } from "cromia";
4
4
  import { Fragment, createContext, forwardRef, use, useCallback, useEffect, useId, useImperativeHandle, useRef, useState } from "react";
@@ -3494,6 +3494,8 @@ function setLinkedImages(document) {
3494
3494
  }
3495
3495
  image.setAttribute("data-external-link", anchor.getAttribute("href") ?? "");
3496
3496
  anchor.removeAttribute("href");
3497
+ const parent = anchor.parentElement;
3498
+ if (parent?.childElementCount === 1 && !parent.textContent?.trim()) anchor.replaceWith(image);
3497
3499
  }
3498
3500
  }
3499
3501
  function getBodyWrapper(document) {
@@ -4431,6 +4431,8 @@ function setLinkedImages(document) {
4431
4431
  }
4432
4432
  image.setAttribute("data-external-link", anchor.getAttribute("href") ?? "");
4433
4433
  anchor.removeAttribute("href");
4434
+ const parent = anchor.parentElement;
4435
+ if (parent?.childElementCount === 1 && !parent.textContent?.trim()) anchor.replaceWith(image);
4434
4436
  }
4435
4437
  }
4436
4438
  function getBodyWrapper(document) {
@@ -4399,6 +4399,8 @@ function setLinkedImages(document) {
4399
4399
  }
4400
4400
  image.setAttribute("data-external-link", anchor.getAttribute("href") ?? "");
4401
4401
  anchor.removeAttribute("href");
4402
+ const parent = anchor.parentElement;
4403
+ if (parent?.childElementCount === 1 && !parent.textContent?.trim()) anchor.replaceWith(image);
4402
4404
  }
4403
4405
  }
4404
4406
  function getBodyWrapper(document) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maily-to/core",
3
- "version": "2.0.0-beta.22",
3
+ "version": "2.0.0-beta.23",
4
4
  "private": false,
5
5
  "description": "Powerful editor for creating beautiful, pre-designed, mobile-ready emails.",
6
6
  "keywords": [
@@ -87,7 +87,7 @@
87
87
  "lucide-react": "^1.28.0",
88
88
  "unit-field": "^0.0.3",
89
89
  "zustand": "^5.0.14",
90
- "@maily-to/shared": "2.0.0-beta.22"
90
+ "@maily-to/shared": "2.0.0-beta.23"
91
91
  },
92
92
  "devDependencies": {
93
93
  "@react-email/components": "^1.0.12",
@@ -107,10 +107,10 @@
107
107
  "typescript": "^7.0.2",
108
108
  "vite-plus": "0.3.0",
109
109
  "yjs": "^13.6.33",
110
- "@maily-to/extension-ai-actions": "0.0.1",
111
110
  "@maily-to/extension-inline-suggestion": "0.0.1",
111
+ "@maily-to/extension-ai-actions": "0.0.1",
112
112
  "@maily-to/extension-variable": "0.0.1",
113
- "@maily-to/render": "2.0.0-beta.22",
113
+ "@maily-to/render": "2.0.0-beta.23",
114
114
  "@maily-to/tsconfig": "0.0.0"
115
115
  },
116
116
  "peerDependencies": {