She
Posts: 0
Joined: Wed Oct 08, 2014 12:46 am

opacity of a text input

Hi Team,
How can i set opacity in a textinput in page show? and when the user taps that textinput the opacity will go back to normal,
i tried to use the disabled thingy using this code:

code//pageshow event
$("[dsid='txtCode']").attr('disabled', true).addClass('ui-state-disabled');
//this is not working in opacity

//and in click/tap event i put this code to enabled the textinput again
$("[dsid='txtCode']").attr('disabled', false).removeClass( 'ui-state-disabled' );
//this is not working too.
/code

Thanks

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

opacity of a text input

Hello She,

What code do you use to set opacity?

She
Posts: 0
Joined: Wed Oct 08, 2014 12:46 am

opacity of a text input

Appery('txtCode').css('opacity', '0.6');

Serhii Kulibaba
Posts: 150
Joined: Tue Aug 27, 2013 1:47 pm

opacity of a text input

Hello She,

Please use JS below for setting transparent background of the input component:

preApperyio('inputComponent').parent().css('background','transparent');/pre

here inputComponent - name of the input component

She
Posts: 0
Joined: Wed Oct 08, 2014 12:46 am

opacity of a text input

Hi Sergiy,
it works perfect. im using that code into pageshow and then when the user clicks the inputcomponent the white background of the inputcomponent will return i used this code:
code
Apperyio('inputComponent').parent().css('background','#fffff');
/code
the problem now is the FONT COLOR is grey. how can i change it to black? i usecode
Apperyio('txtCode').css('color','#000000');
/code
screenshot:
https://d2r1vs3d9006ap.cloudfront.net...
any suggestion?
Thank you
She

She
Posts: 0
Joined: Wed Oct 08, 2014 12:46 am

opacity of a text input

Hi Team,
ignore this i already figured out.

Thank you,

Return to “Issues”