@@ -4,6 +4,8 @@ import Tooltip from "../tooltip.vue";
44import {percentClass } from " ../shared" ;
55import {RuntimeTestCase } from " ./common" ;
66import {computed } from " vue" ;
7+ import Accordion from " ../../../components/accordion.vue" ;
8+ import {testCaseKey } from " ./common" ;
79
810const props = defineProps <{
911 comparisons: TestCaseComparison <RuntimeTestCase >[];
@@ -66,52 +68,55 @@ const unit = computed(() => {
6668 </thead >
6769 <tbody >
6870 <template v-for =" comparison in comparisons " >
69- <tr >
70- <td >
71- {{ comparison.testCase.benchmark }}
72- </td >
73- <td >
74- <div class =" numeric-aligned" >
75- <div >
76- <span v-bind:class =" percentClass(comparison.percent)" >
77- {{ comparison.percent.toFixed(2) }}%
78- </span >
71+ <Accordion :id =" testCaseKey(comparison.testCase)" >
72+ <template v-slot :default >
73+ <td >
74+ {{ comparison.testCase.benchmark }}
75+ </td >
76+ <td >
77+ <div class =" numeric-aligned" >
78+ <div >
79+ <span v-bind:class =" percentClass(comparison.percent)" >
80+ {{ comparison.percent.toFixed(2) }}%
81+ </span >
82+ </div >
7983 </div >
80- </div >
81- </ td >
82- < td >
83- <div class = " numeric-aligned " >
84- < div >
85- {{
86- comparison.significanceThreshold
87- ? comparison.significanceThreshold.toFixed(2) + "% "
88- : "-"
89- }}
84+ </td >
85+ < td >
86+ < div class = " numeric-aligned " >
87+ <div >
88+ {{
89+ comparison.significanceThreshold
90+ ? comparison.significanceThreshold.toFixed(2) + "%"
91+ : "- "
92+ }}
93+ </ div >
9094 </div >
91- </div >
92- </ td >
93- < td >
94- <div class = " numeric-aligned " >
95- < div >
96- {{
97- comparison.significanceFactor
98- ? comparison.significanceFactor.toFixed(2) + "x "
99- : "-"
100- }}
95+ </td >
96+ < td >
97+ < div class = " numeric-aligned " >
98+ <div >
99+ {{
100+ comparison.significanceFactor
101+ ? comparison.significanceFactor.toFixed(2) + "x"
102+ : "- "
103+ }}
104+ </ div >
101105 </div >
102- </div >
103- </td >
104- <td v-if =" showRawData" class =" numeric" >
105- <abbr :title =" comparison.datumA.toString()"
106- >{{ prettifyRawNumber(comparison.datumA) }}{{ unit }}</abbr
107- >
108- </td >
109- <td v-if =" showRawData" class =" numeric" >
110- <abbr :title =" comparison.datumB.toString()"
111- >{{ prettifyRawNumber(comparison.datumB) }}{{ unit }}</abbr
112- >
113- </td >
114- </tr >
106+ </td >
107+ <td v-if =" showRawData" class =" numeric" >
108+ <abbr :title =" comparison.datumA.toString()"
109+ >{{ prettifyRawNumber(comparison.datumA) }}{{ unit }}</abbr
110+ >
111+ </td >
112+ <td v-if =" showRawData" class =" numeric" >
113+ <abbr :title =" comparison.datumB.toString()"
114+ >{{ prettifyRawNumber(comparison.datumB) }}{{ unit }}</abbr
115+ >
116+ </td >
117+ </template >
118+ <template v-slot :collapsed > </template >
119+ </Accordion >
115120 </template >
116121 </tbody >
117122 </table >
@@ -122,6 +127,7 @@ const unit = computed(() => {
122127.benches {
123128 font-size : medium ;
124129 table-layout : fixed ;
130+ border-collapse : collapse ;
125131
126132 td ,
127133 th {
0 commit comments