diff --git a/index.bs b/index.bs index 52eacb2..6c7f034 100644 --- a/index.bs +++ b/index.bs @@ -903,7 +903,7 @@ interface MediaMetadata { attribute DOMString title; attribute DOMString artist; attribute DOMString album; - attribute FrozenArray<MediaImage> artwork; + attribute FrozenArray<object> artwork; }; dictionary MediaMetadataInit { @@ -933,7 +933,8 @@ dictionary MediaMetadataInit {

A {{MediaMetadata}} has an associated list of artwork - images. + images which is a list of type object on the interface + but a list of type {{MediaImage}} internally.

@@ -971,9 +972,10 @@ dictionary MediaMetadataInit {

  • Run the convert artwork algorithm with init's - {{MediaMetadataInit/artwork}} as input and set - metadata's artwork images as the - result if it succeeded. + {{MediaMetadataInit/artwork}} as input, + where the input is a list of type {{MediaImage}}, + and set metadata's artwork images + as the result if it succeeded.
  • Return metadata. @@ -982,7 +984,8 @@ dictionary MediaMetadataInit {

    When the convert artwork algorithm with input parameter is -invoked, the user agent MUST run the following steps: +invoked, where the input is a list of type {{MediaImage}}, +the user agent MUST run the following steps:
    1. Let output be an empty list of type {{MediaImage}}. @@ -1050,7 +1053,7 @@ invoked, the user agent MUST run the following steps: images. On getting, it MUST return the result of the following steps:
      1. - Let frozenArtwork be an empty list of type {{MediaImage}}. + Let frozenArtwork be an empty list of type object.
      2. For each entry in the {{MediaMetadata}}'s image's {{MediaImage/type}} to entry's {{MediaImage/type}}.
      3. +
      4. + Convert image into an object + whose type is object. +
      5. - Call Object.freeze on image, to prevent - accidental mutation by scripts. + Call Object.freeze on the object, + to prevent accidental mutation by scripts.
      6. - Append image to frozenArtwork. + Append the object to frozenArtwork.
    2. @@ -1089,10 +1096,18 @@ invoked, the user agent MUST run the following steps: Create a frozen array from frozenArtwork.
    - On setting, it MUST run the - convert artwork algorithm with the new value as input, and - set the {{MediaMetadata}}'s artwork images as the - result if it succeeded. + On setting, it MUST run the following steps: +
      +
    1. + Convert the frozenArtwork from a list of type object + into a list of type {{MediaImage}}. +
    2. +
    3. + Run convert artwork algorithm with the converted list as + input, and set the {{MediaMetadata}}'s + artwork images as the result if it succeeded. +
    4. +