[AC-1935] Alloy doesn't compile internationalized labels of Ti.UI.iOS.TabbedBar
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | n/a |
Status | Closed |
Resolution | Duplicate |
Resolution Date | 2013-07-08T19:33:20.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | Alloy, Titanium SDK & CLI |
Labels | alloy, i18n, internationalization, labels, tabbedbar |
Reporter | Manuel Lehner |
Assignee | Mauro Parra-Miranda |
Created | 2013-07-08T19:27:26.000+0000 |
Updated | 2016-03-08T07:40:51.000+0000 |
Description
When trying to set internationalized labels to a Ti.UI.iOS.TabbedBar like in the following example, Alloy fails to compile.
The titles of both labels were set with different approaches (first one with *titleid* property, the other one via tss accessed by its id)
index.xml
at index ' + index + ' has no properties');
[ERROR] :
[ERROR] : ^
[ERROR] : ReferenceError: logger is not defined
[ERROR] : at parse (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/Alloy.Abstract.BarItemType.js:30:3)
[ERROR] : at Object.exports.parse (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/base.js:11:17)
[ERROR] : at Object.exports.parse (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/Alloy.Abstract.BarItemType.js:6:27)
[ERROR] : at Object.exports.generateNode (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/compilerUtils.js:223:48)
[ERROR] : at exports.generateNode.content (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/compilerUtils.js:277:29)
[ERROR] : at Array.forEach (native)
[ERROR] : at Function.T.each.T.forEach (/usr/local/lib/node_modules/alloy/Alloy/lib/alloy/underscore.js:5:625)
[ERROR] : at Object.exports.generateNode (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/compilerUtils.js:272:5)
[ERROR] : at Object.exports.generateNodeExtended (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/compilerUtils.js:175:17)
[ERROR] : at /usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/Alloy.Abstract._ItemContainer.js:48:15
[ERROR] : at Array.forEach (native)
[ERROR] : at Function.T.each.T.forEach (/usr/local/lib/node_modules/alloy/Alloy/lib/alloy/underscore.js:5:625)
[ERROR] : at parse (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/Alloy.Abstract._ItemContainer.js:28:4)
[ERROR] : at Object.exports.parse (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/base.js:11:17)
[ERROR] : at Object.exports.parse (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/Alloy.Abstract._ItemContainer.js:17:27)
[ERROR] : at Object.exports.parse (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/Ti.UI.ButtonBar.js:14:52)
[ERROR] : at Object.exports.parse (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/Ti.UI.iOS.TabbedBar.js:2:38)
[ERROR] : at Object.exports.generateNode (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/compilerUtils.js:223:48)
[ERROR] : at exports.generateNode.content (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/compilerUtils.js:277:29)
[ERROR] : at Array.forEach (native)
[ERROR] : at Function.T.each.T.forEach (/usr/local/lib/node_modules/alloy/Alloy/lib/alloy/underscore.js:5:625)
[ERROR] : at Object.exports.generateNode (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/compilerUtils.js:272:5)
[ERROR] : at /usr/local/lib/node_modules/alloy/Alloy/commands/compile/index.js:447:28
[ERROR] : at Array.forEach (native)
[ERROR] : at Function.T.each.T.forEach (/usr/local/lib/node_modules/alloy/Alloy/lib/alloy/underscore.js:5:625)
[ERROR] : at parseAlloyComponent (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/index.js:439:5)
[ERROR] : at /usr/local/lib/node_modules/alloy/Alloy/commands/compile/index.js:202:5
[ERROR] : at Array.forEach (native)
[ERROR] : at Function.T.each.T.forEach (/usr/local/lib/node_modules/alloy/Alloy/lib/alloy/underscore.js:5:625)
[ERROR] : at /usr/local/lib/node_modules/alloy/Alloy/commands/compile/index.js:194:5
[ERROR] : at Array.forEach (native)
[ERROR] : at Function.T.each.T.forEach (/usr/local/lib/node_modules/alloy/Alloy/lib/alloy/underscore.js:5:625)
[ERROR] : at module.exports (/usr/local/lib/node_modules/alloy/Alloy/commands/compile/index.js:192:4)
[ERROR] : at Object. (/usr/local/lib/node_modules/alloy/Alloy/alloy.js:86:46)
[ERROR] : at Module._compile (module.js:449:26)
[ERROR] : at Object.Module._extensions..js (module.js:467:10)
[ERROR] : at Module.load (module.js:356:32)
[ERROR] : at Function.Module._load (module.js:312:12)
[ERROR] : at Module.require (module.js:362:17)
[ERROR] : at require (module.js:378:17)
[ERROR] : at Object. (/usr/local/lib/node_modules/alloy/bin/alloy:3:1)
[ERROR] : at Module._compile (module.js:449:26)
[ERROR] : at Object.Module._extensions..js (module.js:467:10)
[ERROR] : at Module.load (module.js:356:32)
[ERROR] : at Function.Module._load (module.js:312:12)
[ERROR] : at Module.runMain (module.js:492:10)
[ERROR] : at process.startup.processNextTick.process._tickCallback (node.js:245:9)
[ERROR] : Alloy compiler failed
{noformat}
<Alloy>
<Window class="container">
<TabbedBar id="tabbedbar" platform="ios" onClick="setView" >
<Labels id="labels">
<Label titleid="tab_one" />
<Label id="tab_two" />
</Labels>
</TabbedBar>
</Window>
</Alloy>
index.tss
".container": {
backgroundColor:"white"
},
"#tab_two": {
title: L('tab_two')
}
Both are producing this error:
{noformat}
[INFO] : ----- MVC GENERATION -----
[INFO] : [index.xml] view processing...
[INFO] : style: "index.tss"
[INFO] : view: "index.xml"
[ERROR] : /usr/local/lib/node_modules/alloy/Alloy/commands/compile/parsers/Alloy.Abstract.BarItemType.js:30
[ERROR] : logger.warn('
duplicate of ALOY-734
DUP issue.
Trying to do: