eds 13.3.0
Install from the command line:
Learn more about npm packages
$ npm install @chanzuckerberg/eds@13.3.0
Install via package.json:
"@chanzuckerberg/eds": "13.3.0"
About this version
Education Design System (EDS) is a repository of presentational components used to build React-based products for Chan Zuckerberg Initiative.
First install the package.
# via npm
npm install --save @chanzuckerberg/eds
# or, if using Yarn
yarn add @chanzuckerberg/eds
Import the EDS stylesheet and tokens somewhere in your app root, e.g. an init.ts
or app.ts
file:
import '@chanzuckerberg/eds/index.css';
// optionally import EDS font faces
// import '@chanzuckerberg/eds/fonts.css';
We also surface an --eds-font-size-base
property to set your base rem
font size, eg:
html {
font-size: var(--eds-font-size-base); /* Resets the default pixel-to-rem ratio */
}
The EDS Tailwind theme provides EDS color tokens and screens. Import the tailwind config into the app's tailwind config and supply the content property for use:
const edsConfig.theme = require('@chanzuckerberg/eds/tailwind.config');
module.exports = {
content: ['./app/**/*.{ts,tsx,jsx,js}'],
theme: edsConfig.theme,
};
Refer to the tokens tailwind section for usage guidelines.
EDS also provides the tokens used in the internal styles, to use in any custom component recipes and designs. If using VSCode, you can set up the IDE to expose the token values and perform autocomplete:
- Install the CSS Var Complete VSCode extension
- Add the following setting to your user or workspace settings file
{
// ...rest of the settings here
"cssvar.files": [
"node_modules/@chanzuckerberg/eds/lib/index.css"
]
}
- Restart VSCode
Refer to the "EDS Token and Theme Tools" in the tokens documentation to learn about the optional tooling setup.
Import any of the components from the top-level package:
// Import components by name at the top of your file
import { Heading } from '@chanzuckerberg/eds';
and then use them in your React components:
<Heading variant="neutral-strong" size="h2">
Coffee!
</Heading>
EDS provides a suite of components for use, and documentation for available props and overrides.
This project is under active development. See CONTRIBUTING.md for more information on how to contribute to EDS. Also, read our guidelines for additional information.
Instead, if you want to report an issue, you can open an issue.
This project is governed under the Contributor Covenant code of conduct.
See our Security Readme.
Please review our Education Design System Site (SSO Required): /Paper
Details
- eds
- chanzuckerberg
- over 1 year ago
- MIT
- 93 dependencies
Assets
- eds-13.3.0.tgz
Download activity
- Total downloads 172
- Last 30 days 0
- Last week 0
- Today 0