From 6758b923cc1ef234ec63f957f105db839fccbeca Mon Sep 17 00:00:00 2001 From: aooiuu Date: Sat, 11 May 2024 20:20:04 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E8=B0=83=E6=95=B4=E7=9B=AE?= =?UTF-8?q?=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/vscode/src/App.ts | 16 ++++++++-------- .../TreeItemDecorationProvider.ts | 0 .../vscode/src/{treeview => sidebar}/book.ts | 0 .../src/{treeview => sidebar}/bookManager.ts | 0 .../src/{treeview => sidebar}/favorites.ts | 0 .../vscode/src/{treeview => sidebar}/history.ts | 0 .../src/{treeview => sidebar}/localBook.ts | 0 .../vscode/src/{treeview => sidebar}/source.ts | 0 .../src/{treeview => sidebar}/webviewProvider.ts | 0 packages/vscode/src/webview/WebviewEvent.ts | 2 +- packages/vscode/src/webview/index.ts | 2 +- 11 files changed, 10 insertions(+), 10 deletions(-) rename packages/vscode/src/{treeview => sidebar}/TreeItemDecorationProvider.ts (100%) rename packages/vscode/src/{treeview => sidebar}/book.ts (100%) rename packages/vscode/src/{treeview => sidebar}/bookManager.ts (100%) rename packages/vscode/src/{treeview => sidebar}/favorites.ts (100%) rename packages/vscode/src/{treeview => sidebar}/history.ts (100%) rename packages/vscode/src/{treeview => sidebar}/localBook.ts (100%) rename packages/vscode/src/{treeview => sidebar}/source.ts (100%) rename packages/vscode/src/{treeview => sidebar}/webviewProvider.ts (100%) diff --git a/packages/vscode/src/App.ts b/packages/vscode/src/App.ts index b9c18e02..84807bf5 100644 --- a/packages/vscode/src/App.ts +++ b/packages/vscode/src/App.ts @@ -6,14 +6,14 @@ import { CONSTANTS } from '@any-reader/shared'; import { BookChapter, checkDir } from '@any-reader/shared/localBookManager'; import * as localBookManager from '@any-reader/shared/localBookManager'; import { COMMANDS, BOOK_SOURCE_PATH } from './constants'; -import bookProvider from './treeview/book'; -import historyProvider from './treeview/history'; -import sourceProvider from './treeview/source'; -import favoritesProvider from './treeview/favorites'; -import localProvider from './treeview/localBook'; -import bookManager from './treeview/bookManager'; -import { treeItemDecorationProvider } from './treeview/TreeItemDecorationProvider'; -import { webviewProvider } from './treeview/webviewProvider'; +import bookProvider from './sidebar/book'; +import historyProvider from './sidebar/history'; +import sourceProvider from './sidebar/source'; +import favoritesProvider from './sidebar/favorites'; +import localProvider from './sidebar/localBook'; +import bookManager from './sidebar/bookManager'; +import { treeItemDecorationProvider } from './sidebar/TreeItemDecorationProvider'; +import { webviewProvider } from './sidebar/webviewProvider'; import * as ruleFileManager from './utils/ruleFileManager'; import historyManager from './utils/historyManager'; import favoritesManager from './utils/favoritesManager'; diff --git a/packages/vscode/src/treeview/TreeItemDecorationProvider.ts b/packages/vscode/src/sidebar/TreeItemDecorationProvider.ts similarity index 100% rename from packages/vscode/src/treeview/TreeItemDecorationProvider.ts rename to packages/vscode/src/sidebar/TreeItemDecorationProvider.ts diff --git a/packages/vscode/src/treeview/book.ts b/packages/vscode/src/sidebar/book.ts similarity index 100% rename from packages/vscode/src/treeview/book.ts rename to packages/vscode/src/sidebar/book.ts diff --git a/packages/vscode/src/treeview/bookManager.ts b/packages/vscode/src/sidebar/bookManager.ts similarity index 100% rename from packages/vscode/src/treeview/bookManager.ts rename to packages/vscode/src/sidebar/bookManager.ts diff --git a/packages/vscode/src/treeview/favorites.ts b/packages/vscode/src/sidebar/favorites.ts similarity index 100% rename from packages/vscode/src/treeview/favorites.ts rename to packages/vscode/src/sidebar/favorites.ts diff --git a/packages/vscode/src/treeview/history.ts b/packages/vscode/src/sidebar/history.ts similarity index 100% rename from packages/vscode/src/treeview/history.ts rename to packages/vscode/src/sidebar/history.ts diff --git a/packages/vscode/src/treeview/localBook.ts b/packages/vscode/src/sidebar/localBook.ts similarity index 100% rename from packages/vscode/src/treeview/localBook.ts rename to packages/vscode/src/sidebar/localBook.ts diff --git a/packages/vscode/src/treeview/source.ts b/packages/vscode/src/sidebar/source.ts similarity index 100% rename from packages/vscode/src/treeview/source.ts rename to packages/vscode/src/sidebar/source.ts diff --git a/packages/vscode/src/treeview/webviewProvider.ts b/packages/vscode/src/sidebar/webviewProvider.ts similarity index 100% rename from packages/vscode/src/treeview/webviewProvider.ts rename to packages/vscode/src/sidebar/webviewProvider.ts diff --git a/packages/vscode/src/webview/WebviewEvent.ts b/packages/vscode/src/webview/WebviewEvent.ts index 3fc9ac0f..e8da1719 100644 --- a/packages/vscode/src/webview/WebviewEvent.ts +++ b/packages/vscode/src/webview/WebviewEvent.ts @@ -10,7 +10,7 @@ import * as localBookManager from '@any-reader/shared/localBookManager'; import { COMMANDS } from '../constants'; import * as ruleFileManager from '../utils/ruleFileManager'; import { createAdapter } from '../utils/easyPostMessage'; -import favoritesProvider from '../treeview/favorites'; +import favoritesProvider from '../sidebar/favorites'; import favoritesManager from '../utils/favoritesManager'; function success(data: any, msg = '') { diff --git a/packages/vscode/src/webview/index.ts b/packages/vscode/src/webview/index.ts index 77130ccd..5d869605 100644 --- a/packages/vscode/src/webview/index.ts +++ b/packages/vscode/src/webview/index.ts @@ -9,7 +9,7 @@ import { ContentType } from '@any-reader/core'; import type { BookChapter } from '@any-reader/shared/localBookManager'; import * as localBookManager from '@any-reader/shared/localBookManager'; import { sleep } from '../utils/sleep'; -import bookManager, { TreeNode } from '../treeview/bookManager'; +import bookManager, { TreeNode } from '../sidebar/bookManager'; import { WebviewEvent } from './WebviewEvent'; import { getWebViewContent } from '../utils/webview';