@pagenflow/email 1.4.4 → 1.4.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.
@@ -4,6 +4,10 @@ import IInnerLink from "../types/IInnerLink";
4
4
  export interface ButtonConfig {
5
5
  /** Link configuration for the button destination. Required. */
6
6
  innerLink?: IInnerLink;
7
+ /**
8
+ * @deprecated Use innerLink property instead
9
+ */
10
+ href?: string;
7
11
  /** Button text. */
8
12
  children: ReactNode;
9
13
  /** Background color. Required for VML compatibility. */
@@ -19,7 +19,7 @@ export type ColumnConfig = {
19
19
  gap?: string;
20
20
  };
21
21
  export type ColumnProps = {
22
- children: ReactNode;
22
+ children?: ReactNode;
23
23
  config: ColumnConfig;
24
24
  devNode?: ReactNode;
25
25
  };
@@ -37,7 +37,7 @@ export interface ContainerConfig {
37
37
  }
38
38
  export type ContainerProps = {
39
39
  config: ContainerConfig;
40
- children: ReactNode;
40
+ children?: ReactNode;
41
41
  devMode?: boolean;
42
42
  devNode?: ReactNode;
43
43
  };
@@ -31,6 +31,14 @@ export interface ImageConfig {
31
31
  borderRadius?: string;
32
32
  border?: BorderConfig;
33
33
  innerLink?: IInnerLink;
34
+ /**
35
+ * @deprecated Use innerLink property instead
36
+ */
37
+ href?: string;
38
+ /**
39
+ * @deprecated Use innerLink property instead
40
+ */
41
+ target?: string;
34
42
  objectFit?: CSSProperties["objectFit"];
35
43
  objectPosition?: string;
36
44
  mobile?: ImageMobileConfig;
@@ -36,7 +36,7 @@ export interface RowConfig {
36
36
  };
37
37
  }
38
38
  export type RowProps = {
39
- children: ReactNode;
39
+ children?: ReactNode;
40
40
  config: RowConfig;
41
41
  devNode?: ReactNode;
42
42
  devMode?: boolean;
@@ -15,7 +15,7 @@ export type SectionConfig = {
15
15
  };
16
16
  export interface SectionProps {
17
17
  config: SectionConfig;
18
- children: ReactNode;
18
+ children?: ReactNode;
19
19
  devNode?: ReactNode;
20
20
  }
21
21
  declare const _default: React.NamedExoticComponent<SectionProps>;
@@ -17,7 +17,7 @@ export interface TextConfig {
17
17
  /** Font style (e.g., 'italic'). */
18
18
  fontStyle?: string;
19
19
  /** Line height (e.g., '1.5' or '24px'). */
20
- lineHeight?: string;
20
+ lineHeight?: string | number;
21
21
  /** Letter spacing (e.g., '0.5px', '1px'). */
22
22
  letterSpacing?: string;
23
23
  /** Text transform (e.g., 'uppercase', 'lowercase', 'capitalize'). */
@@ -37,6 +37,7 @@ export interface TextConfig {
37
37
  /** Word break behavior (e.g., 'break-all', 'break-word', 'keep-all', 'normal'). */
38
38
  wordBreak?: string;
39
39
  maxWidth?: string;
40
+ listStyle?: string;
40
41
  }
41
42
  export type TextProps = {
42
43
  config: TextConfig;
package/dist/index.cjs.js CHANGED
@@ -1623,7 +1623,9 @@ function Button({ config, devMode }) {
1623
1623
  let vmlButton = "";
1624
1624
  if (!useSimpleOutlookApproach) {
1625
1625
  // VML needs fixed pixel height. We estimate it based on padding and potential wrapping.
1626
- const numericPadding = padding ? parseInt(padding.split(" ")[0] || "12", 10) : 12;
1626
+ const numericPadding = padding
1627
+ ? parseInt(padding.split(" ")[0] || "12", 10)
1628
+ : 12;
1627
1629
  const numericFontSize = fontSize ? parseInt(fontSize, 10) : 0;
1628
1630
  const numericLineHeight = lineHeight
1629
1631
  ? lineHeight.includes("px")
@@ -2864,7 +2866,7 @@ function Spacer({ config, devNode }) {
2864
2866
  var Spacer_default = React.memo(Spacer, arePropsEqual);
2865
2867
 
2866
2868
  function Text({ config, devMode, children }) {
2867
- const { text, padding, color, textAlign, fontFamily, fontSize, fontWeight, fontStyle, lineHeight, letterSpacing, textTransform, textDecoration, direction, verticalAlign, backgroundColor, opacity, whiteSpace, wordBreak = "break-all", maxWidth } = config;
2869
+ const { text, padding, color, textAlign, fontFamily, fontSize, fontWeight, fontStyle, lineHeight, letterSpacing, textTransform, textDecoration, direction, verticalAlign, backgroundColor, opacity, whiteSpace, wordBreak = "break-all", maxWidth, } = config;
2868
2870
  // 1. TD Style: Where padding and background are reliably applied.
2869
2871
  const tdStyle = {
2870
2872
  padding: padding,
@@ -2891,7 +2893,7 @@ function Text({ config, devMode, children }) {
2891
2893
  wordBreak: wordBreak,
2892
2894
  margin: "0",
2893
2895
  padding: "0",
2894
- maxWidth
2896
+ maxWidth,
2895
2897
  };
2896
2898
  // Determine content to render
2897
2899
  const content = text !== null && text !== void 0 ? text : children;