feat: graphql client with fetches for initial pages
This commit is contained in:
7
components/Current/Blocks/List.tsx
Normal file
7
components/Current/Blocks/List.tsx
Normal file
@@ -0,0 +1,7 @@
|
||||
export default function List() {
|
||||
return (
|
||||
<>
|
||||
|
||||
</>
|
||||
)
|
||||
}
|
||||
7
components/Current/Blocks/Preamble.tsx
Normal file
7
components/Current/Blocks/Preamble.tsx
Normal file
@@ -0,0 +1,7 @@
|
||||
export default function Preamble() {
|
||||
return (
|
||||
<>
|
||||
|
||||
</>
|
||||
)
|
||||
}
|
||||
7
components/Current/Blocks/Puffs.tsx
Normal file
7
components/Current/Blocks/Puffs.tsx
Normal file
@@ -0,0 +1,7 @@
|
||||
export default function Puffs() {
|
||||
return (
|
||||
<>
|
||||
|
||||
</>
|
||||
)
|
||||
}
|
||||
32
components/Current/Blocks/Text.tsx
Normal file
32
components/Current/Blocks/Text.tsx
Normal file
@@ -0,0 +1,32 @@
|
||||
import { rteType } from "@/types/rte";
|
||||
|
||||
import Image from "next/image";
|
||||
|
||||
import type { TextProps } from "@/types/components/current/blocks/text"
|
||||
|
||||
export default function Text({ text }: TextProps) {
|
||||
|
||||
return (
|
||||
<>
|
||||
<pre>{JSON.stringify(text.content.json, null, 2)}</pre>
|
||||
{text.content.json.children.map(block => {
|
||||
switch (block.type) {
|
||||
case rteType.reference: {
|
||||
if (block.attrs.type === rteType.asset) {
|
||||
// return (
|
||||
// <Image
|
||||
// alt={block.attrs.alt}
|
||||
// src={block.attrs["asset-link"]}
|
||||
// />
|
||||
// )
|
||||
}
|
||||
|
||||
return null
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
})}
|
||||
</>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user