Closed hermanp closed 3 years ago
For importing and generating content from JSON (search hugo json to md OR markdown
):
Seems rather complicated. :confused: :expressionless: Rather just generate at need the markdown file by R. So currently I see two possibility:
/data
folder. Just copy the (out of this project) generated file into the relevant (Resource) content folder :heavy_check_mark: Oh, man! To make \<details> nested and treeview like, I would have to use Javascript and CSS? Maybe at the next iteration. Trying to just parse the JSON file to a nested unordered HTML markdown list.
I feel miserable. After so much work the end product is not a big deal... However, better than nothing. The process is somehow documented in the following two Stack Overflow posts:
As for the favicons: I modified the code to make it able to download them, however it is not what I expected.
fake-favicon-uri:
string and sometimes missing. Most of the times seems good.iconuri
field, then I can construct it from the host name. I have done this, but many times this leads to redirection (eg. HTTP status code 301) or not found (status code 404) and even when found, its content type are diverse. Data (from 404 favicons in my bookmarks):Status code | Count |
---|---|
200 | 356 |
404 | 47 |
503 | 1 |
HTTP content type | Count |
---|---|
image/png | 182 |
text/html | 57 |
image/vnd.microsoft.icon | 79 |
image/x-icon | 72 |
text/plain | 1 |
image/svg+xml | 6 |
image/jpeg | 4 |
image/icon | 1 |
application/xhtml+xml | 1 |
image/gif | 1 |
There were only 10 errors during downloading favicons.
- # Info
and - ## Python
Next thing to do is: make it transparent or get rid of the list item markers before those list items, which are headings. This seems like a CSS question. Hints:
hugo remove list item marker css
hugo css for a specific page
remove marker nested list certain level item css
style certain level nested list item css
OK. Seems this tale ends here. What I wanted above is what should be called parent selector, which is not implemented yet. (But in draft phase, see: :has() - Mozilla Developer Network). Tried to twist the logic for selecting, but can not be done. Relevant questions:
Decided to remove the list item markers altogether.
The list item markers removed from all of the Resources pages, but not from the Post pages. Because there is bigger need for them than the excess of them. Visual evidence:
I needed to revert the CSS modification 8d39fc450b98123f3a823524ed79b79ed844cde2.
Requested feature
I want to show my bookmarks :bookmark: on a page in the Resources menu. This will force me to keep them tidy and also let others knew what I am interested in. I do not want all my bookmarks to show up, just part of them.
Context
This widget is called treeview, but similar effect can be achieved with the accordion. The look should be something similar to a directory treeview or somehow it should be foldable. It would be good to have a description or "story" of the bookmark, this should be like an HTML tooltip (title attribute) or another level of folding or just display it without any hassle. Would be nice to display the bookmark's favicon also.
Search history
:arrow_forward: Something like Windows Explorer's file tree? It's a tree graph, maybe "graph" should help :next_track_button: "windows explorer file tree graph" :arrow_down_small: Tree view of a directory/folder in Windows? - Stack Overflow :arrow_up_small: :twisted_rightwards_arrows:
:next_track_button: Google search:
hugo collapsible markdown
Suggestion
Preferably without JavaScript, just plain CSS and HTML.
HTML?), source for importing and working with JSON in R:x: treeview or accordion widget :x: description of each bookmark - this page has to be version controlled because of updates of bookmarks. If the markdown is edited after generated, then it won't be automatic, therefore this feature is discarded. Maybe they can be discussed in separate blog posts. :x: favicon