-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2ecd4da
commit 9398520
Showing
27 changed files
with
962 additions
and
82 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,60 +1,58 @@ | ||
{ | ||
"parser": "babel-eslint", | ||
"plugins": [ | ||
"react" | ||
], | ||
"env": { | ||
"amd": true, | ||
"browser": true, | ||
"jquery": true, | ||
"node": true, | ||
"es6": true, | ||
"worker": true | ||
}, | ||
"rules": { | ||
|
||
"eqeqeq": 2, | ||
"comma-dangle": 1, | ||
"no-console": 0, | ||
"no-debugger": 1, | ||
"no-extra-semi": 1, | ||
"no-extra-parens": 1, | ||
"no-irregular-whitespace": 0, | ||
"no-undef": 0, | ||
"no-unused-vars": 0, | ||
"semi": 1, | ||
"semi-spacing": 1, | ||
/*"valid-jsdoc": [ | ||
"parser": "babel-eslint", | ||
"plugins": [ | ||
"react" | ||
], | ||
"env": { | ||
"amd": true, | ||
"browser": true, | ||
"jquery": true, | ||
"node": true, | ||
"es6": true, | ||
"worker": true | ||
}, | ||
"rules": { | ||
"eqeqeq": 2, | ||
"comma-dangle": 1, | ||
"no-console": 0, | ||
"no-debugger": 1, | ||
"no-extra-semi": 1, | ||
"no-extra-parens": 1, | ||
"no-irregular-whitespace": 0, | ||
"no-undef": 0, | ||
"no-unused-vars": 0, | ||
"semi": 1, | ||
"semi-spacing": 1, | ||
/*"valid-jsdoc": [ | ||
2, | ||
{ "requireReturn": false } | ||
],*/ | ||
|
||
"react/display-name": 2, | ||
"react/forbid-prop-types": 1, | ||
"react/jsx-boolean-value": 1, | ||
"react/jsx-closing-bracket-location": 1, | ||
"react/jsx-curly-spacing": 1, | ||
"react/jsx-indent-props": 1, | ||
"react/jsx-max-props-per-line": 0, | ||
"react/jsx-no-duplicate-props": 1, | ||
"react/jsx-no-literals": 0, | ||
"react/jsx-no-undef": 1, | ||
"react/sort-prop-types": 1, | ||
"react/jsx-sort-props": 0, | ||
"react/jsx-uses-react": 1, | ||
"react/jsx-uses-vars": 1, | ||
"react/no-danger": 1, | ||
"react/no-did-mount-set-state": 1, | ||
"react/no-did-update-set-state": 1, | ||
"react/no-direct-mutation-state": 1, | ||
"react/no-multi-comp": 1, | ||
"react/no-set-state": 0, | ||
"react/no-unknown-property": 1, | ||
"react/prop-types":0, | ||
"react/react-in-jsx-scope": 0, | ||
"react/require-extension": "off", | ||
"react/self-closing-comp": 1, | ||
"react/sort-comp": 1, | ||
"react/jsx-wrap-multilines": 1 | ||
} | ||
"react/display-name": 2, | ||
"react/forbid-prop-types": 1, | ||
"react/jsx-boolean-value": 1, | ||
"react/jsx-closing-bracket-location": 1, | ||
"react/jsx-curly-spacing": 1, | ||
"react/jsx-indent-props": 1, | ||
"react/jsx-max-props-per-line": 0, | ||
"react/jsx-no-duplicate-props": 1, | ||
"react/jsx-no-literals": 0, | ||
"react/jsx-no-undef": 1, | ||
"react/sort-prop-types": 1, | ||
"react/jsx-sort-props": 0, | ||
"react/jsx-uses-react": 1, | ||
"react/jsx-uses-vars": 1, | ||
"react/no-danger": 0, | ||
"react/no-did-mount-set-state": 1, | ||
"react/no-did-update-set-state": 1, | ||
"react/no-direct-mutation-state": 1, | ||
"react/no-multi-comp": 1, | ||
"react/no-set-state": 0, | ||
"react/no-unknown-property": 1, | ||
"react/prop-types": 0, | ||
"react/react-in-jsx-scope": 0, | ||
"react/require-extension": "off", | ||
"react/self-closing-comp": 1, | ||
"react/sort-comp": 1, | ||
"react/jsx-wrap-multilines": 1 | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
src/contentscript/AddMonsterButton.js → ...entscript/addmonsters/AddMonsterButton.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
4 changes: 2 additions & 2 deletions
4
src/contentscript/ParseData.js → ...entscript/addmonsters/MonsterParseData.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
import MonsterContentData from "./MonsterContentData"; | ||
|
||
class ParseData { | ||
class MonsterParseData { | ||
constructor(insertFunction: string, target: JQuery<HTMLElement>, monsterData: MonsterContentData) { | ||
this.insert = target[insertFunction].bind(target); | ||
this.monsterData = monsterData; | ||
} | ||
} | ||
|
||
export default ParseData; | ||
export default MonsterParseData; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import React, { Component } from 'react'; | ||
|
||
/** | ||
* Dialog on content page. | ||
*/ | ||
class ContentDialog extends Component { | ||
render() { | ||
return ( | ||
<div id={this.props.dialogId} className="ddb-modal" title="Delete Folder" style={{ display: "none" }}> | ||
<div className="ddb-modal-form"> | ||
<div className="ddb-modal-header"> | ||
<div className="ddb-modal-header-text"> | ||
{this.props.message} | ||
</div> | ||
</div> | ||
<a className="ajax-post button" href="javascript:void(0)" onClick={this.props.onConfirm}> | ||
{this.props.confirmText || "Yes"} | ||
</a> | ||
</div> | ||
</div> | ||
); | ||
} | ||
} | ||
|
||
export default ContentDialog; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import PageScriptService from "../../services/PageScriptService"; | ||
|
||
class ContentDialogService { | ||
/** | ||
* Opens a dialog on content page. | ||
* @param {string} id target element id | ||
*/ | ||
static open(id: string) { | ||
const dialogOptions = `{ width: "auto", beforeClose: () => $("body").css("overflow", "inherit")}`; | ||
PageScriptService.run(`$("#${id}").dialog(${dialogOptions}); $("body").css("overflow", "hidden");`); | ||
} | ||
|
||
/** | ||
* Closes a dialog on content page. | ||
* @param {string} id target element id | ||
*/ | ||
static close(id: string) { | ||
PageScriptService.run(`$("#${id}").dialog("close");`); | ||
} | ||
} | ||
|
||
export default ContentDialogService; |
Oops, something went wrong.