Open RangerMauve opened 2 years ago
Have any Idea where one could start from? Maybe some documentation, or some prerequisites ?
Thanks for taking a shot! :)
First you'll want to get acquainted with the codebase. Here's where the history extension lives: https://github.com/AgregoreWeb/extension-agregore-history
If you open up agregore then go to Help > Open Extensions Folder
you should see the local version of the extension if you want to tinker with it directly.
This is how the search bar talks to the history extension: https://github.com/AgregoreWeb/agregore-browser/blob/master/app/history.js
Likely you'll want to add a new page to the extension like view.html
which imports agregore's built in styles at agregore://theme/style.css
From there you'll need to make a search through the indexdb database and render the results in a list of <a>
tags with the title being the text and the url being the href
property so that the link could be visited.
From there you might want to limit to the last 128 results or something and have a "show more" button to render more items.
Please only use vanilla JavaScript with custom elements and no dependencies except the existing idb.js library.
Does that sound like enough info to get you started?
The history extension should add a "view history" page somewhere. It should be served from the extension's path and should have a way to list the history in chronological order.
We should regsiter a button somewhere to open this page. Might be worth it to make it a raw action and to make a window that doesn't have window chrome.