Compare commits
3 Commits
b2cd8197d4
...
ebdc26a00d
Author | SHA1 | Date | |
---|---|---|---|
ebdc26a00d | |||
dd47dd09da | |||
bc6d2ac549 |
@ -37,6 +37,7 @@
|
|||||||
|
|
||||||
Ultrawidify
|
Ultrawidify
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
<slot>
|
<slot>
|
||||||
<!--
|
<!--
|
||||||
|
@ -85,6 +85,11 @@
|
|||||||
:site="site.host"
|
:site="site.host"
|
||||||
>
|
>
|
||||||
</BaseExtensionSettings>
|
</BaseExtensionSettings>
|
||||||
|
|
||||||
|
<AboutPanel
|
||||||
|
v-if="selectedTab === 'about'"
|
||||||
|
>
|
||||||
|
</AboutPanel>
|
||||||
</template>
|
</template>
|
||||||
<template v-else>No settings or site settings found.</template>
|
<template v-else>No settings or site settings found.</template>
|
||||||
</div>
|
</div>
|
||||||
@ -99,6 +104,7 @@ import BaseExtensionSettings from './src/PlayerUiPanels/BaseExtensionSettings.vu
|
|||||||
import PlayerDetectionPanel from './src/PlayerUiPanels/PlayerDetectionPanel.vue'
|
import PlayerDetectionPanel from './src/PlayerUiPanels/PlayerDetectionPanel.vue'
|
||||||
import PopupVideoSettings from './src/popup/panels/PopupVideoSettings.vue'
|
import PopupVideoSettings from './src/popup/panels/PopupVideoSettings.vue'
|
||||||
import InPlayerUIAdvertisement from './src/PlayerUiPanels/InPlayerUiAdvertisement.vue';
|
import InPlayerUIAdvertisement from './src/PlayerUiPanels/InPlayerUiAdvertisement.vue';
|
||||||
|
import AboutPanel from '@csui/src/popup/panels/AboutPanel.vue'
|
||||||
import Debug from '../ext/conf/Debug';
|
import Debug from '../ext/conf/Debug';
|
||||||
import BrowserDetect from '../ext/conf/BrowserDetect';
|
import BrowserDetect from '../ext/conf/BrowserDetect';
|
||||||
import Comms from '../ext/lib/comms/Comms';
|
import Comms from '../ext/lib/comms/Comms';
|
||||||
@ -109,6 +115,15 @@ import EventBus from '../ext/lib/EventBus';
|
|||||||
import {ChromeShittinessMitigations as CSM} from '../common/js/ChromeShittinessMitigations';
|
import {ChromeShittinessMitigations as CSM} from '../common/js/ChromeShittinessMitigations';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
components: {
|
||||||
|
Debug,
|
||||||
|
BrowserDetect,
|
||||||
|
PopupVideoSettings,
|
||||||
|
PlayerDetectionPanel,
|
||||||
|
BaseExtensionSettings,
|
||||||
|
InPlayerUIAdvertisement,
|
||||||
|
AboutPanel
|
||||||
|
},
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
comms: undefined,
|
comms: undefined,
|
||||||
@ -127,6 +142,7 @@ export default {
|
|||||||
{id: 'videoSettings', label: 'Video settings', icon: 'crop'},
|
{id: 'videoSettings', label: 'Video settings', icon: 'crop'},
|
||||||
// {id: 'playerDetection', label: 'Player detection', icon: 'television-play'},
|
// {id: 'playerDetection', label: 'Player detection', icon: 'television-play'},
|
||||||
{id: 'extensionSettings', label: 'Site and Extension options', icon: 'cogs' },
|
{id: 'extensionSettings', label: 'Site and Extension options', icon: 'cogs' },
|
||||||
|
{id: 'about', label: 'About', icon: 'information-outline'},
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -215,11 +231,7 @@ export default {
|
|||||||
this.narrowPopup = body.offsetWidth < 600;
|
this.narrowPopup = body.offsetWidth < 600;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
components: {
|
|
||||||
Debug,
|
|
||||||
BrowserDetect,
|
|
||||||
PopupVideoSettings, PlayerDetectionPanel, BaseExtensionSettings, InPlayerUIAdvertisement
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
async sleep(t) {
|
async sleep(t) {
|
||||||
return new Promise( (resolve,reject) => {
|
return new Promise( (resolve,reject) => {
|
||||||
|
@ -135,7 +135,7 @@ import PlayerDetectionPanel from './PlayerUiPanels/PlayerDetectionPanel.vue'
|
|||||||
import VideoSettings from './PlayerUiPanels/VideoSettings.vue'
|
import VideoSettings from './PlayerUiPanels/VideoSettings.vue'
|
||||||
import BrowserDetect from '../../ext/conf/BrowserDetect'
|
import BrowserDetect from '../../ext/conf/BrowserDetect'
|
||||||
import ChangelogPanel from './PlayerUiPanels/ChangelogPanel.vue'
|
import ChangelogPanel from './PlayerUiPanels/ChangelogPanel.vue'
|
||||||
import AboutPanel from './PlayerUiPanels/AboutPanel.vue'
|
import AboutPanel from '@csui/src/PlayerUiPanels/AboutPanel.vue'
|
||||||
import PlayerUiSettings from './PlayerUiPanels/PlayerUiSettings.vue'
|
import PlayerUiSettings from './PlayerUiPanels/PlayerUiSettings.vue'
|
||||||
import ResetBackupPanel from './PlayerUiPanels/ResetBackupPanel.vue'
|
import ResetBackupPanel from './PlayerUiPanels/ResetBackupPanel.vue'
|
||||||
|
|
||||||
|
@ -1,17 +1,39 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<h1>In-player UI</h1>
|
<h1>In-player UI</h1>
|
||||||
|
|
||||||
<div
|
<div
|
||||||
class="button b3"
|
class="button b3"
|
||||||
style="margin: 16px; padding: 4px;"
|
style="margin: 16px; padding: 4px;"
|
||||||
@click="showInPlayerUi()"
|
@click="showInPlayerUi()"
|
||||||
>
|
>
|
||||||
Show in-player UI
|
Show settings window
|
||||||
</div>
|
</div>
|
||||||
<p></p>
|
|
||||||
|
<div>
|
||||||
|
<b>Is your screen entirely white or entirely black?</b>
|
||||||
|
|
||||||
|
<p>This appears to be a rare issue that happens to some people. If you're experiencing this issue, please consider contacting me and sharing the following data:</p>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
<li>Which sites this problem appears on and whether it happens on youtube. If you use youtube premium, please try signing out of youtube (or use a new profile in Google Chrome) in order to see whether youtube premium is required.</li>
|
||||||
|
<li>your browser. if using browsers other than Chrome, please try to reproduce this issue in Chrome</li>
|
||||||
|
<li>your operating system</li>
|
||||||
|
<li>your graphics card</li>
|
||||||
|
<li>the following line:<br/>
|
||||||
|
<pre>prefers-color-scheme dark: {{pageData.pcsDark}}; prefers-color-scheme light: {{pageData.pcsLight}}; color-scheme: {{pageData.colorScheme}}</pre>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<p>Please post this info to <a href="https://github.com/tamius-han/ultrawidify/issues/262" target="_blank">this thread</a>, or message me via e-mail.</p>
|
||||||
|
|
||||||
|
<p>Then, disable the in-player UI.</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- <p></p>
|
||||||
<p></p>
|
<p></p>
|
||||||
<p>In-player UI should show and hide automatically as you start or stop moving your mouse inside the player window.</p>
|
<p>In-player UI should show and hide automatically as you start or stop moving your mouse inside the player window.</p>
|
||||||
<p>Note that by default, in-player UI may not show if player window is not big enough.</p>
|
<p>Note that by default, in-player UI may not show if player window is not big enough.</p> -->
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -25,6 +47,29 @@ export default {
|
|||||||
props: [
|
props: [
|
||||||
'eventBus',
|
'eventBus',
|
||||||
],
|
],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
pageData: {
|
||||||
|
pcsDark: 'x',
|
||||||
|
pcsLight: 'x',
|
||||||
|
colorScheme: 'x'
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.eventBus.subscribeMulti(
|
||||||
|
{
|
||||||
|
'uw-page-stats': {
|
||||||
|
function: (data) => {
|
||||||
|
console.log('got page statss:', data);
|
||||||
|
this.pageData = data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
this
|
||||||
|
);
|
||||||
|
this.eventBus.send('uw-get-page-stats', {}, {comms: {forwardTo: 'active'}});
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
showInPlayerUi() {
|
showInPlayerUi() {
|
||||||
this.eventBus.send('uw-set-ui-state', {globalUiVisible: true}, {comms: {forwardTo: 'active'}});
|
this.eventBus.send('uw-set-ui-state', {globalUiVisible: true}, {comms: {forwardTo: 'active'}});
|
||||||
|
@ -7,43 +7,19 @@
|
|||||||
<span class="label">Having an issue?</span><br/> Report <strike>undocumented features</strike> bugs using one of the following options (in order of preference):
|
<span class="label">Having an issue?</span><br/> Report <strike>undocumented features</strike> bugs using one of the following options (in order of preference):
|
||||||
<ul>
|
<ul>
|
||||||
<li> <a target="_blank" href="https://github.com/tamius-han/ultrawidify/issues"><b>Github (preferred)</b></a><br/></li>
|
<li> <a target="_blank" href="https://github.com/tamius-han/ultrawidify/issues"><b>Github (preferred)</b></a><br/></li>
|
||||||
<li>Email: <a target="_blank" :href="mailtoLink">tamius.han@gmail.com</a></li>
|
<li>Email: <a target="_blank" :href="mailtoLink">{{gmailLink}}</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="flex-grow"></div>
|
|
||||||
|
|
||||||
<div class="row">
|
|
||||||
<span class="label">Swatter mode (logging)</span><br/>
|
|
||||||
</div>
|
|
||||||
<div v-if="showEasterEgg" class="center"><small>You've made plenty of marks, all in the wrong places!</small></div>
|
|
||||||
<div class="flex flex-row">
|
|
||||||
<ShortcutButton class="flex flex-grow button"
|
|
||||||
label="Show logger"
|
|
||||||
:active="loggingEnabled"
|
|
||||||
@click.native="showLogger()"
|
|
||||||
></ShortcutButton>
|
|
||||||
<ShortcutButton class="flex flex-grow button"
|
|
||||||
label="Make a mark"
|
|
||||||
@click.native="sendMark()"
|
|
||||||
></ShortcutButton>
|
|
||||||
<ShortcutButton class="flex flex-grow button"
|
|
||||||
label="Hide logger"
|
|
||||||
@click.native="hideLogger()"
|
|
||||||
></ShortcutButton>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import Comms from '../../ext/lib/comms/Comms';
|
// import Comms from '@src/ext/lib/comms/Comms';
|
||||||
import ShortcutButton from '../../common/components/ShortcutButton';
|
// import ShortcutButton from '@src/common/components/ShortcutButton';
|
||||||
import BrowserDetect from '../../ext/conf/BrowserDetect';
|
import BrowserDetect from '@src/ext/conf/BrowserDetect';
|
||||||
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
ShortcutButton,
|
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@ -76,7 +52,7 @@ Browser-related stuff (please ensure this section is correct):
|
|||||||
* Operating system: ${window.navigator.platform}
|
* Operating system: ${window.navigator.platform}
|
||||||
`
|
`
|
||||||
);
|
);
|
||||||
this.mailtoLink = `mailto:tamius.han@gmail.com?subject=%5BUltrawidify%5D%20ENTER%20SUMMARY%20OF%20YOUR%20ISSUE%20HERE&body=${messageTemplate}`;
|
this.mailtoLink = `mailto:${this.gmailLink}?subject=%5BUltrawidify%5D%20ENTER%20SUMMARY%20OF%20YOUR%20ISSUE%20HERE&body=${messageTemplate}`;
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async updateLoggerSettings(allowLogging) {
|
async updateLoggerSettings(allowLogging) {
|
||||||
@ -94,15 +70,15 @@ Browser-related stuff (please ensure this section is correct):
|
|||||||
// Logger.saveConfig({allowLogging: allowLogging, ...lastLoadedLoggerSettings});
|
// Logger.saveConfig({allowLogging: allowLogging, ...lastLoadedLoggerSettings});
|
||||||
// }
|
// }
|
||||||
},
|
},
|
||||||
showLogger() {
|
// showLogger() {
|
||||||
Comms.sendMessage({cmd: 'show-logger', forwardToActive: true});
|
// Comms.sendMessage({cmd: 'show-logger', forwardToActive: true});
|
||||||
},
|
// },
|
||||||
sendMark() {
|
// sendMark() {
|
||||||
this.showEasterEgg = !this.showEasterEgg;
|
// this.showEasterEgg = !this.showEasterEgg;
|
||||||
},
|
// },
|
||||||
hideLogger() {
|
// hideLogger() {
|
||||||
Comms.sendMessage({cmd: 'hide-logger', forwardToActive: true});
|
// Comms.sendMessage({cmd: 'hide-logger', forwardToActive: true});
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
@ -190,6 +190,24 @@ class UI {
|
|||||||
this.sendToIframe('uw-set-ui-state', {...config, isGlobal: this.isGlobal}, routingData);
|
this.sendToIframe('uw-set-ui-state', {...config, isGlobal: this.isGlobal}, routingData);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
'uw-get-page-stats': {
|
||||||
|
function: (config, routingData) => {
|
||||||
|
console.log('got get page stats!');
|
||||||
|
this.eventBus.send(
|
||||||
|
'uw-page-stats',
|
||||||
|
{
|
||||||
|
pcsDark: window.matchMedia('(prefers-color-scheme: dark)').matches,
|
||||||
|
pcsLight: window.matchMedia('(prefers-color-scheme: light)').matches,
|
||||||
|
colorScheme: window.getComputedStyle( document.body ,null).getPropertyValue('color-scheme')
|
||||||
|
},
|
||||||
|
{
|
||||||
|
comms: {
|
||||||
|
forwardTo: 'popup'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
||||||
|
},
|
||||||
'uw-restore-ui-state': {
|
'uw-restore-ui-state': {
|
||||||
function: (config, routingData) => {
|
function: (config, routingData) => {
|
||||||
if (!this.isGlobal) {
|
if (!this.isGlobal) {
|
||||||
@ -324,7 +342,7 @@ class UI {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.uiIframe.style.pointerEvents = event.data.clickable ? 'auto' : 'none';
|
this.uiIframe.style.pointerEvents = event.data.clickable ? 'auto' : 'none';
|
||||||
this.uiIframe.style.opacity = event.data.opacity ? '100' : '0';
|
this.uiIframe.style.opacity = event.data.opacity || this.isGlobal ? '100' : '0';
|
||||||
break;
|
break;
|
||||||
case 'uw-bus-tunnel':
|
case 'uw-bus-tunnel':
|
||||||
const busCommand = event.data.payload;
|
const busCommand = event.data.payload;
|
||||||
@ -337,7 +355,7 @@ class UI {
|
|||||||
this.setUiVisibility(!this.isGlobal);
|
this.setUiVisibility(!this.isGlobal);
|
||||||
break;
|
break;
|
||||||
case 'uwui-hidden':
|
case 'uwui-hidden':
|
||||||
this.uiIframe.style.opacity = event.data.opacity ? '100' : '0';
|
this.uiIframe.style.opacity = event.data.opacity || this.isGlobal ? '100' : '0';
|
||||||
break;
|
break;
|
||||||
case 'uwui-global-window-hidden':
|
case 'uwui-global-window-hidden':
|
||||||
if (!this.isGlobal) {
|
if (!this.isGlobal) {
|
||||||
|
@ -560,6 +560,8 @@ class PlayerData {
|
|||||||
const playerQs = this.siteSettings.getCustomDOMQuerySelector('player');
|
const playerQs = this.siteSettings.getCustomDOMQuerySelector('player');
|
||||||
const playerIndex = this.siteSettings.getPlayerIndex();
|
const playerIndex = this.siteSettings.getPlayerIndex();
|
||||||
|
|
||||||
|
console.log('player index:', playerIndex, 'player qs:', playerQs)
|
||||||
|
|
||||||
// on verbose, get both qs and index player
|
// on verbose, get both qs and index player
|
||||||
if (options?.verbose) {
|
if (options?.verbose) {
|
||||||
if (playerIndex) {
|
if (playerIndex) {
|
||||||
@ -590,6 +592,8 @@ class PlayerData {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
console.log('got player candidate from manual selection?:', playerCandidate);
|
||||||
|
|
||||||
if (playerCandidate) {
|
if (playerCandidate) {
|
||||||
if (options?.verbose) {
|
if (options?.verbose) {
|
||||||
this.getPlayerAuto(elementStack, videoWidth, videoHeight);
|
this.getPlayerAuto(elementStack, videoWidth, videoHeight);
|
||||||
@ -713,8 +717,10 @@ class PlayerData {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (bestCandidate.initialValue) {
|
if (bestCandidate.initialValue) {
|
||||||
|
console.log('No candidates found:', bestCandidate, 'element stack:', elementStack);
|
||||||
bestCandidate = null;
|
bestCandidate = null;
|
||||||
} else {
|
} else {
|
||||||
|
console.log('Got auto-matched candidate', bestCandidate);
|
||||||
bestCandidate.heuristics['autoMatch'] = true;
|
bestCandidate.heuristics['autoMatch'] = true;
|
||||||
if (this.siteSettings.data.playerAutoConfig?.initialIndex !== bestCandidate.index) {
|
if (this.siteSettings.data.playerAutoConfig?.initialIndex !== bestCandidate.index) {
|
||||||
this.siteSettings.set('playerAutoConfig.initialIndex', bestCandidate.index, {reload: false});
|
this.siteSettings.set('playerAutoConfig.initialIndex', bestCandidate.index, {reload: false});
|
||||||
|
Loading…
Reference in New Issue
Block a user