Skip to content

Commit a0fa7fd

Browse files
colinmcneildgageot
authored andcommitted
Use consistent casing
1 parent 31d1844 commit a0fa7fd

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

src/extension/ui/src/components/tile/Modal.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ import { useSecrets } from '../../queries/useSecrets';
4545
import { CatalogItemRichened } from '../../types/catalog';
4646
import ConfigEditor from './ConfigEditor';
4747
import { isEmpty } from 'lodash-es';
48-
import CatalogIconPath from '../../utils/CatalogIconPath';
48+
import getCatalogIconPath from '../../utils/getCatalogIconPath';
4949

5050
interface TabPanelProps {
5151
children?: React.ReactNode;
@@ -177,7 +177,7 @@ const ConfigurationModal = ({
177177
// TODO: Figure out if catalog icon is actually optional, and if so, find a good fallback.
178178
catalogItem.icon && <Avatar
179179
variant="square"
180-
src={CatalogIconPath(catalogItem.icon)}
180+
src={getCatalogIconPath(catalogItem.icon)}
181181
alt={catalogItem.name}
182182
sx={{
183183
width: 40,

src/extension/ui/src/components/tile/Top.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { Avatar, CardHeader, Switch, Tooltip, Typography } from '@mui/material';
22

33
import { CatalogItemRichened } from '../../types/catalog';
44
import { useEffect, useState } from 'react';
5-
import CatalogIconPath from '../../utils/CatalogIconPath';
5+
import getCatalogIconPath from '../../utils/getCatalogIconPath';
66

77
type TopProps = {
88
onToggleRegister: (checked: boolean) => void;
@@ -21,7 +21,7 @@ export default function Top({ item, onToggleRegister }: TopProps) {
2121
setToggled(item.registered);
2222
}, [item.registered]);
2323

24-
const url = CatalogIconPath(item.icon || '');
24+
const url = getCatalogIconPath(item.icon || '');
2525

2626
return (
2727
<CardHeader
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
const CatalogIconPath = (iconUrl: string) => {
1+
const getCatalogIconPath = (iconUrl: string) => {
22
const iconFilename = [...iconUrl].map(c => c.charCodeAt(0).toString(16).padStart(2, '0')).join('').toUpperCase() + '0A.png';
33
return new URL(`/static-assets/${iconFilename}`, import.meta.url).href;
44
}
55

6-
export default CatalogIconPath;
6+
export default getCatalogIconPath;

0 commit comments

Comments
 (0)