Skip to the content

Fuda Cards札

Collectible card frames for images and live 3D: a true thickness, an edge, foil, stacks, wear and a binder, as two web components.

Fuda is the Japanese word 札 for a card or a tag. About the name

Contents

Reference

Options, materials, stacks and wear

import { … } from "@johnmorrisdotca/fuda-cards";

Exports

NameKindWhat it is
cardAttributesfunctionThe attributes of a <fuda-card> for these options, ready to set one by one (element.setAttribute(name, value)): names are the kebab-case of the option's, a true boolean is the empty string (the attribute is present) and a false one, like anything that is undefined or null, is left out.
CardFinishtypeA card's finish: foil catches the light and shows a rainbow in its frame, matte does not.
cardFinishesconstantThe two finishes, foil and matte.
cardMaterialfunctionThe material with this id.
CardMaterialtypeA card material: a stock or a metal with a thickness read from a maker or a standard, and the colour its edge is drawn in.
CardMaterialGrouptypeThe kind of stock a material is: plain paper card, plastic, a thick trading-card stock or metal.
cardMaterialsconstantEvery material the package knows, each with a thickness and the page it was read from.
CardMaterialSourcetypeWhere a number was read: the maker's or the standard's page, and what it says there.
CardOptionstypeEvery setting of <fuda-card> as an object.
CardVarianttypeA card's look: classic gold, silver sport or cosmic violet.
cardVariantsconstantThe three looks, in the order the studio offers them.
CornerKindtypeHow a corner is worn: sharp, softened, rounded, chipped or folded.
DEFAULT_CARD_THICKNESS_MMconstantThe thickness of a card that names no material or thickness: a playing card's black-core stock, 13 pt, 0.325 mm (Qin Printing, Black Core Paper 310 gsm, 0.325 mm).
mmPerPointconstantOne thousandth of an inch ("pt" in card and paper trade talk) in millimetres, 0.0254: a 13 pt card is 13 × 0.0254 mm.
stackHeightMmfunctionThe height of a stack of cards, in millimetres: the count times the thickness of one, to a thousandth of a millimetre.
stackLayoutfunctionWhere the cards of a stack lie, from neat to messy, the same every time for the same seed: the cards under the top one, bottom first, at most depth of them, as the top card is the live one and lies square.
StackLayoutOptionstypeHow a stack is laid out: how messy, from which seed and how many cards deep.
StackPlacetypeWhere one card of a stack lies, as the stack's layout says: how far it is nudged across and down, in card widths, and how far it is turned.
StackPresettypeA count of cards for a stack, with where the number comes from: a deck of 52, a Pokémon deck of 60, a booster pack of about 10.
stackPresetsconstantThe usual sizes of a stack of cards, each with where the number comes from.
VERSIONconstantThe version of this package, the same as package.json's (a test holds the two together).
WearCornertypeOne corner of a worn card: how it is worn and how far the damage reaches.
WearFeaturestypeEvery mark of a worn card: its corners, its centring, and the creases, scratches, specks and stain of each face.
wearLayoutfunctionWhere every mark of a card lies.
wearLevelsfunctionThe levels a card's wear asks for: the grade's or the number's, with any level named on its own laid over them.
WearLevelstypeHow much of each kind of wear, from 0 (none) to 1 (the worst the preset names).
WearOptionstypeWhat a card asks of its wear: a grade or a number, a seed, and any level on its own.
wearOutlinefunctionThe outline of a face as an SVG path in the 250 by 350 box, corners as worn.
wearOverlaySvgfunctionThe SVG laid over one face: whitening, folds, creases, scratches, specks, stain and toning.
wearPresetfunctionThe grade with this id.
WearPresettypeA grading term with the levels it stands for and what it means in a few words.
wearPresetsconstantThe seven grades, from perfect to damaged.

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/fuda-cards 0.11.0.