Skip to content

feat: add document history sidebar and URL-based save states#136

Open
Aryan-git-byte wants to merge 1 commit intotanabe:mainfrom
Aryan-git-byte:main
Open

feat: add document history sidebar and URL-based save states#136
Aryan-git-byte wants to merge 1 commit intotanabe:mainfrom
Aryan-git-byte:main

Conversation

@Aryan-git-byte
Copy link
Copy Markdown

Add Document History Sidebar and URL-Based Save States

This PR transforms the previewer into a multi-document tool by fixing the single-state local storage bottleneck.

Changes:

  • URL-Based State: Documents are now saved to localStorage using unique IDs appended to the URL hash (e.g., /#abc1234), preventing new documents from overwriting existing ones.
  • History Sidebar: Added a collapsible sidebar UI to view, switch between, and delete previous documents.
  • Auto-Index: The app now maintains a docs_index to track creation/update times and automatically pulls the first line of the markdown file to use as the document title.
  • Clean Slate: Cleared the hardcoded defaultInput template so new documents open with a clean editor.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant