nswdpc/silverstripe-datawrapper

Module providing Datawrapper chart and map support

Installs: 1 078

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 3

Forks: 0

Open Issues: 2

Type:silverstripe-vendormodule

v1.0.0 2024-05-13 07:52 UTC

This package is auto-updated.

Last update: 2024-10-13 08:39:22 UTC


README

This module provides an iframe element to embed Datawrapper charts and maps on a page, along with the script to enable responsiveness.

Features

  • Supports Locator Maps, Charts, Chloropeth Maps
  • Responsive iframe support
  • Your content editors can edit charts and maps in Datawrapper and create corresponding elements in pages to display these
  • Datawrapper custom webhook support. See Configuration notes below and Webhook notes for more information.

Requirements

See composer.json

Installation

composer require nswdpc/silverstripe-datawrapper

License

BSD-3-Clause

Documentation

Further documentation for content authors is available.

Configuration

Webhooks

Name: 'app-datawrapper'
After:
  - '#nswdpc-datawrapper'
NSWDPC\Datawrapper\WebhookController:
  webhooks_enabled: true|false
  webhooks_random_code: 'a random unguessable code'

If you are using Datwrapper custom webhooks, add a webhooks_random_code value.

As there is no shared webhook signing key, anyone with the webhook URL and the Datawrapper Id of an element on your website will be able to publish elements. You can change this random code at any time but you must ensure the custom webhook URL value at Datawrapper is updated to match.

You can set elements to ignore webhook publishing requests by unchecking the "Auto publish" value on an element.

Datawrapper custom webhook URLs are Team-based. Only charts in that team will receive a webhook request when they are published.

Maintainers

Bugtracker

We welcome bug reports, pull requests and feature requests on the Github Issue tracker for this project.

Please review the code of conduct prior to opening a new issue.

Development and contribution

If you would like to make contributions to the module please ensure you raise a pull request and discuss with the module maintainers.

Please review the code of conduct prior to completing a pull request.