-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[Cases] Enhance labels in the bulk edit tags flyout #145811
Conversation
Pinging @elastic/response-ops (Team:ResponseOps) |
Pinging @elastic/response-ops-cases (Feature:Cases) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This works for me and the issue seems fixed.
However, I was playing around with the tags while testing and noticed that in the flyout we display the text:
Add whatever as a tag
- as a tag
But if we try to add a tag in the case creation or in the case detail views, the text is
Add whatever as a custom option
- as a custom option
It's not a big deal but maybe we could make these consistent in this PR?
Otherwise, looks good to me 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
UI changes look good.
@@ -51,3 +51,11 @@ export const SELECTED_TAGS = (selectedTags: number) => | |||
defaultMessage: 'Selected: {selectedTags}', | |||
values: { selectedTags }, | |||
}); | |||
|
|||
export const NO_TAGS_AVAILABLE = i18n.translate('xpack.cases.actions.tags.noTagsAvailable', { | |||
defaultMessage: 'No tags available. Type to add one.', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@lcawl Any suggestions for the text? I think we should indicate to the users that to add a tag they have to search.
I think the piece of info I was missing until I tested this myself was "where" we're asking them to type. I suggest changing the string to something like this:
defaultMessage: 'No tags available. Type to add one.', | |
defaultMessage: 'No tags available. To add a tag, type it in the query bar.', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, @lcawl! Sorry, I should explain better.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I received additional feedback from @gchaps recommending "enter" instead of "type":
defaultMessage: 'No tags available. Type to add one.', | |
defaultMessage: 'No tags available. To add a tag, enter it in the query bar.', |
Changes here LGTM, but taking a look on the case view: Now that we have user assignee functionality, should we be using the term Also have we lost some spacing vertically between the Reporter, Participants and Tags sections @mdefazio ? |
I think this has to do with some changes in the |
…-ref HEAD~1..HEAD --fix'
I agree that "assigned" is overloaded now, though I think we still want to follow the layout of the help text for the Assignees section since they're so close. For example: Was:
Should be:
If you want me to add that change as a commit in this PR, @cnasikas, just let me know! |
Thanks Lisa! I will do it. |
}); | ||
|
||
export const NO_SEARCH_MATCH = i18n.translate('xpack.cases.actions.tags.noTagsMatch', { | ||
defaultMessage: 'No tags available. To add a tag, type it in the query bar.', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think unless I've missed the discussion thread, this string should remain as it was in the initial commit (i.e. for the case where a search term doesn't match any tags):
defaultMessage: 'No tags available. To add a tag, type it in the query bar.', | |
defaultMessage: 'No tags match your search.', |
@@ -51,3 +51,11 @@ export const SELECTED_TAGS = (selectedTags: number) => | |||
defaultMessage: 'Selected: {selectedTags}', | |||
values: { selectedTags }, | |||
}); | |||
|
|||
export const NO_TAGS_AVAILABLE = i18n.translate('xpack.cases.actions.tags.noTagsAvailable', { | |||
defaultMessage: 'No tags available. Type to add one.', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I received additional feedback from @gchaps recommending "enter" instead of "type":
defaultMessage: 'No tags available. Type to add one.', | |
defaultMessage: 'No tags available. To add a tag, enter it in the query bar.', |
@@ -28,8 +28,7 @@ export const schema: FormSchema<AboutStepRule> = { | |||
helpText: i18n.translate( | |||
'xpack.securitySolution.detectionEngine.createRule.stepAboutRule.fieldAuthorHelpText', | |||
{ | |||
defaultMessage: | |||
'Type one or more authors for this rule. Press enter after each author to add a new one.', | |||
defaultMessage: 'Separate tags with a line break.', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cnasikas Hey Christos, I believe changes in this file should be reverted, or am I missing something?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@banderror You are right. @lcawl I will revert the changes related to the security solution as it is out of the scope of this PR.
💚 Build Succeeded
Metrics [docs]Async chunks
Page load bundle
Unknown metric groupsESLint disabled in files
ESLint disabled line counts
Total ESLint disabled count
History
To update your PR or re-run it, just comment with: cc @cnasikas |
## Summary This PR a) fixes the label when there are no tags, b) adds a label when there are no matches, c) removes a `useEffect` which is not necessary anymore, and d) shortens the help text for the tags field. Fixes: elastic#145214 ## Screenshots <img width="640" alt="Screenshot 2022-11-19 at 12 57 50 PM" src="https://user-images.githubusercontent.com/7871006/203005858-e7270771-4aaf-40a6-9174-306bacfb55fd.png"> <img width="639" alt="Screenshot 2022-11-19 at 12 45 55 PM" src="https://user-images.githubusercontent.com/7871006/203005874-6a42eff5-2c28-4962-8b53-58b2eb21b97e.png"> ### Checklist Delete any items that are not applicable to this PR. - [x] Any text added follows [EUI's writing guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses sentence case text and includes [i18n support](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md) - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios ### For maintainers - [x] This was checked for breaking API changes and was [labeled appropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process) Co-authored-by: lcawl <lcawley@elastic.co> Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com> (cherry picked from commit 6d9811e)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…146142) # Backport This will backport the following commits from `main` to `8.6`: - [[Cases] Enhance labels in the bulk edit tags flyout (#145811)](#145811) <!--- Backport version: 8.9.7 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Christos Nasikas","email":"christos.nasikas@elastic.co"},"sourceCommit":{"committedDate":"2022-11-23T12:56:44Z","message":"[Cases] Enhance labels in the bulk edit tags flyout (#145811)\n\n## Summary\r\n\r\nThis PR a) fixes the label when there are no tags, b) adds a label when\r\nthere are no matches, c) removes a `useEffect` which is not necessary\r\nanymore, and d) shortens the help text for the tags field.\r\n\r\nFixes: https://github.com/elastic/kibana/issues/145214\r\n\r\n## Screenshots\r\n\r\n<img width=\"640\" alt=\"Screenshot 2022-11-19 at 12 57 50 PM\"\r\nsrc=\"https://user-images.githubusercontent.com/7871006/203005858-e7270771-4aaf-40a6-9174-306bacfb55fd.png\">\r\n\r\n<img width=\"639\" alt=\"Screenshot 2022-11-19 at 12 45 55 PM\"\r\nsrc=\"https://user-images.githubusercontent.com/7871006/203005874-6a42eff5-2c28-4962-8b53-58b2eb21b97e.png\">\r\n\r\n\r\n### Checklist\r\n\r\nDelete any items that are not applicable to this PR.\r\n\r\n- [x] Any text added follows [EUI's writing\r\nguidelines](https://elastic.github.io/eui/#/guidelines/writing), uses\r\nsentence case text and includes [i18n\r\nsupport](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n### For maintainers\r\n\r\n- [x] This was checked for breaking API changes and was [labeled\r\nappropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)\r\n\r\nCo-authored-by: lcawl <lcawley@elastic.co>\r\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>","sha":"6d9811ec7dcd732bc6a5984c35cf628e8ca588f8","branchLabelMapping":{"^v8.7.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:skip","Team:ResponseOps","Feature:Cases","ui-copy","backport:prev-minor","v8.7.0"],"number":145811,"url":"https://github.com/elastic/kibana/pull/145811","mergeCommit":{"message":"[Cases] Enhance labels in the bulk edit tags flyout (#145811)\n\n## Summary\r\n\r\nThis PR a) fixes the label when there are no tags, b) adds a label when\r\nthere are no matches, c) removes a `useEffect` which is not necessary\r\nanymore, and d) shortens the help text for the tags field.\r\n\r\nFixes: https://github.com/elastic/kibana/issues/145214\r\n\r\n## Screenshots\r\n\r\n<img width=\"640\" alt=\"Screenshot 2022-11-19 at 12 57 50 PM\"\r\nsrc=\"https://user-images.githubusercontent.com/7871006/203005858-e7270771-4aaf-40a6-9174-306bacfb55fd.png\">\r\n\r\n<img width=\"639\" alt=\"Screenshot 2022-11-19 at 12 45 55 PM\"\r\nsrc=\"https://user-images.githubusercontent.com/7871006/203005874-6a42eff5-2c28-4962-8b53-58b2eb21b97e.png\">\r\n\r\n\r\n### Checklist\r\n\r\nDelete any items that are not applicable to this PR.\r\n\r\n- [x] Any text added follows [EUI's writing\r\nguidelines](https://elastic.github.io/eui/#/guidelines/writing), uses\r\nsentence case text and includes [i18n\r\nsupport](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n### For maintainers\r\n\r\n- [x] This was checked for breaking API changes and was [labeled\r\nappropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)\r\n\r\nCo-authored-by: lcawl <lcawley@elastic.co>\r\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>","sha":"6d9811ec7dcd732bc6a5984c35cf628e8ca588f8"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v8.7.0","labelRegex":"^v8.7.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/145811","number":145811,"mergeCommit":{"message":"[Cases] Enhance labels in the bulk edit tags flyout (#145811)\n\n## Summary\r\n\r\nThis PR a) fixes the label when there are no tags, b) adds a label when\r\nthere are no matches, c) removes a `useEffect` which is not necessary\r\nanymore, and d) shortens the help text for the tags field.\r\n\r\nFixes: https://github.com/elastic/kibana/issues/145214\r\n\r\n## Screenshots\r\n\r\n<img width=\"640\" alt=\"Screenshot 2022-11-19 at 12 57 50 PM\"\r\nsrc=\"https://user-images.githubusercontent.com/7871006/203005858-e7270771-4aaf-40a6-9174-306bacfb55fd.png\">\r\n\r\n<img width=\"639\" alt=\"Screenshot 2022-11-19 at 12 45 55 PM\"\r\nsrc=\"https://user-images.githubusercontent.com/7871006/203005874-6a42eff5-2c28-4962-8b53-58b2eb21b97e.png\">\r\n\r\n\r\n### Checklist\r\n\r\nDelete any items that are not applicable to this PR.\r\n\r\n- [x] Any text added follows [EUI's writing\r\nguidelines](https://elastic.github.io/eui/#/guidelines/writing), uses\r\nsentence case text and includes [i18n\r\nsupport](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n### For maintainers\r\n\r\n- [x] This was checked for breaking API changes and was [labeled\r\nappropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)\r\n\r\nCo-authored-by: lcawl <lcawley@elastic.co>\r\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>","sha":"6d9811ec7dcd732bc6a5984c35cf628e8ca588f8"}}]}] BACKPORT--> Co-authored-by: Christos Nasikas <christos.nasikas@elastic.co>
Summary
This PR a) fixes the label when there are no tags, b) adds a label when there are no matches, c) removes a
useEffect
which is not necessary anymore, and d) shortens the help text for the tags field.Fixes: #145214
Screenshots
Checklist
Delete any items that are not applicable to this PR.
For maintainers