Работа над LibsPage
This commit is contained in:
@@ -149,7 +149,12 @@ class ExternalLibs extends Vue {
|
|||||||
//this.commit('reader/setLibs', rstore.libsDefaults);
|
//this.commit('reader/setLibs', rstore.libsDefaults);
|
||||||
}
|
}
|
||||||
|
|
||||||
mounted() {
|
mounted() {
|
||||||
|
if (this.mode != 'liberama.top') {
|
||||||
|
this.$router.replace('/404');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
this.$refs.window.init();
|
this.$refs.window.init();
|
||||||
|
|
||||||
this.opener = null;
|
this.opener = null;
|
||||||
|
|||||||
@@ -25,10 +25,14 @@ class LibsPage extends Vue {
|
|||||||
created() {
|
created() {
|
||||||
this.popupWindow = null;
|
this.popupWindow = null;
|
||||||
this.commit = this.$store.commit;
|
this.commit = this.$store.commit;
|
||||||
|
this.messageListener = null;
|
||||||
//this.commit('reader/setLibs', rstore.libsDefaults);
|
//this.commit('reader/setLibs', rstore.libsDefaults);
|
||||||
}
|
}
|
||||||
|
|
||||||
init() {
|
init() {
|
||||||
|
if (this.mode != 'liberama.top')
|
||||||
|
return;
|
||||||
|
|
||||||
this.childReady = false;
|
this.childReady = false;
|
||||||
const subdomain = (window.location.protocol != 'http:' ? 'b.' : '');
|
const subdomain = (window.location.protocol != 'http:' ? 'b.' : '');
|
||||||
this.origin = `http://${subdomain}${window.location.host}`;
|
this.origin = `http://${subdomain}${window.location.host}`;
|
||||||
@@ -100,6 +104,10 @@ class LibsPage extends Vue {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
get mode() {
|
||||||
|
return this.$store.state.config.mode;
|
||||||
|
}
|
||||||
|
|
||||||
get libs() {
|
get libs() {
|
||||||
return this.$store.state.reader.libs;
|
return this.$store.state.reader.libs;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -44,7 +44,7 @@
|
|||||||
<q-tooltip :delay="1500" anchor="bottom middle" content-style="font-size: 80%">{{ rstore.readerActions['refresh'] }}</q-tooltip>
|
<q-tooltip :delay="1500" anchor="bottom middle" content-style="font-size: 80%">{{ rstore.readerActions['refresh'] }}</q-tooltip>
|
||||||
</button>
|
</button>
|
||||||
<div class="space"></div>
|
<div class="space"></div>
|
||||||
<button ref="libs" v-show="showToolButton['libs']" class="tool-button" :class="buttonActiveClass('libs')" @click="buttonClick('libs')" v-ripple>
|
<button ref="libs" v-show="mode == 'liberama.top' && showToolButton['libs']" class="tool-button" :class="buttonActiveClass('libs')" @click="buttonClick('libs')" v-ripple>
|
||||||
<q-icon name="la la-sitemap" size="32px"/>
|
<q-icon name="la la-sitemap" size="32px"/>
|
||||||
<q-tooltip :delay="1500" anchor="bottom middle" content-style="font-size: 80%">{{ rstore.readerActions['libs'] }}</q-tooltip>
|
<q-tooltip :delay="1500" anchor="bottom middle" content-style="font-size: 80%">{{ rstore.readerActions['libs'] }}</q-tooltip>
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@@ -1,8 +1,10 @@
|
|||||||
<div class="part-header">Показывать кнопки панели</div>
|
<div class="part-header">Показывать кнопки панели</div>
|
||||||
|
|
||||||
<div class="item row" v-for="item in toolButtons" :key="item.name">
|
<div class="item row" v-for="item in toolButtons" :key="item.name" v-show="item.name != 'libs' || mode == 'liberama.top'">
|
||||||
<div class="label-3"></div>
|
<div class="label-3"></div>
|
||||||
<div class="col row">
|
<div class="col row">
|
||||||
<q-checkbox size="xs" @input="changeShowToolButton(item.name)" :value="showToolButton[item.name]" :label="rstore.readerActions[item.name]" />
|
<q-checkbox size="xs" @input="changeShowToolButton(item.name)"
|
||||||
|
:value="showToolButton[item.name]" :label="rstore.readerActions[item.name]"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user