1
0
mirror of https://github.com/bpatrik/pigallery2.git synced 2024-12-21 01:22:08 +02:00
pigallery2/frontend/app/gallery/directory/directory.gallery.component.ts

31 lines
881 B
TypeScript
Raw Normal View History

2016-03-20 21:05:51 +02:00
///<reference path="../../../browser.d.ts"/>
import {Component, Input, OnInit} from 'angular2/core';
import {Directory} from "../../../../common/entities/Directory";
2016-03-26 17:25:48 +02:00
import {RouterLink} from "angular2/router";
2016-03-26 20:24:12 +02:00
import {Utils} from "../../../../common/Utils";
2016-04-24 20:56:54 +02:00
import {MATERIAL_BROWSER_PROVIDERS} from "ng2-material/all";
import {ViewportHelper} from "ng2-material/all";
import {MATERIAL_DIRECTIVES} from "ng2-material/all";
2016-03-20 21:05:51 +02:00
@Component({
selector: 'gallery-directory',
2016-03-26 17:25:48 +02:00
templateUrl: 'app/gallery/directory/directory.gallery.component.html',
2016-04-24 20:56:54 +02:00
directives:[RouterLink,MATERIAL_DIRECTIVES],
providers:[MATERIAL_BROWSER_PROVIDERS, ViewportHelper]
2016-03-20 21:05:51 +02:00
})
export class GalleryDirectoryComponent{
@Input() directory: Directory;
constructor() {
}
2016-03-26 20:24:12 +02:00
getDirectoryPath(){
return Utils.concatUrls(this.directory.path,this.directory.name);
}
2016-03-20 21:05:51 +02:00
}