Opened 10 years ago

Closed 18 months ago

#14020 closed defect (invalid)

interact with layout is broken

Reported by: Andrey Novoseltsev Owned by: jason, mpatel, was
Priority: major Milestone: sage-duplicate/invalid/wontfix
Component: notebook Keywords: interact sd48
Cc: Jason Grout, Karl-Dieter Crisman, Frédéric Chapoton Merged in:
Authors: Reviewers: Dima Pasechnik
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description (last modified by Dima Pasechnik)

Consider this example:

@interact(layout={
"top": [
["u_lines"],
["v_lines"],
]
})
def _(
      u_lines=slider([1..50], default=10, label=r"$u$-lines:", display_value=False),
      v_lines=slider([1..50], default=10, label=r"$v$-lines:", display_value=False),
      ):
    print (u_lines, v_lines)

With 5.7.beta1 (and I believe the problem existed for a while):

  • The vertical spacing between elements is HUGE - if I remove layout (which is supposed to reproduce default placement here anyway), it is much more reasonable. This makes it next to impossible to create interacts to show in class that will have all controls and graphs on one screen in a reasonable size.
  • Math is not processed in labels. Again, everything is OK without layout.
  • Values of sliders are not actually updated - this is due to display_value=False with or without layout.

In Cell Server there are no issues with layout, but display_value=False does not work - the value is still shown.

Attachments (1)

Screenshot 2021-06-07 at 10.44.59.png (194.9 KB) - added by Dima Pasechnik 18 months ago.
jupyter@…

Download all attachments as: .zip

Change History (15)

comment:1 Changed 10 years ago by Karl-Dieter Crisman

Cc: Karl-Dieter Crisman added

comment:2 Changed 9 years ago by Andrey Novoseltsev

https://github.com/sagemath/sagenb/pull/168 solves the first two bullets

comment:3 Changed 9 years ago by Andrey Novoseltsev

Keywords: sd48 added

comment:4 Changed 9 years ago by Jeroen Demeyer

Milestone: sage-5.11sage-5.12

comment:5 Changed 9 years ago by For batch modifications

Milestone: sage-6.1sage-6.2

comment:6 Changed 9 years ago by For batch modifications

Milestone: sage-6.2sage-6.3

comment:7 Changed 8 years ago by For batch modifications

Milestone: sage-6.3sage-6.4

comment:8 Changed 3 years ago by Frédéric Chapoton

Milestone: sage-6.4sage-duplicate/invalid/wontfix
Status: newneeds_review

sagenb is now deprecated

comment:9 Changed 3 years ago by Karl-Dieter Crisman

Does this work on Jupyter? We could repurpose the ticket. And the syntax is "supposed to work" on platforms ...

comment:10 Changed 2 years ago by Matthias Köppe

Cc: Frédéric Chapoton added

Proposing to close all sagenb tickets as outdated, so that all remaining open tickets in the notebook component are about the Jupyter notebook.

comment:11 Changed 18 months ago by Dima Pasechnik

Reviewers: Dima Pasechnik
Status: needs_reviewpositive_review

comment:12 Changed 18 months ago by Karl-Dieter Crisman

Status: positive_reviewneeds_info

Again, does this work with Jupyter? If not, we might as well just turn this ticket into a Jupyter one to conform with comment:10. Else close, yes.

Changed 18 months ago by Dima Pasechnik

jupyter@…

comment:13 in reply to:  12 Changed 18 months ago by Dima Pasechnik

Description: modified (diff)
Status: needs_infopositive_review

Replying to kcrisman:

Again, does this work with Jupyter? If not, we might as well just turn this ticket into a Jupyter one to conform with comment:10. Else close, yes.

yes, it does work with Jupyter, see attachment

comment:14 Changed 18 months ago by Frédéric Chapoton

Resolution: invalid
Status: positive_reviewclosed
Note: See TracTickets for help on using tickets.