blackberry / bbUI.js

BlackBerry UI look and feel JavaScript toolkit for WebWorks
Apache License 2.0
312 stars 192 forks source link

"Back" button background color and width #986

Closed sh2sg closed 10 years ago

sh2sg commented 11 years ago

In 10.2, it has black color background, width is shorter too.

untitled-1

splatterb0y commented 11 years ago

@tneil

tneil commented 11 years ago

Can you provide some more information such as which device is this seen on and where you pulled the screenshots from that you are comparing

sh2sg commented 11 years ago

@tneil

OS 10.2.0.1761 on Z10 and Q10 (DAC)

I compared bbUI sample with AppWorld client and System Settings.

BTW, 2 more issues on Back button

Letter B is cut on top. Need to set .bb-action-bar-back-text { overflow:visible;}

Back Slash image does not fade out when screen data-bb-effect="fade"

sh2sg commented 11 years ago

In 10.2, action bar and swipe down menu now look more 'flat' than before,

background color looks like single color, not gray gradient action bar no longer has inner shadow

tneil commented 10 years ago

The backslash image not fading out is an artifact that I don't think I'll be able to fix

tneil commented 10 years ago

I fixed the "back" text being cut off on the top.

tneil commented 10 years ago

I've also added the darker back button coloring. But I think that will be most that I'll be able to do with this one

sh2sg commented 10 years ago

I added a hack to adjust Back button width

    // Create the back button if it has one and there are no tabs in the action bar
    if (actionBar.hasAttribute('data-bb-back-caption') && actionBar.querySelectorAll('[data-bb-style=tab]').length == 0) {
        var chevron,
            backCaption,
            backslash,
            backHighlight,
            versionStyling = 'bb-action-bar-back-button-dark';
        if (bb.device.is10dot2) {
            versionStyling += '-10dot2';
        }
        backBtn = document.createElement('div');
        backBtn.setAttribute('class','bb-action-bar-back-button '+ versionStyling +' bb-action-bar-back-button-'+orientation);

        // Adjust Back button width
        if (bb.device.newerThan10dot1)
            backBtn.style['width'] = (bb.device.is720x720 || bb.device.is1280x720) ? '110px' : '134px'; 
        }