mirror of
https://gitee.com/nocobase/nocobase.git
synced 2025-05-08 15:09:27 +08:00
* fix: missing less loader while building client * fix: correct regex for .less file handling and resolve less-loader path * feat: dynamic import big react components for core plugins * chore: revert lerna.json * chore: remove global deps duplications [skip ci] * chore: optimization * feat: dynamic import for markdown vditor plugin * chore: optimization * chore: more optimization * feat: code split for plugins with some ui components * fix: incorrect submodule commit * fix: test cases failure * chore: refactor hook lazy import * chore: improve lazy component loading * chore: lazy load vditor lib's js files [skip ci] * chore: add bundle analyze option for client bundle * chore: update loading sytle * fix: add spinner when loading umi js files * chore: clean * chore: resolve develop branch confliction * chore: refactor helper function name * fix: error of lazy duplication [skip ci] * fix: replace useImported with uselazyhook * chore: rename * chore: add comments for the helper function * chore: update comment * fix: keep suspense into component level * fix: improve code --------- Co-authored-by: chenos <chenlinxh@gmail.com>
34 lines
944 B
TypeScript
34 lines
944 B
TypeScript
/**
|
|
* This file is part of the NocoBase (R) project.
|
|
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
* Authors: NocoBase Team.
|
|
*
|
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
*/
|
|
|
|
import { Plugin } from '@nocobase/client';
|
|
import { lang } from './locale';
|
|
// import { LogsDownloader } from './LogsDownloader';
|
|
import { lazy } from '@nocobase/client';
|
|
const { LogsDownloader } = lazy(() => import('./LogsDownloader'), 'LogsDownloader');
|
|
|
|
export class PluginLoggerClient extends Plugin {
|
|
async afterAdd() {
|
|
// await this.app.pm.add()
|
|
}
|
|
|
|
async beforeLoad() {}
|
|
|
|
// You can get and modify the app instance here
|
|
async load() {
|
|
this.app.pluginSettingsManager.add('logger', {
|
|
title: lang('Logger'),
|
|
icon: 'FileTextOutlined',
|
|
Component: LogsDownloader,
|
|
});
|
|
}
|
|
}
|
|
|
|
export default PluginLoggerClient;
|