mardi 4 août 2015

How to make table cells square for any amount of text in it when table is overflow?

A Simple Problem: When table is wider than screen and if we add a bigger text in any cell or <td>.

It will increase the height for whole row unnecessary extra


Case 1 (no problem) (only table overflow): (http://ift.tt/1gHeQIA)

Case 2 (no problem) (only a cell with more text): (http://ift.tt/1P3HfDX)

Case 3 (PROBLEMATIC) (overflow + a cell with more text): (http://ift.tt/1gHeQIG)


Solution I Think (i tried javascript but fail) : If we somehow just add 1 property to be square shaped to all table cells (in case we add larger text, it will resize but keep square shape), because square shape will make table to take least area possible.

I know some people will help so thanks in advance for help...



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire