Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
577c220
commit 633c422
Showing
51 changed files
with
1,253 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) 2016 Cloudstitch Inc. | ||
|
||
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. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,19 @@ | ||
# framer.module.cloudstitch | ||
|
||
framer.module.cloudstitch lets you load data from Google Spreadsheets and Microsoft Excel. | ||
|
||
## Installation | ||
Add ```cloudstitch.coffee``` to the /modules folder of your project. | ||
|
||
## Usage | ||
To include the module within your project, add the following: | ||
|
||
``` coffeescript | ||
cloudstitch = require "cloudstitch" | ||
``` | ||
|
||
Then get data from your spreadsheet by providing the Cloudstitch username and appname of your project: | ||
|
||
``` coffeescript | ||
cloudstitch.get(username, appname, (response) -> callback(response)) | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="utf-8"> | ||
|
||
<meta name="format-detection" content="telephone=no"> | ||
<meta name="apple-mobile-web-app-capable" content="yes"> | ||
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent"> | ||
|
||
<script type="text/javascript"> | ||
// This automatically sets the right viewport scale on mobile devices | ||
(function() { | ||
var scale = 1 / window.devicePixelRatio | ||
var viewport = "width=device-width, height=device-height, initial-scale=" + scale + ", maximum-scale=" + scale + ", user-scalable=no" | ||
var iOS = /iPad|iPhone|iPod/.test(navigator.platform) | ||
if (iOS) { viewport += ", shrink-to-fit=no" } | ||
document.write("<meta name=\"viewport\" content=\"" + viewport + "\">") | ||
})() | ||
</script> | ||
|
||
<link rel="apple-touch-icon" href="framer/images/icon-120.png"> | ||
<link rel="apple-touch-icon" href="framer/images/icon-76.png" sizes="76x76"> | ||
<link rel="apple-touch-icon" href="framer/images/icon-120.png" sizes="120x120"> | ||
<link rel="apple-touch-icon" href="framer/images/icon-152.png" sizes="152x152"> | ||
<link rel="apple-touch-icon" href="framer/images/icon-180.png" sizes="180x180"> | ||
<link rel="apple-touch-icon" href="framer/images/icon-192.png" sizes="192x192"> | ||
|
||
<link rel="stylesheet" type="text/css" href="framer/style.css?nocache=6d40bc53861208d298f85019e08849ff"> | ||
|
||
<script src="framer/coffee-script.js"></script> | ||
<script src="framer/framer.js?nocache=9d4afbd0b29b5a54c5b341398a73e99a"></script> | ||
<script src="framer/framer.generated.js?nocache=a5287db4f745db84c38f451264ea8444"></script> | ||
<script src="framer/framer.modules.js?nocache=75c25c91f25d88b6c1ea0aa5ea3a761f"></script> | ||
<script src="framer/framer.init.js"></script> | ||
|
||
</head> | ||
<body> | ||
</body> | ||
</html> | ||
<script src='/_server/resources/FramerStudioViewer/build/FramerStudioViewer.js'></script> |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Project Info | ||
# This info is presented in a widget when you share. | ||
# http://framerjs.com/docs/#info.info | ||
|
||
Framer.Info = | ||
title: "" | ||
author: "Edward Benson" | ||
twitter: "" | ||
description: "" | ||
|
||
# Set background color | ||
Screen.backgroundColor = "#AAEEFF" | ||
|
||
# Some constants to help us lay out the grid | ||
COLS = 3 | ||
SPACE = 20 | ||
SIDE = (Screen.size.width - (SPACE * (COLS - 2))) / COLS | ||
COLS = parseInt(Screen.size.height / (SIDE + SPACE)) | ||
|
||
# Load data from the spreadsheet. | ||
cloudstitch = require "cloudstitch" | ||
|
||
# The `get` method takes your Cloudstitch username and appname, and | ||
# it returns the contents of your spreadsheet as a JSON object. | ||
cloudstitch.get('project-templates', 'framer-module-demo', (data) -> | ||
listLogo(company, i) for company, i in data.Companies | ||
) | ||
|
||
listLogo = (company, i) -> | ||
x = SIDE * (i % COLS) + ((i % COLS)-1)*SPACE | ||
y = parseInt(i / COLS) * SIDE + (parseInt(i / COLS) * SPACE) | ||
|
||
logo = new Layer( | ||
height: SIDE | ||
width: SIDE | ||
x: x | ||
y: y | ||
image: company.URL | ||
html: "<p align='center' style='background-color: black'>" + company.Name + "</p>" | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2c587dbfafdd48dd6c23007c4dac5433:/Users/eob/Code/framer.module.cloudstitch/cloudstitch.framer/modules/cloudstitch.coffee |
34 changes: 34 additions & 0 deletions
34
cloudstitch.framer/framer/backups/backup-2016-09-13 18.17.24.coffee
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
# Project Info | ||
# This info is presented in a widget when you share. | ||
# http://framerjs.com/docs/#info.info | ||
|
||
Framer.Info = | ||
title: "" | ||
author: "Edward Benson" | ||
twitter: "" | ||
description: "" | ||
|
||
# Set background color | ||
Screen.backgroundColor = "#AAEEFF" | ||
SIDE = 200 | ||
|
||
# Load data from the spreadsheet | ||
cloudstitch = require "cloudstitch" | ||
cloudstitch.get('ted', 'polymer-jobs', (data) -> | ||
listLogo(company, i) for company, i in data.jobs | ||
|
||
# | ||
|
||
listLogos = (data) -> | ||
|
||
|
||
listLogo = (company, i) -> | ||
|
||
|
||
logo = new Layer( | ||
height: 200 | ||
width: 200 | ||
x: Align.center(210 * i) | ||
y: Align.center | ||
image: company.LogoUrl | ||
) |
34 changes: 34 additions & 0 deletions
34
cloudstitch.framer/framer/backups/backup-2016-09-13 18.18.24.coffee
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
# Project Info | ||
# This info is presented in a widget when you share. | ||
# http://framerjs.com/docs/#info.info | ||
|
||
Framer.Info = | ||
title: "" | ||
author: "Edward Benson" | ||
twitter: "" | ||
description: "" | ||
|
||
# Set background color | ||
Screen.backgroundColor = "#AAEEFF" | ||
SIDE = 200 | ||
SPACE = 20 | ||
|
||
# Load data from the spreadsheet | ||
cloudstitch = require "cloudstitch" | ||
cloudstitch.get('ted', 'polymer-jobs', (data) -> | ||
listLogo(company, i) for company, i in data.jobs | ||
) | ||
|
||
listLogos = (data) -> | ||
|
||
|
||
listLogo = (company, i) -> | ||
var x = ((SIDE + SPACE) * i) % Screen.size.width | ||
|
||
logo = new Layer( | ||
height: 200 | ||
width: 200 | ||
x: Align.center(210 * i) | ||
y: Align.center | ||
image: company.LogoUrl | ||
) |
35 changes: 35 additions & 0 deletions
35
cloudstitch.framer/framer/backups/backup-2016-09-13 18.19.24.coffee
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Project Info | ||
# This info is presented in a widget when you share. | ||
# http://framerjs.com/docs/#info.info | ||
|
||
Framer.Info = | ||
title: "" | ||
author: "Edward Benson" | ||
twitter: "" | ||
description: "" | ||
|
||
# Set background color | ||
Screen.backgroundColor = "#AAEEFF" | ||
SIDE = 200 | ||
SPACE = 20 | ||
|
||
# Load data from the spreadsheet | ||
cloudstitch = require "cloudstitch" | ||
cloudstitch.get('ted', 'polymer-jobs', (data) -> | ||
listLogo(company, i) for company, i in data.jobs | ||
) | ||
|
||
listLogos = (data) -> | ||
|
||
|
||
listLogo = (company, i) -> | ||
x = ((SIDE + SPACE) * i) % Screen.size.width | ||
y = ((SIDE + SPACE) * i) % Screen.size.height | ||
|
||
logo = new Layer( | ||
height: SIDE | ||
width: SIDE | ||
x: x | ||
y: y | ||
image: company.LogoUrl | ||
) |
38 changes: 38 additions & 0 deletions
38
cloudstitch.framer/framer/backups/backup-2016-09-13 18.20.24.coffee
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
# Project Info | ||
# This info is presented in a widget when you share. | ||
# http://framerjs.com/docs/#info.info | ||
|
||
Framer.Info = | ||
title: "" | ||
author: "Edward Benson" | ||
twitter: "" | ||
description: "" | ||
|
||
# Set background color | ||
Screen.backgroundColor = "#AAEEFF" | ||
SIDE = 200 | ||
SPACE = 20 | ||
COLS = Screen.size.height / (SIDE + SPACE) | ||
|
||
# Load data from the spreadsheet | ||
cloudstitch = require "cloudstitch" | ||
cloudstitch.get('ted', 'polymer-jobs', (data) -> | ||
listLogo(company, i) for company, i in data.jobs | ||
) | ||
|
||
listLogos = (data) -> | ||
|
||
|
||
listLogo = (company, i) -> | ||
x = ((SIDE + SPACE) * i) % Screen.size.width | ||
y = i / COLS | ||
|
||
((SIDE + SPACE) * i) % Screen.size.height | ||
|
||
logo = new Layer( | ||
height: SIDE | ||
width: SIDE | ||
x: x | ||
y: y | ||
image: company.LogoUrl | ||
) |
36 changes: 36 additions & 0 deletions
36
cloudstitch.framer/framer/backups/backup-2016-09-13 18.21.24.coffee
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Project Info | ||
# This info is presented in a widget when you share. | ||
# http://framerjs.com/docs/#info.info | ||
|
||
Framer.Info = | ||
title: "" | ||
author: "Edward Benson" | ||
twitter: "" | ||
description: "" | ||
|
||
# Set background color | ||
Screen.backgroundColor = "#AAEEFF" | ||
SIDE = 200 | ||
SPACE = 20 | ||
COLS = Screen.size.height / (SIDE + SPACE) | ||
|
||
# Load data from the spreadsheet | ||
cloudstitch = require "cloudstitch" | ||
cloudstitch.get('ted', 'polymer-jobs', (data) -> | ||
listLogo(company, i) for company, i in data.jobs | ||
) | ||
|
||
listLogos = (data) -> | ||
|
||
|
||
listLogo = (company, i) -> | ||
x = ((SIDE + SPACE) * i) % Screen.size.width | ||
y = ((SIDE + SPACE) * (i /cols)) | ||
|
||
logo = new Layer( | ||
height: SIDE | ||
width: SIDE | ||
x: x | ||
y: y | ||
image: company.LogoUrl | ||
) |
36 changes: 36 additions & 0 deletions
36
cloudstitch.framer/framer/backups/backup-2016-09-13 18.22.24.coffee
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Project Info | ||
# This info is presented in a widget when you share. | ||
# http://framerjs.com/docs/#info.info | ||
|
||
Framer.Info = | ||
title: "" | ||
author: "Edward Benson" | ||
twitter: "" | ||
description: "" | ||
|
||
# Set background color | ||
Screen.backgroundColor = "#AAEEFF" | ||
SIDE = 200 | ||
SPACE = 20 | ||
COLS = Screen.size.height / (SIDE + SPACE) | ||
|
||
# Load data from the spreadsheet | ||
cloudstitch = require "cloudstitch" | ||
cloudstitch.get('ted', 'polymer-jobs', (data) -> | ||
listLogo(company, i) for company, i in data.jobs | ||
) | ||
|
||
listLogos = (data) -> | ||
console. | ||
|
||
listLogo = (company, i) -> | ||
x = ((SIDE + SPACE) * i) % Screen.size.width | ||
y = ((SIDE + SPACE) * (i / COLS)) | ||
|
||
logo = new Layer( | ||
height: SIDE | ||
width: SIDE | ||
x: x | ||
y: y | ||
image: company.LogoUrl | ||
) |
35 changes: 35 additions & 0 deletions
35
cloudstitch.framer/framer/backups/backup-2016-09-13 18.23.24.coffee
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Project Info | ||
# This info is presented in a widget when you share. | ||
# http://framerjs.com/docs/#info.info | ||
|
||
Framer.Info = | ||
title: "" | ||
author: "Edward Benson" | ||
twitter: "" | ||
description: "" | ||
|
||
# Set background color | ||
Screen.backgroundColor = "#AAEEFF" | ||
SIDE = 200 | ||
SPACE = 20 | ||
COLS = parseInt(Screen.size.height / (SIDE + SPACE)) | ||
|
||
# Load data from the spreadsheet | ||
cloudstitch = require "cloudstitch" | ||
cloudstitch.get('ted', 'polymer-jobs', (data) -> | ||
listLogo(company, i) for company, i in data.jobs | ||
) | ||
|
||
listLogos = (data) -> | ||
|
||
listLogo = (company, i) -> | ||
x = ((SIDE + SPACE) * i) % Screen.size.width | ||
y = ((SIDE + SPACE) * (i / COLS)) | ||
|
||
logo = new Layer( | ||
height: SIDE | ||
width: SIDE | ||
x: x | ||
y: y | ||
image: company.LogoUrl | ||
) |
Oops, something went wrong.