law-centres-design-system

A design system for Law Centre sites and apps. Built using Chakra-ui.


Keywords
react, npm
License
NPOSL-3.0
Install
npm install law-centres-design-system@3.0.47

Documentation

Law Centres Design System

A design system for Law Centre sites and apps utilising Chakra, FontAwesome and Google Fonts.

View Documentation

Usage

yarn add law-centres-design-system

Then install peer dependancies.

Documentation

We use Storybook to create a styleguide. To run this locally use:

npm run storybook

Currently this is automatically deployed to Vercel on push to Github.

Using local version

If developing and using in another local project, use yalc to publish to a local store

  1. Install yalc globally

If you are using yarn:

yarn add global yalc

If you are using npm:

npm i -g yalc

  1. Publish the law-centres-design-system package locally

Run npm run build followed by yalc publish in the law-centres-design-system project

  1. Adding the law-centres-design-system package to desired project

In the project you want to add this package run :

yalc add law-centres-design-system

Note that adding the version number is not necessary but will still work e.g.

yalc add law-centres-design-system@2.6.6

IMPORTANT: If you would like to run a local instance of law-centres-design-system in another project, you need to add the peer dependencies from your law-centres-design-system project to the dependency list of your project's package.json.

  1. Update node_modules

Run yarn to update your yarn.lock

  1. Updating the package after changes

In your local instance of law-centres-design-system run:

yalc push

  1. Remove the local package

To remove the local package run yalc remove law-centres-design-system in the dependent project

Publishing to NPM

This project uses Github actions to publish to npm on a merge into the main branch. This process will also produce a changelog and all notable changes to this project will be documented in this file. See standard-version for commit guidelines.