Compare commits

...

8 commits

Author SHA1 Message Date
smfahim25
77f23d574d update 2025-04-20 15:16:55 +06:00
smfahim25
5c0c53d44c update css 2025-04-13 10:55:47 +06:00
smfahim25
4998de8b24 update logo 2025-04-13 10:46:39 +06:00
smfahim25
3fcbffd986 update 2025-04-13 10:04:53 +06:00
smfahim25
32402275ac update code 2025-04-12 16:11:14 +06:00
smfahim25
50acb05f23 Merge branch 'main' of ssh://git.planpostai.com:2222/planpostai/fake-checker-nativeapp 2025-04-12 15:51:34 +06:00
smfahim25
00ccafdf0e update code 2025-04-12 15:50:02 +06:00
76ef6f9dce Update README.md 2025-01-06 12:39:31 +00:00
15 changed files with 1478 additions and 555 deletions

2
.gitignore vendored
View file

@ -36,3 +36,5 @@ yarn-error.*
*.tsbuildinfo *.tsbuildinfo
app-example app-example
.codegpt

View file

@ -8,17 +8,31 @@
<option name="brand" value="DOCOMO" /> <option name="brand" value="DOCOMO" />
<option name="codename" value="F01L" /> <option name="codename" value="F01L" />
<option name="id" value="F01L" /> <option name="id" value="F01L" />
<option name="labId" value="google" />
<option name="manufacturer" value="FUJITSU" /> <option name="manufacturer" value="FUJITSU" />
<option name="name" value="F-01L" /> <option name="name" value="F-01L" />
<option name="screenDensity" value="360" /> <option name="screenDensity" value="360" />
<option name="screenX" value="720" /> <option name="screenX" value="720" />
<option name="screenY" value="1280" /> <option name="screenY" value="1280" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="OnePlus" />
<option name="codename" value="OP5552L1" />
<option name="id" value="OP5552L1" />
<option name="labId" value="google" />
<option name="manufacturer" value="OnePlus" />
<option name="name" value="CPH2415" />
<option name="screenDensity" value="480" />
<option name="screenX" value="1080" />
<option name="screenY" value="2412" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="34" /> <option name="api" value="34" />
<option name="brand" value="OPPO" /> <option name="brand" value="OPPO" />
<option name="codename" value="OP573DL1" /> <option name="codename" value="OP573DL1" />
<option name="id" value="OP573DL1" /> <option name="id" value="OP573DL1" />
<option name="labId" value="google" />
<option name="manufacturer" value="OPPO" /> <option name="manufacturer" value="OPPO" />
<option name="name" value="CPH2557" /> <option name="name" value="CPH2557" />
<option name="screenDensity" value="480" /> <option name="screenDensity" value="480" />
@ -30,6 +44,7 @@
<option name="brand" value="DOCOMO" /> <option name="brand" value="DOCOMO" />
<option name="codename" value="SH-01L" /> <option name="codename" value="SH-01L" />
<option name="id" value="SH-01L" /> <option name="id" value="SH-01L" />
<option name="labId" value="google" />
<option name="manufacturer" value="SHARP" /> <option name="manufacturer" value="SHARP" />
<option name="name" value="AQUOS sense2 SH-01L" /> <option name="name" value="AQUOS sense2 SH-01L" />
<option name="screenDensity" value="480" /> <option name="screenDensity" value="480" />
@ -40,18 +55,45 @@
<option name="api" value="34" /> <option name="api" value="34" />
<option name="brand" value="Lenovo" /> <option name="brand" value="Lenovo" />
<option name="codename" value="TB370FU" /> <option name="codename" value="TB370FU" />
<option name="formFactor" value="Tablet" />
<option name="id" value="TB370FU" /> <option name="id" value="TB370FU" />
<option name="labId" value="google" />
<option name="manufacturer" value="Lenovo" /> <option name="manufacturer" value="Lenovo" />
<option name="name" value="Tab P12" /> <option name="name" value="Tab P12" />
<option name="screenDensity" value="340" /> <option name="screenDensity" value="340" />
<option name="screenX" value="1840" /> <option name="screenX" value="1840" />
<option name="screenY" value="2944" /> <option name="screenY" value="2944" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="a15" />
<option name="id" value="a15" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="A15" />
<option name="screenDensity" value="450" />
<option name="screenX" value="1080" />
<option name="screenY" value="2340" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="a35x" />
<option name="id" value="a35x" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="A35" />
<option name="screenDensity" value="450" />
<option name="screenX" value="1080" />
<option name="screenY" value="2340" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="31" /> <option name="api" value="31" />
<option name="brand" value="samsung" /> <option name="brand" value="samsung" />
<option name="codename" value="a51" /> <option name="codename" value="a51" />
<option name="id" value="a51" /> <option name="id" value="a51" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" /> <option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy A51" /> <option name="name" value="Galaxy A51" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
@ -63,17 +105,43 @@
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="akita" /> <option name="codename" value="akita" />
<option name="id" value="akita" /> <option name="id" value="akita" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 8a" /> <option name="name" value="Pixel 8a" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
<option name="screenX" value="1080" /> <option name="screenX" value="1080" />
<option name="screenY" value="2400" /> <option name="screenY" value="2400" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="motorola" />
<option name="codename" value="arcfox" />
<option name="id" value="arcfox" />
<option name="labId" value="google" />
<option name="manufacturer" value="Motorola" />
<option name="name" value="razr plus 2024" />
<option name="screenDensity" value="360" />
<option name="screenX" value="1080" />
<option name="screenY" value="1272" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="33" />
<option name="brand" value="motorola" />
<option name="codename" value="austin" />
<option name="id" value="austin" />
<option name="labId" value="google" />
<option name="manufacturer" value="Motorola" />
<option name="name" value="moto g 5G (2022)" />
<option name="screenDensity" value="280" />
<option name="screenX" value="720" />
<option name="screenY" value="1600" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="33" /> <option name="api" value="33" />
<option name="brand" value="samsung" /> <option name="brand" value="samsung" />
<option name="codename" value="b0q" /> <option name="codename" value="b0q" />
<option name="id" value="b0q" /> <option name="id" value="b0q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" /> <option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy S22 Ultra" /> <option name="name" value="Galaxy S22 Ultra" />
<option name="screenDensity" value="600" /> <option name="screenDensity" value="600" />
@ -85,6 +153,7 @@
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="bluejay" /> <option name="codename" value="bluejay" />
<option name="id" value="bluejay" /> <option name="id" value="bluejay" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 6a" /> <option name="name" value="Pixel 6a" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
@ -96,6 +165,7 @@
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="caiman" /> <option name="codename" value="caiman" />
<option name="id" value="caiman" /> <option name="id" value="caiman" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 9 Pro" /> <option name="name" value="Pixel 9 Pro" />
<option name="screenDensity" value="360" /> <option name="screenDensity" value="360" />
@ -106,7 +176,9 @@
<option name="api" value="34" /> <option name="api" value="34" />
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="comet" /> <option name="codename" value="comet" />
<option name="default" value="true" />
<option name="id" value="comet" /> <option name="id" value="comet" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 9 Pro Fold" /> <option name="name" value="Pixel 9 Pro Fold" />
<option name="screenDensity" value="390" /> <option name="screenDensity" value="390" />
@ -118,17 +190,31 @@
<option name="brand" value="samsung" /> <option name="brand" value="samsung" />
<option name="codename" value="crownqlteue" /> <option name="codename" value="crownqlteue" />
<option name="id" value="crownqlteue" /> <option name="id" value="crownqlteue" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" /> <option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy Note9" /> <option name="name" value="Galaxy Note9" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
<option name="screenX" value="2220" /> <option name="screenX" value="2220" />
<option name="screenY" value="1080" /> <option name="screenY" value="1080" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="dm2q" />
<option name="id" value="dm2q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="S23 Plus" />
<option name="screenDensity" value="450" />
<option name="screenX" value="1080" />
<option name="screenY" value="2340" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="34" /> <option name="api" value="34" />
<option name="brand" value="samsung" /> <option name="brand" value="samsung" />
<option name="codename" value="dm3q" /> <option name="codename" value="dm3q" />
<option name="id" value="dm3q" /> <option name="id" value="dm3q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" /> <option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy S23 Ultra" /> <option name="name" value="Galaxy S23 Ultra" />
<option name="screenDensity" value="600" /> <option name="screenDensity" value="600" />
@ -139,18 +225,45 @@
<option name="api" value="34" /> <option name="api" value="34" />
<option name="brand" value="samsung" /> <option name="brand" value="samsung" />
<option name="codename" value="e1q" /> <option name="codename" value="e1q" />
<option name="default" value="true" />
<option name="id" value="e1q" /> <option name="id" value="e1q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" /> <option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy S24" /> <option name="name" value="Galaxy S24" />
<option name="screenDensity" value="480" /> <option name="screenDensity" value="480" />
<option name="screenX" value="1080" /> <option name="screenX" value="1080" />
<option name="screenY" value="2340" /> <option name="screenY" value="2340" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="e3q" />
<option name="id" value="e3q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy S24 Ultra" />
<option name="screenDensity" value="450" />
<option name="screenX" value="1440" />
<option name="screenY" value="3120" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="33" />
<option name="brand" value="google" />
<option name="codename" value="eos" />
<option name="id" value="eos" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" />
<option name="name" value="Eos" />
<option name="screenDensity" value="320" />
<option name="screenX" value="384" />
<option name="screenY" value="384" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="33" /> <option name="api" value="33" />
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="felix" /> <option name="codename" value="felix" />
<option name="id" value="felix" /> <option name="id" value="felix" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel Fold" /> <option name="name" value="Pixel Fold" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
@ -162,6 +275,7 @@
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="felix" /> <option name="codename" value="felix" />
<option name="id" value="felix" /> <option name="id" value="felix" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel Fold" /> <option name="name" value="Pixel Fold" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
@ -173,28 +287,105 @@
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="felix_camera" /> <option name="codename" value="felix_camera" />
<option name="id" value="felix_camera" /> <option name="id" value="felix_camera" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel Fold (Camera-enabled)" /> <option name="name" value="Pixel Fold (Camera-enabled)" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
<option name="screenX" value="2208" /> <option name="screenX" value="2208" />
<option name="screenY" value="1840" /> <option name="screenY" value="1840" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="motorola" />
<option name="codename" value="fogona" />
<option name="id" value="fogona" />
<option name="labId" value="google" />
<option name="manufacturer" value="Motorola" />
<option name="name" value="moto g play - 2024" />
<option name="screenDensity" value="280" />
<option name="screenX" value="720" />
<option name="screenY" value="1600" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="g0q" />
<option name="id" value="g0q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="SM-S906U1" />
<option name="screenDensity" value="450" />
<option name="screenX" value="1080" />
<option name="screenY" value="2340" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="gta9pwifi" />
<option name="id" value="gta9pwifi" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="SM-X210" />
<option name="screenDensity" value="240" />
<option name="screenX" value="1200" />
<option name="screenY" value="1920" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="gts7xllite" />
<option name="id" value="gts7xllite" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="SM-T738U" />
<option name="screenDensity" value="340" />
<option name="screenX" value="1600" />
<option name="screenY" value="2560" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="33" /> <option name="api" value="33" />
<option name="brand" value="samsung" /> <option name="brand" value="samsung" />
<option name="codename" value="gts8uwifi" /> <option name="codename" value="gts8uwifi" />
<option name="formFactor" value="Tablet" />
<option name="id" value="gts8uwifi" /> <option name="id" value="gts8uwifi" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" /> <option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy Tab S8 Ultra" /> <option name="name" value="Galaxy Tab S8 Ultra" />
<option name="screenDensity" value="320" /> <option name="screenDensity" value="320" />
<option name="screenX" value="1848" /> <option name="screenX" value="1848" />
<option name="screenY" value="2960" /> <option name="screenY" value="2960" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="gts8wifi" />
<option name="formFactor" value="Tablet" />
<option name="id" value="gts8wifi" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy Tab S8" />
<option name="screenDensity" value="274" />
<option name="screenX" value="1600" />
<option name="screenY" value="2560" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="gts9fe" />
<option name="id" value="gts9fe" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy Tab S9 FE 5G" />
<option name="screenDensity" value="280" />
<option name="screenX" value="1440" />
<option name="screenY" value="2304" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="34" /> <option name="api" value="34" />
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="husky" /> <option name="codename" value="husky" />
<option name="id" value="husky" /> <option name="id" value="husky" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 8 Pro" /> <option name="name" value="Pixel 8 Pro" />
<option name="screenDensity" value="390" /> <option name="screenDensity" value="390" />
@ -206,6 +397,7 @@
<option name="brand" value="motorola" /> <option name="brand" value="motorola" />
<option name="codename" value="java" /> <option name="codename" value="java" />
<option name="id" value="java" /> <option name="id" value="java" />
<option name="labId" value="google" />
<option name="manufacturer" value="Motorola" /> <option name="manufacturer" value="Motorola" />
<option name="name" value="G20" /> <option name="name" value="G20" />
<option name="screenDensity" value="280" /> <option name="screenDensity" value="280" />
@ -217,6 +409,7 @@
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="komodo" /> <option name="codename" value="komodo" />
<option name="id" value="komodo" /> <option name="id" value="komodo" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 9 Pro XL" /> <option name="name" value="Pixel 9 Pro XL" />
<option name="screenDensity" value="360" /> <option name="screenDensity" value="360" />
@ -228,17 +421,43 @@
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="lynx" /> <option name="codename" value="lynx" />
<option name="id" value="lynx" /> <option name="id" value="lynx" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 7a" /> <option name="name" value="Pixel 7a" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
<option name="screenX" value="1080" /> <option name="screenX" value="1080" />
<option name="screenY" value="2400" /> <option name="screenY" value="2400" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="33" />
<option name="brand" value="motorola" />
<option name="codename" value="maui" />
<option name="id" value="maui" />
<option name="labId" value="google" />
<option name="manufacturer" value="Motorola" />
<option name="name" value="moto g play - 2023" />
<option name="screenDensity" value="280" />
<option name="screenX" value="720" />
<option name="screenY" value="1600" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="o1q" />
<option name="id" value="o1q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy S21" />
<option name="screenDensity" value="421" />
<option name="screenX" value="1080" />
<option name="screenY" value="2400" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="31" /> <option name="api" value="31" />
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="oriole" /> <option name="codename" value="oriole" />
<option name="id" value="oriole" /> <option name="id" value="oriole" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 6" /> <option name="name" value="Pixel 6" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
@ -250,6 +469,7 @@
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="panther" /> <option name="codename" value="panther" />
<option name="id" value="panther" /> <option name="id" value="panther" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 7" /> <option name="name" value="Pixel 7" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
@ -261,6 +481,7 @@
<option name="brand" value="samsung" /> <option name="brand" value="samsung" />
<option name="codename" value="q5q" /> <option name="codename" value="q5q" />
<option name="id" value="q5q" /> <option name="id" value="q5q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" /> <option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy Z Fold5" /> <option name="name" value="Galaxy Z Fold5" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
@ -272,6 +493,7 @@
<option name="brand" value="samsung" /> <option name="brand" value="samsung" />
<option name="codename" value="q6q" /> <option name="codename" value="q6q" />
<option name="id" value="q6q" /> <option name="id" value="q6q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" /> <option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy Z Fold6" /> <option name="name" value="Galaxy Z Fold6" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
@ -282,7 +504,9 @@
<option name="api" value="30" /> <option name="api" value="30" />
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="r11" /> <option name="codename" value="r11" />
<option name="formFactor" value="Wear OS" />
<option name="id" value="r11" /> <option name="id" value="r11" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel Watch" /> <option name="name" value="Pixel Watch" />
<option name="screenDensity" value="320" /> <option name="screenDensity" value="320" />
@ -290,11 +514,24 @@
<option name="screenY" value="384" /> <option name="screenY" value="384" />
<option name="type" value="WEAR_OS" /> <option name="type" value="WEAR_OS" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="r11q" />
<option name="id" value="r11q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="SM-S711U" />
<option name="screenDensity" value="450" />
<option name="screenX" value="1080" />
<option name="screenY" value="2340" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="30" /> <option name="api" value="30" />
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="redfin" /> <option name="codename" value="redfin" />
<option name="id" value="redfin" /> <option name="id" value="redfin" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 5" /> <option name="name" value="Pixel 5" />
<option name="screenDensity" value="440" /> <option name="screenDensity" value="440" />
@ -306,17 +543,32 @@
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="shiba" /> <option name="codename" value="shiba" />
<option name="id" value="shiba" /> <option name="id" value="shiba" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 8" /> <option name="name" value="Pixel 8" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />
<option name="screenX" value="1080" /> <option name="screenX" value="1080" />
<option name="screenY" value="2400" /> <option name="screenY" value="2400" />
</PersistentDeviceSelectionData> </PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="34" />
<option name="brand" value="samsung" />
<option name="codename" value="t2q" />
<option name="id" value="t2q" />
<option name="labId" value="google" />
<option name="manufacturer" value="Samsung" />
<option name="name" value="Galaxy S21 Plus" />
<option name="screenDensity" value="394" />
<option name="screenX" value="1080" />
<option name="screenY" value="2400" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData> <PersistentDeviceSelectionData>
<option name="api" value="33" /> <option name="api" value="33" />
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="tangorpro" /> <option name="codename" value="tangorpro" />
<option name="formFactor" value="Tablet" />
<option name="id" value="tangorpro" /> <option name="id" value="tangorpro" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel Tablet" /> <option name="name" value="Pixel Tablet" />
<option name="screenDensity" value="320" /> <option name="screenDensity" value="320" />
@ -327,7 +579,22 @@
<option name="api" value="34" /> <option name="api" value="34" />
<option name="brand" value="google" /> <option name="brand" value="google" />
<option name="codename" value="tokay" /> <option name="codename" value="tokay" />
<option name="default" value="true" />
<option name="id" value="tokay" /> <option name="id" value="tokay" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" />
<option name="name" value="Pixel 9" />
<option name="screenDensity" value="420" />
<option name="screenX" value="1080" />
<option name="screenY" value="2424" />
</PersistentDeviceSelectionData>
<PersistentDeviceSelectionData>
<option name="api" value="35" />
<option name="brand" value="google" />
<option name="codename" value="tokay" />
<option name="default" value="true" />
<option name="id" value="tokay" />
<option name="labId" value="google" />
<option name="manufacturer" value="Google" /> <option name="manufacturer" value="Google" />
<option name="name" value="Pixel 9" /> <option name="name" value="Pixel 9" />
<option name="screenDensity" value="420" /> <option name="screenDensity" value="420" />

1
.idea/misc.xml generated
View file

@ -1,4 +1,3 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="ProjectRootManager"> <component name="ProjectRootManager">
<output url="file://$PROJECT_DIR$/out" /> <output url="file://$PROJECT_DIR$/out" />

126
README.md
View file

@ -1,93 +1,61 @@
# fake-checker-nativeapp # Fact Checker App
A mobile application built with Expo that helps users verify information and detect misinformation across various sources.
## Prerequisites
## Getting started - [Node.js](https://nodejs.org/) (v16 or higher)
- [npm](https://www.npmjs.com/) (v8 or higher)
To make it easy for you to get started with GitLab, here's a list of recommended next steps. - [Expo CLI](https://docs.expo.dev/workflow/expo-cli/) (`npm install -g expo-cli`)
Already a pro? Just edit this README.md and make it your own. Want to make it easy? [Use the template at the bottom](#editing-this-readme)!
## Add your files
- [ ] [Create](https://docs.gitlab.com/ee/user/project/repository/web_editor.html#create-a-file) or [upload](https://docs.gitlab.com/ee/user/project/repository/web_editor.html#upload-a-file) files
- [ ] [Add files using the command line](https://docs.gitlab.com/ee/gitlab-basics/add-file.html#add-a-file-using-the-command-line) or push an existing Git repository with the following command:
```
cd existing_repo
git remote add origin https://git.planpostai.com/smfahimhossen/fake-checker-nativeapp.git
git branch -M main
git push -uf origin main
```
## Integrate with your tools
- [ ] [Set up project integrations](https://git.planpostai.com/smfahimhossen/fake-checker-nativeapp/-/settings/integrations)
## Collaborate with your team
- [ ] [Invite team members and collaborators](https://docs.gitlab.com/ee/user/project/members/)
- [ ] [Create a new merge request](https://docs.gitlab.com/ee/user/project/merge_requests/creating_merge_requests.html)
- [ ] [Automatically close issues from merge requests](https://docs.gitlab.com/ee/user/project/issues/managing_issues.html#closing-issues-automatically)
- [ ] [Enable merge request approvals](https://docs.gitlab.com/ee/user/project/merge_requests/approvals/)
- [ ] [Set auto-merge](https://docs.gitlab.com/ee/user/project/merge_requests/merge_when_pipeline_succeeds.html)
## Test and Deploy
Use the built-in continuous integration in GitLab.
- [ ] [Get started with GitLab CI/CD](https://docs.gitlab.com/ee/ci/quick_start/index.html)
- [ ] [Analyze your code for known vulnerabilities with Static Application Security Testing (SAST)](https://docs.gitlab.com/ee/user/application_security/sast/)
- [ ] [Deploy to Kubernetes, Amazon EC2, or Amazon ECS using Auto Deploy](https://docs.gitlab.com/ee/topics/autodevops/requirements.html)
- [ ] [Use pull-based deployments for improved Kubernetes management](https://docs.gitlab.com/ee/user/clusters/agent/)
- [ ] [Set up protected environments](https://docs.gitlab.com/ee/ci/environments/protected_environments.html)
***
# Editing this README
When you're ready to make this README your own, just edit this file and use the handy template below (or feel free to structure it however you want - this is just a starting point!). Thanks to [makeareadme.com](https://www.makeareadme.com/) for this template.
## Suggestions for a good README
Every project is different, so consider which of these sections apply to yours. The sections used in the template are suggestions for most open source projects. Also keep in mind that while a README can be too long and detailed, too long is better than too short. If you think your README is too long, consider utilizing another form of documentation rather than cutting out information.
## Name
Choose a self-explaining name for your project.
## Description
Let people know what your project can do specifically. Provide context and add a link to any reference visitors might be unfamiliar with. A list of Features or a Background subsection can also be added here. If there are alternatives to your project, this is a good place to list differentiating factors.
## Badges
On some READMEs, you may see small images that convey metadata, such as whether or not all the tests are passing for the project. You can use Shields to add some to your README. Many services also have instructions for adding a badge.
## Visuals
Depending on what you are making, it can be a good idea to include screenshots or even a video (you'll frequently see GIFs rather than actual videos). Tools like ttygif can help, but check out Asciinema for a more sophisticated method.
## Installation ## Installation
Within a particular ecosystem, there may be a common way of installing things, such as using Yarn, NuGet, or Homebrew. However, consider the possibility that whoever is reading your README is a novice and would like more guidance. Listing specific steps helps remove ambiguity and gets people to using your project as quickly as possible. If it only runs in a specific context like a particular programming language version or operating system or has dependencies that have to be installed manually, also add a Requirements subsection.
## Usage 1. Clone the repository:
Use examples liberally, and show the expected output if you can. It's helpful to have inline the smallest example of usage that you can demonstrate, while providing links to more sophisticated examples if they are too long to reasonably include in the README. ```bash
git clone https://github.com/yourusername/fact-checker-app.git
cd fact-checker-app
```
## Support 2. Install dependencies:
Tell people where they can go to for help. It can be any combination of an issue tracker, a chat room, an email address, etc. ```bash
npm install
```
## Roadmap 3. Start the development server:
If you have ideas for releases in the future, it is a good idea to list them in the README. ```bash
npx expo start
```
## Development
- Run in development mode:
```bash
npx expo start
```
- Run with specific platform:
```bash
npx expo start --android
```
## Testing
```bash
npm run test
```
## Contributing ## Contributing
State if you are open to contributions and what your requirements are for accepting them.
For people who want to make changes to your project, it's helpful to have some documentation on how to get started. Perhaps there is a script that they should run or some environment variables that they need to set. Make these steps explicit. These instructions could also be useful to your future self. 1. Fork the repository
2. Create your feature branch (`git checkout -b feature/amazing-feature`)
You can also document commands to lint the code or run tests. These steps help to ensure high code quality and reduce the likelihood that the changes inadvertently break something. Having instructions for running tests is especially helpful if it requires external setup, such as starting a Selenium server for testing in a browser. 3. Commit your changes (`git commit -m 'Add some amazing feature'`)
4. Push to the branch (`git push origin feature/amazing-feature`)
## Authors and acknowledgment 5. Open a Pull Request
Show your appreciation to those who have contributed to the project.
## License ## License
For open source projects, say how it is licensed.
## Project status This project is released under Creative Commons CC0 1.0 Universal (CC0 1.0) Public Domain Dedication.
If you have run out of energy or time for your project, put a note at the top of the README saying that development has slowed down or stopped completely. Someone may choose to fork your project or volunteer to step in as a maintainer or owner, allowing your project to keep going. You can also make an explicit request for maintainers.
To the extent possible under law, the author has waived all copyright and related or neighboring rights to this work. This work is published from: [Your Country].
For more information, please visit: https://creativecommons.org/publicdomain/zero/1.0/

View file

@ -1,10 +1,10 @@
{ {
"expo": { "expo": {
"name": "Fact checker", "name": "Fraud Guard",
"slug": "fake-check-bd", "slug": "fake-check-bd",
"version": "1.0.0", "version": "1.0.0",
"orientation": "portrait", "orientation": "portrait",
"icon": "./assets/images/icon.png", "icon": "./assets/images/guard.png",
"scheme": "myapp", "scheme": "myapp",
"userInterfaceStyle": "automatic", "userInterfaceStyle": "automatic",
"newArchEnabled": true, "newArchEnabled": true,
@ -13,7 +13,7 @@
}, },
"android": { "android": {
"adaptiveIcon": { "adaptiveIcon": {
"foregroundImage": "./assets/images/adaptive-icon.png", "foregroundImage": "./assets/images/guard.png",
"backgroundColor": "#ffffff" "backgroundColor": "#ffffff"
}, },
"package": "com.smfahimhossen.android" "package": "com.smfahimhossen.android"
@ -28,7 +28,7 @@
[ [
"expo-splash-screen", "expo-splash-screen",
{ {
"image": "./assets/images/splash-icon.png", "image": "./assets/images/guard.png",
"imageWidth": 200, "imageWidth": 200,
"resizeMode": "contain", "resizeMode": "contain",
"backgroundColor": "#ffffff" "backgroundColor": "#ffffff"

View file

@ -1,6 +1,7 @@
import { Tabs } from 'expo-router'; import { Tabs } from 'expo-router';
import React from 'react'; import React from 'react';
import { Platform } from 'react-native'; import { Platform } from 'react-native';
import { Image } from 'react-native';
import { HapticTab } from '@/components/HapticTab'; import { HapticTab } from '@/components/HapticTab';
import { IconSymbol } from '@/components/ui/IconSymbol'; import { IconSymbol } from '@/components/ui/IconSymbol';
@ -29,17 +30,37 @@ export default function TabLayout() {
<Tabs.Screen <Tabs.Screen
name="index" name="index"
options={{ options={{
title: 'Home', title: 'News',
tabBarIcon: ({ color }) => <IconSymbol size={28} name="house.fill" color={color} />, tabBarIcon: ({ focused }) => (
<Image
source={
focused
? require('@/assets/images/news.png')
: require('@/assets/images/news.png')
}
style={{ width: 40, height: 28 }}
resizeMode="contain"
/>
),
}} }}
/> />
<Tabs.Screen <Tabs.Screen
name="explore" name="explore"
options={{ options={{
title: 'Explore', title: 'Fraud Guard',
tabBarIcon: ({ color }) => <IconSymbol size={28} name="paperplane.fill" color={color} />, tabBarIcon: ({ focused }) => (
}} <Image
/> source={
focused
? require('@/assets/images/tabguard.png')
: require('@/assets/images/tabguard.png')
}
style={{ width: 90, height: 28 }}
resizeMode="contain"
/>
),
}}
/>
</Tabs> </Tabs>
); );
} }

View file

@ -1,109 +1,406 @@
import { StyleSheet, Image, Platform } from 'react-native'; import { WebView } from "react-native-webview";
import { useRef, useState } from "react";
import { Alert, StyleSheet, View } from "react-native";
import { Collapsible } from '@/components/Collapsible'; export default function HomeScreen() {
import { ExternalLink } from '@/components/ExternalLink'; const webviewRef = useRef(null);
import ParallaxScrollView from '@/components/ParallaxScrollView'; const [postData, setPostData] = useState([]);
import { ThemedText } from '@/components/ThemedText'; const [isApiCallInProgress, setIsApiCallInProgress] = useState(false);
import { ThemedView } from '@/components/ThemedView';
import { IconSymbol } from '@/components/ui/IconSymbol'; // Function to call the fact-check API
const checkFacts = async (caption, imageUrl) => {
try {
const response = await fetch('https://factcheck.planpostai.com/check-facts', {
method: 'POST',
headers: {
'Accept': 'application/json',
'Content-Type': 'application/json',
},
body: JSON.stringify({ query: caption, url:imageUrl }),
});
const responseText = await response.text();
console.log('Raw API Response:', responseText);
if (!response.ok) {
throw new Error(`HTTP error! status: ${response.status} - ${responseText}`);
}
const result = JSON.parse(responseText);
let color;
if (result?.verdict === 'True') {
color = "#2E7D32";
} else if (result?.verdict === 'False') {
color = "#D32F2F";
} else {
color = "#F9A825";
}
// Send the result back to WebView to show toast
webviewRef.current?.injectJavaScript(`
(function() {
showToast('${result.evidence.replace(/'/g, "\\'")}', 10000, '${color}');
return true;
})();
`);
return result;
} catch (error) {
console.error('API Error Details:', {
message: error.message,
stack: error.stack,
name: error.name
});
// Show error in WebView
webviewRef.current?.injectJavaScript(`
(function() {
showToast('Error: ${error.message.replace(/'/g, "\\'")}', 5000, true);
return true;
})();
`);
throw error;
}
};
const handleMessage = async (event) => {
try {
const data = JSON.parse(event.nativeEvent.data);
switch (data.type) {
case 'postData':
setPostData(prevData => [...prevData, {
caption: data.caption,
imageUrls: data.imageUrls,
postId: data.postId
}]);
if (isApiCallInProgress) {
return;
}
setIsApiCallInProgress(true);
try {
const result = await checkFacts(data.caption, data.imageUrls[0]);
setIsApiCallInProgress(false);
webviewRef.current?.injectJavaScript(`
(function() {
enableAllButtons();
const button = document.querySelector('button[data-post-id="${data.postId}"]');
if (button) {
button.textContent = 'Processed';
button.style.background="green";
button.style.color="white";
button.style.padding="5px 5px";
button.style.opacity = '0.7';
button.disabled = true;
}
return true;
})();
`);
} catch (error) {
setIsApiCallInProgress(false);
webviewRef.current?.injectJavaScript(`
(function() {
const svgCode=\`<svg width="100" height="35" viewBox="0 0 100 35" fill="none" xmlns="http://www.w3.org/2000/svg">
<rect width="100" height="35" rx="17.5" fill="#F9BF32"/>
<path d="M38.716 14.824C38.372 14.824 38.064 14.892 37.792 15.028C37.528 15.164 37.304 15.36 37.12 15.616C36.936 15.864 36.796 16.168 36.7 16.528C36.612 16.888 36.568 17.292 36.568 17.74C36.568 18.348 36.64 18.868 36.784 19.3C36.936 19.724 37.172 20.048 37.492 20.272C37.812 20.496 38.22 20.608 38.716 20.608C39.068 20.608 39.416 20.568 39.76 20.488C40.112 20.408 40.492 20.296 40.9 20.152V21.676C40.524 21.828 40.152 21.94 39.784 22.012C39.416 22.084 39.004 22.12 38.548 22.12C37.668 22.12 36.94 21.94 36.364 21.58C35.796 21.212 35.376 20.7 35.104 20.044C34.832 19.38 34.696 18.608 34.696 17.728C34.696 17.08 34.784 16.488 34.96 15.952C35.136 15.408 35.392 14.94 35.728 14.548C36.072 14.156 36.492 13.852 36.988 13.636C37.492 13.42 38.068 13.312 38.716 13.312C39.14 13.312 39.564 13.368 39.988 13.48C40.42 13.584 40.832 13.728 41.224 13.912L40.636 15.388C40.316 15.236 39.992 15.104 39.664 14.992C39.344 14.88 39.028 14.824 38.716 14.824ZM44.3646 14.74C44.3646 15.06 44.3526 15.368 44.3286 15.664C44.3126 15.96 44.2966 16.168 44.2806 16.288H44.3766C44.5206 16.064 44.6886 15.884 44.8806 15.748C45.0726 15.604 45.2846 15.5 45.5166 15.436C45.7566 15.364 46.0086 15.328 46.2726 15.328C46.7446 15.328 47.1566 15.412 47.5086 15.58C47.8606 15.748 48.1326 16.008 48.3246 16.36C48.5246 16.712 48.6246 17.168 48.6246 17.728V22H46.8366V18.172C46.8366 17.7 46.7486 17.348 46.5726 17.116C46.4046 16.876 46.1406 16.756 45.7806 16.756C45.4206 16.756 45.1366 16.84 44.9286 17.008C44.7286 17.176 44.5846 17.42 44.4966 17.74C44.4086 18.06 44.3646 18.452 44.3646 18.916V22H42.5766V12.88H44.3646V14.74ZM53.1633 15.328C53.7713 15.328 54.2913 15.444 54.7233 15.676C55.1633 15.908 55.5033 16.244 55.7433 16.684C55.9833 17.124 56.1033 17.664 56.1033 18.304V19.168H51.8793C51.8953 19.672 52.0433 20.068 52.3233 20.356C52.6113 20.644 53.0073 20.788 53.5113 20.788C53.9353 20.788 54.3193 20.748 54.6633 20.668C55.0073 20.58 55.3633 20.448 55.7313 20.272V21.652C55.4113 21.812 55.0713 21.928 54.7113 22C54.3593 22.08 53.9313 22.12 53.4273 22.12C52.7713 22.12 52.1913 22 51.6873 21.76C51.1833 21.512 50.7873 21.14 50.4993 20.644C50.2113 20.148 50.0673 19.524 50.0673 18.772C50.0673 18.004 50.1953 17.368 50.4513 16.864C50.7153 16.352 51.0793 15.968 51.5433 15.712C52.0073 15.456 52.5473 15.328 53.1633 15.328ZM53.1753 16.6C52.8313 16.6 52.5433 16.712 52.3113 16.936C52.0873 17.16 51.9553 17.508 51.9153 17.98H54.4233C54.4233 17.716 54.3753 17.48 54.2793 17.272C54.1913 17.064 54.0553 16.9 53.8713 16.78C53.6873 16.66 53.4553 16.6 53.1753 16.6ZM60.2172 22.12C59.5692 22.12 59.0172 22.004 58.5612 21.772C58.1052 21.532 57.7572 21.164 57.5172 20.668C57.2772 20.172 57.1572 19.536 57.1572 18.76C57.1572 17.96 57.2932 17.308 57.5652 16.804C57.8372 16.3 58.2132 15.928 58.6932 15.688C59.1812 15.448 59.7412 15.328 60.3732 15.328C60.8212 15.328 61.2092 15.372 61.5372 15.46C61.8732 15.548 62.1652 15.652 62.4132 15.772L61.8852 17.152C61.6052 17.04 61.3412 16.948 61.0932 16.876C60.8532 16.804 60.6132 16.768 60.3732 16.768C60.0612 16.768 59.8012 16.844 59.5932 16.996C59.3852 17.14 59.2292 17.36 59.1252 17.656C59.0292 17.944 58.9812 18.308 58.9812 18.748C58.9812 19.18 59.0332 19.54 59.1372 19.828C59.2492 20.108 59.4092 20.32 59.6172 20.464C59.8252 20.6 60.0772 20.668 60.3732 20.668C60.7492 20.668 61.0812 20.62 61.3692 20.524C61.6572 20.42 61.9372 20.28 62.2092 20.104V21.628C61.9372 21.804 61.6492 21.928 61.3452 22C61.0492 22.08 60.6732 22.12 60.2172 22.12ZM65.5053 16.96C65.5053 17.208 65.4933 17.456 65.4693 17.704C65.4533 17.944 65.4333 18.188 65.4093 18.436H65.4333C65.5133 18.324 65.5933 18.212 65.6733 18.1C65.7613 17.988 65.8493 17.876 65.9373 17.764C66.0253 17.652 66.1173 17.544 66.2133 17.44L68.0493 15.448H70.0653L67.4613 18.292L70.2213 22H68.1573L66.2733 19.348L65.5053 19.96V22H63.7173V12.88H65.5053V16.96ZM70.5827 19.516V18.052H73.7267V19.516H70.5827ZM76.8138 15.448V22H75.0258V15.448H76.8138ZM75.9258 12.88C76.1898 12.88 76.4178 12.944 76.6098 13.072C76.8018 13.192 76.8978 13.42 76.8978 13.756C76.8978 14.084 76.8018 14.312 76.6098 14.44C76.4178 14.568 76.1898 14.632 75.9258 14.632C75.6538 14.632 75.4218 14.568 75.2298 14.44C75.0458 14.312 74.9538 14.084 74.9538 13.756C74.9538 13.42 75.0458 13.192 75.2298 13.072C75.4218 12.944 75.6538 12.88 75.9258 12.88ZM82.4021 15.328C83.1061 15.328 83.6701 15.52 84.0941 15.904C84.5181 16.28 84.7301 16.888 84.7301 17.728V22H82.9421V18.172C82.9421 17.7 82.8581 17.348 82.6901 17.116C82.5221 16.876 82.2541 16.756 81.8861 16.756C81.3421 16.756 80.9701 16.944 80.7701 17.32C80.5701 17.688 80.4701 18.22 80.4701 18.916V22H78.6821V15.448H80.0501L80.2901 16.288H80.3861C80.5301 16.064 80.7061 15.884 80.9141 15.748C81.1221 15.604 81.3541 15.5 81.6101 15.436C81.8661 15.364 82.1301 15.328 82.4021 15.328Z" fill="white"/>
<path d="M16.7778 23.4545L12.3333 19.0909L13.9 17.5527L16.7778 20.3673L24.1 13.1782L25.6667 14.7273M19 6L9 10.3636V16.9091C9 22.9636 13.2667 28.6255 19 30C24.7333 28.6255 29 22.9636 29 16.9091V10.3636L19 6Z" fill="white"/>
</svg>
\`;
enableAllButtons();
const button = document.querySelector('button[data-post-id="${data.postId}"]');
if (button) {
button.disabled = false;
button.style.opacity = '1';
button.innerHTML = svgCode;
}
return true;
})();
`);
} finally {
setIsApiCallInProgress(false);
}
break;
case 'error':
console.error(`WebView Error: ${data.message}`);
break;
}
} catch (error) {
console.error('Error handling message:', error);
}
};
const injectedJavaScript = `
(function() {
// Add toast CSS
const style = document.createElement('style');
style.innerHTML = \`
#toast-container {
position: fixed;
top: 50px;
right: 20px;
left: 20px;
z-index: 999999;
display: flex;
flex-direction: column;
gap: 10px;
pointer-events: auto;
}
.toast {
background-color: #1db146;
color: #fff;
font-weight: 800;
padding: 12px 16px;
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
font-size: 16px;
opacity: 1;
position: relative;
width: 90%;
z-index: 99999999999;
transition: opacity 0.5s ease;
}
.toast.fade-out {
opacity: 0;
}
.error-toast {
background-color: #ff4444;
}
\`;
document.head.appendChild(style);
// Function to disable all buttons
window.disableAllButtons = function() {
document.querySelectorAll("button").forEach((btn) => {
btn.disabled = true;
btn.style.opacity = "0.5";
btn.style.cursor = "not-allowed";
});
};
// Function to enable all buttons
window.enableAllButtons = function() {
document.querySelectorAll("button").forEach((btn) => {
if (btn.textContent !== "Processed") {
btn.disabled = false;
btn.style.opacity = "1";
btn.style.cursor = "pointer";
}
});
};
// Toast notification function
window.showToast = function showToast(message, duration, color = '#333') {
// Create the toast element
const toast = document.createElement('div');
toast.textContent = message;
// Apply basic styles
toast.style.position = 'fixed';
toast.style.top = '5px';
toast.style.left = '50%';
toast.style.fontSize="16px";
toast.style.fontWeight="800";
toast.style.transform = 'translateX(-50%)';
toast.style.padding = '10px 20px';
toast.style.color = '#fff';
toast.style.backgroundColor = color; // Dynamic background color
toast.style.borderRadius = '8px';
toast.style.boxShadow = '0 2px 10px rgba(0, 0, 0, 0.3)';
toast.style.zIndex = '9999';
toast.style.opacity = '1';
toast.style.transition = 'opacity 0.5s ease-in-out';
toast.style.width = '85%';
// Add toast to the DOM
document.body.appendChild(toast);
// Auto-remove the toast after the specified duration
setTimeout(() => {
toast.style.opacity = '0'; // Fade out
setTimeout(() => {
document.body.removeChild(toast); // Remove from DOM
}, 500); // Match fade-out duration
}, duration);
};
// Function to handle "See More" click
async function handleSeeMoreClick(seeMoreElement, post, button, initialCaption, initialImageURLs, postId) {
return new Promise((resolve) => {
setTimeout(() => {
seeMoreElement.click();
setTimeout(() => {
const captionElement = post.querySelector(
"div.m div.m div[data-type='text'] div.native-text"
);
fullCaption = captionElement ? captionElement.textContent.trim() : initialCaption;
// Send data to React Native
window.ReactNativeWebView.postMessage(JSON.stringify({
type: 'postData',
caption: fullCaption,
imageUrls: initialImageURLs,
postId
}));
resolve();
}, 2000);
}, 100);
});
}
// Function to collect post data immediately
function collectDataImmediately(post, button, initialCaption, initialImageURLs, postId) {
const captionElement = post.querySelector(
"div.m div.m div[data-type='text'] div.native-text"
);
const caption = captionElement ? captionElement.textContent.trim() : initialCaption;
// Send data to React Native
window.ReactNativeWebView.postMessage(JSON.stringify({
type: 'postData',
caption,
imageUrls: initialImageURLs,
postId
}));
}
const svgCode=\`<svg width="100" height="35" viewBox="0 0 100 35" fill="none" xmlns="http://www.w3.org/2000/svg">
<rect width="100" height="35" rx="17.5" fill="#F9BF32"/>
<path d="M38.716 14.824C38.372 14.824 38.064 14.892 37.792 15.028C37.528 15.164 37.304 15.36 37.12 15.616C36.936 15.864 36.796 16.168 36.7 16.528C36.612 16.888 36.568 17.292 36.568 17.74C36.568 18.348 36.64 18.868 36.784 19.3C36.936 19.724 37.172 20.048 37.492 20.272C37.812 20.496 38.22 20.608 38.716 20.608C39.068 20.608 39.416 20.568 39.76 20.488C40.112 20.408 40.492 20.296 40.9 20.152V21.676C40.524 21.828 40.152 21.94 39.784 22.012C39.416 22.084 39.004 22.12 38.548 22.12C37.668 22.12 36.94 21.94 36.364 21.58C35.796 21.212 35.376 20.7 35.104 20.044C34.832 19.38 34.696 18.608 34.696 17.728C34.696 17.08 34.784 16.488 34.96 15.952C35.136 15.408 35.392 14.94 35.728 14.548C36.072 14.156 36.492 13.852 36.988 13.636C37.492 13.42 38.068 13.312 38.716 13.312C39.14 13.312 39.564 13.368 39.988 13.48C40.42 13.584 40.832 13.728 41.224 13.912L40.636 15.388C40.316 15.236 39.992 15.104 39.664 14.992C39.344 14.88 39.028 14.824 38.716 14.824ZM44.3646 14.74C44.3646 15.06 44.3526 15.368 44.3286 15.664C44.3126 15.96 44.2966 16.168 44.2806 16.288H44.3766C44.5206 16.064 44.6886 15.884 44.8806 15.748C45.0726 15.604 45.2846 15.5 45.5166 15.436C45.7566 15.364 46.0086 15.328 46.2726 15.328C46.7446 15.328 47.1566 15.412 47.5086 15.58C47.8606 15.748 48.1326 16.008 48.3246 16.36C48.5246 16.712 48.6246 17.168 48.6246 17.728V22H46.8366V18.172C46.8366 17.7 46.7486 17.348 46.5726 17.116C46.4046 16.876 46.1406 16.756 45.7806 16.756C45.4206 16.756 45.1366 16.84 44.9286 17.008C44.7286 17.176 44.5846 17.42 44.4966 17.74C44.4086 18.06 44.3646 18.452 44.3646 18.916V22H42.5766V12.88H44.3646V14.74ZM53.1633 15.328C53.7713 15.328 54.2913 15.444 54.7233 15.676C55.1633 15.908 55.5033 16.244 55.7433 16.684C55.9833 17.124 56.1033 17.664 56.1033 18.304V19.168H51.8793C51.8953 19.672 52.0433 20.068 52.3233 20.356C52.6113 20.644 53.0073 20.788 53.5113 20.788C53.9353 20.788 54.3193 20.748 54.6633 20.668C55.0073 20.58 55.3633 20.448 55.7313 20.272V21.652C55.4113 21.812 55.0713 21.928 54.7113 22C54.3593 22.08 53.9313 22.12 53.4273 22.12C52.7713 22.12 52.1913 22 51.6873 21.76C51.1833 21.512 50.7873 21.14 50.4993 20.644C50.2113 20.148 50.0673 19.524 50.0673 18.772C50.0673 18.004 50.1953 17.368 50.4513 16.864C50.7153 16.352 51.0793 15.968 51.5433 15.712C52.0073 15.456 52.5473 15.328 53.1633 15.328ZM53.1753 16.6C52.8313 16.6 52.5433 16.712 52.3113 16.936C52.0873 17.16 51.9553 17.508 51.9153 17.98H54.4233C54.4233 17.716 54.3753 17.48 54.2793 17.272C54.1913 17.064 54.0553 16.9 53.8713 16.78C53.6873 16.66 53.4553 16.6 53.1753 16.6ZM60.2172 22.12C59.5692 22.12 59.0172 22.004 58.5612 21.772C58.1052 21.532 57.7572 21.164 57.5172 20.668C57.2772 20.172 57.1572 19.536 57.1572 18.76C57.1572 17.96 57.2932 17.308 57.5652 16.804C57.8372 16.3 58.2132 15.928 58.6932 15.688C59.1812 15.448 59.7412 15.328 60.3732 15.328C60.8212 15.328 61.2092 15.372 61.5372 15.46C61.8732 15.548 62.1652 15.652 62.4132 15.772L61.8852 17.152C61.6052 17.04 61.3412 16.948 61.0932 16.876C60.8532 16.804 60.6132 16.768 60.3732 16.768C60.0612 16.768 59.8012 16.844 59.5932 16.996C59.3852 17.14 59.2292 17.36 59.1252 17.656C59.0292 17.944 58.9812 18.308 58.9812 18.748C58.9812 19.18 59.0332 19.54 59.1372 19.828C59.2492 20.108 59.4092 20.32 59.6172 20.464C59.8252 20.6 60.0772 20.668 60.3732 20.668C60.7492 20.668 61.0812 20.62 61.3692 20.524C61.6572 20.42 61.9372 20.28 62.2092 20.104V21.628C61.9372 21.804 61.6492 21.928 61.3452 22C61.0492 22.08 60.6732 22.12 60.2172 22.12ZM65.5053 16.96C65.5053 17.208 65.4933 17.456 65.4693 17.704C65.4533 17.944 65.4333 18.188 65.4093 18.436H65.4333C65.5133 18.324 65.5933 18.212 65.6733 18.1C65.7613 17.988 65.8493 17.876 65.9373 17.764C66.0253 17.652 66.1173 17.544 66.2133 17.44L68.0493 15.448H70.0653L67.4613 18.292L70.2213 22H68.1573L66.2733 19.348L65.5053 19.96V22H63.7173V12.88H65.5053V16.96ZM70.5827 19.516V18.052H73.7267V19.516H70.5827ZM76.8138 15.448V22H75.0258V15.448H76.8138ZM75.9258 12.88C76.1898 12.88 76.4178 12.944 76.6098 13.072C76.8018 13.192 76.8978 13.42 76.8978 13.756C76.8978 14.084 76.8018 14.312 76.6098 14.44C76.4178 14.568 76.1898 14.632 75.9258 14.632C75.6538 14.632 75.4218 14.568 75.2298 14.44C75.0458 14.312 74.9538 14.084 74.9538 13.756C74.9538 13.42 75.0458 13.192 75.2298 13.072C75.4218 12.944 75.6538 12.88 75.9258 12.88ZM82.4021 15.328C83.1061 15.328 83.6701 15.52 84.0941 15.904C84.5181 16.28 84.7301 16.888 84.7301 17.728V22H82.9421V18.172C82.9421 17.7 82.8581 17.348 82.6901 17.116C82.5221 16.876 82.2541 16.756 81.8861 16.756C81.3421 16.756 80.9701 16.944 80.7701 17.32C80.5701 17.688 80.4701 18.22 80.4701 18.916V22H78.6821V15.448H80.0501L80.2901 16.288H80.3861C80.5301 16.064 80.7061 15.884 80.9141 15.748C81.1221 15.604 81.3541 15.5 81.6101 15.436C81.8661 15.364 82.1301 15.328 82.4021 15.328Z" fill="white"/>
<path d="M16.7778 23.4545L12.3333 19.0909L13.9 17.5527L16.7778 20.3673L24.1 13.1782L25.6667 14.7273M19 6L9 10.3636V16.9091C9 22.9636 13.2667 28.6255 19 30C24.7333 28.6255 29 22.9636 29 16.9091V10.3636L19 6Z" fill="white"/>
</svg>
\`
// Function to collect post data and send to React Native
function collectPostData(post) {
if (post.dataset.processed === "true") return;
// Get the caption
const captionElement = post.querySelector(
"div.m div.m div[data-type='text'] div.native-text"
);
const caption = captionElement ? captionElement.textContent.trim() : null;
// Get the first image (if exists)
const singleImageElement = post.querySelector("div.m.bg-s13 img");
const singleImageURL = singleImageElement && singleImageElement.src ? singleImageElement.src : null;
// Collect all image elements
const imageElements = post.querySelectorAll("div.m.bg-s13 img");
const imageURLs = Array.from(imageElements)
.filter(img => img.src)
.map(img => img.src);
post.dataset.processed = "true";
// Prioritize using a single image if only one exists, otherwise use all images
let imagesToUse = [];
if (singleImageURL) {
imagesToUse = [singleImageURL];
} else if (imageURLs.length > 0) {
imagesToUse = imageURLs;
}
// Create button if there's a caption or at least one image
if ((caption && caption.length > 50) || imagesToUse.length > 0) {
const postId = 'post_' + Math.random().toString(36).substr(2, 9);
createButton(post, caption, imagesToUse, postId);
}
}
// Create check button
function createButton(post, caption, imageURLs, postId) {
post.style.position = "relative";
const button = document.createElement("button");
button.textContent = "Check";
button.setAttribute('data-post-id', postId);
button.innerHTML=svgCode
Object.assign(button.style, {
position: "absolute",
right: "5px",
top: "-34px",
border: "none",
borderRadius: "8px",
cursor: "pointer",
zIndex: 9999,
pointerEvents: "auto",
transition: "all 0.3s",
});
button.addEventListener("click", async () => {
disableAllButtons();
button.textContent = "Processing";
button.style.opacity = "0.5";
button.style.color="white";
button.style.padding="5px 5px";
button.style.background="blue";
collectDataImmediately(post, button, caption, imageURLs, postId);
});
post.appendChild(button);
}
// Mutation observer to handle new posts
function handleMutations(mutationsList) {
mutationsList.forEach((mutation) => {
if (mutation.type === "childList" || mutation.type === "subtree") {
document.querySelectorAll("div.m.bg-s3").forEach((post) => {
if (!post.querySelector("button")) {
collectPostData(post);
}
});
}
});
}
const observer = new MutationObserver(handleMutations);
observer.observe(document.querySelector(".m"), {
childList: true,
subtree: true,
});
document.addEventListener("DOMContentLoaded", () => {
document.querySelectorAll("div.m.displayed.bg-s3").forEach((post) => {
if (!post.dataset.processed) {
collectPostData(post);
}
});
});
return true;
})();
`;
export default function TabTwoScreen() {
return ( return (
<ParallaxScrollView <View style={styles.container}>
headerBackgroundColor={{ light: '#D0D0D0', dark: '#353636' }} <WebView
headerImage={ ref={webviewRef}
<IconSymbol source={{ uri: "https://www.facebook.com" }}
size={310} injectedJavaScript={injectedJavaScript}
color="#808080" startInLoadingState={true}
name="chevron.left.forwardslash.chevron.right" onMessage={handleMessage}
style={styles.headerImage} webviewDebuggingEnabled={__DEV__}
/> />
}> </View>
<ThemedView style={styles.titleContainer}>
<ThemedText type="title">Explore</ThemedText>
</ThemedView>
<ThemedText>This app includes example code to help you get started.</ThemedText>
<Collapsible title="File-based routing">
<ThemedText>
This app has two screens:{' '}
<ThemedText type="defaultSemiBold">app/(tabs)/index.tsx</ThemedText> and{' '}
<ThemedText type="defaultSemiBold">app/(tabs)/explore.tsx</ThemedText>
</ThemedText>
<ThemedText>
The layout file in <ThemedText type="defaultSemiBold">app/(tabs)/_layout.tsx</ThemedText>{' '}
sets up the tab navigator.
</ThemedText>
<ExternalLink href="https://docs.expo.dev/router/introduction">
<ThemedText type="link">Learn more</ThemedText>
</ExternalLink>
</Collapsible>
<Collapsible title="Android, iOS, and web support">
<ThemedText>
You can open this project on Android, iOS, and the web. To open the web version, press{' '}
<ThemedText type="defaultSemiBold">w</ThemedText> in the terminal running this project.
</ThemedText>
</Collapsible>
<Collapsible title="Images">
<ThemedText>
For static images, you can use the <ThemedText type="defaultSemiBold">@2x</ThemedText> and{' '}
<ThemedText type="defaultSemiBold">@3x</ThemedText> suffixes to provide files for
different screen densities
</ThemedText>
<Image source={require('@/assets/images/react-logo.png')} style={{ alignSelf: 'center' }} />
<ExternalLink href="https://reactnative.dev/docs/images">
<ThemedText type="link">Learn more</ThemedText>
</ExternalLink>
</Collapsible>
<Collapsible title="Custom fonts">
<ThemedText>
Open <ThemedText type="defaultSemiBold">app/_layout.tsx</ThemedText> to see how to load{' '}
<ThemedText style={{ fontFamily: 'SpaceMono' }}>
custom fonts such as this one.
</ThemedText>
</ThemedText>
<ExternalLink href="https://docs.expo.dev/versions/latest/sdk/font">
<ThemedText type="link">Learn more</ThemedText>
</ExternalLink>
</Collapsible>
<Collapsible title="Light and dark mode components">
<ThemedText>
This template has light and dark mode support. The{' '}
<ThemedText type="defaultSemiBold">useColorScheme()</ThemedText> hook lets you inspect
what the user's current color scheme is, and so you can adjust UI colors accordingly.
</ThemedText>
<ExternalLink href="https://docs.expo.dev/develop/user-interface/color-themes/">
<ThemedText type="link">Learn more</ThemedText>
</ExternalLink>
</Collapsible>
<Collapsible title="Animations">
<ThemedText>
This template includes an example of an animated component. The{' '}
<ThemedText type="defaultSemiBold">components/HelloWave.tsx</ThemedText> component uses
the powerful <ThemedText type="defaultSemiBold">react-native-reanimated</ThemedText>{' '}
library to create a waving hand animation.
</ThemedText>
{Platform.select({
ios: (
<ThemedText>
The <ThemedText type="defaultSemiBold">components/ParallaxScrollView.tsx</ThemedText>{' '}
component provides a parallax effect for the header image.
</ThemedText>
),
})}
</Collapsible>
</ParallaxScrollView>
); );
} }
const styles = StyleSheet.create({ const styles = StyleSheet.create({
headerImage: { container: {
color: '#808080', flex: 1,
bottom: -90, marginTop: 20,
left: -35,
position: 'absolute',
},
titleContainer: {
flexDirection: 'row',
gap: 8,
}, },
}); });

File diff suppressed because it is too large Load diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

BIN
assets/images/gp.jpeg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

BIN
assets/images/guard.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

BIN
assets/images/guard.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

BIN
assets/images/news.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 170 KiB

BIN
assets/images/news_logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 687 KiB

BIN
assets/images/tabguard.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB