Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how to install in my hard drive and modify the bookmarklet to keep my wpm values #145

Closed
espinozaluis opened this issue Nov 14, 2014 · 4 comments

Comments

@espinozaluis
Copy link

HI, I use linux Mint and firefox browser. I tried to modify the script in the bookmarklet; but I am not a programmer I download the .css and the .js files and modify the directions on the bookmarklet this way:

original:
javascript:%20(function()%20{var%20addStyle%20=%20function(url)%20{var%20style%20=%20document.createElement('link');style.rel%20=%20'stylesheet';style.type%20=%20'text/css';style.href%20=%20url;document.head.appendChild(style);};var%20addScript%20=%20function(url,cb)%20{var%20script%20=%20document.createElement('script');script.src%20=%20url;if(cb)%20{script.onload%20=%20cb;}document.body.appendChild(script);};if%20(typeof%20window.jetzt%20===%20'undefined')%20{var%20cb%20=%20function()%20{window.jetzt.select();};addStyle('https://ds300.github.io/jetzt/jetzt.css');addScript('https://ds300.github.io/jetzt/jetzt-solid.min.js',cb);}%20else%20{window.jetzt.select();}})();

MINE:
javascript:%20(function()%20{var%20addStyle%20=%20function(url)%20{var%20style%20=%20document.createElement('link');style.rel%20=%20'stylesheet';style.type%20=%20'text/css';style.href%20=%20url;document.head.appendChild(style);};var%20addScript%20=%20function(url,cb)%20{var%20script%20=%20document.createElement('script');script.src%20=%20url;if(cb)%20{script.onload%20=%20cb;}document.body.appendChild(script);};if%20(typeof%20window.jetzt%20===%20'undefined')%20{var%20cb%20=%20function()%20{window.jetzt.select();};addStyle('file:///home/luis/websites/jetzt/jetzt.css');addScript('file:///home/luis/websites/jetzt/jetzt-solid.min.js',cb);}%20else%20{window.jetzt.select();}})();

thanks in advance!!
_Luis from Argentina.

@ds300
Copy link
Owner

ds300 commented Nov 14, 2014

Alas, there's no simple way to get the bookmarklet to save WPM settings across domains, even if you're loading it from the local filesystem. Fortunately, you can give it a different default value by changing only one number!

In jetzt.solid.min.js search for the substring target_wpm:400 and change 400 to whatever WPM you like. Voila!

@espinozaluis
Copy link
Author

Hi, I did not mean a different value across domains just to keep a
higher number as you show me.
By the way, how is the right way to edit the script in the bookmarklet
to make it function locally. Thanks!

El 14/11/14 a las 12:13, David Sheldrick escibió:

Alas, there's no simple way to get the bookmarklet to save WPM
settings across domains, even if you're loading it from the local
filesystem. Fortunately, you can give it a different default value by
changing only one number!

In jetzt.solid.min.js search for the substring |target_wpm:400| and
change |400| to whatever WPM you like. Voila!


Reply to this email directly or view it on GitHub
#145 (comment).

@ds300
Copy link
Owner

ds300 commented Nov 14, 2014

You can't load local files from a non-local page. That would be an insane security risk!

You'd have to host your version of jetzt-solid.min.js on a server somewhere (you could use your github account for this).

@espinozaluis
Copy link
Author

Thank you, very useful advice.

El 14/11/14 a las 13:55, David Sheldrick escibió:

You can't load local files from a non-local page. That would be an
insane security risk!

You'd have to host your version of jetzt-solid.min.js on a server
somewhere (you could use your github account for this).


Reply to this email directly or view it on GitHub
#145 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants