mirror of
https://github.com/Tygs/0bin.git
synced 2023-08-10 21:13:00 +03:00
113 lines
3.9 KiB
Smarty
113 lines
3.9 KiB
Smarty
%if "burn_after_reading" in str(paste.expiration):
|
||
%if keep_alive:
|
||
<p class="alert alert-info">
|
||
<a class="close" data-dismiss="alert" href="#" @click.prevent="$event.target.parentNode.remove()">×</a>
|
||
<strong class="title">Ok!</strong>
|
||
<span class="message">
|
||
This paste will be deleted the next time it is read.
|
||
</span>
|
||
</p>
|
||
%else:
|
||
<p class="alert">
|
||
<a class="close" data-dismiss="alert" href="#" @click.prevent="$event.target.parentNode.remove()">×</a>
|
||
<strong class="title">Warning!</strong>
|
||
<span class="message">
|
||
This paste has self-destructed. If you close this window,
|
||
there is no way to recover it.
|
||
</span>
|
||
</p>
|
||
%end
|
||
%end
|
||
|
||
<div class="well paste-form">
|
||
<form action="/" method="get" accept-charset="utf-8">
|
||
<p class="lnk-option">
|
||
<a id="clip-button" v-if="support.clipboard" href="#" @click.prevent="copyToClipboard()">Copy To Clipboard</a> |
|
||
|
||
<a id="email-link" href="#" @click="handleSendByEmail($event)">Email this</a>
|
||
|
||
<span class="paste-option btn-group top">
|
||
<button class="btn btn-clone" @click.prevent="handleClone()"><i class="icon-camera"></i> Clone</button>
|
||
<button class="btn" v-if="downloadLink.url">
|
||
<a :href="downloadLink.url" :download="downloadLink.name"><i class="icon-download"></i> Download</a>
|
||
</button>
|
||
|
||
|
||
<button class="btn">New Paste</button>
|
||
</span>
|
||
</p>
|
||
|
||
<div class="progress progress-striped active" v-show="isLoading">
|
||
<div class="bar"></div>
|
||
</div>
|
||
|
||
%expiration = paste.humanized_expiration
|
||
%if expiration:
|
||
<p id="expiration-tag">Expire {{ expiration }}</p>
|
||
%end
|
||
|
||
<p>
|
||
<pre id="paste-content" class="prettyprint">
|
||
<code>
|
||
{{ paste.content }}
|
||
</code>
|
||
</pre>
|
||
</p>
|
||
|
||
<p v-if="currentPaste.ownerKey">
|
||
<button type="button" class="btn btn-danger" @click="handleDeletePaste()">Delete this paste</button>
|
||
</p>
|
||
|
||
<p class="paste-option btn-group bottom">
|
||
<button class="btn btn-clone" @click.prevent="handleClone()"><i class="icon-camera"></i> Clone</button>
|
||
|
||
<button class="btn" v-if="downloadLink.url">
|
||
<a :href="downloadLink.url" :download="downloadLink.name"><i class="icon-download"></i> Download</a>
|
||
</button>
|
||
|
||
<button class="btn">New Paste</button>
|
||
</p>
|
||
|
||
</form>
|
||
</div>
|
||
|
||
<!-- For cloning -->
|
||
<div class="submit-form clone">
|
||
<form class="well" method="post" action="/paste/create" @submit.prevent="encryptAndSendPaste()">
|
||
<p class="paste-option">
|
||
<label for="expiration">Expiration:</label>
|
||
<select id="expiration" name="expiration" v-model="newPaste.expiration">
|
||
<option value="burn_after_reading">Burn after reading</option>
|
||
<option selected value="1_day">1 day</option>
|
||
<option value="1_month">1 month</option>
|
||
<option value="never">Never</option>
|
||
</select>
|
||
<button type="submit" class="btn btn-primary">Submit</button>
|
||
<button class="btn btn-danger" @click.prevent="handleCancelClone()">Cancel clone</button>
|
||
</p>
|
||
|
||
<div>
|
||
<div class="progress progress-striped active" v-show="isLoading">
|
||
<div class="bar"></div>
|
||
</div>
|
||
<textarea rows="10" style="width:100%;" class="input-xlarge" id="content" name="content" autofocus
|
||
v-on:keydown.prevent.ctrl.enter="encryptAndSendPaste()"></textarea>
|
||
</div>
|
||
|
||
<p class="paste-option down" v-if="displayBottomToolBar">
|
||
<label for="expiration">Expiration:</label>
|
||
<select id="expiration" name="expiration" v-model="newPaste.expiration">
|
||
<option value="burn_after_reading">Burn after reading</option>
|
||
<option selected value="1_day">1 day</option>
|
||
<option value="1_month">1 month</option>
|
||
<option value="never">Never</option>
|
||
</select>
|
||
<button type="submit" class="btn btn-primary">Submit</button>
|
||
</p>
|
||
</form>
|
||
</div>
|
||
|
||
|
||
|
||
% rebase("base", settings=settings, pastes_count=pastes_count)
|