Compare commits
3 Commits
ecc100ac45
...
baed28bef7
Author | SHA1 | Date | |
---|---|---|---|
baed28bef7 | |||
7a6eecf628 | |||
6a63bc235b |
@@ -47,6 +47,7 @@ class NotificationService: UNNotificationServiceExtension {
|
||||
private func processNotification(request: UNNotificationRequest, content: UNMutableNotificationContent) throws {
|
||||
switch content.userInfo["type"] as? String {
|
||||
case "messages.new":
|
||||
content.categoryIdentifier = "REPLYABLE_MESSAGE"
|
||||
try handleMessagingNotification(request: request, content: content)
|
||||
default:
|
||||
try handleDefaultNotification(content: content)
|
||||
@@ -60,8 +61,6 @@ class NotificationService: UNNotificationServiceExtension {
|
||||
|
||||
let pfpIdentifier = meta["pfp"] as? String
|
||||
|
||||
content.categoryIdentifier = "REPLYABLE_MESSAGE"
|
||||
|
||||
let metaCopy = meta as? [String: Any] ?? [:]
|
||||
let pfpUrl = pfpIdentifier != nil ? getAttachmentUrl(for: pfpIdentifier!) : nil
|
||||
|
||||
|
@@ -72,7 +72,7 @@ class MarketplaceWebFeedsScreen extends HookConsumerWidget {
|
||||
searchController.clear();
|
||||
}
|
||||
return null;
|
||||
}, [query.value]);
|
||||
}, [query]);
|
||||
|
||||
// Clean up timer on dispose
|
||||
useEffect(() {
|
||||
|
@@ -77,7 +77,7 @@ class MarketplaceStickersScreen extends HookConsumerWidget {
|
||||
searchController.clear();
|
||||
}
|
||||
return null;
|
||||
}, [query.value]);
|
||||
}, [query]);
|
||||
|
||||
// Clean up timer on dispose
|
||||
useEffect(() {
|
||||
|
@@ -48,7 +48,7 @@ class PostFeaturedList extends HookConsumerWidget {
|
||||
'PostFeaturedList: isCollapsed changed to ${isCollapsed.value}',
|
||||
);
|
||||
return null;
|
||||
}, [isCollapsed.value]);
|
||||
}, [isCollapsed]);
|
||||
|
||||
useEffect(() {
|
||||
if (featuredPostsAsync.hasValue && featuredPostsAsync.value!.isNotEmpty) {
|
||||
@@ -93,7 +93,7 @@ class PostFeaturedList extends HookConsumerWidget {
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}, [featuredPostsAsync.value]);
|
||||
}, [featuredPostsAsync]);
|
||||
|
||||
return ClipRRect(
|
||||
borderRadius: const BorderRadius.all(Radius.circular(8)),
|
||||
|
@@ -36,46 +36,50 @@ class PostShuffleScreen extends HookConsumerWidget {
|
||||
bottom:
|
||||
kBottomControlHeight + MediaQuery.of(context).padding.bottom,
|
||||
),
|
||||
child:
|
||||
(postListState.value?.items.length ?? 0) > 0
|
||||
? CardSwiper(
|
||||
controller: cardSwiperController,
|
||||
cardsCount: postListState.value!.items.length,
|
||||
isLoop: false,
|
||||
cardBuilder: (
|
||||
context,
|
||||
index,
|
||||
horizontalOffsetPercentage,
|
||||
verticalOffsetPercentage,
|
||||
) {
|
||||
return Center(
|
||||
child: ConstrainedBox(
|
||||
constraints: BoxConstraints(maxWidth: 540),
|
||||
child: SingleChildScrollView(
|
||||
child: Card(
|
||||
margin: EdgeInsets.zero,
|
||||
child: ClipRRect(
|
||||
borderRadius: const BorderRadius.all(
|
||||
Radius.circular(8),
|
||||
),
|
||||
child: PostActionableItem(
|
||||
item: postListState.value!.items[index],
|
||||
),
|
||||
child: Builder(
|
||||
key: ValueKey(postListState.value?.items.length ?? 0),
|
||||
builder: (context) {
|
||||
if ((postListState.value?.items.length ?? 0) > 0) {
|
||||
return CardSwiper(
|
||||
controller: cardSwiperController,
|
||||
cardsCount: postListState.value!.items.length,
|
||||
isLoop: false,
|
||||
cardBuilder: (
|
||||
context,
|
||||
index,
|
||||
horizontalOffsetPercentage,
|
||||
verticalOffsetPercentage,
|
||||
) {
|
||||
return Center(
|
||||
child: ConstrainedBox(
|
||||
constraints: BoxConstraints(maxWidth: 540),
|
||||
child: SingleChildScrollView(
|
||||
child: Card(
|
||||
margin: EdgeInsets.zero,
|
||||
child: ClipRRect(
|
||||
borderRadius: const BorderRadius.all(
|
||||
Radius.circular(8),
|
||||
),
|
||||
child: PostActionableItem(
|
||||
item: postListState.value!.items[index],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
onEnd: () {
|
||||
if (postListState.value?.hasMore ?? true) {
|
||||
postListNotifier.fetch(
|
||||
cursor: postListState.value?.nextCursor,
|
||||
);
|
||||
}
|
||||
},
|
||||
)
|
||||
: Center(child: CircularProgressIndicator()),
|
||||
),
|
||||
);
|
||||
},
|
||||
onEnd: () async {
|
||||
if (postListState.value?.hasMore ?? true) {
|
||||
postListNotifier.forceRefresh();
|
||||
}
|
||||
},
|
||||
);
|
||||
} else {
|
||||
return Center(child: CircularProgressIndicator());
|
||||
}
|
||||
},
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
left: 0,
|
||||
|
Reference in New Issue
Block a user