Skip to content

Add image references to the manifest #88

Description

@HadrienGardeur

With the on-going work on #180, we're now capable of detecting where an image is used, if it's decorative and which description (if any) is contained in the text.

This will be handled using a new references object in properties that can contain 1-n objects where:

  • href links to the resources and can contain a CSS selector as a fragment (hello.xhtml#css(body%20%3E%20span:nth-child(16)))
  • description contains the image description (including blank ones, which is different from a missing description)
  • and role where we mostly look for presentation
{
  "href": "OPS/images/Moby-Dick_FE_title_page.jpg",
  "type": "image/jpeg",
  "size": 105155,
  "width": 840,
  "height": 1380,
  "properties": {
    "animated": false,
    "hash": [
      {
        "algorithm": "sha256",
        "value": "dJw6jaDD0O6tKBw29unMf1DxChpBiuWWbouTBZS+UlE="
      }
    ],
    "references": [
     {
       "href": "hello.xhtml#css(body%20%3E%20span:nth-child(16))",
       "description": "This is the description of the image",
       "role": ["presentation"]
     }
    ]
  }
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

manifestRelated to the manifest command

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions