text: var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
      var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
      if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
      else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
      return c > 3 && r && Object.defineProperty(target, key, r), r;
  };
  var __metadata = (this && this.__metadata) || function (k, v) {
      if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
  };
  import { Component } from '@angular/core';
  import { ActionSheetController, Config, NavController } from 'ionic-angular';
  import { InAppBrowser } from '@ionic-native/in-app-browser';
  import { ConferenceData } from '../../providers/conference-data';
  import { SessionDetailPage } from '../session-detail/session-detail';
  import { SpeakerDetailPage } from '../speaker-detail/speaker-detail';
  ;
  var SpeakerListPage = (function () {
      function SpeakerListPage(actionSheetCtrl, navCtrl, confData, config, inAppBrowser) {
          this.actionSheetCtrl = actionSheetCtrl;
          this.navCtrl = navCtrl;
          this.confData = confData;
          this.config = config;
          this.inAppBrowser = inAppBrowser;
          this.speakers = [];
      }
      SpeakerListPage.prototype.ionViewDidLoad = function () {
          var _this = this;
          this.confData.getSpeakers().subscribe(function (speakers) {
              _this.speakers = speakers;
          });
      };
      SpeakerListPage.prototype.goToSessionDetail = function (session) {
          this.navCtrl.push(SessionDetailPage, { sessionId: session.id });
      };
      SpeakerListPage.prototype.goToSpeakerDetail = function (speaker) {
          this.navCtrl.push(SpeakerDetailPage, { speakerId: speaker.id });
      };
      SpeakerListPage.prototype.goToSpeakerTwitter = function (speaker) {
          this.inAppBrowser.create("https://twitter.com/" + speaker.twitter, '_blank');
      };
      SpeakerListPage.prototype.openSpeakerShare = function (speaker) {
          var actionSheet = this.actionSheetCtrl.create({
              title: 'Share ' + speaker.name,
              buttons: [
                  {
                      text: 'Copy Link',
                      handler: function () {
                          console.log('Copy link clicked on https://twitter.com/' + speaker.twitter);
                          if (window['cordova'] && window['cordova'].plugins.clipboard) {
                              window['cordova'].plugins.clipboard.copy('https://twitter.com/' + speaker.twitter);
                          }
                      }
                  },
                  {
                      text: 'Share via ...'
                  },
                  {
                      text: 'Cancel',
                      role: 'cancel'
                  }
              ]
          });
          actionSheet.present();
      };
      SpeakerListPage.prototype.openContact = function (speaker) {
          var mode = this.config.get('mode');
          var actionSheet = this.actionSheetCtrl.create({
              title: 'Contact ' + speaker.name,
              buttons: [
                  {
                      text: "Email ( " + speaker.email + " )",
                      icon: mode !== 'ios' ? 'mail' : null,
                      handler: function () {
                          window.open('mailto:' + speaker.email);
                      }
                  },
                  {
                      text: "Call ( " + speaker.phone + " )",
                      icon: mode !== 'ios' ? 'call' : null,
                      handler: function () {
                          window.open('tel:' + speaker.phone);
                      }
                  }
              ]
          });
          actionSheet.present();
      };
      SpeakerListPage.prototype.open = function (url) {
          var options = {};
          this.inAppBrowser.create(url, '_self', options);
      };
      SpeakerListPage = __decorate([
          Component({
              selector: 'page-speaker-list',template:/*ion-inline-start:"/home/damien/source/ionic/Team-VTT-Maisse/src/pages/speaker-list/speaker-list.html"*/'<ion-header>\n  <ion-navbar>\n    <button ion-button menuToggle>\n      <ion-icon name="menu"></ion-icon>\n    </button>\n    <ion-title>Licenciés</ion-title>\n  </ion-navbar>\n</ion-header>\n\n<ion-content class="outer-content speaker-list">\n  <ion-list [virtualScroll]="speakers">\n    <ion-grid fixed>\n      <ion-row align-items-stretch>\n\n        <ion-col col-12 col-md-6 align-self-stretch align-self-center *virtualItem="let speaker" approxItemHeight="457px">\n\n          <ion-card class="speaker-card">\n            <ion-card-header>\n              <button ion-item detail-none (click)="goToSpeakerDetail(speaker)">\n                <ion-avatar item-start>\n                  <img [src]="speaker.profilePic" alt="Speaker profile pic"/>\n                </ion-avatar>\n                {{speaker.name}}\n              </button>\n            </ion-card-header>\n\n            <ion-card-content class="outer-content">\n              <ion-list>\n                <button ion-item *ngFor="let session of speaker.sessions" (click)="goToSessionDetail(session)">\n                  <h3>{{session.name}}</h3>\n                </button>\n\n               <!-- <button ion-item (click)="goToSpeakerDetail(speaker)">\n                  <h3>About {{speaker.name}}</h3>\n                </button>-->\n              </ion-list>\n            </ion-card-content>\n\n            <ion-row no-padding>\n              <!--<ion-col col-12 col-lg-auto text-center text-lg-left>\n                <button ion-button clear small color="primary" icon-start (click)="goToSpeakerTwitter(speaker)">\n                  <ion-icon name="logo-twitter"></ion-icon>\n                  Tweet\n                </button>\n              </ion-col>\n              <ion-col col-12 col-lg-auto text-center>\n                <button ion-button clear small color="primary" icon-start (click)="openSpeakerShare(speaker)">\n                  <ion-icon name=\'share-alt\'></ion-icon>\n                  Share\n                </button>\n              </ion-col>-->\n              <ion-col col-12 col-lg-auto text-center text-lg-right>\n                <button ion-button clear big color="primary" icon-start (click)="openContact(speaker)">\n                  <ion-icon name=\'chatboxes\'></ion-icon>\n                  Contacter\n                </button>\n              </ion-col>\n            </ion-row>\n\n          </ion-card>\n\n        </ion-col>\n      </ion-row>\n    </ion-grid>\n  </ion-list>\n\n  <ion-fab bottom right #fab4>\n    <button ion-fab><ion-icon name="arrow-dropup"></ion-icon></button>\n    <ion-fab-list side="top">\n      <button ion-fab color="google" (click)="open(\'http://www.teamvttmaisse.org/forum/portal.php\')"><ion-icon name="bicycle"></ion-icon></button>\n      <button ion-fab color="facebook" (click)="open(\'https://www.facebook.com/teamvttmaisse/\')"><ion-icon name="logo-facebook"></ion-icon></button>\n    </ion-fab-list>\n  </ion-fab>\n\n</ion-content>\n\n\n'/*ion-inline-end:"/home/damien/source/ionic/Team-VTT-Maisse/src/pages/speaker-list/speaker-list.html"*/
          }),
          __metadata("design:paramtypes", [ActionSheetController,
              NavController,
              ConferenceData,
              Config,
              InAppBrowser])
      ], SpeakerListPage);
      return SpeakerListPage;
  }());
  export { SpeakerListPage };
  //# sourceMappingURL=speaker-list.js.map