Commit graph

116 commits

Author SHA1 Message Date
Claude e911ac1d94
refactor(tauri): extract credential_domain helper
Three call sites reproduced the same scheme://host parsing inline. Pull
it into a named helper so the domain-extraction convention lives in one
place.
2026-04-19 07:11:53 +00:00
Claude 4e8f7c4536
fix(tauri): reject "/" root path in workspace validation
trim_end_matches('/') collapses "/" to "", which then isn't matched by
the forbidden list, so a root-filesystem workspace slipped through. Keep
"/" as the canonical form when the stripped value is empty.
2026-04-19 07:08:42 +00:00
Claude a79dcc4617
test: cover CLI workspace resolver, date picker, saturating version
Add regression tests for the bugs found in this smoke test:

- resolve_workspace: by-name, by-UUID, unknown-identifier, current-fallback,
  actionable no-workspace message.
- DateTimePicker: selected-day highlight must be month-scoped; committing
  after navigating months uses the selected month, not the viewed one.
- create_task: version is saturating_add on u64::MAX (doesn't panic/wrap).

Also fixes the three pre-existing clippy warnings (WorkspaceMode now uses
#[derive(Default)] + #[default], repository test drops unused binding,
sync test uses struct-update syntax instead of field-reassign-default).
2026-04-17 16:32:22 +00:00
Claude efb4ccaaef
chore(cleanup): remove unused BottomSheet component and dead testConnection
BottomSheet.svelte is not imported anywhere — NewTaskInput hand-rolls
its own sheet. SetupScreen had a standalone testConnection() function
that was only ever reachable through connectAndBrowse which calls
test_webdav_connection directly; the standalone variant had no
callers.
2026-04-17 16:29:04 +00:00
Claude 3acc4c3f5d
fix(empty-state): replace misleading hint with an actual create button
The no-lists empty state said 'Tap the list name above to create one' —
but there is no list name above, just a static 'Tasks' label. The
actual affordance (+ New list) lives in the drawer, which may not be
open. Add a primary-button shortcut that opens the drawer and puts
focus in the new-list input in one click. Google Tasks workspaces are
read-only so they still get the explanatory text instead.
2026-04-17 16:27:18 +00:00
Claude 391c42aa18
fix(rename): imperatively focus + select rename inputs
Svelte's native autofocus attribute is unreliable for inputs rendered
via conditional blocks (prior smoke-test fixed this for the new-list
input). Apply the same bind:this + $effect pattern to the list-rename
input (TasksScreen) and the workspace-rename input (SettingsScreen),
and select() the existing text so typing replaces the old name
cleanly.
2026-04-17 16:26:29 +00:00
Claude 6283f9ab2c
fix(store): guard fs-changed listener against setup/missing screens
The module-scope fs-changed listener fired unconditionally, calling
loadLists even when the user was on the setup or missing-workspace
screens (where no current workspace exists). The invoke would fail
silently and a WebDAV debounced sync could kick off against an
incomplete state. Bail when there's no active workspace or the tasks
screen isn't mounted.
2026-04-17 16:25:39 +00:00
Claude 5869c305aa
fix(bulk-delete): snapshot targets and bail on first failure
executeDeleteCompleted and executeDeleteCompletedSubtasks iterated over
the reactive completedTasks/completedSubtasks lists with no error
handling: the array shrinks with every successful delete, skipping
subsequent entries, and a failed delete silently left a half-deleted
state. Snapshot the target list up front and abort as soon as a delete
returns false — matching the subtask-cascade path.
2026-04-17 16:25:03 +00:00
Claude d213e523ec
fix(sync): narrow transient-error detection so real errors aren't hidden
The connectivity-vs-real-error classifier tested the message against
/timeout|connect|network|unreachable|refused/i, matching any error
whose text happened to include one of those words. A server-side
permission error like 'network share access refused' was silently
classified as transient, updating only the status dot — the user
never saw the actual problem.

Tighten the regex to well-known connectivity phrases and lowercase
error codes (ENOTFOUND/ECONNREFUSED/etc), using word boundaries so
substrings in unrelated messages don't match.
2026-04-17 16:24:20 +00:00
Claude 0fc1f16c9d
fix(new-task): attach date in a single create_task call to prevent loss
The new-task bottom sheet called createTask then, if a date was set,
made a follow-up updateTask to attach the date. If the update failed
(e.g. filesystem error between the two writes) the user was left with
a dateless task and, because transient sync errors are already
suppressed, often no visible error either.

Extend the create_task Tauri command to accept optional date/has_time
fields and pass them through. The frontend now creates the task in one
round-trip. No separate update path needed.
2026-04-17 16:23:51 +00:00
Claude d01bd9d280
fix(settings): stop clobbering WebDAV edits and save without a successful test
Two coupled issues in workspace settings:

1. The credentials-loading effect re-ran whenever ws.webdav_url changed,
   so any config mutation (e.g. changing sync interval) would trigger a
   re-load of the stored username/password, overwriting whatever the
   user was typing into those fields. Gate with a one-shot credsLoaded
   flag.

2. Save would persist whatever was in the URL input even if the user
   had never tested it — a typo'd host silently pointed the workspace
   at a dead server. Now saveWebdav auto-runs the connection test and
   bails if it fails; any edit to the three inputs clears the "ok"
   status via markDirty() so the next Save is forced to re-verify.

Also replaces the ASCII "Failed -- Retry" with an em dash.
2026-04-17 16:22:31 +00:00
Claude f276233be5
fix(tauri): cascade delete must handle the full subtree, not just direct children
delete_task only collected direct children when a parent was deleted,
so grandchildren (and deeper descendants — the data model allows any
depth even though the UI is two-level today) would be left with a
parent_id pointing at a deleted task. Walk the parent-child graph to
collect the full descendant set and delete children before the parent
so a mid-cascade failure can't strand descendants.
2026-04-17 16:19:46 +00:00
Claude df66e7bc98
fix(tauri): add_workspace must initialise the target folder
The frontend currently calls init_workspace before add_workspace, but
the Tauri command itself is trivially breakable by any caller that
skips the pre-step or a future frontend refactor: add_workspace would
save the workspace entry pointing at a non-existent directory, and
every subsequent command would then fail with 'Path does not exist'
via TaskRepository::new. Call TaskRepository::init inside the command
so it is self-contained and idempotent.
2026-04-17 16:19:03 +00:00
Claude a0e2bb214b
fix(date-picker): don't mark the same day in every month as selected
The day cell class used `selectedDay === day`, ignoring the currently
viewed month/year. After picking e.g. April 15, flipping to May still
painted May 15 as the selected day; committing with Done would shift
the task's date to whatever month the user happened to be viewing.

Track selectedYear/selectedMonth alongside selectedDay, update them
only on actual day click, and construct the committed ISO from the
selection (not the view). The pre-existing isSelected() helper is now
wired into the cell template.
2026-04-17 16:17:36 +00:00
Claude 855fa46a0e
refactor: simplify forgetMissingWorkspace now that removeWorkspace handles switch
removeWorkspace already switches to the next available workspace (or falls
back to setup). forgetMissingWorkspace can just delegate, dropping the
duplicate branch that previously never ran anyway because current_workspace
was always null after removal.
2026-04-17 16:13:46 +00:00
Claude cdef59fab4
fix: keep user on tasks screen when removing current workspace
When a user deletes the current workspace from settings, the backend
clears current_workspace and the frontend's hasWorkspace derived fell
through to the setup screen — even if the user still had other healthy
workspaces configured. Mirror the forgetMissingWorkspace flow: switch
to the next available workspace automatically.
2026-04-17 16:12:49 +00:00
Claude 67ac43e527
Add Vitest suite covering the smoke-test fixes
Extracts two pure helpers out of Svelte components so they can be
exercised without the reactive runtime, and adds component tests for
ConfirmDialog's Escape-handling behavior.

- apps/tauri/src/lib/grouping.ts (new): `groupTasksByDate` lifted out of
  the `groupedPendingTasks` $derived in the app store.
- apps/tauri/src/lib/paths.ts (new): `workspaceNameFromPath` lifted out
  of SetupScreen.handleOpen.
- apps/tauri/src/lib/grouping.test.ts: 8 cases — "No Date" placed last
  (regression), full bucket ordering, empty input, within-bucket
  stable sort, earlier-today stays in Today, multi-task same-day,
  No Date preserves insertion order.
- apps/tauri/src/lib/paths.test.ts: 8 cases — POSIX/Windows/mixed
  separators, trailing slash regression ("…/Tasks/" → "Tasks"), empty
  and root-only fallback, names with spaces.
- apps/tauri/src/lib/components/ConfirmDialog.test.ts: 6 cases —
  renders message/detail/custom confirm text, Cancel/Confirm fire the
  right callbacks, Escape calls oncancel and does NOT reach an outer
  window listener (regression), non-Escape keys are ignored, and the
  module-level open-count increments/decrements correctly (including
  when two dialogs are mounted at once).

Test harness: Vitest + jsdom + @testing-library/svelte. `npm test`
runs the suite; `resolve.conditions` is set to "browser" under VITEST
so Svelte resolves its client entry and mount() works.

23/23 tests pass. cargo check, cargo test -p onyx-core (162/162),
and npm run build all still green.
2026-04-17 14:33:12 +00:00
Claude 8a04895270
Fix nine GUI bugs found during local-workspace smoke test
- crates/onyx-core/src/webdav.rs: rename `getpassword`/`setpassword`
  (7 call sites) to `get_password`/`set_password` so `cargo build`
  and the CLI compile again under the default `keyring-storage` feature.
- ConfirmDialog.svelte: intercept Escape at window capture phase and
  expose a module-level open-count so TasksScreen's Escape handler can
  defer; previously Escape on a dialog both dismissed the dialog AND
  popped the task-detail view behind it. Cancel is also focused on
  mount for keyboard users.
- TasksScreen.svelte: extend the taskStack cleanup effect to collapse
  back to parent detail when only the subtask is gone (was leaving a
  blank third panel); focus the new-list input when it appears; reset
  the Completed section's expand state when switching lists.
- TaskDetailView.svelte: re-sync local title/description state when
  the task prop's content changes (unless the user is editing), so a
  sync pull doesn't get silently overwritten on next save. Bail out of
  the parent delete if a subtask delete fails instead of orphaning.
- app.svelte.ts: deleteTask now returns a success boolean; move the
  "No Date" group to the end of the grouped-by-date view so Overdue
  and Today surface first.
- SetupScreen.svelte: strip trailing separators before splitting the
  picked folder path so "…/MyTasks/" yields "MyTasks" instead of the
  literal fallback "workspace".

Verified live under Xvfb for the three user-visible cases (ConfirmDialog
Escape, orphan subtask collapse, new-list autofocus). Screenshots in
screenshots/smoke-test/. cargo test --lib -p onyx-core is green
(162/162); npm run build succeeds.
2026-04-17 14:24:59 +00:00
Claude a313a6e270
refactor: extract shared date formatting utilities in frontend
Three components had duplicate date formatting functions. Extract
formatDateChip (for detail/input views with optional time) and
formatDateLabel (for compact list items) to a shared dateFormat module.

https://claude.ai/code/session_013ooJht2HrZUTXgNJFU79cV
2026-04-16 07:26:06 +00:00
Claude ac72955d23
fix: correct operator precedence in Windows path validation
The condition `len <= 3 && ends_with(":\\") || ends_with(":")` was
missing parentheses, causing the second ends_with check to run
regardless of path length due to && binding tighter than ||.

https://claude.ai/code/session_013ooJht2HrZUTXgNJFU79cV
2026-04-16 07:21:16 +00:00
Claude 24a62b6685
fix: correct isToday check in DateTimePicker
getMonth() returns 0-11, but the comparison string was not adjusting
for this, so the "today" highlight in the calendar never matched.

https://claude.ai/code/session_013ooJht2HrZUTXgNJFU79cV
2026-04-16 07:20:50 +00:00
Claude 125f1e19ac
fix: audit — debounced save data loss, silent workspace errors, code duplication
- Fix debouncedSave in TaskDetailView losing edits when title and
  description are changed within 400ms (shared timer only saved the
  last-changed field)
- Return errors from Tauri commands when workspace ID doesn't exist
  instead of silently succeeding (set_webdav_config, set_workspace_theme,
  set_sync_interval, set_sync_interval_unfocused)
- Remove duplicate atomic_write_bytes in google_tasks.rs; reuse
  pub(crate) atomic_write from storage.rs
- Fix failing test using wrong frontmatter field name (due → date)
- Add Audit.md log

https://claude.ai/code/session_0186pnnUJxj2uv1KhHjWoAGA
2026-04-15 07:16:40 +00:00
Tristan Michael afedac7d32 the kebab menu calls the date on tasks a due date, but it's not a due date... it's just a date. can we make sure the codebase, documentation and everything is consistent about this?
- Renamed `due_date` field on Task struct to `date` (Rust, TypeScript, all usages)
- Renamed `group_by_due_date` field on TaskList/ListMetadata to `group_by_date`
- Renamed `set_group_by_due_date`/`get_group_by_due_date` methods to `set_group_by_date`/`get_group_by_date` in repository, Tauri commands, and JS store
- Renamed `with_due_date()` builder method to `with_date()`
- Renamed `parse_due_date` CLI function to `parse_date`
- Updated UI text "Group by due date" → "Group by date" in TasksScreen.svelte kebab menu
- Renamed JS variables `dueDate`/`dueDateHasTime` → `date`/`dateHasTime` in NewTaskInput.svelte
- Updated all test names and assertions across models.rs and repository.rs
- Updated CLAUDE.md documentation to use "date" terminology consistently
Close kebab menu when toggling subtasks

When toggling the "show subtasks" option from the main panel kebab menu,
the menu remained open which could obscure UI and lead to unexpected
interactions. Ensure that opening/closing the subtasks list also closes
the kebab (showListMenu = false) so the menu is dismissed when the user
chooses to view subtasks.
can we animate opening and closing of the kebab menus? Also, lets move the "NO DATE" section when selecting Group By Date to the top of the list before OVERDUE

- app.css: added CSS @starting-style + display transition on .dropdown-menu for open/close scale+fade animation
- app.svelte.ts: moved "No Date" group to the top (before "Overdue") in groupedPendingTasks
2026-04-14 07:19:27 -07:00
Tristan Michael 6a4b79801b Add Google Tasks read-only workspace and sync
Introduce a new Google Tasks workspace mode that performs a one-way,
read-only pull from the Google Tasks API into the local
FileSystemStorage format. This adds a Google Tasks client (token
refresh, paginated list fetching, stable UUID v5 mapping), desktop
PKCE+loopback OAuth flow (Android stub), credential storage, workspace
creation and sync commands, UI flows for sign-in/creation, and guards to
disable write operations for Google Tasks workspaces. Changes also
include Cargo dependency updates and exports to wire the new module into
the app.
Hide editing UI for Google Tasks workspaces

Make Google Tasks workspaces read-only by hiding editing controls and
the FAB when app.isGoogleTasks is true. This prevents rename,
delete-completed, and new-task actions in read-only Google Tasks
workspaces and adjusts menu options (Rename removed, Group by due date
and Show subtasks remain with proper toggles). The change clarifies the
UX for Google Tasks by disabling interaction where appropriate and
conditionally showing the FAB only for editable workspaces.
Add Google Tasks workspace (read-only)

Introduce Google Tasks as a third workspace mode to allow one-way,
read-only sync from the Google Tasks API into local FileSystemStorage.
This includes a new WorkspaceMode::GoogleTasks, workspace google_account
metadata, a GoogleTasks client and sync logic (with stable UUID v5 task
IDs), OAuth PKCE+loopback flow for desktop (Android uses a
credential-manager stub), UI changes to mark Google Tasks workspaces as
read-only and disable write operations, and commands to create and sync
Google Tasks workspaces. Dependency updates add sha2/sha1_smol/reqwest
for OAuth and API calls.
when I go to create a google tasks workspace, I see the content associated with creating a webdav workspace as part of the interface

- SetupScreen.svelte: fixed template structure where WebDAV branches lacked mode === "webdav" guards, causing them to render when mode === "googletasks"; folded Google Tasks steps into the main if/else chain and removed the separate Google Tasks {#if} block that was appending below the WebDAV content
2026-04-14 07:02:50 -07:00
Tristan Michael 9ed84690ac Rename due_date to date across codebase
The kebab menu and docs referred to a task "due date" but the field was
just a date; this change renames due_date/group_by_due_date and related
identifiers to date/group_by_date across Rust, TypeScript, Svelte, CLI,
docs and tests to keep terminology consistent. Updates include
API/command names, storage/models, repository methods, UI text, JS
variables and builder/parse functions so code, tests and documentation
all use "date" semantics.
Preserve old "group_by_due_date" field name

Add serde alias to ListMetadata.group_by_date so older .listdata.json
files that used the previous field name (group_by_due_date) can still be
deserialized correctly. This fixes serialization/deserialization issues
encountered at /home/trztn/Documents/Onyx and
/var/home/trztn/Nextcloud/Onyx.
the frontmatter due should be date... I don't want due anywhere

- Renamed `TaskFrontmatter.due` → `TaskFrontmatter.date`; YAML key on disk is now `date:` instead of `due:`
- Added `#[serde(alias = "due")]` so existing task files with `due:` frontmatter still deserialize correctly
- Updated google_tasks.rs to write `date:` instead of `due:` in generated YAML
- Renamed CLI `--due` flag to `--date`; updated function signature and display string "Due:" → "Date:"
Remove serde aliases and rename due→date

Drop backwards-compat aliases and update frontmatter/metadata to use the
canonical "date"/"group_by_date" fields. The aliases for
group_by_due_date and due were removed to avoid maintaining
backward-compatibility and to reflect the current schema. Updated
storage types to rename the fields and adjusted serialization attributes
so YAML/JSON frontmatter and .listdata.json files now use group_by_date
and date consistently.
2026-04-14 07:36:10 -07:00
Tristan Michael a0c183df82 Hide subtask counter when parent subtask shown
When "show subtasks" is enabled, the UI could display both the parent
subtask and its counter, leading to redundant information. Hide the
subtask counter under a parent subtask when the parent itself is shown
to reduce visual clutter and avoid duplicate counts.

This change ensures a cleaner presentation of tasks and subtasks by
preventing the counter from appearing alongside the visible parent
subtask.
if I drag a task in this mode, I would love to be able to drag it anywhere and have the task update its date

- Added `date: Date | null` to TaskGroup (null = Overdue or No Date, Date = the group's calendar day)
- Cross-group drops now update the task's due_date to the target group's date; preserves time-of-day when has_time is set; clears due_date when dropping into No Date
- Dropping INTO Overdue is still blocked (it's a computed group); dragging OUT of Overdue to any other group works
- Within-group drops still just reorder
Close open submenus when clicking outside

When submenu elements (like the kebab menu or workspace picker) were
open, clicking elsewhere in the app did not close them and allowed
interacting with underlying UI. This change adds a full-screen invisible
overlay element whenever either menu is open that captures outside
clicks and closes the menus, and removes the previous window-level
mousedown handler and related element bindings. This ensures that
clicking outside a submenu only closes it and prevents accidental
interactions with other parts of the app.
Prevent task clicks when closing dropdown menus

When the list menu or workspace picker is open, clicking outside should
close the menu but not also trigger underlying task click handlers. Add
a mouse down handler that closes dropdowns when clicking outside and a
capture-phase click handler that swallows the click immediately after a
menu close to avoid propagation to task elements. This avoids accidental
task activation right after closing a menu.
Prevent clicks reaching background when menus open

Stop clicks on the main task area from interacting with underlying
elements when the workspace picker or list menu are open. Previously a
global mousedown/click handler attempted to close menus and prevent a
single stray click from propagating; this change replaces that logic by
adding overlay divs inside the drawer and task list panels that capture
clicks and close the respective menus. This simplifies interaction
handling and fixes a bug where clicking menu items also triggered task
clicks.
the kebab menu calls the date on tasks a due date, but it's not a due date... it's just a date. can we make sure the codebase, documentation and everything is consistent about this?

- Renamed `due_date` field on Task struct to `date` (Rust, TypeScript, all usages)
- Renamed `group_by_due_date` field on TaskList/ListMetadata to `group_by_date`
- Renamed `set_group_by_due_date`/`get_group_by_due_date` methods to `set_group_by_date`/`get_group_by_date` in repository, Tauri commands, and JS store
- Renamed `with_due_date()` builder method to `with_date()`
- Renamed `parse_due_date` CLI function to `parse_date`
- Updated UI text "Group by due date" → "Group by date" in TasksScreen.svelte kebab menu
- Renamed JS variables `dueDate`/`dueDateHasTime` → `date`/`dateHasTime` in NewTaskInput.svelte
- Updated all test names and assertions across models.rs and repository.rs
- Updated CLAUDE.md documentation to use "date" terminology consistently
2026-04-14 06:51:56 -07:00
Tristan Michael f98f8492b5 Group pending tasks by due date
Add grouping of pending tasks into Overdue/Today/Tomorrow/This
Week/Later/No Date buckets when the active list has group_by_due_date
enabled. This provides a grouped view in TasksScreen (section headers,
no drag-and-drop) and a new derived store groupedPendingTasks exported
from the app store to supply the UI. Dated groups are sorted by due_date
while the No Date group preserves the custom order.
Few changes: lets make the date chip red when in the overdue section. In all other sections, lets hide the date chip for individual tasks. Then, for the Later section, lets break that up into individual days.

- Replaced single "Later" group with per-day groups (e.g. "Mon, Apr 20"), each sorted by due_date
- Added `dateChipStyle` prop to TaskItem ("normal" | "overdue" | "hidden"), default "normal"
- Date chip is red (border-red-400 text-red-400) in "overdue" style, hidden in "hidden" style
- TasksScreen passes dateChipStyle="overdue" for Overdue group, "hidden" for all others
Fix date chips and include year in future group labels

Replace dynamic ternary class strings with explicit {#if} blocks for the
date chip so Tailwind v4's scanner picks up the classes and theme tokens
are respected. Use text-danger and border-danger for overdue chips and
proper border/token classes for non-overdue chips to fix the overdue
chip appearance and prevent chips from showing in sections that should
be hidden.

Also include the year in per-day group labels when the date is not in
the current year (e.g. "Mon, Apr 20, 2027") by passing the appropriate
Intl.DateTimeFormat options, so tasks scheduled in future years display
an unambiguous header.
yes (remove This Week, extend per-day grouping to everything beyond tomorrow)

- Removed "This Week" group entirely
- Everything beyond tomorrow now gets a per-day group label (same as what "Later" was doing), giving a consistent Overdue → Today → Tomorrow → [per-day] → No Date structure
Respect manual order within same-day groups

Ensure tasks that fall on the same day keep the user's manual ordering
by using a task_order index as a tiebreaker when sorting. Also add
drag-and-drop group tracking so drags and drops are confined to their
originating group and wire full DnD handlers into the grouped view.

- Use a taskOrderIndex map in sortByDue to break ties when due dates are equal so same-day tasks respect manual order.
- Add dragGroup state and record it on handleDragStart; ignore dragOver/drop events when the event group differs from the originating dragGroup to prevent cross-group drops.
- Reset dragGroup on drag end.
- Wrap grouped TaskItem entries with draggable divs and hook up dragstart/dragover/dragend/drop to match the flat view's DnD behavior.
Update drag-and-drop to set task due dates

Support dragging tasks between date-grouped columns by updating the
task's due_date to the target group's date (or clearing it when dropped
into No Date). Preserve the task's time-of-day when has_time is set,
block dropping into the computed Overdue group, and allow dragging out
of Overdue. Also add TaskGroup.date to the grouping data and expose a
showSubtaskCount prop and optional subtask rendering in the task list
UI.
fix null taskId error when reordering after cross-group drag

- Capture dragId and dragGroup into local variables at the top of handleDrop before any awaits — prevents the race where dragend fires during updateTask and nulls out dragId before reorderTask is called
Allow dragging tasks to update date groups

Add date handling to task groups so dragging a task into another group
updates its due_date. Introduce date: Date | null for TaskGroup (null
represents Overdue/No Date), update cross-group drops to set or clear a
task's due_date based on the target group while preserving time-of-day
for tasks with has_time, and keep within-group drops as reorders. Also
ensure Overdue remains a computed-only target (cannot drop into it)
while allowing dragging out.

Additionally, add GoogleTasks workspace support fields
(WorkspaceMode::GoogleTasks and an optional google_account) and include
the new field in WorkspaceConfig::new to initialize google_account to
None.
2026-04-14 06:01:19 -07:00
Tristan Michael 67eb90c2a0 Introduce windowDecorations enum with three options
Replace the previous boolean systemDecorations with a windowDecorations
enum ("custom", "none", "system") to allow three distinct decoration
modes. Update UI to use a select control in Settings, adapt App.svelte
conditionals to check for the "custom" value when applying custom
borders/rounded styles, and rename localStorage key to persist the new
enum. Also ensure the native system decorations are enabled when the
setting is "system" and export the new setter name setWindowDecorations
in the store.
Enable setting window decorations

Add the "core🪟allow-set-decorations" capability to allow the app
to control window decorations (e.g., system titlebar). This fixes the
issue where the system titlebar was not working by permitting the code
to modify decoration state.

Also ensure the capability list remains properly comma-separated after
insertion.
Add outline support for borderless mode

Allow border outline in non-system decoration modes on Linux. The change
updates the condition for applying the linux-window-border class so the
outline is applied when window decorations are custom or any non-system
mode, enabling an outline for borderless windows while keeping
system-decorated windows unaffected.
Respect borderless mode: remove rounded corners

Remove rounded corners from popups and overlays when window decorations
are disabled. The App component now passes the windowDecorations state
into the root div via a data-decorations attribute, and the CSS adds a
rule that forces square corners for all elements under
[data-decorations="none"] to ensure borderless mode yields true square
UI without rounded popups/toasts.
Do not override button/input/select border-radius in borderless mode

Prevent borderless mode from removing rounded corners on interactive
form elements. The previous selector applied border-radius: 0 to all
descendants, unintentionally flattening buttons, inputs, and selects.
Restrict the rule so it excludes button, input, and select elements to
preserve their expected styling.
Strengthen dropdown drop-shadows

Make the kebab and other dropdown menu shadows more pronounced by
replacing the tailwind shadow-lg class with shadow-2xl across
TaskDetailView.svelte and TasksScreen.svelte. This improves visual
contrast and makes menus stand out more clearly against the background,
addressing the request to make the dropshadow on the kebab menus
stronger.
Use consistent menu shadow class

Replace multiple inline shadow utility classes with a shared
"menu-shadow" class for dropdown and context menus across
TaskDetailView, SettingsScreen, and TasksScreen. This unifies styling,
reduces duplication, and allows easier tweaks to the menu drop-shadow
(potentially addressing blurry rendering) by centralizing the shadow
definition.
Add subtle shadow for dropdown/kebab menus

Soften dropdown/kebab menu appearance by adding a subtle box-shadow
utility and a darker variant for dark mode. Also refine the borderless
mode rule to avoid overriding elements that use rounded-full classes so
those intentional circular controls keep their shape.
Make dropdown buttons square-cornered in borderless mode

Ensure dropdown menu buttons use square corners when decorations are
disabled. The CSS update adds a selector to force border-radius: 0 for
buttons inside .dropdown-menu under [data-decorations="none"]. Several
dropdown container divs across TaskDetailView, SettingsScreen,
TasksScreen, and related components are given a .dropdown-menu class so
the new rule applies consistently and makes dropdown buttons match the
rest of the borderless UI.
when workspace settings is up, can we make it so I can drag the header to move the app around?

- Added data-tauri-drag-region to the header and title in SettingsScreen.svelte so the settings header can be used to drag/move the window
<task-notification>
<task-id>bzp4p2vsp</task-id>
<summary>Monitor event: "Tauri rebuild — Finished or error"</summary>
<event>[Monitor timed out — re-arm if needed.]</event>
</task-notification>


Apply decorations-none class for borderless mode

Ensure the "decorations-none" CSS class is applied/removed on the
document root when window decorations are set to "none" so borderless
mode styles take effect. The CSS selector was also adjusted to
explicitly list rounded utility classes so the rule targets known
rounded elements while keeping dropdown-menu buttons included.
2026-04-14 06:02:30 -07:00
Tristan Michael 6be1ee93c0 on linux, when I click the new task button, the toast and the dimming of the background don't respect the visual borders of the app
- Changed `fixed` to `absolute` positioning in NewTaskInput.svelte backdrop div so the overlay respects the app's visual container bounds on Linux (where a p-2 padded, rounded-xl container creates visual borders)
it looks mostly good now, except that when the toast slides up, it's causing the rest of the app content to jitter

- Added `overflow-hidden` to the outer wrapper div in NewTaskInput.svelte to contain the translate-y-full animation within its own layer and prevent repaint jitter on sibling content
when workspace settings is up, can we make it so I can drag the header to move the app around?

- Added data-tauri-drag-region to the header and title in SettingsScreen.svelte so the settings header can be used to drag/move the window
2026-04-14 06:23:10 -07:00
Tristan Michael 34d7e8b17d Add Linux system window decorations setting
Expose a per-user setting to toggle system window decorations on Linux
and apply it to the UI and window behavior.

- Add a SettingsScreen option (Linux-only) to toggle "System window decorations" and bind it to the app store.
- Track the preference in app store with persistent localStorage key and getter/setter (setSystemDecorations) that updates the Tauri window decorations via getCurrentWindow().setDecorations().
- Respect the setting when rendering the main App.svelte by disabling rounded corners and custom Linux window border when system decorations are enabled. This change is needed to let Linux users choose native title bar/window chrome for better integration with their desktop environment.
2026-04-14 05:58:17 -07:00
Tristan Michael 31af983640 Add ink theme and remove onyx border class
Add an "Ink" theme for e-ink displays and remove the previously applied
onyx-border class from the App container. The new theme defines
high-contrast monochrome variables, suppresses shadows and decorative
effects, adjusts scrollbars and select options, and adds a subtle
linux-window-border color suitable for e-ink screens. The onyx border
CSS was removed and the App.svelte container no longer toggles the
onyx-border class; the Settings screen now includes the Ink option in
the theme selector.
Remove unnecessary blank line in app.css

Remove an unneeded blank line in the Tauri app stylesheet. The extra
line was left behind when considering a mode elimination and is not
required, so this cleans up the CSS file to keep it tidy and consistent.
2026-04-14 05:27:21 -07:00
Tristan Michael 9071f46050 Rename Onyx theme to Black and Gold
Update displayed theme name from "Onyx" to "Black and Gold" in the
settings UI so the theme matches the requested branding. This change
ensures users see the new theme name in the theme selector and aligns
the UI with the prompt to call the theme Black and Gold.
2026-04-06 17:32:00 -07:00
Tristan Michael 58e205a024 Fix visibility of completed checkmarks on onyx theme
Ensure checkmarks under the "completed" state are visible on the
near-white primary background for the onyx theme. The change adjusts
selector scoping so dark text and icons (including elements with
.text-white inside .bg-primary) are explicitly styled with a dark color,
preventing white-on-near-white contrast issues.
2026-04-06 17:30:43 -07:00
Tristan Michael 5756e19ceb Desaturate onyx theme gold tones
Tweak several onyx theme color variables to slightly desaturate the gold
accents so the UI appears less saturated and more balanced. Update text,
option, and FAB colors, hover/background and border RGBA values, and add
a new thicker onyx-border utility for a prominent gold window border.
2026-04-06 17:29:49 -07:00
Tristan Michael b83a54328e Brighten dividers and submenu outlines
Make the divider and submenu outline colors a brighter gold to improve
contrast and visual clarity. Updated CSS variables --color-border-light
and --color-border-dark from a dark brown (#2a2418) to a warmer
gold-brown (#5c4d2e). This change enhances the UI by making separators
and submenu outlines more visible and consistent with the app's gold
text accents.
2026-04-06 17:28:29 -07:00
Tristan Michael 42ef8584ab Make large "+ new task" FAB use text gold
Make the prominent "+ new task" floating action button match the primary
text gold color in the Onyx theme. The FAB previously used the cream
primary color; this change sets its background to #d4bc72 so the button
visually aligns with other gold text elements in the UI.
2026-04-06 17:25:46 -07:00
Tristan Michael c4d6d28e12 Lighten onyx gold shades
Adjust onyx theme gold tones to be slightly lighter and warmer for
improved contrast and visual clarity. This updates primary text,
secondary text, scrollbar, select option text, checkbox borders,
hover/focus highlight backgrounds, and the Linux window border to use
the new lighter gold color values so the UI reads better against dark
surfaces.
2026-04-06 17:25:02 -07:00
Tristan Michael c13fbde1b8 Tweak onyx theme colors to warmer gold tones
Give the onyx theme a warmer, gold-accented look and slightly lighten
deep blacks to improve contrast and legibility. Replace pure white
primary colors with a soft yellow/gold, adjust surface and card blacks
to be a bit lighter, and update related elements (select options,
primary button text, checkbox borders, hover/focus highlights, and Linux
window border) so interactive elements read clearly against the new
palette.
2026-04-06 17:23:25 -07:00
Tristan Michael 973d575b51 feat: add onyx dark theme support
Add onyx theme as a new dark theme option. Register it in the dark
themes set, add the theme option to the settings dropdown, and define
complete color variables and scrollbar styling for the onyx theme.

Also improve sync error handling to gracefully skip upload and conflict
resolution actions when files are missing, preventing sync failures due
to files moved or deleted between action computation and execution.
2026-04-06 17:17:00 -07:00
Tristan Michael 5e5773d146 fix: add safe area padding to scrollable content
Add safe area padding to scrollable main content areas and
adjust drawer footer padding to prevent content from being
hidden behind notches and home indicators on mobile devices.
This ensures proper spacing on devices with safe area insets.
2026-04-06 11:21:29 -07:00
Tristan Michael c772e3251a fix: add safe area bottom padding to DateTimePicker
Add bottom padding to DateTimePicker component to prevent content
from being obscured by notches or home indicators on mobile devices.
Uses CSS max() function to ensure minimum 0.75rem spacing while
respecting device safe area insets.
2026-04-06 11:21:29 -07:00
Tristan Michael 9a9dc80e26 fix: set fixed height on calendar grid
Add content-start alignment and fixed 192px height to the
calendar grid to prevent layout shift when switching between
months with different numbers of weeks. This ensures consistent
spacing and prevents the calendar from changing size based on
the month being displayed.
2026-04-06 11:21:29 -07:00
Tristan Michael e9f7f7ab69 feat: move Onyx header above card and enlarge on setup screen 2026-04-06 11:21:29 -07:00
Tristan Michael 3d65aaf502 feat: left-edge swipe gesture for drawer and back navigation on mobile 2026-04-06 10:30:36 -07:00
Tristan Michael 50800f0c2d feat: add separate sync interval for unfocused state
Introduce a new sync interval configuration for when the app is
in the background, allowing users to set a longer sync period to
reduce resource usage. Replace the fixed focus threshold with
dynamic interval switching based on app focus state. Add
syncIntervalUnfocused setting to the UI with a new background
sync interval selector. Refactor sync interval management into
a restartSyncInterval function to handle both focused and
unfocused intervals consistently.
2026-04-06 09:37:06 -07:00
Tristan Michael f5295b5980 fix: reset tasks and remount screen on workspace change
Reset the tasks array when switching workspaces to prevent stale
task data from persisting. Wrap TasksScreen in a keyed block to
force remounting when the current workspace changes, ensuring a
clean state for each workspace.

Configure line endings to use LF across all files for consistency.
2026-04-06 09:10:36 -07:00
Claude 6174836b7f
Fix critical and high-severity issues from project audit
Security:
- Fix path traversal via backslash bypass in sync validate_sync_path()
- Replace silent HTTP client fallback with proper error propagation
- Add 64KB YAML frontmatter size limit to prevent DoS via crafted files

Data integrity:
- Reorder delete operations: update metadata before removing files to
  prevent orphaned metadata entries on crash
- Fix task deduplication to use file mtime as tiebreaker when versions
  are equal, preventing non-deterministic data loss
- Add rollback on conflict recovery failure (remove orphaned duplicate
  files when metadata update fails)
- Clean up temp files on atomic write rename failure
- Add file-based sync lock to prevent concurrent sync operations
- Use saturating_add for task version to prevent overflow

Error handling:
- Surface move_task rollback failures as structured errors instead of
  silent warnings
- Log WebDAV parallel request failures instead of silently swallowing
- Emit watcher-error events to frontend instead of only printing to stderr

Frontend:
- Fix focus listener leak in auto-sync (clean up if stopAutoSync called
  while promise pending)
- Add prefers-reduced-motion CSS media query for accessibility
- Add ARIA labels, roles, and keyboard handlers to TaskItem, BottomSheet,
  and ConfirmDialog components
- Replace BottomSheet children: any with Snippet type

https://claude.ai/code/session_01AJoK28N4vqLqzskq6ybGri
2026-04-06 11:03:11 +00:00
Claude 85748f4c95
Audit fixes: panic safety, path hardening, code quality
- Replace 2 production unwrap() calls in workspace.rs with proper error
  handling to prevent panics on inconsistent state
- Add AppState::save_config() helper to eliminate 11 duplicated
  save_to_file patterns in Tauri lib.rs
- Log file watcher errors instead of silently swallowing them
- Harden path traversal check in storage.rs: re-verify after
  canonicalization to catch symlink escapes
- Add Windows reserved device name handling (CON, NUL, etc.) to
  sanitize_filename
- Clean up stale .tmp files from interrupted atomic writes on startup

All 107 core tests pass.

https://claude.ai/code/session_01EnSrQsowc64rAwzD9BnJpc
2026-04-06 10:41:03 +00:00
Claude a12deb5182
Harden codebase: fix security, quality, and maintainability issues
- Replace dangerous unwrap() with proper error handling (storage.rs, webdav.rs)
- Add atomic writes (temp + rename) for config, sync state, and metadata files
- Add path traversal validation in sync executor
- Add workspace path validation in Tauri commands
- Add input size limits for task titles, descriptions, and list names
- Add file download size limit (10MB) to WebDAV get_file
- Fix move_task rollback to log failures instead of silently ignoring
- Fix JSON serialization unwrap in Tauri create_remote_workspace
- Fix swallowed errors in sync queue backup, metadata writes, sync state load
- Extract hardcoded strings into named constants (filenames, extensions, limits)
- Use REQUEST_TIMEOUT/CONNECT_TIMEOUT constants in WebDAV client builder
- Fix frontend: clear taskStack when viewed task is deleted or list is switched
- Fix frontend: surface credential loading and focus listener errors

https://claude.ai/code/session_01F67yfLLmSaBtT7aKKNus1M
2026-04-06 10:17:30 +00:00
Tristan Michael 5e33416b22 Slim task frontmatter: remove timestamps, add version counter + self-healing dedup
Remove created_at/updated_at from Task struct and frontmatter. Add a
version counter (u64) that increments on every write, defaults to 1 for
old files. list_tasks now groups by UUID and auto-deletes stale
duplicates (keeping highest version), preventing sync-induced dupes from
surfacing in the UI. has_time and parent are omitted from frontmatter
when false/null.

Update CLI, Tauri frontend types, and Svelte components to match.
2026-04-05 19:22:10 -07:00