forked from mirrors/misskey
refactor(frontend): カスタムディレクティブの型付け (#16659)
* refactor(frontend): カスタムディレクティブの型付け * fix
This commit is contained in:
@@ -6,8 +6,8 @@
|
||||
import type { Directive } from 'vue';
|
||||
import { getBgColor } from '@/utility/get-bg-color.js';
|
||||
|
||||
export default {
|
||||
mounted(src, binding, vn) {
|
||||
export const panelDirective = {
|
||||
mounted(src) {
|
||||
const parentBg = getBgColor(src.parentElement) ?? 'transparent';
|
||||
|
||||
const myBg = getComputedStyle(window.document.documentElement).getPropertyValue('--MI_THEME-panel');
|
||||
@@ -18,4 +18,4 @@ export default {
|
||||
src.style.backgroundColor = 'var(--MI_THEME-panel)';
|
||||
}
|
||||
},
|
||||
} as Directive;
|
||||
} as Directive<HTMLElement>;
|
||||
|
||||
Reference in New Issue
Block a user