Commit Graph

58292 Commits

Author SHA1 Message Date
23dd5c20d3 Build(deps-dev): Bump ember-cli-deprecation-workflow from 3.1.0 to 3.2.0 (#31682)
Bumps
[ember-cli-deprecation-workflow](https://github.com/ember-cli/ember-cli-deprecation-workflow)
from 3.1.0 to 3.2.0.
- [Release
notes](https://github.com/ember-cli/ember-cli-deprecation-workflow/releases)
-
[Changelog](https://github.com/ember-cli/ember-cli-deprecation-workflow/blob/main/CHANGELOG.md)
-
[Commits](https://github.com/ember-cli/ember-cli-deprecation-workflow/commits)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-06 23:56:17 +01:00
0976e4ad18 Build(deps-dev): Bump ember-cli from 6.2.2 to 6.2.3 (#31680)
Bumps [ember-cli](https://github.com/ember-cli/ember-cli) from 6.2.2 to
6.2.3.
- [Release notes](https://github.com/ember-cli/ember-cli/releases)
-
[Changelog](https://github.com/ember-cli/ember-cli/blob/master/CHANGELOG.md)
-
[Commits](https://github.com/ember-cli/ember-cli/compare/v6.2.2...v6.2.3)

---------

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-03-06 23:55:16 +01:00
1abc5870c3 Build(deps): Bump aws-eventstream from 1.3.1 to 1.3.2 (#31684)
Bumps [aws-eventstream](https://github.com/aws/aws-sdk-ruby) from 1.3.1
to 1.3.2.
- [Release notes](https://github.com/aws/aws-sdk-ruby/releases)
-
[Changelog](https://github.com/aws/aws-sdk-ruby/blob/version-3/gems/aws-eventstream/CHANGELOG.md)
- [Commits](https://github.com/aws/aws-sdk-ruby/compare/1.3.1...1.3.2)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-06 23:23:36 +01:00
1b95a8e1e0 DEV: replace zero width space character in chat typing indicator (#31675)
We were using a zero width space added by CSS here, but have run into
occasional encoding issues for some reason? a couple people have
reported getting this instead of an empty space:


![image](https://github.com/user-attachments/assets/da39b5f5-61b0-423c-ae3e-18169e4f2f71)

I can't repro the issue, but we can avoid it by removing this space in
CSS — setting the container height to `1em` along with `line-height:
normal` should make it consistent with the height of the text within.

In the blame it seems this static height on the container was added
after the pseudo hack, and achieves the same goal when I test it across
a Firefox/Chrome/Safari
2025-03-06 15:53:50 -05:00
41eb83a401 DEV: Add body class when bulk select is enabled (#31677) 2025-03-06 14:53:32 -06:00
5b092d4466 FIX: ensures emoji picker loader is centered (#31676)
before:
![Screenshot 2025-03-06 at 21 04
32](https://github.com/user-attachments/assets/080d188b-f3ad-48a6-aee7-e8d4be36d407)

after:
![Screenshot 2025-03-06 at 21 04
28](https://github.com/user-attachments/assets/6e131e66-7cc4-45e3-a783-d2774dbf92b4)
2025-03-06 21:19:01 +01:00
dc9269eee5 FEATURE: Handle youtube live url format (#31673)
Meta:
https://meta.discourse.org/t/youtube-autoembeds-for-live-streams/350920

This PR supports YouTube live URLs, such as:
`https://www.youtube.com/live/eJemwqO0SDw`.


![image](https://github.com/user-attachments/assets/b7e57857-5676-4dcf-862e-1e4b4e594009)

![image](https://github.com/user-attachments/assets/f5e6f2d0-a158-41c6-bc20-0642868dbef8)
2025-03-06 15:43:38 -03:00
0e8d36d080 DEV: Fixup theme detection for template-override deprecation (#31672) 2025-03-06 16:46:06 +00:00
fb76696f45 UX: removes per channel context of favorites emojis (#31671)
This was confusing users.
2025-03-06 16:07:58 +01:00
ac736ec0ca DEV: merge mobile stylesheets into common with breakpoints (#31656)
This is the beginning of a longer process to merge our stylesheets under
the common directory.

I also converted a SCSS variable to a CSS custom property along the way.

In the case of the lightbox styles, this seemed more appropriate to
distinguish by primary input type (touch vs mouse) rather than
breakpoint sizes.
2025-03-06 08:44:54 -05:00
9dd26a3954 DEV: discourse-emojis 1.0.32 (#31669)
This gems bring a whole improved fluentui emoji set. Each image has been
recomputed to optimise the size of the emoji and remove useless margins.

For this reason the version has been bumped.

Other changes:
- not loading rake task dependencies in production
- renamed yo_yo/yo-yo to yoyo
2025-03-06 10:35:04 +01:00
3b8b21631b UX: Remove fa- prefix in svg_icon_subset setting description (#31581)
Based on the discussion in
https://github.com/discourse/discourse-social-share/pull/24#discussion_r1975633090
I think "fa-" is no longer needed in core either.
2025-03-06 17:27:48 +11:00
c6b4a09ad9 UX: remove padding in admin card section (#31666)
Before
<img width="1064" alt="Screenshot 2025-03-06 at 3 05 55 pm"
src="https://github.com/user-attachments/assets/38acc2cd-1204-42ec-aac7-18dfee32e8bc"
/>


After
<img width="949" alt="Screenshot 2025-03-06 at 3 06 44 pm"
src="https://github.com/user-attachments/assets/ded3c81f-8057-483d-b997-d1983ccf1318"
/>
2025-03-06 16:35:25 +11:00
ba19430286 DEV: Add a PluginOutlet for mobile-view topic activity number (#31567)
This commit adds a PluginOutlet for activity number in mobile view, so I
can override it with my theme component.

Why?
======

In this theme component
https://meta.discourse.org/t/show-both-op-and-last-reply-on-mobile/267944,
I need to add an avatar to the post time to indicate the last poster.


![image](https://github.com/user-attachments/assets/a33ff8ed-50c6-4bc4-a093-115578ad9bad)

Without this outlet, I can't do this, having to rewrite the entire
`item.gjs`, or use some vanilla JavaScript tricks to do it.

---------

Co-authored-by: Alan Guo Xiang Tan <gxtan1990@gmail.com>
2025-03-06 10:50:43 +08:00
f024bc4c6f FIX: Ensure the reviewable.type_source migration is run post-deploy. (#31663)
When the upgrade process from 29a8c6ee498999f114f933d2de2b46989a407660 is run, there's a deployment race condition where old code can write a Reviewable to the database without a `type_source` (incorrectly defaulting it to "unknown").

This change adds a post-deploy migration script that populates any such Reviewables with the correct `type_source` value.
2025-03-06 12:12:46 +11:00
bbc1c2726c Revert "DEV: discourse-emojis 1.0.31 (#31655)" (#31662)
This reverts commit 7e65cdbc9aa86677a2f6f7a8d4f1b8e87da07ff1.

It broke the production build, as it's trying to load
`selenium-webdriver` (a dev dep) in the production env.
2025-03-06 00:40:01 +01:00
6882453ab7 UX: card section toggle (#31644)
Demo

https://github.com/user-attachments/assets/17e2b6d9-ba49-4312-85d9-6ff2ccad2290
2025-03-06 10:31:29 +11:00
f6860dcb92 DEV: Remove installing minio binaries in tests workflow (#31652)
In the `discourse/discourse_test:release` base image, the minio binaries
are already being installed and updated on a daily basis. There is also
no
real need for us to have to run the latest minio binaries once it is
released. As such, we can drop the step in the `tests` workflow.
2025-03-06 10:04:07 +11:00
593f4f7592 Build(deps-dev): Bump ember-exam from 9.0.0 to 9.1.0 (#31660)
Bumps [ember-exam](https://github.com/ember-cli/ember-exam) from 9.0.0
to 9.1.0.
- [Release notes](https://github.com/ember-cli/ember-exam/releases)
-
[Changelog](https://github.com/ember-cli/ember-exam/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ember-cli/ember-exam/commits)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-05 23:40:29 +01:00
1a25f99e13 Build(deps): Bump google-protobuf from 4.29.3 to 4.30.0 (#31658)
Bumps [google-protobuf](https://github.com/protocolbuffers/protobuf)
from 4.29.3 to 4.30.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/v4.30.0)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-05 23:38:58 +01:00
e29c235281 Build(deps-dev): Bump parallel_tests from 5.0.0 to 5.0.1 (#31657)
Bumps [parallel_tests](https://github.com/grosser/parallel_tests) from
5.0.0 to 5.0.1.
-
[Changelog](https://github.com/grosser/parallel_tests/blob/master/CHANGELOG.md)
-
[Commits](https://github.com/grosser/parallel_tests/compare/v5.0.0...v5.0.1)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-05 23:37:28 +01:00
7e65cdbc9a DEV: discourse-emojis 1.0.31 (#31655)
This gems bring a whole improved fluentui emoji set. Each image has been
recomputed to optimize the size of the emoji and remove useless margins.

For this reason the version has been bumped.

Other notable change: the emoji yo-yo can now be called "yoyo".
2025-03-05 21:49:18 +01:00
faa985bf28 DEV: Add search_result_view app event to SearchMenu (#31632)
For plugins/themes to be able to hook into after search result review is
rendered
2025-03-05 12:20:56 -06:00
f9e4ac94f5 DEV: Add a new behavior transformer to topic list item click (#31653)
- Add the behavior transformer `topic-list-item-click` to allow the
customization for the click behavior on the topic list item.
2025-03-05 15:15:17 -03:00
299b1b42ec DEV: Reduce the use of self/set in tests (#31648)
still lots to update but it's a start
2025-03-05 13:10:20 +01:00
0684ac64f2 DEV: Remove the deprecated componentTest helper (#31649) 2025-03-05 12:50:12 +01:00
95939ca499 DEV: set field type in control wrapper (#31647)
Calling `<field.Calendar>` will ultimately call `componentFor` which
will mutate the type of the field. Problem is the way we use a hash to
define all the available controls, would work correctly on first render,
but because of the mutation in `componentFor` if something would trigger
a re-render it would have to evaluate all the `componentFor` calls, and
the last one would "win" (currently calendar), which would mean that a
field rendered as custom would for example become calendar.

The easiest repro was:

```gjs
<Form as |form|>
  <form.field as |field|>
    {{log field}}
    <field.Custom>
      Hello world
    </field.Custom>
  </form.field>
</Form>
```

The fix for now is to mutate the value at the point where the component
is actually rendered, in control-wrapper.

A possibly more correct longer term fix could be to change the API, to
set the type on the field when defined in the template, and render a
generic component which would use this type to know what to render:

```gjs
<form.field @type="calendar" as |field|>
  <field.Control @someCalendarOption="bar" />
</form.field>
```
2025-03-05 11:43:53 +01:00
ba262733a6 A11Y: Improve contrast for FormKit help text and optional text (#31645) 2025-03-04 22:29:15 -07:00
305039b1c3 DEV: ensure Rails application default headers are present in responses (#31619)
Follow up from https://github.com/discourse/discourse/pull/31559.

We expect some standard headers to be added from
`Rails.application.config.action_dispatch.default_headers` for
responses, however these were found to be removed in some error paths. 
For more detail on this behaviour, refer to https://github.com/discourse/discourse/pull/31619#issuecomment-2699644232.

This PR adds those headers back if they aren't there, with the caveats
that we don't add headers that are irrelevant for non-HTML responses,
and neither do we add X-Frame-Options which is intentionally removed for
embeddables.
2025-03-05 13:19:09 +08:00
63213398bf UX: Add left border to indented field and update caret for consistency (#31643)
* Added a subtle left border to the indented field to improve visual
hierarchy
* Updated the caret to align with other expandable elements for
consistency
2025-03-05 14:29:51 +11:00
e4401e587e FIX: Ensure queued posts with watched words are processed correctly. (#31641)
This change ensures that queued posts that have ended up in the review queue due to matched a watched word display correctly.

It also improves the data checking to ensure that any other reviewables with watched words don't break the review queue, either.
2025-03-05 13:59:42 +11:00
223b40de1c FEATURE: Store composer version and device info on post stat (#31600)
We are developing our new composer, and it would be useful
if we could know how posts are being created by members.

To this end, we are going to start storing the following
on post_stats, which are created at the same time as a post
is created:

* writing_device - Based on `BrowserDetection.device`, which in
  turn is based on user agent. Will store .e.g iphone, android,
  mac, windows etc.
* writing_user_agent - Stores the full user agent (truncated at
  400 chars) of the device/browser the member used to write the post.
* composer_version - Either `1` for our old composer, or
  `2` if the new rich composer is enabled in site settings and
  the user has toggled it on
2025-03-05 12:48:32 +10:00
702a2a9cbc UX: display html tags in silence reason (#31598)
Allow HTML tags in silence reason. Tags must be stripped for title
attribute.

Before

![image](https://github.com/user-attachments/assets/05d9819a-9dbf-46b2-b9c5-88187ca9af5b)


After
<img width="1079" alt="Screenshot 2025-03-04 at 11 39 05 am"
src="https://github.com/user-attachments/assets/2bb41deb-227c-47a8-b840-b0316a764252"
/>
<img width="1096" alt="Screenshot 2025-03-04 at 11 39 22 am"
src="https://github.com/user-attachments/assets/02e27fc0-317e-43df-bce8-6b68e48ac40e"
/>
2025-03-05 12:43:03 +11:00
828fcb1ad3 DEV: Add rake task to bulk delete posts (#31642)
Same as #31576, but in that one I added some support files that turned out to be unnecessary and broke the build. So this is the re-do. 🙏
2025-03-05 09:31:23 +08:00
Sam
503645dc34 DEV: bump to major release of mini_racer (#31640)
Only notable changes is that we added
internal support for TimeWithZone which
was absent from previous release

We also improved error messages for T_OBJECT
2025-03-05 12:06:36 +11:00
72ba574d6f DEV: Convert tests using the gjs codemod (#31625)
```sh
pnpm dlx @embroider/template-tag-codemod@alpha --relativeLocalPaths=false --nativeRouteTemplates=false --nativeLexicalThis=false --templateInsertion="end"
```
2025-03-05 01:37:30 +01:00
28e00d9bfe DEV: Update lint-configs and autofix issues (#31620)
This updates us to Prettier 3.x
2025-03-05 01:20:16 +01:00
f8b30ffd06 Build(deps-dev): Bump @swc/core from 1.11.5 to 1.11.7 (#31636)
Bumps [@swc/core](https://github.com/swc-project/swc) from 1.11.5 to
1.11.7.
- [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.5...v1.11.7)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-05 00:26:30 +01:00
143550a93b Build(deps-dev): Bump babel-import-util from 3.0.0 to 3.0.1 (#31635)
Bumps [babel-import-util](https://github.com/ef4/babel-import-util) from
3.0.0 to 3.0.1.
- [Release notes](https://github.com/ef4/babel-import-util/releases)
-
[Changelog](https://github.com/ef4/babel-import-util/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ef4/babel-import-util/commits)

---------

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-03-05 00:03:22 +01:00
c1d9887ead FIX: only show small user list if users has length (#31631)
Need to check length here so we're not exposing the component when there
are no users, fixes:
https://meta.discourse.org/t/expanding-topic-actions-displays-who-liked-the-posts-but-nobody-has-liked-it/355225

follow-up to
5312550bf9
2025-03-04 16:50:41 -05:00
1e1fae38b5 Build(deps-dev): Bump parallel_tests from 4.9.1 to 5.0.0 (#31630)
Bumps [parallel_tests](https://github.com/grosser/parallel_tests) from
4.9.1 to 5.0.0.
-
[Changelog](https://github.com/grosser/parallel_tests/blob/master/CHANGELOG.md)
-
[Commits](https://github.com/grosser/parallel_tests/compare/v4.9.1...v5.0.0)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-04 22:47:56 +01:00
ba3f1577d4 Build(deps-dev): Bump rubocop-discourse from 3.10.0 to 3.11.0 (#31627)
Bumps
[rubocop-discourse](https://github.com/discourse/rubocop-discourse) from
3.10.0 to 3.11.0.
-
[Commits](https://github.com/discourse/rubocop-discourse/compare/v3.10.0...v3.11.0)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-04 22:40:10 +01:00
1f93d3e36e Build(deps-dev): Bump rubocop-rails from 2.30.2 to 2.30.3 (#31628)
Bumps [rubocop-rails](https://github.com/rubocop/rubocop-rails) from
2.30.2 to 2.30.3.
- [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.2...v2.30.3)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-04 22:39:22 +01:00
b270d541ff Build(deps-dev): Bump rubocop from 1.73.1 to 1.73.2 (#31629)
Bumps [rubocop](https://github.com/rubocop/rubocop) from 1.73.1 to
1.73.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.73.1...v1.73.2)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-04 22:39:03 +01:00
2ab00c5b37 DEV: Add apply_modifier on group's mentionable scope (#31565)
This PR adds DiscoursePluginRegistry.apply_modifier on group's
mentionable scope.
2025-03-04 15:36:55 -06:00
d93f8c1d43 Build(deps): Bump rack from 2.2.11 to 2.2.12 (#31626)
Bumps [rack](https://github.com/rack/rack) from 2.2.11 to 2.2.12.
- [Release notes](https://github.com/rack/rack/releases)
- [Changelog](https://github.com/rack/rack/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rack/rack/compare/v2.2.11...v2.2.12)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-04 22:35:17 +01:00
dde1b523b6 DEV: Update template-override deprecation (#31623)
- Update Meta topic URLs

- Add theme/plugin identification to deprecation

- Enable admin warning banner

- Enable overriding of gjs component templates, to unblock core upgrade
work between now and final removal of the template override feature

https://meta.discourse.org/t/355668
2025-03-04 18:49:49 +00:00
2041eaf89d DEV: Drop PluginOutlet parentView and DButton string actions (#31624)
These have been deprecated, with admin warnings, for some time
2025-03-04 18:48:56 +00:00
3160ad8fb0 DEV: Convert d-button test classes to native syntax (#31622) 2025-03-04 18:44:07 +01:00
150edff1cf DEV: Use an inline require to avoid a circular import (#31615) 2025-03-04 17:34:44 +01:00