Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Show HN: Simple CSS Button (vladocar.github.io)
4 points by vladocar on July 3, 2018 | hide | past | favorite | 7 comments


I'm genuinely interested wether this is a sarcastic submission or actually serious!


It is a simple solution for very common problem: styling a CSS button. There are many CSS buttons libraries but they usually force you to use their style or size. That is why this is interesting and simple solution born with my necessity not to recode and reinvent the CSS button for every new project.


The "hard" part about styling buttons is making them look the same for <a>, <button>, <input>, which is solved like a million times.

Your solution only addresses <div>, which is a accessibility nightmare.


Pretty cool! Small thing: you should use button tags for the examples – you're losing a lot of built-in accessibility by using div tags (for instance keyboard navigation).

How does these handle being applied to anchor (a) tags? Some times you want links to appear as buttons :)


It also works with (a) tags: <a class="button btcolor pill" href="#"> Button Link</a> I need to add this in the examples.


This looks pretty cool, very simple. What is flexy.css? There is 1 button color? Feel free to submit it to my new GitHub repo curation site: http://icodedis.tool.cards/


This is flexy: https://github.com/vladocar/flexy

Yes, just 1 button color if you need more colors just add .btcolor1 , .btcolor2 ...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: