a tool for shared writing and social publishing

new files

+16
app/(home-pages)/reader/PreviewDrawer.tsx

This is a binary file and will not be displayed.

+16
src/useSelectedPostState.ts
··· 1 + import { create } from "zustand"; 2 + import type { NormalizedDocument } from "src/utils/normalizeRecords"; 3 + 4 + export type SelectedPostListing = { 5 + document_uri: string; 6 + document: NormalizedDocument; 7 + drawer: "quotes" | "comments"; 8 + }; 9 + 10 + export const useSelectedPostListing = create<{ 11 + selectedPostListing: SelectedPostListing | null; 12 + setSelectedPostListing: (post: SelectedPostListing | null) => void; 13 + }>((set) => ({ 14 + selectedPostListing: null, 15 + setSelectedPostListing: (post) => set({ selectedPostListing: post }), 16 + }));