Use .icon class for atomicons

This commit is contained in:
simurai
2017-06-01 20:57:57 +09:00
parent d9337a453a
commit c1534d7d2d
6 changed files with 59 additions and 79 deletions

View File

@@ -10,7 +10,6 @@
@import "octicon-utf-codes";
@import "octicon-mixins";
@import "octicons";
@import "atomicons";
// Normalize + scaffolding
@import "normalize";

View File

@@ -1,77 +0,0 @@
@font-face {
font-family: 'Atomicons';
src:
url('atomicons.woff') format('woff');
font-weight: normal;
font-style: normal;
}
.atomicon:before {
display: inline-block;
speak: none;
width: 16px;
height: 16px;
line-height: 1;
font-family: 'Atomicons';
font-size: 16px;
font-style: normal;
font-weight: normal;
font-variant: normal;
text-transform: none;
-webkit-font-smoothing: antialiased;
}
.atomicon-array:before {
content: "\e900";
}
.atomicon-boolean:before {
content: "\e901";
}
.atomicon-class:before {
content: "\e902";
}
.atomicon-constant:before {
content: "\e903";
}
.atomicon-constructor:before {
content: "\e904";
}
.atomicon-enum:before {
content: "\e905";
}
.atomicon-field:before {
content: "\e906";
}
.atomicon-file:before {
content: "\e907";
}
.atomicon-function:before {
content: "\e908";
}
.atomicon-interface:before {
content: "\e909";
}
.atomicon-method:before {
content: "\e90a";
}
.atomicon-module:before {
content: "\e90b";
}
.atomicon-namespace:before {
content: "\e90c";
}
.atomicon-number:before {
content: "\e90d";
}
.atomicon-package:before {
content: "\e90e";
}
.atomicon-property:before {
content: "\e90f";
}
.atomicon-string:before {
content: "\e910";
}
.atomicon-variable:before {
content: "\e911";
}

View File

@@ -11,6 +11,31 @@
// Find: @([a-z-]+): "[^"]+";
// Replace: .make-icon(\1);
// Atomicons (private)
.make-icon(entity-array);
.make-icon(entity-boolean);
.make-icon(entity-class);
.make-icon(entity-constant);
.make-icon(entity-constructor);
.make-icon(entity-enum);
.make-icon(entity-field);
.make-icon(entity-file);
.make-icon(entity-function);
.make-icon(entity-interface);
.make-icon(entity-method);
.make-icon(entity-module);
.make-icon(entity-namespace);
.make-icon(entity-number);
.make-icon(entity-package);
.make-icon(entity-property);
.make-icon(entity-string);
.make-icon(entity-variable);
// Octicons
.make-icon(alert);
.make-icon(alignment-align);
.make-icon(alignment-aligned-to);

View File

@@ -2,11 +2,12 @@
@import "octicon-mixins";
//
// Octicon font
// Icon fonts
// --------------------------------------------------
@font-face { .octicon-font-legacy(); } // keep for backwards compatibility
@font-face { .octicon-font(); }
@font-face { .atomicon-font(); } // Private
//

View File

@@ -46,3 +46,10 @@
font-weight: normal;
font-style: normal;
}
.atomicon-font() {
font-family: 'Octicons Regular';
src: url('atomicons.woff') format('woff');
font-weight: normal;
font-style: normal;
}

View File

@@ -1,3 +1,28 @@
// Atomicons (private)
@entity-array: "\e900";
@entity-boolean: "\e901";
@entity-class: "\e902";
@entity-constant: "\e903";
@entity-constructor: "\e904";
@entity-enum: "\e905";
@entity-field: "\e906";
@entity-file: "\e907";
@entity-function: "\e908";
@entity-interface: "\e909";
@entity-method: "\e90a";
@entity-module: "\e90b";
@entity-namespace: "\e90c";
@entity-number: "\e90d";
@entity-package: "\e90e";
@entity-property: "\e90f";
@entity-string: "\e910";
@entity-variable: "\e911";
// Octicons
@alert: "\f02d";
@alignment-align: "\f08a";
@alignment-aligned-to: "\f08e";