On Mar 20, 2012, at 6:04 PM, Boris Zbarsky wrote:

> On 3/20/12 6:50 PM, Adam Barth wrote:
>> I'm not sure<dialog>  addresses the same use cases as alert() and
>> confirm() because<dialog>  is significantly more complicated.
> 
> But also allows for much better UX...
> 
>> <dialog id="orderConfirm">
>> Are you sure you want to order the widget?
>> <button 
>> onclick="document.getElementById('orderConfirm').close(true);">Ok</button>
>> <button 
>> onclick="document.getElementById('orderConfirm').close(false);">Cancel</button>
> 
> Those should be "Yes" and "No" respectively, according to every single HIG 
> I've seen.  Something that's not possible with confirm(), unfortunately.

Mac OS X HIG recommends that the active option should be labeled with a 
meaningful verb or verb phrase, not just something generic like "OK" or "Yes". 
So the proper labels would be "Order" and "Cancel" in this example. 

reddit's login overlay, for example, actually meets the spirit of this 
requirement by having "create account", "login" and "close this window" as the 
available commands, though the layout is webby and consistent with the web app 
itself, rather than consistent with Mac UI conventions.

Regards,
Maciej

Reply via email to