Skip to content

Commit 14d1f4f

Browse files
authored
Merge pull request #2 from ALPHA-60/add-font
Use "Metropolis" font for body
2 parents f5db1fa + cff4f7b commit 14d1f4f

File tree

3 files changed

+19
-2
lines changed

3 files changed

+19
-2
lines changed

src/Main.elm

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ import Header exposing (header)
1313
import HomePage
1414
import Html as H
1515
import Html.Attributes as HA
16-
import Html.Styled exposing (Html, audio)
17-
import Html.Styled.Attributes exposing (controls, id)
16+
import Html.Styled exposing (Html, audio, text, node)
17+
import Html.Styled.Attributes exposing (controls, id, type_)
1818
import Http
1919
import Json.Decode as JD
2020
import Knob exposing (KnobMsg(..), simpleKnobSvg, simpleSwitchSvg)
@@ -574,6 +574,7 @@ view model =
574574
{ title = "Synthi100"
575575
, body =
576576
[ globalCSS
577+
, fontImport
577578
, header
578579
, page
579580
]
@@ -587,5 +588,21 @@ globalCSS =
587588
[ body
588589
[ backgroundColor (hex "000000")
589590
, color (hex "4A90E2")
591+
, fontFamilies ["Metropolis"]
590592
]
591593
]
594+
595+
fontImport : Html Msg
596+
fontImport =
597+
node "style" [type_ "text/css"] [text """
598+
@font-face {
599+
font-family: "Metropolis";
600+
src: url(/Metropolis-Medium.woff);
601+
}
602+
@font-face {
603+
font-family: "Metropolis";
604+
src: url(/Metropolis-Bold.woff);
605+
font-weight: bold;
606+
}
607+
"""]
608+

web/Metropolis-Bold.woff

17.5 KB
Binary file not shown.

web/Metropolis-Medium.woff

17.3 KB
Binary file not shown.

0 commit comments

Comments
 (0)