【发布时间】:2015-12-30 01:53:59
【问题描述】:
我对模态弹出窗口的转换有疑问。弹出窗口来自一个按钮。我目前正在使用下面的css,这还不错。但是有什么方法可以让转换看起来像是从我刚刚按下的按钮弹出的模式?仅供参考,我只是 css 的中间人。我需要一些JS吗?
.modal.fade .modal-dialog {
-webkit-transform: scale(0.1);
-moz-transform: scale(0.1);
-ms-transform: scale(0.1);
transform: scale(0.1);
top: 300px;
opacity: 0;
-webkit-transition: all 0.3s;
-moz-transition: all 0.3s;
transition: all 0.3s;
}
.modal.fade.in .modal-dialog {
-webkit-transform: scale(1);
-moz-transform: scale(1);
-ms-transform: scale(1);
transform: scale(1);
-webkit-transform: translate3d(0, -300px, 0);
transform: translate3d(0, -300px, 0);
opacity: 1;
}
【问题讨论】:
标签: jquery css css-transitions transition