Compare commits

..

No commits in common. "b163223ff1f17985a0e8c5cb51996853901d01f9" and "285a65f01866bc04af8466a23264a03d74393fab" have entirely different histories.

5 changed files with 17 additions and 27 deletions

View File

@ -46,7 +46,7 @@
/> />
</li> </li>
<template #tooltip> <template v-slot:tooltip>
<Search <Search
content="actors" content="actors"
@select="actor => addActor(actor)" @select="actor => addActor(actor)"
@ -88,7 +88,7 @@
/> />
</li> </li>
<template #tooltip> <template v-slot:tooltip>
<Search <Search
content="tags" content="tags"
:defaults="['anal', 'blowbang', 'mfm', 'dp', 'gangbang', 'airtight']" :defaults="['anal', 'blowbang', 'mfm', 'dp', 'gangbang', 'airtight']"
@ -126,7 +126,7 @@
/> />
</div> </div>
<template #tooltip> <template v-slot:tooltip>
<Search <Search
label="Search channels" label="Search channels"
content="entities" content="entities"
@ -181,7 +181,7 @@
/> />
</li> </li>
<template #tooltip> <template v-slot:tooltip>
<Search <Search
content="stashes" content="stashes"
@select="stash => addStash(stash)" @select="stash => addStash(stash)"
@ -194,7 +194,6 @@
<div class="dialog-actions right"> <div class="dialog-actions right">
<button <button
:disabled="actors.length === 0 && tags.length === 0 && !entity"
type="submit" type="submit"
class="button button-primary" class="button button-primary"
>Add alert</button> >Add alert</button>
@ -211,19 +210,19 @@ import Search from './search.vue';
async function addAlert() { async function addAlert() {
await this.$store.dispatch('addAlert', { await this.$store.dispatch('addAlert', {
actors: this.actors.map((actor) => actor.id), actors: this.actors.map(actor => actor.id),
tags: this.tags.map((tag) => tag.id), tags: this.tags.map(tag => tag.id),
entity: this.entity?.id, entity: this.entity?.id,
notify: this.notify, notify: this.notify,
email: this.email, email: this.email,
stashes: this.stashes.map((stash) => stash.id), stashes: this.stashes.map(stash => stash.id),
}); });
this.$emit('close', true); this.$emit('close', true);
} }
function addActor(actor) { function addActor(actor) {
if (!this.actors.some((selectedActor) => selectedActor.id === actor.id)) { if (!this.actors.some(selectedActor => selectedActor.id === actor.id)) {
this.actors = this.actors.concat(actor); this.actors = this.actors.concat(actor);
} }
@ -236,7 +235,7 @@ function addEntity(entity) {
} }
function addTag(tag) { function addTag(tag) {
if (!this.tags.some((selectedTag) => selectedTag.id === tag.id)) { if (!this.tags.some(selectedTag => selectedTag.id === tag.id)) {
this.tags = this.tags.concat(tag); this.tags = this.tags.concat(tag);
} }
@ -244,7 +243,7 @@ function addTag(tag) {
} }
function removeActor(actor) { function removeActor(actor) {
this.actors = this.actors.filter((listedActor) => listedActor.id !== actor.id); this.actors = this.actors.filter(listedActor => listedActor.id !== actor.id);
} }
function removeEntity() { function removeEntity() {
@ -252,11 +251,11 @@ function removeEntity() {
} }
function removeTag(tag) { function removeTag(tag) {
this.tags = this.tags.filter((listedTag) => listedTag.id !== tag.id); this.tags = this.tags.filter(listedTag => listedTag.id !== tag.id);
} }
function addStash(stash) { function addStash(stash) {
if (!this.stashes.some((selectedStash) => selectedStash.id === stash.id)) { if (!this.stashes.some(selectedStash => selectedStash.id === stash.id)) {
this.stashes = this.stashes.concat(stash); this.stashes = this.stashes.concat(stash);
} }
@ -264,7 +263,7 @@ function addStash(stash) {
} }
function removeStash(stash) { function removeStash(stash) {
this.stashes = this.stashes.filter((listedStash) => listedStash.id !== stash.id); this.stashes = this.stashes.filter(listedStash => listedStash.id !== stash.id);
} }
export default { export default {
@ -274,7 +273,6 @@ export default {
Entity, Entity,
Search, Search,
}, },
emits: ['close'],
data() { data() {
return { return {
actors: [], actors: [],
@ -286,6 +284,7 @@ export default {
availableStashes: this.$store.state.auth.user.stashes, availableStashes: this.$store.state.auth.user.stashes,
}; };
}, },
emits: ['close'],
methods: { methods: {
addActor, addActor,
addAlert, addAlert,

View File

@ -44,11 +44,6 @@
&:hover { &:hover {
background: var(--primary-strong); background: var(--primary-strong);
} }
&:disabled {
background: var(--shadow-weak);
cursor: default;
}
} }
.button-secondary { .button-secondary {

4
package-lock.json generated
View File

@ -1,12 +1,12 @@
{ {
"name": "traxxx", "name": "traxxx",
"version": "1.205.17", "version": "1.205.16",
"lockfileVersion": 2, "lockfileVersion": 2,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "traxxx", "name": "traxxx",
"version": "1.205.17", "version": "1.205.16",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"@casl/ability": "^5.2.2", "@casl/ability": "^5.2.2",

View File

@ -1,6 +1,6 @@
{ {
"name": "traxxx", "name": "traxxx",
"version": "1.205.17", "version": "1.205.16",
"description": "All the latest porn releases in one place", "description": "All the latest porn releases in one place",
"main": "src/app.js", "main": "src/app.js",
"scripts": { "scripts": {

View File

@ -238,13 +238,9 @@ async function scrapeApiReleases(json, site) {
], ],
})); }));
/* master categories include e.g. 'transgender' for non-trans Wicked scenes
release.tags = scene.master_categories release.tags = scene.master_categories
.concat(scene.categories?.map((category) => category.name)) .concat(scene.categories?.map((category) => category.name))
.filter(Boolean); // some categories don't have a name .filter(Boolean); // some categories don't have a name
*/
release.tags = scene.categories?.map((category) => category.name).filter(Boolean); // some categories don't have a name
if (scene.availableOnSite.length > 1) { if (scene.availableOnSite.length > 1) {
release.comment = `Also available on ${scene.availableOnSite.filter((sisterSite) => sisterSite !== site.slug).join(', ')}`; release.comment = `Also available on ${scene.availableOnSite.filter((sisterSite) => sisterSite !== site.slug).join(', ')}`;