table fix

This commit is contained in:
MuslemRahimi 2024-09-13 20:37:21 +02:00
parent f6929ec641
commit 6c9c286fdb
2 changed files with 6 additions and 7 deletions

View File

@ -550,7 +550,7 @@ function calculateStats(data) {
return acc; return acc;
}, { callVolumeSum: 0, putVolumeSum: 0, bullishCount: 0, bearishCount: 0, neutralCount: 0 }); }, { callVolumeSum: 0, putVolumeSum: 0, bullishCount: 0, bearishCount: 0, neutralCount: 0 });
if (bullishCount > bearishCount) { if (bullishCount >= bearishCount) {
flowSentiment = 'Bullish'; flowSentiment = 'Bullish';
} else if (bullishCount < bearishCount) { } else if (bullishCount < bearishCount) {
flowSentiment = 'Bearish'; flowSentiment = 'Bearish';
@ -561,7 +561,6 @@ function calculateStats(data) {
} }
putCallRatio = callVolumeSum !== 0 ? (putVolumeSum / callVolumeSum) : 0; putCallRatio = callVolumeSum !== 0 ? (putVolumeSum / callVolumeSum) : 0;
callPercentage = (callVolumeSum+putVolumeSum) !== 0 ? Math.floor((callVolumeSum)/(callVolumeSum+putVolumeSum)*100) : 0; callPercentage = (callVolumeSum+putVolumeSum) !== 0 ? Math.floor((callVolumeSum)/(callVolumeSum+putVolumeSum)*100) : 0;
@ -884,7 +883,7 @@ $: {
<DropdownMenu.Item class="sm:hover:bg-[#27272A]"> <DropdownMenu.Item class="sm:hover:bg-[#27272A]">
<div class="flex items-center" on:click|capture={(event) => event.preventDefault()}> <div class="flex items-center" on:click|capture={(event) => event.preventDefault()}>
<label on:click={() => {handleChangeValue(item)}} class="cursor-pointer text-white" for={item}> <label on:click={() => {handleChangeValue(item)}} class="cursor-pointer text-white" for={item}>
<input type="checkbox" checked={isChecked(item)}> <input type="checkbox" class="rounded" checked={isChecked(item)}>
<span class="ml-2">{item}</span> <span class="ml-2">{item}</span>
</label> </label>
</div> </div>
@ -1242,7 +1241,7 @@ $: {
<div class="flex flex-col w-full mt-10 sm:mt-0"> <div class="flex flex-col w-full mt-10 sm:mt-0">
<div class="text-white text-3xl font-semibold mb-5"> <div class="text-white text-xl sm:text-3xl font-semibold mb-5">
Add Filters Add Filters
</div> </div>
@ -1285,7 +1284,7 @@ $: {
<!-- head --> <!-- head -->
<tbody> <tbody>
{#each (searchTerm?.length !== 0 ? filteredRows : allRows) as row, index} {#each (searchTerm?.length !== 0 ? filteredRows : allRows) as row, index}
<tr on:click={() => changeRule(row?.rule)} class="hover:bg-[#333333] cursor-pointer"> <tr on:click={() => changeRule(row?.rule)} class="sm:hover:bg-[#333333] cursor-pointer">
<td class="border-b border-[#262626]">{index+1}</td> <td class="border-b border-[#262626]">{index+1}</td>
<td class="text-start border-b border-[#262626]"> <td class="text-start border-b border-[#262626]">
{#if ruleOfList.find((rule) => rule?.name === row?.rule)} {#if ruleOfList.find((rule) => rule?.name === row?.rule)}

View File

@ -1219,7 +1219,7 @@ function handleInput(event) {
<div class="flex flex-col w-full mt-10 sm:mt-0"> <div class="flex flex-col w-full mt-10 sm:mt-0">
<div class="text-white text-3xl font-semibold mb-5"> <div class="text-white text-xl sm:text-3xl font-semibold mb-5">
Add Filters Add Filters
</div> </div>
@ -1262,7 +1262,7 @@ function handleInput(event) {
<!-- head --> <!-- head -->
<tbody> <tbody>
{#each (searchTerm?.length !== 0 ? filteredRows : allRows) as row, index} {#each (searchTerm?.length !== 0 ? filteredRows : allRows) as row, index}
<tr on:click={() => changeRule(row?.rule)} class="hover:bg-[#333333] cursor-pointer"> <tr on:click={() => changeRule(row?.rule)} class="sm:hover:bg-[#333333] cursor-pointer">
<td class="border-b border-[#262626]">{index+1}</td> <td class="border-b border-[#262626]">{index+1}</td>
<td class="text-start border-b border-[#262626]"> <td class="text-start border-b border-[#262626]">
{#if ruleOfList.find((rule) => rule?.name === row?.rule)} {#if ruleOfList.find((rule) => rule?.name === row?.rule)}