mirror of
https://github.com/BetterSEQTA/BetterSEQTA-Plus.git
synced 2026-06-06 03:34:40 +00:00
feat: add docs and dev plugins
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
import type { Plugin } from '../../core/types';
|
||||
import { BasePlugin, BooleanSetting } from '../../core/settings';
|
||||
|
||||
class TestPluginClass extends BasePlugin {
|
||||
@BooleanSetting({
|
||||
default: true,
|
||||
title: "Test Plugin",
|
||||
description: "A test plugin for BetterSEQTA+",
|
||||
})
|
||||
enabled!: boolean;
|
||||
}
|
||||
|
||||
const settingsInstance = new TestPluginClass();
|
||||
|
||||
const testPlugin: Plugin<typeof settingsInstance.settings> = {
|
||||
id: 'test',
|
||||
name: 'Test Plugin',
|
||||
description: 'A test plugin for BetterSEQTA+',
|
||||
version: '1.0.0',
|
||||
settings: settingsInstance.settings,
|
||||
|
||||
run: async (api) => {
|
||||
console.log('Test plugin running');
|
||||
|
||||
api.seqta.onPageChange((page) => {
|
||||
console.log('Page changed to', page);
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
export default testPlugin;
|
||||
Reference in New Issue
Block a user