Giter Club home page Giter Club logo

headstorm / foundry-ui Goto Github PK

View Code? Open in Web Editor NEW
16.0 5.0 43.0 19.03 MB

Foundry-UI is a React UI Library built which prioritizes theming, accessibility, and performance. Fully typed with TypeScript, animated by react-spring, themed with styled-components, and made accessible by polished and jest-axe.

License: Apache License 2.0

JavaScript 1.36% TypeScript 23.90% HTML 74.38% CSS 0.36%
react ui-components ui-kit accessibility a11y a11y-react

foundry-ui's People

Contributors

adrikakhan avatar agheadstorm avatar avilebroker avatar blakekrammes avatar chloetedder avatar cnkeats avatar dawsonbooth avatar dependabot[bot] avatar donaldjbrady avatar enyiasonye avatar ericbaumann avatar garrettrathke avatar griseldazbalmaceda avatar harrisonnoble avatar ishaanbhagwat avatar j-leidy avatar j-storey5 avatar jakeoien avatar jjrockhill avatar joien1 avatar jonesdebu avatar marras0914 avatar meghanainaganti avatar patrickdevries avatar rfisher58 avatar semantic-release-bot avatar vlineros-hs avatar willwinman avatar wmangimelli avatar xavierdonnellon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

foundry-ui's Issues

Add functionality to allow replacing constants files

As a user of the UI library without much interest in CSS or styling (but who wants to change the color scheme), I want to be able to use a simple color scheme object like the one exported from hs-ui, but I don't want to have to replace every use of every color through a new styled prop. It's unnecessary and I hate styling and CSS.

AC:
Implement a method for replacing the files in the constants directory with custom ones.

Divider

  • Implement base UI
  • Fully themable
  • Add story with meaningful knobs
  • Add figma frame to story
  • A11y compliance
  • Unit/snapshot testing

Built on the native hr element. Can be fancy with an svg shape or simple, or have multiple exports/versions controlled the API. I'll leave this open ended to see if someone wants to get creative with it.

Sub-components:

  • Line

API:

  • isShort

Investigate SSR support

When using Foundry with server-side rendering (SSR) apps, i.e. apps created with NextJS, don't have a window object and will require polyfilling.

AC:

  • Test out Foundry UI in a NextJS application
  • Find a solution to get it working (Google is your friend)

Button

  • Implement base UI
  • Fully themable
  • Add story with meaningful knobs
  • Add figma frame to story
  • A11y compliance
  • Unit/snapshot testing

Sub-components

  • Container
  • Icon
  • PointerFeedback
    • for hover effects, click effects, loading, etc.

API:

  • children
  • icon
  • type
  • isLoading
  • isProcessing

Ensure storybook is not included in the installed bundle

Currently it is being included in consuming apps' node_modules

AC:

  • ensure it is not included in consuming apps' node_modules

From @jakeoien:

This ticket was intending to solve an issue where linking Foundry in a local project causes multiple versions of React to load. We came up with this as the solution. Turns out, this isn’t enough - we’re still seeing the issue even after this change. The problem we’re running into is that these storybook dependencies are a part of the foundry package itself.

I’m wondering if a better way of going about this would be to move all of the storybook stuff out of our src/ directory so that it’s not actually a part of our bundled code.

The big thing this blocks is trying to make changes like bugfixes using a local version of foundry, that currently won’t work.

From me:

I’ve seen packages (@react-three/drei for instance) that put all the storybook stuff in .storybook - which may solve the issue for us.

Update storybook images to display correctly in github pages

We are currently using an image in the /public folder which doesn’t work when hosted on github pages. We should instead host one to foundry-ui.com and use that instead on storybook.

AC

  • Upload new image to be hosted on foundry-ui.com (@aVileBroker to provide image and upload to S3)
  • Update storybook image path to the new hosted url

Publish package to npm

Once the project has an angular library, and an exportable component exists, publish the library package to npm. It should be importable by another project. (test with codesandbox.com or another quick-setup environment)

Getting access to or creating the npm organization will be a big first step.

Add a CSS in JS system

Take a base component and abstract one or more styles to a separate file for reuse using a CSS in JS system.

It will lay the groundwork for abstract sizing (small, medium, large), as well as consistent baselines, colorschemes, etc. This will also make the library smarter by powering the styling engine with TypeScript, make it more DRY, and more generally more consistent.

Dropdown | Virtualize options list for better performance of long lists

For long lists of options, we - and material ui - are quite inefficient at rendering them, causing long lists to be very slow/janky in opening and scrolling.

Virtualizing the options list and passing each option its current status (in view vs not in view) would be very powerful. We can roll our own intersection observer hook to achieve this, or use a package - but building our own would be the least risky approach imo.

AC:

  • As an option scrolls out of view, it should be replaced with an div of the height it originally was (or another performant alternative, feel free to do some research on best practices. It would be bad if it ends up being worse on performance than doing nothing)

ScrollArea component

See examples of how custom scrollbars can be created using JS to detect the scrollable area available, as well as the current scroll position to achieve custom scrollbars.

https://twitter.com/sebastienlorber/status/1516847672992350211
https://medium.com/headstorm/in-search-of-a-better-scroll-ux-pattern-3a22d4cff5f1

The default behavior should be a simple scrollbar that is similar to OSX scrollbars. (floating, expand/appear when hovered near gutter)

We should use standard terminology from HTML scrollbar styling, like thumb, gutter, handle, etc.

Add an optional scroll progress indicator subcomponent that shows the current scroll progress

Dropdown

  • Implement base UI
  • Fully themable
  • Add story with meaningful knobs
  • Add figma frame to story
  • A11y compliance
  • Unit/snapshot testing

API:

  • values
  • options
  • multi
  • onInputChange
  • onSelect
  • clearable
  • onClear

Suggested sub-components

  • ValueContainer
  • ValueItem
  • OptionsContainer
  • OptionItem

Usage Recommendation Global Styling

For developers who are new to Foundry, create a Usage section in the package readme to describe the recommended usage of Foundry with global styling.

SPIKE | Research theming architecture

From the original hs-ui pitch:
HS-UI is:
... opinionated in structure and approach, while remaining flexible in look and feel ...

In order to be able to import hs-ui/react/Button, and with a minimal amount of work, get a branded, customized look/feel, an architectural decision needs to be made.

It's also important to have a really nice looking default for developers who don't have ANY front-end theming understanding and are totally fine with just having headstorm orange all over their app.

The automated release is failing 🚨

🚨 The automated release from the master branch failed. 🚨

I recommend you give this issue a high priority, so other packages depending on you could benefit from your bug fixes and new features.

You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can resolve this 💪.

Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.

Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the master branch. You can also manually restart the failed CI job that runs semantic-release.

If you are not sure how to resolve this, here is some links that can help you:

If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.


Invalid npm token.

The npm token configured in the NPM_TOKEN environment variable must be a valid token allowing to publish to the registry https://registry.npmjs.org/.

If you are using Two-Factor Authentication, make configure the auth-only level is supported. semantic-release cannot publish with the default auth-and-writes level.

Please make sure to set the NPM_TOKEN environment variable in your CI with the exact value of the npm token.


Good luck with your project ✨

Your semantic-release bot 📦🚀

Centralized color scheme

Add the Headstorm brand colors to a centralized file which can be exported and used with hs-ui, as well as imported from the library by external projects.

Dropdown | Add searching (with callbacks)

We should have a default internal search which sorts the current option list, which can be turned off and onChange callbacks (also pass the onDebouncedChange callback up as a separate function)

I like to use fuse.basic.js for fuzzy searching lists on client-side. It weights the results and allows for mispellings, searching multiple properties in a nested object, and weights for each property in nested objects. It also returns where in the strings the matches occur so that we can highlight/bold the letters which match the search.

The API could be

  • searchable
  • searchFiltersOptions (needs a better name - but this would be what tells us to filter the list ourselves, and add the boldness to the matched patterns)
  • onSearchChange
  • onDebouncedSearchChange

Table

  • Implement base UI
  • Fully themable
  • Add story with meaningful knobs
  • Add figma frame to story
  • A11y compliance
  • Unit/snapshot testing

Host storybook on foundryui.com

The benefits are keeping people on the main domain and allowing us to maintain docs for older versions (like v0, v1, v1.1, next, etc)

Fix a11y add-on

Perhaps because of styled-components, the a11y add-on for storybook doesn't work as it does with the angular version of hs-ui.

A cursory google search didn't find any explanation, so there could be another issue.

AC:

  • The a11y add-on should be functioning and show passing/failing accessibility tests

Fix module creation

Currently when running yarn build in the hs-react-ui folder, it creates a compiled-down version of the index.ts file but doesn't correctly compile the components and make them available as it should.

One possibility for this ticket is to start a brand new create-react-library and copy the components over to it, then replace hs-react-ui with that version. If you want to continue to try and trouble shoot the current environment, you can look at other libraries created with create-react-library to compare them.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.