Skip to content

Conversation

@SylvainCorlay
Copy link
Member

When aligning certain widget in an hbox, you would get this
un-aligned

With this change:
aligned
@jdfreder

@damianavila
Copy link
Member

I am always a little worried of the !important use, because it is a pain if you try to customize things later... but maybe this is so general that probably nobody wants to change it...

@Carreau
Copy link
Member

Carreau commented Oct 11, 2014

Yep, the important should be avoided, if it's overwritten by something else, then we can probably be more selective on the css rule by using explicitly div.widget-hbox or something else. We are using less, and have full control of css so it's most likely doable.

@SylvainCorlay
Copy link
Member Author

I am aligning with other items which have the !important tag, such as widget-text. If I remove it, it should be removed everywhere.

@minrk
Copy link
Member

minrk commented Oct 11, 2014

If I remove it, it should be removed everywhere.

Agreed, it should be removed everywhere.

@Carreau
Copy link
Member

Carreau commented Oct 11, 2014

Indeed, if there are !important, they slipped through in others PR.

Envoyé de mon iPhone

Le 11 oct. 2014 à 20:14, Min RK notifications@github.com a écrit :

If I remove it, it should be removed everywhere.

Agreed, it should be removed everywhere.


Reply to this email directly or view it on GitHub.

@SylvainCorlay
Copy link
Member Author

There are a bunch of those in

/static/notebook
    outputarea.less
    codemirror.less

And a lot in

/static/widgets/less
    widgets.less

I can remove those in widgets, and test for side effects...

@minrk
Copy link
Member

minrk commented Oct 11, 2014

Yeesh. If you want to just leave this one as-is for symmetry for now, that would be fine, then. If you want to figure out how to clean it up in widgets as a whole, that's good too, though I suspect the widget ones are because of the outputarea ones, so that is probably not doable without dealing with the whole thing.

@SylvainCorlay
Copy link
Member Author

Ok, I will look at it. We overload a lot of styling and we would probably benefit from a cleanup.

@jdfreder
Copy link
Contributor

IIRC there were one or two instances in the widgets where !important was required, because specificity couldn't be used to beat the library defaults. Admittedly I used it in more places than I should have.

@SylvainCorlay
Copy link
Member Author

Ready to merge?

@jdfreder
Copy link
Contributor

👍 from me

@damianavila
Copy link
Member

If we are going to let the clean up for another PR, I am OK to merge... but let's open an issue (better a PR 😜) to track the clean up later...

@jdfreder
Copy link
Contributor

Done - #6695

jdfreder added a commit that referenced this pull request Oct 14, 2014
Minor change in widgets.less to fix alignment issue
@jdfreder jdfreder merged commit 6dc18a1 into ipython:master Oct 14, 2014
@SylvainCorlay SylvainCorlay deleted the widget_hbox_align branch October 14, 2014 21:53
@SylvainCorlay
Copy link
Member Author

@damianavila @jdfreder I will open the PR to remove the !important stuff tonight or tomorrow. it will probably incorporate the flexbox correction. (align-stretch instead of align-start for the widget-subarea, a min_width in em units for the slider readout and flex-grow:1 by default in widget-hslider).

@minrk minrk added this to the 3.0 milestone Oct 14, 2014
mattvonrocketstein pushed a commit to mattvonrocketstein/ipython that referenced this pull request Nov 3, 2014
Minor change in widgets.less to fix alignment issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants