diff options
author | Bastien Wirtz <bastien.wirtz@gmail.com> | 2020-10-23 18:26:41 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-23 18:26:41 -0700 |
commit | 37dfd2a132d883482b330b22a7c19d86948a391c (patch) | |
tree | 361edff077dc7d1796389685a7bfd55ed28473fa /src/components | |
parent | c368290e32213f537b7b1479d767ee404b0a8399 (diff) | |
parent | ed8b17e0df7ffa64e392bacbd2abf6492fdfb3f1 (diff) | |
download | homer-37dfd2a132d883482b330b22a7c19d86948a391c.tar.gz homer-37dfd2a132d883482b330b22a7c19d86948a391c.tar.zst homer-37dfd2a132d883482b330b22a7c19d86948a391c.zip |
Merge pull request #139 from Genymobile/update-deps-and-fix-code-styles
Update deps & fix lint issues
Diffstat (limited to 'src/components')
-rw-r--r-- | src/components/ConnectivityChecker.vue | 2 | ||||
-rw-r--r-- | src/components/Navbar.vue | 2 | ||||
-rw-r--r-- | src/components/SearchInput.vue | 8 | ||||
-rw-r--r-- | src/components/Service.vue | 2 | ||||
-rw-r--r-- | src/components/SettingToggle.vue | 7 |
5 files changed, 10 insertions, 11 deletions
diff --git a/src/components/ConnectivityChecker.vue b/src/components/ConnectivityChecker.vue index a91a809..d5f8f80 100644 --- a/src/components/ConnectivityChecker.vue +++ b/src/components/ConnectivityChecker.vue | |||
@@ -44,7 +44,7 @@ export default { | |||
44 | that.offline = true; | 44 | that.offline = true; |
45 | }) | 45 | }) |
46 | .finally(function () { | 46 | .finally(function () { |
47 | that.$emit("network:status-update", that.offline); | 47 | that.$emit("network-status-update", that.offline); |
48 | }); | 48 | }); |
49 | }, | 49 | }, |
50 | }, | 50 | }, |
diff --git a/src/components/Navbar.vue b/src/components/Navbar.vue index ae84166..dea7049 100644 --- a/src/components/Navbar.vue +++ b/src/components/Navbar.vue | |||
@@ -9,7 +9,7 @@ | |||
9 | aria-expanded="false" | 9 | aria-expanded="false" |
10 | class="navbar-burger" | 10 | class="navbar-burger" |
11 | :class="{ 'is-active': showMenu }" | 11 | :class="{ 'is-active': showMenu }" |
12 | v-on:click="$emit('navbar:toggle')" | 12 | v-on:click="$emit('navbar-toggle')" |
13 | > | 13 | > |
14 | <span aria-hidden="true"></span> | 14 | <span aria-hidden="true"></span> |
15 | <span aria-hidden="true"></span> | 15 | <span aria-hidden="true"></span> |
diff --git a/src/components/SearchInput.vue b/src/components/SearchInput.vue index 22b5eef..9419db3 100644 --- a/src/components/SearchInput.vue +++ b/src/components/SearchInput.vue | |||
@@ -6,8 +6,8 @@ | |||
6 | ref="search" | 6 | ref="search" |
7 | :value="value" | 7 | :value="value" |
8 | @input="$emit('input', $event.target.value.toLowerCase())" | 8 | @input="$emit('input', $event.target.value.toLowerCase())" |
9 | @keyup.enter.exact="$emit('search:open')" | 9 | @keyup.enter.exact="$emit('search-open')" |
10 | @keyup.alt.enter="$emit('search:open', '_blank')" | 10 | @keyup.alt.enter="$emit('search-open', '_blank')" |
11 | /> | 11 | /> |
12 | </div> | 12 | </div> |
13 | </template> | 13 | </template> |
@@ -20,7 +20,7 @@ export default { | |||
20 | this._keyListener = function (event) { | 20 | this._keyListener = function (event) { |
21 | if (event.key === "/") { | 21 | if (event.key === "/") { |
22 | event.preventDefault(); | 22 | event.preventDefault(); |
23 | this.$emit("search:focus"); | 23 | this.$emit("search-focus"); |
24 | this.$nextTick(() => { | 24 | this.$nextTick(() => { |
25 | this.$refs.search.focus(); | 25 | this.$refs.search.focus(); |
26 | }); | 26 | }); |
@@ -28,7 +28,7 @@ export default { | |||
28 | if (event.key === "Escape") { | 28 | if (event.key === "Escape") { |
29 | this.$refs.search.value = ""; | 29 | this.$refs.search.value = ""; |
30 | this.$refs.search.blur(); | 30 | this.$refs.search.blur(); |
31 | this.$emit("search:cancel"); | 31 | this.$emit("search-cancel"); |
32 | } | 32 | } |
33 | }; | 33 | }; |
34 | document.addEventListener("keydown", this._keyListener.bind(this)); | 34 | document.addEventListener("keydown", this._keyListener.bind(this)); |
diff --git a/src/components/Service.vue b/src/components/Service.vue index 81ad8a2..4d3702b 100644 --- a/src/components/Service.vue +++ b/src/components/Service.vue | |||
@@ -11,7 +11,7 @@ | |||
11 | </div> | 11 | </div> |
12 | <div v-if="item.icon" class="media-left"> | 12 | <div v-if="item.icon" class="media-left"> |
13 | <figure class="image is-48x48"> | 13 | <figure class="image is-48x48"> |
14 | <i style="font-size: 35px;" :class="['fa-fw', item.icon]"></i> | 14 | <i style="font-size: 35px" :class="['fa-fw', item.icon]"></i> |
15 | </figure> | 15 | </figure> |
16 | </div> | 16 | </div> |
17 | <div class="media-content"> | 17 | <div class="media-content"> |
diff --git a/src/components/SettingToggle.vue b/src/components/SettingToggle.vue index ffc91a1..985ca84 100644 --- a/src/components/SettingToggle.vue +++ b/src/components/SettingToggle.vue | |||
@@ -1,6 +1,6 @@ | |||
1 | <template> | 1 | <template> |
2 | <a v-on:click="toggleSetting()" class="navbar-item is-inline-block-mobile"> | 2 | <a v-on:click="toggleSetting()" class="navbar-item is-inline-block-mobile"> |
3 | <span><i :class="['fas', 'fa-fw', value ? icon : iconAlt]"></i></span> | 3 | <span><i :class="['fas', 'fa-fw', value ? icon : secondaryIcon]"></i></span> |
4 | <slot></slot> | 4 | <slot></slot> |
5 | </a> | 5 | </a> |
6 | </template> | 6 | </template> |
@@ -15,13 +15,12 @@ export default { | |||
15 | }, | 15 | }, |
16 | data: function () { | 16 | data: function () { |
17 | return { | 17 | return { |
18 | secondaryIcon: null, | ||
18 | value: true, | 19 | value: true, |
19 | }; | 20 | }; |
20 | }, | 21 | }, |
21 | created: function () { | 22 | created: function () { |
22 | if (!this.iconAlt) { | 23 | this.secondaryIcon = this.iconAlt || this.icon; |
23 | this.iconAlt = this.icon; | ||
24 | } | ||
25 | 24 | ||
26 | if (this.name in localStorage) { | 25 | if (this.name in localStorage) { |
27 | this.value = JSON.parse(localStorage[this.name]); | 26 | this.value = JSON.parse(localStorage[this.name]); |