markupr 2.1.8 → 2.5.0
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/README.md +292 -15
- package/dist/cli/index.mjs +3593 -0
- package/dist/main/index.mjs +743 -220
- package/dist/mcp/index.mjs +4053 -0
- package/package.json +32 -7
- package/.claude/commands/review-feedback.md +0 -47
- package/.eslintrc.json +0 -35
- package/.github/CODEOWNERS +0 -16
- package/.github/FUNDING.yml +0 -1
- package/.github/ISSUE_TEMPLATE/bug_report.md +0 -56
- package/.github/ISSUE_TEMPLATE/feature_request.md +0 -54
- package/.github/PULL_REQUEST_TEMPLATE.md +0 -89
- package/.github/dependabot.yml +0 -70
- package/.github/workflows/ci.yml +0 -184
- package/.github/workflows/deploy-landing.yml +0 -134
- package/.github/workflows/nightly.yml +0 -288
- package/.github/workflows/release.yml +0 -318
- package/CHANGELOG.md +0 -127
- package/CLAUDE.md +0 -137
- package/CODE_OF_CONDUCT.md +0 -9
- package/CONTRIBUTING.md +0 -390
- package/PRODUCT_VISION.md +0 -277
- package/SECURITY.md +0 -51
- package/SIGNING_INSTRUCTIONS.md +0 -284
- package/assets/DMG_BACKGROUND_INSTRUCTIONS.md +0 -130
- package/assets/svg-source/dmg-background.svg +0 -70
- package/assets/svg-source/icon.svg +0 -20
- package/assets/svg-source/tray-icon-processing.svg +0 -7
- package/assets/svg-source/tray-icon-recording.svg +0 -7
- package/assets/svg-source/tray-icon.svg +0 -6
- package/assets/tray-complete.png +0 -0
- package/assets/tray-complete@2x.png +0 -0
- package/assets/tray-completeTemplate.png +0 -0
- package/assets/tray-completeTemplate@2x.png +0 -0
- package/assets/tray-error.png +0 -0
- package/assets/tray-error@2x.png +0 -0
- package/assets/tray-errorTemplate.png +0 -0
- package/assets/tray-errorTemplate@2x.png +0 -0
- package/assets/tray-icon-processing.png +0 -0
- package/assets/tray-icon-processing@2x.png +0 -0
- package/assets/tray-icon-processingTemplate.png +0 -0
- package/assets/tray-icon-processingTemplate@2x.png +0 -0
- package/assets/tray-icon-recording.png +0 -0
- package/assets/tray-icon-recording@2x.png +0 -0
- package/assets/tray-icon-recordingTemplate.png +0 -0
- package/assets/tray-icon-recordingTemplate@2x.png +0 -0
- package/assets/tray-icon.png +0 -0
- package/assets/tray-icon@2x.png +0 -0
- package/assets/tray-iconTemplate.png +0 -0
- package/assets/tray-iconTemplate@2x.png +0 -0
- package/assets/tray-idle.png +0 -0
- package/assets/tray-idle@2x.png +0 -0
- package/assets/tray-idleTemplate.png +0 -0
- package/assets/tray-idleTemplate@2x.png +0 -0
- package/assets/tray-processing-0.png +0 -0
- package/assets/tray-processing-0@2x.png +0 -0
- package/assets/tray-processing-0Template.png +0 -0
- package/assets/tray-processing-0Template@2x.png +0 -0
- package/assets/tray-processing-1.png +0 -0
- package/assets/tray-processing-1@2x.png +0 -0
- package/assets/tray-processing-1Template.png +0 -0
- package/assets/tray-processing-1Template@2x.png +0 -0
- package/assets/tray-processing-2.png +0 -0
- package/assets/tray-processing-2@2x.png +0 -0
- package/assets/tray-processing-2Template.png +0 -0
- package/assets/tray-processing-2Template@2x.png +0 -0
- package/assets/tray-processing-3.png +0 -0
- package/assets/tray-processing-3@2x.png +0 -0
- package/assets/tray-processing-3Template.png +0 -0
- package/assets/tray-processing-3Template@2x.png +0 -0
- package/assets/tray-processing.png +0 -0
- package/assets/tray-processing@2x.png +0 -0
- package/assets/tray-processingTemplate.png +0 -0
- package/assets/tray-processingTemplate@2x.png +0 -0
- package/assets/tray-recording.png +0 -0
- package/assets/tray-recording@2x.png +0 -0
- package/assets/tray-recordingTemplate.png +0 -0
- package/assets/tray-recordingTemplate@2x.png +0 -0
- package/build/DMG_BACKGROUND_SPEC.md +0 -50
- package/build/dmg-background.png +0 -0
- package/build/dmg-background@2x.png +0 -0
- package/build/entitlements.mac.inherit.plist +0 -27
- package/build/entitlements.mac.plist +0 -41
- package/build/favicon-16.png +0 -0
- package/build/favicon-180.png +0 -0
- package/build/favicon-192.png +0 -0
- package/build/favicon-32.png +0 -0
- package/build/favicon-48.png +0 -0
- package/build/favicon-512.png +0 -0
- package/build/favicon-64.png +0 -0
- package/build/icon-128.png +0 -0
- package/build/icon-16.png +0 -0
- package/build/icon-24.png +0 -0
- package/build/icon-256.png +0 -0
- package/build/icon-32.png +0 -0
- package/build/icon-48.png +0 -0
- package/build/icon-64.png +0 -0
- package/build/icon.icns +0 -0
- package/build/icon.ico +0 -0
- package/build/icon.iconset/icon_128x128.png +0 -0
- package/build/icon.iconset/icon_128x128@2x.png +0 -0
- package/build/icon.iconset/icon_16x16.png +0 -0
- package/build/icon.iconset/icon_16x16@2x.png +0 -0
- package/build/icon.iconset/icon_256x256.png +0 -0
- package/build/icon.iconset/icon_256x256@2x.png +0 -0
- package/build/icon.iconset/icon_32x32.png +0 -0
- package/build/icon.iconset/icon_32x32@2x.png +0 -0
- package/build/icon.iconset/icon_512x512.png +0 -0
- package/build/icon.iconset/icon_512x512@2x.png +0 -0
- package/build/icon.png +0 -0
- package/build/installer-header.bmp +0 -0
- package/build/installer-header.png +0 -0
- package/build/installer-sidebar.bmp +0 -0
- package/build/installer-sidebar.png +0 -0
- package/build/installer.nsh +0 -45
- package/build/overlay-processing.png +0 -0
- package/build/overlay-recording.png +0 -0
- package/build/toolbar-record.png +0 -0
- package/build/toolbar-screenshot.png +0 -0
- package/build/toolbar-settings.png +0 -0
- package/build/toolbar-stop.png +0 -0
- package/dist/preload/index.mjs +0 -907
- package/dist/renderer/assets/index-CCmUjl9K.js +0 -19495
- package/dist/renderer/assets/index-CUqz_Gs6.css +0 -2270
- package/dist/renderer/index.html +0 -27
- package/docs/AI_AGENT_QUICKSTART.md +0 -42
- package/docs/AI_PIPELINE_DESIGN.md +0 -595
- package/docs/API.md +0 -514
- package/docs/ARCHITECTURE.md +0 -460
- package/docs/CONFIGURATION.md +0 -336
- package/docs/DEVELOPMENT.md +0 -508
- package/docs/EXPORT_FORMATS.md +0 -451
- package/docs/GETTING_STARTED.md +0 -236
- package/docs/KEYBOARD_SHORTCUTS.md +0 -334
- package/docs/TROUBLESHOOTING.md +0 -418
- package/docs/landing/index.html +0 -672
- package/docs/landing/script.js +0 -342
- package/docs/landing/styles.css +0 -1543
- package/electron-builder.yml +0 -140
- package/electron.vite.config.ts +0 -63
- package/railway.json +0 -12
- package/scripts/build.mjs +0 -51
- package/scripts/generate-icons.mjs +0 -314
- package/scripts/generate-installer-images.cjs +0 -253
- package/scripts/generate-tray-icons.mjs +0 -258
- package/scripts/notarize.cjs +0 -180
- package/scripts/one-click-clean-test.sh +0 -147
- package/scripts/postinstall.mjs +0 -36
- package/scripts/setup-markupr.sh +0 -55
- package/setup +0 -17
- package/site/index.html +0 -1835
- package/site/package.json +0 -11
- package/site/railway.json +0 -12
- package/site/server.js +0 -31
- package/src/main/AutoUpdater.ts +0 -392
- package/src/main/CrashRecovery.ts +0 -655
- package/src/main/ErrorHandler.ts +0 -703
- package/src/main/HotkeyManager.ts +0 -399
- package/src/main/MenuManager.ts +0 -529
- package/src/main/PermissionManager.ts +0 -420
- package/src/main/SessionController.ts +0 -1465
- package/src/main/TrayManager.ts +0 -540
- package/src/main/ai/AIPipelineManager.ts +0 -199
- package/src/main/ai/ClaudeAnalyzer.ts +0 -339
- package/src/main/ai/ImageOptimizer.ts +0 -176
- package/src/main/ai/StructuredMarkdownBuilder.ts +0 -379
- package/src/main/ai/index.ts +0 -16
- package/src/main/ai/types.ts +0 -258
- package/src/main/analysis/ClarificationGenerator.ts +0 -385
- package/src/main/analysis/FeedbackAnalyzer.ts +0 -531
- package/src/main/analysis/index.ts +0 -19
- package/src/main/audio/AudioCapture.ts +0 -978
- package/src/main/audio/audioUtils.ts +0 -100
- package/src/main/audio/index.ts +0 -20
- package/src/main/capture/index.ts +0 -1
- package/src/main/index.ts +0 -1693
- package/src/main/ipc/captureHandlers.ts +0 -272
- package/src/main/ipc/index.ts +0 -45
- package/src/main/ipc/outputHandlers.ts +0 -302
- package/src/main/ipc/sessionHandlers.ts +0 -56
- package/src/main/ipc/settingsHandlers.ts +0 -471
- package/src/main/ipc/types.ts +0 -56
- package/src/main/ipc/windowHandlers.ts +0 -277
- package/src/main/output/ClipboardService.ts +0 -369
- package/src/main/output/ExportService.ts +0 -539
- package/src/main/output/FileManager.ts +0 -416
- package/src/main/output/MarkdownGenerator.ts +0 -791
- package/src/main/output/MarkdownPatcher.ts +0 -299
- package/src/main/output/index.ts +0 -186
- package/src/main/output/sessionAdapter.ts +0 -207
- package/src/main/output/templates/html-template.ts +0 -553
- package/src/main/pipeline/FrameExtractor.ts +0 -330
- package/src/main/pipeline/PostProcessor.ts +0 -399
- package/src/main/pipeline/TranscriptAnalyzer.ts +0 -226
- package/src/main/pipeline/index.ts +0 -36
- package/src/main/platform/WindowsTaskbar.ts +0 -600
- package/src/main/platform/index.ts +0 -16
- package/src/main/settings/SettingsManager.ts +0 -730
- package/src/main/settings/index.ts +0 -19
- package/src/main/transcription/ModelDownloadManager.ts +0 -494
- package/src/main/transcription/TierManager.ts +0 -219
- package/src/main/transcription/TranscriptionRecoveryService.ts +0 -340
- package/src/main/transcription/WhisperService.ts +0 -748
- package/src/main/transcription/index.ts +0 -56
- package/src/main/transcription/types.ts +0 -135
- package/src/main/windows/PopoverManager.ts +0 -284
- package/src/main/windows/TaskbarIntegration.ts +0 -452
- package/src/main/windows/index.ts +0 -23
- package/src/preload/index.ts +0 -1047
- package/src/renderer/App.tsx +0 -515
- package/src/renderer/AppWrapper.tsx +0 -28
- package/src/renderer/assets/logo-dark.svg +0 -7
- package/src/renderer/assets/logo.svg +0 -7
- package/src/renderer/audio/AudioCaptureRenderer.ts +0 -454
- package/src/renderer/capture/ScreenRecordingRenderer.ts +0 -492
- package/src/renderer/components/AnnotationOverlay.tsx +0 -836
- package/src/renderer/components/AudioWaveform.tsx +0 -811
- package/src/renderer/components/ClarificationQuestions.tsx +0 -656
- package/src/renderer/components/CountdownTimer.tsx +0 -495
- package/src/renderer/components/CrashRecoveryDialog.tsx +0 -632
- package/src/renderer/components/DonateButton.tsx +0 -127
- package/src/renderer/components/ErrorBoundary.tsx +0 -308
- package/src/renderer/components/ExportDialog.tsx +0 -872
- package/src/renderer/components/HotkeyHint.tsx +0 -261
- package/src/renderer/components/KeyboardShortcuts.tsx +0 -787
- package/src/renderer/components/ModelDownloadDialog.tsx +0 -844
- package/src/renderer/components/Onboarding.tsx +0 -1830
- package/src/renderer/components/ProcessingOverlay.tsx +0 -157
- package/src/renderer/components/RecordingOverlay.tsx +0 -423
- package/src/renderer/components/SessionHistory.tsx +0 -1746
- package/src/renderer/components/SessionReview.tsx +0 -1321
- package/src/renderer/components/SettingsPanel.tsx +0 -217
- package/src/renderer/components/Skeleton.tsx +0 -347
- package/src/renderer/components/StatusIndicator.tsx +0 -86
- package/src/renderer/components/ThemeProvider.tsx +0 -429
- package/src/renderer/components/Tooltip.tsx +0 -370
- package/src/renderer/components/TranscriptionPreview.tsx +0 -183
- package/src/renderer/components/TranscriptionTierSelector.tsx +0 -640
- package/src/renderer/components/UpdateNotification.tsx +0 -377
- package/src/renderer/components/WindowSelector.tsx +0 -947
- package/src/renderer/components/index.ts +0 -99
- package/src/renderer/components/primitives/ApiKeyInput.tsx +0 -98
- package/src/renderer/components/primitives/ColorPicker.tsx +0 -65
- package/src/renderer/components/primitives/DangerButton.tsx +0 -45
- package/src/renderer/components/primitives/DirectoryPicker.tsx +0 -41
- package/src/renderer/components/primitives/Dropdown.tsx +0 -34
- package/src/renderer/components/primitives/KeyRecorder.tsx +0 -117
- package/src/renderer/components/primitives/SettingsSection.tsx +0 -32
- package/src/renderer/components/primitives/Slider.tsx +0 -43
- package/src/renderer/components/primitives/Toggle.tsx +0 -36
- package/src/renderer/components/primitives/index.ts +0 -10
- package/src/renderer/components/settings/AdvancedTab.tsx +0 -174
- package/src/renderer/components/settings/AppearanceTab.tsx +0 -77
- package/src/renderer/components/settings/GeneralTab.tsx +0 -40
- package/src/renderer/components/settings/HotkeysTab.tsx +0 -79
- package/src/renderer/components/settings/RecordingTab.tsx +0 -84
- package/src/renderer/components/settings/index.ts +0 -9
- package/src/renderer/components/settings/settingsStyles.ts +0 -673
- package/src/renderer/components/settings/tabConfig.tsx +0 -85
- package/src/renderer/components/settings/useSettingsPanel.ts +0 -447
- package/src/renderer/contexts/ProcessingContext.tsx +0 -227
- package/src/renderer/contexts/RecordingContext.tsx +0 -683
- package/src/renderer/contexts/UIContext.tsx +0 -326
- package/src/renderer/contexts/index.ts +0 -24
- package/src/renderer/donateMessages.ts +0 -69
- package/src/renderer/hooks/index.ts +0 -75
- package/src/renderer/hooks/useAnimation.tsx +0 -544
- package/src/renderer/hooks/useTheme.ts +0 -313
- package/src/renderer/index.html +0 -26
- package/src/renderer/main.tsx +0 -52
- package/src/renderer/styles/animations.css +0 -1093
- package/src/renderer/styles/app-shell.css +0 -662
- package/src/renderer/styles/globals.css +0 -515
- package/src/renderer/styles/theme.ts +0 -578
- package/src/renderer/types/electron.d.ts +0 -385
- package/src/shared/hotkeys.ts +0 -283
- package/src/shared/types.ts +0 -809
- package/tests/clipboard.test.ts +0 -228
- package/tests/e2e/criticalPaths.test.ts +0 -594
- package/tests/feedbackAnalyzer.test.ts +0 -303
- package/tests/integration/sessionFlow.test.ts +0 -583
- package/tests/markdownGenerator.test.ts +0 -418
- package/tests/output.test.ts +0 -96
- package/tests/setup.ts +0 -486
- package/tests/unit/appIntegration.test.ts +0 -676
- package/tests/unit/appViewState.test.ts +0 -281
- package/tests/unit/audioIpcChannels.test.ts +0 -17
- package/tests/unit/exportService.test.ts +0 -492
- package/tests/unit/hotkeys.test.ts +0 -92
- package/tests/unit/navigationPreload.test.ts +0 -94
- package/tests/unit/onboardingFlow.test.ts +0 -345
- package/tests/unit/permissionManager.test.ts +0 -175
- package/tests/unit/permissionManagerExpanded.test.ts +0 -296
- package/tests/unit/screenRecordingRenderer.test.ts +0 -368
- package/tests/unit/sessionController.test.ts +0 -515
- package/tests/unit/tierManager.test.ts +0 -61
- package/tests/unit/tierManagerExpanded.test.ts +0 -142
- package/tests/unit/transcriptAnalyzer.test.ts +0 -64
- package/tsconfig.json +0 -25
- package/vitest.config.ts +0 -46
|
@@ -1,217 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* markupr Settings Panel
|
|
3
|
-
*
|
|
4
|
-
* Thin composition shell. State lives in useSettingsPanel hook,
|
|
5
|
-
* primitives in ./primitives/, tabs in ./settings/.
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
import React, { useMemo } from 'react';
|
|
9
|
-
import { useTheme } from '../hooks/useTheme';
|
|
10
|
-
import { DonateButton } from './DonateButton';
|
|
11
|
-
import { GeneralTab, RecordingTab, AppearanceTab, HotkeysTab, AdvancedTab, TABS } from './settings';
|
|
12
|
-
import type { SettingsTab } from './settings';
|
|
13
|
-
import { styles } from './settings/settingsStyles';
|
|
14
|
-
import { useSettingsPanel } from './settings/useSettingsPanel';
|
|
15
|
-
|
|
16
|
-
interface SettingsPanelProps {
|
|
17
|
-
isOpen: boolean;
|
|
18
|
-
onClose: () => void;
|
|
19
|
-
initialTab?: SettingsTab;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export const SettingsPanel: React.FC<SettingsPanelProps> = ({
|
|
23
|
-
isOpen,
|
|
24
|
-
onClose,
|
|
25
|
-
initialTab = 'general',
|
|
26
|
-
}) => {
|
|
27
|
-
const { colors } = useTheme();
|
|
28
|
-
const s = useSettingsPanel(isOpen, onClose, initialTab);
|
|
29
|
-
|
|
30
|
-
const renderTabContent = useMemo(() => {
|
|
31
|
-
switch (s.activeTab) {
|
|
32
|
-
case 'general':
|
|
33
|
-
return <GeneralTab settings={s.settings} onSettingChange={s.handleSettingChange} onResetSection={s.resetGeneralSection} />;
|
|
34
|
-
case 'recording':
|
|
35
|
-
return <RecordingTab settings={s.settings} audioDevices={s.audioDevices} onSettingChange={s.handleSettingChange} onResetSection={s.resetRecordingSection} />;
|
|
36
|
-
case 'appearance':
|
|
37
|
-
return <AppearanceTab settings={s.settings} onSettingChange={s.handleSettingChange} onResetSection={s.resetAppearanceSection} />;
|
|
38
|
-
case 'hotkeys':
|
|
39
|
-
return <HotkeysTab settings={s.settings} onHotkeyChange={s.handleHotkeyChange} onResetSection={s.resetHotkeysSection} />;
|
|
40
|
-
case 'advanced':
|
|
41
|
-
return (
|
|
42
|
-
<AdvancedTab
|
|
43
|
-
settings={s.settings}
|
|
44
|
-
openAiApiKey={s.openAiApiKey}
|
|
45
|
-
anthropicApiKey={s.anthropicApiKey}
|
|
46
|
-
onSettingChange={s.handleSettingChange}
|
|
47
|
-
onOpenAiApiKeyChange={s.handleOpenAiApiKeyChange}
|
|
48
|
-
onToggleOpenAiApiKeyVisibility={s.handleToggleOpenAiApiKeyVisibility}
|
|
49
|
-
onTestOpenAiApiKey={s.handleTestOpenAiApiKey}
|
|
50
|
-
onAnthropicApiKeyChange={s.handleAnthropicApiKeyChange}
|
|
51
|
-
onToggleAnthropicApiKeyVisibility={s.handleToggleAnthropicApiKeyVisibility}
|
|
52
|
-
onTestAnthropicApiKey={s.handleTestAnthropicApiKey}
|
|
53
|
-
onClearAllData={s.handleClearAllData}
|
|
54
|
-
onExportSettings={s.handleExportSettings}
|
|
55
|
-
onImportSettings={s.handleImportSettings}
|
|
56
|
-
onResetSection={s.resetAdvancedSection}
|
|
57
|
-
/>
|
|
58
|
-
);
|
|
59
|
-
default:
|
|
60
|
-
return null;
|
|
61
|
-
}
|
|
62
|
-
}, [
|
|
63
|
-
s.activeTab, s.settings, s.audioDevices, s.openAiApiKey, s.anthropicApiKey,
|
|
64
|
-
s.handleSettingChange, s.handleHotkeyChange,
|
|
65
|
-
s.handleOpenAiApiKeyChange, s.handleToggleOpenAiApiKeyVisibility, s.handleTestOpenAiApiKey,
|
|
66
|
-
s.handleAnthropicApiKeyChange, s.handleToggleAnthropicApiKeyVisibility, s.handleTestAnthropicApiKey,
|
|
67
|
-
s.handleClearAllData, s.handleExportSettings, s.handleImportSettings,
|
|
68
|
-
s.resetGeneralSection, s.resetRecordingSection, s.resetAppearanceSection, s.resetHotkeysSection, s.resetAdvancedSection,
|
|
69
|
-
]);
|
|
70
|
-
|
|
71
|
-
if (!isOpen) return null;
|
|
72
|
-
|
|
73
|
-
return (
|
|
74
|
-
<div style={styles.overlay}>
|
|
75
|
-
<div style={styles.backdrop} onClick={onClose} />
|
|
76
|
-
|
|
77
|
-
<div
|
|
78
|
-
ref={s.panelRef}
|
|
79
|
-
style={{
|
|
80
|
-
...styles.panel,
|
|
81
|
-
opacity: s.isAnimating ? 0 : 1,
|
|
82
|
-
transform: s.isAnimating ? 'scale(0.95) translateY(10px)' : 'scale(1) translateY(0)',
|
|
83
|
-
}}
|
|
84
|
-
>
|
|
85
|
-
{/* Header */}
|
|
86
|
-
<div style={styles.header}>
|
|
87
|
-
<div style={styles.headerTitleWrap}>
|
|
88
|
-
<h2 style={styles.headerTitle}>Settings</h2>
|
|
89
|
-
{!s.hasRequiredByokKeys && (
|
|
90
|
-
<button
|
|
91
|
-
type="button"
|
|
92
|
-
style={styles.byokBadge}
|
|
93
|
-
onClick={() => s.setActiveTab('advanced')}
|
|
94
|
-
title="Open BYOK key setup"
|
|
95
|
-
>
|
|
96
|
-
BYOK Setup Required
|
|
97
|
-
</button>
|
|
98
|
-
)}
|
|
99
|
-
</div>
|
|
100
|
-
<button style={styles.closeButton} onClick={onClose} aria-label="Close settings">
|
|
101
|
-
<svg width="20" height="20" viewBox="0 0 20 20" fill="none">
|
|
102
|
-
<path d="M5 5l10 10M15 5l-10 10" stroke="currentColor" strokeWidth="2" strokeLinecap="round" />
|
|
103
|
-
</svg>
|
|
104
|
-
</button>
|
|
105
|
-
</div>
|
|
106
|
-
|
|
107
|
-
{/* Content */}
|
|
108
|
-
<div style={{ ...styles.content, flexDirection: s.isCompact ? 'column' : 'row' }}>
|
|
109
|
-
<nav style={{ ...styles.sidebar, ...(s.isCompact ? styles.sidebarCompact : {}) }}>
|
|
110
|
-
{TABS.map((tab) => (
|
|
111
|
-
<button
|
|
112
|
-
key={tab.id}
|
|
113
|
-
style={{
|
|
114
|
-
...styles.tabButton,
|
|
115
|
-
...(s.isCompact ? styles.tabButtonCompact : {}),
|
|
116
|
-
backgroundColor: s.activeTab === tab.id ? 'rgba(10, 132, 255, 0.16)' : 'transparent',
|
|
117
|
-
color: s.activeTab === tab.id ? colors.text.link : colors.text.tertiary,
|
|
118
|
-
borderColor: s.activeTab === tab.id ? 'rgba(10, 132, 255, 0.32)' : 'transparent',
|
|
119
|
-
}}
|
|
120
|
-
onClick={() => s.setActiveTab(tab.id)}
|
|
121
|
-
aria-selected={s.activeTab === tab.id}
|
|
122
|
-
>
|
|
123
|
-
{tab.icon}
|
|
124
|
-
<span style={styles.tabLabel}>{tab.label}</span>
|
|
125
|
-
</button>
|
|
126
|
-
))}
|
|
127
|
-
</nav>
|
|
128
|
-
|
|
129
|
-
<div style={{ ...styles.tabPanel, ...(s.isCompact ? styles.tabPanelCompact : {}) }}>
|
|
130
|
-
{renderTabContent}
|
|
131
|
-
</div>
|
|
132
|
-
</div>
|
|
133
|
-
|
|
134
|
-
{/* Footer */}
|
|
135
|
-
<div style={styles.footer}>
|
|
136
|
-
<div style={styles.footerLeft}>
|
|
137
|
-
<span style={styles.footerText}>
|
|
138
|
-
markupr {s.appVersion ? `v${s.appVersion}` : ''} {s.hasChanges && <span style={styles.savedIndicator}>Changes saved</span>}
|
|
139
|
-
</span>
|
|
140
|
-
<DonateButton />
|
|
141
|
-
</div>
|
|
142
|
-
<button
|
|
143
|
-
style={styles.resetAllButton}
|
|
144
|
-
onClick={async () => {
|
|
145
|
-
await s.resetGeneralSection();
|
|
146
|
-
await s.resetRecordingSection();
|
|
147
|
-
await s.resetAppearanceSection();
|
|
148
|
-
await s.resetHotkeysSection();
|
|
149
|
-
await s.resetAdvancedSection();
|
|
150
|
-
}}
|
|
151
|
-
>
|
|
152
|
-
Reset All to Defaults
|
|
153
|
-
</button>
|
|
154
|
-
</div>
|
|
155
|
-
</div>
|
|
156
|
-
|
|
157
|
-
{/* spin keyframe provided by animations.css; form element styles below */}
|
|
158
|
-
<style>
|
|
159
|
-
{`
|
|
160
|
-
input[type="range"]::-webkit-slider-thumb {
|
|
161
|
-
-webkit-appearance: none;
|
|
162
|
-
appearance: none;
|
|
163
|
-
width: 16px;
|
|
164
|
-
height: 16px;
|
|
165
|
-
border-radius: 50%;
|
|
166
|
-
background: var(--accent-default);
|
|
167
|
-
cursor: pointer;
|
|
168
|
-
border: 2px solid var(--bg-primary);
|
|
169
|
-
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
input[type="range"]::-webkit-slider-runnable-track {
|
|
173
|
-
width: 100%;
|
|
174
|
-
height: 4px;
|
|
175
|
-
background: rgba(124, 137, 160, 0.4);
|
|
176
|
-
border-radius: 2px;
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
select {
|
|
180
|
-
-webkit-appearance: none;
|
|
181
|
-
appearance: none;
|
|
182
|
-
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 5l3 3 3-3' stroke='%238f9db5' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
|
|
183
|
-
background-repeat: no-repeat;
|
|
184
|
-
background-position: right 12px center;
|
|
185
|
-
padding-right: 36px;
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
select:focus {
|
|
189
|
-
outline: none;
|
|
190
|
-
border-color: var(--accent-default);
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
input[type="color"] {
|
|
194
|
-
-webkit-appearance: none;
|
|
195
|
-
appearance: none;
|
|
196
|
-
border: none;
|
|
197
|
-
width: 32px;
|
|
198
|
-
height: 32px;
|
|
199
|
-
padding: 0;
|
|
200
|
-
cursor: pointer;
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
input[type="color"]::-webkit-color-swatch-wrapper {
|
|
204
|
-
padding: 0;
|
|
205
|
-
}
|
|
206
|
-
|
|
207
|
-
input[type="color"]::-webkit-color-swatch {
|
|
208
|
-
border: none;
|
|
209
|
-
border-radius: 50%;
|
|
210
|
-
}
|
|
211
|
-
`}
|
|
212
|
-
</style>
|
|
213
|
-
</div>
|
|
214
|
-
);
|
|
215
|
-
};
|
|
216
|
-
|
|
217
|
-
export default SettingsPanel;
|
|
@@ -1,347 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Skeleton Loading Components
|
|
3
|
-
*
|
|
4
|
-
* Premium shimmer-effect loading placeholders that match the markupr design system.
|
|
5
|
-
* Use these to indicate loading states while maintaining visual hierarchy.
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
import React from 'react';
|
|
9
|
-
|
|
10
|
-
// ============================================================================
|
|
11
|
-
// Types
|
|
12
|
-
// ============================================================================
|
|
13
|
-
|
|
14
|
-
interface SkeletonProps {
|
|
15
|
-
/** Width of the skeleton (CSS value) */
|
|
16
|
-
width?: string | number;
|
|
17
|
-
/** Height of the skeleton (CSS value) */
|
|
18
|
-
height?: string | number;
|
|
19
|
-
/** Border radius (CSS value or true for default 8px) */
|
|
20
|
-
rounded?: boolean | string | number;
|
|
21
|
-
/** Use circular shape */
|
|
22
|
-
circle?: boolean;
|
|
23
|
-
/** Animation type */
|
|
24
|
-
animation?: 'shimmer' | 'pulse' | 'none';
|
|
25
|
-
/** Additional CSS class */
|
|
26
|
-
className?: string;
|
|
27
|
-
/** Additional inline styles */
|
|
28
|
-
style?: React.CSSProperties;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
interface SkeletonTextProps {
|
|
32
|
-
/** Number of lines to render */
|
|
33
|
-
lines?: number;
|
|
34
|
-
/** Width of the last line (creates natural variation) */
|
|
35
|
-
lastLineWidth?: string | number;
|
|
36
|
-
/** Gap between lines */
|
|
37
|
-
gap?: number;
|
|
38
|
-
/** Animation type */
|
|
39
|
-
animation?: 'shimmer' | 'pulse' | 'none';
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
interface SkeletonCardProps {
|
|
43
|
-
/** Show thumbnail placeholder */
|
|
44
|
-
showThumbnail?: boolean;
|
|
45
|
-
/** Number of text lines */
|
|
46
|
-
lines?: number;
|
|
47
|
-
/** Show avatar */
|
|
48
|
-
showAvatar?: boolean;
|
|
49
|
-
/** Animation type */
|
|
50
|
-
animation?: 'shimmer' | 'pulse' | 'none';
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
// ============================================================================
|
|
54
|
-
// Base Skeleton Component
|
|
55
|
-
// ============================================================================
|
|
56
|
-
|
|
57
|
-
export const Skeleton: React.FC<SkeletonProps> = ({
|
|
58
|
-
width,
|
|
59
|
-
height,
|
|
60
|
-
rounded = true,
|
|
61
|
-
circle = false,
|
|
62
|
-
animation = 'shimmer',
|
|
63
|
-
className = '',
|
|
64
|
-
style = {},
|
|
65
|
-
}) => {
|
|
66
|
-
const getBorderRadius = () => {
|
|
67
|
-
if (circle) return '50%';
|
|
68
|
-
if (rounded === true) return 8;
|
|
69
|
-
if (rounded === false) return 0;
|
|
70
|
-
return rounded;
|
|
71
|
-
};
|
|
72
|
-
|
|
73
|
-
const animationClass =
|
|
74
|
-
animation === 'shimmer'
|
|
75
|
-
? 'ff-skeleton'
|
|
76
|
-
: animation === 'pulse'
|
|
77
|
-
? 'ff-skeleton-pulse'
|
|
78
|
-
: '';
|
|
79
|
-
|
|
80
|
-
return (
|
|
81
|
-
<div
|
|
82
|
-
className={`${animationClass} ${className}`}
|
|
83
|
-
style={{
|
|
84
|
-
width: width ?? '100%',
|
|
85
|
-
height: height ?? 16,
|
|
86
|
-
borderRadius: getBorderRadius(),
|
|
87
|
-
backgroundColor: 'rgba(55, 65, 81, 0.3)',
|
|
88
|
-
...style,
|
|
89
|
-
}}
|
|
90
|
-
/>
|
|
91
|
-
);
|
|
92
|
-
};
|
|
93
|
-
|
|
94
|
-
// ============================================================================
|
|
95
|
-
// Skeleton Text (Multiple lines)
|
|
96
|
-
// ============================================================================
|
|
97
|
-
|
|
98
|
-
export const SkeletonText: React.FC<SkeletonTextProps> = ({
|
|
99
|
-
lines = 3,
|
|
100
|
-
lastLineWidth = '70%',
|
|
101
|
-
gap = 8,
|
|
102
|
-
animation = 'shimmer',
|
|
103
|
-
}) => {
|
|
104
|
-
return (
|
|
105
|
-
<div style={{ display: 'flex', flexDirection: 'column', gap }}>
|
|
106
|
-
{Array.from({ length: lines }).map((_, index) => (
|
|
107
|
-
<Skeleton
|
|
108
|
-
key={index}
|
|
109
|
-
width={index === lines - 1 ? lastLineWidth : '100%'}
|
|
110
|
-
height={16}
|
|
111
|
-
animation={animation}
|
|
112
|
-
style={{
|
|
113
|
-
animationDelay: `${index * 100}ms`,
|
|
114
|
-
}}
|
|
115
|
-
/>
|
|
116
|
-
))}
|
|
117
|
-
</div>
|
|
118
|
-
);
|
|
119
|
-
};
|
|
120
|
-
|
|
121
|
-
// ============================================================================
|
|
122
|
-
// Skeleton Avatar
|
|
123
|
-
// ============================================================================
|
|
124
|
-
|
|
125
|
-
export const SkeletonAvatar: React.FC<{
|
|
126
|
-
size?: number;
|
|
127
|
-
animation?: 'shimmer' | 'pulse' | 'none';
|
|
128
|
-
}> = ({ size = 40, animation = 'shimmer' }) => {
|
|
129
|
-
return <Skeleton width={size} height={size} circle animation={animation} />;
|
|
130
|
-
};
|
|
131
|
-
|
|
132
|
-
// ============================================================================
|
|
133
|
-
// Skeleton Thumbnail
|
|
134
|
-
// ============================================================================
|
|
135
|
-
|
|
136
|
-
export const SkeletonThumbnail: React.FC<{
|
|
137
|
-
width?: string | number;
|
|
138
|
-
aspectRatio?: string;
|
|
139
|
-
animation?: 'shimmer' | 'pulse' | 'none';
|
|
140
|
-
}> = ({ width = '100%', aspectRatio = '16/9', animation = 'shimmer' }) => {
|
|
141
|
-
return (
|
|
142
|
-
<Skeleton
|
|
143
|
-
width={width}
|
|
144
|
-
height="auto"
|
|
145
|
-
rounded={8}
|
|
146
|
-
animation={animation}
|
|
147
|
-
style={{
|
|
148
|
-
aspectRatio,
|
|
149
|
-
}}
|
|
150
|
-
/>
|
|
151
|
-
);
|
|
152
|
-
};
|
|
153
|
-
|
|
154
|
-
// ============================================================================
|
|
155
|
-
// Skeleton Button
|
|
156
|
-
// ============================================================================
|
|
157
|
-
|
|
158
|
-
export const SkeletonButton: React.FC<{
|
|
159
|
-
width?: string | number;
|
|
160
|
-
height?: number;
|
|
161
|
-
animation?: 'shimmer' | 'pulse' | 'none';
|
|
162
|
-
}> = ({ width = 120, height = 40, animation = 'shimmer' }) => {
|
|
163
|
-
return <Skeleton width={width} height={height} rounded={8} animation={animation} />;
|
|
164
|
-
};
|
|
165
|
-
|
|
166
|
-
// ============================================================================
|
|
167
|
-
// Skeleton Card (Composite)
|
|
168
|
-
// ============================================================================
|
|
169
|
-
|
|
170
|
-
export const SkeletonCard: React.FC<SkeletonCardProps> = ({
|
|
171
|
-
showThumbnail = true,
|
|
172
|
-
lines = 2,
|
|
173
|
-
showAvatar = false,
|
|
174
|
-
animation = 'shimmer',
|
|
175
|
-
}) => {
|
|
176
|
-
return (
|
|
177
|
-
<div style={styles.card}>
|
|
178
|
-
{showThumbnail && (
|
|
179
|
-
<SkeletonThumbnail animation={animation} />
|
|
180
|
-
)}
|
|
181
|
-
<div style={styles.cardContent}>
|
|
182
|
-
{showAvatar && (
|
|
183
|
-
<div style={styles.avatarRow}>
|
|
184
|
-
<SkeletonAvatar size={32} animation={animation} />
|
|
185
|
-
<div style={{ flex: 1 }}>
|
|
186
|
-
<Skeleton width="60%" height={14} animation={animation} />
|
|
187
|
-
</div>
|
|
188
|
-
</div>
|
|
189
|
-
)}
|
|
190
|
-
<Skeleton
|
|
191
|
-
width="80%"
|
|
192
|
-
height={18}
|
|
193
|
-
animation={animation}
|
|
194
|
-
style={{ marginBottom: 8 }}
|
|
195
|
-
/>
|
|
196
|
-
<SkeletonText lines={lines} animation={animation} />
|
|
197
|
-
</div>
|
|
198
|
-
</div>
|
|
199
|
-
);
|
|
200
|
-
};
|
|
201
|
-
|
|
202
|
-
// ============================================================================
|
|
203
|
-
// Skeleton List Item
|
|
204
|
-
// ============================================================================
|
|
205
|
-
|
|
206
|
-
export const SkeletonListItem: React.FC<{
|
|
207
|
-
showIcon?: boolean;
|
|
208
|
-
showAction?: boolean;
|
|
209
|
-
animation?: 'shimmer' | 'pulse' | 'none';
|
|
210
|
-
}> = ({ showIcon = true, showAction = false, animation = 'shimmer' }) => {
|
|
211
|
-
return (
|
|
212
|
-
<div style={styles.listItem}>
|
|
213
|
-
{showIcon && <SkeletonAvatar size={24} animation={animation} />}
|
|
214
|
-
<div style={{ flex: 1, display: 'flex', flexDirection: 'column', gap: 4 }}>
|
|
215
|
-
<Skeleton width="70%" height={14} animation={animation} />
|
|
216
|
-
<Skeleton width="40%" height={12} animation={animation} />
|
|
217
|
-
</div>
|
|
218
|
-
{showAction && <SkeletonButton width={80} height={32} animation={animation} />}
|
|
219
|
-
</div>
|
|
220
|
-
);
|
|
221
|
-
};
|
|
222
|
-
|
|
223
|
-
// ============================================================================
|
|
224
|
-
// Skeleton Feedback Item (markupr specific)
|
|
225
|
-
// ============================================================================
|
|
226
|
-
|
|
227
|
-
export const SkeletonFeedbackItem: React.FC<{
|
|
228
|
-
showThumbnail?: boolean;
|
|
229
|
-
animation?: 'shimmer' | 'pulse' | 'none';
|
|
230
|
-
}> = ({ showThumbnail = true, animation = 'shimmer' }) => {
|
|
231
|
-
return (
|
|
232
|
-
<div style={styles.feedbackItem}>
|
|
233
|
-
{/* Drag handle */}
|
|
234
|
-
<div style={styles.dragHandle}>
|
|
235
|
-
<Skeleton width={12} height={20} rounded={2} animation={animation} />
|
|
236
|
-
</div>
|
|
237
|
-
|
|
238
|
-
{/* Content */}
|
|
239
|
-
<div style={{ flex: 1 }}>
|
|
240
|
-
{/* Header with tags */}
|
|
241
|
-
<div style={styles.feedbackHeader}>
|
|
242
|
-
<Skeleton width={60} height={16} animation={animation} />
|
|
243
|
-
<Skeleton width={50} height={20} rounded={6} animation={animation} />
|
|
244
|
-
<Skeleton width={50} height={20} rounded={6} animation={animation} />
|
|
245
|
-
</div>
|
|
246
|
-
|
|
247
|
-
{/* Transcription */}
|
|
248
|
-
<SkeletonText lines={2} lastLineWidth="60%" gap={6} animation={animation} />
|
|
249
|
-
|
|
250
|
-
{/* Thumbnails */}
|
|
251
|
-
{showThumbnail && (
|
|
252
|
-
<div style={styles.thumbnailRow}>
|
|
253
|
-
<Skeleton width={60} height={45} rounded={6} animation={animation} />
|
|
254
|
-
<Skeleton width={60} height={45} rounded={6} animation={animation} />
|
|
255
|
-
</div>
|
|
256
|
-
)}
|
|
257
|
-
</div>
|
|
258
|
-
</div>
|
|
259
|
-
);
|
|
260
|
-
};
|
|
261
|
-
|
|
262
|
-
// ============================================================================
|
|
263
|
-
// Skeleton Window Source (Window Selector specific)
|
|
264
|
-
// ============================================================================
|
|
265
|
-
|
|
266
|
-
export const SkeletonWindowSource: React.FC<{
|
|
267
|
-
animation?: 'shimmer' | 'pulse' | 'none';
|
|
268
|
-
}> = ({ animation = 'shimmer' }) => {
|
|
269
|
-
return (
|
|
270
|
-
<div style={styles.windowSource}>
|
|
271
|
-
<Skeleton width={104} height={64} rounded={8} animation={animation} />
|
|
272
|
-
<Skeleton width="80%" height={11} animation={animation} />
|
|
273
|
-
<Skeleton width={12} height={12} circle animation={animation} />
|
|
274
|
-
</div>
|
|
275
|
-
);
|
|
276
|
-
};
|
|
277
|
-
|
|
278
|
-
// ============================================================================
|
|
279
|
-
// Styles
|
|
280
|
-
// ============================================================================
|
|
281
|
-
|
|
282
|
-
const styles: Record<string, React.CSSProperties> = {
|
|
283
|
-
card: {
|
|
284
|
-
backgroundColor: 'rgba(31, 41, 55, 0.6)',
|
|
285
|
-
borderRadius: 12,
|
|
286
|
-
border: '1px solid rgba(75, 85, 99, 0.3)',
|
|
287
|
-
overflow: 'hidden',
|
|
288
|
-
},
|
|
289
|
-
cardContent: {
|
|
290
|
-
padding: 16,
|
|
291
|
-
},
|
|
292
|
-
avatarRow: {
|
|
293
|
-
display: 'flex',
|
|
294
|
-
alignItems: 'center',
|
|
295
|
-
gap: 12,
|
|
296
|
-
marginBottom: 12,
|
|
297
|
-
},
|
|
298
|
-
listItem: {
|
|
299
|
-
display: 'flex',
|
|
300
|
-
alignItems: 'center',
|
|
301
|
-
gap: 12,
|
|
302
|
-
padding: '12px 16px',
|
|
303
|
-
backgroundColor: 'rgba(31, 41, 55, 0.4)',
|
|
304
|
-
borderRadius: 8,
|
|
305
|
-
},
|
|
306
|
-
feedbackItem: {
|
|
307
|
-
display: 'flex',
|
|
308
|
-
gap: 12,
|
|
309
|
-
padding: 16,
|
|
310
|
-
backgroundColor: 'rgba(31, 41, 55, 0.6)',
|
|
311
|
-
borderRadius: 12,
|
|
312
|
-
border: '1px solid rgba(75, 85, 99, 0.3)',
|
|
313
|
-
},
|
|
314
|
-
dragHandle: {
|
|
315
|
-
display: 'flex',
|
|
316
|
-
alignItems: 'center',
|
|
317
|
-
justifyContent: 'center',
|
|
318
|
-
width: 20,
|
|
319
|
-
},
|
|
320
|
-
feedbackHeader: {
|
|
321
|
-
display: 'flex',
|
|
322
|
-
alignItems: 'center',
|
|
323
|
-
gap: 8,
|
|
324
|
-
marginBottom: 10,
|
|
325
|
-
},
|
|
326
|
-
thumbnailRow: {
|
|
327
|
-
display: 'flex',
|
|
328
|
-
gap: 8,
|
|
329
|
-
marginTop: 12,
|
|
330
|
-
},
|
|
331
|
-
windowSource: {
|
|
332
|
-
display: 'flex',
|
|
333
|
-
flexDirection: 'column',
|
|
334
|
-
alignItems: 'center',
|
|
335
|
-
padding: 12,
|
|
336
|
-
borderRadius: 12,
|
|
337
|
-
border: '2px solid transparent',
|
|
338
|
-
backgroundColor: 'rgba(255, 255, 255, 0.04)',
|
|
339
|
-
gap: 8,
|
|
340
|
-
},
|
|
341
|
-
};
|
|
342
|
-
|
|
343
|
-
// ============================================================================
|
|
344
|
-
// Exports
|
|
345
|
-
// ============================================================================
|
|
346
|
-
|
|
347
|
-
export default Skeleton;
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Status Indicator Component
|
|
3
|
-
*
|
|
4
|
-
* Shows the current recording/processing status with visual feedback
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
import React from 'react';
|
|
8
|
-
import type { SessionStatus } from '../../shared/types';
|
|
9
|
-
import { useTheme } from '../hooks/useTheme';
|
|
10
|
-
|
|
11
|
-
interface StatusIndicatorProps {
|
|
12
|
-
status: SessionStatus;
|
|
13
|
-
error?: string | null;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
const StatusIndicator: React.FC<StatusIndicatorProps> = ({ status, error }) => {
|
|
17
|
-
const { colors } = useTheme();
|
|
18
|
-
|
|
19
|
-
const getColor = (): string => {
|
|
20
|
-
switch (status) {
|
|
21
|
-
case 'recording':
|
|
22
|
-
return colors.status.error;
|
|
23
|
-
case 'processing':
|
|
24
|
-
return colors.status.warning;
|
|
25
|
-
case 'complete':
|
|
26
|
-
return colors.status.success;
|
|
27
|
-
case 'error':
|
|
28
|
-
return colors.status.error;
|
|
29
|
-
default:
|
|
30
|
-
return '#8e8e93';
|
|
31
|
-
}
|
|
32
|
-
};
|
|
33
|
-
|
|
34
|
-
const getText = (): string => {
|
|
35
|
-
switch (status) {
|
|
36
|
-
case 'recording':
|
|
37
|
-
return 'Recording...';
|
|
38
|
-
case 'processing':
|
|
39
|
-
return 'Processing...';
|
|
40
|
-
case 'complete':
|
|
41
|
-
return 'Copied to clipboard!';
|
|
42
|
-
case 'error':
|
|
43
|
-
return error || 'Error occurred';
|
|
44
|
-
default:
|
|
45
|
-
return 'Ready';
|
|
46
|
-
}
|
|
47
|
-
};
|
|
48
|
-
|
|
49
|
-
const color = getColor();
|
|
50
|
-
|
|
51
|
-
return (
|
|
52
|
-
<div style={styles.container} role="status" aria-live={status === 'error' ? 'assertive' : 'polite'}>
|
|
53
|
-
<div
|
|
54
|
-
style={{
|
|
55
|
-
...styles.dot,
|
|
56
|
-
backgroundColor: color,
|
|
57
|
-
boxShadow: status === 'recording' ? `0 0 8px ${color}` : 'none',
|
|
58
|
-
animation: status === 'recording' ? 'pulse 1.5s ease-in-out infinite' : 'none',
|
|
59
|
-
}}
|
|
60
|
-
/>
|
|
61
|
-
<span style={styles.text}>{getText()}</span>
|
|
62
|
-
{/* pulse keyframe provided by animations.css */}
|
|
63
|
-
</div>
|
|
64
|
-
);
|
|
65
|
-
};
|
|
66
|
-
|
|
67
|
-
const styles: Record<string, React.CSSProperties> = {
|
|
68
|
-
container: {
|
|
69
|
-
display: 'flex',
|
|
70
|
-
alignItems: 'center',
|
|
71
|
-
gap: 12,
|
|
72
|
-
},
|
|
73
|
-
dot: {
|
|
74
|
-
width: 10,
|
|
75
|
-
height: 10,
|
|
76
|
-
borderRadius: '50%',
|
|
77
|
-
transition: 'all 0.2s ease',
|
|
78
|
-
},
|
|
79
|
-
text: {
|
|
80
|
-
color: '#eef3ff',
|
|
81
|
-
fontSize: 13,
|
|
82
|
-
fontWeight: 500,
|
|
83
|
-
},
|
|
84
|
-
};
|
|
85
|
-
|
|
86
|
-
export default StatusIndicator;
|