Skip to content

Commit

Permalink
perf(chatScroll): Fix image loading from https url and raw data
Browse files Browse the repository at this point in the history
perf(chatScroll): Fix comments on Fix image loading from https url and raw data
  • Loading branch information
alexjba committed Jan 19, 2023
1 parent 6c76026 commit 2723ef1
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions ui/StatusQ/src/StatusQ/Core/StatusIcon.qml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,13 @@ Image {
fillMode: Image.PreserveAspectFit

onIconChanged: {
if (icon !== "") {
source = "../../assets/img/icons/" + icon + ".svg";
if(icon.startsWith("data:image/") || icon.startsWith("https://")) {
//raw image data
source = icon
objectName = "custom-icon"
}
else if (icon !== "") {
source = "../../assets/img/icons/" + icon+ ".svg";
objectName = icon + "-icon"
}
}
Expand Down

0 comments on commit 2723ef1

Please # to comment.