From ae69e75b9605ba2219bed69ff90c39bc29ed25a9 Mon Sep 17 00:00:00 2001 From: MuslemRahimi Date: Wed, 26 Feb 2025 01:26:12 +0100 Subject: [PATCH] update ratings chart --- src/lib/components/RatingsChart.svelte | 372 +++++++++++---------- src/routes/politicians/[slug]/+page.svelte | 20 +- 2 files changed, 201 insertions(+), 191 deletions(-) diff --git a/src/lib/components/RatingsChart.svelte b/src/lib/components/RatingsChart.svelte index 818697ba..16f0b78c 100644 --- a/src/lib/components/RatingsChart.svelte +++ b/src/lib/components/RatingsChart.svelte @@ -1,23 +1,7 @@ -
- {#if isLoaded && optionsData !== null} +
+ {#if isLoaded && config !== null} {#if historicalData?.length > 0} -
-
+
+
{#each ["1Y", "3Y", "5Y", "Max"] as item, index} {#if data?.user?.tier === "Pro" || index === 0}
-

- {symbol} - {numOfRatings} - {title} -

-
+
{:else}
{/if}
- - diff --git a/src/routes/politicians/[slug]/+page.svelte b/src/routes/politicians/[slug]/+page.svelte index 8e619c65..5be03ce0 100644 --- a/src/routes/politicians/[slug]/+page.svelte +++ b/src/routes/politicians/[slug]/+page.svelte @@ -109,13 +109,13 @@ />
Main Sectors:
@@ -265,9 +265,11 @@
{/if} -
+

Trading History

+ +