From ee17fb03695a7b9247219eaaf203829d8dd6cc18 Mon Sep 17 00:00:00 2001 From: ddavison Date: Tue, 28 May 2019 09:16:35 -0700 Subject: Iteration for _field being the well-formed element Since number fields, text boxes, text areas are editable lets use _field as the vague descriptor --- qa/docs/guidelines.md | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'qa') diff --git a/qa/docs/guidelines.md b/qa/docs/guidelines.md index 433e66ec181..cd4b939fd71 100644 --- a/qa/docs/guidelines.md +++ b/qa/docs/guidelines.md @@ -59,9 +59,10 @@ We follow a simple formula roughly based on hungarian notation. - `_link` - `_tab` - `_dropdown` - - `_text` + - `_field` - `_checkbox` - `_radio` + - `_content` *Note: This list is a work in progress. This list will eventually be the end-all enumeration of all available types. I.e., any element that does not end with something in this list is bad form.* @@ -74,18 +75,16 @@ view '...' do element :edit_button element :notes_tab element :squash_checkbox + element :username_field + element :issue_title_content end ``` **Bad** ```ruby -view '...' do - # `_field` should be `_text`. - # Per the W3C Spec, field is too vague. `type='password'`, `type='hidden'` etc. - element :login_field - - # `_confirmation` should be `_text`. what sort of confirmation? a checkbox confirmation? no real way to disambiguate. - # an appropriate replacement would be `element :password_confirmation_text` +view '...' do + # `_confirmation` should be `_field`. what sort of confirmation? a checkbox confirmation? no real way to disambiguate. + # an appropriate replacement would be `element :password_confirmation_field` element :password_confirmation # `clone_options` is too vague. If it's a dropdown menu, it should be `clone_dropdown`. -- cgit v1.2.1