Commit Graph

30 Commits (145a5a8a8d0f33be547fabb802ae8fd65b33914e)

Author SHA1 Message Date
Michael Telatynski 145a5a8a8d
Conform more code to strict null checking (#10153)
* Conform more code to strict null checking

* Conform more code to strict null checking

* Iterate

* Iterate
2023-02-15 13:36:22 +00:00
Michael Telatynski 030b7e90bf
Enable `@typescript-eslint/explicit-function-return-type` in /src (#9788)
* Enable `@typescript-eslint/explicit-member-accessibility` on /src

* Prettier

* Enable `@typescript-eslint/explicit-function-return-type` in /src

* Fix types

* tsc strict fixes

* Delint

* Fix test

* Fix bad merge
2023-01-12 13:25:14 +00:00
Michael Telatynski f1e8e7f140
Enable `@typescript-eslint/explicit-member-accessibility` on /src (#9785)
* Enable `@typescript-eslint/explicit-member-accessibility` on /src

* Prettier
2022-12-16 12:29:59 +00:00
Michael Weimann 526645c791
Apply prettier formatting 2022-12-12 12:24:14 +01:00
Travis Ralston 10a429c68d
Include a file-safe room name and ISO date in chat exports (#9440)
* conversation export named after room

* sanitization added for exported file name

* sanitization added for exported file name

* sanitization added for exported file name

* sanitization added for exported file name=>lint error fixed

* sanitization added for exported file name=>lint error fixed

* sanitization added for exported file name=>redundancy removed

* sanitization added for exported file name=>redundancy removed

* reverted to previous commit

* sanitization added for exported file name=>redundancy removed

* exported chat date iso formatted

* conversation export named after room

* conversation export named after room

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>

* code refacto filename date format

* Add docs to fn

* Bring in a util library for sanitizing

* Extract file naming function and make consistent for all 3 types

Also use the library we dragged in

* Write tests & associated fixes

* Apply linters locally

* Include new date util in index

Co-authored-by: Sinharitik589 <sinharitik18112835@gmail.com>
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
Co-authored-by: yaya-usman <yayaazeez222@gmail.com>
Co-authored-by: Sinharitik589 <67551927+Sinharitik589@users.noreply.github.com>
2022-10-17 19:54:10 -06:00
Robin 7335b35fbb
Avoid looking up settings during timeline rendering (#8313)
* Avoid showHiddenEventsInTimeline lookups

* Avoid MSC3531 feature lookups

* Test that showHiddenEventsInTimeline doesn't get looked up while
rendering

* Fix code review nits

Co-authored-by: Travis Ralston <travisr@matrix.org>
2022-04-14 23:23:22 +00:00
Travis Ralston 9350c50f87 Step 6: Refactor event rendering to stop using `getComponent`
We move all of the event tile rendering into a factory manager for a couple reasons:
1. `EventTile` is uncomfortably large for a file
2. A simple map isn't possible anymore (can't convert the existing maps like `eventTileTypes` to `Record<string, typeof React.Component>` because the types are actually incompatible)

So, by having a factory manager place we can more easily render components without having to use `getComponent()` all over the place, and without lying to ourselves about how simple the event rendering path is.

This change also moves quite a bit of the rendering path into the new `EventTileFactory` file so it can be easily seen by future developers.
2022-03-28 14:02:31 -06:00
Michael Telatynski 3229b06b01
Add internationalisation to progress strings in room export dialog (#7385) 2021-12-15 16:21:51 +00:00
Aaron Raimist bdc56be863
Auto fix
Signed-off-by: Aaron Raimist <aaron@raim.ist>
2021-10-22 17:23:37 -05:00
Dariusz Niemczyk 2c66403b3c Replace console.info with logger.info
Related https://github.com/vector-im/element-web/issues/18425
2021-10-18 14:08:23 +02:00
Dariusz Niemczyk 9c594a8a96 Replace console.logs to logger.log
Related https://github.com/vector-im/element-web/issues/18425
2021-10-18 14:08:23 +02:00
Jaiwanth 5dbc103486 Modify font-regex and declare json type 2021-08-14 13:01:46 +05:30
Jaiwanth 3efa699b88 Delint 2021-08-14 00:14:57 +05:30
Jaiwanth 31c9e5962c Move export dialog to async-components 2021-08-14 00:03:02 +05:30
Jaiwanth edfc8af6cf Apply PR Suggestions 2021-08-13 08:30:50 +05:30
Jaiwanth 04edf4103f Remove unnecessary awaits 2021-07-30 11:46:55 +05:30
Jaiwanth 9771f4d6c4 PascalCasing for enums 2021-07-27 00:00:52 +05:30
Jaiwanth b91309be82 Apply suggestions from review 2021-07-26 23:40:27 +05:30
Jaiwanth f07402d234 Fix types and precompute blob sizes to avoid overflows 2021-07-19 13:17:19 +05:30
Jaiwanth 87c624d085 Use ref for progress updates 2021-07-02 16:52:33 +05:30
Jaiwanth 6ca664636e Display progress 2021-07-02 10:23:34 +05:30
Jaiwanth 08d886e9d1 Delint 2021-06-30 14:08:22 +05:30
Jaiwanth e404fa3cae Apply suggestions 2021-06-29 10:57:02 +05:30
Jaiwanth d46fe678b0 Handle export cancellation 2021-06-27 20:55:54 +05:30
Jaiwanth 566e7bc8d6 format 2021-06-25 15:52:01 +05:30
Jaiwanth 4af8ec4d40 Explicitly declare file extensions for stickers and log event fetching progress 2021-06-25 15:40:28 +05:30
Jaiwanth 3718826e94 refactor to share downloading code across all formats 2021-06-25 11:16:59 +05:30
Jaiwanth ccd02c48b3 Nicer indentation 2021-06-24 22:49:36 +05:30
Jaiwanth 70cc2b20d5 Fix auto import 2021-06-24 18:23:08 +05:30
Jaiwanth 112dfa2b96 Finish JSON export implementation 2021-06-24 18:19:12 +05:30