servo/components/script_bindings/webidls/IDBVersionChangeEvent.webidl
Josh Matthews 518729a4f5
script: Expose IDBVersionChangeEvent to worker globals. (#37573)
IDBVersionChangeEvent is already used internally from non-Window
globals, but the constructor wasn't set up to expose the interface
object in worker globals.

Testing: The effort involved in adding a test for this does not seem
worthwhile—we get this for free once we enable the indexeddb preference
while our interfaces.worker.js test is running.
Fixes: part of #6963

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2025-06-20 07:42:36 +00:00

23 lines
851 B
Text

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
/*
* The origin of this IDL file is
* https://w3c.github.io/IndexedDB/#idbversionchangeevent
*
*/
// https://w3c.github.io/IndexedDB/#idbversionchangeevent
[Pref="dom_indexeddb_enabled", Exposed=(Window,Worker)]
interface IDBVersionChangeEvent : Event {
constructor(DOMString type, optional IDBVersionChangeEventInit eventInitDict = {});
readonly attribute unsigned long long oldVersion;
readonly attribute unsigned long long? newVersion;
};
// https://w3c.github.io/IndexedDB/#idbversionchangeevent
dictionary IDBVersionChangeEventInit : EventInit {
unsigned long long oldVersion = 0;
unsigned long long? newVersion = null;
};