mirror of https://github.com/docker/docs.git
css: add icons utility
Adds an .icon utility class to set ligature text via via a data-icon attribute on the element. This is a workaround to prevent crawlers from picking up the font ligature innertext in html directly. Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
This commit is contained in:
parent
48b3eb2672
commit
d006adfc20
|
@ -0,0 +1,19 @@
|
|||
@layer utilities {
|
||||
.icon {
|
||||
font-family: "Material Symbols Rounded";
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
font-size: 24px; /* Preferred icon size */
|
||||
display: inline-block;
|
||||
line-height: 1;
|
||||
text-transform: none;
|
||||
letter-spacing: normal;
|
||||
word-wrap: normal;
|
||||
white-space: nowrap;
|
||||
direction: ltr;
|
||||
}
|
||||
|
||||
.icon:after {
|
||||
content: attr(data-icon);
|
||||
}
|
||||
}
|
|
@ -14,3 +14,4 @@
|
|||
@import "tailwindcss/utilities";
|
||||
@import "/assets/css/syntax-light";
|
||||
@import "/assets/css/syntax-dark";
|
||||
@import "/assets/css/icons";
|
||||
|
|
Loading…
Reference in New Issue