Coder Social home page Coder Social logo

radix-ui / website Goto Github PK

View Code? Open in Web Editor NEW
821.0 7.0 420.0 19.06 MB

Website and documentation for Radix.

Home Page: https://radix-ui.com

License: MIT License

TypeScript 27.45% JavaScript 5.94% CSS 2.40% MDX 64.21%
ui ui-components design-system component-library accessibility react documentation radix-ui

website's Introduction

Radix UI hero image

Radix UI website and documentation

Everything you need to build a design system, website or web app.

Components, colors, icons, templates, and an extensive design system. Free and open-source.


Documentation

For full documentation, visit radix-ui.com.

Contributing

This is a Next.js project bootstrapped with create-next-app.

Getting Started

Run the development server:

yarn dev

Open http://localhost:3000 with your browser to see the result.

Authors


Copyright © 2022-present WorkOS.

website's People

Contributors

alecrust avatar andy-hook avatar bdsqqq avatar benoitgrelard avatar brattonross avatar bukinoshita avatar caixetadev avatar colmtuite avatar cprecioso avatar itsfaqih avatar itzami avatar jjenzz avatar joaom00 avatar lucasmotta avatar lutherts avatar officialrajdeepsingh avatar peduarte avatar riccardoscalco avatar ryanleichty avatar sabuhiteymurov avatar samrobbins85 avatar sgggggs avatar shadcn avatar snelsi avatar suliskh avatar tngsam avatar vladmoroz avatar williamhzo avatar yuirsilva avatar zenorocha avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

website's Issues

Color issues

Bug report

Color issues in Alert Dialog and Dialog components
alert_dialog
dialog

Component documentation should map more easily to vanilla CSS

Documentation

Radix component documentation is excellent but has one major drawback IMO, which is that it uses Stitches in a way which encourages abstractions which make the documentation harder to understand. Developers who want to use Radix have to understand Stitches to see how to use the component. Stitches is great but ideally these two technologies should be separated, we don't want to confine Radix to Stitches users, when the library is excellent and has the potential to be used by everyone.

One suggestion from the Discord is to use the core Stitches API which maps more closely to CSS: https://discord.com/channels/752614004387610674/803656831704629298/917373575953018880

My own experience was that it was difficult to figure out how to get it to work, what the options are, etc.

The way I work with documentation: I like to copy an example into my codebase, change it to fit (eg I'm working on a Tailwind project and a Sass project at the moment) and play around with it to see how it works and what I'll need for my project. The current Radix documentation makes that a bit difficult to do.

Accessibility overview broken link

Bug report

Current Behavior

https://www.radix-ui.com/docs/primitives/overview/introduction#accessible

Click accessibility and it takes you here https://www.radix-ui.com/docs/primitives/overview/docs/primitives/overview/accessibility

Page is a 404

Expected behavior

I assume the link should be to https://www.radix-ui.com/docs/primitives/overview/accessibility ?

Reproducible example

n/a

Suggested solution

Additional context

Your environment

Software Name(s) Version
Radix Package(s)
React n/a
Browser
Assistive tech
Node n/a
npm/yarn
Operating System

Clicking on a single color in the palette should copy the hsl value

Feature request

Overview

1st of all amazing color system

Would be really great if I am able to copy HSL values of color palettes.

On the index page

Screenshot 2021-07-13 at 6 31 15 PM

Copy function is there in this page

But it copies the entire object which is cool in that use case.

Screenshot 2021-07-13 at 6 35 00 PM

Examples in other libraries or sites

Vercel Design System has this taping on var(--color-code) copies it.

Who does this impact? Who is this for?

Developers/Designers who want to quickly copy and try it out.

Pages sometimes load without styles for a split second

I know we've been aware of this for some time but wanted to get it written down.

It seems we're depending on @modulz/design-system here so we're on a really old version of stitches. I'm guessing that might have something to do with it.

It would be good to upgrade to @radix-ui/design-system if possible.

Scroll locking elements make the layout shift

This is most likely due to the right aside being position fixed

dropdown

Recorded on Firefox Windows, confirmed same behavior on chrome Windows as well, testing on the linux ones later today

Website: Horizontal scrolling on home page does not work with Chrome

Bug report

Current Behavior

On the home page, I am not able to show the next primitive components by clicking on the arrow right button (also the button "arrow left" does not work).
However: I can scroll with my trackpad.

Expected behavior

Clicking on the arrow should scroll right / left.

Your environment

  • Windows 10
  • Chrome Version 96.0.4664.45 (Official Build) (64-bit)

Blurry Alert Dialog in documentation

Documentation

Relevant Radix Component(s)

Alert Dialog

Recommendation

Hello awesome radix team!

I noticed that in Chrome 94 the Alert Dialog doc example looks blurry when opened. I've noticed that sometimes css transform can cause elements to lose their sharpness, but in particular I noticed it's the will-change: 'transform' that causes the blurriness in this example.

Here's the original CodeSandbox, shown on the docs page: https://codesandbox.io/s/nmk9d?module=App.js
Here's my fork of the CodeSandbox: https://codesandbox.io/s/divine-fog-lznb2?module=App.js

It might be wise to remove the will-change so that the demo component looks awesome in all browsers. It would be a shame if somebody thought it was the primitive's fault.

Cheers!

Menu disappears after selecting some pages on mobile

Documentation

Sometimes when you hit the hamburger menu on mobile, it disappears and you have to refresh to get it back. I think it depends on which page you choose, happens mostly (entirely?) on "Utilities" pages.

Reproduced in Chrome and Safari on iPhone.

Video link: https://www.dropbox.com/s/z3khp8wnj7n68zb/radix%20docs.MP4?dl=0

Very excited by primitives, thanks for everything you all are doing!

Relevant Radix Component(s)

Accessible Icon, Announce, Id Provider etc

Examples from other doc sites

n/a

Tooltip arrow issue with rounded corners

Bug report

Noticed that if the tooltip arrow in on the sides, it gets disconnected from the frame when the frame has rounded corners

Expected behavior

Tooltip should look seamless when the arrow is on the sides. Would expect to be able to offset the position too a little so that the arrow is a little indented and not flush with the frame sides

Reproducible example

The issue can be observed in your own docs:
image

Suggested solution

Provide an offset for tooltip arrow when placed on the sides.

Cannot `yarn dev` repo

Discussed in #274

Originally posted by zenfonseka November 12, 2021
hey ,

i was very enjoyed your UI website and i loved it! but when i get it to Visual Code and run the command of "yarn dev" it's not running tho? can you help me to how to use it please?

thank you!.

I can't run it locally either. I just pulled a fresh copy of the repo, did a yarn && yarn dev and tried navigating to http://localhost:3000/docs/primitives/overview/getting-started but get the following screen:

image

Dropdown Demo bug

Bug report

Current Behavior

Screenshot 2022-04-01 at 15 03 44

Expected behavior

The little arrow indicating the relationship to the trigger looks broken.

Dark theme alert dialog is white on white background

Bug report

Current Behavior

Dark theme alert dialog is white on white background.
You can also select the text behind gray area by holding down the text(selecting it) and dragging your finger up or down.

Screenshot_20210614-091924_Chrome.jpg

Screenshot_20210614-091934_Chrome.jpg

Expected behavior

Text in alert dialog being visible

Reproducible example

Alert docs click open on basic example.

Suggested solution

Change color on dark mode.
Change z-index of alert background.

Additional context

Your environment

Android chrome

Software Name(s) Version
Radix Package(s)
React n/a
Browser
Assistive tech
Node n/a
npm/yarn
Operating System

Dedicated automated testing page

It would be helpful to provide some type of documentation regarding automated testing and primitives, especially with suites running testing-library and user-event. There are quite a few gotchas, especially common are pointer event firing problems and mocking layout specific browser apis as jsdom struggles with these.

Examples of common questions:

radix-ui/primitives#1382
radix-ui/primitives#1220
radix-ui/primitives#1207
radix-ui/primitives#1036
radix-ui/primitives#856
radix-ui/primitives#765
radix-ui/primitives#420

Document null during testing
radix-ui/primitives#1707

Document the available `data-*` attrs as part of the API reference for primitives

Documentation

I recently ran into some breakage when upgrading radix dropdown, which would've been more obvious had I seen &[data-state="open"] as being a new data attr that I needed to handle in order to setup the animations in stitches. See context in discord here: https://discord.com/channels/752614004387610674/803656831704629298/874377300806893578

Relevant Radix Component(s)

All radix components should document that data attrs that are part of their public API.

Add a "When to use" section

There is sometimes visual overlap with our components which makes it a little unclear which pattern is the correct one to choose for a particular use-case. Most recently, we've had a request to make Tooltip appear on click on mobile with a reference to our info icon in the props tables as an example (which actually uses Popover).

It might be nice to provide some sort of tree diagram with questions and yes/no answers that direct folks down the right path.

Dedicated `asChild` page

We have had a few reports that have been assumed to be an issue with the new asChild API but also will have been an issue with the as prop. It seems the explicitness of the asChild API has made some of these issues more apparent for people so it might be useful to provide some documentation on these pitfalls and the solutions to them.

The most recent report we had was here radix-ui/primitives#953

It's not clear what props the child should accept (or that props need to be forwarded). For now we're saying it should always accept DOM props. Ideally we would improve the DX with TS but TS doesn't currently support the ability to type the props of the child React Element.

Add styles to "indeterminate" checkbox example

Documentation

The example shown below doesn't have any visual change when toggling the indeterminate state.

CleanShot 2021-05-25 at 16 44 00@2x

My suggestion would be to show an indeterminate state, similar to this:

CleanShot 2021-05-25 at 16 46 25@2x

Relevant Radix Component(s)

Checkbox

Examples from other doc sites

n/a

Tooltip doesn't work on iOS (14.4)

Bug report

The Tooltip component isn't working on iOS.

Current Behavior

Tapping on a tooltip component doesn't show the content

Expected behavior

Content shows when tapping a Tooltip component

Reproducible example

  1. Load up this page on iOS (14.4 is what I used):

https://www.radix-ui.com/docs/primitives/components/tooltip

  1. Tap the + in the example.

Suggested solution

Content should show on tap events

Your environment

Below is my env, but it's also not working on whatever your website env is.

Software Name(s) Version
Radix Package(s) @radix-ui/react-tooltip 0.1.1
React n/a 17.0.2
Browser Safari iOS 14.4
Assistive tech n/a
Node n/a v14.17.3
npm/yarn npm 6.14.13
Operating System iOS 14.4

Id functionality and documentation for DropdownMenu.Root

Bug report

Using id is not working as expected(as detailed in the documentation) and types do not contain id.

Current Behavior

Using id is not working as expected(as detailed in the documentation) and types do not contain id.

Expected behavior

Types to include id and to pass id attr to ref element, and cases asChild also to be contemplated.

Reproducible example

Reproduced with the latest version "@radix-ui/react-dropdown-menu": "^0.1.6",

Additional context

Docs:
Screen Shot 2022-03-10 at 11 25 43

Types:
Screen Shot 2022-03-10 at 11 25 32

Repro: Not passing the right id (using asChild true)

Screen Shot 2022-03-10 at 11 29 25

Your environment

Software Name(s) Version
Radix Package(s) 0.1.6
React n/a 18
Browser Chrome
Assistive tech
Node n/a
npm/yarn
Operating System

Tweak Dialog example on homepage

I thought the Dialog example on the radix-ui.com homepage was an AlertDialog because it has an OK button… Thoughts on updating the example to avoid confusion between the two component types?

Suggestion: mention Radix-UI is not compatible with Preact

👋

I run into this issue, and it took me a while to realize preact wasn't supported. I dev locally with React and only use Preact to bundle for production purposes. That made it harder to find out what was happening.

I would probably mention it somewhere in the docs as it seems to be a recurrent topic for others.

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.