From 38b8a467477bab9972d37d8309a46f363e080b1a Mon Sep 17 00:00:00 2001 From: wxik Date: Mon, 3 Apr 2023 21:52:53 +0800 Subject: [PATCH] fix: github build error --- README.md | 10 ++++++---- examples/src/example.tsx | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 57af9b6..34d4db1 100644 --- a/README.md +++ b/README.md @@ -175,9 +175,9 @@ export default FontFamilyStylesheet; ```javascript import FontFamilyStylesheet from 'stylesheet.js'; - +const fontFamily = 'Your_Font_Family'; +const initialCSSText = { initialCSSText: `${FontFamilyStylesheet}`, contentCSSText: `font-family: ${fontFamily}` } + ``` 5. Reload the app. You should now be seeing your Rich Editor content in your custom font face! @@ -293,6 +293,8 @@ import React from "react"; import { Text, Platform, KeyboardAvoidingView, SafeAreaView, ScrollView } from "react-native"; import {actions, RichEditor, RichToolbar} from "react-native-pell-rich-editor"; + +const handleHead = ({tintColor}) => H1 const TempScreen = () => { const richText = React.useRef(); return ( @@ -312,7 +314,7 @@ const TempScreen = () => { (H1), }} + iconMap={{ [actions.heading1]: handleHead }} /> ); diff --git a/examples/src/example.tsx b/examples/src/example.tsx index 0f05ba9..e09db2a 100644 --- a/examples/src/example.tsx +++ b/examples/src/example.tsx @@ -4,7 +4,7 @@ * @author wxik * @since 2019-06-24 14:52 */ -import React, {useCallback, useEffect, useMemo, useRef, useState} from 'react'; +import {useCallback, useEffect, useMemo, useRef, useState} from 'react'; import { Appearance, Button,