Skip to content

Commit 0c7a270

Browse files
author
Vlad Balin
committed
Minor fixes
1 parent 372e0a6 commit 0c7a270

File tree

10 files changed

+32
-10
lines changed

10 files changed

+32
-10
lines changed

app/index.js

100644100755
Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,7 @@ class MultiScreenApp extends Application {
2121
// Just switch between two screens we have.
2222
Application.switchTo( this.screen === this.screen1 ? 'screen2' : 'screen1' );
2323
}
24-
}
25-
24+
}
2625
}
2726

2827
// Create and start the application.

app/screen1.js

100644100755
File mode changed.

app/screen2.js

100644100755
Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,25 @@
11
import { View, $at } from './view'
22

3+
// Create the root selector for the view...
34
const $ = $at( '#screen-2' );
45

5-
export class Screen1 extends View {
6+
export class Screen2 extends View {
7+
// Specify the root view element.
8+
// When set, it will be used to show/hide the view on mount and unmount.
69
el = $();
710

11+
// Lifecycle hook executed on `view.mount()`.
812
onMount(){
913
// TODO: insert subviews...
1014
// TODO: subscribe for events...
1115
}
1216

17+
// Lifecycle hook executed on `view.unmount()`.
1318
onUnmount(){
1419
// TODO: unsubscribe from events...
1520
}
1621

22+
// Custom UI update logic, executed on `view.render()`.
1723
onRender(){
1824
// TODO: put DOM manipulations here...
1925
// Call this.render() to update UI.

app/view.js

100644100755
File mode changed.

package.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"fitbit": {
3+
"appUUID": "d84e4e76-0ded-40f2-98f7-f4de4dc27fc4",
4+
"appType": "app",
5+
"appDisplayName": "boilerplate",
6+
"iconFile": "resources/icon.png",
7+
"wipeColor": "#607d8b",
8+
"requestedPermissions": [],
9+
"i18n": {
10+
"en": {
11+
"name": "boilerplate"
12+
}
13+
}
14+
}
15+
}

resources/index.gui

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
<svg>
22
<link rel="import" href="screen1.gui" />
33
<link rel="import" href="screen2.gui" />
4-
</svg>
4+
</svg>

resources/screen1.gui

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
<svg id="screen-1" display="none">
2-
<text id="minutes>--</text>
2+
<text id="minutes">--</text>
33
<text id="seconds">--</text>
44
</svg>

resources/screen2.gui

100644100755
File mode changed.

resources/styles.css

100644100755
Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
text {
2-
font-family: System-Regular;
3-
fill: white;
4-
}
1+
.defaultText {
2+
font-size: 32;
3+
font-family: System-Regular;
4+
font-weight: regular;
5+
text-length: 32;
6+
}

resources/widgets.gui

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@
33
<link rel="stylesheet" href="styles.css" />
44
<link rel="import" href="/mnt/sysassets/widgets_common.gui" />
55
</defs>
6-
</svg>
6+
</svg>

0 commit comments

Comments
 (0)