diff --git a/package-lock.json b/package-lock.json index 1de28b4e..187de65b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -75,7 +75,7 @@ "svelte-intersection-observer": "^1.0.0", "svelte-intersection-observer-action": "^0.0.5", "svelte-inview": "^4.0.2", - "svelte-lazy": "^1.2.7", + "svelte-lazy": "^1.2.11", "svelte-lightweight-charts": "^2.2.0", "svelte-loading-spinners": "^0.3.6", "svelte-preprocess": "^5.1.4", @@ -8205,12 +8205,13 @@ } }, "node_modules/svelte-lazy": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/svelte-lazy/-/svelte-lazy-1.2.7.tgz", - "integrity": "sha512-TvOP22pNsSKlCRsQIZ9mv1IAaEhSZFhezzhMO/kYuKUvX9VQALJvWHV5MOymn/pjeTeVuT4lE9g9y40uf0bNSw==", + "version": "1.2.11", + "resolved": "https://registry.npmjs.org/svelte-lazy/-/svelte-lazy-1.2.11.tgz", + "integrity": "sha512-VVrkn5eMLgAHSZlZrApR675MqQACqlA1pWEI7rDi9kQ3GTsyXEaMjwFpzddnNsNWV4B0Tvd1pZHplQgFiBqPfg==", "dev": true, + "license": "UNLICENSE", "peerDependencies": { - "svelte": "^3.0.0 || ^4.0.0" + "svelte": "^3.0.0 || ^4.0.0 || ^5.0.0" } }, "node_modules/svelte-lightweight-charts": { diff --git a/package.json b/package.json index c63a9cc3..d503a94c 100644 --- a/package.json +++ b/package.json @@ -74,7 +74,7 @@ "svelte-intersection-observer": "^1.0.0", "svelte-intersection-observer-action": "^0.0.5", "svelte-inview": "^4.0.2", - "svelte-lazy": "^1.2.7", + "svelte-lazy": "^1.2.11", "svelte-lightweight-charts": "^2.2.0", "svelte-loading-spinners": "^0.3.6", "svelte-preprocess": "^5.1.4", diff --git a/src/lib/components/AnalystEstimate.svelte b/src/lib/components/AnalystEstimate.svelte index 378cada2..f4e6f934 100644 --- a/src/lib/components/AnalystEstimate.svelte +++ b/src/lib/components/AnalystEstimate.svelte @@ -1,6 +1,6 @@ -
-

{title} Forecast

-
-
- {#if options !== null} - - {/if} -
-
- - - {#each tableDataList as date, index} - +

{title} Forecast

+
+
+ {#if options !== null} + + {/if} +
+
+
{title} - {#if index !== 0}{date}{/if}
+ - {/each} - - - {#each highDataList as item, index} - + {/each} + + + {#each highDataList as item, index} + - {/each} - - {#each avgDataList as item, index} - + {/each} + + {#each avgDataList as item, index} + - {/each} - - {#each lowDataList as item, index} - + {/each} + + {#each lowDataList as item, index} + - {/each} - -
{title}
High - {#if index !== 0} - {#if userTier !== "Pro" && index >= highDataList?.length - 2} - Pro - {:else} - {abbreviateNumber(item?.val)} + {#each tableDataList as date, index} + + {#if index !== 0}{date}{/if}
High + {#if index !== 0} + {#if userTier !== "Pro" && index >= highDataList?.length - 2} + Pro + {:else} + {abbreviateNumber(item?.val)} + {/if} {/if} - {/if} -
Avg - {#if index !== 0} - {#if userTier !== "Pro" && index >= avgDataList?.length - 2} - Pro - {:else} - {abbreviateNumber(item?.val)} +
Avg + {#if index !== 0} + {#if userTier !== "Pro" && index >= avgDataList?.length - 2} + Pro + {:else} + {abbreviateNumber(item?.val)} + {/if} {/if} - {/if} -
Low - {#if index !== 0} - {#if userTier !== "Pro" && index >= lowDataList?.length - 2} - Pro - {:else} - {abbreviateNumber(item?.val)} +
Low + {#if index !== 0} + {#if userTier !== "Pro" && index >= lowDataList?.length - 2} + Pro + {:else} + {abbreviateNumber(item?.val)} + {/if} {/if} - {/if} -
+ + {/each} + + +
- +{:else} +
+

{title}

+
+
+ {#if options !== null} + + {/if} +
+
+ + + {#each tableDataList as date, index} + + {/each} + + + {#each computeGrowthSingleList(highDataList, avgDataList) as item, index} + + {/each} + + {#each avgGrowthList?.filter((item) => item.FY >= 24) as item, index} + + {/each} + + {#each computeGrowthSingleList(lowDataList, avgDataList) as item, index} + + {/each} + +
{title}{#if index !== 0}{date}{/if}
High + {#if index !== 0} + {#if userTier !== "Pro" && index >= highDataList?.length - 2} + Pro + {:else} + 0 + ? "text-[#00FC50] before:content-['+']" + : item?.growth < 0 + ? "text-[#FF2F1F]" + : "text-white"} + > + {item?.growth !== null && Math.abs(item?.growth - 0) > 0 + ? abbreviateNumber(item?.growth) + "%" + : "-"} + + {/if} + {/if} +
Avg + {#if index !== 0} + {#if userTier !== "Pro" && index >= avgDataList?.length - 2} + Pro + {:else} + 0 + ? "text-[#00FC50] before:content-['+']" + : item?.growth < 0 + ? "text-[#FF2F1F]" + : "text-white"} + > + {item?.growth !== null && Math.abs(item?.growth - 0) > 0 + ? abbreviateNumber(item?.growth) + "%" + : "-"} + + {/if} + {/if} +
Low + {#if index !== 0} + {#if userTier !== "Pro" && index >= lowDataList?.length - 2} + Pro + {:else} + 0 + ? "text-[#00FC50] before:content-['+']" + : item?.growth < 0 + ? "text-[#FF2F1F]" + : "text-white"} + > + {item?.growth !== null && Math.abs(item?.growth - 0) > 0 + ? abbreviateNumber(item?.growth) + "%" + : "-"} + + {/if} + {/if} +
+
+
+
+{/if}