Commit Graph

158 Commits

Author SHA1 Message Date
tophf
fe3b1511f6 add "[x] only Usercss" filter in the manager 2017-11-24 13:19:12 +03:00
tophf
65f0a2ac3c add doc link for "[x] as usercss" option in the manager 2017-11-24 13:19:12 +03:00
tophf
62aec5c359 put "[x] as Usercss" option next to "Write new style" button 2017-11-24 13:19:12 +03:00
eight
db1643e9b8 Refactor: pull out colorParser 2017-11-01 11:18:13 +08:00
eight
eec52ad239 Revert "Add: detail dialog. Move makeAuthor to dom.js. Move external.svg into"
This reverts commit 5b701d06ad.
2017-10-12 16:10:17 +08:00
eight
5b701d06ad Add: detail dialog. Move makeAuthor to dom.js. Move external.svg into
images.
2017-10-11 14:52:42 +08:00
eight
d4ddefe8a0 Merge branch 'master' of https://github.com/openstyles/stylus into dev-user-css 2017-09-12 03:40:56 +08:00
tophf
4f7876f961 manage: prevent wrapping in check-all and view-log row 2017-09-10 21:19:37 +03:00
eight
bf455752ec Use options dialog style 2017-09-07 01:51:28 +08:00
eight
4e0f4b34bb Add: colorParser 2017-09-07 01:51:27 +08:00
tophf
36d790e0c2 improve CSS transition suppression on own pages in FF 2017-09-04 01:05:32 +03:00
tophf
519d745f59 globally disable CSS transitions for a moment during page opening
the problem we fix is that since we add the styles asynchronously, the browsers, esp. Firefox, sometimes apply transitions from the null/default state to the one specified in the injected CSS.

supersedes 72e8213b and 4dbca46b
2017-09-03 19:43:37 +03:00
tophf
72e8213bd7 followup 9a55e64b: suppress CSS transitions bug in FF while loading
fixes #177
2017-09-02 08:51:58 +03:00
eight
6aaa7ef878 Fix: configure icon 2017-09-01 13:36:03 +08:00
eight
dece4b57f3 Add: install styles from *.user.css file
Fix: handle dup name+namespace

Fix: eslint eqeqeq

Fix: trim @name's spaces

Add: check update for userstyle

Add: build CSS variable

Fix: only check dup when id is not provided

Refactor: userStyle2json -> userstyle.json

Add: style for input

Add: config dialog

Fix: preserve config during update

Fix: onchange doesn't fire on keyboard enter event

Fix: remove empty file

Add: validator. Metas must stay in the same line

Add: warn the user if installation failed

Fix: add some delay before starting installation

Add: open the editor after first installation

Fix: add openEditor to globals

Fix: i18n

Add: preprocessor. Move userstyle.build to background page.

Fix: remove unused global

Fix: preserved unknown prop in saveStyleSource() like saveStyle()

Add: edit userstyle source

Fix: load preprocessor dynamically

Fix: load content script dynamically

Fix: buildCode is async function

Fix: drop Object.entries

Fix: style.sections is undefined

Fix: don't hide the name input but disable it

Fix: query the style before installation

Revert: changes to editor, editor.html

Refactor: use term `usercss` instead of `userstyle`

Fix: don't show homepage action for usercss

Refactor: move script-loader to js/

Refactor: pull out mozParser

Fix: code style

Fix: we don't need to build meta anymore

Fix: use saveUsercss instead of saveStyle to get responsed error

Fix: last is undefined, load script error

Fix: switch to moz-format

Fix: drop injectContentScript. Move usercss check into install-user-css

Fix: response -> respond

Fix: globals -> global

Fix: queryUsercss -> filterUsercss

Fix: add processUsercss function

Fix: only open editor for usercss

Fix: remove findupUsercss fixme

Fix: globals -> global

Fix: globals -> global

Fix: global pollution

Revert: update.js

Refactor: checkStyle

Add: support usercss

Fix: no need to getURL in background page

Fix: merget semver.js into usercss.js

Fix: drop all_urls in match pattern

Fix: drop respondWithError

Move stylus -> stylus-lang

Add stylus-lang/readme

Fix: use include_globs

Fix: global pollution
2017-08-30 17:29:41 +08:00
tophf
fb7f7d5471 URL-mode in manager's search and popup's manage button
* in manager use search query like url:https://github.com/openstyles/stylus
* in popup shift-click or right-click on manager button opens it and applies the filter
2017-08-23 12:16:32 +03:00
tophf
64ba125601 manage: add inverted filters (disabled, external) 2017-08-22 17:24:44 +03:00
tophf
f80f5612d6 code cosmetics: split manage.js 2017-08-16 08:18:23 +03:00
tophf
f001bca849 manage: show stats for filtered/total styles 2017-08-16 08:18:22 +03:00
Jeremy Schomery
332f95e1ff i18n-html to i18n-text if possible. tNodeList now parses HTML content using tHTML 2017-07-22 12:56:37 +03:00
Rob Garrison
ac91e25eb4 Move messaging.js file & references 2017-07-13 19:52:40 -05:00
Rob Garrison
bb33ff3981 Fix links & split out edit.css 2017-07-12 16:26:20 -05:00
tophf
d02ca476a7 spellcheck="false" in text input fields 2 2017-06-29 16:51:18 +03:00
tophf
8e4b2fbbb0 manage: hardcode edit link; fixes #29 broken in 7084dd12 2017-06-18 15:47:15 +03:00
tophf
4250f89ed3 Add favicons only in Firefox 2017-05-17 01:09:31 +03:00
tophf
3b9ec2508f Use 16px favicon by default if "sizes" attr isn't respected 2017-05-15 15:50:31 +03:00
tophf
1706f380f2 Show favicons on own pages in FF/Opera 2017-05-15 15:41:15 +03:00
tophf
0e1124b8bb optionsUI: make "Shortcuts" a button; unify translations 2017-04-29 19:56:37 +03:00
tophf
809e70a89c manage: show update history button 2017-04-27 20:40:45 +03:00
tophf
50ec32a7b2 Rephrase the misleading "only edited styles" option 2017-04-26 14:33:31 +03:00
tophf
02fd4f1abe Display "force-install" for locally edited styles on update
* Allow manually resetting locally edited style even if up-to-date
* "Check again, I didn't edit any styles!" button
2017-04-26 01:35:32 +03:00
tophf
7677f0dece updater: add 'ignoreDigest' to force-update on manage page
* saveStyle: retain only known properties in sections[] and normalize their order
* remove styleDigest on import
* shorten detailed status names in updater
* don't autohide update status message
2017-04-26 01:35:14 +03:00
tophf
3dc934369b manage: simplify DOM (append icons only when needed) 2017-04-23 23:05:31 +03:00
tophf
fe3f5121e5 manage: shorten "Find editor styles" as "Theme" 2017-04-19 16:34:48 +03:00
tophf
a2943852a7 add a hidden "gray out" options for favicons 2017-04-18 21:49:04 +03:00
tophf
53814fc9e6 manage: homogenize icon stroke widths 2017-04-18 16:11:57 +03:00
tophf
eccabb8f27 Fix even-odd rules on entries
* Now filtering is done in js
* Visible entries are always at the beginning of #installed
* Hidden entries are always at the end of #installed
* The code tries to minimize DOM reordering operations:
  * First pass only moves one hidden entry in hidden groups with odd number of items.
  * Second [full] pass runs after repaint.
2017-04-18 12:47:02 +03:00
tophf
e21d65217a manage: show progress bar on update check 2017-04-18 12:46:38 +03:00
tophf
05c05ec6b9 manage: use chrome://favicon 2017-04-18 12:46:36 +03:00
tophf
5c8d1950a7 Isolate storage.js in background context
To prevent cross-page leaks we need to create/copy prefs and cachedStyles inside the background page context.

* storage.js is now used only in the background page

* messaging.js now contains less bg-specific methods and more common methods. Added saveStyleSafe, deleteStyleSafe which automatically invoke onRuntimeMessage of the current page or just handleUpdate/handleDelete when notify:false

* prefs.js with 'prefs' for background and UI pages: separate objects because a UI page may load before the background page and it can read prefs from localStorage/sync/defaults
2017-04-18 12:46:34 +03:00
tophf
7084dd1223 createStyleElement speedup: reuse the template 2017-04-18 12:46:33 +03:00
tophf
2a7231a887 manage: update state tooltips; add filter option
* update state is shown in tooltips that fade out in 10 sec except for .update-problem and .can-update
* when updates are found a filtering option is revealed; when it's checked only entries with updates are shown; when all updates are installed the option automatically hides
2017-04-18 12:46:32 +03:00
tophf
2bb7d31042 fixups for Opera/Vivaldi/Firefox-compatibility 2017-04-18 12:46:32 +03:00
tophf
ff84e924fa polyfill DOM enumerables for Chrome 49 2017-04-18 12:46:32 +03:00
tophf
c061268aeb manage: fix & speedup createStyleElement a bit 2017-04-18 12:46:31 +03:00
tophf
f147b409df embed SVG to help buggy Chrome's GC
Chrome doesn't garbage-collect (or even leaks) SVG <symbol> referenced via <use> so we'll embed the code directly on manage and popup pages where dozens/hundreds of svgs are displayed.
2017-04-18 12:46:31 +03:00
tophf
4f5e56bc55 manage: don't flicker newUI sub-options 2017-04-18 12:46:31 +03:00
tophf
e3b461a9e8 manage: add new UI option
* align svg icons to pixel grid
* globalize enforceInputRange() and use it in manage
* 1 installed.onclick instead of 1000+ local ones
2017-04-18 12:46:31 +03:00
tophf
0ceff44000 manage: use svg icons in messageBox() 2017-04-18 12:46:30 +03:00
tophf
1cf904b135 polish popup/manage/edit css/svg/etc.
* restore the correct width of svg icons
* popup: use the standard formatting & SVG <symbol>
* popup .breadcrumbs hover highlight
* manage: black links, transitions; use <p> in #options; trim .homepage
* edit: move regexp tester info link to a template
2017-04-18 12:46:29 +03:00
tophf
3c5cc141c4 manage: make #find-editor-styles a link; remove global options
* "Find styles" is a link so we make it one, just like in the popup.
* We have a dedicated global options UI so it makes no sense to subset only two of them on the manage page, moreover both options are unrelated to managing styles.
2017-04-18 12:46:29 +03:00
tophf
ac4a420e2b ESLint: customize the rules; fix the issues 2017-04-18 12:46:23 +03:00
tophf
363f752934 Use messageBox in manage for confirm; partially revert c5741aff 2017-04-18 12:46:23 +03:00
tophf
4936426fa3 dom.js: extract common DOM functions 2017-04-18 12:46:22 +03:00
tophf
b51c264c8b confirmDelete: extract, refactor, use in manage 2017-04-18 12:46:22 +03:00
tophf
b1c19bdf3d Import styles: show report with Undo button 2017-04-18 12:46:22 +03:00
tophf
c1338e63d1 Highlight updated/saved style in manage page 2017-04-18 12:43:30 +03:00
tophf
2f4da37fdb Refactor and speed up popup & manager
Popup:
* Enforce 200-800px range for the popup width option

Manage:
* faster search via cachedStyles.byId
* faster restoration of search results on history nav
* style name is clickable and opens the editor
* animated highlight of style element on update/add/save
* expandable extra applies-to targets
* remember scroll position on normal history navigation
* boz-sizing in #header, also in editor
* applies-to targets use structured markup
* get*Tab*, enableStyle and deleteStyle are promisified
2017-04-18 12:43:29 +03:00
tophf
df570dab9e Store SVG icons in a <symbol> collection
+preserve the page colors via fill:currentColor and opacity transition.
2017-04-18 12:43:28 +03:00
narcolepticinsomniac
e94f9d818e Get rid of text decoration in disabled styles
Fixes https://github.com/schomery/stylish-chrome/pull/58#issuecomment-290607298
2017-03-31 07:14:47 -04:00
narcolepticinsomniac
df0f45dc06 Switch info/external style link icons from img to svg
Switched info to `i` and found a pretty nice external link icon imo. @tophf As for pixelation on the info icons, you mentioned maybe a lighter color would help. For all icons besides external links, I made them lighter with darker hovers. Besides a really high zoom, I never saw any issue to begin with, but let me know if they're alright. I also changed them to use their exact original dimensions, so maybe that helps.
2017-03-30 19:49:03 -04:00
tophf
7d5b9b8a34 New backup labels by narcolepticinsomniac 2017-03-16 13:32:13 +03:00
tophf
08509b8cc2 Support file drag-n-drop on the entire manage page 2017-03-16 13:32:13 +03:00
narcolepticinsomniac
9aa389c0f2 Options UI discoverability & other fixes 2017-02-28 19:09:49 -05:00
narcolepticinsomniac
9a2cab60dd Options UI discoverability and other fixes
#34
2017-02-28 18:57:03 -05:00
narcolepticinsomniac
fa159cf845 Options UI discoverability
#34
2017-02-24 06:04:43 -05:00
narcolepticinsomniac
396edfa1b0 Change 'body' id 2017-02-13 01:20:10 -05:00
Jeremy Schomery
f8fc82cae7 code cleanup; fileSaveLoad.js 2017-02-05 09:55:44 +03:30
Jeremy Schomery
a13bce4673 Removing moment.js dependency 2017-02-05 09:41:23 +03:30
narcolepticinsomniac
2eca976b21 Removed warning for editor styles. 2017-02-03 07:53:27 -05:00
narcolepticinsomniac
801c637d7e Update for backup 2017-01-30 14:22:28 -05:00
Jeremy Schomery
1fdf94a463 #1 follow up 2017-01-13 20:03:52 +03:30
Jeremy Schomery
695cf605c3 allow scrollbar for manager's header section 2017-01-13 12:30:01 +03:30
Jeremy Schomery
5623bca182 #1 follow up 2017-01-13 12:23:17 +03:30
Jeremy Schomery
12859b96be a simpler instruction to import styles 2017-01-11 18:41:33 +03:30
Jeremy Schomery
c1ab447130 Removing sending info to Google Analytics 2017-01-11 15:34:44 +03:30
Jeremy Schomery
9582c65a84 import styles from Stylish extension 2017-01-11 15:25:38 +03:30
Jason
5fb21f2816 Add opt-out for analytics and make it ping once per day 2016-03-23 21:38:15 -05:00
Jason
1dd9153590 Add privacy policy link and reformat the links 2016-03-19 21:45:41 -05:00
Jason
fa97a94494 Various performance improvements 2016-03-19 16:58:01 -05:00
Jason
cc95a62c7c Various Firefox error and warning fixes #166 2016-03-07 23:22:28 -06:00
tophf
485932ae49 Update world_go.png to 32x32, also suitable for retina 2015-09-01 21:50:33 +03:00
Jason Barnabe
7f0557df57 Merge pull request #143 from tophf/fixes
Fixes
2015-08-04 22:37:17 -05:00
tophf
ad12fb1091 Manage: fix broken horizontal scrolling 2015-08-03 20:07:42 +03:00
tophf
4f61494e0d Move html templates to html file 2015-08-03 08:13:01 +03:00
tophf
9cfa214d19 Manage: remember scroll position, initialize styles earlier 2015-06-10 12:20:37 +03:00
tophf
36a70fa612 Manager: search styles filter 2015-05-14 19:57:05 +03:00
tophf
0e6f63951a Localization: embed in html, autorun, apply earlier 2015-05-01 13:33:01 +03:00
Jason
c8ce70f964 Restore header for narrow width edit and standardize position 2015-03-23 19:52:18 -05:00
Jason
80691ed80e Make the filter legend black instead of grey 2015-03-23 19:42:17 -05:00
Jason
7a2d978d4a Fix shadowy border thing on edit screen 2015-03-23 18:51:51 -05:00
Jason
00d5972cac Drop logo from manage page 2015-03-23 18:44:26 -05:00
Jason Barnabe
d092cc7553 Merge pull request #78 from tophf/icons
Add SVG icon, compress PNG icons with pngquant+optipng
2015-03-23 11:15:22 -05:00
tophf
f7929cc8d1 fixup: limit the logo size for the narrow layout 2015-03-23 19:01:38 +03:00
tophf
dc715f697d fixup: embed the SVG logo in html 2015-03-23 18:48:51 +03:00
tophf
1ab749b516 Add SVG icon, compress PNG icons with pngquant+optipng 2015-03-23 17:01:22 +03:00
tophf
6b710e9f56 HTML fixes: close a tag, replace 0px with 0 2015-03-20 17:29:48 +03:00
tophf
3dd8eb1fc6 Manager: "Apply all updates" button 2015-03-20 17:29:48 +03:00
hideheader
222f970d23 [option] List actions before styles in the popup
Styles are listed before actions by default. Actions are listed before
styles if `popup.stylesFirst` is false. A control for the option is shown
in "Manage" if `popup.stylesFirstUI` is true.
2015-03-14 21:35:45 -04:00
hideheader
a0482d3f0b Listing filters for 'Manage'
Two independent filters. One allows only styles that are enabled, the
other allows only styles that were written locally (that is, styles
without an update URL).
2015-03-14 13:33:36 -04:00