mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-01-06 23:52:58 +01:00
Move tpl and less to core
This commit is contained in:
@@ -129,4 +129,14 @@
|
||||
|
||||
.admin .ban-modal .units {
|
||||
line-height: 1.846;
|
||||
}
|
||||
}
|
||||
|
||||
#crop-picture-modal {
|
||||
.cropped-image {
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.cropper-container.cropper-bg {
|
||||
max-width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -212,7 +212,8 @@ define('forum/account/edit', ['forum/account/header', 'uploader', 'translator',
|
||||
}
|
||||
|
||||
function handleImageCrop(data) {
|
||||
templates.parse('partials/modals/crop_uploaded_picture', {url: data.url}, function (cropperHtml) {
|
||||
$('#crop-picture-modal').remove();
|
||||
templates.parse('modals/crop_picture', {url: data.url}, function (cropperHtml) {
|
||||
translator.translate(cropperHtml, function (translated) {
|
||||
var cropperModal = $(translated);
|
||||
cropperModal.modal('show');
|
||||
|
||||
22
src/views/modals/crop_picture.tpl
Normal file
22
src/views/modals/crop_picture.tpl
Normal file
@@ -0,0 +1,22 @@
|
||||
<div id="crop-picture-modal" class="modal" tabindex="-1" role="dialog" aria-labelledby="crop-picture" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
<h3 id="crop-picture">[[user:crop_picture]]</h3>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div id="upload-progress-box" class="progress hide">
|
||||
<div id="upload-progress-bar" class="progress-bar progress-bar-striped active" role="progressbar" aria-valuenow="0" aria-valuemin="0">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<img id="cropped-image" src="{url}" >
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button class="btn btn-default" data-dismiss="modal" aria-hidden="true">Close</button>
|
||||
<button class="btn btn-primary crop-btn">[[user:upload_cropped_picture]]</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
Reference in New Issue
Block a user