navigator add openUrl

This commit is contained in:
pengfei.zhou
2020-04-01 15:19:37 +08:00
committed by osborn
parent 9c520e1dc5
commit 78d4f51314
12 changed files with 78 additions and 13 deletions

View File

@@ -48,6 +48,17 @@ class NaivgatorDemo extends Panel {
navigator(context).pop()
},
} as IText),
label('OpenURL').apply({
width: 200,
height: 50,
backgroundColor: colors[0],
textSize: 30,
textColor: Color.WHITE,
layoutConfig: layoutConfig().just(),
onClick: () => {
navigator(context).openUrl("https://doric.pub")
},
} as IText),
]).apply({
layoutConfig: layoutConfig().most().configHeight(LayoutSpec.FIT),
gravity: gravity().center(),