mirror of
https://github.com/bufanyun/hotgo.git
synced 2025-11-12 20:23:52 +08:00
v2.0
This commit is contained in:
129
web/src/styles/common.less
Normal file
129
web/src/styles/common.less
Normal file
@@ -0,0 +1,129 @@
|
||||
#app,
|
||||
body,
|
||||
html {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: Helvetica Neue, Helvetica, PingFang SC, Hiragino Sans GB, Microsoft YaHei,
|
||||
'\5FAE\8F6F\96C5\9ED1', Arial, sans-serif;
|
||||
line-height: 1.5;
|
||||
color: #515a6e;
|
||||
font-size: 14px;
|
||||
background-color: #f7f7f7;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
//重置样式
|
||||
.anticon {
|
||||
svg {
|
||||
vertical-align: initial;
|
||||
}
|
||||
}
|
||||
|
||||
a {
|
||||
color: #2d8cf0;
|
||||
background: transparent;
|
||||
text-decoration: none;
|
||||
outline: none;
|
||||
cursor: pointer;
|
||||
transition: color 0.2s ease;
|
||||
}
|
||||
|
||||
a:active,
|
||||
a:hover {
|
||||
outline-width: 0;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
color: #57a3f3;
|
||||
}
|
||||
|
||||
a:active {
|
||||
color: #2b85e4;
|
||||
}
|
||||
|
||||
a:active,
|
||||
a:hover {
|
||||
outline: 0;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
/* 滚动条凹槽的颜色,还可以设置边框属性 */
|
||||
*::-webkit-scrollbar-track-piece {
|
||||
background-color: #f8f8f8;
|
||||
-webkit-border-radius: 2em;
|
||||
-moz-border-radius: 2em;
|
||||
border-radius: 2em;
|
||||
}
|
||||
|
||||
/* 滚动条的宽度 */
|
||||
*::-webkit-scrollbar {
|
||||
width: 9px;
|
||||
height: 9px;
|
||||
}
|
||||
|
||||
/* 滚动条的设置 */
|
||||
*::-webkit-scrollbar-thumb {
|
||||
background-color: #ddd;
|
||||
background-clip: padding-box;
|
||||
-webkit-border-radius: 2em;
|
||||
-moz-border-radius: 2em;
|
||||
border-radius: 2em;
|
||||
}
|
||||
|
||||
/* 滚动条鼠标移上去 */
|
||||
*::-webkit-scrollbar-thumb:hover {
|
||||
background-color: #bbb;
|
||||
}
|
||||
|
||||
/* router view transition */
|
||||
.zoom-fade-enter-active,
|
||||
.zoom-fade-leave-active {
|
||||
transition: transform 0.35s, opacity 0.28s ease-in-out;
|
||||
}
|
||||
|
||||
.zoom-fade-enter-from {
|
||||
opacity: 0;
|
||||
transform: scale(0.97);
|
||||
}
|
||||
|
||||
.zoom-fade-leave-to {
|
||||
opacity: 0;
|
||||
transform: scale(1.03);
|
||||
}
|
||||
|
||||
//antd 卡片样式定制
|
||||
body .n-card {
|
||||
transition: all 0.2s ease-in-out;
|
||||
}
|
||||
|
||||
body .n-icon {
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
body .proCard {
|
||||
border-radius: 4px;
|
||||
|
||||
.n-card__content {
|
||||
padding: 16px;
|
||||
|
||||
&:first-child {
|
||||
padding-top: 16px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
body .n-modal {
|
||||
border-radius: 6px;
|
||||
}
|
||||
|
||||
//body .proCardTabs{
|
||||
// .n-card__content{ padding-top: 3px}
|
||||
// .n-card__content:first-child{ padding-top: 3px}
|
||||
//}
|
||||
|
||||
.n-layout-page-header {
|
||||
margin: 0 -10px;
|
||||
}
|
||||
3
web/src/styles/index.less
Normal file
3
web/src/styles/index.less
Normal file
@@ -0,0 +1,3 @@
|
||||
@import 'transition/index.less';
|
||||
@import './var.less';
|
||||
@import './common.less';
|
||||
4
web/src/styles/tailwind.css
Normal file
4
web/src/styles/tailwind.css
Normal file
@@ -0,0 +1,4 @@
|
||||
/*! @import */
|
||||
@tailwind base;
|
||||
@tailwind components;
|
||||
@tailwind utilities;
|
||||
18
web/src/styles/transition/base.less
Normal file
18
web/src/styles/transition/base.less
Normal file
@@ -0,0 +1,18 @@
|
||||
.transition-default() {
|
||||
&-enter-active,
|
||||
&-leave-active {
|
||||
transition: 0.3s cubic-bezier(0.25, 0.8, 0.5, 1) !important;
|
||||
}
|
||||
|
||||
&-move {
|
||||
transition: transform 0.4s;
|
||||
}
|
||||
}
|
||||
|
||||
.expand-transition {
|
||||
.transition-default();
|
||||
}
|
||||
|
||||
.expand-x-transition {
|
||||
.transition-default();
|
||||
}
|
||||
81
web/src/styles/transition/fade.less
Normal file
81
web/src/styles/transition/fade.less
Normal file
@@ -0,0 +1,81 @@
|
||||
.fade-enter-active,
|
||||
.fade-leave-active {
|
||||
transition: opacity 0.2s ease-in-out;
|
||||
}
|
||||
|
||||
.fade-enter-from,
|
||||
.fade-leave-to {
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
/* fade-slide */
|
||||
.fade-slide-leave-active,
|
||||
.fade-slide-enter-active {
|
||||
transition: all 0.3s;
|
||||
}
|
||||
|
||||
.fade-slide-enter-from {
|
||||
opacity: 0;
|
||||
transform: translateX(-30px);
|
||||
}
|
||||
|
||||
.fade-slide-leave-to {
|
||||
opacity: 0;
|
||||
transform: translateX(30px);
|
||||
}
|
||||
|
||||
// ///////////////////////////////////////////////
|
||||
// Fade Bottom
|
||||
// ///////////////////////////////////////////////
|
||||
|
||||
// Speed: 1x
|
||||
.fade-bottom-enter-active,
|
||||
.fade-bottom-leave-active {
|
||||
transition: opacity 0.25s, transform 0.3s;
|
||||
}
|
||||
|
||||
.fade-bottom-enter-from {
|
||||
opacity: 0;
|
||||
transform: translateY(-10%);
|
||||
}
|
||||
|
||||
.fade-bottom-leave-to {
|
||||
opacity: 0;
|
||||
transform: translateY(10%);
|
||||
}
|
||||
|
||||
// fade-scale
|
||||
.fade-scale-leave-active,
|
||||
.fade-scale-enter-active {
|
||||
transition: all 0.28s;
|
||||
}
|
||||
|
||||
.fade-scale-enter-from {
|
||||
opacity: 0;
|
||||
transform: scale(1.2);
|
||||
}
|
||||
|
||||
.fade-scale-leave-to {
|
||||
opacity: 0;
|
||||
transform: scale(0.8);
|
||||
}
|
||||
|
||||
// ///////////////////////////////////////////////
|
||||
// Fade Top
|
||||
// ///////////////////////////////////////////////
|
||||
|
||||
// Speed: 1x
|
||||
.fade-top-enter-active,
|
||||
.fade-top-leave-active {
|
||||
transition: opacity 0.2s, transform 0.25s;
|
||||
}
|
||||
|
||||
.fade-top-enter-from {
|
||||
opacity: 0;
|
||||
transform: translateY(8%);
|
||||
}
|
||||
|
||||
.fade-top-leave-to {
|
||||
opacity: 0;
|
||||
transform: translateY(-8%);
|
||||
}
|
||||
10
web/src/styles/transition/index.less
Normal file
10
web/src/styles/transition/index.less
Normal file
@@ -0,0 +1,10 @@
|
||||
@import './base.less';
|
||||
@import './fade.less';
|
||||
@import './scale.less';
|
||||
@import './slide.less';
|
||||
@import './scroll.less';
|
||||
@import './zoom.less';
|
||||
|
||||
.collapse-transition {
|
||||
transition: 0.2s height ease-in-out, 0.2s padding-top ease-in-out, 0.2s padding-bottom ease-in-out;
|
||||
}
|
||||
21
web/src/styles/transition/scale.less
Normal file
21
web/src/styles/transition/scale.less
Normal file
@@ -0,0 +1,21 @@
|
||||
.scale-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
transform: scale(0);
|
||||
}
|
||||
}
|
||||
|
||||
.scale-rotate-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
transform: scale(0) rotate(-45deg);
|
||||
}
|
||||
}
|
||||
67
web/src/styles/transition/scroll.less
Normal file
67
web/src/styles/transition/scroll.less
Normal file
@@ -0,0 +1,67 @@
|
||||
.scroll-y-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
&-enter-from {
|
||||
transform: translateY(-15px);
|
||||
}
|
||||
|
||||
&-leave-to {
|
||||
transform: translateY(15px);
|
||||
}
|
||||
}
|
||||
|
||||
.scroll-y-reverse-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
&-enter-from {
|
||||
transform: translateY(15px);
|
||||
}
|
||||
|
||||
&-leave-to {
|
||||
transform: translateY(-15px);
|
||||
}
|
||||
}
|
||||
|
||||
.scroll-x-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
&-enter-from {
|
||||
transform: translateX(-15px);
|
||||
}
|
||||
|
||||
&-leave-to {
|
||||
transform: translateX(15px);
|
||||
}
|
||||
}
|
||||
|
||||
.scroll-x-reverse-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
&-enter-from {
|
||||
transform: translateX(15px);
|
||||
}
|
||||
|
||||
&-leave-to {
|
||||
transform: translateX(-15px);
|
||||
}
|
||||
}
|
||||
39
web/src/styles/transition/slide.less
Normal file
39
web/src/styles/transition/slide.less
Normal file
@@ -0,0 +1,39 @@
|
||||
.slide-y-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
transform: translateY(-15px);
|
||||
}
|
||||
}
|
||||
|
||||
.slide-y-reverse-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
transform: translateY(15px);
|
||||
}
|
||||
}
|
||||
|
||||
.slide-x-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
transform: translateX(-15px);
|
||||
}
|
||||
}
|
||||
|
||||
.slide-x-reverse-transition {
|
||||
.transition-default();
|
||||
|
||||
&-enter-from,
|
||||
&-leave-to {
|
||||
opacity: 0;
|
||||
transform: translateX(15px);
|
||||
}
|
||||
}
|
||||
27
web/src/styles/transition/zoom.less
Normal file
27
web/src/styles/transition/zoom.less
Normal file
@@ -0,0 +1,27 @@
|
||||
// zoom-out
|
||||
.zoom-out-enter-active,
|
||||
.zoom-out-leave-active {
|
||||
transition: opacity 0.1 ease-in-out, transform 0.15s ease-out;
|
||||
}
|
||||
|
||||
.zoom-out-enter-from,
|
||||
.zoom-out-leave-to {
|
||||
opacity: 0;
|
||||
transform: scale(0);
|
||||
}
|
||||
|
||||
// zoom-fade
|
||||
.zoom-fade-enter-active,
|
||||
.zoom-fade-leave-active {
|
||||
transition: transform 0.2s, opacity 0.3s ease-out;
|
||||
}
|
||||
|
||||
.zoom-fade-enter-from {
|
||||
opacity: 0;
|
||||
transform: scale(0.92);
|
||||
}
|
||||
|
||||
.zoom-fade-leave-to {
|
||||
opacity: 0;
|
||||
transform: scale(1.06);
|
||||
}
|
||||
4
web/src/styles/var.less
Normal file
4
web/src/styles/var.less
Normal file
@@ -0,0 +1,4 @@
|
||||
@primaryColor: #2d8cf0;
|
||||
@primaryColorHover: #57a3f3;
|
||||
@header-height: 64px;
|
||||
@footer-height: 70px;
|
||||
Reference in New Issue
Block a user