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

[Lens] Split apart config panel component to more manageable chunks #63910

Merged
merged 5 commits into from
Apr 22, 2020

Conversation

wylieconlon
Copy link
Contributor

@wylieconlon wylieconlon commented Apr 17, 2020

This is setting up for work on the Y-axis formatting options.

@wylieconlon wylieconlon added Team:Visualizations Visualization editors, elastic-charts and infrastructure v8.0.0 release_note:skip Skip the PR/issue when compiling release notes Feature:Lens v7.8.0 labels Apr 17, 2020
@wylieconlon wylieconlon requested review from timroes, mbondyra and a team April 17, 2020 21:29
@wylieconlon wylieconlon requested a review from a team as a code owner April 17, 2020 21:29
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app (Team:KibanaApp)

@@ -72,6 +72,10 @@ export const xyVisualization: Visualization<State, PersistableState> = {
return state.layers.map(l => l.layerId);
},

canAppendLayer(state) {
return state.layers.length < 2;
},
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I should probably take this behavior change out into a separate PR

removeLayer?: (state: T, layerId: string) => T;
/** When function is provided and returns true, multiple layers can be added */
canAppendLayer?: (state: T) => boolean;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is an added function

))}
{activeVisualization.canAppendLayer &&
activeVisualization.appendLayer &&
activeVisualization.canAppendLayer(visualizationState) && (
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This line here is a behavioral change

@mbondyra
Copy link
Contributor

@elasticmachine merge upstream

@mbondyra
Copy link
Contributor

Tested max. 2 layers behavior limit and how it will behave for already saved >2 layers visualization (more than 2 layers can be deleted but cannot be re-created). Looks good.

Copy link
Contributor

@cchaos cchaos left a comment

Choose a reason for hiding this comment

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

❤️ Thank you for this. And all the props comments are sweet! I'll be passing you a PR that just adjusts class names and sass files according to this new broken-down structure.

@wylieconlon wylieconlon requested a review from cchaos April 22, 2020 19:59
Copy link
Contributor

@cchaos cchaos left a comment

Choose a reason for hiding this comment

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

👍 LGTM!

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

History

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

@wylieconlon wylieconlon merged commit dd094f2 into elastic:master Apr 22, 2020
@wylieconlon wylieconlon deleted the lens/config-panel-split branch April 22, 2020 21:36
wylieconlon pushed a commit to wylieconlon/kibana that referenced this pull request Apr 22, 2020
…lastic#63910)

* [Lens] Split apart config panel component to more manageable chunks

* Moving around and renaming SASS appropriately

* Remove layer limit

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: cchaos <caroline.horn@elastic.co>
wylieconlon pushed a commit that referenced this pull request Apr 23, 2020
…63910) (#64256)

* [Lens] Split apart config panel component to more manageable chunks

* Moving around and renaming SASS appropriately

* Remove layer limit

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: cchaos <caroline.horn@elastic.co>

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: cchaos <caroline.horn@elastic.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Lens release_note:skip Skip the PR/issue when compiling release notes Team:Visualizations Visualization editors, elastic-charts and infrastructure v7.8.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants