diff --git a/README.md b/README.md index dcb92d2..0e91ec7 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,7 @@ __*!!!警告!!!*__ - [社区介绍](#小程序社区) - [项目设计](#第三代小程序) - [贡献规范](#社区贡献规范) +- [API文档](https://docs.apipost.cn/preview/e737de418d4ef150/419d45d8c97d6a9f) - [入门文档(等待撰写)](#第三代掌上教务处小程序) - [设计架构(等待撰写)](#第三代掌上教务处小程序) diff --git a/miniprogram/app.scss b/miniprogram/app.scss index 50e6753..c31657e 100644 --- a/miniprogram/app.scss +++ b/miniprogram/app.scss @@ -5,30 +5,90 @@ $theme-color-red: #FF9393; $theme-color-light-layout: #F8F8F8; $theme-color-light-background: #f4f0f1; $theme-color-light-title: rgba(0, 0, 0, .65); -$theme-color-light-text: rgba(0, 0, 0, .55); +$theme-color-light-text: rgba(0, 0, 0, .5); -$theme-color-dark-layout: #191919; -$theme-color-dark-background: #1f1f1f; +$theme-color-dark-layout: #1f1f1f; +$theme-color-dark-background: #181615; $theme-color-dark-title: rgba(255, 255, 255, .65); -$theme-color-dark-text: rgba(255, 255, 255, .55); +$theme-color-dark-text: rgba(255, 255, 255, .5); $black-filter: brightness(0) opacity(.65); $white-filter: brightness(100) opacity(.65); $blue-filter: opacity(.65); +// 页面容器外边距 +view.container { + width: 88%; + padding: 0 6%; +} +// 带阴影的 card +view.card { + width: calc( 100% - 36px ); + padding: 0 18px; + border-radius: 15px; + background-color: $theme-color-light-layout; + box-shadow: 0 1.6px 3.6px 0 rgba(0, 0, 0, .08), + 0 0.3px 0.9px 0 rgba(0, 0, 0, .05); +} + +// 顶部导航栏阴影 +view.top-shadow { + position: fixed; + z-index: 9999; + width: 100%; + height: 10px; + top: -10px; + box-shadow: 0 1.6px 3.6px 0 rgba(0, 0, 0, .05); +} page { - background-color: #f4f0f1; + background-color: $theme-color-light-background; color: $theme-color-light-text; - font-weight: 500; - font-size: .9em; +} + +view, text { + font-size: .99em; font-family: Hiragino Sans GB, MicroSoft YaHei; } - + +view.h1 { + color: $theme-color-light-title; + font-size: 1.5em; +} + +view.h2 { + color: $theme-color-light-title; + font-size: 1.3em; +} + +view.h3 { + color: $theme-color-light-title; + font-size: 1em; +} + @media (prefers-color-scheme: dark){ page { - background-color: #1f1f1f; - color: $theme-color-dark-text; + background-color: $theme-color-dark-background; + color: $theme-color-dark-text; + } + + view.card { + background-color: $theme-color-dark-layout; + } + + view.h1 { + color: $theme-color-dark-title; + font-size: 1.2em; + } + + view.h2 { + color: $theme-color-dark-title; + font-size: 1.3em; + } + + view.h3 { + color: $theme-color-dark-title; + font-size: 1em; } } \ No newline at end of file diff --git a/miniprogram/pages/Account/Account.json b/miniprogram/pages/Account/Account.json index 8835af0..e8c2c06 100644 --- a/miniprogram/pages/Account/Account.json +++ b/miniprogram/pages/Account/Account.json @@ -1,3 +1,4 @@ { - "usingComponents": {} + "usingComponents": {}, + "navigationBarTitleText": "设置" } \ No newline at end of file diff --git a/miniprogram/pages/Account/Account.scss b/miniprogram/pages/Account/Account.scss index e69de29..1557d1d 100644 --- a/miniprogram/pages/Account/Account.scss +++ b/miniprogram/pages/Account/Account.scss @@ -0,0 +1,39 @@ +@import "../../app.scss"; + +view.container { + + // 用户卡片 + view.user-card { + margin-top: 20px; + height: 100px; + display: flex; + padding-top: 20px; + padding-bottom: 20px; + + view.avatar { + width: 80px; + height: 80px; + border-radius: 1000px; + overflow: hidden; + } + + view.info { + width: calc(100% - 80px - 20px); + padding-left: 20px; + + view.nick { + margin: 4px 0; + } + + view.student { + margin: 1px 0; + } + } + } +} + +@media (prefers-color-scheme: dark) { + view.container view.user-card view.avatar{ + filter: brightness(.8); + } +} \ No newline at end of file diff --git a/miniprogram/pages/Account/Account.wxml b/miniprogram/pages/Account/Account.wxml index 715e00c..9b41eea 100644 --- a/miniprogram/pages/Account/Account.wxml +++ b/miniprogram/pages/Account/Account.wxml @@ -1 +1,22 @@ - + + + + + + + + + + + + + + + + + 秦浩轩 + 1806240113 + + + + \ No newline at end of file diff --git a/miniprogram/pages/Timetable/StatusBar.scss b/miniprogram/pages/Timetable/StatusBar.scss index 3e5863f..c0bca9f 100644 --- a/miniprogram/pages/Timetable/StatusBar.scss +++ b/miniprogram/pages/Timetable/StatusBar.scss @@ -9,7 +9,7 @@ view.status-bar { display: flex; position: fixed; justify-content: space-between; - background-color: #F8F8F8; + background-color: $theme-color-light-layout; view.select { flex: 1; @@ -111,7 +111,7 @@ view.status-bar-blank { } view.status-bar { - background-color: #191919; + background-color: $theme-color-dark-layout; view.select image { filter: $white-filter; diff --git a/miniprogram/theme.json b/miniprogram/theme.json index f7a1521..5be0b04 100644 --- a/miniprogram/theme.json +++ b/miniprogram/theme.json @@ -11,9 +11,9 @@ }, "dark": { - "navigationBarBackgroundColor": "#191919", + "navigationBarBackgroundColor": "#1f1f1f", "navigationBarTextStyle": "white", - "backgroundColor": "#1f1f1f", + "backgroundColor": "#191919", "tabBarColor": "#666666", "tabBarImage0": "image/navBar/0_dark.png", diff --git a/project.config.json b/project.config.json index ec8c334..de9e730 100644 --- a/project.config.json +++ b/project.config.json @@ -1,58 +1,58 @@ { - "description": "项目配置文件", - "packOptions": { - "ignore": [] - }, - "miniprogramRoot": "miniprogram/", - "compileType": "miniprogram", - "libVersion": "2.16.1", - "projectname": "mini-dlpu-v3", - "setting": { - "urlCheck": false, - "es6": true, - "enhance": true, - "postcss": true, - "preloadBackgroundData": false, - "minified": true, - "newFeature": false, - "coverView": true, - "nodeModules": false, - "autoAudits": false, - "showShadowRootInWxmlPanel": true, - "scopeDataCheck": false, - "uglifyFileName": true, - "checkInvalidKey": true, - "checkSiteMap": true, - "uploadWithSourceMap": true, - "compileHotReLoad": false, - "lazyloadPlaceholderEnable": false, - "useMultiFrameRuntime": true, - "useApiHook": true, - "useApiHostProcess": true, - "babelSetting": { - "ignore": [], - "disablePlugins": [], - "outputPath": "" + "description": "项目配置文件", + "packOptions": { + "ignore": [] }, - "enableEngineNative": false, - "useIsolateContext": false, - "userConfirmedBundleSwitch": false, - "packNpmManually": false, - "packNpmRelationList": [], - "minifyWXSS": true, - "disableUseStrict": false, - "minifyWXML": true, - "showES6CompileOption": false, - "useCompilerPlugins": [ - "typescript", - "sass" - ] - }, - "simulatorType": "wechat", - "simulatorPluginLibVersion": {}, - "appid": "wx7d809f5e8955843d", - "scripts": { - "beforeCompile": "" - }, - "condition": {} + "miniprogramRoot": "miniprogram/", + "compileType": "miniprogram", + "libVersion": "2.16.1", + "projectname": "mini-dlpu-v3", + "setting": { + "urlCheck": false, + "es6": true, + "enhance": true, + "postcss": true, + "preloadBackgroundData": false, + "minified": true, + "newFeature": false, + "coverView": true, + "nodeModules": false, + "autoAudits": false, + "showShadowRootInWxmlPanel": true, + "scopeDataCheck": false, + "uglifyFileName": true, + "checkInvalidKey": true, + "checkSiteMap": true, + "uploadWithSourceMap": true, + "compileHotReLoad": false, + "lazyloadPlaceholderEnable": false, + "useMultiFrameRuntime": false, + "useApiHook": false, + "useApiHostProcess": false, + "babelSetting": { + "ignore": [], + "disablePlugins": [], + "outputPath": "" + }, + "enableEngineNative": false, + "useIsolateContext": false, + "userConfirmedBundleSwitch": false, + "packNpmManually": false, + "packNpmRelationList": [], + "minifyWXSS": true, + "disableUseStrict": false, + "minifyWXML": true, + "showES6CompileOption": false, + "useCompilerPlugins": [ + "typescript", + "sass" + ] + }, + "simulatorType": "wechat", + "simulatorPluginLibVersion": {}, + "appid": "wx7d809f5e8955843d", + "scripts": { + "beforeCompile": "" + }, + "condition": {} } \ No newline at end of file diff --git a/project.private.config.json b/project.private.config.json new file mode 100644 index 0000000..41aae51 --- /dev/null +++ b/project.private.config.json @@ -0,0 +1,23 @@ +{ + "condition": { + "plugin": { + "list": [] + }, + "game": { + "list": [] + }, + "gamePlugin": { + "list": [] + }, + "miniprogram": { + "list": [ + { + "name": "Account", + "pathName": "pages/Account/Account", + "query": "", + "scene": null + } + ] + } + } +} \ No newline at end of file