Ionic-Material icon indicating copy to clipboard operation
Ionic-Material copied to clipboard

Demo input css

Open thomas-tran opened this issue 9 years ago • 19 comments

How can I change the background color of the ion-md-input , it seems that ionic material set the background to black by default and I am unable to change it even I copy the stylesheet from ion-md-input itself.

thomas-tran avatar May 27 '15 08:05 thomas-tran

ion-md-input author here, you should be able to pass a highlight color to the directive.

https://github.com/mhartington/ion-md-input#usage

<ion-md-input placeholder="Name" hightlight-color="energized" type="text"></ion-md-input>

mhartington avatar May 27 '15 16:05 mhartington

Hi

My default color is white on the background page therefore I need change to style to white background color of the input box and the floating label to dark color.

What I mean is the background color of the input text, at the moment it set to dark #444 in your style.css and I could not change the style unless overwrite your css.

The hightlight-color is just change the underline color of the input text and it did not change the background of the input.

thomas-tran avatar May 27 '15 23:05 thomas-tran

Same issue for me

sangregoriopaolo avatar May 28 '15 20:05 sangregoriopaolo

So, I'm not sure I follow. Are you talking about the background color of the inputs or the text-color of the label? Either of the two can be overwritten with your own css, so I'm not sure this is much of an issue.

http://codepen.io/mhartington/pen/zGNrzV

It just would require you to write your own css to fit your needs.

mhartington avatar May 28 '15 20:05 mhartington

Hi, actually, including your css, and following the instructions on ion-md-input to use it, I get this screen shot 2015-05-28 at 22 32 27

sangregoriopaolo avatar May 28 '15 20:05 sangregoriopaolo

Any way you could put together a codepen demo? Something else must be happening here that I'm not aware of

mhartington avatar May 28 '15 20:05 mhartington

Hi ,

I means the background of the input, how can you change it to dark color to white color? Also, the input floating label as well.

I used bower to install to my application and reference the css and js, however I could not find any document how to change the style of those input.

Thanks Thomas

thomas-tran avatar May 28 '15 23:05 thomas-tran

Codepen or Plunkr please On Fri, 29 May 2015 at 00:36, Thomas Tran [email protected] wrote:

Hi ,

I means the background of the input, how can you change it to dark color to white color? Also, the input floating label as well.

I used bower to install to my application and reference the css and js, however I could not find any document how to change the style of those input.

Thanks

Thomas

— Reply to this email directly or view it on GitHub https://github.com/zachsoft/Ionic-Material/issues/74#issuecomment-106629474 .

rbutera avatar May 29 '15 13:05 rbutera

Please demonstrate this issue with a codepen

rbutera avatar May 30 '15 17:05 rbutera

It likes the ionic-material conflict with ion-md-input.

sliontc avatar Aug 14 '15 14:08 sliontc

ionic-material overrides the ion-md-input.

sliontc avatar Aug 14 '15 14:08 sliontc

Just include both ionic-material and ion-md-input to reproduce the issue.

sliontc avatar Aug 14 '15 15:08 sliontc

Any feedback?

sliontc avatar Aug 21 '15 02:08 sliontc

Yes, if use ionic-material and ion-md-input together, the background of ion-md-input will change.

liuwenzhuang avatar Oct 22 '15 03:10 liuwenzhuang

.item-md-label input classes conflict. Need custom override to fix.

mmaask avatar Jan 18 '16 16:01 mmaask

Hi - I've added a new directive to the ion-md-input. This now resets the style. If you want to use without Ionic Material styling just use like this:

My fork here: https://github.com/adskiremote/ion-md-input

adskiremote avatar Feb 09 '16 18:02 adskiremote

Pretty sure this was fixed in my original repo, just this repo was pulling an older version

mhartington avatar Feb 09 '16 18:02 mhartington

Hi Mike, ah sorry didn't realise. Thought the other was the updated. Thanks for that as I'll update mine and check :-)

adskiremote avatar Feb 10 '16 08:02 adskiremote

1 add via bower ionic-material and ion-md-input. 2 in bower component ion-md-input open bower.json and modify main like that "main": [ "ion-md-input.js", "css/ion-md-input.css" ], 3 open ionic-material.css in bower components and comment all row in section /* Directives : MD Label. 4 add this to you css .item-md-label input { border-bottom: 1px solid #757575 !important; width: 100% !important; }

.item-md-label { padding-right: 10px !important; padding-left: 10px !important; }

costin-moraru avatar May 11 '16 13:05 costin-moraru