Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API Review: Web Notification #3186

Open
wants to merge 18 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add links to Notification.actions
  • Loading branch information
peiche-jessica committed Jan 9, 2023
commit 88418d00d46557c91531722e73eefc68c7a96fa9
9 changes: 9 additions & 0 deletions specs/WebNotification.md
Original file line number Diff line number Diff line change
Expand Up @@ -374,12 +374,21 @@ interface ICoreWebView2NotificationCloseRequestedEventHandler : IUnknown {
[uuid(07DD3067-2B86-47F6-AB96-D74825C2DA41), object, pointer_default(unique)]
interface ICoreWebView2NotificationAction : IUnknown {
/// A string identifying a user action to be displayed on the notification.
/// This corresponds to the
/// [action](https://developer.mozilla.org/docs/Web/API/Notification/actions)
/// member of a notification action object.
[propget] HRESULT Action([out, retval] LPWSTR* value);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's weird that Action has a property called Action, but that's what the DOM API calls it, so I'm inclined to match it.

It's not clear what the difference between Action and Title is.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No change required.


/// A string containing action text to be shown to the user.
/// This corresponds to the
/// [title](https://developer.mozilla.org/docs/Web/API/Notification/actions)
/// member of a notification action object.
[propget] HRESULT Title([out, retval] LPWSTR* value);

/// A string containing the URI of an icon to display with the action.
/// This corresponds to the
/// [icon](https://developer.mozilla.org/docs/Web/API/Notification/actions)
/// member of a notification action object.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are these security implications here? Does the host have to take care to avoid CORS-related vulnerabilities?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please consider and follow up.

[propget] HRESULT IconUri([out, retval] LPWSTR* value);
}

Expand Down