Skip to content

Commit

Permalink
fix(AboutModal): Add backgroung image to aboutModal
Browse files Browse the repository at this point in the history
closes hawtio#1031

(cherry picked from commit af8ac3c)
  • Loading branch information
mmelko committed Oct 25, 2024
1 parent 8e5f3b7 commit 2de27d3
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 1 deletion.
1 change: 1 addition & 0 deletions app/public/hawtconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
"title": "Hawtio Management Console",
"description": "A Hawtio reimplementation based on TypeScript + React.",
"imgSrc": "hawtio-logo.svg",
"backgroundImgSrc": "pf-background.svg",
"productInfo": [
{ "name": "ABC", "value": "1.2.3" },
{ "name": "XYZ", "value": "7.8.9" }
Expand Down
15 changes: 15 additions & 0 deletions app/public/img/background-inverted.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions app/public/pf-background.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions packages/hawtio/src/core/config-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ export type AboutConfig = {
title?: string
description?: string
imgSrc?: string
backgroundImgSrc?: string
productInfo?: AboutProductInfo[]
copyright?: string
}
Expand Down
3 changes: 2 additions & 1 deletion packages/hawtio/src/ui/about/HawtioAbout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export const HawtioAbout: React.FunctionComponent<HawtioAboutProps> = props => {
}

const imgSrc = about.imgSrc || imgLogo
const backgroundImgSrc = about.backgroundImgSrc
const title = about.title || 'Hawtio Management Console'
const copyright = about.copyright || '© Hawtio project'

Expand All @@ -36,7 +37,6 @@ export const HawtioAbout: React.FunctionComponent<HawtioAboutProps> = props => {
const productInfo = about.productInfo || []
productInfo.sort((a, b) => stringSorter(a.name, b.name))
log.debug('Product info:', productInfo)

const AboutProductInfo = () => (
<TextContent id='hawtio-about-product-info'>
<Text component='h3'>Component versions</Text>
Expand All @@ -57,6 +57,7 @@ export const HawtioAbout: React.FunctionComponent<HawtioAboutProps> = props => {
onClose={props.onClose}
productName={title}
brandImageSrc={imgSrc}
backgroundImageSrc={backgroundImgSrc}
brandImageAlt={title}
trademark={copyright}
>
Expand Down

0 comments on commit 2de27d3

Please sign in to comment.