Skip to content

Commit

Permalink
refactor: use namespace import
Browse files Browse the repository at this point in the history
  • Loading branch information
AnYiEE committed Nov 20, 2023
1 parent aacc399 commit 169e461
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/AdvancedSiteNotices/AdvancedSiteNotices.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import OPTIONS from './options.json';
import * as OPTIONS from './options.json';
import type {RemoteNotices} from './modules/util/queryApi';
import {WG_ACTION} from './modules/constant';
import {loadRemoteNotices} from './modules/loadRemoteNotices';
Expand Down
2 changes: 1 addition & 1 deletion src/AdvancedSiteNotices/modules/api.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import OPTIONS from '../options.json';
import * as OPTIONS from '../options.json';
import {WG_WIKI_ID} from './constant';
import {initMwApi} from '../../util';

Expand Down
2 changes: 1 addition & 1 deletion src/AdvancedSiteNotices/modules/util/queryApi.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import OPTIONS from '../../options.json';
import * as OPTIONS from '../../options.json';
import {WG_USER_LANGUAGE} from '../constant';
import {api} from '../api';

Expand Down
2 changes: 1 addition & 1 deletion src/Clipboard/Clipboard.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import ClipboardJS from 'clipboard';
import * as ClipboardJS from 'clipboard';

if (!window.ClipboardJS) {
window.ClipboardJS = ClipboardJS;
Expand Down
2 changes: 1 addition & 1 deletion src/Toastify/Toastify.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Toastify from 'toastify-js';
import * as Toastify from 'toastify-js';

if (!window.toastify) {
window.toastify = (
Expand Down
5 changes: 3 additions & 2 deletions src/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* eslint-disable sort-imports */
import type {
ApiClientLoginParams as _ApiClientLoginParams,
ApiComparePagesParams as _ApiComparePagesParams,
Expand All @@ -16,9 +17,9 @@ import type {

import type {SettingGlobal as CatALotSetting} from './Cat-a-lot/modules/types'; // Cat-a-lot

import type _ClipboardJS from 'clipboard';
import type * as _ClipboardJS from 'clipboard';
import type {Tippy as _Tippy} from 'tippy.js';
import type _Toastify from 'toastify-js';
import type * as _Toastify from 'toastify-js';

type I18nCandidatesKey =
| 'en'
Expand Down

0 comments on commit 169e461

Please sign in to comment.