Design Tokens Package
Paste Design System Tokens package with a number of different formats for Web, Mobile, and Sketch.
yarn add @twilio-paste/design-tokens
The Paste design tokens are available as a NPM package which acts as the central source of truth for Paste. By using this package correctly, you can rely on a well-maintained, up-to-date definition of Twilio's Design Language. A simple way to grab or view the latest files in this package is to visit UNPKG - @twilio-paste/design-tokens.
While the Paste Tokens Package supports the following formats, our roadmap currently prioritizes React Components and Sketch Libraries as primary deliverables of the Design System. Reach out to us at #help-design-system if you'd like to use Paste for another format: we'll help you out as much as we can!
Paste Design Tokens are supported in the following formats within this package:
- CSS custom properties
- Android XML
- iOS JSON
- Typescript definitions
- Sketch Palette
Paste supports multiple themes. This is done by exporting the same token formats for each theme. Each file in the root of the design tokens package is exported for each theme with the corresponding values updated for each token. This allows different parts of Twilio to have their own visual styles whilst still maintaining a consistent Twilio feel, coherent component behavior, and preventing Design System bloat. Here's an example of Themes:
|Paste (default) theme||Console theme||SendGrid theme|
|$color-brand-highlight: #F22F46||$color-brand-highlight: #F22F46||$color-brand-highlight: #3368FA|
|$font-weight-semibold: 600||$font-weight-semibold: 500||$font-weight-semibold: 600|
See our list of Tokens and their corresponding values in the Token List page.
Within themes, we presently have support for:
Give us Feedback on this Page#
As you use Paste, you'll likely encounter things that don't seem right. Please reach out with your feedback! Here's some prompts to consider:
- Is this page easy for me to consume?
- Is the information supporting it sufficient / well-described?
- What information is missing?
- How approachable is the documentation? Can a new engineer / PM / designer at Twilio get started with it easily?
All notable changes to this project will be documented in this file. See Conventional Commits for commit guidelines.
- design-token: add new status tokens (462f471)
- design-tokens: create paste and console themes (d550e4e)
- design-tokens: Move the default theme values to be the console theme Make the default theme the Paste theme based on new unified design language
- design-tokens: change color-text-link token values (#172) (f0a215c)
- design-tokens: update lightest console color palette (#174) (98b625c)
- correct button heights add new default icon size (#186) (2e54478)
- design-tokens: update some blues, reds, and focus shadow (#185) (98d70cc)
Note: Version bump only for package @twilio-paste/design-tokens
- icons: delete old icons, add new streamline icons (#129) (571791d)
- typography: heading component (#149) (4e033e6)
- icons: removed all the inherited icons since we're moving to a new system
- design-tokens: fix SendGrid token values (#71) (396fccf)
- design-tokens: typo on word
- tokens: correct the box shadow tokens category and type (#95) (fe0f946)
- design-tokens: resolve path correctly (6f89111)
- tokens: added missing SG token values (#22) (23d7385)
- change @paste scope to @twilio-paste (#2) (1d8d2ff)
- run eslint across the right files and fix any issues that arise. (#21) (2fcc872)
- swap light/dark border token colors (0a99d3c)
- Type-checking fixes (#12) (be02450)