Browse Source

[skip ci] Update docs with gitter, badge icons and favicon

DarthSim 5 years ago
parent
commit
a09c2d103d

+ 1 - 1
README.md

@@ -4,7 +4,7 @@
      src="https://cdn.rawgit.com/DarthSim/imgproxy/master/logo.svg">
 
 
-[![CircleCI branch](https://img.shields.io/circleci/project/github/imgproxy/imgproxy/master.svg?style=for-the-badge)](https://circleci.com/gh/DarthSim/imgproxy) [![Docker](https://img.shields.io/badge/docker-darthsim%2Fimgproxy-blue.svg?style=for-the-badge)](https://hub.docker.com/r/darthsim/imgproxy/) [![MicroBadger Size](https://img.shields.io/microbadger/image-size/darthsim/imgproxy.svg?style=for-the-badge)](https://hub.docker.com/r/darthsim/imgproxy/) [![Docker Pulls](https://img.shields.io/docker/pulls/darthsim/imgproxy.svg?style=for-the-badge)](https://hub.docker.com/r/darthsim/imgproxy/)
+[![CircleCI branch](https://img.shields.io/circleci/project/github/imgproxy/imgproxy/master.svg?logo=circleci&style=for-the-badge)](https://circleci.com/gh/DarthSim/imgproxy) [![Docker](https://img.shields.io/badge/docker-darthsim%2Fimgproxy-blue.svg?logo=docker&logoColor=white&style=for-the-badge)](https://hub.docker.com/r/darthsim/imgproxy/) [![MicroBadger Size](https://img.shields.io/microbadger/image-size/darthsim/imgproxy.svg?logo=docker&logoColor=white&style=for-the-badge)](https://hub.docker.com/r/darthsim/imgproxy/) [![Docker Pulls](https://img.shields.io/docker/pulls/darthsim/imgproxy.svg?logo=docker&logoColor=white&style=for-the-badge)](https://hub.docker.com/r/darthsim/imgproxy/) [![Gitter](https://img.shields.io/gitter/room/imgproxy/imgproxy?logo=gitter&style=for-the-badge)](https://gitter.im/imgproxy/imgproxy)
 
 
 imgproxy is a fast and secure standalone server for resizing and converting remote images. The main principles of imgproxy are simplicity, speed, and security.

+ 29 - 0
docs/assets/docsify-gitter.js

@@ -0,0 +1,29 @@
+; (function (win) {
+  win.GitterPlugin = {}
+
+  function create(room, color) {
+    color = color || "blue";
+
+    var url = "https://gitter.im/" + room;
+    var badgeUrl = "https://img.shields.io/gitter/room/" +
+      room +
+      "?color=" + color +
+      "&style=for-the-badge" +
+      "&logo=gitter";
+    var html = "<a class=\"gitter-link\" href=\"" + url +"\" target=\"_blank\">" +
+      "<img alt=\"Chat on Gitter\" src=\"" + badgeUrl + "\">" +
+      "</a>";
+
+    return function (hook) {
+      hook.mounted(function () {
+        var el = Docsify.dom.create('div', html);
+        var appName = Docsify.dom.find('.app-name');
+
+        Docsify.dom.toggleClass(el, 'gitter');
+        Docsify.dom.appendTo(appName, el);
+      })
+    }
+  }
+
+  win.GitterPlugin.create = create
+})(window)

BIN
docs/assets/favicon-128.png


BIN
docs/assets/favicon-16x16.png


BIN
docs/assets/favicon-196x196.png


BIN
docs/assets/favicon-32x32.png


BIN
docs/assets/favicon-96x96.png


+ 5 - 0
docs/assets/style.css

@@ -109,3 +109,8 @@
 .github-corner {
   position: fixed;
 }
+
+.gitter img {
+  display: block;
+  margin: 5px auto 0;
+}

+ 8 - 1
docs/index.html

@@ -23,6 +23,11 @@
   <meta property="og:site_name" content="imgproxy documentation" />
   <meta name="keywords" content="image, resize-images, crop-image, microservice, docker, jpeg, png, libvips" />
   <meta name="theme-color" content="#000000" />
+  <link rel="icon" type="image/png" href="/assets/favicon-196x196.png" sizes="196x196">
+  <link rel="icon" type="image/png" href="/assets/favicon-128x128.png" sizes="128x128">
+  <link rel="icon" type="image/png" href="/assets/favicon-96x96.png" sizes="96x96">
+  <link rel="icon" type="image/png" href="/assets/favicon-32x32.png" sizes="32x32">
+  <link rel="icon" type="image/png" href="/assets/favicon-16x16.png" sizes="16x16">
   <link rel="stylesheet" href="assets/theme.css">
   <link rel="stylesheet" href="assets/style.css">
 </head>
@@ -37,6 +42,7 @@
     </div>
   </div>
   <script src="assets/docsify-edit-link.js"></script>
+  <script src="assets/docsify-gitter.js"></script>
   <script>
     window.$docsify = {
       name: '<img style="width:90%" title="imgproxy logo" src="/assets/logo.svg" >',
@@ -49,7 +55,8 @@
         depth: 6
       },
       plugins: [
-        EditOnGithubPlugin.create('https://github.com/imgproxy/imgproxy/blob/master/docs/')
+        EditOnGithubPlugin.create('https://github.com/imgproxy/imgproxy/blob/master/docs/'),
+        GitterPlugin.create("imgproxy/imgproxy", "1775d3")
       ]
     }
   </script>