-
Notifications
You must be signed in to change notification settings - Fork 89
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #115 from 18F/ui-styling
Styling and layout improvements
- Loading branch information
Showing
4 changed files
with
63 additions
and
27 deletions.
There are no files selected for viewing
10 changes: 10 additions & 0 deletions
10
resources/validations/ui/src/context/browser/util/styles.ts
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,10 @@ | ||
export const colorTokenForRole = (role: string | undefined) => { | ||
const roleLower = (role || '').toLowerCase(); | ||
if (roleLower.includes('warn')) { | ||
return 'warning'; | ||
} | ||
if (roleLower.includes('error') || roleLower.includes('fatal')) { | ||
return 'error'; | ||
} | ||
return 'info'; | ||
}; |
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