Commit Graph

7671 Commits

Author SHA1 Message Date
Jessica McKellar b66bccb068 Make the more 'topics link' a bit more muted.
(imported from commit a2c01af9ed5e993209b3be538bf303acb5428bbd)
2013-11-27 18:34:21 -05:00
acrefoot eb7be522ac [manual] add supervisor and numconsumer entries for push notifications queue
requires puppet-apply on both staging and prod

(imported from commit 6fc25041b40145d7c62a8bb959a8d25d0dbcb44e)
2013-11-27 18:00:33 -05:00
acrefoot 717e06d94c remove log message on push notification
(imported from commit 45fc89e67a79aac3484c911d88aff3e470b4eff6)
2013-11-27 18:00:33 -05:00
acrefoot 8800dcdce4 more helpful error message when missing APNS certs
(imported from commit e21dc627844b9e28f93a924097176481d4135947)
2013-11-27 18:00:33 -05:00
acrefoot 8ee7536012 Send push notifications more aggresively
Unbundle the push notifications from the missed message queue processors
and handlers. This makes notifications more immediate, and sets things up
for better badge count handling, and possibly per-stream filtering.

(imported from commit 11840301751b0bbcb3a99848ff9868d9023b665b)
2013-11-27 18:00:31 -05:00
Steve Howell bbda1d93c4 Add test for message.handlebars
(imported from commit b02f0c8a6b1d79c868248598e8b9a829245d95a1)
2013-11-27 16:11:16 -05:00
Steve Howell 6a3089a803 [jquery] Add assertion to validate HTML is correct.
This requires the nodes.js version of jquery.  Talk to Luke if you are having issues
installing it.

(imported from commit 86dc91a9a41b2ef9c2dbcc4fb0085109250d7af7)
2013-11-27 15:09:21 -05:00
Steve Howell 4f2b292289 Add HTML output file for JS unit tests.
The node tests can write to .test-js-with-node.html now, so that
when you are unit-testing template-related code, you can use
the browser to inspect the output.

(imported from commit 3cbd7470ec0da1973124f79acb665c3a3e17c580)
2013-11-27 15:09:21 -05:00
Steve Howell c53845a69c Add unit tests for stream_list.
(imported from commit 1d04a2e6115f29b7949466260ec2ba3126b882e6)
2013-11-27 15:09:20 -05:00
Jessica McKellar 3459962e69 API release 0.2.3.
(imported from commit 80591f61785b492b2ec8897bb2a2e5eff8e089fc)
2013-11-27 13:15:21 -05:00
Tim Abbott 53059bb10c Fix lint issues with recent pointer bug fix.
(imported from commit d2a9725e8449609fdd29d2c727730934eb4de763)
2013-11-27 10:58:13 -05:00
Jeff Arnold 56fb3dd877 When closing the compose box, hide it first for perceived speed
(imported from commit 598585365141681a5573ad4fe9905be34ac92dd6)
2013-11-27 10:45:22 -05:00
Jeff Arnold 22d0ee55f6 autosize_textarea() is slow, so avoid it while the user is waiting
We need to resize the textarea when it is changed via .val().  By
clearing and resizing the compose box when it is closed, we can
avoid calling autosize_textarea() when the user opens the compose box.

This saves at least 15ms on every compose and might also be a cause
of longer delays.

(imported from commit fe6e092efcd1c4b95a868ee66653448f99af84c0)
2013-11-27 10:45:22 -05:00
Jeff Arnold 3a41184533 Revert "Make c/C compose to a new destination instead of being identical to r/R"
This reverts commit 755c92aed79ab79089b2e35d2c100582f012736a.

(imported from commit b7790fc63a2cea0a8e294c3f0a881ed6f06ed061)
2013-11-27 10:43:10 -05:00
Zev Benjamin 9d0f801ad6 Exempt a particular client name from heartbeats for testing
(imported from commit 3914130384a7a9854b006405ffd2fe379bbd090d)
2013-11-27 10:39:31 -05:00
Jeff Arnold c0a8fc459a Make c/C compose to a new destination instead of being identical to r/R
R means "I want to send a PM, you can guess the destination"
r means "I want send a stream message, you can guess the destination"
C means "I want to send a PM and specify the destination"
c means "I want to send a stream message and specify the destination"

(imported from commit 755c92aed79ab79089b2e35d2c100582f012736a)
2013-11-27 10:35:37 -05:00
Tim Abbott 09481aab69 Don't throw blueslip errors when trying to scroll to a negative offset.
(imported from commit 1edd0ced20016f817e0380c4fc341ca44cc51426)
2013-11-27 10:17:55 -05:00
Tim Abbott 3d9ad287fa Fix weird scrolling bug in Chrome on OSX.
We encountered a strange bug in Chrome on OSX where the initial call
to set scrollTop when the browser window loads did not do anything,
until we first scrolled to some other location on the page.  This
patch "fixes" that by automatically scrolling somewhere else before
scrolling to the target place on the page.

(imported from commit 96be6a0016e9e5fd78380613c9587f38406604df)
2013-11-27 10:12:27 -05:00
Jessica McKellar 4563271a1b email unsubscribes: have a "display name" for email unsubscribe types.
(imported from commit 24f2db0ac3e26bca410b719dead724c6cef49a3f)
2013-11-27 09:30:00 -05:00
Jessica McKellar 848c9ec7be Add a test for unsubscribing from welcome emails.
(imported from commit c206bd9283e6be22b285abd583c6e80719260448)
2013-11-27 09:30:00 -05:00
Jessica McKellar 2ba9415178 Factor welcome e-mail enqueuing into its own function.
(imported from commit 85054ee3e567d2ba7a4ed94c52a311d02f5e4d43)
2013-11-27 09:30:00 -05:00
Jessica McKellar 8e72084fcb Add one-click unsubscribe links to day 1 and day 2 emails.
(imported from commit 9396f96365430baf894c708f9eaea642fc648435)
2013-11-27 09:29:59 -05:00
Zev Benjamin 8899c62567 Add comment in ClientDescriptor.to_dict and EventQueue.to_dict to avoid future bugs
(imported from commit 45560539d09e9e1922130349be729005b786e632)
2013-11-26 18:39:31 -05:00
Zev Benjamin ce00fe0cd5 Fix loading event queues that don't have a virtual_events attribute
(imported from commit 99c5ae332d253313ed728883a388c61191ed3021)
2013-11-26 18:32:58 -05:00
Steve Howell eb9f7a04b7 Rewrite topic zoom to fix bugs and make cleaner.
In the first cut at topic zoom, I was re-rendering the
streams list, but this created glitches with orphaned
list items.  The reproducible bug was that unread counts
on unshown streams weren't updating.

In the new approach, I keep the elements more permanent, and
I just hide and show them as needed, either through jQuery
show/hide or permanent CSS selectors.

I got rid of toggle_zoom(), so that we just explicitly zoom
in and zoom out in all situations.  In particular, when we
narrow, it's more clear now that only stay zoomed in when
we're narrowing to the same stream as before (including topic
narrows within that stream).

When you zoom in, the number of topics is no longer limited
to 30, since that was kind of arbitrary anyway.  (In practice,
the number of topics is usually well under 30, anyway, due to
the way we track them on the client.)

(imported from commit 5b6c143dee9ba9fe557d8cc36335ff28efb4b0de)
2013-11-26 18:19:49 -05:00
Steve Howell 90bb398784 Revert "[staging] Double-clicking on stream row toggles its zoom level."
This reverts commit 6fdb3cacd68635f313f2a8a81edf2d6101cce2cb.

(imported from commit 6e95bd8caa1b7e327f91a8b7aded72b787d1420a)
2013-11-26 18:19:48 -05:00
Tim Abbott e9f4612281 Upgrade event flag collapsing to support all flag changes.
(imported from commit dadf3852f2ca7aaa85fb97b3d265c990b4e5a38a)
2013-11-26 18:12:52 -05:00
Tim Abbott fb5c42707e event: Add deduplication of server restart events.
(imported from commit 05467929ba376a0ce173119c5d90d83671fc544b)
2013-11-26 18:12:52 -05:00
Tim Abbott 5a4df81202 Add tests for our event queues data structure.
(imported from commit 5be116d6cc983edaac240e83d1b950faa08d164c)
2013-11-26 18:12:52 -05:00
Tim Abbott 1db8fba5aa events: Add support for not storing redundant events.
This should dramatically improve the speed of the dump/load part of
our restart process, especially with large long-lived event queues.

(imported from commit cc493fa50b4c339257e060b3f0c0956c682e449d)
2013-11-26 18:12:52 -05:00
Leo Franchi afa2cc25d1 Remove OS X Snow Leopard note, 0.4.0 supports 10.6 as well
(imported from commit 9471823ff1c4e03f633b382c1b5803f781ece898)
2013-11-26 17:41:26 -05:00
Leo Franchi d36510e4c3 [manual] Release Zulip Desktop 0.4.0
This requires a puppet apply, and also a manual update of
the Zulip-latest.* symlinks in /srv/www/dist/apps

(imported from commit 991dd6924ba33d81f486e914bcbadfec5b350660)
2013-11-26 17:41:25 -05:00
Waseem Daher c1358ac9d4 Add a little more breathing room around code blocks.
Reported to us by one of our users - prior to this change, code blocks
get sort of cut off by our "selected message" highlight.

(imported from commit 395ae41baca12ea55bc39048b4291e29f78a8db5)
2013-11-26 14:06:33 -05:00
Waseem Daher 24978224a3 Use ``` instead of ~~~ in our Markdown documentation.
(imported from commit 7e5045ea9b809973ba5c47bf41139ec0ce66695e)
2013-11-26 14:06:32 -05:00
Luke Faraone 1202cacffd setup.cfg to run install_data on API install
Previously, users of setuptools would get our data embedded in eggs.
Eggs are horrible things, but more importantly our package data should
be free, in a well-known albeit system-dependant path that is
independent of the package.

By specifying [install_data][1] as an alias of install, we assure that
our data (examples, integrations, etc) are placed in $data/share as
$DEITY intended.

Alternative suggestions included force-adding "--old-and-unmanageable",
which would invoke the distutils-style install command, but that had the
unfortunate side effect of turning off eggs and dependency resolution
altogether.

We could also use "--single-version-externally-managed", but I think
that was designed to be used by package managers, not by us.

In any case, both of the above were fragile and might break if the user
specified additional options to setup.py.

In closing, Python module management is horrible. See [this][2],
[this][3], and [this][4] for info about the status quo, and [this][5]
for information about crack to be smoked later down the road. Don't even
get me started about [PEP 427 -- Python wheels][6].

[1]: http://docs.python.org/2/distutils/commandref.html#install-data
[2]: http://lucumr.pocoo.org/2012/6/22/hate-hate-hate-everywhere/
[3]: http://stackoverflow.com/a/6522905/90777
[4]: http://python-notes.boredomandlaziness.org/en/latest/pep_ideas/core_packaging_api.html
[5]: https://python-packaging-user-guide.readthedocs.org/en/latest/future.html
[6]: http://www.python.org/dev/peps/pep-0427/

(imported from commit 6cf1bd2b8f5a60b2f02f5d11094e4a41cc5e48aa)
2013-11-26 13:26:31 -05:00
Tim Abbott 3971f18de8 loadbalancer: Fix missing location-sockjs config.
(imported from commit 27b168e73014d7b7c71fb00ce5b75271393fc491)
2013-11-26 12:22:17 -05:00
Steve Howell c710a54a99 Avoid flicker when narrowing to non-stream view.
(imported from commit a69fd4fe582d56e89990f97a3d3099ea1225315c)
2013-11-26 11:09:38 -05:00
Steve Howell b3e0c93ca6 Zoom out topics when going to Home view.
(imported from commit 04c5ae70d28bd3b41f2311d22f80f95c458f06a2)
2013-11-26 11:09:37 -05:00
Tim Abbott b7d13d542c Cleanup our logging paths.
(imported from commit 2f72ee8e320a501b2e011784c005951ca341102d)
2013-11-26 10:46:25 -05:00
Leo Franchi 501f063426 Replace email_to_domain with split_email_to_domain and resolve_email_to_domain
Now that we support email aliases, we have to be careful when going from
an email address to a domain that we assume we can use to get a Realm
object for. When we care about the Realm's domain, we want to follow
any RealmAliases that exist for a certain domain.

When we just care about the original email address domain itself,
for comparison or other purposes, use split_email_from_domain

This removes the ambiguity of having to decide when to use
email_to_domain + RealmAlias or just email_to_domain

(imported from commit 0e199495502d946ce2e1aae56263e7e8665be4ed)
2013-11-26 10:45:01 -05:00
Steve Howell 78e936fc36 [staging] Add "Show more topics..." link to topic lists.
This link lets you zoom in to more topics.  We only show it if
there are topics that we had to hide to respect the max-5 limit
along with other rules of when you show topics.

This is feature flagged to staging only.

(imported from commit 9915004ec2eb3df7416fe45c0e60cebcd7fecfea)
2013-11-26 10:34:09 -05:00
Steve Howell 41eded47d2 Add link to show all streams when you are zoomed in.
When your left sidebar is zoomed to show just one stream,
there is a link to to show all streams again.

(imported from commit 92f39b042168c443cbb9f524bf892557ef492551)
2013-11-26 10:34:09 -05:00
Steve Howell fd9d48f6df [staging] Double-clicking on stream row toggles its zoom level.
If you double-click on a stream that you've narrowed to, it
will either zoom in or zoom out the left sidebar view.  Zooming
in shows just that stream; zooming out shows all streams.

This is feature flagged to staging only.

(imported from commit 6fdb3cacd68635f313f2a8a81edf2d6101cce2cb)
2013-11-26 10:34:09 -05:00
Steve Howell 44f575c812 Add topic-zooming hooks.
This commit doesn't actually add the final UI to zoom/unzoom
topics, because I want to keep those in separate commits, in
case we change how to enable the feature.  But this commit
adds a toggle_zoom() function that zooms/unzooms topics.

Zooming is minimally invasive, because we don't really introduce
many extra elements to the UI; instead, we just make the list of
streams be a list of length one (i.e. the active stream).  This
gives us a lot of stuff for free, basically, like unread counts, etc.

(imported from commit 814c1361b6210d1591b4174bed1d6e0c98a3f255)
2013-11-26 10:34:08 -05:00
Steve Howell 1080b4239d Move sidebar click handlers into stream_list.js.
(imported from commit b284508b3abd2edc3fa4edf432307eee8f034b58)
2013-11-26 10:34:08 -05:00
Steve Howell 60a8e6e769 Make sure click handlers are called from sidebar menu.
This is a subtle change, to make sure that list items
from stream_filters always go through click handlers, which
ensures, e.g., consistent behavior on opening the compose box.

(imported from commit cd734901def8959c8c8a29c164c7a60730ae0915)
2013-11-26 10:34:08 -05:00
Steve Howell d39141039b Remove dead code related to streamlist_expand class.
(imported from commit b4dd57fdd77b74f9fe570b2267a6f96ec12937d6)
2013-11-26 10:34:08 -05:00
Tim Abbott 9cd2dca9a5 Remove some fields from the footer for Zulip Enterprise.
(imported from commit 30b41eb1bb09ad0fb8d0ae6ab5b08c63b99f5524)
2013-11-25 20:29:27 -05:00
Luke Faraone 567c821cc0 Define empty AUTH_LDAP_SERVER_URI so it exists when we later do a check on it
(imported from commit 959ea2efde99f84c971ff1cd5947e3042d64ea96)
2013-11-25 19:14:36 -05:00
Luke Faraone a424281c89 Make LDAP propagation conditional on AUTH_LDAP_SERVER_URI not AUTH_LDAP_BIND_DN
Many deployments will not set AUTH_LDAP_BIND_DN , because they allow
anonymous binding. It is better for us to use AUTH_LDAP_SERVER_URI as a
signal for whether to use LDAP, since any deployment that uses LDAP will
set that local setting.

(imported from commit ad70bedfb572b42a9df954819593e2678729647b)
2013-11-25 19:12:51 -05:00