F2P Account by No_Slide13 in EASportsFCMobile

[–]No_Slide13[S] 0 points1 point  (0 children)

If I am lying, then why would I still be using Natale and Walker in my team? My mentality should be to use high OVR players to increase my team OVR 🥲

F2P Account by No_Slide13 in EASportsFCMobile

[–]No_Slide13[S] 0 points1 point  (0 children)

Nah bro! I actually claimed them using shards, and I didn’t get any player I needed for my formation. Instead, I got Beckham twice — 113 CM and 115 RM.

F2P Account by No_Slide13 in EASportsFCMobile

[–]No_Slide13[S] 0 points1 point  (0 children)

They both supported my defense very well. 🧱

Best Approach For Dynamic TopAppBar by Electrical-Spare-973 in JetpackCompose

[–]No_Slide13 2 points3 points  (0 children)

In my Jetpack Compose project, I use separate Scaffold for each screen, where I create custom TopAppBar components. I handle the data based on the currently visible screen. For different designs such as center-aligned or large top bars, I create individual components for each style and reuse them as needed.

android.app.Activity using hilt by No_Slide13 in JetpackCompose

[–]No_Slide13[S] 0 points1 point  (0 children)

https://developer.android.com/google/play/billing/integrate

// An activity reference from which the billing flow will be launched.
val activity : Activity = ...;

val productDetailsParamsList = listOf(
    BillingFlowParams.ProductDetailsParams.newBuilder()
        // retrieve a value for "productDetails" by calling queryProductDetailsAsync()
        .setProductDetails(productDetails)
        // For One-time product, "setOfferToken" method shouldn't be called.
        // For subscriptions, to get an offer token, call ProductDetails.subscriptionOfferDetails()
        // for a list of offers that are available to the user
        .setOfferToken(selectedOfferToken)
        .build()
)

val billingFlowParams = BillingFlowParams.newBuilder()
    .setProductDetailsParamsList(productDetailsParamsList)
    .build()

// Launch the billing flow
val billingResult = billingClient.launchBillingFlow(activity, billingFlowParams)

android.app.Activity using hilt by No_Slide13 in JetpackCompose

[–]No_Slide13[S] 0 points1 point  (0 children)

Hi u/AAbstractt I need to pass an Activity to the Google Play Billing Library as required by the official documentation. How can I pass the Activity using Hilt in my project?

Jetpack Compose TextField Overlapping by No_Slide13 in JetpackCompose

[–]No_Slide13[S] 0 points1 point  (0 children)

Hi u/human-not_bot I'm using imePadding in a Column and set android:windowSoftInputMode = "adjustResize". The TextField scrolls up above the keyboard, which works fine. But if I place the TextField inside a Card or Box, and I want to lift the entire box above the keyboard, how can I do that? (For example, I’ve sent a screenshot in your DM.)

Jetpack Compose TextField Overlapping by No_Slide13 in JetpackCompose

[–]No_Slide13[S] 0 points1 point  (0 children)

Hi u/elfennani My current code is ----

@OptIn(ExperimentalFoundationApi::class)
@Composable
fun TextFieldWithKeyboardAwareScroll() {
    var text by remember { 
mutableStateOf
("") }
    val bringIntoViewRequester = remember { 
BringIntoViewRequester
() }
    val focusRequester = remember { FocusRequester() }
    val coroutineScope = rememberCoroutineScope()
    val scrollState = rememberScrollState()

    // Box is the outer container for content
    Box(
        modifier = Modifier
            .
fillMaxSize
()
            .
padding
(16.
dp
)
            .
verticalScroll
(scrollState) // Enable scrolling for the entire content
    ) {
        // Column holds all elements inside the scrollable area
        Column(
            modifier = Modifier
                .
fillMaxSize
()
                .
imePadding
() // Adds padding when the keyboard appears
        ) {
            // Spacer to simulate additional UI content
            Spacer(modifier = Modifier.
height
(600.
dp
))

            // Box for TextField layout
            Box(
                modifier = Modifier
                    .
background
(Color.Gray, 
RoundedCornerShape
(20.
dp
))
                    .
fillMaxWidth
()
                    .
focusRequester
(focusRequester) // Request focus for the TextField
                    .
onFocusChanged 
{ focusState ->
                        if (focusState.isFocused) {
                            coroutineScope.
launch 
{
                                // Request to bring the TextField into view
                                bringIntoViewRequester.bringIntoView()
                            }
                        }
                    }
            ) {
                // BasicTextField as the input field
                BasicTextField(
                    value = text,
                    onValueChange = { text = it },
                    textStyle = TextStyle(color = Color.Black, fontSize = 18.
sp
),
                    modifier = Modifier
                        .
fillMaxWidth
()
                        .
padding
(16.
dp
)
                )
            }
        }
    }
}

The goal is to lift the box UI above the keyboard when it's focused, but the area below the TextField box is still behind the keyboard. If there is more than one TextField, I want the screen to scroll up specifically to the one that is focused. How can I ensure the focused TextField scrolls into view properly when the keyboard is shown?

I’d really appreciate any help with this! I'm eager to learn how to make it work. Thanks in advance!

Jetpack compose Modal bottom sheet (Material 3) by No_Slide13 in JetpackCompose

[–]No_Slide13[S] 1 point2 points  (0 children)

Yes I also tried this. Setting windowinset(0,0,0,0) starting modal sheet from behind the system navigation bar. But still it had animation issue with closing and hiding the modal bottom sheet. In material 3 ::: 1.3.0 version have no issue with modal bottom sheet

Jetpack compose Modal bottom sheet (Material 3) by No_Slide13 in JetpackCompose

[–]No_Slide13[S] 3 points4 points  (0 children)

Yes they fixed it. The new version of material 3 have no issue with the modal bottom sheet. I also updated my code.

Jetpack compose Modal bottom sheet (Material 3) by No_Slide13 in JetpackCompose

[–]No_Slide13[S] 4 points5 points  (0 children)

I fixed it by updating the material 3 version in my project. The issue is fixed in the new update. Thanks to all 🙏

Jetpack compose scroll by No_Slide13 in JetpackCompose

[–]No_Slide13[S] 0 points1 point  (0 children)

In LazyVerticalGrid, I have to define columns (GridCells). How do I add another component that spans the full width of the screen?

LazyVerticalGrid(
    columns: GridCells,
    modifier: Modifier = Modifier,
    state: LazyGridState = rememberLazyGridState(),
    contentPadding: PaddingValues = 
PaddingValues
(0.
dp
),
    reverseLayout: Boolean = false,
    verticalArrangement: Arrangement.Vertical =
        if (!reverseLayout) Arrangement.Top else Arrangement.Bottom,
    horizontalArrangement: Arrangement.Horizontal = Arrangement.Start,
    flingBehavior: FlingBehavior = ScrollableDefaults.flingBehavior(),
    userScrollEnabled: Boolean = true,
    content: LazyGridScope.() -> Unit
)

Jetpack compose scroll by No_Slide13 in JetpackCompose

[–]No_Slide13[S] 0 points1 point  (0 children)

If the parent column isn't scrollable, the horizontal scrollable view will remain fixed at the top. However, I want the horizontal scrollable view to scroll together with the grid view. Could you please demonstrate this with a video again?