Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,26 @@ For private repositories, set this flag.
}
```

- `label`: button label (optional, default is `Bug Report`)

Set button label if you want to use other than default.

```json
{
"gitbook": ">=3.0.0",
"title": "Example",
"plugins": [
"github-issue-feedback"
],
"pluginsConfig": {
"github-issue-feedback": {
"repo": "your/private_repo",
"label": "Report Issue on GitHub"
}
}
}
```

## Changelog

See [Releases page](https://github.com/azu/gitbook-plugin-github-issue-feedback/releases).
Expand Down
2 changes: 1 addition & 1 deletion src/plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ window.require(["gitbook"], function(gitbook) {
gitbook.events.bind("start", function(e, pluginConfig) {
var config = pluginConfig["github-issue-feedback"];
var reportElement = document.createElement("button");
reportElement.textContent = "Bug Report";
reportElement.textContent = config["label"] || "Bug Report";
reportElement.className = "gitbook-plugin-github-issue-feedback";
reportElement.setAttribute("style", "position:fixed; right:0;bottom:0;");
var clickEvent = ("ontouchstart" in window) ? "touchend" : "click";
Expand Down