diff options
Diffstat (limited to 'front/src/components/feed/RP.tsx')
-rw-r--r-- | front/src/components/feed/RP.tsx | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/front/src/components/feed/RP.tsx b/front/src/components/feed/RP.tsx deleted file mode 100644 index dc733cc..0000000 --- a/front/src/components/feed/RP.tsx +++ /dev/null @@ -1,47 +0,0 @@ -import Post from "./Post"; -import type { Ship } from "@/types/urbit"; -import type { Poast, FullNode, ID } from "@/types/trill"; -import PostData from "./PostData"; -export default function (props: { - host: string; - id: string; - rter: Ship; - rtat: number; - rtid: ID; - refetch?: Function; -}) { - return PostData(props)(RP); -} - -function RP({ - data, - refetch, - rter, - rtat, - rtid, -}: { - data: FullNode; - refetch: Function; - rter: Ship; - rtat: number; - rtid: ID; -}) { - return ( - <Post - poast={toFlat(data)} - rter={rter} - rtat={rtat} - rtid={rtid} - refetch={refetch} - /> - ); -} - -export function toFlat(n: FullNode): Poast { - return { - ...n, - children: !n.children - ? [] - : Object.keys(n.children).map((c) => n.children[c].id), - }; -} |