Commit Graph

4 Commits

Author SHA1 Message Date
JhumanJ 61fc30b95c Enhance Pinia History Plugin with State Filtering and Configuration Options
- Added an `ignoreKeys` option in the `mergeOptions` function of `pinia-history.js` to specify keys that should be excluded from history tracking, improving the plugin's flexibility.
- Introduced a new `filterState` function to filter out ignored keys from the state object, ensuring that only relevant state changes are tracked.
- Updated the history management logic to utilize the filtered state, enhancing the accuracy of undo/redo functionality.
- Modified the `working_form.js` store to include default ignored keys for history tracking, streamlining the configuration process.

These changes aim to improve the usability and performance of the Pinia history plugin by allowing developers to customize which state properties are tracked, thereby reducing unnecessary history entries.
2025-05-27 17:45:16 +02:00
Julien Nahum 3dd3147b19 Enhance ESLint Configuration and Improve Code Consistency
- Updated ESLint configuration in `.eslintrc.cjs` to enforce error handling for unused variables, allowing for better code quality and maintainability.
- Added `clone-deep` import in `OpenForm.vue` to facilitate deep cloning of objects, enhancing functionality.
- Refactored variable destructuring in `ColumnCondition.vue` and `useAlert.js` to improve readability by using underscore for ignored parameters.
- Modified `pinia-history.js` to use underscore for unused parameters in the `get` and `set` functions, aligning with the new ESLint rules.

These changes aim to improve code quality, maintainability, and consistency across the codebase.
2025-03-27 11:07:39 +01:00
Julien Nahum a912a10145 Fix OpnForm production 2024-06-25 16:41:14 +02:00
Chirag Chhatrala 0334f7c883
Undo/redo form editor (#452)
* Undo/redo form editor

* Fix undo/redo

* Fix history with version check

* Increase default history size

---------

Co-authored-by: Julien Nahum <julien@nahum.net>
2024-06-25 15:48:20 +02:00