Commit Graph

57399 Commits

Author SHA1 Message Date
Osama Sayegh 3187606d34
FEATURE: Add option to hide full name input at signup (#30471)
This commit replaces the `full_name_required` setting with a new `full_name_requirement` setting to allow more flexibility with the name field in the signup form. The new setting has 2 options, "Required at signup" and "Optional at signup", which are equivalent to the true/false possibilities of the old setting, and a third option "Hidden at signup" that hides the name field from the signup form, making it effectively optional too.

New sites will have the "Hidden at signup" option as the default option, and existing site will continue to use the option that maps to their current configuration.

Internal topic: t/136746.
2024-12-30 22:26:20 +03:00
Sérgio Saquetim b728b74c49
DEV: Add showLogin action to post menu buttons and prevent text selection (#30500)
This commit adds `showLogin` as an available action to the post menu buttons. They can use this action to show the login form when there is no user logged in.

It also adds a small CSS tweak to prevent the content from the post menu to being user selectable. This was causing small UX issues in touch devices.
2024-12-30 15:57:07 -03:00
Angus McLeod ce7a14104b
Add user api key client rate limit settings (#30402) 2024-12-30 11:10:48 -05:00
Renato Atilio 9a22e8d2f1
DEV: fix cancel swipe callback typo (#30491) 2024-12-30 12:45:06 -03:00
communiteq bc3b38db19
FIX: correct topics and posts count in import:ensure_consistency rake task (#30104)
After running the rake task the post and topics counts where way off. When investigating, I found this six-year-old #TODO. It was an easy fix.
2024-12-30 15:15:18 +01:00
David Taylor bf35f7f860
DEV: Add deprecations for topic-status raw-view modifications (#30496)
This will make the 'auto' glimmer-topic-list feature aware of these modifications, so that the new topic-list will not be enabled until they're resolved.
2024-12-30 11:35:23 +00:00
David Taylor 9c83872a4e
PERF: Refactor and optimize splash screen implementation (#30373)
- Remove JS

- Remove "Loading..." text. This has been been broken for a while due to some conflicting discourse-ai CSS. Also, animating the `content:` property like this requires the browser to repaint/reflow, which cannot be done while JS is executing.

- Replace animated SVG with divs animated via CSS. When JS is executing, browsers pause animations of transform properties inside SVGs. This limitation does not exist on regular CSS animations. So with this change, the animation continues smoothly even you run an infinite loop in JS.

  To ensure the splash screen remains "contentful" for LCP purposes, an SVG background-image is used

There is no change to the visual look of the animation
2024-12-30 11:31:08 +00:00
Gary Pendergast 92793c5b73
DEV: Ensure all site settings have a keyword entry (#30485) 2024-12-30 12:22:55 +11:00
chapoi 1312563fac
DEV: add plugin outlet to user-menu tabs (#30468) 2024-12-30 02:17:46 +01:00
dependabot[bot] 0c60575634
Build(deps): Bump oj from 3.16.8 to 3.16.9 (#30495)
Bumps [oj](https://github.com/ohler55/oj) from 3.16.8 to 3.16.9.
- [Release notes](https://github.com/ohler55/oj/releases)
- [Changelog](https://github.com/ohler55/oj/blob/develop/CHANGELOG.md)
- [Commits](https://github.com/ohler55/oj/compare/v3.16.8...v3.16.9)

---
updated-dependencies:
- dependency-name: oj
  dependency-type: direct:production
  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-12-30 07:10:32 +08:00
Joffrey JAFFEUX e9d4afec53
DEV: simplify restore message spec (#30490)
This spec was flaky, by not using a second session and rely on services instead, I hope to make it more stable and faster.
2024-12-28 15:27:12 +01:00
Alan Guo Xiang Tan cf9709ef16
DEV: Run tests workflow using `discourse/discourse_test:release` image
This commit updates the tests workflow to use the `discourse/discourse_test:release` image. This allows us to drop the some usage of Github actions cache which can be quite slow to fetch from our self hosted runners.
2024-12-28 07:39:31 +08:00
Jordan Vidrine def0d13cd9
UX: Hide before-header-panel-outlet on login page (#30472) 2024-12-27 06:07:29 -06:00
Alan Guo Xiang Tan a78028e54e
DEV: Run one system test process per CPU core (#30484)
We are running on self hosted runners with more CPU and RAM so we should
be able to run one system test process per CPU core for more speedz.

This may lead to some instability in our system tests but it is hard to say unless we roll this change out. If it does lead to system tests being more unstable, we can easily roll back the change.
2024-12-27 18:43:45 +08:00
Alan Guo Xiang Tan cad56e2a21
DEV: Support a `perform_when_readonly` option for `Jobs::Scheduled` (#30478)
This is useful for scheduled jobs that should be performed even when
`Discourse.readonly_mode?` is `true`.
2024-12-27 09:42:40 +08:00
Alan Guo Xiang Tan 56ac103547
DEV: Copy gems from Docker image in Github actions tests workflow
On our own self hosted runners, pulling from github actions cache is quite slow and can take up to 20 seconds for the `bundler cache` step. Instead, we will now copy the gems from the `/var/www/discourse/vendor/bundle` folder in the `discourse/discourse_test:release` image which is built daily. This eliminates the need to pull from Github actions cache and also potentially reduces our costs of cache storage.

Note that `discourse/discourse_test:release` is pulled periodically on our self hosted runners so there is no impact on the time it takes to initialize the container.
2024-12-27 08:31:01 +08:00
Arpit Jalan bf3279d75a
FEATURE: support adobe analytics tags tracking (#30433)
https://experienceleague.adobe.com/en/docs/experience-platform/tags/home

https://experienceleague.adobe.com/en/docs/platform-learn/implement-in-websites/configure-tags/add-embed-code
2024-12-26 15:25:48 +05:30
Alan Guo Xiang Tan 061d6fd7a7
DEV: Remove log messages that are redundant (#30466)
I think the log messages were used for initial production trials but the
log messages are actually not very useful in the grand scheme of things.
If the timing of the job is important information, one can get it by
enabling Sidekiq logging and obtain the information from there. There is
no need for us to flood the logs with these messages.

Also the messages will contain at most 100 ids so it is just alot of
noise in general.
2024-12-26 09:54:09 +08:00
Alan Guo Xiang Tan e4cab1c60b
DEV: Set `Jobs::SyncAclsForUploads` to low queue (#30467)
This job is not mission critical and should not clog the default queue
2024-12-26 09:54:02 +08:00
chapoi 61e5431d2a
Hide before-header-panel-outlet on signup/login pages (#30432) 2024-12-26 01:39:26 +01:00
dependabot[bot] e4d0e0d95c
Build(deps-dev): Bump sqlite3 from 2.4.1 to 2.5.0 (#30461)
Bumps [sqlite3](https://github.com/sparklemotion/sqlite3-ruby) from 2.4.1 to 2.5.0.
- [Release notes](https://github.com/sparklemotion/sqlite3-ruby/releases)
- [Changelog](https://github.com/sparklemotion/sqlite3-ruby/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sparklemotion/sqlite3-ruby/compare/v2.4.1...v2.5.0)

---
updated-dependencies:
- dependency-name: sqlite3
  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-12-26 06:19:34 +08:00
dependabot[bot] f6bb371498
Build(deps-dev): Bump rubocop-rails from 2.27.0 to 2.28.0 (#30460)
Bumps [rubocop-rails](https://github.com/rubocop/rubocop-rails) from 2.27.0 to 2.28.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.27.0...v2.28.0)

---
updated-dependencies:
- dependency-name: rubocop-rails
  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-12-26 06:19:18 +08:00
dependabot[bot] 4ccbf5c5ad
Build(deps): Bump rack-test from 2.1.0 to 2.2.0 (#30457)
Bumps [rack-test](https://github.com/rack/rack-test) from 2.1.0 to 2.2.0.
- [Release notes](https://github.com/rack/rack-test/releases)
- [Changelog](https://github.com/rack/rack-test/blob/main/History.md)
- [Commits](https://github.com/rack/rack-test/compare/v2.1.0...v2.2.0)

---
updated-dependencies:
- dependency-name: rack-test
  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-12-24 09:23:13 +08:00
Jarek Radosz c6dd33cc06
DEV: Convert ResponsiveTable to gjs (#30430) 2024-12-23 21:50:13 +01:00
Jordan Vidrine e90a92b298
fix (#30452) 2024-12-23 14:30:58 -06:00
Joffrey JAFFEUX 4e5fc4654c
DEV: fixes safari bug with content including linebreaks (#30451) 2024-12-23 18:39:28 +01:00
Mark VanLandingham df1fc5bca8
FIX: Consistently notify lowest post number if post_moved notification generation (#30448)
We currently query the posts table without an order when notifying users of moved posts. Generally the query will return the lowest post number post (b/c ID correlates with post_number in most cases) but not always. This adds an order to the post query in notify_moved_posts job.

Also I removed some if statement nesting with early returns / guard clauses.
2024-12-23 09:53:43 -06:00
Jordan Vidrine d69b7da3ca
fix (#30450) 2024-12-23 09:42:55 -06:00
Jarek Radosz c3548aec5e
DEV: Don't use 0-delay for test-env discourseLater (#30442)
`discourseLater` automatically uses delay of 10ms in test environment
2024-12-23 16:31:46 +01:00
Jarek Radosz d0e38977e3
UX: Remove chat hover effect from github status badge (#30447) 2024-12-23 16:31:29 +01:00
Jarek Radosz c1818bf40e
DEV: Update a topic test to use `settled` (#30443)
…instead of `next()`/`assert.async()/done()`
2024-12-23 15:49:38 +01:00
Joffrey JAFFEUX 3198326cda
DEV: ensures channel has been created (#30445)
We were sometimes trying to fetch the channel before it has been created.
2024-12-23 13:54:22 +01:00
Joffrey JAFFEUX ae4a4b7d00
DEV: waits for mark_read! to be applied (#30444) 2024-12-23 13:54:13 +01:00
Joffrey JAFFEUX 96b5c28cf9
DEV: correct test to visit category channel and not DM (#30441) 2024-12-23 13:36:02 +01:00
Joffrey JAFFEUX cf26d3f211
DEV: uses capybara helper has_field (#30438)
Checking for value of input directly is not waiting for value to be present.
2024-12-23 13:25:17 +01:00
David Taylor 1f46aed27e
DEV: Automatically set LOAD_PLUGINS for bin/rspec (#30437)
When passing a `plugins/...` path to bin/rspec, it's reasonable to assume that the developer wants the tests to be run with plugins loaded. This commit automatically takes care of that.

If `LOAD_PLUGINS` is explicitly specified, then that value will always be used.

This mimics the logic we already have for database migrations in the `bin/rake` stub
2024-12-23 11:56:10 +00:00
Joffrey JAFFEUX c601b4112e
DEV: no services are used in this component (#30439) 2024-12-23 12:47:53 +01:00
David Taylor 5962373ab9
FEATURE: Unhide 'suppress_secured_categories_from_admin' setting (#30436)
This setting suppresses topics and PMs from the admin UI unless they are participants. This is not a security feature: admins can always access all content on the site if needed.
2024-12-23 11:03:01 +00:00
Osama Sayegh e2cd1da26d
FIX: All admins should be allowed to see deleted PM posts regardless of their mod status (#30206)
Admins and moderators can see a user's deleted posts via the `/u/:username/deleted-posts` route. Admins can always see any post on the site, but that's not always the case for moderators, e.g., they can't see all PMs. So, this route accounts for that and excludes posts that a moderator wouldn't be allowed to see if they were not deleted.

However, there's currently a problem with that logic where admins who also have moderation privileges, are treated the same way as moderators and prevented from seeing posts that pure moderators can't see. This commit fixes that problem and only applies the permission checks to moderators who don't have admin privileges.

Internal topic: t/143107.
2024-12-23 12:48:03 +03:00
dependabot[bot] b7971e17c2
Build(deps): Bump net-imap from 0.5.3 to 0.5.4 (#30431)
Bumps [net-imap](https://github.com/ruby/net-imap) from 0.5.3 to 0.5.4.
- [Release notes](https://github.com/ruby/net-imap/releases)
- [Commits](https://github.com/ruby/net-imap/compare/v0.5.3...v0.5.4)

---
updated-dependencies:
- dependency-name: net-imap
  dependency-type: direct:production
  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-12-23 09:41:53 +01:00
dependabot[bot] 7b5132b0f2
Build(deps-dev): Bump jsuites from 5.8.0 to 5.8.3 (#30422)
Bumps [jsuites](https://github.com/jsuites/jsuites) from 5.8.0 to 5.8.3.
- [Release notes](https://github.com/jsuites/jsuites/releases)
- [Changelog](https://github.com/jsuites/jsuites/blob/master/changelog.md)
- [Commits](https://github.com/jsuites/jsuites/commits)

---
updated-dependencies:
- dependency-name: jsuites
  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-12-23 09:41:22 +01:00
dependabot[bot] 7a9b2e343c
Build(deps): Bump mini_scheduler from 0.17.0 to 0.18.0 (#30424)
Bumps [mini_scheduler](https://github.com/discourse/mini_scheduler) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/discourse/mini_scheduler/blob/main/CHANGELOG.md)
- [Commits](https://github.com/discourse/mini_scheduler/compare/v0.17.0...v0.18.0)

---
updated-dependencies:
- dependency-name: mini_scheduler
  dependency-type: direct:production
  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-12-23 09:11:41 +01:00
Jarek Radosz 3c95aceeb0
DEV: Unify on-resize modifier situation (#30415)
1. Move chat's on-resize to core
2. Remove ember-on-resize-modifier
2024-12-23 09:11:17 +01:00
dependabot[bot] e58579a8d3
Build(deps): Bump openssl from 3.2.1 to 3.3.0 (#30423)
Bumps [openssl](https://github.com/ruby/openssl) from 3.2.1 to 3.3.0.
- [Release notes](https://github.com/ruby/openssl/releases)
- [Changelog](https://github.com/ruby/openssl/blob/master/History.md)
- [Commits](https://github.com/ruby/openssl/compare/v3.2.1...v3.3.0)

---
updated-dependencies:
- dependency-name: openssl
  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-12-23 09:10:26 +01:00
Jarek Radosz 7b9d484bf4
DEV: Group highlight.js updates (#30426)
(and fix a typo)
2024-12-23 09:09:55 +01:00
Jarek Radosz 6175562cb2
DEV: Convert HighlightSearch to gjs (#30406) 2024-12-23 08:54:59 +01:00
Jarek Radosz df9de3022f
DEV: Convert ChooseMessage to gjs (#30408) 2024-12-23 08:47:15 +01:00
Jarek Radosz 0336235c74
DEV: Use object spread instead of Object.assign (#30407) 2024-12-23 08:44:29 +01:00
Jarek Radosz 6f01584607
DEV: Convert DirectoryTable to gjs (#30414)
* DEV: Convert DirectoryTable to gjs

* rename + remove
2024-12-23 16:44:26 +11:00
chapoi 5b989fd5ae
UX: add highlight for active nav in category settings (#30428) 2024-12-23 06:10:48 +01:00