Skip to content

Commit

Permalink
WebComponent support
Browse files Browse the repository at this point in the history
* insert style before our grid (instead of head) to support webcomponent
* fix gridstack#540
* tested on Chrome, FF, Edge, IE11 and all our demos
*Note: I didn't have a way to test webcomponent support, but this should do it.
  • Loading branch information
Alain Dumesny authored and adumesny committed May 12, 2020
1 parent f9a4ac4 commit 2510e3a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/gridstack.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,9 @@
return style.sheet;
},

removeStylesheet: function(id) {
$('STYLE[data-gs-style-id=' + id + ']').remove();
},
removeStylesheet: function(id) {
$('STYLE[data-gs-style-id=' + id + ']').remove();
},

insertCSSRule: function(sheet, selector, rules, index) {
if (typeof sheet.insertRule === 'function') {
Expand Down

0 comments on commit 2510e3a

Please sign in to comment.