Commit Graph

59026 Commits

Author SHA1 Message Date
c4d971ea2c FIX: Consistent search shortcuts (#32099)
We now have 3 search UX variations:

* Header search
* Welcome banner search
* Icon search

And within each of these there is a `<SearchMenu />`
component with an input that needs to be focused based
on either Ctrl+F or `/` shortcuts. This commit makes
sure that each has a unique ID, and moves the functionality
of determining the "current" input ID and focusing the
input to the search service.

This fixes issues like where pressing Ctrl+F twice on
the header search would not reveal the regular browser
search.
2025-04-04 11:54:46 +10:00
aaa648ceac Build(deps-dev): Bump rubocop from 1.75.1 to 1.75.2 (#32155)
Bumps [rubocop](https://github.com/rubocop/rubocop) from 1.75.1 to
1.75.2.
- [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.75.1...v1.75.2)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-04 01:07:39 +02:00
57c0ac02d1 Build(deps-dev): Bump puppeteer-core from 24.5.0 to 24.6.0 (#32161)
Bumps [puppeteer-core](https://github.com/puppeteer/puppeteer) from
24.5.0 to 24.6.0.
- [Release notes](https://github.com/puppeteer/puppeteer/releases)
-
[Changelog](https://github.com/puppeteer/puppeteer/blob/main/CHANGELOG.md)
-
[Commits](https://github.com/puppeteer/puppeteer/compare/puppeteer-core-v24.5.0...puppeteer-core-v24.6.0)

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Discourse CI <ci@ci.invalid>
2025-04-04 01:07:18 +02:00
f91be52d5f Build(deps): Bump mini_racer from 0.18.0 to 0.18.1 (#32154)
Bumps [mini_racer](https://github.com/discourse/mini_racer) from 0.18.0
to 0.18.1.
- [Changelog](https://github.com/rubyjs/mini_racer/blob/main/CHANGELOG)
-
[Commits](https://github.com/discourse/mini_racer/compare/v0.18.0...v0.18.1)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-03 23:51:05 +02:00
4761a7a363 Build(deps): Bump faraday-retry from 2.3.0 to 2.3.1 (#32153)
Bumps [faraday-retry](https://github.com/lostisland/faraday-retry) from
2.3.0 to 2.3.1.
- [Release notes](https://github.com/lostisland/faraday-retry/releases)
-
[Changelog](https://github.com/lostisland/faraday-retry/blob/main/CHANGELOG.md)
-
[Commits](https://github.com/lostisland/faraday-retry/compare/v2.3.0...v2.3.1)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-03 23:50:57 +02:00
239634e325 Build(deps): Bump irb from 1.15.1 to 1.15.2 (#32156)
Bumps [irb](https://github.com/ruby/irb) from 1.15.1 to 1.15.2.
- [Release notes](https://github.com/ruby/irb/releases)
- [Commits](https://github.com/ruby/irb/compare/v1.15.1...v1.15.2)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-03 23:50:46 +02:00
1d94c39bef Build(deps-dev): Bump rubocop-ast from 1.43.0 to 1.44.0 (#32157)
Bumps [rubocop-ast](https://github.com/rubocop/rubocop-ast) from 1.43.0
to 1.44.0.
- [Release notes](https://github.com/rubocop/rubocop-ast/releases)
-
[Changelog](https://github.com/rubocop/rubocop-ast/blob/master/CHANGELOG.md)
-
[Commits](https://github.com/rubocop/rubocop-ast/compare/v1.43.0...v1.44.0)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-03 23:50:32 +02:00
abeb8de7b5 UX: Button fixes (#32152) 2025-04-03 16:13:34 -05:00
eb7e1613a0 DEV: Update plugin outlet wrappers on user-summary-topic.gjs (#31455)
Co-authored-by: Guhyoun Nam <70915823+rngus2344@users.noreply.github.com>
Co-authored-by: Isaac Janzen <50783505+janzenisaac@users.noreply.github.com>
Co-authored-by: rngus2344 <nam@discourse.org>
2025-04-03 15:20:51 -05:00
9140285569 DEV: Remove rotate-center css animation (#32151)
The code that introduced/used it is gone.
2025-04-03 19:12:55 +02:00
9be51b616b DEV: Handle the missing d-lazy-video case (#32148)
aka: lazy load lazy video

---------

Co-authored-by: David Taylor <david@taylorhq.com>
2025-04-03 18:09:02 +02:00
0863a42ff0 DEV: refactor CanCheckEmailsHelper to directly take model id (#32129)
We only need the `model.id` input here, so this simplifies the arguments
being passed into this helper.
2025-04-03 20:33:15 +08:00
1b2cf92d4c DEV: Drop backburner freedom patch (#32147)
Bugfix is now released in ember
2025-04-03 11:58:42 +01:00
c824a3b300 DEV: Retry chunk loading from all chunks (#32146)
Hopefully this will resolve some flaky qunit runs
2025-04-03 11:58:25 +01:00
60d7a4f120 DEV: refactor username validation helper class to take explicit args (#32136)
This aligns closer to how we are passing data through to the
UserFieldsHelperClass https://github.com/discourse/discourse/pull/31670,
and reduces coupling with the component itself.
2025-04-03 18:57:47 +08:00
6a6c0bc179 UX: Proper width of unsaved site setting banner (#32137)
Elements with position: fixed are taken out of the rendering context, so we can't easily make the banner the width of the main container using CSS. We tried a CSS hack, but that doesn't scale to larger screens, and probably breaks in some themes.

This is a simple JavaScript implementation that matches the width of the main container.
2025-04-03 17:35:01 +08:00
a62c2b9a17 DEV: Revert hashtag change and skip admin search test (#32144)
- **Revert "UX: add flex to mention for consistent alignment and spacing
(#32105)"**
- **DEV: Skip test**
2025-04-03 19:20:10 +10:00
7e77b24202 DEV: Preserve unsaved site settings (#32100)
This builds onto #32013 in two major ways:

- Unsaved changes are now persisted when you browse categories inside "All site settings".
- If you're about to navigate away (and lose edits) you will be prompted if you want to save or discard changes. (This applies to individual category site setting pages as well.
2025-04-03 16:10:30 +08:00
191ab68509 UX: add flex to mention for consistent alignment and spacing (#32105)
Fixing hashtag text glued to the icon
![CleanShot 2025-04-01 at 14 14
39](https://github.com/user-attachments/assets/237a0d54-dc08-438d-b935-94d3e670fd09)

And updated some related properties to using better units

| Before | After |
|--------|--------|
| ![CleanShot 2025-04-01 at 14 25
32@2x](https://github.com/user-attachments/assets/818d763d-900d-4a68-9115-381173b0c0a3)
| ![CleanShot 2025-04-01 at 14 15
37@2x](https://github.com/user-attachments/assets/abbe9167-6fa1-41ff-999d-e12a779f6a0e)
|
2025-04-03 09:45:41 +02:00
b40f184a70 UX: Make admin search setting visible (#32142)
We are ready to start rolling this out to more
people and announce it on Meta.
2025-04-03 17:03:53 +10:00
0f0a59d7ff DEV: Move admin only constants into admin bundle (#32141)
Minor optimization so that we don't load extra data for non-admin users.
2025-04-03 14:28:36 +08:00
b112f699f3 FIX: Admin search page shortcut (#32140)
Fixes "[missing %{shortcutHTML} value]" on standalone
admin search page.
2025-04-03 16:06:00 +10:00
60607aa231 UX: Show keyboard shortcut on full admin search page (#31646)
This commit adds an indicator of the shortcut for admin search to the
full page version of the search.

In addition, this commit does extensive refactoring of
`AdminSearchDataSource` and
adds many more tests for it to account for all the variations of
label/url formatting.
2025-04-03 14:12:31 +10:00
576f513304 Update translations (#32106) 2025-04-03 00:04:57 +02:00
a7514670b4 Build(deps-dev): Bump bullet from 8.0.1 to 8.0.2 (#32135)
Bumps [bullet](https://github.com/flyerhzm/bullet) from 8.0.1 to 8.0.2.
- [Changelog](https://github.com/flyerhzm/bullet/blob/main/CHANGELOG.md)
- [Commits](https://github.com/flyerhzm/bullet/compare/8.0.1...8.0.2)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-02 23:47:22 +02:00
1d72fd388d Build(deps): Bump a11y-dialog from 8.1.2 to 8.1.3 (#32134)
Bumps [a11y-dialog](https://github.com/KittyGiraudel/a11y-dialog) from
8.1.2 to 8.1.3.
- [Release notes](https://github.com/KittyGiraudel/a11y-dialog/releases)
-
[Commits](https://github.com/KittyGiraudel/a11y-dialog/compare/8.1.2...8.1.3)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-02 23:39:01 +02:00
7e7062f213 UX: Align tag separator properly when viewing search in full-page mode (#32133)
Better alignment with the  `,` separator

### Before
<img width="205" alt="image"
src="https://github.com/user-attachments/assets/5d834e72-8e55-4d4b-923a-e5d088fb0102"
/>

### After
<img width="207" alt="image"
src="https://github.com/user-attachments/assets/7d85a0ff-1804-451e-aea4-3fb9844e5b8e"
/>
2025-04-02 10:04:20 -04:00
783072e24d FIX: hide search field on auth pages (#32132)
This change prevents rendering the search field on login and sign up
pages.
2025-04-02 17:21:26 +04:00
25e5d7748a UX: Adjust spacing between simple tags in the site settings preview (#32125)
### Before

![image](https://github.com/user-attachments/assets/27afb534-cac3-4573-9be7-a5608f1dc498)


### After
<img width="635" alt="image"
src="https://github.com/user-attachments/assets/999aca40-5488-41f0-8887-01584ce425a4"
/>
2025-04-02 07:10:12 -06:00
8525de7e55 DEV: [gjs-codemod] add codemod commit to git-blame-ignore-revs 2025-04-02 13:44:33 +01:00
999ae73c78 DEV: [gjs-codemod] apply codemod
Co-authored-by: Jarek Radosz <jarek@cvx.dev>
2025-04-02 13:44:15 +01:00
dac398d6ab DEV: [gjs-codemod] merge js and hbs 2025-04-02 13:43:33 +01:00
1c8019a3c7 DEV: [gjs-codemod] renamed hbs to gjs 2025-04-02 13:43:32 +01:00
386bb974d1 DEV: [gjs-codemod] renamed js to gjs 2025-04-02 13:43:28 +01:00
0cb08a3d2f DEV: Double timeout in spec/email_change_spec.rb (#32131)
Checking of the database state is still flaky on CI. Double the timeout
to give the server more time to process as a workaround.

Example of test flake:
https://github.com/discourse/discourse/actions/runs/14216968060/job/39835831706
2025-04-02 20:10:57 +08:00
c1f0d9aee0 Build(deps-dev): Bump @ember/test-helpers from 5.2.0 to 5.2.1 (#32115)
Bumps
[@ember/test-helpers](https://github.com/emberjs/ember-test-helpers)
from 5.2.0 to 5.2.1.
- [Release
notes](https://github.com/emberjs/ember-test-helpers/releases)
-
[Changelog](https://github.com/emberjs/ember-test-helpers/blob/master/CHANGELOG.md)
- [Commits](https://github.com/emberjs/ember-test-helpers/commits)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-02 13:54:44 +02:00
040bcf69f3 Build(deps-dev): Bump esbuild from 0.25.1 to 0.25.2 (#32067)
Bumps [esbuild](https://github.com/evanw/esbuild) from 0.25.1 to 0.25.2.
- [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.25.1...v0.25.2)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-02 13:33:06 +02:00
1d65ebe3bb UX: Adjust spacing to prevent last setting from being hidden behind save all banner (#32127)
This PR adjusts the bottom spacing in the site settings when scrolled to
the bottom and the “Save all changes” banner is visible, ensuring that
the setting controls and helper text are fully visible within the
viewport.

### Before
<img width="954" alt="image"
src="https://github.com/user-attachments/assets/69d8b1ad-e90e-4d94-9f32-4a8ae17ef725"
/>


### After
<img width="937" alt="image"
src="https://github.com/user-attachments/assets/50365613-8553-4354-a8f3-71d834898583"
/>
2025-04-02 05:31:35 -06:00
c96e7aa723 DEV: Fix the enable_current_plugin spec helper
Some plugins are always enabled and don’t have a related site setting.
This patch takes this into account.
2025-04-02 12:30:46 +02:00
116a72504b UX: rename Twitter login button to X (#32123)
Before:

<img width="234" alt="Screenshot 2025-04-02 at 1 15 25 PM"
src="https://github.com/user-attachments/assets/1f852543-38d7-45d3-96d3-df6a8a7e3623"
/>

After:

<img width="184" alt="Screenshot 2025-04-02 at 1 20 41 PM"
src="https://github.com/user-attachments/assets/6bf9428f-2152-45a1-8215-ae006ce4f356"
/>
2025-04-02 15:35:59 +05:30
Sam
c0cf898c10 FEATURE: when rich-editor is enabled use Jetbrains Mono as code font (#32122)
This change forces consistency around code font in Discourse once the
new
rich-editor is enabled

- This means all code blocks in Discourse will render with this font
- Additionally the markdown mode composer will render with this font

Additionally we make 3 small adjustments:

1. We disable ligatures which conflict with typographer
2. We add support for custom ligature settings
3. We adjust down font size, cause 14px ends up matching visually with a
16px non monospace font, this change is already in place previously on
posts

Example:


![image](https://github.com/user-attachments/assets/eca0b544-f3a4-4172-b2af-b39a3c0208e7)
2025-04-02 16:36:52 +11:00
e4244cca35 PERF: Set cluster_concurrency 1 for Jobs::BackfillBadge (#32121)
Since 3e4eac0fed05daedcdea50d6275e143469d55eda, the daily
`Jobs::BadgeGrant` scheduled job enqueues one `Jobs::BackfillBadge`
job per enabled badge. This can become problematic on large sites that
have alot of enabled badges as the long running queries executed by each
`Jobs::BackfillBadge` job may end up exhausting all available
database connections in a short span of time. To combat this, we are
limiting the `cluster_concurrency` of the `Jobs::BackfillBadge` job to
`1`.
2025-04-02 11:23:32 +08:00
cfd539a539 DEV: Fix a flaky system test by doubling timeout (#32117)
The system test relies on a MessageBus message being published and
received by the client. As we currently don't have a reliable way to
ensure that we run an assertion after the client has received all
MessageBus messages, we will just double the timeout for now.
2025-04-02 11:02:05 +08:00
35850b35f4 FIX: invite_link_max_redemptions_limit min 1 (#32118)
When the feature was designed in 2020, it had two options: invite a
single user or generate a link.

https://github.com/discourse/discourse/pull/9813

With simplified interface, it makes sense to allow to send a link to
just 1 user.

Meta:
https://meta.discourse.org/t/unable-to-restrict-invite-link-to-one-person/359872
2025-04-02 10:54:46 +08:00
0f3d61b463 DEV: Use Capybara::Session#using_wait_time instead (#32116)
When `Capybara.threadsafe` has been set to `true` as in our case, we
have to use `Capybara::Session#using_wait_time` instead of
`Capybara.using_wait_time`. The latter sets `default_max_wait_time` on
`Capybara.default_max_wait_time` while the former sets
`default_max_wait_time` on the session.
2025-04-02 09:11:26 +08:00
72c837bc98 Build(deps-dev): Bump rubocop-rails from 2.30.3 to 2.31.0 (#32112)
Bumps [rubocop-rails](https://github.com/rubocop/rubocop-rails) from
2.30.3 to 2.31.0.
- [Release notes](https://github.com/rubocop/rubocop-rails/releases)
-
[Changelog](https://github.com/rubocop/rubocop-rails/blob/master/CHANGELOG.md)
-
[Commits](https://github.com/rubocop/rubocop-rails/compare/v2.30.3...v2.31.0)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-02 01:33:28 +02:00
211b1872ae Build(deps-dev): Bump @swc/core from 1.11.13 to 1.11.16 (#32114)
Bumps [@swc/core](https://github.com/swc-project/swc) from 1.11.13 to
1.11.16.
- [Release notes](https://github.com/swc-project/swc/releases)
- [Changelog](https://github.com/swc-project/swc/blob/main/CHANGELOG.md)
-
[Commits](https://github.com/swc-project/swc/compare/v1.11.13...v1.11.16)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-02 01:27:46 +02:00
e57ae1f386 Build(deps-dev): Bump puppeteer-core from 24.4.0 to 24.5.0 (#32113)
Bumps [puppeteer-core](https://github.com/puppeteer/puppeteer) from
24.4.0 to 24.5.0.
- [Release notes](https://github.com/puppeteer/puppeteer/releases)
-
[Changelog](https://github.com/puppeteer/puppeteer/blob/main/CHANGELOG.md)
-
[Commits](https://github.com/puppeteer/puppeteer/compare/puppeteer-core-v24.4.0...puppeteer-core-v24.5.0)

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Discourse CI <ci@ci.invalid>
2025-04-02 01:27:27 +02:00
e68fef0b4c UX: Wrap edit category subcategories (#32110)
### Issue
In the **edit category settings**, if the category has a large amount of
subcategories, the layout can spill outside the normal content area.

![image](https://github.com/user-attachments/assets/388d0f47-7054-4f6e-85cb-c648df126ee0)

### Solution
Add `flex-wrap: wrap` to form kit container content within edit
category.

![image](https://github.com/user-attachments/assets/a2b51a64-cd6d-423d-9ac6-3230445ed8cf)
2025-04-01 15:37:28 -04:00
c61b19e244 DEV: Update final {{raw}} usages (#32082) 2025-04-01 18:39:42 +01:00