SolvedNativeScript [iOS] remove ActionBar Border (feature-request)

provided example below

actionbarborder.zip

Did you verify this is a real problem by searching [Stack Overflow]

Yes

Tell us about the problem

ActionBar border remains after all styling efforts

Which platform(s) does your issue occur on?

ios for sure, not sure about android

Please tell us how to recreate the issue in as much detail as possible.

tns create new

i updated the code to have page.ios trying to get the border to go away. I want black text, white action bar bg and no bottom border.

var createViewModel = require("./main-view-model").createViewModel;
var frame = require('ui/frame');

function onNavigatingTo(args) {
    var page = args.object;
    page.bindingContext = createViewModel();

    if (page.ios) {
        var navigationBar = frame.topmost().ios.controller.navigationBar;        
        navigationBar.translucent = false;
        navigationBar.barStyle = 0; 
        page.backgroundSpanUnderStatusBar = true;
        page.actionBarHidden = false; 
    }  

}
exports.onNavigatingTo = onNavigatingTo;
20 Answers

βœ”οΈAccepted Answer

<ActionBar flat="true"> implements this (see #3900). It was merged last month into tns-core-modules. I'm successfully using it in a few app already πŸ’ͺ

Other Answers:

@NickIliev Could we maybe put in another request (or turn this one into on) to get this added as an option to the Page\ActionBar?

Like

<ActionBar ios.hasShadow="false"

?

I'd like to bump this a bit, as having more control over the ActionBar is really a win for good UI design

Hi @firescript

Removing the thin border from the bottom of navigationBar is common problem in iOS.
To remove it use the native solution as follows:

    if (page.ios) {
        var navigationBar = frame.topmost().ios.controller.navigationBar;        
        navigationBar.translucent = false;
        navigationBar.barStyle = 0; 
        page.backgroundSpanUnderStatusBar = true;
        page.actionBarHidden = false; 

        // added this lines of code
        navigationBar.shadowImage = new UIImage();
        navigationBar.setBackgroundImageForBarMetrics(new UIImage(), UIBarMetrics.UIBarMetricsDefault)
    }  

More Issues: