Joffrey JAFFEUX
40d1bbab5d
DEV: implements actionDecriptionWidget ( #15367 )
...
This will allow to have more complex behaviors in post-small-actions, while keeping most of the behavior consistent.
2021-12-20 14:53:43 +01:00
Joffrey JAFFEUX
e71cd73965
UX: correctly handles escape on emoji picker ( #15351 )
2021-12-17 16:18:33 +01:00
Joffrey JAFFEUX
bec76f937c
DEV: drops jquery from scrolling-post-stream ( #15313 )
...
Note that this commit also introduces a `domUtils` helper to handle most complex operations in vanilla JS compared to using jQuery.
2021-12-17 14:52:42 +01:00
Joffrey JAFFEUX
8e9799da72
Revert "DEV: supports actionClick for small actions ( #15331 )" ( #15350 )
...
This reverts commit 022dba4727 .
2021-12-17 14:02:12 +01:00
Joffrey JAFFEUX
afdc01a8d8
DEV: allows to import decorateGithubOneboxBody ( #15349 )
2021-12-17 10:05:04 +01:00
Joffrey JAFFEUX
022dba4727
DEV: supports actionClick for small actions ( #15331 )
2021-12-17 09:55:54 +01:00
Joffrey JAFFEUX
cb976ac562
DEV: creates domFromString utility function ( #15310 )
2021-12-17 09:25:34 +01:00
Joffrey JAFFEUX
81b0ac1766
FIX: uses new format for search tag endpoint to prevent issues ( #15328 )
...
Due to our usage of fixtures, backend changes didn't get catch.
2021-12-16 11:57:47 +01:00
Joffrey JAFFEUX
666d291b24
DEV: minor refactoring or jump-to-post ( #15312 )
...
- replaces alias by reads
- drops jquery usage
- autofocus should already be done; so remove custom code
- uses @action
2021-12-15 12:09:26 +01:00
Joffrey JAFFEUX
031f4f06d5
DEV: update and improvements to json editor ( #15294 )
...
- changes on how errors are handled to prevent weird cases
- uses didInsert/willDestroy to setup/clean state
- updates json editor library to 2.6.1
2021-12-14 17:21:49 +01:00
Joffrey JAFFEUX
27fda37a8f
DEV: removes jQuery usage from extend-for-poll ( #15289 )
2021-12-14 16:52:18 +01:00
Joffrey JAFFEUX
ac31c2bbb2
FIX: only consider it handled by composer when a composer ( #15254 )
2021-12-10 13:07:54 +01:00
Joffrey JAFFEUX
e0ea16f05d
DEV: removes jquery usage from admin-watched-words ( #15246 )
2021-12-09 17:06:54 +01:00
Joffrey JAFFEUX
3052eb6ae6
DEV: fixes test as bodyClass is sometimes "foo bar" ( #15248 )
2021-12-09 15:34:50 +01:00
Joffrey JAFFEUX
adb23636e6
DEV: minor full page search refactoring ( #15242 )
...
- drops jquery usage
- shows clear all/ select all only when appropriate
- removes ~ char apparently un-needed
2021-12-09 13:48:08 +01:00
Joffrey JAFFEUX
f889ec2fcd
DEV: refactors admin-plugins/admin-site-settings ( #15244 )
...
- drops jQuery usage
- removes apparently useless clearfix
- uses @action
- drops unused clearFilter function in admin-plugins
2021-12-09 13:47:56 +01:00
Joffrey JAFFEUX
5d44adb9b9
DEV: refactors d-section ( #15245 )
...
- go tagless
- properly declares properties
- deprecates "false" in favour of false
- drops jquery
2021-12-09 13:47:47 +01:00
Joffrey JAFFEUX
76dff7fd9e
DEV: drops jquery usage from discovery-categories ( #15243 )
2021-12-09 13:47:13 +01:00
Joffrey JAFFEUX and Jarek Radosz
828e75c2f3
DEV: minor choose topic refactoring ( #15233 )
...
* DEV: minor choose topic refactoring
- prevents category to be clickable to make clicking topics easier
- drops jQuery
- uses @action
- uses ? operator where possible
- drops un-needed next/schedule usage
* uses topic-status component and prevents pinned icon to be focusable
* Update app/assets/javascripts/discourse/app/templates/components/choose-topic.hbs
Co-authored-by: Jarek Radosz <jradosz@gmail.com >
Co-authored-by: Jarek Radosz <jradosz@gmail.com >
2021-12-09 14:08:21 +11:00
Joffrey JAFFEUX and Jarek Radosz
e1b4e2e034
DEV: removes jquery usage from add-category-tag-classes ( #15232 )
...
Co-authored-by: Jarek Radosz <jradosz@gmail.com >
2021-12-08 14:32:27 +01:00
Joffrey JAFFEUX
a144f49ec2
UX: scroll row to top of container in select-kit ( #15230 )
2021-12-08 12:22:18 +01:00
Joffrey JAFFEUX
f9e2ab570b
FIX: allows more precise placement strategy on mobile ( #15171 )
...
* FIX: allows more precise placement strategy on mobile
- default to absolute on mobile, fixed on desktop
- allows to set a global `placementStrategy` or a specific to each view `mobilePlacementStrategy` `desktopPlacementStrategy`
This is mainly used to allow a proper composer-actions positioning in mobile.
Note this commit also fixes a mouseDown event which could propagate quote-button event and cause the composer to close full screen on mobile
* mobile only
2021-12-03 11:47:33 +11:00
Joffrey JAFFEUX
77a1d8675c
FIX: adds 422 status code to bootstrap json ( #15138 )
...
A post error validation would return a 422 status code. This status code was not accepted with the recent changes to bootstrap-json/index.js and would return a "Discourse Build Error" string, preventing any kind of bootbox popup error in the composer.
2021-11-30 11:54:38 +01:00
Joffrey JAFFEUX
3dc0b9e077
UX: closes multi-select on selection when maximum=1 ( #15092 )
2021-11-29 14:29:11 +01:00
Joffrey JAFFEUX
6e603799eb
FIX: treats ipad as mobileView for popper positioning ( #15091 )
...
* FIX: treats ipad as mobileView for popper positioning
* ensures it doesn’t break wizard
2021-11-29 17:40:01 +11:00
Joffrey JAFFEUX
439cd68e0d
DEV: updates popper to 2.10.2 ( #14986 )
2021-11-17 13:47:55 +01:00
Joffrey JAFFEUX
113ecab7a6
FIX: clear previous errors on second factor form display ( #14987 )
2021-11-17 13:47:38 +01:00
Joffrey JAFFEUX
035822d9e0
DEV: sticky avatar was retained during tests ( #14969 )
2021-11-16 14:33:06 +01:00
Joffrey JAFFEUX
ff7e685a59
DEV: removes jquery usage from discourse-topic ( #14964 )
2021-11-16 13:17:44 +01:00
Joffrey JAFFEUX
0fbeb2e5a2
DEV: removes jquery usage from links-redirect ( #14968 )
2021-11-16 13:16:53 +01:00
Joffrey JAFFEUX
f9682f1c69
DEV: removes jquery usage from html-with-links ( #14966 )
2021-11-16 13:16:43 +01:00
Joffrey JAFFEUX
2167d4d890
FIX: fix regressions introduced in ae16b0a ( #14967 )
...
- ensures arrow up/down doesn’t also apply to textarea while autocomplete is opened
- ensures esc is closing autocomplete and also not closing composer while autocomplete is opened
2021-11-16 12:19:14 +01:00
Joffrey JAFFEUX
49f09345c7
FIX: adds missing class for last visit separator ( #14965 )
2021-11-16 11:40:08 +01:00
Joffrey JAFFEUX
ae16b0a9d4
DEV: reduces jquery usage and memory leaks in composer ( #14924 )
...
Removes more than 60 jquery function leaks in one `Acceptance: Composer` run.
2021-11-16 10:27:05 +01:00
Joffrey JAFFEUX
ef881fdedc
DEV: drops jquery/simplify code/removes leaked event ( #14947 )
2021-11-16 10:26:39 +01:00
Joffrey JAFFEUX
c768c2ab3a
DEV: drops jquery usage in stacked chart ( #14946 )
2021-11-16 10:26:26 +01:00
Joffrey JAFFEUX
43659a6de2
DEV: jquery removal/listeners/cleanup of permalink form ( #14944 )
...
- Removes jquery
- Removes a not unregistered listener and uses component event
- Removes external-url class as it was only valid in one case of the dropdown
- Uses @action
- Tagless
- Other minor changes
2021-11-16 10:25:54 +01:00
Joffrey JAFFEUX
c9a84d8067
DEV: removes unnecessary jquery selector ( #14945 )
2021-11-16 10:25:34 +01:00
Joffrey JAFFEUX
79f49dfb7a
DEV: reduces jquery usage in composer-editor ( #14903 )
2021-11-12 16:40:10 +01:00
Joffrey JAFFEUX
904d509cce
FIX: ensures minimum tags logic is correct and shared ( #14723 )
...
Also fixes a bug where select-kit was not updating noneItem in multi-selects.
2021-11-12 14:04:48 +01:00
Joffrey JAFFEUX
362c47ce6a
DEV: adds a new topic footer dropdown api ( #14747 )
...
This api allows to add a dropdown at the bottom of a topic, note that this API is mobile only for now.
Also included in the commit:
- various doc fixes
- adding tests for both buttons and dropdowns APIs
- uses thrown instead of @ember/error to ensure execution is halted when incorrect parameters are given
2021-11-12 10:21:34 +01:00
Joffrey JAFFEUX
9e19b22f64
DEV: prevents Firefox ESR tests to crash on ||= ( #14758 )
...
A follow up PR should investigate why `proposal-logical-assignment-operators` is not getting used here (test file?) but this should be enough to get things running.
2021-10-28 10:55:22 +02:00
Joffrey JAFFEUX
184ccf4490
DEV: nullify cachedCookFunction to prevent retains ( #14737 )
2021-10-27 16:29:36 +02:00
Joffrey JAFFEUX
4272eb7ffc
FIX: prevents a circular json error in tests ( #14738 )
...
The flow goes from:
- getting current user object
- creating a POJO using some of the current user keys
- passing this POJO around, which end up being used in message bus
- the processing fn associated ens up doing User.create on this object will both create a User object, but also inject store in it, store is holding a reference to currentUser Object and...
BOOM, we have an object holding a reference to the same object, which JSON.stringify used in prepareBody of pretender doesn't like.
2021-10-27 14:01:41 +01:00
Joffrey JAFFEUX
cbd7898d1d
DEV: removes jquery usage from time formatter ( #14700 )
2021-10-25 11:00:15 +02:00
Joffrey JAFFEUX
c7099342ff
DEV: uses vanilla js for fixture qunit helper ( #14703 )
2021-10-25 10:59:58 +02:00
Joffrey JAFFEUX
c0300b13e3
DEV: replaces jquery call by vanilla js in uploader tests ( #14702 )
2021-10-25 10:49:14 +02:00
Joffrey JAFFEUX
cc68eb825b
DEV: drops jquery usage from ajax wizards lib ( #14694 )
2021-10-25 10:24:53 +02:00
Joffrey JAFFEUX
05dda755ed
DEV: removes jquery usage from linkSeenMentions codepath ( #14695 )
2021-10-25 10:24:37 +02:00
Joffrey JAFFEUX
b18c01e3c6
DEV: prevents flakky spec when deleting plugin ( #14701 )
...
Not reseting the registry could lead to assets still being registered for example.
This flakky spec was reprdocible with this call: `bundle exec rspec --seed 9472 spec/components/discourse_plugin_registry_spec.rb spec/components/svg_sprite/svg_sprite_spec.rb`
Which would trigger the following error:
```
Failures:
1) DiscoursePluginRegistry#register_asset registers vendored_core_pretty_text properly
Failure/Error: expect(registry.javascripts.count).to eq(0)
expected: 0
got: 1
(compared using ==)
# ./spec/components/discourse_plugin_registry_spec.rb:248:in `block (3 levels) in <top (required)>'
# ./spec/rails_helper.rb:280:in `block (2 levels) in <top (required)>'
# /Users/joffreyjaffeux/.gem/ruby/2.7.3/gems/webmock-3.14.0/lib/webmock/rspec.rb:37:in `block (2 levels) in <top (required)>'
```
2021-10-25 10:24:21 +02:00
Joffrey JAFFEUX
76a9ca99a8
DEV: removes jquery usage from onebox ( #14683 )
2021-10-22 13:15:46 +02:00
Joffrey JAFFEUX
80ec6f09d3
DEV: removes unnecessary caret position code ( #14665 )
...
We don't support any browser needing this for very long: https://caniuse.com/?search=selectionStart
I'm keeping some protection so It doesn’t crash but ultimately `element.selectionStart` should be enough.
Im not removing this in the commit, but the `caret_position.js` file seems barely used.
2021-10-21 10:06:31 +02:00
Joffrey JAFFEUX
c2d4638ee1
DEV: drops jquery usage from wizard-canvas ( #14662 )
2021-10-20 14:42:06 +02:00
Joffrey JAFFEUX
adb302f801
DEV: drops jquery usage un admin-report-chart ( #14661 )
2021-10-20 14:28:49 +02:00
Joffrey JAFFEUX
d18e3a45b9
FIX: none row doesn’t have a value, use class to target it ( #14659 )
2021-10-20 13:07:58 +02:00
Joffrey JAFFEUX
a5eba43a65
FIX: only replaces double quotes and uses unicode ( #14644 )
...
`’` is actually not converted and doesn’t need to be normalised to `'`
2021-10-19 11:01:46 +02:00
Joffrey JAFFEUX
d76d418e5d
FIX: also track textContent mutations ( #14607 )
...
Tracking innerHTML was not enough to catch every mutations.
2021-10-14 12:14:48 +02:00
Joffrey JAFFEUX
11bd3438c4
FIX: groups using users icon were lacking margin in search ( #14591 )
2021-10-13 12:38:35 +02:00
Joffrey JAFFEUX
b59c419253
FIX: attempts to observe preview mutation asap ( #14590 )
2021-10-13 09:28:55 +02:00
Joffrey JAFFEUX
00e8baffa2
FIX: attempts to enforce caret position in filter ( #14589 )
2021-10-13 08:19:34 +02:00
Joffrey JAFFEUX
be7dcf694e
DEV: correct argument names for addGlobalNotice ( #14582 )
2021-10-12 17:01:54 +02:00
Joffrey JAFFEUX
2af6052307
UX: adds shortcuts for quote (q) and fast edit (e) ( #14552 )
2021-10-07 17:22:28 +02:00
Joffrey JAFFEUX
20e70d0ac5
DEV: adds a topic level bookmark toggle ( #14471 )
2021-10-06 11:53:57 +02:00
Joffrey JAFFEUX
71cf05fbc6
DEV: observe all elements to prevent any missed mutation ( #14507 )
2021-10-05 12:00:05 +02:00
Joffrey JAFFEUX
2d4b9595e8
DEV: uses standard browser_start_timeout ( #14472 )
2021-09-29 13:25:34 +02:00
Joffrey JAFFEUX
fc432a9cab
FIX: incorrect interpolation was limiting to 1 dispatch / component ( #14470 )
2021-09-29 11:14:53 +02:00
4dc14e3a3f
DEV: prevents route nodes to leak on each test run ( #14457 )
...
Note this commit is also adding support for teardown in pre-initializers just like we have for initializers.
Co-authored-by: Jarek Radosz <jradosz@gmail.com >
Co-authored-by: David Taylor <david@taylorhq.com >
2021-09-28 17:08:05 +02:00
Joffrey JAFFEUX
6273dfad4b
REFACTOR: minor changes to api-keys-new ( #14435 )
...
- moves loading scopes to controller
- avoids declaring array
- simplify code
2021-09-27 10:43:47 +02:00
Joffrey JAFFEUX and Jarek Radosz
1abe807528
REFACTOR: setting component mixin ( #14437 )
...
* REFACTOR: setting component mixing
- drops jquery usage
- extract spit function
- uses @action
- removes get usage where possible
- uses helpers
- minor changes
Co-authored-by: Jarek Radosz <jradosz@gmail.com >
2021-09-27 10:43:26 +02:00
Joffrey JAFFEUX
456189795a
FIX: more robust tabindex restriction on preview ( #14425 )
2021-09-23 16:27:51 +02:00
Joffrey JAFFEUX
372479bada
UX: move fast edit before sharing ( #14429 )
...
As sharing has some hover behavior, it was looking slightly clunky with fast edit changing position. Putting sharing at the last position will reduce this effect.
2021-09-23 09:56:00 -04:00
Joffrey JAFFEUX
e28a2735bc
FIX: correctly defines data-attributes used by local-dates ( #14418 )
...
This was previously relying on data-* being allowed by other initialisers which could cause bugs if local dates ends up being used in other contexts.
2021-09-22 16:49:45 +02:00
Joffrey JAFFEUX
dd091fbf36
FEATURE: enables fast edit by default ( #14417 )
2021-09-22 10:15:17 +02:00
Joffrey JAFFEUX
0dd28cdd95
DEV: observes used properties in reason text ( #14389 )
2021-09-20 14:56:33 +02:00
Joffrey JAFFEUX
5a5b166b6d
UX: minor fast edit tweaks ( #14368 )
...
- do not reduce opacity of disabled buttons if they are loading
- replace ‘|’ by single quotes not double quotes
- always start from index 0
- reduces amount of work by checking row's length
- apply quotefix to fallback
- do not add 1 to caretposition if index is 0
2021-09-17 15:36:57 +02:00
Joffrey JAFFEUX
8002b95682
UX: improves fast edit fallback handling ( #14366 )
...
The algorithm will now do the following:
- split selection to retain only first line
- removes possible "* "
- check for first inclusion
- fallback to first row if nothing found
2021-09-17 11:21:50 +02:00
Joffrey JAFFEUX
b83868bfb0
FEATURE: experimental fast edit ( #14340 )
...
Fast edit allows you to quickly edit a typo in a post, this is experimental ATM and behind a site setting: `enable_fast_edit` (default false)
2021-09-15 17:10:30 +02:00
Joffrey JAFFEUX
e263b84196
FIX: prevents extreme cases to overflow in selected content ( #14339 )
...
It would for example cause an issue for a lot of selected items with long names.
2021-09-14 10:49:43 -04:00
Joffrey JAFFEUX
95b15acb1e
DEV: uses forked Mousetrap to avoid leaking listeners ( #14198 )
2021-09-08 14:48:13 +02:00
Joffrey JAFFEUX
d51d94f771
A11Y: do not default to label for aria-label ( #14258 )
2021-09-07 18:24:39 +02:00
Joffrey JAFFEUX
d3be77a0d1
DEV: toggle sk on click ( #14243 )
2021-09-03 18:29:16 +02:00
Joffrey JAFFEUX
142120753f
DEV: prevents focus event bubbling ( #14241 )
2021-09-03 16:41:15 +02:00
Joffrey JAFFEUX
36a81435cf
DEV: simplify logic when selecting an undefined value ( #14225 )
2021-09-03 16:40:20 +02:00
Joffrey JAFFEUX
d00bd626d8
DEV: re-enable ember-cli tests on CI ( #14189 )
2021-09-02 19:27:31 +02:00
Joffrey JAFFEUX
8bb331e63f
DEV: prevents uppy to act on destroyed object ( #14224 )
2021-09-02 18:38:36 +02:00
Joffrey JAFFEUX
d2eef423c3
DEV: prevents broken tests due to focus bubbling ( #14223 )
2021-09-02 18:30:52 +02:00
Joffrey JAFFEUX
a2ca430068
DEV: prevents hooks to create leaks on widgets ( #14207 )
...
Before this, mounted widgets were not correctly unhooked and would keep a reference to a custom widget object.
2021-09-01 14:34:20 +02:00
Joffrey JAFFEUX
55739fd3c9
DEV: cards were leaking mousedown event listener ( #14206 )
2021-09-01 13:01:37 +02:00
Joffrey JAFFEUX
499c69c827
DEV: prevents _lastKeyTimeout to leak after component lifecycle ( #14194 )
2021-08-31 15:22:25 +02:00
Joffrey JAFFEUX
480e512e37
DEV: reapply height hack for iOS ( #14176 )
2021-08-27 12:02:05 +02:00
Joffrey JAFFEUX
14e92bb0ea
FIX: correctly apply unusual padding to profile dropdowns ( #14172 )
2021-08-27 10:03:59 +10:00
Joffrey JAFFEUX
f66217c0b3
DEV: updates popperjs 2.0.6 -> 2.9.3 ( #14163 )
2021-08-26 16:37:04 +02:00
Joffrey JAFFEUX
a4684c151b
REFACTOR: badge-title component ( #14162 )
...
- uses tagName=""
- removes user property which is not being used
- extract utility functions
- better wording for boolean properties
- initializes all properties
- uses @action
- uses optional chaining
- other minor changes
2021-08-26 15:19:09 +02:00
jjaffeux
d4a418e295
DEV: fixes broken tests on ember-cli due to uppy
...
The import was not found and causing the following error:
```
Uncaught TypeError: Class extends value undefined is not a constructor or null
```
2021-08-25 16:01:14 -04:00
Joffrey JAFFEUX
eb52abf076
DEV: adds server:after-body-open ( #14106 )
...
This change is to allow to add a node at the top of body. This is currently done through DOM in a plugin which is causing a full Recalculate Style.
2021-08-24 14:35:44 +02:00
Joffrey JAFFEUX
a230362f65
FIX: sk3 wizard regressions ( #14120 )
2021-08-23 19:57:42 +02:00
Joffrey JAFFEUX
691d1bde54
FIX: do not focus after search if dropdown is collapsed ( #14118 )
2021-08-23 19:33:50 +02:00
Joffrey JAFFEUX
6c0efd50bc
linting ( #14115 )
2021-08-23 14:21:58 +02:00
Joffrey JAFFEUX
d7c185bf3d
DEV: updates chart.js to 3.5.1 ( #14107 )
2021-08-23 13:49:49 +02:00
Joffrey JAFFEUX
cb59681d86
DEV: select-kit third major update with focus on accessibility ( #13303 )
...
Major changes included:
- better support for screen readers
- trapping focus in modals
- better tabbing order in composer
- alerts on no content found/number of items found
- better autofocus in modals
- mini-tag-chooser is now a multi-select component
- each multi-select-component will now display selection on one row
2021-08-23 10:44:19 +02:00