EditAssetForm: replace widget class with generic content box
This commit is contained in:
@@ -74,30 +74,6 @@ body {
|
||||
}
|
||||
|
||||
|
||||
/* Admin widgets
|
||||
------------------*/
|
||||
.widget {
|
||||
background: #fff;
|
||||
padding: 25px;
|
||||
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
.widget h3 {
|
||||
margin: 0 0 1em;
|
||||
font: 400 18px "Raleway", sans-serif;
|
||||
}
|
||||
.widget p, .errormsg p {
|
||||
margin: 0;
|
||||
}
|
||||
.widget ul {
|
||||
margin: 0;
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
}
|
||||
.widget li {
|
||||
line-height: 1.7em;
|
||||
}
|
||||
|
||||
|
||||
/* Edit icon on tiled grids
|
||||
-----------------------------*/
|
||||
.tiled_grid div.landscape, .tiled_grid div.portrait, .tiled_grid div.panorama {
|
||||
@@ -134,7 +110,7 @@ body {
|
||||
color: #fff;
|
||||
}
|
||||
#crop_editor input[type=number] {
|
||||
width: 50px;
|
||||
width: 75px;
|
||||
background: #555;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@ class CropEditor {
|
||||
this.opt = opt;
|
||||
|
||||
this.edit_crop_button = document.createElement("span");
|
||||
this.edit_crop_button.className = "btn";
|
||||
this.edit_crop_button.className = "btn btn-light";
|
||||
this.edit_crop_button.textContent = "Edit crop";
|
||||
this.edit_crop_button.addEventListener('click', this.show.bind(this));
|
||||
|
||||
@@ -34,6 +34,7 @@ class CropEditor {
|
||||
this.position.appendChild(source_x_label);
|
||||
|
||||
this.source_x = document.createElement("input");
|
||||
this.source_x.className = 'form-control d-inline';
|
||||
this.source_x.type = 'number';
|
||||
this.source_x.addEventListener("change", this.positionBoundary.bind(this));
|
||||
this.source_x.addEventListener("keyup", this.positionBoundary.bind(this));
|
||||
@@ -43,6 +44,7 @@ class CropEditor {
|
||||
this.position.appendChild(source_y_label);
|
||||
|
||||
this.source_y = document.createElement("input");
|
||||
this.source_y.className = 'form-control d-inline';
|
||||
this.source_y.type = 'number';
|
||||
this.source_y.addEventListener("change", this.positionBoundary.bind(this));
|
||||
this.source_y.addEventListener("keyup", this.positionBoundary.bind(this));
|
||||
@@ -52,6 +54,7 @@ class CropEditor {
|
||||
this.position.appendChild(crop_width_label);
|
||||
|
||||
this.crop_width = document.createElement("input");
|
||||
this.crop_width.className = 'form-control d-inline';
|
||||
this.crop_width.type = 'number';
|
||||
this.crop_width.addEventListener("change", this.positionBoundary.bind(this));
|
||||
this.crop_width.addEventListener("keyup", this.positionBoundary.bind(this));
|
||||
@@ -61,6 +64,7 @@ class CropEditor {
|
||||
this.position.appendChild(crop_height_label);
|
||||
|
||||
this.crop_height = document.createElement("input");
|
||||
this.crop_height.className = 'form-control d-inline';
|
||||
this.crop_height.type = 'number';
|
||||
this.crop_height.addEventListener("change", this.positionBoundary.bind(this));
|
||||
this.crop_height.addEventListener("keyup", this.positionBoundary.bind(this));
|
||||
@@ -78,13 +82,13 @@ class CropEditor {
|
||||
this.crop_constrain_label.appendChild(this.crop_constrain_text);
|
||||
|
||||
this.save_button = document.createElement("span");
|
||||
this.save_button.className = "btn";
|
||||
this.save_button.className = "btn btn-light";
|
||||
this.save_button.textContent = "Save";
|
||||
this.save_button.addEventListener('click', this.save.bind(this));
|
||||
this.position.appendChild(this.save_button);
|
||||
|
||||
this.abort_button = document.createElement("span");
|
||||
this.abort_button.className = "btn btn-red";
|
||||
this.abort_button.className = "btn btn-danger";
|
||||
this.abort_button.textContent = "Abort";
|
||||
this.abort_button.addEventListener('click', this.hide.bind(this));
|
||||
this.position.appendChild(this.abort_button);
|
||||
|
||||
Reference in New Issue
Block a user