@@ -28,13 +28,13 @@ local DEFAULT_CARD = 'default'
2828local CustomMatchSummary = {}
2929
3030--- @param args table
31- --- @return Widget
31+ --- @return Renderable
3232function CustomMatchSummary .getByMatchId (args )
3333 return MatchSummary .defaultGetByMatchId (CustomMatchSummary , args )
3434end
3535
3636--- @param match MatchGroupUtilMatch
37- --- @return Widget []
37+ --- @return Renderable []
3838function CustomMatchSummary .createBody (match )
3939 local isTeamGame = Array .any (match .opponents , function (opponent ) return opponent .type == Opponent .team end )
4040 local games
5555--- @param game MatchGroupUtilGame
5656--- @param gameIndex integer
5757--- @param date string
58- --- @return Widget
58+ --- @return Renderable
5959function CustomMatchSummary ._createGame (game , gameIndex , date )
6060 local cardData = Array .map (game .opponents , function (opponent )
6161 return Array .map (opponent .players or {}, function (player )
@@ -91,7 +91,7 @@ function CustomMatchSummary._createGame(game, gameIndex, date)
9191end
9292
9393--- @param match MatchGroupUtilMatch
94- --- @return Widget []
94+ --- @return Renderable []
9595function CustomMatchSummary ._createTeamMatchBody (match )
9696 local _ , subMatches = Array .groupBy (match .games , Operator .property (' subgroup' ))
9797 subMatches = Array .map (subMatches , function (subMatch )
179179--- @param subMatchIndex integer
180180--- @param subMatch table
181181--- @param extradata table
182- --- @return Widget
182+ --- @return Renderable
183183function CustomMatchSummary ._createSubMatch (players , subMatchIndex , subMatch , extradata )
184184 -- Add submatch header
185185 local header
@@ -203,7 +203,7 @@ function CustomMatchSummary._createSubMatch(players, subMatchIndex, subMatch, ex
203203 :css (' text-align' , ' right' )
204204 :css (' width' , ' 40%' )
205205 :node (OpponentDisplay .BlockPlayers {
206- opponent = {players = players [1 ]},
206+ opponent = {players = players [1 ], type = ' solo ' , extradata = {} },
207207 overflow = ' ellipsis' ,
208208 showLink = true ,
209209 flip = true ,
@@ -230,7 +230,7 @@ function CustomMatchSummary._createSubMatch(players, subMatchIndex, subMatch, ex
230230 :css (' text-align' , ' left' )
231231 :css (' width' , ' 40%' )
232232 :node (OpponentDisplay .BlockPlayers {
233- opponent = {players = players [2 ]},
233+ opponent = {players = players [2 ], type = ' solo ' , extradata = {} },
234234 overflow = ' ellipsis' ,
235235 showLink = true ,
236236 flip = false ,
0 commit comments