mirror of
https://github.com/elastic/kibana.git
synced 2025-06-28 11:05:39 -04:00
[embeddable] make presentation interface names consistent (#205279)
PR cleans up presentation interface names for consistentency * adds `$` suffix to all observables. For example, `dataLoading` => `dataLoading$` * removes `Panel` naming convention from interface names since an api may not be a panel, an api may be a dashboard. For example, `PublisesPanelTitle` => `PublishesTitle` #### Note to Reviewers Pay special attention to any place where your application creates an untyped API. In the example below, there is no typescript violation when the parent returns `dataLoading` instead of `dataLoading$` since the parent is not typed as `PublishesDataLoading`. Please check for instances like these. ``` <ReactEmbeddableRenderer getParentApi={() => { dataLoading: new BehaviorSubject() }} /> ``` --------- Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com> Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
This commit is contained in:
parent
33145379e5
commit
05916056cd
229 changed files with 1263 additions and 1297 deletions
|
@ -47,7 +47,7 @@ export const RenderExamples = () => {
|
|||
const [api, setApi] = useState<SearchApi | null>(null);
|
||||
const [hidePanelChrome, setHidePanelChrome] = useState<boolean>(false);
|
||||
const [dataLoading, timeRange] = useBatchedOptionalPublishingSubjects(
|
||||
api?.dataLoading,
|
||||
api?.dataLoading$,
|
||||
parentApi.timeRange$
|
||||
);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue