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


TypeScript i18n-polyfill.I18n类代码示例

本文整理汇总了TypeScript中@ngx-translate/i18n-polyfill.I18n的典型用法代码示例。如果您正苦于以下问题:TypeScript I18n类的具体用法?TypeScript I18n怎么用?TypeScript I18n使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: constructor

 constructor(_authService: AuthenticationService,
             _navigation: NavigationService,
             _settingsService: RandomPhotoSettingsService,
             notification: NotificationService,
             i18n: I18n) {
   super(i18n('Random Media'), _authService, _navigation, _settingsService, notification, i18n, s => s.Client.RandomPhoto);
 }
开发者ID:bpatrik,项目名称:PiGallery2,代码行数:7,代码来源:random-photo.settings.component.ts

示例2: constructor

 constructor(_authService: AuthenticationService,
             _navigation: NavigationService,
             _settingsService: ShareSettingsService,
             notification: NotificationService,
             i18n: I18n) {
   super(i18n('Share'), _authService, _navigation, _settingsService, notification, i18n, s => s.Client.Sharing);
 }
开发者ID:bpatrik,项目名称:PiGallery2,代码行数:7,代码来源:share.settings.component.ts

示例3: constructor

  constructor (private i18n: I18n) {
    this.VIDEO_CHANNEL_DISPLAY_NAME = {
      VALIDATORS: [
        Validators.required,
        Validators.minLength(3),
        Validators.maxLength(120)
      ],
      MESSAGES: {
        'required': i18n('Display name is required.'),
        'minlength': i18n('Display name must be at least 3 characters long.'),
        'maxlength': i18n('Display name cannot be more than 120 characters long.')
      }
    }

    this.VIDEO_CHANNEL_DESCRIPTION = {
      VALIDATORS: [
        Validators.minLength(3),
        Validators.maxLength(500)
      ],
      MESSAGES: {
        'minlength': i18n('Description must be at least 3 characters long.'),
        'maxlength': i18n('Description cannot be more than 500 characters long.')
      }
    }

    this.VIDEO_CHANNEL_SUPPORT = {
      VALIDATORS: [
        Validators.minLength(3),
        Validators.maxLength(500)
      ],
      MESSAGES: {
        'minlength': i18n('Support text must be at least 3 characters long.'),
        'maxlength': i18n('Support text cannot be more than 500 characters long.')
      }
    }
  }
开发者ID:jiang263,项目名称:PeerTube,代码行数:36,代码来源:video-channel-validators.service.ts


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