Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/icons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
authorXhmikosR <xhmikosr@gmail.com>2020-12-30 22:42:45 +0300
committerGitHub <noreply@github.com>2020-12-30 22:42:45 +0300
commite2994cc531f3bdb516bd6e7a293d0443b5660aa4 (patch)
tree8e8e5cda18b1972e0266c7c42d627e360306f7e8 /build
parent2fab4138db79ea1f3fa355c57c44b1b1b13814af (diff)
Move font templates to build/font (#628)
Diffstat (limited to 'build')
-rw-r--r--build/font/css.hbs22
-rw-r--r--build/font/html.hbs53
2 files changed, 75 insertions, 0 deletions
diff --git a/build/font/css.hbs b/build/font/css.hbs
new file mode 100644
index 000000000..e42c780b7
--- /dev/null
+++ b/build/font/css.hbs
@@ -0,0 +1,22 @@
+@font-face {
+ font-family: "{{ name }}";
+ src: {{{ fontSrc }}};
+}
+
+[class^="{{prefix}}-"]::before,
+[class*=" {{prefix}}-"]::before {
+ display: inline-block;
+ font-family: {{ name }} !important;
+ font-style: normal;
+ font-weight: normal !important;
+ font-variant: normal;
+ text-transform: none;
+ line-height: 1;
+ vertical-align: text-bottom;
+ -webkit-font-smoothing: antialiased;
+ -moz-osx-font-smoothing: grayscale;
+}
+
+{{# each codepoints }}
+.{{ ../prefix }}-{{ @key }}::before { content: "\\{{ codepoint this }}"; }
+{{/ each }}
diff --git a/build/font/html.hbs b/build/font/html.hbs
new file mode 100644
index 000000000..0639a3a43
--- /dev/null
+++ b/build/font/html.hbs
@@ -0,0 +1,53 @@
+<!doctype html>
+<html lang="en">
+<head>
+ <meta charset="utf-8">
+ <title>{{ name }}</title>
+
+ <style>
+ .icons {
+ display: grid;
+ max-width: 100%;
+ grid-template-columns: repeat(auto-fit, minmax(100px, 1fr) );
+ gap: 1.25rem;
+ }
+ .icon {
+ background-color: var(--bs-light);
+ border-radius: .25rem;
+ }
+ .bi {
+ margin: .25rem;
+ font-size: 2.5rem;
+ }
+ .label {
+ font-family: var(--bs-font-monospace);
+ }
+ .label {
+ display: inline-block;
+ width: 100%;
+ overflow: hidden;
+ padding: .25rem;
+ font-size: .625rem;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+ }
+ </style>
+
+ <link rel="stylesheet" href="/assets/css/bootstrap.min.css">
+ <link rel="stylesheet" href="{{ name }}.css">
+</head>
+<body class="text-center">
+
+ <h1>{{ name }}</h1>
+
+ <div class="icons">
+ {{# each assets }}
+ <div class="icon">
+ <{{ ../tag }} class="{{ ../prefix }} {{ ../prefix }}-{{ @key }}"></{{ ../tag }}>
+ <div class="label">{{ @key }}</div>
+ </div>
+ {{/ each }}
+ </div>
+
+</body>
+</html>