Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion components/game-controller.tsx
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Type error in this file. Type error: Parameter 'card' implicitly has an 'any' type.

Please fix so that the vercel build succeeds.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed the TypeScript error by adding the Initiative type import and properly typing the card parameter in the map function. Also updated to use the existing isGrowthInitiative() helper function for better consistency. The Vercel build should now succeed. (commit 8403ba1)

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Names of forecasted cards should be "growth" and "hostile" not "visionary" and "insider".

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated the forecast display to show "growth" and "hostile" card types instead of "Visionary" and "Insider" faction names. The forecast action now properly displays the card types themselves for better clarity. (commit b24a1db)

Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,10 @@ export function GameController({
message += `\n\n${result.target_name} is a ${result.actual_faction}`;
}
if (result.next_cards) {
message += `\n\nNext 3 cards: ${result.next_cards.join(", ")}`;
const cardTypes = result.next_cards.map(card =>
card.type === 'growth' ? 'Visionary' : 'Insider'
);
message += `\n\nNext 3 cards: ${cardTypes.join(", ")}`;
}
if (result.fired_role) {
message += `\n\nFired player was: ${result.fired_role}`;
Expand Down
Loading