mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Add Atkinson Hyperlegible font
This commit is contained in:
parent
7c55ed7a4c
commit
aae18ed348
7 changed files with 45 additions and 13 deletions
|
|
@ -21,6 +21,7 @@ public func registerFonts() -> Bool {
|
|||
registerFont(bundle: .module, fontName: "OpenDyslexicAlta-Regular", fontExtension: "otf"),
|
||||
registerFont(bundle: .module, fontName: "Montserrat-Regular", fontExtension: "ttf"),
|
||||
registerFont(bundle: .module, fontName: "Newsreader-Regular", fontExtension: "ttf"),
|
||||
registerFont(bundle: .module, fontName: "AtkinsonHyperlegible-Regular", fontExtension: "ttf"),
|
||||
registerFont(bundle: .module, fontName: "SourceSerifPro-Regular", fontExtension: "ttf")
|
||||
]
|
||||
.allSatisfy { $0 }
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@ public enum WebFont: String, CaseIterable {
|
|||
case georgia = "Georgia"
|
||||
case montserrat = "Montserrat"
|
||||
case newsreader = "Newsreader"
|
||||
case atkinsonHyperlegible = "AtkinsonHyperlegible"
|
||||
|
||||
static var sorted: [WebFont] {
|
||||
allCases.sorted { left, right in
|
||||
|
|
@ -34,8 +35,19 @@ public enum WebFont: String, CaseIterable {
|
|||
|
||||
public var displayValue: String {
|
||||
switch self {
|
||||
case .inter, .merriweather, .lora, .opensans, .roboto, .crimsontext, .sourceserifpro, .georgia, .montserrat, .newsreader:
|
||||
case .inter,
|
||||
.merriweather,
|
||||
.lora,
|
||||
.opensans,
|
||||
.roboto,
|
||||
.crimsontext,
|
||||
.sourceserifpro,
|
||||
.georgia,
|
||||
.montserrat,
|
||||
.newsreader:
|
||||
return rawValue
|
||||
case .atkinsonHyperlegible:
|
||||
return "Atkinson Hyperlegible"
|
||||
case .openDyslexic:
|
||||
return "Open Dyslexic"
|
||||
case .system:
|
||||
|
|
@ -178,8 +190,6 @@ public enum WebFont: String, CaseIterable {
|
|||
Text(LocalText.genericFont)
|
||||
Spacer()
|
||||
Image(systemName: "chevron.right")
|
||||
// Button(action: {}, label: { Text("Crimson Text").frame(width: 91) })
|
||||
// .buttonStyle(RoundedRectButtonStyle())
|
||||
}
|
||||
}
|
||||
.foregroundColor(.appGrayTextContrast)
|
||||
|
|
|
|||
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
|
|
@ -232,63 +232,84 @@ div#appleid-signin {
|
|||
font-family: 'Montserrat';
|
||||
font-weight: 400;
|
||||
font-style: normal;
|
||||
src: url('/static/fonts/Source_Serif_Pro/Montserrat-Regular.ttf');
|
||||
src: url('/static/fonts/Montserrat/Montserrat-Regular.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Montserrat';
|
||||
font-weight: 700;
|
||||
font-style: normal;
|
||||
src: url('/static/fonts/Source_Serif_Pro/Montserrat-Bold.ttf');
|
||||
src: url('/static/fonts/Montserrat/Montserrat-Bold.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Montserrat';
|
||||
font-weight: 400;
|
||||
font-style: italic;
|
||||
src: url('/static/fonts/Source_Serif_Pro/Montserrat-Italic.ttf');
|
||||
src: url('/static/fonts/Montserrat/Montserrat-Italic.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Georgia';
|
||||
font-weight: 400;
|
||||
font-style: normal;
|
||||
src: url('/static/fonts/Source_Serif_Pro/Georgia-Regular.ttf');
|
||||
src: url('/static/fonts/Georgia/Georgia-Regular.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Georgia';
|
||||
font-weight: 700;
|
||||
font-style: normal;
|
||||
src: url('/static/fonts/Source_Serif_Pro/Georgia-Bold.ttf');
|
||||
src: url('/static/fonts/Georgia/Georgia-Bold.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Georgia';
|
||||
font-weight: 400;
|
||||
font-style: italic;
|
||||
src: url('/static/fonts/Source_Serif_Pro/Georgia-Italic.ttf');
|
||||
src: url('/static/fonts/Georgia/Georgia-Italic.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Newsreader';
|
||||
font-weight: 400;
|
||||
font-style: normal;
|
||||
src: url('/static/fonts/Source_Serif_Pro/Newsreader-Regular.ttf');
|
||||
src: url('/static/fonts/Newsreader/Newsreader-Regular.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Newsreader';
|
||||
font-weight: 700;
|
||||
font-style: normal;
|
||||
src: url('/static/fonts/Source_Serif_Pro/Newsreader-Bold.ttf');
|
||||
src: url('/static/fonts/Newsreader/Newsreader-Bold.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Newsreader';
|
||||
font-weight: 400;
|
||||
font-style: italic;
|
||||
src: url('/static/fonts/Source_Serif_Pro/Newsreader-Italic.ttf');
|
||||
src: url('/static/fonts/Newsreader/Newsreader-Italic.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'AtkinsonHyperlegible';
|
||||
font-weight: 400;
|
||||
font-style: normal;
|
||||
src: url('/static/fonts/AtkinsonHyperlegible/AtkinsonHyperlegible-Regular.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'AtkinsonHyperlegible';
|
||||
font-weight: 700;
|
||||
font-style: normal;
|
||||
src: url('/static/fonts/AtkinsonHyperlegible/AtkinsonHyperlegible-Bold.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'AtkinsonHyperlegible';
|
||||
font-weight: 400;
|
||||
font-style: italic;
|
||||
src: url('/static/fonts/AtkinsonHyperlegible/AtkinsonHyperlegible-Italic.ttf');
|
||||
}
|
||||
|
||||
@font-face {
|
||||
|
|
|
|||
Loading…
Reference in a new issue