-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
551 lines (491 loc) · 23.6 KB
/
index.html
File metadata and controls
551 lines (491 loc) · 23.6 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
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>FIGX Student Forms</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=DM+Sans:opsz,wght@9..40,300;9..40,400;9..40,700;9..40,900&display=swap" rel="stylesheet">
<style>
:root {
--accent: #04B1E6;
--accent-dk: #039fce;
--bg: #ededec;
--surface: #ffffff;
--border: #e4e4e4;
--text: #1a1a1a;
--text-mid: #555;
--text-soft: #999;
--text-hint: #888;
--radius: 9px;
--shadow: 0 1px 6px rgba(0,0,0,0.07);
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
font-family: 'DM Sans', sans-serif;
color: var(--text);
background-color: #e8e8e6;
background-image:
radial-gradient(ellipse 80% 60% at 15% 10%, rgba(4,177,230,0.08) 0%, transparent 60%),
radial-gradient(ellipse 60% 50% at 88% 85%, rgba(4,177,230,0.06) 0%, transparent 55%),
url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='1' cy='1' r='1' fill='%23000' fill-opacity='0.04'/%3E%3C/svg%3E");
background-attachment: fixed;
-webkit-font-smoothing: antialiased;
}
/* ── LAYOUT ── */
.wrap { max-width: 1180px; margin: 0 auto; padding: 44px 36px 88px; }
/* ── CONTROLS ── */
.controls {
background: var(--surface);
border-radius: var(--radius);
padding: 22px 36px;
margin-bottom: 28px;
box-shadow: var(--shadow);
display: flex;
gap: 18px;
align-items: flex-end;
flex-wrap: wrap;
}
.field { display: flex; flex-direction: column; gap: 6px; flex: 1; min-width: 150px; }
.field label {
font-size: 0.68rem;
font-weight: 700;
color: var(--text-soft);
text-transform: uppercase;
letter-spacing: 0.12em;
}
.field input, .field select {
padding: 0 13px;
border: 1.5px solid var(--border);
border-radius: 6px;
font-family: 'DM Sans', sans-serif;
font-size: 0.93rem;
color: var(--text);
background: var(--surface);
height: 42px;
transition: border-color 0.15s;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--accent); }
/* segmented toggle */
.field-toggle { flex: 2.2; min-width: 280px; }
.type-toggle {
display: flex;
height: 42px;
border: 1.5px solid var(--border);
border-radius: 6px;
overflow: hidden;
}
.type-btn {
flex: 1;
padding: 0 16px;
border: none;
border-right: 1.5px solid var(--border);
background: var(--surface);
font-family: 'DM Sans', sans-serif;
font-size: 0.84rem;
font-weight: 700;
color: var(--text-soft);
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
gap: 7px;
transition: background 0.15s, color 0.15s;
white-space: nowrap;
}
.type-btn:last-child { border-right: none; }
.type-btn.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.type-btn svg { flex-shrink: 0; }
/* ── FORM PANELS ── */
.form-panel { display: none; }
.form-panel.active { display: block; }
.form-doc {
background: var(--surface);
border-radius: var(--radius);
padding: 60px 70px;
box-shadow: var(--shadow);
}
/* ── DOCUMENT HEADER ── */
.doc-title {
font-size: 1.9rem;
font-weight: 900;
color: var(--text);
line-height: 1.12;
letter-spacing: -0.01em;
margin-bottom: 28px;
}
.doc-meta {
display: flex;
gap: 52px;
flex-wrap: wrap;
font-size: 0.97rem;
margin-bottom: 24px;
}
.doc-meta strong { font-weight: 700; }
.meta-val { color: var(--text-mid); }
.doc-intro {
border-left: 3px solid var(--border);
padding: 10px 18px;
font-size: 0.92rem;
color: #666;
line-height: 1.75;
margin-bottom: 52px;
background: #f7f7f6;
border-radius: 0 4px 4px 0;
}
/* ── SECTIONS ── */
.section { margin-bottom: 44px; }
.section-header {
display: flex;
align-items: center;
gap: 11px;
/* margin-bottom: 14px; */
padding-bottom: 14px;
}
.section-header h2 {
font-size: 1.1rem;
font-weight: 900;
letter-spacing: 0.08em;
text-transform: uppercase;
color: #1a1a1a;
}
.s-icon { flex-shrink: 0; color: var(--accent); display: flex; align-items: center; }
/* ── SUBSECTIONS ── */
.subsection { margin-bottom: 26px; }
.sub-label { font-size: 1rem; font-weight: 700; color: var(--text); margin-bottom: 10px; line-height: 1.4; }
/* ── EDITABLE ANSWER ── */
.answer {
min-height: 84px;
padding: 13px 16px;
font-family: 'DM Sans', sans-serif;
font-size: 0.95rem;
color: var(--text);
line-height: 1.5;
outline: none;
border: 1.5px solid var(--border);
border-radius: 6px;
transition: border-color 0.2s;
word-break: break-word;
cursor: text;
}
.answer:focus { border-color: var(--accent); }
.sub-desc {
font-size: 0.85rem;
color: var(--text-hint);
margin-top: 8px;
line-height: 1.55;
}
/* ── ACTIONS ── */
.actions {
margin-top: 48px;
padding-top: 32px;
border-top: 1.5px solid #f0f0f0;
display: flex;
align-items: center;
gap: 20px;
flex-wrap: wrap;
}
.btn-pdf {
background: var(--accent);
color: #fff;
border: none;
padding: 12px 32px;
border-radius: 6px;
font-family: 'DM Sans', sans-serif;
font-size: 0.93rem;
font-weight: 700;
cursor: pointer;
letter-spacing: 0.04em;
display: flex;
align-items: center;
gap: 9px;
white-space: nowrap;
transition: background 0.15s;
}
.btn-pdf:hover { background: var(--accent-dk); }
.reminder {
font-size: 0.86rem;
color: var(--text-hint);
line-height: 1.6;
flex: 1;
display: flex;
align-items: flex-start;
gap: 7px;
}
.reminder svg { flex-shrink: 0; margin-top: 2px; }
.reminder strong { color: var(--accent); font-weight: 700; }
/* ── RESPONSIVE ── */
@media (max-width: 960px) {
.form-doc { padding: 52px 56px; }
.wrap { padding: 32px 24px 72px; }
.controls { padding: 18px 24px; }
}
@media (max-width: 640px) {
.form-doc { padding: 36px 28px; }
.section { margin-bottom: 36px; }
.wrap { padding: 20px 14px 56px; }
.controls { flex-direction: column; padding: 16px 18px; gap: 12px; }
.field, .field-toggle { flex: none; width: 100%; }
.doc-title { font-size: 1.3rem; }
.doc-meta { gap: 18px; }
.doc-intro { margin-bottom: 30px; }
.actions { flex-direction: column; align-items: flex-start; gap: 14px; }
.reminder { flex: none; }
}
@media (max-width: 400px) {
.form-doc { padding: 28px 18px; }
.doc-title { font-size: 1.45rem; }
}
/* ── PRINT ── */
@media print {
* { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
body { background: #fff; zoom: 75%; }
.controls, .actions, .sub-desc, .doc-intro { display: none !important; }
.wrap { padding: 0; max-width: none; }
.form-panel { display: none !important; }
.form-panel.active { display: block !important; }
.form-doc {
box-shadow: none;
border-radius: 0;
padding: 15mm 12mm;
}
.doc-title { font-size: 1.5rem; margin-bottom: 12px; }
.doc-meta { margin-bottom: 14px; }
.section { margin-top: 10px; margin-bottom: 18px; break-inside: avoid; }
.section-header { margin-top: 10px; padding-top: 8px; }
.subsection { margin-bottom: 12px; break-inside: avoid; }
.sub-label { margin-bottom: 5px; }
.answer {
min-height: 40px;
padding: 7px 10px;
border-color: var(--border);
color: #555;
font-size: .85rem;
/* background-color: #f7f7f6; */
}
}
</style>
</head>
<body>
<div id="app">
<div class="wrap">
<div class="controls">
<div class="field">
<label>Student Name</label>
<input type="text" id="studentName" placeholder="Your name" oninput="syncMeta()">
</div>
<div class="field">
<label>Semester</label>
<select id="semesterSel" onchange="syncMeta()">
<option value="">Select semester…</option>
</select>
</div>
<div class="field field-toggle">
<label>Form Type</label>
<div class="type-toggle">
<button class="type-btn active" id="btnGoal" onclick="setForm('goal')">
<svg width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"/><polyline points="12 8 16 12 12 16"/><line x1="8" y1="12" x2="16" y2="12"/></svg>
Semester Beginning
</button>
<button class="type-btn" id="btnAssess" onclick="setForm('assess')">
<svg width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><polyline points="20 6 9 17 4 12"/></svg>
Semester End
</button>
</div>
</div>
</div>
<!-- GOAL-SETTING FORM -->
<div class="form-panel active" id="goalPanel">
<div class="form-doc">
<div class="doc-title">Goal-Setting Form for FIGX Students</div>
<div class="doc-meta">
<span><strong>Name:</strong> <span class="meta-val" id="goalName">[]</span></span>
<span><strong>Period Covered:</strong> <span class="meta-val" id="goalSem">[]</span></span>
</div>
<div class="doc-intro">
You don't need to complete every section or write at length — just take a moment to reflect on what you want.
I hope this process helps you clarify your thoughts and stay motivated. This page generates a PDF but does not store any data.
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"/><circle cx="12" cy="12" r="6"/><circle cx="12" cy="12" r="2"/></svg></span><h2>Research and Career</h2></div>
<div class="subsection">
<div class="sub-label">a. Primary Research Objectives</div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">List the main research goals you aim to achieve this semester.</div>
</div>
<div class="subsection">
<div class="sub-label">b. Milestones</div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Specify key deliverables (e.g., ideas, experiments, data analysis, drafts) that align with your objectives.</div>
</div>
<div class="subsection">
<div class="sub-label">c. Long-term Plan</div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">What are your Ph.D. and post-Ph.D. goals at this point? Skip if not applicable.</div>
</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><polygon points="13 2 3 14 12 14 11 22 21 10 12 10 13 2"/></svg></span><h2>Skill Development</h2></div>
<div class="subsection">
<div class="sub-label">a. Skills</div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">List technical or professional skills (e.g., software tools, communication) you aim to develop.</div>
</div>
<div class="subsection">
<div class="sub-label">b. Courses</div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">List courses, seminars, or workshops you plan to attend in support of your goals.</div>
</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M17 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"/><circle cx="9" cy="7" r="4"/><path d="M23 21v-2a4 4 0 0 0-3-3.87"/><path d="M16 3.13a4 4 0 0 1 0 7.75"/></svg></span><h2>Collaboration</h2></div>
<div class="subsection">
<div class="sub-label">a. Team Interaction</div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Describe how you plan to collaborate with peers, lab members, or external partners.</div>
</div>
<div class="subsection">
<div class="sub-label">b. Networking Goals</div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Identify networking opportunities you'd like to pursue (e.g., meetings, conferences).</div>
</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z"/></svg></span><h2>Well-Being</h2></div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Let me know if you need any resources or support.</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"/></svg></span><h2>Additional Comments</h2></div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Anything else you'd like to share?</div>
</div>
<div class="actions">
<button class="btn-pdf" onclick="generatePDF()">
<svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4"/><polyline points="7 10 12 15 17 10"/><line x1="12" y1="15" x2="12" y2="3"/></svg>
Generate PDF
</button>
<p class="reminder">
<svg width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="#bbb" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><rect x="2" y="4" width="20" height="16" rx="2"/><polyline points="2,4 12,13 22,4"/></svg>
In the print dialog, set <strong>Destination → Save as PDF</strong> and <strong>Layout → Portrait</strong>
</div>
</div>
</div>
<!-- SELF-ASSESSMENT FORM -->
<div class="form-panel" id="assessPanel">
<div class="form-doc">
<div class="doc-title">Self-Assessment Form for FIGX Students</div>
<div class="doc-meta">
<span><strong>Name:</strong> <span class="meta-val" id="assessName">[]</span></span>
<span><strong>Period Covered:</strong> <span class="meta-val" id="assessSem">[]</span></span>
</div>
<div class="doc-intro">
This form helps us track your progress and reflect together. Feel free to cross-reference your goal-setting form,
and skip any sections that don't apply. You don't need to write at length. Just note your main thoughts. This page generates a PDF but does not store any data.
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="8" r="6"/><path d="M15.477 12.89 17 22l-5-3-5 3 1.523-9.11"/></svg></span><h2>Key Achievements</h2></div>
<div class="subsection">
<div class="sub-label">a. Research Activities</div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">List any milestones reached, ideas explored, preliminary results, experiments completed, etc.</div>
</div>
<div class="subsection">
<div class="sub-label">b. Publications and Manuscripts</div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Detail any papers submitted, accepted, or published.</div>
</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><polygon points="13 2 3 14 12 14 11 22 21 10 12 10 13 2"/></svg></span><h2>Skill Development</h2></div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Describe any soft or technical skills — such as methodologies or software — that you have developed.</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M21 11.5a8.38 8.38 0 0 1-.9 3.8 8.5 8.5 0 0 1-7.6 4.7 8.38 8.38 0 0 1-3.8-.9L3 21l1.9-5.7a8.38 8.38 0 0 1-.9-3.8 8.5 8.5 0 0 1 4.7-7.6 8.38 8.38 0 0 1 3.8-.9h.5a8.48 8.48 0 0 1 8 8v.5z"/></svg></span><h2>Collaboration</h2></div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Reflect on any new connections you built — with people, groups, or organizations.</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z"/></svg></span><h2>Well-Being</h2></div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">How has your well-being been this semester?</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M17 3a2.828 2.828 0 1 1 4 4L7.5 20.5 2 22l1.5-5.5L17 3z"/></svg></span><h2>Communication and Feedback</h2></div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Reflect on how well communication with your supervisor has worked, and share any suggestions that could improve your experience.</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M22 11.08V12a10 10 0 1 1-5.93-9.14"/><polyline points="22 4 12 14.01 9 11.01"/></svg></span><h2>Overall Evaluation</h2></div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Did you achieve the goals set in your goal-setting form? Provide an overall evaluation.</div>
</div>
<div class="section">
<div class="section-header"><span class="s-icon"><svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"/></svg></span><h2>Additional Comments</h2></div>
<div class="answer" contenteditable="true"></div>
<div class="sub-desc">Is there anything else you'd like to share?</div>
</div>
<div class="actions">
<button class="btn-pdf" onclick="generatePDF()">
<svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4"/><polyline points="7 10 12 15 17 10"/><line x1="12" y1="15" x2="12" y2="3"/></svg>
Generate PDF
</button>
<p class="reminder">
<svg width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="#bbb" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><rect x="2" y="4" width="20" height="16" rx="2"/><polyline points="2,4 12,13 22,4"/></svg>
In the print dialog, set <strong>Destination → Save as PDF</strong> and <strong>Layout → Portrait</strong>
</p>
</div>
</div>
</div>
</div>
</div>
<script>
(function () {
var sel = document.getElementById('semesterSel');
var year = new Date().getFullYear();
['Spring', 'Fall'].forEach(function(s) {
var o = document.createElement('option');
o.value = year + ' ' + s; o.textContent = year + ' ' + s;
sel.appendChild(o);
});
})();
document.addEventListener('paste', function(e) {
if (!e.target.classList.contains('answer')) return;
e.preventDefault();
var text = (e.clipboardData || window.clipboardData).getData('text/plain');
document.execCommand('insertText', false, text);
});
function setForm(type) {
var isGoal = type === 'goal';
document.getElementById('goalPanel').classList.toggle('active', isGoal);
document.getElementById('assessPanel').classList.toggle('active', !isGoal);
document.getElementById('btnGoal').classList.toggle('active', isGoal);
document.getElementById('btnAssess').classList.toggle('active', !isGoal);
}
function syncMeta() {
var name = document.getElementById('studentName').value.trim() || '—';
var sem = document.getElementById('semesterSel').value || '—';
document.getElementById('goalName').textContent = name;
document.getElementById('goalSem').textContent = sem;
document.getElementById('assessName').textContent = name;
document.getElementById('assessSem').textContent = sem;
}
function generatePDF() {
var name = document.getElementById('studentName').value.trim();
var sem = document.getElementById('semesterSel').value;
if (!name || !sem) {
alert('Please enter your name and select a semester before generating the PDF.');
return;
}
var isGoal = document.getElementById('goalPanel').classList.contains('active');
var formType = isGoal ? 'Goal-Setting' : 'Self-Assessment';
var original = document.title;
document.title = formType + ' - ' + sem + ' - ' + name;
window.print();
document.title = original;
}
</script>
</body>
</html>