Merge pull request #39083 from AarDG10/fix-img-css
fix: fix image overflow by restricting width to 100% of column
This commit is contained in:
commit
cbd6d59cf1
1 changed files with 3 additions and 3 deletions
|
|
@ -10,9 +10,9 @@ frappe.ui.form.ControlImage = class ControlImage extends frappe.ui.form.Control
|
|||
|
||||
var doc = this.get_doc();
|
||||
if (doc && this.df.options && doc[this.df.options]) {
|
||||
this.$img = $(
|
||||
"<img src='" + doc[this.df.options] + "' class='img-responsive'>"
|
||||
).appendTo(this.$body);
|
||||
this.$img = $("<img src='" + doc[this.df.options] + "' class='img-responsive'>")
|
||||
.appendTo(this.$body)
|
||||
.css({ "max-width": "100%" });
|
||||
} else {
|
||||
this.$buffer = $(
|
||||
`<div class='missing-image'>${frappe.utils.icon("restriction", "md")}</div>`
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue