2017-01-16 5 views
1

이것은 내 HTML 코드이지만 어떻게 든이 선택 구성 요소에서 텍스트 둘러싸 기가 작동하지 않습니다. 아무도 아이디어가 있니?이오니아 2 텍스트 줄 바꿈 선택 구성 요소

<ion-list> 
    <h5 color="primary"> 
    Choose: 
    </h5> 

    <ion-item text-wrap> 
    <ion-select text-wrap class="selectWidth" okText="Ok" cancelText="Cancel" [selectOptions]="selectOptions" [(ngModel)]="Decision"> 
     <ion-option text-wrap selected="true" color="primary" value="vone" text-wrap>first first first first first</ion-option> 
     <ion-option text-wrap color="primary" value="vtwo">second second second second second second second</ion-option> 
     <ion-option text-wrap color="primary" value="vthree">third third third third third</ion-option> 
    </ion-select> 
    </ion-item> 
</ion-list> 
+0

당신이'공백을 설정하는 시도가 : 정상 ;''selectWidth' css 클래스에서? –

+0

예! 중요한 태그가있는 경우에도 ... –

+0

이 코드를 작동시키는 방법에 대한 전체 코드를 게시 할 수 있습니까? selectWidth 클래스에는 무엇이 있습니까? – user3561494

답변

2

오버라이드 main.css 또는 app.scss이 문제를 해결해야 당신에 다음을 추가하여 .sass

.alert-radio-label { 
    white-space: normal!important; 
} 
+0

에 올렸습니다. 고맙습니다. 열리는 경고 상자의 색상을 변경하는 방법을 알고 있습니까? .alert-radio-label –

+0

다음과 같이 사용합니다. .alert-wrapper { background-color : purple! important; } –

+0

이 수정되었습니다. 고마워요 :) –

-1

에서이 클래스 :

.alert-ios .alert-radio-label{ white-space: pre-line;} 
.alert-md .alert-radio-label{ white-space: pre-line;} 
.alert-wp .alert-radio-label{ white-space: pre-line;} 
.select-text { white-space: pre-line;}