Commit Graph

45834 Commits

Author SHA1 Message Date
Discourse Translator Bot
0c269dfd18
Update translations (#17447) 2022-07-12 17:26:04 +02:00
Jarek Radosz
0e61f332ee
DEV: Make sure testing-container fits in the viewport (#17446)
This prevents tests failures when the browser viewport is too small.
2022-07-12 15:32:43 +02:00
Jarek Radosz
0f3109cc53
Revert "DEV: Update @popperjs/core (#17437)" (#17448)
This reverts commit 76bb8f8926.

There is a dropdown positioning regression that needs to be investigated.
2022-07-12 15:27:52 +02:00
Jarek Radosz
76bb8f8926
DEV: Update @popperjs/core (#17437) 2022-07-12 13:16:00 +02:00
David Taylor
f38114e161
DEV: Remove development cache-buster query parameter (#17444)
All our development-mode assets serve a `Cache-Control: no-cache` header, so a query parameter shouldn't be needed. Ember CLI does not include cache-busting parameters, so this change will move the development rails app to the same behaviour.

This will fix adding persistent breakpoints in the dev tools. Previously, the browser would think that the assets have been replaced and throw away the breakpoints.
2022-07-12 11:53:59 +01:00
Jarek Radosz
8a0bddd98d
DEV: Remove an unused js helpers file (#17439) 2022-07-12 12:23:21 +02:00
Jarek Radosz
8bc0ec3fac
DEV: Simplify test setup (#17441) 2022-07-12 12:16:17 +02:00
David Taylor
8a68f49adb
FIX: Detect firefox < 89 as an unsupported browser (#17443)
Prior to v89, Firefox has bugs with document.execCommand("insertText"): https://bugzil.la/1220696

This commit introduces some variables to browser-detect, and therefore wraps the entire logic in an IIFE to avoid state leaking. (`let`/`const` are not supported on older browsers)
2022-07-12 10:50:06 +01:00
Jarek Radosz
6c3e262a7c
FIX: Set resolver options on the legacy resolver (#17440) 2022-07-12 11:42:19 +02:00
David Taylor
e15c63027f
DEV: Use auto-injected keyValueStore for screenTrack (#17434)
This manual assignment was added before the keyValueStore was refactored into a service. Now that it's a service, it gets all our standard auto-injections, including the keyValueStore.

Overwriting an automatic injection like this raises an error in future Ember versions.
2022-07-11 22:12:25 +01:00
Jarek Radosz
162a1f8ba7
DEV: Remove asset precompilation hack (#17428)
I don't think it's needed anymore?
2022-07-11 22:52:20 +02:00
Jarek Radosz
365f558bda
DEV: Update ember-resolver (#17432) 2022-07-11 22:52:01 +02:00
David Taylor
9e9e843136
DEV: Allow use of qunit notrycatch mode (#17433)
This is useful when debugging exceptions - when the box is checked, exceptions will be thrown and handled by the browser rather than being absorbed by qunit. This allows developers to intercept the exception and inspect the stack.
2022-07-11 21:40:38 +01:00
Jarek Radosz
d39334b640
DEV: Remove qunit autorunner (#17430)
It was watching outdated filepaths and using the old `/qunit` page, so it seems safe to assume nobody relied on this runner?
2022-07-11 22:29:33 +02:00
Jarek Radosz
006de01943
DEV: Update ember-cli-handlebars (#17429) 2022-07-11 22:25:40 +02:00
Jarek Radosz
040e1650f6
DEV: Remove old redis option (#17427)
`Redis.exists_returns_integer` is now true by default
2022-07-11 22:15:30 +02:00
Chapoi
d90cdba70f
Revert "UX: missing specificity (#17324)" (#17426)
This reverts commit 4730858598.
2022-07-11 20:20:40 +02:00
Kris
6b57d792bb
UX: Fix exp sidebar toggle alignment, add hovers (#17414) 2022-07-11 12:58:48 -04:00
Isaac Janzen
1f1ba07565
FIX: update flaky bulk invite spec (#17425) 2022-07-11 11:58:23 -05:00
David Taylor
dd62b88f78
DEV: Switch from htmlbars-inline-precompile to ember-cli-htmlbars (#17424)
See https://github.com/ember-cli/ember-cli-htmlbars#tagged-template-usage--migrating-from-htmlbars-inline-precompile
2022-07-11 15:25:40 +01:00
dependabot[bot]
2d2dc45607
Build(deps): Bump redis from 4.5.1 to 4.7.1 (#17310)
Bumps [redis](https://github.com/redis/redis-rb) from 4.5.1 to 4.7.1.
- [Release notes](https://github.com/redis/redis-rb/releases)
- [Changelog](https://github.com/redis/redis-rb/blob/master/CHANGELOG.md)
- [Commits](https://github.com/redis/redis-rb/compare/v4.5.1...v4.7.1)

---
updated-dependencies:
- dependency-name: redis
  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>
2022-07-11 14:58:41 +02:00
Joffrey JAFFEUX
f00cf7a119
DEV: uses resize observer to compute header-offset (#17399) 2022-07-11 14:50:52 +02:00
Jarek Radosz
87353faac6
DEV: Implement distributed mutex in lua (#16228)
The rationale behind this was mostly to stop using `redis.synchronize` (now removed in redis gem 4.6)
2022-07-11 14:16:37 +02:00
Jarek Radosz
6487179dec
DEV: Don't forward test-i18n.js requests (#17422)
This fixes i18n related tests in dev env
2022-07-11 13:14:44 +02:00
Jarek Radosz
2414a175cf
DEV: Update message-bus-client (#17421)
This update covers commits:

* e309b6d [BREAKING Make JS client throw if lastId not number](e309b6d533)
* f0bae69 [DEV: removes dead code](f0bae695b0)
* a72b930 [FIX: force a poll more consistently when visibility changes](a72b9308b4)
* 5c01715 [Permit CORS preflight caching](5c01715432)
* 1789784 [DEV: lint files](17897843b4)
* b9cfb90 [FIX: do not leak visibility event subscriptions on stop/start](b9cfb90dd6)
2022-07-11 13:09:30 +02:00
Jarek Radosz
4437579a8c
DEV: Update ember-qunit (#17251) 2022-07-11 12:40:48 +02:00
Jarek Radosz
189bebb2e4
DEV: Modernize component tests (#17368)
* Use QUnit `module` instead of `discourseModule`
* Use QUnit `test` instead of `componentTest`
* Use angle-bracket syntax
* Remove jQuery usage
* Improve assertions (and actually fix some of them)
2022-07-11 12:29:44 +02:00
Jarek Radosz
5b70b67e78
FIX: Just inline the QUnit CSS in theme-test html (#17415)
Side-steps sassc compilation issues.
2022-07-11 12:01:47 +02:00
David Taylor
0ffa93ccaf
FIX: Ensure category-tag filter routes are functioning (#17420)
This regressed as part of the changes in fc36ac6c.

This commit also introduces a test which would have caught the issue.
2022-07-11 10:54:51 +01:00
Loïc Guitaut
5a4c35f627 FIX: Apply all watched words rules to user fields
Currently we only apply watched words of the `Block` type to custom user
fields and user profile fields.

This patch enables all rules to be applied such as `Censor` or
`Replace`.
2022-07-11 11:51:57 +02:00
Jarek Radosz
3b4ed134ba
DEV: Remove old hbs-in-script warning (#17418)
7 years, I think that's long enough for people to notice? 😉
2022-07-11 11:42:40 +02:00
David Taylor
e62730a4c8
FIX: Ensure splash screen <noscript> is loaded for legacy browsers (#17413)
Previously we would only expand the main `<noscript>` element for older browsers. This commit ensures that we expand all noscript elements on the page, including the one used by the splashscreen to hide itself on the no-js view.
2022-07-11 09:07:10 +01:00
Jarek Radosz
a94dee31c4
DEV: Fix emoji-uploader tests (#17395) 2022-07-11 02:06:58 +02:00
Jarek Radosz
25dacc08ce
DEV: Update @ember/test-helpers (#17247) 2022-07-11 01:54:25 +02:00
dependabot[bot]
06bcb27ea6
Build(deps): Bump rubocop-ast from 1.18.0 to 1.19.1 (#17416)
Bumps [rubocop-ast](https://github.com/rubocop/rubocop-ast) from 1.18.0 to 1.19.1.
- [Release notes](https://github.com/rubocop/rubocop-ast/releases)
- [Changelog](https://github.com/rubocop/rubocop-ast/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rubocop/rubocop-ast/compare/v1.18.0...v1.19.1)

---
updated-dependencies:
- dependency-name: rubocop-ast
  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>
2022-07-11 01:52:59 +02:00
Jarek Radosz
e5346ed84a
Revert "DEV: Don't vendor old qunit css (#17410)" (#17417)
This reverts commit cf85ccca7d.
2022-07-11 09:16:00 +10:00
Jarek Radosz
cf85ccca7d
DEV: Don't vendor old qunit css (#17410) 2022-07-10 14:57:22 +02:00
Jarek Radosz
0d6929d935
DEV: Avoid triggering 404 errors in tests (#17404) 2022-07-10 11:09:13 +02:00
Jarek Radosz
f19f804525
DEV: Don't try to vibrate in test mode (#17405)
It ends up just triggering an error:

```
[Intervention] Blocked call to navigator.vibrate because user hasn't tapped on the frame or any embedded frame yet: https://www.chromestatus.com/feature/5644273861001216.
```
2022-07-10 10:53:00 +02:00
Jarek Radosz
9365d4e86a
DEV: Fix test leakage/flakes (#17407)
Fixes failures like:

```
Unhandled request in test environment: /forum/topics/timings (POST)
```
2022-07-10 10:52:42 +02:00
Jarek Radosz
8bf11ae0ce
DEV: Move scripts into theme.html body (#17409)
They were incorrectly placed after the body
2022-07-10 10:52:29 +02:00
Jarek Radosz
d5dc2496d4
DEV: Update qunit (#17411) 2022-07-10 10:52:14 +02:00
Jarek Radosz
0f01cc7df2
DEV: Reduce jQuery usage in acceptance tests (#17406) 2022-07-10 10:52:02 +02:00
Joe
06ae9229e8
UX: Skip length check on reply drafts (#17408)
We don't count quote characters as part of the reply length.

We don't save drafts if the reply length is less than the min_post_length site setting.

If you start a reply that only contains a bunch of quotes with the intent to continue later, you get no draft.

This PR fixes that.

Note that we still don't save drafts if the composer is completely empty or if you're composing a new topic. This only affects replies.

This PR only changes the behavior if the reply composer contains something regardless of whether that something is a quote or not and ignores the min_post_length site setting.
2022-07-10 13:54:40 +08:00
David Taylor
4f18f3ac20
FIX: Ensure splash screen logic is iOS12 compatible (#17401)
The `?.` safe navigation operator is not supported, and inline scripts are not run through babel.
2022-07-09 11:38:31 +01:00
Jordan Vidrine
fec3df60cb
DEV: Add more color schemes (#17398) 2022-07-08 16:46:32 -05:00
Daniel Waterworth
e91cc340e6
FIX: Add ember redirect for tags/:tag_id -> tag/:tag_id (#17397)
/tags/:tag_id is deprecated, but links may exist in posts.
2022-07-08 14:39:43 -05:00
Kris
5a26c87fa6
UX: less janky animation for experimental sidebar (#17396) 2022-07-08 14:06:01 -04:00
David Taylor
8e0b1ee74d
DEV: Future-proof ThemeJavascriptCompiler spec (#17393)
Previously the spec was hardcoded to expect a certain compiled result. The precise result will change as we update to more recent Ember versions.

Instead, we can compile via the special theme compiler, and then compile our expected result via the normal compiler. If they match, then things are working as intended. This technique should be safe across template-compiler upgrades.
2022-07-08 16:28:46 +01:00
Rafael dos Santos Silva
75e40baa64
FIX: min/max username length limits weren't validated (#17382)
* FIX: min/max username length limits weren't validated

The custom validators introduced in e0d7cda made so we ignored the mix
and max values set on site_settings.yml. That change allowed admins to
set values outside of the range defined on the yaml file.

Related to https://meta.discourse.org/t/group-names-with-more-than-60-characters-broken/232115?u=falco

Co-authored-by: Alan Guo Xiang Tan <gxtan1990@gmail.com>
2022-07-08 12:00:47 -03:00