M17idd commited on
Commit
6638946
·
verified ·
1 Parent(s): f6d5a02

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +15 -14
app.py CHANGED
@@ -69,16 +69,16 @@ demo = gr.Interface(
69
  gr.Slider(0.1, 1.5, value=0.7, step=0.1, label="🔥 دمای خلاقیت (temperature)", elem_id="slider-2"),
70
  gr.Slider(0.1, 1.0, value=0.95, step=0.05, label="🎯 Top-p", elem_id="slider-3"),
71
  ],
72
- outputs=[
73
  gr.Textbox(label="📄 گزارش رسمی تولید شده", lines=10, elem_id="military-output"),
74
- gr.File(label=" دانلود گزارش", elem_id="download-btn")
75
  ],
76
  title="🛰️ سامانه گزارش‌ساز هوش مصنوعی «توانا»",
77
  description="🔰 اطلاعات خام عملیات را وارد کن تا سامانه توانا یک گزارش رسمی، حرفه‌ای و محرمانه تولید کند.",
78
  css="""
79
  body {
80
- background-color: #d9dec5 !important;
81
- color: #1e293b !important;
82
  font-family: 'Vazir', sans-serif;
83
  direction: rtl;
84
  }
@@ -87,16 +87,16 @@ demo = gr.Interface(
87
  }
88
  label {
89
  font-size: 22px !important;
90
- color: #eeeeee !important;
91
  font-weight: bold;
92
  }
93
  #military-input textarea, #military-output textarea {
94
  background-color: #d9dec5 !important;
95
  color: #1e293b !important;
96
- border: 2px solid #529b39 !important;
97
  }
98
  .gr-button {
99
- background-color: #529b39 !important;
100
  color: #eeeeee !important;
101
  border-radius: 12px;
102
  font-size: 18px;
@@ -104,26 +104,26 @@ demo = gr.Interface(
104
  transition: all 0.3s ease;
105
  }
106
  .gr-button:hover {
107
- background-color: #45a12d !important;
108
  transform: scale(1.05);
109
  }
110
  .gr-button:active {
111
- background-color: #3b8e27 !important;
112
  }
113
  .gr-button[type="submit"] {
114
- background-color: #529b39 !important;
115
  }
116
  .gr-button[type="reset"] {
117
- background-color: #ff7043 !important;
118
  }
119
  .gradio-footer {
120
  display: none !important;
121
  }
122
 
123
  .gr-textbox input[type="text"], .gr-textbox textarea {
124
- background-color: #1e293b !important;
125
- color: #eeeeee !important;
126
- border: 2px solid #529b39 !important;
127
  font-size: 16px;
128
  }
129
  .gr-textbox input[type="text"]:focus, .gr-textbox textarea:focus {
@@ -134,6 +134,7 @@ demo = gr.Interface(
134
  submit_btn="🎯 تولید گزارش",
135
  clear_btn="🗑️ پاک کردن"
136
  )
 
137
  demo.launch()
138
 
139
  if __name__ == "__main__":
 
69
  gr.Slider(0.1, 1.5, value=0.7, step=0.1, label="🔥 دمای خلاقیت (temperature)", elem_id="slider-2"),
70
  gr.Slider(0.1, 1.0, value=0.95, step=0.05, label="🎯 Top-p", elem_id="slider-3"),
71
  ],
72
+ outputs=[
73
  gr.Textbox(label="📄 گزارش رسمی تولید شده", lines=10, elem_id="military-output"),
74
+ gr.File(label=" دانلود گزارش", elem_id="download-btn") # اضافه کردن دکمه دانلود
75
  ],
76
  title="🛰️ سامانه گزارش‌ساز هوش مصنوعی «توانا»",
77
  description="🔰 اطلاعات خام عملیات را وارد کن تا سامانه توانا یک گزارش رسمی، حرفه‌ای و محرمانه تولید کند.",
78
  css="""
79
  body {
80
+ background-color: #d9dec5 !important; /* رنگ بک‌گراند جدید */
81
+ color: #1e293b !important; /* رنگ متن جدید */
82
  font-family: 'Vazir', sans-serif;
83
  direction: rtl;
84
  }
 
87
  }
88
  label {
89
  font-size: 22px !important;
90
+ color: #eeeeee !important; /* رنگ سفید برای برچسب‌ها */
91
  font-weight: bold;
92
  }
93
  #military-input textarea, #military-output textarea {
94
  background-color: #d9dec5 !important;
95
  color: #1e293b !important;
96
+ border: 2px solid #529b39 !important; /* رنگ جدید برای مرز */
97
  }
98
  .gr-button {
99
+ background-color: #529b39 !important; /* رنگ دکمه‌ها */
100
  color: #eeeeee !important;
101
  border-radius: 12px;
102
  font-size: 18px;
 
104
  transition: all 0.3s ease;
105
  }
106
  .gr-button:hover {
107
+ background-color: #45a12d !important; /* تغییر رنگ به هنگام hover */
108
  transform: scale(1.05);
109
  }
110
  .gr-button:active {
111
+ background-color: #3b8e27 !important; /* رنگ جدید هنگام کلیک */
112
  }
113
  .gr-button[type="submit"] {
114
+ background-color: #529b39 !important; /* رنگ دکمه "تولید گزارش" */
115
  }
116
  .gr-button[type="reset"] {
117
+ background-color: #ff7043 !important; /* رنگ دکمه "پاک کردن" */
118
  }
119
  .gradio-footer {
120
  display: none !important;
121
  }
122
 
123
  .gr-textbox input[type="text"], .gr-textbox textarea {
124
+ background-color: #1e293b !important; /* رنگ پس‌زمینه ورودی‌ها */
125
+ color: #eeeeee !important; /* رنگ متن ورودی‌ها */
126
+ border: 2px solid #529b39 !important; /* رنگ مرز ورودی‌ها */
127
  font-size: 16px;
128
  }
129
  .gr-textbox input[type="text"]:focus, .gr-textbox textarea:focus {
 
134
  submit_btn="🎯 تولید گزارش",
135
  clear_btn="🗑️ پاک کردن"
136
  )
137
+
138
  demo.launch()
139
 
140
  if __name__ == "__main__":