Skip to content

Feature/settings#1

Merged
kotru21 merged 43 commits intomainfrom
feature/settings
Dec 22, 2025
Merged

Feature/settings#1
kotru21 merged 43 commits intomainfrom
feature/settings

Conversation

@kotru21
Copy link
Copy Markdown
Owner

@kotru21 kotru21 commented Dec 22, 2025

This pull request introduces several improvements across the codebase, focusing on developer experience, code quality, and user interface enhancements. The most significant changes include the addition of a continuous integration workflow, stricter import rules for code organization, new end-to-end tests for UI features, and enhancements to theming and appearance handling.

CI/CD and Tooling Improvements:

  • Added a GitHub Actions workflow (.github/workflows/ci.yml) to automate checks for import cycles, linting, type-checking, running tests with coverage, and uploading coverage reports.
  • Updated package.json to add madge for import cycle checks, Playwright for end-to-end testing, and other dev dependencies for accessibility and validation. Also introduced a check:imports script. [1] [2] [3]
  • Added a CI status badge to the README.md for visibility of workflow status.

Code Quality and Structure:

  • Enhanced biome.json configuration to enforce strict import boundaries between FSD layers (entities, features, widgets, pages) to maintain clean architecture. [1] [2]

Testing Enhancements:

UI and Theming Improvements:

  • Major refactor of globals.css to support dynamic theme switching (light/dark), custom accent colors, and utility classes for accent coloring and icon styling. Added global utilities for reduced motion and animation toggling. [1] [2]
  • Updated QueryProvider.tsx to apply appearance settings to the DOM using a new hook, ensuring user preferences are reflected in the UI. [1] [2]

Backend Features:

  • Added a new Tauri command (get_thumbnail) to generate image thumbnails as base64-encoded PNGs, along with supporting model changes and dependency updates (image crate). [1] [2] [3] [4]

These changes collectively improve developer workflow, code maintainability, UI consistency, and user experience.

This update introduces hooks for applying appearance settings, improves file sorting and filtering logic, and refines file row rendering to respect user display preferences. Layout state is now persisted, and panel sizing logic is streamlined. Quick filter and keyboard navigation are enhanced for better usability and performance. Styles are updated for dynamic appearance, compact mode, and accessibility. Unused code is removed and settings exports are clarified.
Introduces two-way sync between settings and runtime layout state, including sidebar/preview size lock and column widths. Adds class-based theme overrides, accent color CSS variable support, and performance settings for thumbnails and search. Refactors appearance application to avoid FOUC, improves undo toast, and adds comprehensive tests for layout and appearance sync. Updates UI components for better accessibility and live previews.
Introduces a reusable confirm dialog with zustand store and integrates it for file overwrite confirmation. Refactors keyboard shortcut handling in the file explorer to support user-configurable shortcuts and Vim navigation mode. Adds global types for debugging, improves performance logging, and updates appearance settings to allow explicit animation disabling. File column headers now respect display settings for file size and date.
Unifies hidden files toggle to use settings store, removes legacy `showHidden` from view mode, and migrates persisted values. Refactors accent color CSS variables for consistency. Updates file explorer click behavior to respect single/double click settings. Adds and improves tests for settings import, file row scroll behavior, thumbnail transitions, and click behaviors. Cleans up unused code and comments, and improves performance logging.
Upgraded several dependencies including lucide-react, react-resizable-panels, @biomejs/biome, @types/node, @vitest/coverage-v8, and vitest to their latest versions for improved features and bug fixes. Updated biome.json schema reference to 2.3.10.
Replaces deprecated react-resizable-panels types and components with updated equivalents (e.g., ImperativePanelHandle to PanelImperativeHandle, PanelGroup to Group, PanelResizeHandle to Separator). Updates prop names and value formats for ResizablePanel and ResizablePanelGroup usage, and adjusts event handlers to match new API. Improves type safety and ensures compatibility with the latest react-resizable-panels API.
Introduces a new setting to show column headers in the simple (non-virtual) file list, with UI and tests. Refactors layout sync to batch frequent updates using debounce and requestAnimationFrame, improving performance during resize. Updates settings migration and validation logic to support the new field, and adds related tests. Minor code comments and test improvements throughout.
Refactored multiple components and hooks to use selector-based state access instead of direct getState() calls, improving performance and maintainability. Added a GitHub Actions CI workflow for linting, type checking, testing, and coverage reporting, and updated the README with a CI badge. Introduced and improved accessibility (a11y) tests for the file browser and toolbar, and split FileExplorer into container and view components for better separation of concerns. Updated dependencies to include vitest-axe and axe-core for a11y testing.
Replaced direct store state access with selector hooks in several components for improved performance and consistency. Updated dependencies in useEffect and useCallback hooks to include selected store functions, ensuring proper memoization and reactivity.
Refactored file explorer handler tests to avoid reading store internals directly and to use DOM-based assertions. Added new tests for useFileExplorerHandlers, improved clipboard state handling in handlers, and updated Toolbar tests to verify UI state via DOM instead of store internals. These changes improve test reliability and ensure handlers always use the latest store state.
- Add Biome `noRestrictedImports` overrides for `src/entities` and `src/features`
- Document import boundaries in `docs/IMPORT_BOUNDARIES.md`
- Refactor entity components to avoid importing feature hooks: `FileRow`, `ColumnHeader`, `FileThumbnail`
- Update widgets to pass settings/appearance/performance via props
- Update unit tests accordingly
Replaces hardcoded WindowControls in TabBar with a controls prop for better composability. Updates FileExplorer and related components to improve prop typing and formatting, and removes temporary and documentation files no longer needed.
Split FileExplorer.view.tsx into smaller components: FileExplorerGrid, FileExplorerSimpleList, FileExplorerVirtualList, and FileExplorerLoading. Added supporting types and a useFileExplorer hook for settings defaults. Updated tests and accessibility checks. Added madge for import cycle checks and integrated it into CI. Introduced a PR checklist for component refactors.
Reordered and cleaned up import statements for consistency across several files. Added minimal type definitions for FileDisplaySettings and FileEntry in FileRow tests to remove external dependencies. Updated a11y tests to use direct assertion on violations array. Improved formatting and clarity in tauri client tests.
Introduces an environment variable (USE_PERF_LOGS/VITE_USE_PERF_LOGS) to enable or disable performance logging across the app. Updates perf utilities to respect this toggle, adds integration tests to verify logging is suppressed when disabled, and sets the variable to 'false' in CI. Refactors code to use a new isPerfEnabled() helper for consistent behavior.
Adds Playwright-based E2E tests for file row and recent folders hover/cursor behavior. Refactors FileRow and FileRowActions for better accessibility, keyboard and pointer interaction, and consistent hover/selection visuals. Introduces popover surface CSS variables and settings for translucency and blur, with new appearance controls in settings. Updates context menu and tooltip to use popover surface styling. Refactors selection handling logic for right-click/context menu. Adds and updates related unit tests. Removes obsolete PR checklist.
Sidebar section expanded/collapsed state is now persisted in the layout store and restored across reloads. Updated Sidebar to use the layout store for section state, added e2e and unit tests for persistence, and removed redundant inline comments from various files for clarity.
Introduces a Rust-side thumbnail generator using the `image` crate, exposes it via Tauri, and adds a new `Thumbnail` model. The React `FileThumbnail` component now supports LQIP (low-quality image placeholder) and progressive thumbnail loading using Tauri, with tests for LQIP and fallback logic. Removes unused actions from `FileRowActions`, updates context menu selection logic, and adds/updates tests for keyboard shortcuts, rename flows, and tab opening behavior.
Replaces direct global variable access for performance and navigation logging with new utility functions in devLogger.ts. Updates all relevant modules to use get/set helpers for __fm_perfLog, __fm_lastFiles, and __fm_lastNav, improving maintainability and testability. Removes global variable declarations from global.d.ts and adds tests for the new devLogger utilities.
Extracted file explorer logic into useFileExplorerLogic for better separation of concerns and simplified FileExplorer component. Introduced preview panel hooks (usePreviewPanel, useFolderPreview) and modularized preview panel UI into separate components (FileMetadata, FilePreviewContent, FolderPreview, ImageViewer). Updated related tests and types for consistency.
Introduces comprehensive tests for file row date formatting, settings reactivity, thumbnail LRU cache, settings persistence, and performance options. Adds 'auto' date format option, updates default date format, and improves accessibility for toggle switches. Increases default thumbnail cache size, exposes test-only cache utilities, and ensures tauri thumbnail command is robustly handled. Updates types and logic to support new settings and behaviors.
Updated the test to locate the 'Размер кэша миниатюр' slider more robustly by searching for the range input whose parent contains the label text. This makes the test less dependent on input order and more resilient to UI changes.
@kotru21 kotru21 merged commit 8314b6b into main Dec 22, 2025
5 checks passed
@kotru21 kotru21 deleted the feature/settings branch December 22, 2025 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant