Output to the user

We have three ways of outputting to the user:

1. Control <output/> with @ref and @value
    Attribute: @appearance
    Extra attribute: @mediatype

2. Action <message/> with @ref and @value
    Extra attribute: level (modal, modeless, ephemeral)

3. Control <dialog/>
    Attribute: @appearance
    Extra attributes: level (as above), hide (true/false).

    + 2 new actions <show/> <hide/>
    + 2 new events  xforms-dialog-show, xforms-dialog-hide

What worries me about these is the lack of consistency, and the lack of  
underlying model.

Visibility is (nearly) always controlled by relevance in XForms, and from  
that point of view, I don't really see the advantage of <dialog/> over  
what we already have, with an extra layer of generality.

For instance, instead of

<dialog id="my-dialog" label="Please enter your information">
   <input ref="first-name" label="First Name:"/>
   <input ref="last-name"  label="Last Name:"/>
   <input ref="e-mail" label="E-mail:"/>
   <trigger label="Submit">
     <hide ev:event="DOMActivate" dialog="my-dialog"/>
   </trigger>
</dialog>

why not

<group level="modal" ref="visible" label="Please enter your information">
   <input ref="first-name" label="First Name:"/>
   <input ref="last-name"  label="Last Name:"/>
   <input ref="e-mail" label="E-mail:"/>
   <trigger label="Submit">
     <setvalue ev:event="DOMActivate" ref="visible" value="0"/>
   </trigger>
</group>

or

<switch level="modal" label="Please enter your information">
   <case id="hidden"/>
   <case id="visible">
      <input ref="first-name" label="First Name:"/>
      <input ref="last-name"  label="Last Name:"/>
      <input ref="e-mail" label="E-mail:"
      <trigger label="Submit">
        <toggle ev:event="DOMActivate" case="hidden"/>
      </trigger>
</switch>

(or the equivalent @caseref version).

That is to say, all these new examples have done is added @level in order  
to make the control modal. No new actions, no new events, same effect.

Steven

Received on Wednesday, 22 February 2017 13:36:53 UTC