open-ui icon indicating copy to clipboard operation
open-ui copied to clipboard

[Radio Button] Proposal (Editor's draft)

Open leolopes opened this issue 4 years ago • 5 comments

Related to: https://github.com/openui/open-ui/issues/251

This PR is still a draft for the radio button proposal. I managed to create two components, one for the radio button and other for the radio button group, and the two would be all it takes to create both a rigid and a flexible layout.

The idea expounded on the proposal, but the gist is that we can either create a group with options inside of it, or a group with options outside of it, that are then bound to the group by a new attribute.

By leveraging slot defaults/fallbacks and proper CSS, we can make basically any layout use case.

===

I would like to validate the basic proposal with the community before developing it too much (you can see I didn't provide much information yet on accessibility, behavior, etc). If this is a valid proposal, I'll carry on.

===

Also, I'm unsure whether I used the "slot logic" correctly... In the group structure, you can see that I put a div inside the choices slot, but maybe the slot should be a direct parent of the radio buttons... If the developer so chooses, then they could fill the slot with a div and then the options. I'm not sure and I'd like your opinion as well.

leolopes avatar Jun 20 '21 17:06 leolopes

Hi @una, @gregwhitworth and @levithomason, I am afraid this PR can become a little stale, but I wouldn't like to go very far before validating the main ideas addresses on it. What could we do to proceed? Thanks.

leolopes avatar Sep 14 '21 11:09 leolopes

Thanks for filing this @leolopes - I've added @chrisdholt to do a review on this. Also, I may have missed it but did we discuss this anatomy and get resolution on it?

gregwhitworth avatar Oct 04 '21 01:10 gregwhitworth

Thanks for filing this @leolopes - I've added @chrisdholt to do a review on this. Also, I may have missed it but did we discuss this anatomy and get resolution on it?

@leolopes this is great! @gregwhitworth I don't think we discussed and resolved. There are a couple super interesting things I think we should discuss though and get resolution on so we can move this forward!

chrisdholt avatar Oct 06 '21 04:10 chrisdholt

Also, I may have missed it but did we discuss this anatomy and get resolution on it?

Hi @gregwhitworth, how are you? We discussed during a meeting the possibility of having the component either be bound together by tag nesting or by attributes. Thus I proposed both ways in this draft, so the actual proposal can be discussed further.

I'll be answering @chrisdholt on each of his points.

leolopes avatar Oct 06 '21 14:10 leolopes

Hello reviewers! Can we proceed with this PR or maybe it is too stale to be merged at this point?

leolopes avatar Apr 13 '22 12:04 leolopes

@leolopes friendly ping on this, do you intend on taking this further?

gregwhitworth avatar Mar 11 '23 02:03 gregwhitworth

@leolopes friendly ping on this, do you intend on taking this further?

Hi @gregwhitworth , I do, I just have been overwhelmed by work and I thought the proposal didn't get much traction so I didn't prioritize this. But I'll try to reserve some time this week and fix conflicts and make some of the requested changes.

leolopes avatar Mar 13 '23 11:03 leolopes

@gregwhitworth , I was trying to resolve the conflicts and now I noticed that the website was rewriten wit Astro in place of Gatsby. I'll have to learn it and make a lot of adjustments so my content will be able to run on the new structure.

leolopes avatar Mar 25 '23 20:03 leolopes

There seems to be an error on a file that was not modified by me. I'm not sure how it can be, because I pulled directly from master.

I can try to fix the file and push again later.

leolopes avatar Mar 25 '23 22:03 leolopes

@andrico1234 can you take a look at this given the error that @leolopes is seeing?

gregwhitworth avatar Mar 25 '23 23:03 gregwhitworth

@gregwhitworth and @andrico1234 I found out what was happening: Husky was messing up with a commented section on the popover.research.explainer.mdx file. I had to bypass the linting proccess on my last commit so I wouldn't run into a syntax error again.

I think either the linter should be reconfigured or the commented section should be removed.

Anyway, the PR is ready for review.

leolopes avatar Mar 26 '23 18:03 leolopes

...while the above may seem daunting it's more a shuffle of the content... @gregwhitworth

That's a bit of work but I can manage it 😉 . Just not sure when I'll get back to it, but not as long as it took before. Thanks!

leolopes avatar Mar 28 '23 17:03 leolopes