Commit Graph

52273 Commits

Author SHA1 Message Date
Lauryn Menard 0d16683c5f rendered-markdown: Update reference to "private message" in comment.
Updates a code comment to use "direct message" instead of "private
message".
2023-06-27 11:03:17 -07:00
Karl Stolley 0b596159c1 docs: Adjust wording and phrasing for clarity. 2023-06-27 09:43:22 -05:00
Karl Stolley 2720e0e35a docs: Correct minor wording and mechanics. 2023-06-27 09:43:22 -05:00
Lauryn Menard e1c809a71e api-docs: Clarify what topics are returned by `get-stream-topics`.
Updates the main description for the `get-stream-topics` endpoint
so that it is clear that the topics for private streams with protected
history are limited to the topics / messages the user has access to.

And updates that documentation and the help center documentation for
bot permissions / abilities, to clarify that bots have the same
restriction and can only access messages / topics that are sent after
the bot (not the bot's owner) subscribed to the stream.
2023-06-26 20:26:30 -07:00
Satyam Bansal 92a1e3464d
integrations: Allow null pull request review body in GitHub Integration.
There are instances in which the pull request review body
can be null.

Fixes #26055.
2023-06-26 11:35:14 -07:00
Evy Kassirer adcf088740
filter: Rename describe to search_description_as_html.
Changing this since wobbly naming on HTML variables is dangerous.
2023-06-26 11:11:17 -07:00
Matthew Volpe 466db56118
docs: Fix missing space in setup-recommended.md.
Previously, there was a missing space in setup-recommended.md that I noticed when reading it.
2023-06-26 11:10:29 -07:00
Lauryn Menard c8b04fc562 web-shared: Update references to "private message" and "PM".
Updates any use of "private message" and "PM" in the `web/shared`
directory to instead use "direct messages".
2023-06-26 11:07:28 -07:00
Lauryn Menard 85096cfb4d web-styles: Update references to "private message" and "PM".
Updates any use of "private message" and "PM" in the `web/styles`
directory to instead use "direct messages".
2023-06-26 11:07:28 -07:00
Lauryn Menard 73e5812831 node-tests: Update references to "private message" and "PM".
Updates any use of "private message" and "PM" in the `web/tests`
directory to instead use "direct messages".
2023-06-26 11:07:28 -07:00
Lauryn Menard 7c47616ffa web-e2e-tests: Update references to "private message" and "PM".
Updates any use of "private message" and "PM" in the `web/e2e-tests`
directory to instead use "direct messages" or "DM".
2023-06-26 11:07:28 -07:00
Lauryn Menard 4d3d9bcefa web-src: Update comments with "private message" or "PM".
Updates comments in files the `web/src` directory to use "direct
message" instead of "private message" or "PM".
2023-06-26 11:07:28 -07:00
Lauryn Menard 5be0f80135 recent-topics-ui: Rename constant for direct message columns.
Renames constant for the number of direct message columms from
`MAX_SELECTABLE_PM_COLS` to `MAX_SELECTABLE_DIRECT_MESSAGE_COLS`.
2023-06-26 11:07:28 -07:00
Lauryn Menard 842623c294 unread: Update class name for unread direct message counter.
Renames the class name in `web/src/unread.js` from `UnreadPMCounter`
to `UnreadDirectMessageCounter` and renames the associated instance
of `unread_pm_counter` to `unread_direct_message_counter`.
2023-06-26 11:07:28 -07:00
Lauryn Menard 4b2b278a53 dm-conversations: Update direct message data structure name.
Updates data structure class name in `web/src/pm_conversations.js`
from `RecentPrivateMessages` to `RecentDirectMessages`.
2023-06-26 11:07:28 -07:00
Lauryn Menard 3c6d283aa9 compose-actions: Update trigger for composing a new direct message.
Updates the trigger in the compose box from "new private message"
to "new direct message".
2023-06-26 11:07:28 -07:00
Satyam Bansal 0945f2dee6 integrations: Separate issue labeled events in GitHub Integration.
This commit creates separate events for issue labeled and
unlabeled notifications. This allows the end-users to choose
whether they want these notifications or not.

Fixes #25789.
2023-06-26 11:04:32 -07:00
Satyam Bansal 842e9d1aca integrations: Improve GitHub issue labeled and unlabeled notifications.
Earlier, the notifications had no information about the labels
being added or removed.
2023-06-26 11:04:32 -07:00
Satyam Bansal 8fc28be8ca integrations: Add issue unlabeled fixture to GitHub Integration. 2023-06-26 11:04:32 -07:00
Satyam Bansal b4674892a4 integrations: Add issue labeled fixture to GitHub Integration. 2023-06-26 11:04:32 -07:00
David Rosa ca4e73b663 docs: Rename private message -> direct message in Spanish style guide.
- Updates instances of "private message" and "PM", improving wording
  and translating to Spanish where needed.
2023-06-26 11:02:34 -07:00
Zixuan James Li dd3fad4b30 mute users: Remove leftover check for muting bot users.
This was missed in #26005. The user popover button does not appear
for bot users. We complete the TODO here and simplify the
calculation for show_manage_menu so that we always show it if not in
spectator view and not showing the popover for self.
2023-06-26 11:01:40 -07:00
evykassirer 87649ddbab condense: Replace $.fn.height with using the DOM API.
This increases performance by at least 10x. See discussion
on CZO for more details:
https://chat.zulip.org/#narrow/stream/6-frontend/topic/resize.20undo.20redo.20condense/near/1581598
2023-06-26 10:59:53 -07:00
evykassirer ca6e93ac7d condense: Remove _message_content_height_cache.
Since `scrollHeight` is very quick, we don't need
the cache anymore, and the code is easier to reason
about without it.

Profiling checks described on CZO here:
https://chat.zulip.org/#narrow/stream/6-frontend/topic/resize.20undo.20redo.20condense/near/1581520
2023-06-26 10:59:53 -07:00
evykassirer 43b18eabf1 condense: Avoid layout thrashing.
More information on layout thrashing
[here](https://web.dev/avoid-large-complex-layouts-and-layout-thrashing/#avoid-layout-thrashing).
2023-06-26 10:59:53 -07:00
evykassirer 8d0fa236c8 more/less: Fix bug where messages rapidly condense and uncondense.
This commit changes a few things:

* Using `scrollHeight` instead of `offsetHeight`, which explicitly
  also measures content not visible on the screen due to overflow.
* Measures the height of `.message_content` which is the div with
  the full message height.
* Only resizes messages that are visible on the screen, i.e. only
  those in `message_lists.current`.
2023-06-26 10:59:53 -07:00
Alex Vandiver f5540303ba pgroonga: Remove 'GRANT USAGE' statement again.
dc2726c814 removed these statements, but c8ec3dfcf6 accidentally
brought one back.  Remove it.
2023-06-26 10:47:17 -04:00
Karl Stolley d6c21c2237 docs: Correct scope of copied material from copy button.
This traverses the DOM to the <pre> element containing the
copyable material of interest.

The button is attached to the .codehilite element to ensure
that the button does not move with horizontally-scrolling
code content that exceeds the width of the content column,
as happens frequently at mobile scales or for very long
lines of content.

Fixes #26093.
2023-06-24 07:51:54 -07:00
David Rosa 04ead84c4d lib-markdown: Rename confusing variable name in `tabbed_sections.py`.
- Renames `data_language` -> `data_tab_key`.
- Renames `tab_name` -> `tab_key`.
2023-06-24 07:47:25 -07:00
David Rosa 0e0512df92 widgets: Rename confusing variable name in `tabbed_instructions.ts`.
The `tabbed_instructions` widget used for both language toggles in our
API documentation and app toggles in our Help Center documentation
misleadingly calls the identifier for the tab `language` in local
variables and its interface.

- Renames local variables `language` -> `tab_key`.
- Renames HTML data attributes `data-language` -> `data-tab-key`.

Fixes #24669.
2023-06-24 07:47:25 -07:00
Alex Vandiver ec4bfd7c78 install: Use the initially-cloned repo as the base /srv/zulip.git.
This ensures that the next `upgrade-zulip-from-git` has access to the
commit history of the initial install, if it was from a forked
repository.  `/home/zulip/deployments/current` and `/srv/zulip.git`
are not quite organized into the steady-state that they will have
after one `upgrade-zulip-from-git`:
 - `/home/zulip/deployments/current` is its own clone, not a worktree
 - `/srv/zulip.git` has an origin of `/home/zulip/deployments/current`
 - `remote.origin.mirror` is set on `/srv/zulip.git`
 - `remote.origin.fetch` is `+refs/*:refs/*`

All but the first are automatically cleaned up by
`upgrade-zulip-from-git` when it is next run, using the code added in
30457ecd02.  The additional complexity of making an existing
independent clone into a worktree seem not worth solving the first
point.
2023-06-24 07:43:04 -07:00
Alex Vandiver 1276653ec8 upgrade-zulip: The "git rev-parse" command can parse "git describe" output directly. 2023-06-24 07:43:04 -07:00
Karl Stolley a9bc5e94e7 bot_icon: Adjust bot-icon color for light and dark modes. 2023-06-23 14:43:22 -07:00
tyler ed1431f1bd gear_menu: Rename tooltip to reflect name change from 'Menu' to 'Main menu'. 2023-06-23 14:42:34 -07:00
tyler 0ce0995e49 gear_menu: Add accessibility label to gear menu toggle. 2023-06-23 14:42:34 -07:00
evykassirer 22d6d9455a header: Fix dark mode header box-shadow.
Followup to 239b6737c0
2023-06-23 14:41:16 -07:00
Alex Vandiver c8ec3dfcf6 pgroonga: Run upgrade SQL when pgroonga package is updated.
Updating the pgroonga package is not sufficient to upgrade the
extension in PostgreSQL -- an `ALTER EXTENSION pgroonga UPDATE` must
explicitly be run[^1].  Failure to do so can lead to unexpected behavior,
including crashes of PostgreSQL.

Expand on the existing `pgroonga_setup.sql.applied` file, to track
which version of the PostgreSQL extension has been configured.  If the
file exists but is empty, we run `ALTER EXTENSION pgroonga UPDATE`
regardless -- if it is a no-op, it still succeeds with a `NOTICE`:

```
zulip=# ALTER EXTENSION pgroonga UPDATE;
NOTICE:  version "3.0.8" of extension "pgroonga" is already installed
ALTER EXTENSION
```

The simple `ALTER EXTENSION` is sufficient for the
backwards-compatible case[^1] -- which, for our usage, is every
upgrade since 0.9 -> 1.0.  Since version 1.0 was released in 2015,
before pgroonga support was added to Zulip in 2016, we can assume for
the moment that all pgroonga upgrades are backwards-compatible, and
not bother regenerating indexes.

Fixes: #25989.

[^1]: https://pgroonga.github.io/upgrade/
2023-06-23 14:40:27 -07:00
Alex Vandiver dc2726c814 pgroonga: Remove now-unnecessary 'GRANT USAGE' statement.
This was only necessary for PGroonga 1.x, and the `pgroonga` schema
will most likely be removed at some point inthe future, which will
make this statement error out.

Drop the unnecessary statement.
2023-06-23 14:40:27 -07:00
David Rosa 9af31c41da templates: Rename "private message" -> "direct message".
- Updates instances of "private message".
2023-06-23 14:36:16 -07:00
David Rosa 992f5b3f6f api docs: Rename "private message" -> "direct message".
Updates instances of "private message" and "PM", avoiding acronyms.
2023-06-23 14:36:16 -07:00
David Rosa 513eb510aa docs: Rename "private message" -> "direct message".
- Updates instances of "private message", "PM", and "private_message",
  excluding historical references in `overview/changelog.md`.
- Also excludes `/docs/translating` since we would need new
  translations for "direct messages" and "DMs".
2023-06-23 14:36:16 -07:00
Sahil Batra db825ad202 settings: Remove settings_text_input class from url type inputs.
This commit removes settings_text_input class from url type inputs
and we instead add the width property to settings_url_input.

Note that we might instead have a single class for all type of inputs
instead of having different classes for url, password and text type
inputs in further commits.
2023-06-23 11:53:38 -07:00
Sahil Batra 7d0da75430 modal: Remove modal_text_input class from password and url type inputs.
We remove the modal_text_input class from password and url type inputs
in modals and add the width property CSS to modal_password_input and
modal_url_input instead.

Note that we might instead have a single class for all type of inputs
instead of having different classes for url, password and text type
inputs in further commits.
2023-06-23 11:53:38 -07:00
Sahil Batra a860e717bb bootstrap: Remove bootstrap CSS for url type inputs.
We use url type inputs in the add and edit custom field modals
and also to show the url type custom fields in "Profile" panel
and "Manage user" modal.

This commit re-adds the bootstrap CSS rules to these specific
input elements using modal_url_input and settings_url_input
class and thus removes the CSS for url type inputs from
bootstrap.css.

We might replace the new class added here with a common class
for all type of inputs in further commits.
2023-06-23 11:53:38 -07:00
Sahil Batra 9cf214a7cb bootstrap: Remove bootstrap CSS for email type inputs.
We use email type inputs only in portico pages and
the bootstrap CSS is already overridden by CSS
defined in portico_signin.css. Only outline property
was being applied by bootstrap on focusing the input
which has been added to CSS in portico_signin.css in
the previous commit as password and email type inputs
have common CSS.

Thus, we can remove the bootstrap CSS for email type
inputs safely.
2023-06-23 11:53:38 -07:00
Sahil Batra 631eba09ee css: Remove bootstrap CSS for password type inputs.
We use password type inputs for API key and password
change modal in the main app and in login, register
and password reset pages.

For the portico pages, i.e. login, register and
password reset pages, the bootstrap CSS is already
overridden by our custom CSS defined in
portico_signin.css and some of the CSS added by
bootstrap is redundant. Only outline property was
being applied by bootstrap on focusing the input
which has been added to CSS in portico_signin.css
in this commit.

For the inputs used in app, i.e. API key and password
change modal, we have already added the CSS rules of
Bootstrap using "modal_password_input" class.

Thus, we can remove the CSS for password type inputs
from bootstrap.css.
2023-06-23 11:53:38 -07:00
Sahil Batra 5ac72eedd9 modals: Re-add bootstrap CSS to password inputs in modals.
This commit adds specific CSS styles from bootstrap to password
type inputs in modals using modal_password_input class. This
change helps us in removing the bootstrap CSS for password type
inputs in further commits.

We might replace the new added class with a single class which
will be used for all type of inputs in further commits.
2023-06-23 11:53:38 -07:00
Sahil Batra 954f605514 bootstrap: Remove CSS image type inputs.
We do not use any image type inputs in our app.
2023-06-23 11:53:38 -07:00
Sahil Batra 4703292c35 bootstrap: Remove CSS for file type inputs.
This commit removes bootstrap CSS for file type inputs
and we can safely do so all file type inputs are hidden.
2023-06-23 11:53:38 -07:00
Sahil Batra 35f252f5b2 templates: Remove pull-left class and its bootstrap CSS.
The "pull-left" class was used for hidden file type input
in compose_control_buttons.hbs and in the copy code button
in codeblocks. It was only used to set the float property
in CSS, but we do not need to set it and removing it does
not make any change in the position of these elements.
So, this commit removes the pull-left class and its CSS
from bootstrap.css as well.

For the file type input, it is already hidden and after
removing the float property also, it is positioned at the
same place due to ordering of elements in HTML.

For the copy code button in codeblocks, it is postioned
using "position" and "right" attributes and removing
"float" property has no effect.
2023-06-23 11:53:38 -07:00