Displace component

Provides a wrapper around Drupal.displace and sets CSS custom properties on the html element when displacement changes.

id: displace
title: Displace
description: 'Provides a wrapper around Drupal.displace and sets CSS custom properties on the html element when displacement changes.'
class: Drupal\ambientimpact_ux\Plugin\AmbientImpact\Component\Displace
provider: ambientimpact_ux
{  }
component.displace:
  js:
    components/displace/displace.js:
      attributes:
        defer: true
  dependencies:
    - ambientimpact_core/component.environment
    - ambientimpact_core/framework