Skip to content

Commit

Permalink
Revert "Revert "Change HashRoute to BrowserRoute"" to support Line in…
Browse files Browse the repository at this point in the history
…tegration

This reverts commit 3bd80f4.
  • Loading branch information
thi-investax committed Dec 31, 2024
1 parent 56133a6 commit 37a62fe
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 10 deletions.
2 changes: 1 addition & 1 deletion e2e_tests/page-object/adminPage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class AdminPage extends WebPage {
readonly rejectAnnotationTextField: Locator;
readonly submitRejectAnnotationButton: Locator;

kycAdminURL = config.use.baseURL + '#/admin/kyc';
kycAdminURL = config.use.baseURL + '/admin/kyc';

constructor(page: Page, context?: BrowserContext) {
super(page, context);
Expand Down
2 changes: 1 addition & 1 deletion e2e_tests/page-object/kycPage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export class KycPage extends WebPage {
readonly countryOfTaxDeclarationDropdown: Locator;
readonly taxIdentificationNumberField: Locator;

kycURL = config.use.baseURL + '#/kyc';
kycURL = config.use.baseURL + '/kyc';
pendingApprovalText = 'Pending approval';
changesRequestedText = 'Changes Requested';
rejectedText = 'Rejected';
Expand Down
2 changes: 1 addition & 1 deletion e2e_tests/page-object/liquidityPoolsPage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ export class LiquidityPoolsPage extends WebPage {
}

async removeCreatedLiqudityPool(pool) {
await this.page.goto(config.use.baseURL + '#/pool')
await this.page.goto(config.use.baseURL + '/pool')
await this.removeLiquidityPool(pool);
}

Expand Down
8 changes: 4 additions & 4 deletions src/components/Launchpad/InvestmentCard/PreviewModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ interface Props {
}

const handleRedirect = () => {
window.location.href = '/#/kyc';
window.location.href = '/kyc';
};

export const PreviewModal = ({ isModalOpen, closeModal, offer }: Props) => {
Expand Down Expand Up @@ -63,7 +63,7 @@ export const PreviewModal = ({ isModalOpen, closeModal, offer }: Props) => {
<div style={{ marginBottom: '10px', marginTop: isMobile ? '15px' : '' }}>
<OfferSaleAllocation {...offer} />
</div>


{offer.hasPresale && (
<div style={{ marginTop: '10px' }}>
Expand All @@ -90,15 +90,15 @@ export const PreviewModal = ({ isModalOpen, closeModal, offer }: Props) => {
<span style={{ fontSize: '16px', fontWeight: '800', color: '#292933', width: isMobile ? '100%' : '60%' }}>
This deal is only available to KYC-ed users
</span>
{!isMobile && <PinnedContentButton onClick={handleRedirect} style={{ width: '190px' }}>Complete KYC</PinnedContentButton>}
{!isMobile && <PinnedContentButton onClick={handleRedirect} style={{ width: '190px' }}>Complete KYC</PinnedContentButton>}
</div>
<div>
<span style={{ color: '#666680', fontSize: '13px', fontWeight: '600' }}>
Become a KYC-ed user by connecting your wallet and completing your KYC.
</span>

</div>
{isMobile && <PinnedContentButton onClick={handleRedirect} style={{ marginTop: '18px' }}>Complete KYC</PinnedContentButton>}
{isMobile && <PinnedContentButton onClick={handleRedirect} style={{ marginTop: '18px' }}>Complete KYC</PinnedContentButton>}
</div>
</ModalContent>
</ModalContainer>
Expand Down
7 changes: 4 additions & 3 deletions src/index.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
/* eslint-disable react/no-deprecated */
import { CookiesProvider } from 'react-cookie'
import React, { StrictMode } from 'react'
import { isMobile } from 'react-device-detect'
import ReactDOM from 'react-dom/client'
import ReactGA from 'react-ga'
import { Provider } from 'react-redux'
import { HashRouter } from 'react-router-dom'
import { BrowserRouter } from 'react-router-dom'
import { LocalizationProvider } from '@material-ui/pickers'
import DayJsUtils from '@material-ui/pickers/adapter/dayjs'
import { PersistGate } from 'redux-persist/integration/react'
Expand Down Expand Up @@ -89,7 +90,7 @@ ReactDOM.createRoot(document.getElementById('root')!).render(
<StrictMode>
<Provider store={store}>
<PersistGate loading={null} persistor={persistor}>
<HashRouter>
<BrowserRouter>
<LanguageProvider>
<Web3Provider>
<Blocklist>
Expand All @@ -108,7 +109,7 @@ ReactDOM.createRoot(document.getElementById('root')!).render(
</Blocklist>
</Web3Provider>
</LanguageProvider>
</HashRouter>
</BrowserRouter>
</PersistGate>
</Provider>
</StrictMode>
Expand Down

0 comments on commit 37a62fe

Please sign in to comment.