GUI Control & Settings
Estimated reading time: 3 minutesThe GUIControl service manages the framework's settings panel, implemented through the ModLoaderGui AngularJS component system. Settings data is persisted to IndexedDB.
The settings page adds a “Reset framework defaults” control: it restores $options.maplebirch to defaults and fires :rest-options, then redraws the current settings view. See Reset framework settings below.
Settings Panel
The framework registers an AngularJS component maplebirch-control-component via ModSubUiAngularJs, displayed on the ModLoader settings page.
Panel Features
- Language Switch — Toggle framework language between EN/CN
- Debug Mode — Enable/disable DEBUG log level
- Module Management — Enable/disable extension modules (visible only in debug mode)
- Script Management — Enable/disable Mod scripts (visible only in debug mode)
- Reset Framework Settings — Clears
$options.maplebirchto defaults and triggers the internal:rest-optionsevent so the Variables module re-applies option defaults (the settings overlay refreshes in place) - Clear Database — Reset IndexedDB (visible only in debug mode)
Operation Instructions
Cascade Dependencies
When disabling a module, other modules that depend on it will be cascade-disabled. When enabling a module, other disabled modules that this module depends on will be cascade-enabled.
IndexedDB Persistence
The framework uses IndexedDB as the settings storage backend, with database name maplebirch.
Core Service
IndexedDBService (accessible via maplebirch.idb) provides the following functionality:
Register Store
Store registration should be completed in the :IndexedDB event:
Transaction Operations
Other Methods
Built-in Stores
The framework registers the following IndexedDB stores:
