Foundations

Feedback

Feedback is an immediate response to user input. It communicates that an element is interactive and that the input has been received.

Feedback cover image

Clickable elements become slightly smaller while pressed. This borrows the sensation of a physical button being pressed in, allowing users to immediately perceive that their finger input reached the element.

Comparison of button in default and pressed states — the pressed one is smaller than the original size indicated by dotted line

The important thing is that the amount of pressed feeling is consistent across all elements. To achieve this, Crispy defines the reduction amount as a distance rather than a ratio.

Using a fixed ratio (e.g., 0.98) for each element has the limitation that the actual distance moved changes when the element's size changes.

Element Size (Width × Height)Specified RatioHorizontal ReductionVertical Reduction
80 × 520.981.6px1.04px
160 × 520.983.2px1.04px
343 × 52 (full mobile width)0.986.9px1.04px
720 × 52 (full tablet width)0.9814.4px1.04px

Vertical reduction is the same for all, but horizontal reduction varies up to 9 times. Since this value has no upper limit, it becomes increasingly unnatural on larger screens.

That's why Crispy defines that elements shrink by a set distance when pressed. The ratio is not a predetermined value but a result calculated from the element's actual size. Since the distance moved is the same whether the element is large or small, the pressed feeling is conveyed consistently regardless of what is pressed on which screen.

Calculation Method

The reduction amount is 2px vertically. When pressed, elements shrink by this amount vertically. The value that determines which length this distance is subtracted from is called the basis length.

basis = max(element height, element width ÷ 4, 24)
ratio  = (basis - 2) ÷ basis

Button with height 40px shrinks by 2px to become ratio 0.95

Button with height 100px shrinks by the same 2px to become ratio 0.98

The basis length is fundamentally the element's height. In left-to-right environments, most pressable elements are wider than they are tall, so height better represents an element's size than width.

Two adjustments are added to this, and the largest of the three values is used as the basis length.

  • element width ÷ 4 — Compensates for elements that are wide and short. In elements like List Item where width is much greater than height, using only height as basis causes excessive horizontal movement. The wider the element, the larger the basis length, so the same 2px becomes proportionally smaller.
  • Minimum 24 — Compensates for very small elements. If the original size is small, the reduction ratio becomes excessive even with the same 2px. A minimum basis length of 24px ensures the reduction ratio doesn't exceed 8.3%.

The reduction amount 2, width adjustment 4, and minimum basis length 24 are fixed values applied identically across all screens using Crispy. Since the goal is consistent pressed feeling everywhere, they are not changed per element or service.

Application Results

ElementSize (Width × Height)Applied BasisCalculated RatioActual Reduction
Icon Button32 × 32Height0.9382px horizontal, 2px vertical
Text Button120 × 48Height0.9585px horizontal, 2px vertical
Wide Button343 × 48Width ÷ 40.9778px horizontal, 1.1px vertical
List Item375 × 60Width ÷ 40.9798px horizontal, 1.3px vertical
Small Button22 × 22Minimum 240.9171.8px horizontal, 1.8px vertical

In the table, vertical reduction is 2px when basis is height. When width adjustment or minimum basis length is applied, basis becomes larger, so vertical reduction becomes less than 2px. In wide elements, vertical reduction nearly disappears, and horizontal edge movement conveys the pressed feeling instead.

Reduction Center Point

Reduction always occurs with the element's center as the reference point.

Center point and crosshair shown at the center of button, showing reduction occurs from that point

Reduction Does Not Change Position

Reduction does not affect the space the element occupies. Even if the pressed element becomes smaller, surrounding elements don't move, and pressing an item in a list doesn't change the position of items above or below.

When Applying to Custom-Built Elements

When applying reduction to components not provided by Crispy, check three things in order.

1. Check if reduction should be applied

Not all pressable elements become smaller.

Does it have a single defined area? Reduction is applied when an element's area is captured as a single surface. It's fine if the background isn't visible in the default state. Action Button's ghost button and individual tabs in Tabs have no background normally but are reduced because the area is ensured by padding and minimum height.

Conversely, don't apply it to elements placed within text like link text. If wrapping occurs, the area splits into multiple lines, and boundaries aren't visible within text flow. Even if reduced, it's unclear what reduced and appears as if the font size changed.

Action Button with surface — becomes smaller than original size when pressed

Text Button without surface — size stays the same when pressed, only background and color change

Are sub-actions equivalent to the entire element? Even if multiple actions exist within an element, apply reduction if the sub-action is subordinate to what the element represents. The Switch in List Item changes the setting that row represents, so it's subordinate to the row. The entire row can shrink unambiguously because any tap on it handles the same target.

Sub-action subordinate to row — List Item containing Switch responds entirely when tapped anywhere

Equivalent actions side-by-side — Close and Like buttons in a card each respond individually, not the entire card

Conversely, don't apply it when equivalent actions are side-by-side like open card, like, save, or go to author. Since each targets a different action, entire shrinking becomes ambiguous. The response is not the entire element but the actual target the user pressed, and each target has its own feedback.

2. Decide what shrinks

Root Scale — entire Switch becomes smaller together

Content Scale — Accordion background stays, only inner content becomes smaller

Determine by checking if alignment, padding, and corners appear misaligned when the entire element is reduced.

  • No misalignment → Root Scale. The entire element shrinks together. Elements like Action Button where background and content are perceived as one surface go here. Internal relationships remain intact even when everything shrinks together.
  • Appears misaligned → Content Scale. Background stays and only content shrinks. Structures like List Item, Accordion, or Select Box Item where the background spans full screen width with multiple elements aligned inside go here.

Shrinking this structure entirely causes three things to misalign simultaneously.

One List Item among vertically stacked items fully reduced, misaligning alignment, padding, and corners

  • Alignment — Elements aligned to left and right edges move inward, misaligning start lines with items above and below.
  • Padding — Background touching screen edges shrinks, changing from originally designed padding.
  • Corners — Corner radius shrinks together, misaligning curvature with surrounding elements.

Background rarely changes. However, for List Item where background spans full screen width with items divided by dividers, the background also expresses press by reducing horizontal padding and increasing corner radius.

3. Check if nested

If placed inside an already-reducing element, turn off the inner element's reduction. When two reductions overlap, ratios multiply, making only the inner element excessively small.

This applies to Checkmark inside List Item. When the entire row is pressed, Checkmark shrinks as part of the content but doesn't trigger its own separate reduction.

Applying via utility

After checking three things, there's no need to implement the formula directly. Each platform provides utilities.

PlatformUsage
ReactWrap the element to reduce with ScaleFeedback. For structures difficult to wrap, receive the same value via useScaleFeedback hook. The calculated ratio is also exposed as --seed-feedback-scale CSS variable. For cases like Content Scale needing to split background and content, apply this value only to the content side. See Scale Feedback guide.
LynxuseScaleFeedback measures elements on Main Thread and applies transform. Connecting trigger and target to the same element creates Self Scale; connecting to different elements creates Content Scale. See Lynx Scale Feedback guide.
iOSUIKit uses SeedPressedEffectInteraction, SwiftUI uses seedScaleEffect().
AndroidAttaching Modifier.dynamicScale() for Compose automatically applies ratio based on rendered actual size. For structures using clickable, pass indication = DynamicScaleIndication instead.

Just wrapping shrinks the entire element. For elements needing Content Scale, ratio should apply only to the content area, so check platform-specific application methods.

When Combined with Other States

Elements can have press and other states simultaneously. Since reduction only occurs while pressing, the original state expression is maintained and reduction is temporarily added.

Appearance when pressed in Selected, Loading, and Disabled states

  • Selected — Selected elements also shrink when pressed. Color expression showing selection state is maintained.
  • Loading — Does not shrink. An action is already in progress, so additional input isn't accepted.
  • Disabled — Does not shrink. It doesn't accept interaction, so no press response occurs.

See State for state definitions.

Accessibility

When the OS Reduce Motion setting is enabled, the ratio is always calculated as 1 and no reduction occurs. In this case, other state expressions like color change convey the press.

When Reduce Motion is off — color change and reduction occur together

When Reduce Motion is on — only color change occurs without reduction

Table of contents