Skip to content

Instantly share code, notes, and snippets.

@pranaypatel512
Created October 29, 2022 11:15
Show Gist options
  • Select an option

  • Save pranaypatel512/3e5d17934b71cc0c54d504e7281849f1 to your computer and use it in GitHub Desktop.

Select an option

Save pranaypatel512/3e5d17934b71cc0c54d504e7281849f1 to your computer and use it in GitHub Desktop.

Revisions

  1. pranaypatel512 created this gist Oct 29, 2022.
    15 changes: 15 additions & 0 deletions WelcomeScreenPreview
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,15 @@
    @Preview(showSystemUi = true, device = "spec:width=411dp,height=891dp")
    @Preview(uiMode = Configuration.UI_MODE_NIGHT_YES)
    // @Preview(showSystemUi = true, device = "spec:width=673.5dp,height=841dp,dpi=480")
    // @Preview(showSystemUi = true, device = "spec:width=1280dp,height=800dp,dpi=480")
    // @Preview(showSystemUi = true, device = "spec:width=1920dp,height=1080dp,dpi=480")
    @Composable
    fun WelcomeScreenPreview() {
    MyAppTheme() {
    Surface() {
    WelcomeScreen()
    }
    }
    }

    // User multiple preview annotation with different device spec to see preview in different devices