Heart Rate Dial
Install the component, then paste your configured usage. Your settings are included in the code below.
npx arclen-ui add climate-dial --settings eyJtb2RlIjoiaGVhcnQtcmF0ZSIsImF1ZGl0RW1iZXJDb2xvciI6IiNmZjNkMWEiLCJhdWRpdEVtYmVyU3RhcnQiOjAsImF1ZGl0WWVsbG93Q29sb3IiOiIjZmZjZTQyIiwiYXVkaXRZZWxsb3dTdGFydCI6NTAsImF1ZGl0R3JlZW5Db2xvciI6IiMzNmRjODAiLCJhdWRpdEdyZWVuU3RhcnQiOjkwLCJwZXJmb3JtYW5jZUxhYmVsIjoiUGVyZm9ybWFuY2UiLCJwZXJmb3JtYW5jZVNjb3JlIjo5MiwicGVyZm9ybWFuY2VGaW5kaW5nIjoiUmVzaXplIHRoZSBoZXJvIGltYWdlIHRvIGltcHJvdmUgdGhlIGZpcnN0IHJlbmRlci4iLCJhY2Nlc3NpYmlsaXR5TGFiZWwiOiJBY2Nlc3NpYmlsaXR5IiwiYWNjZXNzaWJpbGl0eVNjb3JlIjo3NiwiYWNjZXNzaWJpbGl0eUZpbmRpbmciOiJUaHJlZSBpY29uIGJ1dHRvbnMgbmVlZCBhY2Nlc3NpYmxlIG5hbWVzLiIsInNlb0xhYmVsIjoiU0VPIiwic2VvU2NvcmUiOjg4LCJzZW9GaW5kaW5nIjoiVHdvIHBhZ2VzIHNoYXJlIHRoZSBzYW1lIHRpdGxlIHRhZy4iLCJicmlnaHRuZXNzIjo2NSwiZGltbWVyR2xvd0NvbG9yIjoiI2ZmYjE0YSIsImJwbSI6NzIsImxvd1JhdGVDb2xvciI6IiMzNmQ3NzkiLCJtaWRSYXRlQ29sb3IiOiIjZmZjZjM4IiwiaGlnaFJhdGVDb2xvciI6IiNmZjNkMWEiLCJoZWFydEdsb3dSaXNlIjoxMDAsImJlYXREZXB0aCI6MS41LCJoZWFydEljb25TaXplIjoxMzUsImhlYXJ0UHVsc2VBbW91bnQiOjIsInRoZW1lIjoiZGFyayIsInZhbHVlIjozOCwiaGludCI6dH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dXIiOjcsImhhbG9CbHVyIjo4LCJlbnRyYW5jZUhvbGQiOjM4MCwiZW50cmFuY2VMaWZ0IjozNiwiZW50cmFuY2VTY2FsZSI6MC44OCwiZW50cmFuY2VCbHVyIjoxOCwia2V5Ym9hcmRTdGVwIjoxLCJzaGlmdFN0ZXAiOjUsIndoZWVsRW5hYmxlZCI6dHJ1ZSwiaGludFRleHQiOiJUdXJuIHRoZSBkaWFsIHRvIGFkanVzdCBoZWFydCByYXRlIiwiaGludFNpemUiOjEyLCJoaW50R2FwIjo3NC44fQimport { HeartRateDial } from "@/components/climate-dial";
export default function Example() {
return <HeartRateDial {...{
"mode": "heart-rate",
"auditEmberColor": "#ff3d1a",
"auditEmberStart": 0,
"auditYellowColor": "#ffce42",
"auditYellowStart": 50,
"auditGreenColor": "#36dc80",
"auditGreenStart": 90,
"performanceLabel": "Performance",
"performanceScore": 92,
"performanceFinding": "Resize the hero image to improve the first render.",
"accessibilityLabel": "Accessibility",
"accessibilityScore": 76,
"accessibilityFinding": "Three icon buttons need accessible names.",
"seoLabel": "SEO",
"seoScore": 88,
"seoFinding": "Two pages share the same title tag.",
"brightness": 65,
"dimmerGlowColor": "#ffb14a",
"bpm": 72,
"lowRateColor": "#36d779",
"midRateColor": "#ffcf38",
"highRateColor": "#ff3d1a",
"heartGlowRise": 100,
"beatDepth": 1.5,
"heartIconSize": 135,
"heartPulseAmount": 2,
"theme": "dark",
"value": 38,
"hint": true,
"size": 340,
"glow": 1,
"coldAccent": "#3b82f6",
"warmAccent": "#ff3d1a",
"spring": 0.55,
"speed": 1,
"entrance": true,
"pulse": true,
"pulsePeriod": 3.81,
"pulseDepth": 1.5,
"bloomWidth": 84,
"showSeason": true,
"faceRadius": 30,
"rimWidth": 1,
"lightTop": "#fdfcfa",
"lightMid": "#f6f4f0",
"lightBase": "#efece7",
"darkTop": "#161616",
"darkMid": "#0b0b0b",
"darkBase": "#060606",
"lightInk": "#141414",
"darkInk": "#ffffff",
"tickWidth": 1.2,
"inactiveAlpha": 26,
"needleAlpha": 100,
"idlePeriod": 1.905,
"idleStrength": 1,
"readingSize": 45,
"readingTop": 46,
"readingWeight": 500,
"readingStretch": 0.916,
"digitColor": "#ffffff",
"degreeSize": 3.25,
"degreeAlpha": 92,
"digitTravel": 22,
"digitDuration": 265,
"seasonSize": 9.4,
"seasonTop": 15.45,
"seasonWeight": 720,
"seasonTracking": 0.13,
"letterIn": 380,
"letterStagger": 30,
"bloomHeight": 22,
"bloomBottom": -8,
"bloomBlur": 7,
"haloBlur": 8,
"entranceHold": 380,
"entranceLift": 36,
"entranceScale": 0.88,
"entranceBlur": 18,
"keyboardStep": 1,
"shiftStep": 5,
"wheelEnabled": true,
"hintText": "Turn the dial to adjust heart rate",
"hintSize": 12,
"hintGap": 74.8
}} />;
}| Property | Type | Default |
|---|---|---|
modeDial mode Options: heart-rate (Heart rate), dimmer (Light dimmer), site-audit (Site audit) | select | "heart-rate" |
auditEmberColorEmber glow colour | color | "#ff3d1a" |
auditEmberStartEmber starts at score 0–100Step 1 | number | 0 |
auditYellowColorYellow glow colour | color | "#ffce42" |
auditYellowStartYellow starts at score 0–100Step 1 | number | 50 |
auditGreenColorGreen glow colour | color | "#36dc80" |
auditGreenStartGreen starts at score 0–100Step 1 | number | 90 |
performanceLabelPerformance label Up to 48 characters | text | "Performance" |
performanceScorePerformance score 0–100Step 1 | number | 92 |
performanceFindingPerformance finding Up to 320 characters | text | "Resize the hero image to improve the first render." |
accessibilityLabelAccessibility label Up to 48 characters | text | "Accessibility" |
accessibilityScoreAccessibility score 0–100Step 1 | number | 76 |
accessibilityFindingAccessibility finding Up to 320 characters | text | "Three icon buttons need accessible names." |
seoLabelSEO label Up to 48 characters | text | "SEO" |
seoScoreSEO score 0–100Step 1 | number | 88 |
seoFindingSEO finding Up to 320 characters | text | "Two pages share the same title tag." |
brightnessBrightness (%) 0–100Step 1 | number | 65 |
dimmerGlowColorDimmer glow colour | color | "#ffb14a" |
bpmHeart rate (BPM) 40–200Step 1 | number | 72 |
lowRateColorLow BPM glow colour | color | "#36d779" |
midRateColorMid BPM glow colour | color | "#ffcf38" |
highRateColorHigh BPM glow colour | color | "#ff3d1a" |
heartGlowRiseHeart-rate glow rise (%) 0–200Step 1 | number | 100 |
beatDepthGlow pulse depth (%) 0–85Step 0.5 | number | 1.5 |
heartIconSizeHeart icon size (%) 60–200Step 1 | number | 135 |
heartPulseAmountHeart pulse amount (%) 0–25Step 0.1 | number | 2 |
themeTheme Options: dark, light | select | "light" |
valueTemperature (°C) -9–70Step 1 | number | 38 |
hintShow interaction hint | boolean | true |
sizeDial width 240–460Step 2 | number | 340 |
glowGlow strength 0–2Step 0.05 | number | 1 |
coldAccentCold accent | color | "#3b82f6" |
warmAccentWarm accent | color | "#ff3d1a" |
springSpring rebound 0–1Step 0.05 | number | 0.55 |
speedResponse speed 0.4–2Step 0.05 | number | 1 |
entrancePlay entrance sweep | boolean | true |
pulsePulse bottom glow | boolean | true |
pulsePeriodPulse cycle (seconds) 1.2–8Step 0.01 | number | 3.81 |
pulseDepthPulse depth (%) 0–85Step 0.5 | number | 1.5 |
bloomWidthGlow spread (%) 45–120Step 1 | number | 84 |
showSeasonShow dial label | boolean | true |
faceRadiusCorner radius (% of width) 0–50Step 1 | number | 30 |
rimWidthRim thickness (px) 0–4Step 0.25 | number | 1 |
lightTopLight face highlight | color | "#fdfcfa" |
lightMidLight face midtone | color | "#f6f4f0" |
lightBaseLight face shadow | color | "#efece7" |
darkTopDark face highlight | color | "#161616" |
darkMidDark face midtone | color | "#0b0b0b" |
darkBaseDark face shadow | color | "#060606" |
lightInkLight scale color | color | "#141414" |
darkInkDark scale color | color | "#ffffff" |
tickWidthTick width 0.5–4Step 0.1 | number | 1.2 |
inactiveAlphaInactive tick opacity (%) 0–100Step 1 | number | 26 |
needleAlphaNeedle opacity (%) 0–100Step 1 | number | 100 |
idlePeriodResting wave period (s) 0.5–6Step 0.005 | number | 1.905 |
idleStrengthResting wave strength (×) 0–3Step 0.05 | number | 1 |
readingSizeNumber size (% of width) 28–55Step 0.5 | number | 45 |
readingTopNumber position from top (%) 32–58Step 0.5 | number | 46 |
readingWeightNumber weight 200–850Step 10 | number | 500 |
readingStretchNumber width (×) 0.7–1.2Step 0.001 | number | 0.916 |
digitColorDark mode units digit color | color | "#ffffff" |
degreeSizeDegree ring size (% of width) 1.5–5Step 0.05 | number | 3.25 |
degreeAlphaDegree ring opacity (%) 0–100Step 1 | number | 92 |
digitTravelDigit roll distance (px) 0–45Step 1 | number | 22 |
digitDurationDigit roll duration (ms) 50–700Step 5 | number | 265 |
seasonSizeLabel size (% of width) 5–14Step 0.1 | number | 9.4 |
seasonTopLabel position from top (%) 7–26Step 0.05 | number | 15.45 |
seasonWeightLabel weight 300–900Step 10 | number | 720 |
seasonTrackingLetter spacing (em) -0.03–0.3Step 0.01 | number | 0.13 |
letterInLetter arrival (ms) 100–900Step 10 | number | 380 |
letterStaggerArrival stagger (ms) 0–80Step 1 | number | 30 |
bloomHeightBloom height (%) 5–40Step 1 | number | 22 |
bloomBottomBloom bottom offset (%) -22–12Step 1 | number | -8 |
bloomBlurBloom blur (% of width) 1–16Step 0.5 | number | 7 |
haloBlurAmbient halo blur (% of width) 1–18Step 0.5 | number | 8 |
entranceHoldHold before sweep (ms) 0–1000Step 10 | number | 380 |
entranceLiftFace travel (px) 0–80Step 1 | number | 36 |
entranceScaleInitial face scale (×) 0.65–1Step 0.01 | number | 0.88 |
entranceBlurInitial face blur (px) 0–32Step 1 | number | 18 |
keyboardStepKeyboard and wheel step 1–10Step 1 | number | 1 |
shiftStepShift step 1–25Step 1 | number | 5 |
wheelEnabledAdjust with focused wheel | boolean | true |
hintTextHint text Up to 100 characters | text | "Turn the dial to adjust heart rate" |
hintSizeHint type size (px) 9–20Step 0.5 | number | 12 |
hintGapMaximum hint gap (px) 0–110Step 0.1 | number | 74.8 |
Heart Rate Dial opens at 72 BPM. Select **Dial mode** in the preview or pass mode as a prop. Each mode remembers its own reading when you switch.
| Mode | Setting | Glow |
| --- | --- | --- |
| Site audit | Three editable scores, 0–100 | Glow follows each score band |
| Light dimmer | brightness, 0–100% | A steady amber light that goes dark at 0% |
| Heart rate (default) | bpm, 40–200 BPM | A pulse that blends from green through yellow to red |
**Site audit** displays sample scores for Performance, Accessibility and SEO. Each tile opens independently by click, tap, Enter or Space and reveals its finding. The tiles stack in narrow containers. In the preview, each tile has a label, a score (0–100) and a finding. Pass mode="site-audit" with props such as performanceScore, accessibilityLabel or seoFinding to use your own audit results.
Under **Audit glow**, set each colour and its first score. Ember starts at 0, yellow at 50 and green at 90 by default. Each tile uses the colour with the highest start it has reached. Scores below all three starts have no glow. When starts coincide, green takes priority over yellow, then ember. Use auditEmberColor and auditEmberStart, or the matching Yellow and Green props.
Set **Dimmer glow colour** for the light, or use the **Low**, **Mid** and **High BPM glow colour** pickers for heart rate. Their React props are dimmerGlowColor, lowRateColor, midRateColor and highRateColor.
**Heart-rate glow rise (%)** controls how far the light climbs inside the face as you turn the dial. At 100% it follows Climate’s rise. At 0% it stays at its starting height, and at 200% it travels twice as far. The beat timing and pulse depth are independent. Use heartGlowRise in code.
Heart rate starts at 72 BPM. The preview uses green up to 72 BPM, yellow at 120 BPM and Climate’s warm ember accent at 200 BPM, blending continuously between those visual stops. The floor reflection uses Climate’s base brightness and default 1.5% pulse depth. The bottom edge rises slightly on the beat. Set beatDepth for glow intensity. Under **Heart icon**, heartIconSize sets the resting size as a percentage of the label size (135% by default). heartPulseAmount sets the percentage growth on each beat (2% by default). Set it to zero to keep the heart still while the glow pulses. The selected BPM determines the beat independently of the dial’s spring speed and climate breathing settings. Reduced motion, pause and offscreen handling keep the glow steady.
Use onDialChange(value, mode) in React or listen for dialchange with { value, mode } in JavaScript. The climate-specific onValueChange and temperaturechange also include the season.
React
import { HeartRateDial } from './components/climate-dial/src/react';
<HeartRateDial
theme="dark"
bpm={72}
onDialChange={(value, mode) => console.log(value, mode)}
/>The default face is warm porcelain. Pass theme="dark" for graphite or hint={false} to hide the instruction band. Existing integrations can still request mode="climate" to display temperature. A changed value prop updates that mode. User input updates its current value immediately and calls onValueChange. The seasonal ranges are Winter through 4 °C, Autumn from 5 through 15 °C, Spring from 16 through 25 °C and Summer from 26 °C. These are display ranges.
HTML and vanilla JavaScript
import { mount } from './climate-dial/src/core';
import './climate-dial/src/styles.css';
const host = document.querySelector<HTMLElement>('#climate')!;
const controller = mount(host, { value: 38 });
host.addEventListener('temperaturechange', (event) => {
const { value, season } = (event as CustomEvent).detail;
console.log(value, season);
});
controller.update({ theme: 'light' });render(settings) returns the settled dial for static output. mount replaces the host contents. Call destroy() when removing the instance. Programmatic updates leave the user change event silent.
Input and motion
Drag around the scale or click its track to set the temperature. When focused, the arrow keys and mouse wheel adjust it by one degree. Hold Shift for five-degree steps. Home and End jump to the limits.
The 96 indices cover 230 degrees. The graphite pointer travels with a spring-smoothed readout and a temperature-dependent light under the shell. Keyboard and pointer input share this model. The accessible slider reports the target immediately. The digits show the moving temperature within the −9 to 70 °C range. Escape and pointer cancellation restore the value at the start of the drag. Reduced motion and paused snap the scale to the current reading. Hidden or offscreen instances stop motion. The face scales down in narrow hosts. At a 390px viewport it is 312px wide.
Tuning the instrument
size sets the preferred face width in pixels. The containing element and viewport constrain its final width. coldAccent and warmAccent accept six-digit hex colors and tint the three bands of the temperature gradient. glow adjusts the light beneath the face and its reflected edge. Set it to zero for a neutral face.
speed scales response time. spring controls rebound separately. The defaults of 1 and 0.55 preserve the measured fast overshoot. During a gesture, the needle, digit slots and moving reflection all follow the same spring position. The season label fades from white into the current temperature color. The leading numeral and degree mark also pick up the palette. The units digit defaults to solid white. At rest, a wave moves through the lit ticks, with the longest marks just behind the needle. Season changes stagger individual letters out and back in. Each digit slides into its own slot when its integer changes. The tens digit holds still between decades.
With entrance enabled, the face comes into focus, the indices appear from the middle outward and the needle sweeps from −9 °C to the configured temperature. The glow builds underneath before the instruction appears. Changing replayKey in React or calling controller.replay() in JavaScript plays it again. Input interrupts the sweep. Replay leaves the target value and change callback untouched. A paused or reduced-motion instrument displays its settled reading immediately.
Bottom glow
The reflected band rises and falls while the light beneath the dial brightens and dims. Both follow a sine wave with a 3.81-second cycle and a default swing of ±1.5% around the steady reading. Set pulsePeriod to change the length of a full cycle, pulseDepth to change the percentage swing, and bloomWidth to spread or concentrate the pool of light. A depth of 0 or pulse={false} holds the glow steady. The glow also stays steady for reduced motion, paused instances and hidden dials. Set showSeason={false} for a number-only face. The accessible temperature description still includes the season.
Face, type and motion controls
Use the Face controls to adjust the curvature, rim and three gradient stops for each theme. Scale controls set engraving thickness, inactive tick opacity, pointer opacity and the resting wave. idlePeriod is one full cycle in seconds. Set idleStrength to zero for stationary ticks.
Temperature readout and Season label have separate type and placement controls. digitTravel and digitDuration adjust the roll as the temperature changes. letterIn and letterStagger adjust each season letter’s arrival and delay. Replay the entrance to inspect its lift, scale, blur and hold before the needle starts moving. Floor glow controls set the reflection’s height, lower edge and blur, independently of the pulsing light.
keyboardStep and shiftStep set the degree increments for keys and a focused wheel. Turn off wheelEnabled to allow page scrolling while the dial has focus. Hint controls edit its copy, type size and space below the face. These settings work as React props and through controller.update.
The preview runs the component’s own JavaScript. It respects reduced motion and pauses when off screen. The HTML bundle includes a static fallback.
Every setting in this panel comes from the component manifest. Preview size, pause and replay stay in the inspector.