termsearch 0.3.5 → 0.3.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/termsearch.js CHANGED
@@ -376,7 +376,7 @@ async function cmdAutostart(sub) {
376
376
  async function cmdDefault(flags) {
377
377
  const { running, pid } = getStatus();
378
378
  if (running) {
379
- cmdStatus();
379
+ await cmdStatus();
380
380
  } else {
381
381
  await cmdStart(flags);
382
382
  if (getStatus().running) {
@@ -267,6 +267,7 @@ const AI_PRESETS = [
267
267
  { id: 'chutes', label: 'Chutes.ai TEE', api_base: 'https://llm.chutes.ai/v1', keyRequired: true, defaultModel: 'deepseek-ai/DeepSeek-V3.2-TEE' },
268
268
  { id: 'anthropic',label: 'Anthropic', api_base: 'https://api.anthropic.com/v1', keyRequired: true, defaultModel: 'claude-3-5-haiku-latest' },
269
269
  { id: 'openai', label: 'OpenAI', api_base: 'https://api.openai.com/v1', keyRequired: true, defaultModel: 'gpt-4o-mini' },
270
+ { id: 'openrouter', label: 'OpenRoute/OpenRouter', api_base: 'https://openrouter.ai/api/v1', keyRequired: true, defaultModel: 'openai/gpt-4o-mini' },
270
271
  ];
271
272
 
272
273
  const ENGINE_GROUPS = [
@@ -1053,12 +1054,12 @@ function renderApp() {
1053
1054
  const mobileBar = el('div', { className: 'mobile-bar' },
1054
1055
  el('div', { className: 'mobile-bar-search' }, SearchForm(state.query, (q, cat) => { state.query = q; doSearch(q, cat); })),
1055
1056
  mobileTabs,
1057
+ el('div', { className: 'mobile-bar-engine' }, EnginePicker()),
1056
1058
  el('div', { className: 'mobile-bar-row' },
1057
1059
  el('div', {
1058
1060
  className: 'mobile-logo',
1059
1061
  onClick: () => { state.query = ''; state.category = 'web'; navigate('#/'); renderApp(); },
1060
1062
  }, 'Term', el('strong', {}, 'Search')),
1061
- EnginePicker(),
1062
1063
  LangPicker(),
1063
1064
  el('button', { className: 'btn-icon', title: 'Settings', onClick: () => navigate('#/settings') }, iconEl('settings')),
1064
1065
  el('button', { className: 'btn-icon', title: 'Toggle theme', onClick: toggleTheme }, iconEl('theme')),
@@ -1475,7 +1476,7 @@ async function renderSettings() {
1475
1476
  el('label', { className: 'form-label', for: 'ai-base' }, 'API Endpoint'),
1476
1477
  makeInput('ai-base', ai.api_base, 'http://localhost:11434/v1'),
1477
1478
  el('div', { className: 'form-hint' },
1478
- 'Included presets: LocalHost (Ollama · LM Studio · llama.cpp) · Chutes.ai TEE · Anthropic · OpenAI',
1479
+ 'Included presets: LocalHost (Ollama · LM Studio · llama.cpp) · Chutes.ai TEE · Anthropic · OpenAI · OpenRoute/OpenRouter',
1479
1480
  el('br', {}),
1480
1481
  'You can also keep custom OpenAI-compatible endpoints.',
1481
1482
  ),
@@ -962,13 +962,13 @@ a:hover { color: var(--link-h); }
962
962
  scrollbar-width: none;
963
963
  }
964
964
  .mobile-bar-tabs::-webkit-scrollbar { display: none; }
965
+ .mobile-bar-engine { padding: 0 12px 4px; }
965
966
  .mobile-bar-row {
966
967
  display: flex;
967
968
  align-items: center;
968
969
  gap: 6px;
969
970
  padding: 4px 12px 2px;
970
971
  }
971
- .mobile-bar-row .engine-picker { flex-shrink: 0; }
972
972
  .mobile-bar-row .lang-wrap { margin-left: auto; }
973
973
 
974
974
  /* ─── Responsive ──────────────────────────────────────────────────────────── */
@@ -978,7 +978,8 @@ a:hover { color: var(--link-h); }
978
978
  .main { padding-bottom: calc(20px + var(--mobile-bar-height, 0px) + env(safe-area-inset-bottom, 0px)); }
979
979
 
980
980
  .cat-tab { font-size: 10px; padding: 4px 8px; }
981
- .mobile-bar-row .engine-picker-summary { font-size: 11px; padding: 3px 6px; }
981
+ .mobile-bar-engine .engine-picker { width: 100%; margin-left: 0; }
982
+ .mobile-bar-engine .engine-picker-summary { width: 100%; justify-content: space-between; }
982
983
  .engine-picker-body { width: calc(100vw - 24px); right: -6px; bottom: calc(100% + 8px); top: auto; }
983
984
  .logo-text { font-size: 15px; }
984
985
  .home-logo { font-size: 40px; }
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "termsearch",
3
- "version": "0.3.5",
3
+ "version": "0.3.6",
4
4
  "description": "Personal search engine for Termux/Linux/macOS — zero-config, privacy-first, AI-optional",
5
5
  "type": "module",
6
6
  "bin": {
7
- "termsearch": "./bin/termsearch.js"
7
+ "termsearch": "bin/termsearch.js"
8
8
  },
9
9
  "main": "./src/server.js",
10
10
  "files": [
@@ -43,6 +43,6 @@
43
43
  "license": "MIT",
44
44
  "repository": {
45
45
  "type": "git",
46
- "url": "https://github.com/DioNanos/termsearch"
46
+ "url": "git+https://github.com/DioNanos/termsearch.git"
47
47
  }
48
48
  }