Skip to content

Commit

Permalink
stop logging color stuff pleas
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremyGamer13 committed Jun 12, 2024
1 parent 9f6a13e commit 5f12e9e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
2 changes: 1 addition & 1 deletion blocks_vertical/procedures.js
Original file line number Diff line number Diff line change
Expand Up @@ -916,7 +916,7 @@ Blockly.ScratchBlocks.ProcedureUtils.argumentReporterDomToMutation = function(do
this.color = JSON.parse(dom.getAttribute('color'))
this.updateDisplay_()
} catch (err) {
console.log('unkown old argument reporter')
console.warn('unknown old argument reporter')
}
};

Expand Down
3 changes: 0 additions & 3 deletions core/blockly.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,6 @@ goog.color.hsvaToHex = function(hue, saturation, value, alpha) {
var hex = goog.color.hsvToHex(hue, saturation, value)
var alpha = goog.constrain(Math.floor(alpha * 255), 0, 255).toString(16)
if (alpha.length === 1) alpha = '0' + alpha
console.log('set', alpha)
return hex + alpha
}

Expand All @@ -162,11 +161,9 @@ goog.color.hsvaToHex = function(hue, saturation, value, alpha) {
*/
goog.color.hexToHsva = function(decimal) {
var alpha = (() => {
console.log(decimal, decimal.slice(7, 9), parseInt(decimal.slice(7, 9), 16))
if (typeof decimal === 'string') return parseInt(decimal.slice(7, 9), 16)
return decimal & 0xFF
})() / 255
console.log('get', alpha)

var [hue, saturation, value] = goog.color.hexToHsv(decimal.slice(0, 7))
return [hue,saturation,value,alpha];
Expand Down

0 comments on commit 5f12e9e

Please sign in to comment.