2.1.1 • Published 3 years ago

@spartanbio/schedio-tokens v2.1.1

Weekly downloads
190
License
MIT
Repository
github
Last release
3 years ago

Schédio design tokens

Built for with Theo for @spartanbio/schedio.

A full list of tokens is available at https://spartanbio-ux.gitlab.io/schedio-tokens/.

Installation

yarn add @spartanbio/schedio-tokens

Tokens are organized with the path structure dist/<platform>/<language>/<token>.<format>.<ext>

Usage

These formats can be applied to every type of token, not just the master list.

i.e.:

// Importing raw colors from JSON
import { props as colors } from '@spartanbio/schedio-tokens/dist/web/raw-json/colors.raw.json'

JS

Examples use JSON, but Common JS modules are available in dist/web/common-js.

Common JS:

// camelCase tokens
const schedioTokens = require('@spartanbio/schedio-tokens')
// kebab-case tokens with meta data
const {
  props: schedioTokens
} = require('@spartanbio/schedio-tokens/dist/web/raw-json/tokens.raw.json')

ES6 Modules:

// camelCase tokens
import * as schedioTokens from '@spartanbio/scedio-tokens'
// kebab-case tokens with meta data
import { props as schedioTokens } from '@spartanbio/schedio-tokens/dist/web/raw-json/tokens.raw.json'

SCSS

All variables and keys are kebab-case.

// All tokens as variables
@import '~@spartanbio/schedio/dist/web/scss/tokens';

// All tokens as a map
@import '~@spartanbio/schedio/dist/web/scss/tokens.map';

// All tokens as custom properties (works for CSS too)
@import '~@spartanbio/schedio/dist/web/css/tokens.custom-properties';

// Unprefixed maps of specific token categories
@import '~@spartanbio/schedio/dist/web/scss/<token-category>.map';

// Colors, grouped by hue
@import '~@spartanbio/schedio/dist/web/scss/colors.color-map';

Flutter

Only color swatches are supported at this time. Copy dist/flutter/dart/colors.color-swatches.dart into your project.

Adobe Creative Cloud Applications

CC applications that support swatch files can import dist/web/adobe/colors.ase to use colors. Note they are imported without groups.

3.0.0-alpha.5

3 years ago

3.0.0-alpha.4

3 years ago

3.0.0-alpha.3

3 years ago

3.0.0-alpha.2

3 years ago

2.1.1

3 years ago

3.0.0-alpha.1

3 years ago

2.1.1-alpha.1

3 years ago

2.1.0

4 years ago

2.1.0-alpha.4

4 years ago

2.1.0-alpha.3

4 years ago

2.1.0-alpha.2

4 years ago

2.1.0-alpha.1

4 years ago

2.0.1-alpha.1

4 years ago

2.0.0

4 years ago

2.0.0-alpha.11

4 years ago

2.0.0-alpha.12

4 years ago

2.0.0-alpha.10

4 years ago

2.0.0-alpha.9

4 years ago

2.0.0-alpha.8

4 years ago

2.0.0-alpha.7

4 years ago

2.0.0-alpha.6

4 years ago

2.0.0-alpha.5

4 years ago

2.0.0-alpha.4

4 years ago

2.0.0-alpha.3

4 years ago

2.0.0-alpha.2

4 years ago

2.0.0-alpha.1

4 years ago

1.2.0

4 years ago

1.1.1

4 years ago

1.1.0

4 years ago

1.0.0

4 years ago