mirror of
https://github.com/fastmail/Squire.git
synced 2025-01-03 05:00:13 -05:00
Merge pull request #103 from shiawuen/top
fix bug on Browserify component when embed in multi layers of iframe
This commit is contained in:
commit
de7d7011a7
1 changed files with 8 additions and 8 deletions
|
@ -1,14 +1,14 @@
|
|||
/*jshint ignore:start */
|
||||
|
||||
if ( top !== win ) {
|
||||
win.editor = new Squire( doc );
|
||||
if ( win.onEditorLoad ) {
|
||||
win.onEditorLoad( win.editor );
|
||||
win.onEditorLoad = null;
|
||||
}
|
||||
if ( typeof exports === 'object' ) {
|
||||
module.exports = Squire;
|
||||
} else {
|
||||
if ( typeof exports === 'object' ) {
|
||||
module.exports = Squire;
|
||||
if ( top !== win ) {
|
||||
win.editor = new Squire( doc );
|
||||
if ( win.onEditorLoad ) {
|
||||
win.onEditorLoad( win.editor );
|
||||
win.onEditorLoad = null;
|
||||
}
|
||||
} else {
|
||||
win.Squire = Squire;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue