"use client" import { Input } from "@/components/ui/input" import { Button } from "@/components/ui/button" import { Switch } from "@/components/ui/switch" import { Plus, Minus, Clock, HelpCircle } from "lucide-react" import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from "@/components/ui/tooltip" import { useViewMode } from "@/app/components/LayoutWrapper" import { Label } from "@/components/ui/label" interface BasicSettingsProps { formData: { taskName: string startTime: string endTime: string syncCount: number syncInterval: number accountType: "business" | "personal" enabled: boolean } onChange: (data: Partial) => void onNext: () => void } export function BasicSettings({ formData, onChange, onNext }: BasicSettingsProps) { const { viewMode } = useViewMode() const handleSyncCountChange = (delta: number) => { const newValue = Math.max(1, formData.syncCount + delta) onChange({ syncCount: newValue }) } const handleSyncIntervalChange = (delta: number) => { const newValue = Math.max(5, formData.syncInterval + delta) onChange({ syncInterval: newValue }) } return (
onChange({ taskName: e.target.value })} placeholder="请输入任务名称" className="mt-1.5 h-12 rounded-xl" />
{formData.syncCount}
条/天
{formData.syncInterval}
分钟

设置每次发朋友圈的时间间隔

onChange({ startTime: e.target.value })} className="h-12 rounded-xl" /> onChange({ endTime: e.target.value })} className="h-12 rounded-xl" />
onChange({ enabled: checked })} />
) }