added github feedback snippet
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
{% if page.type %}{% else %}
|
||||
<div class="feedback">
|
||||
<p class="feedback-question">
|
||||
Was this article helpful? <a class="link-burrito" href="#yes">Yes</a> - <a class="link-burrito" href="#no">No</a>
|
||||
</p>
|
||||
<p class="feedback-no">
|
||||
Well, that's awkward <i class="em em-sweat_smile"></i>. Would you mind
|
||||
{% capture issue_body %}### [{{ page.title }}]({{ page.path }}) issue:{% endcapture %}
|
||||
{% capture issue_title %}Problem with page {{ page.path }}{% endcapture %}
|
||||
<a class="link-burrito" data-action="feedback-open-issue" href="https://github.com/tinymce/tinymce-docs/issues/new?body={{ issue_body | url_encode }}&title={{ issue_title | url_encode }}" target="_blank">opening an issue</a> or
|
||||
<a class="link-burrito" data-action="feedback-edit" href="https://github.com/tinymce/tinymce-docs/tree/master/{{ page.path }}" target="_blank">help us out</a>?
|
||||
</p>
|
||||
<p class="feedback-yes">
|
||||
Thanks for the feedback!
|
||||
</p>
|
||||
</div>
|
||||
{% endif %}
|
||||
@@ -5,6 +5,7 @@
|
||||
<title>TinyMCE - {{ page.title }}</title>
|
||||
<link href="{{ site.shared_baseurl }}/css/common.min.css" rel="stylesheet">
|
||||
<link href="{{ site.shared_baseurl }}/css/docs.min.css" rel="stylesheet">
|
||||
<link href="https://afeld.github.io/emoji-css/emoji.css" rel="stylesheet">
|
||||
</head>
|
||||
<body role="document" data-shared-baseurl="{{ site.shared_baseurl }}" data-baseurl="{{ site.baseurl }}">
|
||||
{% include top-menu.html %}
|
||||
@@ -48,6 +49,7 @@
|
||||
|
||||
<div class="content">
|
||||
{{ content }}
|
||||
{% include feedback.html %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
require 'uri'
|
||||
|
||||
module Jekyll
|
||||
module URLEncode
|
||||
def url_encode(input)
|
||||
input = URI.escape(input, Regexp.new("[^#{URI::PATTERN::UNRESERVED}]"))
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Liquid::Template.register_filter(Jekyll::URLEncode)
|
||||
Reference in New Issue
Block a user