Commit Graph

31424 Commits

Author SHA1 Message Date
Kelv
bfa3e056f1
DEV: refactor topic-summary widget to topic-map-summary component (#25447)
* shift topic-summary widget to topic-map-summary component
* remove relativeDate memoization which was causing bug where displayed date never updated
2024-01-31 22:09:39 +08:00
Joffrey JAFFEUX
ec26dc51cd
UX: shows PWA/Hub footer navigation on chat (#25501)
This commit sets a default of 0px for `--footer-nav-height` and set it only when `body.footer-nav-visible` allowing us to safely use `--footer-nav-height` wherever it will be needed if set.
2024-01-31 14:41:12 +01:00
David Battersby
52249fad11
FIX: remove fast-edit regex and string replacement (#25496)
This change removes the regex we used previously, which only allowed ASCII characters in fast-edit. Now multi-language content  can be used with fast-edit.

It also removes the string replacement we relied on in the past to catch various forms of punctuation marks, as this no longer appears necessary (possibly since this component was updated to use Glimmer).
2024-01-31 18:26:43 +08:00
chapoi
a695d85cbd
UX: Update selected colour var (#25500) 2024-01-31 09:32:38 +01:00
Jarek Radosz
58be138e75
FIX: Site-setting integer input type (#25485)
Regressed in f2e1363f67
2024-01-30 20:25:48 +01:00
David Taylor
88305e3d96
DEV: Remove version-number-based logic (#25482)
The `deprecate_column` helper would change its behavior based on the current `Discourse::VERSION`. This means that 'finalizing' a stable release introduces a previously untested behavior change.

Much better to keep it as a deprecation until manual action is taken to introduce the breaking change.
2024-01-30 17:34:10 +00:00
David Taylor
9b50de4569
SECURITY: Properly escape user content within <noscript> 2024-01-30 09:10:09 -07:00
David Taylor
283fe48243
DEV: Update confirm-email flows to use central 2fa and ember rendering (#25404)
These routes were previously rendered using Rails, and had a fairly fragile 2fa implementation in vanilla-js. This commit refactors the routes to be handled in the Ember app, removes the custom vanilla-js bundles, and leans on our centralized 2fa implementation. It also introduces a set of system specs for the behavior.
2024-01-30 10:32:42 +00:00
Sam
27301ae5c7
FEATURE: support silent internal links (#25472)
Internal links always notify and add internal connections in topics.

This adds a special feature that lets you append `?silent=true` to a link
to have it excluded from:

1. Notifications - users will not be notified for these links
2. Post links below posts in the UI

This is specifically useful for large reports where adding all these connections
just results in noise.
2024-01-30 17:03:58 +11:00
Martin Brennan
304a7f3e1a
FIX: Do not show quote copy button to anon (#25471)
This was an oversight in 51016e56dd,
anon doesn't have any need to copy quotes, just as they have
no need to open the composer with a quote prefilled.
2024-01-30 13:19:35 +10:00
Mark VanLandingham
f6becaa0b6
DEV: Wrap user summary category rows in plugin outlet (#25466) 2024-01-29 15:48:36 -06:00
Penar Musaraj
2558543794
DEV: Add general pretender for passkey challenge (#25432)
* DEV: Add general pretender for passkey challenge

* Limit a test to Chrome because of Firefox ESR flakiness
2024-01-30 08:13:59 +11:00
Kris
d29fefd73a
FIX: missing ampersand in input class selector (#25464) 2024-01-29 14:03:32 -05:00
Mark VanLandingham
2665752732
DEV: PluginOutlet addition in user/notifications-index & summary class names (#25463) 2024-01-29 12:56:42 -06:00
marstall
5a00d1964f
DEV: add site setting to disable watched word checking in user fields (#25411)
adding a hidden sitesetting, `disable_watched_word_checking_in_user_fields` - false by default. if set to true, you can use any word at all in user profile fields.

meta: https://meta.discourse.org/t/watched-words-scope/282699/20
2024-01-29 12:44:32 -05:00
David Taylor
2457553d0a
FIX: Avoid flash-of-unstyled-content in Safari with bug workaround (#25462)
Safari has a bug which means that scripts with the `defer` attribute are executed before stylesheets have finished loading. This is being tracked at https://bugs.webkit.org/show_bug.cgi?id=209261.

This commit works around the problem by introducing a no-op inline `<script>` to the end of our HTML document. This works because defer scripts are guaranteed to run after inline scripts, and inline scripts are guaranteed to run after any preceding stylesheets.

Technically we only need this for Safari. But given that the cost is so low, it makes sense to include it everywhere rather than incurring the complexity of gating it by user-agent.
2024-01-29 17:20:44 +00:00
chapoi
df2f63cf74
UX: add bg style to input field type number (#25460) 2024-01-29 10:51:12 -05:00
David Taylor
ed2802eeb5
DEV: Fix alternative output directories in ember-cli proxy (#25291)
Specifying alternatives to `dist/` is useful when running multiple servers locally (e.g. for performance testing)
2024-01-29 14:09:41 +00:00
David Taylor
63f6bd5efe
DEV: Add admin warning for sites on Ember 3 (#25459)
Running Discourse 3.2 stable under Ember 3 will technically be possible, but is only intended as a short-term migration point. This commit adds an admin warning for sites which are using this configuration, to make it clear that themes and plugins are unlikely to support the configuration.

https://meta.discourse.org/t/287211
2024-01-29 14:09:07 +00:00
David Taylor
1bfccdd4f2
DEV: Allow run_second_factor! to be used before login (#25420)
In a handful of situations, we need to verify a user's 2fa credentials before `current_user` is assigned. For example: login, email_login and change-email confirmation. This commit adds an explicit `target_user:` parameter to the centralized 2fa system so that it can be used for those situations.

For safety and clarity, this new parameter only works for anon. If some user is logged in, and target_user is set to a different user, an exception will be raised.
2024-01-29 12:28:47 +00:00
dependabot[bot]
8e32c11ab4
Build(deps-dev): Bump @floating-ui/dom from 1.5.4 to 1.6.1 in /app/assets/javascripts (#25449)
* Build(deps-dev): Bump @floating-ui/dom in /app/assets/javascripts

Bumps [@floating-ui/dom](https://github.com/floating-ui/floating-ui/tree/HEAD/packages/dom) from 1.5.4 to 1.6.1.
- [Release notes](https://github.com/floating-ui/floating-ui/releases)
- [Changelog](https://github.com/floating-ui/floating-ui/blob/master/packages/dom/CHANGELOG.md)
- [Commits](https://github.com/floating-ui/floating-ui/commits/@floating-ui/dom@1.6.1/packages/dom)

---
updated-dependencies:
- dependency-name: "@floating-ui/dom"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update lockfiles for ember version flag

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: discoursebuild <build@discourse.org>
2024-01-29 12:39:46 +01:00
Alan Guo Xiang Tan
91bfc513ac
Revert "Build(deps): Bump @glimmer/syntax from 0.84.3 to 0.88.0 in /app/assets/javascripts (#25450)" (#25455)
This reverts commit ef87629526.

Breaks licensee on CI which I have no time to figure out now
2024-01-29 10:14:10 +08:00
Martin Brennan
c7860173c1
DEV: Clean up hashtag code (#25397)
* Delete dead code
* Split up hashtag-autocomplete into more logical modules
2024-01-29 09:48:56 +10:00
dependabot[bot]
ef87629526
Build(deps): Bump @glimmer/syntax from 0.84.3 to 0.88.0 in /app/assets/javascripts (#25450)
* Build(deps): Bump @glimmer/syntax in /app/assets/javascripts

Bumps [@glimmer/syntax](https://github.com/glimmerjs/glimmer-vm) from 0.84.3 to 0.88.0.
- [Release notes](https://github.com/glimmerjs/glimmer-vm/releases)
- [Changelog](https://github.com/glimmerjs/glimmer-vm/blob/main/CHANGELOG.md)
- [Commits](https://github.com/glimmerjs/glimmer-vm/compare/v0.84.3...v0.88.0)

---
updated-dependencies:
- dependency-name: "@glimmer/syntax"
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update lockfiles for ember version flag

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: discoursebuild <build@discourse.org>
2024-01-29 07:18:00 +08:00
Kris
6d57da1d6e
FIX: global selector needed to avoid clicks registering on other elements (#25445) 2024-01-26 22:24:21 +00:00
Kris
3714a6f222
FIX: remove excess margin after title (#25444) 2024-01-26 13:42:38 -05:00
Blake Erickson
7200a41207
FIX: export csv file failed message (#25443)
When exporting a csv file and the size of the file exceeded the
max_export_file_size_kb it will still send the PM that the export
succeeded with a broken link to a missing export file. This change
ensures that a failed message will be sent instead.
2024-01-26 11:16:02 -07:00
Kris
6b185f8655
PERF: eliminate some slow CSS selectors (#25392) 2024-01-26 13:10:45 -05:00
Kris
4e72b06a54
UX: improve mobile table editor button location (#25426) 2024-01-26 13:08:12 -05:00
Kris
4266b0cf7d
UX: fix and improve topic title badge spacing (#25441) 2024-01-26 12:11:03 -05:00
Jarek Radosz
f2e1363f67
FIX: Deprecate NumberField, use <input> instead (#25434)
* Revert "FEATURE: Use native number fields for integer inputs (#24984)"

This reverts commit 8fce890ead.

* FIX: Deprecate NumberField, use <input> instead

This reverts #24984 as it introduced regressions (behavioral and visual) and instead it deprecates the NumberField component and replaces its uses in core with native `<input>` elements.
2024-01-26 17:56:07 +01:00
Penar Musaraj
19b86e7ea2
FIX: Auto-populate group field in invite modal on group route (#25431) 2024-01-26 17:02:48 +01:00
Bianca Nenciu
76647d3a34
FIX: Set allowUncategorized SelectKit option (#25440)
CategoryRow component uses allowUncategorized SelectKit option to
decide whether to show the "Uncategorized" category or not. This was
undefined which lead to "Uncategorized" category being always hidden
causing a minor visual glitch.
2024-01-26 16:26:58 +02:00
chapoi
fbfab92fce
UX: overflow fix for add participants to PM on mobile (#25437) 2024-01-26 09:26:25 +01:00
Kris
3c54d9e64c
UX: improve featured link positioning in topic titles (#25427) 2024-01-25 16:49:34 -05:00
dependabot[bot]
d022b85a52
Build(deps): Bump the babel group in /app/assets/javascripts with 2 updates (#25428)
* Build(deps): Bump the babel group

Bumps the babel group in /app/assets/javascripts 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.23.7 to 7.23.9
- [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.23.9/packages/babel-core)

Updates `@babel/standalone` from 7.23.8 to 7.23.9
- [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.23.9/packages/babel-standalone)

---
updated-dependencies:
- dependency-name: "@babel/core"
  dependency-type: direct:development
  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>

* Update lockfiles for ember version flag

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: discoursebuild <build@discourse.org>
2024-01-25 22:45:19 +01:00
Blake Erickson
e409fabf8d
DEV: Log any errors for the user csv export (#25422)
Currently when exporting a list of users and there is an error we just
log that there was an error, but we don't show what the issue is in the
logs which makes it really hard to debug in production. This change will
output any errors to the logs.
2024-01-25 12:18:16 -07:00
Blake Erickson
ae5c11f364
FIX: Remove css that should not have been added (#25425)
Accidentally added this css that didn't need to be added as part of this
commit: 0dcdc66f58
2024-01-25 12:17:26 -07:00
Blake Erickson
89883b2f51
WIP: Experiemental Bulk Topic Actions Dropdown (#25245)
* WIP: Experiemental Bulk Topic Actions Dropdown

Creates a new dropdown that can be used for topic bulk actions.
2024-01-25 09:12:06 -07:00
Jarek Radosz
4d1ed4a62d
DEV: Don't check for ResizeObserver existence (#25419)
We already assume it's there in many other places
2024-01-25 13:47:15 +01:00
David Taylor
241eaadc26
FIX: Computed property override error for webhook.categories (#25418) 2024-01-25 12:25:02 +00:00
Jarek Radosz
5734066942
DEV: Use document.body directly (#25417)
No need to fire up those query parsing engines :P
2024-01-25 12:50:33 +01:00
David Taylor
1651d63204
FIX: Allow category to be set on topic model instances (#25416)
Some parts of our code (e.g. some types of reviewable) set `topic.category`. In the past this would override the computed property value, but with recent Ember it raises an error. This commit adds a setter which handles the situation cleanly
2024-01-25 10:49:00 +00:00
Martin Brennan
57ededb770
DEV: Move admin sidebar out of initializer (#25396)
Having the admin sidebar code in an instance initializer is not
ideal because:

* It runs during app boot which may not even be necessary based on site settings
* It makes it hard for plugins to register additional links in time without resorting
to before/after initializer gymnastics

This PR moves the admin sidebar into a lib and creates the panel
in custom-sections.js, then the sections and links are loaded when
the main sidebar component is rendered, which leaves plugins enough
time to add additional links in an initializer.

---------

Co-authored-by: David Taylor <david@taylorhq.com>
2024-01-25 10:45:14 +10:00
Ted Johansson
6ad34a0152
DEV: Exclude system users when calculating group user count (#25400)
We want to exclude the system user from group user counts, since intuitively admins wouldn't include them.

Originally this was accomplished by booting said system user from the groups, but this is causing problems, because the system user needs TL group membership to perform certain tasks.

After this PR, system user is still in the TL groups, but excluded when refreshing the user count.
2024-01-25 08:13:58 +08:00
Kris
cf25fab9b0
UX: simplify education message layout on empty /new route (#25412) 2024-01-24 18:13:42 -05:00
Kris
0c63463d28
UX: fix spacing for about page headings (#25410) 2024-01-24 16:36:36 -05:00
dependabot[bot]
0855804d72
Build(deps-dev): Bump webpack from 5.89.0 to 5.90.0 in /app/assets/javascripts (#25409)
* Build(deps-dev): Bump webpack in /app/assets/javascripts

Bumps [webpack](https://github.com/webpack/webpack) from 5.89.0 to 5.90.0.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.89.0...v5.90.0)

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

Signed-off-by: dependabot[bot] <support@github.com>

* Update lockfiles for ember version flag

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: discoursebuild <build@discourse.org>
2024-01-24 22:35:36 +01:00
Mark VanLandingham
9130a3cafd
DEV: Add PluginOutlet wrapping user notifications EmptyState (#25406) 2024-01-24 11:34:43 -06:00
chapoi
4bef6fbd62
UX: add spacing in new topic draft text - timestamp (#25403) 2024-01-24 17:29:50 +01:00