随笔分类 -  -CSS-

积累ing
摘要:body结构 方法一: 将display设置成table-cell,然后水平居中设置text-align为center,垂直居中设置vertical-align为middle。 方法二: 通过position定位来实现。将div设置成相对定位relative,将img设置成绝对定位absolute, 阅读全文
posted @ 2018-12-28 16:49 Alyson.fu 阅读(69019) 评论(0) 推荐(6)
摘要:问题:在ruby命令窗口sass --watch global.scss:global.css会报错,且生成的css文件中文注释是乱码的。根据提示是编码问题。 >>> Sass is watching for changes. Press Ctrl-C to stop. Encoding::Comp 阅读全文
posted @ 2018-12-14 11:29 Alyson.fu 阅读(1133) 评论(0) 推荐(0)
摘要:开始第一想法是用JS去计算图片原始大小和div的高宽的比例来做图片的自适应,但是后面觉得很麻烦,而且准确性不高。 查了一遍百度才发现可以这么做。 给img的父节点设置固定高宽,然后在img的样式里设置:max-height:100%;max-width:100%;不用设置width和height,问 阅读全文
posted @ 2018-03-19 16:01 Alyson.fu 阅读(336) 评论(0) 推荐(0)
摘要:—– BEGIN LICENSE —– TwitterInc 200 User License EA7E-890007 1D77F72E 390CDD93 4DCBA022 FAF60790 61AA12C0 A37081C5 D0316412 4584D136 94D7F7D4 95BC8C1C 阅读全文
posted @ 2017-10-12 16:02 Alyson.fu 阅读(343) 评论(0) 推荐(0)
摘要:// <![CDATA[ document.oncontextmenu=new Function("event.returnValue=false"); document.onselectstart=new Function("event.returnValue=false"); // ]]> 问题 阅读全文
posted @ 2017-01-24 18:10 Alyson.fu 阅读(11282) 评论(0) 推荐(0)
摘要:// <![CDATA[ document.oncontextmenu=new Function("event.returnValue=false"); document.onselectstart=new Function("event.returnValue=false"); // ]]> 在j 阅读全文
posted @ 2017-01-10 18:54 Alyson.fu 阅读(1339) 评论(0) 推荐(0)
摘要:// <![CDATA[ document.oncontextmenu=new Function("event.returnValue=false"); document.onselectstart=new Function("event.returnValue=false"); // ]]> iO 阅读全文
posted @ 2016-12-22 11:38 Alyson.fu 阅读(6012) 评论(6) 推荐(0)