golf 3 anni fa
parent
commit
c08efd8ac8

+ 5 - 5
src/app/navtabs/navtabs.page.html

6
 <ion-tabs>
6
 <ion-tabs>
7
   <ion-tab-bar slot="bottom">
7
   <ion-tab-bar slot="bottom">
8
     <ion-tab-button tab="home" layout="icon-top">
8
     <ion-tab-button tab="home" layout="icon-top">
9
-      <ion-icon name="globe"></ion-icon>
9
+      <ion-icon name="globe" ></ion-icon>
10
       <!-- <ion-label>Home</ion-label> -->
10
       <!-- <ion-label>Home</ion-label> -->
11
     </ion-tab-button>
11
     </ion-tab-button>
12
     <ion-tab-button tab="news" layout="icon-top">
12
     <ion-tab-button tab="news" layout="icon-top">
13
-      <ion-icon name="football"></ion-icon>
13
+      <ion-icon name="football" ></ion-icon>
14
       <!-- <ion-label>News</ion-label> -->
14
       <!-- <ion-label>News</ion-label> -->
15
     </ion-tab-button>
15
     </ion-tab-button>
16
     <ion-tab-button tab="#" layout="icon-top">
16
     <ion-tab-button tab="#" layout="icon-top">
17
-      <ion-icon name="play-circle" size="large"></ion-icon>
17
+      <ion-icon name="play-circle" class="icon-big"></ion-icon>
18
       <!-- <ion-label>Audio</ion-label> -->
18
       <!-- <ion-label>Audio</ion-label> -->
19
     </ion-tab-button>
19
     </ion-tab-button>
20
     <ion-tab-button tab="youtube" layout="icon-top">
20
     <ion-tab-button tab="youtube" layout="icon-top">
21
-      <ion-icon name="logo-youtube"></ion-icon>
21
+      <ion-icon name="logo-youtube" ></ion-icon>
22
       <!-- <ion-label>Youtube</ion-label> -->
22
       <!-- <ion-label>Youtube</ion-label> -->
23
     </ion-tab-button>
23
     </ion-tab-button>
24
     <ion-tab-button tab="#" layout="icon-top">
24
     <ion-tab-button tab="#" layout="icon-top">
25
-      <ion-icon name="videocam"></ion-icon>
25
+      <ion-icon name="videocam" ></ion-icon>
26
       <!-- <ion-label>Video</ion-label> -->
26
       <!-- <ion-label>Video</ion-label> -->
27
     </ion-tab-button>
27
     </ion-tab-button>
28
   </ion-tab-bar>
28
   </ion-tab-bar>

+ 39 - 30
src/app/navtabs/navtabs.page.scss

8
 //     position: unset!important;
8
 //     position: unset!important;
9
 //     contain: size style!important;
9
 //     contain: size style!important;
10
 //   }
10
 //   }
11
-  
11
+
12
 //   .bottom-tab-bar {
12
 //   .bottom-tab-bar {
13
 //     --background: transparent;
13
 //     --background: transparent;
14
 //     --border: 0;
14
 //     --border: 0;
15
 //   }
15
 //   }
16
-  
16
+
17
 //   ion-tab-button {
17
 //   ion-tab-button {
18
 //     --background: #134d80;
18
 //     --background: #134d80;
19
 //     --color:white;
19
 //     --color:white;
20
 //     --color-selected: red;
20
 //     --color-selected: red;
21
 //     --ripple-color: white;
21
 //     --ripple-color: white;
22
 //   }
22
 //   }
23
-  
23
+
24
 
24
 
25
 // .button-center {
25
 // .button-center {
26
 //     --background: transparent!important;
26
 //     --background: transparent!important;
40
 //       content: '';
40
 //       content: '';
41
 //     }
41
 //     }
42
 //   }
42
 //   }
43
-  
43
+
44
 // .inner-left-btn {
44
 // .inner-left-btn {
45
 //     border-radius: 0 50% 0 0; 
45
 //     border-radius: 0 50% 0 0; 
46
 //     //create the curved style on the left side of the center
46
 //     //create the curved style on the left side of the center
51
 //     border-radius: 50% 0 0 0; 
51
 //     border-radius: 50% 0 0 0; 
52
 //     // create the curved style on the right side of the center
52
 //     // create the curved style on the right side of the center
53
 // }
53
 // }
54
-  
54
+
55
 // .inner-center-btn {
55
 // .inner-center-btn {
56
 //     position: absolute;
56
 //     position: absolute;
57
 //     left: calc(50% - 35px); // position your button in the center
57
 //     left: calc(50% - 35px); // position your button in the center
103
 //     border-radius: 16px;
103
 //     border-radius: 16px;
104
 //     width: 92%;
104
 //     width: 92%;
105
 //     margin: 0 auto;
105
 //     margin: 0 auto;
106
-    
106
+
107
 //   }
107
 //   }
108
 
108
 
109
-  ion-tab-button {
110
-    --color: var(--ion-color-medium);
111
-    --color-selected: var(--ion-color-primary);
112
-    --background-focused:#ff600d;
113
-    --background-focused-opacity:0.5;
114
-  
115
-    &::before {
116
-      background-color: transparent;
117
-      display: block;
118
-      content: "";
119
-      margin: 0 auto;
120
-      width: 20px;
121
-      height: 2px;
122
-    }
123
-  
124
-    &.tab-selected::before {
125
-      background-color: var(--ion-color-primary);
126
-    }
127
-  } 
128
-
129
-  // ion-tab-button.tab-selected {
130
-  //   --background: var(--ion-color-dark) !important;
131
-  //   --color-selected: var(--ion-color-light);
132
-  // }
109
+ion-tab-button {
110
+  --color: var(--ion-color-medium);
111
+  --color-selected: var(--ion-color-primary);
112
+  --background-focused: #ff600d;
113
+  --background-focused-opacity: 0.5;
114
+
115
+  &::before {
116
+    background-color: transparent;
117
+    display: block;
118
+    content: "";
119
+    margin: 0 auto;
120
+    width: 20px;
121
+    height: 2px;
122
+  }
123
+
124
+  &.tab-selected::before {
125
+    background-color: var(--ion-color-primary);
126
+  }
127
+}
128
+
129
+.icon-big {
130
+  font-size: 90px;
131
+  display: block;
132
+  color: rgb(255, 106, 0);
133
+  // margin-bottom: 10px;
134
+}
135
+
136
+
137
+
138
+// ion-tab-button.tab-selected {
139
+//   --background: var(--ion-color-dark) !important;
140
+//   --color-selected: var(--ion-color-light);
141
+// }

+ 4 - 1
src/app/news-detail/news-detail.page.html

18
   </ion-grid>
18
   </ion-grid>
19
   <div *ngIf="data">
19
   <div *ngIf="data">
20
     <img [src]="data.better_featured_image.source_url" [style.width]="'100%'" />
20
     <img [src]="data.better_featured_image.source_url" [style.width]="'100%'" />
21
-    <ion-grid >
21
+    <ion-grid>
22
       <ion-row>
22
       <ion-row>
23
         <ion-col class="bg-color-1">
23
         <ion-col class="bg-color-1">
24
           <h2 [innerHTML]="data?.title.rendered" class="title-txt-1"></h2>
24
           <h2 [innerHTML]="data?.title.rendered" class="title-txt-1"></h2>
25
           <div [innerHTML]="data.content.rendered" class="content-txt-1"></div>
25
           <div [innerHTML]="data.content.rendered" class="content-txt-1"></div>
26
+          <div *ngIf="data.acf.youtube_url_for_app" class="">
27
+            <a href="{{data.acf.youtube_url_for_app}}" targrt="_blank">รับชมคลิปผ่าน youtube</a>
28
+          </div>
26
         </ion-col>
29
         </ion-col>
27
       </ion-row>
30
       </ion-row>
28
     </ion-grid>
31
     </ion-grid>

+ 2 - 2
src/app/services/wpdata.service.ts

30
 
30
 
31
   getAllYoutube() {
31
   getAllYoutube() {
32
     return this.http.get(
32
     return this.http.get(
33
-      // "../assets/api/youtube-data.json"
34
-      "https://youtube.googleapis.com/youtube/v3/search?part=snippet&channelId=UCfZdHbI3pIN4uselPFzzbOg&maxResults=5&order=date&key=AIzaSyDsRrS_dUxT_3PFaMZIBBdrbl37p_fqrNY"
33
+       "../assets/api/youtube-data.json"
34
+     // "https://youtube.googleapis.com/youtube/v3/search?part=snippet&channelId=UCfZdHbI3pIN4uselPFzzbOg&maxResults=5&order=date&key=AIzaSyDsRrS_dUxT_3PFaMZIBBdrbl37p_fqrNY"
35
     );
35
     );
36
   }
36
   }
37
 }
37
 }