Skip to content

Commit

Permalink
Implement primal legend avatar customization across the app (#239)
Browse files Browse the repository at this point in the history
---------
Co-authored-by: Aleksandar Ilic <[email protected]>
  • Loading branch information
markocic authored Dec 3, 2024
1 parent 3548e0c commit 5ca80b6
Show file tree
Hide file tree
Showing 98 changed files with 2,339 additions and 363 deletions.
5 changes: 2 additions & 3 deletions app/detekt-baseline.xml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@
<ID>LongMethod:NoteDropdownMenu.kt$@Composable fun NoteDropdownMenuIcon( modifier: Modifier, noteId: String, noteContent: String, noteRawData: String, authorId: String, isBookmarked: Boolean, enabled: Boolean = true, onBookmarkClick: (() -&gt; Unit)? = null, onMuteUserClick: (() -&gt; Unit)? = null, onReportContentClick: (() -&gt; Unit)? = null, )</ID>
<ID>LongMethod:NoteEditorScreen.kt$@OptIn(ExperimentalMaterial3Api::class) @Composable private fun NoteEditorBox( state: NoteEditorContract.UiState, eventPublisher: (UiEvent) -&gt; Unit, modifier: Modifier = Modifier, contentPadding: PaddingValues, )</ID>
<ID>LongMethod:NoteFeedLazyColumn.kt$@ExperimentalMaterial3Api @ExperimentalFoundationApi @Composable fun NoteFeedLazyColumn( modifier: Modifier = Modifier, pagingItems: LazyPagingItems&lt;FeedPostUi&gt;, listState: LazyListState, showPaywall: Boolean, noteCallbacks: NoteCallbacks, onGoToWallet: () -&gt; Unit, showTopZaps: Boolean = false, shouldShowLoadingState: Boolean = true, shouldShowNoContentState: Boolean = true, showReplyTo: Boolean = true, noContentVerticalArrangement: Arrangement.Vertical = Arrangement.Center, noContentPaddingValues: PaddingValues = PaddingValues(all = 0.dp), noContentText: String = stringResource(id = R.string.feed_no_content), contentPadding: PaddingValues = PaddingValues(all = 0.dp), header: @Composable (LazyItemScope.() -&gt; Unit)? = null, stickyHeader: @Composable (LazyItemScope.() -&gt; Unit)? = null, onUiError: ((UiError) -&gt; Unit)? = null, )</ID>
<ID>LongMethod:NoteHeader.kt$@Composable fun FeedNoteHeader( modifier: Modifier = Modifier, authorDisplayName: String, singleLine: Boolean = false, postTimestamp: Instant? = null, authorAvatarSize: Dp = 42.dp, authorAvatarVisible: Boolean = true, authorAvatarCdnImage: CdnImage? = null, authorInternetIdentifier: String? = null, authorLegendAvatarGlow: Boolean = false, authorLegendCustomBadge: Boolean = false, authorLegendaryStyle: LegendaryStyle? = null, replyToAuthor: String? = null, label: String? = authorInternetIdentifier, labelStyle: TextStyle? = null, onAuthorAvatarClick: (() -&gt; Unit)? = null, )</ID>
<ID>LongMethod:NoteVideoLinkPreview.kt$@Composable fun NoteVideoLinkPreview( url: String, title: String?, thumbnailUrl: String?, thumbnailImageSize: DpSize, type: NoteAttachmentType, onClick: (() -&gt; Unit)? = null, )</ID>
<ID>LongMethod:NotificationListItem.kt$@Composable private fun NotificationType.toSuffixText(usersZappedCount: Int = 0, totalSatsZapped: String? = null): String</ID>
<ID>LongMethod:NotificationsScreen.kt$@ExperimentalMaterial3Api @Composable private fun NotificationsList( state: NotificationsContract.UiState, noteState: NoteContract.UiState, listState: LazyListState, seenPagingItems: LazyPagingItems&lt;NotificationUi&gt;, paddingValues: PaddingValues, noteCallbacks: NoteCallbacks, onGoToWallet: () -&gt; Unit, onPostLikeClick: (FeedPostUi) -&gt; Unit, onRepostClick: (FeedPostUi) -&gt; Unit, onZapClick: (FeedPostUi, ULong?, String?) -&gt; Unit, onPostQuoteClick: (FeedPostUi) -&gt; Unit, onBookmarkClick: (FeedPostUi) -&gt; Unit, )</ID>
Expand All @@ -76,11 +75,11 @@
<ID>LongMethod:PremiumOrderHistoryScreen.kt$@OptIn(ExperimentalMaterial3Api::class, ExperimentalFoundationApi::class) @Composable private fun PremiumOrderHistoryScreen( state: PremiumOrderHistoryContract.UiState, eventPublisher: (PremiumOrderHistoryContract.UiEvent) -&gt; Unit, onExtendSubscription: (primalName: String) -&gt; Unit, onClose: () -&gt; Unit, )</ID>
<ID>LongMethod:PremiumPurchaseStage.kt$@ExperimentalMaterial3Api @Composable fun PremiumPurchaseStage( state: PremiumBuyingContract.UiState, onBack: () -&gt; Unit, onLearnMoreClick: () -&gt; Unit, eventPublisher: (PremiumBuyingContract.UiEvent) -&gt; Unit, )</ID>
<ID>LongMethod:PrimalAppNavigation.kt$@OptIn(ExperimentalSharedTransitionApi::class) @Composable fun SharedTransitionScope.PrimalAppNavigation()</ID>
<ID>LongMethod:PrimalDrawer.kt$@Composable private fun DrawerHeader( userAccount: UserAccount?, customBadge: Boolean, avatarGlow: Boolean, legendaryStyle: LegendaryStyle?, onQrCodeClick: () -&gt; Unit, )</ID>
<ID>LongMethod:PrimalDrawer.kt$@Composable private fun DrawerHeader( userAccount: UserAccount?, legendaryCustomization: LegendaryCustomization?, onQrCodeClick: () -&gt; Unit, )</ID>
<ID>LongMethod:PrimalDrawerScaffold.kt$@OptIn(ExperimentalMaterial3Api::class) @Composable fun PrimalDrawerScaffold( modifier: Modifier = Modifier, drawerState: DrawerState, activeDestination: PrimalTopLevelDestination, onPrimaryDestinationChanged: (PrimalTopLevelDestination) -&gt; Unit, onDrawerDestinationClick: (DrawerScreenDestination) -&gt; Unit, onDrawerQrCodeClick: () -&gt; Unit, badges: Badges = Badges(), onActiveDestinationClick: () -&gt; Unit = {}, topAppBarState: TopAppBarState = remember { TopAppBarState( initialHeightOffsetLimit = -Float.MAX_VALUE, initialHeightOffset = 0f, initialContentOffset = 0f, ) }, topAppBar: @Composable (TopAppBarScrollBehavior?) -&gt; Unit = {}, content: @Composable (PaddingValues) -&gt; Unit = {}, floatingNewDataHost: @Composable () -&gt; Unit = {}, floatingActionButton: @Composable () -&gt; Unit = {}, snackbarHost: @Composable () -&gt; Unit = {}, focusModeEnabled: Boolean = true, )</ID>
<ID>LongMethod:PrimalNavigationBar.kt$@Composable fun PrimalNavigationBarLightningBolt( modifier: Modifier = Modifier, activeDestination: PrimalTopLevelDestination, onTopLevelDestinationChanged: (PrimalTopLevelDestination) -&gt; Unit, onActiveDestinationClick: (() -&gt; Unit)? = null, badges: Badges = Badges(), )</ID>
<ID>LongMethod:PrimalOutlinedTextField.kt$@Composable fun PrimalOutlinedTextField( header: String?, value: String, onValueChange: (String) -&gt; Unit, forceFocus: Boolean = false, isRequired: Boolean = false, prefix: String? = null, isMultiline: Boolean = false, fontSize: TextUnit = 16.sp, textAlign: TextAlign = TextAlign.Start, isError: Boolean = false, )</ID>
<ID>LongMethod:PrimalTopAppBar.kt$@OptIn(ExperimentalFoundationApi::class) @ExperimentalMaterial3Api @Composable fun PrimalTopAppBar( modifier: Modifier = Modifier, title: String = "", subtitle: String? = null, titleTrailingIcon: ImageVector? = null, textColor: Color = LocalContentColor.current, navigationIcon: ImageVector? = null, navigationIconTintColor: Color = LocalContentColor.current, navigationIconContentDescription: String? = null, onNavigationIconClick: (() -&gt; Unit)? = null, autoCloseKeyboardOnNavigationIconClick: Boolean = true, avatarCdnImage: CdnImage? = null, avatarLegendaryStyle: LegendaryStyle? = null, actions: (@Composable RowScope.() -&gt; Unit)? = null, showDivider: Boolean = true, scrollBehavior: TopAppBarScrollBehavior? = null, onTitleClick: (() -&gt; Unit)? = null, onTitleLongClick: (() -&gt; Unit)? = null, colors: TopAppBarColors = TopAppBarDefaults.centerAlignedTopAppBarColors( containerColor = AppTheme.colorScheme.surface, scrolledContainerColor = AppTheme.colorScheme.surface, ), footer: @Composable () -&gt; Unit = {}, )</ID>
<ID>LongMethod:PrimalTopAppBar.kt$@OptIn(ExperimentalFoundationApi::class) @ExperimentalMaterial3Api @Composable fun PrimalTopAppBar( modifier: Modifier = Modifier, title: String = "", subtitle: String? = null, titleTrailingIcon: ImageVector? = null, textColor: Color = LocalContentColor.current, navigationIcon: ImageVector? = null, navigationIconTintColor: Color = LocalContentColor.current, navigationIconContentDescription: String? = null, onNavigationIconClick: (() -&gt; Unit)? = null, autoCloseKeyboardOnNavigationIconClick: Boolean = true, avatarCdnImage: CdnImage? = null, legendaryCustomization: LegendaryCustomization? = null, actions: (@Composable RowScope.() -&gt; Unit)? = null, showDivider: Boolean = true, scrollBehavior: TopAppBarScrollBehavior? = null, onTitleClick: (() -&gt; Unit)? = null, onTitleLongClick: (() -&gt; Unit)? = null, colors: TopAppBarColors = TopAppBarDefaults.centerAlignedTopAppBarColors( containerColor = AppTheme.colorScheme.surface, scrolledContainerColor = AppTheme.colorScheme.surface, ), footer: @Composable () -&gt; Unit = {}, )</ID>
<ID>LongMethod:ReactionsScreen.kt$@OptIn(ExperimentalMaterial3Api::class) @Composable private fun ReactionsScreen( state: ReactionsContract.UiState, onClose: () -&gt; Unit, onProfileClick: (profileId: String) -&gt; Unit, )</ID>
<ID>LongMethod:ReadsScreen.kt$@OptIn(ExperimentalMaterial3Api::class) @Composable private fun ReadsScreen( state: ReadsScreenContract.UiState, onTopLevelDestinationChanged: (PrimalTopLevelDestination) -&gt; Unit, onDrawerScreenClick: (DrawerScreenDestination) -&gt; Unit, onDrawerQrCodeClick: () -&gt; Unit, onSearchClick: () -&gt; Unit, onArticleClick: (naddr: String) -&gt; Unit, onGetPremiumClick: () -&gt; Unit, eventPublisher: (ReadsScreenContract.UiEvent) -&gt; Unit, )</ID>
<ID>LongMethod:ReceivePaymentScreen.kt$@Composable private fun ReceivePaymentViewer( paddingValues: PaddingValues, state: UiState, onBuyPremium: () -&gt; Unit, onCopyClick: () -&gt; Unit, onEditClick: () -&gt; Unit, )</ID>
Expand Down
Loading

0 comments on commit 5ca80b6

Please sign in to comment.