FEATURE: Enable the Web Share Target API

This will allow a Discourse instance that was installed[1] to receive share events.

See https://wicg.github.io/web-share-target/ for the spec.

1: https://developers.google.com/web/fundamentals/app-install-banners/
This commit is contained in:
Rafael dos Santos Silva 2018-04-19 17:00:05 -03:00
parent a1f0c58f23
commit 9014ca4624

View File

@ -21,6 +21,9 @@ class MetadataController < ApplicationController
display: 'standalone',
orientation: 'natural',
start_url: "#{Discourse.base_uri}/",
share_target: {
url_template: 'new-topic?title={title}&body={text}%0A%0A{url}'
},
background_color: "##{ColorScheme.hex_for_name('secondary')}",
theme_color: "##{ColorScheme.hex_for_name('header_background')}",
icons: [