anentrypoint-design 0.0.102 → 0.0.103

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.
Files changed (78) hide show
  1. package/app-shell.css +464 -2005
  2. package/colors_and_type.css +140 -626
  3. package/dist/247420.css +578 -2749
  4. package/dist/247420.js +23 -62
  5. package/package.json +22 -23
  6. package/src/bootstrap.js +5 -18
  7. package/src/components/chat.js +15 -15
  8. package/src/components/community.js +9 -7
  9. package/src/components/content.js +71 -54
  10. package/src/components/files-modals.js +4 -2
  11. package/src/components/files.js +6 -14
  12. package/src/components/freddie/helpers.js +38 -77
  13. package/src/components/freddie.js +32 -16
  14. package/src/components/shell.js +22 -15
  15. package/src/components.js +7 -3
  16. package/src/debug.js +21 -30
  17. package/src/deck-stage.js +10 -6
  18. package/src/highlight.js +25 -11
  19. package/src/index.js +29 -5
  20. package/src/{desktop → kits/os}/freddie/helpers.js +1 -1
  21. package/src/{desktop → kits/os}/freddie/pages-chat.js +2 -2
  22. package/src/{desktop → kits/os}/freddie/pages-core.js +2 -2
  23. package/src/{desktop → kits/os}/freddie/pages-os.js +1 -1
  24. package/src/{desktop → kits/os}/freddie/pages-tools.js +2 -2
  25. package/src/{desktop → kits/os}/freddie-dashboard.js +2 -2
  26. package/src/markdown.js +27 -49
  27. package/src/motion.js +30 -17
  28. package/src/page-html.js +18 -116
  29. package/src/styles.js +14 -22
  30. package/src/web-components/ds-chat.js +24 -56
  31. package/dist/247420.app.js +0 -5
  32. package/dist/fonts/archivo_v25_k3k6o8UDI-1M0wlSV9XAw6lQkqWY8Q82sJaRE-NWIDdgffTT0zRp8A.ttf +0 -0
  33. package/dist/fonts/archivo_v25_k3k6o8UDI-1M0wlSV9XAw6lQkqWY8Q82sJaRE-NWIDdgffTT6jRp8A.ttf +0 -0
  34. package/dist/fonts/archivo_v25_k3k6o8UDI-1M0wlSV9XAw6lQkqWY8Q82sJaRE-NWIDdgffTTBjNp8A.ttf +0 -0
  35. package/dist/fonts/archivo_v25_k3k6o8UDI-1M0wlSV9XAw6lQkqWY8Q82sJaRE-NWIDdgffTTNDNp8A.ttf +0 -0
  36. package/dist/fonts/archivo_v25_k3k6o8UDI-1M0wlSV9XAw6lQkqWY8Q82sJaRE-NWIDdgffTTnTRp8A.ttf +0 -0
  37. package/dist/fonts/archivo_v25_k3k6o8UDI-1M0wlSV9XAw6lQkqWY8Q82sJaRE-NWIDdgffTTtDRp8A.ttf +0 -0
  38. package/dist/fonts/archivonarrow_v35_tss5ApVBdCYD5Q7hcxTE1ArZ0Zz8oY2KRmwvKhhv8laKpA.ttf +0 -0
  39. package/dist/fonts/archivonarrow_v35_tss5ApVBdCYD5Q7hcxTE1ArZ0Zz8oY2KRmwvKhhvHlGKpA.ttf +0 -0
  40. package/dist/fonts/archivonarrow_v35_tss5ApVBdCYD5Q7hcxTE1ArZ0Zz8oY2KRmwvKhhvLFGKpA.ttf +0 -0
  41. package/dist/fonts/archivonarrow_v35_tss5ApVBdCYD5Q7hcxTE1ArZ0Zz8oY2KRmwvKhhvy1aKpA.ttf +0 -0
  42. package/dist/fonts/jetbrainsmono_v24_tDbY2o-flEEny0FZhsfKu5WU4zr3E_BX0PnT8RD8-qxjPQ.ttf +0 -0
  43. package/dist/fonts/jetbrainsmono_v24_tDbY2o-flEEny0FZhsfKu5WU4zr3E_BX0PnT8RD8FqtjPQ.ttf +0 -0
  44. package/dist/fonts/jetbrainsmono_v24_tDbY2o-flEEny0FZhsfKu5WU4zr3E_BX0PnT8RD8L6tjPQ.ttf +0 -0
  45. package/dist/fonts/jetbrainsmono_v24_tDbY2o-flEEny0FZhsfKu5WU4zr3E_BX0PnT8RD8yKxjPQ.ttf +0 -0
  46. package/dist/fonts/jetbrainsmono_v24_tDba2o-flEEny0FZhsfKu5WU4xD-IQ-PuZJJXxfpAO-LflOQ.ttf +0 -0
  47. package/dist/fonts/jetbrainsmono_v24_tDba2o-flEEny0FZhsfKu5WU4xD-IQ-PuZJJXxfpAO9seVOQ.ttf +0 -0
  48. package/dist/fonts/spacegrotesk_v22_V8mQoQDjQSkFtoMM3T6r8E7mF71Q-gOoraIAEj42Vksj.ttf +0 -0
  49. package/dist/fonts/spacegrotesk_v22_V8mQoQDjQSkFtoMM3T6r8E7mF71Q-gOoraIAEj4PVksj.ttf +0 -0
  50. package/dist/fonts/spacegrotesk_v22_V8mQoQDjQSkFtoMM3T6r8E7mF71Q-gOoraIAEj7aUUsj.ttf +0 -0
  51. package/dist/fonts/spacegrotesk_v22_V8mQoQDjQSkFtoMM3T6r8E7mF71Q-gOoraIAEj7oUUsj.ttf +0 -0
  52. package/src/app.js +0 -156
  53. package/src/components/freddie/pages-chains.js +0 -168
  54. package/src/components/freddie/pages-chat.js +0 -122
  55. package/src/components/freddie/pages-config-edit.js +0 -174
  56. package/src/components/freddie/pages-config.js +0 -193
  57. package/src/components/freddie/pages-core.js +0 -170
  58. package/src/components/freddie/pages-runtime.js +0 -69
  59. package/src/components/freddie/pages-voice.js +0 -109
  60. package/src/web-components/freddie-chat.js +0 -34
  61. /package/src/{desktop → kits/os}/about-app.js +0 -0
  62. /package/src/{desktop → kits/os}/app-panes.css +0 -0
  63. /package/src/{desktop → kits/os}/browser-app.js +0 -0
  64. /package/src/{desktop → kits/os}/files-app.js +0 -0
  65. /package/src/{desktop → kits/os}/freddie/routes.js +0 -0
  66. /package/src/{desktop → kits/os}/freddie-dashboard.css +0 -0
  67. /package/src/{desktop → kits/os}/icons.js +0 -0
  68. /package/src/{desktop → kits/os}/index.js +0 -0
  69. /package/src/{desktop → kits/os}/launcher.css +0 -0
  70. /package/src/{desktop → kits/os}/launcher.js +0 -0
  71. /package/src/{desktop → kits/os}/monitor-app.js +0 -0
  72. /package/src/{desktop → kits/os}/shell.js +0 -0
  73. /package/src/{desktop → kits/os}/terminal-app.js +0 -0
  74. /package/src/{desktop → kits/os}/theme.css +0 -0
  75. /package/src/{desktop → kits/os}/validate.css +0 -0
  76. /package/src/{desktop → kits/os}/validator-app.js +0 -0
  77. /package/src/{desktop → kits/os}/wm.css +0 -0
  78. /package/src/{desktop → kits/os}/wm.js +0 -0
@@ -1,109 +0,0 @@
1
- import * as webjsx from '../../../vendor/webjsx/index.js';
2
- import { Panel, Hero, Receipt, Kpi } from '../content.js';
3
- import { Chip } from '../shell.js';
4
- import { EmptyState } from '../files.js';
5
- const h = webjsx.createElement;
6
-
7
- function getState() {
8
- return window.__fd_voice = window.__fd_voice || {
9
- listening: false, supported: null, transcript: [], partial: '',
10
- ttsText: '', ttsBusy: false, ttsErr: null, voice: 'alloy', recogn: null
11
- };
12
- }
13
-
14
- function rerender() { if (typeof window.__fd_nav === 'function') window.__fd_nav('voice'); }
15
-
16
- function ensureRecognizer(s) {
17
- if (s.recogn) return s.recogn;
18
- const SR = window.SpeechRecognition || window.webkitSpeechRecognition;
19
- if (!SR) { s.supported = false; return null; }
20
- s.supported = true;
21
- const r = new SR();
22
- r.continuous = true; r.interimResults = true; r.lang = 'en-US';
23
- r.onresult = ev => {
24
- let finals = '', partial = '';
25
- for (let i = ev.resultIndex; i < ev.results.length; i++) {
26
- const t = ev.results[i][0].transcript;
27
- if (ev.results[i].isFinal) finals += t; else partial += t;
28
- }
29
- if (finals) s.transcript.push({ text: finals.trim(), ts: Date.now() });
30
- s.partial = partial.trim();
31
- rerender();
32
- };
33
- r.onend = () => { if (s.listening) { try { r.start(); } catch {} } };
34
- r.onerror = e => { s.partial = '(' + (e.error || 'mic error') + ')'; rerender(); };
35
- s.recogn = r; return r;
36
- }
37
-
38
- function toggleListen(s) {
39
- const r = ensureRecognizer(s);
40
- if (!r) return;
41
- s.listening = !s.listening;
42
- if (s.listening) { try { r.start(); } catch {} } else { try { r.stop(); } catch {} }
43
- rerender();
44
- }
45
-
46
- async function speakText(s) {
47
- const text = s.ttsText.trim(); if (!text) return;
48
- s.ttsBusy = true; s.ttsErr = null; rerender();
49
- try {
50
- if ('speechSynthesis' in window) {
51
- const u = new SpeechSynthesisUtterance(text);
52
- u.onend = () => { s.ttsBusy = false; rerender(); };
53
- u.onerror = e => { s.ttsBusy = false; s.ttsErr = String(e.error || 'tts error'); rerender(); };
54
- window.speechSynthesis.speak(u);
55
- } else { s.ttsBusy = false; s.ttsErr = 'no speechSynthesis API in this browser'; rerender(); }
56
- } catch (e) { s.ttsBusy = false; s.ttsErr = e.message || String(e); rerender(); }
57
- }
58
-
59
- function clearLog(s) { s.transcript = []; s.partial = ''; rerender(); }
60
-
61
- export async function voice(h0) {
62
- const s = getState();
63
- const supported = ('SpeechRecognition' in window) || ('webkitSpeechRecognition' in window);
64
- const ttsSupported = 'speechSynthesis' in window;
65
- const lines = s.transcript.slice(-50);
66
- const tones = { listening: 'ok', idle: 'neutral', off: 'miss' };
67
-
68
- const micPanel = !supported
69
- ? Panel({ title: 'microphone', children: EmptyState({ text: 'this browser does not expose Web Speech API. try chrome or edge.', glyph: '⏚' }) })
70
- : Panel({ title: 'microphone', right: Chip({ tone: s.listening ? tones.listening : tones.idle, children: s.listening ? 'listening ●' : 'idle ○' }),
71
- children: [
72
- h('div', { class: 'fd-voice-controls' },
73
- h('button', { class: s.listening ? 'btn-primary' : 'btn-primary', 'aria-label': s.listening ? 'stop listening' : 'start listening', onclick: ev => { ev.preventDefault(); toggleListen(s); } }, s.listening ? 'stop' : 'start'),
74
- h('button', { class: 'btn', 'aria-label': 'clear transcript', onclick: ev => { ev.preventDefault(); clearLog(s); }, disabled: lines.length === 0 ? 'true' : null }, 'clear'),
75
- s.partial ? h('span', { class: 'fd-voice-partial' }, '… ' + s.partial) : null
76
- ),
77
- lines.length === 0 && !s.partial
78
- ? EmptyState({ text: s.listening ? 'listening — speak into your mic' : 'press start to capture speech', glyph: '◌' })
79
- : h('div', { class: 'fd-list', role: 'log', 'aria-live': 'polite' },
80
- ...lines.map((it, i) => h('div', { key: i, class: 'fd-list-row', 'data-cat': 'doc' },
81
- h('span', { class: 'fd-list-code' }, new Date(it.ts).toLocaleTimeString().slice(0,8)),
82
- h('div', { class: 'fd-list-main' }, h('div', { class: 'fd-list-title' }, it.text))
83
- )))
84
- ] });
85
-
86
- const ttsPanel = !ttsSupported
87
- ? Panel({ title: 'speak', children: EmptyState({ text: 'no speechSynthesis API in this browser.', glyph: '⏚' }) })
88
- : Panel({ title: 'speak', right: s.ttsErr ? Chip({ tone: 'miss', children: 'error' }) : Chip({ tone: s.ttsBusy ? 'warn' : 'neutral', children: s.ttsBusy ? 'speaking' : 'idle' }),
89
- children: h('form', { class: 'fd-voice-tts', onsubmit: ev => { ev.preventDefault(); speakText(s); } },
90
- h('label', { class: 'fd-label', for: 'fd-tts-text' }, 'text to speak'),
91
- h('textarea', { id: 'fd-tts-text', name: 'tts', rows: 3, placeholder: 'type something…', value: s.ttsText, oninput: ev => { s.ttsText = ev.target.value; } }),
92
- h('div', { class: 'fd-voice-controls' },
93
- h('button', { type: 'submit', class: 'btn-primary', disabled: s.ttsBusy ? 'true' : null }, s.ttsBusy ? '…' : 'speak'),
94
- s.ttsErr ? h('span', { class: 'fd-muted' }, s.ttsErr) : null
95
- )) });
96
-
97
- return [
98
- Hero({ title: 'voice', body: 'speak in, hear out. browser-native speech recognition + synthesis.', accent: s.listening ? 'listening' : (lines.length ? lines.length+' utterances' : 'idle') }),
99
- Kpi({ items: [[lines.length,'utterances'],[supported ? '●' : '○','recognition'],[ttsSupported ? '●' : '○','synthesis']] }),
100
- micPanel,
101
- ttsPanel,
102
- Panel({ title: 'how this works', children: Receipt({ rows: [
103
- ['recognition', 'webkit Speech API · client-side, no server'],
104
- ['synthesis', 'speechSynthesis API · client-side, OS voice'],
105
- ['server tts tool', 'plugins/tts (OpenAI tts-1 / ElevenLabs) · runs in agent context'],
106
- ['voice_mode tool', 'plugins/voice_mode · toggles full-duplex on a session']
107
- ] }) })
108
- ];
109
- }
@@ -1,34 +0,0 @@
1
- import { DsChat, registerChatElement } from './ds-chat.js';
2
- import { register } from '../debug.js';
3
-
4
- let _stats = { mounts: 0, sends: 0 };
5
-
6
- class FreddieChat extends DsChat {
7
- constructor() {
8
- super();
9
- this._title = 'freddie';
10
- this._sub = '';
11
- this._placeholder = 'message freddie · /tools · /tool name {json} · /run …';
12
- }
13
-
14
- connectedCallback() {
15
- _stats.mounts += 1;
16
- super.connectedCallback();
17
- }
18
- }
19
-
20
- let _registered = false;
21
- export function registerFreddieChatElement() {
22
- registerChatElement();
23
- if (_registered) return;
24
- if (!customElements.get('freddie-chat')) customElements.define('freddie-chat', FreddieChat);
25
- _registered = true;
26
- }
27
-
28
- if (typeof window !== 'undefined' && typeof customElements !== 'undefined') {
29
- registerFreddieChatElement();
30
- }
31
-
32
- register('freddie-chat', () => ({ registered: _registered, ..._stats, instances: document.querySelectorAll('freddie-chat').length }));
33
-
34
- export { FreddieChat };
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes