diff --git a/app/pages/gallery/gallery.html b/app/pages/gallery/gallery.html
index e3aaac6..0b143bf 100644
--- a/app/pages/gallery/gallery.html
+++ b/app/pages/gallery/gallery.html
@@ -8,11 +8,5 @@
-
-
-
-
-
-
-
+
diff --git a/app/pages/gallery/gallery.ts b/app/pages/gallery/gallery.ts
index f43a05c..6ba865b 100644
--- a/app/pages/gallery/gallery.ts
+++ b/app/pages/gallery/gallery.ts
@@ -6,32 +6,10 @@ import { NavController, NavParams } from 'ionic-angular';
})
export class GalleryPage {
- private images: Array;
- private grid: Array>;
-
- constructor(private _navCtrl: NavController, private _navParams: NavParams) {
- this.images = this._navParams.get('images');
- this.grid = Array(Math.ceil(this.images.length/2));
- }
-
- ionViewLoaded() {
-
- let rowNum = 0;
-
- for (let i = 0; i < this.images.length; i+=2) {
-
- this.grid[rowNum] = Array(2);
+ images: Array;
- if (this.images[i]) {
- this.grid[rowNum][0] = this.images[i]
- }
- if (this.images[i+1]) {
- this.grid[rowNum][1] = this.images[i+1]
- }
-
- rowNum++;
- }
-
+ constructor(public navCtrl: NavController, public navParams: NavParams) {
+ this.images = this.navParams.get('images');
}
}
\ No newline at end of file
diff --git a/app/pages/home/home.scss b/app/pages/home/home.scss
index 000acd5..c780c1e 100644
--- a/app/pages/home/home.scss
+++ b/app/pages/home/home.scss
@@ -1,20 +1,20 @@
.gallery-button {
- top: 50%;
- transform: translateY(-50%);
- position: absolute !important;
- margin:0 auto;
- width:100%;
+ top: 50%;
+ transform: translateY(-50%);
+ position: absolute !important;
+ margin:0 auto;
+ width:100%;
}
-ion-icon[name="images"] {
- border: #FFFFFF 2px solid;
- border-radius: 50%;
- background-color: #2155AA;
- font-size: 35px;
- padding: 15px;
+ion-icon[name="images"] {
+ border: #FFFFFF 2px solid;
+ border-radius: 50%;
+ background-color: #2155AA;
+ font-size: 35px;
+ padding: 15px;
}
-
+
p {
- font-size: 20px;
+ font-size: 20px;
}
diff --git a/app/pages/home/home.ts b/app/pages/home/home.ts
index 99a9b66..125df5e 100644
--- a/app/pages/home/home.ts
+++ b/app/pages/home/home.ts
@@ -9,11 +9,11 @@ import {GalleryPage} from '../gallery/gallery';
export class HomePage {
- constructor(private _navCtrl: NavController) {
+ constructor(public navCtrl: NavController) {
}
- private openGallery (): void {
+ public openGallery (): void {
let options = {
maximumImagesCount: 8,
width: 500,
@@ -22,7 +22,7 @@ export class HomePage {
}
ImagePicker.getPictures(options).then(
- file_uris => this._navCtrl.push(GalleryPage, {images: file_uris}),
+ file_uris => this.navCtrl.push(GalleryPage, {images: file_uris}),
err => console.log('uh oh')
);
}