mirror of
https://github.com/immich-app/immich.git
synced 2024-12-29 15:11:58 +00:00
fix(mobile): Fix asset selector title bar text (#9273)
Fix title bar text
This commit is contained in:
parent
3790d8fcbc
commit
ae08abde24
2 changed files with 5 additions and 8 deletions
|
@ -411,6 +411,7 @@
|
||||||
"share_add_photos": "Add photos",
|
"share_add_photos": "Add photos",
|
||||||
"share_add_title": "Add a title",
|
"share_add_title": "Add a title",
|
||||||
"share_create_album": "Create album",
|
"share_create_album": "Create album",
|
||||||
|
"share_assets_selected": "{} selected",
|
||||||
"shared_album_activities_input_disable": "Comment is disabled",
|
"shared_album_activities_input_disable": "Comment is disabled",
|
||||||
"shared_album_activities_input_hint": "Say something",
|
"shared_album_activities_input_hint": "Say something",
|
||||||
"shared_album_activity_remove_content": "Do you want to delete this activity?",
|
"shared_album_activity_remove_content": "Do you want to delete this activity?",
|
||||||
|
|
|
@ -31,10 +31,6 @@ class AlbumAssetSelectionPage extends HookConsumerWidget {
|
||||||
final selected = useState<Set<Asset>>(existingAssets);
|
final selected = useState<Set<Asset>>(existingAssets);
|
||||||
final selectionEnabledHook = useState(true);
|
final selectionEnabledHook = useState(true);
|
||||||
|
|
||||||
String buildAssetCountText() {
|
|
||||||
return selected.value.length.toString();
|
|
||||||
}
|
|
||||||
|
|
||||||
Widget buildBody(RenderList renderList) {
|
Widget buildBody(RenderList renderList) {
|
||||||
return ImmichAssetGrid(
|
return ImmichAssetGrid(
|
||||||
renderList: renderList,
|
renderList: renderList,
|
||||||
|
@ -63,10 +59,10 @@ class AlbumAssetSelectionPage extends HookConsumerWidget {
|
||||||
'share_add_photos',
|
'share_add_photos',
|
||||||
style: TextStyle(fontSize: 18),
|
style: TextStyle(fontSize: 18),
|
||||||
).tr()
|
).tr()
|
||||||
: Text(
|
: const Text(
|
||||||
buildAssetCountText(),
|
'share_assets_selected',
|
||||||
style: const TextStyle(fontSize: 18),
|
style: TextStyle(fontSize: 18),
|
||||||
),
|
).tr(args: [selected.value.length.toString()]),
|
||||||
centerTitle: false,
|
centerTitle: false,
|
||||||
actions: [
|
actions: [
|
||||||
if (selected.value.isNotEmpty || canDeselect)
|
if (selected.value.isNotEmpty || canDeselect)
|
||||||
|
|
Loading…
Reference in a new issue