Skip to content

Commit

Permalink
Update hasCrossSiteAncestor.md
Browse files Browse the repository at this point in the history
  • Loading branch information
aselya authored Aug 22, 2024
1 parent ac34784 commit f21810e
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions proposals/hasCrossSiteAncestor.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,8 @@ Adds a new optional boolean property `hasCrossSiteAncestor` to the `partitionKey
}
```
#### Cookies.GetPartitionKey()
Adds a new API, `cookies.getPartitionKey()` which retrives a valid `partitionKey` for the indicated frame.
Adds a new API, `cookies.getPartitionKey()` which retrieves a valid `partitionKey` for the indicated frame.
This is an asynchronous function that returns a promise.
This is an asyncronus function that returns a promise.

##### Syntax
```
Expand All @@ -93,7 +92,7 @@ let key = cookies.getPartitionKey(
)
```
##### Parameters
`details` object. Information about the frame to retrive information about.
`details` object. Information about the frame to retrieve information about.
> `tabId`
integer. The ID of the tab in which the frame is.

Expand Down Expand Up @@ -151,4 +150,4 @@ If no value is set for hasCrossSiteAncestor cookies with both true and false val
As described the Abuse Mitigations section, this method will not allow a `hasCrossSiteAncestor` value of false if the URL associated with the cookie and the `topLevelSite` in the `partitionKey` are not first-party. If this is attempted, an error will be returned. If a `hasCrossSiteAncestor` value is provided without a corresponding `topLevelSite` value, an error will be returned. Additionally, if no `hasCrossSiteAncestor` value is provided it will be populated using the algorithm described above.

- `cookies.remove()`:
If no `hasCrossSiteAncestor` value is provided it will be populated using the algorithm described above when determing the cookie to remove. If a `hasCrossSiteAncestor` value is provided without a corresponding `topLevelSite` value, an error will be returned. If `topLevelSite` and `hasCrossSiteAncestor` values are provided, they will be used by the method even if the combination of the values would be invalid.
If no `hasCrossSiteAncestor` value is provided it will be populated using the algorithm described above when determing the cookie to remove. If a `hasCrossSiteAncestor` value is provided without a corresponding `topLevelSite` value, an error will be urned. If `topLevelSite` and `hasCrossSiteAncestor` values are provided, they will be used by the method even if the combination of the values would be invalid.

0 comments on commit f21810e

Please sign in to comment.