Skip to content

Commit

Permalink
Updating the README for v1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Tro95 committed Feb 7, 2020
1 parent 35b9c2a commit 3d1ce83
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Instructions:
- At the top of your Tampermonkey script, ensure you have the following lines:
```
// @grant unsafeWindow
// @require https://raw.githubusercontent.com/Tro95/Pardus-Options-Library/v1.1/pardus_options_library.js
// @require https://raw.githubusercontent.com/Tro95/Pardus-Options-Library/v1.2/pardus_options_library.js
```
This will allow the unsafeWindow permision within your script, which is necessary to guarantee safe
interactions with other scripts utilising this library also. This will also include the library
Expand All @@ -27,12 +27,12 @@ if (document.location.pathname == '/options.php') {
- Add a new tab to the Options page. Recommended usage is one tab per script or userspace.

```
unsafeWindow.Options.addNewTab(label, id)
unsafeWindow.Options.addNewTab(label, id, GM_setValue, GM_getValue)
```
label: String to display in the tab. Visual limitations means this can only be a maximum
of two words, 10 characters each.
id: HTML element id for the tab. This should be a string with no whitespace, convention
is to all be lowercase and words separated with hyphens.
label: String to display in the tab. Visual limitations means this can only be a maximum
of two words, 10 characters each.
id: HTML element id for the tab. This should be a string with no whitespace, convention
is to all be lowercase and words separated with hyphens.

Returns: OptionsContext object. This should be assigned to a variable that is then used
to add options boxes into the tab.
Expand Down

0 comments on commit 3d1ce83

Please sign in to comment.