Skip to content

Implement ignoresSafeArea modifier #505

@Kyle-Ye

Description

@Kyle-Ye

Description

The ignoresSafeArea (formerly edgesIgnoringSafeArea) modifier allows views to extend into the safe area regions of the display. This is essential for full-screen backgrounds and edge-to-edge content.

API Reference

SwiftUI's ignoresSafeArea: https://developer.apple.com/documentation/swiftui/view/ignoressafearea(_:edges:)

Expected API

extension View {
    func ignoresSafeArea(
        _ regions: SafeAreaRegions = .all,
        edges: Edge.Set = .all
    ) -> some View
}

struct SafeAreaRegions: OptionSet {
    static let container: SafeAreaRegions
    static let keyboard: SafeAreaRegions
    static let all: SafeAreaRegions
}

Current Status

  • SafeAreaInsets exists in: Sources/OpenSwiftUICore/Layout/SafeAreaInsets.swift
  • Modifier implementation is missing or incomplete

Use Case

Required for:

  • Full-screen backgrounds
  • Edge-to-edge content
  • Immersive UI experiences
  • Currently commented out in example code

References

  • Example usage commented out in: Example/SharedExample/Animation/Timeline/AnimatedColorTimelineView.swift
  • Related safe area code: Sources/OpenSwiftUICore/Layout/SafeAreaInsets.swift

Priority

Medium - Important for professional UI layouts but not blocking basic functionality

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1Medium priorityenhancementNew feature or requesthelp wantedPR contribution is appreciated

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions