Omnibox keyword search fix, DIY sidePanel, and PowerShell build script #90
Omnibox keyword search fix, DIY sidePanel, and PowerShell build script #90vaimalaviya1233 wants to merge 3 commits intolinkwarden:devfrom
Conversation
Signed-off-by: VaiMalaviya <55515799+vaimalaviya1233@users.noreply.github.com>
Signed-off-by: VaiMalaviya <55515799+vaimalaviya1233@users.noreply.github.com>
Signed-off-by: VaiMalaviya <55515799+vaimalaviya1233@users.noreply.github.com>
There was a problem hiding this comment.
sorry, I can't run sh script on windows that's why i added
| }, | ||
| "omnibox": { | ||
| "keyword": "lk" | ||
| "keyword": "lw" |
There was a problem hiding this comment.
should be "lw" considering it is linkwarden and not linkding
| import OnInputEnteredDisposition = chrome.omnibox.OnInputEnteredDisposition; | ||
|
|
||
| const browser = getBrowser(); | ||
| let configuration = null; // this js needs init function which initializes the configuration variable thus solving many lines in this file which repeadiatly uses getConfig() it might be better |
There was a problem hiding this comment.
i come from the java/kotlin/python so I don't know more of vite/javascript/typescript but this variable needs to be initialized in init function which should be added to this file which also reduces the getConfig() function code.
| const url = isUrl | ||
| ? content | ||
| : `lk`; | ||
| : `${configuration.baseUrl}/search?q=${encodeURIComponent(content)}`; // This part was taken https://github.com/sissbruecker/linkding-extension/blob/master/src/background.js |
| } catch (error) { | ||
| console.error("Failed to reload the side panel:", error); | ||
| } | ||
| }); No newline at end of file |
There was a problem hiding this comment.
ummmm.... i inspected through the background.js console it does execute (see attached image) but chrome.sidePanel.setOptions() function doesn't reload the tab if it's already set to that for that we need to separate the sidepanel page and still i don't know vite so but i'll try to learn vite and implement it via chrome.runtime.onMessage.addListener() which should be able to execute the reload code window.location.reload();
📝:- also you might want to block comment out the both listener functions since they do nothing it was for debug.
|
@crkos thanks for informing to change to dev branch, i tried to add the comments where it was necessary other than that code is ready to test. :)
|
|
Had to recreate the dev branch due to merge conflicts and this one got closed by itself right after. |
ok no problem created draft pr #102 |

Additions
Modifications
Fixes
TODO