-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
224 lines (207 loc) · 10.9 KB
/
index.html
File metadata and controls
224 lines (207 loc) · 10.9 KB
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
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/png" href="/favicon.png" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>CS Picks</title>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link
href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Outfit:wght@500;700;800&display=swap"
rel="stylesheet">
<link rel="stylesheet" href="./src/style.css">
</head>
<body>
<!-- Theme toggle button -->
<button class="theme-toggle" id="theme-toggle" aria-label="Toggle dark mode">
<span class="sun-icon">☀️</span>
<span class="moon-icon">🌙</span>
</button>
<script>
// Apply saved theme immediately to prevent flash
const savedTheme = localStorage.getItem('theme');
const systemDark = window.matchMedia('(prefers-color-scheme: dark)').matches;
const initialTheme = savedTheme || (systemDark ? 'dark' : 'light');
document.documentElement.setAttribute('data-theme', initialTheme);
</script>
<div id="app">
<header>
<h1>CS Picks</h1>
<div class="top-nav" style="display: flex; gap: 1rem; margin-bottom: 1rem; justify-content: center;">
<a href="index.html"
style="text-decoration: none; color: var(--primary-color); border-bottom: 2px solid var(--primary-color); font-weight: 600;">Search</a>
<a href="analysis.html"
style="text-decoration: none; color: var(--text-secondary); font-weight: 600;">Analysis</a>
<a href="compare.html"
style="text-decoration: none; color: var(--text-secondary); font-weight: 600;">Compare</a>
<a href="map.html" style="text-decoration: none; color: var(--text-secondary); font-weight: 600;">Map</a>
</div>
<p>Explore Computer Science Professors, Schools, and Research Areas.</p>
</header>
<div class="search-section">
<div class="search-container">
<input type="search" id="main-search" placeholder="Loading data..." disabled autofocus>
</div>
<div class="filters">
<div class="filter-group">
<label for="region-select">Region</label>
<select id="region-select">
<option value="world" selected>World</option>
<option value="us">USA</option>
<option value="europe">Europe</option>
<option value="asia">Asia</option>
<option value="canada">Canada</option>
<option value="australasia">Australasia</option>
</select>
</div>
<div class="filter-group" id="year-filter-group">
<div class="year-inputs">
<select id="start-year"></select>
<span>to</span>
<select id="end-year"></select>
</div>
</div>
<div class="filter-group">
<select id="conf-set"
style="padding: 0.25rem 0.5rem; border-radius: 6px; border: 1px solid var(--border-color); font-size: 0.9rem; background: var(--card-bg); color: var(--text-primary);">
<option value="csrankings-default" selected>CSRankings (Default)</option>
<option value="csrankings">CSRankings (All)</option>
<option value="core">CORE A*</option>
<option value="core-a">CORE A*/A</option>
</select>
</div>
<div class="filter-group" style="display: flex; gap: 1.5rem;">
<label for="show-rankings" style="display: flex; align-items: center; gap: 0.5rem; cursor: pointer;">
<input type="checkbox" id="show-rankings" style="width: 16px; height: 16px; cursor: pointer;">
<span>Show Rankings</span>
</label>
<label for="historical-mode" style="display: flex; align-items: center; gap: 0.5rem; cursor: pointer;">
<input type="checkbox" id="historical-mode" style="width: 16px; height: 16px; cursor: pointer;">
<span>Historical Mode</span>
<span class="tooltip-trigger" style="color: var(--text-secondary); cursor: help; position: relative;">
ⓘ
<span class="tooltip-content">When enabled, publications are credited to the institution where the author
was affiliated at the time of publication. not their current institution.
Use the year selectors to filter results
for a specific historical period.</span>
</span>
</label>
</div>
</div>
<div class="actions-container">
<button id="simulate-btn" class="btn-secondary" title="Simulate adding an author to a university">
Simulate
</button>
</div>
</div>
<div id="search-context-header"
style="text-align: center; margin: 1.5rem 0; font-size: 1.5rem; font-weight: 600; color: var(--text-primary); display: none;">
</div>
<main>
<section id="conference-results" class="results-grid"></section>
<section id="school-results" class="results-grid"></section>
<section id="area-people-results" class="results-grid"></section>
<section id="prof-results" class="results-grid"></section>
<section id="dblp-results" class="results-grid"></section>
</main>
<div id="sim-modal" class="modal hidden">
<div class="modal-content">
<div class="modal-header">
<h2>Simulator</h2>
<button class="close-modal">×</button>
</div>
<div class="modal-body">
<!-- Step 1: Select University -->
<div class="sim-step" id="step-univ-first">
<h3>1. Select Target University</h3>
<input type="text" id="sim-univ-search" placeholder="Type university name (e.g. George Mason)...">
<div id="sim-univ-results" class="sim-list"></div>
</div>
<!-- Step 2: Enter Candidates -->
<div class="sim-step hidden" id="step-candidates">
<h3>2. Enter Faculty Candidates</h3>
<div class="selected-item" id="selected-univ-display"></div>
<p style="font-size: 0.85rem; color: var(--text-secondary); margin-bottom: 0.5rem;">
Select existing faculty below or paste candidate names in the text box (one per line).
</p>
<div id="sim-faculty-picker" style="margin-bottom: 0.75rem;">
<input type="text" id="sim-faculty-search" placeholder="Search faculty at this university..."
style="width: 100%; padding: 0.5rem; margin-bottom: 0.5rem; border-radius: 6px; border: 1px solid var(--border-color); background: var(--card-bg); color: var(--text-primary); font-size: 0.9rem; box-sizing: border-box;">
<div style="display: flex; gap: 6px; margin-bottom: 0.5rem;">
<button id="sim-select-all" type="button"
style="flex: 1; padding: 4px 8px; font-size: 0.8em; border-radius: 4px; border: 1px solid var(--border-color); background: var(--card-bg); color: var(--text-primary); cursor: pointer;">Select
All</button>
<button id="sim-deselect-all" type="button"
style="flex: 1; padding: 4px 8px; font-size: 0.8em; border-radius: 4px; border: 1px solid var(--border-color); background: var(--card-bg); color: var(--text-primary); cursor: pointer;">Deselect
All</button>
</div>
<div id="sim-faculty-list"
style="max-height: 180px; overflow-y: auto; border: 1px solid var(--border-color); border-radius: 8px; background: var(--card-bg);">
</div>
</div>
<textarea id="sim-candidates-input" rows="4"
placeholder="Or paste external candidate names here (one per line) John Smith Jane Doe"></textarea>
<button id="sim-analyze-btn" class="btn-secondary" style="margin-top: 1rem; width: 100%;">
Analyze Candidates
</button>
</div>
<!-- Step 3: Results -->
<div class="sim-step hidden" id="step-results">
<h3>3. Candidate Rankings</h3>
<div class="selected-item" id="selected-univ-display-results"></div>
<div id="sim-loading" class="hidden">Analyzing candidates... <span class="spinner">↻</span></div>
<div id="sim-candidates-results"></div>
<button id="sim-reset-btn" class="btn-secondary" style="margin-top: 1rem;">Start Over</button>
</div>
</div>
</div>
</div>
</div>
<script type="module" src="/src/main.js"></script>
<footer>
<a href="faq.html" style="color: inherit; text-decoration: underline; margin-right: 1rem;">FAQ & Methods</a>
<a href="#" id="open-ack-modal" style="color: inherit; text-decoration: underline;">Data & Acknowledgment</a>
</footer>
<div id="ack-modal" class="modal hidden">
<div class="modal-content" style="max-width: 500px;">
<div class="modal-header">
<h2>Data & Acknowledgment</h2>
<button class="close-modal"
onclick="document.getElementById('ack-modal').classList.add('hidden')">×</button>
</div>
<div class="modal-body" style="text-align: left;">
<p>CSPicks is inspired by <a href="https://csrankings.org" target="_blank"><strong>CSRankings</strong></a> and
uses its taxonomy and data to organize results.</p>
<p>Historical affiliation data is sourced from <a href="https://openalex.org"
target="_blank"><strong>OpenAlex</strong></a>,
an open catalog of the world's scholarly works.</p>
<p style="color: #666; font-size: 0.9em;"><em>⚠️ OpenAlex uses automated extraction which may produce
inaccuracies in their affiliation data.
Some historical affiliations may be missing, incorrect, or include short-term visiting positions.
These limitations are inherent to the OpenAlex dataset and not errors in CSPicks.</em></p>
<p style="color: #059669; font-size: 0.9em;"><strong>Wrong affiliation?</strong> You can submit corrections
by opening an issue on
<a href="https://github.com/dynaroars/cspicks/issues" target="_blank">GitHub</a> with the professor's name,
correct school, and years.
We maintain a manual override file to fix OpenAlex errors.
</p>
<p>All information is fetched on demand; no data is stored.</p>
<p>Report bugs and issues on <a href="https://github.com/dynaroars/cspicks"
target="_blank"><strong>GitHub</strong></a>.</p>
</div>
</div>
</div>
<script>
document.getElementById('open-ack-modal').addEventListener('click', (e) => {
e.preventDefault();
document.getElementById('ack-modal').classList.remove('hidden');
});
document.getElementById('ack-modal').addEventListener('click', (e) => {
if (e.target.id === 'ack-modal') {
document.getElementById('ack-modal').classList.add('hidden');
}
});
</script>
</body>
</html>