酷炫提交按钮动画特效

代码语言:html

所属分类:表单美化

代码描述:酷炫提交按钮动画特效

代码标签: 动画 特效

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开


<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">

<style>
@import url("https://fonts.googleapis.com/css2?family=Questrial&display=swap");
body {
  -webkit-box-align: center;
          align-items: center;
  display: -webkit-box;
  display: flex;
  font-family: "Questrial";
  font-weight: 800;
  -webkit-box-pack: center;
          justify-content: center;
  height: 100vh;
}

.container {
  -webkit-box-align: center;
          align-items: center;
  border-radius: 26px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.11), 0 2px 2px rgba(0, 0, 0, 0.11),
    0 4px 4px rgba(0, 0, 0, 0.11), 0 6px 8px rgba(0, 0, 0, 0.11),
    0 8px 16px rgba(0, 0, 0, 0.11);
  cursor: pointer;
  display: -webkit-box;
  display: flex;
  -webkit-box-pack: center;
          justify-content: center;
  position: relative;
  height: 52px;
  width: 190px;
}

.bottom {
  border-radius: 26px;
  background: #eabbbb;
  height: 100%;
  overflow: hidden;
  position: absolute;
  width: 100%;
}

.cover {
  background-color: #3743a4;
  border-radius: 26px;
  height: 100%;
  position: absolute;
  width: 100%;
}
.cut {
  -webkit-clip-path: polygon(
    100% 0%,
    99.73714% -0.13875%,
    98.96737% -0.53964%,
    97.71887% -1.17957%,
    96.01985% -2.03547%,
    93.89849% -3.08428%,
    91.38299% -4.30291%,
    88.50154% -5.66829%,
    85.28234% -7.15734%,
    81.75358% -8.74699%,
    77.94346% -10.41416%,
    73.88016% -12.13578%,
    69.59189% -13.88876%,
    65.10683% -15.65005%,
    60.45319% -17.39655%,
    55.65915% -19.10519%,
    50.75291% -20.75291%,
    45.76266% -22.31661%,
    40.7166% -23.77324%,
    35.64292% -25.09971%,
    30.56981% -26.27294%,
    25.52548% -27.26986%,
    20.5381% -28.0674%,
    15.63589% -28.64248%,
    10.84702% -28.97202%,
    6.1997% -29.03295%,
    1.72212% -28.8022%,
    -2.55753% -28.25668%,
    -6.61106% -27.37332%,
    -10.41026% -26.12905%,
    -13.92694% -24.50079%,
    -17.13292% -22.46546%,
    -20% -20%,
    -22.46546% -17.13292%,
    -24.50079% -13.92694%,
    -26.12905% -10.41026%,
    -27.37332% -6.61106%,
    -28.25668% -2.55753%,
    -28.8022% 1.72212%,
    -29.03295% 6.1997%,
    -28.97202% 10.84702%,
    -28.64248% 15.63589%,
    -28.0674% 20.5381%,
    -27.26986% 25.52548%,
    -26.27294% 30.56981%,
    -25.09971% 35.64292%,
    -23.77324% 40.7166%,
    -22.31661% 45.76266%,
    -20.75291% 50.75291%,
    -19.10519% 55.65915%,
    -17.39655% 60.45319%,
    -15.65005% 65.10683%,
    -13.88876% 69.59189%,
    -12.13578% 73.88016%,
    -10.41416% 77.94346%,
    -8.74699% 81.75358%,
    -7.15734% 85.28234%,
    -5.66829% 88.50154%,
    -4.30291% 91.38299%,
    -3.08428% 93.89849%,
    -2.03547% 96.01985%,
    -1.17957% 97.71887%,
    -0.53964% 98.96737%,
    -0.13875% 99.73714%,
    0% 100%,
    100% 100%
  );
          clip-path: polygon(
    100% 0%,
    99.73714% -0.13875%,
    98.96737% -0.53964%,
    97.71887% -1.17957%,
    96.01985% -2.03547%,
    93.89849% -3.08428%,
    91.38299% -4.30291%,
    88.50154% -5.66829%,
    85.28234% -7.15734%,
    81.75358% -8.74699%,
    77.94346% -10.41416%,
    73.88016% -12.13578%,
    69.59189% -13.88876%,
    65.10683% -15.65005%,
    60.45319% -17.39655%,
    55.65915% -19.10519%,
    50.75291% -20.75291%,
    45.76266% -22.31661%,
    40.7166% -23.77324%,
    35.64292% -25.09971%,
    30.56981% -26.27294%,
    25.52548% -27.26986%,
    20.5381% -28.0674%,
    15.63589% -28.64248%,
    10.84702% -28.97202%,
    6.1997% -29.03295%,
    1.72212% -28.8022%,
    -2.55753% -28.25668%,
    -6.61106% -27.37332%,
    -10.41026% -26.12905%,
    -13.92694% -24.50079%,
    -17.13292% -22.46546%,
    -20% -20%,
    -22.46546% -17.13292%,
    -24.50079% -13.92694%,
    -26.12905% -10.41026%,
    -27.37332% -6.61106%,
    -28.25668% -2.55753%,
    -28.8022% 1.72212%,
    -29.03295% 6.1997%,
    -28.97202% 10.84702%,
    -28.64248% 15.63589%,
    -28.0674% 20.5381%,
    -27.26986% 25.52548%,
    -26.27294% 30.56981%,
    -25.09971% 35.64292%,
    -23.77324% 40.7166%,
    -22.31661% 45.76266%,
    -20.75291% 50.75291%,
    -19.10519% 55.65915%,
    -17.39655% 60.45319%,
    -15.65005% 65.10683%,
    -13.88876% 69.59189%,
    -12.13578% 73.88016%,
    -10.41416% 77.94346%,
    -8.74699% 81.75358%,
    -7.15734% 85.28234%,
    -5.66829% 88.50154%,
    -4.30291% 91.38299%,
    -3.08428% 93.89849%,
    -2.03547% 96.01985%,
    -1.17957% 97.71887%,
    -0.53964% 98.96737%,
    -0.13875% 99.73714%,
    0% 100%,
    100% 100%
  );
  -webkit-transition: -webkit-clip-path 500ms;
  transition: -webkit-clip-path 500ms;
  transition: clip-path 500ms;
  transition: clip-path 500ms, -webkit-clip-path 500ms;
}
.container:hover .cut {
  -webkit-clip-path: polygon(
    100% 0%,
    100.00018% 0.14326%,
    99.99754% 0.56399%,
    99.98732% 1.24864%,
    99.96476% 2.18368%,
    99.92511% 3.35553%,
    99.8636% 4.75066%,
    99.77547% 6.35551%,
    99.65597% 8.15653%,
    99.50033% 10.14017%,
    99.3038% 12.29288%,
    99.06161% 14.60111%,
    98.76901% 17.0513%,
    98.42123% 19.62992%,
    98.01352% 22.3234%,
    97.54112% 25.11819%,
    96.99926% 28.00074%,
    96.38318% 30.95751%,
    95.68814% 33.97494%,
    94.90936% 37.03949%,
    94.0421% 40.13759%,
    93.08158% 43.2557%,
    92.02305% 46.38027%,
    90.86174% 49.49775%,
    89.59291% 52.59459%,
    88.21179% 55.65723%,
    86.71362% 58.67212%,
    85.09364% 61.62572%,
    83.34709% 64.50448%,
    81.46921% 67.29483%,
    79.45524% 69.98324%,
    77.30042% 72.55614%,
    75% 75%,
    72.55614% 77.30042%,
    69.98324% 79.45524%,
    67.29483% 81.46921%,
    64.50448% 83.34709%,
    61.62572% 85.09364%,
    58.67212% 86.71362%,
    55.65723% 88.21179%,
    52.59459% 89.59291%,
    49.49775% 90.86174%,
    46.38027% 92.02305%,
    43.2557% 93.08158%,
    40.13759% 94.0421%,
    37.03949% 94.90936%,
    33.97494% 95.68814%,
    30.95751% 96.38318%,
    28.00074% 96.99926%,
    25.11819% 97.54112%,
    22.3234% 98.01352%,
    19.62992% 98.42123%,
    17.0513% 98.76901%,
    14.60111% 99.06161%,
    12.29288% 99.3038%,
    10.14017% 99.50033%,
    8.15653% 99.65597%,
    6.35551% 99.77547%,
    4.75066% 99.8636%,
    3.35553% 99.92511%,
    2.18368% 99.96476%,
    1.24864% 99.98732%,
    0.56399% 99.99754%,
    0.14326% 100.00018%,
    0% 100%,
    100% 100%
  );
          clip-path: polygon(
    100% 0%,
    100.00018% 0.14326%,
    99.99754% 0.56399%,
    99.98732% 1.24864%,
    99.96476% 2.18368%,
    99.92511% 3.35553%,
    99.8636% 4.75066%,
    99.77547% 6.35551%,
    99.65597% 8.15653%,
    99.50033% 10.14017%,
    99.3038% 12.29288%,
    99.06161% 14.60111%,
    98.76901% 17.0513%,
    98.42123% 19.62992%,
    98.01352% 22.3234%,
    97.54112% 25.11819%,
    96.99926% 28.00074%,
    96.38318% 30.95751%,
    95.68814% 33.97494%,
    94.90936% 37.03949%,
    94.0421% 40.13759%,
    93.08158% 43.2557%,
    92.02305% 46.38027%,
    90.86174% 49.49775%,
    89.59291% 52.59459%,
    88.21179% 55.65723%,
    86.71362% 58.67212%,
    85.09364% 61.62572%,
    83.34709% 64.50448%,
    81.46921% 67.29483%,
    79.45524% 69.98324%,
    77.30042% 72.55614%,
    75% 75%,
    72.55614% 77.30042%,
    69.98324% 79.45524%,
    67.29483% 81.46921%,
.........完整代码请登录后点击上方下载按钮下载查看

网友评论0