[Multiple Datasource] Pass selected data sources to plugin consumers when the multi-select component initially loads#6333
Merged
bandinib-amzn merged 3 commits intoopensearch-project:mainfrom Apr 3, 2024
Conversation
Signed-off-by: Huy Nguyen <73027756+huyaboo@users.noreply.github.com>
Signed-off-by: Huy Nguyen <73027756+huyaboo@users.noreply.github.com>
BionIT
approved these changes
Apr 3, 2024
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #6333 +/- ##
=======================================
Coverage 67.49% 67.50%
=======================================
Files 3376 3376
Lines 65798 65800 +2
Branches 10639 10639
=======================================
+ Hits 44413 44415 +2
Misses 18801 18801
Partials 2584 2584
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
bandinib-amzn
approved these changes
Apr 3, 2024
opensearch-trigger-bot bot
pushed a commit
that referenced
this pull request
Apr 3, 2024
…when the multi-select component initially loads (#6333) * Add callback function to initial load Signed-off-by: Huy Nguyen <73027756+huyaboo@users.noreply.github.com> * Add to CHANGELOG Signed-off-by: Huy Nguyen <73027756+huyaboo@users.noreply.github.com> --------- Signed-off-by: Huy Nguyen <73027756+huyaboo@users.noreply.github.com> (cherry picked from commit cb24346) Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> # Conflicts: # CHANGELOG.md
zhongnansu
pushed a commit
that referenced
this pull request
Apr 3, 2024
…when the multi-select component initially loads (#6333) (#6335) * Add callback function to initial load Signed-off-by: Huy Nguyen <73027756+huyaboo@users.noreply.github.com> * Add to CHANGELOG Signed-off-by: Huy Nguyen <73027756+huyaboo@users.noreply.github.com> --------- Signed-off-by: Huy Nguyen <73027756+huyaboo@users.noreply.github.com> (cherry picked from commit cb24346) Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> # Conflicts: # CHANGELOG.md Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This was referenced Apr 22, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
The multi-selectable component does not call the callback function on initial load of the component. This means that plugins cannot initially fetch the dataSourceIds when first rendering the page. This PR makes a call to the callback function upon
componentDidMount()Issues Resolved
Closes #6324
Screenshot
Screen.Recording.2024-04-03.at.11.29.24.AM.mov
Testing the changes
In the
multi-selectcomponent, aconsole.log()statement was added to the callback function and this callback function was passed into themulti-selectcomponent. Because the log statement was called without any selection changes, it shows that the callback function was called when themulti-selectcomponent initially loaded.Check List
yarn test:jestyarn test:jest_integration