最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

一款純css3實(shí)現(xiàn)簡(jiǎn)單的checkbox復(fù)選框和radio單選框

  發(fā)布時(shí)間:2014-11-05 15:27:29   作者:佚名   我要評(píng)論
這篇文章主要為大家介紹了利用純css3實(shí)現(xiàn)一款簡(jiǎn)單實(shí)用的checkbox復(fù)選框和radio單選框,代碼簡(jiǎn)單易懂,可以直接復(fù)制,感興趣的可以進(jìn)來(lái)看看哦

  昨天為大家分享了一款很炫的checkbox復(fù)選框和radio單選框,今天再給大家?guī)?lái)一款簡(jiǎn)單實(shí)用的checkbox復(fù)選框和radio單選框。界面清淅、舒服。先給大家來(lái)張效果圖:

  實(shí)現(xiàn)代碼:

  html代碼:

XML/HTML Code復(fù)制內(nèi)容到剪貼板
  1. <div class="frame">  
  2.         <input checked="checked" id="radio_1" name="radio" type="radio">  
  3.         <label class="radio" for="radio_1">  
  4.             <i class="fa fa-times"></i>  
  5.         </label>  
  6.         <input id="radio_2" name="radio" type="radio">  
  7.         <label class="radio" for="radio_2">  
  8.             <i class="fa fa-times"></i>  
  9.         </label>  
  10.         <input id="radio_3" name="radio" type="radio">  
  11.         <label class="radio" for="radio_3">  
  12.             <i class="fa fa-times"></i>  
  13.         </label>  
  14.         <input id="radio_4" name="radio" type="radio">  
  15.         <label class="radio" for="radio_4">  
  16.             <i class="fa fa-times"></i>  
  17.         </label>  
  18.         <input id="radio_5" name="radio" type="radio">  
  19.         <label class="radio" for="radio_5">  
  20.             <i class="fa fa-times"></i>  
  21.         </label>  
  22.     </div>  
  23.     <div class="frame">  
  24.         <input checked="checked" id="check_1" name="check" type="checkbox">  
  25.         <label class="check" for="check_1">  
  26.             <i class="fa fa-check"></i>  
  27.         </label>  
  28.         <input id="check_2" name="check" type="checkbox">  
  29.         <label class="check" for="check_2">  
  30.             <i class="fa fa-check"></i>  
  31.         </label>  
  32.         <input id="check_3" name="check" type="checkbox">  
  33.         <label class="check" for="check_3">  
  34.             <i class="fa fa-check"></i>  
  35.         </label>  
  36.         <input id="check_4" name="check" type="checkbox">  
  37.         <label class="check" for="check_4">  
  38.             <i class="fa fa-check"></i>  
  39.         </label>  
  40.         <input id="check_5" name="check" type="checkbox">  
  41.         <label class="check" for="check_5">  
  42.             <i class="fa fa-check"></i>  
  43.         </label>  
  44.     </div>  

  css3代碼:

CSS Code復(fù)制內(nèi)容到剪貼板
  1. form   
  2.         {   
  3.             width: 100vw;   
  4.             height: 100vh;   
  5.             display: flex;   
  6.             flex-flow: column wrap;   
  7.             justify-contentcenter;   
  8.             align-items: center;   
  9.         }   
  10.         form .frame   
  11.         {   
  12.             display: flex;   
  13.             flex-flow: row nowrap;   
  14.         }   
  15.         form .frame input   
  16.         {   
  17.             displaynone;   
  18.         }   
  19.         form .frame label   
  20.         {   
  21.             cursorpointer;   
  22.             positionrelative;   
  23.             width30px;   
  24.             height30px;   
  25.             margin10px;   
  26.             background#8ABA56;   
  27.             transition: all 0.3s ease-in-out;   
  28.             font-size12pt;   
  29.             color#FFF;   
  30.             -webkit-font-smoothing: antialiased;   
  31.         }   
  32.         form .frame label.radio   
  33.         {   
  34.             border-radius: 100%;   
  35.         }   
  36.         form .frame label.check   
  37.         {   
  38.             border-radius: 5px;   
  39.         }   
  40.         form .frame label .fa   
  41.         {   
  42.             positionabsolute;   
  43.             top: 0;   
  44.             left: 0;   
  45.             rightright: 0;   
  46.             bottombottom: 0;   
  47.             opacity: 0;   
  48.             -webkit-transform: scale(0);   
  49.             transition: all 0.3s ease-in-out;   
  50.             line-height30px;   
  51.             text-aligncenter;   
  52.         }   
  53.         form .frame input:checked + label   
  54.         {   
  55.             background#678b40;   
  56.         }   
  57.         form .frame input:checked + label .fa   
  58.         {   
  59.             opacity: 1;   
  60.             -webkit-transform: scale(1);   
  61.         }  

  好了。復(fù)制上面的html代碼和css代碼。輕松搞定一款漂亮的checkbox、radio按鈕,謝謝閱讀,希望能幫到大家,請(qǐng)繼續(xù)關(guān)注腳本之家,我們會(huì)努力分享更多優(yōu)秀的文章。

相關(guān)文章

最新評(píng)論

凌海市| 三亚市| 宁化县| 白玉县| 弋阳县| 新和县| 江永县| 曲水县| 德化县| 肥乡县| 拜城县| 天门市| 荣昌县| 昭觉县| 卢氏县| 沁阳市| 宜都市| 衡山县| 红安县| 舒城县| 娱乐| 东光县| 建阳市| 汶上县| 喜德县| 嘉祥县| 玛曲县| 桂平市| 南城县| 额济纳旗| 普格县| 金乡县| 祁连县| 黄浦区| 黑水县| 兴宁市| 怀来县| 甘孜县| 武胜县| 鹿泉市| 长垣县|