File tree Expand file tree Collapse file tree 1 file changed +14
-4
lines changed Expand file tree Collapse file tree 1 file changed +14
-4
lines changed Original file line number Diff line number Diff line change 4
4
* https://github.com/marcj/css-element-queries/blob/master/LICENSE.
5
5
*/
6
6
;
7
- ( function ( ) {
7
+ ( function ( root , factory ) {
8
+ if ( typeof define === 'function' && define . amd ) {
9
+ define ( [ ] , factory ) ;
10
+ } else if ( typeof module === 'object' && module . exports ) {
11
+ module . exports = factory ( ) ;
12
+ } else {
13
+ root . ResizeSensor = factory ( ) ;
14
+ }
15
+ } ( this , function ( ) {
8
16
9
17
/**
10
18
* Class for dimension change detection.
14
22
*
15
23
* @constructor
16
24
*/
17
- this . ResizeSensor = function ( element , callback ) {
25
+ function ResizeSensor ( element , callback ) {
18
26
/**
19
27
*
20
28
* @constructor
155
163
} ;
156
164
} ;
157
165
158
- this . ResizeSensor . detach = function ( element ) {
166
+ ResizeSensor . detach = function ( element ) {
159
167
if ( element . resizeSensor ) {
160
168
element . removeChild ( element . resizeSensor ) ;
161
169
delete element . resizeSensor ;
162
170
delete element . resizedAttached ;
163
171
}
164
172
} ;
165
173
166
- } ) ( ) ;
174
+ return ResizeSensor ;
175
+
176
+ } ) ) ;
You can’t perform that action at this time.
0 commit comments