DropView Documentation

Extensions on View

Methods

drop(item:​alignment:​dismissing​After:​dismissing​OnDrag:​content:​)

@ViewBuilder func drop<I: Identifiable, C: View>(
        item: Binding<I?>,
        alignment: VerticalAlignment = .top,
        dismissingAfter timer: TimeInterval = 2,
        dismissingOnDrag shouldDismissOnDrag: Bool = true,
        @ViewBuilder content: @escaping (I) -> C
    ) -> some View  

Morty Proxy This is a proxified and sanitized view of the page, visit original site.

Overlay a drop view.

Parameters

is​Presented

An optional Identifiable binding.

alignment Vertical​Alignment

A valid VerticalAlignment. Defaults to .top.

timer Time​Interval

The time before it gets autodismissed. Defaults to 2.

should​Dismiss​OnDrag Bool

Whether dragging the drop view should dismiss it or not. Defaults to true.

content @escaping (I) -> C

The drop view factory.

Returns

Some View.

drop(is​Presented:​alignment:​dismissing​After:​dismissing​OnDrag:​content:​)

@ViewBuilder func drop<C: View>(
        isPresented: Binding<Bool>,
        alignment: VerticalAlignment = .top,
        dismissingAfter timer: TimeInterval = 2,
        dismissingOnDrag shouldDismissOnDrag: Bool = true,
        @ViewBuilder content: @escaping () -> C
    ) -> some View  

Morty Proxy This is a proxified and sanitized view of the page, visit original site.

Overlay a drop view.

Parameters

is​Presented Binding<Bool>

An optional Bool binding.

alignment Vertical​Alignment

A valid VerticalAlignment. Defaults to .top.

timer Time​Interval

The time before it gets autodismissed. Defaults to 2.

should​Dismiss​OnDrag Bool

Whether dragging the drop view should dismiss it or not. Defaults to true.

content @escaping () -> C

The drop view factory.

Returns

Some View.

drop​View​Balancing(_:​)

func dropViewBalancing(_ balancing: Balancing) -> some View  

Morty Proxy This is a proxified and sanitized view of the page, visit original site.

Update the drop view Balancing style.

Parameters

balancing Balancing

A valid Balancing.

Returns

Some View.

drop​View​Separator​Color(_:​)

func dropViewSeparatorColor(_ separatorColor: Color) -> some View  

Morty Proxy This is a proxified and sanitized view of the page, visit original site.

Update the drop view separator color style.

Parameters

separator​Color Color

A valid Color.

Returns

Some View.

drop​View​Shadow(_:​)

func dropViewShadow(_ shadow: Shadow) -> some View  

Morty Proxy This is a proxified and sanitized view of the page, visit original site.

Update the drop view separator shadow style.

Parameters

shadow Shadow

A valid Shadow.

Returns

Some View.

drop​View​Shadow(color:​radius:​x:​y:​)

func dropViewShadow(
        color: Color = .black,
        radius: CGFloat,
        x: CGFloat = 0,
        y: CGFloat = 0
    ) -> some View  

Morty Proxy This is a proxified and sanitized view of the page, visit original site.

Update the drop view separator shadow style.

Parameters

color Color

The shadow color. Defaults to .black.

radius CGFloat

The shadow radius.

x CGFloat

The shadow x offset. Defaults to 0.

y CGFloat

The shadow y offset. Defaults to 0.

Returns

Some View.

shadow(_:​)

func shadow(_ shadow: Shadow) -> some View  

Morty Proxy This is a proxified and sanitized view of the page, visit original site.

Apply a given Shadow.

Parameters

shadow Shadow

A valid Shadow.

Returns

Some View.

drop​View​Background​Color(_:​)

func dropViewBackgroundColor(_ backgroundColor: Color) -> some View  

Morty Proxy This is a proxified and sanitized view of the page, visit original site.

Update the drop view background color style.

Parameters

background​Color Color

A valid Color.

Returns

Some View.

Morty Proxy This is a proxified and sanitized view of the page, visit original site.