Added alert dialog. Fixed image rotation EXIT data being discarded.

This commit is contained in:
DebaucheryLibrarian
2021-04-04 21:52:19 +02:00
parent 837fc98ad2
commit da0cbced15
43 changed files with 1134 additions and 38 deletions

View File

@@ -211,6 +211,72 @@ function initTagsActions(store, _router) {
return tags.map(tag => curateTag(tag, store.state.ui.sfw));
}
async function searchTags({ _commit }, {
limit = 100,
minLength = 2,
query,
_group,
_priority,
}) {
const { tags } = await graphql(`
query SearchTags(
$query: String!,
$limit: Int = 100
$minLength: Int = 2
) {
tags: searchTags(
search: $query,
first: $limit
minLength: $minLength
) {
id
name
slug
poster: tagsPosterByTagId {
media {
thumbnail
comment
lazy
width
height
thumbnailWidth
thumbnailHeight
entity {
id
name
slug
type
independent
parent {
id
name
slug
type
independent
}
}
sfw: sfwMedia {
thumbnail
comment
lazy
}
}
}
group {
name
slug
}
}
}
`, {
query,
limit,
minLength,
});
return tags.map(tag => curateTag(tag, store.state.ui.sfw));
}
async function fetchTagReleases({ _commit }, tagId) {
const releases = await get(`/tags/${tagId}/releases`, {
filter: store.state.ui.filter,
@@ -225,6 +291,7 @@ function initTagsActions(store, _router) {
fetchTagBySlug,
fetchTags,
fetchTagReleases,
searchTags,
};
}