-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
additional visualizations plugin cleanup before moving to NP #59318
Changes from 5 commits
6c571b3
2b02da8
cf938ff
ec57155
58f3841
ca9fd34
c65b756
f17e547
08e3b3c
1e8c7cb
c7f491d
deb1993
1374919
f10a9d6
ad8aa44
402ed88
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,8 +22,9 @@ import { i18n } from '@kbn/i18n'; | |
import { createInputControlVisController } from './vis_controller'; | ||
import { getControlsTab } from './components/editor/controls_tab'; | ||
import { OptionsTab } from './components/editor/options_tab'; | ||
import { Status, defaultFeedbackMessage } from '../../visualizations/public'; | ||
import { Status } from '../../visualizations/public'; | ||
import { InputControlVisDependencies } from './plugin'; | ||
import { defaultFeedbackMessage } from '../../../../plugins/kibana_utils/common/default_feedback_message'; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Also, should be imported from the root? |
||
|
||
export function createInputControlVisTypeDefinition(deps: InputControlVisDependencies) { | ||
const InputControlVisController = createInputControlVisController(deps); | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -45,7 +45,6 @@ import { getPainlessError } from './get_painless_error'; | |
import { discoverResponseHandler } from './response_handler'; | ||
import { | ||
angular, | ||
buildVislibDimensions, | ||
getRequestInspectorStats, | ||
getResponseInspectorStats, | ||
getServices, | ||
|
@@ -818,13 +817,28 @@ function discoverController( | |
if ($scope.opts.timefield) { | ||
const tabifiedData = tabifyAggResponse($scope.vis.aggs, resp); | ||
$scope.searchSource.rawResponse = resp; | ||
Promise.resolve( | ||
buildVislibDimensions($scope.vis, { | ||
timeRange: $scope.timeRange, | ||
searchSource: $scope.searchSource, | ||
}) | ||
).then(resp => { | ||
$scope.histogramData = discoverResponseHandler(tabifiedData, resp); | ||
const metric = $scope.vis.aggs.aggs[1]; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For the sake of clarity, I would put this code into a |
||
const agg = $scope.vis.aggs.aggs[0]; | ||
agg.params.timeRange = $scope.timeRange; | ||
agg.buckets.setBounds(agg); | ||
const { esUnit, esValue } = agg.buckets.getInterval(); | ||
$scope.histogramData = discoverResponseHandler(tabifiedData, { | ||
x: { | ||
accessor: 1, | ||
label: agg.makeLabel(), | ||
params: { | ||
date: true, | ||
interval: moment.duration(esValue, esUnit), | ||
intervalESValue: esValue, | ||
intervalESUnit: esUnit, | ||
format: agg.buckets.getScaledDateFormat(), | ||
bounds: agg.buckets.getBounds(), | ||
}, | ||
}, | ||
y: { | ||
accessor: 0, | ||
label: metric.makeLabel(), | ||
}, | ||
}); | ||
} | ||
|
||
|
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2852,7 +2852,6 @@ | |
"timelion.vis.intervalLabel": "时间间隔", | ||
"uiActions.actionPanel.title": "选项", | ||
"uiActions.errors.incompatibleAction": "操作不兼容", | ||
"visualizations.defaultFeedbackMessage": "想反馈?请在“{link}中创建问题。", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. i18n removed, but not added? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. thats what our i18n tool does and should be ok |
||
"visualizations.newVisWizard.betaDescription": "此可视化为公测版,可能会进行更改。设计和代码相对于正式发行版功能还不够成熟,将按原样提供,且不提供任何保证。公测版功能不受正式发行版功能支持 SLA 的约束", | ||
"visualizations.newVisWizard.betaTitle": "公测版", | ||
"visualizations.newVisWizard.chooseSourceTitle": "选择源", | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be imported from the root?