From 918aa456dac5556342eb388144e8908d009e8dbe Mon Sep 17 00:00:00 2001 From: Brandy Carney Date: Tue, 12 Apr 2016 12:39:18 -0400 Subject: [PATCH] docs(demos): update loading API demo --- demos/loading/index.ts | 16 ++++++++++++++-- demos/loading/main.html | 18 +++++++++--------- 2 files changed, 23 insertions(+), 11 deletions(-) diff --git a/demos/loading/index.ts b/demos/loading/index.ts index 2cd8d824e2..98d2599435 100644 --- a/demos/loading/index.ts +++ b/demos/loading/index.ts @@ -91,7 +91,19 @@ class E2EPage { } goToPage2() { - this.nav.push(Page2); + let loading = Loading.create({ + content: 'This will navigate to the next page and then dismiss after 3 seconds.' + }); + + this.nav.present(loading); + + setTimeout(() => { + this.nav.push(Page2); + }, 1000); + + setTimeout(() => { + loading.dismiss(); + }, 4000); } } @@ -100,7 +112,7 @@ class E2EPage { Page 2 - Some content + This is another page! ` }) class Page2 { diff --git a/demos/loading/main.html b/demos/loading/main.html index 76aaf2165c..d08da061f7 100644 --- a/demos/loading/main.html +++ b/demos/loading/main.html @@ -9,27 +9,27 @@ @@ -38,10 +38,10 @@ Custom Loading Indicators @@ -50,7 +50,7 @@