From 114bd8cedc1b03d738bf40b7a12b1044b5c2964e Mon Sep 17 00:00:00 2001 From: fangJinliang1 Date: Thu, 17 Nov 2022 16:44:10 +0800 Subject: [PATCH 1/2] fixed 7f7d711 from https://gitee.com/fangJinliang1/interface_sdk-js/pulls/3370 add interface Signed-off-by: fangJinliang1 Change-Id: Id7aa2ab22daab57cbd2988ab8672f7e30e9b86ae --- api/@ohos.notificationManager.d.ts | 30 -------------------- api/@ohos.notificationSubscribe.d.ts | 41 ++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+), 30 deletions(-) diff --git a/api/@ohos.notificationManager.d.ts b/api/@ohos.notificationManager.d.ts index e35bfb4fcd..6f285ae0bf 100644 --- a/api/@ohos.notificationManager.d.ts +++ b/api/@ohos.notificationManager.d.ts @@ -1157,17 +1157,6 @@ declare namespace notificationManager { uid?: number; } - /** - * Describes a NotificationKey, which can be used to identify a notification. - * @typedef NotificationKey - * @syscap SystemCapability.Notification.Notification - * @since 9 - */ - export interface NotificationKey { - id: number; - label?: string; - } - /** * The type of the Do Not Disturb. * @enum { number } @@ -1277,25 +1266,6 @@ declare namespace notificationManager { TYPE_TIMER = 2, } - /** - * Reason for remove a notification - * @enum { number } - * @syscap SystemCapability.Notification.Notification - * @systemapi - * @since 9 - */ - export enum RemoveReason { - /** - * Notification clicked notification on the status bar - */ - CLICK_REASON_REMOVE = 1, - - /** - * User dismissal notification on the status bar - */ - CANCEL_REASON_REMOVE = 2, - } - /** * Describes an action button displayed in a notification. * @syscap SystemCapability.Notification.Notification diff --git a/api/@ohos.notificationSubscribe.d.ts b/api/@ohos.notificationSubscribe.d.ts index a97f53a9b4..22de1e3291 100644 --- a/api/@ohos.notificationSubscribe.d.ts +++ b/api/@ohos.notificationSubscribe.d.ts @@ -27,6 +27,47 @@ import { EnabledNotificationCallbackData as _EnabledNotificationCallbackData } f * @permission N/A */ declare namespace notificationSubscribe { + /** + * Describes a BundleOption. + * @typedef BundleOption + * @syscap SystemCapability.Notification.Notification + * @since 9 + */ + export interface BundleOption { + bundle: string; + uid?: number; + } + + /** + * Describes a NotificationKey, which can be used to identify a notification. + * @typedef NotificationKey + * @syscap SystemCapability.Notification.Notification + * @since 9 + */ + export interface NotificationKey { + id: number; + label?: string; + } + + /** + * Reason for remove a notification + * @enum { number } + * @syscap SystemCapability.Notification.Notification + * @systemapi + * @since 9 + */ + export enum RemoveReason { + /** + * Notification clicked notification on the status bar + */ + CLICK_REASON_REMOVE = 1, + + /** + * User dismissal notification on the status bar + */ + CANCEL_REASON_REMOVE = 2, + } + /** * Subscribe to notifications. * @permission ohos.permission.NOTIFICATION_CONTROLLER -- Gitee From c7bfb4c6e42ef68bf0df3e61f5960e3e21374ba4 Mon Sep 17 00:00:00 2001 From: FangJinliang Date: Mon, 21 Nov 2022 06:40:22 +0000 Subject: [PATCH 2/2] update api/@ohos.notificationSubscribe.d.ts. Signed-off-by: FangJinliang --- api/@ohos.notificationSubscribe.d.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/api/@ohos.notificationSubscribe.d.ts b/api/@ohos.notificationSubscribe.d.ts index 22de1e3291..0d530853c1 100644 --- a/api/@ohos.notificationSubscribe.d.ts +++ b/api/@ohos.notificationSubscribe.d.ts @@ -22,6 +22,7 @@ import { EnabledNotificationCallbackData as _EnabledNotificationCallbackData } f /** * @name notificationSubscribe * @since 9 + * @systemapi * @syscap SystemCapability.Notification.Notification * @import import notificationSubscribe from '@ohos.notification.subscribe'; * @permission N/A @@ -31,6 +32,7 @@ declare namespace notificationSubscribe { * Describes a BundleOption. * @typedef BundleOption * @syscap SystemCapability.Notification.Notification + * @systemapi * @since 9 */ export interface BundleOption { @@ -42,6 +44,7 @@ declare namespace notificationSubscribe { * Describes a NotificationKey, which can be used to identify a notification. * @typedef NotificationKey * @syscap SystemCapability.Notification.Notification + * @systemapi * @since 9 */ export interface NotificationKey { -- Gitee