Commit graph

6154 commits

Author SHA1 Message Date
Renaud Chaput
a3a2414f0e
Rework polyfills loading (#24907) 2023-05-09 14:55:35 +02:00
fusagiko / takayamaki
6579e3af7d
Add more detailed type annotation for Account (#24815) 2023-05-09 12:09:32 +02:00
Renaud Chaput
c8181eb0a4
Enforce stricter rules for Typescript files (#24910) 2023-05-09 03:11:56 +02:00
Renaud Chaput
d9b93bd15e
Enforce React Rules of Hooks with eslint (#24911) 2023-05-09 03:09:11 +02:00
Renaud Chaput
955179fc55
Dont use CommonJS (require, module.exports) anywhere (#24913) 2023-05-09 03:08:47 +02:00
Renaud Chaput
89269e4b71
Mark wheel events on scrollable list as passive (#24914) 2023-05-09 03:07:13 +02:00
Renaud Chaput
ea04f33f50 [Glitch] Fixes build errors from some previous TS-related commits
Port 45579a26cf to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 22:15:00 +02:00
fusagiko / takayamaki
3d9e35375c [Glitch] Rewrite actions/app.ts and reducers/missed_updates.ts with createAction
Port 0999cb4601 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 22:15:00 +02:00
Renaud Chaput
a33d6c946a [Glitch] Remove MastodonMap TS type
Port 9a52a7f7a0 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 22:15:00 +02:00
fusagiko / takayamaki
e8243d5bbd [Glitch] Add type annotation for some js files
Port e38b391940 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 22:15:00 +02:00
Claire
5f0d2b6e3b Copy Typescript type definitions to glitch-soc 2023-05-08 22:15:00 +02:00
Claire
f3af434c25 [Glitch] Fix incorrect import of redux store
Port 9c1929efad to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 22:15:00 +02:00
fusagiko / takayamaki
f4e3e309b1 [Glitch] use configureStore of redux-toolkit instead of createStore of redux
Port 8227af8dcc to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 22:15:00 +02:00
Eugen Rochko
bbd0e9caa6 [Glitch] Add ALT badges to media that has alternative text in web UI
Port 8131a5b330 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 22:15:00 +02:00
Claire
a8939e9098 [Glitch] Change media elements to use aspect-ratio rather than compute height themselves
Port 598e63dad2 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 22:15:00 +02:00
Claire
10f5329ddf [Glitch] Fix incorrect box shadow on avatar in thread view
Port d37c0a1060 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 21:09:49 +02:00
fusagiko / takayamaki
9ab89bb832 [Glitch] Add type annotation for Blurhash component
Port f50105779b to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 21:09:49 +02:00
fusagiko / takayamaki
20f1f3aa7d [Glitch] Add type annotation for IconButton component
Port 5a5975d7f7 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 21:09:49 +02:00
Claire
d77fbbed73 Merge commit 'f877aa9d70d0d600961989b8e97c0e0ce3ac1db6' into glitch-soc/merge-upstream
Conflicts:
- `.github/dependabot.yml`:
  Upstream made changes, but we had removed it.
  Discarded upstream changes.
- `.rubocop_todo.yml`:
  Upstream regenerated the file, we had some glitch-soc-specific ignores.
- `app/models/account_statuses_filter.rb`:
  Minor upstream code style change where glitch-soc had slightly different code
  due to handling of local-only posts.
  Updated to match upstream's code style.
- `app/models/status.rb`:
  Upstream moved ActiveRecord callback definitions, glitch-soc had an extra one.
  Moved the definitions as upstream did.
- `app/services/backup_service.rb`:
  Upstream rewrote a lot of the backup service, glitch-soc had changes because
  of exporting local-only posts.
  Took upstream changes and added back code to deal with local-only posts.
- `config/routes.rb`:
  Upstream split the file into different files, while glitch-soc had a few
  extra routes.
  Extra routes added to `config/routes/settings.rb`, `config/routes/api.rb`
  and `config/routes/admin.rb`
- `db/schema.rb`:
  Upstream has new migrations, while glitch-soc had an extra migration.
  Updated the expected serial number to match upstream's.
- `lib/mastodon/version.rb`:
  Upstream added support to set version tags from environment variables, while
  glitch-soc has an extra `+glitch` tag.
  Changed the code to support upstream's feature but prepending a `+glitch`.
- `spec/lib/activitypub/activity/create_spec.rb`:
  Minor code style change upstream, while glitch-soc has extra tests due to
  `directMessage` handling.
  Applied upstream's changes while keeping glitch-soc's extra tests.
- `spec/models/concerns/account_interactions_spec.rb`:
  Minor code style change upstream, while glitch-soc has extra tests.
  Applied upstream's changes while keeping glitch-soc's extra tests.
2023-05-08 19:28:21 +02:00
Claire
f89f3a8566
Fix glitch-soc's thread line styling (#2214)
Thread lines were misaligned in glitch-soc because we have less padding and
larger avatar sizes.
2023-05-08 18:21:36 +02:00
fusagiko / takayamaki
aff2d55b80 [Glitch] Add type annotation for RelativeTimestamp component
Port 15fd712464 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 16:02:59 +02:00
fusagiko / takayamaki
a49707dacb [Glitch] Rewrite Icon and IconWithBadge with typescript
Port 81f75b1e0e to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 15:59:27 +02:00
Eugen Rochko
7835f8fd22 [Glitch] Fix icons having an image role
Port 24b2c60beb to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 15:57:35 +02:00
Claire
e9eab013e7 [Glitch] Fix audio player width in thread view
Port cf1bc4bb93 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 15:50:05 +02:00
Nick Schonning
51479f5c28 [Glitch] Add eslint-plugin-jsdoc
Port f22b4e556c to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 15:48:08 +02:00
Christian Schmidt
09054f5485 [Glitch] Fix media description not being cleared
Port bfeccf6748 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-05-08 15:41:17 +02:00
Claire
2d029dedd9 Merge commit '0ad2413b35287958f59073a5b63aecc659a64d98' into glitch-soc/merge-upstream
Conflicts:
- `app/javascript/styles/mastodon/forms.scss`:
  Conflict because we ran eslint autofix on upstream files.
- `config/initializers/content_security_policy.rb`:
  Code style changes but we have a different version.
  Kept our version.
- `streaming/index.js`:
  Upstream fixed a typo close to glitch-soc-only code.
  Applied upstream's changes.
2023-05-08 15:28:36 +02:00
Claire
5d18840ab9
Fix more JS linting issues (#2212)
* Fix uses of intl.formatMessages without default messages

* Ignore lint issue for ColumnLink button
2023-05-08 15:16:55 +02:00
fusagiko / takayamaki
9818f34273
Rewrite Domain component as function component (#24896) 2023-05-08 15:12:12 +02:00
fusagiko / takayamaki
5bc8e2d1fd
Use LayoutType from is_mobile in actions/app (#24863) 2023-05-08 15:10:21 +02:00
Claire
16c5354b8c
Fix some more JS linting issues (#2211)
* Minor refactor and linting fixup in `flavours/glitch/actions/accounts.js`

This is some added boilerplate but it's much more consistent with the remaining
of the code, and avoids the linting issue.

* Fix missing /privacy-policy link in DM warning because of wrongly-named import

* Fix unnecessary import

* Fix regexp in flavours/glitch/utils/hashtag.js
2023-05-08 14:02:41 +02:00
たいち ひ
7c1305b3a4
Add TypeScript support for mastodon alias and image imports (#24895) 2023-05-08 11:28:36 +02:00
たいち ひ
76264e3fe8
Rewrite RadioButton component as FC (#24897) 2023-05-08 11:12:53 +02:00
たいち ひ
a65d2d1045
Rewrite Image component as function component (#24893) 2023-05-08 11:12:44 +02:00
たいち ひ
490ccbf40b
Rewrite <NotSignedInIndicator /> as FC (#24903) 2023-05-08 11:12:13 +02:00
たいち ひ
6fdbee240c
Rewrite <Check /> as FC (#24901) 2023-05-08 08:26:02 +02:00
Claire
de74acbe0c
Fix some more Javascript linting issues and discrepancies with upstream (#2209)
* Fix typo in flavours/glitch/features/video/index.js

* Fix various linting issues and discrepancies with upstream
2023-05-07 21:43:25 +02:00
Claire
ed0a407888
Fix thread lines not being properly updated when new posts are received (#2210) 2023-05-07 20:06:10 +02:00
Plastikmensch
179e38cf15
Reset language to default when cancelling a reply (#2114)
When cancelling a reply, the language was still set to the language of the replied to toot.

Signed-off-by: Plastikmensch <plastikmensch@users.noreply.github.com>
2023-05-07 18:45:10 +02:00
Claire
3fb7fe14c6
Fix some of the Javascript linting issues, as well as bugs and unneeded divergences with upstream (#2208)
* Run eslint --fix

* Fix linting issues in video player and reduce divergences with upstream

This includes a behavior change of not auto-looping videos anymore. I don't
remember loops being ever intended, and they have been removed from upstream
a while ago, but we somehow missed the change.

* Fix lint issues in `app/javascript/flavours/glitch/selectors/index.js`

Those were basically caused by dead code that isn't present upstream, so
that brings us closer to upstream as well.

* Fix linting issue and bug in streaming/index.js

* Fix linting issues in config/webpack/shared.js

* Fix unused import in flavours/glitch/features/ui/index.js

* Fix linting issues and reduce divergences from upstream in flavours/glitch/features/ui/components/video_modal.jsx

* Fix linting issues in flavours/glitch/reducers

* Fix linting issues in glitch-soc onboarding modal

* Fix linting issues in flavours/glitch/features/ui/components/navigation_panel.jsx

* Remove dead code for unused local setting navbar_under

* Fix various linting issues

* Fix linting issues in flavours/glitch/components/scrollable_list.jsx and reduce divergences with upstream
2023-05-07 18:22:25 +02:00
Claire
6f64c79ca4
Fix SCSS linting issues (#2207)
* Disable font-family-no-missing-generic-family-keyword for font-awesome accessibility icons

* Run stylelint --fix

* Avoid `@extend` directives with doodle modal CSS

* Drop use of `@extend` for notification cleanup buttons SCSS

* Run prettier on SCSS
2023-05-07 15:04:59 +02:00
Claire
a6207d243b
New Crowdin updates (#2202)
* New translations en.json (Russian)
[ci skip]

* New translations en.json (Russian)
[ci skip]
2023-05-07 13:37:47 +02:00
fusagiko / takayamaki
140aa6b054
Rewrite VerifiedBadge component as function component (#24892) 2023-05-07 09:10:58 +02:00
Claire
746979f75d
Fix compose textarea scroll behavior (#24872) 2023-05-05 18:58:58 +02:00
S.H
5811ccc611
Fix column back button error (#24867) 2023-05-05 15:13:28 +02:00
Nick Schonning
f95125bd04
Fail ESLint for Warnings in CI (#24836) 2023-05-04 09:48:50 +02:00
Florin
27bafabb64
Fix Back button going outside the app (#24835) 2023-05-04 08:14:04 +02:00
Renaud Chaput
45579a26cf
Fixes build errors from some previous TS-related commits (#24811) 2023-05-03 16:28:14 +02:00
fusagiko / takayamaki
0999cb4601
Rewrite actions/app.ts and reducers/missed_updates.ts with createAction (#24801) 2023-05-03 15:28:39 +02:00
Renaud Chaput
9a52a7f7a0
Remove MastodonMap TS type (#24807) 2023-05-03 13:32:11 +02:00
fusagiko / takayamaki
e38b391940
Add type annotation for some js files (#24787) 2023-05-03 11:43:29 +02:00
Claire
9c1929efad
Fix incorrect import of redux store (#24805) 2023-05-03 10:29:45 +02:00
Claire
d37c0a1060
Fix incorrect box shadow on avatar in thread view (#24800) 2023-05-03 09:11:20 +02:00
fusagiko / takayamaki
8227af8dcc
use configureStore of redux-toolkit instead of createStore of redux (#24790) 2023-05-02 20:39:06 +02:00
Eugen Rochko
8131a5b330
Add ALT badges to media that has alternative text in web UI (#24782) 2023-05-02 14:47:04 +02:00
Claire
598e63dad2
Change media elements to use aspect-ratio rather than compute height themselves (#24686) 2023-05-02 13:58:48 +02:00
fusagiko / takayamaki
f50105779b
Add type annotation for Blurhash component (#24750) 2023-05-02 12:54:00 +02:00
fusagiko / takayamaki
5a5975d7f7
Add type annotation for IconButton component (#24753) 2023-05-02 12:53:32 +02:00
Nick Schonning
fc56eda94b
Bump stylelint-config-standard-scss from 7.0.1 to 9.0.0 (#24755)
Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>
2023-05-01 18:23:57 +09:00
fusagiko / takayamaki
15fd712464
Add type annotation for RelativeTimestamp component (#24749) 2023-05-01 00:51:31 +02:00
fusagiko / takayamaki
81f75b1e0e
Rewrite Icon and IconWithBadge with typescript (#24747) 2023-05-01 00:51:00 +02:00
Eugen Rochko
0a08e9d3d3
New Crowdin updates (#24678)
Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>
2023-04-30 17:02:11 +09:00
Claire
678d836c7d
Fix pop-in player placeholder layout in thread view (#24715) 2023-04-30 06:42:43 +02:00
Claire
cf1bc4bb93
Fix audio player width in thread view (#24713) 2023-04-30 06:42:22 +02:00
Nick Schonning
f22b4e556c
Add eslint-plugin-jsdoc (#24719) 2023-04-30 02:29:54 +02:00
Christian Schmidt
bfeccf6748
Fix media description not being cleared (#24720) 2023-04-30 02:29:24 +02:00
Claire
e79998a11a Restore translations from not-yet-ported onboarding changes as glitch-soc translations 2023-04-29 19:38:08 +02:00
Eugen Rochko
38eeed6cbf [Glitch] Change logo version in header based on screen size in web UI
Port 6028d047b9 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 18:54:13 +02:00
Nick Schonning
1033598416 [Glitch] Enable formatjs/prefer-pound-in-plural
Port 2daa5a1549 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 18:38:23 +02:00
Claire
edec08b970 Disable full-width media in thread view 2023-04-29 12:43:01 +02:00
Claire
cb97a92954 [Glitch] Fix thread lines in right-to-left locales (#24714)
Port 105f8687e4 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 12:21:44 +02:00
Claire
103b6de8b2 [Glitch] Fix sass warning about deprecated slash as division (#24653)
Port 1527b02c6d to glitch-soc

Co-authored-by: Nick Schonning <nschonni@gmail.com>
Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 12:17:06 +02:00
Eugen Rochko
7b01b7c3bf [Glitch] Add lines to threads in web UI
Port 290e4aba31 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 12:08:13 +02:00
Eugen Rochko
8015297f9e [Glitch] Change label from "For you" to "People" on explore screen in web UI
Port 7cf963eec2 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 11:34:44 +02:00
Chike Nwaenie
374a109546 [Glitch] Change styling of the recommended accounts to allow bio to be more visible
Port e1b4eeb636 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 11:28:24 +02:00
Christian Schmidt
0091b28ffe [Glitch] Use CSS to trim long card descriptions
Port e713c545b8 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 11:26:58 +02:00
Claire
11b34a903a [Glitch] Fix infinite loop in emoji replacement code
Port fbb4de3dbc to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 11:14:43 +02:00
Claire
0a813d96db [Glitch] Fix characters being emojified even when using Variation Selector 15 (text)
Port 37886c28da to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 11:12:35 +02:00
fusagiko / takayamaki
66bda4713e [Glitch] Allow == when null checking
Port c1a7e38d2b to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
2023-04-29 11:09:46 +02:00
Claire
12b935fadf Merge branch 'main' into glitch-soc/merge-upstream
Conflicts:
- `.github/dependabot.yml`:
  Updated upstream, removed in glitch-soc to disable noise.
  Kept removed.
- `CODE_OF_CONDUCT.md`:
  Upstream updated to a new version of the covenant, but I have not read it
  yet, so kept unchanged.
- `Gemfile.lock`:
  Not a real conflict, one upstream dependency updated textually too close to
  the glitch-soc only `hcaptcha` dependency.
  Applied upstream changes.
- `app/controllers/admin/base_controller.rb`:
  Minor conflict due to glitch-soc's theming system.
  Applied upstream changes.
- `app/controllers/application_controller.rb`:
  Minor conflict due to glitch-soc's theming system.
  Applied upstream changes.
- `app/controllers/disputes/base_controller.rb`:
  Minor conflict due to glitch-soc's theming system.
  Applied upstream changes.
- `app/controllers/relationships_controller.rb`:
  Minor conflict due to glitch-soc's theming system.
  Applied upstream changes.
- `app/controllers/statuses_cleanup_controller.rb`:
  Minor conflict due to glitch-soc's theming system.
  Applied upstream changes.
- `app/helpers/application_helper.rb`:
  Minor conflict due to glitch-soc's theming system.
  Applied upstream changes.
- `app/javascript/mastodon/features/compose/components/compose_form.jsx`:
  Upstream added a highlight animation for onboarding, while we changed the
  max character limit.
  Applied our local changes on top of upstream's new version.
- `app/views/layouts/application.html.haml`:
  Minor conflict due to glitch-soc's theming system.
  Applied upstream changes.
- `stylelint.config.js`:
  Upstream added ignore paths, glitch-soc had extra ignore paths.
  Added the same paths as upstream.
2023-04-29 10:44:56 +02:00
Claire
105f8687e4
Fix thread lines in right-to-left locales (#24714) 2023-04-28 13:12:35 +02:00
Claire
2a3a110f00
Fix wrong classes audio and video instead of audio-player and video-player in CSS (#24711) 2023-04-28 11:15:43 +02:00
Eugen Rochko
8979b70975
Add default post text to onboarding flow in web UI (#24705) 2023-04-28 10:05:34 +02:00
Eugen Rochko
6028d047b9
Change logo version in header based on screen size in web UI (#24707) 2023-04-28 10:00:33 +02:00
Eugen Rochko
7cf963eec2
Change label from "For you" to "People" on explore screen in web UI (#24706) 2023-04-28 08:54:20 +02:00
Claire
a5bc4ea550
Fix refering to unused preview-card CSS class instead of status-card (#24696) 2023-04-28 07:50:31 +02:00
Claire
d8a06c1375
Fix preview cards layout in thread view (#24677) 2023-04-27 01:45:19 +02:00
Eugen Rochko
d4511f2a76
New Crowdin updates (#24617)
Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>
2023-04-27 04:55:06 +09:00
Plastikmensch
1565af1caf
[Glitch] [Proposal] Make able to write React in Typescript (#2190)
Port 4520e6473a to glitch-soc

Signed-off-by: Plastikmensch <plastikmensch@users.noreply.github.com>
2023-04-26 21:30:41 +02:00
Claire
1527b02c6d
Fix sass warning about deprecated slash as division (#24653)
Co-authored-by: Nick Schonning <nschonni@gmail.com>
2023-04-25 22:15:00 +02:00
Plastikmensch
678480d4d3
Fix small mistakes in RTL layout (#2182)
Borders in blockquotes in reply-indicator weren't colored properly.

avatar margin when viewing edited toots dropdown was applied to wrong side.

Conversations had padding applied to the wrong side.

Padding for notifcation cleaner checkboxes was applied to wrong side.

Signed-off-by: Plastikmensch <plastikmensch@users.noreply.github.com>
2023-04-25 20:33:27 +02:00
Plastikmensch
aea7866161
Change drawer--header to drawer__header (#2189)
Signed-off-by: Plastikmensch <plastikmensch@users.noreply.github.com>
2023-04-25 20:29:04 +02:00
Eugen Rochko
c35e3cb6ac
Add more tips to onboarding flow in web UI (#24646) 2023-04-25 11:12:37 +02:00
Eugen Rochko
8099ba04be
Change hashtags and mentions in bios to open in-app in web UI (#24643) 2023-04-25 06:33:21 +02:00
Eugen Rochko
804aa8d501
Fix cutting off first letter of hashtag links sometimes in web UI (#24623) 2023-04-24 09:53:54 +02:00
Nick Schonning
2daa5a1549
Enable formatjs/prefer-pound-in-plural (#24622) 2023-04-24 08:07:19 +02:00
Eugen Rochko
290e4aba31
Add lines to threads in web UI (#24549) 2023-04-24 08:07:03 +02:00
Nick Schonning
ef3675d688
Remove empty Kushubian (csb) local files (#24151) 2023-04-23 22:43:12 +02:00
Chike Nwaenie
e1b4eeb636
Change styling of the recommended accounts to allow bio to be more visible (#24480) 2023-04-23 22:33:08 +02:00
Christian Schmidt
e713c545b8
Use CSS to trim long card descriptions (#24265) 2023-04-23 22:32:47 +02:00