mirror of
https://github.com/onionshare/onionshare.git
synced 2025-01-24 13:41:14 -05:00
Adds color palette in History Tab with Dark Mode
This commit is contained in:
parent
b6315c6bcf
commit
251012f559
@ -87,6 +87,10 @@ class GuiCommon:
|
|||||||
new_tab_button_background = "#ffffff"
|
new_tab_button_background = "#ffffff"
|
||||||
new_tab_button_border = "#efeff0"
|
new_tab_button_border = "#efeff0"
|
||||||
new_tab_button_text_color = "#4e0d4e"
|
new_tab_button_text_color = "#4e0d4e"
|
||||||
|
downloads_uploads_progress_bar_border_color = "#4E064F"
|
||||||
|
downloads_uploads_progress_bar_chunk_color = "#4E064F"
|
||||||
|
share_zip_progess_bar_border_color = "#4E064F"
|
||||||
|
share_zip_progess_bar_chunk_color = "#4E064F"
|
||||||
if color_mode == "dark":
|
if color_mode == "dark":
|
||||||
header_color = "#F2F2F2"
|
header_color = "#F2F2F2"
|
||||||
title_color = "#F2F2F2"
|
title_color = "#F2F2F2"
|
||||||
@ -94,6 +98,7 @@ class GuiCommon:
|
|||||||
new_tab_button_background = "#5F5F5F"
|
new_tab_button_background = "#5F5F5F"
|
||||||
new_tab_button_border = "#878787"
|
new_tab_button_border = "#878787"
|
||||||
new_tab_button_text_color = "#FFFFFF"
|
new_tab_button_text_color = "#FFFFFF"
|
||||||
|
share_zip_progess_bar_border_color = "#F2F2F2"
|
||||||
|
|
||||||
return {
|
return {
|
||||||
# OnionShareGui styles
|
# OnionShareGui styles
|
||||||
@ -233,7 +238,7 @@ class GuiCommon:
|
|||||||
"downloads_uploads_progress_bar": """
|
"downloads_uploads_progress_bar": """
|
||||||
QProgressBar {
|
QProgressBar {
|
||||||
border: 1px solid """
|
border: 1px solid """
|
||||||
+ header_color
|
+ downloads_uploads_progress_bar_border_color
|
||||||
+ """;
|
+ """;
|
||||||
background-color: #ffffff !important;
|
background-color: #ffffff !important;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
@ -242,10 +247,14 @@ class GuiCommon:
|
|||||||
}
|
}
|
||||||
QProgressBar::chunk {
|
QProgressBar::chunk {
|
||||||
background-color: """
|
background-color: """
|
||||||
+ header_color
|
+ downloads_uploads_progress_bar_chunk_color
|
||||||
+ """;
|
+ """;
|
||||||
width: 10px;
|
width: 10px;
|
||||||
}""",
|
}""",
|
||||||
|
"history_default_label" : """
|
||||||
|
QLabel {
|
||||||
|
color: black;
|
||||||
|
}""",
|
||||||
"history_individual_file_timestamp_label": """
|
"history_individual_file_timestamp_label": """
|
||||||
QLabel {
|
QLabel {
|
||||||
color: #666666;
|
color: #666666;
|
||||||
@ -298,7 +307,7 @@ class GuiCommon:
|
|||||||
"share_zip_progess_bar": """
|
"share_zip_progess_bar": """
|
||||||
QProgressBar {
|
QProgressBar {
|
||||||
border: 1px solid """
|
border: 1px solid """
|
||||||
+ header_color
|
+ share_zip_progess_bar_border_color
|
||||||
+ """;
|
+ """;
|
||||||
background-color: #ffffff !important;
|
background-color: #ffffff !important;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
@ -307,7 +316,7 @@ class GuiCommon:
|
|||||||
QProgressBar::chunk {
|
QProgressBar::chunk {
|
||||||
border: 0px;
|
border: 0px;
|
||||||
background-color: """
|
background-color: """
|
||||||
+ header_color
|
+ share_zip_progess_bar_chunk_color
|
||||||
+ """;
|
+ """;
|
||||||
width: 10px;
|
width: 10px;
|
||||||
}""",
|
}""",
|
||||||
|
@ -148,6 +148,7 @@ class ShareHistoryItem(HistoryItem):
|
|||||||
|
|
||||||
# Change the label
|
# Change the label
|
||||||
self.label.setText(self.get_finished_label_text(self.started_dt))
|
self.label.setText(self.get_finished_label_text(self.started_dt))
|
||||||
|
self.label.setStyleSheet(self.common.gui.css["history_default_label"])
|
||||||
self.status = HistoryItem.STATUS_FINISHED
|
self.status = HistoryItem.STATUS_FINISHED
|
||||||
|
|
||||||
else:
|
else:
|
||||||
@ -439,6 +440,7 @@ class ReceiveHistoryItem(HistoryItem):
|
|||||||
|
|
||||||
# Change the label
|
# Change the label
|
||||||
self.label.setText(self.get_finished_label_text(self.started))
|
self.label.setText(self.get_finished_label_text(self.started))
|
||||||
|
self.label.setStyleSheet(self.common.gui.css["history_default_label"])
|
||||||
|
|
||||||
elif data["action"] == "canceled":
|
elif data["action"] == "canceled":
|
||||||
# Change the status
|
# Change the status
|
||||||
@ -479,6 +481,7 @@ class IndividualFileHistoryItem(HistoryItem):
|
|||||||
self.common.gui.css["history_individual_file_timestamp_label"]
|
self.common.gui.css["history_individual_file_timestamp_label"]
|
||||||
)
|
)
|
||||||
self.path_label = QtWidgets.QLabel(self.path)
|
self.path_label = QtWidgets.QLabel(self.path)
|
||||||
|
self.path_label.setStyleSheet(self.common.gui.css["history_default_label"])
|
||||||
self.status_code_label = QtWidgets.QLabel()
|
self.status_code_label = QtWidgets.QLabel()
|
||||||
|
|
||||||
# Progress bar
|
# Progress bar
|
||||||
|
Loading…
Reference in New Issue
Block a user