Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions content.js
Original file line number Diff line number Diff line change
Expand Up @@ -1653,6 +1653,10 @@
<div class="jm-score-section" id="jmScoreSection">
<div class="jm-score-circle" id="jmScoreCircle">--</div>
<div class="jm-score-label">Match Score</div>
<details class="jm-why-score" id="jmWhyScore">
<summary class="jm-why-summary">Why this score?</summary>
<div class="jm-why-content" id="jmWhyContent"></div>
</details>
</div>

<div class="jm-section" id="jmMatchingSection">
Expand Down Expand Up @@ -3078,6 +3082,19 @@
scoreCircle.className = 'jm-score-circle ' + getScoreClass(score);
scoreSection.style.display = 'block';

// Why this score
const whyEl = shadowRoot.getElementById('jmWhyContent');
if (data.insights && (data.insights.strengths || data.insights.gaps)) {
let whyHtml = '';
if (data.insights.strengths) {
whyHtml += `<p><strong>Why it's strong:</strong> ${escapeHTML(data.insights.strengths)}</p>`;
}
if (data.insights.gaps) {
whyHtml += `<p><strong>What's holding it back:</strong> ${escapeHTML(data.insights.gaps)}</p>`;
}
whyEl.innerHTML = whyHtml;
}

// Matching skills
const matchingSection = shadowRoot.getElementById('jmMatchingSection');
const matchingEl = shadowRoot.getElementById('jmMatchingSkills');
Expand Down
29 changes: 29 additions & 0 deletions styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,32 @@
width: 100vw !important;
}
}

.jm-why-score {
margin-top: 8px;
font-size: 13px;
text-align: left;
}
.jm-why-summary {
cursor: pointer;
color: #2563eb;
font-weight: 500;
list-style: none;
}
.jm-why-summary::-webkit-details-marker {
display: none;
}
.jm-why-summary::before {
content: "▸ ";
}
details[open] .jm-why-summary::before {
content: "▾ ";
}
.jm-why-content {
margin-top: 6px;
padding: 8px;
background: #f9fafb;
border-radius: 6px;
color: #374151;
line-height: 1.5;
}