How to make some sections opened/closed by default when displaying a form

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

How to make some sections opened/closed by default when displaying a form

Miklos Balazs
Hi everyone,

I have a simple question that I could'nt find the answer for: I have a fairly large form with many sections, but some sections are less important than others.
I would like to specify (in the form definition) that some of the sections should be shown as closed by default. So the user would have to open those sections first by clicking on their headers to see their contents.
Is this possible?

Regards,
Miklos

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Reply | Threaded
Open this post in threaded view
|

Re: How to make some sections opened/closed by default when displaying a form

Alessandro  Vernet
Administrator
Hi Miklos,

It isn't possible out-of-the-box. But it would be good to have, so I added an RFE for this:

https://github.com/orbeon/orbeon-forms/issues/1448

If you're OK editing the form, you can achieve this by adding open="false" on the <fr:section> for the sections you want to closed by default. (So this is supported at runtime, but there is no UI in Form Builder to configure this.)

Alex
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
Reply | Threaded
Open this post in threaded view
|

Re: How to make some sections opened/closed by default when displaying a form

Stian Sigvartsen
In reply to this post by Miklos Balazs
Hi Alex
I've been having similar thoughts. If we make the change you suggested
to Miklos, will this be honoured/persisted by future saving of the form
definition via Form Builder?

Stian


-----Original Message-----
From: Alessandro Vernet [mailto:[hidden email]]
Sent: 19 November 2013 21:59
To: [hidden email]
Subject: [orbeon] Re: How to make some sections opened/closed by default
when displaying a form

Hi Miklos,

It isn't possible out-of-the-box. But it would be good to have, so I
added an RFE for this:

https://github.com/orbeon/orbeon-forms/issues/1448

If you're OK editing the form, you can achieve this by adding
open="false"
on the <fr:section> for the sections you want to closed by default. (So
this is supported at runtime, but there is no UI in Form Builder to
configure
this.)

Alex

-----
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
--
View this message in context:
http://discuss.orbeon.com/How-to-make-some-sections-opened-closed-by-def
ault-when-displaying-a-form-tp4657658p4657674.html
Sent from the Orbeon Forms community mailing list mailing list archive
at Nabble.com.

--
You received this message because you are subscribed to the Google
Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to [hidden email].
To post to this group, send email to [hidden email].

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Reply | Threaded
Open this post in threaded view
|

Re: How to make some sections opened/closed by default when displaying a form

Miklos Balazs
In reply to this post by Alessandro Vernet
Hi Alex,

Thanks for the answer. Having to edit the XML by hand is perfectly acceptable by me.

BTW, I have a suggestion on how should this work in a very intuitive way: when the editor closes a section in form builder, the respective open="false" attribute should be added to the XML, and removed when he or she opens the section again. This way there would be no need to develop any additional UI for this in form builder. And in the end, this solution follows the WYSIWYG principle, because the deployed form would look like what the editor saw.

Regards,
Miklos

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Reply | Threaded
Open this post in threaded view
|

Re: How to make some sections opened/closed by default when displaying a form

Erik Bruchez
Administrator
In reply to this post by Stian Sigvartsen
Stian,

Yes, Form Builder does not touch that attribute (if it does, it's a bug ;).

-Erik
Reply | Threaded
Open this post in threaded view
|

Re: How to make some sections opened/closed by default when displaying a form

Erik Bruchez
Administrator
In reply to this post by Miklos Balazs
Miklos,

That could make sense. There is just one twist: for performance reasons, when very large forms are opened in the builder, we automatically close some sections. However you might not want these sections to be closed at runtime.

-Erik
Reply | Threaded
Open this post in threaded view
|

Re: How to make some sections opened/closed by default when displaying a form

Stian Sigvartsen
In reply to this post by Miklos Balazs
Miklos,

I would suggest that although I am a big fan on WYSIWYG editors and I
agree with what you say in principle, I don't think this approach would
be appropriate in practice.
When editing very large forms the form author may find it
convenient/necessary to collapse sections of the form that they are not
editing. So if the editing experience is so directly linked to the
end-user/customer experience then the form author would need to remember
to expand the right sections again before saving & publishing. I am
concerned that the two types of users are motivated by different things
and mistakes are going to be made too easily. I think the
expand/collapse section settings should be a bit more explicit. What do
you think?

Erik, thanks for confirming the attribute will be left untouched
(hopefully ;)

-Stian

-----Original Message-----
From: Erik Bruchez [mailto:[hidden email]]
Sent: 20 November 2013 17:56
To: [hidden email]
Subject: [orbeon] Re: How to make some sections opened/closed by default
when displaying a form

Miklos,

That could make sense. There is just one twist: for performance reasons,
when very large forms are opened in the builder, we automatically close
some sections. However you might not want these sections to be closed at
runtime.

-Erik

--
View this message in context:
http://discuss.orbeon.com/How-to-make-some-sections-opened-closed-by-def
ault-when-displaying-a-form-tp4657658p4657685.html
Sent from the Orbeon Forms community mailing list mailing list archive
at Nabble.com.

--
You received this message because you are subscribed to the Google
Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to [hidden email].
To post to this group, send email to [hidden email].

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Reply | Threaded
Open this post in threaded view
|

Re: How to make some sections opened/closed by default when displaying a form

Erik Bruchez
Administrator
Stian,

You said it better than I did, and I agree that the two aspects should probably remain separate.

Regards,

-Erik