图标是利用 -face">font-face 规则自定义字体 实现的。

    使用的时候只需要加入对应的类名即可,例如 alert 图标,可以这样用:<i class="cubeic-alert"></i>


    style - 图2

    源码地址:reset,使用的就是 Eric Meyer's Reset CSS。

    1. @require "./variable.styl"
    2. body, html
    3. line-height: 1
    4. font-family: 'PingFang SC', 'STHeitiSC-Light', 'Helvetica-Light', arial, sans-serif, 'Droid Sans Fallback'
    5. user-select: none
    6. -webkit-tap-highlight-color: transparent
    7. .clear-fix
    8. &::after
    9. content: ""
    10. display: table
    11. clear: both
    12. .border-top-1px, .border-right-1px, .border-bottom-1px, .border-left-1px
    13. position: relative
    14. &::before, &::after
    15. content: ""
    16. display: block
    17. position: absolute
    18. transform-origin: 0 0
    19. &::before
    20. border-top: 1px solid - color-row-line
    21. left: 0
    22. top: 0
    23. transform-origin: 0 top
    24. .border-right-1px
    25. &::after
    26. border-right: 1px solid - color-col-line
    27. top: 0
    28. right: 0
    29. height: 100%
    30. transform-origin: right 0
    31. .border-bottom-1px
    32. &::after
    33. border-bottom: 1px solid - color-row-line
    34. left: 0
    35. bottom: 0
    36. width: 100%
    37. transform-origin: 0 bottom
    38. .border-left-1px
    39. &::before
    40. border-left: 1px solid - color-col-line
    41. top: 0
    42. left: 0
    43. height: 100%
    44. transform-origin: left 0
    45. @media (min-resolution: 2dppx)
    46. &::before
    47. width: 200%
    48. .border-right-1px
    49. &::after
    50. height: 200%
    51. transform: scale(.5) translateZ(0)
    52. .border-bottom-1px
    53. &::after
    54. width: 200%
    55. transform: scale(.5) translateZ(0)
    56. .border-left-1px
    57. &::before
    58. height: 200%
    59. transform: scale(.5) translateZ(0)
    60. @media (min-resolution: 3dppx)
    61. .border-top-1px
    62. &::before
    63. width: 300%
    64. transform: scale(.333) translateZ(0)
    65. .border-right-1px
    66. &::after
    67. height: 300%
    68. transform: scale(.333) translateZ(0)
    69. .border-bottom-1px
    70. &::after
    71. width: 300%
    72. transform: scale(.333) translateZ(0)
    73. .border-left-1px
    74. &::before
    75. height: 300%

    原文: