- Added fields such as `nickname`, `age`, `gender`, `species`, `nationality`, `status`, and others to enhance character customization.
- Modified localization files to include new field labels and placeholders.
- Updated `CharacterComponent` and `CharacterDetail` components with UI elements for the newly added attributes.
- Introduced "Advanced Mode" toggle to manage visibility of extended customization options.
- Refactored database models and repository methods (`addNewCharacter`, `updateCharacter`, and `fetchCharacters`) to handle the extended schema.
- Improved data encryption and decryption workflows for secure storage of added attributes.
- Enhanced user experience by reorganizing character customization layouts.
- Added `handleDeleteCharacter` method to handle character deletion with confirmation prompts.
- Updated `CharacterComponent` and `CharacterDetail` to include delete button and related logic.
- Localized new strings for character deletion (e.g., confirmation prompts, success/error messages).
- Enhanced database repository methods (`deleteCharacter`) to handle character deletion securely.
- Improved synchronization workflows to accommodate character deletion.
- Added `spells_enabled` column to `book_tools` table.
- Introduced `book_spells` and `book_spell_tags` tables with related indexes for spell and tag storage.
- Updated database initialization and migration scripts to include new tables and fields.
- Introduced spell management with creation, editing, deletion, and tagging capabilities.
- Added `Spell`, `SpellList`, `SpellTagManager` models with corresponding IPC handlers for data operations.
- Implemented `SpellList` and `SpellTagChip` components for UI interactions with spells and tags.
- Localized spell-related strings for English (e.g., error messages, tooltips, and prompts).
- Enhanced database models and repositories with encryption and decryption workflows for secure data handling.
- Updated API to include filtering, searching, and tag-based spell management options.
- Implemented `AdvancedGenerationOptions` component for toggling Explicit and Smart modes with confirmation dialogs.
- Integrated generation options into `GhostWriter`, `DraftCompanion`, and `ShortStoryGenerator`.
- Introduced `ToggleWithConfirmation` component for user interaction with alerts.
- Updated `InputField` to support centered alignment for better layout flexibility.
- Localized Explicit and Smart mode strings in English and French.
- Enhanced content preview logic to filter placeholder text before display.
- Added `autoUpdater` initialization checks and refactored updater setup for improved reliability.
- Integrated `electron-updater` dependency for managing app updates.
- Configured publishing settings with a generic provider and download URL.
- Added `initAutoUpdater` method to handle app updates and implemented it in the main process.
- Updated `package.json` and `package-lock.json` to include `electron-updater` and related dependencies.
- Introduced `lastUpdate` field in `book_tools` for tracking changes.
- Refactored tool enablement logic in `CharacterComponent`, `WorldSetting`, and `LocationComponent` for consistency.
- Updated database schema and migration scripts for `book_tools` table.
- Enhanced synchronization workflows to support new `lastUpdate` logic.
- Adjusted related models, repositories, and IPC handlers for streamlined management.
- Improved type safety and robustness in tool-related methods with additional checks.
- Replaced `id` with `bookId` in `BookProps` and updated corresponding references.
- Added `tools` property to book-related components for tool management.
- Removed unused `books` property from `User` model.
- Added debug logs in `deleteBook` and `BookList` for troubleshooting.
- Unified return types across IPC handlers (`Character`, `Location`, `World`, and `Book`) for consistency.
- Replaced `BookListProps` with `BookProps` for simplified type usage in components and handlers.
- Cleaned up obsolete `BookListProps` interface and applied consistent typings throughout.
- Updated imports to include revised response types (`CharacterListResponse`, `LocationListResponse`, `WorldListResponse`).
- Adjusted data transformation logic in `BookList` and related components to align with new type definitions.
- Introduced toggling functionality for managing `characters`, `worlds`, and `locations` tool availability per book.
- Updated `CharacterComponent`, `WorldSetting`, and `LocationComponent` with toggle switches for tool enablement.
- Added `book_tools` database table and related schema migration for storing tool settings.
- Extended API calls, models, and IPC handlers to support tool enablement states.
- Localized new strings for English with supporting descriptions and messages.
- Adjusted conditional rendering logic across components to respect tool enablement.
- Implemented syncing for `GuideLine` and `AIGuideLine` entities with encryption and decryption workflows.
- Refined `GuidelineRepo` methods to check existence and update/insert records for both guideline types.
- Updated timestamp handling in `GuideLine` and `AIGuideLine` models for accurate tracking.
- Corrected QuillSense localization keys for labels and descriptions.
- Improved database queries and modularized logic for consistency.
- Introduced new "QuillSense" feature for AI-assisted book creation.
- Added QuillSense settings panel with advanced options and disable/enable functionality.
- Updated GhostWriter and TextEditor components to respect QuillSense settings.
- Extended models and repositories to track and manage QuillSense state per book.
- Localized new strings for English and French.
- Updated relative imports by replacing `@/` aliases with proper `../` paths for consistency.
- Refined type definitions in IPC handlers and repositories (`User`, `Chapter`, `Act`, etc.).
- Simplified return types in `Location` model methods for streamlined usage.
- Replaced `Book`-based references with specialized models (`Act`, `Issue`, `World`, `GuideLine`, etc.) for enhanced modularity.
- Updated synchronization, story, guideline, plot, and world-related methods to align with new models.
- Removed redundant type definitions and adjusted interfaces for consistency.
- Introduced new models: `GuideLine`, `Incident`, `PlotPoint`, `Issue`, `Act`, and `World` for managing book-related entities.
- Integrated encryption/decryption for sensitive properties in all models using user-specific keys.
- Added methods for CRUD operations and synchronization workflows with error handling and multilingual support.
- Improved maintainability with JSDoc comments and streamlined queries.
- Add JSDoc comments for better maintainability and code clarity in `BookRepo` methods.
- Streamline query definitions using variables to improve readability.
- Consolidate error handling logic across all methods.
- Ensure multilingual support in error messages for consistent user feedback.
- Remove redundant error branches and simplify unknown error processing.
- Deleted unused database table interfaces and repository methods for book acts, chapters, characters, locations, worlds, and related entities.
- Reduced code complexity by consolidating remaining logic under streamlined methods in `BookRepo`.
- Improved maintainability by cleaning up outdated query interfaces and redundant synchronization code.
- Introduce new error messages for syncing and book deletion in `en.json`.
- Update `DeleteBook` to support local-only deletion and synced book management.
- Refine offline/online behavior with `deleteLocalToo` checkbox and update related state handling.
- Extend repository and IPC methods to handle optional IDs for updates.
- Add `SyncQueueContext` for queueing offline changes and improving synchronization workflows.
- Enhance refined text generation logic in `DraftCompanion` and `GhostWriter` components.
- Replace PUT with PATCH for world updates to align with API expectations.
- Streamline `AlertBox` by integrating dynamic translation keys for deletion prompts.
- Introduced `oauthLogin` method in `electron/preload.ts` and backend IPC handlers for OAuth via `BrowserWindow`.
- Replaced web-based OAuth redirection with Electron-specific implementation for Google, Facebook, and Apple.
- Refactored `SocialForm.tsx` to handle OAuth login success and token management via Electron.
- Updated `User`, `QuillSense`, and context methods to include `quill-trial` subscriptions and extended login logic.
- Cleaned up code, removed unused imports, and improved error handling for authentication scenarios.
- Refactor components to support conditional offline and online CRUD operations.
- Introduce `addToQueue` mechanism for syncing offline changes to the server.
- Add `isChapterContentExist` method and related existence checks in repositories.
- Consolidate data structures and streamline book, chapter, character, and guideline synchronization workflows.
- Encrypt additional character fields and adjust repository inserts for offline data.
- Implement stricter security measures in the Electron app, including navigation blocking, URL validation, and external request handling.
- Add offline mode handling and UI improvements in components like `ScribeFooterBar` and `AddNewBookForm`.
- Refactor `DeleteBook` logic to include offline sync methods.
- Improve user feedback for online/offline states and synchronization errors.
- Add methods to verify the existence of acts, plot points, incidents, worlds, characters, locations, and their sub-elements in repositories.
- Update `syncBookFromServerToClient` to integrate existence checks with insert or update logic.
- Enhance multilingual error handling across repository methods.
- Refactor `TextEditor` to include book-closing functionality with updated toolbar buttons
- Replace `generateHTML` with a lightweight custom TipTap-to-HTML renderer
- Update and lock `esbuild` and related dependencies to latest versions
- Extend repository methods to handle API requests for fetching books, chapters, characters, and other entities with multilingual support (`lang: 'fr' | 'en'`).
- Add `uploadBookForSync` logic to consolidate and decrypt book data for synchronization.
- Refactor schema migration logic to remove console logs and streamline table recreation.
- Enhance error handling across database repositories and IPC methods.
- Add `useEffect` in `ScribeLeftBar` for handling book state changes.
- Extend `BooksSyncContext` with new properties and stricter typings.
- Refine `Repositories` to include `lastUpdate` handling for synchronization processes.
- Add comprehensive `fetchComplete*` repository methods for retrieving entity-specific sync data.
- Enhance offline logic for chapters, characters, locations, and world synchronization.
- Improve error handling across IPC handlers and repositories.
- Introduce `BooksSyncContext` for managing book synchronization states (server-only, local-only, to-sync, etc.).
- Remove `UserContext` and related dependencies.
- Refine localization strings (`en.json`) with sync-related updates (e.g., "toSyncFromServer", "toSyncToServer").
- Extend database schema with additional tables and fields for syncing books, chapters, and related entities.
- Add `last_update` fields and update corresponding repository methods to support synchronization logic.
- Enhance IPC handlers with stricter typing, data validation, and sync-aware operations.
- Integrate `OfflineContext` into `MainChapter` and related components to handle offline scenarios for chapter operations.
- Add conditional logic to toggle between server API requests and offline IPC handlers (`db:chapter:add`, `db:chapter:remove`).
- Extend `GET /book/story` endpoint to include `mainChapter` data.
- Refactor IPC handlers for chapters to accept structured data arguments with stricter typings.
- Update frontend key assignments for `BookList` component for improved rendering stability.
- Integrate `OfflineContext` into book, story settings, and related components.
- Add conditional logic to toggle between server API requests and offline IPC handlers (`db:book:delete`, `db:book:story:get`, `db:location:all`, etc.).
- Refactor and update IPC handlers to accept structured data arguments for improved consistency (`data: object`).
- Ensure stricter typings in IPC handlers and frontend functions.
- Improve error handling and user feedback in both online and offline modes.
- Integrate `OfflineContext` into `TextEditor` and `ScribeChapterComponent` to handle offline scenarios for chapter CRUD operations.
- Add conditional logic to switch between server API requests and offline IPC handlers (`db:chapter:add`, `db:chapter:remove`, `db:chapter:content:save`, `db:chapter:update`).
- Refactor and rename IPC handlers (`db:chapter:create` to `db:chapter:add`, `db:chapter:delete` to `db:chapter:remove`) for consistency.
- Update UI to disable certain actions when offline (e.g., GhostWriter button).
- Increment `SCHEMA_VERSION` to 2 in `schema.ts`.
- Remove all `meta_*` columns from database tables.
- Add migration logic to handle schema upgrades and clean up unused columns.
- Modify database models and repository methods to exclude `meta_*` fields for stricter typings and improved structure.
- Refactor and optimize query statements across repositories to align with new schema changes.
- Introduce `openExternal` IPC handler in `electron/main.ts` for opening external links via the default browser or native app.
- Update typings in `electron.d.ts` and `preload.ts` to include `openExternal`.
- Refactor `ComposerRightBar` and `LeftBar` components to leverage `electron.openExternal` for external link actions (e.g., Facebook, Discord).
- Add offline mode logic to filter navigation options in `ComposerRightBar` and `LeftBar`.
- Enhance footer bar to display book titles when chapters are unavailable.
- Add `OfflineContext` to manage offline state and interactions within components.
- Refactor session logic in `ScribeControllerBar` and `page.tsx` to handle offline scenarios (e.g., check connectivity before enabling GPT features).
- Enhance offline PIN setup and verification with better flow and error messaging.
- Optimize database IPC handlers to initialize and sync data in offline mode.
- Refactor code to clean up redundant logs and ensure stricter typings.
- Improve consistency and structure in handling online and offline operations for smoother user experience.
- Add explicit type annotations for improved code clarity and type safety.
- Refactor encryption/decryption logic with stricter validations and error handling.
- Remove redundant `appReady` logic and unused comments.
- Convert instance methods to `public` for consistent access modifiers.
- Streamline `saveToDisk` to ensure robust encryption and error reporting.
- Introduce `OfflinePinSetup` component for users to configure secure offline access.
- Add new `AIUsageContext` and extend `OfflineProvider` for offline-related state management.
- Implement offline login functionality in `electron/main.ts` with PIN verification and fallback support.
- Enhance IPC handlers to manage offline mode data, PIN setup, and synchronization.
- Update localization files (`en.json`, `fr.json`) with offline mode and PIN-related strings.
- Add `bcrypt` and `@types/bcrypt` dependencies for secure PIN hashing and validation.
- Refactor login and session management to handle offline mode scenarios with improved error handling and flow.
- Replace `electron-store` with OS-level encrypted storage for secure token, userId, and language management in `LocalSystem` and `keyManager`.
- Add `init-user` IPC handler to initialize user data and manage encryption keys.
- Update login process to handle encrypted storage saving with fallback for macOS issues.
- Add offline warning component to `login/page.tsx` to handle first-time sync requirements.
- Remove `electron-store` and associated dependencies from `package.json` and `package-lock.json`.
- Update return types for IPC handlers in `character.ipc.ts`, `chapter.ipc.ts`, and `location.ipc.ts` for stricter type safety.
- Introduce new type definitions for better structure and clarity.
- Remove redundant console logs and unnecessary comments for cleaner code.
- Introduce IPC handlers in `ipc/character.ipc.ts` and `ipc/location.ipc.ts` for CRUD operations, attributes management, and related actions.
- Register character and location IPC modules in `main.ts` for global accessibility.
- Utilize `createHandler` pattern for consistent and modular IPC handler implementation.
- Enhance type definitions for character and location functionalities, improving code consistency.
- Introduce IPC handlers in `ipc/chapter.ipc.ts` for chapter CRUD, content management, and related operations.
- Register chapter IPC module in `main.ts` for application-wide access.
- Enhance type definitions for chapter functionalities, improving code consistency.
- Refactor `ipc/book.ipc.ts` to include new `UpdateStoryData` interface and additional story update handler.
- Reorganize and reformat IPC handlers for improved readability and structure.
- Add missing type definitions for `StoryData`, `AddWorldElementData`, `SetAIGuideLineData`, and others.
- Simplify handler functions by enforcing consistent parameter usage and return types.
- Remove outdated comments, redundant logic, and placeholder TODOs.
- Introduce `db:user:sync` to synchronize user data with the local database during initialization.
- Add `db:user:info` and `db:user:update` IPC handlers for fetching and updating user information.
- Update `User` model and repository to support extended user fields and improved structure.
- Dynamically import user models in main process to avoid circular dependencies.
- Refactor database initialization in the app to include user sync logic with error handling.
- Replace absolute import paths with relative paths for consistency across files.
- Transition database operations in Electron main process to modular handlers in `ipc/book.ipc.ts` using the `createHandler` pattern.
- Update database sync service to use `window.electron.invoke()` for improved reliability and structure.
- Refactor `AddNewBookForm` to handle both online and offline book creation seamlessly.
- Delete `data.service.ts` and `offline-data.service.ts`, consolidating functionality into `LocalSystem`.
- Refactor book, character, and conversation operations to adopt unified, multilingual, and session-enabled IPC handlers in `LocalSystem`.
- Simplify redundant legacy methods, enhancing maintainability and consistency.
- Add `LocalSystem` with handlers for session retrieval (`userId`, `lang`) and error handling.
- Extend IPC handlers to support multilingual operations (`fr`, `en`) and session data injection
- Implement `Book` class to manage book-related operations, including CRUD functionality, cover image handling, and metadata management.
- Add interfaces for `BookProps`, `GuideLine`, `Act`, and other related structures.
- Integrate support for encryption and decryption of sensitive data.
- Include multilingual support (`fr` and `en`) for error messages and content handling.
- Establish connection with `book.repository` and other repositories for streamlined database operations.
- Delete `Story` model implementation including `getVerbesStyle` method and related properties.
- Cleanup unused interfaces and redundant logic from the codebase.
- Implement `Content` model for converting Tiptap raw data into HTML and plain text.
- Add `Model` for storing and managing AI model configurations with pricing and metadata.
- Introduce `Story` model to handle verbal styles and linguistic properties for diverse narrative structures.
- Update `book.repository.ts` to refine `updateBookBasicInformation` and `insertNewPlotPoint` methods, removing unused parameters and optimizing queries.
- Implement `CharacterRepo`, `LocationRepo`, and `UserRepo` for managing character, location, and user data with SQLite.
- Add methods for performing CRUD operations on characters, locations, and users, including attributes and metadata handling.
- Integrate error handling with multilingual support (`fr` and `en`).
- Support data encryption and synchronization using the existing database utilities.