Commit Graph

65 Commits

Author SHA1 Message Date
ganfra
526c33df17 maplibre : remove all mapbox references and update plugin to be compatible. 2024-05-21 16:12:19 +02:00
Benoit Marty
67e0ca9202 Add name to call argument. 2024-03-08 17:30:32 +01:00
Benoit Marty
b6aa44d374 Remove unused val. 2024-02-21 18:30:08 +01:00
Benoit Marty
b48aa45d51 Add first tests for ShowLocationView 2024-02-19 13:36:08 +01:00
Benoit Marty
9c599a298a Introduce fun aShowLocationState to reduce boilerplate code. 2024-02-19 13:35:24 +01:00
Jorge Martin Espinosa
973c57d401 Update Compound to v0.0.5 and update icons (#2380)
Update Compound to `v0.0.5`:

- Make sure we fix all the breaking changes.
- Update some icons to use the compound version instead.
-Replace icons with their Compound counterparts when possible.
- Clean up unused icons.
- Fix issues with incorrect icons or sizes being used after replacing the temporary icons with the Compound ones.

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-02-12 16:41:58 +00:00
Benoit Marty
378692f743 Fix moar ktlint issues 2024-01-11 10:02:10 +01:00
renovate[bot]
7e9cda3aa9 Update plugin ktlint to v12.1.0 (#2200)
* Update plugin ktlint to v12.1.0

* Run `./gradlew ktlintFormat` and fix some issues manually.

* Fix other issues reproted by Ktlint

* Limit false positives, KtLint removes unnecessary curly brace in String templates.

* Remove useless Unit

* Minor improvements over ktlint changes

* Restore `AlertDialogContent` behaviour

* Update screenshots

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Benoit Marty <benoit@matrix.org>
Co-authored-by: Jorge Martín <jorgem@element.io>
Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-01-10 16:22:24 +01:00
Benoit Marty
d9fb5ce007 Remove now useless ExperimentalLayoutApi opt in 2023-12-28 12:41:02 +01:00
Benoit Marty
7c58a843dc Add Konsist test to use isTrue() instead of isEqualTo(true), and fix existing issues. 2023-12-04 15:23:36 +01:00
Benoit Marty
65924eac6b Add Konsist test to use isFalse() instead of isEqualTo(false), and fix existing issues. 2023-12-04 15:21:50 +01:00
Benoit Marty
45883975c4 Add Konsist test to check that assertThat is imported, and fix existing issues. 2023-12-04 15:18:01 +01:00
Jorge Martin Espinosa
a8b85fb4e6 Extract compound tokens and theming to compound-android library (#1888)
* Replace tokens & icons with the external Compound ones

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-11-27 10:30:07 +01:00
Benoit Marty
4ae0790cc1 Remove default value for lambda.
We enforce a value to be provided and it's better for code coverage.
2023-11-22 17:28:23 +01:00
Jorge Martin Espinosa
14cf2b0440 Iterate design on several screens: update icons, replace PreferenceTexts (#1771)
- Batch import new icons from the design team.
- Rename _september icons since they're just extra icons that need to be integrated in Compound in the future, and it should be ok if we don't distinguish between ic_september_*, ic_november_* etc., so all icons are now simply ic_* in the designsystem module.
- Create a new CompoundIconListPreviewProvider to add chunked lists of icons for previews. Add an exception for it to Konsist.
- Move some icons to use Compound icons.
- Remove most PreferenceText usages, use ListItem instead.

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-11-15 10:52:37 +01:00
jonnyandrew
e376feba22 Add analytics for voice messages (#1706) 2023-11-02 09:32:22 +00:00
Jorge Martin Espinosa
0bd9c78836 Initial support for member suggestions (#1631)
* Initial support for member suggestion (search and UI)

* Add custom `BottomSheetScaffold` implementation to workaround several scrolling bugs

* Start searching as soon as `@` is typed, add UI following initial designs

* Extract suggestion processing code

* Extract component, add previews, fix tests

* Add tests

* Add exception from kover to the forked bottom sheet code

* Add a feature flag for mentions

- Extract composer & mention suggestions to their composable.
- Extract mentions suggestions processing to its own class.
- Add `MatrixRoom.canTriggerRoomNotification` function.
- Update strings and conditions for displaying the `@room` mention.

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-27 10:26:40 +00:00
jonnyandrew
ffa6c43503 [Voice messages] Add voice recording UI (#1546)
---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-12 15:17:18 +00:00
Benoit Marty
de31f8a73a Konsist: add test Data class state MUST not have default value, and fix existing issues 2023-10-10 17:31:04 +02:00
Benoit Marty
d2ca528679 Detekt: Rename DayNightPreviews to PreviewsDayNight to follow naming convention.
MultiPreview annotations should start with `Previews` as prefix
2023-09-21 08:30:36 +02:00
Benoit Marty
54ca7c1ea5 More cleanup 2023-09-20 17:32:32 +02:00
Benoit Marty
d6ea21da22 Migrate other icons to compound icons. 2023-09-20 16:44:59 +02:00
Benoit Marty
e326e49e4c Use DayNightPreview 2023-09-19 11:49:12 +02:00
Marco Romano
b860bd30bd GRemove the @JvmField annotation whenever using WarmUpRule. 2023-09-13 15:19:26 +02:00
Marco Romano
5ddaf0547f Update analytics sdk to v0.8.0 (#1284)
Integrates a few breaking changes introducing a `messageType` Composer prop:
- Sends `messageType` = Text by default in composer.
- Refactors existing location analytics to send the appropriate `messageType`.
2023-09-12 14:01:33 +02:00
jonnyandrew
301e49c3a3 Reduce test flakiness by warming up molecule tests (#1226) 2023-09-06 10:08:21 +00:00
Benoit Marty
bcede44407 Move module features.analytics.test to services.analytics.test. FakeAnalyticsService was not implemented at the correct location. 2023-08-28 14:31:36 +02:00
Benoit Marty
52853101d9 migrate object to data object (#1135) 2023-08-24 09:32:44 +02:00
Marco Romano
3609d419c4 Fix detekt 2023-08-18 15:55:41 +02:00
Marco Romano
d1ca452326 Add missing tests 2023-08-18 15:55:41 +02:00
Marco Romano
ac32d724c1 Fix wrong packages after refactor 2023-08-18 15:55:41 +02:00
Marco Romano
7c378dbdd5 Remove redundant screenshots 2023-08-18 15:55:41 +02:00
Marco Romano
314c0499a5 Add location dialogs to show location. Always show FAB. 2023-08-18 15:55:41 +02:00
Marco Romano
917965a9b6 Move AndroidLocationActions to impl package 2023-08-18 15:55:41 +02:00
Marco Romano
675dd4b109 Add permission request flow to ShowLocation feature too.
TODO:
- Presenter Tests
- Add Dialogs in View
2023-08-18 15:55:41 +02:00
Benoit Marty
996574f2c6 Enable detekt rule PreviewPublic and fix existing issues. 2023-07-26 10:08:39 +02:00
Marco Romano
71676c3faf Static images improvements (#933)
1. On devices less than xhdpi request a 1x image from MapTiler (such devices are generally old, slower and with little memory so avoiding to get the 2x image only to have to shrink it later could help).
2. Coerce too big width/height combos within the API limits keeping the aspect ratio (this will allow requests on big horizontal displays to succeed).
3. Don't crash when given weird width/height combos (i.e. zero or negative).
4. Introduce interfaces to hide this whole logic and make it easier for forks to implement their own.

Related to:
- https://github.com/vector-im/element-meta/issues/1678
2023-07-21 13:37:08 +00:00
Marco Romano
ffaf24751a Use correct share my location icon in button (#936)
As per newer design specs.

Related to:
- https://github.com/vector-im/element-meta/issues/1678
2023-07-20 13:59:06 +00:00
Marco Romano
d5a93a50e0 Add screenshots with ~1.5 lines long desc to expanded location view (#923)
This will help in catching alignment regressions.

Related to:
- https://github.com/vector-im/element-meta/issues/1678
2023-07-20 13:42:35 +00:00
Marco Romano
188af2ee98 Correct location event body (#930)
- Now sending the correct body format as agreed with design. This won't be show in EX clients though.

Related to:
- https://github.com/vector-im/element-meta/issues/1682
2023-07-20 10:16:40 +00:00
Marco Romano
584a227920 maplibre-compose allow customisation of location dot style (#929)
- And style it according to our designs.

Related to:
- https://github.com/vector-im/element-meta/issues/1682
2023-07-20 12:09:40 +02:00
renovate[bot]
6d3b816bf5 Update dependency app.cash.molecule:molecule-runtime to v1 (#925)
* Update dependency app.cash.molecule:molecule-runtime to v1

* Replace `RecompositionClock` with `RecompositionMode`

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2023-07-20 07:36:19 +02:00
Marco Romano
025d8781a7 Refactor a custom alignment to its own modifier for readability. (#924) 2023-07-19 16:58:04 +02:00
Marco Romano
30060b5729 Don't crash when sharing a location with no maptiler apikey (#919)
Related to:
- https://github.com/vector-im/element-meta/issues/1682
2023-07-19 16:33:50 +02:00
Marco Romano
c135da2562 Location expanded view: show own location (#916)
If the location permission is granted:
- Shows the user's own location
- Shows a button to center the map on it

Part of:
- https://github.com/vector-im/element-meta/issues/1678
2023-07-19 13:26:06 +00:00
Marco Romano
fb85cc0be4 Fix insets for nav bar in send location view (#915)
Improvement of https://github.com/vector-im/element-x-android/pull/770

- https://github.com/vector-im/element-meta/issues/1682
2023-07-19 13:57:34 +02:00
Marco Romano
278f8ae4c6 Send My Location (#770)
- https://github.com/vector-im/element-meta/issues/1682
2023-07-19 09:58:13 +00:00
Chris Smith
b7bd08b210 Location sharing: don't hardcode API key
In an effort to make it easier for forks to (a) use their own
API keys (b) change map styles or maybe even providers, move
the MapTiler key out of the source code and pass it in via
env var or property.

Also refactor the utility classes slightly to keep all the URL
related functions together, to reduce the chance of collisions
when maintaining such forks.
2023-07-17 16:09:53 +01:00
Benoit Marty
16f30db20e Move TypographyAliases next to ColorAliases 2023-07-11 11:29:56 +02:00
Benoit Marty
529f6d681e Create alias for typography (more semantic name). aliasScreenTitle 2023-07-11 10:29:06 +02:00