`$container` was not mounted when `show` called on mobile, likely
due to slower processing on mobile compared to web, so we ensure
$container is mounted to fix the `show` call having no effect.
This was due to reference being hidden by keyboard or scrolled
offscreen. We fix it by showing the dropdown even if the reference
is hidden for mobile devices.
This commit adds right padding, approximately equal to the
size of the sorting arrow, to the table headers which show
sorting arrows to make sure that arrows are visible clearly
at different font sizes and in different text languages.
We do not allow wrapping text randomly for user role values,
but since bot owner names can be long we do not want to do
that for bot owner column. So, this commit removes the
user_role class which is responsible for adding the required
CSS rule for role values.
This commit adds minimum width property for different columns
such that the columns do not get too small for narrow screens
and the tables can be scrolled horizontally to view the content.
There are some columns where the text is not user dependent
and we know how long the text can be like user role, bot type
and custom profile field type. In such cases, we can just avoid
wrapping the text randomly.
This commit removes width or min-width properties set for
different table columns so that the column width can adjust
themselves based on the text in different font sizes.
We still have the width property set on "actions" column
though to keep it at the right when a table has only 2/3
columns.
Further commits would be added to handle wrapping of
text in some columns and also to make sure that sort
arrows are visible correctly.
This commit adds "progressive-table-wrapper" class so that
the width property is correctly set and UI is correct for
narrow screens. Also, other properties added by that class
are fine.
This commit adds code to show only system groups in the dropdowns
for group permission settings in production for now. We continue
showing user defined groups for the settings that allow them in
development environment.
"can_mention_group" setting can be set to user defined groups
because some of the realms already do that in production.
information_density.initialize uses timerender.stringify_time, and
thus requires timerender.initialize to have been called first.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
Updates strings in the user invite modal to use invitation as the
noun/adjective in strings, instead of invite.
Also use "…" rather than three "." characters for ellipses.
To increase the number of options available for the user to pick from,
we increase the limit of options shown to 50 for all typeaheads, and
make the menu scrollable. The max height is set to original height of
the composebox typeahead menu, which fit 8 options or to 95% of the
window height, whichever is smaller.
Fixes: #20620.
On reactivate or deactivate, we add appropriate class through JQuery.
But that class only remains there until sort, on sort any of these added
classes will be removed. We did not face the problem of un-greying for
active users page, because deactivated_users class was added to the HTML
always if `is_active` was false for the user.
In this commit, we rename `reactivated_user` to `active-user` and this
class will be present for all active users, even on the active users
table. For the deactivated users table, we will have scoped css that
will grey out the row with `active-user` class.
Fixed#29894.
We were using `is_active` to determine whether to show that column or
not. In case of deactivated table, on reactivating a user, `is_active`
will become true for that user, but we still don't want to show that
column and mess up our layout. Same would happen in the active users
table when a user was deactivated and the `is_active` would become
false. It is better to control the column to be shown on a per-table
basis and we introduced `display_last_active_column` to control that.
Co-authored-by: shubham-padia <shubham@zulip.com>
We were trying scroll the highlighted element but it also scrolls
the parent elements leading to scrolling of the help doc.
We don't need to scroll here at all actually since focused element
is scrolled to be visible by default. Tested in chrome, firefox
and safari on mac.
Three events i.e. 'stream create', 'subscription add', and
'message' event are received by client on channel creation.
Earlier, we were narrowing to channel while processing the
'stream create' event. This was resulting in fetching messages
for that narrow even before adding subscription. This resulted
in a bug where "You subscribed to" bookend was visible in the
message feed after the "channel events" message.
This commit updates the logic to narrow ONLY after adding
subscription i.e. while processing "subscription add" event.
Note: A channel creator who is not going to subscribe to the
channel themselves is NOT narrowed to the channel view.
This fixes the incorrect behavior.
Fixes#30691.
We've removed the pencil icon and renamed the button to `Change your
password`. We've also removed the `.small` and `.btn-link` classes.
We also changed the `Password` label to use the `.settings-field-label`
class, same as the other labels for settings.
We removed the pencil icon, `.btn-link` and `.small` classes.
We also changed the `Email` label to use the `.settings-field-label`
class, same as the other labels for settings.
We've removed the pencil icon and removed the `.small` class from the
button.
This setting button is being used in two places: Changing your personal
language and changing the org-wide language for emails. That is why
we have used the `Change the language` generic tooltip instead of
`Change your language` tooltip.
`.change_password_button` and `#pw_change_link` were unused.
I've not checked for any other unused classes in this page, only
the password field. This was noticed when trying to make a layout
change for the password field and the change was moved to a preparatory
commit for the same.
This commit adds a link to the "Personal" tab of the channel settings
modal from the "Channel settings" link in the channel actions popover
when the user doesn't have the permission to change the channel
permissions.
Fixes#30529.
This enables the stream popover for spectators, by unhiding the triple
vertical dots button in the stream sidebar row.
In the spectators' version of the popover, we only show the
"Copy link to channel" option.
Fixes part of #30529.
Now that the channel name in the left sidebar links to the topmost
topic, we add a new menu option that lets us copy the channel feed link
to the clipboard.
Fixes part of #30529.
This commit reorganizes the channel actions popover to group related
actions together.
As noted by Alya Abbott in CZO, the logic behind the grouping is as
follows:
* The top section is things you might do as part of your workflow for
using Zulip.
* The second section is for managing the channel itself.
* "Change color" is kept independently in the last section because of
how the color picker takes over a big chunk of the menu when opened.
Fixes part of #30529.
There was a bug when updating stream privacy with message list
not narrowed to a stream as 'narrow_state.stream_sub().stream_id',
added in 933195f7a5, tried to access stream_id field even when
`narrow_state.stream_sub()` returned undefined.
Modified the `Select a channel below or change topic name.`
instruction in `move topics/move messages` modal.
It's not necessary and can be confusing when user does not
have permissions to change the channel and topic name.
1) On the `Move topic` modal, dropped the line
2) On the `Move messages` modal, replaced the
line with `Move messages to:`
Fixes#30055.
Previously, when enter was pressed in the move messages
modal, it used to trigger page reload because the enter
event of the modal was not handled.
This commit fixes it by adding the "form_id" field while
launching the dialog_widget.
Fixes#29655
As part of the popover menu redesign, this redesigns the compose send
options popover using the new "popover-menu" tippy theme and improves
accessibility by using appropriate ARIA attributes.
Fixes#25117.
As part of the popover menu redesign, this commit redesigns the user
group info popover using the new "popover-menu" tippy theme and improves
accessibility by using appropriate ARIA attributes.
Fixes part of #28699.
User circles indicating their presence are now synced across
all the places they appear, except for:
- navbar_personal_menu_popover - since the status
there will never change.
- typeahead_ist_item - because it is short-lived.
Fixes#30536
In 30d15d58fb, we made the
change to redirect to the newly created stream interleaved
view instead of "stream events" topic of that stream.
The comment related to it was not updated accordingly.
This commit updates the comment.
This commit separates the checking of whether the cursor is
at markdown link marker into its own function, which will be
used in #29136 to decide whether to format pasted urls or not.
This commit changes the width of tabs in stream and
group settings to be set as per the text inside it
with the previous width being set as minimum width
to avoid tabs being too small.
Fixes#30672.
This commit changes the width of tabs in bots panel
to be set as per the text inside it with the previous
width being set as minimum width to avoid tabs being
too small.
This commit updates the dropdown menu width to be set such that
the menu is wide enough to have options in a single line.
This change is only for group-based setting dropdowns in
organization, stream and group settigs.
Fixes#30673.
We now do not restrict the width of dropdown widget buttons
so that the width can be increased when the font size increases
and also if the option selected is long due to langauge.
We have similar behavior for the select element except that
the width of select element is set according to the longest
option while for dropdown widgets the button width is set
as per the current selected value.
This change is only for group-based setting dropdowns in
organization, stream and group settigs.
This commit hides invalid terms, since we don't want to be suggesting
invalid options to the user. We had already hidden invalid has and is
in the past, but this will also hide things like invalid channels or
user suggestions.
In the future it would be helpful to do two followups:
(1) Update the text for invalid is and has in search_description.hbs
since it looks a bit strange (though not introduced here). This
only shows up if you typed an invalid is/has and then start
typing a term beside it, so it's not very likely to happen.
(2) Don't auto-highlight the first typeahead result when there are
no valid suggestions for the last text term. This seems hard
to implement, so I'm leaving that out for now.
This supports adding users to DM pills by simply typing
a user's name in the text input directly after a complete
dm pill. It only works for DM pills at the end of search
input.
Clicking the X button removes a user from its user pill
container, and if that user was the last user left in the
container, then the whole container is also removed.
When the user has selected e.g. "dm:" from the typeahead, we want
to keep this as text, and let them type the search term in full
before it's pill-ified.
Most search suggestions are determined using the "last" search
input term, and the "rest" of the terms. Previously the "last"
term was whatever was at the end of the search query, and we
didn't differentiate between a completed term or an in-progress
term.
Now that there are search pills, we can differentiate between
completed and in-progress search terms, which clarifies some of
the search suggestion logic, and which we'll need to support
group pills and adding users to existing group pills.
Previously, search pill overflow was broken (sticking out of the
search box to the right) and now the search bar extends vertically to
allow pills to wrap when there are too many pills for one line.
There's still a bug when opening the search bar where the input
isn't selected. But I'm not worrying too much about that because
that text is about to be replaced with pills.
This is needed for us to support "search for..."
(i.e. operand = "search") terms being displayed
as text instead of search pills, once we convert
search to search pills.
This is useful for complicated typeaheads that have custom logic
for setting their element's contents after an item is selected.
Specifically, we're adding this to support a feature of search
pills, where selecting "Direct messages with" will add the text
"dm:" in the search bar and then trigger a lookup, and in
contrast selecting "Search for foo" will add "foo" in the search
bar and *not* trigger a lookup. In both cases, we won't want
to set the input element's text to the empty string, and we'll
want custom control over which situations to hide after select.
These two options make that possible.
See #26803 for more context on when this was introduced for
search pills, and this conversation on CZO for the conversation
that led to this decision:
https://chat.zulip.org/#narrow/stream/6-frontend/topic/search.20pills/near/1726228
- Make more succinct; don't over-describe UI the user can't see yet.
- Remove links (there are help links in view descriptions now).
- Explain where topics come from.
At widths under 400px, buttons in the popover were running off the edge,
which is fixed by removing the dividers between them.
For the new info density, buttons in the original row, even despite
removing the dividers, were still not fitting, so their width has been
slightly reduced.
Instead of showing ellipsis if the content of the tab switcher is
more than the width, we now allow it to take more width to show
full text.
If we don't have enough space to show the full text to show on
small screen sizes, we use ellipsis for overflowing text.
Increased sidebar width by 5px to accomodate full tab switcher
at both 14px and 16px font sizes.
These `background-color` and `cursor` rules are not needed here as the
`.dropdown-widget-button` base class already defines these properties
for `:disabled` pseudo-selector and there is no need to repeat here
again.
This is a follow up to previous commit
fe0a068ee5. We want
`.dropdown-widget-button` dropdowns to look same as `select` dropdowns.
This commit fixes opacity for all `.dropdown-widget-button`, which then
makes repetition in `settings.css` unnecessary.
This new section was added in ea2d92d934.
This bug caused settings in this section to not be disabled even when
the user lacked permissions to be able to change these settings.
The multiuse invites data from server does not include
notify_referrer_on_join fields since we do not allow
configure that for multiuse invites. This commit fixes
the zod schema accordingly.
Since we more space now in info overlay after recent width increase
and 40 / 60 split between columns, we have the space to show the
poll header at its normal font size of `18px` without making it wrap
to the next line at even medium width.