forked from amundsen-io/amundsen
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement Custom Typography (amundsen-io#98)
Revamp of typography across the entire app * Removed dependency on bootstrap typography * Added 'Open Sans' and 'Roboto' font definitions * Defined new variables for header and body font family/weight * Defined a set of predefined classes such as title-1, title-2, body-1, etc. * Replaced ad hoc font styles with predefined classes whenever possible.
- Loading branch information
Daniel
authored and
Hans Adriaans
committed
Jun 30, 2022
1 parent
a2ba35f
commit 93e4e59
Showing
44 changed files
with
271 additions
and
210 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
37 changes: 36 additions & 1 deletion
37
frontend/amundsen_application/static/css/_fonts-default.scss
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 |
---|---|---|
@@ -1 +1,36 @@ | ||
// TODO - Import Open Sans or other default font | ||
@import 'variables'; | ||
|
||
// Roboto | ||
@font-face { | ||
font-family: 'Roboto'; | ||
src: url('/static/fonts/Roboto-Medium.ttf') format('truetype'); | ||
font-weight: $font-weight-header-regular; | ||
font-style: normal; | ||
} | ||
@font-face { | ||
font-family: 'Roboto'; | ||
src: url('/static/fonts/Roboto-Bold.ttf') format('truetype'); | ||
font-weight: $font-weight-header-bold; | ||
font-style: normal; | ||
} | ||
|
||
|
||
// Open Sans | ||
@font-face { | ||
font-family: 'Open Sans'; | ||
src: url('/static/fonts/OpenSans-Regular.ttf') format('truetype'); | ||
font-weight: $font-weight-body-regular; | ||
font-style: normal; | ||
} | ||
@font-face { | ||
font-family: 'Open Sans'; | ||
src: url('/static/fonts/OpenSans-SemiBold.ttf') format('truetype'); | ||
font-weight: $font-weight-body-semi-bold; | ||
font-style: normal; | ||
} | ||
@font-face { | ||
font-family: 'Open Sans'; | ||
src: url('/static/fonts/OpenSans-Bold.ttf') format('truetype'); | ||
font-weight: $font-weight-body-bold; | ||
font-style: normal; | ||
} |
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
1 change: 1 addition & 0 deletions
1
frontend/amundsen_application/static/css/_typography-custom.scss
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 @@ | ||
// This file is intentionally left blank and should be overwritten by in the build process. |
122 changes: 122 additions & 0 deletions
122
frontend/amundsen_application/static/css/_typography-default.scss
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,122 @@ | ||
@import 'variables'; | ||
|
||
.text-center { text-align: center; } | ||
.text-left { text-align: left; } | ||
.text-right { text-align: right; } | ||
|
||
h1, h2, h3, | ||
.h1, .h2, .h3 { | ||
color: $text-dark; | ||
font-family: $font-family-header; | ||
margin: 0; | ||
} | ||
|
||
h1, | ||
.h1 { | ||
font-size: 36px; | ||
font-weight: $font-weight-header-regular; | ||
} | ||
|
||
h2, | ||
.h2 { | ||
font-size: 26px; | ||
font-weight: $font-weight-header-bold; | ||
} | ||
|
||
h3, | ||
.h3 { | ||
font-size: 20px; | ||
font-weight: $font-weight-header-bold; | ||
} | ||
|
||
body { | ||
color: $text-dark; | ||
font-size: 14px; | ||
font-family: $font-family-body; | ||
font-weight: $font-weight-body-regular; | ||
} | ||
|
||
.title-1, .title-2, .title-3, | ||
.subtitle-1, .subtitle-2, .subtitle-3, | ||
.body-1, .body-2, .body-3, | ||
.body-secondary-3, .body-link, .caption { | ||
font-family: $font-family-body; | ||
} | ||
|
||
.title-1 { | ||
font-size: 20px; | ||
font-weight: $font-weight-body-bold; | ||
line-height: 24px; | ||
} | ||
|
||
.title-2 { | ||
font-size: 16px; | ||
font-weight: $font-weight-body-bold; | ||
} | ||
|
||
.title-3 { | ||
color: $text-medium; | ||
font-size: 14px; | ||
font-weight: $font-weight-body-bold; | ||
} | ||
|
||
.subtitle-1 { | ||
font-size: 20px; | ||
font-weight: $font-weight-body-semi-bold; | ||
line-height: 20px; | ||
} | ||
|
||
.subtitle-2 { | ||
font-size: 16px; | ||
font-weight: $font-weight-body-semi-bold; | ||
} | ||
|
||
.subtitle-3 { | ||
font-size: 14px; | ||
font-weight: $font-weight-body-semi-bold; | ||
} | ||
|
||
.body-1 { | ||
font-size: 20px; | ||
font-weight: $font-weight-body-regular; | ||
line-height: 24px; | ||
} | ||
|
||
.body-2 { | ||
font-size: 16px; | ||
font-weight: $font-weight-body-regular; | ||
} | ||
|
||
.body-3 { | ||
font-size: 14px; | ||
font-weight: $font-weight-body-regular; | ||
} | ||
|
||
.body-secondary-3 { | ||
color: $text-medium; | ||
font-size: 14px; | ||
font-weight: $font-weight-body-regular; | ||
} | ||
|
||
.body-link { | ||
color: $brand-color-4; | ||
font-size: 14px; | ||
} | ||
|
||
.caption { | ||
color: $text-medium; | ||
font-size: 13px; | ||
font-weight: $font-weight-body-bold; | ||
} | ||
|
||
.column-type { | ||
color: $brand-color-3; | ||
font-size: 13px; | ||
font-family: $font-family-monospace; | ||
} | ||
|
||
.helper-text { | ||
color: $text-light; | ||
font-size: 12px; | ||
font-family: $font-family-body; | ||
} |
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,4 @@ | ||
// Amundsen Default Typography | ||
@import 'typography-default'; | ||
// Per-Client Custom Typography | ||
@import 'typography-custom'; |
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
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
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
10 changes: 0 additions & 10 deletions
10
frontend/amundsen_application/static/js/components/BrowsePage/styles.scss
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
Oops, something went wrong.