diff --git a/src/assets/css/fonts.css b/src/assets/css/fonts.css
index af57437..2c2d0c2 100644
--- a/src/assets/css/fonts.css
+++ b/src/assets/css/fonts.css
@@ -32,3 +32,8 @@
font-family: 'Parkinsans';
src: url('../../assets/fonts/Parkinsans-VariableFont.ttf');
}
+
+@font-face {
+ font-family: 'JetBrains Mono';
+ src: url('../../assets/fonts/JetBrainsMono-VariableFont.ttf');
+}
diff --git a/src/assets/fonts/JetBrainsMono-VariableFont.ttf b/src/assets/fonts/JetBrainsMono-VariableFont.ttf
new file mode 100644
index 0000000..1b3d7f2
Binary files /dev/null and b/src/assets/fonts/JetBrainsMono-VariableFont.ttf differ
diff --git a/src/lib/components/icons/Brave.svelte b/src/lib/components/icons/Brave.svelte
new file mode 100644
index 0000000..5478d11
--- /dev/null
+++ b/src/lib/components/icons/Brave.svelte
@@ -0,0 +1,6 @@
+
diff --git a/src/lib/components/icons/DuckDuckGo.svelte b/src/lib/components/icons/DuckDuckGo.svelte
new file mode 100644
index 0000000..376ee3f
--- /dev/null
+++ b/src/lib/components/icons/DuckDuckGo.svelte
@@ -0,0 +1,6 @@
+
diff --git a/src/lib/components/icons/Google.svelte b/src/lib/components/icons/Google.svelte
new file mode 100644
index 0000000..e5aa04d
--- /dev/null
+++ b/src/lib/components/icons/Google.svelte
@@ -0,0 +1,6 @@
+
diff --git a/src/lib/components/icons/GoogleLine.svelte b/src/lib/components/icons/GoogleLine.svelte
deleted file mode 100644
index 45c9686..0000000
--- a/src/lib/components/icons/GoogleLine.svelte
+++ /dev/null
@@ -1,6 +0,0 @@
-
diff --git a/src/lib/components/icons/MicrosoftBing.svelte b/src/lib/components/icons/MicrosoftBing.svelte
new file mode 100644
index 0000000..b927625
--- /dev/null
+++ b/src/lib/components/icons/MicrosoftBing.svelte
@@ -0,0 +1,6 @@
+
diff --git a/src/lib/components/icons/Yahoo.svelte b/src/lib/components/icons/Yahoo.svelte
new file mode 100644
index 0000000..c61a498
--- /dev/null
+++ b/src/lib/components/icons/Yahoo.svelte
@@ -0,0 +1,6 @@
+
diff --git a/src/lib/components/menubar/SearchMenu.svelte b/src/lib/components/menubar/SearchMenu.svelte
index bc7ec1d..44e08f8 100644
--- a/src/lib/components/menubar/SearchMenu.svelte
+++ b/src/lib/components/menubar/SearchMenu.svelte
@@ -1,5 +1,9 @@
@@ -14,9 +18,30 @@
Go ToCtrl+G
- Notpad.searchOptions.searchOnWeb()}>
- Search on Google
-
-
+
+ Search on
+
+ Notpad.searchOptions.searchOnWeb('google')}>
+ Google
+
+
+ Notpad.searchOptions.searchOnWeb('bing')}>
+ Bing
+
+
+ Notpad.searchOptions.searchOnWeb('duckduckgo')}>
+ DuckDuckGo
+
+
+ Notpad.searchOptions.searchOnWeb('yahoo')}>
+ Yahoo
+
+
+ Notpad.searchOptions.searchOnWeb('brave')}>
+ Brave Search
+
+
+
+
diff --git a/src/lib/helpers/menubar/search-options.ts b/src/lib/helpers/menubar/search-options.ts
index 8b1dbc8..aeb4e0d 100644
--- a/src/lib/helpers/menubar/search-options.ts
+++ b/src/lib/helpers/menubar/search-options.ts
@@ -5,7 +5,15 @@ import { isTauri } from '@/src/lib';
import { open as tauriLaunchUrl } from '@tauri-apps/plugin-shell';
export class SearchOptions {
- public searchOnWeb = (editorId?: string) => {
+ private searchEngines = {
+ google: 'google.com/search',
+ bing: 'bing.com/search',
+ duckduckgo: 'duckduckgo.com/',
+ yahoo: 'search.yahoo.com/search',
+ brave: 'search.brave.com/search'
+ } as const;
+
+ public searchOnWeb = (searchEngine: keyof typeof this.searchEngines, editorId?: string) => {
const editor = Notpad.editors.getEditor(editorId);
if (!editor) return;
@@ -16,7 +24,7 @@ export class SearchOptions {
selectedText = selectedText?.trim();
if (!selectedText) return Notpad.showError('Please select some text to search on the web.');
- const url = `https://www.google.com/search?q=${encodeURIComponent(selectedText)}`;
+ const url = `https://${this.searchEngines[searchEngine]}?q=${encodeURIComponent(selectedText)}`;
if (isTauri) {
tauriLaunchUrl(url);
diff --git a/src/lib/helpers/settings.ts b/src/lib/helpers/settings.ts
index 58e6fa2..d977fee 100644
--- a/src/lib/helpers/settings.ts
+++ b/src/lib/helpers/settings.ts
@@ -22,7 +22,8 @@ export class Settings {
'Lora',
'Roboto Slab',
'Inconsolata',
- 'Parkinsans'
+ 'Parkinsans',
+ 'JetBrains Mono'
] as const;
static fontSizes = [6, 7, 8, 9, 10, 11, 12, 14, 16, 18, 20, 22, 24, 26, 28, 36, 48, 72] as const;
static zooms = [0.5, 0.75, 0.9, 1, 1.2, 1.5, 1.75, 2] as const;