diff --git a/api/@internal/component/ets/image.d.ts b/api/@internal/component/ets/image.d.ts index 49465ff58cc663a6fa2f7d492f834889229dd104..9b991825b72d5662bedc13dfc41f524f00ed95df 100644 --- a/api/@internal/component/ets/image.d.ts +++ b/api/@internal/component/ets/image.d.ts @@ -163,6 +163,13 @@ declare class ImageAttribute extends CommonMethod { */ onError(callback: (event?: { componentWidth: number; componentHeight: number }) => void): ImageAttribute; + /** + * This callback is triggered when an exception occurs during image loading. + * The field of "message" carries the detailed information of failed image loading. + * @since 9 + */ + onError(callback: (event?: { componentWidth: number; componentHeight: number; message: string }) => void): ImageAttribute; + /** * When the loaded source file is a svg image, this callback is triggered when the playback of the svg image is complete. * If the svg image is a wireless loop image, this callback is not triggered.