1
0
Fork 1
mirror of https://github.com/pixelfed/pixelfed.git synced 2024-12-24 16:53:17 +00:00

Update ComposeModal.vue

This commit is contained in:
Daniel Supernault 2019-07-08 23:23:59 -06:00
parent 623e0c9adb
commit e4d6b0022d
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7

View file

@ -1,16 +1,5 @@
<template>
<div>
<div v-if="!composeType">
<div class="card">
<div class="card-body">
<button type="button" class="btn btn-primary btn-block font-weight-bold" @click="composeType = 'post'">Compose Post</button>
<hr>
<!-- <button type="button" class="btn btn-outline-secondary btn-block font-weight-bold" @click="composeType = 'story'">Add Story</button> -->
<button type="button" class="btn btn-outline-secondary btn-block font-weight-bold" @click="composeType = 'loop'">Create Loop</button>
</div>
</div>
</div>
<div v-if="composeType == 'post'">
<input type="file" name="media" class="d-none file-input" multiple="" v-bind:accept="config.uploader.media_types">
<div class="timeline">
<div class="card status-card card-md-rounded-0">
@ -27,7 +16,6 @@
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="dropdownMenuButton">
<div v-show="media.length > 0" class="dropdown-item small font-weight-bold" v-on:click="mediaDrawer = !mediaDrawer">{{mediaDrawer ? 'Hide' : 'Show'}} Media Toolbar</div>
<div class="dropdown-item small font-weight-bold" v-on:click="about">About</div>
<a class="dropdown-item small font-weight-bold" href="/i/compose">Classic Compose UI</a>
<div class="dropdown-divider"></div>
<div class="dropdown-item small font-weight-bold" v-on:click="closeModal">Close</div>
</div>
@ -85,15 +73,15 @@
</ul>
</div>
</div>
<div v-if="mediaDrawer" class="bg-lighter p-2 row">
<div v-if="ids.length > 0 && media[carouselCursor].type == 'Image'" class="bg-lighter p-2 row">
<div class="col-12">
<div class="form-group">
<input type="text" class="form-control" v-model="media[carouselCursor].alt" placeholder="Optional image description">
</div>
<div class="form-group">
<!-- <div class="form-group">
<input type="text" class="form-control" v-model="media[carouselCursor].license" placeholder="Optional media license">
</div>
</div> -->
</div>
<!-- <div class="col-6 pt-2">
<button class="btn btn-outline-secondary btn-sm mr-1"><i class="fas fa-map-marker-alt"></i></button>
@ -101,12 +89,11 @@
</div> -->
<div class="col-12 text-right pt-2">
<button class="btn btn-outline-danger btn-sm font-weight-bold mr-1" v-on:click="deleteMedia()">Delete Photo</button>
<button class="btn btn-outline-secondary btn-sm font-weight-bold" v-on:click="updateMedia()">Hide Media Toolbar</button>
</div>
</div>
</div>
<div class="card-body p-0">
<div class="card-body p-0 border-top">
<div class="caption">
<textarea class="form-control mb-0 border-0 rounded-0" rows="3" placeholder="Add an optional caption" v-model="composeText"></textarea>
</div>
@ -205,30 +192,6 @@
</div>
</div>
</div>
<div v-if="composeType == 'loop'">
<div class="card">
<div class="card-body">
<button type="button" class="btn btn-primary btn-block font-weight-bold" @click="composeType = 'post'">Upload Loop</button>
<hr>
<button type="button" class="btn btn-outline-secondary btn-block font-weight-bold" @click="composeType = ''">Back</button>
<!-- <button type="button" class="btn btn-outline-secondary btn-block font-weight-bold">Import from Coub</button>
<button type="button" class="btn btn-outline-secondary btn-block font-weight-bold">Import from Vine</button>
<button type="button" class="btn btn-outline-secondary btn-block font-weight-bold">Import from YouTube</button> -->
</div>
</div>
</div>
<div v-if="composeType == 'story'">
<div class="card">
<div class="card-body">
<button type="button" class="btn btn-primary btn-block font-weight-bold" @click="composeType = 'post'">Add to Story</button>
<hr>
<button type="button" class="btn btn-outline-primary btn-block font-weight-bold" @click="composeType = 'post'">New Story</button>
<hr>
<button type="button" class="btn btn-outline-secondary btn-block font-weight-bold" @click="composeType = ''">Back</button>
</div>
</div>
</div>
</div>
</template>
<style type="text/css" scoped>