Skip to content

Commit 4f91b1a

Browse files
committed
Modify Twitter's source to work for COS
1 parent 7731130 commit 4f91b1a

File tree

3 files changed

+17
-60
lines changed

3 files changed

+17
-60
lines changed

assets/logo.png

9.73 KB
Loading

assets/style.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ a:hover {
6969
width: 190px;
7070
height: 64px;
7171
margin: 15px 0 0 15px;
72-
background: url("logo.png");
72+
background: url("logo.png") center no-repeat;
7373
text-indent: -99999px;
7474
}
7575

index.html

Lines changed: 16 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22

33
<html>
44
<head>
5-
<title>Twitter &hearts; Open Source</title>
5+
<title>Center for Open Science: Exclusively Open Source</title>
66
<link rel="stylesheet" type="text/css" href="assets/reset.css">
77
<link rel="stylesheet" type="text/css" href="assets/grid.css">
88
<link rel="stylesheet" type="text/css" href="assets/style.css">
9-
<link href="//abs.twimg.com/favicons/favicon.ico" rel="shortcut icon" type="image/x-icon">
9+
<link href="https://osf.io/favicon.ico" rel="shortcut icon" type="image/x-icon">
1010
<script type="text/javascript">
1111

1212
var _gaq = _gaq || [];
13-
_gaq.push(['_setAccount', 'UA-39101739-1']);
13+
_gaq.push(['_setAccount', 'UA-63714248-1']);
1414
_gaq.push(['_trackPageview']);
1515

1616
(function() {
@@ -27,9 +27,9 @@
2727

2828
// Put custom repo URL's in this object, keyed by repo name.
2929
var repoUrls = {
30-
"bootstrap": "http://twitter.github.com/bootstrap/",
31-
"finagle": "http://twitter.github.com/finagle/",
32-
"hogan.js": "http://twitter.github.com/hogan.js/"
30+
// "bootstrap": "http://twitter.github.com/bootstrap/",
31+
// "finagle": "http://twitter.github.com/finagle/",
32+
// "hogan.js": "http://twitter.github.com/hogan.js/"
3333
};
3434

3535
function repoUrl(repo) {
@@ -38,8 +38,8 @@
3838

3939
// Put custom repo descriptions in this object, keyed by repo name.
4040
var repoDescriptions = {
41-
"bootstrap": "An HTML, CSS, and JS toolkit designed to kickstart development of webapps and sites",
42-
"naggati2": "A protocol builder for Netty using Scala 2.8"
41+
// "bootstrap": "An HTML, CSS, and JS toolkit designed to kickstart development of webapps and sites",
42+
// "naggati2": "A protocol builder for Netty using Scala 2.8"
4343
};
4444

4545
function repoDescription(repo) {
@@ -81,7 +81,7 @@
8181
repos = repos || [];
8282
page = page || 1;
8383

84-
var uri = "https://api.github.com/orgs/twitter/repos?callback=?"
84+
var uri = "https://api.github.com/orgs/centerforopenscience/repos?callback=?"
8585
+ "&per_page=100"
8686
+ "&page="+page;
8787

@@ -141,7 +141,7 @@
141141
function getNumMembers(page, numMembers) {
142142
var page = page || 1;
143143
var numMembers = numMembers || 0;
144-
var membersUri = "https://api.github.com/orgs/twitter/members?callback=?"
144+
var membersUri = "https://api.github.com/orgs/centerforopenscience/members?callback=?"
145145
+ "&per_page=100"
146146
+ "&page="+page;
147147

@@ -192,46 +192,6 @@
192192
return opacity;
193193
}
194194

195-
function makeLarry(sizeName, speed) {
196-
var size = sizeDimensions[sizeName];
197-
var top = Math.floor((flyzone().height() - size) * Math.random());
198-
199-
var $img = $("<img>")
200-
.addClass("larry size-" + sizeName)
201-
.attr("src", "assets/larry.png")
202-
.attr("width", size)
203-
.attr("height", size)
204-
.css({
205-
position: "absolute",
206-
opacity: randomOpacity(0.4),
207-
top: top,
208-
left: -size
209-
});
210-
211-
$img.prependTo(flyzone());
212-
213-
var left = flyzone().width() + size;
214-
215-
$img.animate({left: left}, speed, function () {
216-
$img.remove();
217-
makeRandomLarry();
218-
});
219-
220-
return $img;
221-
}
222-
223-
function makeRandomLarry() {
224-
var size = randomItem(sizes);
225-
var speed = Math.floor(Math.random() * 20000) + 15000;
226-
return makeLarry(size, speed);
227-
}
228-
229-
$(function () {
230-
$("#logo").click(function () {
231-
makeRandomLarry();
232-
});
233-
});
234-
235195
var match = (/\blarry(=(\d+))?\b/i).exec(window.location.search);
236196

237197
if (match) {
@@ -249,26 +209,23 @@
249209
<body>
250210
<div id="wrapper" class="grid clearfix">
251211
<div id="main" class="grid-1">
252-
<div id="logo"><h1>Twitter Open Source</h1></div>
253-
<h1>Twitter is built on open source software.</h1>
254-
<p>Want to help? <a href="https://twitter.com/jobs">Join the Flock</a></p>
255-
<p>Visit <a href="https://dev.twitter.com/">dev.twitter.com</a></p>
256-
<p><a href="https://twitter.com/about/resources">Logos and other goodies</a></p>
212+
<div id="logo"><h1>COS Open Source</h1></div>
213+
<h1>We like our software like our science. Open.</h1>
214+
<p>Want to help? <a href="https://cos.io/jobs">We're hiring.</a></p>
257215
</div>
258216

259217
<div class="grid grid-3">
260218
<div id="statistics" class="grid-1 alpha header">
261219
<h1>Statistics</h1>
262220
<p>
263-
<a href="https://github.com/twitter/repositories"><span id="num-repos"><img src="assets/spinner.gif" /></span> public repos</a>
221+
<a href="https://github.com/centerforopenscience/repositories"><span id="num-repos"><img src="assets/spinner.gif" /></span> public repos</a>
264222
<br>
265-
<a href="https://github.com/twitter?tab=members"><span id="num-members"><img src="assets/spinner.gif" /></span> members</a>
223+
<a href="https://github.com/centerforopenscience?tab=members"><span id="num-members"><img src="assets/spinner.gif" /></span> members</a>
266224
</p>
267-
<p class="email"><a href="mailto:[email protected]">[email protected]</a></p>
268225
</div>
269226

270227
<div id="recently-updated" class="grid-2 omega header">
271-
<h1>Recently updated <a href="https://github.com/twitter/repositories">View All on GitHub</a></h1>
228+
<h1>Recently updated <a href="https://github.com/centerforopenscience/repositories">View All on GitHub</a></h1>
272229
<ol id="recently-updated-repos"></ol>
273230
</div>
274231
</div>

0 commit comments

Comments
 (0)