- From: David MacDonald <david100@sympatico.ca>
- Date: Fri, 15 Feb 2019 14:24:45 -0500
- To: Bryan Garaventa <bryan.garaventa@levelaccess.com>
- Cc: James Nurthen <nurthen@adobe.com>, "public-aria@w3.org" <public-aria@w3.org>
- Message-ID: <CAAdDpDbfnCXso7JbUv_OANEW-UOP5=VkpJskLrtjqVXqz3yhiA@mail.gmail.com>
Yup that works for me. http://davidmacd.com/widgets/name-description-calculator/name-description-calculator3.html Cheers, David MacDonald *Can**Adapt* *Solutions Inc.* Tel: 613-806-9005 LinkedIn <http://www.linkedin.com/in/davidmacdonald100> twitter.com/davidmacd GitHub <https://github.com/DavidMacDonald> www.Can-Adapt.com <http://www.can-adapt.com/> * Adapting the web to all users* * Including those with disabilities* If you are not the intended recipient, please review our privacy policy <http://www.davidmacd.com/disclaimer.html> On Fri, Feb 15, 2019 at 1:30 PM Bryan Garaventa < bryan.garaventa@levelaccess.com> wrote: > You could, but as it’s currently set up it only checks for one instance > when the button is clicked and reports that, so if multiple form fields are > meant to be tested like when tabbing around, then it would be necessary to > add an event listener to the document, which could be done by adding a > onfocusin handler to the container where the markup is inserted within, > which would check for the element that currently has focus and then send it > to the callback for reporting the computed name. > > > > E.G By adding this to the focusin handler should do the trick I think. > > > > document.getElementById('calcTextStr').innerHTML = getNames(event.target); > > > > The getNames function is the function already added for returning the > human redable string, but you can easily create your own by referencing the > core calcNames function that does the computation directly like so. > > > > var props = calcNames(node); > > > > props.name // Accessible Name > > props.desc // Accessible Description > > > > Then you can arrange this however you like. > > > > > > > > > > Bryan Garaventa > > Principal Accessibility Architect > > Level Access, Inc. > > Bryan.Garaventa@LevelAccess.com > > 415.624.2709 (o) > > www.LevelAccess.com <http://www.levelaccess.com/> > > > > *From:* James Nurthen <nurthen@adobe.com> > *Sent:* Friday, February 15, 2019 9:57 AM > *To:* David MacDonald <david100@sympatico.ca>; Bryan Garaventa < > bryan.garaventa@levelaccess.com> > *Cc:* public-aria@w3.org > *Subject:* Re: AccName utility for live AccName algorithm testing on the > fly > > > > *CAUTION:* This email originated from outside of the organization. Do not > click links or open attachments unless you recognize the sender and know > the content is safe. > > > > While this sounds like a nice enhancement, wouldn’t the simplest fix for > the cited problem to be to use a different attribute? Perhaps add > data-testnode=”true” to the node you want to test then modify the script to > look for that? > > > > *James Nurthen* | Accessibility Engineer | Adobe | p. > 415.832.2734 | c. 415.987.1918 | nurthen@adobe.com > > > > > > > > *From: *David MacDonald <david100@sympatico.ca> > *Date: *Friday, February 15, 2019 at 8:47 AM > *To: *Bryan Garaventa <bryan.garaventa@levelaccess.com> > *Cc: *"public-aria@w3.org" <public-aria@w3.org> > *Subject: *Re: AccName utility for live AccName algorithm testing on the > fly > *Resent-From: *<public-aria@w3.org> > *Resent-Date: *Friday, February 15, 2019 at 8:47 AM > > > > Hi Bryan > > > > I really like the idea. One thing that might make it easier for me to use > to use is to find a way to make it work without having to add id=test to > the node, which in some cases requires the label referencing to be > adjusted. I think this could be overcome by having the computed value > section listen to the focused element inside the sandbox area where the > rendered code is showing. > > This way a developer could dump in a whole form into the tool, tab around > and see the computed value for whatever has focus. > > > > Cheers, > David MacDonald > > > > *Can**Adapt* *Solutions Inc.* > > Tel: 613-806-9005 > > LinkedIn > <http://www.linkedin.com/in/davidmacdonald100> > > twitter.com/davidmacd > > GitHub <https://github.com/DavidMacDonald> > > www.Can-Adapt.com <http://www.can-adapt.com/> > > > > * Adapting the web to all users* > > * Including those with disabilities* > > > > If you are not the intended recipient, please review our privacy policy > <http://www.davidmacd.com/disclaimer.html> > > > > > > On Thu, Feb 14, 2019 at 9:50 PM Bryan Garaventa < > bryan.garaventa@levelaccess.com> wrote: > > Hi, > I wanted to share this AccName page that was recently enhanced by Todd > Briley. > > https://whatsock.github.io/w3c-alternative-text-computation/Editable%20Live%20Input%20AccName%20Test.html > > Instead of presenting a static page, it allows you to paste or type > whatever markup that you wish to compute the AccName for directly into the > page, which you can then dynamically load and test without having to edit > the page or reload it. This is a great way to quickly validate markup on > the fly while also referencing the latest AccName Prototype code on GitHub. > This too has been added to the 'docs' folder within the main GitHub repo > for reference. > > A quick note, you have to include id="test" on the root node that you are > computing the AccName for, otherwise the script will not know which element > you are trying to calculate. Simply write the markup you wish to process > into the edit field at the end of the page, then click the Paste and Test > button. > > If anybody else would like to contribute with related tools and utilities, > please let me know. All help is welcome. > > All the best, > Bryan > > > Bryan Garaventa > Principal Accessibility Architect > Level Access, Inc. > Bryan.Garaventa@LevelAccess.com > 415.624.2709 (o) > www.LevelAccess.com > >
Received on Friday, 15 February 2019 19:25:21 UTC