Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug 1849148: disable addOnPaste in <SelectorInput> #5801

Merged
merged 1 commit into from Jun 23, 2020

Conversation

rhamilto
Copy link
Member

@rhamilto rhamilto commented Jun 22, 2020

Fix bug where pasted values such as openshift.io/run-level: '1' do not appear. Note this fix disables the ability to paste multiple values at the same time; however, the existing code assumes only one value is being added at a time, and if one of the values contains an invalid character, the entire paste fails (which is the underlying cause of the issue with a value like openshift.io/run-level: '1' since the space indicates more than more value).

Bonus fix: if the entered text was invalid, set the cursor back to black if the user deletes all the entered text (was staying red).

Strings copied/pasted in the screenshots below:

  1. openshift.io/run-level: '1'
  2. foo bar=bam baz=bam
  3. foo bar=bam baz=bam bam: bop

Before:
s74DbvULEJ

  1. Text is not pasted, but cursor turns red.
  2. Text is split on " " and converted to separate values.
  3. Text is not pasted, but cursor turns red.

After:
MuNcEx011z

  1. Text is pasted and turns red indicating there is a problem with the format.
  2. Text is pasted and turns red indicating there is a problem with the format.
  3. Text is pasted and turns red indicating there is a problem with the format.

Fix bug where pasted values such as `openshift.io/run-level: '1'` do not appear.  Note this fix disables the ability to paste multiple values at the same time; however, the existing code assumes only one value is being added at a time, and if one of the values contains an invalid character, the entire paste fails (which is the underlying cause of the issue with a value like `openshift.io/run-level: '1'` since the space indicates more than more value).
@openshift-ci-robot openshift-ci-robot added bugzilla/severity-low Referenced Bugzilla bug's severity is low for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. labels Jun 22, 2020
@openshift-ci-robot
Copy link
Contributor

@rhamilto: This pull request references Bugzilla bug 1849148, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.6.0) matches configured target release for branch (4.6.0)
  • bug is in the state ASSIGNED, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)

In response to this:

Bug 1849148: disable addOnPaste in

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci-robot openshift-ci-robot added component/core Related to console core functionality approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jun 22, 2020
@openshift-ci-robot
Copy link
Contributor

@rhamilto: This pull request references Bugzilla bug 1849148, which is valid.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.6.0) matches configured target release for branch (4.6.0)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)

In response to this:

Bug 1849148: disable addOnPaste in

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Copy link
Member

@spadgett spadgett left a comment

Choose a reason for hiding this comment

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

/approve
/lgtm

Thanks @rhamilto. I agree this is better

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Jun 23, 2020
@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: rhamilto, spadgett

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@rhamilto
Copy link
Member Author

/retest

@rhamilto
Copy link
Member Author

/cherry-pick release-4.5

@openshift-cherrypick-robot

@rhamilto: once the present PR merges, I will cherry-pick it on top of release-4.5 in a new PR and assign it to you.

In response to this:

/cherry-pick release-4.5

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@rhamilto
Copy link
Member Author

/retest

@openshift-merge-robot openshift-merge-robot merged commit 4b0e9ec into openshift:master Jun 23, 2020
@openshift-ci-robot
Copy link
Contributor

@rhamilto: All pull requests linked via external trackers have merged: openshift/console#5801. Bugzilla bug 1849148 has been moved to the MODIFIED state.

In response to this:

Bug 1849148: disable addOnPaste in

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-cherrypick-robot

@rhamilto: new pull request created: #5809

In response to this:

/cherry-pick release-4.5

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. bugzilla/severity-low Referenced Bugzilla bug's severity is low for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. component/core Related to console core functionality lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants