Opened 9 years ago

Closed 3 months ago

#14020 closed defect (invalid)

interact with layout is broken

Reported by: novoselt Owned by: jason, mpatel, was
Priority: major Milestone: sage-duplicate/invalid/wontfix
Component: notebook Keywords: interact sd48
Cc: jason, kcrisman, chapoton Merged in:
Authors: Reviewers: Dima Pasechnik
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description (last modified by dimpase)

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 dimpase 4 months ago.
jupyter@…

Download all attachments as: .zip

Change History (15)

comment:1 Changed 9 years ago by kcrisman

  • Cc kcrisman added

comment:2 Changed 8 years ago by novoselt

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

comment:3 Changed 8 years ago by novoselt

  • Keywords sd48 added

comment:4 Changed 8 years ago by jdemeyer

  • Milestone changed from sage-5.11 to sage-5.12

comment:5 Changed 8 years ago by vbraun_spam

  • Milestone changed from sage-6.1 to sage-6.2

comment:6 Changed 7 years ago by vbraun_spam

  • Milestone changed from sage-6.2 to sage-6.3

comment:7 Changed 7 years ago by vbraun_spam

  • Milestone changed from sage-6.3 to sage-6.4

comment:8 Changed 19 months ago by chapoton

  • Milestone changed from sage-6.4 to sage-duplicate/invalid/wontfix
  • Status changed from new to needs_review

sagenb is now deprecated

comment:9 Changed 19 months ago by kcrisman

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

comment:10 Changed 13 months ago by mkoeppe

  • Cc 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 4 months ago by dimpase

  • Reviewers set to Dima Pasechnik
  • Status changed from needs_review to positive_review

comment:12 follow-up: Changed 4 months ago by kcrisman

  • Status changed from positive_review to needs_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 4 months ago by dimpase

jupyter@…

comment:13 in reply to: ↑ 12 Changed 4 months ago by dimpase

  • Description modified (diff)
  • Status changed from needs_info to positive_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 3 months ago by chapoton

  • Resolution set to invalid
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.