@@ -43,7 +43,11 @@ component TappableLinks(content: string, style: void | TextStyleProp) {
4343
4444 if ( matches . length === 0 ) {
4545 // No URLs detected. Just return the content.
46- return < Text style = { style } > { content } </ Text > ;
46+ return (
47+ < Text maxFontSizeMultiplier = { 1.5 } style = { style } >
48+ { content }
49+ </ Text >
50+ ) ;
4751 }
4852
4953 // URLs were detected. Construct array of Text nodes.
@@ -55,7 +59,11 @@ component TappableLinks(content: string, style: void | TextStyleProp) {
5559 for (const linkRange of matches) {
5660 if ( startIndex < linkRange . lowerBound ) {
5761 const text = content . substring ( startIndex , linkRange . lowerBound ) ;
58- fragments . push ( < Text key = { ++ indexCounter } > { text } </ Text > ) ;
62+ fragments . push (
63+ < Text key = { ++ indexCounter } maxFontSizeMultiplier = { 1.5 } >
64+ { text }
65+ </ Text > ,
66+ ) ;
5967 }
6068
6169 const link = content . substring ( linkRange . lowerBound , linkRange . upperBound ) ;
@@ -66,6 +74,7 @@ component TappableLinks(content: string, style: void | TextStyleProp) {
6674 Linking . openURL ( link ) ;
6775 } }
6876 key = { ++ indexCounter }
77+ maxFontSizeMultiplier = { 1.5 }
6978 style = { styles . linkText } >
7079 { link }
7180 </ Text > ,
@@ -77,13 +86,20 @@ component TappableLinks(content: string, style: void | TextStyleProp) {
7786 if ( startIndex < content . length ) {
7887 const text = content . substring ( startIndex ) ;
7988 fragments . push (
80- < Text key = { ++ indexCounter } style = { style } >
89+ < Text
90+ key = { ++ indexCounter }
91+ maxFontSizeMultiplier = { 1.5 }
92+ style = { style } >
8193 { text }
8294 </ Text > ,
8395 ) ;
8496 }
8597
86- return < Text style = { style } > { fragments } </ Text > ;
98+ return (
99+ < Text maxFontSizeMultiplier = { 1.5 } style = { style } >
100+ { fragments }
101+ </ Text >
102+ ) ;
87103}
88104
89105const cleanContent = ( content : string ) =>
@@ -98,7 +114,9 @@ component LogBoxMessage(
98114 const { content , substitutions } : Message = message ;
99115
100116 if ( plaintext === true ) {
101- return < Text > { cleanContent ( content ) } </ Text > ;
117+ return (
118+ < Text maxFontSizeMultiplier = { 1 } > { cleanContent ( content ) } </ Text >
119+ ) ;
102120 }
103121
104122 const resolvedMaxLength = maxLength != null ? maxLength : Infinity ;
0 commit comments