Skip to content

Commit 5f01334

Browse files
authored
Merge pull request #1333 from prezly/feature/dev-20984-implement-support-for-text-justify-in-emails-site-renderers
[DEV-20984] Fix - Add missing justify styling
2 parents aef0cd3 + fc390b1 commit 5f01334

File tree

3 files changed

+11
-2
lines changed

3 files changed

+11
-2
lines changed

src/components/RichText/Heading.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export function Heading({ node, children }: Props) {
1616
[styles.alignLeft]: node.align === TextAlignment.LEFT,
1717
[styles.alignCenter]: node.align === TextAlignment.CENTER,
1818
[styles.alignRight]: node.align === TextAlignment.RIGHT,
19-
[styles.alignJustify]: node.align === TextAlignment.RIGHT,
19+
[styles.alignJustify]: node.align === TextAlignment.JUSTIFY,
2020
});
2121

2222
if (node.type === HeadingNode.Type.HEADING_ONE) {

src/components/RichText/List.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export function List({ node, children }: PropsWithChildren<ListProps>) {
1818
[styles.alignLeft]: node.align === TextAlignment.LEFT,
1919
[styles.alignCenter]: node.align === TextAlignment.CENTER,
2020
[styles.alignRight]: node.align === TextAlignment.RIGHT,
21-
[styles.alignJustify]: node.align === TextAlignment.RIGHT,
21+
[styles.alignJustify]: node.align === TextAlignment.JUSTIFY,
2222
})}
2323
>
2424
<Tag

src/components/RichText/Quote.module.scss

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,3 +58,12 @@ $content-padding: $spacing-3;
5858
@include quote-fix("right");
5959
}
6060
}
61+
62+
.alignJustify {
63+
text-align: justify;
64+
justify-content: flex-start;
65+
66+
.content {
67+
@include quote-fix("left");
68+
}
69+
}

0 commit comments

Comments
 (0)