forked from DebaucheryLibrarian/traxxx
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:
@@ -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;
|
||||
|
||||
@@ -46,7 +46,7 @@ export default {
|
||||
.logo {
|
||||
width: 100%;
|
||||
height: 5rem;
|
||||
color: $text;
|
||||
color: $text-contrast;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
Reference in New Issue
Block a user