Spaces:
Sleeping
Sleeping
File size: 1,571 Bytes
bc1666b 3aa83be bc1666b 3aa83be 3ceecc5 bc1666b |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 |
# app.py
import streamlit as st
from streamlit_option_menu import option_menu
from utils.functions import get_phone_info, simple_checks, analyze_message, init_stats_file, update_stats
import os
# Inicjalizacja pliku statystyk
init_stats_file()
# Konfiguracja strony
st.set_page_config(page_title="📱 Detektor Fałszywych Wiadomości SMS", page_icon="📱", layout="wide")
# Tworzenie poziomego menu
selected = option_menu(
menu_title=None, # Brak tytułu menu
options=["Analiza SMS", "O Projekcie", "Edukacja", "Statystyki", "Kontakt"],
icons=["house", "info-circle", "book", "bar-chart", "envelope"],
menu_icon="cast",
default_index=0,
orientation="horizontal",
styles={
"container": {"padding": "0!important", "background-color": "#fafafa"},
"icon": {"color": "black", "font-size": "18px"},
"nav-link": {"font-size": "16px", "text-align": "left", "margin":"0px", "--hover-color": "#eee"},
"nav-link-selected": {"background-color": "#02ab21"},
}
)
# Importowanie modułów dla każdej zakładki
if selected == "Analiza SMS":
from pages.Analysis import show_analysis
show_analysis()
elif selected == "O Projekcie":
from pages.About import main as show_about
show_about()
elif selected == "Edukacja":
from pages.Education import main as show_education
show_education()
elif selected == "Statystyki":
from pages.Statistics import main as show_statistics
show_statistics()
elif selected == "Kontakt":
from pages.Contact import main as show_contact
show_contact() |