[whatwg/xhr] Allow doubles for ProgressEvent's loaded and total (PR #394)

This allows specifications to use ProgressEvents while not necessarily giving away the exact number of bytes, while maintaining a granularity greater than just 1 part in 100. See discussion in https://github.com/webmachinelearning/writing-assistance-apis/issues/15 for the concrete use case.

- [ ] At least two implementers are interested (and none opposed):
   * Chromium is interested
   * …
- [ ] [Tests](https://github.com/web-platform-tests/wpt) are written and can be reviewed and commented upon at:
   * I will get these written. The test is basically how synthetic `ProgressEvent` behavior changes: fractions are preserved, and negatives are now passed through as-is instead of subtracted from 2^64.
- [ ] [Implementation bugs](https://github.com/whatwg/meta/blob/main/MAINTAINERS.md#handling-pull-requests) are filed:
   * Chromium: …
   * Gecko: …
   * WebKit: …
- [ ] [MDN issue](https://github.com/whatwg/meta/blob/main/MAINTAINERS.md#handling-pull-requests) is filed: …
- [x] The top of this comment includes a [clear commit message](https://github.com/whatwg/meta/blob/main/COMMITTING.md) to use. <!-- If you created this PR from a single commit, Github copied its message. Otherwise, you need to add a commit message yourself. -->

(See [WHATWG Working Mode: Changes](https://whatwg.org/working-mode#changes) for more details.)

---

I wanted to get this PR up to judge implementer interest. It would be a decent bit cleaner if we all agreed this was reasonable and merged the change now, instead of having to float a patch in the relevant specs and thus causing all the databases to have two definitions of `ProgressEvent`.


<!--
    This comment and the below content is programmatically generated.
    You may add a comma-separated list of anchors you'd like a
    direct link to below (e.g. #idl-serializers, #idl-sequence):

    Don't remove this comment or modify anything below this line.
    If you don't want a preview generated for this pull request,
    just replace the whole of this comment's content by "no preview"
    and remove what's below.
-->
***
<a href="https://whatpr.org/xhr/394.html" title="Last updated on Jan 21, 2025, 2:28 AM UTC (48e8e0d)">Preview</a> | <a href="https://whatpr.org/xhr/394/f2f0397...48e8e0d.html" title="Last updated on Jan 21, 2025, 2:28 AM UTC (48e8e0d)">Diff</a>
You can view, comment on, or merge this pull request online at:

  https://github.com/whatwg/xhr/pull/394

-- Commit Summary --

  * Allow doubles for ProgressEvent's loaded and total

-- File Changes --

    M xhr.bs (8)

-- Patch Links --

https://github.com/whatwg/xhr/pull/394.patch
https://github.com/whatwg/xhr/pull/394.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/xhr/pull/394
You are receiving this because you are subscribed to this thread.

Message ID: <whatwg/xhr/pull/394@github.com>

Received on Tuesday, 21 January 2025 02:28:33 UTC