fix var text
This commit is contained in:
@@ -177,7 +177,7 @@ export const I18N = {
|
||||
zh: `禁用`,
|
||||
en: `Disable`,
|
||||
},
|
||||
mk_none: {
|
||||
mk_mouseover: {
|
||||
zh: `鼠标悬停`,
|
||||
en: `Mouseover`,
|
||||
},
|
||||
|
||||
@@ -163,13 +163,13 @@ export const OPT_STYLE_USE_COLOR = [
|
||||
];
|
||||
|
||||
export const OPT_MOUSEKEY_DISABLE = "mk_disable";
|
||||
export const OPT_MOUSEKEY_NONE = "mk_none";
|
||||
export const OPT_MOUSEKEY_MOUSEOVER = "mk_mouseover";
|
||||
export const OPT_MOUSEKEY_CONTROL = "mk_ctrlKey";
|
||||
export const OPT_MOUSEKEY_SHIFT = "mk_shiftKey";
|
||||
export const OPT_MOUSEKEY_ALT = "mk_altKey";
|
||||
export const OPT_MOUSEKEY_ALL = [
|
||||
OPT_MOUSEKEY_DISABLE,
|
||||
OPT_MOUSEKEY_NONE,
|
||||
OPT_MOUSEKEY_MOUSEOVER,
|
||||
OPT_MOUSEKEY_CONTROL,
|
||||
OPT_MOUSEKEY_SHIFT,
|
||||
OPT_MOUSEKEY_ALT,
|
||||
|
||||
@@ -8,7 +8,7 @@ import {
|
||||
OPT_STYLE_FUZZY,
|
||||
SHADOW_KEY,
|
||||
OPT_MOUSEKEY_DISABLE,
|
||||
OPT_MOUSEKEY_NONE,
|
||||
OPT_MOUSEKEY_MOUSEOVER,
|
||||
} from "../config";
|
||||
import Content from "../views/Content";
|
||||
import { updateFetchPool, clearFetchPool } from "./fetch";
|
||||
@@ -245,7 +245,7 @@ export class Translator {
|
||||
|
||||
_handleMouseover = (e) => {
|
||||
const key = this._setting.mouseKey.slice(3);
|
||||
if (this._setting.mouseKey === OPT_MOUSEKEY_NONE || e[key]) {
|
||||
if (this._setting.mouseKey === OPT_MOUSEKEY_MOUSEOVER || e[key]) {
|
||||
e.target.removeEventListener("mouseover", this._handleMouseover);
|
||||
this._render(e.target);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user