William Simkins 6 lat temu
rodzic
commit
114dcbda48

+ 1
- 1
src/app/app.scss Wyświetl plik

@@ -17,4 +17,4 @@
17 17
 
18 18
 ion-content {
19 19
   background: url("/assets/imgs/bg.jpg") no-repeat center;background-size:cover;
20
-}
20
+}

+ 6
- 5
src/pages/create-account/create-account.html Wyświetl plik

@@ -12,19 +12,20 @@
12 12
 
13 13
 </ion-header>
14 14
 <ion-content padding="true" class="has-header">
15
+  <div class="createaccount-wrapper">
15 16
     <form id="createAnAccount-form3" class="list">
16 17
       <ion-list id="createAnAccount-list1">
17 18
         <label class="item item-input" id="createAnAccount-input5">
18
-          <input type="text" placeholder="Name">
19
+          <input type="text" placeholder="Name" class="field">
19 20
         </label>
20 21
         <label class="item item-input" id="createAnAccount-input6">
21
-          <input type="email" placeholder="Email">
22
+          <input type="email" placeholder="Email" class="field">
22 23
         </label>
23 24
         <label class="item item-input" id="createAnAccount-input7">
24
-          <input type="text" placeholder="Password">
25
+          <input type="text" placeholder="Password" class="field">
25 26
         </label>
26 27
       </ion-list>
27
-      <button ion-button block id="createAnAccount-button3" a (click)= "motivateMe()">Sign up</button>
28
+      <button ion-button block id="createAnAccount-button3" a (click)= "createAccount()">Sign up</button>
28 29
     </form>
29
-
30
+  </div>
30 31
 </ion-content>

+ 9
- 1
src/pages/create-account/create-account.scss Wyświetl plik

@@ -1,3 +1,11 @@
1 1
 page-create-account {
2
-
2
+    .createaccount-wrapper {
3
+        max-width: 500px;
4
+        margin: auto;
5
+      }
6
+      .field {
7
+        width:100%;
8
+        margin-bottom: 10px;
9
+        padding: 5px;
10
+      }
3 11
 }

+ 7
- 4
src/pages/create-topic/create-topic.html Wyświetl plik

@@ -14,16 +14,19 @@
14 14
 
15 15
 
16 16
 <ion-content padding="true" class="has-header">
17
+  <div class="createtopic-wrapper">
17 18
   <form id="createATopic-form6" class="list">
18 19
     <label class="item item-input" id="createATopic-input9">
19
-      <input type="text" placeholder="Topic Name">
20
+      <input type="text" placeholder="Topic Name" class="field">
20 21
     </label>
21 22
     <div class="spacer" style="width: 300px; height: 35px;"></div>
22 23
     <label class="item item-input" id="createATopic-textarea3" name="Description">
23
-      <span class="input-label"></span><textarea placeholder="Description of Topic"></textarea></label>
24
+      <span class="input-label"></span><textarea placeholder="Description of Topic" class="field"></textarea></label>
24 25
     <div class="spacer" style="width: 300px; height: 38px;"></div>
25 26
     <label class="item item-input" id="createATopic-textarea4" name="Advice and Strategies">
26
-      <span class="input-label"></span><textarea placeholder="Advice and Strategies"></textarea></label>
27
+      <span class="input-label"></span><textarea placeholder="Advice and Strategies" class="field"></textarea></label>
27 28
   </form>
28
-  <a (click)="topics()" id="createATopic-button11" class="button button-calm button-block">Save Topic</a>
29
+  
30
+  <button ion-button block id="createATopic-button11" a (click)="topics()">Save topic</button>
31
+</div>
29 32
 </ion-content>

+ 9
- 1
src/pages/create-topic/create-topic.scss Wyświetl plik

@@ -1,3 +1,11 @@
1 1
 page-create-topic {
2
-
2
+    .createtopic-wrapper {
3
+        max-width: 500px;
4
+        margin: auto;
5
+      }
6
+      .field {
7
+        width:100%;
8
+        margin-bottom: 10px;
9
+        padding: 5px;
10
+      }
3 11
 }

+ 1
- 1
src/pages/create-topic/create-topic.ts Wyświetl plik

@@ -23,7 +23,7 @@ export class CreateTopicPage {
23 23
     console.log('ionViewDidLoad CreateTopicPage');
24 24
   }
25 25
 
26
-  topic(){
26
+  topics(){
27 27
     this.navCtrl.push(TopicPage);
28 28
   }
29 29
 

+ 1
- 2
src/pages/home/home.html Wyświetl plik

@@ -1,6 +1,5 @@
1 1
 <ion-header>
2
-
3
-  <ion-navbar>
2
+  <ion-navbar text-center>
4 3
     <ion-title>MotivateMe</ion-title>
5 4
   </ion-navbar>
6 5
 </ion-header>

+ 0
- 7
src/pages/home/home.scss Wyświetl plik

@@ -9,13 +9,6 @@
9 9
     padding: 5px;
10 10
   }
11 11
   
12
-  // .button {
13
-  //   color: #FFF;
14
-  // }
15
-
16
-  .button-calm{
17
-    background-color: #FFF;
18
-  }
19 12
 }
20 13
 
21 14
 

+ 1
- 1
src/pages/home/home.ts Wyświetl plik

@@ -15,7 +15,7 @@ export class HomePage {
15 15
 
16 16
   }
17 17
 
18
-  // public apiProvider: ApiProvider
18
+//   public apiProvider: ApiProvider
19 19
 
20 20
 //   ngOnInit() {
21 21
 //   this.loadUsers();

+ 9
- 7
src/pages/topic/topic.html Wyświetl plik

@@ -13,16 +13,17 @@
13 13
 </ion-header>
14 14
 
15 15
 <ion-content padding="true" class="has-header">
16
-  <a (click)="createTopic()" class="button ion-button block">Create Topic</a>
16
+  <div class="topic-wrapper">
17 17
 
18
-  <form id="topics-form5" class="list">
18
+  <!-- <form id="topics-form5" class="list">
19 19
     <label class="item item-input" id="topics-search1">
20 20
       <i class="icon ion-search placeholder-icon"></i>
21
-      <input type="search" placeholder="Search for Topic">
21
+      <input type="search" placeholder="Search for Topic" class="field">
22 22
     </label>
23
-  </form>
24
-  <a ui-sref="createATopic()" id="topics-button10" class="button button-positive button-block">Create a New Topic</a>
25
-  <ion-list id="topics-list2">
23
+  </form> -->
24
+
25
+  <button ion-button block id="topics-button10" a (click)="createATopic()">Create a Topic</button>
26
+  <!-- <ion-list id="topics-list2">
26 27
     <ion-item class="item-icon-left" id="topics-list-item1">
27 28
       <i class="icon ion-ios-information"></i>Quitting Smoking</ion-item>
28 29
     <ion-item class="item-icon-left" id="topics-list-item2">
@@ -33,5 +34,6 @@
33 34
       <i class="icon ion-ios-information"></i>Working Out</ion-item>
34 35
     <ion-item class="item-icon-left" id="topics-list-item5">
35 36
       <i class="icon ion-ios-information"></i>Public Speaking</ion-item>
36
-  </ion-list>
37
+  </ion-list> -->
38
+  </div>
37 39
 </ion-content>

+ 9
- 3
src/pages/topic/topic.scss Wyświetl plik

@@ -1,5 +1,11 @@
1 1
 page-topic {
2
-.button-calm{
3
-  background-color: #FFF;
4
-}
2
+  .topic-wrapper {
3
+    max-width: 500px;
4
+    margin: auto;
5
+  }
6
+  .field {
7
+    width:100%;
8
+    margin-bottom: 10px;
9
+    padding: 5px;
10
+  }
5 11
 }

+ 1
- 1
src/pages/topic/topic.ts Wyświetl plik

@@ -23,7 +23,7 @@ export class TopicPage {
23 23
     console.log('ionViewDidLoad TopicPage');
24 24
   }
25 25
 
26
-  createTopic(){
26
+  createATopic(){
27 27
     this.navCtrl.push(CreateTopicPage);
28 28
   }
29 29
 

+ 9
- 0
src/providers/api/api.ts Wyświetl plik

@@ -14,4 +14,13 @@ export class ApiProvider {
14 14
     console.log('Hello ApiProvider Provider');
15 15
   }
16 16
 
17
+  getTopics() {
18
+    this.http.get("http://localhost:8100/topics")
19
+  }
20
+
21
+  getUsers(Userid) {
22
+    this.http.get("http://localhost:8100/users")
23
+  }
24
+
25
+
17 26
 }