Skip to content

[DRAFT] Allowing EuiFormRow props on EuiFieldText - #3837

Closed
cchaos wants to merge 19 commits into
elastic:mainfrom
cchaos:poc/input_with_label
Closed

cchaos wants to merge 19 commits into
elastic:mainfrom
cchaos:poc/input_with_label

Conversation

@cchaos

@cchaos cchaos commented Jul 30, 2020 •

Copy link
Copy Markdown
Contributor

Ref #2493

This is just a quick POC of Establishing a pattern of how we can extend EuiFormRow props on each input field component so that they can personally handle the correct values to pass down to EuiFormRow.

This doesn't explicitly "fix" all the issues from the referenced ticket, but it just showcase my idea of how easy it could be to not break current implementations but allow people to convert to the new format.

Screen Shot 2020-07-30 at 16 56 13 PM

Screen Shot 2020-07-30 at 16 56 24 PM

@cchaos
cchaos marked this pull request as draft July 30, 2020 20:59
@cchaos cchaos mentioned this pull request Jul 30, 2020
1 task
@kibanamachine

Copy link
Copy Markdown
Contributor

@myasonik

Copy link
Copy Markdown
Contributor

This seems pretty straightforward and works well! Migrating to this as EUI's recommended approach I think would pay big dividends down the line 👍 👍

@kibanamachine

Copy link
Copy Markdown
Contributor

@cchaos
cchaos changed the base branch from master to feature/inputs_with_label October 20, 2020 17:48
@cchaos cchaos changed the title POC: Allowing EuiFormRow props on EuiFieldText [Feature branch] Allowing EuiFormRow props on EuiFieldText Oct 20, 2020
@kibanamachine

Copy link
Copy Markdown
Contributor

@kibanamachine

Copy link
Copy Markdown
Contributor

@kibanamachine

Copy link
Copy Markdown
Contributor

# Conflicts:
#	src-docs/src/services/playground/_playground_compiler.scss
#	src-docs/src/services/playground/knobs.js
#	src-docs/src/services/playground/playground.js
#	src-docs/src/views/button/playground.js
#	src-docs/src/views/form_controls/playground.js
#	src-docs/src/views/guidelines/writing.js
@cchaos
cchaos changed the base branch from feature/inputs_with_label to master March 20, 2021 22:14
@kibanamachine

Copy link
Copy Markdown
Contributor

@kibanamachine

Copy link
Copy Markdown
Contributor

@kibanamachine

Copy link
Copy Markdown
Contributor

@cchaos cchaos changed the title [Feature branch] Allowing EuiFormRow props on EuiFieldText [DRAFT] Allowing EuiFormRow props on EuiFieldText Mar 29, 2021
@myasonik
myasonik self-requested a review April 29, 2021 21:46
Comment on lines +119 to +128
const { finalNodes: prependNodes, finalNodeIDs: prependIDs } = renderSideNode(
'prepend',
id,
prepend
);
const { finalNodes: appendNodes, finalNodeIDs: appendIDs } = renderSideNode(
'append',
id,
append
);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome.

@myasonik myasonik left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for all the extra individual comment pings – I forgot how to use GitHub for a bit...

Just did an a11y focused review and this looks awesome – a great improvement for text fields and a great pattern to continue to emulate for other (more complicated) form controls as well.

Will do another code review focusing on the code bits. @thompsongl might like to as well.

@thompsongl
thompsongl self-requested a review May 3, 2021 17:40
@kibanamachine

Copy link
Copy Markdown
Contributor

@kibanamachine

Copy link
Copy Markdown
Contributor

@github-actions

github-actions Bot commented Aug 2, 2021

Copy link
Copy Markdown

👋 Hey there. This PR hasn't had any activity for 90 days. We'll automatically close it if that trend continues for another week. If you feel this issue is still valid and needs attention please let us know with a comment.

@github-actions github-actions Bot added the stale-pr (Don't delete - used for automation) label Aug 2, 2021
@cchaos cchaos removed the stale-pr (Don't delete - used for automation) label Aug 2, 2021
@kibanamachine

Copy link
Copy Markdown
Contributor

# Conflicts:
#	src-docs/src/views/flyout/flyout_max_width.js
#	src-docs/src/views/form_compressed/form_compressed.js
#	src-docs/src/views/form_compressed/form_horizontal.js
#	src-docs/src/views/form_compressed/form_horizontal_help.js
#	src-docs/src/views/form_layouts/described_form_group.js
#	src-docs/src/views/form_validation/validation.js
#	src-docs/src/views/i18n/context.js
#	src-docs/src/views/i18n/i18n_attribute.js
#	src/components/form/field_text/field_text.tsx
#	src/components/form/form_row/form_row.tsx
@kibanamachine

Copy link
Copy Markdown
Contributor

@kibanamachine

Copy link
Copy Markdown
Contributor

@github-actions

github-actions Bot commented Apr 6, 2022

Copy link
Copy Markdown

👋 Hey there. This PR hasn't had any activity for 90 days. We'll automatically close it if that trend continues for another week. If you feel this issue is still valid and needs attention please let us know with a comment.

@github-actions github-actions Bot added the stale-pr (Don't delete - used for automation) label Apr 6, 2022
@kibanamachine

Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot removed the stale-pr (Don't delete - used for automation) label Apr 6, 2022
@github-actions

github-actions Bot commented Jul 5, 2022

Copy link
Copy Markdown

👋 Hey there. This PR hasn't had any activity for 90 days. We'll automatically close it if that trend continues for another week. If you feel this issue is still valid and needs attention please let us know with a comment.

@github-actions github-actions Bot added the stale-pr (Don't delete - used for automation) label Jul 5, 2022
@github-actions

Copy link
Copy Markdown

❌ We're automatically closing this PR due to lack of activity. Please comment if you feel this was done in error.

@github-actions github-actions Bot added the stale-pr-closed (Don't delete - used for automation) label Jul 12, 2022
@github-actions github-actions Bot closed this Jul 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stale-pr (Don't delete - used for automation) stale-pr-closed (Don't delete - used for automation)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants