fix: add padding to rte in sidebar
This commit is contained in:
@@ -2,6 +2,8 @@ import JsonToHtml from "@/components/JsonToHtml"
|
|||||||
|
|
||||||
import JoinLoyaltyContact from "./JoinLoyalty"
|
import JoinLoyaltyContact from "./JoinLoyalty"
|
||||||
|
|
||||||
|
import styles from "./sidebar.module.css"
|
||||||
|
|
||||||
import { SidebarProps } from "@/types/components/loyalty/sidebar"
|
import { SidebarProps } from "@/types/components/loyalty/sidebar"
|
||||||
import { SidebarTypenameEnum } from "@/types/requests/loyaltyPage"
|
import { SidebarTypenameEnum } from "@/types/requests/loyaltyPage"
|
||||||
|
|
||||||
@@ -9,10 +11,12 @@ export default function SidebarLoyalty({ block }: SidebarProps) {
|
|||||||
switch (block.__typename) {
|
switch (block.__typename) {
|
||||||
case SidebarTypenameEnum.LoyaltyPageSidebarContent:
|
case SidebarTypenameEnum.LoyaltyPageSidebarContent:
|
||||||
return (
|
return (
|
||||||
|
<section className={styles.content}>
|
||||||
<JsonToHtml
|
<JsonToHtml
|
||||||
embeds={block.content.content.embedded_itemsConnection.edges}
|
embeds={block.content.content.embedded_itemsConnection.edges}
|
||||||
nodes={block.content.content.json.children}
|
nodes={block.content.content.json.children}
|
||||||
/>
|
/>
|
||||||
|
</section>
|
||||||
)
|
)
|
||||||
case SidebarTypenameEnum.LoyaltyPageSidebarJoinLoyaltyContact:
|
case SidebarTypenameEnum.LoyaltyPageSidebarJoinLoyaltyContact:
|
||||||
return <JoinLoyaltyContact block={block.join_loyalty_contact} />
|
return <JoinLoyaltyContact block={block.join_loyalty_contact} />
|
||||||
|
|||||||
9
components/Loyalty/Sidebar/sidebar.module.css
Normal file
9
components/Loyalty/Sidebar/sidebar.module.css
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
.content {
|
||||||
|
padding: 0 1.6rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media screen and (min-width: 950px) {
|
||||||
|
.content {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user