@skyux/avatar
Advanced tools
Comparing version 5.5.0 to 5.6.0
(function (global, factory) { | ||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common'), require('@skyux/errors'), require('@skyux/forms'), require('@skyux/i18n'), require('@skyux/theme')) : | ||
typeof define === 'function' && define.amd ? define('@skyux/avatar', ['exports', '@angular/core', '@angular/common', '@skyux/errors', '@skyux/forms', '@skyux/i18n', '@skyux/theme'], factory) : | ||
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.skyux = global.skyux || {}, global.skyux.avatar = {}), global.ng.core, global.ng.common, global.i1, global.i2$1, global.i3$1, global.i3)); | ||
})(this, (function (exports, i0, i2, i1, i2$1, i3$1, i3) { 'use strict'; | ||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/common'), require('@angular/core'), require('@skyux/errors'), require('@skyux/forms'), require('@skyux/i18n'), require('@skyux/theme')) : | ||
typeof define === 'function' && define.amd ? define('@skyux/avatar', ['exports', '@angular/common', '@angular/core', '@skyux/errors', '@skyux/forms', '@skyux/i18n', '@skyux/theme'], factory) : | ||
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.skyux = global.skyux || {}, global.skyux.avatar = {}), global.ng.common, global.ng.core, global.i1, global.i2$1, global.i3, global.i3$1)); | ||
})(this, (function (exports, i2, i0, i1, i2$1, i3, i3$1) { 'use strict'; | ||
@@ -25,9 +25,74 @@ function _interopNamespace(e) { | ||
var i2__namespace = /*#__PURE__*/_interopNamespace(i2); | ||
var i0__namespace = /*#__PURE__*/_interopNamespace(i0); | ||
var i2__namespace = /*#__PURE__*/_interopNamespace(i2); | ||
var i1__namespace = /*#__PURE__*/_interopNamespace(i1); | ||
var i2__namespace$1 = /*#__PURE__*/_interopNamespace(i2$1); | ||
var i3__namespace$1 = /*#__PURE__*/_interopNamespace(i3$1); | ||
var i3__namespace = /*#__PURE__*/_interopNamespace(i3); | ||
var i3__namespace$1 = /*#__PURE__*/_interopNamespace(i3); | ||
var i3__namespace = /*#__PURE__*/_interopNamespace(i3$1); | ||
/** | ||
* NOTICE: DO NOT MODIFY THIS FILE! | ||
* The contents of this file were automatically generated by | ||
* the 'ng generate @skyux/i18n:lib-resources-module modules/shared/sky-avatar' schematic. | ||
* To update this file, simply rerun the command. | ||
*/ | ||
var RESOURCES = { | ||
'EN-US': { | ||
skyux_avatar_error_not_image_description: { | ||
message: 'Please choose a file that is a valid image.', | ||
}, | ||
skyux_avatar_error_not_image_title: { message: 'File is not an image.' }, | ||
skyux_avatar_error_too_large_description: { | ||
message: 'Please choose an image that is less than {0}.', | ||
}, | ||
skyux_avatar_error_too_large_title: { message: 'File is too large.' }, | ||
skyux_avatar_errormodal_ok: { message: 'OK' }, | ||
skyux_avatar_inner_description: { message: 'Profile picture of {0}' }, | ||
skyux_avatar_upload_change_aria_label: { | ||
message: 'Change profile photo of {0}. Drag a file here or click to browse.', | ||
}, | ||
skyux_avatar_upload_new_aria_label: { | ||
message: 'Add profile photo of {0}. Drag a file here or click to browse.', | ||
}, | ||
}, | ||
}; | ||
var SkyAvatarResourcesProvider = /** @class */ (function () { | ||
function SkyAvatarResourcesProvider() { | ||
} | ||
SkyAvatarResourcesProvider.prototype.getString = function (localeInfo, name) { | ||
return i3.getLibStringForLocale(RESOURCES, localeInfo.locale, name); | ||
}; | ||
return SkyAvatarResourcesProvider; | ||
}()); | ||
/** | ||
* Import into any component library module that needs to use resource strings. | ||
*/ | ||
var SkyAvatarResourcesModule = /** @class */ (function () { | ||
function SkyAvatarResourcesModule() { | ||
} | ||
return SkyAvatarResourcesModule; | ||
}()); | ||
SkyAvatarResourcesModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarResourcesModule, deps: [], target: i0__namespace.ɵɵFactoryTarget.NgModule }); | ||
SkyAvatarResourcesModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarResourcesModule, exports: [i3.SkyI18nModule] }); | ||
SkyAvatarResourcesModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarResourcesModule, providers: [ | ||
{ | ||
provide: i3.SKY_LIB_RESOURCES_PROVIDERS, | ||
useClass: SkyAvatarResourcesProvider, | ||
multi: true, | ||
}, | ||
], imports: [i3.SkyI18nModule] }); | ||
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarResourcesModule, decorators: [{ | ||
type: i0.NgModule, | ||
args: [{ | ||
exports: [i3.SkyI18nModule], | ||
providers: [ | ||
{ | ||
provide: i3.SKY_LIB_RESOURCES_PROVIDERS, | ||
useClass: SkyAvatarResourcesProvider, | ||
multi: true, | ||
}, | ||
], | ||
}] | ||
}] }); | ||
/*! ***************************************************************************** | ||
@@ -639,67 +704,2 @@ Copyright (c) Microsoft Corporation. | ||
/** | ||
* NOTICE: DO NOT MODIFY THIS FILE! | ||
* The contents of this file were automatically generated by | ||
* the 'ng generate @skyux/i18n:lib-resources-module modules/shared/sky-avatar' schematic. | ||
* To update this file, simply rerun the command. | ||
*/ | ||
var RESOURCES = { | ||
'EN-US': { | ||
skyux_avatar_error_not_image_description: { | ||
message: 'Please choose a file that is a valid image.', | ||
}, | ||
skyux_avatar_error_not_image_title: { message: 'File is not an image.' }, | ||
skyux_avatar_error_too_large_description: { | ||
message: 'Please choose an image that is less than {0}.', | ||
}, | ||
skyux_avatar_error_too_large_title: { message: 'File is too large.' }, | ||
skyux_avatar_errormodal_ok: { message: 'OK' }, | ||
skyux_avatar_inner_description: { message: 'Profile picture of {0}' }, | ||
skyux_avatar_upload_change_aria_label: { | ||
message: 'Change profile photo of {0}. Drag a file here or click to browse.', | ||
}, | ||
skyux_avatar_upload_new_aria_label: { | ||
message: 'Add profile photo of {0}. Drag a file here or click to browse.', | ||
}, | ||
}, | ||
}; | ||
var SkyAvatarResourcesProvider = /** @class */ (function () { | ||
function SkyAvatarResourcesProvider() { | ||
} | ||
SkyAvatarResourcesProvider.prototype.getString = function (localeInfo, name) { | ||
return i3$1.getLibStringForLocale(RESOURCES, localeInfo.locale, name); | ||
}; | ||
return SkyAvatarResourcesProvider; | ||
}()); | ||
/** | ||
* Import into any component library module that needs to use resource strings. | ||
*/ | ||
var SkyAvatarResourcesModule = /** @class */ (function () { | ||
function SkyAvatarResourcesModule() { | ||
} | ||
return SkyAvatarResourcesModule; | ||
}()); | ||
SkyAvatarResourcesModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarResourcesModule, deps: [], target: i0__namespace.ɵɵFactoryTarget.NgModule }); | ||
SkyAvatarResourcesModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarResourcesModule, exports: [i3$1.SkyI18nModule] }); | ||
SkyAvatarResourcesModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarResourcesModule, providers: [ | ||
{ | ||
provide: i3$1.SKY_LIB_RESOURCES_PROVIDERS, | ||
useClass: SkyAvatarResourcesProvider, | ||
multi: true, | ||
}, | ||
], imports: [i3$1.SkyI18nModule] }); | ||
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarResourcesModule, decorators: [{ | ||
type: i0.NgModule, | ||
args: [{ | ||
exports: [i3$1.SkyI18nModule], | ||
providers: [ | ||
{ | ||
provide: i3$1.SKY_LIB_RESOURCES_PROVIDERS, | ||
useClass: SkyAvatarResourcesProvider, | ||
multi: true, | ||
}, | ||
], | ||
}] | ||
}] }); | ||
var SkyAvatarModule = /** @class */ (function () { | ||
@@ -715,4 +715,4 @@ function SkyAvatarModule() { | ||
i2$1.SkyFileAttachmentsModule, | ||
i3$1.SkyI18nModule, | ||
i3.SkyThemeModule], exports: [SkyAvatarComponent] }); | ||
i3.SkyI18nModule, | ||
i3$1.SkyThemeModule], exports: [SkyAvatarComponent] }); | ||
SkyAvatarModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarModule, providers: [i2$1.SkyFileSizePipe], imports: [[ | ||
@@ -723,4 +723,4 @@ i2.CommonModule, | ||
i2$1.SkyFileAttachmentsModule, | ||
i3$1.SkyI18nModule, | ||
i3.SkyThemeModule, | ||
i3.SkyI18nModule, | ||
i3$1.SkyThemeModule, | ||
]] }); | ||
@@ -736,4 +736,4 @@ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyAvatarModule, decorators: [{ | ||
i2$1.SkyFileAttachmentsModule, | ||
i3$1.SkyI18nModule, | ||
i3.SkyThemeModule, | ||
i3.SkyI18nModule, | ||
i3$1.SkyThemeModule, | ||
], | ||
@@ -740,0 +740,0 @@ providers: [i2$1.SkyFileSizePipe], |
@@ -71,3 +71,3 @@ { | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.module.ts", | ||
"line": 31, | ||
"line": 26, | ||
"character": 13 | ||
@@ -107,3 +107,3 @@ } | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.component.ts", | ||
"line": 98, | ||
"line": 94, | ||
"character": 2 | ||
@@ -188,3 +188,3 @@ } | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.component.ts", | ||
"line": 90, | ||
"line": 86, | ||
"character": 9 | ||
@@ -233,3 +233,3 @@ } | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.component.ts", | ||
"line": 76, | ||
"line": 72, | ||
"character": 9 | ||
@@ -276,3 +276,3 @@ } | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.component.ts", | ||
"line": 84, | ||
"line": 80, | ||
"character": 9 | ||
@@ -311,3 +311,3 @@ } | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.component.ts", | ||
"line": 34, | ||
"line": 30, | ||
"character": 13 | ||
@@ -397,3 +397,3 @@ } | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.component.ts", | ||
"line": 51, | ||
"line": 47, | ||
"character": 13 | ||
@@ -471,3 +471,3 @@ } | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.component.ts", | ||
"line": 64, | ||
"line": 60, | ||
"character": 13 | ||
@@ -535,3 +535,3 @@ } | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.component.ts", | ||
"line": 104, | ||
"line": 100, | ||
"character": 9 | ||
@@ -605,3 +605,3 @@ } | ||
"fileName": "projects/avatar/src/modules/avatar/avatar.component.ts", | ||
"line": 25, | ||
"line": 21, | ||
"character": 13 | ||
@@ -713,3 +713,3 @@ } | ||
"filePath": "/projects/avatar/documentation/code-examples/avatar/avatar-demo.component.ts", | ||
"rawContents": "import { Component } from '@angular/core';\n\nimport { SkyFileItem } from '@skyux/forms';\n\n@Component({\n selector: 'app-avatar-demo',\n templateUrl: './avatar-demo.component.html',\n})\nexport class AvatarDemoComponent {\n public avatarUrl: string | File = 'https://imgur.com/tBiGElW.png';\n\n public name = 'Robert C. Hernandez';\n\n public updateSrc(fileItem: SkyFileItem): void {\n /*\n This is where you might upload the new avatar,\n but for this demo we'll just update it locally.\n */\n if (fileItem) {\n this.avatarUrl = fileItem.file;\n }\n }\n}\n" | ||
"rawContents": "import { Component } from '@angular/core';\nimport { SkyFileItem } from '@skyux/forms';\n\n@Component({\n selector: 'app-avatar-demo',\n templateUrl: './avatar-demo.component.html',\n})\nexport class AvatarDemoComponent {\n public avatarUrl: string | File = 'https://imgur.com/tBiGElW.png';\n\n public name = 'Robert C. Hernandez';\n\n public updateSrc(fileItem: SkyFileItem): void {\n /*\n This is where you might upload the new avatar,\n but for this demo we'll just update it locally.\n */\n if (fileItem) {\n this.avatarUrl = fileItem.file;\n }\n }\n}\n" | ||
}, | ||
@@ -719,5 +719,5 @@ { | ||
"filePath": "/projects/avatar/documentation/code-examples/avatar/avatar-demo.module.ts", | ||
"rawContents": "import { NgModule } from '@angular/core';\n\nimport { SkyAvatarModule } from '@skyux/avatar';\n\nimport { AvatarDemoComponent } from './avatar-demo.component';\n\n@NgModule({\n declarations: [AvatarDemoComponent],\n imports: [SkyAvatarModule],\n exports: [AvatarDemoComponent],\n})\nexport class AvatarDemoModule {}\n" | ||
"rawContents": "import { NgModule } from '@angular/core';\nimport { SkyAvatarModule } from '@skyux/avatar';\n\nimport { AvatarDemoComponent } from './avatar-demo.component';\n\n@NgModule({\n declarations: [AvatarDemoComponent],\n imports: [SkyAvatarModule],\n exports: [AvatarDemoComponent],\n})\nexport class AvatarDemoModule {}\n" | ||
} | ||
] | ||
} |
@@ -9,6 +9,6 @@ import { Injectable } from '@angular/core'; | ||
this.revokeBlobUrl(); | ||
let el = elementRef.nativeElement; | ||
const el = elementRef.nativeElement; | ||
/*istanbul ignore else */ | ||
if (el) { | ||
let imageEl = el.querySelector('.sky-avatar-image'); | ||
const imageEl = el.querySelector('.sky-avatar-image'); | ||
/*istanbul ignore else */ | ||
@@ -34,3 +34,3 @@ if (imageEl) { | ||
createBlobUrl(src) { | ||
let url = URL.createObjectURL(src); | ||
const url = URL.createObjectURL(src); | ||
// Keep the last blob URL around so we can revoke it later. | ||
@@ -37,0 +37,0 @@ // https://developer.mozilla.org/en-US/docs/Web/API/URL/revokeObjectURL |
@@ -32,3 +32,3 @@ import { Component, ElementRef, Input, ViewEncapsulation, } from '@angular/core'; | ||
if (this.name) { | ||
let nameSplit = this.name.split(' '); | ||
const nameSplit = this.name.split(' '); | ||
initials = getInitial(nameSplit[0]); | ||
@@ -42,3 +42,3 @@ if (nameSplit.length > 1) { | ||
get colorIndex() { | ||
let name = this.name; | ||
const name = this.name; | ||
let colorIndex; | ||
@@ -48,3 +48,3 @@ if (name) { | ||
// so that a given name will always generate the same color. | ||
let seed = name.charCodeAt(0) + name.charCodeAt(name.length - 1) + name.length; | ||
const seed = name.charCodeAt(0) + name.charCodeAt(name.length - 1) + name.length; | ||
colorIndex = Math.abs(seed % 6); | ||
@@ -51,0 +51,0 @@ } |
@@ -0,3 +1,3 @@ | ||
import { CommonModule } from '@angular/common'; | ||
import { NgModule } from '@angular/core'; | ||
import { CommonModule } from '@angular/common'; | ||
import { SkyErrorModule } from '@skyux/errors'; | ||
@@ -7,5 +7,5 @@ import { SkyFileAttachmentsModule, SkyFileSizePipe } from '@skyux/forms'; | ||
import { SkyThemeModule } from '@skyux/theme'; | ||
import { SkyAvatarResourcesModule } from '../shared/sky-avatar-resources.module'; | ||
import { SkyAvatarComponent } from './avatar.component'; | ||
import { SkyAvatarInnerComponent } from './avatar.inner.component'; | ||
import { SkyAvatarResourcesModule } from '../shared/sky-avatar-resources.module'; | ||
import * as i0 from "@angular/core"; | ||
@@ -12,0 +12,0 @@ export class SkyAvatarModule { |
@@ -8,3 +8,3 @@ /** | ||
import { NgModule } from '@angular/core'; | ||
import { getLibStringForLocale, SkyI18nModule, SKY_LIB_RESOURCES_PROVIDERS, } from '@skyux/i18n'; | ||
import { SKY_LIB_RESOURCES_PROVIDERS, SkyI18nModule, getLibStringForLocale, } from '@skyux/i18n'; | ||
import * as i0 from "@angular/core"; | ||
@@ -11,0 +11,0 @@ const RESOURCES = { |
@@ -1,5 +0,5 @@ | ||
import * as i0 from '@angular/core'; | ||
import { Injectable, Component, ViewEncapsulation, Input, EventEmitter, Output, NgModule } from '@angular/core'; | ||
import * as i2 from '@angular/common'; | ||
import { CommonModule } from '@angular/common'; | ||
import * as i0 from '@angular/core'; | ||
import { NgModule, Injectable, Component, ViewEncapsulation, Input, EventEmitter, Output } from '@angular/core'; | ||
import * as i1 from '@skyux/errors'; | ||
@@ -15,2 +15,61 @@ import { SkyErrorModule } from '@skyux/errors'; | ||
/** | ||
* NOTICE: DO NOT MODIFY THIS FILE! | ||
* The contents of this file were automatically generated by | ||
* the 'ng generate @skyux/i18n:lib-resources-module modules/shared/sky-avatar' schematic. | ||
* To update this file, simply rerun the command. | ||
*/ | ||
const RESOURCES = { | ||
'EN-US': { | ||
skyux_avatar_error_not_image_description: { | ||
message: 'Please choose a file that is a valid image.', | ||
}, | ||
skyux_avatar_error_not_image_title: { message: 'File is not an image.' }, | ||
skyux_avatar_error_too_large_description: { | ||
message: 'Please choose an image that is less than {0}.', | ||
}, | ||
skyux_avatar_error_too_large_title: { message: 'File is too large.' }, | ||
skyux_avatar_errormodal_ok: { message: 'OK' }, | ||
skyux_avatar_inner_description: { message: 'Profile picture of {0}' }, | ||
skyux_avatar_upload_change_aria_label: { | ||
message: 'Change profile photo of {0}. Drag a file here or click to browse.', | ||
}, | ||
skyux_avatar_upload_new_aria_label: { | ||
message: 'Add profile photo of {0}. Drag a file here or click to browse.', | ||
}, | ||
}, | ||
}; | ||
class SkyAvatarResourcesProvider { | ||
getString(localeInfo, name) { | ||
return getLibStringForLocale(RESOURCES, localeInfo.locale, name); | ||
} | ||
} | ||
/** | ||
* Import into any component library module that needs to use resource strings. | ||
*/ | ||
class SkyAvatarResourcesModule { | ||
} | ||
SkyAvatarResourcesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAvatarResourcesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); | ||
SkyAvatarResourcesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAvatarResourcesModule, exports: [SkyI18nModule] }); | ||
SkyAvatarResourcesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAvatarResourcesModule, providers: [ | ||
{ | ||
provide: SKY_LIB_RESOURCES_PROVIDERS, | ||
useClass: SkyAvatarResourcesProvider, | ||
multi: true, | ||
}, | ||
], imports: [SkyI18nModule] }); | ||
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAvatarResourcesModule, decorators: [{ | ||
type: NgModule, | ||
args: [{ | ||
exports: [SkyI18nModule], | ||
providers: [ | ||
{ | ||
provide: SKY_LIB_RESOURCES_PROVIDERS, | ||
useClass: SkyAvatarResourcesProvider, | ||
multi: true, | ||
}, | ||
], | ||
}] | ||
}] }); | ||
/** | ||
* @internal | ||
@@ -21,6 +80,6 @@ */ | ||
this.revokeBlobUrl(); | ||
let el = elementRef.nativeElement; | ||
const el = elementRef.nativeElement; | ||
/*istanbul ignore else */ | ||
if (el) { | ||
let imageEl = el.querySelector('.sky-avatar-image'); | ||
const imageEl = el.querySelector('.sky-avatar-image'); | ||
/*istanbul ignore else */ | ||
@@ -46,3 +105,3 @@ if (imageEl) { | ||
createBlobUrl(src) { | ||
let url = URL.createObjectURL(src); | ||
const url = URL.createObjectURL(src); | ||
// Keep the last blob URL around so we can revoke it later. | ||
@@ -90,3 +149,3 @@ // https://developer.mozilla.org/en-US/docs/Web/API/URL/revokeObjectURL | ||
if (this.name) { | ||
let nameSplit = this.name.split(' '); | ||
const nameSplit = this.name.split(' '); | ||
initials = getInitial(nameSplit[0]); | ||
@@ -100,3 +159,3 @@ if (nameSplit.length > 1) { | ||
get colorIndex() { | ||
let name = this.name; | ||
const name = this.name; | ||
let colorIndex; | ||
@@ -106,3 +165,3 @@ if (name) { | ||
// so that a given name will always generate the same color. | ||
let seed = name.charCodeAt(0) + name.charCodeAt(name.length - 1) + name.length; | ||
const seed = name.charCodeAt(0) + name.charCodeAt(name.length - 1) + name.length; | ||
colorIndex = Math.abs(seed % 6); | ||
@@ -270,61 +329,2 @@ } | ||
/** | ||
* NOTICE: DO NOT MODIFY THIS FILE! | ||
* The contents of this file were automatically generated by | ||
* the 'ng generate @skyux/i18n:lib-resources-module modules/shared/sky-avatar' schematic. | ||
* To update this file, simply rerun the command. | ||
*/ | ||
const RESOURCES = { | ||
'EN-US': { | ||
skyux_avatar_error_not_image_description: { | ||
message: 'Please choose a file that is a valid image.', | ||
}, | ||
skyux_avatar_error_not_image_title: { message: 'File is not an image.' }, | ||
skyux_avatar_error_too_large_description: { | ||
message: 'Please choose an image that is less than {0}.', | ||
}, | ||
skyux_avatar_error_too_large_title: { message: 'File is too large.' }, | ||
skyux_avatar_errormodal_ok: { message: 'OK' }, | ||
skyux_avatar_inner_description: { message: 'Profile picture of {0}' }, | ||
skyux_avatar_upload_change_aria_label: { | ||
message: 'Change profile photo of {0}. Drag a file here or click to browse.', | ||
}, | ||
skyux_avatar_upload_new_aria_label: { | ||
message: 'Add profile photo of {0}. Drag a file here or click to browse.', | ||
}, | ||
}, | ||
}; | ||
class SkyAvatarResourcesProvider { | ||
getString(localeInfo, name) { | ||
return getLibStringForLocale(RESOURCES, localeInfo.locale, name); | ||
} | ||
} | ||
/** | ||
* Import into any component library module that needs to use resource strings. | ||
*/ | ||
class SkyAvatarResourcesModule { | ||
} | ||
SkyAvatarResourcesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAvatarResourcesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); | ||
SkyAvatarResourcesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAvatarResourcesModule, exports: [SkyI18nModule] }); | ||
SkyAvatarResourcesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAvatarResourcesModule, providers: [ | ||
{ | ||
provide: SKY_LIB_RESOURCES_PROVIDERS, | ||
useClass: SkyAvatarResourcesProvider, | ||
multi: true, | ||
}, | ||
], imports: [SkyI18nModule] }); | ||
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAvatarResourcesModule, decorators: [{ | ||
type: NgModule, | ||
args: [{ | ||
exports: [SkyI18nModule], | ||
providers: [ | ||
{ | ||
provide: SKY_LIB_RESOURCES_PROVIDERS, | ||
useClass: SkyAvatarResourcesProvider, | ||
multi: true, | ||
}, | ||
], | ||
}] | ||
}] }); | ||
class SkyAvatarModule { | ||
@@ -331,0 +331,0 @@ } |
{ | ||
"name": "@skyux/avatar", | ||
"version": "5.5.0", | ||
"version": "5.6.0", | ||
"peerDependencies": { | ||
@@ -8,6 +8,6 @@ "@angular/common": "^12.2.16", | ||
"@angular/router": "^12.2.16", | ||
"@skyux/core": "5.5.0", | ||
"@skyux/i18n": "5.5.0", | ||
"@skyux/errors": "5.5.0", | ||
"@skyux/forms": "5.5.0" | ||
"@skyux/core": "5.6.0", | ||
"@skyux/i18n": "5.6.0", | ||
"@skyux/errors": "5.6.0", | ||
"@skyux/forms": "5.6.0" | ||
}, | ||
@@ -14,0 +14,0 @@ "dependencies": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
15
29
178349