mirror of
https://github.com/Xevion/the-office.git
synced 2025-12-14 08:13:14 -06:00
Disable surrounding quotes request, fix Algolia errors
This commit is contained in:
@@ -58,7 +58,7 @@
|
|||||||
</b-col>
|
</b-col>
|
||||||
</b-row>
|
</b-row>
|
||||||
</b-container>
|
</b-container>
|
||||||
<ais-configure :click-analytics="true" />
|
<ais-configure :analytics="true" />
|
||||||
</ais-instant-search>
|
</ais-instant-search>
|
||||||
<Footer :build-moment="buildMoment" />
|
<Footer :build-moment="buildMoment" />
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -2,7 +2,8 @@
|
|||||||
<b-card
|
<b-card
|
||||||
class="mb-1" body-class="p-0 expandable-result"
|
class="mb-1" body-class="p-0 expandable-result"
|
||||||
footer-class="my-1"
|
footer-class="my-1"
|
||||||
:class="[expanded ? 'expanded' : '']" @mouseover="hoverOn"
|
:class="[expanded ? 'expanded' : '']"
|
||||||
|
@mouseover="hoverOn"
|
||||||
@mouseleave="hoverOff"
|
@mouseleave="hoverOff"
|
||||||
@click="toggleExpansion"
|
@click="toggleExpansion"
|
||||||
>
|
>
|
||||||
@@ -128,7 +129,7 @@ export default {
|
|||||||
// if first time expanding, fetch quotes
|
// if first time expanding, fetch quotes
|
||||||
if (!this.fetchQuotes()) {
|
if (!this.fetchQuotes()) {
|
||||||
this.hasExpanded = true;
|
this.hasExpanded = true;
|
||||||
this.fetchQuotes();
|
// this.fetchQuotes();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
hoverFetch() {
|
hoverFetch() {
|
||||||
@@ -140,15 +141,15 @@ export default {
|
|||||||
},
|
},
|
||||||
hoverOn() {
|
hoverOn() {
|
||||||
// Schedule a fetching event
|
// Schedule a fetching event
|
||||||
this.timeoutID = setTimeout(this.hoverFetch, 300);
|
// this.timeoutID = setTimeout(this.hoverFetch, 300);
|
||||||
},
|
},
|
||||||
hoverOff() {
|
hoverOff() {
|
||||||
// Hover is off. Unschedule event if it has not already fetched.
|
// Hover is off. Unschedule event if it has not already fetched.
|
||||||
|
if (this.timeoutID !== null)
|
||||||
clearTimeout(this.timeoutID);
|
clearTimeout(this.timeoutID);
|
||||||
},
|
},
|
||||||
fetchQuotes() {
|
fetchQuotes() {
|
||||||
const path = `${process.env.VUE_APP_API_URL}/api/quote_surround?season=\
|
const path = `/api/quote/surrounding?season=${this.item.season}&episode=${this.item.episode_rel}&scene=${this.item.section_rel}"e=${this.item.quote_rel}`;
|
||||||
${this.item.season}&episode=${this.item.episode_rel}&scene=${this.item.section_rel}"e=${this.item.quote_rel}`;
|
|
||||||
axios
|
axios
|
||||||
.get(path)
|
.get(path)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user