Javascript
If you can't use the default React install, you can still benefit from Hopper UI.
Tokens
Hopper tokens are a collection of design decisions translated into data, which should be used to style your applications.
Installation
Run the following command to install Hopper tokens.
Usage
CSS
Import the tokens in your project:
Import dark mode tokens if your application supports it:
You can now use Hopper tokens in your project by using the following syntax:
Fonts
In order to use Hopper fonts in your project, import the following:
All the necessary font-face declarations are now imported into your project.
SVG Icons
If your project is not using the React framework, you can use SVG icons directly. You can find the SVG icons in the @hopper-ui/svg-icons
package.
Installation
Run the following command to install Hopper icons.
Usage
You can import the SVG directly into your JavaScript file. Keep in mind that if you plan to use SVG icons as components, you'll need to ensure that your bundler is configured to handle SVG parsing appropriately.
You can also use SVG icons directly in your CSS like this::