Commit Graph

46214 Commits

Author SHA1 Message Date
dependabot[bot] 5c5a08cb33 Build(deps): Bump sidekiq from 6.5.4 to 6.5.5
Bumps [sidekiq](https://github.com/mperham/sidekiq) from 6.5.4 to 6.5.5.
- [Release notes](https://github.com/mperham/sidekiq/releases)
- [Changelog](https://github.com/mperham/sidekiq/blob/main/Changes.md)
- [Commits](https://github.com/mperham/sidekiq/compare/v6.5.4...v6.5.5)

---
updated-dependencies:
- dependency-name: sidekiq
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-23 09:16:22 +08:00
Bianca Nenciu b160331d41
FIX: Move show like logic to client side (#18025)
The logic was added in commit ec8306835d,
to show the like action even if the user could not like the post. It is
not necessary for this logic to be implemented on the server side.
2022-08-22 18:40:09 +03:00
Jarek Radosz 21abcfe5a7
FIX: Track native class deps in discourseComputed (#18023)
Co-authored-by: David Taylor <david@taylorhq.com>
2022-08-22 17:33:32 +02:00
Arpit Jalan b567cebffe
FIX: remove "--composer-height" style when composer is closed (#18022)
* FIX: remove "--composer-height" style when composer is closed

* fix typo

* fix linting
2022-08-22 17:41:56 +05:30
Bianca Nenciu ec8306835d
FIX: Improvements to like button for archived topics (#17951)
* FIX: Do not allow to remove like if topic is archived

* FIX: Always show like button

The like button used to be hidden if the topic was archived and it had
no likes. This commit changes that to always show the like button, but
with a not-allowed cursor if the topic is archived.
2022-08-22 14:58:02 +03:00
David Taylor 33a2624f09
DEV: Introduce flag for compiling Plugin JS with Ember CLI (#17965)
When `EMBER_CLI_PLUGIN_ASSETS=1`, plugin application JS will be compiled via Ember CLI. In this mode, the existing `register_asset` API will cause any registered JS files to be made available in `/plugins/{plugin-name}_extra.js`. These 'extra' files will be loaded immediately after the plugin app JS file, so this should not affect functionality.

Plugin compilation in Ember CLI is implemented as an addon, similar to the existing 'admin' addon. We bypass the normal Ember CLI compilation process (which would add the JS to the main app bundle), and reroute the addon Broccoli tree into a separate JS file per-plugin. Previously, Sprockets would add compiled templates directly to `Ember.TEMPLATES`. Under Ember CLI, they are compiled into es6 modules. Some new logic in `discourse-boot.js` takes care of remapping the new module names into the old-style `Ember.TEMPLATES`.

This change has been designed to be a like-for-like replacement of the old plugin compilation system, so we do not expect any breakage. Even so, the environment variable flag will allow us to test this in a range of environments before enabling it by default.

A manual silence implementation is added for the build-time `ember-glimmer.link-to.positional-arguments` deprecation while we work on a better story for plugins.
2022-08-22 09:56:39 +01:00
Alan Guo Xiang Tan 558e6a3ff4 Review feedback 2022-08-22 15:20:56 +08:00
Alan Guo Xiang Tan 3a5314c792 UX: Fix topic admin menu hidden on narrow screens
When there is not enough window width to display the admin menu on the
right, we display it on the left instead. Behavior is reversed on RTL
layout.

This commit also removes jQUery usage.
2022-08-22 15:20:56 +08:00
Alan Guo Xiang Tan a3565914a4 UX: Adjust scrollbar behaviour in sidebar
Vertical sidebar is only restricted to sidebar sections and not the
footer.
2022-08-22 14:09:39 +08:00
dependabot[bot] 1e1cf1e821 Build(deps): Bump addressable from 2.8.0 to 2.8.1
Bumps [addressable](https://github.com/sporkmonger/addressable) from 2.8.0 to 2.8.1.
- [Release notes](https://github.com/sporkmonger/addressable/releases)
- [Changelog](https://github.com/sporkmonger/addressable/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sporkmonger/addressable/compare/addressable-2.8.0...addressable-2.8.1)

---
updated-dependencies:
- dependency-name: addressable
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-22 11:10:10 +08:00
dependabot[bot] 085b9823a2 Build(deps): Bump omniauth from 1.9.1 to 1.9.2
Bumps [omniauth](https://github.com/omniauth/omniauth) from 1.9.1 to 1.9.2.
- [Release notes](https://github.com/omniauth/omniauth/releases)
- [Commits](https://github.com/omniauth/omniauth/compare/v1.9.1...v1.9.2)

---
updated-dependencies:
- dependency-name: omniauth
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-22 11:09:55 +08:00
Krzysztof Kotlarek caab916569
FEATURE: default sidebar categories and tags (#17939)
Ability to set up default sidebar categories and tags for authenticated users
2022-08-22 08:46:20 +10:00
Jarek Radosz 49fa2e93c2
DEV: Clean up twitter onebox code (#18012) 2022-08-21 19:26:24 +02:00
Joffrey JAFFEUX 4e3c688d65
DEV: implements `removeKeys(predicate)` in keyValueStore (#18019) 2022-08-21 19:19:25 +02:00
Jarek Radosz 9130565895
DEV: Async a bit more of Composer (#18013) 2022-08-21 12:11:10 +02:00
Jarek Radosz ff0f43014c
DEV: Remove widget-test helpers file (#18011) 2022-08-21 09:20:45 +02:00
Jarek Radosz 545bfcaca7
DEV: Simplify "Editing a post stages new content" test (#18007) 2022-08-21 09:20:26 +02:00
Jarek Radosz 870ff48470
DEV: Rework two composer actions tests (#18008) 2022-08-21 09:19:39 +02:00
Jarek Radosz d35ffe8361
DEV: `zoom` isn't used anymore (#18016) 2022-08-21 09:18:19 +02:00
Jarek Radosz 1284d746b0
DEV: Remove `progid:DXImageTransform` (#18017) 2022-08-21 09:17:58 +02:00
Jarek Radosz cb49fcad63
DEV: Clean up keyTrapper prototype override (#18018) 2022-08-21 09:17:33 +02:00
Jarek Radosz dc5dc78309
DEV: Use async and sinon.resolves instead of rsvp (#18001)
…in tests
2022-08-20 11:20:55 +02:00
Jarek Radosz e3108ded11
UX: Hide chat image overflow (#18000)
When there was a problem with an image the built-in frame would expand way outside the message.
2022-08-20 11:19:55 +02:00
Jarek Radosz 9b55c42eee
UX: Correctly center the reply-where modal (#17999)
And make the buttons actually full width, and use css vars.
2022-08-20 11:19:38 +02:00
Jarek Radosz aa59229c80
DEV: Fix busted twitter onebox spec (#18009)
Added in #17519. Was causing spec failures.
2022-08-20 11:19:19 +02:00
Constanza 067c4deb4c
Fix comment to include phpbb 3.3, which is now supported (#18006) 2022-08-19 16:42:32 -04:00
jbrw 73b2522261
FIX: Allow `match_all_tags` to be passed as a URL param (#17972)
`TopicQueryParams` allows for `match_all_tags` to be passed as a query parameter. `TagsController` forces the value to be true.

This change allows a value to be passed, and only sets it to true if no value has been set. It then uses `ActiveModel::Type::Boolean.new.cast` to compare the value.
2022-08-19 15:41:56 -04:00
Isaac Janzen 42385d020d
DEV: Add values to bread-crumbs-right plugin outlet (#18005) 2022-08-19 12:34:46 -05:00
Constanza ef842a4b29
FEATURE: Adding a simple CSV importer (#17993) 2022-08-19 13:09:30 -04:00
Isaac Janzen ce30422d6c
DEV: Add select-kit option to hide values from preview (#18002)
* DEV: Add select-kit option to hide values from preview
2022-08-19 11:39:58 -05:00
Isaac Janzen 36f766399d
DEV: Add after-title-and-category plugin outlet (#18004) 2022-08-19 11:39:46 -05:00
David Taylor 23ec819e70
DEV: Introduce debugging rake task for PostRevision issues (#17998)
See https://meta.discourse.org/t/232885 for context. This rake task enumerates problematic records and prints out a sample of each failure.
2022-08-19 11:30:46 +01:00
Osama Sayegh 67bb0d8a55
DEV: Add profile tab to the experimental user menu (#17982)
This commit adds the profile tab to the experimental user menu. We're adding it to the user menu because it contains links/buttons that are not available anywhere else. We may remove the tab again if we find better places for those links/buttons, but for now it'll stay.

For more context on the experimental user menu, see https://github.com/discourse/discourse/pull/17379.
2022-08-19 13:02:11 +03:00
David Taylor 66376a6569
PERF: Minify admin and wizard JS bundles to match app (#17992)
This regressed when we switched these bundles to be compiled by ember-cli. Before/after sizes:

```
          before                  after
admin.js: 1370 KB (190 KB gz) --> 782 KB (125 KB gzipped)
wizard.js: 127 KB ( 22 KB gz) -->  68 KB ( 18 KB gzipped)
```
2022-08-19 08:35:00 +01:00
Alan Guo Xiang Tan 2d1e50911b DEV: Use button for sidebar section header
Buttons can be focused and action triggered via the enter key compared
to a span.
2022-08-19 10:21:36 +08:00
Andrei Prigorshnev 21d5904d7c UX: fix typo in a blank page copy 2022-08-19 09:36:51 +08:00
dependabot[bot] 2f2e146d2d Build(deps-dev): Bump webmock from 3.17.1 to 3.18.1
Bumps [webmock](https://github.com/bblimke/webmock) from 3.17.1 to 3.18.1.
- [Release notes](https://github.com/bblimke/webmock/releases)
- [Changelog](https://github.com/bblimke/webmock/blob/master/CHANGELOG.md)
- [Commits](https://github.com/bblimke/webmock/compare/v3.17.1...v3.18.1)

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

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-19 09:36:37 +08:00
dependabot[bot] b36a22d6e2 Build(deps-dev): Bump minitest from 5.16.2 to 5.16.3
Bumps [minitest](https://github.com/seattlerb/minitest) from 5.16.2 to 5.16.3.
- [Release notes](https://github.com/seattlerb/minitest/releases)
- [Changelog](https://github.com/minitest/minitest/blob/master/History.rdoc)
- [Commits](https://github.com/seattlerb/minitest/compare/v5.16.2...v5.16.3)

---
updated-dependencies:
- dependency-name: minitest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-19 09:36:23 +08:00
Martin Brennan 49a70a37f1
FIX: Remove last_unread_post excerpt logic for bookmarks (#17979)
The logic to determine what post excerpt to show for
a topic-level bookmark based on the last unread post
was complex and slow, so we decided to remove it and
always just use the first post excerpt.

This commit also fixes an issue where a couple of
instances of for_topic were missed when doing the
Bookmarkable refactors, so:

1. Clicking the topic bookmark link was not taking
   the user to the last unread post
2. When replying to a topic where there was a topic
   level bookmark with the auto delete preference
   of "on owner reply", we were not removing the
   bookmark from the UI correctly.

A test has been added for the former, the latter would
be quite time-consuming to test and not really worth
it considering it's quite an edge case UI bug.
2022-08-19 09:35:25 +10:00
David Taylor df9e546f5d
DEV: Abort qunit tests when clicking in the toolbar (#17989)
Ever opened `/tests`, immediately tried to change the config, and got frustrated that focus keeps getting stolen by the running tests? Worry no more - this commit will make the tests auto-abort when you click any of the input/dropdowns in the QUnit header. It's not perfect - abort will wait until the end of the currently running test, so sometimes focus will be stolen one more time. But it's still a lot better than having to manually find and click the abort button.
2022-08-18 23:32:38 +01:00
Mayfield 542cd1ff90
FIX: allow extra whitespace when asking discobot to perform a bot command (#17738) 2022-08-18 13:32:30 -04:00
Frank 6e682cc7c4
FEATURE: Count views on published pages (#17878)
* FEATURE: Count views on published pages

* Removed trailing whitespaces

* Fixed the test
2022-08-19 00:11:19 +08:00
David Taylor c63580b226
DEV: Add hint when qunit assertion fails and app is unsettled (#17984) 2022-08-18 16:19:46 +01:00
Bianca Nenciu 707034bc75
FIX: Limit new and existent staged users for email topics (#17970)
The maximum_staged_users_per_email site setting controls how many
staged users will be invited to the topic created from an incoming
email. Previously, it counted only the new staged users.
2022-08-18 18:19:20 +03:00
Bianca Nenciu b082f459c9
FEATURE: Limit maximum recipients for group emails (#17971)
New maximum_recipients_per_new_group_email site setting can be used to
prevent spam group emails with many recipients.
2022-08-18 18:18:58 +03:00
Andrei Prigorshnev e49167b311
UX: Improve empty state copy on the activity/replies page (#17784) 2022-08-18 18:00:15 +04:00
Andrei Prigorshnev d7c1ff3116
UX: show blank page placeholder instead of the blue panel that says "No Activity" (#16293) 2022-08-18 17:24:52 +04:00
Jarek Radosz 6c46f4af71
UX: Don't shrink avatar/number box (#17985)
Fixes an issue where longer sidebar item text would squeeze the prefix element
2022-08-18 14:36:30 +02:00
Arpit Jalan 1e58bed4d2
DEV: add tests for --composer-height calculation (#17986)
Follow up for 2b43238973
2022-08-18 18:03:15 +05:30
Jarek Radosz 7b51ac418b
DEV: Asyncify most of Composer controller (#17974)
…and fix cases where we were breaking the promise/async chain (by not awaiting or not returning promises)
2022-08-18 13:58:08 +02:00