better handling for padding in a top/bottom or left/right configuration
This commit is contained in:
@@ -983,6 +983,28 @@ describe('Layout', function() {
|
||||
);
|
||||
});
|
||||
|
||||
it('should layout with position absolute left, right and width', function() {
|
||||
testLayout(
|
||||
{style: {}, children: [
|
||||
{style: {left: 5, right: -1, width: 300, position: 'absolute'}}
|
||||
]},
|
||||
{width: 0, height: 0, top: 0, left: 0, children: [
|
||||
{width: 300, height: 0, top: 0, left: 5}
|
||||
]}
|
||||
);
|
||||
});
|
||||
|
||||
it('should layout with position absolute top, bottom and min padding', function() {
|
||||
testLayout(
|
||||
{style: {}, children: [
|
||||
{style: {top: -5, bottom: -5, paddingTop: 5, position: 'absolute'}}
|
||||
]},
|
||||
{width: 0, height: 0, top: 0, left: 0, children: [
|
||||
{width: 0, height: 10, top: -5, left: 0}
|
||||
]}
|
||||
);
|
||||
});
|
||||
|
||||
xit('should layout text with alignItems: stretch', function() {
|
||||
testLayout(
|
||||
{style: {width: 80, padding: 7, alignItems: 'stretch', measure: text('loooooooooong with space')}},
|
||||
|
Reference in New Issue
Block a user