Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/debug.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:

- name: Build torus-page
if: steps.changes.outputs.torus-page == 'true'
run: echo "Building torus-page..."
run: echo "Building torus-page... "

# Debug output
- name: Show changes
Expand Down
4 changes: 4 additions & 0 deletions apps/torus-wallet/src/app/components/actions/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
export { SendAction } from "./send"
export { StakeAction } from "./stake"
export { TransferStakeAction } from "./transfer-stake"
export { UnstakeAction } from "./unstake"
36 changes: 0 additions & 36 deletions apps/torus-wallet/src/app/components/actions/receive.tsx

This file was deleted.

22 changes: 2 additions & 20 deletions apps/torus-wallet/src/app/components/sidebar-links.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import Link from "next/link";
import { Check } from "lucide-react";
import { usePathname, useRouter } from "next/navigation";
import { usePathname } from "next/navigation";

import {
Button,
Expand All @@ -20,7 +20,6 @@ import { env } from "~/env";
export const SidebarLinks = () => {
const chainEnv = env("NEXT_PUBLIC_TORUS_CHAIN_ENV");
const pathname = usePathname();
const router = useRouter();

const bridgeLink =
chainEnv === "mainnet"
Expand All @@ -29,26 +28,9 @@ export const SidebarLinks = () => {

const isActive = (path: string) => pathname === path;

const handleSelectChange = (value: string) => {
switch (value) {
case "wallet":
router.push("/");
break;
case "staking":
router.push("/staking");
break;
case "bridge":
router.push(bridgeLink);
break;
}
};

return (
<>
<Select
onValueChange={handleSelectChange}
defaultValue={pathname === "/" ? "wallet" : pathname.slice(1)}
>
<Select defaultValue="wallet">
<SelectTrigger className="w-full lg:hidden">
<SelectValue placeholder="Select a view" />
</SelectTrigger>
Expand Down
6 changes: 1 addition & 5 deletions apps/torus-wallet/src/app/components/wallet-actions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,8 @@ import { SendAction } from "./actions/send";
import { StakeAction } from "./actions/stake";
import { TransferStakeAction } from "./actions/transfer-stake";
import { UnstakeAction } from "./actions/unstake";
import { ReceiveAction } from "./actions/receive";

const transferButtons = [
{ text: "Send", component: <SendAction /> },
{ text: "Receive", component: <ReceiveAction /> },
];
const transferButtons = [{ text: "Send", component: <SendAction /> }];

const stakingButtons = [
{ text: "Stake", component: <StakeAction /> },
Expand Down
41 changes: 0 additions & 41 deletions apps/torus-wallet/src/app/components/wallet-skeleton-loader.tsx

This file was deleted.

4 changes: 2 additions & 2 deletions apps/torus-wallet/src/app/page.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { Suspense } from "react";

import { Loading } from "@torus-ts/ui";
import WalletActions from "./components/wallet-actions";
import { WalletSkeletonLoader } from "./components/wallet-skeleton-loader";

export default function Page(): JSX.Element {
return (
<Suspense fallback={<WalletSkeletonLoader />}>
<Suspense fallback={<Loading />}>
<WalletActions route="transfer" />
</Suspense>
);
Expand Down
4 changes: 2 additions & 2 deletions apps/torus-wallet/src/app/staking/page.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { Suspense } from "react";

import { Loading } from "@torus-ts/ui";
import WalletActions from "../components/wallet-actions";
import { WalletSkeletonLoader } from "../components/wallet-skeleton-loader";

export default function Page(): JSX.Element {
return (
<Suspense fallback={<WalletSkeletonLoader />}>
<Suspense fallback={<Loading />}>
<WalletActions route="staking" />
</Suspense>
);
Expand Down
Loading