Commit Graph

1269 Commits

Author SHA1 Message Date
b2a2e4f1e5 FIX: ensures seconds are displayed when used with dates (#10170) 2020-07-06 09:26:31 +02:00
d234e0f922 SPEC: add spec to ensure discobot works in French
PERF: memoize cooked triggers

Follow-up to 3c31884b
2020-06-26 12:48:11 +02:00
3c31884b79 FIX: match discobot triggers on cooked version
In French, the help trigger has a raw content of "afficher l'aider" which is then cooked into "afficher l’aide" (note the different quote character).
Since we were checking the raw content of the trigger against the cooked version of the post, this trigger never worked in French.

This changes so that we cook the trigger before checking in against the cooked version of the post.

DEV: new 'discobot_username' method that is used everywhere instead of 'discobot_user.username' / 'discobot_user.username_lower'
2020-06-25 13:29:55 +02:00
713298c622 FIX: advanced tutorial errors when all categories are secured (#10111)
The category hashtag step will fail with an error when all
categories aren't public. Choose a category that the user can see.
2020-06-24 15:45:50 +10:00
4c543b4a49 UX: Make youtube embeds full width by default (#10106)
* UX: Make youtube embeds full width by default

* UX: Make youtube embeds fluid by default actually

* Remove double sizes in yt-lazy
2020-06-23 17:21:36 -03:00
3370ef188e FEATURE: Remove deprecated uploads url site settings.
The site settings have been replaced with direct image upload since
Discourse 2.3.
2020-06-22 14:32:29 +08:00
26260d50b1 DEV: Import I18n in standard plugins (#10098) 2020-06-22 02:36:45 +02:00
390dc5c7a9 Update translations 2020-06-21 11:58:21 +02:00
36a3675e0a Update translations 2020-06-14 23:39:33 +02:00
ff6811ceb8 Allow multiple groups which can vote when creating a poll (#10015)
* FEATURE: Allow multiple groups which can vote when creating a poll

* DEV: Fix select-kit deprecations

* DEV: Fix lint
2020-06-12 14:52:32 +03:00
65dd8e2fa2 Update translations 2020-06-10 12:01:02 -04:00
3094459cd9 FEATURE: multiple use invite links (#9813) 2020-06-09 20:49:32 +05:30
72c09ab4ae Update translations 2020-06-01 13:58:51 -04:00
13d00eaad0 Drop support for outdated browsers (#9956)
In particular, this includes Internet Explorer 11. Code which existed to support old browsers will be removed over the coming weeks.

https://meta.discourse.org/t/discourse-is-ending-support-for-internet-explorer-11-ie11-on-june-1-2020/137984
2020-06-01 16:38:44 +01:00
3d20a1143b Update translations 2020-05-26 10:06:07 -04:00
979093787f FIX: Include lazyYT-container in cooked post HTML (#9870)
This applies the new styles without waiting for the JS to run.
2020-05-25 14:24:40 -07:00
faeb5793ba UI: various tweaks to polls UI on mobile (#9864) 2020-05-23 19:08:49 +02:00
d9a02d1336 Revert "Revert "Merge branch 'master' of https://github.com/discourse/discourse""
This reverts commit 20780a1eeed56b321daf18ee6bbfe681a51d1bf4.

* SECURITY: re-adds accidentally reverted commit:
  03d26cd6: ensure embed_url contains valid http(s) uri
* when the merge commit e62a85cf was reverted, git chose the 2660c2e2 parent to land on
  instead of the 03d26cd6 parent (which contains security fixes)
2020-05-23 00:56:13 -04:00
20780a1eee Revert "Merge branch 'master' of https://github.com/discourse/discourse"
This reverts commit e62a85cf6fd81a2a34aff6144bd36b9ac459964a, reversing
changes made to 2660c2e21d84bea667e1ea339f91cda352328062.
2020-05-22 20:25:56 -07:00
37128d71c7 Add rails_helper to spec (#9861) 2020-05-22 12:27:52 -04:00
3aecc1990b DEV: Review follow up to 234cd5c3e7f8d1be7c98af7eeb572e5b79f0a16a. 2020-05-20 16:17:59 +08:00
37983a7815 Fix lint. 2020-05-20 10:33:34 +08:00
b7387d4611 DEV: Remove code unused code when seeding narrative bot. 2020-05-20 10:22:51 +08:00
234cd5c3e7 FIX: Switch discobot to pull avatar from gravatar. 2020-05-20 10:20:08 +08:00
96c02caba7 DEV: Change use of Redis flushall to flushdb.
FLUSHALL removes all keys from all databases. Instead we only want to
remove keys from the current Redis database.
2020-05-19 10:20:00 +08:00
f86b123cfc DEV: Remove use of const in untranspiled js 2020-05-15 17:55:34 +01:00
ac042c2bbe UX: Fetch higher-resolution youtube thumbnails where available
We have been using YouTube's 'hqdefault.jpg' image which works consistently to provide a 480x360 thumbnail. YouTube does provide larger thumbnails, but not consistently for every video. By using og:image, we will fetch the best resolution YouTube can provide for each video.

This commit also refactors lazy-yt to re-use the thumbnail already existing in the cooked content. This means we get lazy-loading for free, and avoid hotlinking images to YouTube (when download remote images is enabled on the site).
2020-05-15 17:49:27 +01:00
0c6f30d92a FIX: Allow lazy-yt thumbnails to fetched by pull_hotlinked_images
The thumbnails were being correctly downloaded, but the URLs were not being substituted correctly in post_process_cooked because the lazy-yt output did not include the `onebox` class.
2020-05-14 17:33:16 +01:00
a849bdf0c9 FIX: Don't publish typing presence if composer isn't opened.
Hitting cancel on composer will set composer's reply and title to null
causing our observer to fire.
2020-05-14 12:52:10 +08:00
3d5589e026 DEV: Remove assertions that are not required. 2020-05-14 10:07:55 +08:00
c5ef465179 DEV: Avoid relative paths when importing in plugins. 2020-05-14 10:05:16 +08:00
623920f13d FEATURE: Introduce a staff only override key for discourse-presence.
Merge remote-tracking branch 'origin/coding-standards'
This uses the composer as a bridge for other plugins.
2020-05-13 14:13:31 +08:00
ca8d11635c Add missing export in 15e32dc1af90ceafbb8eadf2e0e5ecc59b9a7527. 2020-05-13 13:57:12 +08:00
15e32dc1af FIX: Composer presence shows user as editing when replying. 2020-05-13 13:41:03 +08:00
aa40a07d73 FIX: Throttle typing function in discourse-presence. 2020-05-13 13:31:06 +08:00
e990d8adce FIX: ensures preview is correctly computing timezone for current user (#9758)
This also fixes a related bug with timezones on displayed date when in calendar range.
2020-05-12 12:30:41 -07:00
6e3fe1abba DEV: Use async/await instead of andThen() 2020-05-11 18:22:48 +02:00
4a74f18e95 PERF: Move fetching of avatar into hijack for discobot certificate 2020-05-11 09:35:06 +08:00
6359a5f8a9 DEV: Fix poll plugin causing error when server reloads in dev env. 2020-05-08 14:59:55 +08:00
781e3f5e10 DEV: Use response.parsed_body in specs (#9615)
Most of it was autofixed with rubocop-discourse 2.1.1.
2020-05-07 17:04:12 +02:00
1dd9df9cd0 REFACTOR: removes overwritten properties and duplicates fn (#9686) 2020-05-07 16:39:53 +02:00
029d091ea8 FIX: displays poll's close date in local time (#9656) 2020-05-06 22:18:47 +02:00
f5bdbd347e Revert "FIX: Discobot has not been created with our custom avatar."
This reverts commit 1062dbc3e9cbf9370803c0acea55eb3c054060ca.

Looks like it's causing some errors on migration.

```
/var/www/discourse/lib/image_sizer.rb:6:in `resize'
/var/www/discourse/lib/upload_creator.rb:120:in `block in create_for'
/var/www/discourse/lib/distributed_mutex.rb:33:in `block in synchronize'
/var/www/discourse/lib/distributed_mutex.rb:29:in `synchronize'
/var/www/discourse/lib/distributed_mutex.rb:29:in `synchronize'
/var/www/discourse/lib/distributed_mutex.rb:14:in `synchronize'
/var/www/discourse/lib/upload_creator.rb:37:in `create_for'
```
2020-05-06 11:28:42 -04:00
2f714c7412 FIX: end date of ranges in html preview was incorrect (#9654)
This commit also remove an unused block of code as previewedTimezones can't be empty anymore.
2020-05-06 17:16:36 +02:00
1062dbc3e9 FIX: Discobot has not been created with our custom avatar.
Previously the image was imported from a Discourse hosted CDN but the
URL has since become invalid. However, it was not caught since all
errors are rescued. This commit fixes the issue by shipping the user
avatar with the plugin.
2020-05-06 09:25:01 +08:00
b299f5f491 DEV: Use Ember.Service over manually registering a factory.
Follow up to 9e827eb420c7aefd166fba1e7724eced81aaffe7
2020-05-06 09:24:49 +08:00
9bff0882c3 FEATURE: Nokogumbo (#9577)
* FEATURE: Nokogumbo

Use Nokogumbo HTML parser.
2020-05-05 13:46:57 +10:00
b8b1cbbfb9 UX: Improve second factor UI (#9526)
This will make a few minor improvements to the second factor user interface. Highlights include:

- Using the site's title to prefix the backup code filename. If non-ascii characters are detected, then prefix "discourse" instead.
- Add icons and change the text on some of the buttons for better clarity and consistency
- Add an education link to the security key modal
2020-05-05 11:05:25 +10:00
3cce608379 Update translations 2020-05-04 10:39:01 -04:00
9e827eb420 DEV: Refactor presence manager to deal with multiple composer states.
This change amends it so we use a static service to keep track of
the typing presence.

It correct various edge cases the initial implementation had

- Faster close messages
- When composing on topic 1 and viewing topic 2 we had incorrect
  presence
- Changing a running composer to reply as new topic or reply to a
  differet topic would not correctly shift presence

Authored by tgxworld, with contributions by sam
2020-05-01 11:37:03 +10:00