Skip to content

Commit

Permalink
add warning icon for outdated merchants
Browse files Browse the repository at this point in the history
  • Loading branch information
secondl1ght committed Mar 19, 2024
1 parent 33e1d6b commit 6dc4733
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/lib/map/setup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1034,7 +1034,9 @@ ${
? `<span title="Verified within the last year"><svg width='16px' height='16px' class='inline text-primary dark:text-white'>
<use width='16px' height='16px' href="/icons/popup/spritesheet.svg#verified"></use>
</svg></span>`
: ''
: `<span title="Outdated please re-verify"><svg width='16px' height='16px' class='inline text-primary dark:text-white'>
<use width='16px' height='16px' href="/icons/popup/spritesheet.svg#outdated"></use>
</svg></span>`
}`
: '<span title="Not verified">---</span>'
}
Expand Down
16 changes: 16 additions & 0 deletions src/routes/merchant/[id]/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,7 @@
let lnTooltip: HTMLImageElement;
let nfcTooltip: HTMLImageElement;
let verifiedTooltip: HTMLSpanElement;
let outdatedTooltip: HTMLSpanElement;
$: thirdPartyTooltip &&
merchant &&
Expand Down Expand Up @@ -290,6 +291,11 @@
content: 'Verified within the last year'
});
$: outdatedTooltip &&
tippy([outdatedTooltip], {
content: 'Outdated please re-verify'
});
let lat: number | undefined;
let long: number | undefined;
Expand Down Expand Up @@ -701,6 +707,16 @@
type="popup"
/>
</span>
{:else}
<span bind:this={outdatedTooltip}>
<Icon
w="30"
h="30"
style="text-primary dark:text-white mr-2"
icon="outdated"
type="popup"
/>
</span>
{/if}
<strong>{verified[0]}</strong>
</div>
Expand Down
5 changes: 5 additions & 0 deletions static/icons/popup/spritesheet.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 6dc4733

Please sign in to comment.