Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Less css #2708

Merged
merged 59 commits into from Jan 31, 2013
Merged

Less css #2708

merged 59 commits into from Jan 31, 2013

Conversation

Carreau
Copy link
Member

@Carreau Carreau commented Dec 19, 2012

Edit : TODO

  • fix body overflow on dasboad
  • fix stderr not red
  • create a test_notebook with most css case
  • [ ] prepare nbviewer for transition
  • fix or remove print view.

Start to replace css by less.

For now, in browser compilation, kind of much better to develop and test as you don't have to restart.

Start replacing hardcoded value with variable.

(try setting @notebook_background in varaibles.less to a nice light pink, and the rest follows)

Start removing jquery-ui-class references in javascript.

Eg, instead of toggling ui-widget-content ui-corner-all on cell selection/unselection, replace by a 'selected' class and put the correct css in

.cell{
    &.selected {
        // the code.
    }
}

Browser side parsing should allow things like user only defining css variable in their .profile/static... and it should work.

(parsing time is ~+80 ms on my laptop according to less)

Just for your eyes, what you can do with variables...
Capture d e cran 2012-12-19 a 21 21 15

Current style is unchanged of course.

@Carreau Carreau mentioned this pull request Dec 19, 2012
@bollwyvl
Copy link
Contributor

fantastic stuff. as a plugin writer, i would love to be able to use LESS when building new widgets.

what relationship does this have to the larger JS/HTML refactor? In that vein, it seems like picking up an existing LESS-ful framework like bootstrap could be beneficial. I have found that my code has gotten much cleaner on the JS side after dropping bootstrap jquery-ui for page basics... and the theming is much, much cleaner. of course, the jqui stuff would all still work.

@jasongrout
Copy link
Member

Are you saying it's much better after dropping jquery-ui, or after dropping bootstrap?

@Carreau
Copy link
Member Author

Carreau commented Dec 19, 2012

Yes, we want to move to bootstrap.
For the moment I move to less only because it is easier that going bootstrap right now, as we have css-conflict with it.

@jasongrout
Copy link
Member

From what I've seen of less (we have someone that is moving the Sage notebook to it), +1 to the idea.

@bollwyvl
Copy link
Contributor

using more bootstrap than jqui. I have found that I think more clearly
about my classes in html (or templates), which can lead to writing no JS at
all. writing zero code for navigation (tabs, etc) is huge, until i need
something really special.

base bootstrap doesn't create magic temporary/hidden/intermediate/wrapping
divs to achieve most of its effects, and tends to limit the amount of
style="" wrangling. I don't have to guess at what is happening when i am
getting extra padding, etc.
On Dec 19, 2012 3:46 PM, "Jason Grout" notifications@github.com wrote:

Are you saying it's much better after dropping jquery-ui, or after
dropping bootstrap?


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-11547662.

@ellisonbg
Copy link
Member

Matthias, do you think we should start to use prefixed css class names like
ip_notebook... or ipynb_notebook. At least on our top level classes for
prevent conflicts. Also, I think it is more common to use "-" in css class
names rather than the "_". If we wanted to change, this would be a good
time. What do you think?

On Thu, Dec 20, 2012 at 5:04 AM, bollwyvl notifications@github.com wrote:

using more bootstrap than jqui. I have found that I think more clearly
about my classes in html (or templates), which can lead to writing no JS
at
all. writing zero code for navigation (tabs, etc) is huge, until i need
something really special.

base bootstrap doesn't create magic temporary/hidden/intermediate/wrapping
divs to achieve most of its effects, and tends to limit the amount of
style="" wrangling. I don't have to guess at what is happening when i am
getting extra padding, etc.
On Dec 19, 2012 3:46 PM, "Jason Grout" notifications@github.com wrote:

Are you saying it's much better after dropping jquery-ui, or after
dropping bootstrap?


Reply to this email directly or view it on GitHub<
https://github.com/ipython/ipython/pull/2708#issuecomment-11547662>.


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-11572598.

Brian E. Granger
Cal Poly State University, San Luis Obispo
bgranger@calpoly.edu and ellisonbg@gmail.com

@Carreau
Copy link
Member Author

Carreau commented Dec 20, 2012

Matthias, do you think we should start to use prefixed css class names like
ip_notebook... or ipynb_notebook. At least on our top level classes for
prevent conflicts. Also, I think it is more common to use "-" in css class
names rather than the "_". If we wanted to change, this would be a good
time. What do you think?

Is it to prevent conflict with bootstrap ?
or for Embeding ?
I already tried, and made a Pr to fix some potential conflict.

If it is for embedding/nbviewer...etc you just "namespace" the css with a nesting rule

div#ipython{
    //all the rest od the less file
}

Which will effectively apply the css only to the element that are inside the `#ipython' div...

@jasongrout
Copy link
Member

But if the parent page has the same classnames, some of its styles could be erroneously applied to the IPython part.

@Carreau
Copy link
Member Author

Carreau commented Dec 20, 2012

And if the embedding page use a bootstrap theme that conflict with our, we are also screwed, the same with jQuery UI.
Also our css does overwrite some of the jquery-ui classes.

The other risk of embedding will be that boilerplate might not be applied and you will have some inheritances you dont want.

We can be careful while creating new css-classes, but I'm not sure it is worth it for now, we will encounter collision elsewhere.

I also would really like if jQuery UI classes where not manipulated with javascript.

@ellisonbg
Copy link
Member

Yes, both to prevent conflicts with Bootstrap but also to enable better
embedding. I also ran into an issue when doing the work with Online Python
Tutor, that our classes conflicted with them.

I think we really do need to do more than simple elements nesting, to
prevent other people's styles from appyling to our elements.

On Thu, Dec 20, 2012 at 9:03 AM, Bussonnier Matthias <
notifications@github.com> wrote:

Matthias, do you think we should start to use prefixed css class names like
ip_notebook... or ipynb_notebook. At least on our top level classes for
prevent conflicts. Also, I think it is more common to use "-" in css class
names rather than the "_". If we wanted to change, this would be a good
time. What do you think?

Is it to prevent conflict with bootstrap ?
or for Embeding ?
I already tried, and made a Pr to fix some potential conflict.

If it is for embedding/nbviewer...etc you just "namespace" the css with a
nesting rule

div#ipython{
//all the rest od the less file
}

Which will effectively apply the css only to the element that are inside
the `#ipython' div...


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-11581445.

Brian E. Granger
Cal Poly State University, San Luis Obispo
bgranger@calpoly.edu and ellisonbg@gmail.com

@ellisonbg
Copy link
Member

Matthias,

What prefix should we use? ip? ipynb? ipy?
Should we do the prefix stuff in this PR or another?
If we are going to rename our css classes, let's also go from "_" to "-"

I completely agree that it would be wonderful to get rid of the jquery ui
css classes logic in our JS code. I imagine that less will help with that.
The other thing I want to do is to organize our css into files that
correspond to the Javascript classes we have (Notebook, CodeCell, etc). so
that people can grab just the css they need in a more modular manner. But
maybe that can wait for another PR.

On Thu, Dec 20, 2012 at 9:25 AM, Bussonnier Matthias <
notifications@github.com> wrote:

And if the embedding page use a bootstrap theme that conflict with our, we
are also screwed, the same with jQuery UI.
Also our css does overwrite some of the jquery-ui classes.

The other risk of embedding will be that boilerplate might not be applied
and you will have some inheritances you dont want.

We can be careful while creating new css-classes, but I'm not sure it is
worth it for now, we will encounter collision elsewhere.

I also would really like if jQuery UI classes where not manipulated with
javascript.


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-11582414.

Brian E. Granger
Cal Poly State University, San Luis Obispo
bgranger@calpoly.edu and ellisonbg@gmail.com

@Carreau
Copy link
Member Author

Carreau commented Dec 21, 2012

Short from my phone.

I can do this as part of this pr.

I'm leaving in a few hours, so my availlability will vary a lot durring the
following 2 weeks.

Also i will be stuck with windows I hope i'll be able to install a VM.
Le 21 déc. 2012 00:42, "Brian E. Granger" notifications@github.com a
écrit :

Matthias,

What prefix should we use? ip? ipynb? ipy?
Should we do the prefix stuff in this PR or another?
If we are going to rename our css classes, let's also go from "_" to "-"

I completely agree that it would be wonderful to get rid of the jquery ui
css classes logic in our JS code. I imagine that less will help with that.
The other thing I want to do is to organize our css into files that
correspond to the Javascript classes we have (Notebook, CodeCell, etc). so
that people can grab just the css they need in a more modular manner. But
maybe that can wait for another PR.

On Thu, Dec 20, 2012 at 9:25 AM, Bussonnier Matthias <
notifications@github.com> wrote:

And if the embedding page use a bootstrap theme that conflict with our,
we
are also screwed, the same with jQuery UI.
Also our css does overwrite some of the jquery-ui classes.

The other risk of embedding will be that boilerplate might not be
applied
and you will have some inheritances you dont want.

We can be careful while creating new css-classes, but I'm not sure it is
worth it for now, we will encounter collision elsewhere.

I also would really like if jQuery UI classes where not manipulated with
javascript.


Reply to this email directly or view it on GitHub<
https://github.com/ipython/ipython/pull/2708#issuecomment-11582414>.

Brian E. Granger
Cal Poly State University, San Luis Obispo
bgranger@calpoly.edu and ellisonbg@gmail.com


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-11597375.

@Carreau
Copy link
Member Author

Carreau commented Dec 22, 2012

If we go this way.

  • do we do all the changes in one shot ?
  • do we stay on browser compilation ?
  • do we do this for 0.14 or 0.15 ?

I'm + 1 on staying on browser side compilation,
To do it step by step, but maybe keep that for 0.15.

@bollwyvl
Copy link
Contributor

I see no disadvantages to client-side css compilation, as your performance
tests have indicated, other than being a little hard to hack on when
debugging a plugin, for example. I don't know if there is the equivalent of
source maps like for coffescript to JS.

haven't checked the code, so I don't know whether you have the compiled
path setup yet. There is a less compiler in python:
http://code.google.com/p/lesscss-python/

If you are talking compilation at runtime, it seems like adding node.js
just for this is not worth it... having a build step for released for web
assets is the plan, similar to bootstrap, might not be bad, as the results
would be checked in.

re: runtime, server side compilation. webassets, the python module, which
may be worth a look.
On Dec 22, 2012 4:12 PM, "Bussonnier Matthias" notifications@github.com
wrote:

If we go this way.

  • do we do all the changes in one shot ?
  • do we stay on browser compilation ?
  • do we do this for 0.14 or 0.15 ?

I'm + 1 on staying on browser side compilation,
To do it step by step, but maybe keep that for 0.15.


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-11641385.

@Carreau
Copy link
Member Author

Carreau commented Dec 22, 2012

The python compiler have no commits in 2 years.

Advantage of compiling browser side is that user can override 1 less file
in their .profile/static and it will be take into account
on the browser side.
Otherwise they have to recompile the all css.

Also for now we don't have any build step for the notebook, It will greatly
slowdown the development process.
Already changing templates need the server to be restarted and I hope we'll
find a way to keep that as smooth as we can.

On Sat, Dec 22, 2012 at 10:26 PM, bollwyvl notifications@github.com wrote:

I see no disadvantages to client-side css compilation, as your performance
tests have indicated, other than being a little hard to hack on when
debugging a plugin, for example. I don't know if there is the equivalent
of
source maps like for coffescript to JS.

haven't checked the code, so I don't know whether you have the compiled
path setup yet. There is a less compiler in python:
http://code.google.com/p/lesscss-python/

If you are talking compilation at runtime, it seems like adding node.js
just for this is not worth it... having a build step for released for web
assets is the plan, similar to bootstrap, might not be bad, as the results
would be checked in.

re: runtime, server side compilation. webassets, the python module, which
may be worth a look.
On Dec 22, 2012 4:12 PM, "Bussonnier Matthias" notifications@github.com
wrote:

If we go this way.

  • do we do all the changes in one shot ?
  • do we stay on browser compilation ?
  • do we do this for 0.14 or 0.15 ?

I'm + 1 on staying on browser side compilation,
To do it step by step, but maybe keep that for 0.15.


Reply to this email directly or view it on GitHub<
https://github.com/ipython/ipython/pull/2708#issuecomment-11641385>.


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-11641494.

@Carreau
Copy link
Member Author

Carreau commented Dec 23, 2012

new --NotebookApp.use_less flag.

Either use style.min.css if set to false (which need to me generateed by running make in static dir)
Or load and parse the less files on the fly in the browser if set to True.
Css probably broken in in login/logout.html

@Carreau
Copy link
Member Author

Carreau commented Dec 31, 2012

Need to be rebased.

@ghost ghost assigned Carreau Dec 31, 2012
@Carreau
Copy link
Member Author

Carreau commented Jan 3, 2013

Ok, should merge cleanly again.

@Carreau
Copy link
Member Author

Carreau commented Jan 3, 2013

Bootstrap css added (not the Js plugins/ images)
And css recompiled.

There are a few glitches here and there, but nothing serious, just ugly.

I replace the "project folder" in dashboard with a breadcrumb not clickable yet, but it might be a way to "Navigate" the folder structure.

@Carreau
Copy link
Member Author

Carreau commented Jan 20, 2013

rebased on top of master to avoid the few conflict.

@ellisonbg
Copy link
Member

OK I will try to review this soon.

On Sun, Jan 20, 2013 at 11:55 AM, Bussonnier Matthias <
notifications@github.com> wrote:

rebased on top of master to avoid the few conflict.


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-12476255.

Brian E. Granger
Cal Poly State University, San Luis Obispo
bgranger@calpoly.edu and ellisonbg@gmail.com

@Carreau
Copy link
Member Author

Carreau commented Jan 21, 2013

Css still need some tweaks with the current merge of celltoolbar.
also I would like to know if we want to include full bootstrap with it's Js plugin, or only css...

@bollwyvl
Copy link
Contributor

Just hacked up an inventory of existing notebook elements that could (not saying should, as it means more work!) use bootstrap javascript components, with some notes on where future components could use these.

further, the dev community seems to be picking up speed on building stuff "the bootstrap way," but the jquery ui ecosystem still strictly dominates in terms of available components. actually, one of the items from that post includes a less-ful theme of jq.ui to make it more bootstrap-like... this could be great for getting consistent visuals, while keeping the goodness that is jq.ui, and would tie in nicely to the effort on this ticket

Legend

👍 useful
🎱 not sure if it is useful

Transitions: 🎱

  • not really used anywhere

Modal: 👍

  • some of these are already used with ui
  • bootstrap modals are functionally equivalent to UI ones, but can be defined more easily in markup

Dropdown: 👍 👍

  • menubar.js
  • again, more markup-based

Scrollspy: 🎱

  • nothing is currently like this
  • this would could be good if there was a powerpoint-like cell thumbnail navigator

Tab: 🎱

  • currently no tabs? who likes tabs anyway?

Tooltip: 👍

  • used in codecell, and is heavily customized: haven't dug into what the customizations do
  • bootstrap tooltips are a little fiddly: there is no direct markup mechanism, and modifying the text after initiation requires some undocumented API digging

Popover: 👍

  • these are great... nice for things that don't need a whole modal, but are bigger than a tooltip

Alert: 👍

  • luckily, alerts are rare in the codebase... just a WebSocket warning in kernel.js
  • might replace some modals
  • nice, consistent styling, would be responsive to themes

Button: 👍 👍

  • used all over
  • somewhat simpler than the jq.ui buttons... icons are just markup (not magic)

Collapse: 👍

  • used in codecells
  • might be simpler... there is a lot of stuff that talks about collapsing

Carousel: 🎱

  • not used anywhere
  • probably not that useful, as any of the presentation viewers would already have this

Typeahead: 🎱

  • handled by codemirror, predominantly
  • might be useful for add-ons

Affix: 🎱

  • nothing like this used
  • not sure how this would play

@Carreau
Copy link
Member Author

Carreau commented Jan 21, 2013

Thanks for the comprehensive review !

With some comment though.
Notebook format does allow worksheet. Tabs maybe...

Tooltip are written fully from scratch. I didn't found anything even close from what we have now.

Scrollspy could be use to keep current focused cell in focus when new output arrives above.

I would like for the "celltoolbar" a kind of affix, where it stick up the screen when the cell bleed above
the top edge of the window but which would be pushed up when the next cell arrives.
A little like the alphabetic delimiters on iOS when you scroll fast or the mail header on gmail app on android phones

See what I mean ?

@bollwyvl
Copy link
Contributor

great stuff.

first off:
just checked out the less-css branch: jinja2 is now called for, only
reference is in notebookapp.py. I <3 jinja, is this permanent?

will this become another line in the pip install/easy_install pyzmq tornado jinja2 extra installation instructions? Case for breaking out
notebook as separate installable becoming stronger...

Notebook format does allow worksheet. Tabs maybe...

Ah. Just hadn't seen them visually represented. It looks like (according to
notebook.js@1159 on the PR branch) this is not supported, yet! this would
be a fun thing to work on :) Do the different sheets share the same running
kernel?

does the message format already account for this? haven't sniffed much of
the on-the-wire notebook stuff.

I have found BS tabs a bit easier and more semantically-sound than jq.ui
ones... may be worth investigating. However, some of the behaviors (like
drag-drop reorderable tabs) are not built in to BS, but is already in
jq.ui... it seems like this behavior would be required vs. some clunkly
"move sheet right" or "move sheet left": i'm looking at you, google docs!
however, it could be just a matter of adding jq.ui.sortable to the BS
tabs :)

Tooltip are written fully from scratch. I didn't found anything even close
from what we have now.

Yeah, couldn't evaluate that with my level of understanding. Is this a
candidate for extraction, or are they extremely tied into the "guts" of the
notebook?

Scrollspy could be use to keep current focused cell in focus when new
output arrives above.

Can't visualize what you are suggesting, but i have had good success with
using scrollspy to do nifty things in long scrolling documents. One I liked
was pretty much exactly what you describe below: basically, we have a
big-ol-page of django models from a "parent" starting point, and visually
represent the "health" (i.e. filled-in status, semantic validation) of all
child instances.

we used d3/svg for this... is there a targeted browser that supports
websockets that doesn't support SVG? could probably redo the code for DIVs.

I could envision a notebook add-on which, in exchange for 20px of
horizontal space, as you add more cells, you would see:

  • how many cells there are
  • which cells are "bigger" from a screen real estate point of view
    • this might be weird with "really big" output cells... perhaps all
      output cells are the same size? thumbnails of images would be amazing.
  • how big your current viewing window is in comparison to the whole document
  • which cells are throwing errors
  • where new content just popped in/was updated
    • would be super handy in eventual collaborative mode
  • which cells you edited most recently (gradually fading alpha)
    • this wouldn't work over successive notebook loads, as this is not
      captured in the notebook format?
  • where your currently-selected text occurs
    • handy for refactoring
  • where a searched-for text occurs
    • similar to mobile chrome
    • oh and: a good JS find/replace dialog would be really nice :)

I would like for the "celltoolbar" a kind of affix, where it stick up the
screen when the cell bleed above
the top edge of the window but which would be pushed up when the next cell
arrives.
A little like the alphabetic delimiters on iOS when you scroll fast or the
mail header on gmail app on android phones

Yes, that would be lovely, a great way to visually inform the user that a
particular cell has "extras" without cluttering up the "sheet" bar, or
resorting to lots of "modal" (i.e. disabled if irrelevant) buttons.

@Carreau
Copy link
Member Author

Carreau commented Jan 21, 2013

just checked out the less-css branch: jinja2 is now called for, only
reference is in notebookapp.py. I <3 jinja, is this permanent?

we'll need it for the ipynb > * converter.

will this become another line in the pip install/easy_install pyzmq tornado jinja2 extra installation instructions? Case for breaking out
notebook as separate installable becoming stronger...

We'll see.

Notebook format does allow worksheet. Tabs maybe...
Ah. Just hadn't seen them visually represented. It looks like (according to
notebook.js@1159 on the PR branch) this is not supported, yet! this would
be a fun thing to work on :) Do the different sheets share the same running
kernel?

Not supported yet on master, but it is on Emacs client.
Yes they will share the same kernel, nothing prevent from doing otherwise
but then it is just 2 notebook...

does the message format already account for this? haven't sniffed much of
the on-the-wire notebook stuff.

This is purely frontend specific.kernel is agnostic that it runs from a notebook.

I have found BS tabs a bit easier and more semantically-sound than jq.ui
ones... may be worth investigating. However, some of the behaviors (like
drag-drop reorderable tabs) are not built in to BS, but is already in
jq.ui... it seems like this behavior would be required vs. some clunkly
"move sheet right" or "move sheet left": i'm looking at you, google docs!
however, it could be just a matter of adding jq.ui.sortable to the BS
tabs :)

look in "closed PR" someone had a draft.

Tooltip are written fully from scratch. I didn't found anything even close
from what we have now.
Yeah, couldn't evaluate that with my level of understanding. Is this a
candidate for extraction, or are they extremely tied into the "guts" of the
notebook?

It shouldn't be 'that' much entangled.
If you wish to extract it into a component, that would be great !

Scrollspy could be use to keep current focused cell in focus when new
output arrives above.
Can't visualize what you are suggesting, but i have had good success with
using scrollspy to do nifty things in long scrolling documents. One I liked
was pretty much exactly what you describe below: basically, we have a
big-ol-page of django models from a "parent" starting point, and visually
represent the "health" (i.e. filled-in status, semantic validation) of all
child instances.

we used d3/svg for this... is there a targeted browser that supports
websockets that doesn't support SVG? could probably redo the code for DIVs.

I could envision a notebook add-on which, in exchange for 20px of
horizontal space, as you add more cells, you would see:

I do not get everything, but you could try.
we also have (maybe) a plan for a search/command line bar

@minrk
Copy link
Member

minrk commented Jan 21, 2013

will this become another line in the pip install/easy_install pyzmq tornado jinja2 extra installation instructions? Case for breaking out
notebook as separate installable becoming stronger...

Yes, jinja2 will be a dependency of the notebook from 0.14. It is a
long-term goal to split the notebook (and other frontends) from the IPython
core repo in the long run, but for now it makes no sense, since there is
still too much coupled development (we would have to make simultaneous
releases
and require exact version matching, which makes the separation functionally
meaningless, and only a source of problems).
Once the boundaries between some of these parts of the code have
solidified, IPython will probably become a few repos (ipython, ipython-zmq,
ipython-parallel, ipython-notebook, ipython-qtconsole).

@ellisonbg
Copy link
Member

The notebook page is also much closer. A few more things:

  • The cell toolbar is off: slightly darker borders than the rest of the input area. It is slightly taller than before - it takes up too much vertical space now. And the slideshow select box is off: too wide and the label is the wrong color.
  • It is sort of a separate issue, but our pager is no longer monospaced (in master even).

Later tonight i will try to finish looking through your css sample notebook, but this is getting closer.

@Carreau
Copy link
Member Author

Carreau commented Jan 30, 2013

The default mode is use_less=False, in which case the notebook just loads the saved style.min.css.

Yes

Quick note to myself, does it apply to other pages like dashboard ?

@ellisonbg
Copy link
Member

Not sure if you are asking me a question - I do think we should have
use_less=False by default on all pages.

On Tue, Jan 29, 2013 at 10:06 PM, Bussonnier Matthias <
notifications@github.com> wrote:

The default mode is use_less=False, in which case the notebook just
loads the saved style.min.css.
Yes

Quick note to myself, does it apply to other pages like dashboard ?


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-12875811.

Brian E. Granger
Cal Poly State University, San Luis Obispo
bgranger@calpoly.edu and ellisonbg@gmail.com

@Carreau
Copy link
Member Author

Carreau commented Jan 30, 2013

Not sure if you are asking me a question

No, I just need to check that the use_less flag also have an effect on other pages, I might have forgot some templates modifications.

@Carreau
Copy link
Member Author

Carreau commented Jan 30, 2013

grey border between the header and the read of the page.

Done

The line-height of the text in the "Notebooks" and "Clusters" tabs is larger in your version of the notebook. But let's leave this because we will want to transition to bootstrap styled tabs.

Not changed.

You are still using the breadcrumbs, but that is a minor point and shouldn't hold this up.

Will make sens when you'll have to make them clickable to browse folders...

A few more things:

The cell toolbar is off: slightly darker borders than the rest of the input area.

Should be fixed

It is slightly taller than before

Also fixed... this one was hard.

And the slideshow select box is off: too wide and the label is the wrong color.

I can't differentiate myself...

It is sort of a separate issue, but our pager is no longer monospaced (in master even).

Hum, strage, font-type is set to monospace still..

Later tonight i will try to finish looking through your css sample notebook, but this is getting closer.

moved in examples/tests

@Carreau
Copy link
Member Author

Carreau commented Jan 30, 2013

Quick note to myself, does it apply to other pages like dashboard ?

Now it does.

@Carreau
Copy link
Member Author

Carreau commented Jan 30, 2013

Ok, I guess I fixed everything.

@ellisonbg
Copy link
Member

Things are really looking good.

  • I looked and there is something a bit wierd going on with the pager. It is now wrapped in .output_area and .output_stream css classes. I don't remember that. I too am confused though as it looks like it should be monospace.
  • The only styling thing I found on the notebook page is that the border around markdown cell's input area is darker while editing the cell.

@ellisonbg
Copy link
Member

While the printnotebook view is disabled, I see that all of its files, its its tornado handler are still there. Do you mean to remove them? Any reason to keep them around?

@ellisonbg
Copy link
Member

So the only things I see are:

  • Fix border of markdown/text cells when editing.
  • Decide what to do about fully removing printnotebook view.

@Carreau
Copy link
Member Author

Carreau commented Jan 31, 2013

I looked and there is something a bit wierd going on with the pager. It is now wrapped in .output_area and .output_stream css classes. I don't remember that. I too am confused though as it looks like it should be monospace.

it seem to have been for quite a while

commit 0c51946afcf388c6f7515846d9bb85cff12c90a8
Author: Brian E. Granger <ellisonbg@gmail.com>
Date:   Fri Jul 22 17:07:35 2011 -0700

    Updating font-sizing to use the YUI protocol.

diff --git a/IPython/frontend/html/notebook/static/js/pager.js b/IPython/frontend/html/notebook/static/js/pager.js
index a6ce743..707e666 100644
--- a/IPython/frontend/html/notebook/static/js/pager.js
+++ b/IPython/frontend/html/notebook/static/js/pager.js
@@ -81,9 +81,8 @@ var IPython = (function (IPython) {


     Pager.prototype.append_text = function (text) {
-        var toinsert = $("<div/>").addClass("output_area output_stream monospace-font");
-        toinsert.append($("<pre/>").addClass("monospace-font").
-            html(utils.fixConsole(text)));
+        var toinsert = $("<div/>").addClass("output_area output_stream");
+        toinsert.append($('<pre/>').html(utils.fixConsole(text)));
         this.pager_element.append(toinsert);
     };

but indeed, removing it bring back monospace font.

The only styling thing I found on the notebook page is that the border around markdown cell's input area is darker while editing the cell.

Do you mean background ? I always have #ababab for border ... the background was different still

While the printnotebook view is disabled, I see that all of its files, its its tornado handler are still there. Do you mean to remove them? Any reason to keep them around?

It will probably be easier to reenable the print view. and I would prefer to remove in a separate PR to undo more easily if needed. Also one can still access it by adding /print manually

@ellisonbg
Copy link
Member

I do mean the border. Let me try to describe a bit more. When you are editing a markdown/text cell, it shades in the input area and adds a border to it. The fill color looks fine to the eye, but the border is darker than the border around the code cell input area. It is most noticeable when you have the celltoolbar open, as the ctb has the correct lighter border compared to the input area..

Let's worry about the pager formatting in a later PR.

I am fine with you plan for the printview, I just wanted to make sure it wasn't a mistake to leave that stuff there for now.

@ellisonbg
Copy link
Member

Matthias,

Not sure if you are still up, but do you want to IRC about this PR? I am
on there if you want.

On Thu, Jan 31, 2013 at 4:37 AM, Bussonnier Matthias <
notifications@github.com> wrote:

I looked and there is something a bit wierd going on with the pager. It is
now wrapped in .output_area and .output_stream css classes. I don't
remember that. I too am confused though as it looks like it should be
monospace.

it seem to have been for quite a while

commit 0c51946
Author: Brian E. Granger ellisonbg@gmail.com
Date: Fri Jul 22 17:07:35 2011 -0700

Updating font-sizing to use the YUI protocol.

diff --git a/IPython/frontend/html/notebook/static/js/pager.js b/IPython/frontend/html/notebook/static/js/pager.jsindex a6ce743..707e666 100644--- a/IPython/frontend/html/notebook/static/js/pager.js+++ b/IPython/frontend/html/notebook/static/js/pager.js@@ -81,9 +81,8 @@ var IPython = (function (IPython) {

 Pager.prototype.append_text = function (text) {-        var toinsert = $("<div/>").addClass("output_area output_stream monospace-font");-        toinsert.append($("<pre/>").addClass("monospace-font").-            html(utils.fixConsole(text)));+        var toinsert = $("<div/>").addClass("output_area output_stream");+        toinsert.append($('<pre/>').html(utils.fixConsole(text)));
     this.pager_element.append(toinsert);
 };

but indeed, removing it bring back monospace font.

The only styling thing I found on the notebook page is that the border
around markdown cell's input area is darker while editing the cell.

Do you mean background ? I always have #ababab for border ... the
background was different still

While the printnotebook view is disabled, I see that all of its files, its
its tornado handler are still there. Do you mean to remove them? Any reason
to keep them around?

It will probably be easier to reenable the print view. and I would prefer
to remove in a separate PR to undo more easily if needed. Also one can
still access it by adding /print manually


Reply to this email directly or view it on GitHubhttps://github.com//pull/2708#issuecomment-12940527.

Brian E. Granger
Cal Poly State University, San Luis Obispo
bgranger@calpoly.edu and ellisonbg@gmail.com

@ellisonbg
Copy link
Member

I think this is ready, great work!

ellisonbg added a commit that referenced this pull request Jan 31, 2013
@ellisonbg ellisonbg merged commit ec14a41 into ipython:master Jan 31, 2013
@Carreau Carreau deleted the less-css branch February 10, 2013 10:23
mattvonrocketstein pushed a commit to mattvonrocketstein/ipython that referenced this pull request Nov 3, 2014
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.

None yet

5 participants