refactor(project): re-adjust the overall folder

This commit is contained in:
vince
2024-07-23 00:03:59 +08:00
parent a1a566cb2f
commit 14538f7ed5
281 changed files with 1365 additions and 1659 deletions

View File

@@ -11,8 +11,7 @@
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm unbuild --stub"
"build": "pnpm unbuild"
},
"files": [
"dist"

View File

@@ -11,8 +11,7 @@
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm unbuild --stub"
"build": "pnpm unbuild"
},
"files": [
"dist"
@@ -36,7 +35,7 @@
},
"dependencies": {
"@iconify/vue": "^4.1.2",
"lucide-vue-next": "^0.411.0",
"lucide-vue-next": "^0.414.0",
"vue": "^3.4.33"
}
}

View File

@@ -11,8 +11,7 @@
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm unbuild --stub"
"build": "pnpm unbuild"
},
"files": [
"dist"

View File

@@ -67,7 +67,7 @@ class StorageManager {
* @param defaultValue 当项不存在或已过期时返回的默认值
* @returns 值,如果项已过期或解析错误则返回默认值
*/
getItem<T>(key: string, defaultValue: T | null = null): T | null {
getItem<T>(key: string, defaultValue: null | T = null): null | T {
const fullKey = this.getFullKey(key);
const itemStr = this.storage.getItem(fullKey);
if (!itemStr) {

View File

@@ -7,7 +7,7 @@ interface StorageValue<T> {
interface IStorageCache {
clear(): void;
getItem<T>(key: string): T | null;
getItem<T>(key: string): null | T;
key(index: number): null | string;
length(): number;
removeItem(key: string): void;

View File

@@ -41,4 +41,4 @@ function isValidColor(color?: string) {
return new TinyColor(color).isValid;
}
export { TinyColor, convertToHsl, convertToHslCssVar, isValidColor };
export { convertToHsl, convertToHslCssVar, isValidColor, TinyColor };

View File

@@ -11,8 +11,7 @@
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm build --stub"
"build": "pnpm unbuild"
},
"files": [
"dist"

View File

@@ -39,7 +39,7 @@ type AnyFunction<T extends any[] = any[], R = void> =
/**
* T | null 包装
*/
type Nullable<T> = T | null;
type Nullable<T> = null | T;
/**
* T | Not null 包装

View File

@@ -1,4 +1,4 @@
import type { RouteRecordRaw, Router } from 'vue-router';
import type { Router, RouteRecordRaw } from 'vue-router';
import type { Component } from 'vue';