Files
hermes-agent/apps/desktop/src/components/tips/tips.css
T
Brooklyn Nicholson baaf304992 feat(desktop): in-app tips
An ambient rotation that points at parts of the app you may not have found yet
— one accent bubble, an arrow, and an outline around the subject. No scrim and
no spotlight: a tip is a pointer beside your work, not a modal in front of it,
so it takes no focus, owns no Esc, and blocks nothing.

It only speaks when the app is genuinely quiet — nothing streaming, no dialog,
menu or tour up, window focused, a few seconds since the last keystroke — and
walks the catalog in order rather than shuffling, so tips arrive as a tour of
neighbouring parts of the app instead of unrelated ones. A tip with nothing on
screen to point at is skipped, not waited for.

Closing one with its ✕ retires it for good. That is the whole reason the ✕ is a
heavier gesture than letting the bubble time out, and Settings → Appearance is
the only way back — alongside the switch that turns the feature off entirely.
2026-08-27 21:50:18 -05:00

43 lines
1.7 KiB
CSS

/* THE POINTED-AT THING.
A tip has no scrim and no spotlight — the arrow is the whole mechanism — so
the subject gets marked rather than the rest of the app getting dimmed. The
host hangs `data-tip-target` on the subject — the arrow's anchor, or the
region that anchor defers to — and takes it off when the tip goes. Nothing
here knows what that element is.
`outline` and not a border, ring or glow: it draws outside the box without
taking part in layout, so nothing shifts when a tip lands, and it inherits
whatever `border-radius` the target already has instead of imposing one.
A glow was the first attempt and read as noise at every intensity — the
targets sit on busy surfaces, and a soft accent haze looks like more of the
same. A hard line does not. */
[data-tip-target] {
outline: 2px solid var(--dt-primary);
outline-offset: 3px;
animation: hermes-tip-outline-pulse 1.8s ease-in-out infinite;
}
/* A region is a whole area — a nav row, the sidebar, the composer — and those
are the elements sitting flush against a scroller or an `overflow-hidden`
parent, where an outline drawn 3px OUTSIDE the box is the outline you can't
see. Inset it and it always lands on its own surface. Applies whether the
region was deferred to or anchored directly. */
[data-tip-target][data-tip-region] {
outline-offset: -2px;
}
@keyframes hermes-tip-outline-pulse {
50% {
outline-color: color-mix(in srgb, var(--dt-primary) 45%, transparent);
}
}
/* Marked, not breathing. The outline is the signal; the pulse is only flavour. */
@media (prefers-reduced-motion: reduce) {
[data-tip-target] {
animation: none;
}
}