Tailwindcss: [Feature proposal] top, right, button, left

Created on 23 Jul 2018  Â·  9Comments  Â·  Source: tailwindlabs/tailwindcss

How amazing is Tailwind! So happy to use it for the first time and really enjoying it.

However a very basic feature is missing for me: Setting the position e.g. for absolute positioned elements, where the "pin" classes are not usable.

For example if you want to set a absolute element to the bottom underneath a relative one, top: 0 (.pin-t) or bottom: 0 (.pin-b) doesn't help. Here I would need top: 100%.

So my suggestion is to add some more position classes such as

  • .t-100 (top: 100%)
  • .b-100 (bottom: 100%)

Best regards,

Philipp

Most helpful comment

This is now supported in 1.0: #764

All 9 comments

I vote this is a customizable plugin. Keeping tailwind's core lightweight and simple will be key to its success.

@chrisdmacrae tailwind itself is pretty much a customizable plugin. You can EASILY disable anything you don't need.

Button...

@brandonpittman yes, button: 0 is a very important CSS property. /s

I agree that it could be handy so I made this: https://github.com/bradlc/tailwindcss-inset – hope it’s useful!

My layout plugin can also do this with its "offset" module. I think it should be in the core, though.

Keep the core light. You can add these in another way.

@adamwathan Sorry if I'm annoying 😅 But would you be interested in a PR for this, or is this plugin-land?

This is now supported in 1.0: #764

Was this page helpful?
0 / 5 - 0 ratings

Related issues

nternetinspired picture nternetinspired  Â·  3Comments

chasegiunta picture chasegiunta  Â·  3Comments

dbpolito picture dbpolito  Â·  3Comments

AlexVipond picture AlexVipond  Â·  3Comments

manniL picture manniL  Â·  3Comments