mirror of
https://github.com/servo/servo.git
synced 2025-08-09 07:25:35 +01:00
Auto merge of #15536 - asajeffrey:script-document-domain-setter, r=nox
Implement setter for document.domain <!-- Please describe your changes on the following line: --> This PR implements the setter for `document.domain`. It builds on #15438 and #15478, only the last commit is part of this PR. It includes tests for similar-origin security checks. --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: --> - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #934. - [X] There are tests for these changes. <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/15536) <!-- Reviewable:end -->
This commit is contained in:
commit
e600e0495c
104 changed files with 413 additions and 1057 deletions
|
@ -81,7 +81,7 @@ partial /*sealed*/ interface Document {
|
|||
// resource metadata management
|
||||
[/*PutForwards=href, */Unforgeable]
|
||||
readonly attribute Location? location;
|
||||
readonly attribute DOMString domain;
|
||||
[SetterThrows] attribute DOMString domain;
|
||||
readonly attribute DOMString referrer;
|
||||
[Throws]
|
||||
attribute DOMString cookie;
|
||||
|
|
|
@ -10,7 +10,7 @@ interface History {
|
|||
readonly attribute unsigned long length;
|
||||
// attribute ScrollRestoration scrollRestoration;
|
||||
// readonly attribute any state;
|
||||
void go(optional long delta = 0);
|
||||
[Throws] void go(optional long delta = 0);
|
||||
void back();
|
||||
void forward();
|
||||
// void pushState(any data, DOMString title, optional USVString? url = null);
|
||||
|
|
|
@ -4,26 +4,24 @@
|
|||
|
||||
// https://html.spec.whatwg.org/multipage/#location
|
||||
[Exposed=Window, Unforgeable] interface Location {
|
||||
/*stringifier*/ attribute USVString href;
|
||||
readonly attribute USVString origin;
|
||||
attribute USVString protocol;
|
||||
attribute USVString host;
|
||||
attribute USVString hostname;
|
||||
attribute USVString port;
|
||||
attribute USVString pathname;
|
||||
attribute USVString search;
|
||||
attribute USVString hash;
|
||||
/*stringifier*/ [Throws] attribute USVString href;
|
||||
[Throws] readonly attribute USVString origin;
|
||||
[Throws] attribute USVString protocol;
|
||||
[Throws] attribute USVString host;
|
||||
[Throws] attribute USVString hostname;
|
||||
[Throws] attribute USVString port;
|
||||
[Throws] attribute USVString pathname;
|
||||
[Throws] attribute USVString search;
|
||||
[Throws] attribute USVString hash;
|
||||
|
||||
[Throws]
|
||||
void assign(USVString url);
|
||||
[Throws]
|
||||
void replace(USVString url);
|
||||
void reload();
|
||||
[Throws] void assign(USVString url);
|
||||
[Throws] void replace(USVString url);
|
||||
[Throws] void reload();
|
||||
|
||||
//[SameObject] readonly attribute USVString[] ancestorOrigins;
|
||||
|
||||
// This is only doing as well as gecko right now.
|
||||
// https://github.com/servo/servo/issues/7590 is on file for
|
||||
// adding attribute stringifier support.
|
||||
stringifier;
|
||||
[Throws] stringifier;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue