diff --git a/frontend/src/TVMode.css b/frontend/src/TVMode.css index 16a64e5..d030d6a 100644 --- a/frontend/src/TVMode.css +++ b/frontend/src/TVMode.css @@ -55,5 +55,5 @@ span { gap: 30px; } .voting { - margin: auto; + margin: 15%; } \ No newline at end of file diff --git a/frontend/src/TVMode.tsx b/frontend/src/TVMode.tsx index 0435f43..e94c276 100644 --- a/frontend/src/TVMode.tsx +++ b/frontend/src/TVMode.tsx @@ -1,7 +1,7 @@ import { CSSProperties, useEffect, useState } from 'react'; import './TVMode.css'; import './Client.css'; -import { buttonTypeList, WGPPState } from './types'; +import { ButtonType, buttonTypeList, WGPPState } from './types'; const TVMode = () => { @@ -38,6 +38,7 @@ const TVMode = () => { }, []) const totalCount = buttonTypeList.reduce((acc, v) => (state?.votes?.[v]??0) + acc, 0); + const voteList = buttonTypeList.map(b => [b, state?.votes?.[b] ?? 0] as [ButtonType, number]); return