Commit Graph

54374 Commits

Author SHA1 Message Date
Sérgio Saquetim c3f43125a2
DEV: Allow @glimmer/* packages' MIT style licenses (#27210) 2024-05-28 14:00:52 -03:00
David Taylor 4dbd072eae
DEV: Allow afterFramePaint to be used in tests (#27231)
We need to register a waiter so that `settled()` will wait for `runAfterFramePaint()` callbacks to be run before proceeding.

Re-lands 63b7b598cb, but wrapped with `isTesting()` to avoid production errors.
2024-05-28 17:02:58 +01:00
David Taylor 9b11e9a8d1
UX: Hide 'same site cookies' site setting (#27230)
Changing this to anything other than 'Lax' will lead to pain. 'None' is much less secure, and 'Strict' will break lots of functionality.
2024-05-28 16:13:45 +01:00
Jan Cernik 76c56c8284
FIX: Bulk clear reminders when the reminder is expired (#27220) 2024-05-28 10:21:33 -03:00
Isaac Janzen caa29ec973
DEV: Update how we determine the presence of a topic in the header (#27138)
# Context

We currently have a tracked value of `topic` in the header service that we utilize across the app for determining the presence of a topic.

A simple example is: If you are in a topic, and scroll down the page, we need to communicate to the header that a topic is present and we change the styling of the header. 

The issue with this logic is that when entering a topic (and you are at the top of the page), we **haven't** set the topic on the header service yet. We only set the topic when you have scrolled down on the page (set by `app/components/discourse-topic.js`) 

This is unhelpful behavior when you are utilizing a plugin outlet that is receiving the `topic` from the header: 

17add599e3/app/assets/javascripts/discourse/app/components/header/topic/info.gjs (L85)

As the `topic` won't be present until you scroll down the page. 

# Changes

This PR adds a tracked `inTopic` value to the header service that is a boolean value. This is to let the app know

> Yes, we are scrolled within a topic

And instead sets the tracked `topic` value immediately, if you are loading a topic, to allow the necessary data to be populated to the plugin outlets on page load.
2024-05-28 07:16:18 -06:00
David Taylor 531fc1d754
Revert "DEV: Allow afterFramePaint to be used in tests (#27226)" (#27228)
This reverts commit 63b7b598cb.

Causing issues in production builds
2024-05-28 14:01:10 +01:00
chapoi d0427919f1
UX: add illustrations for empty chat list + split into tabs on drawer (#26910)
Adds a placeholder image + CTA in chat, for empty channel and DM lists.

On desktop with drawer mode, we split chat into tabs (like mobile).

---------

Co-authored-by: Joffrey JAFFEUX <j.jaffeux@gmail.com>
Co-authored-by: David Battersby <info@davidbattersby.com>
Co-authored-by: Régis Hanol <regis@hanol.fr>
2024-05-28 17:00:04 +04:00
Jarek Radosz e02b8b4a83
DEV: Remove extra whitespace from glimmer topic list items (#27225) 2024-05-28 14:23:36 +02:00
David Taylor aea1f4417a
DEV: Remove all direction tracking from sticky-avatars code (#27224)
No longer required since b6cc95a0e1
2024-05-28 13:17:27 +01:00
David Taylor 63b7b598cb
DEV: Allow afterFramePaint to be used in tests (#27226)
We need to register a waiter so that `settled()` will wait for `runAfterFramePaint()` callbacks to be run before proceeding.
2024-05-28 13:09:46 +01:00
Jan Cernik 30e963be03
DEV: Add spec for x.com onebox url matcher (#27214) 2024-05-28 09:04:20 -03:00
David Taylor b6cc95a0e1
UX: Make sticky avatars behavior consistent (#27223)
Previously, avatars would be 'sticky' when:

1. The post was longer than the viewport

OR

2. You were scrolling up

The difference in behavior based on scroll direction doesn't 'feel' quite right. This commit makes the behavior consistent, so sticky avatar logic is applied to all posts regardless of scroll direction.
2024-05-28 12:14:15 +01:00
Natalie Tay 61c6d2a7fc
DEV: Also noindex embedded comments (#27221)
For some reason, despite iframe also indicating a

```
<meta name="robots" content="noindex">
```

.. Google is still indexing the embed/comment URLs. This causes links like http://\<site>/embed/comments\?topic_id\=6366 to be indexed instead of the topic.

This commit adds it explicitly in the header.
2024-05-28 12:59:24 +08:00
Martin Brennan 9c85ea5945
DEV: Remove old TODOs for message-id formats (#27196)
Introduced back in 2022 in
e3d495850d,
our new more specific message-id format for inbound and
outbound emails has now been in use for a very long time,
we can remove the support for the old formats:

`topic/:topic_id/:post_id.:random@:host`
`topic/:topic_id@:host`
`topic/:topic_id.:random@:host`
2024-05-28 13:57:09 +10:00
Krzysztof Kotlarek 39902c148f
FIX: move ServiceRunner from Chat to Core (#27219)
In this PR service objects were moved to Core https://github.com/discourse/discourse/pull/26506

However, ServiceRunner should be moved as well. Mostly for CI to run effortlessly without loading plugins.
2024-05-28 13:55:46 +10:00
Alan Guo Xiang Tan 4d8eca91ef
Revert "DEV: Use `127.0.0.1` instead of `localhost` as Capybara's server host (#27215)" (#27218)
This reverts commit 998b50fdf4.

Ended up making system tests even more unstable
2024-05-28 11:32:22 +08:00
Krzysztof Kotlarek 556ff0a7b8
DEV: remove obsolete needs_review score type (#27200)
Chat messages are following normal post flags. This newly registered score type is not used anymore.
2024-05-28 13:03:58 +10:00
Martin Brennan 73c6bb2593
FIX: Admin sidebar disappeared on some routes for header dropdown (#27216)
When navigation_menu is set to header dropdown, we are
still forcing admin sidebar by checking if the user is an
admin route (c.f. 9bcbfbba43).

However in the initial commit the route check had the
false premise that all admin routes started with `admin.`;
there are others that don't. We need to force admin sidebar
on all routes starting with `admin` (no `.`).

c.f. https://meta.discourse.org/t/feedback-on-admin-sidebar-when-header-dropdown-navigation-selected/309490/3?u=martin
2024-05-28 11:47:54 +10:00
Alan Guo Xiang Tan 998b50fdf4
DEV: Use `127.0.0.1` instead of `localhost` as Capybara's server host (#27215)
We are seeing a weird resolution error on Github actions with the
following backtrace:

```
Failure/Error:
  visit File.join(
          GlobalSetting.relative_url_root || "",
          "/session/#{user.encoded_username}/become.json?redirect=false",
        )

Socket::ResolutionError:
  getaddrinfo: Temporary failure in name resolution

```

Switch to use `127.0.0.1` instead of forcing a name resolution.
2024-05-28 09:47:22 +08:00
dependabot[bot] b9984d9c64
Build(deps-dev): Bump @discourse/lint-configs from 1.3.8 to 1.3.9 (#27213)
Bumps [@discourse/lint-configs](https://github.com/discourse/lint-configs) from 1.3.8 to 1.3.9.
- [Commits](https://github.com/discourse/lint-configs/commits)

---
updated-dependencies:
- dependency-name: "@discourse/lint-configs"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-28 01:43:39 +02:00
dependabot[bot] 635303f6f8
Build(deps-dev): Bump lefthook from 1.6.12 to 1.6.13 (#27212)
Bumps [lefthook](https://github.com/evilmartians/lefthook) from 1.6.12 to 1.6.13.
- [Release notes](https://github.com/evilmartians/lefthook/releases)
- [Changelog](https://github.com/evilmartians/lefthook/blob/master/CHANGELOG.md)
- [Commits](https://github.com/evilmartians/lefthook/compare/v1.6.12...v1.6.13)

---
updated-dependencies:
- dependency-name: lefthook
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-28 01:43:32 +02:00
Régis Hanol 5f6b6e9818 FIX: correctly compute the window for email summaries
In 958437e7dd we ensured that the email summaries are properly sent based on 'digest_attempted_at' for people who barely/never visit the forum.

This fixed the "frequency" of the email summaries but introduced a bug where the digest would be sent even though there wasn't anything new since for some users.

The logic we use to compute the threshold date for the content to be included in the digest was

```ruby
@since = opts[:since] || user.last_seen_at || user.user_stat&.digest_attempted_at || 1.month.ago
```

It was working as expected for users who haven never been seen but for users who have connected at least once, we would use their "last_seen_at" date as the "threshold date" for the content to be sent in a summary 😬

This fix changes the logic to be the most recent date amongst the `last_seen_at`, `digest_attempted_at` and `1.month.ago` so it's correctly handling cases where

- user has never been seen nor emailed a summary
- user has been seen in a while but has recently been sent a summary
- user has been sent a summary recently but hasn't been seen in a while.
2024-05-27 22:33:51 +02:00
chapoi 6a21143d83
UX: add text-overflow for channel members list (#27208) 2024-05-27 21:28:54 +02:00
Loïc Guitaut 2a28cda15c DEV: Update to lastest rubocop-discourse 2024-05-27 18:06:14 +02:00
Joffrey JAFFEUX 3b6d4c830f
DEV: correctly delete custom scheme (#27203)
We were adding the custom scheme as a symbol, but trying to delete the string. Which would result in the symbol to not be removed.

This was causing errors in others test:

```
Error encountered while proccessing /admin/color_schemes.json  I18n::MissingTranslationData: Translation missing: en.color_schemes.baseschemewithnohighlightcolor
```

Reproducible with (probably possible to have a simpler repro):

```
bundle exec rspec --order random:27167 spec/integration/invalid_request_spec.rb spec/integration/spam_rules_spec.rb spec/jobs/bulk_invite_spec.rb spec/jobs/change_display_name_spec.rb spec/jobs/cleanup_imap_sync_log_spec.rb spec/jobs/download_backup_email_spec.rb spec/jobs/fix_primary_emails_for_staged_users_spec.rb spec/jobs/fix_s3_etags_spec.rb spec/jobs/pending_users_reminder_spec.rb spec/jobs/periodical_updates_spec.rb spec/jobs/pull_hotlinked_images_spec.rb spec/jobs/regular/group_smtp_email_spec.rb spec/jobs/reindex_search_spec.rb spec/jobs/update_topic_hot_scores_spec.rb spec/jobs/user_email_spec.rb spec/lib/admin_confirmation_spec.rb spec/lib/backup_restore/database_restorer_multisite_spec.rb spec/lib/backup_restore/system_interface_spec.rb spec/lib/bookmark_reminder_notification_handler_spec.rb spec/lib/color_math_spec.rb spec/lib/content_buffer_spec.rb spec/lib/discourse_spec.rb spec/lib/discourse_tagging_spec.rb spec/lib/discourse_webauthn/registration_service_spec.rb spec/lib/email/renderer_spec.rb spec/lib/email_updater_spec.rb spec/lib/ember_cli_spec.rb spec/lib/feed_element_installer_spec.rb spec/lib/file_helper_spec.rb spec/lib/final_destination/resolver_spec.rb spec/lib/freedom_patches/schema_migration_details_spec.rb spec/lib/guardian/post_guardian_spec.rb spec/lib/guardian/topic_guardian_spec.rb spec/lib/message_id_service_spec.rb spec/lib/onebox/domain_checker_spec.rb spec/lib/onebox/engine/google_maps_onebox_spec.rb spec/lib/onebox/engine/google_play_app_onebox_spec.rb spec/lib/onebox/engine/json_spec.rb spec/lib/onebox/engine/reddit_media_onebox_spec.rb spec/lib/onebox/engine/video_onebox_spec.rb spec/lib/onebox/engine/wikipedia_onebox_spec.rb spec/lib/onebox/engine/wistia_onebox_spec.rb spec/lib/post_destroyer_spec.rb spec/lib/post_locker_spec.rb spec/lib/s3_helper_spec.rb spec/lib/s3_inventory_spec.rb spec/lib/scss_checker_spec.rb spec/lib/site_icon_manager_spec.rb spec/lib/site_setting_extension_multisite_spec.rb spec/lib/summarization/base_spec.rb spec/lib/trashable_spec.rb spec/lib/validators/category_search_priority_weights_validator_spec.rb spec/lib/validators/max_username_length_validator_spec.rb spec/lib/validators/regex_presence_validator_spec.rb spec/lib/validators/regexp_list_validator_spec.rb spec/lib/validators/topic_title_length_validator_spec.rb spec/lib/validators/url_validator_spec.rb spec/lib/work_queue_spec.rb spec/mailers/test_mailer_spec.rb spec/mailers/version_mailer_spec.rb spec/models/badge_grouping_spec.rb spec/models/category_featured_topic_spec.rb spec/models/color_scheme_spec.rb spec/models/flag_spec.rb spec/models/given_daily_like_spec.rb spec/models/plugin_store_spec.rb spec/models/screened_url_spec.rb spec/models/site_setting_spec.rb spec/models/tag_spec.rb spec/models/theme_svg_sprite_spec.rb spec/models/top_menu_item_spec.rb spec/models/topic_allowed_user_spec.rb spec/models/topic_converter_spec.rb spec/models/topic_timer_spec.rb spec/models/translation_override_spec.rb spec/models/user_archived_message_spec.rb spec/models/user_email_spec.rb spec/models/user_search_spec.rb spec/models/user_status_spec.rb spec/models/web_hook_event_spec.rb spec/multisite/pausable_multisite_spec.rb spec/multisite/pausable_spec.rb spec/requests/about_controller_spec.rb spec/requests/admin/backups_controller_spec.rb spec/requests/admin/color_schemes_controller_spec.rb spec/requests/admin/email_templates_controller_spec.rb spec/requests/admin/form_templates_controller_spec.rb spec/requests/admin/screened_ip_addresses_controller_spec.rb spec/requests/admin/site_texts_controller_spec.rb spec/requests/api/categories_spec.rb spec/requests/api/site_spec.rb spec/requests/api/tags_spec.rb spec/requests/api/uploads_spec.rb spec/requests/api/users_spec.rb spec/requests/associate_accounts_controller_spec.rb spec/requests/badges_controller_spec.rb spec/requests/csp_reports_controller_spec.rb spec/requests/edit_directory_columns_controller_spec.rb spec/requests/slugs_controller_spec.rb spec/requests/steps_controller_spec.rb spec/requests/stylesheets_controller_spec.rb spec/requests/topic_view_stats_controller_spec.rb spec/requests/user_avatars_controller_spec.rb spec/requests/users_controller_spec.rb spec/script/import_scripts/vanilla_body_parser_spec.rb spec/serializers/basic_reviewable_queued_post_serializer_spec.rb spec/serializers/found_user_serializer_spec.rb spec/serializers/reviewable_flagged_post_serializer_spec.rb spec/serializers/reviewable_queued_post_serializer_spec.rb spec/serializers/reviewable_user_serializer_spec.rb spec/serializers/theme_objects_setting_metadata_serializer_spec.rb spec/serializers/topic_tracking_state_item_serializer_spec.rb spec/serializers/user_summary_serializer_spec.rb spec/serializers/user_with_custom_fields_serializer_spec.rb spec/services/color_scheme_revisor_spec.rb spec/services/email_settings_exception_handler_spec.rb spec/services/notification_emailer_spec.rb spec/services/problem_check/email_polling_errored_recently_spec.rb spec/services/problem_check/missing_mailgun_api_key_spec.rb spec/services/problem_check/unreachable_themes_spec.rb spec/services/site_settings_spec.rb spec/services/topic_timestamp_changer_spec.rb spec/services/username_changer_spec.rb
```
2024-05-27 16:35:42 +02:00
Joffrey JAFFEUX ca4b813d29
DEV: linting (#27205) 2024-05-27 16:35:30 +02:00
Osama Sayegh 361992bb74
FIX: Apply crawler rate limits to cached requests (#27174)
This commit moves the logic for crawler rate limits out of the application controller and into the request tracker middleware. The reason for this move is to apply rate limits to all crawler requests instead of just the requests that make it to the application controller. Some requests are served early from the middleware stack without reaching the Rails app for performance reasons (e.g. `AnonymousCache`) which results in crawlers getting 200 responses even though they've reached their limits and should be getting 429 responses.

Internal topic: t/128810.
2024-05-27 16:26:35 +03:00
Juan David Martínez Cubillos 7992d7a65a
DEV: Refactor to add Custom emoji sanitization (#24368)
Co-authored-by: Joffrey JAFFEUX <j.jaffeux@gmail.com>
2024-05-27 15:24:55 +02:00
Anatolii Prybylovych 51e02e0d31
DEV: Add reviewable id data attribute and plugin outlet for reviewable actions (#25311) 2024-05-27 15:15:18 +02:00
Krzysztof Kotlarek f5516b8088
DEV: clean after replacing flags spec (#27194)
After flags are replaced, we need to bring the state back to the original. Otherwise, it causes flaky specs.
2024-05-27 19:57:41 +08:00
Alan Guo Xiang Tan 3c0e672fc4
PERF: `PostTiming.pretend_read` to not update `TopicUser` cache columns (#27201)
This commit splits out the updating of `TopicUser#last_read_post_number` in
`TopicUser.ensure_consistency!` to a new
`TopicUser.update_last_read_post_number` method` which
`PostTiming.pretend_read` will now call instead. Previously,
`PostTiming.pretend_read` calls `TopicUser.ensure_consistency!` which in
turn calls `TopicUser.update_post_action_cache` but that is
unnecessary for `PostTiming.pretend_read` since `PostTiming.pretend_read` does not
affect the `TopicUser#liked` or `TopicUser.bookmarked` columns which
`TopicUser.update_post_action_cache` updates. As the query in
`TopicUser.update_post_action_cache` can be expensive, we should avoid
calling it when it isn't necessary.

One such scenario where it is unnecessary is when we are closing a
topic.
2024-05-27 19:56:33 +08:00
dependabot[bot] f9df40cc5c
Build(deps-dev): Bump webmock from 3.23.0 to 3.23.1 (#27192)
Bumps [webmock](https://github.com/bblimke/webmock) from 3.23.0 to 3.23.1.
- [Changelog](https://github.com/bblimke/webmock/blob/master/CHANGELOG.md)
- [Commits](https://github.com/bblimke/webmock/compare/v3.23.0...v3.23.1)

---
updated-dependencies:
- dependency-name: webmock
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-27 11:42:32 +02:00
dependabot[bot] 0a11327704
Build(deps-dev): Bump rubocop from 1.63.5 to 1.64.0 (#27191)
Bumps [rubocop](https://github.com/rubocop/rubocop) from 1.63.5 to 1.64.0.
- [Release notes](https://github.com/rubocop/rubocop/releases)
- [Changelog](https://github.com/rubocop/rubocop/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rubocop/rubocop/compare/v1.63.5...v1.64.0)

---
updated-dependencies:
- dependency-name: rubocop
  dependency-type: indirect
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-27 11:42:14 +02:00
dependabot[bot] 4789536d55
Build(deps): Bump google-protobuf from 4.26.1 to 4.27.0 (#27190)
Bumps [google-protobuf](https://github.com/protocolbuffers/protobuf) from 4.26.1 to 4.27.0.
- [Release notes](https://github.com/protocolbuffers/protobuf/releases)
- [Changelog](https://github.com/protocolbuffers/protobuf/blob/main/protobuf_release.bzl)
- [Commits](https://github.com/protocolbuffers/protobuf/commits)

---
updated-dependencies:
- dependency-name: google-protobuf
  dependency-type: indirect
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-27 11:42:03 +02:00
dependabot[bot] ed21f34eeb
Build(deps-dev): Bump glob from 10.3.16 to 10.4.1 (#27186)
Bumps [glob](https://github.com/isaacs/node-glob) from 10.3.16 to 10.4.1.
- [Changelog](https://github.com/isaacs/node-glob/blob/main/changelog.md)
- [Commits](https://github.com/isaacs/node-glob/compare/v10.3.16...v10.4.1)

---
updated-dependencies:
- dependency-name: glob
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-27 11:41:43 +02:00
dependabot[bot] a2bbf571a8
Build(deps): Bump zeitwerk from 2.6.14 to 2.6.15 (#27189)
Bumps [zeitwerk](https://github.com/fxn/zeitwerk) from 2.6.14 to 2.6.15.
- [Changelog](https://github.com/fxn/zeitwerk/blob/main/CHANGELOG.md)
- [Commits](https://github.com/fxn/zeitwerk/compare/v2.6.14...v2.6.15)

---
updated-dependencies:
- dependency-name: zeitwerk
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-27 11:40:07 +02:00
dependabot[bot] 1a04f1cf33
Build(deps-dev): Bump puppeteer-core from 22.9.0 to 22.10.0 (#27188)
Bumps [puppeteer-core](https://github.com/puppeteer/puppeteer) from 22.9.0 to 22.10.0.
- [Release notes](https://github.com/puppeteer/puppeteer/releases)
- [Changelog](https://github.com/puppeteer/puppeteer/blob/main/release-please-config.json)
- [Commits](https://github.com/puppeteer/puppeteer/compare/puppeteer-core-v22.9.0...puppeteer-core-v22.10.0)

---
updated-dependencies:
- dependency-name: puppeteer-core
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-27 11:39:55 +02:00
dependabot[bot] 4b061c4a8c
Build(deps-dev): Bump esbuild from 0.21.3 to 0.21.4 (#27187)
Bumps [esbuild](https://github.com/evanw/esbuild) from 0.21.3 to 0.21.4.
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.21.3...v0.21.4)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-27 11:38:37 +02:00
dependabot[bot] 4d7869d731
Build(deps): Bump the babel group with 2 updates (#27185)
Bumps the babel group with 2 updates: [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) and [@babel/standalone](https://github.com/babel/babel/tree/HEAD/packages/babel-standalone).


Updates `@babel/core` from 7.24.5 to 7.24.6
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.24.6/packages/babel-core)

Updates `@babel/standalone` from 7.24.5 to 7.24.6
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.24.6/packages/babel-standalone)

---
updated-dependencies:
- dependency-name: "@babel/core"
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: babel
- dependency-name: "@babel/standalone"
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: babel
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-27 11:25:56 +02:00
Discourse Translator Bot 9d8044a2ee
FEATURE: Add Uyghur language (#27183)
Co-authored-by: Gerhard Schlager <gerhard.schlager@discourse.org>
2024-05-27 09:58:18 +02:00
Gerhard Schlager 5e61d55940
FIX: Updating avatar didn't trigger a rebake of posts with quotes of the user (#27184) 2024-05-27 09:57:48 +02:00
Gerhard Schlager 9aede9c8d8
FIX: "Replace Text" didn't list "Welcome Topic" when "General" category is missing (#27182)
Replacing the text of seeded topics doesn't require categories to exist, so this change removes that requirement for updates.
2024-05-27 09:57:30 +02:00
Sam d1191b7f5f
FEATURE: topic_view_stats table with daily fidelity (#27197)
This gives us daily fidelity of topic view stats

New table stores a row per topic viewed per day tracking
anonymous and logged on views

We also have a new endpoint `/t/ID/views-stats.json` to get the statistics for the topic.
2024-05-27 15:25:32 +10:00
Alan Guo Xiang Tan 6cafe59c76
DEV: Add `DISCOURSE_DUMP_BACKTRACES_ON_UNICORN_WORKER_TIMEOUT` env (#27199)
This commit adds a `DISCOURSE_DUMP_BACKTRACES_ON_UNICORN_WORKER_TIMEOUT`
environment that will allow us to dump all backtraces for all threads of
a Unicorn worker 2 seconds before it times out. In development,
backtraces are dumped to `STDOUT` and in production we will dump it to
`unicorn.stdout.log`.

We want to dump all the backtraces to make it easier to identify the
cause of a Unicorn worker timing out.
2024-05-27 12:20:38 +08:00
Martin Brennan 3a91a92563
DEV: Remove hashtag deprecations (#27195)
Introduced in
c7860173c1,
they are no longer necessary once https://github.com/discourse/discourse-encrypt/pull/317
is merged
2024-05-27 14:00:36 +10:00
Ted Johansson cb592ae4ac
DEV: Remove deprecated User#saw_notification_id method (#27175) 2024-05-27 11:10:46 +08:00
Juan David Martínez Cubillos 581dbca97f
DEV: Update Reviewables agree and edit action test (#27162) 2024-05-24 12:20:30 -07:00
Joffrey JAFFEUX 0260415664
FIX: correctly handle notifications for channels (#27178)
Prior to this fix we had too logic to detect if a user is active or not:

- idle codepath on the frontend
- online user ids on the backend

The frontend solution is not very reliable, and both solution are just trying to be too smart. Making a lot of people questioning why they receive a notification sometimes and sometimes not. This commit removes all this logic and replaces it with a much more simpler logic:

- you can't receive notifications for channel you are actually watching
- we won't play a sound more than once every 3seconds
2024-05-24 19:59:24 +02:00
Joffrey JAFFEUX 14b8894ddb
FIX: missing appEvents param for onNotification (#27180)
The `onNotification` signature is:

```
onNotification(data, siteSettings, user, appEvents)
```

And we were not passing `appEvents`.

Also explicitly inject `currentUser` in `chat-notification-manager` service.
2024-05-24 18:39:54 +02:00
Régis Hanol bc089dc52b FIX: bypass fast edit when selected text isn't editable
When selected some text inside a post, we offer the ability to "fast edit" the selected text without opening the composer.

However, there are certain cases where this isn't working quite a expected, due to the fact that we have some text in the "cooked" version of the post that isn't literally in the "raw" version of the post.

This ensures that whenever someone selects the within

- a quote
- a onebox
- an encrypted message
- a "cooked" date

we directly show the composer instead of showing the fast edit modal and then leaving the user with an invisible error.

Internal ref. t/128400
2024-05-24 18:19:28 +02:00