Blake Erickson
08b4753843
DEV: Use FileHelper instead for downloading narrative bot avatar
...
Follow up to
b69450bee2
Using FileHelper here allows us to not have to use another require for
open-uri and gives us all the benefits of FileHelper.
2019-11-14 05:23:51 -07:00
Daniel Waterworth
0bb6b64747
DEV: Run prettier
2019-11-14 11:01:22 +00:00
Daniel Waterworth
7b63c92f47
DEV: Remove path building indirection
...
Tags are now handled just like other context information.
2019-11-14 10:47:14 +00:00
Daniel Waterworth
126b9bd16d
FIX: Tag topic lists should pass on noSubcategories when building the top menu
2019-11-14 10:40:14 +00:00
Daniel Waterworth
a1cf0b88a8
DEV: Make NavItem.fromText take a filterType instead of a URL
...
This is step one of removing filterMode URLs entirely.
2019-11-14 09:43:15 +00:00
Krzysztof Kotlarek
f434de2536
FIX: Tracking Topic State know about category_seen_at ( #8351 )
...
If category got last_seen_at is set TrackingTopicState should know about it and exclude those topics from marking them as new
2019-11-14 16:11:34 +11:00
Blake Erickson
b69450bee2
FIX: need to require open-uri for discourse-narrative-bot plugin
...
By requiring open-uri this will fix the following error:
```
NoMethodError (private method `open' called for #<URI::Generic...
```
also switched to the shorter syntax and removed default options. Since
ruby 2.4 redirect is on by default.
2019-11-13 18:11:50 -07:00
Sam Saffron
03efbad932
DEV: lint files
2019-11-14 11:52:29 +11:00
Martin Brennan
e7226a8c84
FEATURE: Allow scoping search to tag ( #8345 )
...
* When viewing a tag, the search widget will now show a checkbox to scope the search by tag, which will limit search results to that tag on desktop and mobile
2019-11-14 10:40:26 +10:00
Krzysztof Kotlarek
6e1fe22a9d
FEATURE: Dismiss new per category ( #8330 )
...
Ability to dismiss new topics per category.
2019-11-14 11:16:13 +11:00
David Taylor
d095c2cee7
FIX: Allow importing themes with subdirectories in extra_js
...
The folder/file detection was broken by 9fea43e46a
. This commit fixes and adds relevant specs
2019-11-13 23:45:09 +00:00
romanrizzi
0ba0aa00e7
DEV: Use a bigger suite for warming up the tmp folder
2019-11-13 18:34:10 -03:00
Roman Rizzi
c63e84dc62
FEATURE: Send a message to new TL2 users and point them to the advanced tutorial ( #8335 )
...
* FEATURE: Send a message to new TL2 users and point them to the advanced tutorial
* DEV: Use a method to find the discobot user
2019-11-13 18:31:49 -03:00
Robin Ward
a4b89f8187
DEV: Remove some extra `Discourse.Site` uses
2019-11-13 16:00:58 -05:00
Robin Ward
bc2067898e
FIX: Missing User objects in Utilities
2019-11-13 15:55:32 -05:00
Robin Ward
f5ed0dc2e6
FIX: Failing tests
2019-11-13 15:34:30 -05:00
Robin Ward
3d0b310368
DEV: Fix some more deprecated Discourse.User and Discourse.Site
2019-11-13 15:34:30 -05:00
Mark VanLandingham
4843414de6
WIP - set Discourse.currentUser
2019-11-13 15:34:30 -05:00
Mark VanLandingham
38cc1962e7
WIP - discourse/models/user not defined
2019-11-13 15:34:30 -05:00
Mark VanLandingham
f9894aec97
DEV: Remove Discourse.User and import instead
2019-11-13 15:34:30 -05:00
David Taylor
0a14b9b42a
FEATURE: Automatically redirect to authenticator when there is only one
...
This brings the behavior in line with native Discourse SSO. If login is required, and a user tries to visit the forum, they will be directed straight to the external login page without requiring any clicks.
2019-11-13 17:28:12 +00:00
Mark VanLandingham
3c5df82590
DEV: Remove Discourse.Site in favor of import ( #8344 )
...
* DEV: Remove Discourse.Site in favor of importing Site
* Ran prettier
2019-11-13 12:13:47 -05:00
Robin Ward
d2b3ac1282
FIX: Missing braces
2019-11-13 12:04:40 -05:00
Robin Ward
f518065654
FIX: computed is part of `@ember/object` not `@ember/object/computed`
2019-11-13 11:58:09 -05:00
Daniel Waterworth
e98d94f17f
DEV: Commas in top_menu items are no longer used
...
According to eviltrout, commas and pipes were the delimiters of a
Discourse specific microformat, but this is no longer the case and
hasn't been for some time.
2019-11-13 16:21:34 +00:00
David Taylor
481efebe76
DEV: Update backup/restore pipeline to avoid `cd` ( #8347 )
2019-11-13 15:52:28 +00:00
Joffrey JAFFEUX
d2d846a88e
DEV: prevents input/change events to cause a full rerender ( #8339 )
...
Code should decide when to do something with the event value, and maybe cause a re-rerender but it shouldn't be automatic. This is currently a gigantic waste of resources.
2019-11-13 15:49:01 +01:00
Daniel Waterworth
a7dd31496e
DEV: Defer creation of extraNavItems until they are required
...
This also means that each list view gets a fresh set of ExtraNavItems.
2019-11-13 14:04:37 +00:00
Daniel Waterworth
e00ec22582
DEV: Remove extraneous intermediates
2019-11-13 14:03:47 +00:00
Daniel Waterworth
13c5381027
DEV: Don't return navigation item from addNavigationBarItem
...
No plugin or theme that I could find used the return value. Not
providing this to plugins affords us leeway to change the internals.
2019-11-13 13:07:09 +00:00
Daniel Waterworth
58b5d1434b
FIX: Allow forceActive without a customHref
2019-11-13 12:17:57 +00:00
Daniel Waterworth
60e804ad5c
DEV: No need to use call to call these callbacks
...
This is safe because addNavigationBarItem decorates these callbacks,
throwing away the context.
2019-11-13 11:50:40 +00:00
Arpit Jalan
5ff84be8cc
FIX: do not strip nil string
2019-11-13 16:58:14 +05:30
David Taylor
b27e009655
DEV: Temporarily remove NoChdir cop
...
We inherit this rubocop config from plugins and other projects, so the `require` line does not work reliably.
2019-11-13 10:26:40 +00:00
David Taylor
9fea43e46a
DEV: Remove use of `cd` in the app ( #8337 )
...
`FileUtils.cd` and `Dir.chdir` cause the working directory to change for the entire process. We run sidekiq jobs, hijacked requests and deferred jobs in threads, which can make working directory changes have unintended side-effects.
- Add a rubocop rule to warn about usage of Dir.chdir and FileUtils.cd
- Added rubocop:disable for scripts used outside the app
- Refactored code using cd to use alternative methods
- Temporarily skipped the rubocop check for lib/backup_restore. This will require more complex refactoring, so I will create a separate PR for review
2019-11-13 09:57:39 +00:00
Joffrey JAFFEUX
e4df3792f6
DEV: provides a way to hook into createWidget constructor ( #8340 )
2019-11-13 09:29:12 +01:00
Joffrey JAFFEUX
38a18b7aa0
DEV: call destroy() on widget when glue is cleaned up ( #8338 )
2019-11-13 09:28:43 +01:00
Jeff Wong
3b36326cb7
Add plugin outlet after flagged post bodies
2019-11-12 17:47:56 -08:00
tshenry
9caec39aef
UX: Add CSP documentation link to content_security_policy_script_src setting
2019-11-12 14:57:47 -08:00
Roman Rizzi
1c179177e7
REFACTOR: Attach resize controls to images from the markdown pipeline ( #8314 )
2019-11-12 17:32:37 -03:00
Neil Lalonde
7711df40e6
REFACTOR: redo DiscourseTagging.filter_allowed_tags ( #8328 )
...
This method had grown into a monster. Its query had bugs
that I couldn't fix, and new features would be hard to add.
Also I don't understand how it all works anymore...
Replace it with common table expressions that can be queried
to generate the results we need, instead of subtracting
results using lots of "NOT IN" clauses.
Fixed are bugs with tag schemas that use combinations of
tag groups, parent tags, and one-tag-per-topic restrictions.
For example: https://meta.discourse.org/t/130991/6
2019-11-12 14:28:44 -05:00
Robin Ward
4422d9a4bf
DEV: Provide a nicer error when JSON is malformed
...
This is very useful for development. It will give a much nicer error if
the JSON that comes back from the server is missing a required key.
2019-11-12 13:04:52 -05:00
romanrizzi
c9bd463e9d
DEV: Let is not supported, use var instead
2019-11-12 14:58:16 -03:00
David Taylor
836b3f4d82
FIX: Do not deactivate admin accounts with recent posts or api keys ( #8342 )
...
This prevents 'bot' users being deactivated
2019-11-12 16:56:01 +00:00
Mark VanLandingham
213ebc3b32
DEV: Deprecation warning for aliased module usage ( #8341 )
2019-11-12 10:20:14 -06:00
David Taylor
cf4356cd81
UX: Do not add leading/trailing spaces when copying API key in Firefox
...
If there is any other whitespace in the container, then Firefox will add a leading/trailing space when double clicking the key. This commit wraps the key in a div with no whitespace, to work around the problem.
2019-11-12 16:00:57 +00:00
Robin Ward
f49494b0bf
REFACTOR: Remove a few `Discourse.Site` globals
2019-11-12 10:53:22 -05:00
Robin Ward
afadf361b3
REFACTOR: `idMap` should be a private API
2019-11-12 10:53:22 -05:00
Robin Ward
7f651b9666
REFACTOR: Deprecate `Discourse.Site` and `Discourse.User`
2019-11-12 10:53:22 -05:00
Mark VanLandingham
3dd2f2f701
DEV: Remove RSS feed polling in favor of plugin ( #8233 )
2019-11-12 09:49:02 -06:00