mjml-blocks 4.11.0 → 4.13.0
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/README.md +4 -7
- package/dist/index.d.ts +23 -21
- package/dist/index.js +23 -21
- package/dist/models/MjmlAccordionElementNode.d.ts +1 -1
- package/dist/models/MjmlAccordionElementProps.d.ts +11 -11
- package/dist/models/MjmlAccordionNode.d.ts +1 -1
- package/dist/models/MjmlAccordionProps.d.ts +16 -16
- package/dist/models/MjmlAccordionTextNode.d.ts +1 -1
- package/dist/models/MjmlAccordionTextProps.d.ts +12 -12
- package/dist/models/MjmlAccordionTitleNode.d.ts +1 -1
- package/dist/models/MjmlAccordionTitleProps.d.ts +10 -10
- package/dist/models/MjmlAttributeField.d.ts +1 -1
- package/dist/models/MjmlAttributeKind.d.ts +9 -8
- package/dist/models/MjmlAttributeKind.js +8 -9
- package/dist/models/MjmlAttributeType.d.ts +6 -6
- package/dist/models/MjmlBlockTypeDefinition.d.ts +3 -3
- package/dist/models/MjmlButtonNode.d.ts +1 -1
- package/dist/models/MjmlButtonProps.d.ts +33 -33
- package/dist/models/MjmlCarouselImageNode.d.ts +1 -1
- package/dist/models/MjmlCarouselImageProps.d.ts +11 -11
- package/dist/models/MjmlCarouselNode.d.ts +1 -1
- package/dist/models/MjmlCarouselProps.d.ts +17 -17
- package/dist/models/MjmlColumnNode.d.ts +1 -1
- package/dist/models/MjmlColumnProps.d.ts +22 -22
- package/dist/models/MjmlContentKind.d.ts +6 -5
- package/dist/models/MjmlContentKind.js +5 -6
- package/dist/models/MjmlDirection.d.ts +6 -5
- package/dist/models/MjmlDirection.js +5 -6
- package/dist/models/MjmlDividerNode.d.ts +1 -1
- package/dist/models/MjmlDividerProps.d.ts +11 -11
- package/dist/models/MjmlGroupNode.d.ts +1 -1
- package/dist/models/MjmlGroupProps.d.ts +4 -4
- package/dist/models/MjmlHeroNode.d.ts +1 -1
- package/dist/models/MjmlHeroProps.d.ts +20 -20
- package/dist/models/MjmlImageNode.d.ts +1 -1
- package/dist/models/MjmlImageProps.d.ts +29 -29
- package/dist/models/MjmlNavbarLinkNode.d.ts +1 -1
- package/dist/models/MjmlNavbarLinkProps.d.ts +18 -18
- package/dist/models/MjmlNavbarNode.d.ts +1 -1
- package/dist/models/MjmlNavbarProps.d.ts +22 -22
- package/dist/models/MjmlNodeType.d.ts +25 -24
- package/dist/models/MjmlNodeType.js +24 -25
- package/dist/models/MjmlRawNode.d.ts +1 -1
- package/dist/models/MjmlRawProps.d.ts +1 -1
- package/dist/models/MjmlRenderSpecification.d.ts +1 -1
- package/dist/models/MjmlRichText.d.ts +1 -1
- package/dist/models/MjmlRootProps.d.ts +9 -9
- package/dist/models/MjmlSectionNode.d.ts +1 -1
- package/dist/models/MjmlSectionProps.d.ts +23 -23
- package/dist/models/MjmlSocialElementNode.d.ts +1 -1
- package/dist/models/MjmlSocialElementProps.d.ts +31 -31
- package/dist/models/MjmlSocialNode.d.ts +1 -1
- package/dist/models/MjmlSocialProps.d.ts +24 -24
- package/dist/models/MjmlSpacerNode.d.ts +1 -1
- package/dist/models/MjmlSpacerProps.d.ts +12 -12
- package/dist/models/MjmlTableNode.d.ts +1 -1
- package/dist/models/MjmlTableProps.d.ts +19 -19
- package/dist/models/MjmlTextNode.d.ts +1 -1
- package/dist/models/MjmlTextProps.d.ts +19 -19
- package/dist/models/MjmlWrapperNode.d.ts +1 -1
- package/dist/models/MjmlWrapperProps.d.ts +24 -24
- package/dist/services/MjmlContentKindSchemaMap.d.ts +2 -2
- package/dist/services/MjmlContentKindSchemaMap.js +3 -3
- package/dist/services/checkMjmlAlternativeText.d.ts +2 -2
- package/dist/services/components/createMjmlAccordionTextPropsSchema.d.ts +1 -1
- package/dist/services/components/createMjmlAccordionTextType.js +2 -2
- package/dist/services/components/createMjmlRichTextType.js +3 -3
- package/dist/services/components/createMjmlTextPropsSchema.d.ts +1 -1
- package/dist/services/components/createMjmlTextType.js +2 -2
- package/dist/services/components/mjAccordion.d.ts +1 -1
- package/dist/services/components/mjAccordion.js +6 -5
- package/dist/services/components/mjAccordionElement.d.ts +3 -2
- package/dist/services/components/mjAccordionElement.js +7 -7
- package/dist/services/components/mjAccordionTitle.d.ts +1 -1
- package/dist/services/components/mjAccordionTitle.js +9 -8
- package/dist/services/components/mjButton.d.ts +1 -1
- package/dist/services/components/mjButton.js +9 -8
- package/dist/services/components/mjCarousel.d.ts +1 -1
- package/dist/services/components/mjCarousel.js +6 -5
- package/dist/services/components/mjCarouselImage.d.ts +3 -2
- package/dist/services/components/mjCarouselImage.js +4 -4
- package/dist/services/components/mjColumn.d.ts +1 -1
- package/dist/services/components/mjColumn.js +16 -15
- package/dist/services/components/mjDivider.d.ts +1 -1
- package/dist/services/components/mjDivider.js +5 -4
- package/dist/services/components/mjGroup.d.ts +3 -2
- package/dist/services/components/mjGroup.js +5 -5
- package/dist/services/components/mjHero.d.ts +1 -1
- package/dist/services/components/mjHero.js +16 -15
- package/dist/services/components/mjImage.d.ts +1 -1
- package/dist/services/components/mjImage.js +5 -4
- package/dist/services/components/mjNavbar.d.ts +1 -1
- package/dist/services/components/mjNavbar.js +6 -5
- package/dist/services/components/mjNavbarLink.d.ts +1 -1
- package/dist/services/components/mjNavbarLink.js +9 -8
- package/dist/services/components/mjRaw.d.ts +3 -2
- package/dist/services/components/mjRaw.js +8 -8
- package/dist/services/components/mjSection.js +6 -6
- package/dist/services/components/mjSocial.d.ts +1 -1
- package/dist/services/components/mjSocial.js +6 -5
- package/dist/services/components/mjSocialElement.d.ts +1 -1
- package/dist/services/components/mjSocialElement.js +9 -8
- package/dist/services/components/mjSpacer.d.ts +1 -1
- package/dist/services/components/mjSpacer.js +5 -4
- package/dist/services/components/mjTable.d.ts +1 -1
- package/dist/services/components/mjTable.js +9 -8
- package/dist/services/components/mjWrapper.d.ts +0 -5
- package/dist/services/components/mjWrapper.js +7 -7
- package/dist/services/constants.d.ts +1 -1
- package/dist/services/constants.js +7 -11
- package/dist/services/createMjmlDocumentSchema.d.ts +1 -1
- package/dist/services/createMjmlRootPropsSchema.js +2 -1
- package/dist/services/createMjmlSlotSchema.js +1 -1
- package/dist/services/createTypeSchema.js +7 -7
- package/dist/services/getFilledMjmlAttributes.d.ts +1 -0
- package/dist/services/getFilledMjmlAttributes.js +3 -0
- package/dist/services/mjmlNodeChildren.js +23 -23
- package/dist/services/mjmlNodeSchema.js +23 -23
- package/dist/services/mjmlRootPropsSchema.d.ts +2 -2
- package/dist/services/mjmlRootPropsSchema.js +2 -2
- package/dist/services/parseMjmlAttributeType.js +7 -7
- package/dist/services/parseMjmlDocument.js +2 -1
- package/dist/services/readMjmlContent.d.ts +1 -1
- package/dist/services/readMjmlContent.js +4 -4
- package/dist/services/readMjmlNode.js +2 -1
- package/dist/services/readMjmlNodes.js +2 -1
- package/dist/services/readMjmlRoot.js +2 -1
- package/dist/services/readMjmlRootProps.d.ts +1 -0
- package/dist/services/readMjmlRootProps.js +7 -0
- package/dist/services/renderMjmlDocument.js +3 -2
- package/dist/services/renderMjmlHead.js +1 -1
- package/dist/services/renderMjmlNode.js +8 -8
- package/package.json +7 -6
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import { MjmlCarouselImageNode } from "./MjmlCarouselImageNode.js";
|
|
2
2
|
import { BlockNodeProps } from "vue-block-editor-headless";
|
|
3
3
|
export interface MjmlCarouselProps extends BlockNodeProps {
|
|
4
|
-
align?: string;
|
|
5
|
-
"border-radius"?: string;
|
|
4
|
+
align?: string | undefined;
|
|
5
|
+
"border-radius"?: string | undefined;
|
|
6
6
|
children: MjmlCarouselImageNode[];
|
|
7
|
-
"container-background-color"?: string;
|
|
8
|
-
"icon-width"?: string;
|
|
9
|
-
"left-icon"?: string;
|
|
10
|
-
padding?: string;
|
|
11
|
-
"padding-bottom"?: string;
|
|
12
|
-
"padding-left"?: string;
|
|
13
|
-
"padding-right"?: string;
|
|
14
|
-
"padding-top"?: string;
|
|
15
|
-
"right-icon"?: string;
|
|
16
|
-
"tb-border"?: string;
|
|
17
|
-
"tb-border-radius"?: string;
|
|
18
|
-
"tb-hover-border-color"?: string;
|
|
19
|
-
"tb-selected-border-color"?: string;
|
|
20
|
-
"tb-width"?: string;
|
|
21
|
-
thumbnails?: string;
|
|
7
|
+
"container-background-color"?: string | undefined;
|
|
8
|
+
"icon-width"?: string | undefined;
|
|
9
|
+
"left-icon"?: string | undefined;
|
|
10
|
+
padding?: string | undefined;
|
|
11
|
+
"padding-bottom"?: string | undefined;
|
|
12
|
+
"padding-left"?: string | undefined;
|
|
13
|
+
"padding-right"?: string | undefined;
|
|
14
|
+
"padding-top"?: string | undefined;
|
|
15
|
+
"right-icon"?: string | undefined;
|
|
16
|
+
"tb-border"?: string | undefined;
|
|
17
|
+
"tb-border-radius"?: string | undefined;
|
|
18
|
+
"tb-hover-border-color"?: string | undefined;
|
|
19
|
+
"tb-selected-border-color"?: string | undefined;
|
|
20
|
+
"tb-width"?: string | undefined;
|
|
21
|
+
thumbnails?: string | undefined;
|
|
22
22
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MjmlColumnProps } from "./MjmlColumnProps.js";
|
|
2
2
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
3
3
|
import { BlockNode } from "vue-block-editor-headless";
|
|
4
|
-
export type MjmlColumnNode = BlockNode<MjmlNodeType.Column, MjmlColumnProps>;
|
|
4
|
+
export type MjmlColumnNode = BlockNode<typeof MjmlNodeType.Column, MjmlColumnProps>;
|
|
@@ -2,27 +2,27 @@ import { MjmlFlowNode } from "./MjmlFlowNode.js";
|
|
|
2
2
|
import { MjmlLeafNode } from "./MjmlLeafNode.js";
|
|
3
3
|
import { BlockNodeProps } from "vue-block-editor-headless";
|
|
4
4
|
export interface MjmlColumnProps extends BlockNodeProps {
|
|
5
|
-
"background-color"?: string;
|
|
6
|
-
border?: string;
|
|
7
|
-
"border-bottom"?: string;
|
|
8
|
-
"border-left"?: string;
|
|
9
|
-
"border-radius"?: string;
|
|
10
|
-
"border-right"?: string;
|
|
11
|
-
"border-top"?: string;
|
|
5
|
+
"background-color"?: string | undefined;
|
|
6
|
+
border?: string | undefined;
|
|
7
|
+
"border-bottom"?: string | undefined;
|
|
8
|
+
"border-left"?: string | undefined;
|
|
9
|
+
"border-radius"?: string | undefined;
|
|
10
|
+
"border-right"?: string | undefined;
|
|
11
|
+
"border-top"?: string | undefined;
|
|
12
12
|
children: (MjmlFlowNode | MjmlLeafNode)[];
|
|
13
|
-
direction?: string;
|
|
14
|
-
"inner-background-color"?: string;
|
|
15
|
-
"inner-border"?: string;
|
|
16
|
-
"inner-border-bottom"?: string;
|
|
17
|
-
"inner-border-left"?: string;
|
|
18
|
-
"inner-border-radius"?: string;
|
|
19
|
-
"inner-border-right"?: string;
|
|
20
|
-
"inner-border-top"?: string;
|
|
21
|
-
padding?: string;
|
|
22
|
-
"padding-bottom"?: string;
|
|
23
|
-
"padding-left"?: string;
|
|
24
|
-
"padding-right"?: string;
|
|
25
|
-
"padding-top"?: string;
|
|
26
|
-
"vertical-align"?: string;
|
|
27
|
-
width?: string;
|
|
13
|
+
direction?: string | undefined;
|
|
14
|
+
"inner-background-color"?: string | undefined;
|
|
15
|
+
"inner-border"?: string | undefined;
|
|
16
|
+
"inner-border-bottom"?: string | undefined;
|
|
17
|
+
"inner-border-left"?: string | undefined;
|
|
18
|
+
"inner-border-radius"?: string | undefined;
|
|
19
|
+
"inner-border-right"?: string | undefined;
|
|
20
|
+
"inner-border-top"?: string | undefined;
|
|
21
|
+
padding?: string | undefined;
|
|
22
|
+
"padding-bottom"?: string | undefined;
|
|
23
|
+
"padding-left"?: string | undefined;
|
|
24
|
+
"padding-right"?: string | undefined;
|
|
25
|
+
"padding-top"?: string | undefined;
|
|
26
|
+
"vertical-align"?: string | undefined;
|
|
27
|
+
width?: string | undefined;
|
|
28
28
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
export declare
|
|
2
|
-
Label
|
|
3
|
-
Raw
|
|
4
|
-
RichText
|
|
5
|
-
}
|
|
1
|
+
export declare const MjmlContentKind: {
|
|
2
|
+
readonly Label: "label";
|
|
3
|
+
readonly Raw: "raw";
|
|
4
|
+
readonly RichText: "richText";
|
|
5
|
+
};
|
|
6
|
+
export type MjmlContentKind = (typeof MjmlContentKind)[keyof typeof MjmlContentKind];
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
// src/models/MjmlContentKind.ts
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
}({});
|
|
2
|
+
const MjmlContentKind = {
|
|
3
|
+
Label: "label",
|
|
4
|
+
Raw: "raw",
|
|
5
|
+
RichText: "richText"
|
|
6
|
+
};
|
|
8
7
|
export { MjmlContentKind };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
export declare
|
|
2
|
-
Auto
|
|
3
|
-
Ltr
|
|
4
|
-
Rtl
|
|
5
|
-
}
|
|
1
|
+
export declare const MjmlDirection: {
|
|
2
|
+
readonly Auto: "auto";
|
|
3
|
+
readonly Ltr: "ltr";
|
|
4
|
+
readonly Rtl: "rtl";
|
|
5
|
+
};
|
|
6
|
+
export type MjmlDirection = (typeof MjmlDirection)[keyof typeof MjmlDirection];
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
// src/models/MjmlDirection.ts
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
}({});
|
|
2
|
+
const MjmlDirection = {
|
|
3
|
+
Auto: "auto",
|
|
4
|
+
Ltr: "ltr",
|
|
5
|
+
Rtl: "rtl"
|
|
6
|
+
};
|
|
8
7
|
export { MjmlDirection };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MjmlDividerProps } from "./MjmlDividerProps.js";
|
|
2
2
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
3
3
|
import { BlockNode } from "vue-block-editor-headless";
|
|
4
|
-
export type MjmlDividerNode = BlockNode<MjmlNodeType.Divider, MjmlDividerProps>;
|
|
4
|
+
export type MjmlDividerNode = BlockNode<typeof MjmlNodeType.Divider, MjmlDividerProps>;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { BlockNodeProps } from "vue-block-editor-headless";
|
|
2
2
|
export interface MjmlDividerProps extends BlockNodeProps {
|
|
3
|
-
align?: string;
|
|
4
|
-
"border-color"?: string;
|
|
5
|
-
"border-style"?: string;
|
|
6
|
-
"border-width"?: string;
|
|
7
|
-
"container-background-color"?: string;
|
|
8
|
-
padding?: string;
|
|
9
|
-
"padding-bottom"?: string;
|
|
10
|
-
"padding-left"?: string;
|
|
11
|
-
"padding-right"?: string;
|
|
12
|
-
"padding-top"?: string;
|
|
13
|
-
width?: string;
|
|
3
|
+
align?: string | undefined;
|
|
4
|
+
"border-color"?: string | undefined;
|
|
5
|
+
"border-style"?: string | undefined;
|
|
6
|
+
"border-width"?: string | undefined;
|
|
7
|
+
"container-background-color"?: string | undefined;
|
|
8
|
+
padding?: string | undefined;
|
|
9
|
+
"padding-bottom"?: string | undefined;
|
|
10
|
+
"padding-left"?: string | undefined;
|
|
11
|
+
"padding-right"?: string | undefined;
|
|
12
|
+
"padding-top"?: string | undefined;
|
|
13
|
+
width?: string | undefined;
|
|
14
14
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MjmlGroupProps } from "./MjmlGroupProps.js";
|
|
2
2
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
3
3
|
import { BlockNode } from "vue-block-editor-headless";
|
|
4
|
-
export type MjmlGroupNode = BlockNode<MjmlNodeType.Group, MjmlGroupProps>;
|
|
4
|
+
export type MjmlGroupNode = BlockNode<typeof MjmlNodeType.Group, MjmlGroupProps>;
|
|
@@ -2,9 +2,9 @@ import { MjmlColumnNode } from "./MjmlColumnNode.js";
|
|
|
2
2
|
import { MjmlRawNode } from "./MjmlRawNode.js";
|
|
3
3
|
import { BlockNodeProps } from "vue-block-editor-headless";
|
|
4
4
|
export interface MjmlGroupProps extends BlockNodeProps {
|
|
5
|
-
"background-color"?: string;
|
|
5
|
+
"background-color"?: string | undefined;
|
|
6
6
|
children: (MjmlColumnNode | MjmlRawNode)[];
|
|
7
|
-
direction?: string;
|
|
8
|
-
"vertical-align"?: string;
|
|
9
|
-
width?: string;
|
|
7
|
+
direction?: string | undefined;
|
|
8
|
+
"vertical-align"?: string | undefined;
|
|
9
|
+
width?: string | undefined;
|
|
10
10
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MjmlHeroProps } from "./MjmlHeroProps.js";
|
|
2
2
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
3
3
|
import { BlockNode } from "vue-block-editor-headless";
|
|
4
|
-
export type MjmlHeroNode = BlockNode<MjmlNodeType.Hero, MjmlHeroProps>;
|
|
4
|
+
export type MjmlHeroNode = BlockNode<typeof MjmlNodeType.Hero, MjmlHeroProps>;
|
|
@@ -2,25 +2,25 @@ import { MjmlFlowNode } from "./MjmlFlowNode.js";
|
|
|
2
2
|
import { MjmlLeafNode } from "./MjmlLeafNode.js";
|
|
3
3
|
import { BlockNodeProps } from "vue-block-editor-headless";
|
|
4
4
|
export interface MjmlHeroProps extends BlockNodeProps {
|
|
5
|
-
"background-color"?: string;
|
|
6
|
-
"background-height"?: string;
|
|
7
|
-
"background-position"?: string;
|
|
8
|
-
"background-url"?: string;
|
|
9
|
-
"background-width"?: string;
|
|
10
|
-
"border-radius"?: string;
|
|
5
|
+
"background-color"?: string | undefined;
|
|
6
|
+
"background-height"?: string | undefined;
|
|
7
|
+
"background-position"?: string | undefined;
|
|
8
|
+
"background-url"?: string | undefined;
|
|
9
|
+
"background-width"?: string | undefined;
|
|
10
|
+
"border-radius"?: string | undefined;
|
|
11
11
|
children: (MjmlFlowNode | MjmlLeafNode)[];
|
|
12
|
-
height?: string;
|
|
13
|
-
"inner-background-color"?: string;
|
|
14
|
-
"inner-padding"?: string;
|
|
15
|
-
"inner-padding-bottom"?: string;
|
|
16
|
-
"inner-padding-left"?: string;
|
|
17
|
-
"inner-padding-right"?: string;
|
|
18
|
-
"inner-padding-top"?: string;
|
|
19
|
-
mode?: string;
|
|
20
|
-
padding?: string;
|
|
21
|
-
"padding-bottom"?: string;
|
|
22
|
-
"padding-left"?: string;
|
|
23
|
-
"padding-right"?: string;
|
|
24
|
-
"padding-top"?: string;
|
|
25
|
-
"vertical-align"?: string;
|
|
12
|
+
height?: string | undefined;
|
|
13
|
+
"inner-background-color"?: string | undefined;
|
|
14
|
+
"inner-padding"?: string | undefined;
|
|
15
|
+
"inner-padding-bottom"?: string | undefined;
|
|
16
|
+
"inner-padding-left"?: string | undefined;
|
|
17
|
+
"inner-padding-right"?: string | undefined;
|
|
18
|
+
"inner-padding-top"?: string | undefined;
|
|
19
|
+
mode?: string | undefined;
|
|
20
|
+
padding?: string | undefined;
|
|
21
|
+
"padding-bottom"?: string | undefined;
|
|
22
|
+
"padding-left"?: string | undefined;
|
|
23
|
+
"padding-right"?: string | undefined;
|
|
24
|
+
"padding-top"?: string | undefined;
|
|
25
|
+
"vertical-align"?: string | undefined;
|
|
26
26
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MjmlImageProps } from "./MjmlImageProps.js";
|
|
2
2
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
3
3
|
import { BlockNode } from "vue-block-editor-headless";
|
|
4
|
-
export type MjmlImageNode = BlockNode<MjmlNodeType.Image, MjmlImageProps>;
|
|
4
|
+
export type MjmlImageNode = BlockNode<typeof MjmlNodeType.Image, MjmlImageProps>;
|
|
@@ -1,32 +1,32 @@
|
|
|
1
1
|
import { BlockNodeProps } from "vue-block-editor-headless";
|
|
2
2
|
export interface MjmlImageProps extends BlockNodeProps {
|
|
3
|
-
align?: string;
|
|
4
|
-
alt?: string;
|
|
5
|
-
border?: string;
|
|
6
|
-
"border-bottom"?: string;
|
|
7
|
-
"border-left"?: string;
|
|
8
|
-
"border-radius"?: string;
|
|
9
|
-
"border-right"?: string;
|
|
10
|
-
"border-top"?: string;
|
|
11
|
-
"container-background-color"?: string;
|
|
12
|
-
decorative?: boolean;
|
|
13
|
-
"fluid-on-mobile"?: string;
|
|
14
|
-
"font-size"?: string;
|
|
15
|
-
height?: string;
|
|
16
|
-
href?: string;
|
|
17
|
-
"max-height"?: string;
|
|
18
|
-
name?: string;
|
|
19
|
-
padding?: string;
|
|
20
|
-
"padding-bottom"?: string;
|
|
21
|
-
"padding-left"?: string;
|
|
22
|
-
"padding-right"?: string;
|
|
23
|
-
"padding-top"?: string;
|
|
24
|
-
rel?: string;
|
|
25
|
-
sizes?: string;
|
|
26
|
-
src?: string;
|
|
27
|
-
srcset?: string;
|
|
28
|
-
target?: string;
|
|
29
|
-
title?: string;
|
|
30
|
-
usemap?: string;
|
|
31
|
-
width?: string;
|
|
3
|
+
align?: string | undefined;
|
|
4
|
+
alt?: string | undefined;
|
|
5
|
+
border?: string | undefined;
|
|
6
|
+
"border-bottom"?: string | undefined;
|
|
7
|
+
"border-left"?: string | undefined;
|
|
8
|
+
"border-radius"?: string | undefined;
|
|
9
|
+
"border-right"?: string | undefined;
|
|
10
|
+
"border-top"?: string | undefined;
|
|
11
|
+
"container-background-color"?: string | undefined;
|
|
12
|
+
decorative?: boolean | undefined;
|
|
13
|
+
"fluid-on-mobile"?: string | undefined;
|
|
14
|
+
"font-size"?: string | undefined;
|
|
15
|
+
height?: string | undefined;
|
|
16
|
+
href?: string | undefined;
|
|
17
|
+
"max-height"?: string | undefined;
|
|
18
|
+
name?: string | undefined;
|
|
19
|
+
padding?: string | undefined;
|
|
20
|
+
"padding-bottom"?: string | undefined;
|
|
21
|
+
"padding-left"?: string | undefined;
|
|
22
|
+
"padding-right"?: string | undefined;
|
|
23
|
+
"padding-top"?: string | undefined;
|
|
24
|
+
rel?: string | undefined;
|
|
25
|
+
sizes?: string | undefined;
|
|
26
|
+
src?: string | undefined;
|
|
27
|
+
srcset?: string | undefined;
|
|
28
|
+
target?: string | undefined;
|
|
29
|
+
title?: string | undefined;
|
|
30
|
+
usemap?: string | undefined;
|
|
31
|
+
width?: string | undefined;
|
|
32
32
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MjmlNavbarLinkProps } from "./MjmlNavbarLinkProps.js";
|
|
2
2
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
3
3
|
import { BlockNode } from "vue-block-editor-headless";
|
|
4
|
-
export type MjmlNavbarLinkNode = BlockNode<MjmlNodeType.NavbarLink, MjmlNavbarLinkProps>;
|
|
4
|
+
export type MjmlNavbarLinkNode = BlockNode<typeof MjmlNodeType.NavbarLink, MjmlNavbarLinkProps>;
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import { BlockNodeProps } from "vue-block-editor-headless";
|
|
2
2
|
export interface MjmlNavbarLinkProps extends BlockNodeProps {
|
|
3
|
-
color?: string;
|
|
3
|
+
color?: string | undefined;
|
|
4
4
|
content: string;
|
|
5
|
-
"font-family"?: string;
|
|
6
|
-
"font-size"?: string;
|
|
7
|
-
"font-style"?: string;
|
|
8
|
-
"font-weight"?: string;
|
|
9
|
-
href?: string;
|
|
10
|
-
"letter-spacing"?: string;
|
|
11
|
-
"line-height"?: string;
|
|
12
|
-
name?: string;
|
|
13
|
-
padding?: string;
|
|
14
|
-
"padding-bottom"?: string;
|
|
15
|
-
"padding-left"?: string;
|
|
16
|
-
"padding-right"?: string;
|
|
17
|
-
"padding-top"?: string;
|
|
18
|
-
rel?: string;
|
|
19
|
-
target?: string;
|
|
20
|
-
"text-decoration"?: string;
|
|
21
|
-
"text-transform"?: string;
|
|
5
|
+
"font-family"?: string | undefined;
|
|
6
|
+
"font-size"?: string | undefined;
|
|
7
|
+
"font-style"?: string | undefined;
|
|
8
|
+
"font-weight"?: string | undefined;
|
|
9
|
+
href?: string | undefined;
|
|
10
|
+
"letter-spacing"?: string | undefined;
|
|
11
|
+
"line-height"?: string | undefined;
|
|
12
|
+
name?: string | undefined;
|
|
13
|
+
padding?: string | undefined;
|
|
14
|
+
"padding-bottom"?: string | undefined;
|
|
15
|
+
"padding-left"?: string | undefined;
|
|
16
|
+
"padding-right"?: string | undefined;
|
|
17
|
+
"padding-top"?: string | undefined;
|
|
18
|
+
rel?: string | undefined;
|
|
19
|
+
target?: string | undefined;
|
|
20
|
+
"text-decoration"?: string | undefined;
|
|
21
|
+
"text-transform"?: string | undefined;
|
|
22
22
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MjmlNavbarProps } from "./MjmlNavbarProps.js";
|
|
2
2
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
3
3
|
import { BlockNode } from "vue-block-editor-headless";
|
|
4
|
-
export type MjmlNavbarNode = BlockNode<MjmlNodeType.Navbar, MjmlNavbarProps>;
|
|
4
|
+
export type MjmlNavbarNode = BlockNode<typeof MjmlNodeType.Navbar, MjmlNavbarProps>;
|
|
@@ -2,27 +2,27 @@ import { MjmlNavbarLinkNode } from "./MjmlNavbarLinkNode.js";
|
|
|
2
2
|
import { MjmlRawNode } from "./MjmlRawNode.js";
|
|
3
3
|
import { BlockNodeProps } from "vue-block-editor-headless";
|
|
4
4
|
export interface MjmlNavbarProps extends BlockNodeProps {
|
|
5
|
-
align?: string;
|
|
6
|
-
"base-url"?: string;
|
|
5
|
+
align?: string | undefined;
|
|
6
|
+
"base-url"?: string | undefined;
|
|
7
7
|
children: (MjmlNavbarLinkNode | MjmlRawNode)[];
|
|
8
|
-
hamburger?: string;
|
|
9
|
-
"ico-align"?: string;
|
|
10
|
-
"ico-close"?: string;
|
|
11
|
-
"ico-color"?: string;
|
|
12
|
-
"ico-font-family"?: string;
|
|
13
|
-
"ico-font-size"?: string;
|
|
14
|
-
"ico-line-height"?: string;
|
|
15
|
-
"ico-open"?: string;
|
|
16
|
-
"ico-padding"?: string;
|
|
17
|
-
"ico-padding-bottom"?: string;
|
|
18
|
-
"ico-padding-left"?: string;
|
|
19
|
-
"ico-padding-right"?: string;
|
|
20
|
-
"ico-padding-top"?: string;
|
|
21
|
-
"ico-text-decoration"?: string;
|
|
22
|
-
"ico-text-transform"?: string;
|
|
23
|
-
padding?: string;
|
|
24
|
-
"padding-bottom"?: string;
|
|
25
|
-
"padding-left"?: string;
|
|
26
|
-
"padding-right"?: string;
|
|
27
|
-
"padding-top"?: string;
|
|
8
|
+
hamburger?: string | undefined;
|
|
9
|
+
"ico-align"?: string | undefined;
|
|
10
|
+
"ico-close"?: string | undefined;
|
|
11
|
+
"ico-color"?: string | undefined;
|
|
12
|
+
"ico-font-family"?: string | undefined;
|
|
13
|
+
"ico-font-size"?: string | undefined;
|
|
14
|
+
"ico-line-height"?: string | undefined;
|
|
15
|
+
"ico-open"?: string | undefined;
|
|
16
|
+
"ico-padding"?: string | undefined;
|
|
17
|
+
"ico-padding-bottom"?: string | undefined;
|
|
18
|
+
"ico-padding-left"?: string | undefined;
|
|
19
|
+
"ico-padding-right"?: string | undefined;
|
|
20
|
+
"ico-padding-top"?: string | undefined;
|
|
21
|
+
"ico-text-decoration"?: string | undefined;
|
|
22
|
+
"ico-text-transform"?: string | undefined;
|
|
23
|
+
padding?: string | undefined;
|
|
24
|
+
"padding-bottom"?: string | undefined;
|
|
25
|
+
"padding-left"?: string | undefined;
|
|
26
|
+
"padding-right"?: string | undefined;
|
|
27
|
+
"padding-top"?: string | undefined;
|
|
28
28
|
}
|
|
@@ -1,24 +1,25 @@
|
|
|
1
|
-
export declare
|
|
2
|
-
Accordion
|
|
3
|
-
AccordionElement
|
|
4
|
-
AccordionText
|
|
5
|
-
AccordionTitle
|
|
6
|
-
Button
|
|
7
|
-
Carousel
|
|
8
|
-
CarouselImage
|
|
9
|
-
Column
|
|
10
|
-
Divider
|
|
11
|
-
Group
|
|
12
|
-
Hero
|
|
13
|
-
Image
|
|
14
|
-
Navbar
|
|
15
|
-
NavbarLink
|
|
16
|
-
Raw
|
|
17
|
-
Section
|
|
18
|
-
Social
|
|
19
|
-
SocialElement
|
|
20
|
-
Spacer
|
|
21
|
-
Table
|
|
22
|
-
Text
|
|
23
|
-
Wrapper
|
|
24
|
-
}
|
|
1
|
+
export declare const MjmlNodeType: {
|
|
2
|
+
readonly Accordion: "mj-accordion";
|
|
3
|
+
readonly AccordionElement: "mj-accordion-element";
|
|
4
|
+
readonly AccordionText: "mj-accordion-text";
|
|
5
|
+
readonly AccordionTitle: "mj-accordion-title";
|
|
6
|
+
readonly Button: "mj-button";
|
|
7
|
+
readonly Carousel: "mj-carousel";
|
|
8
|
+
readonly CarouselImage: "mj-carousel-image";
|
|
9
|
+
readonly Column: "mj-column";
|
|
10
|
+
readonly Divider: "mj-divider";
|
|
11
|
+
readonly Group: "mj-group";
|
|
12
|
+
readonly Hero: "mj-hero";
|
|
13
|
+
readonly Image: "mj-image";
|
|
14
|
+
readonly Navbar: "mj-navbar";
|
|
15
|
+
readonly NavbarLink: "mj-navbar-link";
|
|
16
|
+
readonly Raw: "mj-raw";
|
|
17
|
+
readonly Section: "mj-section";
|
|
18
|
+
readonly Social: "mj-social";
|
|
19
|
+
readonly SocialElement: "mj-social-element";
|
|
20
|
+
readonly Spacer: "mj-spacer";
|
|
21
|
+
readonly Table: "mj-table";
|
|
22
|
+
readonly Text: "mj-text";
|
|
23
|
+
readonly Wrapper: "mj-wrapper";
|
|
24
|
+
};
|
|
25
|
+
export type MjmlNodeType = (typeof MjmlNodeType)[keyof typeof MjmlNodeType];
|
|
@@ -1,27 +1,26 @@
|
|
|
1
1
|
// src/models/MjmlNodeType.ts
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
}({});
|
|
2
|
+
const MjmlNodeType = {
|
|
3
|
+
Accordion: "mj-accordion",
|
|
4
|
+
AccordionElement: "mj-accordion-element",
|
|
5
|
+
AccordionText: "mj-accordion-text",
|
|
6
|
+
AccordionTitle: "mj-accordion-title",
|
|
7
|
+
Button: "mj-button",
|
|
8
|
+
Carousel: "mj-carousel",
|
|
9
|
+
CarouselImage: "mj-carousel-image",
|
|
10
|
+
Column: "mj-column",
|
|
11
|
+
Divider: "mj-divider",
|
|
12
|
+
Group: "mj-group",
|
|
13
|
+
Hero: "mj-hero",
|
|
14
|
+
Image: "mj-image",
|
|
15
|
+
Navbar: "mj-navbar",
|
|
16
|
+
NavbarLink: "mj-navbar-link",
|
|
17
|
+
Raw: "mj-raw",
|
|
18
|
+
Section: "mj-section",
|
|
19
|
+
Social: "mj-social",
|
|
20
|
+
SocialElement: "mj-social-element",
|
|
21
|
+
Spacer: "mj-spacer",
|
|
22
|
+
Table: "mj-table",
|
|
23
|
+
Text: "mj-text",
|
|
24
|
+
Wrapper: "mj-wrapper"
|
|
25
|
+
};
|
|
27
26
|
export { MjmlNodeType };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
2
2
|
import { MjmlRawProps } from "./MjmlRawProps.js";
|
|
3
3
|
import { BlockNode } from "vue-block-editor-headless";
|
|
4
|
-
export type MjmlRawNode = BlockNode<MjmlNodeType.Raw, MjmlRawProps>;
|
|
4
|
+
export type MjmlRawNode = BlockNode<typeof MjmlNodeType.Raw, MjmlRawProps>;
|
|
@@ -2,7 +2,7 @@ import { MjmlContentKind } from "./MjmlContentKind.js";
|
|
|
2
2
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
3
3
|
export interface MjmlRenderSpecification {
|
|
4
4
|
allowedAttributes: Record<string, string>;
|
|
5
|
-
contentKind?: MjmlContentKind;
|
|
5
|
+
contentKind?: MjmlContentKind | undefined;
|
|
6
6
|
hasAlternativeText: boolean;
|
|
7
7
|
hasChildren: boolean;
|
|
8
8
|
tagName: MjmlNodeType;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { MjmlRichTextAttributeValue } from "./MjmlRichTextAttributeValue.js";
|
|
2
2
|
export interface MjmlRichText {
|
|
3
|
-
attrs?: Record<string, MjmlRichTextAttributeValue
|
|
3
|
+
attrs?: Record<string, MjmlRichTextAttributeValue> | undefined;
|
|
4
4
|
content?: MjmlRichText[];
|
|
5
5
|
marks?: {
|
|
6
6
|
attrs?: Record<string, MjmlRichTextAttributeValue>;
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { MjmlDirection } from "./MjmlDirection.js";
|
|
2
2
|
export interface MjmlRootProps {
|
|
3
|
-
attributes?: Record<string, Record<string, string
|
|
4
|
-
body?: Record<string, string
|
|
5
|
-
breakpoint?: {
|
|
3
|
+
attributes?: Record<string, Record<string, string>> | undefined;
|
|
4
|
+
body?: Record<string, string> | undefined;
|
|
5
|
+
breakpoint?: undefined | {
|
|
6
6
|
width: string;
|
|
7
7
|
};
|
|
8
|
-
direction?: MjmlDirection;
|
|
9
|
-
fonts?: {
|
|
8
|
+
direction?: MjmlDirection | undefined;
|
|
9
|
+
fonts?: undefined | {
|
|
10
10
|
href: string;
|
|
11
11
|
name: string;
|
|
12
12
|
}[];
|
|
13
|
-
lang
|
|
14
|
-
preview?: string;
|
|
15
|
-
styles?: {
|
|
13
|
+
lang: string;
|
|
14
|
+
preview?: string | undefined;
|
|
15
|
+
styles?: undefined | {
|
|
16
16
|
css: string;
|
|
17
17
|
inline: boolean;
|
|
18
18
|
}[];
|
|
19
|
-
title
|
|
19
|
+
title: string;
|
|
20
20
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MjmlNodeType } from "./MjmlNodeType.js";
|
|
2
2
|
import { MjmlSectionProps } from "./MjmlSectionProps.js";
|
|
3
3
|
import { BlockNode } from "vue-block-editor-headless";
|
|
4
|
-
export type MjmlSectionNode = BlockNode<MjmlNodeType.Section, MjmlSectionProps>;
|
|
4
|
+
export type MjmlSectionNode = BlockNode<typeof MjmlNodeType.Section, MjmlSectionProps>;
|