Skip to content

feat: Show explainer note when step decreases due to benchmark increase#321

Open
timgl wants to merge 2 commits intomainfrom
timgl/step-decrease-explainer
Open

feat: Show explainer note when step decreases due to benchmark increase#321
timgl wants to merge 2 commits intomainfrom
timgl/step-decrease-explainer

Conversation

@timgl
Copy link
Copy Markdown
Collaborator

@timgl timgl commented Apr 2, 2026

Problem

When we increase a benchmark, some employees get releveled, which can result in their step decreasing even though they got a raise. This can be confusing when employees view their own salary history — seeing a step go down looks like a bad sign when it isn't.

Changes

  • Detects when a salary entry has a lower step but higher benchmark factor than the previous entry (releveling scenario)
  • Shows an italicized info note below the salary card explaining the benchmark change and why the step/level numbers may have changed
  • Adds previousSalary prop to SalaryHistoryCard and builds a chronological map in the employee page to pass it through
  • Adds demo data in generateDemoData.ts with a releveling scenario (benchmark 1.0→1.15, step 0.8→0.6, salary still increased) for local testing

How did you test this code?

This was authored by an AI agent. The demo data can be used to verify the behavior locally by logging in as dev@posthog.com and viewing the employee's salary history.

🤖 LLM context

Co-authored with Claude Code (Opus 4.6).

When employees view their salary history and a step decreased while the
benchmark factor increased (releveling), show an italicized info note
explaining that the benchmark change updated expectations and this isn't
a bad sign.

Also adds demo data with a releveling scenario for local testing.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@timgl timgl requested a review from MarconLP as a code owner April 2, 2026 00:48
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant