Skip to content

Commit

Permalink
Escape title inside blocks
Browse files Browse the repository at this point in the history
  • Loading branch information
artf committed Feb 26, 2018
1 parent 1f2a083 commit e60a5bc
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion dist/css/grapes.min.css

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion src/block_manager/view/BlockView.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ module.exports = Backbone.View.extend({
const className = `${pfx}block`;
const label = this.model.get('label');
el.className += ` ${className} ${pfx}one-bg ${pfx}four-color-h`;
el.innerHTML = `<div title="${label}" class="${className}-label">${label}</div>`;
el.innerHTML = `<div class="${className}-label">${label}</div>`;
el.title = el.textContent.trim();
hasDnd(this.em) && el.setAttribute('draggable', true);
return this;
}
Expand Down
2 changes: 1 addition & 1 deletion src/styles/scss/_gjs_blocks.scss
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
width: 45%;
padding: 1em;
box-sizing: border-box;
height: 103px;
height: 90px;
cursor: all-scroll;
font-size: 11px;
font-weight: lighter;
Expand Down

0 comments on commit e60a5bc

Please sign in to comment.