Merge branch 'master' into pagination

This commit is contained in:
Denis Fedoseev 2017-08-04 10:00:22 +03:00
commit d2d31fd8c3
4 changed files with 53 additions and 19 deletions

View file

@ -1,16 +1,40 @@
.progress-bar {
height: 18px;
background: green;
}
.foto-block {
/* border: 1px solid black; */
}
.foto-block .image {
padding: 5px;
}
.foto-block .foto-notes {
padding: 5px;
}
.copy-img {
content:url(/img/copy_icon.png);
content: url(/img/copy_icon.png);
width: 32px;
height: 32px;
overflow: hidden;
cursor: pointer;
position: relative;
}
.copy-bb-more {
content: url(/img/more_icon.png);
width: 32px;
height: 32px;
overflow: hidden;
cursor: pointer;
position: relative;
}
.image-scale {
float: left;
padding-right: 5px;
position: relative;
}

BIN
public/img/more_icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

View file

@ -28,7 +28,7 @@
</div>
<div id="progress">
<div class="bar" style="width: 0%;"></div>
<div class="progress-bar" style="width: 0%;"></div>
</div>
<div id="lastUploadLog"></div>
</div>
@ -39,15 +39,33 @@
<div class="foto-block row" v-for="image in imagesList">
<div class="image col-md-3">
<img v-bind:src="image.thumbnail_url">
<div class="image_title">{{ image.id }} - {{ image.filename }}</div>
<div class="image_title">
{{ image.filename }}
</div>
</div>
<div class="foto-notes col-md-3">
<ul>
<li><a v-bind:href="image.original_url">Original</a> <div @click="copyText" class="copy-img">{{ hostname+image.original_url }}</div></li>
<li v-for="scale in image.scales">
<a v-bind:href="scale.url">{{ scale.size }}</a> <div @click="copyText" class="copy-img">{{ hostname+scale.url }}</div>
</li>
</ul>
<div class="image-scale image-original">
<div class="image-scale-url">
<a v-bind:href="image.original_url">Original</a>
</div>
<div @click="copyText" class="copy-img">
&lt;img src={{ hostname+image.original_url }}&gt;
</div>
<div @click="copyText" class="copy-bb-more">
[MORE=&lt;img src={{ hostname+image.thumbnail_url }}&gt;]&lt;img src={{ hostname+image.original_url }}&gt;[/MORE]
</div>
</div>
<div class="image-scale" v-for="scale in image.scales">
<div class="image-scale-url">
<a v-bind:href="scale.url">{{ scale.size }}</a>
</div>
<div @click="copyText" class="copy-img">
&lt;img src={{ hostname+scale.url }}&gt;
</div>
<div @click="copyText" class="copy-bb-more">
[MORE=&lt;img src={{ hostname+image.thumbnail_url }}&gt;]&lt;img src={{ hostname+scale.url }}&gt;[/MORE]
</div>
</div>
</div>
</div>
<div class="container paginator">
@ -100,7 +118,7 @@
//TODO: rewrite it to vue or pure JS from jQuery
var $temp = $("<input>");
$("body").append($temp);
$temp.val("<img src="+$(event.target).text()+">").select();
$temp.val($(event.target).text().trim()).select();
document.execCommand("copy");
$temp.remove();
},

View file

@ -14,15 +14,7 @@
<link rel="stylesheet" href="/file_uploader/css/jquery.fileupload-ui.css">
<link rel="stylesheet" href="/css/main.css">
<script src="https://vuejs.org/js/vue.min.js"></script>
<script src="https://cdn.jsdelivr.net/vuejs-paginator/2.0.1/vuejs-paginator.min.js"></script>
<style>
.bar {
height: 18px;
background: green;
}
</style>
<script src="https://vuejs.org/js/vue.min.js"></script>
</head>
<body>
<div class="navbar navbar-inverse navbar-fixed-top" role="navigation">