Commit Graph

95 Commits

Author SHA1 Message Date
Claire 0ad919b192 Merge branch 'main' into glitch-soc/merge-upstream
Conflicts:
- `app/javascript/mastodon/features/compose/components/poll_form.js`:
  glitch-soc change because of having changed the default number of
  available poll options.
  Applied upstream's changes while keeping glitch-soc's default number of
  poll options.
- `public/oops.png`:
  We had a minor graphics change, probably not worth diverging from upstream.
  Took upstream version.
2022-11-06 09:50:41 +01:00
Claire 9616f5bb22
Fix compose form submission reloading web interface (#19762)
* Fix compose form submission reloading web interface

Fix regression introduced by #19742

* Fix various compose form buttons being handled like submit buttons

* Fix coding style issue

* Fix missing onClick prop check
2022-11-05 13:43:37 +01:00
Sunny Ripert 0165449e3a
A11y: Explicit <form> element around compose area (#19742) 2022-11-04 17:08:08 +01:00
Claire 25a46d9e59 Merge branch 'main' into glitch-soc/merge-upstream
Conflicts:
- `app/javascript/styles/fonts/montserrat.scss`:
  Code style changes upstream, path changes in glitch-soc.
  Applied upstream's code style changes.
- `app/javascript/styles/fonts/roboto-mono.scss`:
  Code style changes upstream, path changes in glitch-soc.
  Applied upstream's code style changes.
- `app/javascript/styles/fonts/roboto.scss`:
  Code style changes upstream, path changes in glitch-soc.
  Applied upstream's code style changes.
- `app/models/account.rb`:
  Textual conflict only caused by glitch-soc using a different value
  for character limits in a nearby line.
  Applied upstream's changes.
- `app/views/statuses/_simple_status.html.haml`:
  Attribute added to a tag modified by glitch-soc.
  Added upstream's attributes.
- `yarn.lock`:
  Upstream added/updated dependencies close to glitch-soc-only ones.
  Updated/added upstream dependencies.
2022-06-02 09:49:38 +02:00
Eugen Rochko 628c177ebe
Change label of publish button to be "Publish" again (#18583) 2022-06-01 05:03:12 +02:00
Claire 4415005de7 Merge branch 'main' into glitch-soc/merge-upstream
Conflicts:
- `app/javascript/mastodon/features/compose/components/compose_form.js`:
  Conflict caused because of minor code style change upstream, while glitch-soc
  has different code for handling variable maximum chars.
  Ported the change.
- `app/serializers/initial_state_serializer.rb`:
  Conflict because glitch-soc had two extra attributes where upstream added
  one.
  Added upstream's attribute.
2022-05-16 22:29:05 +02:00
Eugen Rochko 0cdb077570
Add language dropdown to compose in web UI (#18420) 2022-05-16 11:18:35 +02:00
Claire be493b6c0d Merge branch 'main' into glitch-soc/merge-upstream
Conflicts:
- `app/models/account.rb`:
  Not a real conflict, just upstream getting rid of unused constants too close
  to glitch-soc-specific contents.
  Removed unused constants like upstream did.
- `app/models/trends.rb`:
  Conflict because glitch-soc disabled email notifications for trending links.
  Upstream has refactored this quite a bit and added trending posts.
  Took upstream code, but disabling the extra trending stuff will come in
  another commit.
- `app/views/admin/trends/links/index.html.haml`:
  Conflict due to glitch-soc's theming system.
  Ported upstream changes accordingly.
2022-02-26 09:29:23 +01:00
Claire 2cd31b3177
Fix reply button on media modal not giving focus to compose form (#17626)
* Avoid compose form and modal management fighting for focus

* Fix reply button on media modal footer not giving focus to compose form
2022-02-25 00:51:01 +01:00
Claire c9669ee167 Merge branch 'main' into glitch-soc/merge-upstream 2022-02-12 21:36:33 +01:00
Claire 38845592c4
Fix controls for unchangeable properties on status edit not being disabled (#17531)
Fixes #17520
2022-02-12 19:00:33 +01:00
Claire f1a6f9062e Merge branch 'main' into glitch-soc/merge-upstream
Conflicts:
- `app/controllers/api/v1/statuses_controller.rb`:
  Upstream moved things around in a place where glitch-soc had support for
  an extra parameter (`content_type`).
  Follow upstream but reintroduce `content_type`.
2022-02-10 19:09:27 +01:00
Eugen Rochko 63002cde03
Add editing for published statuses (#17320)
* Add editing for published statuses

* Fix change of multiple-choice boolean in poll not resetting votes

* Remove the ability to update existing media attachments for now
2022-02-10 00:15:30 +01:00
Claire 61ef81c548 Merge branch 'main' into glitch-soc/merge-upstream
Conflicts:
- `spec/models/status_spec.rb`:
  Upstream added tests too close to glitch-soc-specific tests.
  Kept both tests.
2022-01-23 18:24:01 +01:00
Claire 3a103cd317
Fix text being incorrectly pre-selected in composer textarea on /share (#17339)
Fixes #17295
2022-01-20 20:56:21 +01:00
Claire f60c99a8fb Merge branch 'main' into glitch-soc/merge-upstream 2021-03-24 10:53:50 +01:00
Claire 034f37b85a
Fix compose form behavior in mobile view (#15555)
* Fix ComposeForm being mounted twice in mobile view

Fixes #13094

* Fix compose form focus and pre-selection behavior in mobile view

* Split _updateFocusAndSelection out of componentDidUpdate
2021-03-24 10:19:07 +01:00
Claire f8d867bac4 Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- `app/services/remove_status_service.rb`:
  Conflict caused by us having a distinc Direct timeline.
  Ported upstream changes.
- `app/javascript/mastodon/features/compose/components/compose_form.js`:
  Conflict between glitch-soc's variable character limit and upstream
  refactoring that part of the code.
  Ported upstream changes.
2020-12-05 17:33:37 +01:00
Mélanie Chauvel 68775b6039
Fix character count not ignoring hidden CW field (#15236) 2020-11-30 12:09:34 +01:00
Thibaut Girka 7039dca12c Merge commit 'c07cca4727041ea5a5721acbc603d4bfb45a15a6' into glitch-soc/merge-upstream
Unlike upstream, kept the direct timeline endpoint, as it is still of use in
glitch-soc.
2019-07-07 13:49:31 +02:00
ThibG c07cca4727 Only scroll to the compose form if it's not horizontally in the viewport (#11246)
Avoids jumping the scroll around vertically when giving it focus and
editing long toots.
2019-07-06 18:18:08 +02:00
Thibaut Girka aaec64a500 Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- app/controllers/settings/preferences_controller.rb
- app/lib/user_settings_decorator.rb
- app/models/user.rb
- config/locales/simple_form.en.yml
2019-06-26 23:19:22 +02:00
ThibG 32a4494926 Scroll to compose form rather than reply indicator on focus (#11182) 2019-06-26 14:28:36 +02:00
Thibaut Girka 5717f75340 Merge branch 'master' into glitch-soc/merge-upstream 2019-06-16 21:09:19 +02:00
ThibG 01e362316c Do not scroll in the compose panel on single-column (#11093) 2019-06-16 18:46:55 +02:00
Thibaut Girka 60adda7e59 Merge branch 'master' into glitch-soc/merge-upstream 2019-06-13 22:23:20 +02:00
ThibG b4d67fe57a Fix ordering of keyboard access between CW field, textarea and emoji picker (#11066) 2019-06-13 17:07:43 +02:00
Thibaut Girka 1b0ff4cd69 Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- app/controllers/settings/notifications_controller.rb
- app/javascript/packs/public.js
- app/views/settings/preferences/show.html.haml
- app/views/stream_entries/_simple_status.html.haml
- config/locales/simple_form.en.yml
- config/locales/simple_form.pl.yml
- config/navigation.rb
- config/routes.rb
2019-06-10 18:59:53 +02:00
Eugen Rochko cc8f6b3cda
Fix some React warnings (#10989) 2019-06-07 17:15:18 +02:00
Thibaut Girka 34b8346e7f Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- app/controllers/statuses_controller.rb
- app/controllers/stream_entries_controller.rb
2019-06-07 17:00:36 +02:00
Takeshi Umeda c402c291f4 Fix emoji picker being always displayed (#10979)
* Fix emoji picker being always displayed

* Remove duplicate content with other pull-requests
2019-06-06 12:30:14 +02:00
Jeong Arm 8f3c32e29c Scroll to compose form when focus (#10970)
* Scroll to compose form when focus

* Get rid of constructor
2019-06-05 15:29:45 +02:00
Thibaut Girka 76918554a6 Merge remote-tracking branch 'upstream/master' into glitch-soc/merge-upstream
Conflicts:
- Gemfile.lock
- config/webpack/rules/css.js
- package.json
- yarn.lock
2019-06-03 14:54:30 +02:00
Takeshi Umeda d93b82af87 Improvement variable height in single column layout (#10917)
* Improvement variable height of compose and navigation panel in single column layout

* Fix wrong quotes and missing commas
2019-06-02 10:05:54 +02:00
Thibaut Girka 68629f2773 Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- app/controllers/statuses_controller.rb
  minor conflict because of glitch-soc's theming system
- app/controllers/stream_entries_controller.rb
  minor conflict because of glitch-soc's theming system
2019-05-10 17:09:12 +02:00
ThibG f2be71c293 Add emoji suggestions to CW and poll option fields (#10555)
* Refactor selectComposeSuggestion so that different paths can be updated

* Add suggestions in CW field

* Add emoji suggestion to poll options

* Attempt to fix CSS

* Hide suggestions by default

They will be enabled if the input has focus
2019-05-09 22:10:27 +02:00
Thibaut Girka 33c80e0783 Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- app/models/media_attachment.rb
2019-05-04 16:37:26 +02:00
Eugen Rochko 05ef3462ba
Make the "mark media as sensitive" button more obvious in web UI (#10673)
* Make the "mark media as sensitive" button more obvious in web UI

* Use eye-slash icon instead of eye icon to mean "hide"
2019-05-03 04:34:55 +02:00
Thibaut Girka a9eaa780f5 Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- app/javascript/mastodon/features/compose/components/compose_form.js
  Upstream cleaned up a bit, including on lines in which
  we replaced the hardcoded 500 character limit with a maxChar
  constant. Applied the changes while keeping maxChar instead of 500.
- app/javascript/packs/public.js
  Moved upstream's new animated avatar hover handling in
  app/javascript/core/public.js
- app/javascript/styles/fonts/montserrat.scss
  Upstream fixed local font name, applied those changes.
- app/javascript/styles/fonts/roboto.scss
  Upstream fixed local font name, applied those changes.
- lib/mastodon/version.rb
  Upstream made repo URL configurable, did the same, but
  default to glitch-soc
2019-04-22 20:40:04 +02:00
ThibG bdec58b514 Minor code cleanup (#10613) 2019-04-22 14:55:24 +02:00
Thibaut Girka 4806232997 Merge branch 'master' into glitch-soc/merge-upstream 2019-03-06 11:29:06 +01:00
Eugen Rochko d97cbb0da6
Add UI for creating polls (#10184)
* Add actions and reducers for polls

* Add poll button

* Disable media upload if poll enabled

* Add poll form

* Make delete & redraft work with polls
2019-03-06 04:53:37 +01:00
Thibaut Girka 0e34e91661 Merge branch 'master' into glitch-soc/merge-upstream 2019-02-12 20:32:48 +01:00
Hinaloe 0e513ff862 Don't focus spiler input when disabled spoiler (#10017) 2019-02-12 05:10:31 +01:00
Thibaut Girka e87bd6d94a Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- README.md
  Kept our version
- app/javascript/mastodon/features/compose/components/compose_form.js
  Two changes too close to each other, took both changes
2019-02-01 16:12:20 +01:00
Eugen Rochko 1f95190202
Refactor icons in web UI to use Icon component (#9951)
* Refactor uses of icons to an Icon component in web UI

* Refactor options passed to the Icon component

* Make tests work with absolute component paths
2019-02-01 00:14:05 +01:00
Thibaut Girka 034ffc079e Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- app/controllers/admin/base_controller.rb
  Some refactoring made upstream, no real conflict.
- app/javascript/mastodon/features/compose/components/compose_form.js
  Updated using upstream's code but using maxChars instead of the
  hardcoded length of 500 characters per toot.
- app/javascript/styles/mastodon/components.scss
  Upstream redesigned the onboarding modal. Not sure why we had a
  conflict there.
2018-12-18 16:55:15 +01:00
ThibG 4297de34cf Split out is_changing_upload from is_submitting (#9536)
There is no reason to disable the composer textarea when some media metadata
is being modified, nor is there any reason to focus the textarea when some
media metadata has been modified (prevents clicking one image's description
field right after having modified another).
2018-12-16 21:17:56 +01:00
Thibaut Girka 5bb8563f6c Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
- app/controllers/admin/base_controller.rb
- app/controllers/filters_controller.rb
- app/controllers/invites_controller.rb
- app/controllers/settings/deletes_controller.rb
- app/controllers/settings/exports_controller.rb
- app/controllers/settings/follower_domains_controller.rb
- app/controllers/settings/migrations_controller.rb
- app/controllers/settings/notifications_controller.rb
- app/controllers/settings/preferences_controller.rb
- app/controllers/settings/two_factor_authentication/recovery_codes_controller.rb
- app/javascript/packs/public.js
- app/views/settings/profiles/show.html.haml

Conflicts were mostly due to the addition of body classes to the settings page,
this was caused by rejecting upstream changes for most of those files and
modifying Settings::BaseController instead.

Another cause of conflicts was the deletion of client-side checking of
display name / bio length, this was modified in app/javascript/core/settings.js
instead.
2018-10-26 20:41:43 +02:00
Eugen Rochko 01c169e796
Fix JS error when posting from page without router context (#9073)
Fix #9057
2018-10-24 01:31:31 +02:00