Browse Source

tweak bookmarks bar multilanguage fix

main
familyfriendlymikey 2 years ago
parent
commit
55278f7e37
  1. 5
      package-lock.json
  2. 7
      src/main.imba

5
package-lock.json

@ -8,6 +8,7 @@
"name": "fuzzyhome", "name": "fuzzyhome",
"version": "1.0.0", "version": "1.0.0",
"dependencies": { "dependencies": {
"esbuild-darwin-arm64": "^0.15.18",
"fzi": "^1.5.0", "fzi": "^1.5.0",
"imba": "^2.0.0-alpha.225", "imba": "^2.0.0-alpha.225",
"lodash": "^4.17.21", "lodash": "^4.17.21",
@ -891,7 +892,6 @@
"cpu": [ "cpu": [
"arm64" "arm64"
], ],
"optional": true,
"os": [ "os": [
"darwin" "darwin"
], ],
@ -3438,8 +3438,7 @@
"esbuild-darwin-arm64": { "esbuild-darwin-arm64": {
"version": "0.15.18", "version": "0.15.18",
"resolved": "https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.15.18.tgz", "resolved": "https://registry.npmjs.org/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.15.18.tgz",
"integrity": "sha512-tKPSxcTJ5OmNb1btVikATJ8NftlyNlc8BVNtyT/UAr62JFOhwHlnoPrhYWz09akBLHI9nElFVfWSTSRsrZiDUA==", "integrity": "sha512-tKPSxcTJ5OmNb1btVikATJ8NftlyNlc8BVNtyT/UAr62JFOhwHlnoPrhYWz09akBLHI9nElFVfWSTSRsrZiDUA=="
"optional": true
}, },
"esbuild-freebsd-64": { "esbuild-freebsd-64": {
"version": "0.15.18", "version": "0.15.18",

7
src/main.imba

@ -38,11 +38,8 @@ def init
Frequencies = frequencies or {} Frequencies = frequencies or {}
global.chrome.bookmarks.getTree! do(bookmarks) global.chrome.bookmarks.getTree! do(bookmarks)
# Bookmarks Bar folder is guaranteed to be the first child of the bookmarks tree root const bookmarks-bar = bookmarks[0].children[0].children
const bookmarkBarTitle = bookmarks[0].children[0].title state.links = api.traverse bookmarks-bar
const folder = api.bfs bookmarkBarTitle, bookmarks
state.links = api.traverse folder
api.sort_links! api.sort_links!
state.loaded = yes state.loaded = yes
imba.commit! imba.commit!

Loading…
Cancel
Save