mirror of
https://github.com/gradio-app/gradio.git
synced 2024-12-21 02:19:59 +08:00
remove alpha from brush
This commit is contained in:
parent
cff874ff51
commit
3f6695c4f1
@ -68,6 +68,9 @@ const image_input = {
|
||||
let io = get_interface(e.target);
|
||||
io.overlay_target.addClass("hide");
|
||||
if ($(e.target).hasClass('tui_save')) {
|
||||
// if (io.tui_editor.ui.submenu == "crop") {
|
||||
// io.tui_editor._cropAction().crop());
|
||||
// }
|
||||
io.set_image_data(io.tui_editor.toDataURL(), /*update_editor=*/false);
|
||||
}
|
||||
})
|
||||
|
@ -29,7 +29,6 @@ function resizeImage(base64Str, max_width, max_height, callback) {
|
||||
canvas.height = height;
|
||||
var ctx = canvas.getContext('2d');
|
||||
ctx.drawImage(img, 0, 0, width, height);
|
||||
console.log(canvas.toDataURL())
|
||||
callback.call(null, canvas.toDataURL());
|
||||
}
|
||||
}
|
||||
|
2
gradio/static/js/vendor/tui-image-editor.js
vendored
2
gradio/static/js/vendor/tui-image-editor.js
vendored
@ -8262,7 +8262,7 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
|
||||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
|
||||
|
||||
var DRAW_OPACITY = 0.7;
|
||||
var DRAW_OPACITY = 1;
|
||||
|
||||
/**
|
||||
* Draw ui class
|
||||
|
Loading…
Reference in New Issue
Block a user