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

[Discover][Embeddable] Fix search highlighting #197607

Merged
merged 5 commits into from
Oct 25, 2024

Conversation

jughosta
Copy link
Contributor

@jughosta jughosta commented Oct 24, 2024

Summary

This PR fixes the search highlights for saved search panels on Dashboard.

Checklist

@jughosta jughosta added release_note:fix v9.0.0 Team:DataDiscovery Discover, search (e.g. data plugin and KQL), data views, saved searches. For ES|QL, use Team:ES|QL. v8.16.0 backport:version Backport to applied version labels v8.17.0 labels Oct 24, 2024
@jughosta jughosta self-assigned this Oct 24, 2024
@jughosta jughosta changed the title [Discover][Embeddable] Fix highlighting and don't calculate total hits [Discover][Embeddable] Fix search highlighting Oct 24, 2024
@jughosta jughosta marked this pull request as ready for review October 24, 2024 15:32
@jughosta jughosta requested a review from a team as a code owner October 24, 2024 15:32
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-data-discovery (Team:DataDiscovery)

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
discover 821.8KB 821.9KB +30.0B

History

cc @jughosta

Copy link
Contributor

@davismcphee davismcphee left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for fixing it!

@jughosta jughosta merged commit 2b645d5 into elastic:main Oct 25, 2024
22 checks passed
@jughosta jughosta deleted the 197195-fix-search-highlights branch October 25, 2024 07:01
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.16, 8.x

https://github.com/elastic/kibana/actions/runs/11513458512

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Oct 25, 2024
- Closes elastic#197195

## Summary

This PR fixes the search highlights for saved search panels on
Dashboard.

### Checklist

- [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

(cherry picked from commit 2b645d5)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Oct 25, 2024
- Closes elastic#197195

## Summary

This PR fixes the search highlights for saved search panels on
Dashboard.

### Checklist

- [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

(cherry picked from commit 2b645d5)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.16
8.x

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Oct 25, 2024
# Backport

This will backport the following commits from `main` to `8.x`:
- [[Discover][Embeddable] Fix search highlighting
(#197607)](#197607)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Julia
Rechkunova","email":"julia.rechkunova@elastic.co"},"sourceCommit":{"committedDate":"2024-10-25T07:01:22Z","message":"[Discover][Embeddable]
Fix search highlighting (#197607)\n\n- Closes
https://github.com/elastic/kibana/issues/197195\r\n\r\n##
Summary\r\n\r\nThis PR fixes the search highlights for saved search
panels on\r\nDashboard.\r\n\r\n\r\n### Checklist\r\n\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","sha":"2b645d56b76dd44f84e1c4c31a1336260513c6b2","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","v9.0.0","Team:DataDiscovery","v8.16.0","backport:version","v8.17.0"],"title":"[Discover][Embeddable]
Fix search highlighting
","number":197607,"url":"https://github.com/elastic/kibana/pull/197607","mergeCommit":{"message":"[Discover][Embeddable]
Fix search highlighting (#197607)\n\n- Closes
https://github.com/elastic/kibana/issues/197195\r\n\r\n##
Summary\r\n\r\nThis PR fixes the search highlights for saved search
panels on\r\nDashboard.\r\n\r\n\r\n### Checklist\r\n\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","sha":"2b645d56b76dd44f84e1c4c31a1336260513c6b2"}},"sourceBranch":"main","suggestedTargetBranches":["8.16","8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/197607","number":197607,"mergeCommit":{"message":"[Discover][Embeddable]
Fix search highlighting (#197607)\n\n- Closes
https://github.com/elastic/kibana/issues/197195\r\n\r\n##
Summary\r\n\r\nThis PR fixes the search highlights for saved search
panels on\r\nDashboard.\r\n\r\n\r\n### Checklist\r\n\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","sha":"2b645d56b76dd44f84e1c4c31a1336260513c6b2"}},{"branch":"8.16","label":"v8.16.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.x","label":"v8.17.0","branchLabelMappingKey":"^v8.17.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Julia Rechkunova <julia.rechkunova@elastic.co>
kibanamachine added a commit that referenced this pull request Oct 25, 2024
)

# Backport

This will backport the following commits from `main` to `8.16`:
- [[Discover][Embeddable] Fix search highlighting
(#197607)](#197607)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Julia
Rechkunova","email":"julia.rechkunova@elastic.co"},"sourceCommit":{"committedDate":"2024-10-25T07:01:22Z","message":"[Discover][Embeddable]
Fix search highlighting (#197607)\n\n- Closes
https://github.com/elastic/kibana/issues/197195\r\n\r\n##
Summary\r\n\r\nThis PR fixes the search highlights for saved search
panels on\r\nDashboard.\r\n\r\n\r\n### Checklist\r\n\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","sha":"2b645d56b76dd44f84e1c4c31a1336260513c6b2","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","v9.0.0","Team:DataDiscovery","v8.16.0","backport:version","v8.17.0"],"title":"[Discover][Embeddable]
Fix search highlighting
","number":197607,"url":"https://github.com/elastic/kibana/pull/197607","mergeCommit":{"message":"[Discover][Embeddable]
Fix search highlighting (#197607)\n\n- Closes
https://github.com/elastic/kibana/issues/197195\r\n\r\n##
Summary\r\n\r\nThis PR fixes the search highlights for saved search
panels on\r\nDashboard.\r\n\r\n\r\n### Checklist\r\n\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","sha":"2b645d56b76dd44f84e1c4c31a1336260513c6b2"}},"sourceBranch":"main","suggestedTargetBranches":["8.16","8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/197607","number":197607,"mergeCommit":{"message":"[Discover][Embeddable]
Fix search highlighting (#197607)\n\n- Closes
https://github.com/elastic/kibana/issues/197195\r\n\r\n##
Summary\r\n\r\nThis PR fixes the search highlights for saved search
panels on\r\nDashboard.\r\n\r\n\r\n### Checklist\r\n\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","sha":"2b645d56b76dd44f84e1c4c31a1336260513c6b2"}},{"branch":"8.16","label":"v8.16.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.x","label":"v8.17.0","branchLabelMappingKey":"^v8.17.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Julia Rechkunova <julia.rechkunova@elastic.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:version Backport to applied version labels release_note:fix Team:DataDiscovery Discover, search (e.g. data plugin and KQL), data views, saved searches. For ES|QL, use Team:ES|QL. v8.16.0 v8.17.0 v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Discover][Embeddable] Missing search highlights
4 participants