Skip to content

Commit

Permalink
Merge pull request #209 from pnnl/ira-title-and-workflow-changes
Browse files Browse the repository at this point in the history
App title updated based on the environment
  • Loading branch information
sudhacheran authored Jul 11, 2024
2 parents 1759e04 + 7ef40c3 commit 17e4e6e
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion src/components/root_layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,17 @@ const RootLayout: FC<RootLayoutProps> = ({ children }) => {
}
}, [location.pathname])

/**
* When deploying the application to AWS S3, the environment variable 'REACT_APP_ENV'
* is set to 'quality-install-tool' or 'ira-quality-install-tool' for the respective applications.
*
* The title of the application is set accordingly
*/
const app_title =
process.env.REACT_APP_ENV === 'quality-install-tool'
? 'Quality Install Tool'
: 'IRA - Quality Install Tool'

return (
<div id="root-background">
<Navbar id="root-banner">
Expand All @@ -72,7 +83,7 @@ const RootLayout: FC<RootLayoutProps> = ({ children }) => {
)}
<Container id="root-flex-layout">
<Navbar.Brand>
<span id="root-title">Quality Install Tool</span>
<span id="root-title">{app_title}</span>
</Navbar.Brand>
</Container>
</Navbar>
Expand Down

0 comments on commit 17e4e6e

Please sign in to comment.