In 61b3c698af we stopped restoring widgets
from the cache, so the only purpose of the cache remaining was to access
the event handler patched onto the widget jquery.
Now instead of the entire jquery object, we cache just the event handler
since that's the only thing we need from the cache, and do not patch it
onto the widget jquery object.
Use the "/json/messages/flags" instead of "/json/messages/flags/narrow"
when we have fully fetched the current view.
Update messages on the basis of id instead of updating the entire
narrow.
Fixes#28945.
Since the reference for these typeaheads is has a fixed position
unlike say message controls which move on scroll and need to be
repositioned, we can use `fixed` position for typeaheads too so
there is no jumps when user is trying to scroll when a typeahead
is active.
This basically replaces the commit where where we remove `fixed`
as an argument to `Typeahead` library. We can add it later if
any of our typeaheads don't need to be fixed positioned.
When compose box is expanded, typeahead overlfows the top of the window.
We move the typeahead to the bottom of the screen and let
preventOverflow shift it into the visible area.
To better make use of server load when fetching message history for
users, we limit how much history we fetch in the initial loading
experience based on how much time in the organization's message
history it corresponds to.
Co-authored-by: Tim Abbott <tabbott@zulip.com>
For more discoverability, the keyboard shortcuts for preview, and bold,
italic and link formatting are now displayed in the tooltips of those
compose buttons.
Earlier we did not activate widgets if their rendered HTML was cached,
and also when narrowing to the combined feed view. This caused bugs with
widgets not being activated, and so not responding to any interactions.
Now we unconditionally render and activate widgets in the current view,
irrespective of the cached HTML or the view being narrowed to.
`source` is expecting a list so `false` doesn't make sense here.
It was working before because the code that calls `source` in
`bootstrap_typeahead` just does falsey checks.
This commit replaces the fontawesome "edit" and "copy-link" icon found
in the user profile modal with the corresponding zulip icons.
It also moves the functional classes like
user-profile-manage-own-copy-link-button from the icon element to its
container, including adding a new div wrapping the icon in
user-profile-manage-others-edit-button.
Attempting to convert .data("draft-id") to .attr mysteriously breaks
draft saving, so I’ll leave that for future work.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
e.target is the wrong element, and even if this were to successfully
add the _full-height-no-scroll class to <body>, that’s not a child of
.portico-hello-page.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
Its selector looks like it’s missing a ‘.’, but “fixing” it breaks the
page even more, and trying to decipher this mess of event handlers
that poorly replicate what should be native behavior is making my
brain hurt.
Signed-off-by: Anders Kaseorg <anders@zulip.com>