当前位置: 首页>>代码示例>>TypeScript>>正文


TypeScript Toast.create方法代码示例

本文整理汇总了TypeScript中ionic-angular.Toast.create方法的典型用法代码示例。如果您正苦于以下问题:TypeScript Toast.create方法的具体用法?TypeScript Toast.create怎么用?TypeScript Toast.create使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ionic-angular.Toast的用法示例。


在下文中一共展示了Toast.create方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。

示例1: showToastMsgWithCloseButton

 showToastMsgWithCloseButton(msg) {
     const toast = Toast.create({
         message: msg,
         showCloseButton: true,
         closeButtonText: 'Ok'
     });
     return toast;
 }
开发者ID:RashmiNalwad,项目名称:Teach2Ed,代码行数:8,代码来源:lib.ts

示例2:

 self.loading.dismiss().then(function(){
     self.toast = Toast.create({
         message: "Create product failed!",
         duration: 1000,
         position: 'bottom'
     });
     self.nav.present(self.toast);
 });
开发者ID:khavq,项目名称:ion2-bangbang,代码行数:8,代码来源:photo-detail.ts

示例3: bottomPosition

    bottomPosition(){
        let toast = Toast.create({
            message:'take me to the temple you shall',
            duration:2000,
            position:'bottom'
        });

        this.nav.present(toast);
    }
开发者ID:ralphowino,项目名称:ionic-native-kitchen-sink,代码行数:9,代码来源:toast.ts

示例4:

 .then(() => {
   let successToast = Toast.create({
     message: 'Inventory cleared successfully',
     cssClass: 'fzToast-success',
     duration: 1000
   });
   this._nav.present(successToast);
   this._events.publish('fzInventoryUpdated', null);
 })  
开发者ID:scunningham777,项目名称:Fantazaar,代码行数:9,代码来源:settings-page.ts

示例5: closeToast

    closeToast(){
        let toast = Toast.create({
            message:'Will you join the Sith?',
            showCloseButton: true,
            closeButtonText: 'Ok'
        });

        this.nav.present(toast);
    }
开发者ID:ralphowino,项目名称:ionic-native-kitchen-sink,代码行数:9,代码来源:toast.ts

示例6: checkWeb

 checkWeb(nav: Nav) {
   if (Network.connection == 'none') {
     let toast = Toast.create({
       message: 'No connection.',
       //duration: 10000,
     });
     nav.present(toast);
   } 
 }
开发者ID:faithandrel,项目名称:geo-sched-mobile,代码行数:9,代码来源:schd-error-handler.ts

示例7: presentPriceAlerts

 presentPriceAlerts() {
   let toastMessage = this.priceAlertMessages.join(' -- ');
   let toast = Toast.create({
     message: toastMessage,
     showCloseButton: true,
     closeButtonText: 'Ok'
   });
   this.nav.present(toast);
 }
开发者ID:pmaclellan,项目名称:ChemCaravan,代码行数:9,代码来源:settlement-page.ts

示例8: addCart

  // add to card
  addCart(item) {
    let toast = Toast.create({
      message: 'Item added to card',
      duration: 500,
      position: 'middle'
    });

    this.nav.present(toast);
  }
开发者ID:abethcrane,项目名称:Rogo,代码行数:10,代码来源:modal-item-option.ts

示例9: showSchdError

  showSchdError(theError: any, nav: Nav) {
    let toast = Toast.create({
      message: JSON.stringify(theError),
      duration: 3000,
    });
    
    nav.present(toast);

  }
开发者ID:faithandrel,项目名称:geo-sched-mobile,代码行数:9,代码来源:schd-error-handler.ts

示例10: middlePosition

    middlePosition(){
        let toast = Toast.create({
            message:'Execute Order 66',
            duration:2000,
            position:'middle'
        });

        this.nav.present(toast);
    }
开发者ID:ralphowino,项目名称:ionic-native-kitchen-sink,代码行数:9,代码来源:toast.ts


注:本文中的ionic-angular.Toast.create方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。