2015-01-08 00:21:53 -05:00
|
|
|
/*jshint ignore:start */
|
2013-06-20 08:15:18 -05:00
|
|
|
|
2015-06-18 23:12:37 -05:00
|
|
|
if ( typeof exports === 'object' ) {
|
|
|
|
module.exports = Squire;
|
2015-07-13 11:16:16 -05:00
|
|
|
} else if ( typeof define === 'function' && define.amd ) {
|
2015-07-13 11:33:38 -05:00
|
|
|
define( function () {
|
2015-07-13 11:16:16 -05:00
|
|
|
return Squire;
|
2015-07-13 11:33:38 -05:00
|
|
|
});
|
2013-06-20 08:15:18 -05:00
|
|
|
} else {
|
2015-07-06 00:19:21 -05:00
|
|
|
win.Squire = Squire;
|
|
|
|
|
|
|
|
if ( top !== win &&
|
|
|
|
doc.documentElement.getAttribute( 'data-squireinit' ) === 'true' ) {
|
2015-06-18 23:12:37 -05:00
|
|
|
win.editor = new Squire( doc );
|
|
|
|
if ( win.onEditorLoad ) {
|
|
|
|
win.onEditorLoad( win.editor );
|
|
|
|
win.onEditorLoad = null;
|
|
|
|
}
|
2015-05-06 21:52:32 -05:00
|
|
|
}
|
2013-06-20 08:15:18 -05:00
|
|
|
}
|
|
|
|
|
2013-04-07 22:27:06 -05:00
|
|
|
}( document ) );
|