* Upgrade to angular 2.0.0-rc.1 * Add a simple .travis.yml closes #180 * Upgrade to ng2-bootstrap 1.0.16 * Install typings on prepublish * (chore) Fix rxjs dependency, moved it to dev dep * (chore) Upgrade to node 6. Keep mandatory deps.
31 lines
903 B
TypeScript
31 lines
903 B
TypeScript
/// <reference path="../../../tsd.d.ts" />
|
|
|
|
import {Component} from '@angular/core';
|
|
import {CORE_DIRECTIVES, FORM_DIRECTIVES, NgClass, NgStyle} from '@angular/common';
|
|
import {FILE_UPLOAD_DIRECTIVES, FileUploader} from '../../../ng2-file-upload';
|
|
|
|
// webpack html imports
|
|
let template = require('./simple-demo.html');
|
|
|
|
// const URL = '/api/';
|
|
const URL = 'https://evening-anchorage-3159.herokuapp.com/api/';
|
|
|
|
@Component({
|
|
selector: 'simple-demo',
|
|
template: template,
|
|
directives: [FILE_UPLOAD_DIRECTIVES, NgClass, NgStyle, CORE_DIRECTIVES, FORM_DIRECTIVES]
|
|
})
|
|
export class SimpleDemo {
|
|
private uploader:FileUploader = new FileUploader({url: URL});
|
|
private hasBaseDropZoneOver:boolean = false;
|
|
private hasAnotherDropZoneOver:boolean = false;
|
|
|
|
private fileOverBase(e:any) {
|
|
this.hasBaseDropZoneOver = e;
|
|
}
|
|
|
|
private fileOverAnother(e:any) {
|
|
this.hasAnotherDropZoneOver = e;
|
|
}
|
|
}
|