a tool for shared writing and social publishing

add iosbs and focus editor on placeholder click

+4 -2
+4 -2
app/[leaflet_id]/publish/BskyPostEditorProsemirror.tsx
··· 18 import { history, undo, redo } from "prosemirror-history"; 19 import { inputRules, InputRule } from "prosemirror-inputrules"; 20 import { autolink } from "components/Blocks/TextBlock/autolink-plugin"; 21 22 // Schema with only links, mentions, and hashtags marks 23 const bskyPostSchema = new Schema({ ··· 258 }, [handleMentionSelect]); 259 260 return ( 261 - <div className="relative w-full h-full"> 262 {editorState && ( 263 <MentionAutocomplete 264 editorState={editorState} ··· 270 /> 271 )} 272 {editorState?.doc.textContent.length === 0 && ( 273 - <div className="italic text-tertiary absolute top-0 left-0"> 274 Write a post to share your writing! 275 </div> 276 )} ··· 282 overflowWrap: "break-word", 283 }} 284 /> 285 </div> 286 ); 287 }
··· 18 import { history, undo, redo } from "prosemirror-history"; 19 import { inputRules, InputRule } from "prosemirror-inputrules"; 20 import { autolink } from "components/Blocks/TextBlock/autolink-plugin"; 21 + import { IOSBS } from "app/lish/[did]/[publication]/[rkey]/Interactions/Comments/CommentBox"; 22 23 // Schema with only links, mentions, and hashtags marks 24 const bskyPostSchema = new Schema({ ··· 259 }, [handleMentionSelect]); 260 261 return ( 262 + <div className="relative w-full h-full group"> 263 {editorState && ( 264 <MentionAutocomplete 265 editorState={editorState} ··· 271 /> 272 )} 273 {editorState?.doc.textContent.length === 0 && ( 274 + <div className="italic text-tertiary absolute top-0 left-0 pointer-events-none"> 275 Write a post to share your writing! 276 </div> 277 )} ··· 283 overflowWrap: "break-word", 284 }} 285 /> 286 + <IOSBS view={viewRef} /> 287 </div> 288 ); 289 }