Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/ionic-framework/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/neo4j/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ionic framework Ionic4 Ion选择样式属性不工作_Ionic Framework_Ionic4 - Fatal编程技术网

Ionic framework Ionic4 Ion选择样式属性不工作

Ionic framework Ionic4 Ion选择样式属性不工作,ionic-framework,ionic4,Ionic Framework,Ionic4,我想为我的警报控制器应用css属性,但不起作用 home.html 这是我在项目中的工作解决方案 home.ts global.scss 你到底想给selectcss或alert box css什么?如果你想提醒框css,那么我已经在下面分享了我的解决方案 <ion-select [(ngModel)]="accountSystem" placeholder="Match Accounting Standard" okText="Done" cancelText="Cancel"

我想为我的警报控制器应用css属性,但不起作用

home.html


这是我在项目中的工作解决方案

home.ts

global.scss


你到底想给selectcss或alert box css什么?如果你想提醒框css,那么我已经在下面分享了我的解决方案
   <ion-select [(ngModel)]="accountSystem" placeholder="Match Accounting  Standard"  okText="Done" cancelText="Cancel"   class="select-account">
                  <ion-select-option value="PRC Gaap">PRC Gaap</ion-select-option>
                  <ion-select-option value="IFRS">IFRS</ion-select-option>
                  <ion-select-option value="US Gaap">US Gaap</ion-select-option>
              </ion-select>
   .select-account{
.alert-wrapper{
    .alert-button-inner{
    color:rgb(239,52,52);
    }
    .alert-button{
    color:rgb(52,223,57);
    }
}}
const alert = await this.alertCtrl.create({
      header: "Alert",
      mode: "ios",
      cssClass: "codealert",
          buttons: [
       {
          text: 'Cancel',
          role: 'cancel',
          cssClass: 'alertbutton',
          handler: () => {
            console.log('Confirm Cancel');
          }
        }, {
          text: 'Ok',
          cssClass: 'alertbutton',
          handler: () => {
            console.log('Confirm Ok');
          }
        }
      ]
    });

    await alert.present();
  }  
.codealert {
  --background: white;
}
.alertbutton {
  color: #600001 !important;
  font-weight: bold;
}