Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "minor",
"comment": "Add `DevicePermission.ClipboardRead` and clipboard permission telemetry/runtime foundations for the updated clipboard-read architecture (P0, additive; no behavior change)",
"packageName": "@microsoft/teams-js",
"email": "leahxia@microsoft.com",
"dependentChangeType": "patch"
}
2 changes: 2 additions & 0 deletions packages/teams-js/src/internal/telemetry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,8 @@ export const enum ApiName {
Chat_OpenGroupChat = 'chat.openGroupChat',
Clipboard_Read = 'clipboard.read',
Clipboard_Write = 'clipboard.write',
Clipboard_HasPermission = 'clipboard.hasPermission',
Clipboard_RequestPermission = 'clipboard.requestPermission',
Conversations_CloseConversation = 'conversations.closeConversation',
Conversations_GetChatMember = 'conversations.getChatMember',
Conversations_OpenConversation = 'conversations.openConversation',
Expand Down
1 change: 1 addition & 0 deletions packages/teams-js/src/public/interfaces.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1161,6 +1161,7 @@ export enum ErrorCode {
export enum DevicePermission {
GeoLocation = 'geolocation',
Media = 'media',
ClipboardRead = 'clipboard-read',
}

/** @hidden */
Expand Down
10 changes: 9 additions & 1 deletion packages/teams-js/src/public/runtime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,15 @@ interface IRuntimeV4 extends IBaseRuntime {
readonly calendar?: {};
readonly call?: {};
readonly chat?: {};
readonly clipboard?: {};
readonly clipboard?: {
/**
* When present, the host supports reading the clipboard natively in the app
* frame (via `navigator.clipboard`) gated by the `clipboard-read` device
* permission, instead of the legacy host-proxied `clipboard.readFromClipboard`
* path. Absent on older hosts, which fall back to the proxied path.
*/
readonly native?: {};
};
readonly conversations?: {};
readonly copilot?: {
readonly customTelemetry?: {};
Expand Down
Loading