Skip to content

Latest commit

 

History

History
60 lines (47 loc) · 3.14 KB

README.md

File metadata and controls

60 lines (47 loc) · 3.14 KB

Authentic User Accessibility Preferences as Verifiable Credentials

This repo contains inspirations from TPAC September 2022.

These are experiments, unsafe for production use.

Injecting Authentic User Preferences in Web Pages

Open en.wikipedia.org/wiki/Americans_with_Disabilities_Act_of_1990.

Open the Chrome Menu in the upper-right-hand corner of the browser window and select More Tools > Developer Tools. You can also use Option + ⌘ + J (on macOS), or Shift + CTRL + J (on Windows/Linux).

Paste this into the console while on the page above:

;(() => {
  const vc = {
    '@context': [
      {
        '@version': 1.1,
        id: '@id',
        type: '@type',
        '@vocab': 'https://www.w3.org/ns/credentials#',
        credentialSubject: {
          '@type': '@id',
        },
      },
    ],
    id: 'urn:uuid:e4390388-e819-4f18-b257-3a11841dbc00',
    type: ['VerifiableCredential', 'ADA-Accessibility-Preferences'],
    issuer:
      'urn:ietf:params:oauth:jwk-thumbprint:sha-256:1MELFccN3bm8o3g7rpWKlOI5xphtiCJW3H5Fet-7vcQ',
    issuanceDate: '2010-01-01T19:23:24Z',
    credentialSubject: {
      id: 'urn:ietf:params:oauth:jwk-thumbprint:sha-256:1MELFccN3bm8o3g7rpWKlOI5xphtiCJW3H5Fet-7vcQ',
      style: 'p { font-size: 150% !important; }',
    },
  }
  const style = document.createElement('style')
  style.appendChild(document.createTextNode(vc.credentialSubject.style))
  document.getElementsByTagName('head')[0].appendChild(style)
})()

Want to contribute?

Want to Generate Your Own Credentials?

npm i
npm t