From e144739dece9155e603cbb8afaa1d37a1df6d1b8 Mon Sep 17 00:00:00 2001 From: El RIDO Date: Fri, 18 Sep 2015 10:49:39 +0200 Subject: [PATCH] implement file upload UI on bootstrap templates --- js/zerobin.js | 3 +-- tpl/bootstrap-compact.html | 26 ++++++++++++++++++++++++-- tpl/bootstrap.html | 32 +++++++++++++++++++++++++++++--- 3 files changed, 54 insertions(+), 7 deletions(-) diff --git a/js/zerobin.js b/js/zerobin.js index 479e384..b5c08fa 100644 --- a/js/zerobin.js +++ b/js/zerobin.js @@ -922,6 +922,7 @@ $(function() { stateNewPaste: function() { this.message.text(''); + this.attachment.addClass('hidden'); this.cloneButton.addClass('hidden'); this.rawTextButton.addClass('hidden'); this.remainingTime.addClass('hidden'); @@ -937,7 +938,6 @@ $(function() { this.newButton.removeClass('hidden'); this.password.removeClass('hidden'); this.attach.removeClass('hidden'); - this.attachment.removeClass('hidden'); this.message.removeClass('hidden'); this.message.focus(); }, @@ -961,7 +961,6 @@ $(function() { this.rawTextButton.removeClass('hidden'); this.attach.addClass('hidden'); - this.attachment.addClass('hidden'); this.expiration.addClass('hidden'); this.formatter.addClass('hidden'); this.burnAfterReadingOption.addClass('hidden'); diff --git a/tpl/bootstrap-compact.html b/tpl/bootstrap-compact.html index b8c82b5..42f6f93 100644 --- a/tpl/bootstrap-compact.html +++ b/tpl/bootstrap-compact.html @@ -57,7 +57,11 @@ {/if}{if="$FILEUPLOAD"} + {/if}