From 14699818d58beef4b9b20b3ddb3e03641c0b7f21 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Wed, 16 Sep 2015 15:06:56 -0400 Subject: populate collectionview --- StoneIsland/platforms/ios/StoneIsland/config.xml | 1 + StoneIsland/platforms/ios/www/css/index.css | 153 +++------- StoneIsland/platforms/ios/www/img/logo.png | Bin 21814 -> 0 bytes StoneIsland/platforms/ios/www/index.html | 343 +++++++++++++++++++++- StoneIsland/platforms/ios/www/js/index.js | 54 ++-- StoneIsland/platforms/ios/www/js/vendor/cookie.js | 63 ---- StoneIsland/platforms/ios/www/js/vendor/xhr.js | 35 --- 7 files changed, 410 insertions(+), 239 deletions(-) delete mode 100644 StoneIsland/platforms/ios/www/img/logo.png delete mode 100644 StoneIsland/platforms/ios/www/js/vendor/cookie.js delete mode 100644 StoneIsland/platforms/ios/www/js/vendor/xhr.js (limited to 'StoneIsland/platforms') diff --git a/StoneIsland/platforms/ios/StoneIsland/config.xml b/StoneIsland/platforms/ios/StoneIsland/config.xml index c102dc1a..5acacfc0 100755 --- a/StoneIsland/platforms/ios/StoneIsland/config.xml +++ b/StoneIsland/platforms/ios/StoneIsland/config.xml @@ -39,6 +39,7 @@ + StoneIsland Stone Island app diff --git a/StoneIsland/platforms/ios/www/css/index.css b/StoneIsland/platforms/ios/www/css/index.css index 51daa797..3c2a4d10 100644 --- a/StoneIsland/platforms/ios/www/css/index.css +++ b/StoneIsland/platforms/ios/www/css/index.css @@ -1,115 +1,44 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ * { - -webkit-tap-highlight-color: rgba(0,0,0,0); /* make transparent link selection, adjust last value opacity 0 to 1.0 */ + -webkit-tap-highlight-color: rgba(0,0,0,0); } - -body { - -webkit-touch-callout: none; /* prevent callout to copy image, etc when tap to hold */ - -webkit-text-size-adjust: none; /* prevent webkit from resizing text to fit */ - -webkit-user-select: none; /* prevent copy paste, to allow, change 'none' to 'text' */ - background-color:#E4E4E4; - background-image:linear-gradient(top, #A7A7A7 0%, #E4E4E4 51%); - background-image:-webkit-linear-gradient(top, #A7A7A7 0%, #E4E4E4 51%); - background-image:-ms-linear-gradient(top, #A7A7A7 0%, #E4E4E4 51%); - background-image:-webkit-gradient( - linear, - left top, - left bottom, - color-stop(0, #A7A7A7), - color-stop(0.51, #E4E4E4) - ); - background-attachment:fixed; - font-family:'HelveticaNeue-Light', 'HelveticaNeue', Helvetica, Arial, sans-serif; - font-size:12px; - height:100%; - margin:0px; - padding:0px; - text-transform:uppercase; - width:100%; -} - -/* Portrait layout (default) */ -.app { - background:url(../img/logo.png) no-repeat center top; /* 170px x 200px */ - position:absolute; /* position in the center of the screen */ - left:50%; - top:50%; - height:50px; /* text area height */ - width:225px; /* text area width */ - text-align:center; - padding:180px 0px 0px 0px; /* image height is 200px (bottom 20px are overlapped with text) */ - margin:-115px 0px 0px -112px; /* offset vertical: half of image height and text area height */ - /* offset horizontal: half of text area width */ -} - -/* Landscape layout (with min-width) */ -@media screen and (min-aspect-ratio: 1/1) and (min-width:400px) { - .app { - background-position:left center; - padding:75px 0px 75px 170px; /* padding-top + padding-bottom + text area = image height */ - margin:-90px 0px 0px -198px; /* offset vertical: half of image height */ - /* offset horizontal: half of image width and text area width */ - } -} - -h1 { - font-size:24px; - font-weight:normal; - margin:0px; - overflow:visible; - padding:0px; - text-align:center; -} - -.event { - border-radius:4px; - -webkit-border-radius:4px; - color:#FFFFFF; - font-size:12px; - margin:0px 30px; - padding:2px 0px; -} - -.event.listening { - background-color:#333333; - display:block; -} - -.event.received { - background-color:#4B946A; - display:none; -} - -@keyframes fade { - from { opacity: 1.0; } - 50% { opacity: 0.4; } - to { opacity: 1.0; } -} - -@-webkit-keyframes fade { - from { opacity: 1.0; } - 50% { opacity: 0.4; } - to { opacity: 1.0; } -} - -.blink { - animation:fade 3000ms infinite; - -webkit-animation:fade 3000ms infinite; +body, html { + height: 100%; + width: 100%; + margin: 0px; + padding: 0px; + overflow: hidden; } +body { + -webkit-touch-callout: none; /* prevent callout to copy image, etc when tap to hold */ + -webkit-text-size-adjust: none; /* prevent webkit from resizing text to fit */ + -webkit-user-select: none; /* prevent copy paste, to allow, change 'none' to 'text' */ + background: white; + font-family: pfd, sans-serif; + font-size: 12px; +} + +.loader { + z-index: 2; + width: 80px; + height: 80px; + position: absolute; + top: 50%; + left: 50%; + margin-top: -40px; + margin-left: -40px; + display: none; +} +.loader:before { + content: ''; + border-radius: 50%; + border-top: 3px solid #fff; + border-right: 3px solid transparent; + animation: loading .5s linear infinite; + -webkit-animation: loading .5s linear infinite; +} +@keyframes loading { + to {transform: rotate(360deg)} +} +@-webkit-keyframes loading { + to {-webkit-transform: rotate(360deg)} +} \ No newline at end of file diff --git a/StoneIsland/platforms/ios/www/img/logo.png b/StoneIsland/platforms/ios/www/img/logo.png deleted file mode 100644 index 9519e7dd..00000000 Binary files a/StoneIsland/platforms/ios/www/img/logo.png and /dev/null differ diff --git a/StoneIsland/platforms/ios/www/index.html b/StoneIsland/platforms/ios/www/index.html index 09709bb9..652cce9a 100644 --- a/StoneIsland/platforms/ios/www/index.html +++ b/StoneIsland/platforms/ios/www/index.html @@ -16,13 +16,348 @@ + + + + + + Stone Island - - - - + + + +
+ +
+
+
STORE
+
HUB
+
STORY
+
ARCHIVE
+ +40.589060 -74.044636 +
+ + + + + +
+

STORY

+
+ +
+
+ +
+

HUB

+
+ +
+
+ +
+

ARCHIVE

+
+ +
+
+ +
+

COLLECTION NAME

+
+
+ +
+
+ + +
+ + + + + + + + + + + +
+
+
+ + +
+ +
+ X-SMALL + SMALL + MEDIUM + LARGE + X-LARGE +
+
+ +
+
+ + + +
+ + + SIGN IN +
+
+ + +
+

YOUR CART / 2 ITEMS

+ +
+ SUMMARY + SHIPPING + BILLING +
+ +
+
+ +
+
+ SUB TOTAL + +
+
+ ESTIMATED SHIPPING
& HANDLING
+ +
+
+ TAX + +
+
+ TOTAL + +
+
+ +
+
+ ADDRESS +
+
+
+ + +
+
+ + + +
+
+ + +
+
+ + +
+
+ + +
+
+ +

SHIPPING METHOD

+ +
+
+ STANDARD $10 + (DELIVERY IN 5-8 WORKING DAYS) +
+ +
+
+ EXPRESS $20 + (DELIVERY IN 2-4 WORKING DAYS) +
+
+ +
+
+ +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/StoneIsland/platforms/ios/www/js/index.js b/StoneIsland/platforms/ios/www/js/index.js index 2875c90b..5720dcf1 100644 --- a/StoneIsland/platforms/ios/www/js/index.js +++ b/StoneIsland/platforms/ios/www/js/index.js @@ -1,37 +1,41 @@ var app = (function(){ - var app = {} + app.init = function(){ + app.archive = new ArchiveView () + app.hub = new HubView () + app.story = new StoryView () + + app.cart = new CartView () + + app.header = new HeaderView () + app.footer = new FooterView () + app.curtain = new CurtainView () + app.nav = new NavView () + + app.login = new LoginView () + app.intro = new IntroView () + + app.product = new ProductView () + app.collection = new CollectionView () + + app.selector = new Selector () + app.bind() } + app.bind = function(){ + if (window.location.href.match("8000")) { app.ready() } document.addEventListener('deviceready', app.ready, false) } + app.ready = function(){ - cookies.setItem("testing", "testing", 60*60*24*365) - console.log(document.cookie) - $.ajax({ - url: "http://lvh.me:5000/", - xhrFields: { - withCredentials: true - }, - success: function(){ - app.again() - } - }) - document.write("duh") - } - app.again = function(){ - $.ajax({ - url: "http://lvh.me:5000/", - xhrFields: { - withCredentials: true - }, - success: function(){ - } - }) + app.view = null + app.router = new SiteRouter () + app.router.route() } - app.init() - + return app })() + +app.init() diff --git a/StoneIsland/platforms/ios/www/js/vendor/cookie.js b/StoneIsland/platforms/ios/www/js/vendor/cookie.js deleted file mode 100644 index ad160ef1..00000000 --- a/StoneIsland/platforms/ios/www/js/vendor/cookie.js +++ /dev/null @@ -1,63 +0,0 @@ -/*\ -|*| -|*| :: cookies.js :: -|*| -|*| A complete cookies reader/writer framework with full unicode support. -|*| -|*| Revision #1 - September 4, 2014 -|*| -|*| https://developer.mozilla.org/en-US/docs/Web/API/document.cookie -|*| https://developer.mozilla.org/User:fusionchess -|*| -|*| This framework is released under the GNU Public License, version 3 or later. -|*| http://www.gnu.org/licenses/gpl-3.0-standalone.html -|*| -|*| Syntaxes: -|*| -|*| * docCookies.setItem(name, value[, end[, path[, domain[, secure]]]]) -|*| * docCookies.getItem(name) -|*| * docCookies.removeItem(name[, path[, domain]]) -|*| * docCookies.hasItem(name) -|*| * docCookies.keys() -|*| -\*/ - -var cookies = { - getItem: function (sKey) { - if (!sKey) { return null; } - return decodeURIComponent(document.cookie.replace(new RegExp("(?:(?:^|.*;)\\s*" + encodeURIComponent(sKey).replace(/[\-\.\+\*]/g, "\\$&") + "\\s*\\=\\s*([^;]*).*$)|^.*$"), "$1")) || null; - }, - setItem: function (sKey, sValue, vEnd, sPath, sDomain, bSecure) { - if (!sKey || /^(?:expires|max\-age|path|domain|secure)$/i.test(sKey)) { return false; } - var sExpires = ""; - if (vEnd) { - switch (vEnd.constructor) { - case Number: - sExpires = vEnd === Infinity ? "; expires=Fri, 31 Dec 9999 23:59:59 GMT" : "; max-age=" + vEnd; - break; - case String: - sExpires = "; expires=" + vEnd; - break; - case Date: - sExpires = "; expires=" + vEnd.toUTCString(); - break; - } - } - document.cookie = encodeURIComponent(sKey) + "=" + encodeURIComponent(sValue) + sExpires + (sDomain ? "; domain=" + sDomain : "") + (sPath ? "; path=" + sPath : "") + (bSecure ? "; secure" : ""); - return true; - }, - removeItem: function (sKey, sPath, sDomain) { - if (!this.hasItem(sKey)) { return false; } - document.cookie = encodeURIComponent(sKey) + "=; expires=Thu, 01 Jan 1970 00:00:00 GMT" + (sDomain ? "; domain=" + sDomain : "") + (sPath ? "; path=" + sPath : ""); - return true; - }, - hasItem: function (sKey) { - if (!sKey) { return false; } - return (new RegExp("(?:^|;\\s*)" + encodeURIComponent(sKey).replace(/[\-\.\+\*]/g, "\\$&") + "\\s*\\=")).test(document.cookie); - }, - keys: function () { - var aKeys = document.cookie.replace(/((?:^|\s*;)[^\=]+)(?=;|$)|^\s*|\s*(?:\=[^;]*)?(?:\1|$)/g, "").split(/\s*(?:\=[^;]*)?;\s*/); - for (var nLen = aKeys.length, nIdx = 0; nIdx < nLen; nIdx++) { aKeys[nIdx] = decodeURIComponent(aKeys[nIdx]); } - return aKeys; - } -}; \ No newline at end of file diff --git a/StoneIsland/platforms/ios/www/js/vendor/xhr.js b/StoneIsland/platforms/ios/www/js/vendor/xhr.js deleted file mode 100644 index 715d1c60..00000000 --- a/StoneIsland/platforms/ios/www/js/vendor/xhr.js +++ /dev/null @@ -1,35 +0,0 @@ -var XMLHTTPRequest = (function(){ - - var xhr = function (opt) { - this.status = 0 - this.readyState = 0 - this.response = "" - this.responseText = "" - this.responseType = "" // "" arraybuffer blob document json text - this.responseXML = "" - this.statusText = "" - this.timeout = 0 - this.onreadystatechange = function(){} - this.ontimeout = function(){} - this.onload = function(){} - this.headers = [] - this.upload = {} - this.withCredentials = false - } - xhr.prototype.open = function(method, url, async, user, password){ - } - xhr.prototype.abort = function(){ - } - xhr.prototype.getAllResponseHeaders = function(){ - } - xhr.prototype.getResponseHeader = function(){ - } - xhr.prototype.overrideMimeType = function(){ - } - xhr.prototype.setRequestHeader = function(key, value){ - this.headers.push({ key: key, value: value }) - } - xhr.prototype.send = function(data){ - } - -})() \ No newline at end of file -- cgit v1.2.3-70-g09d2