mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-04-27 09:46:25 +02:00
docs: update PRD with comprehensive extension features and UX integration strategy
- Added UX strategy: Extension for Quick Actions, Frontend for Management - Organized features into 4 phases (Phase 1 completed) - Added 14 new extension features (FR-EXT-07 to FR-EXT-17): * Smart Monitoring: Price alerts, whale tracking, rug pull detection * Trading Intelligence: Token analysis, entry/exit suggestions, portfolio tracker * Content Creation: Chart screenshots, AI thread generator * Productivity: Quick actions, notifications, keyboard shortcuts - Added Feature Responsibility Matrix showing Extension vs Frontend roles - Added Settings Sync strategy (FR-EXT-06) with deep links to frontend - Documented state sync architecture: Extension ↔ Backend API ↔ Frontend
This commit is contained in:
parent
fd9eddf7fa
commit
a052b01a68
27 changed files with 5163 additions and 88 deletions
42
surfsense_browser_extension/sidepanel/chat/ChatInput.tsx
Normal file
42
surfsense_browser_extension/sidepanel/chat/ChatInput.tsx
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
import { useState } from "react";
|
||||
import { Send } from "lucide-react";
|
||||
import { Button } from "@/routes/ui/button";
|
||||
|
||||
interface ChatInputProps {
|
||||
onSend: (content: string) => void;
|
||||
disabled?: boolean;
|
||||
placeholder?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Chat input component with send button
|
||||
*/
|
||||
export function ChatInput({ onSend, disabled, placeholder }: ChatInputProps) {
|
||||
const [input, setInput] = useState("");
|
||||
|
||||
const handleSubmit = (e: React.FormEvent) => {
|
||||
e.preventDefault();
|
||||
if (input.trim() && !disabled) {
|
||||
onSend(input.trim());
|
||||
setInput("");
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<form onSubmit={handleSubmit} className="border-t p-3">
|
||||
<div className="flex gap-2">
|
||||
<input
|
||||
type="text"
|
||||
value={input}
|
||||
onChange={(e) => setInput(e.target.value)}
|
||||
placeholder={placeholder || "Type a message..."}
|
||||
disabled={disabled}
|
||||
className="flex-1 px-3 py-2 border rounded-md bg-background text-sm focus:outline-none focus:ring-2 focus:ring-primary"
|
||||
/>
|
||||
<Button type="submit" size="icon" disabled={disabled || !input.trim()}>
|
||||
<Send className="h-4 w-4" />
|
||||
</Button>
|
||||
</div>
|
||||
</form>
|
||||
);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue