Sanitise the component and Demo shell from embedded strings (#2474)

This commit is contained in:
Eugenio Romano
2017-10-14 14:27:41 +01:00
committed by Denys Vuika
parent bfe8fc8d15
commit 9663971256
17 changed files with 158 additions and 73 deletions

View File

@@ -16,8 +16,7 @@
*/
import { NgModule } from '@angular/core';
import { CoreModule } from 'ng2-alfresco-core';
import { CoreModule, TRANSLATION_PROVIDER } from 'ng2-alfresco-core';
import { MaterialModule } from './src/material.module';
export { ViewerComponent } from './src/components/viewer.component';
@@ -49,11 +48,20 @@ export function declarations() {
],
declarations: declarations(),
providers: [
RenderingQueueServices
RenderingQueueServices,
{
provide: TRANSLATION_PROVIDER,
multi: true,
useValue: {
name: 'ng2-alfresco-viewer',
source: 'assets/ng2-alfresco-viewer'
}
}
],
exports: [
MaterialModule,
...declarations()
]
})
export class ViewerModule {}
export class ViewerModule {
}

View File

@@ -1,6 +1,6 @@
<div class="adf-viewer__unknown-format-view">
<div>
<md-icon class="icon">wifi_tethering</md-icon>
<div class="label">Document preview could not be loaded.</div>
<div class="label">{{'VIEWER.UNKNOWN' | translate}}</div>
</div>
</div>

View File

@@ -1,3 +1,5 @@
{
"VIEWER": {
"UNKNOWN": "Document preview could not be loaded"
}
}