Skip to content

Commit

Permalink
Merge pull request #247 from joeetwork/jet/token-info-back-button
Browse files Browse the repository at this point in the history
Back button added to token info page
  • Loading branch information
0xIchigo committed Dec 13, 2023
2 parents a725623 + a9b43be commit 85b9f6d
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 32 deletions.
23 changes: 7 additions & 16 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,18 +1,9 @@
{
"editor.tabSize": 4,
"eslint.validate": [
"javascript",
"javascriptreact",
"html",
"svelte"
],
"editor.codeActionsOnSave": {
"source.fixAll.stylelint": true,
"source.fixAll.eslint": true,
},
"cSpell.words": [
"HELIUS",
"lamports",
"solana"
],
"cSpell.words": ["HELIUS", "lamports", "solana"],
"editor.codeActionsOnSave": {
"source.fixAll.stylelint": "explicit",
"source.fixAll.eslint": "explicit"
},
"editor.tabSize": 4,
"eslint.validate": ["javascript", "javascriptreact", "html", "svelte"]
}
50 changes: 34 additions & 16 deletions src/lib/components/nav.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -45,23 +45,41 @@

<div class="col-span-2 flex items-center justify-end">
<div class="flex justify-end pr-2">
<div
class="tooltip"
data-tip="Docs"
>
<a
href="https://docs.helius.dev/welcome/what-is-helius"
rel="noreferrer"
target="_blank"
class="btn-ghost btn"
{#if $page.url.pathname == "/"}
<div
class="tooltip"
data-tip="Docs"
>
<img
class="h-6 opacity-90"
src="docs.svg"
alt=""
/>
</a>
</div>
<a
href="https://docs.helius.dev/welcome/what-is-helius"
rel="noreferrer"
target="_blank"
class="btn-ghost btn"
>
<img
class="h-6 opacity-90"
src="docs.svg"
alt=""
/>
</a>
</div>
{/if}
{#if $page.url.pathname !== "/"}
<div
class="tooltip"
data-tip="Back"
>
<button
class="btn-ghost btn"
on:click={() => window.history.back()}
>
<Icon
id="arrowLeft"
size="lg"
/>
</button>
</div>
{/if}
<div
class="tooltip"
data-tip="Help"
Expand Down
1 change: 1 addition & 0 deletions src/routes/token/[token]/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
import getMimeType from "$lib/util/get-mime-type";
import { metadataStore } from "$lib/util/stores/metadata";
import type { UITokenMetadata } from "$lib/types";
import Icon from "$lib/components/icon.svelte";
const address = $page.params.token;
const params = new URLSearchParams(window.location.search);
Expand Down

0 comments on commit 85b9f6d

Please sign in to comment.