@travetto/email-inky 3.3.4 → 3.3.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/package.json +1 -1
- package/src/components.ts +1 -1
- package/src/render/html.ts +2 -2
- package/src/render/markdown.ts +1 -1
package/package.json
CHANGED
package/src/components.ts
CHANGED
|
@@ -25,7 +25,7 @@ export const Spacer: CompFn<{ small?: number, large?: number, size?: number }> =
|
|
|
25
25
|
export const Wrapper: CompFn<{}> = () => EMPTY;
|
|
26
26
|
|
|
27
27
|
export const If: CompFn<{ attr: string }> = () => EMPTY;
|
|
28
|
-
export const Value: CompFn<{ attr: string }> = () => EMPTY;
|
|
28
|
+
export const Value: CompFn<{ attr: string, raw?: boolean }> = () => EMPTY;
|
|
29
29
|
export const Unless: CompFn<{ attr: string }> = () => EMPTY;
|
|
30
30
|
export const For: CompFn<{ attr: string }> = () => EMPTY;
|
|
31
31
|
|
package/src/render/html.ts
CHANGED
|
@@ -64,7 +64,7 @@ export const Html: RenderProvider<RenderContext> = {
|
|
|
64
64
|
For: async ({ recurse, props }) => `{{#${props.attr}}}${await recurse()}{{/${props.attr}}}`,
|
|
65
65
|
If: async ({ recurse, props }) => `{{#${props.attr}}}${await recurse()}{{/${props.attr}}}`,
|
|
66
66
|
Unless: async ({ recurse, props }) => `{{^${props.attr}}}${await recurse()}{{/${props.attr}}}`,
|
|
67
|
-
Value: async ({ props }) => `{{${props.attr}}}`,
|
|
67
|
+
Value: async ({ props }) => props.raw ? `{{{${props.attr}}}}` : `{{${props.attr}}}`,
|
|
68
68
|
|
|
69
69
|
br: async () => '<br>\n',
|
|
70
70
|
hr: async (el) => `<table ${propsToStr(el.props)}><th></th></table>`,
|
|
@@ -155,7 +155,7 @@ export const Html: RenderProvider<RenderContext> = {
|
|
|
155
155
|
<tbody>
|
|
156
156
|
<tr>${await recurse()}</tr>
|
|
157
157
|
</tbody>
|
|
158
|
-
|
|
158
|
+
</table>`,
|
|
159
159
|
|
|
160
160
|
Button: async ({ recurse, el, props, createState }): Promise<string> => {
|
|
161
161
|
const { href, target, ...rest } = props;
|
package/src/render/markdown.ts
CHANGED
|
@@ -16,7 +16,7 @@ export const Markdown: RenderProvider<RenderContext> = {
|
|
|
16
16
|
For: async ({ recurse, props }) => `{{#${props.attr}}}${await recurse()}{{/${props.attr}}}`,
|
|
17
17
|
If: async ({ recurse, props }) => `{{#${props.attr}}}${await recurse()}{{/${props.attr}}}`,
|
|
18
18
|
Unless: async ({ recurse, props }) => `{{^${props.attr}}}${await recurse()}{{/${props.attr}}}`,
|
|
19
|
-
Value: async ({ props }) => `{{${props.attr}}}`,
|
|
19
|
+
Value: async ({ props }) => props.raw ? `{{{${props.attr}}}}` : `{{${props.attr}}}`,
|
|
20
20
|
|
|
21
21
|
strong: async ({ recurse }) => `**${await recurse()}**`,
|
|
22
22
|
hr: async () => '\n------------------\n',
|