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

Unified Diff: sky/examples/widgets/index.sky

Issue 831353003: Implement <sky-input> (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 11 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 | « no previous file | sky/framework/sky-input.sky » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/examples/widgets/index.sky
diff --git a/sky/examples/widgets/index.sky b/sky/examples/widgets/index.sky
index 29c967882d6668ab61ef8602cab60f43094f935d..8e74c77c71974ecb4c1e20ba511c73fa92c52198 100644
--- a/sky/examples/widgets/index.sky
+++ b/sky/examples/widgets/index.sky
@@ -4,10 +4,11 @@
// found in the LICENSE file.
-->
<sky>
-<import src="/sky/framework/sky-element/sky-element.sky" as="SkyElement"/>
-<import src="/sky/framework/sky-button/sky-button.sky"/>
<import src="/sky/framework/sky-box/sky-box.sky"/>
+<import src="/sky/framework/sky-button/sky-button.sky"/>
<import src="/sky/framework/sky-checkbox/sky-checkbox.sky"/>
+<import src="/sky/framework/sky-element/sky-element.sky" as="SkyElement"/>
+<import src="/sky/framework/sky-input.sky"/>
<import src="/sky/framework/sky-radio/sky-radio.sky"/>
<sky-element name="widget-root">
<template>
@@ -24,6 +25,8 @@
}
</style>
+ <sky-input id="text" value="Ready" />
+
<sky-box title='Buttons'>
<sky-button id='button' on-click='handleClick'>Button</sky-button>
<div>highlight: {{ myButton.highlight }}</div>
@@ -56,10 +59,12 @@ module.exports = class extends SkyElement {
attached() {
this.myButton = this.shadowRoot.getElementById('button');
this.myCheckbox = this.shadowRoot.getElementById('checkbox');
+ this.myText = this.shadowRoot.getElementById('text');
this.clickCount = 0;
}
handleClick(event) {
this.clickCount++;
+ this.myText.value = "Moar clicking " + this.clickCount;
}
}.register();
</script>
« no previous file with comments | « no previous file | sky/framework/sky-input.sky » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698