save
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<title>Typing Word</title>
|
||||
<script>
|
||||
+(function () {
|
||||
function s() {
|
||||
function rem() {
|
||||
let html = document.documentElement;
|
||||
let max = parseInt('2048rem');
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
rem();
|
||||
window.addEventListener('resize', rem);
|
||||
})();
|
||||
}
|
||||
</script>
|
||||
<script>
|
||||
|
||||
|
||||
@@ -47,26 +47,25 @@
|
||||
"@types/file-saver": "^2.0.5",
|
||||
"@types/lodash-es": "^4.17.9",
|
||||
"@types/uuid": "^9.0.4",
|
||||
"@unocss/postcss": "^0.60.2",
|
||||
"@vitejs/plugin-vue": "^4.2.3",
|
||||
"@vitejs/plugin-vue-jsx": "^3.0.1",
|
||||
"@vue/compiler-sfc": "^3.3.4",
|
||||
"autoprefixer": "^10.4.19",
|
||||
"commitizen": "^4.3.0",
|
||||
"cz-conventional-changelog": "^3.3.0",
|
||||
"esm": "^3.2.25",
|
||||
"gulp": "^4.0.2",
|
||||
"husky": "^8.0.3",
|
||||
"postcss": "^8.4.38",
|
||||
"push-dir": "^0.4.1",
|
||||
"rollup-plugin-visualizer": "^5.9.2",
|
||||
"sass": "^1.64.2",
|
||||
"tailwindcss": "^3.4.3",
|
||||
"tslib": "^2.6.2",
|
||||
"typescript": "^5.2.0",
|
||||
"unocss": "^0.60.2",
|
||||
"unplugin-auto-import": "^0.16.6",
|
||||
"unplugin-vue-components": "^0.25.2",
|
||||
"unplugin-vue-define-options": "^1.4.1",
|
||||
"vite": "^4.4.5",
|
||||
"vite": "^5.2.0",
|
||||
"vue-tsc": "^1.8.5",
|
||||
"xlsx": "^0.18.5"
|
||||
},
|
||||
|
||||
1552
pnpm-lock.yaml
generated
1552
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@@ -1,6 +0,0 @@
|
||||
export default {
|
||||
plugins: {
|
||||
tailwindcss: {},
|
||||
autoprefixer: {},
|
||||
},
|
||||
}
|
||||
8
postcss.config.mjs
Normal file
8
postcss.config.mjs
Normal file
@@ -0,0 +1,8 @@
|
||||
// postcss.config.mjs
|
||||
import UnoCSS from '@unocss/postcss'
|
||||
|
||||
export default {
|
||||
plugins: [
|
||||
UnoCSS(),
|
||||
],
|
||||
}
|
||||
@@ -1,14 +1,9 @@
|
||||
//@import '/node_modules/element-plus/dist/index.css';
|
||||
@tailwind base;
|
||||
@tailwind components;
|
||||
@tailwind utilities;
|
||||
|
||||
@import "/node_modules/hover.css";
|
||||
@import "variable.scss";
|
||||
@import "anim";
|
||||
@import 'element-plus/theme-chalk/dark/css-vars';
|
||||
|
||||
|
||||
:root {
|
||||
--color-background: #E6E8EB;
|
||||
--color-main-bg: #E6E8EB;
|
||||
@@ -142,7 +137,7 @@ html.dark {
|
||||
}
|
||||
|
||||
html, body {
|
||||
font-size: 1px;
|
||||
//font-size: 1px;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
width: 100vw;
|
||||
|
||||
@@ -9,6 +9,7 @@ import {createI18n} from 'vue-i18n'
|
||||
import router from "@/router.ts";
|
||||
import VueVirtualScroller from 'vue-virtual-scroller'
|
||||
import 'vue-virtual-scroller/dist/vue-virtual-scroller.css'
|
||||
import 'virtual:uno.css';
|
||||
|
||||
const i18n = createI18n({
|
||||
locale: 'zh-CN',
|
||||
|
||||
@@ -120,10 +120,10 @@ function del(e) {
|
||||
@import "@/assets/css/style";
|
||||
|
||||
.dict-list-panel {
|
||||
width: 50%;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
$header-height: 60rem;
|
||||
padding: var(--space);
|
||||
$header-height: 5rem;
|
||||
//padding: var(--space);
|
||||
padding-top: 0;
|
||||
box-sizing: border-box;
|
||||
|
||||
@@ -135,18 +135,18 @@ function del(e) {
|
||||
|
||||
.tabs {
|
||||
display: flex;
|
||||
gap: 20rem;
|
||||
gap: 2rem;
|
||||
|
||||
.tab {
|
||||
color: var(--color-font-1);
|
||||
cursor: pointer;
|
||||
padding: 10rem;
|
||||
padding-bottom: 5rem;
|
||||
padding: 1rem;
|
||||
padding-bottom: 0.5rem;
|
||||
transition: all .5s;
|
||||
border-bottom: 2px solid transparent;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 6rem;
|
||||
gap: 0.6rem;
|
||||
|
||||
&.active {
|
||||
$main: rgb(64, 158, 255);
|
||||
@@ -154,7 +154,7 @@ function del(e) {
|
||||
}
|
||||
|
||||
img {
|
||||
height: 30rem;
|
||||
height: 2rem;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -168,16 +168,16 @@ function del(e) {
|
||||
flex: 1;
|
||||
overflow: auto;
|
||||
height: 100%;
|
||||
padding-right: 10rem;
|
||||
padding-right: 1rem;
|
||||
|
||||
.translate {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
color: var(--color-font-1);
|
||||
margin-bottom: 30rem;
|
||||
margin-bottom: 2rem;
|
||||
|
||||
& > span {
|
||||
font-size: 22rem;
|
||||
font-size: 1.6rem;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,7 +24,7 @@ function goHome(){
|
||||
|
||||
img {
|
||||
cursor: pointer;
|
||||
height: 35rem;
|
||||
height: 2rem;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -63,22 +63,22 @@ let length = $computed(() => {
|
||||
.dict-item {
|
||||
cursor: pointer;
|
||||
box-sizing: border-box;
|
||||
padding: 10rem;
|
||||
width: 125rem;
|
||||
height: 165rem;
|
||||
border-radius: 10rem;
|
||||
padding: 1rem;
|
||||
width: 12rem;
|
||||
height: 16rem;
|
||||
border-radius: 1rem;
|
||||
position: relative;
|
||||
background: var(--color-third-bg);
|
||||
border: 1px solid var(--color-item-border);
|
||||
color: var(--color-font-1);
|
||||
font-size: 14rem;
|
||||
font-size: 1rem;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
overflow: hidden;
|
||||
|
||||
.name {
|
||||
font-size: 16rem;
|
||||
font-size: 1rem;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
display: -webkit-box; //作为弹性伸缩盒子模型显示。
|
||||
@@ -103,14 +103,14 @@ let length = $computed(() => {
|
||||
|
||||
.go {
|
||||
position: absolute;
|
||||
right: 10rem;
|
||||
bottom: 15rem;
|
||||
right: 1rem;
|
||||
bottom: 1rem;
|
||||
}
|
||||
|
||||
.del {
|
||||
position: absolute;
|
||||
top: 10rem;
|
||||
right: 10rem;
|
||||
top: 1rem;
|
||||
right: 1rem;
|
||||
opacity: 0;
|
||||
transition: opacity .3s;
|
||||
}
|
||||
@@ -139,17 +139,17 @@ let length = $computed(() => {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
height: 55rem;
|
||||
width: 55rem;
|
||||
height: 4rem;
|
||||
width: 4rem;
|
||||
color: white;
|
||||
//background-color: skyblue;
|
||||
background-color: var(--color-main-active);
|
||||
clip-path: polygon(0 10%, 0% 100%, 100% 100%);
|
||||
font-size: 12rem;
|
||||
font-size: 0.8rem;
|
||||
display: flex;
|
||||
justify-content: flex-start;
|
||||
align-items: flex-end;
|
||||
padding: 4rem;
|
||||
padding: 0.2rem;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ const emit = defineEmits<{
|
||||
.dict-list {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 15rem;
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
</style>
|
||||
@@ -60,7 +60,6 @@ const runtimeStore = useRuntimeStore()
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
display: flex;
|
||||
font-size: 14rem;
|
||||
}
|
||||
|
||||
.aside {
|
||||
@@ -69,23 +68,23 @@ const runtimeStore = useRuntimeStore()
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 100vh;
|
||||
width: 200rem;
|
||||
padding: 20rem 10rem;
|
||||
width: 12rem;
|
||||
padding: 1rem 1rem;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.row {
|
||||
padding: 10rem;
|
||||
padding: 0.5rem;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10rem;
|
||||
font-size: 16rem;
|
||||
gap: 0.5rem;
|
||||
font-size: 1rem;
|
||||
//font-weight: bold;
|
||||
|
||||
svg {
|
||||
font-size: 36rem;
|
||||
font-size: 2rem;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,13 +1,64 @@
|
||||
<script setup lang="ts">
|
||||
import {useBaseStore} from "@/stores/base.ts";
|
||||
import DictListPanel from "@/pages/pc/components/DictListPanel.vue";
|
||||
import {Icon} from '@iconify/vue'
|
||||
import {ActivityCalendar} from "vue-activity-calendar";
|
||||
import "vue-activity-calendar/style.css";
|
||||
|
||||
const base = useBaseStore()
|
||||
|
||||
function clickEvent(e) {
|
||||
console.log('e', e)
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="word flex s1s font-bold underline">
|
||||
asdf
|
||||
<div class="word flex justify-center h-full">
|
||||
<div class="w-3/5">
|
||||
<div class="card flex justify-between items-center">
|
||||
<div class="bg-slate-200 p-5 rounded-md cursor-pointer flex items-center">
|
||||
<span>{{ base.currentDict.name }}</span>
|
||||
<Icon icon="mingcute:right-line" class="text-2xl ml-2"/>
|
||||
</div>
|
||||
<div class="rounded-xl bg-slate-800 flex items-center py-3 px-5 text-white">
|
||||
开始学习
|
||||
</div>
|
||||
</div>
|
||||
<div class="card">
|
||||
<div class="title">
|
||||
学习记录
|
||||
</div>
|
||||
<div class="center">
|
||||
<ActivityCalendar
|
||||
:data="[{ date: '2023-05-22', count: 5 }]"
|
||||
:width="40"
|
||||
:height="7"
|
||||
:cellLength="16"
|
||||
:cellInterval="8"
|
||||
:fontSize="12"
|
||||
:showLevelFlag="false"
|
||||
:showWeekDayFlag="false"
|
||||
:clickEvent="clickEvent"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<DictListPanel
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.card {
|
||||
@apply rounded-xl bg-white p-5 mt-10 ;
|
||||
}
|
||||
|
||||
.center {
|
||||
@apply flex justify-center items-center;
|
||||
}
|
||||
|
||||
.title {
|
||||
@apply text-xl font-bold;
|
||||
}
|
||||
</style>
|
||||
@@ -1,12 +0,0 @@
|
||||
/** @type {import('tailwindcss').Config} */
|
||||
export default {
|
||||
content: [
|
||||
"./index.html",
|
||||
"./src/**/*.{vue,js,ts,jsx,tsx}",
|
||||
],
|
||||
theme: {
|
||||
extend: {},
|
||||
},
|
||||
plugins: [],
|
||||
}
|
||||
|
||||
13
uno.config.ts
Normal file
13
uno.config.ts
Normal file
@@ -0,0 +1,13 @@
|
||||
// uno.config.ts
|
||||
import {defineConfig, presetUno} from 'unocss'
|
||||
|
||||
export default defineConfig({
|
||||
content: {
|
||||
filesystem: [
|
||||
'**/*.{html,js,ts,jsx,tsx,vue,svelte,astro}',
|
||||
],
|
||||
},
|
||||
presets: [
|
||||
presetUno(),
|
||||
],
|
||||
})
|
||||
@@ -1,6 +1,6 @@
|
||||
import {defineConfig} from 'vite'
|
||||
import vue from '@vitejs/plugin-vue'
|
||||
import vueJsx from "@vitejs/plugin-vue-jsx";
|
||||
import Vue from '@vitejs/plugin-vue'
|
||||
import VueJsx from "@vitejs/plugin-vue-jsx";
|
||||
import {resolve} from 'path'
|
||||
import {visualizer} from "rollup-plugin-visualizer";
|
||||
import {ElementPlusResolver} from "unplugin-vue-components/resolvers";
|
||||
@@ -8,6 +8,7 @@ import AutoImport from 'unplugin-auto-import/vite'
|
||||
import Components from 'unplugin-vue-components/vite'
|
||||
import {getLastCommit} from "git-last-commit";
|
||||
import DefineOptions from 'unplugin-vue-define-options/vite' // 引入插件
|
||||
import UnoCSS from 'unocss/vite'
|
||||
|
||||
function pathResolve(dir: string) {
|
||||
return resolve(__dirname, ".", dir)
|
||||
@@ -23,9 +24,11 @@ export default defineConfig(async () => {
|
||||
})
|
||||
return {
|
||||
plugins: [
|
||||
vue({
|
||||
Vue({
|
||||
reactivityTransform: true
|
||||
}),
|
||||
VueJsx(),
|
||||
UnoCSS(),
|
||||
AutoImport({
|
||||
resolvers: [ElementPlusResolver()],
|
||||
}),
|
||||
@@ -34,7 +37,6 @@ export default defineConfig(async () => {
|
||||
}),
|
||||
//用于给setup组件定义名字的,keep-alive需要name才能正常工作
|
||||
DefineOptions(),
|
||||
vueJsx(),
|
||||
lifecycle === 'report' ?
|
||||
visualizer({
|
||||
gzipSize: true,
|
||||
|
||||
Reference in New Issue
Block a user