diff --git a/e2e/panels-suite/panelEdit_transforms.spec.ts b/e2e/panels-suite/panelEdit_transforms.spec.ts index 6e45dd6522a..6f12a438c73 100644 --- a/e2e/panels-suite/panelEdit_transforms.spec.ts +++ b/e2e/panels-suite/panelEdit_transforms.spec.ts @@ -10,10 +10,7 @@ e2e.scenario({ e2e.flows.openDashboard({ uid: '5SdHCadmz', queryParams: { editPanel: 3 } }); e2e.components.Tab.title('Transform').should('be.visible').click(); - - // Flacky tests. Error: cy.click() failed because this element is detached from the DOM. - // The element is visible and clickable manually. - // e2e.components.TransformTab.newTransform('Reduce').scrollIntoView().should('be.visible').click(); - // e2e.components.Transforms.Reduce.calculationsLabel().should('be.visible'); + e2e.components.TransformTab.newTransform('Reduce').scrollIntoView().should('be.visible').click(); + e2e.components.Transforms.Reduce.calculationsLabel().should('be.visible'); }, }); diff --git a/public/app/features/dashboard/components/TransformationsEditor/TransformationsEditor.tsx b/public/app/features/dashboard/components/TransformationsEditor/TransformationsEditor.tsx index f3b7f49da1a..1a4506245ad 100644 --- a/public/app/features/dashboard/components/TransformationsEditor/TransformationsEditor.tsx +++ b/public/app/features/dashboard/components/TransformationsEditor/TransformationsEditor.tsx @@ -346,107 +346,6 @@ class UnThemedTransformationsEditor extends React.PureComponent ( - <> - {config.featureToggles.transformationsRedesign && ( - <> - {!noTransforms && ( - - )} -
- - Transformations{' '} - - -  allow you to manipulate your data before a visualization is applied. -
- - )} - - {!config.featureToggles.transformationsRedesign && ( - - )} - - {!config.featureToggles.transformationsRedesign && - xforms.map((t) => { - return ( - { - this.onTransformationAdd({ value: t.id }); - }} - /> - ); - })} - - {config.featureToggles.transformationsRedesign && ( -
- -
- Show images{' '} - this.setState({ showIllustrations: !this.state.showIllustrations })} - /> -
-
- )} - - {config.featureToggles.transformationsRedesign && ( -
- {filterCategoriesLabels.map(([slug, label]) => { - return ( - this.setState({ selectedFilter: slug })} - label={label} - selected={this.state.selectedFilter === slug} - /> - ); - })} -
- )} - - {config.featureToggles.transformationsRedesign && ( - { - this.onTransformationAdd({ value: id }); - }} - /> - )} -
- - ); - return ( <> {noTransforms && ( @@ -487,7 +386,109 @@ class UnThemedTransformationsEditor extends React.PureComponent )} {showPicker ? ( - + <> + {config.featureToggles.transformationsRedesign && ( + <> + {!noTransforms && ( + + )} +
+ + Transformations{' '} + + +  allow you to manipulate your data before a visualization is applied. +
+ + )} + + {!config.featureToggles.transformationsRedesign && ( + + )} + + {!config.featureToggles.transformationsRedesign && + xforms.map((t) => { + return ( + { + this.onTransformationAdd({ value: t.id }); + }} + /> + ); + })} + + {config.featureToggles.transformationsRedesign && ( +
+ +
+ Show images{' '} + this.setState({ showIllustrations: !this.state.showIllustrations })} + /> +
+
+ )} + + {config.featureToggles.transformationsRedesign && ( +
+ {filterCategoriesLabels.map(([slug, label]) => { + return ( + this.setState({ selectedFilter: slug })} + label={label} + selected={this.state.selectedFilter === slug} + /> + ); + })} +
+ )} + + {config.featureToggles.transformationsRedesign && ( + { + this.onTransformationAdd({ value: id }); + }} + /> + )} +
+ ) : (