Browse Source

Restore demo codes

iou90 5 years ago
parent
commit
af3331328b
2 changed files with 2 additions and 14 deletions
  1. 1
    11
      demo/App.js
  2. 1
    3
      demo/config.js

+ 1
- 11
demo/App.js View File

@@ -115,17 +115,7 @@ const Explorer = () => {
115 115
         alignItems: 'center',
116 116
       }}>
117 117
       <AutoHeightWebView
118
-        scrollEnabledWithZoomedin
119
-        scrollEnabled={false}
120
-        customStyle={
121
-          `
122
-          #rnahw-wrapper {
123
-            padding: 0 30px;
124
-            width: 100vw;
125
-            box-sizing: border-box;
126
-          }
127
-          `
128
-        }
118
+        customStyle={heightStyle}
129 119
         onError={onError}
130 120
         onLoad={onHeightLoad}
131 121
         onLoadStart={onHeightLoadStart}

+ 1
- 3
demo/config.js View File

@@ -1,8 +1,6 @@
1 1
 'use strict';
2 2
 
3
-import newsletterZeit from "./newsletterZeit";
4
-
5
-const autoHeightHtml0 = newsletterZeit;//`<p style="font-weight: 400;font-style: normal;font-size: 21px;line-height: 1.58;letter-spacing: -.003em;"><a href="https://github.com/iou90/react-native-autoheight-webview">Tags</a> are great for describing the essence of your story in a single word or phrase, but stories are rarely about a single thing. <span style="background-color: transparent !important;background-image: linear-gradient(to bottom, rgba(146, 249, 190, 1), rgba(146, 249, 190, 1));">If I pen a story about moving across the country to start a new job in a car with my husband, two cats, a dog, and a tarantula, I wouldn't only tag the piece with "moving". I’d also use the <a href="http://x-squad.com">tags</a> "pets", "marriage", "career change", and "travel tips".</span></p>`;
3
+const autoHeightHtml0 = `<p style="font-weight: 400;font-style: normal;font-size: 21px;line-height: 1.58;letter-spacing: -.003em;"><a href="https://github.com/iou90/react-native-autoheight-webview">Tags</a> are great for describing the essence of your story in a single word or phrase, but stories are rarely about a single thing. <span style="background-color: transparent !important;background-image: linear-gradient(to bottom, rgba(146, 249, 190, 1), rgba(146, 249, 190, 1));">If I pen a story about moving across the country to start a new job in a car with my husband, two cats, a dog, and a tarantula, I wouldn't only tag the piece with "moving". I’d also use the <a href="http://x-squad.com">tags</a> "pets", "marriage", "career change", and "travel tips".</span></p>`;
6 4
 
7 5
 const autoHeightHtml1 = `Tags are great for describing the essence of your story in a single word or phrase, but stories are rarely about a single thing. If I pen a story about moving across the country to start a new job in a car with my husband, two cats, a dog, and a tarantula, I wouldn’t only tag the piece with "moving".`;
8 6