2016-09-27 16 views
2

login.htmlの入力ボックスに問題があります。私は入力ボックスの幅を増やすことができません。幅を100%に増やしていると、その高さが増えています。ionic - 入力ボックスの幅

ここに幅を示す画像があります。

私は幅がそれのほぼ倍になりたいです。ここ は私のHTMLとCSSへのリンクです: https://jsfiddle.net/ybkjv8uw/

item.item-input { 
    border: none; 
    position: relative; 

    left: 0px; 
    top: 135px; 
    background-color: transparent; 
} 

答えて

0

.view-content { 
 
    background-color:#85b818; 
 
} 
 
.img-div { 
 

 
    position: relative; 
 
    left: 110px; 
 
    top: 35px; 
 
    
 

 
} 
 

 
.item.item-input { 
 
\t border: none; 
 
\t position: relative; 
 
    
 
    left: 0px; 
 
    top: 135px; 
 
    background-color: transparent; 
 
    width:100%; 
 
} 
 
.item.item-input span{width:auto;} 
 
.item.item-input input{width:68%;} 
 
/*.item-input-inset .item-input-wrapper input { 
 
    padding-left: 4px; 
 
    height: 29px; 
 
    background: transparent; 
 
    line-height: 18px; 
 
    // you should add the following: 
 
    box-sizing: border-box; 
 
    width: 100%; 
 
}*/ 
 
input::-webkit-input-placeholder { 
 
color: white; 
 
} 
 

 

 

 
label { 
 

 
    /*display: block; width: 100%;*/ 
 
    width:200px; 
 
    float: left; 
 
    /*clear:left;*/ 
 
    text-align:right; 
 
    /*padding-right:10px;*/ 
 
} 
 

 
input{ 
 
    /*float:left;*/ 
 

 
} 
 

 
.enter-div { 
 
\t text-align: center; 
 
} 
 

 
.enter-button { 
 
\t position: relative; 
 
    top: 170px; 
 
\t width: 280px; 
 
\t height: 50px; 
 
    border-radius: 25px; 
 
\t border: none; 
 
\t background-color: green; 
 
\t color: white; 
 
} 
 

 
.foyopass-div { 
 
\t position: relative; 
 
\t text-align: center; 
 
\t top: 200px; 
 
\t color: white; 
 
}
<ion-view class="view-content"> 
 
     <div class="img-div"> 
 
     <img src="img/main_logo_icon.png" style="width : 40% ; height : 20%" > 
 
     </div> 
 
     <div> 
 
      <label class="item item-input"> 
 
      <span class="input-label" ><img src="img/email_icon.png" style="width: 30%" ></span> 
 
      <input type="email" placeholder="Email"> 
 
      </label> 
 
     </div> 
 
     <div> 
 
      <label class="item item-input"> 
 
      <span class="input-label" ><img src="img/password_icon.png" style="width: 25%"></span> 
 
      <input type="password" placeholder="Password"> 
 
      </label> 
 
     </div> 
 
     <div class="enter-div"> 
 
     <button class="enter-button"> 
 
     Enter 
 
     </button> 
 

 

 
     </div> 
 
     <div class="enter-div"> 
 
     <a href="" class="foyopass-div">forgot your password?</a> 
 
     </div> 
 
</ion-view>

+0

どうもありがとう!!! Dhaarani !!!それは今働く! :) –

+0

@S。 Jashoriaそれは大丈夫です – Dhaarani

3
.item.item-input { 
    border: none; 
    position: relative; 
    top: 135px; 
    background-color: transparent; 
    width:100%; 
    } 


.item.item-input>span{ 
    width:auto; 
    } 
.item.item-input>input{ 
    width:68%; 
} 
+1

このコードスニペットは問題を解決するかもしれませんが、[説明を含む](http://meta.stackexchange.com/questions/114762/explaining-entirely-code-based-answers)は、あなたの投稿。将来読者の質問に答えていることを覚えておいてください。そうした人々はあなたのコード提案の理由を知らないかもしれません。 – andreas

関連する問題