Commit Graph

53 Commits

Author SHA1 Message Date
Jessica McKellar 3f3b229578 HTML templates: Switch from Humbug to Zulip in user-visible text.
(imported from commit 07b4e92c270d3b7b0967ea5b6cf5821bf95d166a)
2013-07-15 17:41:52 -04:00
Scott Feeney 2c33320746 Reuse minified JS from previous deploys
This is a big change affecting lots of areas:

* Pipeline no longer deals with JS (though it still minifies CSS)
* A new script, tools/minify-js (called from update-prod-static),
  minifies JavaScripts
* A command-line argument --prev-deploy, if passed to minify-js or
  update-prod-static, is used to copy minified JS from a previous
  deploy (i.e., a previous git checkout), if the source files have
  not changed
* update-deployment passes --prev-deploy
* Scripts are now included with the minified_js template tag, rather
  than Pipeline's compressed_js

Also, as a side benefit of this commit, our Handlebars templates will
no longer be copied into prod-static/ and accessible in production.

Unminification is probably broken, but, per Zev and Trac ticket #1377,
it wasn't working perfectly before this change either.

(Based on code review, this commit has been revised to:
 * Warn if git returns an error in minify-js
 * Add missing output redirects in update-prod-static
 * Use DEPLOY_ROOT instead of manually constructing that directory
 * Use old style formatting)

(imported from commit e67722ea252756db8519d5c0bd6a421d59374185)
2013-07-12 11:59:04 -04:00
Zev Benjamin dd939ed7fe Disable the collection of metrics when not deployed
We were using up a lot of events in our dev environments.

(imported from commit 8413ecfa835cce0a231bdf437f37ad8cf12a9133)
2013-06-18 17:07:36 -04:00
Zev Benjamin aff42f0c73 Revert "Add a bunch of debugging support for mixpanel"
This reverts commit c5050f66d985eb76e38117b2668594fedfc10702.

(imported from commit ea1c92f73e8fd4ce2816e7af94b5d3a55edc8a7e)
2013-06-18 17:07:36 -04:00
Zev Benjamin 4cd194ec6a Minify our JS and CSS with third-party JS and CSS
(imported from commit e08d54c0ce09baff1f88db6b0c22386a556bc2df)
2013-05-30 13:51:47 -04:00
Keegan McAllister 52e0aa59a6 Minify third-party JavaScript and CSS in production
(imported from commit 943d712bc460640d7a689ac678922d9c5bf7aa9c)
2013-05-30 13:51:47 -04:00
Keegan McAllister 7d5f2cb2cd Switch away from CDN for jquery and jquery-validate
We're going to minify these together with everything else.

(imported from commit 929538ac119a82a0d96446a48da90c162a317417)
2013-05-30 13:51:46 -04:00
Zev Benjamin b565b2adc9 Add a bunch of debugging support for mixpanel
Currently, some browsers don't seem to be sending metrics information
to mixpanel.  This commit will make said browsers noisy, but should
help debug what's going on.

(imported from commit c5050f66d985eb76e38117b2668594fedfc10702)
2013-05-22 10:43:57 -04:00
Zev Benjamin 22e2eb3305 Use different mixpanel tokens while deployed vs in development
(imported from commit 4fac466a822d49cb0e1a7592dbd77d8ee019803e)
2013-05-21 17:56:49 -04:00
Zev Benjamin 55b29291c9 Add Mixpanel JS
(imported from commit 64c466902d757dd70b1501eb3253b94547c1299e)
2013-05-21 17:56:49 -04:00
Zev Benjamin b46bc6004f Load blueslip as early as possible
This will help us track down errors in third-party javascript
libraries.

blueslip needs jQuery and the page_params, so those must come first.

(imported from commit f53f67d758298d4e1c2784ec27e09d6abf0b3223)
2013-05-20 23:29:54 -04:00
Zev Benjamin 39bb10a24a Only load jquery.validate where we need it
(imported from commit 9c6bcb95932c70bf7a8b34733d9ffacab971f33c)
2013-05-20 23:29:54 -04:00
Zev Benjamin 7b3f5ed14c Add interface for creating and viewing bots
We really should not be storing bot API keys in the DOM and should
require some sort of additional authentication before showing them,
but this seems reasonable for a first pass.

(imported from commit c7d75aa52e21894bf53917457e771c18de38bbcc)
2013-05-11 02:38:32 -04:00
Waseem Daher 567d04d386 Remove Glyphicons third-party dependency.
(imported from commit 4f5f4e915370f3631c558f8fd7feefc79c357e50)
2013-05-09 10:35:47 -04:00
Waseem Daher aad262d041 fonts.css is included in our compressed CSS; no need to import separately.
(Actually, it 404s if you try.)

(imported from commit 5fc022693f6c76efaf468c80d547c605b4742452)
2013-04-22 10:00:02 -04:00
Allen Rabinovich e28cef697f Switched the star icon to FontAwesome and made it bigger and green.
* renamed the 'icon-star' style to 'icon-vector-star' to keep backwards compatibility for icon-* classes
  * changed relevant styles in zephyr.css; added FontAwesome assets
  * changed relevant CSS classes in base.html, left-sidebar.html, ui.js, message.handlebars
  * added new fonts.css to start consolidating all font-based assets
  * added fonts.css to PIPELINE_CSS in settings.py under 'portico' and 'app'
  * modified the stars test suite to reflect new star icon class name.

(imported from commit 3116fcfd4b5fb4edecd457da554fea616bb7081b)
2013-04-21 17:31:50 -07:00
Waseem Daher 3ce48f8a45 Make layout more responsive.
To be fully responsive, we can basically never specify the width of
our container in a fixed number of pixels; otherwise we'll run into
the situation where there's an inordinate amount of wasted space on
our left and right.

So everything needs to change from, e.g. row to row-fluid,
and that has a whole cascading series of changes that that implies.

(imported from commit 7e2771d916f429548c65c0a00fc4c11397054656)
2013-03-03 11:04:57 -05:00
Keegan McAllister 49e16b0ba6 Add portico and misc CSS and JS to Pipeline
Fixes #963.

(imported from commit 63ec313a41fd13350657c78356efc16422a5fff1)
2013-02-25 16:18:35 -05:00
Keegan McAllister 5e9b0ba79d [manual] Get rid of the static-access-control mechanism
We will minify our code, rather than trying to restrict who can see the
un-minified code.  Removing access control first simplifies things.

Manual deployment steps:

    scp servers/puppet/files/nginx/humbug-include/app root@staging.humbughq.com:/etc/nginx/humbug-include/
    ssh root@staging.humbughq.com service nginx reload

and then the same for app.humbughq.com once deployed to prod.

(imported from commit 63788aa3fa7ba5fd97fcf85b05760abb5e7cae4b)
2013-01-31 15:34:12 -05:00
Waseem Daher 3b891d2f74 Use Glyphicons font for gear icon, rather than image.
(imported from commit 46e2524ab0bcf4e52bd09525b45d15198a82da03)
2013-01-22 17:23:18 -05:00
Waseem Daher e0b8f4d3aa Make favicon have transparent background.
(imported from commit 841b1a21b2b4f01f298f0ceb099cf885f30d17b8)
2012-12-18 16:24:00 -05:00
Zev Benjamin 339ef0f139 Set the favicon a little more portably
http://en.wikipedia.org/wiki/Favicon claims this will work across all major browsers.

(imported from commit ab849cf3c0ac263fdff358c1ab77e079ccf90704)
2012-12-17 20:54:30 -05:00
Jeff Arnold d67e2cc4f3 Put the domain earlier in the titlebar, to help distinguish tabs
(imported from commit 225072a7cc044b011114a8630b02d74640b39d55)
2012-12-05 16:03:02 -05:00
Luke Faraone 1dbd806b6a Implement a favicon as a link rel.
This has the benefit of not getting cached forever by browsers.

(imported from commit c7c7877dfbb9d479e997d122827017036c5337f5)
2012-11-28 15:12:37 -05:00
Jeff Arnold 2f882b505a Show "how many messages have arrived while away" in the document title
(imported from commit 6e2a18be9953694048d107a56a03a67f8bc2bd5a)
2012-11-27 13:39:46 -05:00
Waseem Daher 5e321048b1 Put the realm in the <title> when you're logged in.
This resolves Trac #145.

(imported from commit 680c11ecb25e22201a1a335f97b014290aa25a06)
2012-11-20 21:15:26 -05:00
Keegan McAllister b81ef9cca7 Replace template variables static_{third,public} with hardcoded paths
So that the 500 error view will render properly, even though no variables are
set.  We keep the variable static_hidden, which by design is not used on the
500 page.

Fixes #240.

(imported from commit 3c7534f896479b7d7edbe5ef13958481e169a13c)
2012-10-31 18:43:44 -04:00
Keegan McAllister e93c1ab87c Switch from Open Sans to Droid Sans
We found a number of characters that look bad in Open Sans.

(imported from commit f8e7926f002b2de7f0d8bab255d212fac1cf6115)
2012-10-29 13:02:31 -04:00
Keegan McAllister 9de9d45623 Declare charset UTF-8
(imported from commit 61fa96565d7a1214c3944b7bb1f613a36697fc6b)
2012-10-22 14:18:50 -04:00
Keegan McAllister 235ce960b8 Use the obfuscated URLs
The key property is that we never reveal the non-public directory name
4nrjx8cwce2bka8r to a not-logged-in user.  This makes it less likely that
random people from the Internet will download all our client code while we're
still in private beta.

(imported from commit 7428e847e0a1a34152cb6dc2b677c1b47290c202)
2012-10-17 15:04:33 -04:00
Waseem Daher e6c1b2a4b7 Refactor things so that the 'viewport' meta tag properly gets set in the app.
(imported from commit f41cc0bfc586126e73d7c9f9817bee9723e3cc94)
2012-10-17 13:52:57 -04:00
Keegan McAllister dbd88b28f3 Document what all the Django templates are for
(imported from commit fa2b6c5327b0004f2c19502471f6717d84705ba7)
2012-10-16 01:33:15 -04:00
Keegan McAllister 66ed141dc1 Enable Django template autoescaping
This has been disabled since forever, but we've mostly been assuming it's
enabled.  Let's actually turn it on and see what breaks.

(imported from commit a194ba4b77b5290c31b46401d400bece68a33e6d)
2012-10-10 17:24:49 -04:00
Waseem Daher 6d37154a36 Better, but still not great, small-window behavior.
I'd like it to ultimately be the case that if you make the window
too narrow, the menubar goes to the very top and has small icons.

(imported from commit 0a5fe548d4d848c0358c9780df7af1fe1abc93fa)
2012-10-05 11:50:40 -04:00
Keegan McAllister 2ebd708a8d Remove client-side linkification
It causes problems when [un]narrowing, and we already do the rest of formatting
on the server side.

This reverts commit 90af0192b37bbebbf56d5e7c50f182485ddbca10.
This reverts commit df7e355648d2c4d6319de049933547ed96402fd8.

(imported from commit 99d87f0826ec2f49741f86fad6524ed93e76723f)
2012-10-04 16:52:08 -04:00
Luke Faraone ae6cfee818 Implement a new login redesign per Waseem. Be a little cute about it.
Split off some content previously placed into base back into index.html.
Move content previously localised in accounts_home to a new content_base
for use in the non-app version of the site.

We wrote up some copy and styled it according to taste.

In our new signup form, we no longer collect a short name and instead
extrapolate from the email.

(imported from commit cd734b13a4bda7f304129379524c4cc96b77b24b)
2012-09-26 16:42:10 -04:00
Jessica McKellar f60e9de1f2 Linkify URLs in zephyrs.
(imported from commit df7e355648d2c4d6319de049933547ed96402fd8)
2012-09-26 10:33:33 -04:00
Luke Faraone 5bbe023c23 Refactor index.html, move things to base.html.
In this commit we also remove the navbar from base.html for implementing
further changes as requested by Waseem.

(imported from commit 85a8ea82ff0e271120adde83e15eb671b5584722)
2012-09-24 11:40:09 -04:00
Tim Abbott ee8f28a084 Use email addresses as unique identifiers rather than usernames.
Note that this code still assumes one's email address (stripped of
domain) is unique.

(imported from commit e98f96601ad109811978fc00b1165e97d8f7b185)
2012-09-21 09:43:22 -04:00
Keegan McAllister 8f1cee0b88 Move third-party components into static/third/
(imported from commit 709c78a6e41afcd4202a8264c9103ac7827158ec)
2012-09-06 15:48:15 -04:00
Keegan McAllister b1eb0fd0fd Inhibit caching of zephyr.css
(imported from commit 5e1af66b12454f791f7edfcc3f01be03b00e4b2f)
2012-09-06 14:54:10 -04:00
Keegan McAllister 4dd1567426 Keep third-party jQuery style in the jquery dir
(imported from commit 9e34277b90c13b3ce71521fe0657014f186fc1c3)
2012-09-06 11:00:34 -04:00
Luke Faraone 974b560659 Add autocomplete for personals, classes, and instances.
Here we pull in the jqueryui library and a style sheet to provide a widget
to do autocomplete for various fields. We populate a list of all ever-seen
classes, instances, and people (C/I/P) into JS arrays and then pass them to
jqueryui.

Each time a new C/I/P appears, we reinitialise the autocomplete functions
so they will notice the new data.

(imported from commit f1ab69c99d21f68ccf40c015bd43960f463c6ff2)
2012-09-04 16:14:48 -04:00
Keegan McAllister 053122c3d1 Drop the responsive navbar
(imported from commit 9ccf5a2f43242f35e510adab58ac6ca4715bceec)
2012-08-29 15:40:10 -04:00
Keegan McAllister a2777eaed4 Resize main_div to exactly take up remaining vertical space
Unfortunately, it's not so easy to do this with CSS only.

(imported from commit 93b58a53e20aae9ee651aa66b3163f68549a3982)
2012-08-29 15:40:09 -04:00
Keegan McAllister 3ef5334d9b Focus username field on loading login/register pages
(imported from commit 004a98ffaa59aebab34057cbe34f5e1038e44b62)
2012-08-29 15:16:28 -04:00
Keegan McAllister 473de4eb2a New layout
(imported from commit d44db3acf1d4c6a7b42a54aff9720bb86d01a754)
2012-08-28 19:09:48 -04:00
Keegan McAllister 9849cc91e9 Move bootstrap.js and jQuery into head
(imported from commit 8deddd6178f5612be275509bea0a23d20fb4693c)
2012-08-28 18:36:55 -04:00
Keegan McAllister 54622c9101 Create zephyr.css
(imported from commit 56c698496ba5cc59aeed4902dfee7bcfa248ffcf)
2012-08-28 18:36:55 -04:00
Keegan McAllister f88882f9a2 Basic Bootstrapification
(imported from commit 54871fadcb5670a1ed3a68156b282bde1b50363f)
2012-08-28 18:36:55 -04:00