-
Notifications
You must be signed in to change notification settings - Fork 29
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
Add File Handling manifest member, parsing, LaunchQueue/LaunchParams #51
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left some drive-by review comments.
Execute a file handler launch | ||
</h2> | ||
<p> | ||
The steps to <dfn>execute a file handler launch</dfn> are given by |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@inexorabletash should this wording also be modernized, like in w3c/compute-pressure#96
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe not? As this isn't actually a web-facing method, i.e. there's no webidl definition for it or its parameters.
<ol> | ||
<li>[=list/for each=] |extension:string| of |extensions| | ||
<ol> | ||
<li>If |filename| does not end in |extension|, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we should do trimming of filenames? We used to do trimming in web app manifest, so might be good to check what we do there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@annevk I see that infra has https://infra.spec.whatwg.org/#string-starts-with so we need something for suffix/ends with?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you mean whitespace trimming? The file names are provided by the OS as command line arguments. AFAIK there's no rule saying a file name can't start with a space.
index.html
Outdated
<li>Else, set |launches|[|file_handler|] to a list | ||
with the single element |filename|. | ||
</li> | ||
<li>Continue to next element of |files|. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[=iteration/continue=]
Not sure what is the correct wording here @annevk?
PTAL @dmurph |
</section> | ||
<section> | ||
<h3> | ||
Handling Web App Launches |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if we need to acknowledge the step of 'creating a new document' or browsing context.
"user agent SHOULD navigate to url and the appropriate browsing context is set to a new top level browsing context." (same line as in protocol handling) somewhere in the algorithm?
Should we be mentioning edge cases like redirection? Or are we not mentioning that on purpose?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added a line about the creation of the new browser context. I didn't use the exact same language since it's a step in an algorithm rather than part of a paragraph.
Redirection (and reload) should be mentioned but I think that's sort of out of the scope of file handling. It should definitely be mentioned when the LaunchQueue/Params spec is fleshed out.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
</section> | ||
<section> | ||
<h3> | ||
Handling Web App Launches |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
thanks! |
Add description of manifest member file_handlers as well as a rough sketch of LaunchQueue and LaunchParams.
Preview | Diff