forked from dccxi/trust-zh-CN
-
Notifications
You must be signed in to change notification settings - Fork 0
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
Showing
15 changed files
with
452 additions
and
214 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 |
---|---|---|
|
@@ -5,11 +5,17 @@ | |
} | ||
|
||
body{ | ||
|
||
margin:0; | ||
overflow: hidden; | ||
|
||
background: #fff; /*url('[email protected]'); | ||
background-size: 100px 100px;*/ | ||
|
||
font-family: 'FuturaHandwritten'; | ||
color: #333; | ||
font-size: 20px; | ||
|
||
} | ||
#main{ | ||
width: 100%; | ||
|
@@ -30,7 +36,7 @@ body{ | |
#slideshow{ | ||
|
||
/*background: #bada55;*/ | ||
/*border: 1px solid rgba(0,0,0,0.2);*/ | ||
border: 1px solid rgba(0,0,0,0.2); | ||
width:960px; | ||
height:540px; | ||
|
||
|
@@ -55,15 +61,15 @@ body{ | |
|
||
/******** Text Box ********/ | ||
|
||
.textbox{ | ||
font-family: 'FuturaHandwritten'; | ||
color: #333; | ||
font-size: 20px; | ||
} | ||
.textbox{} | ||
.textbox > div{ | ||
position: absolute; | ||
} | ||
|
||
.label{ | ||
position: absolute; | ||
} | ||
|
||
/********* Button ********/ | ||
|
||
.button{ | ||
|
@@ -112,6 +118,33 @@ body{ | |
display: none; | ||
} | ||
|
||
|
||
/*************************/ | ||
/****** SANDBOX UI *******/ | ||
/*************************/ | ||
|
||
#sandbox_tabs{ | ||
position: absolute; | ||
left: 460px; top:-10px; | ||
background: url(../assets/sandbox_tabs.png); | ||
width:500px; height:470px; | ||
background-size: auto 100%; | ||
} | ||
#sandbox_tabs > div{ | ||
position: absolute; | ||
} | ||
#sandbox_tabs .hitbox{ | ||
cursor: pointer; | ||
font-size: 25px; | ||
top: 22px; | ||
} | ||
#sandbox_tabs .sandbox_page{ | ||
width: 433px; | ||
height: 385px; | ||
left: 33px; | ||
top: 80px; | ||
} | ||
|
||
/*************************/ | ||
/***** SLIDE SELECT ******/ | ||
/*************************/ | ||
|
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
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
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
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,53 @@ | ||
// a url (naming it a, because it will be reused to store callbacks) | ||
// e timeout error placeholder to avoid using var, not to be used | ||
// xhr placeholder to avoid using var, not to be used | ||
function pegasus(a, e, xhr) { | ||
xhr = new XMLHttpRequest(); | ||
|
||
// Set URL | ||
xhr.open('GET', a); | ||
|
||
// Don't need a to store URL anymore | ||
// Reuse it to store callbacks | ||
a = []; | ||
|
||
pegasus.timeout && (xhr.timeout = pegasus.timeout); | ||
|
||
xhr.ontimeout = function (event) { | ||
e = event | ||
} | ||
|
||
xhr.onreadystatechange = xhr.then = function(onSuccess, onError, cb, data) { | ||
// Test if onSuccess is a function | ||
// Means that the user called xhr.then | ||
if (onSuccess && onSuccess.call) { | ||
a = [,onSuccess, onError]; | ||
} | ||
|
||
// Test if there's a timeout error | ||
e && a[2] && a[2](e, xhr) | ||
|
||
// Test if request is complete | ||
if (xhr.readyState == 4) { | ||
// index will be: | ||
// 0 if undefined | ||
// 1 if status is between 200 and 399 | ||
// 2 if status is over | ||
cb = a[0|xhr.status / 200]; | ||
if (cb) { | ||
/*try { | ||
data = JSON.parse(xhr.responseText) // NICKY FIX -- don't be helpful | ||
} catch (e) {*/ | ||
data = null; | ||
//} | ||
cb(data, xhr); | ||
} | ||
} | ||
}; | ||
|
||
// Send the GET request | ||
xhr.send(); | ||
|
||
// Return request | ||
return xhr; | ||
} |
This file was deleted.
Oops, something went wrong.
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
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.