Skip to content

Restrict possible values of DataTransfer.dropEffect and DataTransfer.effectAllowed. #891

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

Merged
merged 2 commits into from
Sep 10, 2020
Merged
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
4 changes: 2 additions & 2 deletions baselines/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4167,15 +4167,15 @@ interface DataTransfer {
*
* The possible values are "none", "copy", "link", and "move".
*/
dropEffect: string;
dropEffect: "none" | "copy" | "link" | "move";
/**
* Returns the kinds of operations that are to be allowed.
*
* Can be set (during the dragstart event), to change the allowed operations.
*
* The possible values are "none", "copy", "copyLink", "copyMove", "link", "linkMove", "move", "all", and "uninitialized",
*/
effectAllowed: string;
effectAllowed: "none" | "copy" | "copyLink" | "copyMove" | "link" | "linkMove" | "move" | "all" | "uninitialized";
/**
* Returns a FileList of the files being dragged, if any.
*/
Expand Down
15 changes: 15 additions & 0 deletions inputfiles/overridingTypes.json
Original file line number Diff line number Diff line change
Expand Up @@ -1177,6 +1177,21 @@
}
}
},
"DataTransfer": {
"name": "DataTransfer",
"properties": {
"property": {
"dropEffect": {
"name": "dropEffect",
"override-type": "\"none\" | \"copy\" | \"link\" | \"move\""
},
"effectAllowed": {
"name": "effectAllowed",
"override-type": "\"none\" | \"copy\" | \"copyLink\" | \"copyMove\" | \"link\" | \"linkMove\" | \"move\" | \"all\" | \"uninitialized\""
}
}
}
},
"DataTransferItemList": {
"name": "DataTransferItemList",
"methods": {
Expand Down