Skip to content

Commit 9c9ea7c

Browse files
authored
Merge pull request #741 from w3bdesign/dev
Add search link
2 parents 78faa4c + d46d823 commit 9c9ea7c

File tree

4 files changed

+11
-6
lines changed

4 files changed

+11
-6
lines changed

.eslintrc.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ module.exports = {
44
browser: true,
55
node: true,
66
},
7-
parserOptions: {
7+
/* parserOptions: {
88
parser: 'babel-eslint',
9-
},
9+
},*/
1010
extends: [
1111
'@nuxtjs',
1212
'prettier',

components/Layout/Cart.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ export default {
5454
cart: {
5555
prefetch: true,
5656
query: GET_CART_QUERY,
57-
pollInterval: process.server ? undefined : 2000,
57+
pollInterval: process.server ? undefined : 3000,
5858
result({ data, loading, networkStatus }) {
5959
const cartIsReady = networkStatus === 7
6060
if (cartIsReady && !loading) {

components/Layout/MobileMenu.vue

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,11 @@
2222
Categories
2323
</NuxtLink>
2424
</li>
25+
<li class="text-xl linkStyle">
26+
<NuxtLink to="/search" @click.native="displayMobileMenu">
27+
Search
28+
</NuxtLink>
29+
</li>
2530
<li class="flex justify-center mt-6 text-lg linkStyleCart">
2631
<NuxtLink to="/cart" @click.native="displayMobileMenu">
2732
<Cart />

pages/search.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<ais-search-box />
44
<ais-stats />
55
<ais-refinement-list attribute="brand" />
6-
<ais-hits>
6+
<ais-hits :class-names="{ 'ais-Hits-item': 'CustomHitsItem' }">
77
<template slot="item" slot-scope="{ item }">
88
<NuxtLink
99
class="text-black cursor-pointer hover:underline"
@@ -96,14 +96,14 @@ export default {
9696

9797
<style>
9898
@media (max-width: 767px) {
99-
.ais-Hits-item {
99+
.CustomHitsItem {
100100
padding: 10px;
101101
width: 100%;
102102
}
103103
}
104104
105105
@media (min-width: 768px) {
106-
.ais-Hits-item {
106+
.CustomHitsItem {
107107
width: 30%;
108108
}
109109
}

0 commit comments

Comments
 (0)