diff --git a/src/lib/components/SegmentedControl.svelte b/src/lib/components/SegmentedControl.svelte index 8c0fb4d1e..5c222f4f9 100644 --- a/src/lib/components/SegmentedControl.svelte +++ b/src/lib/components/SegmentedControl.svelte @@ -17,7 +17,12 @@ button-like control with a segement for each possible value. export let options: readonly string[]; export let secondary = false; - const dispatch = createEventDispatcher(); + const dispatch = createEventDispatcher<{ + change: { + name: string | undefined; + value: string; + }; + }>(); function dispatchChange(this: HTMLInputElement) { dispatch('change', { @@ -30,7 +35,7 @@ button-like control with a segement for each possible value.
{#each options as option} {/each} @@ -58,13 +63,16 @@ button-like control with a segement for each possible value. } .segmented-control { - display: flex; + display: grid; + grid-auto-flow: column; gap: var(--gap); overflow: hidden; } label { - flex: 1; + display: flex; + justify-content: center; + align-items: center; background: var(--background-default, inherit); padding: var(--padding); border-radius: var(--border-radius, inherit); @@ -77,16 +85,16 @@ button-like control with a segement for each possible value. &:first-child { border-radius: var(--radius-md) 0 0 var(--radius-md); - span { - padding-left: var(--space-xxs); + div { + padding-left: 0.25rem; } } &:last-child { border-radius: 0 var(--radius-md) var(--radius-md) 0; - span { - padding-right: var(--space-xxs); + div { + padding-right: 0.25rem; } } } diff --git a/src/lib/trade-executor/components/ChainFilter.svelte b/src/lib/trade-executor/components/ChainFilter.svelte new file mode 100644 index 000000000..61e7a3e5c --- /dev/null +++ b/src/lib/trade-executor/components/ChainFilter.svelte @@ -0,0 +1,66 @@ + + + + + +
+ {#if option !== 'all'} + {option} + {/if} + {option} +
+
+ + diff --git a/src/lib/trade-executor/components/index.ts b/src/lib/trade-executor/components/index.ts deleted file mode 100644 index 087677004..000000000 --- a/src/lib/trade-executor/components/index.ts +++ /dev/null @@ -1,5 +0,0 @@ -export { default as KeyMetric } from './KeyMetric.svelte'; -export { default as KeyMetricDescription } from './KeyMetricDescription.svelte'; -export { default as StrategyIcon } from './StrategyIcon.svelte'; -export { default as StrategyError } from './StrategyError.svelte'; -export * from './StrategyError.svelte'; diff --git a/src/routes/FeaturedStrategies.svelte b/src/routes/FeaturedStrategies.svelte index 1b6dbc481..25bcde387 100644 --- a/src/routes/FeaturedStrategies.svelte +++ b/src/routes/FeaturedStrategies.svelte @@ -1,34 +1,38 @@

Open strategies

-
- - - +
+
-
- {#each strategies as strategy (strategy.id)} - +
+ {#each filteredStrategies as strategy, idx (strategy.id)} + {@const params = { duration: 200, delay: 50 * idx, easing: cubicOut }} +
+ +
{:else}
Check back soon to see top-performing strategies. @@ -37,7 +41,7 @@
-
@@ -46,22 +50,14 @@ text-align: center; } - .differentiators { - margin-top: 0.75rem; - display: flex; - gap: 2em; + .filters { + display: grid; + gap: 1.25rem; justify-content: center; - font: var(--f-ui-md-medium); - letter-spacing: var(--f-ui-md-spacing); + margin-top: 1rem; @media (--viewport-sm-down) { - font: var(--f-ui-sm-medium); - letter-spacing: var(--f-ui-sm-spacing); - } - - @media (--viewport-xs) { - display: grid; - gap: 0.875em; + justify-content: stretch; } } diff --git a/src/routes/HomeHeroBanner.svelte b/src/routes/HomeHeroBanner.svelte index 7e94ef241..983c0c60c 100644 --- a/src/routes/HomeHeroBanner.svelte +++ b/src/routes/HomeHeroBanner.svelte @@ -1,26 +1,32 @@ - - -
+
- +
+

+ Unleash the power of + automated crypto trading +

+
+ + + +
+
-

Unleash the power of automated crypto trading

- -
+
  1. Select a professional-grade strategy aligned with your goals.
  2. @@ -28,39 +34,54 @@ Home page hero banner.
  3. Track your returns as the strategy trades automatically.
  4. Adjust your portfolio or withdraw anytime.
- -
- - -
-
+ diff --git a/src/routes/strategies/+page.svelte b/src/routes/strategies/+page.svelte index b60ea86fa..38e01a68b 100644 --- a/src/routes/strategies/+page.svelte +++ b/src/routes/strategies/+page.svelte @@ -1,25 +1,51 @@ @@ -29,22 +55,35 @@
- - - {#if admin} - - {/if} - - + + +
+ + {#if admin} + + {/if} +
{#if filteredStrategies.length}
- {#each filteredStrategies as strategy (strategy.id)} - + {#each filteredStrategies as strategy, idx (strategy.id)} + {@const params = { duration: 200, delay: 50 * idx, easing: cubicOut }} +
+ +
{/each}
{:else} -

Currently no open strategies available.

+

+ Currently no + {#if selectedStatus !== 'all'} + {selectedStatus} + {/if} + {#if selectedChain !== 'all'} + {getChain(selectedChain)?.name} + {/if} + strategies available. +

Join Discord to get access. @@ -64,6 +103,27 @@ margin-top: 1.25rem; } + .filters { + display: grid; + gap: 0.75rem 1rem; + grid-template-columns: auto auto; + justify-content: space-between; + margin-block: -1.5rem 1.75rem; + text-transform: capitalize; + + @media (--viewport-md-down) { + margin-block: -1rem 1.5rem; + } + + @media (--viewport-sm-down) { + grid-template-columns: 1fr; + } + + @media (--viewport-xs) { + margin-block: -0.75rem 1.25rem; + } + } + .strategy-tiles { display: grid; grid-template-columns: 1fr 1fr; diff --git a/src/routes/strategies/StrategyDataSummary.svelte b/src/routes/strategies/StrategyDataSummary.svelte index 466b5b7c8..6d5d1e438 100644 --- a/src/routes/strategies/StrategyDataSummary.svelte +++ b/src/routes/strategies/StrategyDataSummary.svelte @@ -1,7 +1,7 @@