generated from mlibrary/ruby-starter
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Creating
icons
stylesheet and updating mixins and variables.
- Loading branch information
1 parent
a8d12b5
commit df05098
Showing
6 changed files
with
77 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
@use './messages'; | ||
@use 'sass:map'; | ||
|
||
// -------------------------------------------------- | ||
// | ||
// # Icons | ||
// Styling for elements using Material Icons. | ||
// https://fonts.google.com/icons | ||
// | ||
// ## Table of Contents | ||
// 1. Variables and Mixins | ||
// 1.1 Variables | ||
// 1.2 Mixins | ||
// | ||
// -------------------------------------------------- | ||
|
||
|
||
|
||
|
||
|
||
// ******************************* // | ||
// *** 1. VARIABLES AND MIXINS *** // | ||
// ******************************* // | ||
|
||
// * * // | ||
// * 1.1 VARIABLES * // | ||
// * * // | ||
$icons: ( | ||
'dashboard': '\e871', | ||
'info': '\e88e', | ||
'open_in_new': '\e89e' | ||
); | ||
|
||
|
||
|
||
// * * // | ||
// * 1.2 MIXINS * // | ||
// * * // | ||
|
||
@mixin icon($fill: false, $icon) { | ||
font-family: "Material Symbols Rounded"; | ||
@if $fill { | ||
font-variation-settings: "FILL" 1; | ||
} | ||
@if $icon { | ||
@include messages.missing-key($icons, $icon); | ||
& { | ||
content: map.get($icons, $icon); | ||
display: inline-block; | ||
vertical-align: bottom; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters