Reference · Draw a bracket, a table or a road to the final
boutBoardSizefunction
The width and the height of a bout board with officialCount officials: the width given (1280 by default) and a height of 64 + 38 + 10 + 62 + 10 + 38 + 42 an official + 10, in units of the width over 1280.
Import it
import { boutBoardSize } from "@johnmorrisdotca/taisen-brackets";
Definition
function boutBoardSize(officialCount: number, options?: Pick<BroadcastOptions, "width">): { width: number; height: number; }
Parameters
| Name | Type | Description |
|---|---|---|
officialCount | number | How many officials are listed. |
options (optional) | Pick<BroadcastOptions, "width"> | The |
Returns
{ width: number; height: number; }
The width and the height, in pixels.
Examples
import { boutBoardSize } from "@johnmorrisdotca/taisen-brackets";
console.log(boutBoardSize(3, { width: 960 }));{ width: 960, height: 269 }What it prints (run when this page was built)