-
Notifications
You must be signed in to change notification settings - Fork 4
/
styles.py
147 lines (111 loc) · 4.49 KB
/
styles.py
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
import Charts
tabs_styles = {
'height': '44px',
'width': '50%'
}
tab_style = {
'borderBottom': '1px solid #d6d6d6',
'padding': '6px',
'fontWeight': 'bold'
}
tab_selected_style = {'border-top': '3px solid #445262'}
graph_content_style={'display': 'block', 'padding': '10px'}
graph_style = {'height': '50vh'
}
single_study_graph_style = {'width': '100%', 'height': '80vh'}
graph_editor_container = {'width': '100%',
'display': 'flex',
'justify-content': 'center',
'flex-wrap': 'wrap',
'margin-top': '1.5em'
}
defaultEditorLabel = {'display': 'block',
'font-weight': 'bold',
'padding': '10px 10px 10px 10px'}
disabledStyle = {
'display': 'none'
}
tableStyle = {'float': 'left',
'width': '100%',
'margin-top': '1em'}
tableStyle_next_to_plot = {'float': 'left',
'width': '30%',
'margin-top': '2em'
}
perItemTableStyle = {
'max-width': '100%',
'margin-right': '30px'}
mainPageSummaryHeaderStyle = {
'font-size': '1.2em',
'font-weight': 'bold',
'color': 'white'
}
mainPageSummaryParagraph = {'width':'75%', 'margin-left': 'auto', 'margin-right':'auto'}
editorInfoTextStyle = {'font-weight': 'normal',
'font-size': 'small'}
download_div_style_mainplot = {'display': 'block',
'float': 'left',
'padding': '10px 10px 10px 10px'
}
download_div_style = {'display': 'block',
'padding': '10px 10px 10px 10px'
}
graph_style_per_item = {
'float': 'left',
'width': '60%',
'height': '50vh'
}
graph_div_style = {'margin-left': 'auto',
'margin-right': 'auto',
}
graph_div_style_with_table = {'width': '70%',
'float': 'left'}
graph_div_style_per_item = {'max-width': '100%',
'float': 'right'}
graph_div_style_with_table_row = {'max-width': '100%',
'display': 'flex',
'justify-content': 'center'}
main_content_style = {'width': '70%',
'display':'inline-block',
'float': 'left'
}
single_study_main_content_style = {
'width': '70%'}
per_item_main_content_style = {'display': 'block',
'width': '70%'}
mainPageDownloadPanelStyle = {
'align-items': 'center',
'height': '10em',
'borderWidth': '1px',
'borderStyle': 'dashed',
'borderRadius': '5px',
'display': 'flex',
'justify-content':'center',
'textAlign': 'center',
'background-color': '#FFFFFF',
'box-shadow': '0 .5rem 1rem -.5rem rgba(0, 0, 0, .4)',
'color': 'black',
'font-family': 'monospace',
}
editableTableDataStyleError = {'border': '3px double #FF0033'}
editableTableDataStyleDefault = {'border': '1px double lightgray'}
tableErrorIconDefaultStyle = {'display':'none'}
tableErrorIconEnabledStyle = {'margin-left': 'auto', 'margin-right': 'auto', 'display':'block'}
tab_style_upload_panel = {
'fontWeight': 'bold'
}
tab_selected_style_upload_panel = {
'backgroundColor': '#445262',
'color': 'white',
}
def changeGraphWidth(width):
return {'max-width': '1000px',
'width': '{}px'.format(width),
'float': 'right', #
'height': '500px'}
# Workaround function for bug that changes the width and length of the graph div when changing tabs
def adjustGraphStyle(systemCount, orientationValue):
if orientationValue == 'horizontal':
return changeGraphWidth(Charts.plotSize.get(orientationValue))
else:
return changeGraphWidth(Charts.plotSize.get(systemCount))