diff --git a/package.json b/package.json index 2cbb9c6..249fbdb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "my-weekly-todo-list", - "version": "1.49.1", + "version": "1.50.0", "description": "A web-based weekly task management application that organizes to-dos and calendar events in a single, intuitive weekly view", "main": "index.js", "scripts": { diff --git a/src/components/WeeklyView.tsx b/src/components/WeeklyView.tsx index 7a0cdeb..fb5a8eb 100644 --- a/src/components/WeeklyView.tsx +++ b/src/components/WeeklyView.tsx @@ -8514,10 +8514,7 @@ export default function WeeklyView() { onEndHourChange: (h: number) => { setEndHour(h); saveSetting("endHour", h); }, }} perView={{ - isPerView: isPerView as any, - togglePerView: togglePerView as any, saveViewSetting: saveViewSetting as any, - viewLabel: viewStyle === "simple" ? (language === "de" ? "Einfach" : "Simple") : viewStyle === "calendar" ? (language === "de" ? "Kalender" : "Calendar") : viewStyle === "list" ? (language === "de" ? "Liste" : "List") : "Kanban", }} /> ) @@ -10055,10 +10052,7 @@ interface SettingsSidebarProps { onEndHourChange: (h: number) => void; }; perView: { - isPerView: (key: string) => boolean; - togglePerView: (key: string, globalVal: any) => void; saveViewSetting: (key: string, value: any, perView: boolean) => void; - viewLabel: string; }; } // Notes Sidebar Component @@ -10286,31 +10280,6 @@ function SettingsSidebar({ mobileActions, perView, }: SettingsSidebarProps) { - // Per-view badge: shows which view a setting applies to, click to toggle - const PerViewBadge = ({ settingKey, globalVal }: { settingKey: string; globalVal: any }) => { - const isPV = perView.isPerView(settingKey); - return ( - - ); - }; - const [activeTab, setActiveTab] = useState< "calendar" | "general" | "account" | "styling" | "motivation" | "about" | "localisation" >(initialTab || "general"); @@ -10837,6 +10806,33 @@ function SettingsSidebar({
+ {/* View Style Tabs — at top, acts as context for per-view settings */} +
+ +
+ + + + +
+

+ {profile.language === "de" ? "Einstellungen unten gelten für diese Ansicht" : "Settings below apply to this view"} +

+
{ setProfile({ ...profile, showTaskCheckboxes: e.target.checked }); - if (perView.isPerView("showTaskCheckboxes")) { - perView.saveViewSetting("showTaskCheckboxes", e.target.checked, true); - } + perView.saveViewSetting("showTaskCheckboxes", e.target.checked, true); }} style={{ width: "16px", height: "16px" }} />