googleads-mobile-flutter icon indicating copy to clipboard operation
googleads-mobile-flutter copied to clipboard

[Feature request] Able to customize border around native ads (color, radius)

Open naamapps opened this issue 2 years ago • 19 comments

Plugin Version

3.0.0

Steps to Reproduce

Just run a native ad on ios and see that it renders with a border around it.

Expected results: The ad renders without borders.

Actual results: The ad renders with borders. See image:

flutter_06 copy

naamapps avatar Jul 06 '23 13:07 naamapps

Hi @naamapps,

The borders you are noticing are working as intended. I have labeled this case as a feature request and escalated to the greater team.

malandr2 avatar Jul 06 '23 15:07 malandr2

Hey @malandr2, Thanks for your quick comment. Please explain why is this the intended behavior, it seems like a bug to me. The borders are really distracting from the main content of the app.

Also why did you close the issue if it is not resolved? Shouldn't it be open until it's resolved?

naamapps avatar Jul 06 '23 15:07 naamapps

Hey @naamapps, ticket is re-opened. Will be closed once resolved by engineering.

The border is part of the UI and it is black by default. @jjliu15 feature request would be to allow customization of the border color.

malandr2 avatar Jul 07 '23 15:07 malandr2

Got it. Looking forward to this new feature to control the border color. Also if it's possible, maybe add an option to control the border radius? Just suggesting a few customizations. Thanks

naamapps avatar Jul 07 '23 15:07 naamapps

I also see this issue on Android as well. Updating labels corresponding to this. Verified on plugin versions: google_mobile_ads: ^3.0.0

Demo Android
Flutter plugin - Android Android native example

huycozy avatar Jul 12 '23 09:07 huycozy

https://github.com/googleads/googleads-mobile-flutter/issues/842#issuecomment-1709401591

CHECK THIS

ravitaak avatar Sep 07 '23 04:09 ravitaak

@ravitaak per your comment, we cannot recommend modifying the plugin code itself. I've re-raised this issue with the engineering team for visibility's sake. Thanks.

malandr2 avatar Oct 02 '23 15:10 malandr2

Thanks for your response @malandr2, However every issue only seems for visibility's sake. Why is there no actual work being done to resolve those critical issues?

This package looks abandoned and forgotten. Please take this package seriously, and not like a side project.

naamapps avatar Oct 05 '23 11:10 naamapps

Hey @naamapps, this specific issue isn't as high of a priority fix for the team compared to the others. Rest assured work is being done to address the larger issues in the list as well as implementing new features (those do not have any associated GitHub tracker).

malandr2 avatar Oct 05 '23 14:10 malandr2

Commenting for issue visibility.

The current state of this feature bothers me a lot as it makes use cases for the native ads very limited. E.g. I want the ads to match the dark theme of my application. I can make the inside of the ad dark, but the white, eye-burning border stays there no matter what:

2023-10-11_19:14:30

bcyran avatar Oct 11 '23 17:10 bcyran

@bcyran, ACK. Thanks for your feedback.

malandr2 avatar Oct 12 '23 14:10 malandr2

@malandr2 When will it be updated? I am still waiting for the custom design features.

jhlee-danbi avatar Nov 21 '23 03:11 jhlee-danbi

Bump! Native ads have more potential for revenue growth than any other ad type, but it all depends on their ability to mesh well with the whole app's style. Introducing basic customization features shouldn't detract too much from other issues :(

fernandorascon avatar May 04 '24 06:05 fernandorascon

Hi there!,

Some news about it?

Thanks,

joshuamoreno1 avatar May 19 '24 23:05 joshuamoreno1

Hi,

Any new about this? It doesn't make sense to use this kind of ad if it's not fully customizable with the UI

Thanks

DanielMartini avatar Aug 11 '24 20:08 DanielMartini

I managed to set the borders transparent by adding these two lines in my android/app/src/main/res/values/styles.xml:

image

lancelotF avatar Aug 19 '24 04:08 lancelotF

For IOS Comment following line

ios/Classes/NativeTemplates/GoogleAdsMobileIosNativeTemplates/GADTTemplateView.m inside the package file

This helps me change the border and color.

- (void)applyStyles {
  // self.layer.borderColor =
  //     [GADTTemplateView colorFromHexString:@"E0E0E0"].CGColor;
  // self.layer.borderWidth = 1.0f;
  [self.mediaView sizeToFit];
  if ([self styleForKey:GADTNativeTemplateStyleKeyCornerRadius]) {
    float roundedCornerRadius =
        ((NSNumber *)[self styleForKey:GADTNativeTemplateStyleKeyCornerRadius])
            .floatValue;

    // Rounded corners
    self.iconView.layer.cornerRadius = roundedCornerRadius;
    self.iconView.clipsToBounds = YES;
    ((UIButton *)self.callToActionView).layer.cornerRadius =
        roundedCornerRadius;
    ((UIButton *)self.callToActionView).clipsToBounds = YES;
  }
...

}

happy coding!

ajith-ab avatar Oct 06 '24 12:10 ajith-ab