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

Side by Side Diff: sky/examples/color/color-samples.sky

Issue 897683002: Extend the sky color picker example (Closed) Base URL: https://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 unified diff | Download patch
OLDNEW
(Empty)
1 <!--
2 // Copyright 2015 The Chromium Authors. All rights reserved.
3 // Use of this source code is governed by a BSD-style license that can be
4 // found in the LICENSE file.
5 -->
6 <import src="/sky/framework/sky-element/sky-element.sky" as="SkyElement" />
7 <import src="color-sample.sky" />
8
9 <sky-element name="color-samples">
10 <template>
11 <style>
12 :host {
13 display: flex;
14 }
15 color-sample {
16 height: 100%;
17 flex: 1;
18 margin-left: 2px;
19 margin-right: 2px;
20 }
21 /* Sadly, last-child doesn't work */
22 color-sample:last-child {
23 border: 1px solid gray;
24 }
abarth-chromium 2015/02/04 17:23:51 I'd remove this given that it doesn't work.
hansmuller1 2015/02/04 17:30:32 Good point. I'd only put it there to get some feed
25 </style>
26 <template repeat="{{ colors }}">
27 <color-sample color="{{ cssColor }}" />
28 </template>
29 </template>
30 <script>
31 module.exports = class extends SkyElement {
32 created() {
33 this.colors = [];
34 }
35 }.register();
36 </script>
37 </sky-element>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698