view service/wifi/src/index.ts @ 674:2b9865bf1737

streamed-graph finally imports and builds. polymer bindings don't work in a <dom-bind> though Ignore-this: afcf4436ac3d7b88c0d7fc88de81d8e4
author drewp@bigasterisk.com
date Thu, 02 Jan 2020 00:23:36 -0800
parents f2215949c0c9
children 9ae34280218b
line wrap: on
line source

import { PolymerElement, html } from "@polymer/polymer";
import {
  customElement,
  property,
  computed,
  observe,
} from "@polymer/decorators";
import { N3Store } from "n3";
//import {* as wt} from './wifi-table';
import { VersionedGraph, StreamedGraph } from "streamed-graph";
export { DomBind } from "@polymer/polymer/lib/elements/dom-bind.js";

console.log("here is a real dependency on ", StreamedGraph.name);

@customElement("wifi-display")
class WifiDisplay extends PolymerElement {
  @property({ type: Object, observer: WifiDisplay.prototype.onGraphChanged})
  graph!: VersionedGraph;


  onGraphChanged() {
    console.log("new graph", this.graph);
  }

  ready() {
    super.ready();
  }

  // redraw() {
  //     wt.render(this.graph.graph);
  // }
  static get template() {
    return html`
      here
    `;
  }
}