ericjedha commited on
Commit
119a494
·
verified ·
1 Parent(s): 7bd726e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +37 -44
app.py CHANGED
@@ -23,74 +23,67 @@ theme = gr.themes.Soft(
23
  )
24
 
25
  css = """
26
- #warning {background-color: #FFCCCB}
 
 
 
 
 
 
 
 
27
 
28
- /* Surbrillance pour "Malin" (rouge #F54927) */
29
  .highlight.malin {
30
  background-color: #F54927;
31
  color: white;
32
- font-weight: bold;
33
- padding: 10px 6px;
34
  border-radius: 4px;
35
- font-size:24px;
 
 
36
  }
37
- #.highlight.malin h2.output-class {
38
- # font-size: 24px !important; /* Cible le <h2> à l'intérieur du span */
39
- #}
40
 
41
- /* Surbrillance pour "Bénin" (vert #34EA3A) */
42
  .highlight.benin {
43
  background-color: #34EA3A;
44
  color: black;
45
- font-weight: bold;
46
- padding: 3px 6px;
47
  border-radius: 4px;
48
- font-size:24px;
49
- }
50
- #.highlight.benin h2.output-class {
51
- # font-size: 24px !important; /* Optionnel : si tu veux aussi appliquer à "Bénin" */
52
- #}
53
-
54
- /* Style pour le Diagnostic global */
55
- .diagnostic-global h2.output-class {
56
- font-size: 24px !important;
57
- }
58
-
59
- #warning {background-color: #FFCCCB}
60
-
61
- /* Conteneur pour l'explication */
62
- .feedback-container {
63
- background-color: #f9f9f9;
64
- border-radius: 5px;
65
- padding: 10px;
66
- margin-bottom: 15px;
67
- border: 1px solid #e0e0e0;
68
- }
69
-
70
- /* Style pour le texte d'explication */
71
- .feedback-text {
72
- font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
73
- font-size: 16px;
74
- line-height: 1.5;
75
- margin-bottom: 10px;
76
  }
77
 
78
- /* Style pour la div d'avertissement */
79
  .warning-message {
80
  background-color: #e9d5ff;
81
  border-radius: 3px;
82
- padding: 10px;
83
- margin-top: 10px;
84
  border: 1px solid #d4b5ff;
85
- font-size: 16px;
86
- color: #333;
87
  }
88
 
 
 
 
 
 
 
 
 
89
 
 
 
 
 
 
 
90
  """
91
 
92
 
93
 
 
94
  # Désactiver GPU et logs TensorFlow
95
  os.environ['CUDA_VISIBLE_DEVICES'] = '-1'
96
  os.environ['TF_CPP_MIN_LOG_LEVEL'] = '2'
 
23
  )
24
 
25
  css = """
26
+ /* Police lisible et compatible */
27
+ body {
28
+ font-family: Arial, sans-serif !important;
29
+ }
30
+
31
+ /* Conteneur du diagnostic global */
32
+ .diagnostic-global {
33
+ margin-bottom: 15px;
34
+ }
35
 
36
+ /* Style pour les badges Malin/Bénin */
37
  .highlight.malin {
38
  background-color: #F54927;
39
  color: white;
40
+ padding: 4px 8px;
 
41
  border-radius: 4px;
42
+ display: inline-block;
43
+ font-weight: bold;
44
+ margin: 5px 0;
45
  }
 
 
 
46
 
 
47
  .highlight.benin {
48
  background-color: #34EA3A;
49
  color: black;
50
+ padding: 4px 8px;
 
51
  border-radius: 4px;
52
+ display: inline-block;
53
+ font-weight: bold;
54
+ margin: 5px 0;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
55
  }
56
 
57
+ /* Message d'avertissement (version mobile-friendly) */
58
  .warning-message {
59
  background-color: #e9d5ff;
60
  border-radius: 3px;
61
+ padding: 8px;
62
+ margin: 10px 0;
63
  border: 1px solid #d4b5ff;
64
+ font-size: 14px;
 
65
  }
66
 
67
+ /* Pour les images dans le diagnostic */
68
+ .diagnostic-global img {
69
+ max-width: 100%;
70
+ height: auto;
71
+ float: left;
72
+ margin-right: 10px;
73
+ margin-bottom: 10px;
74
+ }
75
 
76
+ /* Clearfix pour les flottants */
77
+ .clearfix::after {
78
+ content: "";
79
+ display: table;
80
+ clear: both;
81
+ }
82
  """
83
 
84
 
85
 
86
+
87
  # Désactiver GPU et logs TensorFlow
88
  os.environ['CUDA_VISIBLE_DEVICES'] = '-1'
89
  os.environ['TF_CPP_MIN_LOG_LEVEL'] = '2'