用css控制一个DIV画图标。

在实际开发中,我们会用到一些小图形,图标。大多数情况下都是用图片来实现的,同时对图片进行处理使图片大小尽可能的缩小。但是图片在怎么处理也是按KB来算的。但是要是用CSS画,只要用很少的空间就能完成同样的效果了,而且还方便后期的维护。我们今天画四个图形,一个三角形,一个直角三角形两种方法画多边框正方形同心圆分享图标

三角形

首先,我们先画一个三角形

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHEAAABDCAIAAAAkrn0hAAABgElEQVR4nO3awQ3DMAxDUc+cCZIs4JHbg4AeiqKtbUqiDP4JqHdWeyh0LXvAhskUn0zxyRSfTPHJFJ9M8ckUn0zxyRSfTPHJFJ9M8ckUn0zxyRSfTPGxm17X1XvPXjEWtWnvvbXWWqvFymv6ArXO88xe9G+kpm+gtVgZTT+CFmKlM/0CWoWVy/QnaAlWItM/QflZWUyHQMlZKUwnQJlZ802nQWlZk00XQTlZM00hoISsaaZAUDbWHFM4KBVrgqkTKA9rtKkrKAlrqGkAKANrnGkYaDprkGkwaC5rhGkKaCKru2kiaBarr2k6qBXM6mhKAmpFsnqZUoFaYawupoSgVgwr3pQW1ApgBZuSg1rerEjTEqCWKyvMtBCo5ceKMS0HajmxAkyLgloerKumpUEtOOuS6QagFpZ13nQbUAvIOmm6GaiFYp0x3RLUgrAOm24Maq2zjpne9519ckSLrAOmx3FkHxvXCmv+X99+yRSfTPHJFJ9M8ckUn0zxyRSfTPE9AX1+vkWfo1CCAAAAAElFTkSuQmCC" alt="" />

代码如下:  <div id="duo1"></div> 对 就是用一个DIV来画。

我们可以把这幅图补脑一下

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIoAAABqCAIAAADsoV6xAAADw0lEQVR4nO3US4LbMAwDUB/dN8iR04U67UT0h5IACo6IpUPLEN+02zsjnG12gcxVkkc6ySOd5JFO8kgneaSTPNJJHukkj3SSRzrJI53kkY6XZ/sJtU2mimvd2/JhM5xu3jWUmSSUPN6wJY437xrKJI9y2Aynm3cNSVZ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XHmhdT8xySOd5JFO8kgneaSTPNJJHukkj3SSRzp/AE2+G21RLovpAAAAAElFTkSuQmCC" alt="" />

这是不是就有点眼熟了呢?没看出来没关系,在看这张。

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAZIAAACfCAIAAABcCcjHAAAJ/ElEQVR4nO3XS5Lttg5E0TP0msEdldsegodSbjCiXNaXH4BIkHuFWtd1pAQoZbz3+evvf7i4uLgSXZ/wBFxcXFxNF7XFxcWV7KK2uLi4kl2fbwBIhdoCkAy1BSAZagtAMtQWgGSoLQDJUFsAkqG2ACRDbQFIhtoCkAy1BSAZagtAMtQWgGSoLQDJUFsAkqG2ACRDbQFIhtoCkAy1BSAZagtAMtQWgGSoLQDJaNXWB/8XfSCAIq0PI7olFEWfCSBH66uIrghR0ccCaNH6JKL7QVT0sQBatD6J6H4QFX0sgBatT2Lzj3bz8YFKWl/Fzv9zY9vBgVZaH8ae/19pw5GBEVofxnNtLfkZ7zYvME7rw3itrcW+5K2GBaxofRg1tbXMx7zPpIAtrQ/j/NGu+j3fDbXYmIAHrQ/j7qNdrLkexllmxkTYdjpaR/Xw0S7TXM+DLDBgLpfHsZXoE+ihFfp5oQvs/TV/3tGSGvzm1xB9CM20Er9uM/Xea5JnnCu1wQ9+DdGH0Ewrcc02k66+MnOuoRYw+MGvIfoQmmklrtxmru03pU0x0UpGvvY1RJ9AD63QTQtNcQat74r4OOtZ75O+s9KMWqFbFyp+DB0viuwsq3qurWWOYLEBtUJ3LPT1tZPisQGMMDk1ZUtOpxW6b6GVlRHObwPodl5499kJsnot1WiF7l5oXW9E8t4A+lwufOQEddi+mVK0Qo8stPKQQszZADrcLXzwHMM9vIp5h/qhFXpwoVUVEmHaBtDqYeGDRxno+T3MONGBVujBhY63hhVqK4vnhYu8Tk1eM+ca55JWaGorPPluXhcu8kZVqkmbZZYHWqE9assjZ2uSCT9En5qF67xXzypz6g/ySiu0bW15JPROojPCJioXrt9c9QmVp6ikFZra0hlhE/ULV26upmy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x3+U9zu+6UMDVg5fMNLdlbx01yHf4/df5+UoQErIQ0SpTTX4R+jT6BHytCAlZD6CPT19XX4l+gT6JEyNGAlojq0RJ9Aj5ShAUOpP+A+2UfOmhvAtqgtAMlQWwCSobYAJENtAUiG2gKQDLUFIBlqC0Ay1BaAZKgtAMlQWwCSobYAJENtAUiG2gKQDLUFIBlqC0Ay1BaAZKgtAMlQWwCSobYAJENtAUiG2gKQDLUFIBlqC0Ay1BaAZKgtAMlQWwCSobYAJENtAUiG2gKQDLUFIBlqC0Ay1BaAZKgtAMlQWwCSobYAJENtAUjmX1+yf8+JO1kWAAAAAElFTkSuQmCC" alt="" />

左边的大家应该很熟悉了,就是一个有边框的盒子,而右边的就是把盒子的宽度和高度设置为0px。

然后我们把边框的左,上,右设置为白色。代码如下

 <head>
<style>
div[id="duo1"]{
width:0px; height:0px;
border-top:50px solid white;
border-left:50px solid white;
border-bottom:50px solid #;
border-right:50px solid white;}
</style>
</head>
<body>
<div id="duo1"></div>
</body>

直角三角形

那么直角三角形呢?其实方法是一样的。显示左下两部分边框,

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJMAAABnCAIAAACLhOdNAAAB60lEQVR4nO3UUW5CMQxEUS8dvoEiFsBa049KrdRKlOTFice+dwXjHCnWSDPbPYAGQ0415FRDTjXkVENONeRUQ0415FRDTjXkVENONeRUQ0415FRDTjXkVOuWO589ZlB33XJm7XLxWEJ9jciBF6FBObN2vXrsoXcblwNvb4fkwNvYUTnwdjVBDrwtzZEDb33T5MBb3Ew58FY2WQ68Zc2XA29NLnJm7XbzWEs/ecmB552jHHiu+cqB55e7HHhOrZADz6NFcuBNb50ceHNbKgfexFbLmbWPD49DyrVBDrwp7ZED73jb5MA72E458I60WQ684fbLgTdWCDnwBooiB15vgeTA6yqWnFm73z3OTFg4OfDeLKIceO8UVA68f4srB97rQsuB96Locmbt+fQ4XD4BObP2eHjcrp2GHN/m32TkwPuVkpxZO508HkEyMTnwvtOTA+8rSTnwmq4ceMJyxfG05SrjycuVxcsgVxMviVxBvDxy1fBSyZXCyyZXBy+hXBG8nHIV8NLKpcfLLJcbL7lcYrz8clnxSsilxKsilw+vkFwyvFpymfDKyaXBqyiXA6+oXAK8unLqeKXlpPGqy+niIaeKh5wqHnKqeMip4iGnioecKh5yqnjIqeIhp4rXLUdBQk415FRDTjXkVPsEm/HkJ1GDCB8AAAAASUVORK5CYII=" alt="" />

//css样式代码
div[id="zjsjx"]{
width:0px; height:0px;
border-top:50px solid white;
border-left:50px solid blue;
border-bottom:50px solid blue;
border-right:50px solid white;} //HTML代码
<div id="zjsjx"></div>

 正方形

那有两个边正方形怎么用一个div画呢?

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFgAAABWCAIAAADE/cYTAAAA0klEQVR4nO3QwQ0DMRADMfff9OYzeVwBge0cBRUw4BqbmZm1O+CUgWggGogGooFoD4i1/vMgQIAAAQIEiH0QM+uKgwABAgQIECBugtg1EN9SEJWCqBREpSAqBVEpiEpBVAqiUhCVgqgURKUgKgVRKYhKQVQKolIQlYKoFESlICoFUSmISkFUCqJSEJWCqBREpSAqBVEpiEpBVAqiUhCVgqgURKUgKgVRKYhKT4M46yBAgAABAgSI8yBuPwgQIECAAAHi9xBvHogGooFoIBqIBqJ9AE1KcS/HLI9TAAAAAElFTkSuQmCC" alt="" />

这个时候就要用到一个属性 描边属性outline或者叫轮廓线属性。

 div[id="dcbk"]{
width:50px; height:50px;
outline:10px solid blue;
border:10px solid yellow;}

但是,outline属性有有关问题 比如要设置这个DIV为圆角,那么这个属性就会有问题,如图:

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFkAAABdCAIAAABB+F3uAAACbElEQVR4nO3br04cURzF8RHIFTgMoqICwyOQkMAzdF9gxYqKTUpa0YohfZQKEhAIBIInWF1IH2DFisqKESu+FaQ9+4ffzJBc7t2Wc3Il4Z7fJ+wsydxb4fxJVbrAFsUWii0UWyi2UGyhPGFRVf/nsoUtbGELW9jCFttn0ZUG7mAEx/AWBlAlWgN4A8cwghtoOkYqajGHSdLhO2nGMN82iwXUsJtLYU2khsWWWExhWEJheQ1hWtziO+yXhnhc+/CjoMUUjkoTLK+j5b+OnBYzeFd6+M01hFl+i/PSY0frPLPFvOtb4wC+wg387N68b2ZwDV/goHXr3ccv2mwWk9Y27+FXOoLNNF0FJl392/Isi6b1H6pvqSePcgs7QYcBLPJYXMUQH5JP3JpPcZOrPBaj+Bnxoh+NzTTxs2Ocx+I02L5OPmuP1EGZ0zwWh8H2l8kH7ZHLoMxhHou9YPuH5IP2yENQZi+PRfS4KpWn+9jCFrb429QWamoLNbWFmtpCTW2hprZQU1uoqS3U1BZqags1tYWa2kJNbaGmtlBTW6ipLdTUFmpqCzW1hZraQk0LWkTviu6TT9kj90GZTO+K/A5Rv+sk2L5OPmiP1EGZkzwWLWcOOs4lp07LmYNRHouL+PH5Mfm4rfkcN7nIY9F+Ruk2+cRB7lrPKDV5LIBxbLEDZy/8YWngLIaoYNzVvy3PtZh33QcoeKZxkPlMI/EDvPiq+/VPaeEz0Cs/6LPxK/GdiZX4Ls1KfMdqPb57t57XdCfzX1+2sIUtbGELW9iinMWrjS0UWyi2UGyh2EKxhWILxRaKLRRbKLZQbKHYQvkNPJRcrMcw0F0AAAAASUVORK5CYII=" alt="" />

可以看出 outline属性不会随着div的圆角变化而变化。那怎么办呢?别急 我们还有第二种方法来实现。

正方形方法二

第二种方法我们要用到一个属性box-shadow属性。

box-shadow语法:box-shadow: h-shadow v-shadow blur spread color inset;

box-shadow: 水平阴影的位置(左偏移)  垂直阴影的位置(下偏移) 模糊距离(模糊度) 阴影的尺寸  颜色  将外部阴影 (outset) 改为内部阴影;

当然我们这里不需要设置那么多值。

如果水平阴影的位置  垂直阴影的位置都设置为O即左,下不偏移,然后再设置尺寸不就是相当于边框了吗?

 div[id="dcbk2"]{
width:50px; height:50px;
border:10px solid yellow;
box-shadow:0 0 0 10px blue;

效果是一样的,而且跟着圆角变

aaarticlea/png;base64,i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og71GG+w1/wGpU0KK8r1g9wAAAABJRU5ErkJggg==" alt="" />

同心圆

一个圆我们会画,两个同心圆我们也可以,那么三个四个五个呢?

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAKgAAACQCAIAAAATALcjAAASRklEQVR4nO2df1BUV5bHv2pnQgYwoERJMEmvIIoCdrlO1h+pSDJq2h+ZxZIYIRhZk5lY5exI1K1BYywZY5hSJ+qGCdbIjzgImGIjWxNBa1htQJRJ6Q7uaMVS3JiJjiyiRhkrbmz17B/tGoa+577X2Pe9xve+df6yGzjnfLz33Xd/nAuyZUnBbAdsmSMbvEVlg7eobPAWlQ3eorLBW1Q2eIvKBm9R2eAtKhu8RWWDt6hs8BaVDd6issFbVDZ4i8oGb1HZ4C0qG7xFZYO3qGzwFtUDCr69nTweKiqi3FxyuyktjZxOcjopJoYAAigm5u6/pKWR2025uVRURB4Ptbeb7bpBelDAX79OjY30q19RVhYlJt6l2ztLTKTMTNq0iTwe6uoyOzBV6uPgvV6qqaH58ykq6r5gcxYVRRkZVFNDN26YHWqQ1TfB37xJdXW0bBmlpirh7W/JyZSbS7W1dPOm2cEHR30N/PXrVFZGM2caxNvfZs6k0tIH4BHQd8Cbjry7ud1UXExXr5qdlN6rj4A/eJBcLvN59zCXi+rrzU5NLxXy4FtaaPFieuQR8zEL7aGH6I03qLnZ7DQFrBAG7/VSQQFFRPSChxeOVriqkVGAvDewPQ2e8TjixNlhOOf7yjCcc+LseByZivrFKNqIFTVIP45kLxy9wR8RQQUF5PWanbIAFKrgm5ooIyOg7N/CgMOYuAVLs1CRgLbeNeAEtGWhYguWHsbEWxgQ2A9nZFBjo9mJ06uQBF9SEtATvRmT87HmOTQGtxefgoZ8rGnG5AB+xuWikhKz06dLIQbe66XcXP2JLkf2BLQEl7e/TUBLGXIC+IG8vNDv9kMJ/JkztGiRzuRWInM2PlWNvLvNwp6dePUO+un6dk4OnTpldkJlChnwx47RvHl6clqHGa9iZz/cMZL6PctE5e/wkq6vzp1L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BLPPAE9GpUzR3rjxf9Zjqxl597H3WCdQAy7lzOVJNAJYDNdxyi9CexwHZm5vP0tPppGHVV3XJVPBEdPQoTZ8uz9oJjMlhNq1q2XGgDMgD0oFRgLNb3Y1YwAkkA+lAHlDOnXOTWyYqZbM0PktLo5YWk/PsJ7PBE1FbG8XGynPnhWM11vH7M00wB7wrsFE2lPNZbGyotXWfQgA8ER04QNOmaSb7ECYtQSF/JalBFomuN7FNtubWva3v3Wt2csUKDfBEdOSI5vPeZ7WY+Sp28ldUqrVMVMp2VXS39PQQ7OHvKWTAE9GpU5rj/HtWiUzpRZXBt1nYU4EsdgdVD1u4MDR7+HsKJfBE5PVyu3KFVo7sCWhRjXwCWtid0ULLyzNxoV2nQgy8TyUl8jndHtaMyflYMwUNweU9BQ35WMOefRGayxU6c3NyhSR4Impqkq/l+NstDDiMiVuwNAsV/LU3GpaAtixUbMHSw5h4CwMC++GMDIPvjrsfhSp4IvJ6qaCAK40qNy8crXBVI6MAeW9gexo843HEibPDcM73lWE458TZ8TgyFfWLUbQRK2qQfhzJ2q9nQgsLo4KC0O/euyuEwft08CAtWkT9+wezEw+uLVxo+q6KXijkwfu0dy8lJJjPuIclJFB1tdmp6aX6CHgi6uykbdv0zPMYYS+8QIWFIbXoEqj6Dvh7qqkJaMwfZHO5qLq6bz3OheqD4Ino5k2qq6Nly7hSycG35GTKzaXaWrp50+zgg6O+Cf6evF6qqaH587nSavdrUVGUkUE1NXTjhtmhBll9HHx3tbbS5s2Unn6//wmioig9nTZvptZWs0NSqAcIfHe1t5PHQ0VFlJtLbjelpZHTSU4nxcTcpRsTc/df0tLI7abcXCoqIo+nT4/XAtIDCt6WlmzwFpUN3qKywVtUNniLygZvUdngLSobvEVlg7eobPAWlQ3eorLBW1Q2eIvKBm9R2eAtKhu8RWWDt6hs8BaVDd6i+j/cO8UuIA7xPQAAAABJRU5ErkJggg==" alt="" />

怎么做呢?要是可以定义多个边框不就好了吗?在上面,我们是用box-shadow来做边框效果的

同样,我们还是用box-shadow属性。但是其实box-shadow可以同时定义多个阴影的,写法如下

 div[id="yuan"]{ width:50px; height:50px;
border:10px solid yellow;
border-radius:100px;
box-shadow:0 0 0 10px black,
0 0 0 20px blue,
0 0 0 30px red;}

中间用","隔开就好了,没有数量限制。

分享图标

最后我们做一个分享的图标

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEEAAAAsCAIAAAC1/0KWAAABhklEQVRoge3XIY6EMBQG4EoEggMgOQSGBMkBCFygYmQFBygawSE4BgKNRpJVCCQCUVHBCjKTTWZh286Dwqa/nCl/35cJHUDL/YN0DwAQY7hGjOEaMYZrxBiuEQ2GsixhCzUYEEKwDD0GhBClFKwQqkhiy2egGBIGJJOd+QSXaTbsTya1WI/hz/tV1ny24R3AGKvrGmMchqHnebZtK/x0hxhE1o/jSAjZGhqQcYiBc04pdRxHcPoPGfCGtm3TNJWd/kKGrutc1z0TAGxo2zYIgpMBkIZhGJIkOR8AacjzXAsAzDCO4/spZNt2FEVZlhVFUVVV0zR938/zDAsAMxBCXl9ZloUxbpqGMbbfo/mZ7+fnjLH1j8yyLErpNE0iPXqevbcMdV0jhHzf7/tesEfbO9CWAWMcxzHnXLBH57voluHxeIgDtkIIUb4WwNB1nfL2a9YjQflymHtaeftlWSilv551EoNJLN0+W5XzAtzYANJpDB/HGJ4lavsdEWMwBv2Gr/vnPxi+AZNafY8ZmGwCAAAAAElFTkSuQmCC" alt="" />

这个怎么做呢?我们可以把他分开来看,可以看成一个三角形,两个边框还有一个鹰嘴一样的图。

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAd4AAADOCAIAAAAfXfS7AAAUr0lEQVR4nO3dTYgUVwLA8Sar4MFAEAMJ7EHYEDwI+TjEIothwNlshCyMuwsZiB+zOWXWLJmDH1kiOIwGDyGOIhjImPWSGB0PgszgIYQx6ylobyAj0UkOwoLtQUjSBpKlX3XXHmpse+rzvapXVa+q/j+aMNHuqurqmb81r19XNRwAgGEaRW8AAMCLNAO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+a1MCXQnkNsdwj7wZBI+iHswPgGJluy5oAk0kyaveRfETMD7e31yMjDIZErV5SGsKOPi8P+liIjPdJMmr1UX5ewQOt99bMTcZAbEVzP/Ukz9CLNpNkr2avjD7TeVz8H/vhG/6//aTKaAV1IM2n2SvMaDQba/ZMSFUo+zf0Qe/4b+EAgAdJMmr3Sv1JuoN2vS9Qp1ZFl0ozskGbS7KXlxeorUack0xz4CwFphl6kmTR7aXmx+krUqYjmBj4Lz90CbxlvMiqLNJNmLy0vVl+J8hRW4bCnwJEyskOaSbOXlherryzNijg6jn6I/2sgPdJMmr20vFh9pWiWzNCEf4CCAQ1khzQX/3G1yt+0vPoGqvBTQ+H+D513IPZAylPwAAAAAElFTkSuQmCC" alt="" />

三角形和两个边框好做的,利用本文的第一部分讲的就能作了。关键是鹰嘴怎么做?

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAWgAAAC7CAIAAADHWpO3AAAJeklEQVR4nO3dv09UWRTA8ReDCQUmhGgCyRYUxlBM4o/C0GimoMDEgs4pjE78B6TAShIIDYUFBQmUNEghBQmJoTBmCrIqjhuUQSgsUJEQM1ml0gLM2+KaxWWHcc6d++65M+/7ySkZOO/Ne9/MzjIS/bm6xTAMI5pIfQOGYRpuCAfDMOIhHAzDiOcwHDEA1IZwABAjHADECAcAMcIBQIxwABAjHADECAcAMcIBQIxwABAjHADECAcAMcIBQIxwABAjHADECAcAMcIBQIxwABCLnq1umdHeBEDDiJ693jKjvQl+7+8/zgY72ucGXhGOsOzv729ubi4sLIyPj+fz+Ww2m81mM5lMd3d3Z2eneh0IBwzCoW9zc3N6ejqXy2UymZaWluh46nUgHDAIh45yuWxi0dnZWaUUx4VDe/1DAa4ED6Jnr9+b0d4kFT5//jw7O3vr1q2urq7ae0E4EBrC4UmpVBocHDx9+rRFLwgHQkM4Ere4uJjP50+dOlVPMggHgkI4knJwcPDo0aNcLnfy5Mn6k0E4EBTCkYhisZjNZl31gnAgNITDsfX19aGhoTrfyyAcCB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EOwkE4IEY4CAfhgBjhIByEA2KEg3AQDogRDsJBOCBGOAgH4YAY4SAchANihINwEA6IEQ7CQTggRjgIB+GAWFRc/2RGexPfCIdBOGCBcBAOwgExwkE4CAfECAfhIBwQIxyEg3BAjHDYjPbuLhEOWIiKbz+Z0d7EN8JhEA5YIByEg3BALL3hiBP+Y4tpG+0nE14RDoZwQIxwMIQDYoSDi94Gpy7lCAdXvw1OXcoRDq5+G5y6lCMcXP02OHUpRzi4+m1w6lKOcHD12+DUpRzh4Oq3walLOcLB1W+DU5dyhIOr3wanLuUIB1e/DU5dyhEOrn4bnLqUi169/WRGexMFXP3WOHUpRziYukb7OYQOwsEQDogRDoZwQCzV4QBgJ3r1dseM9iYAGgbhACAWvdrYMaO9CYCGQTgAiBEOAGKEA4AY4QAgRjgAiBEOAGKEA4AY4QAgRjgAiBEOAGKEA4AY4QAgRjgAiBEOAGKEA4BY9NfGjhntTQA0DMIBQIxwABAjHADECAcAMcIBQOwf9MdYwNFvd7QAAAAASUVORK5CYII=" alt="" />

这样补齐是不是就是一个左上角为圆角的盒子了?

然后我们再把左边距的宽度缩小到0,是不是就是一个鹰嘴的图形了?

下面是分享图标的代码:

 div[id="hez1"]{
width:10px; height:30px;
border-top:5px solid #000;
border-left:5px solid #000;
border-right:5px solid white;
position: absolute;}
div[id="hez2"]{
width:30px; height:5px; border-top:5px solid white;
border-right:5px solid #000;border-bottom:5px solid #000;
position: absolute;left:0px;top:15px;} div[id="yuanjiao"]{
width:20px; height:20px;
border-radius:20px 0 0 0;
border-left:0px solid #000;
border-top:10px solid #000;
position: absolute;
left:5px;top:-21px;
}
div[id="sanjiao"]{
width:0px; height:0px;
border-top:13px solid white;
border-left:13px solid #000;
border-bottom:13px solid white;
border-right:0px solid white;
position: absolute;
left: 20px;
top: -18px;} <div id="hez1">
<div id="hez2">
<div id="yuanjiao">
<div id="sanjiao"></div>
</div></div></div>

等等!!!你以为这样就完了?太天真了!!!

把背景改为红色看看!!!

aaarticlea/png;base64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iwk/n69nrke4KV1zz33nJ9Gr6HL/dwuM/IsJP5+c3q2d+/eZcuWDRs2LKtmaCxfXsTO5VlI/P3m8ezhhx+++OKLMxsGoNHXp383K4C/38yePQVMmzatA5LJs/Lj7zebZ/8K5Po+NlQyeVZ+/P1m8+yyDkomz8qPv98Mnm0x7BkDzAWWAXcDO4HdwN4j7q2NZPKs/Pj7zeDZrFfeYPLIkdcADwED9gO5JJNn5cffb1rPNg4ZzRgxYr2t15H31l4yeVZ+/P2m9ewCAP12FuIAAAF2SURBVMAU4EZgX8IQbsnkWfnx95vKs31AFzAN2J0qBND/sY+Zksmz8uPvN5Vn64FpLz27T07/zTe7JJNn5cffbyrPFgDb2VtKiDwLib9fv2dD1rp3vztLDmP1LV5c3M7lWUj8/abybPcZZ2TJ0VaySy8t9IDlWUj8/aby7NnXvCZLjiNWY+nSI/9R7izyLCT+flN5ljHHYZItX972yV9nkWch8feb6/1n2TIVeeeDyLOQ+PuVZ/IsP/5+5Zk8y4+/X3kmz/Lj71eeybP8+PtN9Xd1GUN0+g6TIM9C4u9Xnsmz/Pj77cj1NTKv4nYuz0Li71eeybP8+PvtyN+jF/TenjzIs5D4+9X1tuVZfvz9yjN5lh9/v/JMnuXH3688k2f58fcrz+RZfvz9yjN5lh9/v/JMnuXH3688k2f58fcrz+RZfvz9yjN5lh9/vwMzZ1aVpB2xD6kCePrVai36OZUdfgJRB/gJRB3gJxB1gJ9A1AF+AlEH/j+Sv5lVk/9XVAAAAABJRU5ErkJggg==" alt="" />

这样就会发现,之前不管是三角形还是什么我们的边框设置的都是白色,而且分享图形放大了看会发现下面边框的一角被三角形挡住了。

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJgAAABzCAIAAADrI1w3AAAHVklEQVR4nO3czWsTaRzA8UEqlN0kTaaptu66ZJeaTMbZbZNMY1zXbsTsmoIuXWHXIKKD/4A51JOBxl5yqBqk0IIgvdQe7CEQkB5EcshJchBMMQcPPYgUCWhB0EMqs4euWNNkXp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RjnmDMHYy5j0RdessdjLmDMU8w5gnFvCHZK8i+r5dXkL2C3BeSPaGYJxTbvryry3LvXKGYOxTzhGKeULRPiHqFqE+I8uFIv/j/8oujfjHSL0Z4McqHo75wjA/LfFjmRZkXx3hxrP/z2v6nLyz7wrJXb/l2L1H2iV8Oy4tj/WLcLyUO/HL84OiJQ9Hxw/HTP55IH/n9nHD6fPj03weGpW/5gW/6eLD1H1cMBqGs+A7WAAAAAElFTkSuQmCC" alt="" />

怎么解决呢?很简单。吧他透明就好了,

rgba(r,p,g,a);其中A是透明度的意思,A为1 代表不透明,A为0代码100%透明。

rgba(255,255,255,0.0);以下是部分代码。

 div[id="sanjiao"]{width:0px; height:0px;
border-top:13px solid rgba(255,255,255,0.0);
border-left:13px solid #000;
border-bottom:13px solid rgba(255,255,255,0.0);
border-right:0px solid rgba(255,255,255,0.0);
position: absolute;
left: 20px;
top: -18px;}

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOgAAACPCAIAAAB/OgDNAAAKNUlEQVR4nO2dP2gUWRjAhxAhRYQlKMTKLURSLBgtZAqVBbeIYLFXuYLGwUrvCreIsTCQZVOkkGMDgaTIQZqYeKaIBCWFyCipJBcCbjAEObaQGLwFTRAUdnb3XTGaP5vZ+fu+ed/kfT+mMuTN9+fn+ObNm1FhBLFDucx0nRUK7M4dpqqss5MpCs5DEV0qAjf//ceWl9mzZ2x0lPX3s+vX2YUL7ORJ1tIiwNeWFnbyJLtwgV2/TuISvjAMViqxlRWm62xmhk1MsFyOZbNM01gqxZJJlkyy7m4Wj+8esdg+C2OxfT/t7v75W6kU0zSWzbJcjk1MsJkZputsZYWVSswwds5P4hKRhMQlIgmJS0QSEpeIJCQuEUlIXCKSkLhEJCFxiUhC4hKRhMQlIgmJS0QSEpeIJCQuEUlIXCKSkLhEJCFxiUhC4hKRhMQlIgmJS0QSEpeIJCQuEUlIXCKSkLjoKBQKokOIACQuOhRFIXcdIXHRoSiKoii5XE50IKghcdGh/ILctYHER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xkMhDBe8KHuC7Xax1HdvmXlsT1AJy4X7586ejoUBQllUoJuRtrwKu47p8y2I+czWZdlo7E9QCcuEtLS4qixOPx+fl5oOA94UlcT8/GbEbO5XLuS0fiegBO3Lm5Oa8GgOJeXK8xNxt5x1oSlz9w4g4PD8diMSSbEJhrcQuFApeR91pL4vIHTlxN0/Bcbpm7Zvuw1nLkBmtJXP7AiZtMJj9+/AgUtg/gmt0w8kFrSVz+wIk7MDAAFLM/whHX0loSlz9w4ob8upgjIYjbzFoSlz9w4mLb/wUqLq9DeC5uOOTifvv2DShmf4A22+Za66N0zqcjcUlcDiM7WUvi8gdOXGwANduNtSQuf0jcQGO6s5bE5Q+J639A19aSuPwhcX0jsHQkLonrHxJXJFKJe5gOgZVE4YE84nJH2tKhSEba6gdH2tKhSEba6gdH2tKhSEba6gdH2tKhSEba6gdH2tKhSEba6gdH2tKhSEba6gdH2tKhSEba6gdH2tKhSEba6gdH2tKhSEba6gdH2tKhSEba6gdH2tKhSEba6gdH2tKhSMZT9QnfiO4zT1AkI7qhsiC6zzxBkYzohsqC6D7zBEUyohsqC6L7zBMUyYhuqCyI7jNPUCQjuqGyILrPPEGRjOiGyoLoPvMERTKiGyoLovvMExTJiG6oLIjuM09QJCO6obIgus88QZGM6IbKgug+8wRFMqIbKgui+8wTFMmIbqgsiO4zT1AkI7qhsiC6zzxBkYzohsqC6D7zRPmXICLI/+K8oDTDQGTkAAAAAElFTkSuQmCC" alt="" />

你以为这样就完了吗?不!还没完。

做为一个优秀的前端工程师,我们要用最简洁的代码写出最好的功能。

  div[id="one"]{width:10px; height:30px;
border-top:5px solid #000;
border-left:5px solid #000;
border-right:5px solid rgba(255,255,255,0.0);
position: absolute;} div[id="one"]:after{
content:""; width:30px; height:5px;
border-top:5px solid rgba(255,255,255,0.0);
border-right:5px solid #000;
border-bottom:5px solid #000;
position: absolute;left:0px;top:15px;
} div[id="one"]:before{
content:""; width:20px; height:20px;
border-radius:20px 0 0 0;
border-left:0px solid #000;
border-top:10px solid #000;
position: absolute;
left:5px;top:-1px;
} div[id="sanjiao2"]{width:0px; height:0px;
border-top:13px solid rgba(255,255,255,0.0);
border-left:13px solid #000;
border-bottom:13px solid rgba(255,255,255,0.0);
border-right:0px solid rgba(255,255,255,0.0);
position: absolute;
left: 25px;
top: -10px;} <div id="one"><div id="sanjiao2"></div></div>

我们把上面的代码简化成只用两个DIV就能做出相同的效果。

下面是全部代码:

 <!DOCTYPE html>
<HTML>
<head>
<style type="text/css">
*{ margin:0px; padding:0px; border:0px; }
body{ padding:20px;}
div[id="duo1"]{width:0px; height:0px; border-top:50px solid rgba(255,255,255,0.0);
border-left:50px solid rgba(255,255,255,0.0);
border-bottom:50px solid #000;
border-right:50px solid rgba(255,255,255,0.0);} div[id="zjsjx"]{width:0px; height:0px;
border-top:50px solid rgba(255,255,255,0.0);
border-left:50px solid blue;
border-bottom:50px solid blue;
border-right:50px solid rgba(255,255,255,0.0);} div[id="dcbk"]{ width:50px; height:50px; outline:10px solid blue; border:10px solid yellow;} div[id="dcbk2"]{ width:50px; height:50px;
border:10px solid yellow;
box-shadow:0 0 0 10px blue;} div[id="yuan"]{ width:50px; height:50px;
border:10px solid yellow; margin:20px;
border-radius:100px;
box-shadow:0 0 0 10px black,0 0 0 20px blue,
0 0 0 30px red;} //分享图标的css代码
div[id="hez1"]{width:10px; height:30px;
border-top:5px solid #000;
border-left:5px solid #000;
border-right:5px solid rgba(255,255,255,0.0);
position: absolute;} div[id="hez2"]{width:30px; height:5px;
border-top:5px solid rgba(255,255,255,0.0);
border-right:5px solid #000;
border-bottom:5px solid #000;
position: absolute;left:0px;top:15px;} div[id="yuanjiao"]{width:20px; height:10px;
border-radius:20px 0 0 0;
border-left:0px solid #000;
border-top:10px solid #000;
position: absolute;
left:5px;top:-21px;
} div[id="sanjiao"]{width:0px; height:0px;
border-top:13px solid rgba(255,255,255,0.0);
border-left:13px solid #000;
border-bottom:13px solid rgba(255,255,255,0.0);
border-right:0px solid rgba(255,255,255,0.0);
position: absolute;
left: 20px;
top: -18px;} //简化后分享图标的css代码
div[id="one"]{width:10px; height:30px;
border-top:5px solid #000;
border-left:5px solid #000;
border-right:5px solid rgba(255,255,255,0.0);
position: absolute;} div[id="one"]:after{
content:""; width:30px; height:5px;
border-top:5px solid rgba(255,255,255,0.0);
border-right:5px solid #000;
border-bottom:5px solid #000;
position: absolute;left:0px;top:15px;
} div[id="one"]:before{
content:""; width:20px; height:20px;
border-radius:20px 0 0 0;
border-left:0px solid #000;
border-top:10px solid #000;
position: absolute;
left:5px;top:-1px;
} div[id="sanjiao2"]{width:0px; height:0px;
border-top:13px solid rgba(255,255,255,0.0);
border-left:13px solid #000;
border-bottom:13px solid rgba(255,255,255,0.0);
border-right:0px solid rgba(255,255,255,0.0);
position: absolute;
left: 25px;
top: -10px;} </style>
</head>
<body>
<div id="duo1"></div>
<br>
<div id="zjsjx"></div>
<br>
<div id="dcbk"></div>
<br>
<div id="dcbk2"></div>
<br>
<div id="yuan"></div>
<br>
<!--
<div id="hez1">
<div id="hez2">
<div id="yuanjiao">
<div id="sanjiao"></div>
</div></div></div>
-->   //简化后分享图标的HTML代码
<div id="one"><div id="sanjiao2"></div></div>
</body>
</HTML>

如果有什么疑问或者建议或者漏洞及错误欢迎指正,与我联系
==================================================================================================

本文为冷小包原创,转载请注明出处及作者。谢谢合作

                                                                       ——冷小包著

上一篇:springMVC异常&&重定向&&转发


下一篇:BZOJ 2002 [Hnoi2010]Bounce 弹飞绵羊 ——Link-Cut Tree