chromium/third_party/blink/renderer/core/preferences/preference_object.idl

// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

// Spec: https://wicg.github.io/web-preferences-api/
[
    Exposed=Window,
    SecureContext,
    RuntimeEnabled=WebPreferences
]
interface PreferenceObject : EventTarget {
  [CallWith=ScriptState] readonly attribute DOMString? override;
  [CallWith=ScriptState] readonly attribute DOMString value;
  readonly attribute FrozenArray<DOMString> validValues;

  [CallWith=ScriptState] undefined clearOverride();
  [CallWith=ScriptState] Promise<undefined> requestOverride(DOMString? value);

  attribute EventHandler onchange;
};