diff --git a/customize.dist/translations/messages.js b/customize.dist/translations/messages.js index fa08fb1c7..cc279516c 100644 --- a/customize.dist/translations/messages.js +++ b/customize.dist/translations/messages.js @@ -211,6 +211,9 @@ define(function () { out.canvas_enable = "Enable draw"; out.canvas_width = "Width"; out.canvas_opacity = "Opacity"; + out.canvas_opacityLabel = "opacity: {0}"; + out.canvas_widthLabel = "Width: {0}"; + // File manager diff --git a/www/whiteboard/main.js b/www/whiteboard/main.js index a96fdb457..a19b5ba63 100644 --- a/www/whiteboard/main.js +++ b/www/whiteboard/main.js @@ -97,7 +97,8 @@ window.canvas = canvas; var updateBrushWidth = function () { var val = $width.val(); canvas.freeDrawingBrush.width = Number(val); - $widthLabel.text(val); + $widthLabel.text(val) + $widthLabel.text(Cryptpad.Messages._getKey("canvas_widthLabel", [val])) $widthLabel.text("width: " + $width.val()) createCursor(); console.log("change size") @@ -111,7 +112,7 @@ window.canvas = canvas; brush.opacity = Number(val); canvas.freeDrawingBrush.color = Colors.hex2rgba(brush.color, brush.opacity); $opacityLabel.text(val) - $opacityLabel.text("opacity: " + $opacity.val()); + $opacityLabel.text(Cryptpad.Messages._getKey("canvas_opacityLabel", [val])); createCursor(); console.log("change opacity") console.log("opacity: " + $opacity.val())