generators

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 8, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CSSGenerator

type CSSGenerator struct {
	// contains filtered or unexported fields
}

CSSGenerator generates CSS custom properties from design tokens

func NewCSSGenerator

func NewCSSGenerator() *CSSGenerator

NewCSSGenerator creates a new CSS variables generator

func (*CSSGenerator) Generate

func (g *CSSGenerator) Generate(tokens []design.Token) (string, error)

Generate generates CSS custom properties from design tokens

func (*CSSGenerator) Name

func (g *CSSGenerator) Name() string

Name returns the generator name

func (*CSSGenerator) SupportedFormats

func (g *CSSGenerator) SupportedFormats() []string

SupportedFormats returns supported output formats

type JSONGenerator

type JSONGenerator struct {
	// contains filtered or unexported fields
}

JSONGenerator generates JSON output from design tokens

func NewJSONGenerator

func NewJSONGenerator(pretty bool) *JSONGenerator

NewJSONGenerator creates a new JSON generator

func (*JSONGenerator) Generate

func (g *JSONGenerator) Generate(tokens []design.Token) (string, error)

Generate generates JSON from design tokens

func (*JSONGenerator) Name

func (g *JSONGenerator) Name() string

Name returns the generator name

func (*JSONGenerator) SupportedFormats

func (g *JSONGenerator) SupportedFormats() []string

SupportedFormats returns supported output formats

type SCSSGenerator

type SCSSGenerator struct {
	// contains filtered or unexported fields
}

SCSSGenerator generates SCSS variables from design tokens

func NewSCSSGenerator

func NewSCSSGenerator() *SCSSGenerator

NewSCSSGenerator creates a new SCSS variables generator

func (*SCSSGenerator) Generate

func (g *SCSSGenerator) Generate(tokens []design.Token) (string, error)

Generate generates SCSS variables from design tokens

func (*SCSSGenerator) Name

func (g *SCSSGenerator) Name() string

Name returns the generator name

func (*SCSSGenerator) SupportedFormats

func (g *SCSSGenerator) SupportedFormats() []string

SupportedFormats returns supported output formats

type TailwindGenerator

type TailwindGenerator struct {
	// contains filtered or unexported fields
}

TailwindGenerator generates Tailwind CSS configuration from design tokens

func NewTailwindGenerator

func NewTailwindGenerator() *TailwindGenerator

NewTailwindGenerator creates a new Tailwind config generator

func (*TailwindGenerator) Generate

func (g *TailwindGenerator) Generate(tokens []design.Token) (string, error)

Generate generates Tailwind config from design tokens

func (*TailwindGenerator) Name

func (g *TailwindGenerator) Name() string

Name returns the generator name

func (*TailwindGenerator) SupportedFormats

func (g *TailwindGenerator) SupportedFormats() []string

SupportedFormats returns supported output formats

type TypeScriptGenerator

type TypeScriptGenerator struct {
	// contains filtered or unexported fields
}

TypeScriptGenerator generates TypeScript constants from design tokens

func NewTypeScriptGenerator

func NewTypeScriptGenerator() *TypeScriptGenerator

NewTypeScriptGenerator creates a new TypeScript constants generator

func (*TypeScriptGenerator) Generate

func (g *TypeScriptGenerator) Generate(tokens []design.Token, format string) (string, error)

Generate generates TypeScript/JavaScript constants from design tokens

func (*TypeScriptGenerator) Name

func (g *TypeScriptGenerator) Name() string

Name returns the generator name

func (*TypeScriptGenerator) SupportedFormats

func (g *TypeScriptGenerator) SupportedFormats() []string

SupportedFormats returns supported output formats

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL