mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-11-21 22:30:41 +08:00
Implement new landing page
This commit is contained in:
+2
-34
@@ -6,11 +6,11 @@
|
||||
import Authenticate from "./Header/Authenticate.svelte";
|
||||
import Breadcrumbs from "./Header/Breadcrumbs.svelte";
|
||||
import Button from "@app/components/Button.svelte";
|
||||
import Command from "@app/components/Command.svelte";
|
||||
import IconSmall from "@app/components/IconSmall.svelte";
|
||||
import Link from "@app/components/Link.svelte";
|
||||
import NodeInfo from "@app/App/Header/NodeInfo.svelte";
|
||||
import Popover from "@app/components/Popover.svelte";
|
||||
import ConnectInstructions from "@app/components/ConnectInstructions.svelte";
|
||||
|
||||
const buttonTitle: Record<HttpdState["state"], string> = {
|
||||
stopped: "radicle-httpd is stopped",
|
||||
@@ -39,26 +39,9 @@
|
||||
height: var(--button-regular-height);
|
||||
margin: 0 0.5rem;
|
||||
}
|
||||
.label {
|
||||
display: block;
|
||||
font-size: var(--font-size-small);
|
||||
font-weight: var(--font-weight-regular);
|
||||
margin-bottom: 0.75rem;
|
||||
}
|
||||
.connect-popover {
|
||||
max-width: 20rem;
|
||||
}
|
||||
.divider {
|
||||
height: 1px;
|
||||
width: 100%;
|
||||
background-color: var(--color-fill-separator);
|
||||
margin: 1rem 0;
|
||||
}
|
||||
.heading {
|
||||
font-size: var(--font-size-small);
|
||||
font-weight: var(--font-weight-bold);
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
</style>
|
||||
|
||||
<header>
|
||||
@@ -89,22 +72,7 @@
|
||||
Connect
|
||||
</Button>
|
||||
<div slot="popover" class="connect-popover">
|
||||
<div class="heading">Connect & Authenticate</div>
|
||||
<div class="label">
|
||||
Start the local node to browse projecs on your local machine, create
|
||||
issues, and participate in discussions.
|
||||
</div>
|
||||
<Command fullWidth command={`rad web ${window.origin}`} />
|
||||
|
||||
<div class="divider" />
|
||||
<div class="heading">New to Radicle?</div>
|
||||
<div class="label">
|
||||
Run the following command and follow the instructions to install
|
||||
Radicle and get started.
|
||||
</div>
|
||||
<Command
|
||||
fullWidth
|
||||
command="sh <(curl -sSf https://radicle.xyz/install)" />
|
||||
<ConnectInstructions />
|
||||
</div>
|
||||
</Popover>
|
||||
{:else}
|
||||
|
||||
@@ -5,11 +5,11 @@
|
||||
|
||||
import Avatar from "@app/components/Avatar.svelte";
|
||||
import Button from "@app/components/Button.svelte";
|
||||
import Command from "@app/components/Command.svelte";
|
||||
import IconButton from "@app/components/IconButton.svelte";
|
||||
import IconSmall from "@app/components/IconSmall.svelte";
|
||||
import NodeId from "@app/components/NodeId.svelte";
|
||||
import Popover from "@app/components/Popover.svelte";
|
||||
import ConnectInstructions from "@app/components/ConnectInstructions.svelte";
|
||||
</script>
|
||||
|
||||
<style>
|
||||
@@ -37,12 +37,6 @@
|
||||
.connect-popover {
|
||||
max-width: 20rem;
|
||||
}
|
||||
.label {
|
||||
display: block;
|
||||
font-size: var(--font-size-small);
|
||||
font-weight: var(--font-weight-regular);
|
||||
margin-bottom: 0.75rem;
|
||||
}
|
||||
</style>
|
||||
|
||||
{#if $httpdStore.state === "authenticated"}
|
||||
@@ -87,12 +81,7 @@
|
||||
Authenticate
|
||||
</Button>
|
||||
<div slot="popover" class="connect-popover">
|
||||
<div class="label">
|
||||
Authenticate with your local node to make changes.
|
||||
</div>
|
||||
<Command
|
||||
fullWidth
|
||||
command={`rad web ${window.origin} --connect ${httpd.api.hostname}:${httpd.api.port}`} />
|
||||
<ConnectInstructions />
|
||||
</div>
|
||||
</Popover>
|
||||
{/if}
|
||||
|
||||
Reference in New Issue
Block a user