Commit Graph
4264 Commits
Author SHA1 Message Date
Discourse Translator Bot 7d3bfe978e Update translations (#34436) 2025-08-21 11:02:39 +02:00
Martin Brennan ad2d3007d5 FEATURE: Disable user tips + narrative bot welcome post for all sites (round 2) (#34373)
We want to temporarily disable user tips and the Discobot welcome PM
on all sites by default until we have time to improve their
functionality, because
right now they create a lot of noise for new members and admins without
providing obvious benefits.

Existing sites which have customized any of these localization strings will have
`disable_discourse_narrative_bot_welcome_post` kept as `false`:

* system_messages.welcome_user.subject_template OR
* system_messages.welcome_user.text_body_template OR
* discourse_narrative_bot.new_user_narrative.hello.message

Followup revert 70859e277f.
2025-08-21 09:17:20 +10:00
Roman Rizzi 5ccd7fa1e4 FIX: Default prompts have to be explicit about the expected format. (#34442)
Wrapping the expected response with `<output>` tags confuses models,
especially those from the Claude family, which don't have schema support
and rely on prefilling. Relying on prefilling means they only know the
response must start with `{`, and how the JSON looks is only hinted at
in the system prompt.
2025-08-20 13:56:21 -03:00
chapoi f698bb9088 UX: fix cmd-k bottom padding (#34440)
Moved some things around to fix the lack of bottom padding while
searching for results:
<img width="1706" height="398" alt="CleanShot 2025-08-20 at 15 58 32@2x"
src="https://github.com/user-attachments/assets/c67f2c35-719d-4a3d-98ee-191353a476e2"
/>

🔽 
<img width="1706" height="398" alt="CleanShot 2025-08-20 at 15 52 13@2x"
src="https://github.com/user-attachments/assets/65869c9d-06b7-4dd9-b5ef-156e320a798a"
/>
2025-08-20 16:45:39 +02:00
Charles Lechasseur 4380efbf78 FIX: Relax Matrix room ID validation (#34399)
This PR relaxes the accepted format of Matrix room IDs in the Matrix
chat provider. It allows the new room ID format in [Room
v12](https://github.com/matrix-org/matrix-spec-proposals/blob/matthew/msc4291/proposals/4291-room-ids-as-hashes.md)
to be used in Discourse.

Reported here:
https://meta.discourse.org/t/new-matrix-v12-rooms-not-supported-by-chat-integration/378675
2025-08-20 13:18:29 +10:00
Martin Brennan 30e0058463 DEV: Replace <Input /> text usage in plugins (#34352)
Replaces usage of the Ember `<Input />` component with
native `<input>` elements in core plugins for text and
number inputs.

Generated with claude.
2025-08-20 11:23:41 +10:00
Discourse Translator BotandGerhard Schlager ab0b0573a1 Update translations (#34413)
Co-authored-by: Gerhard Schlager <gerhard.schlager@discourse.org>
2025-08-19 16:23:59 +02:00
Discourse Translator Bot 74066bffa2 Update translations (#34116) 2025-08-19 12:14:51 +02:00
SamandMartin Brennan f0fc5646dc FEATURE: dynamic poll support (#34368)
If a poll is created with `dynamic-poll=true`
then options can be amended after you post poll.

This is useful for polls like: "favorite IDE" where you want
people to easily be allowed to add options.

---------

Co-authored-by: Martin Brennan <martin@discourse.org>
2025-08-19 16:43:36 +10:00
Sam 87476ce2c1 FEATURE: add support for Groq as a pre-configured LLM (#34402) 2025-08-19 16:17:45 +10:00
Kelv a3bc8c80d7 DEV: floatkit autocomplete for ai-bot-conversations (#34354)
This PR changes the ai-bot-conversations component to use the
floatkit-based autocomplete menu for the AI bot chat interface when
autocompleting hashtags (`#`) and mentions (`@`). Also fixes a bug where autocompleting in the full page search input field results in the search immediately submitting.
2025-08-19 10:48:07 +08:00
Nat 4edad4dc3c SECURITY: Escape names 2025-08-19 10:09:14 +08:00
Roman Rizzi 5d27b185e2 FEATURE: Skip spam scanning when relevant content is unchanged or edited by staff (#34391) 2025-08-19 09:04:02 +10:00
Roman Rizzi 4abe2229f1 FIX: Include llm_persona_triage scripts in the AI features' triage section (#34395) 2025-08-19 08:59:48 +10:00
Roman Rizzi 565a70b72c FIX: Truncate seeded persona's names to fit name length constraint (#34393) 2025-08-18 18:08:43 -03:00
Keegan GeorgeandRoman Rizzi fcb098e85d FEATURE: Ability to regenerate short summaries (#34345)
## 🔍 Overview
This update allows you to regenerate short summaries (gists) with the
click of a button. This is helpful for admins to fix short summaries
when they go wrong. This update adds a regenerate button in the topic
admin controls as well as the bulk select dropdown for topic lists.

## 📸 Screenshots
<img width="443" height="663" alt="Screenshot 2025-08-14 at 17 28 46"
src="https://github.com/user-attachments/assets/25784d3e-38b4-4eb6-8fde-a921ca9243f6"
/>

<img width="564" height="579" alt="Screenshot 2025-08-14 at 17 28 36"
src="https://github.com/user-attachments/assets/26ef3037-2d79-4a32-bca9-baa94430bf18"
/>

---------

Co-authored-by: Roman Rizzi <rizziromanalejandro@gmail.com>
2025-08-18 13:48:41 -07:00
Joffrey JAFFEUX fc3ba98d03 DEV: correctly teardown page changed event (#34383)
We were not unsubscribing from this event, causing us to add more and
more listeners, after few pages visits you would end up with as many
subscriptions and as many ajax calls, eventually causing 429s.

A further improvement of this code could be to cache the events list,
there not much value in refetching each time given the query doesnt
change for each page.
2025-08-18 13:34:54 +02:00
Jarek Radosz 75750e4453 DEV: Remove unused code (#34381) 2025-08-18 12:31:19 +02:00
Meghna 790d269112 FIX: fix the closing paragraph tag in locale (#34372) 2025-08-18 13:11:30 +05:30
Martin Brennan 70859e277f Revert "FEATURE: Disable user tips + narrative bot welcome post for all sites (#34316)" (#34370)
This reverts commit 443caf1bed.

Need to iron out some more issues first.
2025-08-18 15:58:58 +10:00
Natalie Tay 56f2310fb4 DEV: Use common candidate helper for backfill job (#34364)
Related: https://github.com/discourse/discourse/pull/33927

This is already tested in the job itself and is a refactor to use the
new class.
2025-08-18 11:04:35 +08:00
Martin Brennan 443caf1bed FEATURE: Disable user tips + narrative bot welcome post for all sites (#34316)
We want to temporarily disable user tips and the Discobot welcome PM
on all sites by default until we have time to improve their
functionality, because
right now they create a lot of noise for new members and admins without
providing obvious benefits.
2025-08-18 11:43:39 +10:00
Keegan George 08e9f9c00b UX: remove barThickness so translation bars scale naturally (#34362)
## 🔍 Overview
When a forum has many translations, the explicit `barThickness` looks
too thick. This update removes the explicit `barThickness` so that the
bars scale naturally based on the amount of translations in the chart.

## 📷 Screenshots

### ← Before
<img width="1093" height="673" alt="Screenshot 2025-08-15 at 13 06 07"
src="https://github.com/user-attachments/assets/030eac00-d972-40de-97d6-e266dbbe17eb"
/>

### → After
<img width="1095" height="704" alt="Screenshot 2025-08-15 at 13 05 41"
src="https://github.com/user-attachments/assets/9fa41e63-0324-45f1-ae1f-5212ab2a770d"
/>
2025-08-15 14:10:49 -07:00
Keegan George 5c58a550d6 FEATURE: Translation progress admin UI (#34239)
## 🔍 Overview
This update adds a tab to the Discourse AI admin panel where admins can
see automatic translation progress for selected locales on the forum as
well as manage the relevant translation settings.

## 📷 Screenshots

<img width="930" height="806" alt="01-in-use"
src="https://github.com/user-attachments/assets/b470f687-fd4b-49c8-93d8-226e4234a4c7"
/>

---

<img width="924" height="397" alt="02-disabled"
src="https://github.com/user-attachments/assets/92a847ca-12a2-4bba-b022-f9d47174bef6"
/>
2025-08-15 12:19:35 -07:00
Natalie Tay c002d10b11 DEV: Return finished and total number of candidates needed for translation rather than a percentage (#34357)
To better support https://github.com/discourse/discourse/pull/34239, we
return the raw values here instead of a derived percentage.
2025-08-15 10:25:27 -07:00
Kris 42b3148f7b UX: don't highlight admin content on hover if it isn't clickable (#34332)
This resolves a number of cases where we were highlighting content on
hover that isn't clickable.


Common table example

Before:
<img width="1726" height="548" alt="image"
src="https://github.com/user-attachments/assets/24635052-0efd-4c02-b75b-dc3901acd799"
/>


After:
<img width="1744" height="550" alt="image"
src="https://github.com/user-attachments/assets/73837bff-532b-48ec-99de-2e579221eccb"
/>




Reports are a case where the box *should* be clickable, so I kept the
hover effect and made the box clickable via changes to
`admin-section-landing-item`...

Before: 
<img width="1710" height="838" alt="image"
src="https://github.com/user-attachments/assets/a8bc8f67-5f1f-44c1-8de7-e64c1a60fd49"
/>


After (removed the blue because the headings aren't actually links
anymore, the whole box is):
<img width="1732" height="922" alt="image"
src="https://github.com/user-attachments/assets/2fb5b63a-1cdc-4fc9-906a-c343c26cd025"
/>

In cases where these boxes have buttons, the inner title (if linked) and
buttons are clickable, not the box...

<img width="400" alt="image"
src="https://github.com/user-attachments/assets/3bf04522-179b-49e6-ae0a-f5d3714b94ec"
/>
2025-08-14 15:59:29 -04:00
Jarek Radosz 36fc29fb2d DEV: Update deprecated imports (#34329)
moving forward this will be an auto-fixable eslint rule
2025-08-14 20:25:09 +02:00
Jarek Radosz 07425a9fed DEV: Reduce the getOwnerWithFallback usage (#34330) 2025-08-14 20:24:59 +02:00
Kris d538b50847 DEV: apply common filter component to AI persona admin (#34300)
This applies the common `AdminFilterControls` component here: 

<img width="2216" height="144" alt="image"
src="https://github.com/user-attachments/assets/3e6ad0e9-9f14-4974-a80c-49e0d1b0b108"
/>

I also wanted to add the layout control button, so I added the ability
to use an actions block in `AdminFilterControls` — this required
creating two separate blocks `actions` and `content`, which required
updating the other instances of `AdminFilterControls` ... but this
should allow more flexibility going forward
2025-08-14 10:25:18 -04:00
Jarek Radosz 41acf4eace DEV: Remove unused code (#34322) 2025-08-14 16:21:46 +02:00
Jarek Radosz 93f0f5ce54 DEV: Remove @triggers args where eq to the default (#34321)
triggers are `["click"]` by default
2025-08-14 16:21:33 +02:00
chapoi 823e1b6272 UX: user status emoji alignment in sidebar and chat mention (#34320)
Follow up of https://github.com/discourse/discourse/pull/33902

Fixes:
* User status in chat mentions needed a spacing
<img width="404" height="70" alt="CleanShot 2025-08-14 at 11 00 21"
src="https://github.com/user-attachments/assets/3c3f3e8b-5a0a-4516-a152-c2e8a5e361e4"
/>

* Sidebar user status was misaligned
<img width="181" height="65" alt="CleanShot 2025-08-14 at 11 00 58"
src="https://github.com/user-attachments/assets/ef86b103-1cbd-4a2d-8169-1c3ae125b8fc"
/>
2025-08-14 11:21:49 +02:00
Osama Sayegh 91e33664ae FIX: Improve automation on/off toggle (#33482)
This commit replaces the "enabled" checkbox on the automation page with a
toggle at the top of the automation page. We've made this change to make
the automation edit page consistent with the automations list page where
a toggle is used for turning on/off automations, and also consistent
with the rest of admin pages where we've been using toggle for
controlling the enable/disable state.

Internal topic: t/153523.
2025-08-14 10:16:20 +03:00
David Battersby 5dfa0f3cb6 FIX: use group name in unreachable mention warning (#34174)
In cases where there are mentioned users that are unreachable (ie. they
cannot join the channel), then we normally notify the sender of those
users in the chat notice. However, with groups have a
`members_visible_level` setting which determines who can view members.
This change takes into account this setting when showing the chat notice
to the sender.

If there is a mentioned group that the sender does not have permission
to view members then we will show the group name instead of the users.
2025-08-14 09:33:51 +04:00
Sam d2cd9462ba FEATURE: CRUD access for ai-artifacts (admin only) (#34193)
- GET /admin/plugins/discourse-ai/ai-artifacts.json — list (paginated,
per_page capped at 100)
- GET /admin/plugins/discourse-ai/ai-artifacts/:id.json — show
- POST /admin/plugins/discourse-ai/ai-artifacts.json — create
- PUT /admin/plugins/discourse-ai/ai-artifacts/:id.json — update
- DELETE /admin/plugins/discourse-ai/ai-artifacts/:id.json — destroy

Admin-only, JSON responses.
2025-08-14 12:17:20 +10:00
Kelv 282a544cce DEV: raise error on missing name properties for user autocomplete results (#34283)
Related to https://github.com/discourse/discourse/pull/34208.

Previously, missing name properties for a selected user search result
would fail silently which made it difficult to tell if something had
gone wrong with the user autocomplete.

This PR adds some error handling to make it more obvious that an error
has occurred. I've opted for using `toasts` here since it's less
intrusive compared to the `dialog` modal.

https://github.com/user-attachments/assets/92f585d8-95bf-4c5b-a08a-698c1a527b79
2025-08-14 09:12:47 +08:00
Jarek Radosz 0b5211671c DEV: Update jsconfig (#34285)
to include recently bundled plugins and themes
2025-08-13 21:17:50 +02:00
Roman Rizzi dbbe8009ce FEATURE: Opt-in to the responses API when using Azure (#34290) 2025-08-13 10:36:47 -03:00
Roman Rizzi 01875b3e18 FEATURE: Display automation scripts in the AI features page (#34254)
<img width="1139" height="282" alt="Screenshot 2025-08-12 at 11 22
05 AM"
src="https://github.com/user-attachments/assets/5649ea01-1b55-4211-841a-e8c85d1e5972"
/>


<img width="1102" height="175" alt="Screenshot 2025-08-12 at 11 22
25 AM"
src="https://github.com/user-attachments/assets/dabaa2f6-a6cd-4f6d-9aba-ce46056d01a4"
/>
2025-08-13 09:40:38 -03:00
Alan Guo Xiang Tan c9421c1120 DEV: Promote historic core plugins post_deploy migrations (#34274)
This commit promotes all post_deploy migrations which existed in
Discourse v3.4.0 (timestamp <= 20241023041126)
2025-08-13 15:52:19 +08:00
ee094b99cc FEATURE: filter tips for assigned topics (#33992)
Refactors filter navigation menu: 

* Replaces local filtering logic with async `FilterSuggestions` service
(new parser, prefixes, multi-value delimiters, active filter handling)
* Introduces topics_filter_options modifier hook and custom filter
mapping support (including comma‑separated values) in TopicsFilter
* Adds assigned: (multi user/group, *, nobody) and status:solved /
status:unsolved options via plugins. Also updates solved/assign locales.
* Adds in:new-replies and in:new-topics filters for tracking
* Enhances assign filter query logic. 
* Adds custom in: filter mapping tests.

---------

Co-authored-by: Martin Brennan <martin@discourse.org>
Co-authored-by: Jarek Radosz <jradosz@gmail.com>
2025-08-13 16:35:33 +10:00
KrisandJarek Radosz cef550d982 FIX: ensure AI gists render on mobile (#34261)
Follow-up to
https://github.com/discourse/discourse/commit/383760759b5a325a497ef85cc783d7ba9442f58f

The change in outlet there made the gists stop appearing on mobile, so
here I'm making the outlet conditional on mobile/desktop view and adding
a spec to make sure they appear

---------

Co-authored-by: Jarek Radosz <jradosz@gmail.com>
2025-08-12 17:16:31 -04:00
Jarek Radosz 89b108c4b2 DEV: Remove unused services from plugins/themes (#34231) 2025-08-12 22:47:31 +02:00
Jarek Radosz ba44ec67ef DEV: Convert more tests to gjs/template tag (#34259) 2025-08-12 22:44:48 +02:00
Jordan Vidrine dfb0c4d857 FIX: Border-radius should appear in the edit topic title input (#34258) 2025-08-12 14:28:21 -05:00
Jordan Vidrine e8cda50573 DEV: Simple refactor of button markup (#34256) 2025-08-12 13:00:32 -05:00
Krzysztof Kotlarek 91d26abb10 FIX: Remove redundant allowedGroups parameter (#34244)
Remove frontend code that automatically adds
allowedGroups="trust_level_0" to public events.


https://meta.discourse.org/t/non-staff-members-cannot-create-calendar-events/376796
2025-08-12 11:56:26 +08:00
Roman Rizzi f2d6c8a8c8 FIX: Assume buffer also carries stuff from previous chunks, not just the last one (#34230) 2025-08-11 18:40:37 -03:00
Sérgio Saquetim 168c4b75fd DEV: Close footnote tooltip when trigger is removed (#34182)
This commit ensures inline footnote tooltips are closed when their trigger
element is removed from the page.

- Refactors inline footnotes to use a Glimmer component and DTooltip
- Replaces anchor triggers with components rendered via Glimmer
- Adds acceptance test to verify tooltip closes when link inside tooltip
is clicked
- Improves reliability of tooltip teardown on navigation or interaction
2025-08-11 15:49:28 -03:00
Kelv a71eb4108a FIX: user autocomplete search cache pollution (#34208)
The current chat autocomplete pipeline can mutate the user object
selected for autocomplete here:

https://github.com/discourse/discourse/blob/071e82140cf375e2875b87d1664ae596c19320dd/plugins/chat/assets/javascripts/discourse/components/chat-composer.gjs#L485

Specifically this occurs when we attempt to create a record in the store
service where it already exists, and the logic for fetching the right
record there deletes some properties from the input object:

https://github.com/discourse/discourse/blob/216df43502e25fcb9a228bfc09f90548712d7f49/app/assets/javascripts/discourse/app/services/store.js#L426-L435

This mutates the object that is eventually used to replace the search
term (and therefore causes an error as it is now missing all its
properties except for `id`). This also pollutes the upstream cache in
the userSearch JS module.

This PR fixes both issues by cloning the user objects before they get
passed into the processing functions.
2025-08-11 13:14:25 +08:00