Skip to content

Instantly share code, notes, and snippets.

@communiteq
Created December 23, 2016 18:03
Show Gist options
  • Save communiteq/bf5f07f4d7224f25e544604e7942600f to your computer and use it in GitHub Desktop.
Save communiteq/bf5f07f4d7224f25e544604e7942600f to your computer and use it in GitHub Desktop.
Discourse site customization : Extra menu items in top bar
{"site_customization":{"id":7,"name":"Extra menu items in top bar","key":"74197bb7-683d-424f-87af-1feedd585275","enabled":true,"created_at":"2016-12-23T17:43:43.847Z","updated_at":"2016-12-23T17:58:19.457Z","stylesheet":"/* add extra items in the top bar (left to the search icon)\n author: Richard at DiscourseHosting.com\n*/\n\ndiv#toprow-links {\n display: inline;\n float: left;\n font-size: 1.2em;\n margin-right: 20px;\n margin-top: 10px;\n}\ndiv#toprow-links a {\n color: #666;\n margin-right: 20px;\n}","header":"\u003c!-- add extra items in the top bar (left to the search icon)\n author: Richard at DiscourseHosting.com --\u003e\n\n\u003cscript type=\"text/discourse-plugin\" version=\"0.2\"\u003e\napi.decorateWidget('header-icons:before', helper =\u003e {\n const showExtraInfo = helper.attrs.minimized;\n if(!showExtraInfo) {\n return helper.h('div#toprow-links', [\n helper.h('a#test1', {\n href:'https://www.google.com/', \n text:'Link #1'\n }),\n helper.h('a#test2', {\n href:'https://www.google.com/', \n text:'Link #2'\n })\n ]);\n }\n});\n\u003c/script\u003e","footer":"","top":"","mobile_stylesheet":"","mobile_header":"","mobile_footer":"","mobile_top":"","head_tag":"","body_tag":"","embedded_css":""}}
@communiteq
Copy link
Author

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment