From 43a0baec8445ff0c413132d18085c02cde95c7e3 Mon Sep 17 00:00:00 2001 From: zcdqs Date: Sat, 22 Jan 2022 11:12:50 +0800 Subject: [PATCH] add getInspector to element for js xts Signed-off-by: zcdqs Change-Id: I921df0a00acffddf41ddad1cb141312f4ec80f31 --- api/common/@internal/viewmodel.d.ts | 7 +++++++ api/phone/@internal/viewmodel.d.ts | 6 ++++++ api/tablet/@internal/viewmodel.d.ts | 6 ++++++ api/tv/@internal/viewmodel.d.ts | 6 ++++++ api/wearable/@internal/viewmodel.d.ts | 6 ++++++ 5 files changed, 31 insertions(+) diff --git a/api/common/@internal/viewmodel.d.ts b/api/common/@internal/viewmodel.d.ts index 5c80a95a2c..46eba6d51b 100644 --- a/api/common/@internal/viewmodel.d.ts +++ b/api/common/@internal/viewmodel.d.ts @@ -482,6 +482,13 @@ export interface Element { */ getBoundingClientRect(): RectObj; + /** + * Obtains attributes of the element. + * @returns attributes of the element in json string. + * @devices tv, phone, tablet, wearable + */ + getInspector(): string; + /** * If 0.5 is returned, 50% of the current component is visible. * @param radios Scope of Monitoring components. diff --git a/api/phone/@internal/viewmodel.d.ts b/api/phone/@internal/viewmodel.d.ts index cf357da918..0710455c8e 100644 --- a/api/phone/@internal/viewmodel.d.ts +++ b/api/phone/@internal/viewmodel.d.ts @@ -391,6 +391,12 @@ export interface Element { */ getBoundingClientRect(): RectObj; + /** + * Obtains attributes of the element. + * @returns attributes of the element in json string. + */ + getInspector(): string; + /** * If 0.5 is returned, 50% of the current component is visible. * @param radios Scope of Monitoring components. diff --git a/api/tablet/@internal/viewmodel.d.ts b/api/tablet/@internal/viewmodel.d.ts index d2dfe1c838..6ef80bb304 100644 --- a/api/tablet/@internal/viewmodel.d.ts +++ b/api/tablet/@internal/viewmodel.d.ts @@ -390,6 +390,12 @@ export interface Element { */ getBoundingClientRect(): RectObj; + /** + * Obtains attributes of the element. + * @returns attributes of the element in json string. + */ + getInspector(): string; + /** * If 0.5 is returned, 50% of the current component is visible. * @param radios Scope of Monitoring components. diff --git a/api/tv/@internal/viewmodel.d.ts b/api/tv/@internal/viewmodel.d.ts index 4098a8d15f..f52f000195 100644 --- a/api/tv/@internal/viewmodel.d.ts +++ b/api/tv/@internal/viewmodel.d.ts @@ -390,6 +390,12 @@ export interface Element { */ getBoundingClientRect(): RectObj; + /** + * Obtains attributes of the element. + * @returns attributes of the element in json string. + */ + getInspector(): string; + /** * If 0.5 is returned, 50% of the current component is visible. * @param radios Scope of Monitoring components. diff --git a/api/wearable/@internal/viewmodel.d.ts b/api/wearable/@internal/viewmodel.d.ts index 0ada64d418..4ceaed183a 100644 --- a/api/wearable/@internal/viewmodel.d.ts +++ b/api/wearable/@internal/viewmodel.d.ts @@ -390,6 +390,12 @@ export interface Element { */ getBoundingClientRect(): RectObj; + /** + * Obtains attributes of the element. + * @returns attributes of the element in json string. + */ + getInspector(): string; + /** * If 0.5 is returned, 50% of the current component is visible. * @param radios Scope of Monitoring components. -- Gitee