Tasks extraction
aka Checklist, TODO
Introduction
Imagine you are writing an article and have a checklist of what else you want to cover in the article.
On one hand, it is convenient to keep this checklist in the article itself. On the other hand, you may want to see all tasks at a glance. With the help of BrainDB, it is possible to extract all tasks from all pages and list them on one page.
Installation
-
Install BrainDB
-
Create
TaskList
component -
Use component, wherever you like
Limitations
For now, I have implemented the bare minimum for task extraction in BrainDB. These are the limitations that I want to address in the future.
Limitation 1: flat list
BrainDB will return this as a flat list instead of a hierarchical structure:
Limitation 2: text only
BrainDB can return Markdown for the content of the task, but for now, I havenβt figured out a good way to render it with Astro. I use plain text instead:
Limitation 3: no subitems
For now, BrainDB returns only the content of the task, but not the subitems:
Example
This is an example of <TaskList />
output π
-
Create a Rehype plugin to wrap images in a container (
<figure class="beoe"></figure>
) to avoid creating it on the client side. - Do not stretch images if they are smaller than viewport
- Prevent clicks on drag or pan
- minimap and full-screen mode, like in reactflow β
-
sitemap β
(
lastmod
) - in the Sidebar to show "new" badge
- add other favicon providers β
- Highlighting of nodes or edges
- Search/filter by labels
- Show labels for tags on the graph.
- Create an example with Client-side content graph
- Render as partials and fetch from the server instead of prerendering, because there are too many DOM nodes.
- Tabs should preserve state across navigations.
-
The scroll area should be inside the
TabItem
.
-
Plugin that places sitemap URL in
robots.txt
(astro-robots-txt
) - Use the "updated at" date in the sitemap (so search engines would rescan those pages first)
- Check that anchors correspond to a header in the target document.
-
What about ambiguous links (
bdb.documentsSync({ slug: permalink }).length > 1
)? -
Image wikilinks (
![[some.jpg]]
)
- Generate a gradient based on tag colors
- Page for each tag
- Metadata for tags (color, icon)
-
Remove the
Graphviz
component from the repo; need to use@beoe/astro-graphviz
instead.
- Links for nodes
- Zoom behavior is a bit annoying; is there a way to customize it?
- Tags probably should have a constant size or damping factor; otherwise, they will always be the biggest nodes.
- On node hover, highlight neighbor nodes and connecting edges.
- If there were metadata for tags or pages, like color or icon, it could be used for graph visualization.
-
I can still use
facets
orpagefind
, but I need a different UI. - Other potential fields for facets:
- Sort by:
- Handle non-HTML links (images, PDFs).
-
Fix bug: it crashes if there are missing header levels, like
h4
directly underh2
. - Fix "snake" styles.