Skip to content

Feature Request: Support for Radial Boundary (Circular Drag Constraint) #14

@Rspoon3

Description

@Rspoon3

Thanks for this great library! I’ve been using SnapDraggingModifier and really like the intuitive UX it enables.

Currently, the API supports horizontal and vertical boundaries:

SnapDraggingModifier(
  gestureMode: .normal,
  offset: $offset,
  horizontalBoundary: .init(min: -50, max: 50, bandLength: 50),
  verticalBoundary: .init(min: -50, max: 50, bandLength: 50)
)

However, I’d love to see support for a radial (circular) boundary, where the drag is constrained to a circle around a center point. This would make the experience feel more like the view is “leashed” to a certain point — great for circular controls, knobs, or playful UI elements.

Would you consider adding this feature or supporting a custom boundary shape?

Thanks again!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions