React Native可用的css屬性

  React Native的css名稱和css有點點不一樣,有css基礎的很快上手css

 

 "alignItems",在輔軸的排列方向佈局

flex-start | flex-end | center | stretch

 "alignSelf",主容器內元素在輔軸的排列方向,同alignItems有點相似
  "backfaceVisibility",
  "backgroundColor",——背景顏色
  "borderBottomColor",
  "borderBottomLeftRadius",
  "borderBottomRightRadius",
  "borderBottomWidth",
  "borderColor",
  "borderLeftColor",
  "borderLeftWidth",
  "borderRadius",——容器圓角
  "borderRightColor",
  "borderRightWidth",
  "borderStyle",——solid,dotted,dashed
  "borderTopColor",
  "borderTopLeftRadius",
  "borderTopRightRadius",
  "borderTopWidth",
  "borderWidth",——邊框寬度
  "bottom",——絕對定位屬性
  "color",——字體顏色
  "elevation",——聽覺樣式表
  "flex",——分配剩餘空間
  "flexDirection",——設置主軸方向
  "flexWrap",
  "fontFamily",
  "fontSize",
  "fontStyle",
  "fontWeight",
  "height",
  "justifyContent",——在主軸的排列方向
  "left",——絕對定位屬性
  "letterSpacing",
  "lineHeight",
  "margin",
  "marginBottom",
  "marginHorizontal",
  "marginLeft",
  "marginRight",
  "marginTop",
  "marginVertical",
  "maxHeight",
  "maxWidth",
  "minHeight",
  "minWidth",
  "opacity",
  "overflow",
  "overlayColor",——?
  "padding",
  "paddingBottom",
  "paddingHorizontal",
  "paddingLeft",
  "paddingRight",
  "paddingTop",
  "paddingVertical",——針對輔軸兩邊的內邊距
  "position",
  "resizeMode",——resizeMode 縮放比例,可選參數('cover', 'contain', 'stretch') 該當圖片的尺寸超過佈局的尺寸的時候,會根據設置Mode進行縮放或者裁剪圖片
  "right",
  "rotation",
  "scaleX",
  "scaleY",
  "shadowColor",
  "shadowOffset",
  "shadowOpacity",
  "shadowRadius",
  "textAlign",
  "textAlignVertical",
  "textDecorationColor",
  "textDecorationLine",
  "textDecorationStyle",
  "textShadowColor",
  "textShadowOffset",
  "textShadowRadius",
  "tintColor",——圖片背景顏色
  "top",
  "transform",
  "transformMatrix",
  "translateX",
  "translateY",
  "width",
  "writingDirection",
  "zIndex"字體

相關文章
相關標籤/搜索