Compare commits

..

No commits in common. "39ceff9cf76583e6cc1ee2e8e7443d39c67a619c" and "0bd52157c45fa0d6b95b635eb757ae3a5f9e0fb4" have entirely different histories.

5 changed files with 2678 additions and 2446 deletions

View File

@ -16,56 +16,57 @@
"prepare": "husky install"
},
"dependencies": {
"@chakra-ui/anatomy": "^2.2.1",
"@chakra-ui/icons": "^2.1.1",
"@chakra-ui/react": "^2.8.1",
"@emotion/react": "^11.11.1",
"@chakra-ui/anatomy": "^2.1.1",
"@chakra-ui/icons": "^2.0.19",
"@chakra-ui/react": "^2.7.0",
"@emotion/react": "^11.11.0",
"@emotion/styled": "^11.11.0",
"@jixun/libparakeet": "0.2.1",
"@reduxjs/toolkit": "^1.9.5",
"framer-motion": "^10.16.4",
"framer-motion": "^10.12.16",
"immer": "^10.0.2",
"nanoid": "^5.0.1",
"radash": "^11.0.0",
"nanoid": "^4.0.2",
"radash": "^10.8.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-dropzone": "^14.2.3",
"react-icons": "^4.11.0",
"react-icons": "^4.9.0",
"react-promise-suspense": "^0.3.4",
"react-redux": "^8.1.2",
"react-redux": "^8.0.5",
"react-syntax-highlighter": "^15.5.0",
"sass": "^1.67.0",
"sass": "^1.63.3",
"sql.js": "^1.8.0"
},
"devDependencies": {
"@rollup/plugin-replace": "^5.0.2",
"@testing-library/jest-dom": "^6.1.3",
"@testing-library/jest-dom": "^5.16.5",
"@testing-library/react": "^14.0.0",
"@testing-library/user-event": "^14.5.1",
"@types/node": "^20.6.2",
"@types/react": "^18.2.21",
"@types/react-dom": "^18.2.7",
"@testing-library/user-event": "^14.4.3",
"@types/node": "^20.2.5",
"@types/react": "^18.2.7",
"@types/react-dom": "^18.2.4",
"@types/react-syntax-highlighter": "^15.5.7",
"@types/sql.js": "^1.4.4",
"@typescript-eslint/eslint-plugin": "^6.7.0",
"@typescript-eslint/parser": "^6.7.0",
"@vitejs/plugin-react": "^4.0.4",
"@vitest/coverage-v8": "^0.34.4",
"@vitest/ui": "^0.34.4",
"eslint": "^8.49.0",
"eslint-config-prettier": "^9.0.0",
"@types/testing-library__jest-dom": "^5.14.6",
"@typescript-eslint/eslint-plugin": "^5.59.7",
"@typescript-eslint/parser": "^5.59.7",
"@vitejs/plugin-react": "^4.0.0",
"@vitest/coverage-c8": "^0.31.1",
"@vitest/ui": "^0.31.1",
"eslint": "^8.41.0",
"eslint-config-prettier": "^8.8.0",
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-react-refresh": "^0.4.3",
"eslint-plugin-react-refresh": "^0.4.1",
"husky": "^8.0.3",
"jsdom": "^22.1.0",
"lint-staged": "^14.0.1",
"prettier": "^3.0.3",
"typescript": "^5.2.2",
"vite": "^4.4.9",
"vite-plugin-pwa": "^0.16.5",
"lint-staged": "^13.2.2",
"prettier": "^2.8.8",
"typescript": "^5.0.4",
"vite": "^4.3.9",
"vite-plugin-pwa": "^0.15.1",
"vite-plugin-top-level-await": "^1.3.1",
"vite-plugin-wasm": "^3.2.2",
"vitest": "^0.34.4"
"vitest": "^0.31.1"
},
"lint-staged": {
"*": "prettier --write --ignore-unknown",
@ -79,10 +80,6 @@
"pnpm": {
"patchedDependencies": {
"sql.js@1.8.0": "patches/sql.js@1.8.0.patch"
},
"overrides": {
"rollup-plugin-terser": "npm:@rollup/plugin-terser@0.4.3",
"sourcemap-codec": "npm:@jridgewell/sourcemap-codec@1.4.15"
}
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,17 +0,0 @@
import cp from 'node:child_process';
import path from 'node:path';
import url from 'node:url';
const projectRoot = url.fileURLToPath(new URL('../', import.meta.url));
export function command(cmd: string, dir = '') {
return cp.execSync(cmd, { cwd: path.join(projectRoot, dir), encoding: 'utf-8' }).trim();
}
export function tryCommand(cmd: string, dir = '', fallback = '') {
try {
return command(cmd, dir);
} catch (e) {
return fallback;
}
}

View File

@ -6,5 +6,7 @@
"moduleResolution": "bundler",
"allowSyntheticDefaultImports": true
},
"include": ["vite.config.ts", "support/**/*.ts"]
"include": [
"vite.config.ts"
]
}

View File

@ -1,3 +1,4 @@
import cp from 'node:child_process';
import url from 'node:url';
import path from 'node:path';
import fs from 'node:fs';
@ -9,13 +10,15 @@ import replace from '@rollup/plugin-replace';
import topLevelAwait from 'vite-plugin-top-level-await';
import { VitePWA } from 'vite-plugin-pwa';
import { tryCommand } from './support/command';
const gitRoot = url.fileURLToPath(new URL('.', import.meta.url));
const pkg = JSON.parse(fs.readFileSync(gitRoot + '/package.json', 'utf-8'));
const projectRoot = url.fileURLToPath(new URL('.', import.meta.url));
const pkg = JSON.parse(fs.readFileSync(projectRoot + '/package.json', 'utf-8'));
function command(cmd, dir = '') {
return cp.execSync(cmd, { cwd: path.join(gitRoot, dir), encoding: 'utf-8' }).trim();
}
const COMMAND_GIT_VERSION = 'git describe --long --dirty --tags --always';
const shortCommit = tryCommand(COMMAND_GIT_VERSION, __dirname, 'unknown');
const shortCommit = command(COMMAND_GIT_VERSION);
const version = `${pkg.version}-${shortCommit}`;
// https://vitejs.dev/config/