From c7fd8285c190e0c0cf411200ce0bce771d6165a4 Mon Sep 17 00:00:00 2001 From: jljsj Date: Fri, 11 Sep 2015 14:02:00 +0800 Subject: [PATCH] updata slide scale(.8). add zoomBig --- components/menu/index.jsx | 2 +- style/core/motion/slide.less | 16 ++++++++-------- style/core/motion/zoom.less | 20 ++++++++++++++++++++ 3 files changed, 29 insertions(+), 9 deletions(-) diff --git a/components/menu/index.jsx b/components/menu/index.jsx index d123462166..23b819c221 100644 --- a/components/menu/index.jsx +++ b/components/menu/index.jsx @@ -15,7 +15,7 @@ const AntMenu = React.createClass({ openAnimation = 'slide-up'; break; case 'vertical': - openAnimation = 'zoom'; + openAnimation = 'zoom-big'; break; case 'inline': openAnimation = animation; diff --git a/style/core/motion/slide.less b/style/core/motion/slide.less index a643986201..67e4bafa9a 100644 --- a/style/core/motion/slide.less +++ b/style/core/motion/slide.less @@ -18,7 +18,7 @@ 0% { opacity: 0; transform-origin: 0% 0%; - transform: scaleY(0); + transform: scaleY(.8); } 100% { opacity: 1; @@ -36,7 +36,7 @@ 100% { opacity: 0; transform-origin: 0% 0%; - transform: scaleY(0); + transform: scaleY(.8); } } @@ -44,7 +44,7 @@ 0% { opacity: 0; transform-origin: 100% 100%; - transform: scaleY(0); + transform: scaleY(.8); } 100% { opacity: 1; @@ -62,7 +62,7 @@ 100% { opacity: 0; transform-origin: 100% 100%; - transform: scaleY(0); + transform: scaleY(.8); } } @@ -70,7 +70,7 @@ 0% { opacity: 0; transform-origin: 0% 0%; - transform: scaleX(0); + transform: scaleX(.8); } 100% { opacity: 1; @@ -88,7 +88,7 @@ 100% { opacity: 0; transform-origin: 0% 0%; - transform: scaleX(0); + transform: scaleX(.8); } } @@ -96,7 +96,7 @@ 0% { opacity: 0; transform-origin: 100% 0%; - transform: scaleX(0); + transform: scaleX(.8); } 100% { opacity: 1; @@ -114,6 +114,6 @@ 100% { opacity: 0; transform-origin: 100% 0%; - transform: scaleX(0); + transform: scaleX(.8); } } diff --git a/style/core/motion/zoom.less b/style/core/motion/zoom.less index 75e2c29831..3fef410682 100644 --- a/style/core/motion/zoom.less +++ b/style/core/motion/zoom.less @@ -10,6 +10,7 @@ } .zoom-motion(zoom, zoom); +.zoom-motion(zoom-big, zoomBig); .zoom-motion(zoom-up, zoomUp); .zoom-motion(zoom-down, zoomDown); .zoom-motion(zoom-left, zoomLeft); @@ -34,6 +35,25 @@ transform: scale(0); } } +@keyframes zoomBigIn { + 0% { + opacity: 0; + transform: scale(.8); + } + 100% { + transform: scale(1); + } +} + +@keyframes zoomBigOut { + 0% { + transform: scale(1); + } + 100% { + opacity: 0; + transform: scale(.8); + } +} @keyframes zoomUpIn { 0% { -- GitLab