Watch
1
0
Fork
You've already forked nexus
0
forked from Nexus/nexus

Compare commits

..
Author SHA1 Message Date
0a09a4ee0a
general cleanups and mounted guards 2026-10-24 12:02:23 -04:00
62e200f305
fix typing indicators not ellipsizing 2026-10-24 11:30:14 -04:00
dd01ad9d74
migrate Content classes to primary constructors
The Riverpod bug preventing us from doing this has been fixed.
2026-10-23 20:44:29 -04:00
853116ab2f
treewide cleanups 2026-10-23 20:26:37 -04:00
53d9c2b1e6
make enums fall back to unknown or null where possible
Futureproofing.
2026-10-23 20:12:54 -04:00
401b527714
ignore invalid account data 2026-10-23 20:05:23 -04:00
3754bc2feb
allow sending emoji/stickers from emote packs 2026-10-23 18:16:45 -04:00
868023a4a1
avoid un-needed reloads for diffs 2026-10-23 17:02:41 -04:00
9e6951818a
hide server ACL events from timeline by default, introduce setting to show them 2026-10-23 14:29:37 -04:00
0743c4cfc6
reorder appearance settings 2026-10-23 14:26:26 -04:00
6336764da0
add power level groups 2026-10-23 12:24:22 -04:00
3a39f1c5ac
more intuitive permissions in encrypted rooms 2026-10-23 12:12:20 -04:00
6e2d56ec75
add diffing for a lot of events 2026-10-23 12:01:38 -04:00
4e140e9fc7
add pinned event and server ACL diffing 2026-10-23 11:28:44 -04:00
e5dd53ed6c
tweak color picking algorithm for power levels, and introduce setting for per PL or per user colors 2026-10-23 10:23:49 -04:00
c0f4c053b0
Make displayname colors based off of power level
Fixes #128
2026-10-23 01:10:01 -04:00
ee36a9b1c8
Revert "use media_kit from main"
This reverts commit f5371382d7.
2026-10-23 00:36:31 -04:00
f5371382d7
use media_kit from main
Has some perf improvements, especially for Linux
2026-10-23 00:28:43 -04:00
2937c241e0
release v1.0.0 2026-10-22 22:10:33 -04:00
9dcddb3fbe
Revert "quick smoketest of macos"
This reverts commit 3014a9d029.
2026-10-22 22:08:59 -04:00
3014a9d029
quick smoketest of macos 2026-10-22 21:41:31 -04:00
4a9f151d92
don't watch entire room in room settings
performance improvement
2026-10-22 21:36:16 -04:00
d4ae5ebccf
drop unstable timezone key support 2026-10-22 21:32:19 -04:00
850bd33b18
fix maxMagnitude value for power levels
(oops thats a xor not an exponent operator)
2026-10-22 21:28:51 -04:00
8fbfcde9c5
add profile editor
Fixes #12
2026-10-22 21:20:13 -04:00
e0b5dc58d0
gate android branches of window_manager 2026-10-22 17:31:43 -04:00
ffbf2722f7
turn down minimum size
too large for linux mobile rn
2026-10-22 16:33:02 -04:00
3e1552f246
don't open media if context not mounted 2026-10-22 16:09:27 -04:00
44a1ec667e
switch to new window_manager from main 2026-10-22 16:06:28 -04:00
479279b68e
bring back padding for filters on member list 2026-10-22 15:33:29 -04:00
b0dd452926
add power level room settings 2026-10-22 15:29:02 -04:00
fcfe4eed1e
more correct fallback for unknown join conditions 2026-10-22 14:32:58 -04:00
b390dbbbe1
add room access settings 2026-10-22 14:22:54 -04:00
8e51852ae3
add general room settings 2026-10-22 11:29:19 -04:00
48c04d9b3e
make swipe from right open member list 2026-10-22 10:53:07 -04:00
7f30150e95
make theme's platform Android when Linux Mobile Mode is on
Allows for swiping drawers closed
2026-10-22 10:37:31 -04:00
c8e1aef74b
show mutual rooms in user popover
Fixes #97
2026-10-22 10:25:50 -04:00
5ee3449f02
bump gomuks 2026-10-22 09:56:52 -04:00
1715ee785e
make names in typing indicators clickable 2026-10-21 23:01:22 -04:00
e38307657d
Read receipt support
Fixes #93
2026-10-21 22:58:06 -04:00
e14ab3e708
use *Async methods from gomuks
Performance improvement due to not needing as many Isolates.
2026-10-21 22:57:26 -04:00
f5645db6ea
only reserve space for jump to bottom when it exists 2026-10-21 15:09:41 -04:00
0fcbc275cd
add typing indicators
Fixes #92
2026-10-21 15:07:02 -04:00
a54004736b
add event search
Fixes #77
2026-10-21 13:31:01 -04:00
427e06be3e
add knock support
Fixes #123
2026-10-21 12:32:02 -04:00
a1a15af30d
use dot shorthands for default immutable collections where possible 2026-10-20 18:23:41 -04:00
800fb5566d add a global toggle to hide membership events (#142)
fixes #141

Co-authored-by: seres <seres@seres.eu.org>
Reviewed-on: Nexus/nexus#142
2026-10-20 18:15:01 -04:00
80197aff00
add keyboard inset workaround to MainActivity
Should be reverted once https://github.com/flutter/flutter/issues/191156 is fixed
2026-10-20 15:17:34 -04:00
78162efbde
move MainActivity to correct directory 2026-10-20 15:15:42 -04:00
a2906746b9
release v1.0.0-alpha5 2026-10-19 21:18:33 -04:00
6659f21ceb
apply SafeArea on showAdaptiveSheet
This fixes actions being cut off when using button navigation.
2026-10-19 21:18:03 -04:00
a065b823bb
remove outdated bundled-emoji reference 2026-10-19 21:10:05 -04:00
765e96cce4
refactor and improve notification handling 2026-10-19 21:10:05 -04:00
9cf16db669
use webcrypto fork to fix macOS builds 2026-10-19 20:39:33 -04:00
2c8a4da2a8
Reapply "override webcrypto to a version with build hooks"
This reverts commit eca2b0b558.
2026-10-19 20:02:34 -04:00
cb426cd27e
add fallback emoji font list until flutter 3.50 releases 2026-10-19 19:39:09 -04:00
bfd259543d
don't bundle an emoji font
Might need reverts after testing.
2026-10-19 18:19:05 -04:00
9f0b80072d
pause sync when app is backgrounded 2026-10-19 17:40:57 -04:00
b6ee5aec64
use system emoji before bundled
Needs testing on:
- Android
- Windows
- MacOS
To make sure that it doesn't break stuff.
2026-10-19 10:38:30 -04:00
deac9ef24e
handle permission denials more gracefully 2026-10-18 16:36:36 -04:00
e24e99fd8e
slight improvements to windows and darwin notifs 2026-10-18 16:14:00 -04:00
4580110da0
update gomuks vendorHash 2026-10-18 16:04:56 -04:00
d1724932b2
clean up and improve notifications
Thanks to Gomuks' new handling, we have sender displayname and avatar, and can use android's conversation notifications.

On other platforms, we just append sender name to the body, bolded if possible.

This also improves the logic on when to send notifications, as we drop notifs where `response["notification"]` is null.

We also now correctly set if notifications should play a sound or not, based on `PushNotification.sound`.

`PushNotification.image` handling might come sometime in the future, but it seems hard on Android.
2026-10-18 16:01:37 -04:00
a6fe80fea2
split APKs per abi and only upload arm64 APK 2026-10-17 16:19:27 -04:00
9f45cbc1e7
add warning when user has cross signing but not secret storage 2026-10-17 16:12:10 -04:00
eca2b0b558
Revert "override webcrypto to a version with build hooks"
This reverts commit 4e6ba571fc.

Due to an upstream bug, this broke Linux aarch64 builds, as well as MacOS builds.
2026-10-17 11:53:23 -04:00
4e6ba571fc
override webcrypto to a version with build hooks 2026-10-17 11:37:51 -04:00
200e03f082
noheic always 2026-10-17 11:21:20 -04:00
8180338d99
use another avif library that works on aarch64-linux 2026-10-17 11:18:23 -04:00
72c5e7d819
add errorBuilder to reactions 2026-10-17 10:24:30 -04:00
254b7e134f
release v1.0.0-alpha4 2026-10-16 22:14:15 -04:00
ef25e765d4
handle events_decrypted 2026-10-16 22:12:15 -04:00
58a27fdd9e
tiny cleanup in avif decoding 2026-10-16 22:00:00 -04:00
6d42477041
add support for avif images
Fixes #138
2026-10-16 20:35:42 -04:00
2f17f5b6c6
add swipe to reply
Fixes #90
2026-10-16 18:08:42 -04:00
1380233f2e
release v1.0.0-alpha3 2026-10-16 17:20:36 -04:00
a3a3781252
open sidebar on homepage pop 2026-10-16 17:17:19 -04:00
81851bdc42
fix no room selected after leave / init 2026-10-16 17:13:25 -04:00
f19a51939c
small cleanups 2026-10-16 17:06:22 -04:00
0ad85f24d5
Add support for downloading media
Fixes #85
2026-10-16 17:05:26 -04:00
1c2ba2971b
release v1.0.0-alpha2 2026-10-16 11:23:14 -04:00
fb0af571ed
fixup controls on narrow videos 2026-10-16 11:14:07 -04:00
9cd43f4e3c
only start timer to end highlight after scroll complete 2026-10-16 11:08:24 -04:00
0fa0f57738
fix ctrl+v text paste not working 2026-10-16 11:02:23 -04:00
00f22d46b7
slight cleanups 2026-10-16 10:56:55 -04:00
23046f08a9
add support for initializing and resetting crypto identity
Fixes #137
2026-10-16 10:49:04 -04:00
784e5254e2
fixup credits header on readme 2026-10-15 23:41:40 -04:00
7193ac0dba
remove progress list and disclaimer for readme
Progress list has been replaced by issues, now there aren't too many unchecked boxes.
2026-10-15 23:40:33 -04:00
7ab4b5e59f
update screenshots 2026-10-15 23:28:08 -04:00
c23dc19c6e
update readme progress list
[skip ci]
2026-10-15 23:03:48 -04:00
0b79aac7af
update readme for release
[skip ci]
2026-10-15 23:01:47 -04:00
e4f290eaa6
release v1.0.0-alpha1 2026-10-15 22:57:36 -04:00
d309754c60
fix nix build 2026-10-15 22:57:36 -04:00
a5dedb0d38
add Not yet implemented warning to discover / directory page 2026-10-15 22:41:20 -04:00
659e76b8f8
add slight padding above browse space fab 2026-10-15 22:40:55 -04:00
ab3eda0beb
show topics and summaries for spaces 2026-10-15 22:39:37 -04:00
b71a7f0bd6
Show space hierarchies
Fixes #83
2026-10-15 22:34:27 -04:00
8d944831f5
treewide: small refactors 2026-10-15 20:10:44 -04:00
9117663c48
mass migrate to adaptive sheets 2026-10-15 20:06:37 -04:00
ba258c2fcd
invite-related fixups 2026-10-15 20:01:24 -04:00
485383e99c
fixup weird behavior when leaving spaces 2026-10-15 19:50:35 -04:00
ed84410039
add support for creating rooms
Fixes #81
2026-10-15 19:49:04 -04:00
df592b3f38
add better OAuth error
Fixes #88
2026-10-15 18:30:12 -04:00
d47c4ae15c
update gomuks vendorHash 2026-10-15 15:30:33 -04:00
d308ef98cb
small fixups
Fixes #67
2026-10-15 15:13:31 -04:00
f082a75d9c
run GomuksStart on an isolate 2026-10-15 14:25:45 -04:00
36f61a62d8
allow pasting attachments from keyboard
Closes #55
2026-10-15 13:56:10 -04:00
27137c488d
replace media_kit's video widget with a custom impl
Fixes #48

This helps Linux touchscreen devices like Linux phones, where the old widget didn't work correctly.
2026-10-15 10:53:30 -04:00
ce5c7b972b
make user sheets popovers on desktop 2026-10-15 10:25:20 -04:00
76d78596cd
show bottom sheets / dialogs / menus based on screen size
Fixes #76
2026-10-15 10:20:27 -04:00
ed2d08ed40
fixup showing an error when opening info dialogue on sync waiting 2026-10-15 10:02:43 -04:00
24e516e6dd
store related events for mentions 2026-10-15 00:44:08 -04:00
66a437094a
show badges totaled in more areas 2026-10-15 00:42:56 -04:00
d37ec2878b
add invite support
Closes #82
2026-10-15 00:35:38 -04:00
dbf30c3706
fix historical event jumps
Fixes #118
2026-10-14 23:52:16 -04:00
2d619bf1ad
properly order historical timelines
Fixes #117
2026-10-14 23:37:53 -04:00
07700c1eff
add syncing waiting / error / failed indicator 2026-10-14 23:21:31 -04:00
a5fef138dd
add support for altering room ordering
Fixes #115
2026-10-14 22:58:10 -04:00
7353955d4e
add more guidelines to DEVELOPMENT.md 2026-10-14 17:04:05 -04:00
012ecd9249
treewide sweepfixes 2026-10-14 17:01:39 -04:00
8fda43ccf8
Push sidebar if needed and scroll to notif when tapped
Fixes #116
2026-10-14 16:51:14 -04:00
3a33bf7bfe
Allow swapping UnifiedPush distributor
Fixes #120
2026-10-14 16:41:01 -04:00
9237a3dbed
use upstream nix2flatpak
All PRs have been merged.
2026-10-14 16:27:27 -04:00
30a5fa100c
gracefully catch errors when parsing membership state 2026-10-12 10:36:41 -04:00
f198888635
bump deps
fixes #119
2026-10-11 13:43:13 -04:00
be945031cd
bump nix2flatpak 2026-10-11 12:48:53 -04:00
263 changed files with 11833 additions and 3580 deletions

View file

@ -27,7 +27,7 @@ jobs:
KEYSTORE_CONTENT: ${{ secrets.KEYSTORE_CONTENT }} KEYSTORE_CONTENT: ${{ secrets.KEYSTORE_CONTENT }}
- name: Build app - name: Build app
run: nix develop --command bash -c "flutter pub get && dart scripts/generate.dart && flutter pub run build_runner build && flutter build apk --target-platform android-arm64 --dart-define=GIT_COMMIT=${{ github.sha }}" run: nix develop --command bash -c "flutter pub get && dart scripts/generate.dart && flutter pub run build_runner build && flutter build apk --target-platform android-arm64 --split-per-abi --dart-define=GIT_COMMIT=${{ github.sha }}"
env: env:
KEYSTORE_PATH: ../../keystore.jks KEYSTORE_PATH: ../../keystore.jks
KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }} KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}
@ -36,4 +36,4 @@ jobs:
uses: actions/upload-artifact@v6 uses: actions/upload-artifact@v6
with: with:
name: APK name: APK
path: build/app/outputs/flutter-apk/app-release.apk path: build/app/outputs/flutter-apk/app-arm64-v8a-release.apk

View file

@ -27,22 +27,26 @@ ref.read(MyController.provider.notifier).helperMethod()
We use an object oriented style for controllers, where `provider` is a static member on the controller class. E.g. We use an object oriented style for controllers, where `provider` is a static member on the controller class. E.g.
```dart ```dart
class MyController extends AsyncNotifier<DataThisControllerExposes> { class MyController(final SomeInputType input)
final SomeInputType input; extends AsyncNotifier<DataThisControllerExposes> {
MyController(this.input);
@override @override
Future<DataThisControllerExposes> build() async { Future<DataThisControllerExposes> build() async {
return input.foo; return input.foo;
} }
static final provider = static final provider =
AsyncNotifierProvider.family<MyController, DataThisControllerExposes, SomeInputType>( AsyncNotifierProvider.family<MyController, DataThisControllerExposes, SomeInputType>(
AuthorController.new, MyController.new,
); );
} }
``` ```
#### `watch` vs `read`
Only use `ref.watch` in a `build` method, where you want to rebuild when the value changes. Everywhere else, like callbacks, `useEffect`, and methods on a controller, use `ref.read`.
Use `.select` to narrow down what you depend on, e.g. `ref.watch(RoomsController.provider.select((rooms) => rooms[roomId]))`.
Providers which are not controllers, e.g. they expose no data, only methods, should instead live in `lib/helpers/`. For an example, see `lib/helpers/launch_helper.dart`. Other, non-provider helpers, like extensions or helper methods can also go in `lib/helpers/`. Providers which are not controllers, e.g. they expose no data, only methods, should instead live in `lib/helpers/`. For an example, see `lib/helpers/launch_helper.dart`. Other, non-provider helpers, like extensions or helper methods can also go in `lib/helpers/`.
### Don't use StatefulWidgets ([Flutter Hooks](https://pub.dev/packages/flutter_hooks)) ### Don't use StatefulWidgets ([Flutter Hooks](https://pub.dev/packages/flutter_hooks))
@ -61,6 +65,36 @@ When possible, use immutable collections instead of the mutable equivalent. For
When possible, we prefer not to create global variables or methods. You can usually replace a global variable with a Riverpod controller, and a global method with an extension method. When possible, we prefer not to create global variables or methods. You can usually replace a global variable with a Riverpod controller, and a global method with an extension method.
I'm also not a big fan of unneeded private methods or variables, but this is contextual.
### Modern Dart syntax
We try to use newer Dart language features where they make code shorter:
- Primary constructors for classes, including widgets, e.g. `class const MemberList(final String roomId, {super.key}) extends HookConsumerWidget`.
- Dot shorthands wherever the type can be inferred, e.g. `.new(...)`, `padding: .all(8)`, `relationType == .reply`.
- Patterns and switch expressions over null checks and casts, e.g. `if (event.content case MessageContent(:final body?))` rather than checking `is` then using `!`.
### Prefer `map` over inline `for` loops
When building a list (or set, or map) from another collection, use `.map`, `.expand` and friends rather than a `for` inside the collection literal:
```dart
// Prefer
children: rooms.map((room) => RoomTile(room)).toList(),
// Over
children: [for (final room in rooms) RoomTile(room)],
```
Regular `for` statements are fine for logic that doesn't just build a collection.
### Async values and errors
When rendering an `AsyncValue`, use the `betterWhen` extension, which shows our standard loading and error widgets, or a switch expression if you need more control (e.g. `AsyncData(:final value) || AsyncLoading(:final value?)` to keep showing old data while reloading).
For futures started from the UI that nothing awaits, like button presses, add `.onError(showError)` so failures are shown to the user instead of being lost.
## LLM/AI Assisted Contributions ## LLM/AI Assisted Contributions
LLM generated code is NOT allowed. All contributions should be written by humans. Using LLMs for interacting with others, e.g. for Comments, PRs, etc, is also not allowed. LLM generated code is NOT allowed. All contributions should be written by humans. Using LLMs for interacting with others, e.g. for Comments, PRs, etc, is also not allowed.

129
README.md
View file

@ -1,8 +1,5 @@
# Nexus Client # Nexus Client
> [!WARNING]
> Nexus Client is still in development, and doesn't support everything needed for daily use.
## Description ## Description
A simple and user-friendly Matrix client made with Flutter and a Gomuks backend. A simple and user-friendly Matrix client made with Flutter and a Gomuks backend.
@ -13,113 +10,13 @@ A simple and user-friendly Matrix client made with Flutter and a Gomuks backend.
| :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :------------------------------------------------------------------------------: | | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :------------------------------------------------------------------------------: |
| ![Screenshot of Nexus Client in dark mode, showing users talking, with a sidebar showing rooms and spaces, and another sidebar showing members](./assets/screenshotDark.png) | ![The same screenshot as above, but in light mode](./assets/screenshotLight.png) | | ![Screenshot of Nexus Client in dark mode, showing users talking, with a sidebar showing rooms and spaces, and another sidebar showing members](./assets/screenshotDark.png) | ![The same screenshot as above, but in light mode](./assets/screenshotLight.png) |
## Progress
- [x] Platform Support
- [x] Linux
- [x] Notifications through UnifiedPush
- [x] Windows
- [ ] Background notifications
- [x] Android
- [x] Notifications through UnifiedPush
- [x] Notifications through FCM
- [x] MacOS
- [x] Unsigned .ipa
- [ ] App Store
- [ ] Background notifications
- [x] iOS
- [x] Unsigned .ipa
- [ ] App Store
- [ ] Background notifications
- [ ] Web (may not be possible)
- [x] Login (via OAuth)
- [x] Rooms / Spaces
- [x] Displaying and choosing
- [x] Reading, showing unread
- [x] Mark as read button on rooms and spaces
- [ ] Searching
- [ ] Creating (Rooms, Spaces, and DMs)
- [x] Joining
- [x] Parse vias
- [x] Using a text/uri/link
- [x] Plain text
- [x] `matrix:` Uri
- [x] Matrix.to link
- [ ] From space
- [ ] From directory
- [x] Leaving
- [x] Subspaces
- [x] Messages
- [x] Encryption
- [x] Restoring crypto identity from a recovery passphrase/key
- [x] Sending
- [x] Plain text
- [x] HTML/Markdown
- [x] Replies
- [x] Choose ping on/off
- [x] Per message profiles
- [x] Attachments
- [ ] Commands with [MSC4391](https://github.com/matrix-org/matrix-spec-proposals/pull/4391)
- [x] Tags
- [x] Users
- [x] Rooms
- [x] Emojis
- [ ] Custom emojis/stickers
- [ ] GIFs using Gomuks' GIF proxies
- [x] Receiving
- [x] Plain text
- [x] Per message profiles
- [x] HTML
- [x] URL Previews
- [x] Replies
- [x] Viewing
- [x] Jump to original message
- [x] Edits
- [x] Attachments
- [x] Unencrypted
- [x] Encrypted
- [x] Blurhashing
- [ ] Downloading attachments
- [x] Opening attachments in their own view
- [ ] Polls
- [x] Mentions
- [x] Users
- [x] Clickable
- [x] Rooms
- [x] Clickable
- [x] Matrix URIs
- [x] Matrix.to links
- [x] Events
- [x] Custom emojis/stickers
- [x] History loading
- [x] Editing
- [x] Deleting
- [x] Reactions
- [x] Pins
- [x] Displaying
- [x] Pinning/Unpinning
- [ ] Threads
- [x] Profile popouts
- [x] Working actions
- [x] Copy link to:
- [x] Room
- [x] Space
- [x] Message
- [ ] Reporting
- [x] Events
- [ ] Rooms
- [x] Member list
- [x] Sort by power level
- [ ] Colors based off of power level
- [x] Notifications using UnifiedPush ([#35](https://git.federated.nexus/Nexus/nexus/issues/35))
- [x] Notifications page
- [ ] Group calls using [MSC4195](https://github.com/matrix-org/matrix-spec-proposals/pull/4195)
- [ ] Invites
- [x] Settings
## Try it out ## Try it out
If you want to try out Nexus, grab one of the following artifacts from CI: If you want to try out Nexus, download the [latest release](https://git.federated.nexus/Nexus/nexus/releases/latest).
### Nightly Builds
For the newest changes, grab one of the following nightly artifacts, built by CI from the latest commit on `main`.
- [Android APK](https://nightly.link/Henry-Hiles/nexus/workflows/android/main/APK.zip) - [Android APK](https://nightly.link/Henry-Hiles/nexus/workflows/android/main/APK.zip)
- [Unsigned iOS IPA](https://nightly.link/Henry-Hiles/nexus/workflows/ios/main/Nexus.ipa.zip) - [Unsigned iOS IPA](https://nightly.link/Henry-Hiles/nexus/workflows/ios/main/Nexus.ipa.zip)
@ -128,7 +25,7 @@ If you want to try out Nexus, grab one of the following artifacts from CI:
Or, use one of the below methods: Or, use one of the below methods:
### Flatpak ### Nightly Flatpak Repo
Make sure Flatpak is set up on your system, then run: Make sure Flatpak is set up on your system, then run:
@ -149,6 +46,12 @@ nexus = {
}; };
``` ```
This tracks the latest commit on `main`. To stay on a release instead, pin the input to its tag:
```nix
url = "git+https://git.federated.nexus/Nexus/nexus?ref=refs/tags/v1.0.0";
```
Then import the module and enable it in your NixOS configuration: Then import the module and enable it in your NixOS configuration:
```nix ```nix
@ -232,12 +135,6 @@ dart scripts/generate.dart
> export CPATH="$(clang -v 2>&1 | grep "Selected GCC installation" | rev | cut -d' ' -f1 | rev)/include" > export CPATH="$(clang -v 2>&1 | grep "Selected GCC installation" | rev | cut -d' ' -f1 | rev)/include"
> ``` > ```
Build webcrypto:
```sh
flutter pub run webcrypto:setup
```
Build generated files, and watch for new changes: Build generated files, and watch for new changes:
```sh ```sh
@ -256,7 +153,7 @@ Development instructions can be found in [DEVELOPMENT.md](./DEVELOPMENT.md).
Join the [Nexus Client Matrix room](https://matrix.to/#/#nexus:federated.nexus) for questions or help with developing or using Nexus Client. Join the [Nexus Client Matrix room](https://matrix.to/#/#nexus:federated.nexus) for questions or help with developing or using Nexus Client.
# Credits ## Credits
Thank you Hylke Bons (https://planetpeanut.studio) for making the amazing icon for Nexus! Thank you Hylke Bons (https://planetpeanut.studio) for making the amazing icon for Nexus!
Thank you Tulir Asokan for making [Gomuks](https://github.com/gomuks/gomuks), and helping us integrate it into Nexus! Thank you Tulir Asokan for making [Gomuks](https://github.com/gomuks/gomuks), and helping us integrate it into Nexus!

View file

@ -1,22 +0,0 @@
{
"name": "Nexus",
"identifier": "nexus.federated.nexus.source",
"subtitle": "Nexus for iOS",
"description": "Nexus iOS builds for AltStore and SideStore.",
"iconURL": "https://git.federated.nexus/Nexus/nexus/raw/branch/main/assets/icon.png",
"website": "https://git.federated.nexus/Nexus/nexus",
"apps": [
{
"name": "Nexus",
"bundleIdentifier": "nexus.federated.nexus",
"developerName": "Nexus",
"subtitle": "A Matrix client",
"localizedDescription": "Nexus for iOS. Unsigned builds, resigned at install by AltStore/SideStore.",
"iconURL": "https://git.federated.nexus/Nexus/nexus/raw/branch/main/assets/icon.png",
"category": "social",
"screenshots": [],
"versions": []
}
],
"news": []
}

View file

@ -51,6 +51,16 @@
<meta-data <meta-data
android:name="flutterEmbedding" android:name="flutterEmbedding"
android:value="2" /> android:value="2" />
<!-- Needed by pasteboard, for pasting files from the clipboard -->
<provider
android:name="androidx.core.content.FileProvider"
android:authorities="${applicationId}.provider"
android:exported="false"
android:grantUriPermissions="true">
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="@xml/provider_paths" />
</provider>
</application> </application>
<!-- Required to query activities that can process text, see: <!-- Required to query activities that can process text, see:
https://developer.android.com/training/package-visibility and https://developer.android.com/training/package-visibility and

View file

@ -1,5 +0,0 @@
package nexus.federated.nexus
import io.flutter.embedding.android.FlutterActivity
class MainActivity: FlutterActivity()

View file

@ -0,0 +1,40 @@
package nexus.federated.nexus
import android.os.Build
import android.os.Bundle
import android.view.View
import android.view.WindowInsets
import android.view.WindowInsetsAnimation
import io.flutter.embedding.android.FlutterActivity
// TODO: Revert this commit once https://github.com/flutter/flutter/issues/191156 is fixed
class MainActivity: FlutterActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.R) return
window.decorView.setWindowInsetsAnimationCallback(
object : WindowInsetsAnimation.Callback(DISPATCH_MODE_CONTINUE_ON_SUBTREE) {
override fun onProgress(
insets: WindowInsets,
runningAnimations: List<WindowInsetsAnimation>,
) = insets
override fun onEnd(animation: WindowInsetsAnimation) {
if ((animation.typeMask and WindowInsets.Type.ime()) != 0) reapplyInsets()
}
},
)
}
override fun onWindowFocusChanged(hasFocus: Boolean) {
super.onWindowFocusChanged(hasFocus)
if (hasFocus && Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) reapplyInsets()
}
// Posted so it runs after Flutter has applied any insets it deferred.
private fun reapplyInsets() {
val view = findViewById<View>(FLUTTER_VIEW_ID) ?: return
view.post { view.rootWindowInsets?.let(view::onApplyWindowInsets) }
}
}

View file

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<paths xmlns:android="http://schemas.android.com/apk/res/android">
<external-path
name="external_files"
path="." />
</paths>

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 615 KiB

After

Width:  |  Height:  |  Size: 246 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 616 KiB

After

Width:  |  Height:  |  Size: 251 KiB

Before After
Before After

0
assets/twim/.gitkeep Normal file
View file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

11
flake.lock generated
View file

@ -42,16 +42,15 @@
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
}, },
"locked": { "locked": {
"lastModified": 1790870263, "lastModified": 1791751882,
"narHash": "sha256-ZBblCzxsUBBCZJRJR0knnaOt2+Xl5JGfI+YkGPf2SI4=", "narHash": "sha256-DWcMlQFQMEqQGAHU6rAbl4uKWmlJMR1HZG0BvH0H2fk=",
"owner": "Henry-Hiles", "owner": "neobrain",
"repo": "nix2flatpak", "repo": "nix2flatpak",
"rev": "2ef0e3cde2bdce0870f79a7568a72c2681ad20b5", "rev": "7731e8b3fca73879f8217de5a919c0a5d17303de",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "Henry-Hiles", "owner": "neobrain",
"ref": "quad/nexus",
"repo": "nix2flatpak", "repo": "nix2flatpak",
"type": "github" "type": "github"
} }

View file

@ -5,7 +5,7 @@
self.submodules = true; self.submodules = true;
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
flake-parts.url = "github:hercules-ci/flake-parts"; flake-parts.url = "github:hercules-ci/flake-parts";
nix2flatpak.url = "github:Henry-Hiles/nix2flatpak/quad/nexus"; nix2flatpak.url = "github:neobrain/nix2flatpak";
}; };
outputs = outputs =

2
gomuks

@ -1 +1 @@
Subproject commit 38e5033c3a91db0cbea6cbd9f0feef9ff6441038 Subproject commit 53cae0e0334aef5ac376ea84f19ba1cff8a92310

View file

@ -122,7 +122,7 @@ Future<void> main(List<String> args) => build(args, (input, output) async {
"sqlite_fts5", "sqlite_fts5",
"goolm", "goolm",
// goheif/dav1d is not supported on Android or iOS, would need to be fixed upstream // goheif/dav1d is not supported on Android or iOS, would need to be fixed upstream
if (targetOS == OS.android || targetOS == OS.iOS) "noheic", "noheic",
].join(","); ].join(",");
final archiveFile = targetOS == OS.iOS final archiveFile = targetOS == OS.iOS

View file

@ -1,6 +1,7 @@
import "dart:convert"; import "dart:convert";
import "package:fast_immutable_collections/fast_immutable_collections.dart"; import "package:fast_immutable_collections/fast_immutable_collections.dart";
import "package:flutter/foundation.dart";
import "package:flutter_riverpod/flutter_riverpod.dart"; import "package:flutter_riverpod/flutter_riverpod.dart";
import "package:nexus/models/account_data.dart"; import "package:nexus/models/account_data.dart";
@ -9,11 +10,16 @@ class AccountDataController extends Notifier<AccountData> {
AccountData build() => .new(); AccountData build() => .new();
void update(IMap<String, IMap<String, dynamic>> newAccountData) => void update(IMap<String, IMap<String, dynamic>> newAccountData) =>
state = .fromJson({ state = newAccountData.entries.fold(state, (data, entry) {
...json.decode(json.encode(state.toJson())), try {
...newAccountData return .fromJson({
.map((key, value) => MapEntry(key, value["content"])) ...json.decode(json.encode(data.toJson())),
.unlock, entry.key: entry.value["content"],
});
} catch (error) {
debugPrint("Ignoring invalid ${entry.key} account data: $error");
return data;
}
}); });
static final provider = NotifierProvider<AccountDataController, AccountData>( static final provider = NotifierProvider<AccountDataController, AccountData>(

View file

@ -0,0 +1,25 @@
import "package:fast_immutable_collections/fast_immutable_collections.dart";
import "package:flutter_riverpod/flutter_riverpod.dart";
import "package:material_emoji_picker/material_emoji_picker.dart";
import "package:nexus/controllers/image_packs.dart";
import "package:nexus/helpers/extensions/image_pack_emoji.dart";
class AllEmojiController(final String roomId)
extends AsyncNotifier<IList<EmojiCategory>> {
@override
Future<IList<EmojiCategory>> build() async {
final packs = await ref.watch(ImagePacksController.provider(roomId).future);
final unicode = await ref.watch(EmojiController.provider.future);
return packs
.map((pack) => pack.emojiCategory)
.nonNulls
.toIList()
.addAll(unicode);
}
static final provider = AsyncNotifierProvider.autoDispose
.family<AllEmojiController, IList<EmojiCategory>, String>(
AllEmojiController.new,
);
}

View file

@ -0,0 +1,18 @@
import "package:flutter/widgets.dart";
import "package:flutter_riverpod/flutter_riverpod.dart";
class AppPausedController extends Notifier<bool> {
@override
bool build() {
final listener = AppLifecycleListener(
onPause: () => state = true,
onResume: () => state = false,
);
ref.onDispose(listener.dispose);
return WidgetsBinding.instance.lifecycleState == .paused;
}
static final provider = NotifierProvider<AppPausedController, bool>(
AppPausedController.new,
);
}

Some files were not shown because too many files have changed in this diff Show more