docsify-corner
Advanced tools
Comparing version 1.0.3 to 1.0.5
@@ -52,2 +52,4 @@ 'use strict'; | ||
icon: '', | ||
// the text of the title attribute is displayed as a tooltip | ||
title: '', | ||
// the corner background color, default false to use default color | ||
@@ -67,4 +69,7 @@ background: false, | ||
const a = document.querySelector('a.github-corner'); | ||
a.href = cornerOptions.url || ' '; | ||
a.innerHTML = getIcon(cornerOptions); | ||
cornerOptions.url && (a.href = cornerOptions.href); | ||
cornerOptions.title && (a.title = cornerOptions.title); | ||
// icon color config | ||
@@ -71,0 +76,0 @@ const cl = document.querySelector('.github-corner svg'); |
{ | ||
"name": "docsify-corner", | ||
"version": "1.0.3", | ||
"version": "1.0.5", | ||
"description": "A plugin for setting corner of docsify.", | ||
@@ -5,0 +5,0 @@ "main": "dist/docsify-corner.js", |
@@ -7,4 +7,5 @@ # docsify-corner | ||
- [x] support more icon. ( `Gitlab`...etc) | ||
- [x] support more icon ( `Gitlab`...). | ||
- [x] support customized image(`png`、`jpg`、`gif`). | ||
- [x] support more settings(`tooltip`、`color`). | ||
@@ -45,4 +46,5 @@ [![](https://data.jsdelivr.com/v1/package/npm/docsify-corner/badge)](https://www.jsdelivr.com/package/npm/docsify-corner) | ||
| height | the height of the customized image. | | ||
| color | the color of the icon.(Optional) | | ||
| background | the background color of the customized icon.(Optional) | | ||
| color | the color of the icon. | | ||
| background | the background color of the customized icon. | | ||
| title | the text of the title attribute is displayed as a tooltip. | | ||
@@ -81,3 +83,3 @@ | ||
You can set your own image in the corner. | ||
You can set your own image in the corner. | ||
@@ -106,3 +108,3 @@ ```html | ||
This the current [svg icon resources](https://gitlab.com/gitlab-org/gitlab-svgs) I m working on. | ||
This the current [svg icon resources](https://gitlab.com/gitlab-org/gitlab-svgs) I' m working on. | ||
@@ -112,3 +114,3 @@ Steps : | ||
- Folk it ! | ||
- Install dependencies `npm run install`. | ||
- Install dependencies `npm install`. | ||
- Create your feature branch: `git checkout -b my-new-feature`. | ||
@@ -115,0 +117,0 @@ - Commit your changes: `git commit -am 'Add some feature'.` |
@@ -12,2 +12,4 @@ import { getIcon } from './icon' | ||
icon: '', | ||
// the text of the title attribute is displayed as a tooltip | ||
title: '', | ||
// the corner background color, default false to use default color | ||
@@ -27,4 +29,7 @@ background: false, | ||
const a = document.querySelector('a.github-corner') | ||
a.href = cornerOptions.url || ' ' | ||
a.innerHTML = getIcon(cornerOptions) | ||
cornerOptions.url && (a.href = cornerOptions.url) | ||
cornerOptions.title && (a.title = cornerOptions.title) | ||
// icon color config | ||
@@ -31,0 +36,0 @@ const cl = document.querySelector('.github-corner svg') |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Deprecated
MaintenanceThe maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
20712
8
191
122
1