Revert "fix vue imports"

This reverts commit cd7a1de548.
This commit is contained in:
Tamius Han 2021-03-14 02:10:41 +01:00
parent 6546ad2166
commit 42394a48bc
8 changed files with 46 additions and 21 deletions

View File

@ -195,6 +195,8 @@
:settings="settings" :settings="settings"
:site="selectedSite" :site="selectedSite"
/> />
<PerformancePanel v-if="selectedTab === 'performance-metrics'"
:performance="performance" />
<WhatsNewPanel v-if="selectedTab === 'whats-new'" /> <WhatsNewPanel v-if="selectedTab === 'whats-new'" />
<AboutPanel v-if="selectedTab === 'about'" /> <AboutPanel v-if="selectedTab === 'about'" />
<Donate v-if="selectedTab === 'donate'" /> <Donate v-if="selectedTab === 'donate'" />
@ -221,9 +223,9 @@ import ExtensionMode from '../common/enums/ExtensionMode.enum';
import Logger from '../ext/lib/Logger'; import Logger from '../ext/lib/Logger';
import {ChromeShittinessMitigations as CSM} from '../common/js/ChromeShittinessMitigations'; import {ChromeShittinessMitigations as CSM} from '../common/js/ChromeShittinessMitigations';
import { browser } from 'webextension-polyfill-ts'; import { browser } from 'webextension-polyfill-ts';
import { defineComponent } from 'vue';
export default defineComponent({ import Vue from '*.vue';
export default Vue.extend({
data () { data () {
return { return {
selectedTab: 'video', selectedTab: 'video',

View File

@ -5,7 +5,7 @@ class PopupExec {
settings: Settings; settings: Settings;
site: any; site: any;
constructor(settings?, site?) { constructor(settings, site) {
this.settings = settings; this.settings = settings;
this.site = site; this.site = site;
} }

View File

@ -42,11 +42,11 @@ import ShortcutButton from '../../common/components/ShortcutButton.vue';
import BrowserDetect from '../../ext/conf/BrowserDetect'; import BrowserDetect from '../../ext/conf/BrowserDetect';
import { browser } from 'webextension-polyfill-ts'; import { browser } from 'webextension-polyfill-ts';
import { defineComponent } from 'vue' import Vue from 'vue'
export default defineComponent({ export default Vue.extend({
components: { components: {
ShortcutButton, ShortcutButton,
}, },
data() { data() {
return { return {
// reminder webextension-polyfill doesn't seem to work in vue! // reminder webextension-polyfill doesn't seem to work in vue!

View File

@ -126,11 +126,10 @@
import KeyboardShortcutParser from '../../common/js/KeyboardShortcutParser'; import KeyboardShortcutParser from '../../common/js/KeyboardShortcutParser';
import ShortcutButton from '../../common/components/ShortcutButton.vue'; import ShortcutButton from '../../common/components/ShortcutButton.vue';
import ComputeActionsMixin from '../../common/mixins/ComputeActionsMixin'; import ComputeActionsMixin from '../../common/mixins/ComputeActionsMixin';
import Vue from 'vue'
import PopupExec from '../js/PopupExec'; import PopupExec from '../js/PopupExec';
import { defineComponent } from 'vue'; export default Vue.extend({
export default defineComponent({
data() { data() {
return { return {
} }
@ -144,7 +143,7 @@ export default defineComponent({
site: String, site: String,
}, },
created() { created() {
this.exec = new PopupExec(this.settings, this.site); this.exec = new ExecAction(this.settings, this.site);
}, },
components: { components: {
ShortcutButton, ShortcutButton,

View File

@ -0,0 +1,25 @@
<template>
<div>
PERFORMANCE PANEL :: This is here for debugging purposes.
<pre>{{performance}}</pre>
</div>
</template>
<script lang="ts">
import Vue from 'vue'
export default Vue.extend({
props: {
performance: Object,
},
watch: {
performance: {
deep: true,
}
}
})
</script>
<style>
</style>

View File

@ -134,8 +134,8 @@ import ExtensionMode from '../../common/enums/ExtensionMode.enum';
import VideoAlignmentType from '../../common/enums/VideoAlignmentType.enum'; import VideoAlignmentType from '../../common/enums/VideoAlignmentType.enum';
import StretchType from '../../common/enums/StretchType.enum'; import StretchType from '../../common/enums/StretchType.enum';
import { defineComponent } from 'vue' import Vue from 'vue'
export default defineComponent({ export default Vue.extend({
components: { components: {
QuerySelectorSetting, QuerySelectorSetting,
ShortcutButton, ShortcutButton,

View File

@ -120,16 +120,15 @@
</div> </div>
</template> </template>
<script lang="ts"> <script>
import PopupExec from '../js/PopupExec'; import PopupExec from '../js/PopupExec';
import KeyboardShortcutParser from '../../common/js/KeyboardShortcutParser'; import KeyboardShortcutParser from '../../common/js/KeyboardShortcutParser';
import ShortcutButton from '../../common/components/ShortcutButton.vue'; import ShortcutButton from '../../common/components/ShortcutButton';
import ComputeActionsMixin from '../../common/mixins/ComputeActionsMixin'; import ComputeActionsMixin from '../../common/mixins/ComputeActionsMixin';
import CropModePersistence from '../../common/enums/CropModePersistence.enum'; import CropModePersistence from '../../common/enums/CropModePersistence.enum';
import { defineComponent } from 'vue';
export default defineComponent({ export default {
data() { data() {
return { return {
scope: 'page', scope: 'page',
CropModePersistence: CropModePersistence, CropModePersistence: CropModePersistence,
@ -182,7 +181,7 @@ export default defineComponent({
); );
} }
} }
}) }
</script> </script>
<style> <style>

View File

@ -18,10 +18,10 @@
</template> </template>
<script lang="ts"> <script lang="ts">
import { defineComponent } from 'vue';
import BrowserDetect from '../../ext/conf/BrowserDetect'; import BrowserDetect from '../../ext/conf/BrowserDetect';
export default defineComponent({ import Vue from 'vue'
export default Vue.extend({
data () { data () {
return { return {
BrowserDetect: BrowserDetect BrowserDetect: BrowserDetect