验证码控件部分样式调整
This commit is contained in:
parent
662b22576d
commit
02e12f6e3d
4
src/vendor/tianai-captcha/captcha/captcha.js
vendored
4
src/vendor/tianai-captcha/captcha/captcha.js
vendored
@ -8,7 +8,7 @@ import WordImageClick from "./word_image_click/word_image_click";
|
|||||||
import { CaptchaConfig, wrapConfig, wrapStyle } from "./config/config";
|
import { CaptchaConfig, wrapConfig, wrapStyle } from "./config/config";
|
||||||
import { clearAllPreventDefault } from "./common/common";
|
import { clearAllPreventDefault } from "./common/common";
|
||||||
const template = `
|
const template = `
|
||||||
<div class="captcha-parent">
|
<div class="__captcha-parent">
|
||||||
<div class="captcha-bg-img"></div>
|
<div class="captcha-bg-img"></div>
|
||||||
<div class="captcha-box">
|
<div class="captcha-box">
|
||||||
<div class="captcha-loading loading"></div>
|
<div class="captcha-loading loading"></div>
|
||||||
@ -55,7 +55,7 @@ class TianAiCaptcha {
|
|||||||
init() {
|
init() {
|
||||||
this.destroyWindow();
|
this.destroyWindow();
|
||||||
this.config.domBindEl.append(template);
|
this.config.domBindEl.append(template);
|
||||||
this.domTemplate = this.config.domBindEl.find(".captcha-parent");
|
this.domTemplate = this.config.domBindEl.find(".__captcha-parent");
|
||||||
clearAllPreventDefault(this.domTemplate);
|
clearAllPreventDefault(this.domTemplate);
|
||||||
this.loadStyle();
|
this.loadStyle();
|
||||||
// 绑定按钮事件
|
// 绑定按钮事件
|
||||||
|
|||||||
27
src/vendor/tianai-captcha/captcha/captcha.less
vendored
27
src/vendor/tianai-captcha/captcha/captcha.less
vendored
@ -1,6 +1,6 @@
|
|||||||
.captcha-parent {
|
.__captcha-parent {
|
||||||
box-shadow: 0 0 11px 0 #999999;
|
box-shadow: 0 0 11px 0 #999999;
|
||||||
width: 318px;
|
width: 316px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 997;
|
z-index: 997;
|
||||||
@ -29,7 +29,7 @@
|
|||||||
transform-style: preserve-3d;
|
transform-style: preserve-3d;
|
||||||
will-change: transform;
|
will-change: transform;
|
||||||
transition-duration: 0.45s;
|
transition-duration: 0.45s;
|
||||||
transform: translateX(-300px);
|
transform: translateX(-100%);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.captcha-bg-img {
|
.captcha-bg-img {
|
||||||
@ -46,8 +46,12 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.slider-bottom {
|
.slider-bottom {
|
||||||
|
text-align: right;
|
||||||
|
margin-top: 8px;
|
||||||
|
display: flex;
|
||||||
|
justify-content: flex-end;
|
||||||
|
gap: 10px;
|
||||||
.close-btn, .refresh-btn {
|
.close-btn, .refresh-btn {
|
||||||
display: inline-block;
|
|
||||||
width: 20px;
|
width: 20px;
|
||||||
height: 20px;
|
height: 20px;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
@ -56,18 +60,15 @@
|
|||||||
.close-btn {
|
.close-btn {
|
||||||
background-image: url("../images/icon.png");
|
background-image: url("../images/icon.png");
|
||||||
background-position: 0 -14px;
|
background-position: 0 -14px;
|
||||||
margin-right: 2px;
|
|
||||||
}
|
}
|
||||||
.refresh-btn {
|
.refresh-btn {
|
||||||
background-image: url("../images/icon.png");
|
background-image: url("../images/icon.png");
|
||||||
background-position: 0 -167px;
|
background-position: 0 -167px;
|
||||||
margin-right: 10px;
|
|
||||||
}
|
}
|
||||||
text-align: right;
|
|
||||||
margin-top: 8px;
|
|
||||||
}
|
}
|
||||||
.slider-move-shadow {
|
.slider-move-shadow {
|
||||||
animation: myanimation 2s infinite;
|
animation: move-shadow 2s infinite;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
width: 5px;
|
width: 5px;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
@ -92,6 +93,14 @@
|
|||||||
left: -1px;
|
left: -1px;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
}
|
}
|
||||||
|
@keyframes move-shadow {
|
||||||
|
from {
|
||||||
|
left: 0;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
left: 289px;
|
||||||
|
}
|
||||||
|
}
|
||||||
@import "./common/common.less";
|
@import "./common/common.less";
|
||||||
@import "./slider/slider.less";
|
@import "./slider/slider.less";
|
||||||
@import "./rotate/rotate.less";
|
@import "./rotate/rotate.less";
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
.captcha {
|
.captcha {
|
||||||
text-align: left;
|
text-align: left;
|
||||||
box-sizing: content-box;
|
box-sizing: content-box;
|
||||||
width: 300px;
|
width: 100%;
|
||||||
height: 260px;
|
height: 260px;
|
||||||
z-index: 999;
|
z-index: 999;
|
||||||
.slider-bottom .logo {
|
.slider-bottom .logo {
|
||||||
@ -21,12 +21,8 @@
|
|||||||
z-index: 999;
|
z-index: 999;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
line-height: 25px;
|
line-height: 25px;
|
||||||
/*background-color: #FF5D39;*/
|
|
||||||
color: #fff;
|
color: #fff;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
/* transform: translateY(0px); */
|
|
||||||
/* display: none; */
|
|
||||||
/* transition: max-height 0.5s; */
|
|
||||||
transition: bottom 0.3s ease-in-out;
|
transition: bottom 0.3s ease-in-out;
|
||||||
}
|
}
|
||||||
.captcha-tips.captcha-tips-error {
|
.captcha-tips.captcha-tips-error {
|
||||||
@ -75,11 +71,3 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@keyframes myanimation {
|
|
||||||
from {
|
|
||||||
left: 0;
|
|
||||||
}
|
|
||||||
to {
|
|
||||||
left: 289px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user