Skip to content

Commit

Permalink
feat: Support for stylus. #32
Browse files Browse the repository at this point in the history
  • Loading branch information
jaywcjlove committed Aug 15, 2020
1 parent 5b89c56 commit 7826c60
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -459,6 +459,8 @@ svgtofont.eot
svgtofont.json
svgtofont.less
svgtofont.module.less
svgtofont.scss
svgtofont.styl
svgtofont.svg
svgtofont.symbol.svg
svgtofont.ttf
Expand Down
18 changes: 18 additions & 0 deletions src/styles/_{{fontname}}.styl
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
@font-face {font-family: "{{fontname}}";
src: url('{{fontname}}.eot?t={{timestamp}}'); /* IE9*/
src: url('{{fontname}}.eot?t={{timestamp}}#iefix') format('embedded-opentype'), /* IE6-IE8 */
url("{{fontname}}.woff2?t={{timestamp}}") format("woff2"),
url("{{fontname}}.woff?t={{timestamp}}") format("woff"),
url('{{fontname}}.ttf?t={{timestamp}}') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
url('{{fontname}}.svg?t={{timestamp}}#{{fontname}}') format('svg'); /* iOS 4.1- */
}

[class^="{{prefix}}-"], [class*=" {{prefix}}-"] {
font-family: '{{fontname}}' !important;
font-size:16px;
font-style:normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}

{{cssString}}

0 comments on commit 7826c60

Please sign in to comment.