提交 2ce6a954 编写于 作者: Q qiang

Merge branch 'dev' of github.com:dcloudio/uni-app into dev

...@@ -171,22 +171,24 @@ if (process.env.UNI_USING_V3) { ...@@ -171,22 +171,24 @@ if (process.env.UNI_USING_V3) {
if (!isInsideKeyframes(rule)) { if (!isInsideKeyframes(rule)) {
// rule.selectors == comma seperated selectors // rule.selectors == comma seperated selectors
// a, b.c {} => ["a", "b.c"] // a, b.c {} => ["a", "b.c"]
rule.selectors = rule.selectors.map(complexSelector => rule.selectors = rule.selectors.map(complexSelector => {
// complexSelector => simpleSelectors // complexSelector => simpleSelectors
// "a.b#c" => ["a", ".b", "#c"] // "a.b#c" => ["a", ".b", "#c"]
transformSelector(complexSelector, simpleSelectors => if (complexSelector === 'page') {
hasPage = true
}
return transformSelector(complexSelector, simpleSelectors =>
// only process type selector, leave alone class & id selectors // only process type selector, leave alone class & id selectors
simpleSelectors.walkTags(tag => { simpleSelectors.walkTags(tag => {
if (tag.value === 'page') { if (tag.value === 'page') {
tag.value = 'uni-page-body' tag.value = 'uni-page-body'
hasPage = true
} else if (~TAGS.indexOf(tag.value) && tag.value.substring( } else if (~TAGS.indexOf(tag.value) && tag.value.substring(
0, 4) !== 'uni-') { 0, 4) !== 'uni-') {
tag.value = 'uni-' + tag.value tag.value = 'uni-' + tag.value
} }
}) })
) )
) })
} }
// handle upx unit // handle upx unit
rule.walkDecls(decl => { rule.walkDecls(decl => {
......
...@@ -24,7 +24,7 @@ function getTabBarPages (appJson) { ...@@ -24,7 +24,7 @@ function getTabBarPages (appJson) {
} }
function isTabBarPage (pathName, tabBarPages) { function isTabBarPage (pathName, tabBarPages) {
return tabBarPages.find(item => item.pagePath === pathName) return tabBarPages && tabBarPages.find(item => item.pagePath === pathName)
} }
function parseEntryPagePath (appJson, manifestJson) { function parseEntryPagePath (appJson, manifestJson) {
......
...@@ -298,7 +298,7 @@ export default { ...@@ -298,7 +298,7 @@ export default {
this._setValue() this._setValue()
var $picker = this.$refs.picker var $picker = this.$refs.picker
$picker.remove(); $picker.remove();
(document.querySelector('uni-app') || document.body).append($picker) (document.querySelector('uni-app') || document.body).appendChild($picker)
$picker.style.display = 'block' $picker.style.display = 'block'
setTimeout(() => { setTimeout(() => {
this.visible = true this.visible = true
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册