Hi,

Unfortunately the accordion widget is a bit underdeveloped. A few more
comments below.

On Mon, Jul 3, 2017 at 2:42 PM, Peter Uhnák <i.uh...@gmail.com> wrote:

> Hi,
>
> I'm playing around with Glamour and accordion presentation, however there
> are couple things I'm struggling with.
>
> I have a simple presentation:
>
> ```
> | browser data|
> data := {
> 'First' -> #(1 2 3).
> 'Second' -> #(a b c).
> 'Third' -> #(A B C).
> 'Fourth' -> #(! @ #'#').
> }.
>
> browser := GLMTabulator new.
> browser column: #accordion.
> browser transmit to: #accordion; andShow: [ :a |
> a accordionArrangement.
> a title: 'Accordion'.
> data do: [ :pair |
> a fastList
> title: pair key;
> display: pair value
> ].
> a list.
> ].
>
> browser openOn: #().
> ```
>
>
>
>
> * Is it possible to tell the accordion to not take more space than is
> needed? E.g. after item 3, and after item $c there's lot of empty space.
> * Is it possible to close accordions upwards? I have added an empty list
> at the end to consume extra white space, but it is insufficient (see point
> above) and ugly.
> * Is it possible to control which accordions are opened/closed by default?
> * Is it possible to connect all the lists so only one item can be selected
> at any time? Currently I can select independently in the lists.
>

I don't think any of the above things are supported by the current
accordion implementation. The current implementation is
in GLMMorphicAccordionRenderer>>render:. It's quite small and it could use
some improvements.

* Is it possible to build the lists from the input data (=openOn: XXX)? I
> can fill the data, but if I am making multiple lists then I am lost.
>

You should be able. The #andShow: block can take as a second parameter the
value passed on the entity port (so the value passed to openOn: in your
case)

Cheers,
Andrei


>
> (I could use tree to fix most of the problems, but Accordion looks much
> nicer :))
>
> Any pointers appreciated,
> Peter
>
> _______________________________________________
> Moose-dev mailing list
> moose-...@list.inf.unibe.ch
> https://www.list.inf.unibe.ch/listinfo/moose-dev
>
>

Reply via email to