Security News
Bun 1.2 Released with 90% Node.js Compatibility and Built-in S3 Object Support
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
@loadsmart/miranda-tokens
Advanced tools
This package uses Style Dictionary under the hood to manage the base tokens, and offers a set of tools built on top of the processed tokens to allow them to be consume from Javascript-based styling.
Our tokens are structured inside the src/tokens folder.
...
tokens
│
|- brands
│ │
│ |-──brand-1
│ │ │
│ │ │ color.js // { brand: { color: { primary: { value: 'red' } } } }
│ │
│ └───brand-2
│ │
│ │ color.js // { brand: { color: { primary: { value: 'green' } } } }
│
|- platforms
│ │
│ |-──platform-1
│ │ │
│ │ │ font.js // { platform: { font: { family: { value: 'Verdana' } } } }
│ │
│ └───platform-2
│ │
│ │ font.js // { platform: { font: { family: { value: 'Roboto' } } } }
│
|- globals
│ │
│ |-color
│ │ │
│ │ │ index.js // { color: { primary: { value'{brand.color.primary.value}' } } }
│ │
│ |-font
│ │
│ │ index.js // { font: { family: { value'{platform.font.family.value}' } } }
│
...
First evaluate if your token should be brand or platform specific:
If yes, the new token is brand or platform specific: 1.1. Add the new token under the existing category (font, color, spacing, etc) file, or add a new file to represent the new category in the respective brand or platform folder. 1.2. Likewise, add the equivalent token for the other brands or platforms.
If no, the new token is not brand or platform specific: 2.1. Add the token under the existing category under the globals folder
After that, to generate the updated base theme, run:
yarn build-tokens
You should see something like this output:
Build started...
Processing canonical theme
web
✔︎ src/themes/base.theme.js
Processing: [web] [loadsmart]
web
✔︎ dist/tokens/web/loadsmart/variables.css
✔︎ dist/tokens/web/loadsmart/variables.scss
✔︎ dist/tokens/web/loadsmart/index.js
End processing
FAQs
Design tokens for the Miranda Design System
The npm package @loadsmart/miranda-tokens receives a total of 211 weekly downloads. As such, @loadsmart/miranda-tokens popularity was classified as not popular.
We found that @loadsmart/miranda-tokens demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.