mirror of
https://github.com/ThatGuySam/doesitarm.git
synced 2026-05-18 06:44:46 -07:00
List app categories from single file
This commit is contained in:
parent
64e681b4a3
commit
e578118bab
7 changed files with 120 additions and 30 deletions
|
|
@ -76,7 +76,7 @@
|
|||
style="transition-property: border;"
|
||||
>
|
||||
<template v-if="seenItems[app.slug] === false && hasStartedAnyQuery === false">
|
||||
{{ app.section.icon.length !== 0 ? `${app.section.icon} ${app.name}` : app.name }}
|
||||
{{ getAppCategory(app).icon ? `${getAppCategory(app).icon} ${app.name}` : app.name }}
|
||||
<div class="text-sm leading-5 font-bold">
|
||||
{{ app.text }}
|
||||
</div>
|
||||
|
|
@ -89,7 +89,7 @@
|
|||
</div>
|
||||
</client-only>
|
||||
|
||||
{{ app.section.icon.length !== 0 ? `${app.section.icon} ${app.name}` : app.name }}
|
||||
{{ getAppCategory(app).icon ? `${getAppCategory(app).icon} ${app.name}` : app.name }}
|
||||
<div class="text-sm leading-5 font-bold">
|
||||
{{ app.text }}
|
||||
</div>
|
||||
|
|
@ -163,19 +163,13 @@
|
|||
<script>
|
||||
import scrollIntoView from 'scroll-into-view-if-needed'
|
||||
|
||||
import { getAppCategory } from '~/helpers/categories.js'
|
||||
// import appList from '~/static/app-list.json'
|
||||
|
||||
// import EmailSubscribe from '~/components/email-subscribe.vue'
|
||||
// import RelativeTime from '~/components/relative-time.vue'
|
||||
import ListSummary from '~/components/list-summary.vue'
|
||||
|
||||
// import overlayStore from './mixins/store'
|
||||
// import modalRouter from '~/components/modals/mixins/router'
|
||||
// import Card from '~/components/cards/Default.vue'
|
||||
// import CardsRow from '~/components/cards/Row.vue'
|
||||
// import ComingSoonImage from '~/components/partials/ComingSoonImage.vue'
|
||||
// import InfoCircle from '~/assets/svg/info-circle.svg?inline'
|
||||
// import PlayCircle from '~/assets/svg/play-circle.svg?inline'
|
||||
|
||||
export default {
|
||||
components: {
|
||||
|
|
@ -316,6 +310,7 @@ export default {
|
|||
console.log('appList', this.appList.length)
|
||||
},
|
||||
methods: {
|
||||
getAppCategory,
|
||||
// Search priorities
|
||||
titleStartsWith (query, app) {
|
||||
const matches = app.name.toLowerCase().startsWith(query)
|
||||
|
|
@ -332,7 +327,7 @@ export default {
|
|||
return matches
|
||||
},
|
||||
sectionContains (query, app) {
|
||||
const matches = app.section.label.toLowerCase().includes(query)
|
||||
const matches = getAppCategory(app).label.toLowerCase().includes(query)
|
||||
if (matches) {
|
||||
this.sectionContainsResults.push(app)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue