Merge pull request #20377 from mattray/opencost-20333

Use a proper React file import for the OpenCost logo
This commit is contained in:
Ben Lambert
2023-10-10 11:01:59 +02:00
committed by GitHub
3 changed files with 8 additions and 7 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-opencost': patch
---
Fix for broken image reference.
+1 -1
View File
@@ -28,7 +28,7 @@ and
</FlatRoutes>
```
3. Add link to OpenCost to your sidebar
3. Import the `MoneyIcon` and add link to OpenCost to your sidebar
```typescript
// packages/app/src/components/Root/Root.tsx
@@ -17,6 +17,7 @@ import React from 'react';
import { Grid } from '@material-ui/core';
import { Header, Page, Content } from '@backstage/core-components';
import { OpenCostReport } from '../OpenCostReport';
import logo from '../../images/pig.png';
export const OpenCostPage = () => (
<Page themeId="tool">
@@ -25,12 +26,7 @@ export const OpenCostPage = () => (
subtitle="Open source Kubernetes cloud cost monitoring"
>
<a href="https://opencost.io">
<img
width={68}
height={64}
src={require('../../images/pig.png')}
alt="OpenCost"
/>
<img width={68} height={64} src={logo} alt="OpenCost" />
</a>
</Header>
<Content>