facebook/litho

alignItems & baseline is not working properly with Text alignment

ryanhoo opened this issue · 1 comments

Version

The latest code on master branch.

Issues and Steps to Reproduce

Paste the code below to PlaygroundComponentSpec and run Litho sample project, click on Playground button and you will see this:
2

Expected Behavior

1

Link to Code

@LayoutSpec
public class PlaygroundComponentSpec {

    @OnCreateLayout
    static Component onCreateLayout(ComponentContext c) {
        return Row.create(c)
                .paddingDip(YogaEdge.ALL, 24f)
                .alignItems(YogaAlign.BASELINE)
                .child(Text.create(c).text("$").textSizeDip(13f).backgroundColor(0x10000000))
                .child(Text.create(c).text("16").textSizeDip(33f).lineHeightDip(33f).backgroundColor(0x20000000))
                .child(Text.create(c).text(".87").textSizeDip(13f).backgroundColor(0x10000000))
                .build();
    }
}

Hi, @ryanhoo
I would like to work on this issue, if no one else have taken it up already.