Skip to content

Commit

Permalink
don't show ongoing game result
Browse files Browse the repository at this point in the history
  • Loading branch information
ornicar committed Sep 25, 2024
1 parent f4b42e7 commit b1ae81a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/view/side.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,10 @@ export const renderMoves = (ctrl: PgnViewer) =>
),
]);

const renderResultComment = (ctrl: PgnViewer) =>
ctrl.game.metadata.result ? [ h('comment.result',ctrl.game.metadata.result)] : [];
const renderResultComment = (ctrl: PgnViewer) => {
const res = ctrl.game.metadata.result;
return res && res != '*' ? [ h('comment.result',ctrl.game.metadata.result)] : [];
};

const emptyMove = () => h('move.empty', '...');
const indexNode = (turn: number) => h('index', `${turn}.`);
Expand Down

0 comments on commit b1ae81a

Please sign in to comment.