2014-02-25 43 views
0

今天我已經更新了我的應用程序從流星0.7.0.1到0.7.1.1,而且我的應用因我的app.css文件而崩潰。css和流星0.7.1:屬性丟失

這裏是失敗的部分:

@media screen (min-width: 1200px) { 
    #BtnCollapseStatusFilterBar { /* IT'S HERE JUST BEFORE THE EMBRACE */ 
    display: block; 
    } 
} 

和消息是:

=> Errors prevented startup: 
App 21289 stdout: 
App 21289 stdout: While building the application: 
App 21289 stdout: app.css: property missing ':' near line 10:31 
App 21289 stdout: 
App 21289 stdout: => Your application has errors. Waiting for file change. 

我真的不明白的問題,因爲我不是一個CSS高手。

有什麼想法?

以下是完整的CSS

@-webkit-viewport{width:device-width} 
@-moz-viewport{width:device-width} 
@-ms-viewport{width:device-width} 
@-o-viewport{width:device-width} 
@viewport{width:device-width} 

@grid-float-breakpoint: @screen-desktop; 

@media (min-width: 1200px) { 
    #BtnCollapseStatusFilterBar { 
    display: block; 
    } 

    #navbar-status-filterbar-collapse.collapse { 
    display: none !important; 
    } 
} 

/* CSS declarations go here */ 

#nprogress .bar { 
    z-index: 2000; /*bs3 navbar is on 1030*/ 
    background: #A300FF; 
} 

body { 
    background-image: url(subtlenet2.png); 
    background-attachment: repeat; 
    /*line-height: 19px;*/ 
    padding-top: 50px; 
} 

.blockAd { 
    padding-left: 10px; 
    min-height: 275px; /* don't work, only if inside style attribute directly in html */ 
    border: none; /*1px solid grey;*/ 
    border-radius: 10px 0 10px 0; 
    margin-bottom: 20px; 
    margin-right: 6px; 
    width:208px; 
    background: rgba(256, 256, 256, .7); 
} 

/* new ad */ 
.blockAd.newAd { 
    border-top: solid turquoise; 
} 

/* no more new */ 
.blockAd.viewedAd { 
    border-top: solid mediumseagreen; 
} 

/* detail open */ 
.blockAd.openedAd { 
    border-top: solid aquamarine; 
} 

/* no more interesting */ 
.blockAd.removedAd { 
    border-top: solid orange; 
} 

/* went to product */ 
.blockAd.visitedAd { 
    border-top: solid skyblue; 
} 

/* owner contacted */ 
.blockAd.starAd { 
    border-top: solid orangered; 
} 

.blockAd .btn-toolbar { 
    padding-top:5px; 
} 

.blockAnnonce .infos { 
    height: 110px; 
    margin-bottom: 3px; 
} 

.blockAd .infosHead { 
    color:black; 
} 

.blockAd .centerContentImage { 
    float:right; 
    width:100%; 
    padding-right:5px; 
    display:table-cell; 
    vertical-align:middle; 
    text-align:center; 
    margin-left:auto; 
    margin-right:auto; 
} 

.blockAd .centerContentImage img { 
    max-height: 110px; 
    max-width:140px; 
} 

.blockAd .centerContentImage button.OpenDetailAd { 
    height:105px; 
    margin-left:3px; 
} 

/* background of geo zone */ 
.navbar-collapse.navbar-location-collapse { 
    max-height: inherit; 
} 

/* title and buttons up/down non clickable */ 
.navbar-location-collapse ul { 
    margin-top: 50px; 
} 

/* 
a.BtnConfiguration span { 
    width: 44px; 
    height: 34px; 
}*/ 

回答

2

好像版本0.7.1在CSS的語法不正確的地方拋出錯誤,而忽略了相關的規則,就像以前的情況一樣。那裏可能總是有問題,只是在0.7.1之前沒有提出。

我會把你的整個CSS文件放在CSS Lint中,看看它出現了什麼問題 - 這可能與Meteor建議的不同,或者至少在某個地方出現了問題。

UPDATE 看完整的代碼,你至少有一個變化較少的在你的文件(@grid-float-breakpoint)。我不使用LESS,但據我所知,您需要給LESS文件一個.less文件擴展名,以告訴Meteor將它們編譯爲CSS,否則規則將失敗。嘗試將文件名從app.css改爲app.less,看看是否有效。很明顯,你需要添加LESS包,所以meteor add less如果你還沒有這樣做。

+0

感謝您的提示,不幸的是,林特沒有發現任何錯誤或警告消息。我從css文件中刪除了這些行,然後再次運行。但這不是解決方案,因爲我需要這些線路。 – Rebolon

+0

事實上,如果我刪除了一些先前的行的CSS,然後CSS林特發現更多的警告。其中一些是「在選擇器中禁止ID」,但即使我刪除了五行frise的CSS我仍然有一些ID和它的作品... – Rebolon

+0

你可以發佈整個CSS? – richsilv

0

我有同樣的問題幾個小時回來。我只是錯過這樣

padding-left:"" 

我忘了給的值一些屬性值,我給後它工作得很好。在CSS中檢查相同的內容。

我想在你的應用程序中的第10行的東西你忘了給像上面的財產價值。