From 9a7c1316f4c11be55e76215ed0490652632b29ba Mon Sep 17 00:00:00 2001 From: zhangbingce Date: Tue, 11 Jan 2022 17:10:34 +0800 Subject: [PATCH] fixed a1a3663 from https://gitee.com/zhangbingce/interface_sdk-js/pulls/315 sync xcomponent interface Signed-off-by: zhangbingce Change-Id: I21bf022b36b2357011e9f2c904bce259503fc8f5 --- api/@internal/component/ets/xcomponent.d.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/api/@internal/component/ets/xcomponent.d.ts b/api/@internal/component/ets/xcomponent.d.ts index 2d1a4f6588..714116d3f4 100644 --- a/api/@internal/component/ets/xcomponent.d.ts +++ b/api/@internal/component/ets/xcomponent.d.ts @@ -16,26 +16,37 @@ import { CommonMethod } from "./common"; /** + * Defines XComponentController * @since 8 + * @systemapi */ export declare class XComponentController { /** * constructor. * @since 8 + * @systemapi */ constructor(); /** * get the id of surface created by XComponent. * @since 8 + * @systemapi */ getXComponentSurfaceId(); } /** + * Defines XComponent. * @since 8 + * @systemapi */ interface XComponent extends XComponentAttribute { + /** + * Constructor parameters + * @since 8 + * @systemapi + */ (value: { id: string; type: string; @@ -45,18 +56,22 @@ interface XComponent extends XComponentAttribute { } /** + * Defines XComponentAttribute. * @since 8 + * @systemapi */ declare class XComponentAttribute extends CommonMethod { /** * Called when judging whether the xcomponent surface is created. * @since 8 + * @systemapi */ onLoad(callback: (event?: {}) => void): T; /** * Called when judging whether the xcomponent is destroyed. * @since 8 + * @systemapi */ onDestroy(event: () => void): T; } -- Gitee