Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1707)

Unified Diff: sky/examples/stocks/stock.sky

Issue 954503002: Morph "appish" example into a "stocks" app (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sky/examples/stocks/index.sky ('k') | sky/examples/stocks/stocks.sky » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/examples/stocks/stock.sky
diff --git a/sky/examples/stocks/stock.sky b/sky/examples/stocks/stock.sky
new file mode 100644
index 0000000000000000000000000000000000000000..d4ffbd72abb282be50da644d059a5cc0d11f27ec
--- /dev/null
+++ b/sky/examples/stocks/stock.sky
@@ -0,0 +1,29 @@
+<!--
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+-->
+<import src="/sky/framework/sky-element.sky" />
+
+<sky-element attributes="ticker:string">
+<template>
+ <style>
+ </style>
+ <div id="ticker" />
+</template>
+<script>
+import "dart:sky";
+
+@Tagname('stock')
+class Stock extends SkyElement {
+ Element _ticker;
+
+ void shadowRootReady() {
+ _ticker = shadowRoot.getElementById('ticker');
+ _ticker.textContent = ticker;
+ }
+}
+
+_init(script) => register(script, Stock);
+</script>
+</sky-element>
« no previous file with comments | « sky/examples/stocks/index.sky ('k') | sky/examples/stocks/stocks.sky » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698