Change ElementID to Element for Sidebar Extension
Summary: Element also contains `id`, which is equivalent to ElementID used in the existing extension. This change will help the implementation of layout intern search easier. Reviewed By: mweststrate Differential Revision: D21385001 fbshipit-source-id: b8c6e6f052af8cfa54bf3a132571e40567cdee4b
This commit is contained in:
committed by
Facebook GitHub Bot
parent
655d856d1c
commit
475a425a20
@@ -7,14 +7,14 @@
|
|||||||
* @format
|
* @format
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import {PluginClient, Client, ElementID} from 'flipper';
|
import {PluginClient, Client, Element} from 'flipper';
|
||||||
import {Logger} from 'app/src/fb-interfaces/Logger';
|
import {Logger} from 'app/src/fb-interfaces/Logger';
|
||||||
|
|
||||||
export default [] as Array<
|
export default [] as Array<
|
||||||
(
|
(
|
||||||
client: PluginClient,
|
client: PluginClient,
|
||||||
realClient: Client,
|
realClient: Client,
|
||||||
selectedNode: ElementID,
|
selectedNode: Element,
|
||||||
logger: Logger,
|
logger: Logger,
|
||||||
) => React.ReactNode
|
) => React.ReactNode
|
||||||
>;
|
>;
|
||||||
|
|||||||
@@ -149,7 +149,7 @@ const Sidebar: React.FC<Props> = (props: Props) => {
|
|||||||
const sections: Array<React.ReactNode> = (
|
const sections: Array<React.ReactNode> = (
|
||||||
(SidebarExtensions &&
|
(SidebarExtensions &&
|
||||||
SidebarExtensions.map((ext) =>
|
SidebarExtensions.map((ext) =>
|
||||||
ext(props.client, props.realClient, element.id, props.logger),
|
ext(props.client, props.realClient, element, props.logger),
|
||||||
)) ||
|
)) ||
|
||||||
[]
|
[]
|
||||||
).concat(
|
).concat(
|
||||||
|
|||||||
Reference in New Issue
Block a user