goldenratio.app

v0.1.1
app.goldenratio/mcp Checked 3 days ago Published 28 days ago

Golden-ratio design math: spacer calculator, spacing scale, grid widths, CSS vars, Tailwind setup.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

golden_calculator Golden Calculator

The goldenratio.app Golden Calculator. Stack spacers numbered 1-11 (each is the previous x 1.618) on a left and a right side; returns whether both sides are equal and, if not, every combination of spacers that would make the shorter side match ("Try" on the site). The site starts with left = [6, 5, 6], right = [].

ParameterTypeDescription
leftarraySpacer numbers stacked on the left, top to bottom, e.g. [6, 5, 6].
rightarraySpacer numbers stacked on the right.

golden_spacing Golden spacing scale

The golden spacing scale (spacers 1-11 plus half-N and double-N) with exact values, px and CSS variable names, as used by goldenratio.app and the tailwindcss-golden-ratio plugin. With default options it also returns the rounded cheatsheet table from goldenratio.app/#/spacing.

ParameterTypeDescription
prefixPlugin prefix option, only changes tailwind_key (true = "gr-").
root_font_pxnumberRoot font size for px conversion of rem/em values (default 16).
spacer_basenumbertheme.goldenRatio.spacerBase: the size of spacer 6 (default 1.5, as on goldenratio.app).
spacer_unitstringtheme.goldenRatio.spacerUnit (default 'rem').

golden_grid Golden grid

The golden grid from goldenratio.app/#/grid: w-grp-1..11, w-grp-half-*, w-grp-double-* percentage widths, the starter .container/.row CSS, every example row from the site with its total width, and an optional check of your own row (does it add up to exactly 100%?).

ParameterTypeDescription
container_pxnumberAlso give each width in px for a row this wide.
include_examplesbooleanInclude the site example rows (default true).
rowarrayWidths to check as one row, e.g. ["5", "4"] or ["half-4", "5", "half-4"] (w-grp- prefix optional).

golden_css_variables Golden CSS variables

The :root block of golden-ratio CSS variables (--golden-ratio-1..11, half-*, double-*, --gr) exactly as goldenratio.app ships it. Use without Tailwind.

ParameterTypeDescription
formatstringcss (default, readable), min (one line, as in the site stylesheet) or json.
spacer_basenumbertheme.goldenRatio.spacerBase: the size of spacer 6 (default 1.5, as on goldenratio.app).
spacer_unitstringtheme.goldenRatio.spacerUnit (default 'rem').

tailwind_plugin_setup tailwindcss-golden-ratio setup

How to add the tailwindcss-golden-ratio plugin (the one goldenratio.app uses): install command, tailwind.config.js, options, and the exact theme values it generates (spacing, grp widths, scale, fontSize extras, borderWidth/lineHeight) for the given options.

ParameterTypeDescription
prefixtheme.goldenRatio.prefix (true = "gr-").
spacer_basenumbertheme.goldenRatio.spacerBase: the size of spacer 6 (default 1.5, as on goldenratio.app).
spacer_unitstringtheme.goldenRatio.spacerUnit (default 'rem').
use_css_varsbooleantheme.goldenRatio.useCssVars (default true).

golden_ratio_steps Golden ratio steps

Step any number up or down the golden ratio (x or / 1.61803398875), e.g. to pick a type scale or the next size. What the goldenratio.app Alfred workflow does.

ParameterTypeDescription
value *numberStarting value, e.g. 16.
steps_downintegerSteps below the value (default 5).
steps_upintegerSteps above the value (default 5).
unitstringUnit suffix for the text column, e.g. "px".