Skip to content

Add Support for Working on Learning Maps #26

@mikebarkmin

Description

@mikebarkmin

Overview

Currently the web project supports creating learning maps. We want to add support for working on learning maps.

Implementation Requirements

New Route

  • Create a new route at /learn
  • This route should display the LearningMap component
  • The route must support a json parameter in the URL hash

Example URL:

https://www.learningmap.app/learn/#json=iIhK7sHqL-EMWp9OM5_-q

Data Loading

Roadmap Data

  • Load roadmapData from the jsonStore
  • Store the complete roadmapData in localStorage using Zustand persist to avoid refetching on page reload

Initial State

  • Load initialState from localStorage using Zustand persist
  • Each roadmapState should be saved under the key of the json parameter
    • Example: For URL #json=iIhK7sHqL-EMWp9OM5_-q, the state key would be iIhK7sHqL-EMWp9OM5_-q
  • This approach ensures multiple learning maps can be worked on simultaneously with separate states

Learning Maps List View

When no json parameter is present in the URL, display a page that shows:

  1. List of all learning maps currently stored in localStorage
  2. Input field with the ability to paste a learning map URL to add a new learning map to the list

Benefits

  • Enables users to work on multiple learning maps
  • Persists progress across page reloads
  • Provides a centralized view of all learning maps being worked on

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions