-
Notifications
You must be signed in to change notification settings - Fork 217
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(refactor) Improve footer component and a11y (#1240)
This PR is a follow-up to #1192 that makes the following changes: - Extracts footer styles to a dedicated stylesheet - Replaces the `Button` Carbon component with a `Link` component for the "Learn more" button - Adds error handing for the logo image loading - Improves a11y with aria labels - Adds a type annotation for the `Logo`` interface
- Loading branch information
1 parent
78eae7c
commit 7269bbf
Showing
6 changed files
with
105 additions
and
83 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
@use '@carbon/colors'; | ||
@use '@carbon/layout'; | ||
|
||
.footer { | ||
display: flex; | ||
justify-content: space-between; | ||
align-items: center; | ||
padding: layout.$spacing-05; | ||
position: absolute; | ||
bottom: 0; | ||
flex-wrap: wrap; | ||
gap: layout.$spacing-05; | ||
width: 100%; | ||
} | ||
|
||
.poweredByTile { | ||
display: flex; | ||
text-align: left; | ||
max-width: fit-content; | ||
min-height: fit-content; | ||
font-size: smaller; | ||
background-color: colors.$white; | ||
padding: layout.$spacing-03 layout.$spacing-05; | ||
border: 1px solid colors.$gray-20; | ||
border-radius: layout.$spacing-04; | ||
flex-wrap: wrap; | ||
} | ||
|
||
.poweredByContainer { | ||
display: flex; | ||
height: layout.$spacing-06; | ||
align-items: center; | ||
gap: layout.$spacing-03; | ||
} | ||
|
||
.poweredByLogo { | ||
height: layout.$spacing-07; | ||
width: auto; | ||
max-width: layout.$spacing-12; | ||
border-collapse: collapse; | ||
padding: 0; | ||
object-fit: contain; | ||
display: block; | ||
flex-shrink: 0; | ||
} | ||
|
||
.poweredByLogo + .poweredByText { | ||
margin-left: layout.$spacing-02; | ||
} | ||
|
||
.learnMoreButton { | ||
display: flex; | ||
align-items: center; | ||
|
||
svg { | ||
fill: colors.$blue-60; | ||
} | ||
} |
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