1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/actiontext/test/dummy
Sean Doyle 614580270d Locate fill_in_rich_text_area by <label> text
This commit dovetails with [#38551] in its focus on improving the
ability to test calls to `rich_text_area` in accessibility-minded ways.

In addition to searching for `<trix-editor>` elements with the
appropriate [`aria-label`][aria-label] attribute, also support locating
elements that match the corresponding `<label>` element's text.

Now that [basecamp/trix#829][] has been merged and released, clicking on
`<label>` elements that reference `<trix-editor>` elements will move
focus into the `<trix-editor>` element.

There are still some accessible [label text][] improvements that could
be made, but extending `fill_in_rich_text_area` to account for `<label
for="...">` elements is a good start.

[#38551]: https://github.com/rails/rails/pull/38551
[aria-label]: https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_aria-label_attribute
[basecamp/trix#829]: https://github.com/basecamp/trix/pull/829
[label text]: https://github.com/basecamp/trix/pull/829#issuecomment-699119852
2020-10-02 18:02:14 -04:00
..
app Locate fill_in_rich_text_area by <label> text 2020-10-02 18:02:14 -04:00
bin require, require_relative, load by double quotes (#38841) 2020-03-29 16:30:52 -07:00
config Unify raise_on_missing_translations for views and controllers 2020-05-20 02:42:59 +03:00
db Track Active Storage variants in the database 2019-12-06 13:26:51 -05:00
lib/assets
log
public
storage
tmp
.browserslistrc Update Webpacker in Action Text's test dummy app 2019-05-11 20:27:37 -04:00
.postcssrc.yml
babel.config.js Update Webpacker in Action Text's test dummy app 2019-05-11 20:27:37 -04:00
config.ru require, require_relative, load by double quotes (#38841) 2020-03-29 16:30:52 -07:00
package.json Add ActionDispatch::SystemTestCase#fill_in_rich_text_area 2019-05-13 12:44:06 -04:00
postcss.config.js Update Webpacker in Action Text's test dummy app 2019-05-11 20:27:37 -04:00
Rakefile require, require_relative, load by double quotes (#38841) 2020-03-29 16:30:52 -07:00
yarn.lock Add ActionDispatch::SystemTestCase#fill_in_rich_text_area 2019-05-13 12:44:06 -04:00