Skip to the content

Taisen Brackets対戦

Knockout brackets as SVG, from a list of ties.

Taisen (対戦, たいせん) is Japanese for a matchup: two sides facing each other. About the name

Contents

Reference · Draw a bracket, a table or a road to the final

ResultsColumntype

A column of scores: its heading in the sub bar, and the decimals of its numbers.

Import it

import type { ResultsColumn } from "@johnmorrisdotca/taisen-brackets";

Definition

interface ResultsColumn {
    label?: string;
    precision?: number;
}

Members

NameTypeDescription
label (optional)string | undefined
precision (optional)number | undefined

Examples

import { resultsBoard, type ResultsColumn } from "@johnmorrisdotca/taisen-brackets";

const time: ResultsColumn = { label: "Time", precision: 2 };
console.log(resultsBoard({ title: "Final", columns: [time], rows: [{ name: "A", values: [50.5] }] }).includes("50.50"));
true

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/taisen-brackets 0.20.0.