Skip to content

Commit

Permalink
rough draft for Issue #691: attribute reflection
Browse files Browse the repository at this point in the history
  • Loading branch information
cookiecrook committed Feb 12, 2018
1 parent fd8621d commit ae6cb52
Showing 1 changed file with 89 additions and 9 deletions.
98 changes: 89 additions & 9 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -74,21 +74,20 @@
companyURI: "http://www.w3.org",
w3cid: 34017
},
{ name: "Richard Schwerdtfeger",
mailto: "schwer@us.ibm.com",
company: "IBM Corporation",
companyURI: "http://www.ibm.com/",
w3cid: 2460,
note: "until October 2017"
},
{
name: "James Craig",
url: 'https://www.apple.com',
url: 'https://www.apple.com/accessibility/',
mailto: "jcraig@apple.com",
company: "Apple Inc.",
companyURI: "https://www.apple.com",
w3cid: 42459,
note: "until May 2016"
},
{ name: "Richard Schwerdtfeger",
mailto: "schwer@us.ibm.com",
company: "IBM Corporation",
companyURI: "http://www.ibm.com/",
w3cid: 2460,
note: "until October 2017"
}
],

Expand Down Expand Up @@ -10975,6 +10974,87 @@ <h2>State and Property Attribute Processing</h2>
<p>Sometimes states and properties are present in the DOM but have a zero-length string ("") as their value. This is equivalent to their absence. User agents SHOULD treat state and property attributes with a value of "" the same as they treat an absent attribute. For supported states and properties, this corresponds to the default value, but if it is a required attribute, it signals an author error, and the implicit value for the role is used. </p>
</section>
</section>
<section id="dom-interface" class="normative">
<h2>DOM Interface</h2>
<div class="ednote">
<p>This is pretty rough. Pushing a branch mainly to see if people think creating a new section is the right choice, or if these should be worked into the respective Role and States/Props sections, with an IDL index list. ReSpec automatic listing would work on single-page version, but maybe not the split versions. -jc</p>
<p>Remember to:</p>
<ul>
<li>Write intro for the IDL section, including example usage in JavaScript.</li>
<li>Note that "tabIndex" IDL is defined elsewhere.</li>
<li>Fix all the ReSpec errors.</li>
<li>Update the changelog.</li>
</ul>
</div>

<section id="web-idl" class="normative">
<h2>WebIDL Definition</h2>
<p>The <code><dfn data-cite="https://www.w3.org/TR/dom/#interface-element">Element</dfn></code> interface is defined by the W3C [[DOM]].</p>
<pre class="idl">
partial interface Element {
// Does role need to be defined in a different spec?
attribute DOMString role;
};
</pre>
<pre class="idl">
partial interface Element {
attribute DOMString ariaActiveDescendant;
attribute DOMString ariaAtomic;
attribute DOMString ariaAutoComplete;
attribute DOMString ariaBusy;
attribute DOMString ariaChecked;
attribute DOMString ariaColCount;
attribute DOMString ariaColIndex;
attribute DOMString ariaColSpan;
attribute DOMString ariaControls;
attribute DOMString ariaCurrent;
attribute DOMString ariaDescribedBy;
attribute DOMString ariaDetails;
attribute DOMString ariaDisabled;
attribute DOMString ariaErrorMessage;
attribute DOMString ariaExpanded;
attribute DOMString ariaFlowTo;
attribute DOMString ariaHasPopup;
attribute DOMString ariaHidden;
attribute DOMString ariaInvalid;
attribute DOMString ariaKeyShortcuts;
attribute DOMString ariaLabel;
attribute DOMString ariaLabelledBy;
attribute DOMString ariaLevel;
attribute DOMString ariaLive;
attribute DOMString ariaModal;
// Note: @aria-multiline reflected as ariaMultiline, not ariaMultiLine.
attribute DOMString ariaMultiline;
// Note: @aria-multiselectable reflected as ariaMultiselectable, not ariaMultiSelectable.
attribute DOMString ariaMultiselectable;
attribute DOMString ariaOrientation;
attribute DOMString ariaOwns;
// Note: @aria-placeholder reflected as ariaPlaceholder, not ariaPlaceHolder.
attribute DOMString ariaPlaceholder;
// Note: @aria-posinset reflected as ariaPosInSet, not ariaPosInset.
attribute DOMString ariaPosInSet;
attribute DOMString ariaPressed;
// Note: @aria-readonly reflected as ariaReadonly, not ariaReadOnly.
attribute DOMString ariaReadonly;
attribute DOMString ariaRelevant;
attribute DOMString ariaRequired;
attribute DOMString ariaRoleDescription;
attribute DOMString ariaRowCount;
attribute DOMString ariaRowIndex;
attribute DOMString ariaRowSpan;
attribute DOMString ariaSelected;
attribute DOMString ariaSetSize;
attribute DOMString ariaSort;
attribute DOMString ariaValueMax;
attribute DOMString ariaValueMin;
attribute DOMString ariaValueNow;
attribute DOMString ariaValueText;
};
</pre>
</section>
<p>Note: Attributes <pref>aria-dropeffect</pref> and <sref>aria-grabbed</sref> were deprecated in ARIA 1.1 and do not have reflected DOM properties.</p>
<div class="ednote"><p>Seems harmless to include these two deprecated attrs as IDL props, so if anyone has a strong preference, we could include them. On the flip-side, we could add some normative requirement to avoid them, "Implementors SHOULD NOT create new implementions of deprecated attributes." -jc</p></div>
</section>
<section class="appendix informative" id="a_schemata">
<h1>Schemata</h1>
<p>WAI-ARIA roles, states, and properties are available in a number of machine-readable formats to support validation of content using WAI-ARIA attributes. WAI-ARIA is not finalized, however, so these files are subject to change without notice. <span class="todo">Todo: Remove disclaimers about not final at rec.</span></p>
Expand Down

0 comments on commit ae6cb52

Please sign in to comment.