mirror of
https://github.com/turt2live/matrix-dimension.git
synced 2024-10-01 01:05:53 -04:00
4965b61f2d
This still doesn't allow editing, but it supports showing the widgets at least.
16 lines
422 B
TypeScript
16 lines
422 B
TypeScript
import { Http, Response } from "@angular/http";
|
|
import { Observable } from "rxjs/Observable";
|
|
|
|
export class AuthedApi {
|
|
public static SCALAR_TOKEN: string = null;
|
|
|
|
constructor(protected http: Http) {
|
|
}
|
|
|
|
protected authedGet(url: string, qs?: any): Observable<Response> {
|
|
if (!qs) qs = {};
|
|
qs["scalar_token"] = AuthedApi.SCALAR_TOKEN;
|
|
return this.http.get(url, {params: qs});
|
|
}
|
|
}
|