MCPcopy Create free account
hub / github.com/fontsource/fontsource / toggleVariableAxis

Function toggleVariableAxis

website/app/components/preview/toggles.ts:36–42  ·  view source on GitHub ↗
(
	axes: Record<string, boolean>,
	value: string | number,
)

Source from the content-addressed store, hash-verified

34 * variable entrypoints always include the weight axis.
35 */
36export const toggleVariableAxis = (
37 axes: Record<string, boolean>,
38 value: string | number,
39): Record<string, boolean> => ({
40 ...toggleKey(axes, value),
41 wght: true,
42});

Callers 3

handleActiveVariantFunction · 0.90
handleActiveFunction · 0.90
handleActiveVariantFunction · 0.90

Calls 1

toggleKeyFunction · 0.85

Tested by

no test coverage detected