Added basic filename copy. Added HTTP helper to q. Fetching all actor release pages from Naughty America. Added various high res network logos.

This commit is contained in:
2020-02-04 00:18:53 +01:00
parent bffa6d2c9e
commit ef602a3a15
42 changed files with 1483 additions and 54 deletions

View File

@@ -208,11 +208,24 @@
class="link added"
>{{ formatDate(release.dateAdded, 'MMMM D, YYYY') }}</a>
</span>
<div class="row">
<Icon icon="paste2" />
<input
class="filename"
:value="filename"
@focus="copyFilename"
>
</div>
</div>
</div>
</template>
<script>
import config from 'config';
import format from 'template-format';
import Banner from './banner.vue';
import Actor from '../tile/actor.vue';
import Release from '../tile/release.vue';
@@ -222,8 +235,19 @@ function pageTitle() {
return this.release && this.release.title;
}
function copyFilename(event) {
event.target.setSelectionRange(0, event.target.value.length);
document.execCommand('copy');
}
async function mounted() {
this.release = await this.$store.dispatch('fetchReleaseById', this.$route.params.releaseId);
this.filename = format(config.filename.pattern, {
...this.release,
date: this.formatDate(this.release.date, config.filename.date),
}, {
spreadSeparator: config.filename.separator,
});
}
export default {
@@ -236,12 +260,16 @@ export default {
data() {
return {
release: null,
filename: null,
};
},
computed: {
pageTitle,
},
mounted,
methods: {
copyFilename,
},
};
</script>
@@ -375,6 +403,12 @@ export default {
margin: 0 1rem .5rem 0;
}
.filename {
width: 100%;
padding: .5rem;
border: solid 1px $shadow-weak;
}
.link {
display: inline-block;
color: $link;

View File

@@ -46,7 +46,7 @@ export default {
.logo {
width: 100%;
height: 5rem;
color: $text;
color: $text-contrast;
display: flex;
align-items: center;
justify-content: center;

View File

@@ -0,0 +1,6 @@
<!-- Generated by IcoMoon.io -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
<title>file-empty2</title>
<path d="M11 4h3.627c-0.078-0.126-0.172-0.266-0.286-0.421-0.347-0.473-0.831-1.027-1.362-1.558s-1.085-1.015-1.558-1.362c-0.155-0.114-0.295-0.208-0.421-0.286v3.627z"></path>
<path d="M10 4.5v-4.5h-7.75c-0.689 0-1.25 0.561-1.25 1.25v13.5c0 0.689 0.561 1.25 1.25 1.25h11.5c0.689 0 1.25-0.561 1.25-1.25v-9.75h-4.5c-0.276 0-0.5-0.224-0.5-0.5z"></path>
</svg>

After

Width:  |  Height:  |  Size: 511 B

View File

@@ -0,0 +1,6 @@
<!-- Generated by IcoMoon.io -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
<title>file-video2</title>
<path d="M11 4h3.627c-0.078-0.126-0.172-0.266-0.286-0.421-0.347-0.473-0.831-1.027-1.362-1.558s-1.085-1.015-1.558-1.362c-0.155-0.114-0.295-0.208-0.421-0.286v3.627z"></path>
<path d="M10.5 5c-0.276 0-0.5-0.224-0.5-0.5v-4.5h-7.75c-0.689 0-1.25 0.561-1.25 1.25v13.5c0 0.689 0.561 1.25 1.25 1.25h11.5c0.689 0 1.25-0.561 1.25-1.25v-9.75h-4.5zM12 14l-3-2v2h-5v-5h5v2l3-2v5z"></path>
</svg>

After

Width:  |  Height:  |  Size: 541 B

5
assets/img/paste2.svg Normal file
View File

@@ -0,0 +1,5 @@
<!-- Generated by IcoMoon.io -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
<title>paste2</title>
<path d="M13 5v-2.5c0-0.275-0.225-0.5-0.5-0.5h-3.5v-1c0-0.55-0.45-1-1-1h-2c-0.55 0-1 0.45-1 1v1h-3.5c-0.275 0-0.5 0.225-0.5 0.5v10c0 0.275 0.225 0.5 0.5 0.5h4.5v3h7l3-3v-8h-3zM6 1.002c0.001-0.001 0.001-0.001 0.002-0.002h1.996c0.001 0.001 0.001 0.001 0.002 0.002v0.998h-2v-0.998zM3 4v-1h8v1h-8zM13 14.586v-1.586h1.586l-1.586 1.586zM15 12h-3v3h-5v-9h8v6z"></path>
</svg>

After

Width:  |  Height:  |  Size: 522 B

6
assets/img/paste3.svg Normal file
View File

@@ -0,0 +1,6 @@
<!-- Generated by IcoMoon.io -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
<title>paste3</title>
<path d="M8 8v2h0.5l0.5-1h1v4h-0.75v1h3.5v-1h-0.75v-4h1l0.5 1h0.5v-2z"></path>
<path d="M13 5v-2.5c0-0.275-0.225-0.5-0.5-0.5h-3.5v-1c0-0.55-0.45-1-1-1h-2c-0.55 0-1 0.45-1 1v1h-3.5c-0.275 0-0.5 0.225-0.5 0.5v10c0 0.275 0.225 0.5 0.5 0.5h4.5v3h10v-11h-3zM6 1.002c0.001-0.001 0.001-0.001 0.002-0.002h1.996c0.001 0.001 0.001 0.001 0.002 0.002v0.998h-2v-0.998zM3 4v-1h8v1h-8zM15 15h-8v-9h8v9z"></path>
</svg>

After

Width:  |  Height:  |  Size: 557 B

5
assets/img/unlocked.svg Normal file
View File

@@ -0,0 +1,5 @@
<!-- Generated by IcoMoon.io -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
<title>unlocked</title>
<path d="M12 1c1.654 0 3 1.346 3 3v3h-2v-3c0-0.551-0.449-1-1-1h-2c-0.551 0-1 0.449-1 1v3h0.25c0.412 0 0.75 0.338 0.75 0.75v7.5c0 0.412-0.338 0.75-0.75 0.75h-8.5c-0.412 0-0.75-0.338-0.75-0.75v-7.5c0-0.412 0.338-0.75 0.75-0.75h6.25v-3c0-1.654 1.346-3 3-3h2z"></path>
</svg>

After

Width:  |  Height:  |  Size: 427 B

View File

@@ -2,4 +2,9 @@ export default {
api: {
url: `${window.location.origin}/api`,
},
filename: {
pattern: '{site.name} - {title} ({actors.$n.name}, {date} {shootId})',
separator: ', ',
date: 'DD-MM-YYYY',
},
};

View File

@@ -19,7 +19,7 @@ function initNetworksActions(store, _router) {
slug
url
sites(
orderBy: PRIORITY_DESC,
orderBy: [PRIORITY_DESC, NAME_ASC],
filter: {
enabled: {
equalTo: true,