|
|
@@ -1,5 +1,5 @@
|
|
|
<script setup>
|
|
|
-import { ref, computed, defineProps, defineEmits } from 'vue';
|
|
|
+import { ref, computed } from 'vue';
|
|
|
import dayjs from 'dayjs';
|
|
|
|
|
|
import MatchCard from './match_card.vue';
|
|
|
@@ -172,20 +172,16 @@ const switchSolution = (index) => {
|
|
|
}
|
|
|
};
|
|
|
|
|
|
-const topSolutions = computed(() => {
|
|
|
- return props.solutions.slice(0, 5);
|
|
|
-});
|
|
|
-
|
|
|
const currentIndex = computed(() => {
|
|
|
const index = selectedIndex.value;
|
|
|
- if (topSolutions.value[index]) {
|
|
|
+ if (props.solutions[index]) {
|
|
|
return index;
|
|
|
}
|
|
|
return 0;
|
|
|
});
|
|
|
|
|
|
const currentSolution = computed(() => {
|
|
|
- return topSolutions.value[currentIndex.value];
|
|
|
+ return props.solutions[currentIndex.value];
|
|
|
});
|
|
|
|
|
|
const currentRelation = computed(() => {
|
|
|
@@ -236,7 +232,7 @@ const hg = computed(() => {
|
|
|
<div class="league-name">{{ currentRelation.leagueName }}</div>
|
|
|
<div class="date-time">{{ currentRelation.dateTime }}</div>
|
|
|
<div class="switch-btns">
|
|
|
- <a href="javascript:;" v-for="(solution, index) in topSolutions" :key="index" :class="{ 'selected': index === currentIndex }" @click="switchSolution(index)">{{ solution.sol.win_average_rate ?? fixFloat(solution.sol.win_average / solution.sol.inner_base * 100) }}</a>
|
|
|
+ <a href="javascript:;" v-for="(solution, index) in solutions" :key="index" :class="{ 'selected': index === currentIndex }" @click="switchSolution(index)">{{ solution.sol.win_average_rate ?? fixFloat(solution.sol.win_average / solution.sol.inner_base * 100) }}</a>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="solution-content">
|