annotation color and clone templates
This commit is contained in:
@@ -22,6 +22,8 @@ $(document).ready(function () {
|
||||
let partsListData = [];
|
||||
// DIMENSIONE GLOBALE MARKER
|
||||
let globalMarkerSize = 16;
|
||||
// COLORE TESTO LISTA DESCRIZIONI
|
||||
let globalDescriptionColor = "#000000";
|
||||
|
||||
// ===================
|
||||
// MODAL INITIALIZATION
|
||||
@@ -138,6 +140,7 @@ $(document).ready(function () {
|
||||
descriptionTextbox = null;
|
||||
markerObjects = {};
|
||||
globalMarkerSize = 16;
|
||||
globalDescriptionColor = "#000000";
|
||||
$("#photoSelectorContainerAnnotations").empty().hide();
|
||||
$("#samplePhotoAnnotations").attr("src", "");
|
||||
$("#partsListAnnotations").empty();
|
||||
@@ -177,7 +180,25 @@ $(document).ready(function () {
|
||||
updateMarkers();
|
||||
markUnsaved();
|
||||
});
|
||||
// ===================
|
||||
// COLORE LISTA DESCRIZIONI
|
||||
// ===================
|
||||
$(document)
|
||||
.off("input.descriptionColor", "#descriptionColorPickerAnnotations")
|
||||
.on(
|
||||
"input.descriptionColor",
|
||||
"#descriptionColorPickerAnnotations",
|
||||
function () {
|
||||
globalDescriptionColor = $(this).val();
|
||||
|
||||
if (descriptionTextbox && fabricCanvas) {
|
||||
descriptionTextbox.set("fill", globalDescriptionColor);
|
||||
fabricCanvas.renderAll();
|
||||
}
|
||||
|
||||
markUnsaved();
|
||||
},
|
||||
);
|
||||
// ===================
|
||||
// PHOTO LOADERS
|
||||
// ===================
|
||||
@@ -1130,7 +1151,7 @@ $(document).ready(function () {
|
||||
backgroundColor: "transparent",
|
||||
fontFamily: "Arial",
|
||||
fontSize: Math.max(16, Math.round(globalMarkerSize * 0.8)),
|
||||
fill: "#000000",
|
||||
fill: globalDescriptionColor,
|
||||
padding: 10,
|
||||
editable: false,
|
||||
selectable: true,
|
||||
|
||||
Reference in New Issue
Block a user