Skip to content

Commit

Permalink
merge dev to working branch
Browse files Browse the repository at this point in the history
  • Loading branch information
Izobov committed Nov 21, 2024
2 parents 43f447d + 9c7a1eb commit 6a6b9ad
Show file tree
Hide file tree
Showing 9 changed files with 65 additions and 35 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "betarena-scores-platform",
"version": "2.15.1",
"version": "2.15.3",
"description": "Betarena Official Scores Platform (PWA)",
"author": "migbash",
"license": "ISC",
Expand Down
9 changes: 8 additions & 1 deletion src/app.html
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
href="/app.css"
/>


<!--
▓ NOTE:
▓ > Declare all CSS 'all-in-one-css-file.css'.
Expand Down Expand Up @@ -14741,8 +14742,14 @@
gtag('js', new Date());
gtag('config', 'G-LDMRQC7B7Z');
</script>
<!--
╭──────────────────────────────────────────────────────────────────────────────────╮
│ 3rd-Party JS Snippet | optimonk │
╰──────────────────────────────────────────────────────────────────────────────────╯
-->
<script type="text/javascript" src="https://onsite.optimonk.com/script.js?account=240954" async></script>

%sveltekit.head%
%sveltekit.head%
</head>

<!--
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,8 +276,9 @@ MODAL - DYNAMIC
</button>

<a
href="/u/deposit/{$userBetarenaSettings.lang}"
title='Go to Deposit Page'
href="https://betarena.com/public-presale"
target="_blank"
title='Go to Presale Page'
>
<button
on:click={() => closeModal()}
Expand Down
31 changes: 18 additions & 13 deletions src/lib/components/page/profile/Widget-MenuOpt-Row.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ COMPONENT JS (w/ TS)
): void
{
const if_M_0: boolean
= ['Scores'].includes(MENU_OPT)
= ['Scores', "Withdraw"].includes(MENU_OPT)
;
if (if_M_0) return;
Expand Down Expand Up @@ -194,11 +194,14 @@ COMPONENT JS (w/ TS)
}
else if (MENU_OPT == 'Withdraw')
{
hoverMenuOptIconAlt = icon_withdraw_select;
selectedMenuOptIcon
= SELECTED_OPT == MENU_OPT
? icon_withdraw_select
: icon_withdraw
hoverMenuOptIconAlt = icon_withdraw;
selectedMenuOptIcon = icon_withdraw;
// hoverMenuOptIconAlt = icon_withdraw_select;
// selectedMenuOptIcon
// = SELECTED_OPT == MENU_OPT
// ? icon_withdraw_select
// : icon_withdraw
;
}
else if (MENU_OPT == 'Transaction History')
Expand Down Expand Up @@ -347,14 +350,16 @@ VIEW DESIGN - 2
{
!
[
'Scores'
'Scores',
"Withdraw"
]
.includes(MENU_OPT)
}
class:cursor-not-allowed=
{
[
'Scores'
'Scores',
"Withdraw"
]
.includes(MENU_OPT)
}
Expand Down Expand Up @@ -384,7 +389,7 @@ VIEW DESIGN - 2
<img
src=
{
(!isHoverMenuOptItem || ['Scores'].includes(MENU_OPT))
(!isHoverMenuOptItem || ['Scores', "Withdraw"].includes(MENU_OPT))
? selectedMenuOptIcon
: hoverMenuOptIconAlt
}
Expand Down Expand Up @@ -413,16 +418,16 @@ VIEW DESIGN - 2
class:color-grey-shade=
{
[
'Scores'

'Scores',
"Withdraw"
].includes(MENU_OPT)
}
class:menu-opt-text=
{
!
[
'Scores'

'Scores',
"Withdraw"
].includes(MENU_OPT)
}
>
Expand Down
18 changes: 15 additions & 3 deletions src/lib/components/page/profile/Widget-MenuOpt.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,13 @@ COMPONENT JS (w/ TS)
if (selectedMenuOpt == 'Investor')
targetUrl = `/u/investor/${$userBetarenaSettings.lang}`
;
if (selectedMenuOpt == 'Deposit')
targetUrl = `/u/deposit/${$userBetarenaSettings.lang}`
;
if (selectedMenuOpt == "Deposit") {
if (browser) {
window.open(`https://betarena.com/public-presale`, "_blank");
}
selectedMenuOpt = "Dashboard";
targetUrl = `/u/dashboard/${$userBetarenaSettings.lang}`;
}
if (selectedMenuOpt == 'Transaction History')
targetUrl = `/u/transaction-history/${$userBetarenaSettings.lang}`
;
Expand Down Expand Up @@ -149,6 +153,14 @@ COMPONENT JS (w/ TS)
selectedMenuOpt = 'Investor';
break;
case 'deposit':
case 'deposit':
goto
(
`/u/dashboard/${$userBetarenaSettings.lang}`,
{
replaceState: true
}
);
selectedMenuOpt = 'Deposit';
break;
case 'transaction-history':
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,9 @@
▓ NOTE:
▓ > Public Presale box.
-->
<div
<a
href="https://betarena.com/public-presale"
target="_blank"
class=
"
view-opt-box
Expand All @@ -163,11 +165,11 @@
<TranslationText
key={`${CNAME}/title`}
text={profileTrs?.investor?.tab.tab_2}
fallback={'Public Presale (Soon)'}
fallback={'Public Presale'}
/>
</p>

</div>
</a>

</div>

Expand Down Expand Up @@ -272,6 +274,12 @@
width: 100%;
}
a.view-opt-box:hover p {
cursor: pointer;
color: var(--white) !important;
opacity: 1;
}
div.view-opt-box
{
/* 🎨 style */
Expand Down
10 changes: 2 additions & 8 deletions src/lib/components/shared/BuyBta/Buy-BTA-Button.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@
import type { B_NAV_T } from "@betarena/scores-lib/types/navbar.js";
import Button from "$lib/components/ui/Button.svelte";
import { createEventDispatcher, onMount } from "svelte";
import { modalStore } from "$lib/store/modal.js";
import BuyBtaPopup from "./Buy-BTA-popup.svelte";
import { get } from "$lib/api/utils.js";
import buyOptionsTranslations from "./store"
import sessionStore from "$lib/store/session.js";
Expand Down Expand Up @@ -74,12 +72,8 @@
function click() {
dispatch("click");
if (popup) {
modalStore.update((s) => ({
show: true,
modal: true,
component: BuyBtaPopup as any,
}));
if (popup && browser) {
window.open("https://betarena.com/public-presale", "_blank");
}
}
Expand Down
7 changes: 5 additions & 2 deletions src/lib/components/shared/BuyBta/Buy-BTA-popup.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -45,16 +45,19 @@
// │ 4. $: [..] │
// ╰────────────────────────────────────────────────────────────────────────╯
$: data = $buyOptionsTranslations;
$: console.log("DATA: ", data)
$: options = [
{
name: data.competitions || "Competitions",
description: data.info_competitions || "Get tokens to participate",
link: data.link_competitions || "/competitions",
target: "_self",
},
{
name: data.presale || "Presale",
description: data.info_presale || "Invest on BTA token presale",
link: data.link_presale || `/u/investor/${$userBetarenaSettings.lang}`,
link: "https://betarena.com/public-presale",
target: "_blank",
},
];
Expand All @@ -80,7 +83,7 @@
on:click={() => ($modalStore.show = false)}
>
{#each options as option, i}
<a href={option.link} class="option" title={option.description}>
<a href={option.link} target={option.target} class="option" title={option.description}>
<div class="label">
<span class="name">{option.name}</span>
<span class="description">{option.description}</span>
Expand Down

0 comments on commit 6a6b9ad

Please sign in to comment.