mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 01:38:56 -04:00
fix timeslice chaining in react embeddable control group (#188866)
While reviewing https://github.com/elastic/kibana/pull/188687, I noticed that controls where still getting filtered by timeslider changes even when chaining was disabled or the control was to the left of the timeslider. This PR resolves this issue by only passing in timeslice from `chaining$` instead of `controlGroupFetch$`. Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
This commit is contained in:
parent
6bc7d729a5
commit
c1070f3dab
1 changed files with 1 additions and 10 deletions
|
@ -37,9 +37,6 @@ export function controlGroupFetch$(
|
|||
}
|
||||
if (!parentIgnoreSettings?.ignoreTimerange && parentApi.timeRange$) {
|
||||
observables.push(parentApi.timeRange$);
|
||||
if (parentApi.timeslice$) {
|
||||
observables.push(parentApi.timeslice$);
|
||||
}
|
||||
}
|
||||
if (apiPublishesReload(parentApi)) {
|
||||
observables.push(parentApi.reload$);
|
||||
|
@ -61,13 +58,7 @@ export function controlGroupFetch$(
|
|||
timeRange:
|
||||
parentIgnoreSettings?.ignoreTimerange || !parentApi.timeRange$
|
||||
? undefined
|
||||
: parentApi.timeslice$?.value
|
||||
? {
|
||||
from: new Date(parentApi.timeslice$?.value[0]).toISOString(),
|
||||
to: new Date(parentApi.timeslice$?.value[1]).toISOString(),
|
||||
mode: 'absolute' as 'absolute',
|
||||
}
|
||||
: (parentApi as PublishesUnifiedSearch).timeRange$.value,
|
||||
: parentApi.timeRange$.value,
|
||||
};
|
||||
})
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue