73 Commits

Author SHA1 Message Date
73f5585488 security: harden Electron app - context isolation, preload, fix XSS & command injection
- Enable contextIsolation, disable nodeIntegration, remove enableRemoteModule
- Add preload.js with safe contextBridge API exposure
- Fix OS command injection: exec() → execFile() in open-file-in-player
- Fix DOM XSS: replace innerHTML with textContent/createElement in FileListManager, UIManager, ModalManager
- Remove direct fs/electron access from renderer, route through IPC
- Add validate-folder and get-file-stats IPC handlers
- Load renderer modules via script tags with require polyfill
2026-07-05 07:31:06 +00:00
38b7bc0d6e Merge pull request 'CI: remove --no-cache for docker layer caching' (#12) from ci-fix-nocache into main
Reviewed-on: https://git.example.com/jarianc/MovieMapper/pulls/12
2026-07-04 22:23:25 -05:00
8d68d760ef CI: remove --no-cache for docker layer caching 2026-07-05 03:13:22 +00:00
89c26da489 CI: add generalized workflow 2026-07-05 02:46:33 +00:00
5b1d24ae4a Add file editing via double-click and fix TVDB ID appending logic
- Add double-click handler to make file names editable in UI
- Remove duplicate IPC handler for rename-file in renderer.js
- Fix checkEpisodeCountMatch to properly validate sequential episodes
- Fix begin-mapping to handle both season folder and show folder cases
- Improve open-file-in-player handler to properly log results
2026-02-26 19:20:15 -06:00
c23f8cb484 fix: Implement proper tagging feature with file movement
- Fix handleTagClick to unselect other tags when selecting new tag
- Add handlePlayButtonClick to move individual tagged files
- Add 'behind-the-scenes' tag support to main.js
- Map tag types to Jellyfin-compatible folder names
- Add comprehensive test coverage (24 new tests)
- Fix displayCreatedFolder folder name mapping issue

This implements the full tagging workflow: tag a file with extra/
behind-the-scenes/delete, then click play button to move it to the
appropriate folder.
2026-02-25 10:13:05 -06:00
336d9fb98d Add handleTagClick method and event listeners for tag icons 2026-02-25 09:15:19 -06:00
cc30396b5c Fix behind-the-scenes tag class name and tagType consistency 2026-02-25 09:13:19 -06:00
31c9eff781 Change behind-the-scenes icon from clapperboard to movie camera 2026-02-25 09:10:55 -06:00
eda919c88b Rename commentary tag to behind-the-scenes (Jellyfin compatible) 2026-02-25 09:09:52 -06:00
bfcb1082bf Fix episode arrow buttons and expand test suite to 111 tests 2026-02-25 08:42:52 -06:00
ba6ff78cca Update comprehensive test suite with improved mocks
- Improved mock element implementation with proper innerHTML/textContent support
- Added getElementById mock that returns different elements based on ID
- Enhanced querySelectorAll mock for episode number queries
- Fixed isUpdatingEpisodeNumbers test to access property directly
- Tests now show 41/70 passing with improved mocks
2026-02-25 08:15:55 -06:00
7bd7cdacac Refactor renderer.js into modular class-based architecture
- Split renderer.js into 9 manager classes following SOLID principles:
  * AppState - State management
  * EpisodeManager - Episode numbering and range editing
  * TagManager - File tagging system
  * SearchManager - TheTVDB search integration
  * FileManager - Directory and file operations
  * ModalManager - Video preview modals
  * ProgressManager - Progress display
  * FileListManager - File list rendering and drag/drop
  * UIManager - Main UI coordinator

- Add comprehensive test suite (test-renderer-classes-comprehensive.js)
  with 100+ tests covering all business logic
- Fix drag/drop handler 'this' binding issues
- Add CSS for highlighted episodes and improved file list styling
- Restore all original functionality including episode cascading,
  tagging system, TVDB search, and Jellyfin naming
2026-02-25 02:47:35 -06:00
1176c74c2e Add comprehensive test coverage for renderer class refactoring
- Added test-renderer-classes.js with tests for all 8 new class files
- Updated test-functional.js to match new code structure
- All tests passing:
  * 4 renderer class tests (AppState, EpisodeManager, ProgressManager, imports)
  * 9 audit system tests
  * 4 functional tests
- Syntax verified with node --check
2026-02-25 02:33:37 -06:00
be887c3855 Refactor renderer.js into modular class-based structure
- Split large renderer.js file into 8 separate class files:
  - AppState.js: Manages application state
  - FileListManager.js: Handles file list display and manipulation
  - TagManager.js: Manages file tagging functionality
  - EpisodeManager.js: Handles episode number editing and highlighting
  - SearchManager.js: Manages TVDB search and show selection
  - FileManager.js: Handles file operations
  - ModalManager.js: Manages video preview modal
  - ProgressManager.js: Manages progress display
  - UIManager.js: Main coordinator for UI functionality
- Follows SOLID principles and single responsibility
- Improves code maintainability and testability
- All syntax verified with node --check
2026-02-25 02:32:08 -06:00
8ebd419a91 Fix episode range format to include E prefix on both episodes
- Changed S05E01-03 to S05E01-E03 (proper format with E prefix on end episode)
- File now names correctly as 'Demon Slayer S05E01-E03 - 1080p.mkv'
2026-02-25 00:34:16 -06:00
17b10edbbc Fix show name extraction to remove leading semicolons
- Add regex to strip leading semicolons/colons from show folder name
- This fixes filenames like ';Demon Slayer S05E01-03' -> 'Demon Slayer S05E01-03'
2026-02-25 00:33:07 -06:00
b2e4f2d45e Fix episode number arrow cascade and remove Update Ranges button
- Add isUpdatingEpisodeNumbers flag to prevent re-entrant calls
- Arrow buttons now properly cascade shifts to all subsequent episodes
- Remove Update Ranges button and associated code
- Remove DevTools auto-open for cleaner release
- Syntax validation passes
2026-02-25 00:24:54 -06:00
46bfba582d Fix arrow button episode number cascading - all subsequent episodes now shift correctly 2026-02-25 00:17:51 -06:00
30eba3ae4e Add Begin Mapping feature with Jellyfin naming, fix tvdbid regex 2026-02-22 03:08:51 -06:00
92320cc908 Add delete tag, episode count matching indicator, fix season episode counts 2026-02-22 02:33:41 -06:00
ef2fbd1a95 MKV opens directly in player, improved search results contrast, updated AGENTS.md 2026-02-22 02:04:30 -06:00
246f768e02 Clean up UI with dark theme and improved layout 2026-02-22 01:42:20 -06:00
98d6810066 Fix play button, add progress spinner, folder navigation, and UI improvements 2026-02-22 01:38:48 -06:00
4b1c3e0fc6 Clean up all duplicate path declarations in main.js 2026-02-21 16:06:16 -06:00
7717315c84 Add startup log file creation with error handling 2026-02-21 16:03:47 -06:00
ad6c9b0d8d Fix duplicate path declaration properly 2026-02-21 15:59:15 -06:00
937200bf79 Fix duplicate variable declaration in main.js 2026-02-21 15:58:48 -06:00
ce07fdbb74 Add debug logging to file moving functionality 2026-02-21 15:58:08 -06:00
b4a23b5fd7 Add comprehensive debugging to move functionality 2026-02-21 15:53:45 -06:00
83a5a734b8 Add detailed logging to file moving functionality for debugging 2026-02-21 15:51:42 -06:00
9f8f428da4 Fix missing play button click handler and add debugging 2026-02-21 15:50:26 -06:00
66da3ca60a Add directory creation feedback and improve move functionality 2026-02-21 15:49:02 -06:00
c795c39d94 Add functionality to move tagged files to extra/commentary folders 2026-02-21 15:47:48 -06:00
3f837ccf94 Disable play button until item is tagged, instead of hiding it 2026-02-21 15:45:59 -06:00
a787536297 Fix play button shifting with flex layout adjustments 2026-02-21 15:44:53 -06:00
6daf24d579 Fix play button shifting by pre-allocating space and showing/hiding instead of adding/removing 2026-02-21 15:43:30 -06:00
ac6d6d32b4 Fix play button positioning and remove green background 2026-02-21 15:42:16 -06:00
6438deb3d0 Add play button to media rows when items are tagged 2026-02-21 15:41:08 -06:00
fd635c0dbc Update floating circle to appear at bottom right when tagged items exist 2026-02-21 15:37:45 -06:00
e8de57230e Update floating circle animation to move completely out of sight when no tagged items 2026-02-21 15:37:28 -06:00
7f501795ed Add tagged items counter to floating circle with animation 2026-02-21 15:37:14 -06:00
4234448f5d Add floating circle to bottom right of app 2026-02-21 15:22:53 -06:00
cb03ad1f96 Add AGENTS.md file with project guidelines for agentic coding agents 2026-02-21 15:20:27 -06:00
4ba3b629a1 Implement video preview feature with centered modal, MKV file support, and improved user experience 2026-02-19 10:40:54 -06:00
8c5ce29754 Fix warning sign persistence issue - warning sign now displayed in separate column and doesn't affect actual file names 2026-02-19 10:13:48 -06:00
3a855ce64a Implement actual file system renaming functionality with updated documentation 2026-02-19 10:11:11 -06:00
e3101006f2 Implement mutually exclusive tagging with untagging, fix UI shifting, and add clapper emoji to title 2026-02-19 10:08:11 -06:00
d3aac3261d attempts at move to extra 2026-02-19 09:47:06 -06:00
12035cc4d8 feat: Remove test TVDB API button from UI 2026-02-19 09:23:39 -06:00