Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-17090] MobileWeb: height values is displayed as "auto" when button, styles property set as height: Ti.UI.SIZE

GitHub Issuen/a
TypeBug
PriorityLow
StatusClosed
ResolutionWon't Fix
Resolution Date2017-06-26T18:45:11.000+0000
Affected Version/sRelease 3.3.0
Fix Version/sn/a
ComponentsMobileWeb
Labelsqe-3.3.0
ReporterPriya Agarwal
AssigneeChris Barber
Created2014-06-09T11:18:42.000+0000
Updated2018-04-04T23:20:39.000+0000

Description

height values is displayed as "auto" when button, styles properties set as height: Ti.UI.SIZE. Steps to reproduce: index.js:
$.index.open();

var style = require('alloy/styles/index');
var i, len;	
for (i = 0, len = $.index.children.length; i < len; i++) {
	var child = $.index.children[i];
	child.addEventListener('click', function(e) {
		var id = e.source.id;
		_.each(style, function(o) {
			if (o.key === id && o.isId) {
				// print each style that applies by ID to the source
				alert(JSON.stringify(o));
			}
		});
	});
}
index.xml:
<Alloy>
	<Window>
		<Label id="info">Click anything to see its ID style entry</Label>
		<Button id="button1">button1</Button>
		<Button id="button2">button2</Button>
		<Button id="button3">button3</Button>
	</Window>
</Alloy>
index.tss:
"#index": {
	layout: 'vertical'
}
"#button1": {
	height: '70dp',
	width: '250dp',
	borderRadius: 8,
	borderWidth: 2,
	borderColor: '#500'
}

"#button2": {
	width: '100dp',
	height: Ti.UI.SIZE
}

"#button3": {
	height: '40dp',
	width: '200dp',
	borderRadius: 32,
	borderWidth: 1,
	borderColor: '#0f0'
}
1. Run the sample test code 2. Click on the button2. Expected Result: 1. alert must pop up with height value as "SIZE" Actual Result: 1. alert must pop up with height value as "auto" Note: This is not a regression. Occurs with alloy@1.3.1 also Working fine for normal iOS and Android project.

Comments

  1. Lee Morris 2017-06-26

    Marking ticket as "Won't Fix" as MobileWeb has been deprecated.
  2. Eric Merriman 2018-04-04

    Closing as will not fix.

JSON Source