From 54257fd527695c707449ab5be40abc7f80e7ea56 Mon Sep 17 00:00:00 2001 From: wushuwang Date: Wed, 5 Jun 2024 17:07:51 +0800 Subject: [PATCH] =?UTF-8?q?docs:=20=20[Issues:=20#I9KQRM]=20=E4=BF=AE?= =?UTF-8?q?=E6=94=B9react-native-material-design-style=E6=8C=87=E5=AF=BC?= =?UTF-8?q?=E6=96=87=E6=A1=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- zh-cn/react-native-material-design-style.md | 120 ++++++++++---------- 1 file changed, 62 insertions(+), 58 deletions(-) diff --git a/zh-cn/react-native-material-design-style.md b/zh-cn/react-native-material-design-style.md index 88ce5f56..4c75589a 100644 --- a/zh-cn/react-native-material-design-style.md +++ b/zh-cn/react-native-material-design-style.md @@ -41,69 +41,73 @@ yarn add react-native-material-design-styles@0.2.7 下面的代码展示了这个库的基本使用场景: -#### **Typography** + ```js -import { StyleSheet } from 'react-native'; +import { StyleSheet, Text, View, ScrollView } from 'react-native'; import { typography, color } from 'react-native-material-design-styles'; - const typographyStyle = StyleSheet.create(typography); const colorStyle = StyleSheet.create(color); - -Typography -Display4 -Display3 -Display2 -Display1 -Headline -Title -Subhead -Body2 -Body1 -Caption -Button -Code2 -Code1 -``` -#### **Color** -```js -import { StyleSheet } from 'react-native'; -import { color } from 'react-native-material-design-styles'; -const typographyStyle = StyleSheet.create(typography); - -Text Color -paperPink500 -paperPink50 -paperPink100 -paperPink200 -paperPink300 -paperPink400 -paperPink500 -paperPink600 -paperPink700 -paperPink800 -paperPink900 -paperPinkA100 -paperPinkA200 -paperPinkA400 -paperPinkA700 -``` -#### **Using for background or other ways** -```js - - - - - - - - - - - - - - +export function MetailDesignColor() { + return ( + + + Typography + Display4 + Display3 + Display2 + Display1 + Headline + Title + Subhead + Body2 + Body1 + Caption + Button + Code2 + Code1 + + Text Color + paperPink500 + paperPink50 + paperPink100 + paperPink200 + paperPink300 + paperPink400 + paperPink500 + paperPink600 + paperPink700 + paperPink800 + paperPink900 + paperPinkA100 + paperPinkA200 + paperPinkA400 + paperPinkA700 + + + + + + + + + + + + + + + + + + ) +} + +const styles = StyleSheet.create({ + colorItem: { + height: 50 + } +}) ``` -- Gitee