Skip to content

Commit

Permalink
feat: use single src image for tradingpost svg
Browse files Browse the repository at this point in the history
  • Loading branch information
its-felix committed Jan 12, 2024
1 parent 8af39e9 commit 6f5bd0b
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 15 deletions.
Binary file modified public/assets/de/tradingpost.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/assets/en/tradingpost.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed public/assets/tp_background1.png
Binary file not shown.
Binary file removed public/assets/tp_background2.png
Binary file not shown.
Binary file removed public/assets/tp_background3.png
Binary file not shown.
18 changes: 3 additions & 15 deletions src/components/common/assets.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -149,30 +149,18 @@ export function Tradingpost({

return (
<svg style={responsiveStyle} xmlns='http://www.w3.org/2000/svg' viewBox='0 0 991 731'>
<defs>
<image id='background1' href='/assets/tp_background1.png' width='27' height='18' />
<image id='background2' href='/assets/tp_background2.png' width='103' height='24' />
<image id='background3' href='/assets/tp_background3.png' width='174' height='32' />
</defs>

<image href={href} width='991' height='731' />
<image href={iconHref} width='57' height='57' x='272' y='138' />

<use href='#background1' x='415' y='270' />
<use href='#background1' x='490' y='270' />
<use href='#background1' x='565' y='270' />
<use href='#background2' x='335' y='144' />
<use href='#background3' x='380' y='310' />

<text x='335' y='160' fontSize='1.7em' fill='#b222ff'>{name}</text>

<text x='418' y='286' fontSize='1.2em' fill={goldColor}>{gold}</text>
<text x='495' y='286' fontSize='1.2em' fill={silverColor}>{silver}</text>
<text x='570' y='286' fontSize='1.2em' fill={copperColor}>{copper}</text>

<text x='382' y='333' fontSize='1.5em' fill={goldColor}>{gold}</text>
<text x='439' y='333' fontSize='1.5em' fill={silverColor}>{silver}</text>
<text x='497' y='333' fontSize='1.5em' fill={copperColor}>{copper}</text>
<text x='384' y='332' fontSize='1.5em' fill={goldColor}>{gold}</text>
<text x='439' y='332' fontSize='1.5em' fill={silverColor}>{silver}</text>
<text x='497' y='332' fontSize='1.5em' fill={copperColor}>{copper}</text>

<line x1='425' y1='270' x2='600' y2='200' stroke='red' strokeWidth='3px' />
<line x1='505' y1='270' x2='600' y2='200' stroke='red' strokeWidth='3px' />
Expand Down

0 comments on commit 6f5bd0b

Please sign in to comment.