daily tag

This commit is contained in:
下羊 2020-03-13 09:48:37 +08:00
parent 3c44a68ccb
commit 2c013dbfc5
4 changed files with 15 additions and 12 deletions

View File

@ -1,8 +1,8 @@
const { eslint, deepmerge } = require('@ice/spec');
const { tslint, deepmerge } = require('@ice/spec');
module.exports = deepmerge(eslint, {
module.exports = deepmerge(tslint, {
rules: {
"global-require": 0,
"interface-name" : [true, "never-prefix"]
"@typescript-eslint/interface-name-prefix": 0
},
});

View File

@ -12,7 +12,7 @@ module.exports = {
},
plugins: [
['ice-plugin-fusion', {
themePackage: '@alife/theme-lowcode-light',
themePackage: '@alife/theme-lowcode-dark',
}],
['ice-plugin-moment-locales', {
locales: ['zh-cn'],

View File

@ -9,7 +9,7 @@ export interface EditorConfig {
shortCuts?: ShortCutsConfig;
utils?: UtilsConfig;
constants?: ConstantsConfig;
lifeCycles?: lifeCyclesConfig;
lifeCycles?: LifeCyclesConfig;
i18n?: I18nConfig;
}
@ -38,7 +38,7 @@ export interface ThemeConfig {
}
export interface PluginsConfig {
[propName: string]: Array<PluginConfig>;
[propName: string]: PluginConfig[];
}
export interface PluginConfig {
@ -63,7 +63,7 @@ export interface PluginConfig {
pluginProps?: object;
}
export type HooksConfig = Array<HookConfig>;
export type HooksConfig = HookConfig[];
export interface HookConfig {
message: string;
@ -71,14 +71,14 @@ export interface HookConfig {
handler: (editor: Editor, ...args) => void;
}
export type ShortCutsConfig = Array<ShortCutConfig>;
export type ShortCutsConfig = ShortCutConfig[];
export interface ShortCutConfig {
keyboard: string;
handler: (editor: Editor, ev: React.KeyboardEventHandler<HTMLElement>, keymaster: any) => void;
}
export type UtilsConfig = Array<UtilConfig>;
export type UtilsConfig = UtilConfig[];
export interface UtilConfig {
name: string;
@ -88,7 +88,7 @@ export interface UtilConfig {
export type ConstantsConfig = object;
export interface lifeCyclesConfig {
export interface LifeCyclesConfig {
init?: (editor: Editor) => any;
destroy?: (editor: Editor) => any;
}
@ -114,7 +114,7 @@ export interface Utils {
export interface PluginClass extends React.ComponentClass<{
editor: Editor;
[key: string]: any
[key: string]: any;
}> {
init?: (editor: Editor) => void;
open?: () => any;
@ -133,3 +133,4 @@ export interface PluginStatus {
locked?: boolean;
};
}

View File

@ -17,9 +17,11 @@ if (res && res[1]) {
// 重要用于矫正画布执行new Function的window对象上下文
window.__newFunc = funContext => {
return new Function(funContext);
return new Function(funContext);
};
// 关闭浏览器前提醒,只有产生过交互才会生效
window.onbeforeunload = function(e) {
e = e || window.event;