npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

studio-design-system

v1.4.7

Published

Studio's Design System, built to help us work together in creating an excellent user experience. The design system is our toolkit and building blocks for building the platform where everyone can connect with their creativity.

Downloads

9

Readme

Studio Design System

Studio's Design System, built to help us work together in creating an excellent user experience. The design system is our toolkit and building blocks for building the platform where everyone can connect with their creativity.

Usage

  1. Import package
yarn add @openmindlearning/design-system
  1. Use ThemeProvider or ThemeWrapper as a container component
<ThemeProvider>
  <MyApp/>
</ThemeProvider>
<ThemeWrapper theme={ThemeType.light}>
  <MyApp/>
</ThemeWrapper>
  1. Import the prebuilt Vanilla Extract CSS file in your top level app
import "@openmindlearning/design-system/dist/style.css";

or in a global.css file:

@import "@openmindlearning/design-system/dist/style.css";

About this package

@studio/design-system is developed to be agnostic to our platform and is intended for creating components that act as building blocks for both our applications, but also any other application or feature we could imagine.

The package is set up using a barrel export pattern such that users can import anything directly from @studio/design-system without having to specify a path (i.e. import { theme, Button } from '@studio/design-system').

The package is structured as follows:

@studio/design-system/src
├── docs          # Documentation for working with the package
├── components    # Our component library
├── hooks         # Reusable Hooks
├── icons         # SVG Icons
├── themes        # Our theme composed of CSS variables that should be used to style components
├── util          # Utility functions
└── tokens        # Raw values that compose our theme

Components:

Our component library consists of generic components that serve common use cases for features in our platform. Components are intentionally free of business logic and are designed to be extendable enough such that they can accommodate many different feature needs. Most components in the component library are built based on a collection of desktop component designs created by our Design team.

Component specific documentation and visual reference can be found in storybook (instructions on running storybook can be found in the Commands section). Component stories include a breakdown of style variations that are implicit to any component, in addition to the component's prop interface.

If you would like to contribute a component to the design system, please refer to the Contribution Guidelines documentation in Storybook which also includes PR creation guidelines.

Theme:

Our theme is composed of:

  • border styles
  • breakpoints
  • colors
  • fonts & typography styles
  • shadows (box shadows & text shadows)
  • spacing

The theme is strongly typed to provide code completion and prevent css compilation, and usage errors.

Commands

Installing dependencies locally:

yarn

Running storybook:

yarn storybook

Key Dependencies

  • React (v. )

  • Vanilla Extract CSS Our css in JS library that allows for type safe CSS variable generation. We use Vanilla Extract to create css variables in our theme to provide the convenience of semantic

  • Storybook Storybook is a visual reference and rapid prototyping tool. Our guidelines for writing stories can be found in the Contribution Guidelines.

  • Vite The design system's build tool. Vite builds storybook and provides a local port for accessing storybook

Frequently Asked Questions

  • How should I import the theme? import { theme } from "@studio/design-system"

  • How does the theme get applied to my components? The theme is provided by the ThemeProvider which exposes the theme to all children of the provider. If you are creating a component that breaks out of the scope of the ThemeProvider (i.e. a portal) you can use the ThemeWrapper to wrap your component and extend the theme to your component.

      import {ThemeWrapper} "@studio/design-system"
      import * as styles from "@vanilla-extract/css"
    
      export function MyComponent(){
    
        return (
          <ThemeWrapper>
            <div>Hello World </div>
          </ThemeWrapper>
        )
      }

Contributing

If you would like to contribute to the design system, please checkout our Contribution Guidelines page in storybook