forked from dequelabs/Form-Personalization
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: gets initial POC working with submit buttons
- Loading branch information
0 parents
commit a857a60
Showing
13 changed files
with
5,682 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"presets": ["env"] | ||
} |
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,2 @@ | ||
dist | ||
node_modules |
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 @@ | ||
{ | ||
"extends": ["eslint:recommended"], | ||
"parser": "babel-eslint", | ||
"parserOptions": { | ||
"sourceType": "module", | ||
"ecmaVersion": 8 | ||
}, | ||
"rules": { | ||
"eqeqeq": 0, | ||
"curly": 2, | ||
"quotes": [1, "single"], | ||
"semi": ["error", "always"] | ||
}, | ||
"env": { | ||
"es6": true, | ||
"node": true, | ||
"browser": true | ||
}, | ||
"globals": { | ||
"chrome": true | ||
} | ||
} |
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,2 @@ | ||
node_modules/ | ||
dist/ |
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,35 @@ | ||
# Cogsistency | ||
|
||
Creating consistent (appearing) UI for common element types | ||
|
||
## Installation / Setup | ||
|
||
### Build extension | ||
|
||
```sh | ||
$ npm install && npm run build | ||
``` | ||
|
||
### Load extension | ||
|
||
- Go to `chrome://extensions` | ||
- Check developer mode | ||
- Click "Load unpacked extension..." | ||
- Select the `dist/` directory of this project | ||
|
||
### Debugging in the browser | ||
|
||
Open up the devtools console and set the desired debug flag(s): | ||
|
||
```js | ||
localStorage.debug = 'cogsistency:*'; | ||
``` | ||
|
||
## See it in action | ||
|
||
For proof of concept purposes, I've added a simple overlay for all submit buttons. Go to any page with a submit button. | ||
|
||
## TODO | ||
|
||
- write tests | ||
- create a popup with UI to easily add new overlay types (utilize persistent background script to "permanently" store overlay data) |
Oops, something went wrong.