Skip to content
SolidOSPublic

About

User Interface widgets and utilities for Solid

Topics

Resources

Stars

154 stars

Watchers

24 watching

Forks

Repository files navigation

solid-ui

NPM Package

User Interface widgets and utilities for Solid (solid-ui)

These are HTML5 widgets which connect to a solid store. Building blocks for solid-based apps. Vanilla JS. Includes large widgets like chat, table, matrix, form fields, and small widgets.

Table of Contents

Getting started

Contributions of bug fixes and new functionality, documentation, and tests are always appreciated.

Install via npm

npm install solid-ui rdflib solid-logic

In order to use components, choose whether to import specific ones or all of them:

// Import individual components...
import 'solid-ui/components/button'
import 'solid-ui/components/combobox'

// Or all of them.
import 'solid-ui/components'

Then, you can use them in your HTML like you would use any element (all of them are prefixed by solid-ui):

<solid-ui-button>Click me!</solid-ui-button>

And don't forget to also include the CSS, either with a link tag or inside a CSS file:

@import "solid-ui"
  <link rel="stylesheet" href="https://unpkg.com/solid-ui@^4.0.0/dist/theme.css">

You can also use some of the helpers exported from the default entry:

import { log } from 'solid-ui'

log.msg('Hello there!')

Finally, if you're going to use a component that requires global state (like <solid-ui-account> which hooks into authentication), you'll need to wrap your app with <solid-ui-provider>:

<solid-ui-provider>
    <!-- This will display the logged in user and allow guests to log in -->
    <solid-ui-account></solid-ui-account>
</solid-ui-provider>

Widget navigation icons