Compare commits

..

1626 Commits
v1 ... master

Author SHA1 Message Date
b2bfde4426 Fix sliders, but for real this time (pt 2) 2024-12-28 03:41:23 +01:00
8602b53260 Fix sliders, but for real 2024-12-28 03:14:53 +01:00
145b361581 Fix 2024-12-28 02:05:42 +01:00
7743dd8e7f Add sliders 2024-12-28 02:02:01 +01:00
ed2886d449 add minEnabledHeight to settings 2024-12-28 01:42:13 +01:00
002dfacc3e change timeout a bit 2024-12-28 00:42:53 +01:00
fd9fbc32a8 Remove some console.logs 2024-12-28 00:42:40 +01:00
e54deeb4f7 save settings when changing parameters 2024-12-28 00:41:07 +01:00
c85f211d5e Add reset settings to options 2024-12-27 23:13:12 +01:00
67f848a9ee Unbreak showing popup on hover 2024-12-27 23:12:41 +01:00
fe336122e0 Make crop iptions and stretch options panels editable by default without breaking the popup. Add them to UI and keyboard section of settings 2024-12-27 13:18:31 +01:00
6d8d8493a6 Zone editor mostly finished 2024-12-27 04:41:35 +01:00
5d7d249fff Fix overlay positioning 2024-12-27 04:40:30 +01:00
35ca030dfb Close window when opening zone edotir 2024-12-26 17:54:05 +01:00
fab6fb0f5b Fix mousemove position calculation 2024-12-26 17:41:00 +01:00
3b8fc807f7 Add corner markers to editor resizer area 2024-12-26 17:40:27 +01:00
13cfb9ff14 Checkpoint: aard status indicator + trigger zone editor now kinda works 2024-12-26 14:58:14 +01:00
aabd5e75d8 Update changelog 2024-12-22 23:29:43 +01:00
7be6fb9501 Add fallback option class (currently unused) 2024-12-22 23:20:07 +01:00
9fc63e5cd3 Add player UI settings panel 2024-12-22 23:17:32 +01:00
7a1e8be48a attempt to shut some warnings up (but fail) 2024-12-22 23:16:54 +01:00
d299a65e03 fix — open on correct tab 2024-12-22 23:07:55 +01:00
2337f7a3ba add new options to settings interface 2024-12-22 23:06:14 +01:00
4853d7e2fd allow opening of extension settings window on specific tab 2024-12-22 23:05:56 +01:00
ca1a375f2d Limit when in-player UI shows. Add self-expiring menu options that takes you to the proposed, not-yet-implemented UI settings screen 2024-12-17 02:02:49 +01:00
0d098815a2 fix aspect ratio calculations 2024-11-13 01:46:17 +01:00
30cbfb6ffd Make sure that guard line gets invalidated correctly 2024-11-13 01:45:45 +01:00
4c7deffdfe Do full reset of AARD test result every time aard restarts 2024-11-13 01:43:07 +01:00
15133e561f Get autodetection to work at least on a basic level 2024-11-07 02:26:19 +01:00
c235b52e3b fix canvas initialization, add add methods to attach canvas to main body for ez debug 2024-11-07 00:18:40 +01:00
903f356252 Make the context menu slightly less rudimentary 2024-10-24 01:47:46 +02:00
54c44b4379 Add very rudimentary context menu 2024-10-23 01:23:54 +02:00
dcbeecc8cf fix syntax 2024-10-23 01:23:37 +02:00
bf182c65ad Aard should be nominally complete. Probably. 2024-10-22 23:43:25 +02:00
7c5e4101b0 Finish aspect ratio check 2024-10-21 01:08:03 +02:00
2736ac418f WIP on aspect ratio detection 2024-10-19 16:04:20 +02:00
e2dac10501 Finish guardline/image line tests 2024-10-15 17:38:04 +02:00
c15d7ab28e Start re-implementing aspect ratio detection (now with more documentation) 2024-10-14 00:28:13 +02:00
de78f8b1d5 Switch to gl canvas 2024-10-10 00:45:28 +02:00
e56d32180c Add GL canvas wrapper 2024-10-09 23:54:21 +02:00
6c92837317 wip 2024-06-12 20:29:00 +02:00
d4015a86ef Version bump 2024-06-12 09:17:52 +02:00
4b4be96e26 Fix one more link 2024-06-12 09:09:25 +02:00
823e1d983c Remove currently inactive downloads permission 2024-06-12 09:06:12 +02:00
47fba5b81a Fix external links 2024-06-12 03:15:02 +02:00
ee23ebb705 Update permissions for mmanifest v3 2024-06-12 02:17:03 +02:00
d6d3a95daf Last pre-publish fixes 2024-06-12 01:55:12 +02:00
e839e632fc Merge branch 'feature/player-ui' 2024-06-11 02:39:09 +02:00
cb6f0a9a32 Changelog.MD update 2024-06-11 02:36:36 +02:00
c5515934d9 Do the changelog + highlight changelog tab 2024-06-11 02:22:53 +02:00
7dafe85c53 Do the version bump 2024-06-11 01:59:11 +02:00
3bc65c252d I think i disasbled size requirements for in-player UI. Changed wording in popup to reflect that 2024-06-11 01:56:21 +02:00
d4f9ab9f37 Fix player detector panel 2024-06-11 01:55:02 +02:00
b96227b07a plan ahead 2024-06-10 23:40:49 +02:00
da12ee452c Get aard to start reliably if it's set as default aspect ratio for the site 2024-06-10 23:40:33 +02:00
99df043b5f Fix Aard pausing/unpausing when not intended 2024-06-10 23:27:47 +02:00
54d53f1b91 Remove unused code to make Aard work 2024-06-10 23:27:00 +02:00
3645b9ffcf fix typo 2024-06-10 23:26:08 +02:00
9d0ce25be7 Ensure videos get aligned even when aspect ratio is not defined 2024-06-10 00:08:49 +02:00
1c860f74fb remove wiki link, as it's innacurrate 2024-06-09 21:28:57 +02:00
75e31dc3a4 Improve alignment ui 2024-06-09 21:25:11 +02:00
10a8452709 Include changelog 2024-06-09 21:24:26 +02:00
f824f73491 update some libraries 2024-06-09 21:23:25 +02:00
16c34e3d52 ui styling 2024-06-08 03:23:49 +02:00
76c4599dee prepare class names for a day in the future, when we'll move to tailwind 2024-06-08 03:23:34 +02:00
1af80096c7 Add changelog, about panel 2024-06-08 02:10:50 +02:00
cbb2bb4502 Shortcut editor alert 2024-06-06 00:51:47 +02:00
0f3bcaa8e6 Fix alignment/offset handling, make it as player-invariant as possible 2024-06-06 00:51:34 +02:00
ae6575043e fix keyboard shortcut handling for default shortcuts 2024-06-06 00:50:58 +02:00
0dbd5b456c Fix setting keyboard shortcuts 2024-06-06 00:50:08 +02:00
81f3e62446 Pin and close buttons 2024-06-05 23:52:50 +02:00
e0bb25466d UI/global UI mostly works 2024-06-05 01:08:50 +02:00
cb334aab0d Do a bad code, because chrome doesn't work when you try to write good code 2024-06-03 00:16:40 +02:00
9cef850d06 Make extension work on Chrome. Make extension NOT work on firefox. 2024-06-03 00:16:12 +02:00
79ecc87db4 WIP trying to convince in-player UI to show 2024-06-02 16:06:26 +02:00
12644bfbea get manifest v3 to approximately work 2024-05-30 01:02:09 +02:00
bc6b58aa3f Ensure transform offsets are is rounded 2024-05-07 21:02:22 +02:00
abeded1d03 Further migrations to runlevel 2024-05-07 21:02:04 +02:00
a466f77b6e Merge branch 'master' into feature/player-ui 2024-05-07 20:28:39 +02:00
968ce5432a RunLevel works, even though half-assed 2024-05-07 20:24:50 +02:00
277506b3c8 Start implementing run levels 2024-05-07 19:05:10 +02:00
1c48ea1908 Reorder panels in video settings 2024-05-04 01:08:42 +02:00
f2ac1557a4 Fix icon & heading sizes in popup 2024-05-04 01:08:32 +02:00
7213c1e35f Fix padding 2024-05-04 01:08:25 +02:00
9f5f953b46 'Edit shortcuts' bar banner now doesn't take up vertical space while inactive 2024-05-04 01:08:21 +02:00
3ff6054c20 Fix popup (css now finally workS!) 2024-05-04 01:08:14 +02:00
9fb25254a6 Import CSS in vue component instead of html, otherwise popup is without css 2024-05-03 23:13:55 +02:00
8c6a06d490 move fonts 2024-05-03 23:13:07 +02:00
dd37837848 Update node 2024-04-07 15:37:16 +02:00
5ca9325e16 fix 2024-01-28 13:08:31 +01:00
b8fdf0911a Update changelog 2024-01-28 13:01:45 +01:00
a7302fee4b fix angle detection 2024-01-28 13:01:16 +01:00
41bf4d2764 fix 2024-01-28 13:00:48 +01:00
0970140a3a Version bump 2024-01-27 23:29:03 +01:00
b8eb8ec052 rework about panel 2024-01-27 23:06:56 +01:00
46b7d6a25a Round pixel offset 2024-01-27 22:24:09 +01:00
aab2f5b014 fix ard performance display 2023-10-21 17:59:52 +02:00
6062094e6f Fix crashes in chrome 2023-10-21 17:41:09 +02:00
f7e36619df remove manifestv2 2023-10-21 14:04:02 +02:00
167f5173cd get popup to at least mildly work 2023-09-11 00:43:26 +02:00
c7ebd42fe9 some more moving around 2023-09-10 22:09:26 +02:00
94018c6ee3 Cleanup file/directory structure for the UI 2023-09-10 22:06:16 +02:00
388327ec1d fix fs handlers 2023-09-10 19:51:36 +02:00
0ba56c271d hardcode defautl css string somewhere else 2023-09-10 13:12:35 +02:00
bd1216c275 get player select UI to work 2023-07-15 04:17:38 +02:00
3180063fe3 attempt to get player selector to work 2023-07-15 04:03:32 +02:00
9cb9a6607b Remove unused components 2023-07-15 01:29:57 +02:00
42cdcd5c25 Site and extension options: done 2023-07-15 01:28:20 +02:00
8b1da27af7 remove UI when extension is disabled 2023-07-11 00:48:34 +02:00
638e228ce9 don't init UI by default 2023-07-10 22:56:26 +02:00
94469ccd0e mess around with launch.json, still didnt get debugger to work, decided i dont care 2023-07-10 22:05:37 +02:00
48f7e1f39c Merge branch 'feature/manifest-v3-v2' into feature/player-ui 2023-07-10 22:05:02 +02:00
60f7abfa42 get manifest v3 to approximately work 2023-07-10 22:04:30 +02:00
cd391db302 wip 2023-07-10 18:27:06 +02:00
8613d6971f Showing aard notifications is no longer implemented, so we don't call it 2023-04-16 02:54:30 +02:00
cc18153889 Minor update to site settings 2023-04-16 02:53:59 +02:00
be4bf9e2a3 detect whether extension is enabled on dimension changes. Trigger dimension check on fullscreen change 2023-04-16 02:43:50 +02:00
085bd4aab9 fix video alignment default settings 2023-04-16 02:16:57 +02:00
977d103c3a remove aard::halt() (is duplicate of aard::stop() anyway) 2023-04-16 01:55:11 +02:00
0778f07922 sensible variable naming is important + remove redundant code 2023-04-12 23:08:19 +02:00
e12154601b also add 32:9 button 2023-03-30 00:49:09 +02:00
b22d50f760 Firefox also stopped liking the -alpha# format, so version numbering was switched from [next major]-X.X-[alpha|beta|dev]# to [current-major].99.X-# 2023-03-30 00:45:34 +02:00
302f21b477 Cycle mode 2023-03-30 00:43:30 +02:00
65da515854 various fixes 2023-03-29 22:07:50 +02:00
e9bd3154a5 change event bus parameter names 2023-03-29 21:51:06 +02:00
1da147e110 remove redundant comments 2023-03-29 21:49:27 +02:00
e7dd85420c iframe manager 2023-03-02 01:08:25 +01:00
3e542871c6 Attach source frame info when communicating between frames on the same page 2023-03-02 01:08:16 +01:00
26b78f1225 EventBus: Allow forwarding between iframes of a page 2023-03-02 00:37:23 +01:00
57261b5094 Extension settings now holds both extension and site settings 2023-01-23 00:15:56 +01:00
c7f24133e5 fix ANGLE 2023-01-23 00:15:21 +01:00
87aa397a7c Version bump + changelog 2023-01-22 18:04:26 +01:00
e2a18ec765 Extconfpatch for disney+ 2023-01-22 17:58:39 +01:00
26ee2ffbb6 ANGLE popup 2023-01-22 17:45:33 +01:00
38dd1ddbe8 ANGLE detection 2023-01-22 16:06:33 +01:00
11bc79520a ANGLE detection 2023-01-22 16:05:07 +01:00
cc0ae60c83 Update settings object, finalize-ish site settings panel 2023-01-15 22:11:47 +01:00
30b028d836 remove redundant code 2023-01-15 22:10:17 +01:00
a30a70c6b5 get UI to somewhat work. TODO: get scripts to work 2023-01-07 19:19:44 +01:00
9503003a4a migration to site settings mostly done. TODO: check if things still work 2023-01-07 18:57:47 +01:00
a58edad8ea migrate settings to new and simplified SiteSettings 2023-01-07 03:06:37 +01:00
d0ba619b45 Redefine settings interface, write function to migrate some settings on update 2023-01-07 03:05:51 +01:00
64bad6758b start work on new panels 2023-01-07 03:05:03 +01:00
b902b8f9ba fix some warnings 2023-01-06 19:03:44 +01:00
7bb4ee96e7 return zoom slider to its rightful place 2023-01-06 19:03:35 +01:00
6c3e960096 Player is in a separate component 2023-01-06 18:47:42 +01:00
cacb0f1ea0 Put player window into its own component 2023-01-06 18:23:34 +01:00
5a2e33ccd2 fix 2023-01-06 18:23:12 +01:00
5d389a0796 Rename a file for future consistency 2023-01-06 18:22:15 +01:00
6db1d8af2a remove old dist before build 2023-01-06 18:19:59 +01:00
51d73e09ae ?? 🤔🤔🤔🤔 2023-01-06 18:17:08 +01:00
3c324aa1b2 Add global page (not loaded by extension yet), put mousemove probes in a separate file 2023-01-04 18:09:01 +01:00
a94092ac78 remove unnecessary components 2023-01-04 18:08:11 +01:00
f9d72d12b6 minor changes 2023-01-04 18:07:55 +01:00
81e11c2ae9 Extension options WIP 2022-11-22 01:28:04 +01:00
f7a82ccdf7 re-add missing method 2022-11-21 20:46:51 +01:00
44e3395835 Get basic messaging from popup to CS working. TODO: Forwarding to specific iframes/videos 2022-11-21 01:04:57 +01:00
d558717152 Try to recreate some UI in popup 2022-11-20 23:41:40 +01:00
b9b021f466 Spin off VideoSettings component into subcomponents 2022-11-20 22:45:34 +01:00
13bfd63dc2 Move common things between mousehandler and kbhandler to kbmBase 2022-11-20 17:26:57 +01:00
9600c4f1c9 fix kbm whoopsie 2022-11-20 15:23:23 +01:00
de9696471a kbm refactoring stuffs 2022-11-20 14:46:01 +01:00
c954f8b984 add playerMouseHandler 2022-09-28 01:18:58 +02:00
08479242f7 fix settings 2022-09-28 00:40:09 +02:00
d70783cc82 Rename canStartExtension to more descriptive isEnabledForSite 2022-09-28 00:39:20 +02:00
a2f0617d5a start splitting kbmHandler into keyboard and mouse handler 2022-09-28 00:38:36 +02:00
27b6ca824d fix action handler rename 2022-09-27 22:15:01 +02:00
e84f8ee541 start fixing KbmHandler (formerly: action handler) some more 2022-09-27 01:48:08 +02:00
ad87dbdcb9 remove unnecessary logging 2022-09-20 01:38:08 +02:00
9c42c120f5 Remove unnecessary components 2022-09-20 01:35:47 +02:00
740f2e8f6f fix forwarding data between server, content script, and popup 2022-09-20 01:34:59 +02:00
a0388689cf Continue slowly working on unified event bus 2022-08-21 22:46:06 +02:00
46cb5e1078 npm fix 2022-08-21 15:50:03 +02:00
abc53cf00f don't fuck ArDetector up 2022-08-21 15:49:28 +02:00
68f367bd39 Merge branch 'master' into feature/player-ui 2022-08-21 15:45:11 +02:00
d54097799c update cleanup script 2022-08-21 15:24:34 +02:00
ffc25520bb fix types 2022-08-21 15:24:24 +02:00
ccdc68870a Fix #199 2022-08-21 15:04:21 +02:00
7820da181e Readability fixes (I guess) 2022-08-20 16:04:31 +02:00
ec4d43d2ec unpause: Don't resume autodetection if not paused 2022-08-08 23:17:13 +02:00
c12a04b55f mostly whitespace 2022-08-08 23:16:55 +02:00
e0fe4c7103 Version bump + changelog 2022-08-06 01:56:12 +02:00
82f2983ac2 package.lock update 2022-08-06 01:31:40 +02:00
d2733cf486 Fix autodetection getting stuck in 21:9 2022-08-06 01:31:18 +02:00
3aabd298ec fix various fuckies wuckies 2022-07-31 01:12:54 +02:00
a0e375d2dc Cleanup — remove old uwui implementation 2022-07-31 00:18:21 +02:00
8806c8ea0c Integrate comms client/server into eventBus 2022-07-31 00:15:28 +02:00
f0120010fe do types 2022-07-31 00:14:40 +02:00
a5a121ee00 flag for whether autodetection is currently active 2022-07-30 23:07:33 +02:00
459a0eaa91 build lied? 2022-07-30 00:55:20 +02:00
84fefbaa14 remove some console.logs 2022-07-30 00:54:12 +02:00
023b8c370a fix tslint complaints 2022-07-30 00:52:14 +02:00
0a023ac6f2 fix command 2022-07-30 00:47:11 +02:00
83f7e4498a npm audit fix maybe? 2022-07-30 00:32:23 +02:00
d57040fc5b Merge branch 'master' into feature/player-ui 2022-07-30 00:29:23 +02:00
7df62ba530 Version bump + changelog 2022-07-30 00:15:15 +02:00
f51ec50113 fix aard, attempt 3 2022-07-29 00:42:35 +02:00
6748cbe52d update package.lock 2022-07-29 00:25:29 +02:00
fda2dcc484 fix aard: fix harder ? 2022-07-29 00:25:16 +02:00
07a5f06695 Merge branch 'dependabot/npm_and_yarn/shell-quote-1.7.3' 2022-07-29 00:21:52 +02:00
c9392911d9 fix aard? 2022-07-29 00:21:34 +02:00
88dec55116 get DRM status in player ui 2022-07-28 00:45:35 +02:00
f30de3f4a0 Add debug panel with logger 2022-07-27 01:16:14 +02:00
3c5aafee2d update package.lock 2022-07-26 23:55:39 +02:00
52b4e48217 start extension popup rework 2022-07-26 23:54:25 +02:00
58ed3b1ca4 Update changelog 2022-07-26 22:41:12 +02:00
bfef49bc33 fix stuff from merge 2022-07-26 22:40:45 +02:00
b7a61e5bc0 Rework blackframe to not use its own drawImage call 2022-07-26 22:15:39 +02:00
dependabot[bot]
15a3ffd406 Bump shell-quote from 1.7.2 to 1.7.3
Bumps [shell-quote](https://github.com/substack/node-shell-quote) from 1.7.2 to 1.7.3.
- [Release notes](https://github.com/substack/node-shell-quote/releases)
- [Changelog](https://github.com/substack/node-shell-quote/blob/master/CHANGELOG.md)
- [Commits](https://github.com/substack/node-shell-quote/compare/v1.7.2...1.7.3)

---
updated-dependencies:
- dependency-name: shell-quote
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-26 19:59:10 +00:00
66f934e46e fix version but reals 2022-07-26 21:57:22 +02:00
47b85cfebc Revert "Bump node-sass from 4.14.1 to 7.0.0"
This reverts commit 9a3bd3ff88.
2022-07-26 01:24:33 +02:00
d0b060f31a Changelog + fix version bump 2022-07-26 01:20:29 +02:00
a756a9dc16 Version bump 2022-07-26 01:13:25 +02:00
207b82cc8b Fix set-extension-commnand for people who installed extension while this command was misspelled 2022-07-26 01:12:42 +02:00
26df9633b4 Remove ancient migrations 2022-07-26 01:10:11 +02:00
2b749d6a3b fix set-extension-mode commands 2022-07-26 01:04:36 +02:00
8c403f106c Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/terser-4.8.1' 2022-07-26 00:52:25 +02:00
36aa226e9c Reimplement blackframe. Start timing blackframe execution. Add some placeholder UI for autodetection settings 2022-07-26 00:52:06 +02:00
dependabot[bot]
1946b77285 Bump terser from 4.8.0 to 4.8.1
Bumps [terser](https://github.com/terser/terser) from 4.8.0 to 4.8.1.
- [Release notes](https://github.com/terser/terser/releases)
- [Changelog](https://github.com/terser/terser/blob/master/CHANGELOG.md)
- [Commits](https://github.com/terser/terser/commits)

---
updated-dependencies:
- dependency-name: terser
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-20 14:48:52 +00:00
a09ea26b0e Rework blackframe to not use its own drawImage call 2022-07-13 00:22:16 +02:00
1556506bd7 monitor autodetection performance 2022-07-13 00:21:21 +02:00
f94f6ec956 Autodetect script can now report performance data 2022-06-28 22:34:47 +02:00
aae566b82a stuff we missed in previous cleanup 2022-06-28 22:34:20 +02:00
dd8aeefdfd Clean up some performance stuff for autodetection 2022-06-28 20:53:50 +02:00
7d951a5115 comment cleanup 2022-06-28 19:28:14 +02:00
556722693c Rearrange things a bit. No longer do fallback mode 2022-06-28 01:33:21 +02:00
78f350b72b UI design for player selection is mostly done 2022-06-16 00:07:03 +02:00
340ee05443 fix pointer events 2022-06-15 00:53:43 +02:00
561a1aa5a5 Add more styling, choose few quick actions 2022-06-15 00:43:36 +02:00
e2fa4f9cfc some things weren't as "no longer needed" as initially thought 2022-06-14 23:23:08 +02:00
ee56187c9d give player section an icon 2022-06-14 23:20:26 +02:00
d3dbceb749 fix 2022-06-14 23:20:07 +02:00
799c953b30 Remove code no longer needed 2022-06-14 00:27:37 +02:00
e766d6da69 Allow users to set player element from the popup 2022-06-14 00:26:06 +02:00
53ed81fa81 showing and hiding of ultrawidify UI 2022-06-11 15:40:36 +02:00
320d35d9e5 holy shit we did it 🅱️ois, we made some progress on improving manual player detection 2022-06-10 00:22:06 +02:00
a1bfaaaf92 wip 2022-06-09 17:41:04 +02:00
03ebc87aa5 Prepare rendering of basic element tree 2022-06-09 09:01:30 +02:00
d2447d2d8a player detect panel boilerplate 2022-06-09 01:29:26 +02:00
296f146835 Refactor player detection + have player detection log some data for use in settings window 2022-06-09 01:28:46 +02:00
9a7e38d897 dict update 2022-06-09 01:27:50 +02:00
f0fcf996c9 set default stretching and cropping for site and extension in UI 2022-05-25 00:18:54 +02:00
c1b14979a2 also get alignment to work from player UI 2022-05-24 23:48:26 +02:00
9e9fdfe37f get zoom to work again 2022-05-24 23:45:41 +02:00
135ce2dfdd Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/async-2.6.4' 2022-05-06 00:28:52 +02:00
167d46ca76 Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/minimist-1.2.6' 2022-05-06 00:28:47 +02:00
23d2c252fe Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/object-path-0.11.8' 2022-05-06 00:28:43 +02:00
9100c1d9de Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/node-fetch-2.6.7' 2022-05-06 00:28:38 +02:00
b45b232ecf Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/path-parse-1.0.7' 2022-05-06 00:28:35 +02:00
9648d30aa2 If videoData is destroyed, remove its eventBus from pageInfo's downstream buses 2022-05-06 00:28:13 +02:00
5a04c2eeee Migrate actionHandler to new commands 2022-05-06 00:23:15 +02:00
74fe85f3a2 Put a parent event bus to pageInfo 2022-05-06 00:23:01 +02:00
4b44efe6fc Finish event bus propagation 2022-05-06 00:22:35 +02:00
dependabot[bot]
8922054c44 Bump async from 2.6.3 to 2.6.4
Bumps [async](https://github.com/caolan/async) from 2.6.3 to 2.6.4.
- [Release notes](https://github.com/caolan/async/releases)
- [Changelog](https://github.com/caolan/async/blob/v2.6.4/CHANGELOG.md)
- [Commits](https://github.com/caolan/async/compare/v2.6.3...v2.6.4)

---
updated-dependencies:
- dependency-name: async
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-29 00:39:55 +00:00
302353f448 Style dropdowns 2022-04-13 23:03:55 +02:00
3891d946e0 Add new aspect ratios. Fix deleting old aspect ratios. 2022-04-13 21:15:33 +02:00
e92e2e22f5 Update and delete keyboard shortcuts 2022-04-13 01:17:25 +02:00
4f4eb46a60 Clear keyboard shortcut 2022-04-13 00:24:10 +02:00
0daef615c1 Sort out inputs, shortcut button 2022-04-12 00:48:33 +02:00
6ce8bba6b7 Start working on the edit box for crop settings 2022-04-09 15:58:40 +02:00
09cf3ce54e Reorder some methods around into logical sections 2022-04-09 15:37:23 +02:00
872b0dea6e Change 'official' to 'verified' 2022-03-29 02:01:03 +02:00
376f20aeab Show last selected aspect ratio in the UI 2022-03-29 01:53:16 +02:00
57aae96781 Update button css 2022-03-28 23:57:34 +02:00
7c27c33aa0 Prepare some things for edit mode 2022-03-28 23:57:25 +02:00
7dc354509b Remove some of dem pointless console.logs that are no longer needed 2022-03-28 23:56:52 +02:00
7c09440084 UI base: sort out header and tabs 2022-03-28 23:14:52 +02:00
dependabot[bot]
5538ec4d3d Bump minimist from 1.2.5 to 1.2.6
Bumps [minimist](https://github.com/substack/minimist) from 1.2.5 to 1.2.6.
- [Release notes](https://github.com/substack/minimist/releases)
- [Commits](https://github.com/substack/minimist/compare/1.2.5...1.2.6)

---
updated-dependencies:
- dependency-name: minimist
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-24 16:24:35 +00:00
89168b643c Connect popup (video settings only so far) to content script logic 2022-03-22 01:23:50 +01:00
7fefe255ea Add some things we missed in initial implementation of pointer-events toggling 2022-03-22 01:23:15 +01:00
3423aac49a remove some console.logs 2022-03-22 01:21:18 +01:00
dependabot[bot]
cc8d1d8a94 Bump node-fetch from 2.6.1 to 2.6.7
Bumps [node-fetch](https://github.com/node-fetch/node-fetch) from 2.6.1 to 2.6.7.
- [Release notes](https://github.com/node-fetch/node-fetch/releases)
- [Commits](https://github.com/node-fetch/node-fetch/compare/v2.6.1...v2.6.7)

---
updated-dependencies:
- dependency-name: node-fetch
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-20 23:52:29 +00:00
dependabot[bot]
c0a863740a Bump object-path from 0.11.5 to 0.11.8
Bumps [object-path](https://github.com/mariocasciaro/object-path) from 0.11.5 to 0.11.8.
- [Release notes](https://github.com/mariocasciaro/object-path/releases)
- [Commits](https://github.com/mariocasciaro/object-path/commits/v0.11.8)

---
updated-dependencies:
- dependency-name: object-path
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-20 23:52:23 +00:00
dependabot[bot]
f006eed113 Bump path-parse from 1.0.6 to 1.0.7
Bumps [path-parse](https://github.com/jbgutierrez/path-parse) from 1.0.6 to 1.0.7.
- [Release notes](https://github.com/jbgutierrez/path-parse/releases)
- [Commits](https://github.com/jbgutierrez/path-parse/commits/v1.0.7)

---
updated-dependencies:
- dependency-name: path-parse
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-20 23:52:22 +00:00
3f131f44d1 Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/prismjs-1.27.0' 2022-03-21 00:51:22 +01:00
5cfc089bf1 Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/ajv-6.12.6' 2022-03-21 00:51:20 +01:00
987b1ad655 Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/node-sass-7.0.0' 2022-03-21 00:51:16 +01:00
1cd06040da Toggle 'pointer-events' based on whether mouse hovers over a csui element or not 2022-03-21 00:50:54 +01:00
f99220bf8b Process messages from content script, respond with results 2022-03-21 00:50:03 +01:00
8bef1d0c99 something's fucky with window.parent.location 2022-03-20 20:56:29 +01:00
47a73cfa6c Get page URL from window.parent.location instead of window.location for iframe 2022-03-20 20:44:50 +01:00
2dd901b1d5 Mark ui as clickable 2022-03-20 20:43:49 +01:00
46725c6fa4 Send mouse coordinates to the iframe 2022-03-20 20:40:11 +01:00
dependabot[bot]
adfc3fca5f Bump prismjs from 1.23.0 to 1.27.0
Bumps [prismjs](https://github.com/PrismJS/prism) from 1.23.0 to 1.27.0.
- [Release notes](https://github.com/PrismJS/prism/releases)
- [Changelog](https://github.com/PrismJS/prism/blob/master/CHANGELOG.md)
- [Commits](https://github.com/PrismJS/prism/compare/v1.23.0...v1.27.0)

---
updated-dependencies:
- dependency-name: prismjs
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-26 02:33:31 +00:00
dependabot[bot]
077610820c Bump ajv from 6.10.2 to 6.12.6
Bumps [ajv](https://github.com/ajv-validator/ajv) from 6.10.2 to 6.12.6.
- [Release notes](https://github.com/ajv-validator/ajv/releases)
- [Commits](https://github.com/ajv-validator/ajv/compare/v6.10.2...v6.12.6)

---
updated-dependencies:
- dependency-name: ajv
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-12 13:52:45 +00:00
dependabot[bot]
9a3bd3ff88 Bump node-sass from 4.14.1 to 7.0.0
Bumps [node-sass](https://github.com/sass/node-sass) from 4.14.1 to 7.0.0.
- [Release notes](https://github.com/sass/node-sass/releases)
- [Changelog](https://github.com/sass/node-sass/blob/master/CHANGELOG.md)
- [Commits](https://github.com/sass/node-sass/compare/v4.14.1...v7.0.0)

---
updated-dependencies:
- dependency-name: node-sass
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-10 19:16:57 +00:00
85fed9d4c5 Hot dang, icons now show up in Chrome as well.
Also cleaned up some of the mess.
2022-01-29 16:23:40 +01:00
5a2d8d22cb Move extension popup into an iframe, get it to display at least something 2022-01-07 00:50:58 +01:00
761f2c21a8 fixes 2021-11-25 22:16:48 +01:00
c34340d0d1 install mdi font 2021-11-25 22:16:16 +01:00
045cd5a528 Stop using some of the old code 2021-11-25 20:00:32 +01:00
27b0609d34 Let's try to avoid injecting ultrawidify-specific CSS before we actually need it. Part 1/? 2021-11-25 00:31:38 +01:00
65556d9cad We will need to distinguish between two automatic aspect ratio types
AspectRatioType.Automatic: "start autodetection pls"
AspectRatioType.AutomaticUpdate: "Hi I'm aard and I want to change this aspect ratio to something new"
2021-11-25 00:14:06 +01:00
30835e94c0 UI: can set default crop, stretch. (TODO: actually get and use those values) 2021-11-23 01:32:55 +01:00
ee8ac1d9ee Site support level works now ... for most values of work 2021-11-21 02:08:53 +01:00
2be44d54ae Try achieving css class rename some more 2021-11-21 02:08:32 +01:00
cf8bedfad9 fix an oversight 2021-11-20 20:56:49 +01:00
5dc9b498d4 sample jenkins test 2021-11-13 00:57:41 +01:00
fb7a168d31 whitespace 2021-11-13 00:55:17 +01:00
484db037c0 use event bus 2021-11-13 00:54:20 +01:00
15a89583a2 Package updates 2021-11-13 00:48:08 +01:00
75cc0d5a87 handle alignment along y 2021-11-03 00:08:34 +01:00
0e3b962a00 whitespace 2021-11-02 22:20:01 +01:00
afaf65a53d Fix stretch mode from ui 2021-11-02 22:19:50 +01:00
f00d3b5aaf Fix zoom, but for realses 2021-11-02 20:52:01 +01:00
03bd442783 do the version bumping thing again 2021-11-02 20:51:45 +01:00
787bd1a532 Prevent eventBus from crashing everything under certain conditions 2021-11-01 01:18:07 +01:00
bd5befc18c Get sliders to update with values from aspect ratio options 2021-11-01 01:13:13 +01:00
829047585a Get manual zoom to work 2021-11-01 00:11:14 +01:00
78da45d468 cosmetic stuff 2021-10-31 23:18:44 +01:00
7f7ab7b752 Add some things to mitigate windows/wsl suckiness 2021-10-31 19:03:22 +01:00
79fb10c556 Add new format for defining actions. They're called commands now. 2021-10-28 22:53:43 +02:00
ffd9c6fb7a ExtConfPatches to typescrtipt 2021-10-28 22:53:23 +02:00
4074774d3a Preemtive version bump and patch notes 2021-10-27 20:46:14 +02:00
e7d43c566f Fix aspect ratio not getting applied correctly 2021-10-27 20:10:55 +02:00
52b94003bf Fix popup not opening 2021-10-27 20:10:21 +02:00
13bd280062 Get event bus to work (for some values of work) 2021-10-26 23:16:11 +02:00
209e4221d2 Start adding event bus 2021-10-26 22:20:50 +02:00
c4832a9ef7 Comment out temporarily unused commands 2021-10-26 20:11:26 +02:00
6cb8cc174b Prevent multiple concurrent vue app instances 2021-10-26 20:11:03 +02:00
e9b882376c Simplify player data dimension change tracking a bit 2021-10-26 00:30:38 +02:00
a4948d3eef Whitespace 2021-10-25 23:13:35 +02:00
746a78577e UI for manual zoom and video alignment 2021-10-24 00:57:57 +02:00
268ef7dae3 push the popup thing a bit further 2021-10-22 00:31:04 +02:00
6c1d666fdf switch bootstrap icons with mdijs 2021-10-22 00:30:36 +02:00
53fb3e8f46 Add stretch actions to the popup, styling 2021-10-19 22:49:56 +02:00
2df0b1a0fb formatting 2021-10-19 22:49:28 +02:00
3846d1a926 Cropping now also works from in-player UI 2021-10-19 22:49:13 +02:00
2a747e11af Merge branch 'master' into feature/player-ui 2021-10-19 20:27:41 +02:00
cda6b4e10d Version bump n shit 2021-09-19 21:32:47 +02:00
502ce707e1 Style 2021-09-19 21:22:12 +02:00
5b1f73a69e Fix problem with autodetection 2021-09-19 21:22:05 +02:00
f7eba0974f Fix default settings 2021-09-19 21:21:23 +02:00
2ae84bccd8 update changelog 2021-09-15 03:13:02 +02:00
3ac3f1aee5 It would be good to disable frame check if AARD is halted or exited 2021-09-15 01:45:51 +02:00
23ca74afdb Add quick readme to the logger 2021-09-15 00:54:46 +02:00
7d894fb1e3 it is higly recommended to actually resolve those promises 2021-09-15 00:54:23 +02:00
b39e6be952 Add a directory for debugging resources (e.g. logs submitted by users).
Since logs can be rather extensive and, more importantly, may accidentally contain PI, we also have them on gitignore.
2021-09-14 23:25:57 +02:00
415ebf6821 Simplify video rescans 2021-09-14 23:22:59 +02:00
b1ec4f7387 Make framecheck ever so slightly async 2021-09-14 19:12:54 +02:00
820af9b133 Patch for netflix 2021-09-13 22:47:27 +02:00
54c88dcb2f we no longer have gitlab 2021-08-28 02:24:23 +02:00
104ed85d72 Get UI to show again 2021-08-26 01:34:59 +02:00
84de5927cd Try initializing UI again 2021-08-26 01:07:39 +02:00
1b829e095b Merge branch 'master' into feature/player-ui 2021-08-26 00:54:07 +02:00
cbb4624e25 Version bump stuff 2021-08-26 00:45:22 +02:00
2cb02ff3f2 fix 2021-08-26 00:45:12 +02:00
b8cd441109 misc fixes 2021-08-26 00:37:56 +02:00
86a8c23999 Change how halting AARD is handled 2021-08-25 23:13:02 +02:00
a2573b5aaf Add performance timing to ar detector + make it use animationFrame 2021-08-25 22:32:39 +02:00
ea8671f64b Tidy up ArDetector 2021-08-25 20:39:27 +02:00
a234903b8f Fix logging popup a bit 2021-08-24 02:13:05 +02:00
981da95cde The logger should be working again? 2021-08-24 00:57:29 +02:00
18fe17f00f Youtube: fix alignment issues with square-ish videos in normal player (#162). Fix issue with misalignment of featured videos on channel page 2021-08-17 19:39:00 +02:00
5ad8302084 Add missing conf for piped.kavin.rocks (fix #151) 2021-07-14 22:45:00 +02:00
cfcd0c5945 version bump 2021-07-14 22:06:50 +02:00
eb1b1cf73d changelog 2021-07-14 22:06:42 +02:00
95d3d962f4 I reckon we can drop ExtConfPatches for versions over a year old
like, everyone should have receiving this and future updates should be on 5.x, or at least on 4.5.x
2021-07-14 21:19:39 +02:00
6eb96f917d Goodies for #160 2021-07-14 21:17:32 +02:00
5847215097 Merge branch 'master' into feature/player-ui 2021-07-05 01:22:30 +02:00
d102a8cd7d fix popup 2021-07-05 01:17:10 +02:00
571ac92cd3 Version bump & changelog 2021-07-05 01:02:21 +02:00
246743203f whitespace + plex rule 2021-07-05 00:51:15 +02:00
1cc76ab3b1 Improve UI in advanced settings 2021-07-05 00:49:35 +02:00
5c9112a07b package.json: add npm run dev-[browser] scripts 2021-07-05 00:48:59 +02:00
d92b24a2f6 Merge branch 'master' into feature/player-ui 2021-06-13 02:19:39 +02:00
7729bf545e shut up some of dem vue warnings 2021-06-13 02:19:05 +02:00
c14aa99e5b Fix extconfpatches 2021-06-13 02:18:47 +02:00
2ced591ed4 Fix build errors 2021-06-12 23:23:47 +02:00
56dcd0feb3 Merge branch 'master' into feature/player-ui 2021-06-12 23:22:54 +02:00
c43b1daa42 Edge probably doesn't need the 'pls ensure you're up to date' warning anymore 2021-06-12 23:21:01 +02:00
5e0f7c6160 update package.json — npm start now builds for _all_ browsers 2021-06-12 23:12:04 +02:00
cbaa424fc4 Version bumps and changelogs 2021-06-07 22:16:03 +02:00
c2039da7c8 Make some labels less confusing 2021-06-07 21:57:40 +02:00
6d4b161b06 Fix for disneyplus maybe? 2021-06-07 21:56:57 +02:00
fef2c26cbe raise RAM, second attempt 2021-06-07 20:34:27 +02:00
50719113b1 Raise memory limits in build scripts. Also build edge version on the CI 2021-06-07 20:09:35 +02:00
4e407e2cf8 Edge is supported for a while now, actually. 2021-06-07 19:55:05 +02:00
336879a4a1 Version bump & changelog 2021-05-12 00:19:21 +02:00
7fd28616aa Fix incorrect stretch with fix-source stretch 2021-05-12 00:01:40 +02:00
fba6a8d604 Additional details in the popup 2021-05-11 22:45:08 +02:00
e5c1bcded1 Safety check 2021-05-11 22:44:24 +02:00
b99929063c Restore aspect ratio if offsets fail verification 2021-05-11 22:43:27 +02:00
18d7414b90 refactor 2021-05-11 22:42:51 +02:00
Tamius Han
4427844a41 Merge pull request #154 from tamius-han/dependabot/npm_and_yarn/lodash-4.17.21
Bump lodash from 4.17.20 to 4.17.21
2021-05-11 14:49:50 +02:00
dependabot[bot]
e92f53f590 Bump lodash from 4.17.20 to 4.17.21
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.20 to 4.17.21.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.20...4.17.21)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-10 14:38:04 +00:00
965a48c086 Remove some code that was only needed cos old edge 2021-04-12 20:54:42 +02:00
0edd82479e Put in console.errors on extension initialization. 2021-04-12 20:54:26 +02:00
338b219142 Since webExt polyfill ensures 'browser' is also present in Chrome, code for opening settings page from popup stopped working in Chrome 2021-04-12 20:36:42 +02:00
c504d5594c Version bump 2021-04-12 20:31:50 +02:00
9beeffc679 Force old chrome installs to force-enable the zoom limit 2021-04-12 20:30:42 +02:00
19e021ce8e Update 'what's new'? 2021-04-12 20:27:49 +02:00
c863447f3d ; 2021-04-12 20:25:44 +02:00
520b0b7ade Extra comments 2021-04-12 19:08:12 +02:00
48e12c8504 Fix player detection on videos wider than the monitor 2021-04-12 19:03:18 +02:00
60f940f4db try/catch in aspect ratio getter 2021-04-12 19:01:28 +02:00
0bed840b6f fix settings interface 2021-04-10 04:17:07 +02:00
ddbddc45a9 Whitespace and stuff 2021-04-10 04:10:22 +02:00
a039fd4ce4 Make isFullscreen a bit more lenient.
innerWidth|Height and screen.width|height no longer need an exact match
2021-04-10 04:10:12 +02:00
d3c3c99069 fix 'is extension enabled' query 2021-04-10 04:09:00 +02:00
843a405323 get settings for current site function 2021-04-10 04:08:35 +02:00
cb548c3a3d aspect ratio is a getter now. Use said getter 2021-04-10 04:08:09 +02:00
d406438527 Enable zoom limit for new installs in Chrome as well 2021-04-10 04:03:14 +02:00
6737061713 Add new settings option 2021-04-10 04:02:52 +02:00
46c635b11b Chrome still has that bug 2021-04-08 21:53:49 +02:00
5f04c03f80 Correct changelog to account for Edge. 2021-04-05 03:31:07 +02:00
dbf96f97b6 Fix :disabled for a certain checkbox 2021-04-05 03:30:49 +02:00
861e62dc56 Add confPatch for Edge 2021-04-05 03:30:29 +02:00
1b00420388 correct the interface 2021-04-05 03:29:56 +02:00
0ac57ca2ac add target:blank to links 2021-04-05 03:29:35 +02:00
58e29f4590 Remove logging, typos 2021-04-04 23:55:49 +02:00
8e544a6ae0 make build-all script windows-friendly (or windows-friendlier)
still requires bash tho
2021-04-04 23:55:34 +02:00
2cf42cb6ed Add link to blog 2021-04-04 23:19:50 +02:00
93eb67ca49 Prevent recursing 2021-04-04 23:19:43 +02:00
58302ea87c move @types/node to dev dependencies 2021-04-04 15:54:28 +02:00
f17bae8f39 more vscode configuration stuff 2021-04-04 15:53:06 +02:00
fee73519e6 formatting 2021-04-04 15:48:46 +02:00
5d1ad6f935 remove unnecessary logging 2021-04-04 15:48:33 +02:00
6d07fc24e4 we did a npm -i again 2021-04-04 15:48:11 +02:00
a720556ac9 typos and dict update 2021-04-04 15:48:01 +02:00
0bc1254ce0 Merge branch 'master' into feature/player-ui 2021-04-04 03:59:08 +02:00
f8bd8e2eec Update "what's new" stuff. 2021-04-04 03:58:26 +02:00
d0beb137fe Version bump 2021-04-04 03:58:08 +02:00
c6e4d06fa1 Allow toggling chrome hardware acceleration bug workaround for people not experiencing it 2021-04-04 03:42:36 +02:00
190737b915 Merge branch 'master' into feature/player-ui 2021-04-01 23:50:08 +02:00
902f880a68 no stray logs 2021-04-01 21:44:07 +02:00
624c072bb3 Changelog + version bump 2021-04-01 21:43:19 +02:00
09253fe0a1 Unbork settings page even more 2021-04-01 21:40:58 +02:00
a0eeabbd50 Fix for #142, possibly 2021-04-01 21:24:19 +02:00
873a8cf3a8 Fix enum imports 2021-04-01 21:23:59 +02:00
9c1fb77dc8 Turn all logging off for release 2021-03-31 00:10:41 +02:00
0a3627c7fe Don't attempt height:auto compensation if style height compensation is active 2021-03-31 00:10:18 +02:00
2a4a3f7192 change mailto link 2021-03-30 23:40:06 +02:00
0b30688d59 update changelog a bit more 2021-03-30 23:39:41 +02:00
5cbfb70306 add some folds to code 2021-03-30 21:55:17 +02:00
63e40cf71a Compensate for height:auto in certain scenarios 2021-03-30 21:54:44 +02:00
d1baebcceb Add types, return crop strategy with stretch factors 2021-03-30 21:54:08 +02:00
c07916362e log a lil bit less. Fix mutation observer callback 2021-03-30 20:38:16 +02:00
d382b46464 Log a lil bit more 2021-03-30 01:11:39 +02:00
78c66a1543 update packages ... some of them, at least, so we can really use ResizeObserver 2021-03-30 01:11:11 +02:00
48319acc31 okay, we can't ditch mutationobserver 5ever 2021-03-30 01:10:37 +02:00
b634e4d2b3 remove some logging 2021-03-29 23:40:34 +02:00
03f37fa1a3 long live ResizeObserver, let's ditch MutationObserver five-ever 2021-03-29 23:30:54 +02:00
3185e500d1 Add resizer observer 2021-03-29 23:29:30 +02:00
bf010a243c changelog 2021-03-29 22:52:32 +02:00
9d2b480f3f Use webextension-polyfill in popup 2021-03-29 21:15:01 +02:00
b69a03d42f code cleanup 2021-03-29 21:14:03 +02:00
f1330570d6 fix popup not working 2021-03-29 21:07:54 +02:00
589a1fefbf fix import 2021-03-14 02:34:35 +01:00
d64b41a363 Revert "split popup into ts"
This reverts commit 73eb5ffe93.
2021-03-14 02:33:04 +01:00
e7613aa691 Revert "okay what the actual fuck"
This reverts commit a9ab8d8b92.
2021-03-14 02:32:40 +01:00
e272d1d4d4 Revert "Move popup to vue"
This reverts commit 5b0fcef15c.
2021-03-14 02:32:34 +01:00
0dc196127e Revert "fix imports"
This reverts commit d644395b35.
2021-03-14 02:32:28 +01:00
42394a48bc Revert "fix vue imports"
This reverts commit cd7a1de548.
2021-03-14 02:32:22 +01:00
6546ad2166 Add module resolution to tsconfig 2021-03-14 02:32:14 +01:00
cd7a1de548 fix vue imports 2021-03-14 02:10:41 +01:00
d644395b35 fix imports 2021-03-14 01:29:05 +01:00
5b0fcef15c Move popup to vue 2021-03-14 00:34:47 +01:00
dependabot[bot]
bd1a904fd5 Bump elliptic from 6.5.3 to 6.5.4
Bumps [elliptic](https://github.com/indutny/elliptic) from 6.5.3 to 6.5.4.
- [Release notes](https://github.com/indutny/elliptic/releases)
- [Commits](https://github.com/indutny/elliptic/compare/v6.5.3...v6.5.4)

Signed-off-by: dependabot[bot] <support@github.com>
2021-03-11 23:16:21 +00:00
a9ab8d8b92 okay what the actual fuck 2021-03-12 00:14:52 +01:00
bb3fcc646e Update changelog.md 2021-03-11 22:00:23 +01:00
0f5111e1e2 add vue cli typescript plugin 2021-03-11 21:58:43 +01:00
73eb5ffe93 split popup into ts 2021-03-11 21:58:12 +01:00
8cefa4af2f add vue shim 2021-03-11 21:57:44 +01:00
ede570865f Migrate some more things to typescript 2021-03-11 21:04:09 +01:00
038191d38e Merge branch 'master' into feature/player-ui 2021-03-06 04:07:03 +01:00
6a1f07d881 Merge branch 'typescriptify' 2021-03-06 04:02:59 +01:00
6c59c009e5 Move some last remaining enums to typescript 2021-03-06 04:01:47 +01:00
4354393f79 Do the version bump 2021-03-06 03:57:10 +01:00
d215a10486 move most of the main content/background script to ts 2021-03-06 03:35:33 +01:00
a699166368 Some arguments need to be optional 2021-03-06 03:34:38 +01:00
b83be3de7d More types for logger 2021-03-06 03:34:22 +01:00
db287adaed Remove vestigial code 2021-03-06 02:54:22 +01:00
7714adb843 Fix keyboard shortcuts 2021-03-06 02:53:58 +01:00
3eca178df5 Add type to ports 2021-03-06 02:22:56 +01:00
87310f95cc remove some logs 2021-03-06 02:07:09 +01:00
57ad81a7a4 Move comms to ts (3/3 | client) 2021-03-06 02:06:46 +01:00
c1e0e7b280 Move comms to ts (2/3 | server) 2021-03-06 01:27:28 +01:00
006c9ef975 Move comms to ts (1/3) 2021-03-06 01:23:58 +01:00
08fceafc17 Use browser-polyfill in settings 2021-03-06 01:22:09 +01:00
357d4829eb Fix logger 2021-03-06 01:21:31 +01:00
e5d1addc00 ??? 2021-03-05 23:39:12 +01:00
d4868020f4 DrmDetector can into typescript 2021-03-05 23:35:32 +01:00
7e41768aba Migrate actionhandler to ts 2021-02-20 00:09:17 +01:00
075168ed85 Convert all remaining vars to lets 2021-02-18 22:38:32 +01:00
8475340999 Fix problems in ArDetector and related functions 2021-02-18 22:35:58 +01:00
a3bd8a8b7e convert ArDetector to ts 2021-02-18 22:29:23 +01:00
7e49b493bb Merge branch 'master' into typescriptify 2021-02-18 19:06:37 +01:00
888ffcaded Version bump & update notes 2021-02-18 19:06:23 +01:00
83b8ce0aaa Fix drm detection, but hopefully for real 2021-02-18 19:03:48 +01:00
7f77847baa migrate additional things over from master branch 2021-02-18 01:08:12 +01:00
72da7eb5f4 Merge branch 'master' into typescriptify 2021-02-18 00:15:38 +01:00
5c6ea49c66 Version bump + version notes 2021-02-18 00:13:51 +01:00
6de5ae6355 Fix false positive 'this site cant work cos drm' errors ... xcept for real 2021-02-18 00:13:34 +01:00
ec2cd3d6a0 Fix DRM detector bugs 2021-02-17 01:06:11 +01:00
6031e35133 Add new DRM detection. Do it _before_ launching AARD 2021-02-17 00:51:56 +01:00
b322ef0db1 Fix for #134 2021-02-17 00:23:55 +01:00
4febd2f602 fix 2021-02-17 00:20:30 +01:00
46360d1b1f remove typo from comment 2021-02-09 00:54:04 +01:00
2d8bf0c0ee Move some more files to typescript 2021-02-09 00:52:58 +01:00
a907d0d404 Finish moving videoTransform stuff to typescript 2021-02-09 00:42:52 +01:00
0117d44422 Move settings to typescript. Add interface for settings object 2021-02-09 00:37:54 +01:00
4fdd6af291 Add additional types 2021-02-08 23:23:15 +01:00
9a864bc11c Migrate pseudo-enums to typescript enums. Fix related imports & stuff 2021-02-08 23:04:54 +01:00
ee3ccef0e4 Migrate first batch to typescript 2021-02-08 22:45:51 +01:00
d9053e26b5 update configs 2021-02-08 22:45:41 +01:00
efefa4ef32 update packages 2021-02-08 22:45:34 +01:00
cfc7f6aca6 add new packages 2021-02-08 21:05:27 +01:00
3b79829b72 Do tsconfig and webpack 2021-02-08 20:55:17 +01:00
4d1da636e3 Log just a little on master as well 2021-02-08 20:47:06 +01:00
226cfb654e We don't need this logging on master
This reverts commit dc71a25863.
2021-02-08 20:45:57 +01:00
dc71a25863 Do additional logging 2021-02-08 20:44:49 +01:00
cb5218e52d Only allow one instance of offset validation watcher per video element 2021-02-08 20:44:34 +01:00
f63fd895fe Rework observers a little. Debounce offset validation in videoData 2021-02-08 20:43:56 +01:00
5efa8c88c1 Additional anti-recursing measures, pt 2 2021-02-07 12:54:20 +01:00
870384f83b Decrease callback frequency 2021-02-01 00:11:24 +01:00
02b4b44780 Additional anti-recursing measures 2021-01-31 23:55:50 +01:00
ea186d0aeb always return videoDimensions 2021-01-31 23:32:32 +01:00
96a5b8da8f Add a bit of 'maybe' to "whoops no Aard on this site" notification 2021-01-31 17:57:35 +01:00
f961c8aea8 Don't do logging by default 2021-01-31 17:44:33 +01:00
f3a9c06f92 Anti-recursing measures 2021-01-31 17:44:24 +01:00
78c04523c0 Prevent some more errors 2021-01-31 16:46:33 +01:00
fff575f762 Version bump 2021-01-31 01:54:33 +01:00
bc19164c25 fix pt 4 2021-01-31 01:42:08 +01:00
3ab619799a fix pt 3 2021-01-31 01:34:43 +01:00
f1613b950c fix a lil bit more 2021-01-31 01:18:35 +01:00
ee9599d040 bind this for shits and giggles on onPlayerDimensionsChanged 2021-01-31 01:04:31 +01:00
851f0e0e84 fix pt 2 2021-01-31 00:58:43 +01:00
56ebd2d36c Fix 2021-01-31 00:47:32 +01:00
38d1be5fc2 fix condition 2021-01-31 00:24:02 +01:00
35208cf9e8 log wtf is going on with scaler and resizer 2021-01-30 13:50:11 +01:00
0aa7beb525 Fix chrome condition test 2021-01-30 13:31:30 +01:00
71cb357424 Fix imports 2021-01-30 13:07:19 +01:00
bc5d5046df Webpack fix 2021-01-30 12:21:04 +01:00
5bd2952437 Fix chrome bug .. hopefully 2021-01-30 12:16:37 +01:00
9a0c0ba810 whitespace 2021-01-30 12:16:27 +01:00
a5bf3ec1e0 Remove redundant code 2021-01-30 10:38:45 +01:00
84da78e2e8 expose videoData objects via window.ultrawidify 2021-01-27 00:41:42 +01:00
13b89eb2a9 Add sample button from old config 2021-01-27 00:41:13 +01:00
89c524a690 add video settings placeholder to the UI 2021-01-21 00:21:15 +01:00
d44d1b6e64 add getRuntime() to BrowserDetect 2021-01-21 00:20:43 +01:00
8ea5b3d5be add toString() method to an enum 2021-01-21 00:20:27 +01:00
f8c774700e Merge branch 'master' into feature/player-ui 2021-01-20 22:58:40 +01:00
ef410d9e01 Changelog 2021-01-13 19:33:36 +01:00
328eba1d6c Version bump 2021-01-13 19:33:31 +01:00
b819fc816b Fix DRM detection for Chrome 2021-01-13 01:12:03 +01:00
1410f699c5 Add video status checks 2021-01-13 01:11:55 +01:00
be6df178f6 Optimize catching DRM protected videos. 2021-01-13 01:11:44 +01:00
2a7001ea3a fix 2021-01-13 00:22:42 +01:00
e2eaa206e4 remove console.logs 2021-01-12 23:35:58 +01:00
437890a609 Documentation & comments 2021-01-12 23:28:27 +01:00
2025547d33 Un-initalize videoData on illegal video dimensions ($
When youtube changes between two videos, video dimensions briefly become 0x0. This is super duper illegal and sometimes causes the behaviour described in issue #125. Setting VideoData.videoLoaded to false fixes this.
2021-01-12 23:28:17 +01:00
884db1c5e3 Do event listeners properly 2021-01-12 23:24:20 +01:00
aa1ccedad5 Cosmetic changes 2021-01-12 23:19:04 +01:00
df2b0f5614 Add toString method to aspect ratio enum 2021-01-12 23:18:14 +01:00
aec87e7681 Don't assume jenkins build number is always there, cos it's not on local builds 2021-01-10 20:46:41 +01:00
bf26961aaa Fix formatting in what's new panel 2021-01-10 18:07:58 +01:00
67ad0c54b4 Apply some styling to the edge warning box 2021-01-10 17:43:11 +01:00
fda7b38fa1 fix 2021-01-10 17:25:36 +01:00
5b5f4204bb Version bump 2021-01-10 17:22:12 +01:00
167b9d4305 Disney+ should be fixed? Maybe? See #84 2021-01-10 17:22:02 +01:00
0760e447db Changelog updates 2021-01-10 17:21:23 +01:00
897e65567b add note in the popup 2021-01-10 16:12:35 +01:00
7e403e3406 Edge issues are fixed, so the popup goes. 2021-01-10 16:12:20 +01:00
7cb378029c Some cosmetic changes in BrowserDetect 2020-12-30 15:35:54 +01:00
f4ff7e7ed6 Distinction between chrome build and edge build, and "doesn't matter which of the two" build. 2020-12-30 15:35:08 +01:00
4c359675b6 Build edge version of the addon separately from Chrome 2020-12-30 15:14:03 +01:00
5987fda0b2 Merge branch 'master' into feature/player-ui 2020-12-29 20:36:06 +01:00
066b74e1ac Version bump 2020-12-29 20:34:59 +01:00
af7833a372 Changelog notes 2020-12-29 20:34:02 +01:00
f554030f3c Don't set AR if video dimensions are undefined. 2020-12-29 20:20:00 +01:00
0e0eb57fd9 Merge branch 'master' into feature/player-ui 2020-12-29 18:33:54 +01:00
485a5c13f0 Rewrite popup 2020-12-25 01:27:05 +01:00
bb8d63f67d update base css 2020-12-25 01:26:52 +01:00
6340541daf Attempt to load fonts in popup 2020-12-25 01:26:46 +01:00
028aceef2c Version bump + changelog 2020-12-24 23:27:19 +01:00
5e96cdcad8 Alternative fix for streamable (#128) 2020-12-24 23:26:22 +01:00
c04780bb16 Make a comment explaining reversal to ensure we wont do that thing again 2020-12-24 22:58:48 +01:00
84d33a9ccb Revert "Add 'position:absolute' to video css when setting AR (fix #116)"
This reverts commit a5ef24a50f.
2020-12-24 22:54:20 +01:00
b30369dfea Changelog update 2020-12-23 02:09:30 +01:00
a5ef24a50f Add 'position:absolute' to video css when setting AR (fix #116) 2020-12-23 02:04:06 +01:00
9b1067afc4 Formatting 2020-12-23 02:03:39 +01:00
433057bb19 Edge popup fixes 2020-12-23 02:03:32 +01:00
3704ea7962 Make logger and options object optional for Settings 2020-12-23 02:01:52 +01:00
76b380d6c3 console.log removal 2020-12-23 01:59:49 +01:00
804509b3c5 Move the code that shows the Edge popup back to PlayerData 2020-12-23 01:15:11 +01:00
1e8fd6aad4 Enable aard on netflix for new users, even on Chromium-based browsers
This was done because the edge popup is dependant on autodetection at least attempting to start. Also, we want to show 'autodetection won't work cos drm' on netflix for other chromium-based users.
2020-12-23 01:14:29 +01:00
fbcf4c0c19 Target:blankify all links on the popup. Other minor adjustments. 2020-12-23 01:13:05 +01:00
0234ea7871 Update changelog & bump version 2020-12-22 23:23:36 +01:00
75ec1969c0 Move edge warning popup into the starting phase of autodetection 2020-12-22 23:23:03 +01:00
bcc3d89342 Reset aspect ratio on aard fail 2020-12-22 22:25:41 +01:00
e4194e029c Additional popup updates 2020-12-22 22:25:12 +01:00
d673ed089f Don't commit extension configs submitted by the people reporting a problem. 2020-12-22 21:44:36 +01:00
96ddc8a84b Write the promised blog post & include it in the popup message. 2020-12-22 21:43:45 +01:00
70f7b88d71 Try to fix extension unsetting Netflix' default AR 2020-12-22 03:32:56 +01:00
f174ddab68 Only show the popup in Edge 2020-12-22 03:21:14 +01:00
f7c373481d Add popup for Edge 2020-12-22 03:14:03 +01:00
33d16221cc Remove some logs 2020-12-22 00:12:52 +01:00
dd4d71a496 Add anchor for player UI (base for reworking stuff into Edge 'doesnt work' warning) 2020-12-22 00:12:28 +01:00
c2f1c6980f Fix popup interface not updating — #127 2020-12-21 23:28:23 +01:00
c0c454f3ef Add afterSettingsSaved callback 2020-12-21 23:27:45 +01:00
4b5c5a8dce Fix popup not working at all in Chrome 2020-12-21 19:29:52 +01:00
becf7c328e Add workaround for Chrome refusing to do chrome.runtime from Proxy objects 2020-12-21 19:29:39 +01:00
fbe58ec54d Add static class properties thing to babel 2020-12-21 19:27:34 +01:00
609247cbf0 Fix 'fit height' a little 2020-12-20 01:00:06 +01:00
a9f99d93be Fix aspect ratio calculations on height-compensated videos, episode 1 2020-12-19 03:18:14 +01:00
be82c4dae6 Fix a crash 2020-12-19 03:02:20 +01:00
94a9b1e56f fix 2020-12-18 01:50:00 +01:00
769ff6aace Fix the issue where videos on players that were narrower than the video got cropped a lil bit too much 2020-12-18 01:44:45 +01:00
6e1fe930ac Remove Edge/Microsoft store links from description 2020-12-17 01:51:10 +01:00
93b8049b01 Move debug data into a separate component/panel 2020-12-17 01:49:28 +01:00
5cf74b4405 Fix typo in one of the mutations 2020-12-17 01:49:15 +01:00
2aa91df820 Add additional data to debug popup 2020-12-17 01:48:45 +01:00
85fedbfeaf Fix base css 2020-12-17 01:48:29 +01:00
1cbe74252c display some data 2020-12-16 01:40:09 +01:00
9fb9667dba fix base css 2020-12-16 01:36:00 +01:00
55b6ca7392 fix comms 2020-12-16 01:35:39 +01:00
758c2bf0bc Report data to the UI 2020-12-16 00:19:37 +01:00
6eed271814 Display such data in a very rudamentary way 2020-12-16 00:19:20 +01:00
7a5a4bddf8 support passing debug data between content script and UI 2020-12-16 00:19:02 +01:00
3f8ea683ef Add toString() method to selected enums 2020-12-16 00:18:23 +01:00
29dff35bb4 Merge branch 'master' into feature/player-ui 2020-12-15 21:57:03 +01:00
c1c9dd1625 Version bump 2020-12-15 20:29:33 +01:00
ffa38cf4ff Readme fixes 2020-12-15 20:28:36 +01:00
3d64a08b08 Remove autoarPreventConditions — they're redundant with new way of calculating AR and, as of now, interfere with netflix' ultrawide workarounds 2020-12-15 20:13:23 +01:00
79462c320d Add anchor for player UI 2020-12-15 00:26:19 +01:00
7881ae5290 Update roadmap in changelog 2020-12-14 20:39:28 +01:00
2d6052d715 Update changelog 2020-12-13 23:59:28 +01:00
b4e8622af3 Add hint text in options -> add action popup 2020-12-13 23:31:27 +01:00
7c2cd5cf03 fix icon padding in notification 2020-12-13 23:30:52 +01:00
2a350f404a Remove some logging 2020-12-13 18:54:32 +01:00
6907f65439 Fix code that replaces notification UI so it no longer crashes restore() inside updatePlayerDimension() 2020-12-13 18:54:10 +01:00
5713037c4d Prevent notification UI from blocking website interface 2020-12-13 16:55:30 +01:00
cd26a1ceed Prevent page css from effecting CSS of notification popups (...ish) 2020-12-13 02:03:17 +01:00
c05eed44f0 Did a very bad thing (tm) to appease Chrome (bootstrap icons svg was copied directly into Icon component) 2020-12-13 01:11:52 +01:00
f27b3f1895 Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/ini-1.3.7' 2020-12-12 00:38:59 +01:00
f4f69d4eaa Nest ultrawidify classes inside a css class that guarantees reset of global css 2020-12-12 00:38:51 +01:00
1badce511e add ms icons 2020-12-12 00:12:12 +01:00
dependabot[bot]
595109024a Bump ini from 1.3.5 to 1.3.7
Bumps [ini](https://github.com/isaacs/ini) from 1.3.5 to 1.3.7.
- [Release notes](https://github.com/isaacs/ini/releases)
- [Commits](https://github.com/isaacs/ini/compare/v1.3.5...v1.3.7)

Signed-off-by: dependabot[bot] <support@github.com>
2020-12-11 20:46:40 +00:00
f55731e793 fix popup 2020-12-07 00:09:28 +01:00
6061a3efc5 Add DRM check for Chrome 2020-12-07 00:09:08 +01:00
b6cae36528 fix? 2020-12-07 00:07:59 +01:00
7d8f3912bb Fix extension popup in chrome 2020-12-06 21:57:16 +01:00
eb02865131 Sorta include browser-polyfill but not really
I'm still not rewriting legacy code, but the bRoWsEr iS uNdEfInEd bullshit in (browser || chrome).runtime call there in the notifications pushed some buttons. cc #114
2020-12-05 04:12:37 +01:00
0310e1e2de Finish notification system (for now) 2020-12-05 03:30:43 +01:00
12b15c58f8 LPT: injected components won't get CSS styles if you don't include them in manifest.json 2020-12-05 00:45:48 +01:00
4635dc4eec fix ui 2020-12-04 02:02:25 +01:00
0a5243837f Make buttons unselectable (prolly) 2020-12-04 00:54:03 +01:00
37eccb12f2 Fix normal-sized popup 2020-12-04 00:53:51 +01:00
84db9361f9 Fix default icon margins 2020-12-04 00:53:20 +01:00
3fd432f432 Extra styling for the button 2020-12-04 00:26:39 +01:00
d4947571a4 Try injecting notification UI 2020-12-03 01:35:48 +01:00
e8e9db2bbc Add scss imports 2020-12-03 01:35:34 +01:00
4ed998a9ab Fixes 2020-12-03 01:35:22 +01:00
7900bd18db Pointless changes to logging 2020-12-03 01:16:57 +01:00
357b7a0365 I removed this and stuff still works, therefore it must not have been important 2020-12-03 01:05:57 +01:00
145b237701 Additional logging / change logging 2020-12-03 01:05:39 +01:00
38ef7905c7 Fix a rookie mistake + rename the class 2020-12-03 01:03:29 +01:00
38641df28e add classes for notification UI.
The UI classes are split into "general UI" part — a base class that could potentially be used for proper in-player UI if we ever get to that point — and part that's specific to our notification requirements.
2020-12-03 00:34:50 +01:00
55fbd30699 Add notification UI component 2020-12-03 00:32:33 +01:00
5e4aca66c5 Fix icon css 2020-12-03 00:32:17 +01:00
8325e44a0e Plant a typescript seed into webpack config 2020-12-02 22:39:57 +01:00
a91ed7368f Add icon component 2020-12-02 22:39:43 +01:00
cda4b81554 Add bootstrap icons 2020-12-02 22:39:07 +01:00
be759c512a Version bumps 2020-12-01 01:49:55 +01:00
cfde1ee58c Update changelog with stuff that was done today 2020-12-01 01:48:52 +01:00
db866bf8d8 Add support for wakanim.tv (#113) 2020-12-01 01:48:31 +01:00
d32c083406 Fix quick setting dialogue when extension is in extension overflow menu (#119) 2020-12-01 01:46:53 +01:00
e56551c79d Remove redundant code 2020-12-01 00:22:22 +01:00
97099ece1c Merge branch 'vue3' 2020-12-01 00:21:29 +01:00
f05f37841a Fix logger UI 2020-12-01 00:20:10 +01:00
dbc0c8c741 Fix 'about' section of the options page 2020-11-30 00:50:13 +01:00
2ab01c1013 optionally chain _all_ the things. Again. 2020-11-30 00:38:38 +01:00
ada7e69abd Fix options and popup pages 2020-11-30 00:37:45 +01:00
27e03115d2 Migrate to vue3. Debug popup is broken ATM 2020-11-30 00:17:46 +01:00
1b6d20fa0b Turns out vue update updated jack shit, so optional chaining operators are gonna disappear from vue templates again 2020-11-22 22:48:07 +01:00
aa186da1bd Bump vue 2 2020-11-22 22:46:49 +01:00
a6a09a10b5 Add optional chaining operators back
This reverts commit e25a0a954c.
2020-11-22 22:46:49 +01:00
e25a0a954c Revert "optionally chain _all_ the things"
This reverts commit 1858e092a9.
2020-11-22 22:17:28 +01:00
09f203dd64 Bump vue two major versions #yolo 2020-11-22 22:15:43 +01:00
1858e092a9 optionally chain _all_ the things 2020-11-22 22:12:52 +01:00
e5f2bde6bc add custom setter for settings 2020-11-22 22:12:37 +01:00
0848b2fe67 Some things break youtube, so baseClass is split off into its own component differently 2020-11-06 00:03:11 +01:00
691675bdc2 Awaitable responses to injectCss (& the rest of the gang) 2020-11-05 23:56:41 +01:00
1e70ea51cf This is handled via base class 2020-11-05 23:56:06 +01:00
f8e3a39620 Fix setBaseClass function 2020-11-05 23:55:42 +01:00
6b91444f3c Set, unset base class functions 2020-11-05 23:12:03 +01:00
4f7fc75d6b Version bump 2020-10-25 22:24:30 +01:00
51735ad8c2 What's new 2020-10-25 22:11:24 +01:00
78c34c77e0 Fix for cruncyhroll (#115) 2020-10-25 22:07:38 +01:00
65dacee829 Version bump 2020-10-21 23:56:38 +02:00
288f2334f6 Changelog 2020-10-21 23:55:42 +02:00
43a86a7495 Destroy old pageInfo instance when initializing WU 2020-10-21 23:52:49 +02:00
28c12861e5 Change action handler 2020-10-21 23:52:16 +02:00
7fb9aad0d0 misc fixes 2020-10-21 23:51:58 +02:00
48167623ff Force user styles a bit harder 2020-10-21 21:42:22 +02:00
43b136ca46 Fix crashing when checking player size 2020-10-21 21:26:00 +02:00
ec83830e78 Force zero margins on <video> element.
This should fix issues with alignment on twitch and hulu, et al.
2020-10-21 19:49:26 +02:00
7093236237 fix some issues related to panning 2020-10-21 19:48:56 +02:00
c7d133ba3d ensure aspect ratio only gets changed on aspect ratio changes 2020-10-21 19:48:04 +02:00
47475ac597 document aspect ratio enum 2020-10-21 19:46:25 +02:00
4f478a4667 Calculate "real" displayed side of video instead of relying on offsetWidth 2020-09-23 00:23:24 +02:00
b55d9dd7b9 fix? 2020-09-23 00:19:42 +02:00
02fa4e2fe8 style fixes 2020-09-20 12:26:03 +02:00
e5206b524f Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/bl-3.0.1' 2020-09-20 12:25:24 +02:00
dependabot[bot]
5695534a9a Bump bl from 3.0.0 to 3.0.1
Bumps [bl](https://github.com/rvagg/bl) from 3.0.0 to 3.0.1.
- [Release notes](https://github.com/rvagg/bl/releases)
- [Commits](https://github.com/rvagg/bl/compare/v3.0.0...v3.0.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-09-02 16:26:01 +00:00
ca6083b0ee version bump 2020-07-25 13:02:33 +02:00
8d29e7b5bb fix prepare-amo-source script 2020-07-25 13:02:25 +02:00
7f9766ff95 Add .nvmrc 2020-07-25 12:57:30 +02:00
5098c45174 Merge remote-tracking branch 'origin/dependabot/npm_and_yarn/lodash-4.17.19' 2020-07-25 12:54:10 +02:00
6ca6fcd10c update libraries 2020-07-25 12:53:58 +02:00
86a184fe29 Remove build for old edge 2020-07-25 12:43:15 +02:00
19f2ef7d68 Yet another readme update 2020-07-25 12:42:04 +02:00
dependabot[bot]
74ea6fa238 Bump lodash from 4.17.15 to 4.17.19
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.15 to 4.17.19.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.15...4.17.19)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-18 06:59:55 +00:00
87a65d4af2 Updated readme 2020-06-28 21:51:26 +02:00
2eec8b3ef9 readme update & version bump 2020-06-18 22:27:52 +02:00
cfa0c4e2c8 Update build scripts 2020-06-18 22:22:43 +02:00
ced35084ba Reproducibility test 2020-06-18 22:12:45 +02:00
20346a784e Re-allow minification. Remove source maps from prod build. 2020-06-18 22:12:28 +02:00
4f6f946245 properify readme some more 2020-06-16 21:41:16 +02:00
16a2a424d2 Remove redundant info from README-AMO 2020-06-16 21:40:03 +02:00
2aea741372 Fixes for README-AMO preparation 2020-06-16 21:35:46 +02:00
53073ecdfa README-AMO updates 2020-06-16 21:35:21 +02:00
8216965533 Variable fix 2020-06-14 23:46:22 +02:00
88ce945a47 Include node/npm/linux versions in README-AMO.md, rename README-AMO.md to README.md when including it into the archive 2020-06-14 23:41:02 +02:00
fef30ce3e9 Fix script that packs source code for AMO 2020-06-14 21:48:04 +02:00
0cdbb19b7a Readme+changelog update 2020-06-05 00:59:44 +02:00
69e44c4964 version bump 2020-06-05 00:59:12 +02:00
d59a78b039 Hopefully this fixes #104. Turns out 'location.host' and 'location.hostname' aren't quite interchangeable 2020-06-04 22:47:04 +02:00
e7957b6503 Extra logging 2020-06-04 22:44:53 +02:00
3b4b52f6a1 logging fixes 2020-06-04 22:15:32 +02:00
a4bca8af45 Additional fixes for #101 — if illegal video dimensions are detected, tell VideoData to reset/reapply aspect ratio when video starts playing again 2020-06-04 21:51:22 +02:00
cc53df5999 Youtube player detection goes back to auto by default 2020-06-02 01:05:03 +02:00
a271b4d63e fix observer 2020-06-02 00:52:23 +02:00
5c73f97c54 Add player dimension sanity check to resizer 2020-06-01 23:54:42 +02:00
ecc65676f2 cosmetic fix 2020-06-01 23:54:24 +02:00
619d89c4f5 Break videoData setup into two stages for improved stability 2020-06-01 23:54:10 +02:00
fe66c9dfbc Diversify logging: in addition to console.log, use .warn .info .error as well 2020-06-01 23:53:03 +02:00
95d8d8a8cb Fix minor issue 2020-06-01 23:52:29 +02:00
ee7d958224 Fix settings 2020-05-29 22:50:39 +02:00
88a3298cfa fix launch.json 2020-05-29 22:50:07 +02:00
4a761efaed Find all blacklisted origins in stack 2020-05-29 22:06:24 +02:00
fc8d011758 Additional fixes 2020-05-17 02:30:16 +02:00
3708b99186 version bump 2020-05-17 02:17:59 +02:00
291c4fdd4d changelog update 2020-05-17 02:17:52 +02:00
7d8758d1ee Do old frame cleanup with polling 2020-05-16 22:50:29 +02:00
9019963597 fix single video control not working 2020-05-16 22:02:06 +02:00
7bb3d079f7 Fix issue with chrome not hiding frame/video numbers 2020-05-16 21:35:24 +02:00
84470846ef Typo fixes & addign words to dictionary 2020-05-16 20:52:37 +02:00
c17e6f0f6d Discern popup of dev/nightly/testing versions from stable version 2020-05-16 20:31:56 +02:00
a0031be90a unfuckywucky the icons 2020-05-14 00:01:18 +02:00
ed0e51114c Change timeouts again 2020-04-30 00:40:12 +02:00
1646958449 version bump 2020-04-30 00:14:36 +02:00
e1b062f19e increase number of retries 2020-04-30 00:14:26 +02:00
ff0dc23d5d Fix build generate script 2020-04-29 23:21:32 +02:00
cb91e2a09f Forgot to bump version in manifest 2020-04-29 23:03:22 +02:00
103ecf7a83 Version update stuff 2020-04-29 22:55:20 +02:00
ccde079aee If video dimensions are invalid, wait a little and check again before performing the crop calculation 2020-04-28 03:05:55 +02:00
10f1bae7de move sleep function to a separate fire 2020-04-28 03:04:15 +02:00
dfdc26fe2b fix font imports 2020-04-28 00:35:41 +02:00
06cc9220c2 scope styles for jsonElement 2020-04-26 16:26:15 +02:00
a7f654650d Logging when file loads 2020-04-13 15:20:29 +02:00
ff525f159b try rescoping 2020-04-13 14:35:04 +02:00
44eef78d29 whitespace removal 2020-04-13 14:31:01 +02:00
7c80da3b5a add ms certification notes 2020-03-22 02:43:45 +01:00
Tamius Han
d2a6dfe55d Merge pull request #98 from tamius-han/dependabot/npm_and_yarn/acorn-6.4.1
Bump acorn from 6.4.0 to 6.4.1
2020-03-15 20:41:58 +01:00
Tamius Han
7873777b96 Merge pull request #99 from tamius-han/stable
Merge branch 'master' into stable
2020-03-15 20:41:02 +01:00
1268c2b0cc Merge branch 'master' into stable 2020-03-15 20:39:31 +01:00
d6e6c4ad40 Don't include some files in final package 2020-03-15 20:28:38 +01:00
0272597bda hide zoom&panning options as they don't work anyway 2020-03-15 20:20:04 +01:00
2e7b7f6c30 Popup: fix 'tab' sidebar max width 2020-03-15 20:19:48 +01:00
e447b39beb Delete invalid keys from manifest.json for Chromium-based browsers 2020-03-15 20:19:24 +01:00
9df8bdf3b9 manifest.json fix 2020-03-15 20:01:45 +01:00
95676d5343 Changelog 2020-03-15 19:56:52 +01:00
309f738d25 version bump 2020-03-15 19:56:47 +01:00
d2bd215877 Update AMO readme 2020-03-15 19:47:46 +01:00
c2ebe34ab6 Disable logging + extra notes 2020-03-15 19:47:38 +01:00
c83f8530f8 emit/handle loggingEnded 2020-03-15 19:16:27 +01:00
e9795f4a00 Add new thing to vue store 2020-03-15 19:14:33 +01:00
dependabot[bot]
d63197b13a Bump acorn from 6.4.0 to 6.4.1
Bumps [acorn](https://github.com/acornjs/acorn) from 6.4.0 to 6.4.1.
- [Release notes](https://github.com/acornjs/acorn/releases)
- [Commits](https://github.com/acornjs/acorn/compare/6.4.0...6.4.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-03-15 16:31:13 +00:00
72a3bba8ad Auto-show logger popup is logging to file is enabled 2020-03-13 00:29:19 +01:00
f0cc710621 fix imports 2020-03-13 00:28:41 +01:00
49ca4b64e3 forwarding logs to UI 2020-03-13 00:28:34 +01:00
06a2f67759 Fix saving logs 2020-03-13 00:19:39 +01:00
783684570c actually wait, we still need logger to save to vuex 2020-03-13 00:17:14 +01:00
5998b6c0b2 Functions for sending to specific frame/port 2020-03-13 00:13:00 +01:00
6a3cc8e03e Use sendmessage instead of vuex store in logger 2020-03-13 00:12:42 +01:00
a629bbeab7 Logger cosmetics 2020-03-12 23:36:06 +01:00
7e74aa2c3b Add ignoreKeys property to JsonEditor 2020-03-12 23:35:52 +01:00
9a5ccf1602 JsonEditor uses monospace 2020-03-12 00:49:40 +01:00
d7d0f69a58 Update logger settings from JsonEditor 2020-03-12 00:49:24 +01:00
217206ca1e Change how strings and text are editable (submit on enter), colorify json 2020-03-12 00:37:57 +01:00
a7fa66b840 Prevent typing in logger popup from triggering page shortcuts 2020-03-12 00:37:15 +01:00
4df771aae1 Remove pre 2020-03-12 00:36:34 +01:00
77f3ce0e39 Display logger conf with json components 2020-03-11 23:12:29 +01:00
b353e6f34d Fix json components 2020-03-11 23:12:18 +01:00
e9dfd834f7 Load UI css with extension 2020-03-11 23:11:55 +01:00
c9b354e06a Add json structure editor 2020-03-11 00:15:53 +01:00
7b845553e2 remove player images 2020-03-10 21:00:54 +01:00
fe72a4fdec Fonts: remove .woff (since css only loads woff2 anyways), extrabold, heavy 2020-03-10 20:17:17 +01:00
6e6b3522fe Merge branch 'stable' 2020-03-10 00:04:42 +01:00
bf0d3b99cf Version bump 2020-03-10 00:04:09 +01:00
7d4e4fc520 Fix disney+ a bit more thoroughly 2020-03-10 00:03:12 +01:00
e4480a91ef Merge branch 'master' into stable 2020-03-09 22:36:26 +01:00
e2d393d500 Fixes for netflix, disney+ 2020-03-09 22:36:17 +01:00
ce6a22d31b Merge branch 'master' into stable 2020-03-09 22:08:20 +01:00
85290ae832 Version update 2020-03-09 22:07:54 +01:00
3f51048c1a Patch notes 2020-03-09 22:06:34 +01:00
a81c5765e1 Minor fixes for chrome 2020-03-09 21:41:31 +01:00
cf1cc3d87a Fix logger popup initialization. 2020-03-09 21:29:39 +01:00
2a1419eb53 Fix uw script 2020-03-09 21:29:24 +01:00
0edb5d5c4f add words to dictionary 2020-03-09 21:29:10 +01:00
5b417d3f47 cosmetic fix 2020-03-09 21:29:00 +01:00
eee7d622b8 Revert logging oopsie whoopsie 2020-03-09 19:41:15 +01:00
bbc4247893 Don't overwrite existing ports on connect 2020-03-09 19:39:24 +01:00
26757c0b2d Remove redundant code 2020-03-09 19:11:23 +01:00
b3fce146f5 Fix port naming 2020-03-09 19:11:08 +01:00
80c14f72be comment out dead imports and code 2020-03-08 18:47:01 +01:00
6ea2b0488d Fix console errors 2020-03-08 18:43:53 +01:00
5cc90ea368 Fix problems with uw-ui 2020-03-08 18:38:36 +01:00
d8181431ff Block show-logger until ui is initiated 2020-03-08 18:38:09 +01:00
e681a64f55 remove unnecessary code 2020-03-08 18:34:30 +01:00
92c4ba0c69 Remove paginfo and command declarations out of comms 2020-03-08 17:13:50 +01:00
c26744b9d9 handleMessage _always_ tries to execute command, even if it has forwarding flags set. Command is executed before forwarding. 2020-03-08 16:49:20 +01:00
4c41601319 spin UI to a separate file 2020-03-08 16:45:46 +01:00
210290e7f4 Merge branch 'master' into stable 2020-03-03 00:36:34 +01:00
95aec0f68c remove install/first time tab from webpack, as it's not used yet 2020-03-03 00:36:24 +01:00
a600f30ff8 Merge branch 'master' into stable 2020-03-03 00:34:15 +01:00
ec046767c7 Changelog update 2020-03-03 00:33:55 +01:00
f86ef5bda6 Version update 2020-03-02 22:35:41 +01:00
77ee6be218 Fix getting extension version in the popup 2020-03-02 22:35:34 +01:00
1c978e61b7 Fix the bug with Settings.fixSiteSettings() 2020-03-01 21:52:57 +01:00
aba099d577 Disable unnecessary logging 2020-03-01 21:52:47 +01:00
33e05014fd flex.css -> flex.scss for dat scoping 2020-03-01 20:24:08 +01:00
c5f6868a63 Make sure aspect ratio makes sense before setting it. Don't set NaN for aspect ratio, that tends to break things 2020-03-01 16:55:52 +01:00
4b177a9724 initialize content script vue/ui only if there's a need 2020-02-26 00:45:35 +01:00
9a2261faed whitespace 2020-02-26 00:45:06 +01:00
d009b53dba update webpack to include new install/update pages 2020-02-26 00:44:28 +01:00
acfa833203 Some stuff for easier logging configuration - wip 2020-02-26 00:43:11 +01:00
4c0aca48fd Add "first time" and "updated" pages templates. 2020-02-26 00:42:41 +01:00
66169ddeb1 Remove scheduleGc to avoid webNavigation 2020-02-14 21:45:31 +01:00
72b28918e9 Try disabling minimization 2020-02-14 20:55:20 +01:00
7eca642da3 Let's take away 'tabs' permission, since activeTab seems to do the job just fine 2020-02-14 20:29:38 +01:00
4fa1cb5cbc Merge branch 'master' into stable 2020-02-11 20:01:33 +01:00
18a3a2162a Changelog and version update stuff 2020-02-11 20:01:10 +01:00
6054da346d Merge branch 'master' into stable 2020-02-11 20:00:04 +01:00
ef52eec860 Merge branch 'master' into stable 2020-02-11 19:59:33 +01:00
c88247df25 Fix problem with video sometimes being offset to the side 2020-02-11 19:54:41 +01:00
f028af8b98 change single quotes to double quotes for json 2020-02-11 19:36:49 +01:00
51526b5dcc Version bump 2020-02-09 02:11:37 +01:00
2ead2f8e41 Changelog 2020-02-09 02:11:28 +01:00
c4914b4e5b Improve handling of change listener on settings, fix bug that prevented callback from triggering 2020-02-09 01:16:46 +01:00
a5685fa420 Improve logging of storage listener in logger 2020-02-09 01:14:05 +01:00
f53faac344 Make logger thing a proper json, not just javascript object 2020-02-09 01:13:29 +01:00
c9f227c0f9 This appears to do exactly nothing? 2020-02-09 00:28:35 +01:00
470f576b41 Fix build-zip script 2020-02-08 01:05:05 +01:00
8945226d24 Fixes for Edge 2020-02-08 00:41:10 +01:00
6b7f41ecf8 update readme for AMO 2020-02-08 00:38:40 +01:00
dd74725c0a fix run scripts, but for real. Fix related stuff as well 2020-02-08 00:38:09 +01:00
9338711d4c update gitignore 2020-02-08 00:12:49 +01:00
ddf8c3210f typo fix 2020-02-08 00:09:07 +01:00
806a889726 Gotta have separate dist folders for each browser 2020-02-08 00:08:07 +01:00
0ab21f8360 Remove unnecessary scripts, 'npm run dev' builds both chrome and ff builds 2020-02-08 00:07:34 +01:00
7f806a55af Install concurrently package 2020-02-07 23:51:35 +01:00
31ed290390 fix webpack, don't include useless files (ext/lib and ext/conf) in build
Since files in /lib and /conf use optional chaining, and since optional chaining is only supported through the magic of babel plugins, this is one sure way to fail validation
2020-02-07 00:07:28 +01:00
2788b9e439 fix imports for chrome 2020-02-07 00:06:12 +01:00
355108e0ef Ensure things don't crash on undefined settings 2020-02-06 23:53:31 +01:00
0eb3840221 Move easter eggs around 2020-02-06 23:52:58 +01:00
6013fd68ff Add easter eggs 2020-02-06 23:09:22 +01:00
63922d5744 Changelog updates 2020-02-06 23:06:37 +01:00
f721c795e6 Version bump 2020-02-06 23:02:28 +01:00
006e684f17 Logger fixes 2020-02-06 22:59:57 +01:00
e529239c8d save as .log instead of .json 2020-02-06 22:59:43 +01:00
21e24cc226 Finalize logging 2020-02-06 22:29:59 +01:00
435f2890c4 Logger is half functional 2020-02-05 00:39:16 +01:00
179614bd85 Finish logging ... sorta 2020-02-04 23:31:50 +01:00
f0f02032cc cosmetic fixes 2020-02-04 23:15:06 +01:00
8a70fc5f81 fix export 2020-02-04 23:14:48 +01:00
ef0a802c16 move export log to file to its own file 2020-02-04 22:05:29 +01:00
22bcd02afc Add show/hide popup buttons to 'report a problem' popup tab. Removed everything else re: logging from there. 2020-02-04 00:57:30 +01:00
bd2fa787e1 work on logger popup 2020-02-04 00:56:48 +01:00
87e65a99d4 Messaging fixes 2020-02-04 00:56:31 +01:00
0cd644a38a fix ui overflow 2020-02-03 22:14:07 +01:00
78364472ad Avoid logging too much unnecessary stuff 2020-02-03 22:13:03 +01:00
8eed3431c8 Show log results in popup 2020-02-02 00:57:54 +01:00
f5bde78378 add webext polyfill 2020-02-02 00:57:34 +01:00
390b788b61 add css to manifest 2020-02-01 17:48:49 +01:00
7cb77a7a58 whitespace 2020-02-01 17:48:40 +01:00
a1395da957 abandon ghetto css 2020-02-01 17:48:31 +01:00
983c7747cc Create dummy logger UI 2020-01-31 01:03:06 +01:00
b1538e9a8c logger fixes and refactorting 2020-01-30 23:18:30 +01:00
646d98588a logging fixes 2020-01-30 23:17:43 +01:00
5890192751 sleep() to utils 2020-01-30 23:15:08 +01:00
e6b1370f71 get a better package for decycle 2020-01-30 23:14:56 +01:00
6aba6e0277 add decycle to dictionary 2020-01-30 23:14:40 +01:00
89a459e42b Include json-decycle 2020-01-30 21:25:23 +01:00
2ad5a7b205 consistent naming of 'eject-css' command 2020-01-30 01:07:15 +01:00
d2fdbe178c Implement finish logging and connect things to export 2020-01-30 01:07:00 +01:00
1cdf246919 Refactor comms server a little bit 2020-01-30 01:06:21 +01:00
810fbbdc97 fix bug in actionhandler that causes log to stop logging 2020-01-30 01:06:02 +01:00
0abd4fc776 Add nightly build links to readme 2020-01-29 23:53:52 +01:00
97d97e022b Add onLogEnd callback to logger 2020-01-29 23:38:52 +01:00
78ff7d7e40 Fix logging 2020-01-29 01:36:23 +01:00
1899f486e1 Settings should only watch for uwSettings storage changes, Logger should only monitor for uwLogger changes 2020-01-29 01:36:09 +01:00
9ba1afebee Use optional chaining 2020-01-28 23:34:36 +01:00
c8d943da0b Fix logging bugs, add mousemove to blacklist by default 2020-01-28 23:11:59 +01:00
f5f3e2754f Update npm packages & add optional chaining 2020-01-28 23:11:15 +01:00
0cbd62352e [Logger] Track origin of the call stack. Allow blacklisting of some periodic calls 2020-01-28 01:27:30 +01:00
3e565ddbfc fix logger in popup 2020-01-28 01:26:40 +01:00
c84900def0 dictionary update 2020-01-28 01:26:20 +01:00
1588ebd274 Don't restore ar if player dimensions haven't changed 2020-01-27 23:42:55 +01:00
691f45fbcc remove log to console 2020-01-27 23:42:35 +01:00
c62033fb28 typo fixes and whitespace/console.log removals 2020-01-27 23:42:17 +01:00
dfabfaad48 pass CHANNEL to process.env for extension to use 2020-01-27 23:35:38 +01:00
f770b0dbf1 fixes for logger 2020-01-27 23:20:38 +01:00
f3e5aeb9e6 Fix logger crashing the extension 2020-01-27 22:32:38 +01:00
f1d2881359 Add logger commands to comms server 2020-01-21 00:41:18 +01:00
8c78715271 additional logger functions 2020-01-21 00:41:06 +01:00
8b648fb4d7 Rework of command handling in CommsClient 2020-01-21 00:40:56 +01:00
46fc868109 fix settings for logger 2020-01-20 20:07:18 +01:00
d633cb3b97 Only allow in-code log overrides if we're running in dev 2020-01-20 20:07:01 +01:00
5372acdf07 Logging changes for build and deploy 2020-01-20 20:06:36 +01:00
9234b86e46 Create dist-zip after deletion 2020-01-19 21:32:49 +01:00
6031a99af7 fix build 2020-01-19 21:08:34 +01:00
6f5768567f logging in build-zip 2020-01-19 20:27:05 +01:00
65b9822e24 mkdir recursive 2020-01-19 20:21:11 +01:00
d78a83c4e3 re-enable FF builds (without signing) 2020-01-19 20:16:34 +01:00
fe85f6a7a5 change directory for builds 2020-01-19 20:13:47 +01:00
6b78e5652e fix typo 2020-01-19 20:05:30 +01:00
bbef2aa2e7 manually copy built files via ssh 2020-01-19 20:03:03 +01:00
13f4dcb215 fix jenkins build script 2020-01-19 19:43:32 +01:00
ff82807130 change package.json stuff 2020-01-16 21:49:13 +01:00
c7980ab892 Update github username 2020-01-16 01:02:19 +01:00
753a9348f4 Add rudamentary logger section to 'about' tab of popup 2020-01-16 01:01:04 +01:00
79e781dcd8 Support static save, load, subscribe to logger settings changes 2020-01-16 01:00:47 +01:00
6b9bf1b70f New logging property! 2020-01-16 01:00:12 +01:00
76b1da1b1c Change email template in hopes for illiterate twats to not edit or remove my precious process.env and generated version number
smh my head
2020-01-15 23:37:34 +01:00
7fdb15821a Changelog updates 2020-01-15 22:23:22 +01:00
d2c1b2de3e Get current site more reliably (hopefully) 2020-01-15 21:20:34 +01:00
d6201dc2ac Add override to log everything 2020-01-15 21:09:12 +01:00
0f6b707d69 Merge remote-tracking branch 'origin/master' 2020-01-06 21:40:10 +01:00
90c1ba0b6c Merge branch 'HEAD' into stable 2020-01-06 21:39:23 +01:00
73872d4188 Add timeout to logger 2020-01-06 21:38:10 +01:00
936cb78b26 typo fix 2 2020-01-06 21:38:10 +01:00
2dca756b20 typo fix 2020-01-06 21:38:10 +01:00
3d2bbe742b npm appeasal 2020-01-06 21:38:10 +01:00
bc51505727 Version bump, changelog 2020-01-06 21:38:10 +01:00
c8418f0373 Fix extension failing to load 2020-01-06 21:38:10 +01:00
39a7a8187e typo fix 2 2020-01-04 15:46:43 +01:00
d66cfd430d typo fix 2020-01-04 15:45:28 +01:00
d9430dc90d npm appeasal 2020-01-04 15:45:21 +01:00
1c1d31e563 Version bump, changelog 2020-01-04 15:43:11 +01:00
bf8d133962 Fix extension failing to load 2020-01-04 15:34:54 +01:00
0920c234d0 Merge branch 'master' into stable 2020-01-04 02:47:56 +01:00
4cd0eac01b Changelog update 2020-01-04 02:47:09 +01:00
c08ffa9c58 disney+ conf patch 2020-01-04 02:37:00 +01:00
410cd4d7f3 Fix invalid site settings on settings.save 2020-01-04 02:36:46 +01:00
3d7a47662e minor fix for autoar 2020-01-04 02:04:32 +01:00
e37ad4ba7a Version bump (todo: release notes) 2020-01-04 00:42:13 +01:00
377a58c427 Merge branch 'master' into stable 2019-12-12 20:12:34 +01:00
0c6355e370 Merge branch 'testing' 2019-12-06 00:17:38 +01:00
b9e8d111e6 Version update stuff 2019-12-06 00:17:20 +01:00
73b1a57749 Added extra stretch/squish options, hopefully fixed disney+, fixed bug that prevented removal of actions added by user 2019-12-06 00:17:09 +01:00
0801c122e2 disable copy for a bit, we're doing that with plugin now 2019-12-04 18:26:17 +01:00
e58f5c4b62 Merge branch 'master' into testing 2019-12-04 18:25:58 +01:00
4bfb116d45 fix for build override? 2019-12-04 18:04:46 +01:00
96d7456ea1 Merge branch 'testing' 2019-12-04 18:02:38 +01:00
18cf4e5d0f Add logging to build script 2019-12-03 22:39:07 +01:00
6283bd74e5 Fix script 2019-12-03 22:30:26 +01:00
585ad1f525 Merge branch 'master' into testing 2019-12-03 22:19:14 +01:00
33d9bbe00b +x 2019-12-03 22:19:00 +01:00
8b066c3692 Merge branch 'master' into testing 2019-12-03 22:12:02 +01:00
291699b925 Build script moved to file 2019-12-03 22:11:29 +01:00
14a2233ff2 Merge branch 'testing' 2019-12-03 02:21:44 +01:00
cc6d08e452 Readme update to trigger jenkins build 2019-12-03 02:20:59 +01:00
1cd2af7c58 Merge branch 'master' into testing 2019-12-03 02:16:12 +01:00
a1b89e0fc2 This is here mostly to test CI (master commit shouldn't build, merge to testing should) 2019-12-03 02:11:16 +01:00
9036bb5810 Merge branch 'master' into testing 2019-12-03 02:07:40 +01:00
5d200805f0 build-zip should get data from /dist instead of /src 2019-12-03 02:07:15 +01:00
30d6338d76 Separate testing and nightly 2019-12-03 02:01:29 +01:00
bd38e28610 fix 2019-11-29 01:53:23 +01:00
967a5bf87b we don't have background.js file 2019-11-29 01:48:30 +01:00
2675960aa0 fix key name 2019-11-29 01:39:01 +01:00
289baf73e5 Force player re-detection when setting aspect ratio 2019-11-29 01:33:58 +01:00
5a6195d36d fix permissions 2019-11-29 01:27:24 +01:00
d359b60bc5 don't remain cd'd into folder 2019-11-29 01:26:52 +01:00
1581e3382c Add crx build file 2019-11-29 01:25:40 +01:00
6355e31004 Also ignore kate swap files, they're garbage we don't need on git 2019-11-29 01:00:59 +01:00
ec36ca1bc8 Version number is already in process.env on server, no need for this 2019-11-29 01:00:24 +01:00
51d0cbf16f Include build number in version scripts 2019-11-29 00:55:22 +01:00
db5d69d92f fix build 2019-11-29 00:31:20 +01:00
470f5481ee fix? 2019-11-29 00:15:48 +01:00
e51a2f4193 fix build config 2019-11-29 00:12:31 +01:00
62b986575c Zip: collapse dashes and spaces into single dash 2019-11-28 23:52:55 +01:00
4be2d902b8 Merge remote-tracking branch 'origin/master' 2019-11-28 23:37:45 +01:00
709cb7763c prepare stuff for CI nightly builds 2019-11-28 23:37:26 +01:00
f469c29cc8 Readme update, pt. 2 2019-11-25 23:45:45 +01:00
cc36305568 Readme update 2019-11-25 23:42:22 +01:00
b43747a59c Merge branch 'master' into stable 2019-11-05 00:09:20 +01:00
fcd9deac6f Version update 2019-11-05 00:09:08 +01:00
97ef4c2fec Changelog updates 2019-11-05 00:08:27 +01:00
0eadb1aac6 Don't set aspect ratio pointlessly 2019-11-04 23:53:28 +01:00
5fc867b4a3 Fix for vk 2019-11-04 23:53:08 +01:00
414bf7b36f Update logger output 2019-11-04 23:52:37 +01:00
4fc68db7f8 Disable logging 2019-11-04 23:50:54 +01:00
08460a923d Fix logger 2019-11-04 22:14:41 +01:00
5f4abcec1f version bump 2019-11-02 22:43:11 +01:00
1157a8a8e2 Update readme 2019-11-02 22:42:36 +01:00
b2f6a1fddd Auto-collect extension/browser info in mailto/reddit compose links (and hopefully fix them) 2019-11-02 21:58:55 +01:00
b6ff740b84 Merge branch 'master' into stable 2019-11-02 02:47:59 +01:00
0e09ae771c Update readme 2019-11-02 02:45:30 +01:00
970b9b6b1d Reset panning on aspect ratio change. 2019-11-02 02:45:24 +01:00
83a4dd08ac remove console litter 2019-11-02 02:21:21 +01:00
f806d154ee Fix panning 2019-11-02 02:20:09 +01:00
b128f97a7c Fixed readme 2019-11-02 01:11:57 +01:00
dbc35ccbd1 Patching for v4.4.0 2019-11-02 01:05:36 +01:00
5becf0bdf0 Version bump is gonna be a bit more major 2019-11-01 23:51:51 +01:00
04c33956a1 changelog update 2019-10-30 17:47:15 +01:00
42d85f75f7 Logging, prepare code for when browsers finally implement ArrayBuffer.transfer() 2019-10-29 18:15:46 +01:00
18f0c7540b Fix incorrect crop resets 2019-10-29 18:15:10 +01:00
1c4c4d5652 update test videos 2019-10-29 00:38:06 +01:00
ab42557283 Fixes for crop mode persistence on the popup side of things 2019-10-28 22:10:15 +01:00
5e20925ec5 Fix fit to width / fit to height for portrait monitors 2019-10-28 20:33:40 +01:00
9b8e500927 Prevent action on contentEditable divs. 2019-10-27 23:37:13 +01:00
83d84e5a93 Fix popup not displaying 2019-10-27 23:20:45 +01:00
470a7e8883 Fix video fit on portrait orientations 2019-10-27 22:11:07 +01:00
2422cec1e9 update formatting 2019-10-27 22:08:48 +01:00
bde7eb6327 Fix autodetecting not starting 2019-10-27 16:51:47 +01:00
6af771e1ff Restrict which kind of mutation events are allowed to trigger player refresh 2019-10-27 16:51:31 +01:00
828ded6b29 Fix overly aggressive forced player refreshes 2019-10-27 16:48:05 +01:00
f05a0813d2 Fix minor issues 2019-10-27 00:10:49 +02:00
854bc05d14 Pass set-ar-persistence between CommsClient and pageInfo 2019-10-26 02:38:47 +02:00
cda5d87735 Display new options in popup, update ExecAction 2019-10-25 00:59:02 +02:00
d0058cedb9 Changes to how crop mode persistence works, extra persistence options 2019-10-24 23:27:43 +02:00
d5a6e8d707 change reload prevention to something a bit less contrived 2019-10-24 21:13:45 +02:00
8fde5bb3d6 Implement crop persistence in content script 2019-10-24 00:45:11 +02:00
ab06f0bd41 Add saveWithoutReload() to settings.js 2019-10-24 00:44:27 +02:00
f652bce8fe Prepare version update stuff, readme updates 2019-10-23 20:01:11 +02:00
261f9a6b8d Use event.code instead of event.keyCode. Add key codes to default settings 2019-10-23 19:34:58 +02:00
cd4e3768e2 Make compiler a bit happier. 2019-10-22 01:40:46 +02:00
4a9ef1f9db Fix 'clear shortcut' button (probably) 2019-10-22 01:40:38 +02:00
3768575bad Allow default keyboard shortcuts to work on non-ASCII layouts 2019-10-22 01:33:56 +02:00
c28651d9f7 Merge branch 'master' into stable 2019-10-20 21:12:43 +02:00
fdc4fc8dc9 fix the fix 2019-10-20 21:11:17 +02:00
85fa314bb4 change some variable names for readability 2019-10-20 21:11:09 +02:00
7a9c341bf8 Version update stuff 2019-10-20 14:13:58 +02:00
cec427d9ab fix for twitch 2019-10-20 14:09:19 +02:00
a461d8fa71 test videos update 2019-10-20 14:03:09 +02:00
b53276da62 Merge branch 'master' into stable 2019-09-28 00:14:21 +02:00
2d6a020c5b Version update stuff 2019-09-28 00:14:03 +02:00
afe7b8e692 minor rework of settings options 2019-09-28 00:13:50 +02:00
408b771656 Fix settings page 2019-09-27 22:06:28 +02:00
f784eedd3f Merge branch 'master' into stable 2019-09-26 01:24:20 +02:00
4e67902c56 version update stuff 2019-09-25 18:44:01 +02:00
b70cc7bb88 Update readme with correct build instructions 2019-09-25 10:04:52 +02:00
Tamius Han
3788fee24c Merge pull request #77 from ezzak/master
Fix error for new users.
2019-09-25 09:35:41 +02:00
Tamius Han
20161207b9 just making presence check more in line with my style, otherwise this is fine 2019-09-25 09:34:14 +02:00
EzzAK
282f8350dd Fix error for new users. 2019-09-24 22:10:36 -07:00
e7f8ca058d Merge branch 'master' into stable 2019-09-22 02:49:53 +02:00
2ad4e79bf3 Fix 2019-09-22 02:49:40 +02:00
5171c3129b Merge branch 'master' into stable 2019-09-22 02:40:14 +02:00
bf9ee47527 Some tweaks to release notes 2019-09-22 02:39:24 +02:00
ecf495dae6 Let's make a script that does both ff and chrome build at the same time
+ let's automate making source code zip for AMO, while we're at it
2019-09-22 02:38:13 +02:00
46bc4bfd8d Fixes for reddit 2019-09-22 02:07:04 +02:00
7b73a42e5c Force fallback mode, always. 2019-09-21 23:50:06 +02:00
469c607568 Fix changelog 2019-09-21 23:48:17 +02:00
b983b6e4ec Mutation observer doesn't always detect changes correctly, so we still need to periodically check for changes in player/video sizes. 2019-09-21 21:49:31 +02:00
685cfc9466 Popup: Fix issue where 'sites' tab would be disabled if extension mode was set to whitelist only 2019-09-21 19:55:47 +02:00
c407e7a298 Add steam to test videos 2019-09-21 19:55:11 +02:00
4f830e2a37 Update changelog. Update includes a promise (popup bit needs to be fixed) 2019-09-18 01:08:07 +02:00
b91fc2e422 Turn debugging on 2019-09-18 01:05:17 +02:00
0bed77bafa Fix new reddit 2019-09-18 01:05:07 +02:00
e1e962df04 If no element fits the criteria for the video player, have extension ignore such videos.
Also, sometimes mutationObserver doesn't catch all mutations/we miss some mutations. Added a delay that validates offsets. If validation fails, retrigger aspect ratio correction to make sure there's no misalignments. (That last bit was mostly needed for new reddit)
2019-09-18 01:05:07 +02:00
40416d74e9 Updated test videos 2019-09-18 01:01:52 +02:00
dacd1f7a9c Version upgrade stuff 2019-09-17 22:26:43 +02:00
536e726f4b Disable logging 2019-09-17 22:18:02 +02:00
7d63245136 Remove unnecessarsy console.logs 2019-09-17 22:15:00 +02:00
7454b278a4 Fix settings patching and version number saving 2019-09-17 22:14:42 +02:00
f854daa44b Removing unnecessary stuff from webpack 2019-09-17 22:14:05 +02:00
d89db7a5a1 This low-key shouldn't be in logger 2019-09-17 22:13:31 +02:00
f495cec5ba fox type 2019-09-17 18:51:19 +02:00
824fe7993e Disabled unfinished features 2019-09-17 18:47:09 +02:00
77a02acb5a minor dictionary update 2019-09-14 23:52:12 +02:00
705d4c2e6d remove some dead code 2019-09-14 23:50:48 +02:00
b1af778656 dunno what that is, but it doesn't seem to break anything 2019-09-14 23:23:52 +02:00
44caa5f492 Fixed issues with mutation observers 2019-09-14 23:23:00 +02:00
ef9f106e18 Let's use npm instead of yarn 2019-09-14 23:01:02 +02:00
287680d4de dictionary update 2019-09-03 23:49:30 +02:00
66bcc40fb4 Minor fixes 2019-09-03 23:49:22 +02:00
59df28029f logger import reordering 2019-09-03 23:01:23 +02:00
7ac5e17415 Fix passing logger some more 2019-09-03 22:55:10 +02:00
c08033fba6 One of the merges fucked up the fix for twitchy twich. Re-fix this bug. 2019-09-03 22:46:28 +02:00
0ab1f558e1 Changes to logger insert (from videoData.logger instead as consructor param) 2019-09-03 22:42:38 +02:00
3c1b5f4b1a Move everything to logger, but for real 2019-09-03 22:17:10 +02:00
0f14d9c7dd Fix missing imports 2019-09-03 21:30:18 +02:00
df5b2b5165 Finished converting console.logs to logger 2019-09-03 00:48:18 +02:00
2de8d64b29 cummulative patching of settings 2019-09-03 00:28:35 +02:00
7ef8c21e63 Merge branch '4.2.4' 2019-09-01 03:56:16 +02:00
2f76a90b29 Merge branch '4.2.4' into stable 2019-09-01 03:55:21 +02:00
cd25cfbf8f minor fixes 2019-09-01 03:23:19 +02:00
6d77b7818d Merge branch '4.2.4' 2019-09-01 01:54:41 +02:00
8e21bb8f92 Merge branch '4.2.4' into stable 2019-09-01 01:52:34 +02:00
49872ae16d package.json doesn't like fourth digit 2019-09-01 01:41:51 +02:00
842851197e Version bump related stuff 2019-09-01 01:41:12 +02:00
a67dbad21c Fix player detection rules — for sites where query selector is defined as well 2019-09-01 01:40:39 +02:00
8cfc699fe6 Fix default extensionconf for reddit 2019-09-01 01:18:13 +02:00
fc2515d5c8 Fix default extensionconf for reddit 2019-09-01 01:17:49 +02:00
e44738b3a8 Fixed merge fuckup 2019-08-31 22:59:46 +02:00
19cf8477ca Merge branch '4.2.4' 2019-08-31 22:58:59 +02:00
50e0d7aa59 Merge branch '4.2.4' into stable 2019-08-31 22:55:03 +02:00
149b9cb7de Reverse query selectors order in extconfpatches for reddit 2019-08-31 22:45:56 +02:00
67f031e549 Additional fixes for player element discovery. Force player element refresh on every video element size change. 2019-08-31 22:10:51 +02:00
c275e389a1 Updating version numbers & stuff 2019-08-31 18:22:57 +02:00
1dacc66ead Fix "what's new" notification not going away (hopefully) 2019-08-31 18:22:13 +02:00
c1012c59a6 Fix player detection 2019-08-31 18:21:49 +02:00
434583d19b Add test video for reddit 2019-08-28 18:31:17 +02:00
a04b3ccecf Merge branch '4.2.3' into stable 2019-08-28 18:29:39 +02:00
8e7c3ce2ac Merge branch '4.2.3' 2019-08-28 18:29:15 +02:00
29e78c7833 Hotfix for memory leak (hopefully) & failed first time install 2019-08-28 18:28:22 +02:00
e2df9285ff Fixed logger issues 2019-08-25 22:00:57 +02:00
0918c8b86d Undo version bump in manifest.json 2019-08-25 21:23:59 +02:00
e03a4adc9e readme update 2019-08-25 21:23:04 +02:00
0be0e2a265 Use mutationobserver-based ways to detect player changes instead of the old pleb-loop based method 2019-08-25 21:19:56 +02:00
0d641a98e3 Merge branch 'stable' 2019-08-25 01:57:23 +02:00
142b51f934 Merge branch '4.2.3' into stable 2019-08-25 01:55:45 +02:00
9f2880c802 Hotfix for popup 2019-08-25 01:52:04 +02:00
24dcbdf770 Merge branch 'stable' 2019-08-24 23:21:53 +02:00
c7847ac626 Merge branch '4.2.3' into stable 2019-08-24 23:17:54 +02:00
68e2b276df Version update & fix build 2019-08-24 22:36:38 +02:00
5f1f14f8ca Update what's new 2019-08-24 22:36:24 +02:00
31f0e2165e Fix HTML 2019-08-24 22:36:10 +02:00
dba9b054d4 Fix issue with 1px letterbox in atuodetection 2019-08-24 22:35:56 +02:00
d7b3508f85 Replace (video) cssWatcher with mutation observer 2019-08-24 17:05:04 +02:00
13104609cd Only replace CSS if the CSS changed 2019-08-24 17:04:53 +02:00
eeddbe9cc6 Combine ejectCss and injectCss into a single function 2019-08-24 00:28:08 +02:00
68b3589e77 Twitching issue was fixed but performance is shite 2019-08-23 02:25:48 +02:00
6d564e2f98 Readied some things for the player selector thing, but in content scripts 2019-08-13 22:31:25 +02:00
5b3ee66066 Start some work on player selector 2019-08-13 21:21:35 +02:00
f41ffb3155 Readme updates for 4.3.0, version bump 2019-07-20 21:33:15 +02:00
c1ba6ffac2 Merge branch '4.2.2' 2019-07-20 20:57:10 +02:00
3f8def5268 Merge branch '4.2.2' into stable 2019-07-20 20:56:32 +02:00
76d6551bc7 Update redit player classlists. 2019-07-20 20:41:03 +02:00
338afad417 Replace consoles in ext with custom logger 2019-07-18 21:25:58 +02:00
f0fa6aa9a8 Replaced console.logs with logger in ArDetect. Other places still need changing. 2019-07-16 22:46:16 +02:00
9072183dd1 Added logger 2019-07-16 20:59:12 +02:00
e08a7eea74 Export settings but for chrome. Also some fixes for FF 2019-07-15 23:18:12 +02:00
060d644487 Version update 2019-07-15 23:17:55 +02:00
84eed2fa13 Import/export settings 2019-07-15 22:54:41 +02:00
dfa4aedd53 Merge branch 'master' into stable 2019-07-07 21:14:41 +02:00
723881d09d ExtConfPatches update 2019-07-07 21:14:12 +02:00
a3d01f7fb4 Fixed issue where user-defined css wasn't loading. 2019-07-07 21:13:28 +02:00
3c3e8b409c Removed unnecessary whitespace 2019-07-07 21:13:10 +02:00
57463e01ec Version & readme update 2019-07-07 21:12:57 +02:00
201b511a49 readme update 2019-07-07 15:27:07 +02:00
61ca9cd9f2 Merge branch 'master' into stable 2019-07-07 15:13:55 +02:00
cce3a677bb Light up "what's new" when upgrading extension. 2019-07-07 15:12:15 +02:00
4cd67161ba Popup: remove bullshit scrollbars in Chrome. Move scrollbar in site lists to the left. 2019-07-06 22:39:59 +02:00
9cbd2fc34c Changelog update 2019-07-05 23:45:57 +02:00
0ef36f64d3 Version update 2019-07-05 23:45:40 +02:00
04a6c11cf5 Super ghetto patching 2019-07-05 23:45:29 +02:00
d5acab1c40 Fix player defaults for youtube 2019-07-05 23:00:15 +02:00
ca8eeffc12 design update 2019-07-05 22:58:29 +02:00
04fe2a6c6a autoar: presume video aspect ratio as default (rather than null) 2019-07-04 22:46:18 +02:00
5329f0a600 Show warning when some frames on a given site are disabled 2019-07-03 22:35:17 +02:00
67d45d265b remove logging some more 2019-07-03 22:35:01 +02:00
4260e36ade Allow re-enabling of sites in embedded frames 2019-07-03 21:55:08 +02:00
2b281b292f Change player element detection on reddit as well 2019-07-03 21:37:03 +02:00
90d646ba25 remove dead code 2019-07-03 21:03:12 +02:00
406329864a update changelog 2019-07-03 20:45:17 +02:00
478d4a8795 Select player elements on youtube and twitch with query selector 2019-07-03 20:17:55 +02:00
d962535311 update test videos 2019-07-03 20:10:39 +02:00
8ad0250d7e Scrollbars styled for chrome as well, but chrome is fucky-wucky 2019-07-02 01:23:43 +02:00
3e627f5fed Thin scrollbar for FF, UX update (what's new, report problem, donate menu entries are at the bottom) 2019-07-02 01:02:22 +02:00
4d83b8260e Merge branch 'stable' 2019-06-24 14:30:14 +02:00
6b5f79347e Merge branch '4.1.2' into stable 2019-06-24 14:30:05 +02:00
67ffd483b6 readme update but in popup 2019-06-24 14:29:47 +02:00
1e4f32aee5 version bump 2019-06-24 14:27:23 +02:00
5256a1bf19 readme update 2019-06-24 14:26:43 +02:00
47e20721e6 Reddit: detect player manually, fix site details popup 2019-06-24 14:05:37 +02:00
d2170eb937 Merge branch '4.1.1' into stable 2019-06-15 23:30:00 +02:00
18a86bc815 Merge branch '4.1.1' 2019-06-15 23:29:29 +02:00
7a987c57d2 disable extension for gfycat 2019-06-15 23:03:19 +02:00
a4ad5f0dde Prepare for version update 2019-06-15 23:01:18 +02:00
33590aa353 UX: In popup, indicate which sites (and corresponding frames) are disabled. This will need additional work on content scripts tho 2019-06-15 22:58:19 +02:00
3fcf32c687 Merge branch 'master' into stable 2019-06-14 23:22:24 +02:00
746a883e07 Prepare for release 2019-06-14 23:21:03 +02:00
2eaab6d3a4 Update default settings: fix old.reddit, vimeo, disable imgur 2019-06-14 23:20:47 +02:00
106cc11e5e Update changelog 2019-06-14 23:10:30 +02:00
031c5d8e4c Add changelog to extension popup 2019-06-14 23:10:21 +02:00
d7f6cd1271 Add 'experimental' tag to site details tab in popup 2019-06-14 22:37:31 +02:00
060278a972 Fix site details panel 2019-06-14 22:36:21 +02:00
8bb5f30e71 Rename 'about' to 'report a problem' in the popup for better visibility of issue reporting options 2019-06-14 22:05:29 +02:00
69114cc47e Update manifest description for that sweet SEO 2019-06-14 21:56:40 +02:00
d27b6bbce9 add 'npm start' script 2019-06-14 21:53:57 +02:00
bc89a9c116 Fix bugs 2019-06-14 21:53:48 +02:00
2df3c3c9be Don't insert CSS on player element. Insert CSS into page instead. Popup doesn't work, still. 2019-06-14 02:15:24 +02:00
afefed7f34 Manually assigning players sorta works, but is bugged 2019-06-12 23:55:15 +02:00
26610f2e00 Start working on applying extra css to player and video elements 2019-06-11 01:34:02 +02:00
08c257ec00 Detecting manually determined video and player elements implemented 2019-06-10 23:45:15 +02:00
03d8a99885 Popup for setting site-specific options is roughly done 2019-06-08 03:45:35 +02:00
17f374d0c3 Remove unused files 2019-06-08 03:44:55 +02:00
2bfa3e8dfc Site settings: allow user to select a site 2019-06-07 01:50:13 +02:00
a3375eb289 Remove unnecessary logging 2019-06-06 19:47:43 +02:00
d8e3f39f2f Updated readme 2019-06-06 00:36:50 +02:00
f6c86382f0 Updated readme 2019-06-06 00:35:58 +02:00
aa939f200d manifest bump 2019-06-06 00:23:07 +02:00
13d0e29e46 Merge branch '4.0.1' into stable 2019-06-05 23:39:20 +02:00
d6a9ea4831 Remove unnecessary logging, fix bug that didn't seem to have any effect 2019-06-05 23:37:12 +02:00
f5b9311225 Fix settings not returning correct default mode. Ensure that update 4.0.0 -> 4.0.1 won't reset settings, while giving people on pre-4.x a clean slate 2019-06-05 23:36:47 +02:00
ae98b0aa92 Fix extension sometimes not working on netflix 2019-06-05 23:35:25 +02:00
af39f3d708 Added readme for AMO (compliance stuff) 2019-06-05 23:35:01 +02:00
1b267ca5a1 Version bump 2019-06-03 23:58:15 +02:00
524b417f2a Update manifest description for 4.0.0 2019-06-03 23:57:26 +02:00
a2f28f738a rogue console.log removal 2019-06-03 00:50:08 +02:00
98703c30d2 Disable debugging 2019-06-03 00:41:06 +02:00
65e41e575d Force override existing settings for 4.0 2019-06-03 00:37:57 +02:00
8231174f57 Add donation tab 2019-06-03 00:34:42 +02:00
5bcdfac16b Remove obsolete 'advanced options' from autodetection page in settings 2019-06-02 23:56:56 +02:00
b8a6e9e0b3 Allow disabling of shortcuts 2019-06-02 23:54:32 +02:00
ebea657f8c Fix settings bug, rework autoar page in extension settings 2019-06-02 23:54:22 +02:00
a0f288e2ad Refactor execAction 2019-06-02 23:52:27 +02:00
cbf38424e4 Tweak default settings 2019-06-02 23:49:48 +02:00
d2d624eddf Refactor showing buttons on popup, hide sections with no buttons 2019-06-02 23:49:31 +02:00
50b16b0893 Made saving settings a bit less of a pain 2019-06-02 03:00:07 +02:00
2e6d33bc79 Plebified settings 2019-06-02 02:44:02 +02:00
66f9c1b9e3 Allow setting aspect ratio detection sensitivity 2019-06-02 00:34:37 +02:00
72dc5ed372 EdgeDetect: respect minimum number of samples 2019-06-01 23:33:21 +02:00
98413534be Fix bug with fallback autodetection 2019-05-26 02:54:02 +02:00
ce30c6faa8 Fix #64 2019-05-26 02:53:29 +02:00
fd5c3fc06f Removed console.logs _not_ gated behind ifs from .vue files 2019-05-22 01:05:32 +02:00
c651bb222b 'nother minor readme update 2019-05-22 01:03:27 +02:00
add72e8398 First round of CSS fixes 2019-05-22 01:03:15 +02:00
4c5569f039 remove debugging ui from popup 2019-05-21 23:16:34 +02:00
4227a4abc0 Remove unused code 2019-05-21 22:21:46 +02:00
b4ee166bd7 pointless readme update 2019-05-21 22:13:41 +02:00
f0b7e619e4 Fix settings, update package.json 2019-05-10 19:21:17 +02:00
e73c6018ef updated gitignore 2019-05-10 18:49:38 +02:00
358863e7ef Settings.get fix for chrome and edge 2019-05-09 23:41:07 +02:00
6bb4e97f64 Added "super advanced settings" (tm) 2019-05-09 23:40:56 +02:00
04f40d9a4c Webpack: pass env.BROWSER to webpack 2019-05-09 21:10:45 +02:00
280e9cfa62 minor fixes 2019-05-09 21:10:26 +02:00
47b1bc68e0 BrowserDetect gets browser from env. Package.json updated to provide BROWSER in env 2019-05-09 21:08:39 +02:00
8f4c201bb1 Convincing the popup to work in Chrome again. Consolidating processMessage_nonpersistent_chrome and .._ff into same function cos that was the problem 2019-05-09 21:07:40 +02:00
2f5acd9d9e Fixed multiple instances running on Twitch/clips.twitch. Fixed lockups on reddit/embedded. Fixed aspect ratio calculations on fitw and fith modes 2019-05-07 23:40:13 +02:00
887cbaab0a attempt at getting debugging via vscode working 2019-05-07 23:03:13 +02:00
86eeab323d Minor changes to add action popup 2019-05-05 00:55:03 +02:00
a783c75b98 Fixed new actions not saving 2019-05-05 00:39:36 +02:00
2e6a2dd92a Update changelog 2019-05-05 00:26:00 +02:00
0eba96af08 Fixed scaling problems from #48 and #54 2019-05-05 00:09:49 +02:00
7e70d91582 Added more test videos 2019-05-04 22:13:45 +02:00
5fbdb3822c Improvements to gradient detection 2019-05-04 21:33:48 +02:00
9a3ba39076 get extension version from manifest.json instead of package.json 2019-05-04 17:05:08 +02:00
54ae79c320 Moving to storage.local instead of storage.sync, because our settings object is too big for chrome 2019-05-03 00:58:06 +02:00
8cef734926 Autodetection/black frame check: use more strict/lax rules depending on color variance 2019-05-03 00:49:33 +02:00
6c4060e827 test videos update 2019-05-02 22:58:14 +02:00
d647046aee Autodetection sorta functional again 2019-05-02 22:43:40 +02:00
eaa1a0975a Rewrote column test, again (todo: actually analyse results) 2019-05-02 00:57:37 +02:00
d51ce8add7 Fixed cropping via popup 2019-04-25 22:02:10 +02:00
c9f806cd5f Converting component file names skipped few things 2019-04-25 21:11:26 +02:00
d8bd884596 Convert component file names from kebab-case to PascalCase for consistency 2019-04-25 01:09:04 +02:00
598dd6cab5 Fix iframe marking 2019-04-13 03:09:29 +02:00
7f349fe985 Typo fix 2019-04-13 00:19:19 +02:00
31c3295748 Added 'about' panel to popup. Both 'about' panels display addon version. 2019-04-12 23:23:35 +02:00
fda105eabc added 'about' section to settings page 2019-04-12 22:57:08 +02:00
108297fe1b Section for editing keyboard shortcuts is reasonably complete. 2019-04-12 21:06:01 +02:00
6435862daa Settings/control: save keyboard shortcuts 2019-04-12 00:49:56 +02:00
9b808a2c36 Settings/controls: fix editing command block 2019-04-12 00:04:38 +02:00
80b7654db5 Settings/controls: Fix adding new command block 2019-04-11 23:52:29 +02:00
7837cf2e22 Implement & fix action edit popup showing existing actions 2019-03-17 23:24:08 +01:00
f3e0a48471 Automatic detection fix 2019-03-10 23:35:13 +01:00
7b5157a48d Aspect ratio types were enumified. 2019-03-10 23:27:50 +01:00
22c44a3972 Building action.cmd[] and editing of command, arg. Order of commands can't be edited yet 2019-03-10 16:31:50 +01:00
76ff4da77f Fix scopes and shortcut button for add action 2019-02-28 23:56:13 +01:00
812f3e6b69 Fix autodetection settings page 2019-02-28 23:55:37 +01:00
8253b6e8a5 Fixes for input stylings 2019-02-28 23:55:20 +01:00
80c484431d autodetection settings fix 2019-02-27 23:36:29 +01:00
be34838dba Shortcut button thingy works ... ish 2019-02-27 23:22:15 +01:00
f07a1e529e add-edit-command component is capable of adding commands 2019-02-27 21:59:57 +01:00
9084b8b156 Typo fix 2019-02-27 20:55:22 +01:00
d4cd1fd92e Typo fixes 2019-02-22 23:02:48 +01:00
fbd7aad9b9 Settings page for autodetection finally has all the options 2019-02-22 22:50:09 +01:00
0cdd70b2d3 Autodetection settings page 2019-02-22 00:32:44 +01:00
aa4dbc15f6 Gradient detect mode 2019-02-21 21:51:35 +01:00
978bd41386 Minor tweaks 2019-02-21 21:35:21 +01:00
3d0c6926db Automatic detection is now checking for gradients. Autodetection is slower because of that. 2019-02-21 21:21:25 +01:00
a0f1a27271 Stretch mode fixes 2019-02-19 21:10:49 +01:00
4eba239da9 Made extgension remember default stretch mode 2019-02-16 01:54:41 +01:00
5b9080c1c7 Fixes for autoar 2019-02-16 01:19:29 +01:00
9f3a7ba418 Fixed autodetection to the point it sorta works 2019-02-15 20:40:56 +01:00
9cc03d0900 First batch of fixes 2019-02-15 00:26:54 +01:00
a0900a7dad Fixed autodetection to the point it at least starts 2019-02-15 00:00:22 +01:00
4082d0afd9 [poking at ci intensifies some more] 2019-02-14 00:29:17 +01:00
ae9bd30335 poking at ci intensifies 2019-02-14 00:22:59 +01:00
83ca2a0392 testing gitlab ci 2019-02-14 00:17:53 +01:00
2e65e26cf9 Merge remote-tracking branch 'origin/Testing' 2019-02-14 00:01:50 +01:00
c1d34fceb1 Popups sorta work 2019-02-13 23:58:19 +01:00
Alziratt
d8376b39ce Minor work on the buttons and some of the text. 2019-02-13 13:15:56 -02:00
Alziratt
50f3c4fc27 This is a commit test 2019-01-26 15:35:37 -02:00
295c363d60 Minor fixes and reworks of ExtensionConf. Fixed 'general settings' page 2019-01-26 17:52:50 +01:00
cf221fba90 Extension/site settings panel complete (but not functional) 2019-01-21 00:07:11 +01:00
e0482084f0 Rounded up some stragglers from refactor 2019-01-20 23:36:08 +01:00
9ec6973cc0 Fix typo 2019-01-20 23:05:04 +01:00
3336e62ae6 Fix import for extension mode enum 2019-01-20 23:01:45 +01:00
d2a8a177a7 Enumification, reorg of ExtensionConf 2019-01-20 22:59:06 +01:00
08469074a6 css fixes 2019-01-20 21:12:26 +01:00
a2f1c8eba2 Sending commands to single frames seems to work, kinda 2019-01-20 20:36:24 +01:00
b49f8c6d26 Functionality that lists embedded videos has been restored. TODO: css, make it work 2019-01-20 19:58:26 +01:00
e1467cd6d7 attempt at fixing frames 2019-01-18 00:26:15 +01:00
3ed3eb8004 Readme update, css fixes 2019-01-17 22:16:55 +01:00
3ff00e629d UI fixes, re-implemented zoom 2019-01-03 02:07:16 +01:00
7a6ecb96bb fix shortcut button 2019-01-03 02:05:54 +01:00
a9fb93966a Commands from popup to content script seem to work 2019-01-02 20:36:00 +01:00
286a49e189 we dont need that 2019-01-02 00:54:28 +01:00
10a8746338 Made keyboard shortcuts work again, changed videoFloat -> videoAlignment for consistency, roughly completed ActionList.js 2018-12-31 03:34:26 +01:00
9c3ca3744b Reorganized stuff for content script & get it working (preliminary; performance issues on YT) 2018-12-31 01:03:07 +01:00
20030f1679 Comms broken into separate files, fixed uw-bg to the point there's no errors in console 2018-12-30 23:41:44 +01:00
e2df78aa78 Started using vue for settings and popup, start of rewrite for settings page 2018-12-30 23:16:09 +01:00
7593e95726 last non-vue commit 2018-12-30 17:08:54 +01:00
2e5e85d9d8 Styled action table, fixed callback function not returning proper action index 2018-12-14 00:19:46 +01:00
c23445ba3f Action table is now actually a table 2018-12-13 23:09:29 +01:00
7f185c80ef Change css of the popup 2018-12-10 00:33:31 +01:00
d88a6d2378 Swap 'all' and 'currently playing' options, make 'all' default. 2018-12-10 00:32:52 +01:00
8fa33ed7aa fixed video registering 2018-12-09 02:13:26 +01:00
93e767be0b Remove player mark when closing player popup 2018-12-09 01:37:19 +01:00
5d082f406c Tabitem — updated to include color tag 2018-12-09 01:36:30 +01:00
236852bc78 Don't duplicate overlays for frame marks 2018-12-07 22:57:35 +01:00
6ef744bfa5 attempt at launch.json for debugging. Not very successful so far. 2018-12-07 21:37:32 +01:00
11d7e59645 Pass pointer events through the div (todo: think of something when player thing goes live) 2018-12-07 00:22:27 +01:00
2c889b55a8 Marking player now works (the div mark remains on top of yt videos). Todo: clear mark when popup goes away. 2018-12-07 00:17:49 +01:00
8bdd8a4dbf Marking frames (todo: sort out the comms) 2018-12-06 23:55:54 +01:00
e43d39a8fd Fixed panning for real, added option to reverse mouse settings. 2018-12-03 00:31:28 +01:00
5043190441 Panning works again (while holding shift) 2018-12-02 23:51:34 +01:00
bf5a51963b forgot to commit new files 2018-12-01 01:35:22 +01:00
8cc1d4c19f Settings: build list of actions 2018-12-01 00:50:22 +01:00
fa0181815b Settings page: Ui accessible via settingsvars.js 2018-11-30 22:18:58 +01:00
2404cd7757 Settings page: basic html 2018-11-29 21:07:27 +01:00
a5639ad394 Proper css/js imports for settings page 2018-11-28 23:52:54 +01:00
d8fa0ce08f Re-added settings page. Settings page is broken atm tho. 2018-11-28 23:47:46 +01:00
98250ee2f2 Re-added all buttons to popup. Not working: selection 2018-11-26 23:44:37 +01:00
6b9c0274b7 Selecting popup buttons in 'site settings' and 'extension settings' 2018-11-26 22:42:00 +01:00
1d7362c27f fix 2018-11-26 21:19:48 +01:00
ebf1058dda Tab switching in popup fixed 2018-11-26 21:12:24 +01:00
5a43011797 Remove unused popupvars 2018-11-26 20:44:23 +01:00
65c35d369c Process buttons for extension and site settings 2018-11-26 00:04:11 +01:00
8bdb7b9e94 Extension settings and site settings prepared for adding buttons programmatically 2018-11-25 23:53:30 +01:00
e9cc0d8eeb fix tabitem saving 2018-11-23 00:29:13 +01:00
6eaeb717e2 remember tab item selection in popup 2018-11-22 22:55:22 +01:00
0526b43aae remove console.logs at frame selection 2018-11-21 22:15:16 +01:00
acd38cf8b4 fix frame selection resetting 2018-11-21 22:14:14 +01:00
4d21187596 setting aspect ratio only to videos that are playing works 2018-11-21 21:58:13 +01:00
c6ad32f712 routing requests to appropriate frames 2018-11-21 20:41:15 +01:00
f294865231 'Currently playing' and 'all' tabs added, select 'video settings' by default 2018-11-18 23:54:54 +01:00
5e7af00f24 Fix #50
That was easier than expected.
2018-11-18 20:40:57 +01:00
6eab0cf828 Buttons and keyboard shortcuts functional 2018-11-18 18:44:44 +01:00
0ff3a71c16 Keyboard shortcut can display modifier keys, code cleanup 2018-11-18 12:43:03 +01:00
85426aa47f Button fix 2018-11-18 03:50:15 +01:00
b83b46577b Removed some console.logs that weren't hiding behind if 2018-11-18 03:30:43 +01:00
32e5ed365b Popup buttons are being added programmatically (video tab only) 2018-11-18 03:29:16 +01:00
0004b4287a Save button labels in ExtensionConf. Temporarily added master list of all possible actions to ExtensionConf 2018-11-18 01:32:01 +01:00
e1847f93b7 Fixed video alignment when video is aligned to left or right, not center 2018-11-17 00:11:07 +01:00
c6e3689d0d Fixed video alignment 2018-11-16 23:02:56 +01:00
df79c9ddd3 ActionHandler works (at least as far as keys are concerned) 2018-11-15 00:18:41 +01:00
5489d7d723 Keybinds getting re-implemented into action handler 2018-11-14 23:32:37 +01:00
3f14785c29 Create tabs and stuff with javascript for more readability. 'unregisterVideo' doesn't get fired, so manual cleanup of the videoTab object was implemented in background script 2018-11-11 22:35:08 +01:00
ccafcd5285 Components for popup UI 2018-11-11 02:25:47 +01:00
981368b376 check for embedded by url, not by frame id 2018-11-10 23:09:50 +01:00
a321789c34 added comment next to some weird hack 2018-11-09 00:57:47 +01:00
701a1b1123 unborked saving/loading options (forgot to change site -> site.host everywhere where applicable) 2018-11-09 00:57:05 +01:00
a2c127fef5 fix css 2018-11-09 00:37:05 +01:00
c3ba318c7d Breaking vars from popup.js into separate file, showing list of embedded frames 2018-11-09 00:35:18 +01:00
cbd7cbeb4a popup now receives info about current tab as well as the list of frames with videos in that tab 2018-11-08 23:05:47 +01:00
5cf3ec9b86 Videos from tabs/frames are being registered in the background script 2018-11-07 00:03:06 +01:00
8760626e8f readme update, version bump 2018-11-06 20:43:47 +01:00
c3d71cd1e7 Extension basic mode more or less works. Added fix for sites that center stuff with 'top: 50; left: 50, translate(-50, -50)' 2018-11-02 23:10:42 +01:00
48da83b75d Basic mode: ar resets properly when switching from fullscreen to normal 2018-11-02 21:51:51 +01:00
32f868a91c Basic mode: when switching to full screen, restart ar detection proper 2018-11-02 21:41:26 +01:00
985e285914 Basic mode works when switching to full screen (on clips.twitch)
doesn't work when we go back from the full screen mode tho
2018-11-02 21:19:34 +01:00
94990a0ba8 example for (clips.)twitch.com 2018-11-02 20:42:26 +01:00
90e512559d Started including basic mode 2018-11-02 02:52:01 +01:00
8c4759dbe8 test videos update 2018-11-01 23:38:07 +01:00
e216929b0c Added test video examples for reddit and streamable 2018-10-26 18:49:16 +02:00
10071aea7f minor readme overhaul 2018-09-27 22:50:54 +02:00
be80858209 fix typos in readme 2018-09-27 22:36:42 +02:00
128e311bb5 Merge branch 'master' of github.com:xternal7/ultrawidify 2018-09-27 22:30:30 +02:00
6a05d48084 README.md update — added howto for MS Edge 2018-09-27 22:30:16 +02:00
06c681668f Zip with edge version zipped 2018-09-27 01:34:23 +02:00
bb3349eff9 Edge stuff 2018-09-27 00:18:13 +02:00
ee268c5e9c Fixed some edge-specific bugs 2018-09-25 23:38:15 +02:00
ac59998f24 Merge branch 'master' into stable 2018-09-23 19:56:43 +02:00
255cdd9820 changelog update 2018-09-23 19:48:48 +02:00
9fd1921348 Release 2018-09-23 19:47:50 +02:00
7036799e9f Pan: eventhandler unbinding. Fixed 'reset zoom' in popup 2018-09-23 19:47:18 +02:00
2bd83fbc01 fixed issue with saving alignment 2018-09-23 13:55:03 +02:00
79f5ae01de Various fixes. Release version for reals 2018-09-23 02:39:27 +02:00
e2cb85610b release version, but for real this time. (removed ungated console.logs, updated readme) 2018-09-23 00:51:19 +02:00
ee21fdcd12 release version 2018-09-23 00:45:42 +02:00
908d37dee5 readme fix 2018-09-23 00:42:25 +02:00
5c50272f9e fixed popup zoom slider resetting 2018-09-23 00:38:36 +02:00
8dbdc3c2d2 Readme update 2018-09-23 00:30:25 +02:00
f490684cfd probably fixed settings saving 2018-09-22 22:50:32 +02:00
afb595d8c0 popup picks up current zoom level 2018-09-21 00:26:08 +02:00
51c1255eed disable other buttons in 'extension settings' tab if extension is disabled 2018-09-20 22:02:15 +02:00
d1d8945aac using tabs API to acquire URL of current tab 2018-09-20 21:45:09 +02:00
e05eb27e6a updating popup url 2018-09-20 21:30:45 +02:00
0f996f3067 registering tab — working with youtube only 2018-09-20 01:11:18 +02:00
06cfb9a04e Fixes for minor popup bugs 2018-09-19 23:34:47 +02:00
c713977bb6 Fixed popup zoom 2018-09-19 22:52:53 +02:00
c7cf9b4be7 logging 2018-09-18 23:48:05 +02:00
f265799e3c commands for setting zoom from the popup, zoom is logarithmic/exponential rather than linear 2018-09-18 23:37:33 +02:00
5e2611f410 check for nulls on videodata/panhandler 2018-09-18 00:42:30 +02:00
c8f65f7fca Popup: functional. TODO: implement command handling in CommsClient 2018-09-18 00:40:05 +02:00
4965529de9 Updating settings backthing stuff for new popup 2018-09-17 00:39:32 +02:00
f6899be0ce Popup: extra buttons, console output beautify, changed experimental notice, disabled text selection 2018-09-16 23:24:01 +02:00
89ebae315a Popup: fixed buttons in site settings tab not getting selected 2018-09-16 19:28:40 +02:00
1efcc83b44 Popup: fixed menus not getting disabled 2018-09-16 14:22:08 +02:00
76b5f6eca1 Fixed switching menus 2018-09-16 14:14:16 +02:00
354b987cb4 start popup redesign 2018-09-14 22:21:39 +02:00
d7946d4098 fix zoom 2018-09-14 00:10:57 +02:00
a8a84fa4ef updated readme 2018-09-13 23:51:42 +02:00
063a803933 Zooming and panning kinda works 2018-09-13 23:47:20 +02:00
067ea67485 Merge branch 'master' into stable 2018-08-31 00:38:25 +02:00
8c9ee493a8 fix 2018-08-31 00:38:03 +02:00
c1a4b8e701 updated readme files 2018-08-31 00:35:52 +02:00
a12c43451f Merge branch 'master' into stable 2018-08-30 23:18:04 +02:00
c6d5298f39 v3.1.0 for firefox 2018-08-30 23:17:42 +02:00
165790db7e fixed issue where resizer.js didn't get killed properly 2018-08-30 23:03:47 +02:00
0c37c5a0e1 Popup and settings work, but all scripts can run doubly if uw.init() was called twice 2018-08-30 00:56:26 +02:00
38a94e3bd3 Changing persistent settings (the ones _not_ limited to current page) bypasses comms 2018-08-29 21:23:08 +02:00
6c93a19248 Misc fixes 2018-08-29 00:41:26 +02:00
1feeaed257 Some more attempts at making comms/setting saving behave 2018-08-23 01:04:37 +02:00
107c9b12bd Comms: accounted for the possibility of pageInfo missing when extension is disabled 2018-08-22 23:46:59 +02:00
2619b02263 Fix comms 2018-08-22 23:16:08 +02:00
b222ea81c7 Fix settings 2018-08-22 22:34:07 +02:00
65f385ca11 manifest.json cleanup 2018-08-22 22:20:53 +02:00
e97b385738 Gitignore update 2018-08-22 22:20:31 +02:00
83aef6ac79 #40: Settings persist over page reload 2018-08-21 23:48:47 +02:00
a5aa282a01 CSS watcher reimplemented, seems to be working (fix #43) 2018-08-21 00:48:15 +02:00
b3079a81ea #42: GlobalVars is gone. 2018-08-20 22:45:43 +02:00
da18f5a5c4 Extension at least starts now 2018-08-07 23:31:28 +02:00
966f8a034d Rewrote Settings.js, did some cleanup with legacy stuff. 2018-08-05 23:48:56 +02:00
b01e5ebcec Renamed stuff for consistency with ExtensionConf. Cleanup. 2018-08-03 00:44:37 +02:00
09cc1816ad Cleanup 2018-08-02 23:24:22 +02:00
1eaff8f2ce some preliminary cleaning in the 'about' section 2018-07-19 23:48:24 +02:00
8ba028a5b2 git commit -am doesn't add new files 2018-07-19 23:05:57 +02:00
872bc4ece7 Some work on settings 2018-07-19 23:05:39 +02:00
335bcd64fc code cleanup 2018-07-16 22:34:32 +02:00
20576675ce Fixes for chrome 2018-07-16 22:30:52 +02:00
5ce0c51018 Fixed autodetection menu 2018-07-16 20:38:16 +02:00
d48d1d3e96 updated readme some more 2018-07-15 17:01:30 +02:00
9a058d18b7 Get ready 🅱️ois, it's happening. 3.0.0 is now officially out of alpha and in stable. 2018-07-15 16:35:08 +02:00
97b5c16345 Language in the popup could be considered hostile or unprofessional by some, so I changed stuff so it appears more kind and polite. 2018-07-15 16:28:29 +02:00
6c458d7590 fixed issue with video alignment not working 2018-07-15 16:22:32 +02:00
8579d25d5f fixed an issue where autodetection wouldn't sometimes trigger even when it should 2018-07-15 15:18:40 +02:00
bfb416e9fb Finished readme rewrite 2018-07-13 21:56:55 +02:00
ae37009dd4 Included new images 2018-07-13 00:00:37 +02:00
db5eb4a9d8 documentation 2018-07-12 23:59:33 +02:00
30c94975c1 reenabled ghetto url check 2018-07-12 23:27:10 +02:00
43d1b02303 using basic stretching should pause aspect ratio autodetection 2018-07-11 23:13:40 +02:00
37b59f19ab Fixed aspect ratio flip-flopping in fallbackMode (kinda. it's a workaround) 2018-07-11 00:01:44 +02:00
0825dacdb8 fixed autodetection on netflix (and anywhere with fallbackMode, hopefully) 2018-07-10 21:58:26 +02:00
a4f0c9db4d basic stretch mode fixed 2018-07-10 20:36:12 +02:00
8a73d8c6a4 validation feedback on autoar timer input field 2018-07-09 23:40:26 +02:00
cf813cf6f8 Popup seems to be more or less fixed. 2018-07-09 23:30:11 +02:00
0eb70babf3 Popup: moved stretching settings to a new tab 2018-06-29 00:30:42 +02:00
029efd92ed Popup is now approximately functional 2018-06-28 23:43:52 +02:00
ea86721321 Fixed some minor bugs, rewrote some bits of the popup 2018-06-27 23:55:37 +02:00
c5debb40a7 Fixed basic stretching 2018-06-15 00:33:10 +02:00
3e787be684 Fixed the bug where extension didn't ignore binds when writing comments 2018-05-31 23:15:47 +02:00
8e1687a5b6 stretch mode is in stretcher now 2018-05-30 23:20:23 +02:00
9478b5af15 half of possibilities to stretch a video checked and working 2018-05-29 00:36:14 +02:00
ce0b9a4e99 Merge branch 'master' of github.com:xternal7/ultrawidify 2018-05-28 23:57:12 +02:00
2bf5a07bc5 started some work on stretcher 2018-05-28 23:56:44 +02:00
Tamius Han
7d08377b17 Update issue templates 2018-05-27 23:09:44 +02:00
0871ad6d97 Stretch mode buttons work 2018-05-27 21:41:08 +02:00
293b784704 Popup: aspect ratio buttons are working. Fixed some bugs with crop calculation. 2018-05-27 01:29:02 +02:00
ba26db28ea CommsServer should now support frames (but we aren't quite sure yet) 2018-05-26 23:56:50 +02:00
dd319551bc Comms minimally functional again, with one ugly workaround. 2018-05-26 23:08:49 +02:00
e2d43fb46d Cropping video now uses scale() and translate() 2018-05-25 21:37:09 +02:00
f5035b933d applyConditionalStretch() now accepts factors and actualAr as arguments. 2018-05-24 23:50:46 +02:00
748ed8293d Fixed function calls in Resizer.js (zoom and stretcher). ApplyConditionalStretch, computeOffsets and applyCss are still TODO 2018-05-24 23:29:30 +02:00
547ef7ad7b Stretcher.js instanced, can calculate aspect ratio factors from aspect ratios alone 2018-05-24 22:49:32 +02:00
7d89f41e40 Moved keybinds options to ExtensionConf. Rewrote Keybinds in a bit more OOP way 2018-05-24 20:50:37 +02:00
0f8f842ec6 Forgot to save VideoData.js 2018-05-23 23:58:34 +02:00
8f201e1ee0 PageInfo can start and stop all periodic functions (to be implemented when switching tabs) 2018-05-23 23:57:51 +02:00
8d7cefd420 Scaler.js - calculateCrop() and modeToAr() no longer take 'video' and 'playerDimensions' as arguments, instead reading those properties from videoData 2018-05-23 00:34:18 +02:00
a7aef8856d PlayerData object gets destroyed when videoData does. Scaler now takes video from videoData instead of function arguments 2018-05-22 00:19:50 +02:00
69d665f6fd PageInfo: rescan doesn't compare found <video> elements to elements in destroyed VideoData objects, fixing the issue where autodetection broke upon visiting youtube's search page 2018-05-21 22:43:56 +02:00
42cf4d91e7 Fixed the problem where 'this' in ghettoWatcher() was 'window' instead of current object. 2018-05-20 23:31:05 +02:00
ad1436289b Fixed some problems with recursion in autodetection startup. Fixed problems with autodetection sometimes not starting. 2018-05-20 23:17:09 +02:00
009a440ce8 but really, now 2018-05-19 22:21:28 +02:00
c53780e619 If video doesn't have width or height, we do nothing. 2018-05-19 22:20:35 +02:00
08b10220e1 Scaler no longer static 2018-05-18 23:26:20 +02:00
c442f9e01c Fixed autodetection crash on drm-protected sites 2018-05-17 23:09:04 +02:00
4fe5ce6bcb Autodetection persists over multiple videos 2018-05-16 23:26:47 +02:00
82abee42bd autodetection works more or less properly. Removed some console.logs 2018-05-16 20:59:39 +02:00
4914a0dc1c video is now centered correctly 2018-05-16 20:42:00 +02:00
d38dee1a8a Autodetection gets detected and applied, but css is still off 2018-05-16 20:26:55 +02:00
17f330f242 Automatic aspect ratio detection runs, but applied css is garbage and everything crashes after first aspect ratio change. 2018-05-15 21:40:53 +02:00
dba655b7d3 EdgeDetect: findCandidates() and edgeDetect() work (according to DebugCanvas) 2018-05-15 20:36:22 +02:00
a106d0f468 Fixed syntax errors and errors with inexisting or improperly declared variables. Didn't fix things that make stuff not work tho 2018-05-14 20:39:15 +02:00
3686341677 rewrite finished to the point where extension doesn't outright crash. Nothing works, though. 2018-05-13 21:05:11 +02:00
0ac051d5d5 Resizer prepared to handle stretching and zooming 2018-05-13 15:22:28 +02:00
cbe250fabf All thigns related to player element have been moved to PlayerData (or at least most of them). 2018-05-13 13:49:25 +02:00
4e2ac9c647 Implemented zoom 2018-05-12 02:51:58 +02:00
4519d8854a EdgeDetect is now in edgeDetect 2018-05-12 01:51:43 +02:00
acc0455415 EdgeDetection partially moved to its own file 2018-05-11 00:49:50 +02:00
3bc356636e Fixed some silly mistakes 2018-05-10 22:35:38 +02:00
4ed361ca65 DebugCanvas converted to proper object. ArDetect not fixed yet 2018-05-10 22:22:58 +02:00
af0ad4c080 GuardLine (blackbar and image tests) moved to their own file) 2018-05-10 21:39:24 +02:00
edcd1e3ccb Fixed links in popup for Chrome 2018-05-10 18:37:03 +02:00
Tamius Han
d39a070117 Some progress on frameCheck() (formerly _ard_draw_but_for_realz) 2018-05-09 00:58:50 +02:00
Tamius Han
a40f32908b ArDetect.js: processAr rewritten in ArDetector object 2018-05-09 00:34:22 +02:00
Tamius Han
2f6710586f ArDetect.start() was objectified 2018-05-09 00:03:22 +02:00
Tamius Han
36878921fb Starting to turn ArDetect into a proper class as well 2018-05-08 23:35:16 +02:00
Tamius Han
c7b6035c55 conditional stretching 2018-05-07 21:58:11 +02:00
Tamius Han
390348202e Moved functions that calculate video crop from Resizer.js to Scaler.js. Resizer.js is not fixed to account for this yet. 2018-05-06 21:32:18 +02:00
Tamius Han
fa5e3909e6 Added support links to the popup, preparing popup for stretch mode fixes. 2018-05-06 00:36:38 +02:00
Tamius Han
befd331687 minor fixes 2018-05-05 23:19:42 +02:00
Tamius Han
c35a8c5f59 Added a safety thingy that disables autodetection if autodetection consistenly causes lag. 2018-05-05 23:06:39 +02:00
Tamius Han
081f8e968f added auto-disable if autodetection takes too long 2018-05-04 00:27:40 +02:00
Tamius Han
b5a5609898 fixed popup, for reals 2018-05-02 18:02:54 +02:00
Tamius Han
1d0772fae7 shortened autodetection frequency warning 2018-05-02 17:56:10 +02:00
Tamius Han
cdd533e093 think this should be good for release 2018-05-02 17:52:25 +02:00
Tamius Han
9a5f586eaf Fixes to aspect ratio detection: guardline/black line now works properly-ish. By accident also managed to correct the bug where aspect ratio detection was mildly screwed in theater mode? 2018-05-01 23:09:58 +02:00
Tamius Han
bf7dce2482 Forgot git commit -a doesn't actually add new files. again. 2018-04-26 00:40:23 +02:00
Tamius Han
9e044ac66f added a debug canvas for ArDetect to draw on in debug mode 2018-04-26 00:40:09 +02:00
Tamius Han
b0ef12d97b Trying to fix the youtube popup bug by re-detecting player element every time a new <video> tag is detected. 2018-04-25 20:39:52 +02:00
Tamius Han
eebed0e1c4 turned on logging in debug.js 2018-04-22 17:10:36 +02:00
Tamius Han
956675b0c9 extra changes to logs 2018-04-22 16:51:35 +02:00
Tamius Han
7527f73922 some more testing stuff for testers 2018-04-22 15:12:27 +02:00
Tamius Han
596ca021ba some more testing stuff for testers 2018-04-22 15:11:48 +02:00
Tamius Han
64e28e8074 Another attempt at fixing the youtube search popup. 2018-04-22 14:35:40 +02:00
Tamius Han
77e1f711fd enabled logging for player dimensions 2018-04-11 19:59:00 +02:00
Tamius Han
59d741b8a5 Tried implementing some checks that would prevent aspect ratio from changing if our edge candidate is text on black background. 2018-04-11 00:19:44 +02:00
Tamius Han
3740f2c487 ??? 2018-04-10 21:35:34 +02:00
Tamius Han
6fe906f166 Did I mention Warcraft movie needs a sequel? Because Warcraft movie needs a sequel.
So netflix aspect ratio detection was fine when watching Altered Carbon (2:1), but Warcraft (21:9) had some huge issues with properly auto-detecting aspect ratio (especially when starting automatic aspect ratio after manual toggle). Fixed that (i think).
2018-03-18 17:35:51 +01:00
Tamius Han
44828b3ecf Tried to fix aspect ratio autodetection on netflix but ended up watching the entire Altered Carbon instead.
Just kidding, I also fixed the autodetection on netflix. And the bit where key for netflix in SitesConf.js was wrong.
2018-03-18 15:14:57 +01:00
Tamius Han
55121a5f1b updated readme 2018-03-14 23:53:41 +01:00
Tamius Han
61a3b07c6b Fixed some issues with detecting player size changes (esp. on youtube), where switching from normal player to full screen player wouldn't be handled correctly. 2018-03-14 23:51:13 +01:00
Tamius Han
dcd430d05e font-fak -> overpass, also fixed overpass-mono 2018-03-14 21:45:53 +01:00
Tamius Han
b3a842e0b1 Font inclusion fixed for reals now. 2018-03-14 21:43:58 +01:00
Tamius Han
c35774c36f Chrome kinda works according to 1 beta tester. Fixed few other chrome-specific bugs I've noticed. Fixed the font inclusion (hopefully) 2018-03-14 21:19:15 +01:00
Tamius Han
3b7f00dc8e I feel fancy.
Fixed #25
Fixed #32
Fixed #30 (I actually haven't, just the extension was set to 'you have to manually allow sites other than youtube and netflix')
Fixed #27
2018-03-14 00:08:51 +01:00
Tamius Han
e6efaf52d8 Split settings between Settings.js (handles loading and saving) and ExtensionConf.js (actual configuration). All settings are now handled in background script (content scripts get ExtensionConf from background script). Saving seems to work. 2018-03-13 23:55:38 +01:00
Tamius Han
51f2df930d end of the day commit. settings for autoAr ARE NOT getting saved. 2018-03-13 00:36:10 +01:00
Tamius Han
13a928b90e ar fixed, disabling/enabling sites roughly works. 2018-03-11 18:00:47 +01:00
Tamius Han
d079a84005 Sitesconf comeback complete. Need to implement adding and changing settings for sites in the popup and the background script. 2018-03-11 00:49:29 +01:00
Tamius Han
15aeefbd8c retiring whitelist/blacklist arrays in Settings, SitesConf is making a comeback instead 2018-03-10 23:25:30 +01:00
Tamius Han
a5422abfcd Fixed the issue where fullscreen videos wouldn't be entirely fullscreen on youtube. 2018-03-10 12:30:38 +01:00
Tamius Han
2849bf5d85 Popup is now set to use font overpass files that are included with the extension, as opposed to assuming people have it installed on their machines. 2018-03-10 11:11:44 +01:00
Tamius Han
ef324595ef Added overpass font 2018-03-10 11:00:24 +01:00
Tamius Han
7db22fb466 RAM leak issue should be fixed for the most part. We did it ~~reddit~~github! (NOTE: there's still other things that need fixing before I let this into prod) 2018-03-08 22:22:42 +01:00
Tamius Han
93d3b064da end of the day commit. multiple concurrent instances seems to be at least somewhat under control, but other parts of extension still need modifications and testing. 2018-03-07 23:49:43 +01:00
Tamius Han
ba841c6ea3 unfuck progress before switching branches. 2018-03-07 21:42:40 +01:00
Tamius Han
18f1ea26a7 The memory usage situation improved but still far from ideal, both in terms of memory usage as well as polling frequency and video resolution we settled for. 2018-03-05 23:55:14 +01:00
Tamius Han
b9b9626cbd forgot to revert something 2018-03-04 23:07:46 +01:00
Tamius Han
4f37fe059f tried and failed some more at getting solution to garbage garbage collector 2018-03-04 23:07:11 +01:00
Tamius Han
6c9f3c537c The more I try to fix ArDetect, the more broken it is :/ 2018-03-03 23:58:29 +01:00
Tamius Han
b4d5749988 #25 appears to be fixed, but needs more testing. 2018-02-28 23:54:32 +01:00
Tamius Han
3bd28842e1 Tried my hand at fixing memory leak. ArDetect — no dice. Ghetto watcher for changes in player size now saves the HTML element that's deemed to be the player frame and uses said node for size tests in subsequent iterations (as opposed to searching for player node on every frame). Also hopefully fixed the bug with custom settings for individual sites not
getting saved.
2018-02-26 22:38:17 +01:00
Tamius Han
7b5453ec03 Updated readme 2018-02-25 21:52:06 +01:00
Tamius Han
a33c3656ad Merge branch 'stable-ytfix' 2018-02-25 21:41:44 +01:00
Tamius Han
724c856f0c Disabled imgur. 2018-02-25 21:38:42 +01:00
Tamius Han
9a569a8020 Merge branch 'stable-ytfix' 2018-02-22 22:27:21 +01:00
Tamius Han
6edcd4f0fb fix for #22 — reddit should be blacklisted by default now 2018-02-22 22:20:15 +01:00
Tamius Han
728fa0a0b3 fixed #24 and prolly #23 2018-02-22 22:14:52 +01:00
Tamius Han
3896bff39b fix for youtube screwy that happened this week 2018-02-22 22:10:13 +01:00
Tamius Han
aa30ebaa88 committing some stuff before hotfixing #24 2018-02-22 21:06:57 +01:00
Tamius Han
28014f5ff1 Of course ArDetect was bugged. Fixed most of those bugs. 2018-02-16 00:19:08 +01:00
Tamius Han
8c59faa25c New ArDetect almost finished. Not tested and no console.logs yet tho. 2018-02-15 22:59:31 +01:00
Tamius Han
90b1d8935c Started rewrite of autodetection. 2018-02-15 00:17:58 +01:00
Tamius Han
4daa054169 Fixed a series of small bugs with autodetection. 2018-02-12 23:28:31 +01:00
Tamius Han
f284c8b48a enabled logging 2018-02-06 19:51:31 +01:00
Tamius Han
1ceca7c293 Debug mode off, updated readme, manifest.json is now written for Chrome 2018-02-06 00:48:13 +01:00
Tamius Han
d78fa346ce register-video in ghettoOnChange didn't always work. background script now polls content script of current tab every 5 or so seconds. Popup script polls for has-video changes once every two seconds or so. 5s and 2s seem reasonable. 2018-02-06 00:36:48 +01:00
Tamius Han
fc4f073e5d fix for #20 2018-02-05 22:46:38 +01:00
Tamius Han
97fc77b80b Updated description as well 2018-02-04 20:22:12 +01:00
Tamius Han
2c0f0ed607 Release v2.1.0 (sans readme) 2018-02-04 17:39:26 +01:00
Tamius Han
b13eff44e3 Reworked popup warnings. Chrome doesn't work again. 2018-02-02 00:21:29 +01:00
Tamius Han
174c987690 Keyboard shortcuts get loaded in popup, fixed 'reset' button in popup. 2018-02-01 00:26:16 +01:00
Tamius Han
7e848332ce Fixed keyboard not working in Firefox/twitch. 2018-01-30 23:36:03 +01:00
Tamius Han
3cccaa37ae Minor fixes, updated readme with beggathon. 2018-01-28 02:35:05 +01:00
Tamius Han
97b7adc55a Fixed autodetection and preserving aspect ratio changes across fullscreen switch. 2018-01-27 22:25:25 +01:00
Tamius Han
0c1cae3215 "Fit to width" and "fit to height" now calculate video fit according to player size, not screen size. 2018-01-27 20:27:11 +01:00
Tamius Han
463dcc0692 Fixed popup for Chrome — or so it seems. 2018-01-27 20:13:23 +01:00
Tamius Han
e51faaf934 New comms between [uw.js <==> uw-bg.js <==> popup.js] established. Working in Firefox, not in Chrome — potentially due to Promise.all() (try replacing with for(promise of promises) await promise) 2018-01-26 00:09:08 +01:00
Tamius Han
48dd676977 fixed command 2018-01-24 23:26:09 +01:00
Tamius Han
551bee1724 reintroducing background script, which will keep track of frames and videos in currently opened tab (not yet implemented) 2018-01-24 23:15:54 +01:00
Tamius Han
85a6a680b9 Optimizations and changes. 2018-01-20 22:59:31 +01:00
Tamius Han
3b3430ddce Merged FullScreenDetect into PlayerDetect. Youtube: switching between theater mode, full screen and normal mode works properly. Vimeo still broken. 2018-01-18 22:34:42 +01:00
Tamius Han
9265a336bc Trying to add blanket support for theater mode. Changing aspect ratio works in youtube theater mode, but only when manually launched. Chaning to full screen mode stops it. This commit breaks vimeo support. 2018-01-18 00:11:03 +01:00
Tamius Han
18b8e77e05 Merge branch 'master' of github.com:xternal7/ultrawidify 2018-01-17 20:58:12 +01:00
Tamius Han
ee626fd5dd Extra videos, BrowserDetect is getting set up for Edge 2018-01-17 20:57:24 +01:00
unknown
7175db885e Updated README.md 2018-01-12 23:31:03 +01:00
unknown
4829d45b09 Fixed netflix misalignment in FF 57+ 2018-01-12 22:53:07 +01:00
Tamius Han
f443fb62ec ... well that's always a thing that happens with README.md 2018-01-12 00:33:06 +01:00
Tamius Han
b33092070d (whoopsie daisy)² 2018-01-12 00:28:37 +01:00
Tamius Han
d51736d6ac whoopsie daisy 2018-01-12 00:27:49 +01:00
Tamius Han
a17ac319cb Added bigger icons that chrome uses, updated README.md 2018-01-12 00:26:29 +01:00
Tamius Han
d4a6901d7d Popup now works on Chrome as well. 2018-01-11 22:43:25 +01:00
Tamius Han
33acbe5015 Okay then. Turns out background script might not be necessary. (Even though not yet removed from the projects, popup now communicates directly with the tab as opposed to background page which forwards everything to the tab. I think. But this means even Chrome — as shit as it is — might be able to do the popup stuff without me having to maintain another
version of code that does the same thing.)
2018-01-10 23:16:07 +01:00
Tamius Han
45c986d66d Chrome is fucking cancer and its sendMessage() (both in chrome.tabs as well as chrome.runtime) sucks major ass. 2018-01-08 22:48:45 +01:00
Tamius Han
88bbf1cb07 README.MD updates 2018-01-06 23:00:24 +01:00
Tamius Han
4b61325c58 Attempt at fixing Chrome's UI. Not successful because Chrome documentation is TL;DR 2018-01-06 22:58:31 +01:00
Tamius Han
d8ee278491 Fixed bug with popup buttons for forcing aspect ratio not always working. Autodetection can no longer get triggered by small changes in aspect ratio (but will get triggered if change is a small amount over the treshold still) 2018-01-02 03:36:29 +01:00
Tamius Han
5ad7144e67 Version 2.0! Woohoooo! 2017-12-31 18:28:03 +01:00
Tamius Han
ec6dfadb41 Some basic settings for keyboard shortcuts. 2017-12-30 20:53:15 +01:00
Tamius Han
d0373820fe Popup is working properly now. 2017-12-30 18:36:08 +01:00
Tamius Han
82dd71eb5b Keyboard settings work (modifiers untested) 2017-12-30 12:55:58 +01:00
Tamius Han
0f2d786780 Popup menus are showing properly. 2017-12-30 02:58:24 +01:00
Tamius Han
de2677fdd6 Added ui/popup window (and it kinda works) 2017-12-29 23:34:40 +01:00
Tamius Han
c9719a163a Fixed some problems. 2017-12-17 22:56:07 +01:00
Tamius Han
66cc44ab6d Reshaped popup 2017-12-02 21:09:08 +01:00
Tamius Han
e64f21d427 Fixed the icon in manifet.json 2017-11-14 00:01:45 +01:00
Tamius Han
b1fcb233a3 Added popup (no functionality at this time). 2017-11-13 23:34:24 +01:00
Tamius Han
0083e8203d Fixed the issue with styles not getting applied. 2017-11-13 22:35:04 +01:00
Tamius Han
4e38a746e1 Edited wrong readme 2017-10-17 22:22:41 +02:00
Tamius Han
602c5f3418 We have semi-working version. Keybinds aren't rebindable yet. Settings page needs to be remade to accomodate new options. 2017-10-17 22:17:51 +02:00
Tamius Han
f582cbe42d started with keybinds 2017-10-02 23:30:40 +02:00
Tamius Han
021f5c6580 Vimeo has a non-fs autodetect. 2017-10-02 00:27:01 +02:00
Tamius Han
9b4b6c2ceb Improved autodetection a little (detecting aspect ratio is possible even if the letterbox is interrupted by dark shapes) 2017-09-27 02:26:47 +02:00
Tamius Han
ed1ac6da36 Autodetection works. Somewhat globally, even (tested youtube and vimeo) 2017-09-24 01:54:46 +02:00
Tamius Han
be8fba8e04 fixed the issue with hanging. 2017-09-15 23:49:58 +02:00
Tamius Han
24a7b1c448 Some fun testing. Offending script currently crashes firefox for some reason. 2017-09-15 22:19:49 +02:00
Tamius Han
999a4c6c95 Started v2 'the dev' branch 2017-09-15 19:55:43 +02:00
Tamius Han
5ce4fc9825 Updated readme with absence notice, forked master to v1 (old version) and v2 (where rewrite to requirejs will happen). 2017-09-15 19:52:35 +02:00
277 changed files with 73888 additions and 17025 deletions

27
.babelrc Normal file
View File

@ -0,0 +1,27 @@
{
"plugins": [
"@babel/plugin-proposal-class-properties"
],
"presets": [
["@babel/preset-env", {
"useBuiltIns": false,
"targets": {
"esmodules": true
}
}]
]
}
// {
// "plugins": [
// "@babel/plugin-proposal-optional-chaining"
// ],
// "presets": [
// ["@babel/preset-env", {
// "useBuiltIns": "usage",
// "targets": {
// // https://jamie.build/last-2-versions
// "browsers": ["> 0.25%", "not ie 11", "not op_mini all"]
// }
// }]
// ]
// }

25
.github/ISSUE_TEMPLATE/bug_report.md vendored Normal file
View File

@ -0,0 +1,25 @@
---
name: Bug report
about: Create a report to help us improve
---
**Describe the bug**
Describe what happened. Don't forget to mention which site you were on (reddit, netflix, youtube). If issue only happens with certain videos, please provide links with timestamps.
**To Reproduce**
What did you do to make it happen?
**Expected behavior**
What do you think should happen instead?
**Screenshots**
A picture is worth a thousand words. If Ultrawidify scales a video in an improper way, please include a screenshot of that.
**Browser and OS**
* Browser/browser version:
* Operating system:
* Ultrawidify version:
**Additional info**
Any other things you want to say.

18
.gitignore vendored
View File

@ -1 +1,17 @@
ultrawidify.zip
old/
build/
/node_modules
/*.log
/dist*
/uw-git_keys
/untracked-assets
*.pem
*.kate-swp
src/res/img/git-ignore/
test/debug-configs/
debugging-resources/

1
.nvmrc Normal file
View File

@ -0,0 +1 @@
14.21.3

8
.vscode/extensions.json vendored Normal file
View File

@ -0,0 +1,8 @@
{
"recommendations": [
"hollowtree.vue-pack",
"msjsdiag.debugger-for-chrome",
"firefox-devtools.vscode-firefox-debug",
"msjsdiag.debugger-for-edge"
]
}

52
.vscode/launch.json vendored Normal file
View File

@ -0,0 +1,52 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "chrome",
"request": "attach",
"name": "Attach to Chrome",
"port": 9222,
"urlFilter": "http://*/*",
"webRoot": "${workspaceFolder}"
},
{
"type": "firefox",
"request": "attach",
"name": "Attach (firefox)",
"pathMappings": [
{
"url": "webpack:///ext",
"path": "${workspaceFolder}/src/ext"
}
]
},
{
"name": "Launch addon (firefox)",
"type": "firefox",
"request": "launch",
"port": 6000,
"reAttach": true,
"addonType": "webExtension",
"addonPath": "${workspaceFolder}/dist-ff",
"pathMappings": [
{
"url": "webpack:///ext",
"path": "${workspaceFolder}/src/ext"
},
]
}
],
"firefox": {
"executable": "/usr/bin/firefox-developer-edition",
"firefoxArgs": [
"--start-debugger-server"
]
},
"chrome": {
"executable": "/usr/bin/google-chrome-stable --remote-debugging-port=9222",
}
}

86
.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,86 @@
{
"cSpell.words": [
"aard",
"ardetector",
"autodetect",
"autodetection",
"beforeunload",
"blackbar",
"blackbars",
"blackframe",
"canvas",
"clickthrough",
"com",
"comms",
"csui",
"decycle",
"dinked",
"dinks",
"disneyplus",
"endregion",
"equalish",
"fith",
"fitw",
"fuckup",
"gfycat",
"gmail",
"guardline",
"han",
"haram",
"iframe",
"imgur",
"insta",
"letterboxed",
"manjaro",
"mdicon",
"mdijs",
"minification",
"mitigations",
"nogrow",
"noshrink",
"outro",
"PILLARBOX",
"PILLARBOXED",
"polyfill",
"recursing",
"reddit",
"rescan",
"resizer",
"scrollbar",
"shitiness",
"smallcaps",
"suboption",
"tabitem",
"tablist",
"tamius",
"textbox",
"ultrawide",
"ultrawidify",
"unmark",
"unmarking",
"unshift",
"uwid",
"uwui",
"videodata",
"vids",
"vuejs",
"vuex",
"webextension",
"webextensions",
"youtube"
],
"cSpell.ignoreWords": [
"abcdefghijklmnopqrstuvwxyz",
"autoar",
"cheight",
"cwidth",
"fcstart",
"fctime",
"legacycd",
"ncol",
"nrow",
"tickrate",
"undisable",
"vdid"
]
}

584
CHANGELOG.md Normal file
View File

@ -0,0 +1,584 @@
# Changelog
### Plans for the future
* Native builds for Chromium Edge
* Settings page looks ugly af right now. Maybe fix it some time later
* other bug fixes
## v7.0 (planned major)
* WebGL autodetection
## v6.0 (current major)
### v6.0.1
* Fixed external links
### v6.0.0
Chrome only, because I needed to rush manifest v3 migration before ensuring things work in Firefox.
* In player UI
* New alignment options (can align video both vertically, as well as horizontally)
* Extension does a little bit of a better job differentiating between levels of support for a given site
* Changed how cropping and panning works. This should lead to fewer problems and better generic support.
* REGRESSION: no manual panning with shift + mouse movement
* "Player select" screen, which provides a GUI way for picking HTML element that acts as the video player area
Regressions and potential issues:
* Settings were largely not migrated from previous versions. This is as intended, since changes to cropping (and some other aspects)
rendered certain old settings obsolete.
* Extension can no longer discriminate between iframes — extension popup commands get sent to ALL iframes on page
* Extension probably can't discriminate between multiple videos on a single page
## v5.x
### v5.1.7
Firefox-only.
* When cropping and panning video, CSS' `transform: translate(x,y)` now uses integers _always_. Before that fix, `translate(x,y)` could be offset by x.5 px, and that half of a pixel introduced a 1px thick line on the portion of the left edge of the video.
### v5.1.7
* When aligning videos, ensure video is never translated by a fractional value
* As of recent nVidia driver update in Edge, Angle detection fails in a way that prevents popup from showing up. This problem should be fixed now.
The angle detection problem was fixed by disabling the angle detection check for now, as Chrome, et al. appear to have fixed buggy video hardware acceleration.
### v5.1.6
* Added new config for disney+ (courtesy of @MStefan99)
* Chrome hardware acceleration is bugged and cannot be worked around in-extension. Only way to fix this is for users to change their Google Chrome settings. Added naggathon with instructions into the extension popup.
### v5.1.5
* Fixed laginess in Chromium-based browsers on Windows. Details in [#199](https://github.com/tamius-han/ultrawidify/issues/199#issuecomment-1221383134)
### v5.1.4
* Fixed some problems with autodetection not returning to 16:9 when necessary if autodetection already changed aspect ratio ([#198](https://github.com/tamius-han/ultrawidify/issues/198))
### v5.1.3
* Fixed some problems with autodetection sometimes briefly resetting on dark frames ([#195](https://github.com/tamius-han/ultrawidify/issues/195), [#196](https://github.com/tamius-han/ultrawidify/issues/196))
### v5.1.2
* `set-extension-mode` turned into `set-ExtensionMode` at some point. This caused in "Enable this extension" options to vanish on certain setups.
* Blackframe tests now run on same data as main algorithm as opposed on a smaller sample (`drawImage()` calls are _very_ expensive even for a 16x9 sample).
### v5.1.1
* Fixed autodetection
### v5.1.0
* Re-enable logger
* Move aspect ratio autodetection to requestAnimationFrame
* Fix netflix
### v5.0.7
* Videos of square-ish aspect ratios on 1440p (and lower) resolutions now no longer get misaligned ([#162](https://github.com/tamius-han/ultrawidify/issues/162))
* Alignment of featured videos on youtube channel page should now also be fixed
### v5.0.6
* Added configuration for metaivi.com based on user feedback ([#160](https://github.com/tamius-han/ultrawidify/issues/160))
* Removed ExtConfPatches for versions < 4.5.0, because nobody should be using a build of this extension that's over a year old
### v5.0.5
* improved UX a bit
* Fixed white background on app.plex.tv ([#158](https://github.com/tamius-han/ultrawidify/issues/158))
### v5.0.4
* Attempt to fix disney+ again, courtesy of [@jwannebo](https://github.com/tamius-han/ultrawidify/issues/84#issuecomment-846334005) on github.
### v5.0.3
* Fixed the issue where the videos were sometimes offset up and left. Again.
* Fix the issue where correcting source stretch was squished incorrectly ([#153](https://github.com/tamius-han/ultrawidify/issues/153))
### v5.0.2
* When in full screen, the extension will assume player element dimensions are the same as the screen resolution. This should help with sites where ultrawidify doesn't correctly identify the player, as cropping generally doesn't work if player element is not identified. Old behaviour can be restored in advanced extension settings by toggling the "use player aspect ratio in fullscreen" checkbox under 'player detection settings'.
* Extension should now respect 'disable extension' option for real.
* Fixed the issue where player wouldn't get detected if video was wider than the player.
### v5.0.1
* Added an option for users to turn off (and/or configure) Chrome/Edge's zoom limiter.
### v5.0.0
There's been some big-ish changes under the hood:
* Migrate main scripts to typescript (vue is currently not included).
* webextension-polyfill is now used everywhere (if only because typescript throws a hissy fit with `browser` and `chrome` otherwise) ([#114](https://github.com/tamius-han/ultrawidify/issues/114))
* Fix some bugs that I didn't even know I had, but typescript kinda shone some light on them
* Manual zoom (Z/U unless sites override the two) should now work again (without automatic AR constantly overriding it). Same goes for panning. ([#135](https://github.com/tamius-han/ultrawidify/issues/135) & [#138](https://github.com/tamius-han/ultrawidify/issues/138))
* Fix issue when video would be scaled incorrectly if video element uses `height:auto`.
* **[5.0.0.1]** Fixed the issue where settings were reset on page load.
* **[5.0.0.1]** Fixed the issue where settings page wouldn't load.
## v4.x (current major)
### v4.5.3
* Provides workaround for the fullscreen stretching bug Chrome 88 (or a recent Windows 10 update) introduced for nVidia users using hardware acceleration on Windows 10. In order to mitigate this bug, Ultrawidify needs to keep a 5-10 px wide black border while watching videos in full screen. This bug is also present in Edge.
* **[4.5.3.1]** Fixed letterbox misalignment binding in settings (#134)
* **[4.5.3.2]** Fixed false 'autodetection not supported' notifications.
### v4.5.2
* Fixed the issue where videos would sometimes get misaligned while using hybrid stretch, except for real this time. ([#125](https://github.com/tamius-han/ultrawidify/issues/125))
* Improved DRM detection (the 'autodetection cannot work on this site' popup should now no longer show up on the sites where autodetection _can_ work)
### v4.5.1
* Fixed the misalignment issue on netflix ... hopefully.
* 'Site settings' tab should now work in Chrome as well ([#126](https://github.com/tamius-han/ultrawidify/issues/126))
* Popup interface now refreshes properly ([#127](https://github.com/tamius-han/ultrawidify/issues/127))
* Videos should now be scaled correctly when the display is narrower than video's native aspect ratio ([#118](https://github.com/tamius-han/ultrawidify/issues/118))
* Fullscreen videos on streamable are aligned correctly ([#116](https://github.com/tamius-han/ultrawidify/issues/118)).
* **[4.5.1.1]** Streamable fix broke old.reddit + RES on embeds from v.redd.it and streamable.com. We're now using an alternative implementation. ([#128](https://github.com/tamius-han/ultrawidify/issues/128))
* **[4.5.1.2]** Fixed the issue where videos would sometimes get misaligned while using hybrid stretch. ([#125](https://github.com/tamius-han/ultrawidify/issues/125))
* **[4.5.1.3]** Added fix for disney plus
* **[4.5.1.3]** Microsoft Edge has fixed the bugs that prevented the extension from working properly. Popup should no longer be shown.
### v4.5.0 (Current)
* Under the hood: migrated from vue2 to vue3, because optional chaining in templates is too OP.
* (On options page, section 'Action &amp; shortcuts') Manual aspect ratio now supports entering custom ratios using '21/9' and '2.39:1' formats (as opposed to single number, e.g. '2.39') — [#121](https://github.com/tamius-han/ultrawidify/issues/121).
* Added config for wakanim.tv (special thanks to @saschanaz for doing the legwork — [#113](https://github.com/tamius-han/ultrawidify/issues/113))
* (In Firefox) When extension was placed in overflow menu, the popup was cut off. That should be fixed now. [#119](https://github.com/tamius-han/ultrawidify/issues/119)
* The extension will now show a notification when autodetection can't run due to DRM
* Videos on facebook and reddit no longer get shifted up and to the left for me (cropping most of the video off-screen), but I haven't been deliberately trying to fix that issue. If you experience that issue, please consider contacting me (via github or email) with a link to a problematic video.
### v4.4.10
* Video alignment should now work on Twitch — [#109](https://github.com/tamius-han/ultrawidify/issues/109)
* Videos should now align properly on Hulu while cropped — [#111](https://github.com/tamius-han/ultrawidify/issues/111) & via email
* Fixed a problem where changing certain settings would cause multiple instances of Ultrawidify to run on a page, effectively preventing some crop options to be set until reload. (possibly [#112](https://github.com/tamius-han/ultrawidify/issues/112)?)
* Fixed a problem where embedded videos would be misaligned after switching from full screen
* **[4.4.10.1]** Fixed cruncyhroll regression — [#109](https://github.com/tamius-han/ultrawidify/issues/115)
### v4.4.9
* Fixed the youtube alignment issue (previously fixed in v4.4.7.1-2), but this time for real (and in a bit more proper way)
* Fixed the bug where extension wouldn't work when URL specified a port (e.g. www.example.com:80)
* **[4.4.9.1]** removed source files from extension build in order to decrease package size
* **[4.4.9.2]** updated dependencies and stuff
In addition to that, as of 4.4.9.1 the build process ensures removal of `node_modules` before building the extension so we can have reproducible builds except for real this time. Hopefully.
### v4.4.8
* Fixed the bug where on pages with more than one video, the list of available videos in the extension popup wouldn't remove videos that are no longer displayed on site. This resulted in extension listing videos that were no longer on the page. Reboot or navigation would also not clear the list if navigating between various pages on the same host.
* Fixed the chrome-only bug where on sites with more than one video, the number wouldn't get hidden when the extension popup closed.
### v4.4.7
* Removed unnecessary font files and image files from the package.
* LoggerUI is now functional.
* **[4.4.7.1]** Additional CSS fixes
* **[4.4.7.1]** Bruteforce fix for youtube alignment issue
* **[4.4.7.2]** Bruteforce fix for youtube alignment issue — increase number of retries
### v4.4.6
* Ensured that Vue part of the content script (logger UI) only loads when necessary in order to fix breakage on certain sites (#96).
* Disabling (or enabling, if running in whitelist-only mode) specific sites used to not work (#91). This issue appears to have been fixed.
* Default stretch mode for sites is now probably being observed, too (#94).
* Fixed netflix (and possibly disney+ )
* It's been almost a month and Chrome Web Store still hasn't finished the review of the 4.4.4.1 (and 4.4.4.2) revisions because when it comes to incompetence, it's hard to expect anything less from Google. I've did some proverbial yelling at the support in hopes that Chrome version will finally see an update (disclaimer: when I said yelling I really mean a polite request, because support staff doesn't deserve abuse because a different department is utter shite at doing their jobs).
### v4.4.5
* Extension no longer requires `allTabs` and `webNavigation` permissions
* Some CSS on the debugger popup was not scoped, causing issues with some sites.
* Fix some additional issues with video alignment when changing video on autoplay
### v4.4.4
* Tab detection in extension popup has been made more accurate
* QoL: Added user-accessible logger (to make fixing sites I can't access a bit easier)
* Changed links to reflect my github username change
* **[4.4.4.1]** Fix broken extension popup.
* **[4.4.4.1]** Fix global/site settings not getting applied immediately/only getting applied after page reload.
* **[4.4.4.2]** Fix problem with video being offset while switching between full screen and non-fullscreen non-theater mode on Youtube
### v4.4.3
* Fixed conf patch for disney+ (hopefully) (v4.4.3.1: but for real)
* `Settings.save()` adds missing values to site config when saving extension configuration.
### v4.4.2
* New stretching modes that squish video to a specified aspect ratio. One of the two modes correct aspect ratio before cropping, the other corrects after cropping.
* Potential fix for disney+ — added an option that forces extension to force player re-detection.
* Fixed bug where certain custom actions that should be removable weren't removable
### v4.4.1
* Changes to player detection that fix issues with vk
* Extension tries to avoid setting aspect ratio pointlessly
* (Hopefully) fixed mailto: and reddit compose links.
* When reporting bugs, email/reddit template now automatically gathers browser, extension version and OS.
### v4.4.0
* Russian users (and users of other non-latin keyboard layouts) can now use keyboard shortcuts by default, without having to rebind them manually. (NOTE: if you've changed keyboard shortcuts manually, this change will ***NOT*** be applied to your configuration.)
* NOTE: when using non-latin layouts, 'zoom' shortcut (`z` by default) uses the position of 'Y' on QWERTY layout.
* Ability to preserve aspect ratio between different videos (applies to current page and doesn't survive proper page reloads)
* Changing aspect ratio now resets zooming and panning.
* Fixed bug where keyboard shortcuts would work while typing in certain text fields
* Fixed minor bug with autodetection
* **[4.4.0.1]** fixed mailto and reddit compose links. When reporting issues via e-mail or reddit, extension version, browser
and OS are automatically included in email/reddit template.
### v4.3.1
* Minor rework of settings page (actions & shortcuts section)
* Fixed bug that prevented settings page from opening
* **[4.3.1.1]** quick patch for twitch.tv
### v4.3.0
* Fixed some issues with incorrect alignment after window resize
* Fixed all sorts of issues for videos hosted on v.reddit for new (and old) reddit
* Fixed the issue where setting extension to 'whitelist only' would disable 'site settings' in popup.
* Added user-friendly way to export/import settings (export requires 'download' permissions)
* Reworked logging
* Started using mutation observers to watch for changes in player size as well. Since mutation observers aren't entirely reliable, old way of doing things is still somewhat present as a backup way, but runs less frequently.
* Implemented/improved/fixed settings patching
* **[4.3.0.1]** Removed some console.logs that I missed the first time around.
* **[4.3.0.2]** Extension would not work for new users. (Special thanks to [ezzak](https://github.com/ezzak) for finding and submitting a patch)
### v4.2.4 / 4.2.4.x
* Improvements to player detection. More details in the [blog post](https://stuff.tamius.net/sacred-texts/2019/08/31/ultrawidify-and-the-improper-cropping/).
* **[4.2.4.1]** Fixed default video settings for reddit
* **[4.2.4.1]** Manually specified query selectors will also be checked for compliance with player detection rules.
* **[4.2.4.2]** Additional bugfixes. Updated/fixed default settings.
### v4.2.3 / 4.2.3.x
* Fixed twitchy behaviour on Twitch, Facebook and Twatter. Here's a [blog post](https://stuff.tamius.net/sacred-texts/2019/08/24/ultrawidify-the-twitchy-twitch-problem/) that covers the issue in more detail.
* Cropping now uses user styles (as opposed to modifying element's style attribute)
* Fixed the issue where one-pixel letterbox would result in constant aspect ratio corrections.
* Started using mutation observers to watch for anything modifying the size of our video.
* **[4.2.3.1]** fixed some bugs in popup.
### v4.2.2
* Fixed player detection on reddit (for videos from v.reddit)
### v4.2.1
* Fixed bug where custom CSS didn't get applied to pages
### v4.2.0
* Slightly improved popup design. (Design change suggested by PortaTrekos)
* Player detection: youtube and twitch now have manual player element detection, with strictly defined players.
* Improved site settings control in extension popup. It's possible to enable extension for previously disabled embedded sites.
* Improved incompatibilities with reddit, where videos would be vertically misaligned when not using RES
* Fixed imcompatibilities with Iridium. Flicker when clicking play/pause or switching between big and popup player is caused by either Youtube or Iridium trying to apply their styles over mine.
* Issues with inconsistent alignment that some people reported are potentially fixed
### v4.1.2
* Fixed video alignment issues on www.reddit as well (for people who use old reddit without going to old.reddit)
* Fixed bug with 'player detection' tab
### v4.1.1
* Disabled gfycat
### v4.1.0
* Added ability to add custom CSS to page
* Fixed video alignment issues on old.reddit. Disabled extension on imgur by default.
* Extension now works on vimeo again
* **UX:** Renamed 'about' to 'report a problem' in order to make contact info more discoverable
### v4.0.1
* Fixed bug where sites using 'default' option in 'Extension mode' settings would be disabled, even if extension was not.
* Fixed bug where extension sometimes wouldn't work on Netflix.
### v4.0.0
* Fixed the bug where saving settings wouldn't work
* Massive under-the-hood changes. The extension popup and settings page use VueJS
* **Autodetection improvements:**
* Autodetection tries to differentiate between gradients and hard edge and avoids correcting on gradients. This should help with videos that are similar to [IGN's review of Hollow Knight](https://www.youtube.com/watch?v=hg25ONutphA).
* Black frame detection has been implemented and improved. Some cases (but not all) of text on black background causing aspect ratio corrections have also been fixed.
* Autodetection frequency increased from roughly once every 0.6 seconds to about 3 checks per second.
* Fixed the bug where autodetectin didn't calculate aspect ratio correctly. This bug would manifest in extension cropping too much even though the edge was clearly defined. It most commonly occured in videos of aspect ratio <1 that contained letterbox. [ex 1]( https://www.youtube.com/watch?v=9DP0TbOQcOw), [ex 2](https://www.reddit.com/r/videos/comments/a137pj/daily_reminder_that_shelly_miscavige_wife_of/)
* **Settings page was re-added**
* This includes a page for adding new aspect ratios and keyboard shortcuts. This feature is experimental.
* It's possible to tweak autodetection sensitivity and frequency — in slightly more user-friendly way as well
* It's also possible to tweak autodetection settings in detail.
* It's now possible to reset settings to default
* Rewrote keyboard shortcuts and changed how they're handled. Massively.
* You can now select which specific video on the page you control, provided each video is in its separate iframe
* While I wasn't looking, Netflix started supporting ultrawide monitors on its own. Netflix' implementation clashes with my own, though, so I've decided to disable autodetection on videos that netflix already cropped on their own. Manual aspect ratio changes are still possible, but they're off. You've been warned.
## v3.x
~~### v3.3.0~~
~~This will probably get promoted to 4.0, continuing the trend of version something. 3 not happening. Eulul~~
* ~~Basic mode added~~
* ~~Per-site controls in popup (to control embedded videos)~~
* ~~Rewrote keyboard shortcuts and changed how they're handled. Massively.~~
Never happened, got bumped to 4.0.0.
### v3.2.2
* Pan event listener now gets properly unbound
* Fixed 'reset zoom' button in popup
### v3.2.1
* Fixed issue where global video alignment setting didn't get saved properly
### v3.2.0
* Zoom and panning
* Reorganized popup
* Various bug fixes
### v3.1.1 (Chrome-only)
* Logging was accidentally left on in release version. This was fixed.
### v3.1.0
* Fixed the issue where aspect ratio change wouldn't survive switching between fullscreen and non-fullscreen modes
* Fixed the issue where settings wouldn't survive browser restarts in Firefox
Under the hood:
* rewrote how settings work, swapped Comms with storage.onChanged where it made sense & as much as possible
* enabling/disabling extension (either globally or for a given site) has now instant effect (consequence of above)
### v3.0.1
Minor fixes.
### v3.0.0
Pretty much rewrote extension in more object-oriented way and sorted out spaghetti a little. Site settings and keybinds have been merged with the rest of the extension settings. Rewrote messageing.
User-facing changes:
* Extension can be enabled/disabled globally or on per-site basis
* Automatic aspect ratio can be turned off, either globally or on per-site basis
* Stretching mode implemented
* Popup has been pimped up to reflect those changes
## v2.x
### v2.2.5 (AMO, Chrome)
Added some anti-lag measures. This seems to be an issue affecting _only_ Chrome (and only then some installs), where canvas.drawImage() won't work properly for some reason.
### v2.2.4
Lots of mostly incredibly minor stuff.
* Fixed issue where 21:9 videos with no letterbox would be zoomed in incorrectly in theater mode
* Added pillarbox basic pillarbox detection: extension will avoid zooming in a video if both letterbox and pillarbox are detected. This should fix the issues with incorrect zooming on certain kinds of images (such as movie titles and studio logos, e.g. [lucasfilm](https://i.ytimg.com/vi/H368H5cTqVM/maxresdefault.jpg) was one of the offenders).
* Fixed an issue where automatic detection would sometimes _not_ unzoom the video in cases where it clearly should
* Implemented some debugging tools for me. It's not much.
* Fixed some under-the-hood bugs nobody knew they even existed
* A lil bit of refactoring
### v2.2.3
* Fixed automatic aspect ratio detection on DRM-protected sites.
### v2.2.2
* Fixes problems with switching from normal to fullscreen player on youtube. If 2.2.1 didn't fix the font issue, this version should have.
### v2.2.1
* Fixes few chrome-specific fixes/bugs that v2.2.0 introduced. Maybe fixed the font problem.
### v2.2.0
Various improvements to automatic aspect ratio detection:
* **Fixed the situation with insane memory usage due to the automatic aspect ratio detection (#25, #32) and lag that appeared in certain cases after the extension has been running for a while.** There's still fun stuff going on — see notes below.
* Improved accuracy of automatic detection. This should fix the issue of rapid switching in dark videos or videos with otherwise uneven edges (#12 - [video](https://www.youtube.com/watch?v=NaTGwlfRB_c); #24 - [video](https://www.youtube.com/watch?v=xvZqHgFz51I) (see the car at the beginning))
Improved accuracy has increased the base RAM usage, and not by a small amount (I seem to have fixed my blunders, so that could _actually_ be on Firefox). As a result, I've reduced both resolution of the sample as well as polling frequency.
Polling of 1 check per second shouldn't use too much RAM. If you want automatic aspect ratio detection to react faster, you can up that number to 30 in the settings. 30 checks per second can be expensive: up to 400 MB if you've just started Firefox and went to youtube. Can go north of 2 gigs if you've been running Firefox for longer than that (seems to be a problem with Javascript garbage collection).
Videos that aren't playing (e.g. videos that are paused or ended) do (should) ***not*** use any meaningful amount of RAM.
* Overpass font is now bundled with this extension, meaning the popup should appear the way it was meant to appear™.
### v2.1.4
* Extension has been disabled on imgur (it was breaking gifs)
### v2.1.3
* Youtube pushed an update that broke this extension on Firefox (but not on Chrome?). This update fixes it.
* Extension disabled on reddit by default
Youtube fix seems to have broken Chrome compatibility (again), so any quick fix for this point forward will land in Chrome version along with v2.2.
### v2.1.2
* Fixed some bugs with autodetection sometimes not working properly on Youtube.
Problem: there's this bit of code that keeps aspect ratio from changing when the difference between 'previous' and 'current' aspect ratio is too small. Unfortunately, the 'previous' value was _not_ updated on every aspect ratio switch for some reason. Also `ArDetect.init()` — for some reason — didn't always clean the 'previous' value even though it should.
### v2.1.1
* Fixed issue #20 — aspect ratio autodetection should now start on subsequent videos as well.
* Netflix sometimes always showed 'no video detected' warning. Popup and background script now periodically poll for `hasVideos` property.
### v2.1.0 (Chrome)
* Popup should work more reliably now
* Twitch works ... kinda but not always
### v2.0.3
* Fixed the bug where Netflix videos weren't vertically centered in Firefox 57+ (not present in Chrome or FF 56 or earlier)
### v2.0.2
v2.0.1, but UI in the extension button now also works in Chrome.
### v2.0.1
* Autodetection: aspect ratio is no longer corrected if the detected difference is too small to make a meaningful difference
### v2.0
* Completely rewritten
* Automatic aspect ratio detection works on Youtube _and_ Netflix
* Added popup for quick actions (serves as a replacement for player UI)
* Restored settings page for keybinds.
Getting automatic aspect ratio detection required some hacks, not sure how easy will be to port to chrome.
### v2.0a1
The extension is being rewritten almost ground-up, around automatic aspect ratio detection. By default, this extension now only works in fullscreen, but due to some simplification it should work on most sites. As direct result of this simplification:
* The UI is completely gone
* Ability to add custom sites has been scrapped (might get implemented later on if some sites are a bit more problematic
* Extension broken up between smaller files, this time the proper way
* Added "the impossible aspect ratio autodetection"
* Zoom/unzoom options are gone
* Can't customize keybinds yet
# v1.x
### v1.3a1
* Adding ability to add custom sites (in progress)
* Most of the extension is being completely rewritten to accomodate that feature, which means there's a serious regression with Netflix support (no netflix at the moment)
* I'm also trying to break the 1500 line behemoth into smaller files.
### v1.2.1
* Fixed the bugs which caused aspect ratio to not be calculated properly.
* Introduced further changes that allow me to not keep two separate version for Firefox and Chrome.
### v1.2.0
* Auto-aspect ratio detection on netflix
* initial port to Chrome
### v1.1.1
* Fixed zooming issue on netflix
* Ultrawidify shortcuts > youtube/netflix shortcuts
* Fixed 'settings' page
* Fixed 'settings' (wrench button) popup on youtube (it was broken by one of the previous updates)
### v1.1.0
* Introduced Netflix support.
As Netflix relies on extension re-initializing at least the UI ***a lot***, the optimization introduced in 1.0.2 was reversed (as waiting 2 seconds for the UI to appear is just too much).
Furthermore, triggering UI re-initialisation on onUpdated events turned out to not be the proper way to go: immediately after the extension is initialized, onUpdated gets triggered even more often than your average Buzzfeed writer/reader. But change the episode on Netflix and suddenly, onUpdated gets barely triggered at all — which means that more often than not, the UI extension injects into the page wasn't visible. (the fuck, really)
This is why Netflix uses another function that manually checks whether the player bar is present. Ideally that check happens every tenth of a second, but Firefox may be limiting that to one per second.
### v1.0.2
The 'extension sometimes not working' bug was fixed (by having extension try to setup every time a page got updated), but the fix had some problems. Namely, the extension would re-initiate (complete with re-adding the entire UI) itself very _very_ often.
This could be a problem, so it was fixed. Extension is notified of updates only every ~2 seconds (which absorbs most of the "page was updated" events on page load) and doesn't attempt to reload the UI if the UI was already loaded. (Unless `debugmsg` is set to true. It's generally not, but any commits to this repo could potentially still have it enabled).
### v1.0.1
Fixed the bug where sometimes the extension would fail to work. (example: you opened youtube's search page in a brand new tab. You then opened a video from the search results (_not_ in a new tab). Extension wouldn't work at all in videos opened in that manner).
### v1.0.0
* Is pretty much rc1, except slightly different background image.
### v1.0-rc1
* Settings page is added and mostly working.
### v0.9.9.6
* The issue with buttons not fitting in the control bar was resolved.
### v0.9.9.5
* Played with settings and localstorage a bit, but no clear implementation yet.
* Fixed some bugs caused by event propagation.
* All buttons in the player's control bar are now also in the settings popup.
* Had to scrap settings page in its current form
* TODO: sometimes not all buttons can fit in the control bar. Such occurences should be detected.
### v0.9.9.1
* Keybinds `a` and `w` now work.
* Some changes under the bonnet, mostly regarding the way keypresses are handled.
* 'Settings' page is ~15% done.
### v0.9.9
* The aspect ratio thingy is now also in GUI
* Fixed code for forcing aspect ratio. At least I think it's fixed now.
### v0.9.8
* Added GUI/buttons on the player.
* Script now only loads on youtube pages (iframes included) (before, this script would run on any page)
### v0.9.7
* No new features added. Version number got incremented due to an attempt at autoupdating (which got foiled due to lack of HTTPS)
### v0.9.6
* Added experimental feature that tries to force an aspect ratio
### v0.9.1
* First version on GitHub (and on AMO) with basic features (zoom, fit to width, fit to height)

6
DOCUMENTATION.MD Normal file
View File

@ -0,0 +1,6 @@
# Implementation details
## Enabling/disabling aspect ratio corrections
* Aspect ratios are changed by proxy. Extension attaches **a custom CSS class** to `video` and `player` elements.
* To prevent extension from affecting the appearance of a webpage, **it's sufficient to remove our custom CSS classes from `video` and `player` elements.**

32
Jenkinsfile vendored Normal file
View File

@ -0,0 +1,32 @@
// required jenkins plugins:
// * https://plugins.jenkins.io/git/
pipeline {
agent any
stages {
// stage('Check for changes') {
// sh "env.GIT_COMMIT != env.GIT_PREVIOUS_COMMIT"
// }
stage('Install dependencies') {
steps {
sh 'npm ci'
}
}
stage('Build') {
steps {
sh 'npm run build-all'
}
}
stage('Push to release server') {
steps {
sh "echo 'implement me pls!'"
}
}
}
}

View File

@ -0,0 +1,23 @@
Microsoft edge extension store requires notes for certification. Because I'm too lazy to whip this text over and over and over and over and over and over again, I'm making it a copypasta.
---------------------------------------------------------------------------------------------
This extension is targeted at users of 21:9 monitors. If using 16:9 monitor, use youtube in THEATER MODE.
Not all videos need to have their aspect ratio corrected. Here is few examples of videos with problems this extension is trying to solve:
* Variable aspect ratio — autodetection testing grounds: https://www.youtube.com/watch?v=-IHzprfs6tw
* Static (but incorrect) aspect ratio: https://www.youtube.com/watch?v=BTETsm79D3A
Twitch example (collapse subscription & chat sidebars on 16:9, do not fullscreen) — aspect ratio switch happens at around 1:50:00 mark:
* https://www.twitch.tv/videos/330639009?t=1h49m45s
Autodetect has technological limitations and can incorrectly detect aspect ratio. This is acceptable — user should override it in such cases.
Functions labelled 'experimental' are experimental and may not function correctly.
Websites may interfere with keyboard shortcuts.
Brief video flicker when changing between fullscreen, non-fullscreen or when changing browser is inherent artifact caused by sites not being aware of extension and is thus considered acceptable.
Logger option does nothing (except give you a popup) unless you have a logger config handy. It is designed for debugging in case of bug reports.

31
README-AMO.md Normal file
View File

@ -0,0 +1,31 @@
# Build guide for AMO
## Build platform
The extension is built on a PC running Manjaro Linux. npm and node are installed from repositories/aur.
### Software versions:
Node/npm versions:
```
node: %%NODE_VERSION%%
npm: %%NPM_VERSION%%
```
Linux (`uname -a`):
```
%%LINUX_VERSION%%
```
## Reproducing build
Run the following commands to install dependencies and compile the firefox build:
```
npm ci
npm run build
```
The compiled code pops up in `/dist-ff`.

17
README-PERMISSIONS.md Normal file
View File

@ -0,0 +1,17 @@
#Permissions
This extension requires some permissions. Here's why.
#TL;DR version:
* **All tabs** — allows this extension to work on any site (By default, you need to enable sites other than those supported by default manually). Automatic detection on Netflix also [requires this permission](https://discourse.mozilla.org/t/drawwindow-in-webextension/13811) (or at least it did as of January 2018).
* **Access browser tabs** — required for the popup to work (and it still doesn't always).
* **Access browser activity during navigation** — makes some stuff with displaying popup easier. Most notably, it's used to ask the tab you're switching to whether it contains any videos, so this information is known before you need to open the popup.
#Technical mumbo-jumbo
todo
#This extension asks for permission that isn't listed above.
Sometimes (and by 'sometimes' I mean 'way too often') I forget to update README files. If there's a permission that I haven't wrote an explanation for, please [open an issue](https://github.com/tamius-han/ultrawidify/issues).

391
README.md
View File

@ -1,191 +1,284 @@
This is the v1 of the project. This branch is the original source for the extension, which is now obsolete (due to the code rewrite started in october 2017). See main (stable) and v2 (current) branches for something that's still getting maintained.
# Ultrawidify — aspect ratio fixer for youtube and netflix
## Super TL;DR: I'm just looking for the install links, thanks
[Firefox](https://addons.mozilla.org/en/firefox/addon/ultrawidify/), [Chrome](https://chrome.google.com/webstore/detail/ultrawidify/dndehlekllfkaijdlokmmicgnlanfjbi), [Edge](https://microsoftedge.microsoft.com/addons/detail/ultrawidify/lmpgpgechmkkkehkihpiddbcbgibokbi).
There's also [nightly "builds"](https://stuff.lionsarch.tamius.net/ultrawidify/nightly/).
## TL;DR
If you own an ultrawide monitor, you have probably noticed that sometimes videos aren't encoded properly — they feature black bars on all four sides. This could happen because someone was incompetent (note: as far as youtube is concerned, improperly rendered videos might be due to youtube's implementation of certain new features). The extension kinda fixes that by doing this:
![Demo](img-demo/example-httyd2.png "Should these black bars be here? No [...] But an ultrawide user never forgets.")
Works on Youtube and Netflix. Available for [Firefox (v1.2.1)](https://addons.mozilla.org/en/firefox/addon/ultrawidify/) and [Chrome (v1.2.1)](https://chrome.google.com/webstore/detail/ultrawidify/dndehlekllfkaijdlokmmicgnlanfjbi).
## The long version
## Known issues
The technology has been here for a while, but plenty of people don't know how to properly encode a video (despite the fact [youtube has an article that explains aspect ratios](https://support.google.com/youtube/answer/6375112)). Plenty of people surprisingly includes major Holywood studios, such as [Marvel](https://www.youtube.com/watch?v=Ke1Y3P9D0Bc), [Disney](https://www.youtube.com/watch?v=yCOPJi0Urq4), [Dreamworks](https://www.youtube.com/watch?v=oKiYuIsPxYk), [Warner Brothers](https://www.youtube.com/watch?v=VYZ3U1inHA4), [Sony](https://www.youtube.com/watch?v=7BWWWQzTpNU), et cetera. You'd think that this is the one thing Holywood studios and people who make [music videos for a living](https://www.youtube.com/watch?v=c6Mx2mxpaCY) would know how to do right, but they don't. This extension is here to fix that.
* Netflix autodetection not working in Chrome and working poorly in Firefox. This problem happens because DRM, and happens on other sites utilizing DRM protection schemes. Don't expect Chrome support any time soon.
* Everything reported in [issues](https://github.com/tamius-han/ultrawidify/issues)
### Limitations
* Unclear how extension handles sites with more than one video per page.
* Autodetection is only correct 95% of the time, most of the time.
* That new stretching mode wasn't thoroughly tested yet. Issues may be present. (Same with zoom)
* Enabling extension everywhere (as opposed to whitelisted sites) could break some websites.
### Features
* **Can be enabled or disabled on per-site basis**
* **Crop video to fit screen** (no stretching. Supported aspect ratios: 21/9 (1:2.39), 16:9, 16:10. It's possible to set additional aspect ratios, but settings GUI currently contains some mildly annoying bugs)
* **Automatic aspect ratio detection** (can be enabled/disabled entirely or on a per-site basis, separately of the extension. May not work on sites utilizing DRM schemes, such as Netflix et. al.). Autodetection in action: [youtube](https://www.youtube.com/watch?v=j2xn1WpbtCQ))
* **Supports Youtube theater mode**
* **[EXPERIMENTAL!]** Stretch video to fit the screen
* **[EXPERIMENTAL!]** custom zooming and panning
### Officially supported sites
* Youtube
* Netflix
* Twitch
### Other sites
I am not actively testing extension on other sites. You can try your luck and enable extension for any unsupported site you stumble across via extension popup, but I make no guarantees it will work everywhere.
If extension doesn't work for a site I'm not testing on out of the box, follow [this wiki](https://github.com/tamius-han/ultrawidify/wiki/Fixing-site-incompatibilites-('Advanced-settings')). The 'quick and dirty' approach should work for most sites. (If you try doing things the proper way, you should really know what you're doing.)
### Installing this extension
You can download this extension from the relevant extension stores:
* [Firefox](https://addons.mozilla.org/en/firefox/addon/ultrawidify/)
* [Chrome](https://chrome.google.com/webstore/detail/ultrawidify/dndehlekllfkaijdlokmmicgnlanfjbi)
* [Edge](https://microsoftedge.microsoft.com/addons/detail/ultrawidify/lmpgpgechmkkkehkihpiddbcbgibokbi)
Other browsers are not officially supported. If you're using a different Chromium-based browser, you can try installing the addon from the Chrome Web Store — but if things don't work, you're on your own.
### Nightly builds
* Nightly builds can be downloaded [here](https://stuff.lionsarch.tamius.net/ultrawidify/) as an unpacked extension that can
only be installed temporarily.
If I did anything during the day, the nightly version will be sorta-built at whatever my VPS provider thinks is 4AM CE(S)T.
# Beggathon (donations)
If you want to support this project, please consider a donation. Working on this extension takes time, money, coffee and motivation. Sometimes also [a very precise amount of alco](https://xkcd.com/323/).
You can make a donation [via Paypal](https://www.paypal.me/tamius).
**Any donation — no matter how big or small — is well appreciated. Thanks.**
&nbsp;
&nbsp;
&nbsp;
&nbsp;
# The long version
The technology has been here for a while, but plenty of people don't know how to properly encode a video (despite the fact [youtube has an article that explains aspect ratios](https://support.google.com/youtube/answer/6375112)). Plenty of people surprisingly includes major Hollywood studios, such as [Marvel](https://www.youtube.com/watch?v=Ke1Y3P9D0Bc), [Disney](https://www.youtube.com/watch?v=yCOPJi0Urq4), [Dreamworks](https://www.youtube.com/watch?v=oKiYuIsPxYk), [Warner Brothers](https://www.youtube.com/watch?v=VYZ3U1inHA4), [Sony](https://www.youtube.com/watch?v=7BWWWQzTpNU), et cetera. You'd think that this is the one thing Hollywood studios and people who make [music videos for a living](https://www.youtube.com/watch?v=c6Mx2mxpaCY) would know how to do right, but they don't. This extension is here to fix that.
![Jesus Christ.](img-demo/example-jasonbourne.png "This is indeed worse than Snowden.")
## Features
* **Adds UI to the player's controls**
* **Fit video to width/height**
* **Zoom/unzoom video**
* **Force specific aspect ratio**
* **(Attempt to) autodetect aspect ratio** (Netflix only)
* **Rebindable shortcuts**
Most settings are self-explanatory, but we'll get into details anyway.
### User interface
### Limitations:
![UI](img-demo/example-ui-general.png "If I ever found out that the video I'm in is 21:9, but encoded as 16:9 + black bars, I'd probably consider killing myself as well. To be completely fair, Blender institute did good job encoding the video properly. But of course there's some repost channels to fuck it up.")
Before we go on to features, let's discuss limitations.
To be entirely fair to the blender foundation, the video featured above is properly encoded. (However, few accounts that reposted it didn't sport the same levels of competence).
* Currently, this extension is only tested on Youtube and Netflix. It should work on other sites as well, but you'll need to manually enable extension on other sites via the popup.
* It's unclear how extension handles sites displaying multiple videos per site. Having multiple videos on the same page is a very tricky case that hasn't been given much thought.
* Autodetection is a very hard problem to solve. Despite various improvements, it's still not 100% correct. In cases where aspect ratio is hard to determine, extension tends to err on the side of caution and tries to avoid changing aspect ratios. However, sometimes aspect ratio changes will still trigger too eagerly.
The 'more settings' menu contains all the buttons on the control bar, plus an option to force a specific aspect ratio — in case you're trying to watch a 16:9 video, that's encoded as 4:3 video, on a 21:9 monitor.
![UI](img-demo/example-ui-more-settings.png "If you know me and came looking for the obligatory »it's a wyvern, not a dragon« comment ... well, you just found it.")
### Automatic aspect ratio detection
These options might show some benefit for people not using 21:9 monitors, as they would allow you to crop a (proper) 21:9 to 16:9 (remove black bars at the cost of some video). 'Fit to height' would often do the same job, though.
By default, automatic detection will run on every site this extension is enabled for. It does what it says on the tin: it attempts to detect aspect ratio of the video by periodically looking at a video frame.
Some caveats apply:
* autodetection is very easy in 99% of cases and very tricky in the 1%. Sometimes, autodetection will be too eager. Sometimes it won't be eager enough.
* Some sites use DRM. DRM measures are designed specifically to prevent scripts from looking at video frames. Since that's exactly what this extension uses to determine aspect ratio of a video, **autodetection is not possible on sites that use DRM** (Netflix and the likes). Firefox is slight exception to this.
* Firefox offers an API that can be used to take screenshots of the page. Turns out that you can use this API to work around the above limitation. Usage of this API has its own limitations. Due to those limitations, automatic detection on DRM-protected sites in Firefox keeps a thin black bar at the top and the bottom of the video.
Autodetection can be enabled or disabled globally, per site or per video.
### Popup
Most of the extension settings can be accessed and modified via the popup. If extension is enabled for the site you're currently on, the popup will display options for the video you're currently watching.
![Demo](img-demo/ui/popup/popup_video_settings.png)
### Cropping video
![Demo](img-demo/ui/popup/crop.png)
Extension can crop videos to the desired aspect ratio. Options offered by the extension are (keyboard shortcuts in **bold**):
* Automatic — **A**
* Reset (default) — **R**
* 21:9 (2.39:1) — **D**
* 18:9 (2:1) — **X**
* 16:9 (1.77) — **S**
* Custom — **Q**
In addition to that, you can crop video to fit width (**W**) or height (**E**).
**Note:** manually adjusting aspect ratio _disables_ autodetection for current video. Manual adjustments are temporary and should last for only one video.
You can set custom aspect ratio by clicking 'set custom aspect ratio' link under the buttons, changing the value in the box and clicking 'save'. Aspect ratio can be in any of the following formats:
* `width/height` (e.g. `16/9`, `21/9` - even `2560/1080`)
* `1:ratio` (e.g. `1:2.39`. You can omit the `1:` part, too — e.g. `2.39` is equivalent to `1:2.39`)
'Save' button saves your custom aspect ratio. If you don't save changes, they'll be forgotten by the time you close the popup.
![Demo](img-demo/ui/popup/crop_custom.png)
### Zoom
Keys 'Z' and 'U' manually zoom the video. You can use those to zoom farther than merely adjusting aspect ratio would. At high magnification, you can pan the video by moving mouse over it. Panning is off by default and can be activated by holding 'shift' or toggled by pressing 'P' key.
You can also zoom video by using the slider in the popup:
![Demo](img-demo/ui/popup/zoom.png)
### Align video
If you watch 16:9 videos in full screen on a 21:9 monitor, there's obviously going to be black bars on either side of the video. The video will be centered, though. Some people don't want video to be centered in such situations, instead preferring having the video aligned to either side. **Video alignment** option does that.
### Stretching videos
![Demo](img-demo/ui/popup/stretch.png)
When you watch a 16:9 content on a 21:9 monitor, you can deal with this issue in three ways: A) you don't, B) you crop or C) you stretch the 16:9 video to fit a 21:9 container. Obviously not everyone is a person of culture, some people prefer to choose the greater evil of the three: they prefer their videos stretched!
Ultrawidify offers you several ways of dealing with the issue:
* **Never** — don't stretch at all
* **Basic** — stretch the video to fit screen. Doesn't remove black bars encoded in the video. While this option is active, automatic aspect ratio detection is disabled.
* **Hybrid** — this mode first crops away the black bars encoded in the video file. If the video doesn't fit your monitor after being cropped, the extension will proceed to stretch it in a smart way. Automatic detection remains active with this option.
* **Thin borders** — this mode only applies stretching only when borders around video are thin (less than 5% of total width or height).
## Global and per-site default settings
You can change default settings for extension or site you're currently on by visiting 'Extension settings' and 'Site settings' tabs in the popup. Per-site settings override extension defaults, video settings override both. Both tabs also have the same options:
![Demo](img-demo/ui/popup/extension_settings.png)
Quick rundown of the options:
* **Enable this extension** (Extension settings)
Whether the extension is enabled. Options:
`Always` — allow this extension to run on every site (unless the site is blacklisted)
`On whitelisted sites` — allow this extension to run only on sites you manually enabled
`Never` — this extension won't work. At all.
* **Enable autodetection** (Extension settings)
Whether extension should automatically detect aspect ratio. Uses same options as _Enable this extension_ options.
* **Enable this extension** (Site settings)
Whether the extension is enabled on current site. Options:
`Whitelist` — allow this extension to run on current site.
`Default` — follow global settings (allow if global option is set to 'always', don't allow if global option is set to any of the other two)
`Blacklist` — never allow extension to run on current site.
* **Enable autodetection** (Site settings)
Whether extension should automatically detect aspect ratio on current site. Uses same options as _Enable this extension_ options.
* **Default stretching mode**
How, if at all, should extension stretch the video by default.
* **Video alignment**
How to align the video by default.
## Keyboard shortcuts
The keyboard shortcuts have already been listed, but let's list them all again in the same, handy place.
### Default keyboard shortcuts
w - fit to width
e - fit to height
r - reset
z - zoom
u - unzoom
a - attempt to automatically determine the aspect ratio (netflix only)
s - force 21:9
d - force 16:9
x - force 16:10
c - force 4:3
`w` - fit to width
`e` - fit to height
`r` - reset
### About Netflix aspect ratio autodetection
`a` - attempt to automatically determine the aspect ratio
Automatic aspect ratio detection on Netflix works by grabbing the title of the video off Netflix' control bar and throws it at some third party services. First, it takes the title and throws it at OMDB. OMDB replies with IMDB id. We then throw that id at IMDB, which replies with 1700+ lines (and aspect ratio information is hopefully somewhere among them). If OMDB doesn't find the movie — or if the IMDB doesn't have information about aspect ratio for that particular title — automatic detection fails. There's also a posibility that this method returns the wrong data, as there's a possibility that multiple movies share the same title.
`s` - force 16:9
`d` - force 21:9
`x` - force 18:9
`q` - force custom aspect ratio
For best results with autodetection, please make sure the following requirements are met:
`z` - zoom
`u` - unzoom
`p` - toggle video panning
`shift`- pan video (while holding)
### Rebinding keyboard shortcuts
is currently not possible. Settings page for this extension has been disabled sometime with 2.0 release (because it [broke](https://github.com/tamius-han/ultrawidify/issues/16)), and fixing the setting page has been very low priority as I've had more important issues to work on.
However, I do plan on implementing this feature. Hopefully by the end of the year, but given how consistently I've been breaking self-imposed deadlines and goals for this extension don't hold your breath. After all, [Hofstadter's a bitch](https://en.wikipedia.org/wiki/Hofstadter%27s_law).
## Plans for the future
1. Handle porting of extension settings between versions.
2. ~~Reintroduce gradual zoom on z and u and provide a way to 'scroll' the zoomed in video up/down left/right.~~ (v3.2.0)
3. reintroduce settings page (rebindable keys, blacklist/whitelist management, some settings for automatic aspect ratio detection)
4. site-specific options for sites that require additional CSS classes or other hacks
5. figure the best way to do GUI (injecting buttons into the player bar is not a good way. Been there, done that, each site has its own way and some appear to be impossible). ~~Might get bumped to be released alongside #2~~no it wont lol
6. Improvements to automatic aspect ratio detection
* Netflix, not youtube
* Netflix must be in English
* Movie title must be in English/the original title
* Movie must be known by OMDB
* Movie must have aspect ratio info on IMDB
## Installing
### Permanent install / stable
[v1.2.1 — Regular version — download from AMO](https://addons.mozilla.org/en/firefox/addon/ultrawidify/)
[Latest stable for Firefox — download from AMO](https://addons.mozilla.org/en/firefox/addon/ultrawidify/)
[v1.2.1 — Regular version — download from Chrome store](https://chrome.google.com/webstore/detail/ultrawidify/dndehlekllfkaijdlokmmicgnlanfjbi)
[Latest stable for Chrome — download from Chrome store](https://chrome.google.com/webstore/detail/ultrawidify/dndehlekllfkaijdlokmmicgnlanfjbi)
Edge version is currently not available, as Edge has some bugs that prevent this extension from working correctly. [Read more](https://github.com/tamius-han/ultrawidify/issues/117#issuecomment-747109695)
<!-- [Latest stable for Edge — Download from Microsoft store](https://microsoftedge.microsoft.com/addons/detail/lmpgpgechmkkkehkihpiddbcbgibokbi) -->
### Installing the current, github version
## Get pre-built version:
TODO
## Build from source
Requirements: npm, node.
1. Clone this repo
2. Open up Firefox
3. Go to `about:debugging`
2. run `npm install`
3. If using **Firefox,** run: `npm run watch:dev`. If using **Chrome,** run: `npm run watch-chrome:dev`.
TODO: see if #3 already loads the extension in FF
2. Open up Firefox (or Chrome)
3. Go to `about:debugging` (or Chrome equivalent)
4. Add temporary addon
5. Browse to wherever you saved it and select manifest.json
5. Select `${ultrawidify_folder}/dist/manifest.json`
## Known issues (in stable versions)
# Changelog
'More settings' button actually doesn't work at the moment.
see changelog.md
## Plans for the future
* ~~Adding custom keybinds~~ (done at lastest)
* ~~Adding a proper settings page~~ (done at last)
* ~~Adding buttons for actions in youtube's player~~ (kinda done)
* ~~Adding an option to force specific aspect ratio~~ (now it's "good enough")
* ~~Port to Chrome~~
* ~~Have extension remember the last setting when switching between fullscreen and not fullscreen.~~ (kinda done)
* Have an option to remember last selected aspect ratio.
* Option to hide UI
* ~~Netflix support~~ (done)
## Changelog
###v1.3a1 (git/current version)
* Adding ability to add custom sites (in progress)
* Most of the extension is being completely rewritten to accomodate that feature, which means there's a serious regression with Netflix support (no netflix at the moment)
* I'm also trying to break the 1500 line behemoth into smaller files.
###v1.2.1 (AMO + Chrome)
* Fixed the bugs which caused aspect ratio to not be calculated properly.
* Introduced further changes that allow me to not keep two separate version for Firefox and Chrome.
###v1.2.0
* Auto-aspect ratio detection on netflix
* initial port to Chrome
###v1.1.1
* Fixed zooming issue on netflix
* Ultrawidify shortcuts > youtube/netflix shortcuts
* Fixed 'settings' page
* Fixed 'settings' (wrench button) popup on youtube (it was broken by one of the previous updates)
###v1.1.0
* Introduced Netflix support.
As Netflix relies on extension re-initializing at least the UI ***a lot***, the optimization introduced in 1.0.2 was reversed (as waiting 2 seconds for the UI to appear is just too much).
Furthermore, triggering UI re-initialisation on onUpdated events turned out to not be the proper way to go: immediately after the extension is initialized, onUpdated gets triggered even more often than your average Buzzfeed writer/reader. But change the episode on Netflix and suddenly, onUpdated gets barely triggered at all — which means that more often than not, the UI extension injects into the page wasn't visible. (the fuck, really)
This is why Netflix uses another function that manually checks whether the player bar is present. Ideally that check happens every tenth of a second, but Firefox may be limiting that to one per second.
###v1.0.2
The 'extension sometimes not working' bug was fixed (by having extension try to setup every time a page got updated), but the fix had some problems. Namely, the extension would re-initiate (complete with re-adding the entire UI) itself very _very_ often.
This could be a problem, so it was fixed. Extension is notified of updates only every ~2 seconds (which absorbs most of the "page was updated" events on page load) and doesn't attempt to reload the UI if the UI was already loaded. (Unless `debugmsg` is set to true. It's generally not, but any commits to this repo could potentially still have it enabled).
###v1.0.1
Fixed the bug where sometimes the extension would fail to work. (example: you opened youtube's search page in a brand new tab. You then opened a video from the search results (_not_ in a new tab). Extension wouldn't work at all in videos opened in that manner).
###v1.0.0
* Is pretty much rc1, except slightly different background image.
###v1.0-rc1
* Settings page is added and mostly working.
###v0.9.9.6
* The issue with buttons not fitting in the control bar was resolved.
###v0.9.9.5
* Played with settings and localstorage a bit, but no clear implementation yet.
* Fixed some bugs caused by event propagation.
* All buttons in the player's control bar are now also in the settings popup.
* Had to scrap settings page in its current form
* TODO: sometimes not all buttons can fit in the control bar. Such occurences should be detected.
###v0.9.9.1
* Keybinds `a` and `w` now work.
* Some changes under the bonnet, mostly regarding the way keypresses are handled.
* 'Settings' page is ~15% done.
###v0.9.9
* The aspect ratio thingy is now also in GUI
* Fixed code for forcing aspect ratio. At least I think it's fixed now.
###v0.9.8
* Added GUI/buttons on the player.
* Script now only loads on youtube pages (iframes included) (before, this script would run on any page)
###v0.9.7
* No new features added. Version number got incremented due to an attempt at autoupdating (which got foiled due to lack of HTTPS)
###v0.9.6
* Added experimental feature that tries to force an aspect ratio
###v0.9.1
* First version on GitHub (and on AMO) with basic features (zoom, fit to width, fit to height)
todo: add link to changelog.md here

View File

@ -1,84 +0,0 @@
#!/bin/bash
# Takes all the files from 'src' and compiles it intro a single content script.
# Also compiles background scripts and settings pages.
#
# I'm using this over something like requirejs so my extension doesn't need even more
# dependencies.
#
# How does this work?
# 0. You're supposed to run this in the root directory of the extension.
# 1. see if file has any #include [filename] comments. If so, merge [filename] file
# into the current file (after checking if that file has any #include comments
# Compiled files are saved to /tmp.
#
# 2. After compiling file and its dependencies, check for presence of #location [directory]
# comments. [directory] is relative to the root directory of the extension
# 2.1 also check for #out, which defines filename.
#
# 3. Use '-nodebug' to remove all calls of console.log (to be implemented)
function flattenFileName {
echo $1 | sed 's/\//_/g'
}
fileList="";
function compileFile {
local file=$1
local flatfile=$(flattenFileName $file);
if [ -f /tmp/$flatfile ] ; then
return 0
fi;
fileList="$fileList $flatfile"
# let's take all the #included files and put them at the top
for f in $(grep "#include" $file | awk '{print $NF}') ; do
local lf=$f
fflat=$(flattenFileName $lf);
compileFile $lf
printf "\n//BEGIN included from $lf\n" >> /tmp/$flatfile
grep -Ev "#include|#location|#out" /tmp/$fflat >> /tmp/$flatfile
printf "//END included from $lf\n\n" >> /tmp/$flatfile
done
grep -Ev "#include|#location|#out" $file >> /tmp/$flatfile
}
cd src;
for file in *.js ; do
echo "main loop, we're looking at this file: $file"
compileFile $file
echo "Files compiled. Moving to location (if specified)"
outFile=$file
if grep -q "#out" $file ; then
outFile=$( grep "#out" $file | awk '{print $NF}')
fi
if grep -q "#location" $file ; then
location=$( grep "#location" $file | awk '{print $NF}')
echo "File will be saved to $location as $outFile"
cd ..
echo "// Autogenerated using buildext. This file should not be modified — modify source files instead." > $location/$outFile
grep -Ev "#location|#include|#out" /tmp/$(flattenFileName $file) >> $location/$outFile
cd src
fi
done
# perform cleanup
for file in $fileList ; do
rm /tmp/$file
done

BIN
img-demo/ui-popup-0.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 136 KiB

BIN
img-demo/ui/popup/crop.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.1 KiB

BIN
img-demo/ui/popup/zoom.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.0 KiB

10220
js/jquery-3.1.1.js vendored

File diff suppressed because it is too large Load Diff

View File

@ -1,181 +0,0 @@
var browser_autodetect = true;
var usebrowser = "chrome";
debugmsg = false;
debugmsg_imdb = false;
url_changed = false;
if(debugmsg){
console.log(". . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ");
console.log("\nLoading ultrawidify background script (uw-bg)\nIf you can see this, extension at least tried to load\n\nRandom number: ",Math.floor(Math.random() * 20) + 1,"\n");
console.log(". . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ");
}
if(browser_autodetect){
if(typeof browser === "undefined"){ // This means we're probably not on Firefox, but on nazi chrome
if(chrome){
browser = chrome;
usebrowser = "chrome";
}
}
else
usebrowser = "firefox";
}
else{
if(usebrowser == "chrome")
browser = chrome;
}
/********************************************
**** script-related stuff starts here ****
********************************************/
function gibActiveTab(){
return browser.tabs.query({active: true, currentWindow: true});
}
var page_change_msg_count = 0;
function notifyChange(){
if(debugmsg)
console.log("uw-bg::tab updated. seq:", page_change_msg_count++);
browser.tabs.query({active: true, currentWindow: true}, function(tabs){
browser.tabs.sendMessage(tabs[0].id, {message: "page-change"});
});
}
browser.tabs.onUpdated.addListener(notifyChange);
//BEGIN Goldberg machine that gets aspect ratio data off imdb
function getAspectRatio(title, sender_tab){
// presledki morajo biti zamenjani s +
// spaces need to be replaced with +
var rektitle = title.replace(/ /g, '+');
// Zdaj lahko pošljemo zahtevek na omdbapi
// now we can send a request to omdbapi
httpGET("http://www.omdbapi.com/?t=" + rektitle,
function(response, sender_tab) {
if(debugmsg || debugmsg_imdb)
console.log("uw-bg::getAspectRatio | omdbapi gave us this: ", response);
var info = JSON.parse(response);
if(!info || !info.Title)
return;
if(debugmsg || debugmsg_imdb){
console.log("uw-bg::getAspectRatio | movie title: »»", info.Title, "«« | imdb ID:", info.imdbID,"\nTrying to get technical specs off IMDB");
}
httpGET("https://www.imdb.com/title/" + info.imdbID + "/technical",
function(response, sender_tab){
if(!response)
return;
var lines = response.split('\n');
if(debugmsg || debugmsg_imdb){
console.log("uw-bg::getAspectRatio | we just got something off IMDB, it's",lines.length,"long. Here's what we got:\n",response);
}
// IMDB nam zraven da veliko nepotrebnega sranja. Na testni strani je bil relevanten podatek
// 700+ (!) vrstic globoko. Stvar, ki nam jo da IMDB ima 1500+ vrstic. Iskanje bomo zato začeli
// od sredine
//
// IMDB gives us a lot of unnecessary shit along with the data we want. On our test page the
// relevant data was buried 700+ lines deep (1500+ lines total). Because we don't want to
// pointlessly search half the page, the best place to start seems to be the middle.
var lines_nr = lines.length;
if(lines_nr % 2 == 1)
++lines_nr;
var i = lines_nr / 2;
var j = i;
var ar_found = 0;
while(i > 400 && j < lines_nr){
if(lines[i].indexOf("Aspect Ratio") != -1){
if(debugmsg || debugmsg_imdb)
console.log("uw-bg::getAspectRatio | »Aspect Ratio« has been found on line",i," — searching for aspect ratio ...");
ar_found = i;
break;
}
if(lines[j].indexOf("Aspect Ratio") != -1){
if(debugmsg || debugmsg_imdb)
console.log("uw-bg::getAspectRatio | »Aspect Ratio« has been found on line",j," — searching for aspect ratio ...");
ar_found = j;
break;
}
--i;
++j;
}
if(ar_found){
var ar_limit = ar_found + 5;
for(var i = ar_found; i < ar_limit; ++i){
if(debugmsg || debugmsg_imdb)
console.log("uw-bg::getAspectRatio | scanning lines for aspect ratio number. Line:",lines[i],"has ar:", lines[i].indexOf(":"));
if(lines[i].indexOf(":") != -1){
// To pomeni, da smo našli razmerje stranic. gg ez
// This means we found our aspect ratio, gg ez
var ar = lines[i].trim().split(":");
ar[0] = ar[0].trim();
ar[1] = ar[1].trim();
if(debugmsg || debugmsg_imdb)
console.log("uw-bg::getAspectRatio | Aspect ratio found:",ar[0],":",ar[1]);
// Pa povejmo to naši strani:
// Let's break the news:
browser.tabs.sendMessage(sender_tab.id, {type:"arInfo", arx:ar[0], ary:ar[1]});
}
}
}
else
if(debugmsg || debugmsg_imdb)
console.log("uw-bg::getAspectRatio | Aspect ratio hasn't been found");
},
sender_tab
); //httpGET end
},
sender_tab
); //httpGET end
}
function httpGET(url, callback, callback_args){
var rek = new XMLHttpRequest();
rek.onreadystatechange = function(){
if(rek.readyState == 4 && rek.status == 200){
callback(rek.responseText, callback_args);
}
}
rek.open("GET", url, true);
rek.send(null);
}
//END 3rd party snooping for aspect ratios
browser.runtime.onMessage.addListener(function(request, sender, sendResponse) {
//Stvari delamo samo, če ima naše sporočilce tip
//We only do stuff if our message has a type
if(request.type){
if(request.type == "debug"){
console.log("uw-bg::onMessage | got a message. It was a debugging message. Here's the full message:",request);
}
if(request.type == "gibAspectRatio"){
if(debugmsg || debugmsg_imdb)
console.log("uw-bg::onMessage | got a message, we want to set aspect ratio. message:",request,"sender:",sender);
var result = getAspectRatio(request.title, sender.tab);
}
}
});

2125
js/uw.js

File diff suppressed because it is too large Load Diff

View File

@ -1,50 +0,0 @@
{
"manifest_version": 2,
"name": "Ultrawidify-git",
"version": "1.3a1",
"icons": {
"32":"res/icons/uw-32.png",
"64":"res/icons/uw-64.png"
},
"description": "Aspect ratio fixer for youtube that works around some people's disability to properly encode 21:9 (and sometimes, 16:9) videos.",
"content_scripts": [
{
"matches": ["*://*/*"],
"js": [ "js/jquery-3.1.1.js", "js/uw_libbuttons.js", "js/uw.js" ],
"all_frames": true
}
],
"background": {
"scripts": ["js/jquery-3.1.1.js", "js/uw-bg.js"]
},
"permissions": [
"tabs", "storage", "activeTab", "*://*.youtube.com/*", "*://youtube.com/*", "*://imdb.com/*", "*://*.imdb.com/*"
],
"web_accessible_resources": [
"res/img/ytplayer-icons/zoom.png",
"res/img/ytplayer-icons/unzoom.png",
"res/img/ytplayer-icons/fitw.png",
"res/img/ytplayer-icons/fith.png",
"res/img/ytplayer-icons/reset.png",
"res/img/ytplayer-icons/settings.png",
"res/img/settings/about-bg.png",
"res/css/uw_common.css",
"res/css/uw_yt.css",
"res/css/uw_netflix.css",
"res/css/uw_settings.css"
],
"options_ui" : {
"page": "res/settings.html",
"open_in_tab": true
}
}

16616
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

78
package.json Normal file
View File

@ -0,0 +1,78 @@
{
"name": "ultrawidify",
"version": "6.0.2",
"description": "Aspect ratio fixer for youtube and other sites, with automatic aspect ratio detection. Supports ultrawide and other ratios.",
"author": "Tamius Han <tamius.han@gmail.com>",
"scripts": {
"build": "npm run pre-build; cross-env NODE_ENV=production BROWSER=firefox CHANNEL=stable webpack --hide-modules",
"build-all": "bash ./scripts/build-all.sh",
"build-chrome": "cross-env NODE_ENV=production BROWSER=chrome CHANNEL=stable webpack --hide-modules",
"build-chrome:dev": "cross-env NODE_ENV=development BROWSER=chrome webpack --hide-modules",
"build-edge": "cross-env NODE_ENV=production BROWSER=edge CHANNEL=stable webpack --hide-modules",
"build-nightly": "cross-env NODE_ENV=development BROWSER=firefox CHANNEL=nightly webpack --hide-modules",
"build-nightly-chrome": "cross-env NODE_ENV=development BROWSER=chrome CHANNEL=nightly webpack --hide-modules",
"build-testing": "cross-env NODE_ENV=development BROWSER=firefox CHANNEL=testing webpack --hide-modules",
"build-testing-chrome": "cross-env NODE_ENV=development BROWSER=chrome CHANNEL=testing webpack --hide-modules",
"build-zip": "node scripts/build-zip.js",
"build:dev": "webpack --hide-modules",
"dev": "cross-env NODE_ENV=development CHANNEL=dev concurrently \"cross-env BROWSER=firefox npm run build:dev -- --watch\" \"cross-env BROWSER=chrome npm run build:dev -- --watch\" \"cross-env BROWSER=edge npm run build:dev -- --watch\"",
"dev:windows": "cross-env NODE_ENV=development CHANNEL=dev concurrently \"cross-env BROWSER=firefox npm run build:dev -- -w --watch-poll\" \"cross-env BROWSER=chrome npm run build:dev -- -w --watch-poll\" \"cross-env BROWSER=edge npm run build:dev -- -w --watch-poll\"",
"dev-ff": "rm -rf ./dist-ff && cross-env NODE_ENV=development CHANNEL=dev BROWSER=firefox npm run build:dev -- --watch",
"dev-chrome": "rm -rf ./dist-chrome && cross-env NODE_ENV=development CHANNEL=dev BROWSER=chrome npm run build:dev -- --watch",
"dev-edge": "rm -rf ./dist-edge && cross-env NODE_ENV=development CHANNEL=dev BROWSER=edge npm run build:dev -- --watch",
"pre-build": "rm -rf ./dist-ff; rm -rf ./dist-chrome; rm -rf ./dist-edge; rm -rf ./node_modules; npm ci",
"start": "npm run dev",
"start:windows": "npm run dev:windows"
},
"dependencies": {
"@babel/plugin-proposal-class-properties": "^7.16.0",
"@mdi/font": "^6.5.95",
"@mdi/js": "^6.4.95",
"@types/resize-observer-browser": "^0.1.6",
"concurrently": "^5.3.0",
"fs-extra": "^7.0.1",
"gl-matrix": "^3.4.3",
"json-cyclic": "0.0.3",
"lodash": "^4.17.21",
"mdi-vue": "^3.0.11",
"typescript": "^4.4.4",
"vue": "^3.2.21",
"vue-style-loader": "^4.1.3",
"vuex": "^4.0.2",
"vuex-webextensions": "^1.3.3",
"webextension-polyfill": "^0.12.0"
},
"devDependencies": {
"@babel/core": "^7.16.0",
"@babel/preset-env": "^7.16.0",
"@types/chrome": "0.0.240",
"@types/core-js": "^2.5.5",
"@types/es6-promise": "^3.3.0",
"@types/firefox": "0.0.31",
"@types/lodash": "^4.14.176",
"@types/node": "^14.17.32",
"@vue/cli": "^4.5.15",
"@vue/cli-plugin-typescript": "^4.5.15",
"@vue/compiler-sfc": "^3.2.21",
"archiver": "^3.0.0",
"babel-loader": "^8.2.3",
"babel-preset-es2020": "^1.0.2",
"copy-webpack-plugin": "^4.5.3",
"cross-env": "^5.2.0",
"css-loader": "^0.28.11",
"ejs": "^2.7.4",
"file-loader": "^1.1.11",
"mini-css-extract-plugin": "^0.4.4",
"node-sass": "^4.14.1",
"resolve-url-loader": "^5.0.0",
"sass-loader": "^7.1.0",
"ts-loader": "^8.3.0",
"vue-cli-plugin-vue-next": "~0.1.4",
"vue-loader": "^16.8.2",
"web-ext-types": "^2.3.0",
"webpack": "^4.46.0",
"webpack-chrome-extension-reloader": "^0.8.3",
"webpack-cli": "^3.3.12",
"webpack-shell-plugin": "^0.5.0"
}
}

View File

@ -1,57 +0,0 @@
@import url('https://fonts.googleapis.com/css?family=Oxygen:300,400&subset=latin-ext');
.show{
display: block !important;
}
.uw_hide{
display: none !important;
}
.uw_submenu{
display: none;
position: absolute;
background-color: rgba(0,0,0,0.66);
}
/*
.uw-setmenu{
padding-left: 2em !important;
padding-right: 2em !important;
}*/
.uw_submenu_bottom0{
bottom: 0px;
}
.display_relative{
display: relative;
}
.uw-setmenu-item{
padding-right: 2em !important;
padding-left: 2em !important;
}
.common_anchor {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
overflow: hidden;
}
.uw_button{
display: inline-block;
/* height: 100% !important; */
background-size: 75% 75%;
background-repeat: no-repeat;
background-position: center center;
}
.uw_ui_anchor{
display: inline-block;
}
#uw_ui_anchor{
display: inline-block;
}

View File

@ -1,39 +0,0 @@
.uw-button{
display: inline-block;
/* height: 100% !important; */
background-size: 75% 75%;
background-repeat: no-repeat;
background-position: center center;
}
.uw-button-row {
display: inline-block !important;
position: absolute !important;
top: 0 !important;
right: 0 !important;
width: 99% !important;
height: 100% !important;
z-index: 1337 !important;
text-align: right;
}
.uw-button:hover{
background-color: rgba(192,0,0,0.66);
}
.uw-setmenu{
display: none;
position: absolute;
background-color: rgba(0,0,0,0.66);
right: 0px;
}
.uw-setmenu-item{
display: flex;
align-items: center;
font-family: "Oxygen";
color: #ffffff !important;
width: 90%;
padding-left: 10%;
}
.uw-setmenu-item:hover{
background-color: rgba(192,0,0,0.66);
}

View File

@ -1 +0,0 @@
/* yeah this is also a placeholder file, this time for 'settings' page */

View File

@ -1,28 +0,0 @@
.uw-button{
display: inline-block;
height: 100% !important;
background-size: 75% 75%;
background-repeat: no-repeat;
background-position: center center;
}
.uw-button:hover{
background-color: rgba(192,0,0,0.66);
}
.uw-setmenu{
display: none;
position: absolute;
background-color: rgba(0,0,0,0.66);
right: 0px;
}
.uw-setmenu-item{
display: flex;
align-items: center;
font-family: "Oxygen";
color: #ffffff !important;
}
.uw-setmenu-item:hover{
background-color: rgba(192,0,0,0.66);
}
.uw_top{
z-index: 1337;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 317 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 783 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.6 KiB

View File

@ -1,387 +0,0 @@
<html>
<head>
<title>Ultrawidify :: settings</title>
<meta charset="UTF-8">
<base target="_blank">
<style>
@import url('https://fonts.googleapis.com/css?family=Oxygen:300,400&subset=latin-ext');
body{
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAMAAAAp4XiDAAAAUVBMVEWFhYWDg4N3d3dtbW17e3t1dXWBgYGHh4d5eXlzc3OLi4ubm5uVlZWPj4+NjY19fX2JiYl/f39ra2uRkZGZmZlpaWmXl5dvb29xcXGTk5NnZ2c8TV1mAAAAG3RSTlNAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEAvEOwtAAAFVklEQVR4XpWWB67c2BUFb3g557T/hRo9/WUMZHlgr4Bg8Z4qQgQJlHI4A8SzFVrapvmTF9O7dmYRFZ60YiBhJRCgh1FYhiLAmdvX0CzTOpNE77ME0Zty/nWWzchDtiqrmQDeuv3powQ5ta2eN0FY0InkqDD73lT9c9lEzwUNqgFHs9VQce3TVClFCQrSTfOiYkVJQBmpbq2L6iZavPnAPcoU0dSw0SUTqz/GtrGuXfbyyBniKykOWQWGqwwMA7QiYAxi+IlPdqo+hYHnUt5ZPfnsHJyNiDtnpJyayNBkF6cWoYGAMY92U2hXHF/C1M8uP/ZtYdiuj26UdAdQQSXQErwSOMzt/XWRWAz5GuSBIkwG1H3FabJ2OsUOUhGC6tK4EMtJO0ttC6IBD3kM0ve0tJwMdSfjZo+EEISaeTr9P3wYrGjXqyC1krcKdhMpxEnt5JetoulscpyzhXN5FRpuPHvbeQaKxFAEB6EN+cYN6xD7RYGpXpNndMmZgM5Dcs3YSNFDHUo2LGfZuukSWyUYirJAdYbF3MfqEKmjM+I2EfhA94iG3L7uKrR+GdWD73ydlIB+6hgref1QTlmgmbM3/LeX5GI1Ux1RWpgxpLuZ2+I+IjzZ8wqE4nilvQdkUdfhzI5QDWy+kw5Wgg2pGpeEVeCCA7b85BO3F9DzxB3cdqvBzWcmzbyMiqhzuYqtHRVG2y4x+KOlnyqla8AoWWpuBoYRxzXrfKuILl6SfiWCbjxoZJUaCBj1CjH7GIaDbc9kqBY3W/Rgjda1iqQcOJu2WW+76pZC9QG7M00dffe9hNnseupFL53r8F7YHSwJWUKP2q+k7RdsxyOB11n0xtOvnW4irMMFNV4H0uqwS5ExsmP9AxbDTc9JwgneAT5vTiUSm1E7BSflSt3bfa1tv8Di3R8n3Af7MNWzs49hmauE2wP+ttrq+AsWpFG2awvsuOqbipWHgtuvuaAE+A1Z/7gC9hesnr+7wqCwG8c5yAg3AL1fm8T9AZtp/bbJGwl1pNrE7RuOX7PeMRUERVaPpEs+yqeoSmuOlokqw49pgomjLeh7icHNlG19yjs6XXOMedYm5xH2YxpV2tc0Ro2jJfxC50ApuxGob7lMsxfTbeUv07TyYxpeLucEH1gNd4IKH2LAg5TdVhlCafZvpskfncCfx8pOhJzd76bJWeYFnFciwcYfubRc12Ip/ppIhA1/mSZ/RxjFDrJC5xifFjJpY2Xl5zXdguFqYyTR1zSp1Y9p+tktDYYSNflcxI0iyO4TPBdlRcpeqjK/piF5bklq77VSEaA+z8qmJTFzIWiitbnzR794USKBUaT0NTEsVjZqLaFVqJoPN9ODG70IPbfBHKK+/q/AWR0tJzYHRULOa4MP+W/HfGadZUbfw177G7j/OGbIs8TahLyynl4X4RinF793Oz+BU0saXtUHrVBFT/DnA3ctNPoGbs4hRIjTok8i+algT1lTHi4SxFvONKNrgQFAq2/gFnWMXgwffgYMJpiKYkmW3tTg3ZQ9Jq+f8XN+A5eeUKHWvJWJ2sgJ1Sop+wwhqFVijqWaJhwtD8MNlSBeWNNWTa5Z5kPZw5+LbVT99wqTdx29lMUH4OIG/D86ruKEauBjvH5xy6um/Sfj7ei6UUVk4AIl3MyD4MSSTOFgSwsH/QJWaQ5as7ZcmgBZkzjjU1UrQ74ci1gWBCSGHtuV1H2mhSnO3Wp/3fEV5a+4wz//6qy8JxjZsmxxy5+4w9CDNJY09T072iKG0EnOS0arEYgXqYnXcYHwjTtUNAcMelOd4xpkoqiTYICWFq0JSiPfPDQdnt+4/wuqcXY47QILbgAAAABJRU5ErkJggg==);
background-size: 75px;
background-color: #000000;
color: #ddd;
font-family: 'Oxygen', serif;
font-size: 1.2em;
width: 100%;
border: 0px;
margin: 0px;
padding: 0px;
text-align: center;
z-index: -1000;
}
a, a:visited{
color: #fa6607;
text-decoration: none;
}
a:hover{
color: #fa6;
}
.show{
display: block !important;
}
.hide{
display: none !important;
}
head{
width: 100%;
border: 0px;
margin: 0px;
padding: 0px;
}
h1,h2{
color: #ff9;
font-weight: 300;
}
h1{
font-size: 3.3em;
}
h2{
font-size: 2.2em;
}
.sites_header{
font-size: 1.6em;
color: #ff9;
}
.content{
display: inline-block;
width: 52em;
}
.center{
margin: 0 auto;
}
.basecolor: {
color: #ddd !important;
}
.red{
color: #ff3a00;
}
.disabled: {
opacity: 0.69;
}
.left{
text-align: left;
}
.block{
display: inline-block;
margin-left: 1em;
margin-right: 1em;
}
.tabline{
background-color: #000;
width: 100%;
margin-bottom: 1.5em;
padding-top: 0.3em;
padding-bottom: 0.4em;
z-index: -200;
}
.tab{
color: #fa6607;
}
.tab:hover{
text-shadow: #aa5 0px 0px 0.02em,#aa5 0px 0px 0.02em;
}
.tab-selected {
color: #ff9 !important;
}
#all{
min-width: 100%;
min-height: 100vh;
background-image: url('img/settings/about-bg.png');
background-position: calc(50vw + 20em) 10vh;
background-attachment: fixed;
background-size: auto 100%;
background-repeat: no-repeat;
}
.dup_keybinds{
background-color: #720 !important;
}
input[type=text]{
font-size: 1em;
padding-left: 0.6em;
margin-left: 1em;
width: 2em;
background-color: #000;
border: 1px #442 solid;
}
.uw_shortcuts_line{
padding-top: 0.25em;
padding-left: 5em;
}
.uw_shortcuts_label{
display: inline-block;
color: #fff;
width: 17.5em;
}
.uw_options_line{
margin-top: 0.75em;
font-size: 1.1em;
width: 80%;
margin-left: 5%;
}
.uw_options_option{
margin-left: 5%;
}
.uw_suboption{
margin-left: 5em;
margin-top: 0.75em;
font-size: 0.85em;
}
.uw_options_desc, .uw_suboption_desc{
margin-top: 0.33em;
font-size: 0.69em;
color: #aaa;
}
.uw_suboption_desc{
margin-left: 5em;
}
.buttonbar{
/* width: 100%; */
padding-left: 20em;
margin-bottom: 2em;
}
.button{
display: inline-block;
margin-left: 1em;
margin-right: 1em;
padding-left: 1em;
padding-right: 1em;
padding-top: 0.4em;
width: 4em;
text-align: center;
background-color: rgba(0,0,0,0.66);
color: #ffc;
height: 1.7em;
}optionsoptions
Shortcuts
About
Official
Shortcuts
About
Official
/** site options css **/
.site_name {
padding-left: 1em;
padding-bottom: 0.3em;
color: #fff;
font-size: 1.1em;
height: 13em !important;
}
.site_details {
font-size: 0.8em;
}
.site_title_ebox {
width: 10em !important;
font-size: 1.5em !important;
background-color: rgba(0,0,0,0) !important;
margin-left: 0px !important;
border: 0px !important;
color: #ffc !important;
}
.details_ebox {
width: 12em !important;
background-color: rgba(0,0,0,0) !important;
border: 0px !important;
color: #ffc !important;
margin-left: 0em !important;
}
.details_ebox:disabled {
color: #aaa !important;
}
.inline_button {
display: inline-block;
margin-top: -1.42em;
}
.inline_button:hover {
color: #fff;
}
</style>
</head>
<body>
<div id="all">
<header>
<div class="content center">
<div class="left">
<h1>Ultrawidify :: settings</h1>
</div>
</div>
<div class="tabline center">
<div class="content left">
<div id="tab_general_settings" class="block tab tab-selected">General settings</div>
<div id="tab_sites" class="block tab">Site options</div>
<div id="tab_shortcuts" class="block tab">Shortcuts</div>
<div id="tab_about" class="block tab">About</div>
</div>
</div>
</header>
<div id="general_settings">
<div class="content left">
<div class="uw_options_line">
<div class="uw_options_option"><input type="checkbox" id='enable_autoar'> Enable automatic aspect ratio detection</div>
<div class="uw_options_desc">This option uses 3rd party websites to determine aspect ratio. It may not work all the time or even properly. It only works with Netflix. <span class="red">This option is <b>NOT</b> available on Youtube.</span></div>
</div>
<div class="uw_options_line">
<div class="uw_options_option"><input type="checkbox" id="enable_ui"> Show UI in the player bar</div>
<div class="uw_options_desc">If this option is enabled, the extension will add some extra buttons to the player bar. If this option is disabled, setting video fit and aspect ratio is only possible via keyboard shortcuts.</div>
<div class="uw_suboption_line" id="compact_ui_suboption">
<div class="uw_suboption"><input type="checkbox" id="enable_ui_compact"> If possible, use compact UI</div>
<div class="uw_suboption_desc">With this option enabled, only 'more settings' button is enabled. Note that this option doesn't work on every site.</div>
</div>
</div>
</div>
</div>
<div id="uw_sites" class="hide">
<div id="uw_sites_body" class="content left">
</div>
</div>
<div id="uw_shortcuts" class="hide">
<div class="content left">
<form>
<!-- BEGIN FORM -->
<!-- fit width -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Fit to width</div>
<input type='checkbox' id='fitw_ctrl' > Ctrl +
<input type='checkbox' id='fitw_shift' > Shift +
<input type='checkbox' id='fitw_alt' > Alt +
<input type='text' id='fitw_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- fit height -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Fit to height</div>
<input type='checkbox' id='fith_ctrl' > Ctrl +
<input type='checkbox' id='fith_shift' > Shift +
<input type='checkbox' id='fith_alt' > Alt +
<input type='text' id='fith_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- reset -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Reset</div>
<input type='checkbox' id='reset_ctrl' > Ctrl +
<input type='checkbox' id='reset_shift' > Shift +
<input type='checkbox' id='reset_alt' > Alt +
<input type='text' id='reset_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- zoom -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Zoom</div>
<input type='checkbox' id='zoom_ctrl' > Ctrl +
<input type='checkbox' id='zoom_shift' > Shift +
<input type='checkbox' id='zoom_alt' > Alt +
<input type='text' id='zoom_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- unzoom -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Unzoom</div>
<input type='checkbox' id='unzoom_ctrl' > Ctrl +
<input type='checkbox' id='unzoom_shift' > Shift +
<input type='checkbox' id='unzoom_alt' > Alt +
<input type='text' id='unzoom_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- force 21:9 -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Force 21:9</div>
<input type='checkbox' id='ar219_ctrl' > Ctrl +
<input type='checkbox' id='ar219_shift' > Shift +
<input type='checkbox' id='ar219_alt' > Alt +
<input type='text' id='ar219_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- force 16:9 -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Force 16:9</div>
<input type='checkbox' id='ar169_ctrl' > Ctrl +
<input type='checkbox' id='ar169_shift' > Shift +
<input type='checkbox' id='ar169_alt' > Alt +
<input type='text' id='ar169_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- force 16:10 -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Force 16:10</div>
<input type='checkbox' id='ar1610_ctrl' > Ctrl +
<input type='checkbox' id='ar1610_shift' > Shift +
<input type='checkbox' id='ar1610_alt' > Alt +
<input type='text' id='ar1610_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- force 4:3 -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Force 4:3</div>
<input type='checkbox' id='ar43_ctrl' > Ctrl +
<input type='checkbox' id='ar43_shift' > Shift +
<input type='checkbox' id='ar43_alt' > Alt +
<input type='text' id='ar43_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- try autoar -->
<div class="uw_shortcuts_line">
<div class="uw_shortcuts_label">Autodetect aspect ratio (Netflix only)</div>
<input type='checkbox' id='autoar_ctrl' > Ctrl +
<input type='checkbox' id='autoar_shift' > Shift +
<input type='checkbox' id='autoar_alt' > Alt +
<input type='text' id='autoar_letter' maxlength='1' class='shortcut_input'>
</div>
<!-- END FORM -->
</form>
<div class="buttonbar"><div class="button" id="kb_cancel">Cancel</div><div class="button" id="kb_save">Save</div></div>
<div id="errbox"></div>
<div><small><b>Note:</b> keyboard shortcut conflicts aren't handled by this extension. You must know your shortcuts.<br/><b>Pro tip:</b> If you don't want to have a keybind for a shortcut, just uncheck all boxes for the action and remove the letter</small></div>
</div>
</div>
<div id="about" class="hide">
<div class="content left">
<h2>Ultrawidify - an aspect ratio fixer for youtube <small>(and netflix)</small></h2>
<p>Created by Tamius Han (me). If something is broken, you can shout at me on <a href="https://github.com/xternal7/ultrawidify">github</a> (shout nicely, though. Open an issue or bug report or something). If you're curious to see the source code, <a href="https://github.com/xternal7/ultrawidify">github's here</a>. If you're looking at this page because you're bored and want to be bored some more, <a href="http://tamius.net">my website's here</a>.</p>
<h2>So you want to help?</h2>
<p>There's a lot of sites where you can stream videos. A lot of these sites keep failing to handle aspect ratios correctly, which means it would be great if this extension worked elsewhere. Unfortunately, a lot of these sites require me to pony up some money (ayy lmao) OR just flat out block anyone who's not from the US (or their small selection of approved regions). Some sites even do both.</p>
<p>This means I'd need some help. There's two ways. One of them is to use 'inspect element' option of your browser to pick up IDs (or classnames) of certain elements. More detail here(TODO: add a link to quick tutorial).</p>
<p>The second one is, well. I won't shy away from donations either. <small>Bonus respect for dank amounts!</small></p>
<p>Needless to say, I'll be happy and thankful regardless of the way you contribute.</p>
<h2>Plans for the future</h2>
<p>Support for more sizes. More flexible/customizable UI. Maybe (but absolutely no promises here) a bit more advanced autodetection.</p>
<h2>Acknowledgements</h2>
<p>This extension uses font <a href="https://fonts.google.com/specimen/Oxygen">Oxygen</a>.</p>
<p>Special thanks to CD Project Red (The Witcher 2), Anet (Guild Wars 2), and Valve (CS:GO), which made it possible for me to untrigger myself after seeing so many improperly encoded videos.</p>
<small><p>More or less.</p>
<!-- <p>GW2 is also roughly how the avatar was obtained. Noone tell Anet, though.</p> --></small>
<p>Special one-finger salute to all incompetent people who don't know how to properly encode videos and upload them to youtube (to word it most nicely).</p>
<p>Special thanks to me for making this extension. You're welcome.</p>
</div>
</div>
</div>
<script src="./settings.js"></script>
</body>
</html>

View File

@ -1,860 +0,0 @@
// Autogenerated using buildext. This file should not be modified — modify source files instead.
//BEGIN included from lib/libopts.js
// setopt, getopt, delopt. Shrani oz. dobi oz. briše stvari iz skladišča
// setopt, getopt, delopt. They set/get/delete stuff from the storage
function setopt(item){
browser.storage.local.set(item);
}
function getopt(prop, callback){
if(usebrowser == "chrome")
browser.storage.local.get(prop, callback);
else
browser.storage.local.get(prop).then(callback);
}
function delopt(item){
browser.storage.local.remove(item);
}
//END included from lib/libopts.js
//BEGIN included from lib/uiutils.js
//END included from lib/uiutils.js
//BEGIN included from conf/sitesconf.js
var UW_SITES = {
youtube: {
enabled: true,
type: "official",
urlRules: ["youtu"],
player: {
name: "movie_player",
isClass: false,
},
iframe: {
name: "player",
isClass: false
},
ui: {
uiMode: "native",
uiconf: {
sampleButton: {
class: "ytp-button ytp-settings-button",
index: 0,
buttonSizeBase: "x",
},
uiParent: {
name: "ytp-right-controls",
isClass: true,
insertStrat: "prepend",
},
uiOffset: {
offsetBy: "10vh",
offsetType: "css"
}
}
},
autoar_imdb:{
enabled: false
}
},
netflix: {
enabled: true,
type: "official",
urlRules: ["netflix"],
player: {
name: "placeholder",
isClass: true,
},
ui: {
uiMode: "native",
uiconf: {
sampleButton: {
class: "ytp-button ytp-settings-button",
index: 0,
buttonSizeBase: "x",
},
uiParent: {
name: "player-controls-wrapper",
isClass: true,
insertStrat: "append"
},
uiOffset: {
offsetBy: "0px",
offsetType: "css"
}
}
},
autoar_imdb:{
enabled: true,
title: "player-status-main-title",
isClass: true
}
},
dummy: {
type: "add new site",
urlRules: [""],
player: {
name: "",
isClass: false,
},
sampleButton: {
class: "ytp-button ytp-settings-button",
index: 0,
buttonSizeBase: "x",
},
uiParent: {
name: "",
isClass: false,
insertStrat: "prepend",
},
autoar_imdb:{
enabled: false
}
}
}
//END included from conf/sitesconf.js
var browser_autodetect = true;
var usebrowser = "chrome";
var debugmsg = true;
if(browser_autodetect){
if(typeof browser === "undefined"){
if(chrome){
browser = chrome;
usebrowser = "chrome";
}
}
else
usebrowser = "firefox";
}
else{
if(usebrowser == "chrome")
browser = chrome;
}
var UW_SITES = {};
function showAbout(){
clearPage();
document.getElementById("about").classList.remove("hide");
document.getElementById("tab_about").classList.add("tab-selected");
}
function showShortcuts(){
clearPage();
document.getElementById("uw_shortcuts").classList.remove("hide");
document.getElementById("tab_shortcuts").classList.add("tab-selected");
}
function showGeneralSettings(){
clearPage();
document.getElementById("general_settings").classList.remove("hide");
document.getElementById("tab_general_settings").classList.add("tab-selected");
}
function showSites(){
clearPage();
document.getElementById("uw_sites").classList.remove("hide");
document.getElementById("tab_sites").classList.add("tab-selected");
}
function clearPage(){
// Hide you sections
document.getElementById("uw_shortcuts").classList.add("hide");
document.getElementById("about").classList.add("hide");
document.getElementById("general_settings").classList.add("hide");
document.getElementById("uw_sites").classList.add("hide");
// Hide you tabs
document.getElementById("tab_shortcuts").classList.remove("tab-selected");
document.getElementById("tab_about").classList.remove("tab-selected");
document.getElementById("tab_general_settings").classList.remove("tab-selected");
document.getElementById("tab_sites").classList.remove("tab-selected");
}
function saveopts(){
var actions = ["fitw", "fith", "reset", "zoom", "unzoom", "ar219", "ar169", "ar1610", "ar43", "autoar"];
var new_keybinds = {};
// Preberemo naš obrazec in iz njega naredimo nov objekt z bližnjicami.
// Let's read our form and make a new object with keybinds.
for(var i = 0; i < actions.length; i++){
var action = actions[i];
var targetAR = "";
if(action == "ar219"){
action = "char";
targetAR = (21/9);
}
if(action == "ar169"){
action = "char";
targetAR = (16/9);
}
if(action == "ar1610"){
action = "char";
targetAR = (16/10);
}
if(action == "ar43"){
action = "char";
targetAR = (4/3);
}
if(targetAR != ""){
var keybind = {
action: action,
targetAR: targetAR,
key: document.querySelector("#" + actions[i] + "_letter").value.toLowerCase().replace(/[^a-z0-9]/,""),
modifiers: []
}
}
else{
var keybind = {
action: action,
key: document.querySelector("#" + actions[i] + "_letter").value.toLowerCase().replace(/[^a-z0-9]/,""),
modifiers: []
}
}
if(document.querySelector("#" + actions[i] + "_ctrl").checked)
keybind.modifiers.push("ctrl");
if(document.querySelector("#" + actions[i] + "_alt").checked)
keybind.modifiers.push("alt");
if(document.querySelector("#" + actions[i] + "_shift").checked)
keybind.modifiers.push("shift");
new_keybinds[i] = keybind;
}
// Preveriti moramo, da nismo dvema možnostima dodali isto bližnjico.
// We need to check if all keybinds are unique.
var fail = false;
for(var i = 0; i < actions.length; i++)
document.querySelector("#" + actions[i] + "_letter").classList.remove("dup_keybinds");
for(var i = 0; i < actions.length; i++){
if(new_keybinds[i].key == "")
continue;
for(var j = i + 1; j < actions.length; j++){
if(new_keybinds[i].key == new_keybinds[j].key){
if(compareModifiers(new_keybinds[i].modifiers, new_keybinds[j].modifiers)){
fail = true;
document.querySelector("#" + actions[i] + "_letter").classList.add("dup_keybinds");
document.querySelector("#" + actions[j] + "_letter").classList.add("dup_keybinds");
}
}
}
}
if (!fail){
browser.storage.local.set({ultrawidify_keybinds:new_keybinds});
}
}
function saveAutoar(){
setopt({ultrawidify_autoar: document.querySelector("#enable_autoar").checked});
}
function saveUI(){
var show_ui = document.querySelector("#enable_ui");
var ui_compact = document.querySelector("#enable_ui_compact");
var optionLine = document.getElementById("compact_ui_suboption");
if(show_ui.checked){
ui_compact.disabled = false;
optionLine.classList.remove("hide");
setopt({ultrawidify_ui: ui_compact.checked ? "compact" : "all" });
}
else{
ui_compact.disabled = true;
optionLine.classList.add("hide");
setopt({ultrawidify_ui: "none"});
}
}
function compareModifiers(a,b){
//NOTE: to je precej slab in neprenoslijv način primerjanja dveh tabel, ampak za naš primer deluje dovolj
// dobro, saj 'ctrl' vedno pride pred 'alt' in 'alt' vedno pride pred 'shift' (če se sploh pojavijo).
//NOTE: this is bad and totally unfoolproof practice. In our example comparing arrays the way we do works
// because values ALWAYS appear in the same order: 'ctrl' always appears before 'alt' (or it doesn't
// appear at all). 'alt' always appears before 'shift' (or it doesn't appear at all).
if(a.length != b.length)
return false;
var match = true;
for(var i = 0; i < a.length; i++)
match &= a[i] == b[i]
return match;
}
function printerr(err){
console.log(err);
}
function gotopts(opts){
if(!opts.ultrawidify_keybinds){
console.log("ultrawidify keybinds are undefined. the fuck?",opts);
return;
}
var KEYBINDS = Object.keys(opts.ultrawidify_keybinds).map(function (key) { return opts.ultrawidify_keybinds[key];});
// google chrome is really the untermensch browse // google chrome is really the untermensch browserr
var actions = ["fitw", "fith", "reset", "zoom", "unzoom", "ar219", "ar169", "ar1610", "ar43", "autoar"];
for(var i = 0; i < actions.length; i++){
document.querySelector("#" + actions[i] + "_letter").classList.remove("dup_keybinds");
document.querySelector("#" + actions[i] + "_letter").value = KEYBINDS[i].key;
for(var j = 0; j < KEYBINDS[i].modifiers.length; j++){
if(KEYBINDS[i].modifiers[j] == "ctrl")
document.querySelector("#" + actions[i] + "_ctrl").checked = true;
if(KEYBINDS[i].modifiers[j] == "alt")
document.querySelector("#" + actions[i] + "_alt").checked = true;
if(KEYBINDS[i].modifiers[j] == "shift")
document.querySelector("#" + actions[i] + "_shift").checked = true;
}
}
}
function gotar(opts){
}
function gotui(opts){
var show_ui = document.querySelector("#enable_ui");
var ui_compact = document.querySelector("#enable_ui_compact");
var optionLine = document.getElementById("compact_ui_suboption");
if(opts.ultrawidify_ui == "all"){
show_ui.checked = true;
ui_compact.checked = false;
optionLine.classList.remove("hide");
}
else if(opts.ultrawidify_ui == "compact"){
show_ui.checked = true;
ui_compact.checked = true;
optionLine.classList.remove("hide");
}
else if(opts.ultrawidify_ui == "none"){
show_ui.checked = false;
ui_compact.checked = false;
optionLine.classList.add("hide");
}
}
function gotsites(opts){
var list = document.getElementById("uw_sites_list");
if(list)
list.remove();
var anchor = document.getElementById("uw_sites_body");
// at the top of the list, there is this option to reset site config
resetLink = document.createElement("a");
resetLink.onclick = function(){ delopt("ultrawidify_siterules"); setopt({"ultrawidify_siterules":UW_SITES}); };
resetLink.textContent = "Reset site options to default";
anchor.appendChild(resetLink);
list = document.createElement("div");
list.id = "uw_sites_list";
list.className = "uw_sites";
anchor.appendChild(list);
uw_sites = opts.ultrawidify_siterules;
UW_SITES = uw_sites;
if(debugmsg)
console.log("uw settings::gotopts | site opts:",opts);
for (type in {"official":1,"non-official":1,"custom":1, "add new site":1} ) { // unparalleled laziness!
if(debugmsg){
console.log("uw settings::gotopts | adding sites of type" , type);
}
var head = document.createElement("div");
head.className = "sites_header";
head.textContent = type.charAt(0).toUpperCase() + type.slice(1);
var category_desc = document.createElement("div");
if(type == "official"){
category_desc.innerHTML = "These sites are officially supported by the extension developer. These sites should always work. <small>(Pro tip: if you don't want extension to run on some of the following sites, uncheck the checkbox for that site)</small>";
}
else if(type == "non-official"){
category_desc.textContent = "Sites in this category have been contribued by third parties. These sites will probably work, but the developer couldn't test whether they work or not.";
}
else if(type == "custom"){
category_desc.textContent = "In this section, you can define rules for sites that aren't supported either officially or non-officially. See [todo: link] contributing for details. If you define a custom site, please consider sharing configuration on github (see contributing for details).";
}
else if(type == "add new site"){
category_desc.textContent = "Add a custom site by filling the form below.";
}
list.append(head);
list.append(category_desc);
var category_counter = 0;
for (site in uw_sites) {
if(debugmsg)
console.log("we're at site %s of type %s. We're %s this site.",site, uw_sites[site].type, uw_sites[site].type == type ? "processing" : "ignoring");
if(uw_sites[site].type == type){
var entry = document.createElement("div");
var header = document.createElement("div");
header.id = site + "_display";
header.className = "uw_options_line site_details";
var siteTitle = document.createElement("div");
siteTitle.className = "site_name";
{
var sitecb = mkcb(site, uw_sites[site].enabled, "siteEnabled", true);
var editTitle = mkebox(site, site, "title");
editTitle.className = "site_title_ebox";
siteTitle.append(sitecb);
siteTitle.append(editTitle);
var editBtn = document.createElement("div");
editBtn.textContent = "« edit »";
editBtn.className = "inline_button";
editBtn.id = site + "_edit_button";
editBtn.addEventListener("click", function(){ var site = this.id; site = site.replace("_edit_button", ""); enableEditing(site)});
var saveBtn = document.createElement("div");
saveBtn.textContent = "« save »";
saveBtn.className = "inline_button hide";
saveBtn.id = site + "_save_button";
saveBtn.addEventListener("click", function(){ var site = this.id; site = site.replace("_save_button", ""); saveEdited(site)});
var cancelBtn = document.createElement("div");
cancelBtn.textContent = "« cancel »";
cancelBtn.className = "inline_button hide";
cancelBtn.id = site + "_cancel_button";
cancelBtn.addEventListener("click", function(){ var site = this.id; site = site.replace("_cancel_button", ""); cancelEditing(site)});
siteTitle.append(editBtn);
siteTitle.append(saveBtn);
siteTitle.append(cancelBtn);
}
header.appendChild(siteTitle);
entry.appendChild(header);
var body = document.createElement("div");
var jsonForm = document.createElement("textarea");
jsonForm.cols = 64;
jsonForm.rows = 32;
jsonForm.value = JSON.stringify(uw_sites[site], null, 2);
body.appendChild(jsonForm);
// body.classNamež
entry.appendChild(body);
list.append(entry);
category_counter++;
}
}
// for (site in uw_sites){
// if(debugmsg)
// console.log("we're at site %s of type %s. We're %s this site.",site, uw_sites[site].type, uw_sites[site].type == type ? "processing" : "ignoring");
//
// if(uw_sites[site].type == type){
//
// var entry = document.createElement("div");
// var displayedInfo = document.createElement("div");
// displayedInfo.id = site + "_display";
// displayedInfo.className = "uw_options_line site_details";
//
// var siteTitle = document.createElement("div");
// siteTitle.className = "site_name";
//
// {
// var sitecb = mkcb(site, uw_sites[site].enabled, "siteEnabled", true);
// var editTitle = mkebox(site, site, "title");
// editTitle.className = "site_title_ebox";
// siteTitle.append(sitecb);
// siteTitle.append(editTitle);
//
// var editBtn = document.createElement("div");
// editBtn.textContent = "« edit »";
// editBtn.className = "inline_button";
// editBtn.id = site + "_edit_button";
// editBtn.addEventListener("click", function(){ var site = this.id; site = site.replace("_edit_button", ""); enableEditing(site)});
//
// var saveBtn = document.createElement("div");
// saveBtn.textContent = "« save »";
// saveBtn.className = "inline_button hide";
// saveBtn.id = site + "_save_button";
// saveBtn.addEventListener("click", function(){ var site = this.id; site = site.replace("_save_button", ""); saveEdited(site)});
//
// var cancelBtn = document.createElement("div");
// cancelBtn.textContent = "« cancel »";
// cancelBtn.className = "inline_button hide";
// cancelBtn.id = site + "_cancel_button";
// cancelBtn.addEventListener("click", function(){ var site = this.id; site = site.replace("_cancel_button", ""); cancelEditing(site)});
//
// siteTitle.append(editBtn);
// siteTitle.append(saveBtn);
// siteTitle.append(cancelBtn);
// }
//
// var siteDetails = document.createElement("div");
// siteDetails.id = site + "_conf_details";
// siteDetails.classList = "hide";
//
// var urlRules = document.createElement("div");
// {
// var urlRulesLabel = document.createElement("span");
// urlRulesLabel.textContent = "URL rule: ";
//
// urlRulesEbox = mkebox(site, uw_sites[site].urlRules[0], "url_rules");
//
// urlRules.append(urlRulesLabel);
// urlRules.append(urlRulesEbox);
// }
//
// var playerElement = document.createElement("div");
//
// {
// var playerName = document.createElement("div");
//
// var playerNameLabel = document.createElement("span");
//
// playerNameLabel.textContent = "id of the player container:";
// var playerNameEbox = mkebox(site, uw_sites[site].player.name, "player_name");
//
// playerName.append(playerNameLabel);
// playerName.append(playerNameEbox);
//
// var playerClass = document.createElement("div");
// var pcb = document.createElement("input");
// pcb.className = site + "_ebox";
// pcb.type = "checkbox";
// pcb.name = site + "_pccb_name";
// pcb.id = site + "_pccb_id";
// pcb.checked = uw_sites[site].player.isClass;
// pcb.disabled = true;
//
// var pcblabel = document.createElement("span");
// pcblabel.textContent = " Name of the player container is a class";
//
// playerClass.append(pcb);
// playerClass.append(pcblabel);
// playerElement.append(playerName);
// playerElement.append(playerClass);
// }
//
// var iframe_playerName = document.createElement("div");
// var ipn_label = document.createElement("span");
// ipn_label.textContent = "id of the player container when in an iframe:";
// ipn_ebox = mkebox(site, uw_sites[site].iframe ? uw_sites[site].iframe.name : "", "iframe_name");
// iframe_playerName.append(ipn_label);
// iframe_playerName.append(ipn_ebox);
//
// var iframe_playerClass = document.createElement("div");
// var ipc_label = document.createElement("span");
// ipc_label.textContent = " Name of the player container is a class";
// var ipc_cb = mkcb(site, uw_sites[site].iframe ? uw_sites[site].iframe.isClass : false, "iframe_class");
// iframe_playerClass.append(ipc_cb);
// iframe_playerClass.append(ipc_label);
//
//
// var sampleButton = document.createElement("div");
// var sbc = document.createElement("div");
// var sbi = document.createElement("div");
// var sbo = document.createElement("div");
// var sbc_label = document.createElement("span");
// var sbi_label = document.createElement("span");
// var sbo_label = document.createElement("span");
// sbc_label.textContent = "Sample button class:";
// sbi_label.textContent = "Sample button index:";
// sbo_label.textContent = "Use height for UI scaling";
// var sampleButtonClass = mkebox(site, uw_sites[site].sampleButton.class, "sample_button_class");
// var sampleButtonIndex = mkebox(site, uw_sites[site].sampleButton.index, "sample_button_index");
// var buttonSizeBase = mkcb(site, uw_sites[site].sampleButton.buttonSizeBase == "y", "sample_button_size_base");
//
// sbc.append(sbc_label);
// sbc.append(sampleButtonClass);
// sampleButton.append(sbc);
//
// sbi.append(sbi_label);
// sbi.append(sampleButtonIndex);
// sampleButton.append(sbi);
//
// sbo.append(buttonSizeBase);
// sbo.append(sbo_label);
// sampleButton.append(sbo);
//
// var imdbar = document.createElement("div");
// var imdbar_cb = mkcb(site, uw_sites[site].autoar_imdb, "imdbar");
// var imdbar_label = document.createElement("span");
// imdbar_label.textContent = " This site supports automatic aspect ratio detection";
// imdbar.append(imdbar_cb);
// imdbar.append(imdbar_label);
//
// var imdbar_title = document.createElement("div");
// var it_label = document.createElement("span");
// it_label.textContent = "id of the element containing video title:";
// it_ebox = mkebox(site, uw_sites[site].iframe ? uw_sites[site].iframe.name : "", "imdbar_title");
// imdbar_title.append(it_label);
// imdbar_title.append(it_ebox);
//
// var imdbar_class = document.createElement("div");
// var ic_label = document.createElement("span");
// ic_label.textContent = " Name of the title container is a class";
// var ic_cb = mkcb(site, uw_sites[site].iframe ? uw_sites[site].iframe.isClass : false, "imdbar_class");
// imdbar_class.append(ic_cb);
// imdbar_class.append(ic_label);
//
//
//
//
//
// var optionspad = document.createElement("div");
// optionspad.textContent = "-------------";
//
//
// siteDetails.append(urlRules);
// siteDetails.append(playerElement);
// siteDetails.append(optionspad);
// siteDetails.append(iframe_playerName);
// siteDetails.append(iframe_playerClass);
// siteDetails.append(optionspad);
//
// siteDetails.append(sampleButton);
//
// siteDetails.append(imdbar);
// siteDetails.append(imdbar_title);
// siteDetails.append(imdbar_class);
// // siteDetails.append(optionspad);
//
//
// displayedInfo.append(siteTitle);
// displayedInfo.append(siteDetails);
//
// entry.append(displayedInfo);
//
// list.append(entry);
//
// category_counter++;
//
// if(site == "dummy" && type == "add new site"){
// if(debugmsg)
// console.log("uw settings::gotsites | we are adding dummy site");
// enableEditing("dummy");
// document.getElementById("dummy_title_ebox").disabled = false;
// }
// }
// }
if(! category_counter){
var noEntriesMsg = document.createElement("div");
noEntriesMsg.textContent = "There's no entries in this category yet";
noEntriesMsg.classList = "red";
list.append(noEntriesMsg);
}
}
}
function mkebox(site, value, id){
var ebox = document.createElement("input");
ebox.className = "site_details details_ebox " + site + "_ebox",
ebox.id = site + "_" + id + "_ebox";
ebox.type = "text";
ebox.value = value;
ebox.disabled = true;
return ebox;
}
function mkcb(site, checked, id, forceEnable){
var cb = document.createElement("input");
cb.type = "checkbox";
cb.name = site + "_cb_name";
cb.id = site + "_" + id + "_cb";
cb.checked = checked;
if(!forceEnable){
cb.disabled = true;
cb.className = site + "_ebox";
}
return cb;
}
function enableEditing(site){
showSiteDetails(site);
if(debugmsg)
console.log("uw settings :: enableEditing | enabling editing for",site);
var formElements = document.getElementsByClassName(site + "_ebox");
if(!formElements)
return;
if(debugmsg)
console.log("form elements: ", formElements);
for(var i = 0; i < formElements.length; i++){
formElements[i].disabled = false;
}
var editButton = document.getElementById(site + "_edit_button");
if( editButton )
editButton.classList.add("hide");
else
return;
try{
document.getElementById(site + "_save_button").classList.remove("hide");
document.getElementById(site + "_cancel_button").classList.remove("hide");
} catch (e){};
}
function disableEditing(site){
var formElements = document.getElementsByClassName(site + "_ebox");
if(!formElements)
return;
for(var i = 0; i < formElements.length; i++){
formElements[i].disabled = true;
}
var editButton = document.getElementById(site + "_edit_button");
if( editButton )
editButton.classList.remove("hide");
else
return;
try{
document.getElementById(site + "_save_button").classList.add("hide");
document.getElementById(site + "_cancel_button").classList.add("hide");
} catch (e){};
}
function cancelEditing(site){
if(site != "dummy"){
disableEditing(site);
hideSiteDetails(site);
}
setSiteOpts(site, UW_SITES[site]);
}
function saveEdited(site){
console.log("uw settings::saveEdited | this is our site:",site,"is this 'dummy'?", site == "dummy");
if(site == "dummy"){
var newsite = getSiteOpts(site);
newsite.type = "custom";
newsite.enabled = true;
UW_SITES[document.getElementById("dummy_title_ebox").value] = newsite;
}
else{
UW_SITES[site] = getSiteOpts(site);
// disableEditing(site);
// hideSiteDetails(site);
}
setopt({ultrawidify_siterules: UW_SITES});
if(site == "dummy")
gotsites({ultrawidify_siterules: UW_SITES});
}
function showSiteDetails(site){
try{
document.getElementById(site + "_conf_details").classList.remove("hide");
}catch(me_outside_how_about_that){}
}
function hideSiteDetails(site){
try{
document.getElementById(site + "_conf_details").classList.add("hide");
}catch(me_outside_how_about_that){}
}
function getSiteOpts(site){
var newOptions = {};
newOptions.urlRules = [ document.getElementById(site + "_url_rules_ebox").value ];
newOptions.player = {};
newOptions.player.name = document.getElementById(site + "_player_name_ebox").value;
newOptions.player.isClass = document.getElementById(site + "_pccb_id").checked;
newOptions.iframe = {};
newOptions.iframe.name = document.getElementById(site + "_iframe_name_ebox").value;
newOptions.iframe.isClass = document.getElementById(site + "_iframe_class_cb").checked;
newOptions.autoar_imdb = {};
newOptions.autoar_imdb.enabled = document.getElementById(site + "_imdbar_cb").value;
newOptions.autoar_imdb.title = document.getElementById(site + "_imdbar_title_ebox").value;
newOptions.autoar_imdb.isClass = document.getElementById(site + "_imdbar_class_cb").checked;
return newOptions;
}
function setSiteOpts(site, opts){
document.getElementById(site + "_url_rules_ebox").value = opts.urlRules[0];
document.getElementById(site + "_player_name_ebox").value = opts.player.name;
document.getElementById(site + "_pccb_id").checked = opts.player.isClass;
if(opts.iframe){
document.getElementById(site + "_iframe_name_ebox").value = opts.iframe.name;
document.getElementById(site + "_iframe_class_cb").checked = opts.iframe.isClass;
}
if(opts.autoar_imdb){
document.getElementById(site + "_imdbar_cb").checked = opts.autoar_imdb.enabled;
if(opts.autoar_imdb.enabled){
document.getElementById(site + "_imdbar_title_ebox").value = opts.autoar_imdb.title;
document.getElementById(site + "_imdbar_class_cb").value = opts.autoar_imdb.isClass
}
}
}
function loadopts(){
getopt("ultrawidify_keybinds", gotopts);
// getopt("ultrawidify_autoar", gotar)
getopt("ultrawidify_ui", gotui);
getopt("ultrawidify_siterules", gotsites);
// We build ui for 'site options' here
// buildSites();
}
// page init
document.addEventListener("DOMContentLoaded", loadopts);
document.querySelector("#tab_shortcuts").addEventListener("click", showShortcuts);
document.querySelector("#tab_about").addEventListener("click", showAbout);
document.querySelector("#tab_general_settings").addEventListener("click",showGeneralSettings);
document.querySelector("#tab_sites").addEventListener("click", showSites);
document.querySelector("#kb_save").addEventListener("click", saveopts);
document.querySelector("#kb_cancel").addEventListener("click",loadopts);
document.querySelector("#enable_autoar").addEventListener("click",saveAutoar);
document.querySelector("#enable_ui").addEventListener("click", saveUI);
document.querySelector("#enable_ui_compact").addEventListener("click", saveUI);
getopt("ultrawidify_autoar",function(obj){document.querySelector("#enable_autoar").checked = obj.ultrawidify_autoar});

42
scripts/build-all.sh Normal file
View File

@ -0,0 +1,42 @@
#!/bin/bash
# NOTE: this script needs to be run with the npm run build-all
# command from the root directory of the project. Running it in
# any other way probably isn't going to work.
# pre-build steps:
mkdir -p ./build/old
npm run pre-build
rm ./dist-zip/uw-amo-source.zip
mv -f ./dist-zip/*.zip ./build/old
# lets force raise ram limit, but the improper way
# export NODE_OPTIONS=--max_old_space_size=4096
# build the version for each browser and create a zip afterwards
# step 1: define build functions
#function buildFF {
npm run build
node scripts/build-zip.js ff
#}
#function buildChrome {
npm run build-chrome
node scripts/build-zip.js chrome
#}
#function buildEdge {
npm run build-edge
node scripts/build-zip.js edge
#}
# step 2: execute them all at once
# buildFF &
# buildChrome &
# buildEdge &
# wait < <(jobs -p)
# prepare AMO source
# source code needs to be prepared AFTER
# the code has been built, to ensure that
# package-lock.json remains unchanged
./scripts/prepare-amo-source.sh

94
scripts/build-and-deploy.sh Executable file
View File

@ -0,0 +1,94 @@
#!/bin/bash
# env variables to set:
#
# FORCE_BUILD set this variable to "true" if you wanna force build, even if build was
# triggered without any commits pushed to the directory
#
# BUILD_SCRIPT build-testing or build-nightly, could be any other from package.json tho
#
# RELEASE_SERVER target server (where to push built zips after they've been built)
# RELEASE_DIRECTORY base directory on the target server
# BUILD_CHANNEL_DIRECTORY directory for uploads, inside the release directory
#
# AMO_API_KEY needed if you want to sign and push extension to addons.mozilla.org
# AMO_API_SECRET -||-
echo "============= STARTING BUILD SCRIPT ============="
pwd
whoami
echo " ::: env dump"
echo " -> FORCE_BUILD: $FORCE_BUILD"
echo " -> BUILD_SCRIPT: $BUILD_SCRIPT"
echo " -> RELEASE_SERVER: $RELEASE_SERVER"
echo " -> RELEASE_DIRECTORY: $RELEASE_DIRECTORY"
echo " -> BUILD_CHANNEL_DIRECTORY: $BUILD_CHANNEL_DIRECTORY"
# don't build if nothing has changed, unless overriden via env variable
if [ ! -z "$GIT_COMMIT" ] ; then
if [ ! -z "$GIT_PREVIOUS_COMMIT" ] ; then
if [ "$GIT_COMMIT" == "$GIT_PREVIOUS_COMMIT" ] ; then
if [ $FORCE_BUILD == false ] ; then
echo "--------------------------------------------"
echo " Nothing has changed. Aborting build."
echo "--------------------------------------------"
exit 0;
fi
fi
fi
fi
# let's raise RAM limit for npm command globally
NODE_OPTIONS=--max_old_space_size=4096
npm ci
rm -rf ./dist-zip || true # no big deal if ./dist-zip doesn't exist
mkdir dist-zip # create it back
#
# build firefox
#
npm run "${BUILD_SCRIPT}"
node --max-old-space-size=2048 scripts/build-zip.js ff nightly
# if [ ! -z "${AMO_API_KEY}" ] ; then
# if [ ! -z "${AMO_API_SECRET}" ] ; then
# web-ext sign --source-dir ./dist --api-key "${AMO_API_KEY}" --api-secret "${AMO_API_SECRET}"
# fi
# fi
#
# build chrome
#
npm run "${BUILD_SCRIPT}-chrome"
node --max-old-space-size=2048 scripts/build-zip.js chrome nightly
#
#./scripts/build-crx.sh
#
#
# build edge
#
npm run "${BUILD_SCRIPT}-edge"
node --max-old-space-size=2048 scripts/build-zip.js chrome nightly
######################################
# UPLOAD TO WEB SERVER
######################################
echo "--------------------------------------------"
echo " files ready for upload"
echo "--------------------------------------------"
echo ""
echo "Uploading to server ..."
# push all built stuff to the server
scp -i ~/.ssh/id_rsa -r ./dist-zip/* "ultrawidify-uploader@${RELEASE_SERVER}:${RELEASE_DIRECTORY}${BUILD_CHANNEL_DIRECTORY}"
######################################
# Build finished message
######################################
echo ""
echo "--------------------------------------------"
echo " BUILD FINISHED SUCCESSFULLY"
echo "--------------------------------------------"

45
scripts/build-crx.sh Executable file
View File

@ -0,0 +1,45 @@
#!/bin/bash -e
#
# Purpose: Pack a Chromium extension directory into crx format
# gotten from: https://web.archive.org/web/20180114090616/https://developer.chrome.com/extensions/crx#scripts
#
# Script assumes we're in basedir of the repository and that extension has been built and zipped to /dist-zip
# using the crx name we want (same name as zip, except different extension)
#
# also this doesn't check for errors ever so
#
echo "entering dist-zip"
cd ./dist-zip
zip=`ls | grep chrome.zip`
name="${zip%.*}"
crx="$name.crx"
key="../keys/chrome-nightly.pem" # this is also good for testing build
pub="$name.pub"
sig="$name.sig"
trap 'rm -f "$pub" "$sig" "$zip"' EXIT
# signature
openssl sha1 -sha1 -binary -sign "$key" < "$zip" > "$sig"
# public key
openssl rsa -pubout -outform DER < "$key" > "$pub" 2>/dev/null
byte_swap () {
# Take "abcdefgh" and return it as "ghefcdab"
echo "${1:6:2}${1:4:2}${1:2:2}${1:0:2}"
}
crmagic_hex="4372 3234" # Cr24
version_hex="0200 0000" # 2
pub_len_hex=$(byte_swap $(printf '%08x\n' $(ls -l "$pub" | awk '{print $5}')))
sig_len_hex=$(byte_swap $(printf '%08x\n' $(ls -l "$sig" | awk '{print $5}')))
(
echo "$crmagic_hex $version_hex $pub_len_hex $sig_len_hex" | xxd -r -p
cat "$pub" "$sig" "$zip"
) > "$crx"
echo "Wrote $crx"
echo "exiting dist-zip"
cd ..

76
scripts/build-zip.js Normal file
View File

@ -0,0 +1,76 @@
#!/usr/bin/env node
const fs = require('fs');
const path = require('path');
const archiver = require('archiver');
const extractExtensionData = (browserPostfix) => {
const extPackageJson = require(`../dist-${browserPostfix}/manifest.json`);
return {
name: extPackageJson.name,
version: extPackageJson.version
}
};
const makeDirIfNotExists = (dir) => {
if(!fs.existsSync(dir)) {
fs.mkdirSync(dir);
}
}
const buildZip = (src, dist, zipFilename) => {
console.info(`Building ${zipFilename}...`);
const archive = archiver('zip', { zlib: { level: 9 }});
const stream = fs.createWriteStream(path.join(dist, zipFilename));
return new Promise((resolve, reject) => {
archive
.directory(src, false)
.on('error', err => reject(err))
.pipe(stream);
stream.on('close', () => resolve());
archive.finalize();
});
};
const main = () => {
const browser = process.argv[2];
const testingOrNightly = process.argv[3];
let browserPostfix;
if (browser == 'firefox') {
browserPostfix = 'ff';
} else {
browserPostfix = browser;
}
const destDir = path.join(__dirname, `../dist-${browserPostfix}`);
const zipDir = path.join(__dirname, '../dist-zip');
const {name, version} = extractExtensionData(browserPostfix);
// collapse spaces and dashes into single dash
const baseFilename = `${name.replace(/[ -]+/g, '-')}-${version}`;
let realZipDir;
if (!!testingOrNightly) {
realZipDir = path.join(zipDir, version);
} else {
realZipDir = path.join(zipDir);
}
const zipFilename = `${baseFilename}-${browser}.zip`;
try {
makeDirIfNotExists(realZipDir, {recursive: true});
} catch (e) {
console.error('Failed to make directory.\nDirectory we wanted to make', realZipDir, '\nerror we got:\n', e)
return 1;
}
buildZip(destDir, realZipDir, zipFilename)
.then(() => console.info('OK'))
.catch(console.err);
};
main();

47
scripts/prepare-amo-source.sh Executable file
View File

@ -0,0 +1,47 @@
#!/bin/bash
# makes a zip file with human-readable source code that we need to upload to AMO
# since webpack minifies stuff
# first, we collect npm/node versions:
# (NOTE: the last bit is necessary to remove ANSI color codes from output)
NODE_VERSION=`node --version`
NPM_VERSION=`npm --version`
LINUX_VERSION="$(uname -a | sed 's/\//\\\//g')"
# copy REAMDE to /tmp for processing
cp README-AMO.md /tmp/README-AMO.md
# replace placeholders with proper software versions
sed -i "s/%%NODE_VERSION%%/${NODE_VERSION}/g" /tmp/README-AMO.md
sed -i "s/%%NPM_VERSION%%/${NPM_VERSION}/g" /tmp/README-AMO.md
sed -i "s/%%LINUX_VERSION%%/${LINUX_VERSION}/g" /tmp/README-AMO.md
# add files to archive
zip -r dist-zip/uw-amo-source.zip /tmp/README-AMO.md .babelrc package.json package-lock.json webpack.config.js scripts/ src/
# rename /tmp/README-AMO.md to README.md
printf "@ tmp/README-AMO.md\n@=README.md\n" | zipnote -w dist-zip/uw-amo-source.zip
# printout for debugging purposes:
echo ""
echo "—————— AMO SOURCE PREPARATION FINISHED ——————"
echo " Debug info:"
echo ""
echo "node --version:"
node --version
echo ""
echo "npm --version"
npm --version
echo ""
echo "uname -a"
uname -a
echo ""
echo ""
echo "extracted variables:"
echo "NODE_VERSION: ${NODE_VERSION}"
echo "NPM_VERSION: ${NPM_VERSION}"
echo "UNAME: ${LINUX_VERSION}"
echo ""
echo ""
echo "—————— EXTENSION PACKAGES READY FOR UPLOAD ——————"

53
scripts/remove-evals.js Normal file
View File

@ -0,0 +1,53 @@
#!/usr/bin/env node
const path = require('path');
const fs = require('fs');
const BUNDLE_DIR = path.join(__dirname, `../dist-${process.env.BROWSER === 'firefox' ? 'ff' : process.env.BROWSER}`);
const bundles = [
'csui/csui-popup.js',
];
const evalRegexForProduction = /;([a-z])=function\(\){return this}\(\);try{\1=\1\|\|Function\("return this"\)\(\)\|\|\(0,eval\)\("this"\)}catch\(t\){"object"==typeof window&&\(\1=window\)}/g;
const evalRegexForDevelopment = /;\\r\\n\\r\\n\/\/ This works in non-strict mode(?:.){1,304}/g;
const removeEvals = (file) => {
console.info(`Removing eval() from ${file}`);
return new Promise((resolve, reject) => {
fs.readFile(file, 'utf8', (err, data) => {
if(err) {
reject(err);
return;
}
const regex = process.env.NODE_ENV === 'production' ? evalRegexForProduction : evalRegexForDevelopment;
if(!regex.test(data)) {
reject(`No CSP specific code found in ${file}.`);
return;
}
data = data.replace(regex, '=window;');
fs.writeFile(file, data, (err) => {
if(err) {
reject(err);
return;
}
resolve();
});
});
});
};
const main = () => {
bundles.forEach(bundle => {
removeEvals(path.join(BUNDLE_DIR, bundle))
.then(() => console.info(`Bundle ${bundle}: OK`))
.catch(console.error);
});
};
main();

57
scripts/reproducability-test.sh Executable file
View File

@ -0,0 +1,57 @@
#!/bin/bash
### VARIABLES
REPRODUCABILITY=5 # how many times we need to build with same hash
### TEST STARTS HERE ###
CURRENT_DIR=$(pwd)
if [[ $(echo $0 | awk -F"/" '{print NF-1}') -eq 1 ]] ; then
# we need to go one directory up
cd ..
fi
# cleanup after self if we already ran and previous test crashed or
# something before it cleaned up after itself.
rm -rf /tmp/uw-test-runs/* 2>/dev/null # we not interested if fails
# make new folder if it doesn't exist
mkdir -p /tmp/uw-test-runs
for ((run=0;run<$REPRODUCABILITY;run++)) ; do
echo ""
echo "---- run ${run} ----"
# save hash and then run build. Save hash.
OLD_HASH=$HASH
HASH=$(npm run build 2>/dev/null | grep "Hash:")
# move build file to /tmp, where it'll be saved for later
mv dist-ff /tmp/uw-test-runs/${run}
# skip comparisons with previous tests on first run,
# cos we don't have anything to compare against yet
if [[ $run -ne 0 ]] ; then
if [[ "$OLD_HASH" == "$HASH" ]] ; then
echo "Hashes ok${HASH##*:}"
else
echo "Webpack hashes do not match! (${OLD_HASH##*:} <---> ${HASH##*:})"
fi
echo "Diff test (no output=ok):"
diff -qr /tmp/uw-test-runs/${prev_run} /tmp/uw-test-runs/${run}
else
echo "Webpack hash: $HASH"
fi
# save id of previous run
prev_run=$run
done
# clean up after self
rm -rf /tmp/uw-test-runs
# restore dir
cd "$CURRENT_DIR"

View File

@ -0,0 +1,14 @@
let Notifications = Object.freeze({
'TEST_NOTIFICATION': {
icon: 'card-text',
text: 'This is a test notification.',
timeout: -1,
},
'AARD_DRM': {
icon: 'exclamation-triangle',
text: '<b>Autodetection may not be able to run on this video.</b> On sites that utilize DRM you will have to set aspect ratio manually.',
timeout: 5000,
}
});
export default Notifications;

View File

@ -0,0 +1,7 @@
enum AntiGradientMode {
Disabled = 0,
Lax = 1,
Strict = 2
}
export default AntiGradientMode;

View File

@ -0,0 +1,13 @@
enum AspectRatioType {
Cycle = -2,
Initial = -1, // page default
Reset = 0, // reset to initial
Automatic = 1, // we want to request automatic aspect ratio detection
FitWidth = 2, // legacy/dynamic = fit to width
FitHeight = 3, // legacy/dynamic = fit to height
Fixed = 4, // pre-determined aspect ratio
Manual = 5, // ratio achieved by zooming in/zooming out
AutomaticUpdate = 6, // set by Aard
}
export default AspectRatioType;

View File

@ -0,0 +1,9 @@
enum CropModePersistence {
Default = -1,
Disabled = 0,
UntilPageReload = 1,
CurrentSession = 2,
Forever = 3,
}
export default CropModePersistence;

View File

@ -0,0 +1,10 @@
enum ExtensionMode {
AutoDisabled = -2,
Disabled = -1,
Default = 0,
Whitelist = 1,
Basic = 2,
Enabled = 3,
};
export default ExtensionMode;

View File

@ -0,0 +1,11 @@
enum StretchType {
NoStretch = 0,
Basic = 1,
Hybrid = 2,
Conditional = 3,
Fixed = 4,
FixedSource = 5,
Default = -1
};
export default StretchType;

View File

@ -0,0 +1,10 @@
enum VideoAlignmentType {
Left = 0,
Center = 1,
Right = 2,
Top = 3,
Bottom = 4,
Default = -1
};
export default VideoAlignmentType;

View File

@ -0,0 +1,6 @@
import AspectRatioType from '../enums/AspectRatioType.enum';
export interface Ar {
type: AspectRatioType,
ratio?: number
}

View File

@ -0,0 +1,418 @@
import { Action } from '../../../node_modules/vuex/types/index'
import AntiGradientMode from '../enums/AntiGradientMode.enum'
import AspectRatioType from '../enums/AspectRatioType.enum'
import CropModePersistence from '../enums/CropModePersistence.enum'
import ExtensionMode from '../enums/ExtensionMode.enum'
import StretchType from '../enums/StretchType.enum'
import VideoAlignmentType from '../enums/VideoAlignmentType.enum'
export interface KeyboardShortcutInterface {
key?: string,
code?: string,
ctrlKey?: boolean,
metaKey?: boolean,
altKey?: boolean,
shiftKey?: boolean,
onKeyUp?: boolean,
onKeyDown?: boolean,
onMouseMove?: boolean,
}
interface ActionScopeInterface {
show: boolean,
label?: string, // example override, takes precedence over default label
shortcut?: KeyboardShortcutInterface[],
}
interface RestrictionsSettings {
disableOnSmallPlayers?: boolean; // Whether ultrawidify should disable itself when the player is small
minAllowedWidth?: number; // if player is less than this many px wide, ultrawidify will disable itself
minAllowedHeight?: number; // if player is less than this many px tall, ultrawidify will disable itself
onlyAllowInFullscreen?: boolean; // if enabled, ultrawidify will be disabled when not in full screen regardless of what previous two options say
onlyAllowAutodetectionInFullScreen?: boolean; // if enabled, autodetection will only start once in full screen
}
interface ExtensionEnvironmentSettingsInterface {
normal: ExtensionMode,
theater: ExtensionMode,
fullscreen: ExtensionMode,
}
export interface CommandInterface {
action: string,
label: string,
comment?: string,
arguments?: any,
shortcut?: KeyboardShortcutInterface,
internalOnly?: boolean,
actionId?: string,
}
export type SettingsReloadComponent = 'PlayerData' | 'VideoData';
export type SettingsReloadFlags = true | SettingsReloadComponent;
export interface AardSettings {
aardType: 'webgl' | 'legacy' | 'auto';
disabledReason: string, // if automatic aspect ratio has been disabled, show reason
allowedMisaligned: number, // top and bottom letterbox thickness can differ by this much.
// Any more and we don't adjust ar.
allowedArVariance: number, // amount by which old ar can differ from the new (1 = 100%)
timers: { // autodetection frequency
playing: number, // while playing
paused: number, // while paused
error: number, // after error
minimumTimeout: number,
tickrate: number, // 1 tick every this many milliseconds
},
autoDisable: { // settings for automatically disabling the extension
maxExecutionTime: number, // if execution time of main autodetect loop exceeds this many milliseconds,
// we disable it.
consecutiveTimeoutCount: number, // we only do it if it happens this many consecutive times
// FOR FUTURE USE
consecutiveArResets: number // if aspect ratio reverts immediately after AR change is applied, we disable everything
},
canvasDimensions: {
blackframeCanvas: { // smaller than sample canvas, blackframe canvas is used to recon for black frames
// it's not used to detect aspect ratio by itself, so it can be tiny af
width: number,
height: number,
},
sampleCanvas: { // size of image sample for detecting aspect ratio. Bigger size means more accurate results,
// at the expense of performance
width: number,
height: number,
},
},
// NOTE: Black Frame is currently not in use.
blackframe: {
sufficientColorVariance: number, // calculate difference between average intensity and pixel, for every pixel for every color
// component. Average intensity is normalized to where 0 is black and 1 is biggest value for
// that component. If sum of differences between normalized average intensity and normalized
// component varies more than this % between color components, we can afford to use less strict
// cumulative threshold.
cumulativeThresholdLax: number,
cumulativeThresholdStrict: number,// if we add values of all pixels together and get more than this, the frame is bright enough.
// (note: blackframe is 16x9 px -> 144px total. cumulative threshold can be reached fast)
blackPixelsCondition: number, // How much pixels must be black (1 all, 0 none) before we consider frame as black. Takes
// precedence over cumulative threshold: if blackPixelsCondition is met, the frame is dark
// regardless of whether cumulative threshold has been reached.
},
// Used by old aspect ratio detection algorithm. Pls remove.
blackbar: {
blackLevel: number, // everything darker than 10/255 across all RGB components is considered black by
// default. blackLevel can decrease if we detect darker black.
threshold: number, // if pixel is darker than the sum of black level and this value, we count it as black
// on 0-255. Needs to be fairly high (8 might not cut it) due to compression
// artifacts in the video itself
frameThreshold: number, // threshold, but when doing blackframe test
imageThreshold: number, // in order to detect pixel as "not black", the pixel must be brighter than
// the sum of black level, threshold and this value.
gradientThreshold: number, // When trying to determine thickness of the black bars, we take 2 values: position of
// the last pixel that's darker than our threshold, and position of the first pixel that's
// brighter than our image threshold. If positions are more than this many pixels apart,
// we assume we aren't looking at letterbox and thus don't correct the aspect ratio.
gradientSampleSize: number, // How far do we look to find the gradient
maxGradient: number, // if two neighboring pixels in gradientSampleSize differ by more than this, then we aren't
// looking at a gradient
gradientNegativeTreshold: number,
gradientMaxSD: number, // reserved for future use
antiGradientMode: AntiGradientMode
},
// Also not in use, probs.
variableBlackbarThresholdOptions: { // In case of poor bitrate videos, jpeg artifacts may cause us issues
// FOR FUTURE USE
enabled: boolean, // allow increasing blackbar threshold
disableArDetectOnMax: boolean, // disable autodetection when threshold goes over max blackbar threshold
maxBlackbarThreshold: number, // max threshold (don't increase past this)
thresholdStep: number, // when failing to set aspect ratio, increase threshold by this much
increaseAfterConsecutiveResets: number // increase if AR resets this many times in a row
},
blackLevels: {
defaultBlack: number, // By default, pixels darker than this are considered black.
// (If detection algorithm detects darker blacks, black is considered darkest detected pixel)
blackTolerance: number, // If pixel is more than this much brighter than blackLevel, it's considered not black
// It is not considered a valid image detection if gradient detection is enabled
imageDelta: number, // When gradient detection is enabled, pixels this much brighter than black skip gradient detection
}
sampling: {
edgePosition: number; // % of width (max 0.33). Pixels up to this far away from either edge may contain logo.
staticCols: number, // we take a column at [0-n]/n-th parts along the width and sample it
randomCols: number, // we add this many randomly selected columns to the static columns
staticRows: number, // forms grid with staticSampleCols. Determined in the same way. For black frame checks,
},
guardLine: { // all pixels on the guardline need to be black, or else we trigger AR recalculation
// (if AR fails to be recalculated, we reset AR)
enabled: boolean,
ignoreEdgeMargin: number, // we ignore anything that pokes over the black line this close to the edge
// (relative to width of the sample)
imageTestThreshold: number, // when testing for image, this much pixels must be over blackbarThreshold
edgeTolerancePx: number, // black edge violation is performed this far from reported 'last black pixel'
edgeTolerancePercent: null // unused. same as above, except use % of canvas height instead of pixels
},
arSwitchLimiter: { // to be implemented
switches: number, // we can switch this many times
period: number // per this period
},
// pls deprecate and move things used
edgeDetection: {
slopeTestWidth: number,
gradientTestSamples: number, // we check this many pixels below (or above) the suspected edge to check for gradient
gradientTestBlackThreshold: number, // if pixel in test sample is brighter than that, we aren't looking at gradient
gradientTestDeltaThreshold: number, // if delta between two adjacent pixels in gradient test exceeds this, it's not gradient
gradientTestMinDelta: number, // if last pixels of the test sample is less than this brighter than the first -> not gradient
thresholds: {
edgeDetectionLimit: number, // during scanning of the edge, quit after edge gets detected at this many points
minQualitySingleEdge: number, // At least one of the detected must reach this quality
minQualitySecondEdge: number, // The other edge must reach this quality (must be smaller or equal to single edge quality)
}
maxLetterboxOffset: 0.1, // Upper and lower letterbox can be different by this many (% of height)
// Previous iteration variables VVVV
sampleWidth: number, // we take a sample this wide for edge detection
detectionThreshold: number, // sample needs to have this many non-black pixels to be a valid edge
confirmationThreshold: number, //
singleSideConfirmationThreshold: number, // we need this much edges (out of all samples, not just edges) in order
// to confirm an edge in case there's no edges on top or bottom (other
// than logo, of course)
logoThreshold: number, // if edge candidate sits with count greater than this*all_samples, it can't be logo
// or watermark.
edgeTolerancePx?: number, // we check for black edge violation this far from detection point
edgeTolerancePercent?: number, // we check for black edge detection this % of height from detection point. unused
middleIgnoredArea: number, // we ignore this % of canvas height towards edges while detecting aspect ratios
minColsForSearch: number, // if we hit the edge of blackbars for all but this many columns (%-wise), we don't
// continue with search. It's pointless, because black edge is higher/lower than we
// are now. (NOTE: keep this less than 1 in case we implement logo detection)
},
pillarTest: {
ignoreThinPillarsPx: number, // ignore pillars that are less than this many pixels thick.
allowMisaligned: number // left and right edge can vary this much (%)
},
textLineTest: {
nonTextPulse: number, // if a single continuous pulse has this many non-black pixels, we aren't dealing
// with text. This value is relative to canvas width (%)
pulsesToConfirm: number, // this is a threshold to confirm we're seeing text.
pulsesToConfirmIfHalfBlack: number, // this is the threshold to confirm we're seeing text if longest black pulse
// is over 50% of the canvas width
testRowOffset: number // we test this % of height from detected edge
}
}
interface SettingsInterface {
_updateFlags?: {
requireReload?: SettingsReloadFlags,
forSite?: string
}
arDetect: AardSettings,
ui: {
inPlayer: {
enabled: boolean,
enabledFullscreenOnly: boolean,
popupAlignment: 'left' | 'right',
minEnabledWidth: number, // don't show UI if player is narrower than % of screen width
minEnabledHeight: number, // don't show UI if player is narrower than % of screen height
activation: 'trigger-zone' | 'player', // what needs to be hovered in order for UI to be visible
triggerZoneDimensions: { // how large the trigger zone is (relative to player size)
width: number
height: number,
offsetX: number, // fed to translateX(offsetX + '%'). Valid range [-100, 0]
offsetY: number // fed to translateY(offsetY + '%'). Valid range [-100, 100]
},
}
}
restrictions?: RestrictionsSettings;
crop: {
default: any;
},
stretch: {
default: any;
conditionalDifferencePercent: number // black bars less than this wide will trigger stretch
// if mode is set to '1'. 1.0=100%
},
kbm: {
enabled: boolean, // if keyboard/mouse handler service will run
keyboardEnabled: boolean, // if keyboard shortcuts are processed
mouseEnabled: boolean, // if mouse movement is processed
}
zoom: {
minLogZoom: number,
maxLogZoom: number,
announceDebounce: number // we wait this long before announcing new zoom
},
miscSettings: {
mousePan: {
enabled: boolean
},
mousePanReverseMouse: boolean,
defaultAr?: any
},
resizer: {
setStyleString: {
maxRetries: number,
retryTimeout: number
}
},
pageInfo: {
timeouts: {
urlCheck: number,
rescan: number
}
},
pan?: any,
version?: string,
preventReload?: boolean,
// -----------------------------------------
// ::: MITIGATIONS :::
// -----------------------------------------
// Settings for browser bug workarounds.
mitigations?: {
zoomLimit?: {
enabled?: boolean,
fullscreenOnly?: boolean,
limit?: number,
}
}
// -----------------------------------------
// ::: ACTIONS :::
// -----------------------------------------
// Nastavitve za ukaze. Zamenja stare nastavitve za bližnične tipke.
//
// Polje 'shortcut' je tabela, če se slučajno lotimo kdaj delati choordov.
actions: {
name?: string, // name displayed in settings
label?: string, // name displayed in ui (can be overridden in scope/playerUi)
cmd?: {
action: string,
arg: any,
customArg?: any,
persistent?: boolean, // optional, false by default. If true, change doesn't take effect immediately.
// Instead, this action saves stuff to settings
}[],
scopes?: {
global?: ActionScopeInterface,
site?: ActionScopeInterface,
page?: ActionScopeInterface
},
playerUi?: {
show: boolean,
path?: string,
},
userAdded?: boolean,
}[],
// This object fulfills the same purpose as 'actions', but is written in less retarded and overly
// complicated way. Hopefully it'll be easier to maintain it that way.
commands?: {
crop?: CommandInterface[],
stretch?: CommandInterface[],
zoom?: CommandInterface[],
pan?: CommandInterface[],
internal?: CommandInterface[],
},
whatsNewChecked: boolean,
newFeatureTracker: any,
// -----------------------------------------
// ::: SITE CONFIGURATION :::
// -----------------------------------------
// Config for a given page:
//
// <hostname> : {
// status: <option> // should extension work on this site?
// arStatus: <option> // should we do autodetection on this site?
//
// defaultAr?: <ratio> // automatically apply this aspect ratio on this side. Use extension defaults if undefined.
// stretch? <stretch mode> // automatically stretch video on this site in this manner
// videoAlignment? <left|center|right>
//
// type: <official|community|user> // 'official' — blessed by Tam.
// // 'community' — blessed by reddit.
// // 'user' — user-defined (not here)
// override: <true|false> // override user settings for this site on update
// }
//
// Valid values for options:
//
// status, arStatus, statusEmbedded:
//
// * enabled — always allow, full
// * basic — allow, but only the basic version without playerData
// * default — allow if default is to allow, block if default is to block
// * disabled — never allow
//
sites: {
[x: string]: SiteSettingsInterface,
}
}
export interface SiteSettingsInterface {
enable: ExtensionEnvironmentSettingsInterface;
enableAard: ExtensionEnvironmentSettingsInterface;
enableKeyboard: ExtensionEnvironmentSettingsInterface;
type?: 'official' | 'community' | 'user-defined' | 'testing' | 'officially-disabled' | 'unknown' | 'modified';
defaultType: 'official' | 'community' | 'user-defined' | 'testing' | 'officially-disabled' | 'unknown' | 'modified';
// must be defined in @global and @empty
persistCSA?: CropModePersistence, // CSA - crop, stretch, alignment
defaults?: { // must be defined in @global and @empty
crop?: {type: AspectRatioType, [x: string]: any},
stretch?: StretchType,
alignment?: {x: VideoAlignmentType, y: VideoAlignmentType},
}
cropModePersistence?: CropModePersistence;
stretchModePersistence?: CropModePersistence;
alignmentPersistence?: CropModePersistence;
activeDOMConfig?: string;
DOMConfig?: { [x: string]: SiteDOMSettingsInterface };
// the following script are for extension caching and shouldn't be saved.
// if they _are_ saved, they will be overwritten
currentDOMConfig?: SiteDOMSettingsInterface;
// the following fields are for use with extension update script
override?: boolean; // whether settings for this site will be overwritten by extension upgrade script
}
export interface SiteDOMSettingsInterface {
type: 'official' | 'community' | 'user-defined' | 'modified' | undefined;
elements?: {
player?: SiteDOMElementSettingsInterface,
video?: SiteDOMElementSettingsInterface,
other?: { [x: number]: SiteDOMElementSettingsInterface }
};
customCss?: string;
periodicallyRefreshPlayerElement?: boolean;
// the following script are for extension caching and shouldn't be saved.
// if they _are_ saved, they will be overwritten
anchorElementIndex?: number;
anchorElement?: HTMLElement;
}
export interface SiteDOMElementSettingsInterface {
manual?: boolean;
querySelectors?: string;
index?: number; // previously: useRelativeAncestor + videoAncestor
mode?: 'index' | 'qs';
nodeCss?: {[x: string]: string};
}
export default SettingsInterface;

View File

@ -0,0 +1,33 @@
/**
* For some reason, Chrome really doesn't like when chrome.runtime
* methods are wrapped inside a ES6 proxy object. If 'port' is a
* ES6 Proxy of a Port object that `chrome.runtime.connect()` creates,
* then Chrome will do bullshits like `port.sendMessage` and
* `port.onMessage.addListener` crashing your Vue3 UI with bullshits
* excuses, e.g.
*
* | TypeError: Illegal invocation. Function must be called on
* | an object of type Port
*
* which is some grade A bullshit because Firefox can handle that just
* fine.
*
* There's two ways how I could handle this:
* * Find out how to get the original object from the proxy Vue3
* creates, which would take time and ruin my xmass holiday, or
* * make a global object with a passive-aggressive name and ignore
* the very real possibility that there's prolly a reason Chrome
* does things in its own very special(tm) way, as if it had one
* extra chromosome over Firefox.
*
* Easy choice, really.
*/
export class ChromeShittinessMitigations {
static port = null;
static setProperty(property, value) {
ChromeShittinessMitigations[property] = value;
}
}
export default ChromeShittinessMitigations;

24
src/common/js/IO.ts Normal file
View File

@ -0,0 +1,24 @@
class IO {
/**
* Export a (presumably json) string to file. Meant for use with content script.
* @param {*} jsonString string to be saved
*/
static async csStringToFile(jsonString) {
console.info("\n\n\n\n---------- Starting export of log to file ----------------");
console.info("[info] json string for exportObject:", jsonString.length);
const blob = new Blob([jsonString], {type: 'application/json'});
const fileUrl = URL.createObjectURL(blob);
const a = document.createElement('a');
a.style.display = 'none';
a.href = fileUrl;
a.download = 'ultrawidify-log.log';
document.body.appendChild(a);
a.click();
window.URL.revokeObjectURL(fileUrl);
}
}
export default IO;

View File

@ -0,0 +1,40 @@
class KeyboardShortcutParser {
static parseShortcut(keypress) {
let shortcutCombo = '';
if (keypress.ctrlKey) {
shortcutCombo += 'Ctrl + ';
}
if (keypress.shiftKey) {
shortcutCombo += 'Shift + ';
}
if (keypress.metaKey) {
shortcutCombo += 'Meta + ';
}
if (keypress.altKey) {
shortcutCombo += 'Alt + ';
}
if (keypress.key) {
shortcutCombo += keypress.key.toUpperCase();
} else {
shortcutCombo += '<mouse action>'
}
return shortcutCombo;
}
static generateShortcutFromKeypress(event) {
return {
ctrlKey: event.ctrlKey,
altKey: event.altKey,
shiftKey: event.shiftKey,
metaKey: event.metaKey,
code: event.code,
key: event.key,
keyup: true,
keydown: false,
type: event.type, // only needed for purposes of EditShortcutButton
}
}
}
export default KeyboardShortcutParser;

18
src/common/js/utils.ts Normal file
View File

@ -0,0 +1,18 @@
export async function sleep(timeout) {
return new Promise<void>( (resolve, reject) => setTimeout(() => resolve(), timeout));
}
/**
* Creates deep copy of an object
* @param obj
* @returns
*/
export function _cp(obj) {
try {
return JSON.parse(JSON.stringify(obj));
} catch (e) {
// console.error('Failed to parse json. This probably means that the data we received was not an object. Will return data as-is');
// console.error('data in:', obj, 'error:', e);
return obj;
}
}

View File

@ -0,0 +1,17 @@
<template>
<div>
<p><i><a href="https://www.youtube.com/watch?v=Mn3YEJTSYs8&feature=youtu.be&t=770" target='_blank'>...</a> but as is normal, you can't use a free extensions without the developers begging for money. It's the bi-daily beggathon here on ... wherever here is.</i>
</p>
<p>
Jokes and references few will get aside, developing this extension does take a decent amount of time, motivation, carefully calibrated quantities
of alcohol and enough coffee to bankrupt a small nation.
</p>
<p>If you want to buy me a beer or bankroll my caffeine addiction, you can do so by <a href="https://paypal.me/tamius">clicking here</a>. All donations are appreciated.
</p>
</div>
</template>
<script>
</script>

View File

@ -1,57 +0,0 @@
// Yeah hi /r/badcode.
// Anyway, because nazi localstorage flat out refuses to store arrays:
var DEFAULT_KEYBINDINGS = {
0:{ action: "fitw",
key: 'w',
modifiers: []
},
1:{
action: "fith",
key: 'e',
modifiers: []
},
2: {
action: "reset",
key: 'r',
modifiers: []
},
3: {
action: "zoom",
key: "z",
modifiers: []
},
4: {
action: "unzoom",
key: "u",
modifiers: []
},
5: {
action: "char",
targetAR: (21/9),
key: "d",
modifiers: []
},
6: {
action: "char",
targetAR: (16/9),
key: "s",
modifiers: []
},
7: {
action: "char",
targetAR: (16/10),
key: "x",
modifiers: []
},
8: {
action: "char",
targetAR: (4/3),
key: "c",
modifiers: []
},
9: {
action: "autoar",
key: "a",
modifiers: []
}
};

View File

@ -1,91 +0,0 @@
var UW_SITES = {
youtube: {
enabled: true,
type: "official",
urlRules: ["youtu"],
player: {
name: "movie_player",
isClass: false,
},
iframe: {
name: "player",
isClass: false
},
ui: {
uiMode: "native",
uiconf: {
sampleButton: {
class: "ytp-button ytp-settings-button",
index: 0,
buttonSizeBase: "x",
},
uiParent: {
name: "ytp-right-controls",
isClass: true,
insertStrat: "prepend",
},
uiOffset: {
offsetBy: "10vh",
offsetType: "css"
}
}
},
autoar_imdb:{
enabled: false
}
},
netflix: {
enabled: true,
type: "official",
urlRules: ["netflix"],
player: {
name: "placeholder",
isClass: true,
},
ui: {
uiMode: "native",
uiconf: {
sampleButton: {
class: "ytp-button ytp-settings-button",
index: 0,
buttonSizeBase: "x",
},
uiParent: {
name: "player-controls-wrapper",
isClass: true,
insertStrat: "append"
},
uiOffset: {
offsetBy: "0px",
offsetType: "css"
}
}
},
autoar_imdb:{
enabled: true,
title: "player-status-main-title",
isClass: true
}
},
dummy: {
type: "add new site",
urlRules: [""],
player: {
name: "",
isClass: false,
},
sampleButton: {
class: "ytp-button ytp-settings-button",
index: 0,
buttonSizeBase: "x",
},
uiParent: {
name: "",
isClass: false,
insertStrat: "prepend",
},
autoar_imdb:{
enabled: false
}
}
}

View File

@ -1,116 +0,0 @@
var UW_UI_BUTTONS = {
fitw: {
native_bar: true,
has_submenu: false,
button: true,
icon: "/res/img/ytplayer-icons/fitw.png",
text: "Fit to width",
onclick: function(){ changeCSS("fit", "fitw") }
},
fith: {
native_bar: true,
has_submenu: false,
button: true,
icon: "/res/img/ytplayer-icons/fith.png",
text: "Fit to height",
onclick: function(){ changeCSS("fit", "fith") }
},
reset: {
native_bar: true,
has_submenu: false,
button: true,
icon: "/res/img/ytplayer-icons/reset.png",
text: "Reset",
onclick: function(){ changeCSS("reset", "reset") }
},
zoom: {
native_bar: true,
has_submenu: false,
button: true,
icon: "/res/img/ytplayer-icons/zoom.png",
text: "Zoom",
onclick: function(){ changeCSS("fit", "zoom") }
},
unzoom: {
native_bar: true,
has_submenu: false,
button: true,
icon: "/res/img/ytplayer-icons/unzoom.png",
text: "Unzoom",
onclick: function(){ changeCSS("fit", "unzoom") }
},
zoom: {
native_bar: true,
has_submenu: false,
button: true,
icon: "/res/img/ytplayer-icons/zoom.png",
text: "Reset",
onclick: function(){ changeCSS("fit", "zoom") }
},
autoar: {
native_bar: false,
has_submenu: false,
button: false,
text: "Detect aspect ratio via 3rd party",
onclick: function(){ manual_autoar()}
},
settings: {
native_bar: true,
button: true,
icon: "/res/img/ytplayer-icons/settings.png",
text: "Settings",
has_submenu: true,
submenu: [ "fitw","fith","reset","zoom","unzoom","autoar","ar" ],
top_level: true,
submenu_id: "uw_settings_menu",
onclick: function(){ toggleMenu("uw_settings_menu") }
},
ar: {
native_bar: false,
button: false,
text: "Force aspect ratio",
has_submenu: true,
submenu: [ "ar219", "ar169", "ar1610", "ar43" ],
submenu_id: "uw_force_ar_menu",
onclick: function(){ showMenu("uw_force_ar_menu") }
},
ar219: {
native_bar: false,
button: false,
text: "21:9",
has_submenu: false,
onclick: function(){ changeCSS("char", ( 21/9 )); }
},
ar169: {
native_bar: false,
button: false,
text: "16:9",
has_submenu: false,
onclick: function(){ changeCSS("char", ( 16/9 )); }
},
ar1610: {
native_bar: false,
button: false,
text: "16:10",
has_submenu: false,
onclick: function(){ changeCSS("char", ( 1.6 )); }
},
ar43: {
native_bar: false,
button: false,
text: "4:3",
has_submenu: false,
onclick: function(){ changeCSS("char", ( 4/3 )); }
}
}
var UW_UI_BANLIST = {
youtube: {
autoar: "all"
},
netflix: {
settings: "all"
}
}

View File

@ -1 +0,0 @@

69
src/csui/GlobalFrame.vue Normal file
View File

@ -0,0 +1,69 @@
<template>
<div class="uw-clickthrough relative w-100 h-100">
<template v-for="rectangle of drawnRectangles" :key="rectangle.id ?? rectangle">
<!-- Player element overlays -->
<div class="absolute z-index-overlay"
:style="rectangle.style"
>
<!-- used for drawing player element overlay rectangles - keep this section empty -->
</div>
<!-- Notification overlay -->
<div class="absolute z-index-notification notification-area">
<template v-for="notification of displayedNotifications" :key="notification.id">
<div class="notification d-flex flex-row">
<div class="notification-icon">
<mdicon :name="notification.icon ?? 'alert'" :size="128"></mdicon>
</div>
<div class="notification-text">
<h3 class="notification-title">{{ notification.title }}</h3>
<p class="notification-verbose">{{ notification.text }}</p>
</div>
</div>
</template>
</div>
</template>
</div>
</template>
<script>
import UIProbeMixin from './src/utils/UIProbeMixin';
export default {
components: {
},
mixins: [
UIProbeMixin
],
data() {
return {
drawnRectangles: [],
displayedNotifications: [],
}
},
async created() {
this.logger = new Logger();
// this prolly needs to be taken out
await this.logger.init({
allowLogging: true,
});
/**
* Setup the "companion" onMouseMove handler to the one in the content script.
* We can handle events with the same function we use to handle events from
* the content script.
*/
document.addEventListener('mousemove', (event) => {
this.handleProbe({
coords: {
x: event.clientX,
y: event.clientY
}
}, this.origin);
});
}
}
</script>

687
src/csui/PlayerOverlay.vue Normal file
View File

@ -0,0 +1,687 @@
<template>
<div
class="context-spawn uw-ui-area"
style="z-index: 1000;"
v-if="!triggerZoneEditorVisible"
>
<div
class="spawn-container uw-ui-trigger"
:style="triggerZoneStyles"
>
&nbsp;
</div>
</div>
<div
v-if="contextMenuActive || settingsInitialized && uwTriggerZoneVisible && !isGlobal"
class="context-spawn uw-clickable uw-ui-area"
style="z-index: 1001"
>
<GhettoContextMenu
alignment="right" class="uw-menu"
@mouseenter="() => {preventContextMenuHide(); newFeatureViewUpdate('uw6.ui-popup')}"
@mouseleave="allowContextMenuHide()"
>
<template v-slot:activator>
<div class="context-item">
Ultrawidify
</div>
</template>
<slot>
<!--
Didn't manage to ensure that extension status pops up above other menu items in less than 3 minutes with z-index,
so wrapping 'status' and 'real menu items' in two different divs, ordering them in the opposite way, and then
ensuring correct ordering with flex-direction: column-reverse ended up being easier and faster.
-->
<div class="menu-width flex-reverse-order">
<div style="z-index: 1000">
<GhettoContextMenu alignment="right">
<template v-slot:activator>
Crop
</template>
<slot>
<GhettoContextMenuOption
v-for="(command, index) of settings?.active.commands.crop"
:key="index"
:label="command.label"
:shortcut="getKeyboardShortcutLabel(command)"
@click="execAction(command)"
>
</GhettoContextMenuOption>
</slot>
</GhettoContextMenu>
<GhettoContextMenu alignment="right">
<template v-slot:activator>
Stretch
</template>
<slot>
<GhettoContextMenuOption
v-for="(command, index) of settings?.active.commands.stretch"
:key="index"
:label="command.label"
:shortcut="getKeyboardShortcutLabel(command)"
@click="execAction(command)"
>
</GhettoContextMenuOption>
</slot>
</GhettoContextMenu>
<GhettoContextMenu alignment="right">
<template v-slot:activator>
<div class="context-item">
Align
</div>
</template>
<slot>
<GhettoContextMenuItem :disableHover="true" :css="{'reduced-padding': true}">
<AlignmentOptionsControlComponent
:eventBus="eventBus"
>
</AlignmentOptionsControlComponent>
</GhettoContextMenuItem>
</slot>
</GhettoContextMenu>
<!-- shortcut for configuring UI -->
<GhettoContextMenuOption
v-if="settings.active.newFeatureTracker?.['uw6.ui-popup']?.show > 0"
@click="showUwWindow('playerUiSettings')"
>
<span style="color: #fa6;">Change when and if<br/>this popup appears</span>
<span style="font-size: 0.8rem">
<span style="font-size: 0.8rem; opacity: 0.5">This menu option will show {{settings.active.newFeatureTracker?.['uw6.ui-popup']?.show}} more<br/> times; or until clicked or dismissed.<br/>
Also accessible via:<br/> <span style="font-size: 0.85em">EXTENSION SETTINGS > UI AND KEYBOARD</span>.
</span>
<br/>
<a style="color: #fa6; cursor: pointer;" @click="() => acknowledgeNewFeature('uw6.ui-popup')">Dismiss this option</a>
</span>
</GhettoContextMenuOption>
<!-- -->
<GhettoContextMenuOption
@click="showUwWindow()"
label="Extension settings"
>
</GhettoContextMenuOption>
<GhettoContextMenuOption
@click="showUwWindow('playerDetection')"
label="Incorrect cropping?"
>
</GhettoContextMenuOption>
<GhettoContextMenuOption
@click="showUwWindow('about')"
label="Not working?"
>
</GhettoContextMenuOption>
</div>
<div style="z-index: 10000">
<GhettoContextMenuItem
class="extension-status-messages"
:disableHover="true"
>
Site compatibility:
<SupportLevelIndicator
:siteSupportLevel="siteSupportLevel"
>
</SupportLevelIndicator>
<div v-if="statusFlags.hasDrm" class="aard-blocked">
Autodetection potentially<br/>
unavailable due to <a href="https://en.wikipedia.org/wiki/Digital_rights_management">DRM</a>.
</div>
<div v-else-if="statusFlags.aardErrors?.cors" class="aard-blocked">
Autodetection blocked<br/>
by site/browser (CORS).
</div>
<div v-else-if="statusFlags.aardErrors?.webglError" class="aard-blocked">
Autodetection unavailable<br/>
due to webgl error.
</div>
</GhettoContextMenuItem>
</div>
</div>
</slot>
</GhettoContextMenu>
</div>
<div
v-if="settingsInitialized && uwWindowVisible"
class="uw-window flex flex-col uw-clickable uw-ui-area"
:class="{'fade-out': uwWindowFadeOut}"
>
<PlayerUIWindow
:settings="settings"
:eventBus="eventBus"
:logger="logger"
:in-player="!isGlobal"
:site="site"
:defaultTab="defaultWindowTab"
@close="uwWindowVisible = false"
@preventClose="(event) => uwWindowFadeOutDisabled = event"
></PlayerUIWindow>
</div>
<div
v-if="triggerZoneEditorVisible"
class="context-spawn uw-ui-area"
style="z-index: 1000;"
>
<TriggerZoneEditor
:settings="settings"
:eventBus="eventBus"
:playerDimensions="playerDimensions"
>
</TriggerZoneEditor>
</div>
</template>
<script>
import PlayerUIWindow from './src/PlayerUIWindow.vue';
import GhettoContextMenu from './src/components/GhettoContextMenu.vue';
import GhettoContextMenuItem from './src/components/GhettoContextMenuItem.vue';
import GhettoContextMenuOption from './src/components/GhettoContextMenuOption.vue';
import AlignmentOptionsControlComponent from './src/PlayerUiPanels/AlignmentOptionsControlComponent.vue';
import BrowserDetect from '../ext/conf/BrowserDetect';
import Logger from '../ext/lib/Logger';
import Settings from '../ext/lib/Settings';
import EventBus from '../ext/lib/EventBus';
import UIProbeMixin from './src/utils/UIProbeMixin';
import KeyboardShortcutParserMixin from './src/utils/KeyboardShortcutParserMixin';
import CommsMixin from './src/utils/CommsMixin';
import SupportLevelIndicator from './src/components/SupportLevelIndicator.vue';
import TriggerZoneEditor from './src/components/TriggerZoneEditor.vue';
export default {
components: {
PlayerUIWindow,
GhettoContextMenu,
GhettoContextMenuItem,
GhettoContextMenuOption,
AlignmentOptionsControlComponent,
SupportLevelIndicator,
TriggerZoneEditor,
},
mixins: [
UIProbeMixin,
KeyboardShortcutParserMixin,
CommsMixin
],
data() {
return {
uwTriggerZoneVisible: false,
uwTriggerZoneTimeout: undefined,
uwTriggerRegionConf: {
left: "10%",
top: "10%",
height: "30%",
width: "30%",
maxWidth: "24rem",
maxHeight: "13.37rem",
},
uwWindowFadeOutDisabled: false,
uwWindowFadeOut: false,
uwWindowCloseTimeout: undefined,
uwWindowVisible: false,
triggerZoneEditorVisible: false,
// component properties
settings: {},
BrowserDetect: BrowserDetect,
settingsInitialized: false,
eventBus: new EventBus(),
logger: null,
// NOTE: chromium doesn't allow us to access window.parent.location
// meaning we will have to correct this value from our uwui-probe
// messages ... which is a bummer.
site: null,
origin: '*', // will be set appropriately once the first uwui-probe event is received
lastProbeTs: null,
isGlobal: true,
disabled: false,
contextMenuActive: false,
triggerZoneActive: false,
uiVisible: true,
debugData: {
resizer: {},
player: {},
},
debugDataPrettified: '',
// in global overlay, this property is used to determine
// if closing the window should emit uw-set-ui-state
// event on eventBus
showPlayerUIAfterClose: false,
statusFlags: {
hasDrm: undefined,
aardErrors: undefined,
},
defaultWindowTab: 'videoSettings',
saveState: {},
siteSettings: undefined,
previewZoneVisible: false,
};
},
computed: {
// LPT: NO ARROW FUNCTIONS IN COMPUTED,
// IS SUPER HARAM
// THINGS WILL NOT WORK IF YOU USE ARROWS
windowWidth() {
return window.innerWidth;
},
windowHeight() {
return window.innerHeight;
},
// LPT: NO ARROW FUNCTIONS IN COMPUTED,
// IS SUPER HARAM
// THINGS WILL NOT WORK IF YOU USE ARROWS
siteSupportLevel() {
return (this.site && this.siteSettings) ? this.siteSettings.data.type || 'no-support' : 'waiting';
}
},
watch: {
showUi(visible) {
if (visible !== undefined) {
this.uiVisible = visible;
}
},
resizerDebugData(newData) {
this.debugData.resizer = newData;
this.debugDataPrettified = JSON.stringify(this.debugData, null, 2);
},
playerDebugData(newData) {
this.debugData.player = newData;
this.debugDataPrettified = JSON.stringify(this.debugData, null, 2);
}
},
async created() {
this.logger = new Logger();
// this prolly needs to be taken out
await this.logger.init({
allowLogging: true,
});
this.settings = new Settings({afterSettingsSaved: this.updateConfig, logger: this.logger});
this.settings.listenAfterChange(() => this.updateTriggerZones());
await this.settings.init();
this.settingsInitialized = true;
// set up communication with client script.
// NOTE: companion onmousemove is set up in UIProbeMixin
window.addEventListener('message', event => {
this.handleMessage(event);
});
this.eventBus.subscribe('uw-config-broadcast', {function: (data) => {
switch (data.type) {
case 'drm-status':
this.statusFlags.hasDrm = data.hasDrm;
break;
case 'aard-error':
this.statusFlags.aardErrors = data.aardErrors;
break;
case 'player-dimensions':
this.playerDimensionsUpdate(data.data);
break;
}
}});
this.eventBus.subscribe('uw-set-ui-state', { function: (data) => {
if (data.globalUiVisible !== undefined) {
if (this.isGlobal) {
if (data.globalUiVisible) {
this.showUwWindow();
} else {
this.hideUwWindow(true);
}
// this.showPlayerUIAfterClose = data.showPlayerUIAfterClose;
} else {
// non global UIs are hidden while global overlay
// is visible and vice versa
// this.disabled = data.globalUiVisible;
this.saveState = {
uwWindowVisible: this.uwWindowVisible,
uwWindowFadeOutDisabled: this.uwWindowFadeOutDisabled,
uwWindowFadeOut: this.uwWindowFadeOut
};
this.uwWindowFadeOutDisabled = false;
this.hideUwWindow(true);
}
}
}});
this.eventBus.subscribe(
'uw-restore-ui-state',
{
function: (data) => {
if (this.saveState) {
if (this.saveState.uwWindowVisible) {
this.showUwWindow();
}
this.uwWindowFadeOutDisabled = this.saveState.uwWindowFadeOutDisabled;
this.uwWindowFadeOut = this.saveState.uwWindowFadeOut;
}
this.saveState = {};
}
}
);
this.eventBus.subscribe('ui-trigger-zone-update', {
function: (data) => {
this.showTriggerZonePreview = data.previewZoneVisible;
// this.;
}
});
this.eventBus.subscribe(
'start-trigger-zone-edit',
{
function: () => {
this.triggerZoneEditorVisible = true;
this.uwWindowVisible = false;
}
}
);
this.eventBus.subscribe(
'finish-trigger-zone-edit',
{
function: () => {
this.triggerZoneEditorVisible = false;
this.showUwWindow('playerUiSettings');
}
}
);
this.sendToParentLowLevel('uwui-get-role', null);
this.sendToParentLowLevel('uwui-get-theme', null);
this.sendToParentLowLevel('uw-bus-tunnel', {
action: 'get-player-dimensions'
});
},
methods: {
/**
* Gets URL of the browser settings page (i think?)
*/
getUrl(url) {
return BrowserDetect.getURL(url);
},
/**
* Mostly intended to process messages received via window.addEventListener('message').
* This method should include minimal logic instead, it should only route messages
* to the correct function down the line.
*/
handleMessage(event) {
switch (event.data.action) {
case 'uwui-probe':
if (!this.site) {
this.origin = event.origin;
this.site = event.origin.split('//')[1];
this.siteSettings = this.settings.getSiteSettings(this.site);
}
return this.handleProbe(event.data, event.origin); // handleProbe is defined in UIProbeMixin
case 'uw-bus-tunnel':
return this.handleBusTunnelIn(event.data.payload);
case 'uwui-set-role':
this.isGlobal = event.data.payload.role === 'global';
this.sendToParentLowLevel('uwui-interface-ready', true);
break;
}
},
/**
* Handles trigger zone
*/
handleTriggerZone(mouseInside) {
// this.triggerZoneActive = mouseInside;
},
acknowledgeNewFeature(featureKey) {
delete this.settings.active.newFeatureTracker[featureKey];
this.settings.saveWithoutReload();
},
newFeatureViewUpdate(featureKey) {
if (!this.settings.active.newFeatureTracker[featureKey]) {
return;
}
try {
this.settings.active.newFeatureTracker[featureKey].show--;
this.settings.saveWithoutReload();
if (this.settings.active.newFeatureTracker[featureKey]?.show < 0) {
this.acknowledgeNewFeature(featureKey);
}
} catch (e) {
// do nothing
}
},
/**
* Sends message to parent _without_ using event bus.
*/
sendToParentLowLevel(action, payload, lowLevelExtras = {}) {
window.parent.postMessage(
{
action, payload, ...lowLevelExtras
},
'*'
);
},
preventContextMenuHide() {
this.contextMenuActive = true;
},
allowContextMenuHide() {
this.contextMenuActive = false;
},
setTriggerZoneActive(active, event) {
this.triggerZoneActive = active;
},
showUwWindow(tab) {
this.defaultWindowTab = tab; // can be undefined
this.uwWindowFadeOut = false;
this.uwWindowVisible = true;
this.uwTriggerZoneVisible = false;
this.allowContextMenuHide();
// refresh DRM status
this.eventBus.send('get-drm-status');
// if (this.isGlobal) {
// this.sendToParentLowLevel('uwui-clickable', undefined, {clickable: true});
// }
},
hideUwWindow(skipTimeout = false) {
if (this.uwWindowFadeOutDisabled) {
return;
}
const timeout = skipTimeout ? 0 : 1100;
this.uwWindowCloseTimeout = setTimeout(
() => {
this.uwWindowVisible = false;
// Global UI has some extra housekeeping to do when window gets hidden
if (this.isGlobal) {
this.sendToParentLowLevel('uwui-global-window-hidden', {});
}
},
timeout
);
this.uwWindowFadeOut = true;
},
cancelUwWindowHide() {
this.uwWindowFadeOut = false;
clearTimeout(this.uwWindowCloseTimeout);
},
handleBusTunnelIn(payload) {
this.eventBus.send(payload.action, payload.config, payload.routingData);
}
}
}
</script>
<style lang="scss">
.ard-blocked {
color: rgb(219, 125, 48) !important;
background-color: rgba(0,0,0,0.85) !important;
}
</style>
<style lang="scss" src="./src/res-common/panels.scss" scoped module></style>
<style lang="scss" src="./src/res-common/common.scss" scoped module></style>
<style lang="scss" scoped>
.uw-hover {
position: absolute;
z-index: 999999999999999999;
}
.reduced-padding {
padding: 1rem !important;
}
.uv-hover-trigger-region {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
border: 0.5rem dashed #fff;
color: #fff;
backdrop-filter: blur(0.5rem) brightness(0.5);
}
.uw-window {
position: fixed;
top: 10%;
left: 10%;
z-index: 999999999999999999;
width: 2500px;
height: 1200px;
max-width: 80%;
max-height: 80%;
pointer-events: all !important;
opacity: 1;
backdrop-filter: blur(16px) saturate(120%);
&.fade-out {
opacity: 0;
transition: opacity 0.5s;
transition-delay: 0.5s;
}
}
.gib-bg {
background-color: rgba(0, 0, 0, 0.5);
backdrop-filter: blur(16px) saturate(120%);
width: fit-content;
block-size: fit-content;
}
.context-spawn {
position: absolute;
top: 0;
left: 0;
width: 100dvw;
height: 100dvh;
box-sizing: border-box;
overflow: hidden;
display: flex;
flex-direction: row;
align-content: center;
align-items: center;
// width: 100%;
// height: 100%;
color: #fff;
// .context-item {
// font-size: .95rem;
// padding: 1rem 1.6rem;
// background-color: rgba(0, 0, 0, 0.5);
// backdrop-filter: blur(16px) saturate(120%);
// white-space: nowrap;
// }
// .spawn-container {
// border: 1px solid white;
// }
}
.extension-status-messages {
z-index: 1000;
text-transform: uppercase;
display: flex;
flex-direction: column;
text-align: center;
width: 112.25%;
transform: translate(-12.5%, 12.5%) scale(0.75);
> * {
margin-top: 0.5rem;
margin-bottom: 0.5rem;
}
}
.flex-reverse-order {
display: flex;
flex-direction: column-reverse;
}
.aard-blocked {
color: #fa6;
}
.trigger-zone-preview {
border: 4px solid #fa4;
}
.debug-1 {
border: 1px solid yellow;
&:hover {
background-color: rbba(255,255,0,0.5);
}
}
.debug-2 {
border: 1px solid blue;
&:hover {
background-color: rbba(0,0,255,.5);
}
}
</style>

535
src/csui/Popup.vue Normal file
View File

@ -0,0 +1,535 @@
<template>
<div class="popup-panel">
<!--
NOTE the code that makes ultrawidify popup work in firefox regardless of whether the
extension is being displayed in a normal or a small/overflow popup breaks the popup
behaviour on Chrome (where the popup would never reach the full width of 800px)
Since I'm tired and the hour is getting late, we'll just add an extra CSS class for
non-firefox builds of this extension and be done with it. No need to complicate things
further than that.
-->
<div v-if="settingsInitialized"
class="popup flex flex-col no-overflow"
:class="{'popup-chrome': ! BrowserDetect?.firefox}"
>
<div class="flex-row flex-nogrow flex-noshrink relative header"
>
<div class="grow shrink">
<h1>
<span class="smallcaps">Ultrawidify</span>: <small>Quick settings</small>
</h1>
</div>
<div v-if="BrowserDetect?.processEnvChannel !== 'stable'" class="absolute channel-info version-info">
Build channel: {{BrowserDetect?.processEnvChannel}} <br/>
<label>Version:</label> <br/>
{{ settings.getExtensionVersion() }}
</div>
<div v-else class="version-info">
<label>Version:</label> <br/>
{{ settings.getExtensionVersion() }}
</div>
</div>
<!-- CONTAINER ROOT -->
<div class="flex flex-row body no-overflow flex-grow">
<!-- TABS -->
<div class="flex flex-col tab-row" style="flex: 3 3; border-right: 1px solid #222;">
<div
v-for="tab of tabs"
:key="tab.id"
class="tab flex flex-row"
:class="{'active': tab.id === selectedTab}"
@click="selectTab(tab.id)"
>
<div class="icon-container">
<mdicon
:name="tab.icon"
:size="32"
/>
</div>
<div class="label">
{{tab.label}}
</div>
</div>
</div>
<!-- CONTENT -->
<div class="scrollable" style="flex: 7 7; padding: 1rem;">
<template v-if="settings && siteSettings">
<InPlayerUIAdvertisement
v-if="selectedTab === 'playerUiCtl'"
:eventBus="eventBus"
/>
<PopupVideoSettings
v-if="selectedTab === 'videoSettings'"
:settings="settings"
:eventBus="eventBus"
:siteSettings="siteSettings"
></PopupVideoSettings>
<!-- <PlayerDetectionPanel
v-if="selectedTab === 'playerDetection'"
:settings="settings"
:eventBus="eventBus"
:siteSettings="siteSettings"
:site="site.host"
>
</PlayerDetectionPanel> -->
<BaseExtensionSettings
v-if="selectedTab === 'extensionSettings'"
:settings="settings"
:eventBus="eventBus"
:siteSettings="siteSettings"
:site="site.host"
>
</BaseExtensionSettings>
</template>
<template v-else>No settings or site settings found.</template>
</div>
</div>
</div>
</div>
</template>
<script>
import BaseExtensionSettings from './src/PlayerUiPanels/BaseExtensionSettings.vue'
import PlayerDetectionPanel from './src/PlayerUiPanels/PlayerDetectionPanel.vue'
import PopupVideoSettings from './src/popup/panels/PopupVideoSettings.vue'
import InPlayerUIAdvertisement from './src/PlayerUiPanels/InPlayerUiAdvertisement.vue';
import Debug from '../ext/conf/Debug';
import BrowserDetect from '../ext/conf/BrowserDetect';
import Comms from '../ext/lib/comms/Comms';
import CommsClient, {CommsOrigin} from '../ext/lib/comms/CommsClient';
import Settings from '../ext/lib/Settings';
import Logger from '../ext/lib/Logger';
import EventBus from '../ext/lib/EventBus';
import {ChromeShittinessMitigations as CSM} from '../common/js/ChromeShittinessMitigations';
export default {
data () {
return {
comms: undefined,
eventBus: new EventBus(),
settings: {},
settingsInitialized: false,
narrowPopup: null,
sideMenuVisible: null,
logger: undefined,
site: undefined,
siteSettings: undefined,
selectedTab: 'playerUiCtl',
tabs: [
// see this for icons: https://pictogrammers.com/library/mdi/
{id: 'playerUiCtl', label: 'In-player UI', icon: 'artboard'},
{id: 'videoSettings', label: 'Video settings', icon: 'crop'},
// {id: 'playerDetection', label: 'Player detection', icon: 'television-play'},
{id: 'extensionSettings', label: 'Site and Extension options', icon: 'cogs' },
],
}
},
async created() {
this.logger = new Logger();
await this.logger.init({
allowLogging: true,
});
this.settings = new Settings({afterSettingsSaved: () => this.updateConfig(), logger: this.logger});
await this.settings.init();
this.settingsInitialized = true;
// const port = chrome.runtime.connect({name: 'popup-port'});
// port.onMessage.addListener( (m,p) => this.processReceivedMessage(m,p));
// CSM.setProperty('port', port);
this.eventBus = new EventBus();
this.eventBus.subscribe(
'set-current-site',
{
function: (config, context) => {
if (this.site) {
if (!this.site.host) {
// dunno why this fix is needed, but sometimes it is
this.site.host = config.site.host;
}
}
this.site = config.site;
// this.selectedSite = this.selectedSite || config.site.host;
this.siteSettings = this.settings.getSiteSettings(this.site.host);
this.eventBus.setupPopupTunnelWorkaround({
origin: CommsOrigin.Popup,
comms: {
forwardTo: 'active'
}
});
this.loadFrames(this.site);
}
}
);
this.comms = new CommsClient('popup-port', this.logger, this.eventBus);
this.eventBus.setComms(this.comms);
this.eventBus.setupPopupTunnelWorkaround({
origin: CommsOrigin.Popup,
comms: {forwardTo: 'active'}
});
// ensure we'll clean player markings on popup close
window.addEventListener("unload", () => {
CSM.port.postMessage({
cmd: 'unmark-player',
forwardToAll: true,
});
// if (BrowserDetect.anyChromium) {
// chrome.extension.getBackgroundPage().sendUnmarkPlayer({
// cmd: 'unmark-player',
// forwardToAll: true,
// });
// }
});
// get info about current site from background script
while (true) {
this.requestSite();
await this.sleep(5000);
}
},
async updated() {
const body = document.getElementsByTagName('body')[0];
// ensure that narrowPopup only gets set the first time the popup renders
// if popup was rendered before, we don't do anything because otherwise
// we'll be causing an unwanted re-render
//
// another thing worth noting the popup gets first initialized with
// offsetWidth set to 0. This means proper popup will be displayed as a
// mini popup if we don't check for that.
if (this.narrowPopup === null && body.offsetWidth > 0) {
this.narrowPopup = body.offsetWidth < 600;
}
},
components: {
Debug,
BrowserDetect,
PopupVideoSettings, PlayerDetectionPanel, BaseExtensionSettings, InPlayerUIAdvertisement
},
methods: {
async sleep(t) {
return new Promise( (resolve,reject) => {
setTimeout(() => resolve(), t);
});
},
toObject(obj) {
return JSON.parse(JSON.stringify(obj));
},
requestSite() {
try {
this.logger.log('info','popup', '[popup::getSite] Requesting current site ...')
// CSM.port.postMessage({command: 'get-current-site'});
this.eventBus.send(
'get-current-site',
{
comms: {forwardTo: 'active'}
}
);
} catch (e) {
this.logger.log('error','popup','[popup::getSite] sending get-current-site failed for some reason. Reason:', e);
}
},
getRandomColor() {
return `rgb(${Math.floor(Math.random() * 128)}, ${Math.floor(Math.random() * 128)}, ${Math.floor(Math.random() * 128)})`;
},
selectTab(tab) {
this.selectedTab = tab;
},
processReceivedMessage(message, port) {
this.logger.log('info', 'popup', '[popup::processReceivedMessage] received message:', message)
if (message.command === 'set-current-site'){
if (this.site) {
if (!this.site.host) {
// dunno why this fix is needed, but sometimes it is
this.site.host = site.tabHostname;
}
}
this.site = message.site;
// update activeSites
// this.activeSites = this.activeSites.filter(x => x.host !== message.site);
// add current site
// this.activeSites = unshift({
// host: message.site.host,
// isIFrame: false, // currently unused
// });
this.selectedSite = this.selectedSite || message.site.host;
this.loadFrames(this.site);
}
return true;
},
isDefaultFrame(frameId) {
return frameId === '__playing' || frameId === '__all';
},
loadFrames() {
this.activeSites = [{
host: this.site.host,
isIFrame: false, // not used tho. Maybe one day
}];
this.selectedSite = this.selectedSite || this.site.host;
// for (const frame in videoTab.frames) {
// this.activeFrames.push({
// id: `${this.site.id}-${frame}`,
// label: videoTab.frames[frame].host,
// ...this.frameStore[frame],
// })
// // only add each host once at most
// if (!this.activeSites.find(x => x.host === videoTab.frames[frame].host)) {
// this.activeSites.push({
// host: videoTab.frames[frame].host,
// isIFrame: undefined // maybe one day
// });
// }
// }
// update whether video tab can be shown
// this.updateCanShowVideoTab();
},
getRandomColor() {
return `rgb(${Math.floor(Math.random() * 128)}, ${Math.floor(Math.random() * 128)}, ${Math.floor(Math.random() * 128)})`;
}
}
}
</script>
<style lang="scss">
// @import 'res/css/uwui-base.scss';
@import 'res/css/colors.scss';
@import 'res/css/font/overpass.css';
@import 'res/css/font/overpass-mono.css';
@import 'res/css/common.scss';
@import './src/res-common/_variables';
.header {
background-color: rgb(90, 28, 13);
color: #fff;
padding: 8px;
display: flex;
flex-direction: row;
justify-content: space-between;
h1 {
font-size: 2rem;
}
.version-info {
text-align: right;
font-size: 0.8rem;
opacity: 0.8;
label {
opacity: 0.5;
}
}
}
.site-support-info {
display: flex;
flex-direction: row;
align-items: center;
.site-support-site {
font-size: 1.5em;
}
.site-support {
display: inline-flex;
flex-direction: row;
align-items: center;
margin-left: 1rem;
border-radius: 8px;
padding: 0rem 1.5rem 0rem 1rem;
position: relative;
.tooltip {
padding: 1rem;
display: none;
position: absolute;
bottom: 0;
transform: translateY(110%);
width: 42em;
background-color: rgba(0,0,0,0.90);
color: #ccc;
}
&:hover {
.tooltip {
display: block;
}
}
.mdi {
margin-right: 1rem;
}
&.official {
background-color: #fa6;
color: #000;
.mdi {
fill: #000 !important;
}
}
&.community {
background-color: rgb(85, 85, 179);
color: #fff;
.mdi {
fill: #fff !important;
}
}
&.no-support {
background-color: rgb(138, 65, 126);
color: #eee;
.mdi {
fill: #eee !important;
}
}
&.user-added {
border: 1px solid #ff0;
color: #ff0;
.mdi {
fill: #ff0 !important;
}
}
}
}
.content {
flex-grow: 1;
.warning-area {
flex-grow: 0;
flex-shrink: 0;
}
.panel-content {
flex-grow: 1;
flex-shrink: 1;
overflow-y: auto;
padding: 1rem;
}
}
.warning-box {
background: rgb(255, 174, 107);
color: #000;
margin: 1rem;
padding: 1rem;
display: flex;
flex-direction: row;
align-items: center;
.icon-container {
margin-right: 1rem;
flex-shrink: 0;
flex-grow: 0;
}
a {
color: rgba(0,0,0,0.7);
cursor: pointer;
}
}
.popup-panel {
background-color: rgba(0,0,0,0.50);
color: #fff;
overflow-y: auto;
.popup-window-header {
padding: 1rem;
background-color: rgba(5,5,5, 0.75);
}
.tab-row {
background-color: rgba(11,11,11, 0.75);
.tab {
display: flex;
flex-direction: row;
align-items: center;
padding: 1rem;
font-size: 1.25rem;
// height: rem;
min-height: 3rem;
border-bottom: 1px solid rgba(128, 128, 128, 0.5);
border-top: 1px solid rgba(128, 128, 128, 0.5);
opacity: 0.5;
&:hover {
opacity: 1;
}
&.active {
opacity: 1.0;
background-color: $primaryBg;
color: rgb(255, 174, 107);
border-bottom: 1px solid rgba(116, 78, 47, 0.5);
border-top: 1px solid rgba(116, 78, 47, 0.5);
}
.icon-container {
width: 64px;
flex-grow: 0;
flex-shrink: 0;
}
.label {
flex-grow: 1;
flex-shrink: 1;
padding: 0 !important;
}
}
}
.popup-title, .popup-title h1 {
font-size: 48px !important;
}
}
pre {
white-space: pre-wrap;
}
.button {
border: 1px solid #222 !important;
}
h1 {
margin: 0; padding: 0; font-weight: 400; font-size:24px;
}
</style>

16
src/csui/csui-global.html Normal file
View File

@ -0,0 +1,16 @@
<!DOCTYPE html>
<html lang="en"; style="position: relative">
<head>
<meta charset="UTF-8">
<meta name="color-scheme" content="light dark">
<title>Ultrawidify - Content Script User Interface (global overlay)</title>
<!-- <link rel="stylesheet" href="csui.css"> -->
<% if (NODE_ENV === 'development') { %>
<!-- Load some resources only in development environment -->
<% } %>
</head>
<body class="uw-ultrawidify-container-root">
<div id="app"></div>
<script src="csui-global.js"></script>
</body>
</html>

11
src/csui/csui-global.js Normal file
View File

@ -0,0 +1,11 @@
import { createApp } from 'vue';
import GlobalFrame from './GlobalFrame';
import mdiVue from 'mdi-vue/v3';
import * as mdijs from '@mdi/js';
// NOTE — this is in-player interface for ultrawidify
// it is injected into the page in UI.init()
createApp(GlobalFrame)
.use(mdiVue, {icons: mdijs})
.mount('#app');

View File

@ -0,0 +1,13 @@
<!DOCTYPE html>
<html lang="en" style="position: relative">
<head>
<meta charset="UTF-8">
<meta name="color-scheme" content="dark">
<title>Ultrawidify - Content Script User Interface (in-player overlay)</title>
<!-- <link rel="stylesheet" href="csui.css"> -->
</head>
<body class="uw-ultrawidify-container-root" style="background-color: transparent;">
<div id="app"></div>
<script src="csui.js"></script>
</body>
</html>

View File

@ -0,0 +1,13 @@
<!DOCTYPE html>
<html lang="en" style="position: relative">
<head>
<meta charset="UTF-8">
<meta name="color-scheme" content="light">
<title>Ultrawidify - Content Script User Interface (in-player overlay)</title>
<!-- <link rel="stylesheet" href="csui.css"> -->
</head>
<body class="uw-ultrawidify-container-root" style="background-color: transparent;">
<div id="app"></div>
<script src="csui.js"></script>
</body>
</html>

View File

@ -0,0 +1,12 @@
<!DOCTYPE html>
<html lang="en" style="position: relative">
<head>
<meta charset="UTF-8">
<title>Ultrawidify - Content Script User Interface (in-player overlay)</title>
<!-- <link rel="stylesheet" href="csui.css"> -->
</head>
<body class="uw-ultrawidify-container-root" style="background-color: transparent;">
<div id="app"></div>
<script src="csui.js"></script>
</body>
</html>

20
src/csui/csui-popup.html Normal file
View File

@ -0,0 +1,20 @@
<!DOCTYPE html>
<html lang="en" style="position: relative">
<head>
<meta charset="UTF-8">
<title>Title</title>
<!-- <link rel="stylesheet" href="popup.css"> -->
<% if (NODE_ENV === 'development') { %>
<!-- Load some resources only in development environment -->
<% } %>
</head>
<body
style="width: 100%; height: 100%; overflow-x: hidden; min-width: 750px"
>
<div id="app">
</div>
<script src="csui-popup.js"></script>
</body>
</html>

8
src/csui/csui-popup.js Normal file
View File

@ -0,0 +1,8 @@
import { createApp } from 'vue'
import Popup from './Popup';
import mdiVue from 'mdi-vue/v3';
import * as mdijs from '@mdi/js';
createApp(Popup)
.use(mdiVue, {icons: mdijs})
.mount('#app');

11
src/csui/csui.js Normal file
View File

@ -0,0 +1,11 @@
import { createApp } from 'vue';
import PlayerOverlay from './PlayerOverlay';
import mdiVue from 'mdi-vue/v3';
import * as mdijs from '@mdi/js';
// NOTE — this is in-player interface for ultrawidify
// it is injected into the page in UI.init()
createApp(PlayerOverlay)
.use(mdiVue, {icons: mdijs})
.mount('#app');

View File

@ -0,0 +1,18 @@
$text-normal: #ddd;
$text-dim: #999;
$text-dark: #666;
$primary-color: #fb772a;
$primary: $primary-color;
$secondary-color: #e70c0c;
$input-background: #141414;
$input-border: #4e3527;
$page-background: #101010;
$popup-header-background: #7f1416;
$background-primary: #101010;
$selected-color: #f5cbaf;
$background-selected: #412d20;
$info-color: #bda9f3;

View File

@ -0,0 +1,396 @@
@import "colors.scss";
@import "fonts.scss";
@import "flex.scss";
// @import "~/@mdi/font/css/materialdesignicons.css";
// @import "form.scss";
body {
background-color: $background-primary;
color: $text-normal;
font-family: 'Overpass', sans-serif;
font-size: 1.2em;
width: 100%;
min-height: 100%;
height: 100vh;
border: 0px;
margin: 0px;
padding: 0px;
}
/* STANDARD WIDTHS AND HEIGHTS */
.w100 {
width: 100%;
}
.h100, .h-full {
height: 100%;
}
.w24 {
width: 100px;
}
.m-t-0-33em {
margin-top: 0.33em;
}
.x-pad-1em {
padding-left: 1em;
padding-right: 1em;
}
/* overflow stuff */
.overflow-y-auto {
overflow: auto;
scrollbar-width: thin;
scrollbar-color: rgba($primary-color, 0.7) $background-primary;
}
.scrollbar-darker {
scrollbar-color: rgba($primary-color, 0.5) $background-primary;
}
/* scrollbars for chrome/webkit */
.overflow-y-auto::-webkit-scrollbar {
width: 3px;
}
.overflow-y-auto::-webkit-scrollbar-track {
background: $background-primary;
}
.overflow-y-auto::-webkit-scrollbar-thumb {
background: rgba($primary-color, 0.7);
}
.overflow-y-auto::-webkit-scrollbar-button {
display: none;
}
.scrollbar-darker::-webkit-scrollbar-thumb {
background: rgba($primary-color, 0.5);
}
.no-overflow {
overflow: hidden;
}
.no-overflow-x {
overflow-x: hidden;
}
.no-overflow-y {
overflow-y: hidden;
}
/* .SELECTED CLASSES */
.selected-tab {
background-color: initial;
border-left: $primary-color 5px solid;
}
.selected-tab-secondary {
background-color: initial;
border-left: $secondary-color 3px solid !important;
}
/* BASIC STYLING */
.description {
color: $text-dim;
font-size: 1rem;
}
.label {
padding-top: 1.5rem;
font-size: 1.5rem;
font-variant: small-caps;
font-weight: 600;
}
.label-secondary {
font-weight: 600;
}
.button-box {
padding-top: 0.69rem;
padding-bottom: 0.69rem;
}
.indent {
padding-left: 4.2rem;
}
.row-padding {
padding-top: 0.69rem;
padding-bottom: 0.69rem;
}
a, a:visited {
color: $primary-color;
}
a:hover {
color: lighten($primary-color, 10%);
}
/* INPUT FORMATTING */
input[type="number"], input[type="text"], input {
outline: none;
background-color: $input-background;
color: $text-normal;
padding: 0.1rem;
padding-top: 0.2rem;
padding-bottom: 0.1rem;
margin-left: 1rem;
border: 1px solid $input-border;
}
input:disabled {
background: #444444;
color: darken($text-normal, 50%);
}
/* ELEMENT POSITIONING */
.row {
display: block;
margin-top: 20px;
margin-bottom: 10px;
}
.button-row {
display: block;
margin-top: 5px;
margin-bottom: 10px;
}
.float-left {
float: left;
}
.float-right {
float: right;
}
.inline-block {
display: inline-block;
}
.block {
display: block;
}
.hidden {
display: none !important;
}
.hide {
display: none !important;
}
/* TEXT FORMATTING (no colors) */
small {
font-size: 0.75em;
font-weight: 200;
}
.small {
font-size: 0.75em;
font-weight: 200;
}
.medium-small {
font-size: 0.85em;
font-weight: 200;
}
.smallcaps{
font-variant: small-caps;
}
.center{
text-align: center;
width: 100%;
}
.text-center {
text-align: center;
}
.invalid-input {
border: 1px solid #720 !important;
background-color: #410 !important;
}
.button {
/*display: inline-block;*/
// padding-top: 8px;
// padding-bottom: 3px;
//padding-left: 5px;
//padding-right: 5px;
border: 1px solid rgb(39, 39, 39);
margin-top: 3px;
margin-bottom: 3px;
color: $text-dim;
text-align: center;
cursor: pointer;
user-select: none;;
}
.selected, .setting-selected {
color: $selected-color !important;
background-color: $background-selected !important;
}
.selected-tab {
color: $selected-color;
}
.setting-selected {
border: 1px solid shade($selected-color, 25%);
}
.button:hover {
color: lighten($selected-color, 10%);
background-color: lighten($background-selected, 10%);
}
.disabled {
pointer-events: none;
/* color: #666; */
filter: contrast(50%) brightness(40%) grayscale(100%);
}
.disabled-button {
color: #666 !important;
cursor: not-allowed !important;
}
.disabled-button:hover {
color: #777 !important;
background-color: #222 !important;
}
/* BROWSER-SPECIFIC DISABLE */
.disabled-edge {
pointer-events: none !important;
filter: contrast(50%) brightness(40%) grayscale(100%) !important;
content: "NOT SUPPORTED IN THIS BROWSER";
}
.disabled-edge::after {
background-color: #333272;
color: #d8d9e6;
display: inline-block;
font-size: .75em;
font-variant: small-caps;
padding-left: 5px;
padding-right: 5px;
margin-left: 10px;
}
/** misc **/
.warning-color {
color: #d6ba4a;
}
.warning, .warning-lite {
color: #d6ba4a;
padding-left: 35px;
float: right;
}
.warning::before, .warning-lite::before {
content: "";
display: inline-block;
}
.warning::before {
font-weight: bold;
font-size: 2.5em;
margin-left: -35px;
padding-right: 10px;
}
.info {
color: $info-color;
padding-left: 35px;
float: right;
}
.info::before {
content: "";
display: inline-block;
font-weight: bold;
margin-left: -35px;
padding-right: 10px;
}
.new {
color: #fff;
}
.new::after {
content: "";
color: $info-color !important;
display: inline-block;
font-weight: bold;
padding-right: 10px;
}
.experimental::after {
// content: "Experimental";
content: "";
color: #ffde12;
// background-color: #1f1f1f;
display: inline-block;
font-size: .75em;
font-variant: small-caps;
padding-left: 5px;
padding-right: 5px;
margin-left: 10px;
margin-top: -4px;
}
.experimental:hover::after {
content: "Ⓔ Experimental";
// content: "";
color: #ffde12;
// background-color: #1f1f1f;
display: inline-block;
font-size: .75em;
font-variant: small-caps;
padding-left: 5px;
padding-right: 5px;
margin-left: 10px;
margin-top: -4px;
}
.sticky-bottom {
width: 100%;
position: sticky;
// position: fixed;
bottom: 0px;
background-color: rgba($background-primary, 0.7);
}
.rtl {
direction: rtl;
}
.ltr {
direction: ltr;
}
.monospace {
font-family: 'Overpass Mono';
}
.pointer {
cursor: pointer;
user-select: none;
}

View File

@ -0,0 +1,51 @@
.flex {
display: flex;
}
.flex-row {
flex-direction: row;
}
.flex-col {
flex-direction: column;
}
.flex-auto {
flex: 1 1 auto;
}
.flex-grow {
flex-grow: 1;
}
.flex-nogrow {
flex-grow: 0;
}
.flex-shrink {
flex-shrink: 1;
}
.flex-noshrink {
flex-shrink: 0;
}
.flex-wrap {
flex-wrap: wrap;
}
.flex-center {
align-content: center;
align-items: center;
}
.flex-end {
justify-content: flex-end;
}
.flex-cross-center {
justify-content: center;
justify-items: center;
}
.flex-self-center {
align-self: center;
}

View File

View File

@ -0,0 +1,91 @@
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-thin.woff2') format('woff2'); /* Super Modern Browsers */
font-weight: 200;
font-style: normal;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-thin-italic.woff2') format('woff2');
font-weight: 200;
font-style: italic;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-extralight.woff2') format('woff2');
font-weight: 300;
font-style: normal;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-extralight-italic.woff2') format('woff2');
font-weight: 300;
font-style: italic;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-light.woff2') format('woff2');
font-weight: 400;
font-style: normal;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-light-italic.woff2') format('woff2');
font-weight: 400;
font-style: italic;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-regular.woff2') format('woff2');
font-weight: 500;
font-style: normal;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-italic.woff2') format('woff2');
font-weight: 500;
font-style: italic;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-semibold.woff2') format('woff2');
font-weight: 600;
font-style: normal;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-semibold-italic.woff2') format('woff2');
font-weight: 600;
font-style: italic;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-bold.woff2') format('woff2');
font-weight: 700;
font-style: normal;
}
@font-face {
font-family: 'overpass';
src: url('../../fonts/overpass-webfont/overpass-bold-italic.woff2') format('woff2');
font-weight: 700;
font-style: italic;
}

111
src/csui/res/css/fonts.scss Normal file
View File

@ -0,0 +1,111 @@
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-thin.woff2') format('woff2'); /* Super Modern Browsers */
font-weight: 200;
font-style: normal;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-thin-italic.woff2') format('woff2');
font-weight: 200;
font-style: italic;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-extralight.woff2') format('woff2');
font-weight: 300;
font-style: normal;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-extralight-italic.woff2') format('woff2');
font-weight: 300;
font-style: italic;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-light.woff2') format('woff2');
font-weight: 400;
font-style: normal;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-light-italic.woff2') format('woff2');
font-weight: 400;
font-style: italic;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-regular.woff2') format('woff2');
font-weight: 500;
font-style: normal;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-italic.woff2') format('woff2');
font-weight: 500;
font-style: italic;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-semibold.woff2') format('woff2');
font-weight: 600;
font-style: normal;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-semibold-italic.woff2') format('woff2');
font-weight: 600;
font-style: italic;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-bold.woff2') format('woff2');
font-weight: 700;
font-style: normal;
}
@font-face {
font-family: 'Overpass';
src: url('/csui/res/fonts/overpass-webfont/overpass-bold-italic.woff2') format('woff2');
font-weight: 700;
font-style: italic;
}
@font-face {
font-family: 'Overpass mono';
src: url('/csui/res/fonts/overpass-mono-webfont/overpass-mono-light.woff2') format('woff2');
font-weight: 300;
font-style: normal;
}
@font-face {
font-family: 'Overpass mono';
src: url('/csui/res/fonts/overpass-mono-webfont/overpass-mono-regular.woff2') format('woff2');
font-weight: 400;
font-style: normal;
}
@font-face {
font-family: 'Overpass mono';
src: url('/csui/res/fonts/overpass-mono-webfont/overpass-mono-semibold.woff2') format('woff2');
font-weight: 500;
font-style: normal;
}
@font-face {
font-family: 'Overpass mono';
src: url('/csui/res/fonts/overpass-mono-webfont/overpass-mono-bold.woff2') format('woff2');
font-weight: 600;
font-style: normal;
}

26653
src/csui/res/css/mdi.scss Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,35 @@
@import 'flex.scss';
@import 'colors.scss';
@import 'common.scss';
* {
font-family: 'Overpass';
}
.uw-ultrawidify-container-root {
// here's the defaults:
// all: initial;
// * {
// all: unset;
// }
// here's things that we don't want as defaults
// (must come after the all: declaration, otherwise
// all: declaration overrides everything.)
// we put our UI _over_ site's player:
z-index: 999999;
position: absolute;
width: 100%;
height: 100%;
top: 0;
left: 0;
background-color: none transparent !important;
// Ensure we're display:block
display: block;
// we are click-through by default:
pointer-events: none;
}

View File

@ -0,0 +1,50 @@
## License
Copyright 2015 Red Hat, Inc.,
This Font Software is dual licensed and available under the SIL Open Font License, Version 1.1. and also the LGPL 2.1
The Open Font license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
The GNU LGPL can be found at http://www.gnu.org/licenses/old-licenses/lgpl-2.1.en.html
#### SIL OPEN FONT LICENSE
Version 1.1 - 26 February 2007
---
#### PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
#### DEFINITIONS
“Font Software” refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
“Reserved Font Name” refers to any names specified as such after the copyright statement(s).
“Original Version” refers to the collection of Font Software components as distributed by the Copyright Holder(s).
“Modified Version” refers to any derivative made by adding to, deleting, or substituting—in part or in whole—any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
“Author” refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
#### PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
#### TERMINATION
This license becomes null and void if any of the above conditions are not met.
#### DISCLAIMER
THE FONT SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More