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

[Presentation] Deprecate Solution Toolbar Button in favor of Shared UX Component #126916

Closed
wants to merge 28 commits into from

Conversation

rshen91
Copy link
Contributor

@rshen91 rshen91 commented Mar 4, 2022

Summary

Related to #125998

The solution toolbar button was moved to the Shared UX team. This PR deprecates the solution toolbar button for the presentation team so that both components do not have to be maintained.

@rshen91 rshen91 added backport:skip This commit does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas Team:SharedUX Team label for AppEx-SharedUX (formerly Global Experience) v8.2.0 labels Mar 4, 2022
@rshen91 rshen91 marked this pull request as ready for review March 4, 2022 17:33
@rshen91 rshen91 requested a review from a team as a code owner March 4, 2022 17:33
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-presentation (Team:Presentation)

Copy link
Contributor

@ThomThomson ThomThomson left a comment

Choose a reason for hiding this comment

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

Change LGTM!

I'm wondering though, since it seems like this component is only used in Presentation Util itself, it could be quite trivial to migrate to the version in shared UX immediately, and remove the version in presentation_util.

Is there a reason to leave it deprecated for a while? Or should we think about removing it ASAP?

@rshen91 rshen91 requested a review from a team March 9, 2022 15:23
@rshen91 rshen91 requested a review from a team as a code owner March 9, 2022 15:23
Copy link
Contributor

@mdefazio mdefazio left a comment

Choose a reason for hiding this comment

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

Fine on our end...just seeing the scss file deletions for our review.

"embeddable",
"expressions",
"dataViews",
"sharedUx"
Copy link
Contributor

Choose a reason for hiding this comment

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

The plugin's name is sharedUX; I think that's why the build went crazy.

@@ -25,6 +25,12 @@ export const LazySolutionToolbarButton = React.lazy(() =>
}))
);

export const LazySolutionToolbarButtonProps = React.lazy(() =>
import('./toolbar/index').then(({ SolutionToolbarButtonProps }: any) => ({
Copy link
Contributor

Choose a reason for hiding this comment

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

Two things: first, this should exist.

LazySolutionToolbarButtonProps is a Typescript interface, so there's no lazy load necessary-- types are removed at compile time.

Second, as @majagrubic pointed out: no need to tack /index onto this import.

@@ -39,6 +45,8 @@ export const ExitFullScreenButton = withSuspense(LazyExitFullScreenButton);
*/
export const SolutionToolbarButton = withSuspense(LazySolutionToolbarButton);

export const SolutionToolbarButtonProps = withSuspense(LazySolutionToolbarButtonProps);
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
export const SolutionToolbarButtonProps = withSuspense(LazySolutionToolbarButtonProps);

@@ -18,7 +18,7 @@
"embeddable",
"expressions",
"dataViews",
"sharedUx"
"sharedUX"
Copy link
Contributor

Choose a reason for hiding this comment

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

For plugin ids we have historically kept to the most simple form of camelcase, and only capitalized the first letter in an abbreviation. Said another way, the capital just replaces the _ in the snake_case version of the word, so shared_ux would be come sharedUx

Copy link
Contributor

Choose a reason for hiding this comment

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

Oh, I was confused about which PR this is, maybe @clintandrewhall is open to a rename PR outside of this work or maybe when the number of inflight PRs is a bit lower.

@kibana-ci
Copy link
Collaborator

kibana-ci commented Mar 16, 2022

💔 Build Failed

Failed CI Steps

Test Failures

  • [job] [logs] OSS Accessibility Tests / a11y tests using flights sample data Dashboard create dashboard button
  • [job] [logs] OSS Accessibility Tests / a11y tests using flights sample data Dashboard create dashboard button
  • [job] [logs] Default Firefox Tests / Canvas app smoke test loads workpage when clicked
  • [job] [logs] Default CI Group #2 / Canvas app smoke test loads workpage when clicked
  • [job] [logs] Default Firefox Tests / Canvas app smoke test loads workpage when clicked
  • [job] [logs] Default CI Group #2 / Canvas app smoke test loads workpage when clicked
  • [job] [logs] OSS CI Group #1 / context app context link in discover navigates to doc view from embeddable
  • [job] [logs] OSS CI Group #1 / context app context link in discover navigates to doc view from embeddable
  • [job] [logs] OSS CI Group #6 / dashboard app new charts library dashboard state "after all" hook for "Saved search will update when the query is changed in the URL"
  • [job] [logs] OSS CI Group #6 / dashboard app new charts library dashboard state "after all" hook for "Saved search will update when the query is changed in the URL"
  • [job] [logs] OSS CI Group #6 / dashboard app new charts library dashboard state Overriding colors on an area chart is preserved
  • [job] [logs] OSS CI Group #6 / dashboard app new charts library dashboard state Overriding colors on an area chart is preserved
  • [job] [logs] OSS CI Group #2 / dashboard app using current data empty dashboard "after all" hook for "should open editor menu when editor button is clicked"
  • [job] [logs] OSS CI Group #2 / dashboard app using current data empty dashboard "after all" hook for "should open editor menu when editor button is clicked"
  • [job] [logs] OSS CI Group #2 / dashboard app using current data empty dashboard "before all" hook for "should display empty widget"
  • [job] [logs] OSS CI Group #2 / dashboard app using current data empty dashboard "before all" hook for "should display empty widget"
  • [job] [logs] OSS CI Group #3 / dashboard app using current data full screen mode available in view mode
  • [job] [logs] OSS CI Group #3 / dashboard app using current data full screen mode available in view mode
  • [job] [logs] OSS CI Group #5 / dashboard app using legacy data dashboard save warns on duplicate name for new dashboard
  • [job] [logs] OSS CI Group #5 / dashboard app using legacy data dashboard save warns on duplicate name for new dashboard
  • [job] [logs] OSS Firefox Tests / dashboard app using legacy data dashboard save warns on duplicate name for new dashboard
  • [job] [logs] OSS Firefox Tests / dashboard app using legacy data dashboard save warns on duplicate name for new dashboard
  • [job] [logs] OSS CI Group #4 / dashboard app using legacy data dashboard time picker Visualization updated when time picker changes
  • [job] [logs] OSS CI Group #4 / dashboard app using legacy data dashboard time picker Visualization updated when time picker changes
  • [job] [logs] Default Accessibility Tests / Dashboard Edit Panel can open menu
  • [job] [logs] Default Accessibility Tests / Dashboard Edit Panel can open menu
  • [job] [logs] Default CI Group #19 / dashboard feature controls dashboard feature controls security global dashboard all privileges, no embeddable application privileges create new dashboard shows addNew button
  • [job] [logs] Default CI Group #19 / dashboard feature controls dashboard feature controls security global dashboard all privileges, no embeddable application privileges create new dashboard shows addNew button
  • [job] [logs] Default CI Group #3 / Dashboard save a search sessions Saves and restores a session
  • [job] [logs] Default CI Group #3 / Dashboard save a search sessions Saves and restores a session
  • [job] [logs] Default CI Group #25 / discover Discover Saved Searches Customize time range should be possible to customize time range for saved searches on dashboards
  • [job] [logs] Default CI Group #25 / discover Discover Saved Searches Customize time range should be possible to customize time range for saved searches on dashboards
  • [job] [logs] Default CI Group #16 / lens app lens add-to-dashboards tests should allow new lens to be added by value to a new dashboard
  • [job] [logs] Default CI Group #16 / lens app lens add-to-dashboards tests should allow new lens to be added by value to a new dashboard
  • [job] [logs] Default CI Group #4 / lens app lens tagging "before all" hook for "adds a new tag to a Lens visualization"
  • [job] [logs] Default CI Group #4 / lens app lens tagging "before all" hook for "adds a new tag to a Lens visualization"
  • [job] [logs] Default CI Group #26 / machine learning anomaly detection anomaly explorer with farequote based multi metric job adds swim lane embeddable to a dashboard
  • [job] [logs] Default CI Group #26 / machine learning anomaly detection anomaly explorer with farequote based multi metric job adds swim lane embeddable to a dashboard
  • [job] [logs] Default CI Group #15 / machine learning data visualizer field statistics in Dashboard with lucene saved search and filter displays Field statistics table in Dashboard when enabled
  • [job] [logs] Default CI Group #15 / machine learning data visualizer field statistics in Dashboard with lucene saved search and filter displays Field statistics table in Dashboard when enabled
  • [job] [logs] Default CI Group #8 / machine learning embeddables anomaly charts in dashboard with multi metric job can open job selection flyout
  • [job] [logs] Default CI Group #8 / machine learning embeddables anomaly charts in dashboard with multi metric job can open job selection flyout
  • [job] [logs] OSS CI Group #9 / management kibana settings state:storeInSessionStorage when false, dashboard state is unhashed
  • [job] [logs] OSS CI Group #9 / management kibana settings state:storeInSessionStorage when false, dashboard state is unhashed
  • [job] [logs] Default CI Group #22 / maps app embeddable maps add-to-dashboard save flow should allow new map be added by value to a new dashboard
  • [job] [logs] Default CI Group #22 / maps app embeddable maps add-to-dashboard save flow should allow new map be added by value to a new dashboard
  • [job] [logs] Default CI Group #14 / saved objects tagging - functional tests dashboard integration creating allows to select tags for a new dashboard
  • [job] [logs] Default CI Group #14 / saved objects tagging - functional tests dashboard integration creating allows to select tags for a new dashboard
  • [job] [logs] Jest Tests #4 / Storyshots components/WorkpadHeader/EditorMenu dark mode
  • [job] [logs] Jest Tests #4 / Storyshots components/WorkpadHeader/EditorMenu default
  • [job] [logs] Jest Tests #4 / Storyshots components/WorkpadHeader/ElementMenu default
  • [job] [logs] OSS CI Group #11 / visualize app visualize ciGroup11 visual builder Time Series basics Clicking on the chart should create a filter
  • [job] [logs] OSS CI Group #11 / visualize app visualize ciGroup11 visual builder Time Series basics Clicking on the chart should create a filter

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
presentationUtil 182 170 -12

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
presentationUtil 177 173 -4

Async chunks

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

id before after diff
canvas 1.0MB 1.0MB -17.0B
controls 398.6KB 398.6KB -17.0B
dashboard 294.8KB 294.7KB -14.0B
presentationUtil 136.8KB 136.8KB -10.0B
total -58.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
dashboard 66.4KB 66.5KB +138.0B
presentationUtil 44.6KB 42.6KB -2.0KB
total -1.8KB
Unknown metric groups

API count

id before after diff
presentationUtil 228 224 -4

ESLint disabled in files

id before after diff
apm 15 14 -1
securitySolution 67 66 -1
uptime 7 6 -1
total -3

ESLint disabled line counts

id before after diff
apm 88 85 -3
enterpriseSearch 7 6 -1
uptime 48 42 -6
total -10

References to deprecated APIs

id before after diff
canvas 70 64 -6
dashboard 81 75 -6
dataEnhanced 49 43 -6
discover 44 38 -6
fleet 5 4 -1
lens 237 185 -52
management 2 1 -1
maps 456 330 -126
monitoring 40 28 -12
stackAlerts 183 157 -26
upgradeAssistant 8 3 -5
visDefaultEditor 205 155 -50
visTypeTimeseries 427 377 -50
visTypeVega 25 24 -1
visualizations 114 100 -14
total -362

Total ESLint disabled count

id before after diff
apm 103 99 -4
enterpriseSearch 7 6 -1
securitySolution 508 507 -1
uptime 55 48 -7
total -13

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas Team:SharedUX Team label for AppEx-SharedUX (formerly Global Experience) v8.2.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants