Skip to content

added description option to bindings. - #659

Open
unstoppablecarl wants to merge 1 commit into
cocopon:mainfrom
unstoppablecarl:feat-add-label-description
Open

added description option to bindings. #659
unstoppablecarl wants to merge 1 commit into
cocopon:mainfrom
unstoppablecarl:feat-add-label-description

Conversation

@unstoppablecarl

@unstoppablecarl unstoppablecarl commented Feb 15, 2026

Copy link
Copy Markdown

When I come back to old projects with Tweakpane I often wish I could leave some more detailed descriptions for the bindings. Tweakpane's compact UI is its key feature. This adds an optional description to each label without intruding on the UI at all.

The description is set to the label element title attribute allowing users to hover and get a tooltip of the description.

pane.addBinding(PARAMS, 'size', {
  label: 'Field radius',
  description: 'Force Field Radius in Meters',
});

label output

<div class="tp-lblv_l" title="Force Field Radius in Meters">Field radius</div>

this also allows some options for styling the labels.

.tp-lblv_l[title] {
  white-space: nowrap;
}

.tp-lblv_l[title]::after {
  content: ' ⓘ';
}

SEE:

…abel element title attribute allowing users to hover and get a tooltip of the description.
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