Bridge Craftwork › Docs › Convention card

Convention card

Build and edit your partnership’s convention card in the browser. Import a card from BBO, Bridgodex or BBA, then print it on the ACBL card. You don’t need an account, and your cards stay on your own computer.

Getting started

  1. Open the editor. It starts with a sample card, 2/1 Intermediate. The sample can’t be changed, so it’s always there to start from.
  2. Click Duplicate to make your own copy, or New for a blank card, or Import to bring in a card you already have (below).
  3. Click Edit. Pick a section on the left (notrump openings, slam bidding, carding and so on) and tick the conventions you play. Each section also has room for notes.
  4. Click Save.

The level buttons at the top (Basic, Intermediate, Advanced, Expert) set how far up the list goes. Basic shows only the most common conventions, and Expert shows all of them. A convention you have ticked is always listed, whatever the level.

Where your cards are kept

Your cards are saved in this browser, on this computer. There is no account and nothing is uploaded. That also means:

To keep a copy, use Export Content → Bridge Classroom JSON and save the file somewhere safe. Import reads it back exactly.

To keep a card with an account, click Save to Bridge Classroom. It opens Bridge Classroom with your card, and Bridge Classroom saves it there once you sign in.

Importing a card

Click Import and choose the file. The editor works out what kind of file it is.

Where it came fromThe file
This editor, or Bridge ClassroomThe .json from Export Content
A PDF this editor printedThe .pdf. The card is stored inside the PDF, so it comes back complete.
BBOThe convention card’s JSON export
BridgodexThe card’s JSON export
BBA (Bridge Bidding Analyser)The .bbsa convention file

If you already have a card with the same name, the editor asks whether to replace it or keep both.

Printing and exporting

Sending a card by link

A link can carry a whole card. When someone opens it, the card is added to the cards in their browser and opened. The card is in the part of the address after #, which browsers never send to a server.

https://bridge-craftwork.com/card/#import=v1.…

Other tools use these links to hand a card over. For example, the Better BBO Convention Card browser extension will use one to open a BBO card here.

For programs and assistants

/card/reference.txt lists every field a card can hold (its path, values, default and older names), every convention (its ID, level and a short summary) and the program interface below. It is plain text, generated from the same spec the editor reads. If a field isn’t in it, it isn’t a card field. /card/llms.txt is a short index.

window.card

The editor page provides the interface every Bridge Craftwork tool shares. Methods return promises, except getInput.

MethodWhat it does
run(input, params)Reads a card and converts it to params.to. Returns { ok, from, name, output, diagnostics }.
validate(input, params)Reads and checks a card without converting it.
getInput()The card open in the editor, unsaved edits included.
setInput(input, params)Adds a card to the browser’s cards and opens it.
getOutput(params)The open card, converted to params.to.

input can be any format Import reads: JSON as an object or text, .bbsa text, a PDF’s bytes, or an #import= link. params.to is one of card (the export JSON), card_data, bbsa, pdf-classic, pdf-new, pdf-drawn, link or bridge-classroom. Each diagnostic is { severity, message, path, hint }, where path names the field it is about.

const r = await window.card.run(bbsaText, { name: 'Our card', to: 'pdf-classic' })
if (!r.ok) console.log(r.diagnostics)

The library

The converters, the PDF export and the card check are a plain JavaScript library with no framework and no network access. It runs in a page, a browser extension or Node. There is also a Rust crate. Both live in bridge-craftwork/convention-card. Depend on the repository at a tagged version, since there are no npm or crates.io packages.

Bridge Craftwork · free & open source · source