discourse/spec/services
Martin Brennan 7c25597da2
FEATURE: Generic hashtag autocomplete part 1 (#18592)
This commit adds a new `/hashtag/search` endpoint and both
relevant JS and ruby plugin APIs to handle plugins adding their
own data sources and priority orders for types of things to search
when `#` is pressed.

A `context` param is added to `setupHashtagAutocomplete` which
a corresponding chat PR https://github.com/discourse/discourse-chat/pull/1302
will now use.

The UI calls `registerHashtagSearchParam` for each context that will
require a `#` search (e.g. the topic composer), for each type of record that
the context needs to search for, as well as a priority order for that type. Core
uses this call to add the `category` and `tag` data sources to the topic composer.

The `register_hashtag_data_source` ruby plugin API call is for plugins to
add a new data source for the hashtag searching endpoint, e.g. discourse-chat
may add a `channel` data source.

This functionality is hidden behind the `enable_experimental_hashtag_autocomplete`
flag, except for the change to `setupHashtagAutocomplete` since only core and
discourse-chat are using that function. Note this PR does **not** include required
changes for hashtag lookup or new styling.
2022-10-19 14:03:57 +10:00
..
notifications Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
anonymous_shadow_creator_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
auto_silence_spec.rb DEV: Use AR enums in reviewables related code 2022-09-22 14:44:27 +02:00
badge_granter_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
base_bookmarkable_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
color_scheme_revisor_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
destroy_task_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
email_settings_exception_handler_spec.rb DEV: Upgrade to Rails 7 2022-04-28 11:51:03 +02:00
email_settings_validator_spec.rb DEV: Upgrade to Rails 7 2022-04-28 11:51:03 +02:00
email_style_updater_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
external_upload_manager_spec.rb DEV: Run some specs with fake S3 implementation instead of stubs 2022-06-28 21:27:52 +02:00
flag_sockpuppets_spec.rb DEV: Use AR enums in reviewables related code 2022-09-22 14:44:27 +02:00
group_action_logger_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
group_mentions_updater_spec.rb DEV: Automatically require 'rails_helper' in all specs (#16077) 2022-03-01 17:50:50 +00:00
group_message_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
hashtag_autocomplete_service_spec.rb FEATURE: Generic hashtag autocomplete part 1 (#18592) 2022-10-19 14:03:57 +10:00
heat_settings_updater_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
inline_uploads_multisite_spec.rb FIX: Maintain HTML `<img` when downloading remote images (#16278) 2022-03-29 10:55:10 +01:00
inline_uploads_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
notification_emailer_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
post_action_notifier_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
post_alerter_spec.rb DEV: Use AR enums in reviewables related code 2022-09-22 14:44:27 +02:00
post_bookmarkable_spec.rb DEV: Guardians aren't active record objects, so shouldn't use fab! (#17789) 2022-08-03 19:17:40 -05:00
post_owner_changer_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
push_notification_pusher_spec.rb FIX: fallback to default push notification icon if none exists (#16961) 2022-06-01 12:00:05 +10:00
random_topic_selector_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
search_indexer_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
site_settings_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
staff_action_logger_spec.rb FIX: Restore trust level when leaving group (#17954) 2022-08-29 13:00:48 +03:00
themes_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
topic_bookmarkable_spec.rb DEV: Guardians aren't active record objects, so shouldn't use fab! (#17789) 2022-08-03 19:17:40 -05:00
topic_status_updater_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
topic_timestamp_changer_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
trust_level_granter_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
user_activator_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
user_anonymizer_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
user_authenticator_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
user_destroyer_spec.rb DEV: Use AR enums in reviewables related code 2022-09-22 14:44:27 +02:00
user_merger_spec.rb FEATURE: Introduce personal_message_enabled_groups setting (#18042) 2022-09-26 13:58:40 +10:00
user_notification_schedule_processor_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
user_silencer_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
user_stat_count_updater_spec.rb Add RSpec 4 compatibility (#17652) 2022-07-28 10:27:38 +08:00
user_updater_spec.rb FEATURE: Implement new onboarding popups (#18362) 2022-10-12 18:38:45 +03:00
username_changer_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
username_checker_service_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
wildcard_domain_checker_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
wildcard_url_checker_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00
word_watcher_spec.rb DEV: Use proper wording for contexts in specs 2022-08-04 11:05:02 +02:00