From 5a8f96011804444e948f6c7f26c7c78dd9024e71 Mon Sep 17 00:00:00 2001 From: Eddie <102564160@qq.com> Date: Fri, 6 Aug 2021 17:25:31 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0Login=E8=83=8C=E6=99=AF?= =?UTF-8?q?=E7=89=B9=E6=95=88--=20=20=E4=BF=AE=E6=94=B9=E4=B8=BB=E9=A2=98?= =?UTF-8?q?=E9=A2=9C=E8=89=B2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 1 + public/particles.json | 110 ++++++++++++++ src/components/ActionButton/index.vue | 200 +++++++++++++++++++++---- src/layout/components/Navbar.vue | 2 +- src/layout/components/Sidebar/Logo.vue | 2 +- src/styles/element-ui.scss | 13 +- src/styles/variables.scss | 9 +- src/views/login/index.vue | 190 +++++++++++------------ src/views/member-management/index.vue | 139 ++++++++++++++++- src/views/sort-management/index.vue | 142 +++++++++++++++++- 10 files changed, 668 insertions(+), 140 deletions(-) create mode 100644 public/particles.json diff --git a/package.json b/package.json index 27ed1ab..6983df9 100644 --- a/package.json +++ b/package.json @@ -34,6 +34,7 @@ "lodash": "^4.17.20", "normalize.css": "7.0.0", "nprogress": "0.2.0", + "particles.js": "^2.0.0", "path-to-regexp": "2.4.0", "pinyin": "2.9.0", "screenfull": "4.2.0", diff --git a/public/particles.json b/public/particles.json new file mode 100644 index 0000000..d979956 --- /dev/null +++ b/public/particles.json @@ -0,0 +1,110 @@ +{ + "particles": { + "number": { + "value": 30, + "density": { + "enable": true, + "value_area": 800 + } + }, + "color": { + "value": "#ffffff" + }, + "shape": { + "type": "circle", + "stroke": { + "width": 0, + "color": "#FFF" + }, + "polygon": { + "nb_sides": 1 + }, + "image": { + "src": "img/github.svg", + "width": 2, + "height":2 + } + }, + "opacity": { + "value": 0.5, + "random": false, + "anim": { + "enable": false, + "speed": 1, + "opacity_min": 0.1, + "sync": false + } + }, + "size": { + "value": 5, + "random": true, + "anim": { + "enable": false, + "speed": 20, + "size_min": 0.1, + "sync": false + } + }, + "line_linked": { + "enable": true, + "distance": 300, + "color": "#FFF", + "opacity": 0.2, + "width": 1 + }, + "move": { + "enable": true, + "speed": 12, + "direction": "none", + "random": false, + "straight": false, + "out_mode": "out", + "bounce": false, + "attract": { + "enable": false, + "rotateX": 600, + "rotateY": 1200 + } + } + }, + "interactivity": { + "detect_on": "canvas", + "events": { + "onhover": { + "enable": false, + "mode": "repulse" + }, + "onclick": { + "enable": true, + "mode": "push" + }, + "resize": true + }, + "modes": { + "grab": { + "distance": 800, + "line_linked": { + "opacity": 1 + } + }, + "bubble": { + "distance": 500, + "size": 80, + "duration": 2, + "opacity": 0.8, + "speed": 3 + }, + "repulse": { + "distance": 400, + "duration": 0.4 + }, + "push": { + "particles_nb": 4 + }, + "remove": { + "particles_nb": 2 + } + } + }, + "retina_detect": true +} diff --git a/src/components/ActionButton/index.vue b/src/components/ActionButton/index.vue index b7629f2..d59fbae 100644 --- a/src/components/ActionButton/index.vue +++ b/src/components/ActionButton/index.vue @@ -4,18 +4,41 @@
- - - - - {{ addBtnText }} + + + + + + {{ textBtn1 }} + + + + + + + {{ textBtn2 }} - - - - - {{ deleteBtnText }} + + + + + + {{ textBtn3 }} + + + + + + {{ textBtn4 }} + + + + + + {{ textBtn5 }} + +
@@ -55,6 +78,7 @@ */ export default { props: { + // 基础设置 openSearch: { type: Boolean, default: true @@ -67,61 +91,173 @@ export default { type: String, default: 'mini' }, - // 添加按钮 - openAdd: { + // 按钮1 + openBtn1: { type: Boolean, - default: true + default: false }, - addBtnSvg: { + isSvgBtn1: { type: Boolean, default: false }, - addBtnType: { + typeBtn1: { type: String, default: 'primary' }, - addBtnIcon: { + iconBtn1: { type: String, default: 'el-icon-plus' }, - addBtnText: { + textBtn1: { type: String, default: '' }, - // 删除按钮 - openDelete: { + disabledBtn1: { type: Boolean, - default: true + default: false }, - deleteBtnSvg: { + plainBtn1: { type: Boolean, default: false }, - deleteBtnType: { + // 按钮2 + openBtn2: { + type: Boolean, + default: false + }, + isSvgBtn2: { + type: Boolean, + default: false + }, + typeBtn2: { type: String, - default: 'danger' + default: 'primary' }, - deleteBtnIcon: { + iconBtn2: { type: String, - default: 'el-icon-delete' + default: 'el-icon-plus' }, - deleteBtnText: { + textBtn2: { type: String, default: '' + }, + disabledBtn2: { + type: Boolean, + default: false + }, + plainBtn2: { + type: Boolean, + default: false + }, + // 按钮3 + openBtn3: { + type: Boolean, + default: false + }, + isSvgBtn3: { + type: Boolean, + default: false + }, + typeBtn3: { + type: String, + default: 'primary' + }, + iconBtn3: { + type: String, + default: 'el-icon-plus' + }, + textBtn3: { + type: String, + default: '' + }, + disabledBtn3: { + type: Boolean, + default: false + }, + plainBtn3: { + type: Boolean, + default: false + }, + // 按钮4 + openBtn4: { + type: Boolean, + default: false + }, + isSvgBtn4: { + type: Boolean, + default: false + }, + typeBtn4: { + type: String, + default: 'primary' + }, + iconBtn4: { + type: String, + default: 'el-icon-plus' + }, + textBtn4: { + type: String, + default: '' + }, + disabledBtn4: { + type: Boolean, + default: false + }, + plainBtn4: { + type: Boolean, + default: false + }, + // 按钮5 + openBtn5: { + type: Boolean, + default: false + }, + isSvgBtn5: { + type: Boolean, + default: false + }, + typeBtn5: { + type: String, + default: 'primary' + }, + iconBtn5: { + type: String, + default: 'el-icon-plus' + }, + textBtn5: { + type: String, + default: '' + }, + disabledBtn5: { + type: Boolean, + default: false + }, + plainBtn5: { + type: Boolean, + default: false } }, methods: { handleRefresh() { this.$emit('handle-refresh') }, - handleAdd() { - this.$emit('handle-add') - }, - handleDelete() { - this.$emit('handle-delete') - }, handleSearch() { this.$emit('handle-search') + }, + handleButton1() { + this.$emit('handle-button1') + }, + handleButton2() { + this.$emit('handle-button2') + }, + handleButton3() { + this.$emit('handle-button3') + }, + handleButton4() { + this.$emit('handle-button4') + }, + handleButton5() { + this.$emit('handle-button5') } } } diff --git a/src/layout/components/Navbar.vue b/src/layout/components/Navbar.vue index f5fed92..f0238e9 100644 --- a/src/layout/components/Navbar.vue +++ b/src/layout/components/Navbar.vue @@ -107,7 +107,7 @@ export default { overflow: hidden; position: relative; //@include linearGradient(-90deg, #3660a5, #234c90); - @include linearGradient(-90deg, #409EFF, #005DFB); + @include linearGradient(90deg, #3660A5 0%, #234C90 100%); box-shadow: 0 1px 4px rgba(0, 21, 41, 0.08); .hamburger-container { diff --git a/src/layout/components/Sidebar/Logo.vue b/src/layout/components/Sidebar/Logo.vue index 0dbc1fd..e91b2fc 100644 --- a/src/layout/components/Sidebar/Logo.vue +++ b/src/layout/components/Sidebar/Logo.vue @@ -61,7 +61,7 @@ export default { width: 100%; height: 64px; line-height: 64px; - background: #005DFB; + background: #1F488B; /*background: #1f488b;*/ text-align: center; overflow: hidden; diff --git a/src/styles/element-ui.scss b/src/styles/element-ui.scss index 4929541..3209312 100644 --- a/src/styles/element-ui.scss +++ b/src/styles/element-ui.scss @@ -69,7 +69,7 @@ // dropdown .el-dropdown-menu { a { - display: block + display: block; } } @@ -82,3 +82,14 @@ .el-range-separator { box-sizing: content-box; } + +.head-box { + .el-input__inner { + width: 250px; + } +} + +.particles-js-canvas-el { + position: fixed; + top: 0; +} diff --git a/src/styles/variables.scss b/src/styles/variables.scss index fec69d2..45dd357 100644 --- a/src/styles/variables.scss +++ b/src/styles/variables.scss @@ -46,12 +46,11 @@ $menuActiveText: #a0d1ff; $subMenuActiveText: #a0d1ff; // https://github.com/ElemeFE/element/issues/12951 -$menuBg: #005DFB; +$menuBg: #1F488B; +$menuHover: #1F488B; -$menuHover: #1890FF; - -$subMenuBg: #0350D7; -$subMenuHover: #1890ff; +$subMenuBg: #365FA4; +$subMenuHover: #1890FF; //$menuBg: #365fa4; // diff --git a/src/views/login/index.vue b/src/views/login/index.vue index 3d2d5e7..f3c5b8e 100644 --- a/src/views/login/index.vue +++ b/src/views/login/index.vue @@ -1,9 +1,9 @@ diff --git a/src/views/member-management/index.vue b/src/views/member-management/index.vue index d8c8bd8..7df4dba 100644 --- a/src/views/member-management/index.vue +++ b/src/views/member-management/index.vue @@ -1,14 +1,145 @@ diff --git a/src/views/sort-management/index.vue b/src/views/sort-management/index.vue index ad63dcd..1f507a0 100644 --- a/src/views/sort-management/index.vue +++ b/src/views/sort-management/index.vue @@ -1,14 +1,148 @@