aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2020-03-22Merge branch 'dependabot/npm_and_yarn/acorn-6.4.1'HEADmasterTeddy Wing
2020-03-15Bump acorn from 6.1.1 to 6.4.1dependabot[bot]
Bumps [acorn](https://github.com/acornjs/acorn) from 6.1.1 to 6.4.1. - [Release notes](https://github.com/acornjs/acorn/releases) - [Commits](https://github.com/acornjs/acorn/compare/6.1.1...6.4.1) Signed-off-by: dependabot[bot] <support@github.com>
2019-06-10Add READMETeddy Wing
2019-06-10Add license (GNU GPLv3+)Teddy Wing
2019-05-08Attempt to add next/previous page shortcuts to index view (WIP)Teddy Wing
The shortcuts don't work yet unfortunately. Just committing this as a progress commit.
2019-05-02Try to add 'j/k' shortcuts in the pager viewTeddy Wing
Very messy at the moment. Doesn't currently work because it needs to be executed when the pager view becomes visible. Pager divs are created and removed each time a message is opened. Going to put this aside for now and try to focus on the index view. From there, I should be able to figure out how to load in pager commands when a message is selected.
2019-05-02Idea.txt: Make shortcut to download the emailTeddy Wing
2019-05-01gmail_selectors.ts: Add new selectors for index and pager viewsTeddy Wing
2019-05-01Rename 'gmail_css_class' to 'gmail_selectors'Teddy Wing
Since I'd like to put non-class selectors in this module now.
2019-05-01index.ts: Better Gmail loading initialisation logicTeddy Wing
Instead of using a timeout, which may get executed prematurely, check for the visibility of Gmail's `loading` screen. When it disappears from view, we know we can safely initialise all our plugin features. This allows us to, for example, try to ensure our `<style>` element gets appended last. Now the sidebar actually gets hidden with our CSS rule from 496ac03b0d6afb28db09998eb9944db2102ad49e since it can take precedence over Gmail's asynchronously-loaded styles.
2019-05-01style.ts: Hide the left sidebar by defaultTeddy Wing
2019-05-01sidebar.ts: Add comment showing command keysTeddy Wing
2019-05-01sidebar.ts: Extract multi-key shortcut command codeTeddy Wing
Make the multi-key command generic so that it works with other commands, not just `\m`. Use the array equality method from Abhi (https://stackoverflow.com/users/2968762/abhi) on Stack Overflow: https://stackoverflow.com/questions/7837456/how-to-compare-arrays-in-javascript/19746771#19746771
2019-05-01sidebar.ts: Extract `key_codes` to moduleTeddy Wing
Move this to a separate module as we'll probably want to use the same dictionary of key codes to make other shortcuts. Also fix some syntax while we're at it.
2019-05-01Add shortcut to toggle the left sidebarTeddy Wing
Map sidebar toggle to `\m`. Initialise the code after a timeout to account for Gmail's initial loading screen. Needed to use an `as HTMLElement` cast in order to get the code to compile: https://github.com/Microsoft/TypeScript/issues/16920 src/sidebar.ts:10:5 - error TS2740: Type 'Element' is missing the following properties from type 'HTMLElement': accessKey, accessKeyLabel, autocapitalize, dir, and 110 more.
2019-05-01Add MakefileTeddy Wing
Formalise build recipe.
2019-05-01Use CommonJS modules, fix importsTeddy Wing
* Use single quotes * Add 'sidebar.ts' to main * Fix `SIDEBAR` import from 'gmail_css_class.ts' * Remove ".ts" extensions from imports * Build to 'build/' directory instead of a file. This creates one JS file per module by the Typescript compiler.
2019-05-01package.json: Add 'browserify'Teddy Wing
Try using Browserify to package our modules into a single file instead of trying to rely on the Typescript compiler.
2019-05-01Move Gmail CSS class definitions to a new moduleTeddy Wing
Allow them to be used for a new Sidebar module that will enable sidebar toggling. Had to switch the compiled module system to `amd` because of this error message: tsconfig.json:3:3 - error TS6082: Only 'amd' and 'system' modules are supported alongside --outFile. Thinking I'm going to switch to Typescript namespaces to save myself the trouble of using a 'require' library for the AMD modules.
2019-05-01Move code to "style.ts"Teddy Wing
* Create a separate module for the CSS style-related code. * Use `commonjs` module format instead of `amd` so that the resulting output file can be used (hopefully) without modification directly in the browser.
2019-05-01.gitignore: Ignore build directoryTeddy Wing
For now. We'll probably want to add it back in (or dist/) later.
2019-05-01Change `MESSAGE_PAGER` classTeddy Wing
Use a class from a deeper element in the hierarchy. This way the action buttons above messages aren't inverted.
2019-05-01Add some test stylesTeddy Wing
* Remove the right "tools" sidebar * Invert colours in the main message viewer. Doesn't appear to be working correctly at the moment. Looks like I need to add some specificity to the selector. Change the name of the output file to make it a user script. Add the UserScript header metadata.
2019-05-01Add constants for Gmail CSS classesTeddy Wing
Create a type and names for these generated class names.
2019-05-01Add tsconfig.jsonTeddy Wing
* Build a single output file for use in a browser. * Compile the "index.ts" file.
2019-05-01.gitignore: Ignore node_modules/ directoryTeddy Wing
2019-05-01Add init script to put `tsc` Typescript executable in PATHTeddy Wing
2019-05-01Add Typescript dependencyTeddy Wing
2019-05-01Idea for a Gmail plugin that adds Mutt shortcutsTeddy Wing