diff --git a/src/app/app.routes.ts b/src/app/app.routes.ts index 65a662e..b5e2b32 100644 --- a/src/app/app.routes.ts +++ b/src/app/app.routes.ts @@ -3,14 +3,8 @@ export const routes: Routes = [ { path: '', - loadComponent: () => { - // Branch: ?id= means legacy SBP merchant flow. - const hasLegacyId = typeof window !== 'undefined' - && new URLSearchParams(window.location.search).has('id'); - return hasLegacyId - ? import('./pages/legacy-pay-page/legacy-pay-page').then((m) => m.LegacyPayPage) - : import('./pages/fastcheck-page/fastcheck-page').then((m) => m.FastcheckPage); - } + loadComponent: () => + import('./pages/fastcheck-page/fastcheck-page').then((m) => m.FastcheckPage) }, { path: 'about', diff --git a/src/app/pages/fastcheck-page/fastcheck-page.html b/src/app/pages/fastcheck-page/fastcheck-page.html index 72a4de9..ede6d17 100644 --- a/src/app/pages/fastcheck-page/fastcheck-page.html +++ b/src/app/pages/fastcheck-page/fastcheck-page.html @@ -28,7 +28,7 @@ autocomplete="off" maxlength="20" /> - {{ 'fastcheck.number_new' | translate }} + {{ 'fastcheck.number_new' | translate }} diff --git a/src/app/pages/fastcheck-page/fastcheck-page.scss b/src/app/pages/fastcheck-page/fastcheck-page.scss index eec9b8e..d5c5d5d 100644 --- a/src/app/pages/fastcheck-page/fastcheck-page.scss +++ b/src/app/pages/fastcheck-page/fastcheck-page.scss @@ -64,6 +64,7 @@ font-family: inherit; white-space: nowrap; transition: opacity .15s, transform .1s, background .15s; + appearance: none; -webkit-appearance: none; &--ghost { @@ -159,6 +160,7 @@ cursor: pointer; font-family: inherit; transition: background .15s; + appearance: none; -webkit-appearance: none; &:hover { background: #e2e8f0; } diff --git a/src/app/pages/fastcheck-page/fastcheck-page.ts b/src/app/pages/fastcheck-page/fastcheck-page.ts index 55326d4..31710f7 100644 --- a/src/app/pages/fastcheck-page/fastcheck-page.ts +++ b/src/app/pages/fastcheck-page/fastcheck-page.ts @@ -51,6 +51,15 @@ export class FastcheckPage { error = signal(''); amountLoading = signal(false); + // Pass-through partner id from ?id= used by the "New" button link. + partnerId = signal(''); + newQrUrl = computed(() => { + const id = this.partnerId(); + return id + ? `https://qr.vitanova.network/?id=${encodeURIComponent(id)}` + : 'https://qr.vitanova.network/'; + }); + popupOpen = signal(false); popupLoading = signal(false); popupError = signal(''); @@ -98,8 +107,13 @@ export class FastcheckPage { this.codeEnabled.set(true); } + const params = new URLSearchParams(window.location.search); + + // ?id= — just propagated to the "New" button URL. + this.partnerId.set(params.get('id') ?? ''); + // ?iid=xxxxxx-xxxxxx-xxxxxx — auto-fill and trigger lookup - const iidParam = new URLSearchParams(window.location.search).get('iid') ?? ''; + const iidParam = params.get('iid') ?? ''; if (iidParam && !created) { const digits = iidParam.replace(/\D/g, '').slice(0, 18); const groups: string[] = [];