Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 0 additions & 37 deletions Modules/Context.js

This file was deleted.

31 changes: 0 additions & 31 deletions Pages/EditHikePage.js

This file was deleted.

File renamed without changes.
File renamed without changes.
42 changes: 42 additions & 0 deletions chapter-1/MainView.ux
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<App>
<ClientPanel>
<JavaScript>
var Observable = require("FuseJS/Observable");

var name = Observable("Tricky Trails");
var location = Observable("Lakebed, Utah");
var distance = Observable(10.4);
var rating = Observable(4);
var comments = Observable("This hike was nice and hike-like. Glad I didn't bring a bike.");

module.exports = {
name: name,
location: location,
distance: distance,
rating: rating,
comments: comments
};
</JavaScript>

<ScrollView>
<StackPanel>
<Text Value="{name}" />

<Text>Name:</Text>
<TextBox Value="{name}" />

<Text>Location:</Text>
<TextBox Value="{location}" />

<Text>Distance (km):</Text>
<TextBox Value="{distance}" InputHint="Decimal" />

<Text>Rating:</Text>
<TextBox Value="{rating}" InputHint="Integer" />

<Text>Comments:</Text>
<TextView Value="{comments}" TextWrapping="Wrap" />
</StackPanel>
</ScrollView>
</ClientPanel>
</App>
File renamed without changes.
File renamed without changes
10 changes: 10 additions & 0 deletions chapter-1/hikr.unoproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"RootNamespace":"",
"Packages": [
"Fuse",
"FuseJS"
],
"Includes": [
"*"
]
}
2 changes: 2 additions & 0 deletions chapter-2/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
build/
.uno/
21 changes: 21 additions & 0 deletions chapter-2/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) 2016 Fuse

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
89 changes: 89 additions & 0 deletions chapter-2/MainView.ux
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
<App>
<ClientPanel>
<JavaScript>
var Observable = require("FuseJS/Observable");

var hikes = [
{
id: 0,
name: "Tricky Trails",
location: "Lakebed, Utah",
distance: 10.4,
rating: 4,
comments: "This hike was nice and hike-like. Glad I didn't bring a bike."
},
{
id: 1,
name: "Mondo Mountains",
location: "Black Hills, South Dakota",
distance: 20.86,
rating: 3,
comments: "Not the best, but would probably do again. Note to self: don't forget the sandwiches next time."
},
{
id: 2,
name: "Pesky Peaks",
location: "Bergenhagen, Norway",
distance: 8.2,
rating: 5,
comments: "Short but SO sweet!!"
},
{
id: 3,
name: "Rad Rivers",
location: "Moriyama, Japan",
distance: 12.3,
rating: 4,
comments: "Took my time with this one. Great view!"
},
{
id: 4,
name: "Dangerous Dirt",
location: "Cactus, Arizona",
distance: 19.34,
rating: 2,
comments: "Too long, too hot. Also that snakebite wasn't very fun."
}
];

var hike = Observable();

function chooseHike(arg) {
hike.value = arg.data;
}

module.exports = {
hikes: hikes,

hike: hike,

chooseHike: chooseHike
};
</JavaScript>

<ScrollView>
<StackPanel>
<Each Items="{hikes}">
<Button Text="{name}" Clicked="{chooseHike}" />
</Each>

<Text Value="{hike.name}" />

<Text>Name:</Text>
<TextBox Value="{hike.name}" />

<Text>Location:</Text>
<TextBox Value="{hike.location}" />

<Text>Distance (km):</Text>
<TextBox Value="{hike.distance}" InputHint="Decimal" />

<Text>Rating:</Text>
<TextBox Value="{hike.rating}" InputHint="Integer" />

<Text>Comments:</Text>
<TextView Value="{hike.comments}" TextWrapping="Wrap" />
</StackPanel>
</ScrollView>
</ClientPanel>
</App>
14 changes: 14 additions & 0 deletions chapter-2/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# hikr
Pronounced "hiker" (/ˈhaɪkə(r)/), hikr is a basic hike-tracking app.

![Screen cap](https://github.com/fusetools/hikr/blob/master/hikr.gif)

## basic info
hikr is an example app case to accompany Fuse's [end-to-end Fuse app tutorial](https://www.fusetools.com/docs/tutorial/tutorial).

_Note: there have been some force-pushes on this repo, so if you've cloned it before the series went live, it's probably a good idea to delete it and clone again._

## license
This code is licensed under the MIT license (see LICENSE).

The provided video file (`Assets/nature.mp4`) is a modified version of [Graham Uhelski](https://vimeo.com/mankindfilms)'s ["The Valley"](http://mazwai.com/#/videos/220). It is licensed under [CC BY 3.0](https://creativecommons.org/licenses/by/3.0/).
Binary file added chapter-2/hikr.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 10 additions & 0 deletions chapter-2/hikr.unoproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"RootNamespace":"",
"Packages": [
"Fuse",
"FuseJS"
],
"Includes": [
"*"
]
}
2 changes: 2 additions & 0 deletions chapter-3/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
build/
.uno/
21 changes: 21 additions & 0 deletions chapter-3/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) 2016 Fuse

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
8 changes: 8 additions & 0 deletions chapter-3/MainView.ux
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<App>
<ClientPanel>
<PageControl>
<HomePage />
<EditHikePage />
</PageControl>
</ClientPanel>
</App>
7 changes: 7 additions & 0 deletions chapter-3/Pages/EditHikePage.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
var Observable = require("FuseJS/Observable");

var hike = Observable();

module.exports = {
hike: hike
};
24 changes: 24 additions & 0 deletions chapter-3/Pages/EditHikePage.ux
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<Page ux:Class="EditHikePage">
<JavaScript File="EditHikePage.js" />

<ScrollView>
<StackPanel>
<Text Value="{hike.name}" />

<Text>Name:</Text>
<TextBox Value="{hike.name}" />

<Text>Location:</Text>
<TextBox Value="{hike.location}" />

<Text>Distance (km):</Text>
<TextBox Value="{hike.distance}" InputHint="Decimal" />

<Text>Rating:</Text>
<TextBox Value="{hike.rating}" InputHint="Integer" />

<Text>Comments:</Text>
<TextView Value="{hike.comments}" TextWrapping="Wrap" />
</StackPanel>
</ScrollView>
</Page>
11 changes: 11 additions & 0 deletions chapter-3/Pages/HomePage.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
var hikes = require("hikes");

function chooseHike(arg) {
// TODO
}

module.exports = {
hikes: hikes,

chooseHike: chooseHike
};
11 changes: 11 additions & 0 deletions chapter-3/Pages/HomePage.ux
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<Page ux:Class="HomePage">
<JavaScript File="HomePage.js" />

<ScrollView>
<StackPanel>
<Each Items="{hikes}">
<Button Text="{name}" Clicked="{chooseHike}" />
</Each>
</StackPanel>
</ScrollView>
</Page>
14 changes: 14 additions & 0 deletions chapter-3/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# hikr
Pronounced "hiker" (/ˈhaɪkə(r)/), hikr is a basic hike-tracking app.

![Screen cap](https://github.com/fusetools/hikr/blob/master/hikr.gif)

## basic info
hikr is an example app case to accompany Fuse's [end-to-end Fuse app tutorial](https://www.fusetools.com/docs/tutorial/tutorial).

_Note: there have been some force-pushes on this repo, so if you've cloned it before the series went live, it's probably a good idea to delete it and clone again._

## license
This code is licensed under the MIT license (see LICENSE).

The provided video file (`Assets/nature.mp4`) is a modified version of [Graham Uhelski](https://vimeo.com/mankindfilms)'s ["The Valley"](http://mazwai.com/#/videos/220). It is licensed under [CC BY 3.0](https://creativecommons.org/licenses/by/3.0/).
Loading