Skip to content

Releases: nalexn/ViewInspector

0.9.2

17 Sep 13:59
ac7df67
Compare
Choose a tag to compare

Released on 2022-09-17.

Requires Xcode 14.0

What's new:

  • Adds support for SwiftUI 4.0

  • New APIs:

    • find(viewWithAccessibilityLabel: ) and find(viewWithAccessibilityIdentifier: ) (PR #168)
    • axes: Axis.Set and showsIndicators: Bool inspectable attributes on ScrollView
    • callOnSubmit inspection of the onSubmit modifier (PR #184)
    • primaryAction inspection support on Menu (#183)
    • Inspectable attributes on Rotation3D (PR #191)
    • Label(_:systemImage:) inspection (#176)
  • Fixes and PRs:

    • 'callOnChange' not recognizing Optional parameters (#163)
    • Error when accessing the keyboardType in TextField (#171)
    • Failure to find .background() when BackgroundView contains Color (#169)
    • Error 'Cannot find 'XCTFail' in scope' when integrating with CocoaPods (#145)

0.9.1

30 Dec 13:12
Compare
Choose a tag to compare

Released on 2021-12-30.

Requires Xcode 13.2

What's new:

  • Added inspection support for:

    • AsyncImage
    • Canvas
    • ControlGroup
    • LocationButton
    • SignInWithAppleButton
    • TimelineView
    • VideoPlayer
    • EllipticalGradient (PR #135)
    • ContainerRelativeShape
    • tint() (PR #139)
    • listItemTint() (PR #137)
    • overlayPreferenceValue() (#144)
    • backgroundPreferenceValue()
    • statusBarHidden()
  • New APIs:

    • isAbsent: Bool for checking if optional view is present. Requested in #129 and #136
    • classified() for erasing the type of the view to ViewType.ClassifiedView

Fixes and PRs:

  • Fixed 'Cannot find 'XCTFail' in scope' when integrating with CocoaPods (#145)
  • Fixed actualView() not injecting EnvironmentObjects (issue #149, PR #150)
  • Fixed find().actualView() gets type mismatch error on a nested view type within a custom generic container (#138)

Happy coming New Year!

0.9.0

19 Sep 21:39
Compare
Choose a tag to compare

Released on 2021-09-19.

Requires Xcode 13.0

What's new:

  • Added watchOS support (#125)
  • Existing inspection code updated for iOS 15 (#128)
  • Added support for Toolbar
  • Added support for safeAreaInset overlay
  • Added support for confirmationDialog
  • Inspector.print(:) is made public for easier view debugging

Breaking changes:

Fixes and PRs:

  • navigationBarItems no longer block the inspection starting from iOS 15 (#29)
  • Fixed Inspector.print(:) cyclic recursion (#105)
  • Fixed "callOnChange is not found on _ConditionalContent" (#126)
  • Fixed Shape views being reported as blockers for search (#133)
  • Merged PR #132: Adds support for FullScreenCover
  • Merged PR #124: Include ToolBarItem in readiness.md

0.8.1

17 Jun 10:15
Compare
Choose a tag to compare

Released on 2021-06-17.

  • Fixed compilation issues on Xcode 12.4 (#116)
  • Fixed some tests not passing for iOS 13
  • Merged PR #118: Fixed a link in the guide

0.8.0

15 Jun 11:16
Compare
Choose a tag to compare

Released on 2021-06-15.

  • Inspection of a custom ViewModifier is now fully aligned with a custom View inspection and is devoid of some shortcomings. Your existing tests won't break, but if you choose to migrate to the new one - please refer to the guide for updated snippets for the class Inspection. Kudos to @gili-labs for playing an essential role in the research and development of this feature.

  • A View that has applied custom ViewModifier now inherits view and environment modifiers applied inside that custom ViewModifier. See the example below:

struct MyModifier: ViewModifier {
    func body(content: Self.Content) -> some View {
        content
           .padding(.top, 15)
    }
}

let view = Text("Hi").modifier(MyModifier())

Before: Text would report it has no padding modifier applied.
Now: Text reports the padding applied from inside the MyModifier.

  • Merged PR #112: Added support for Map view inspection (requested in #59).
  • Added support for MapAnnotation inspection.

0.7.7

24 May 08:32
Compare
Choose a tag to compare

Released on 2021-05-24.

  • Merged PR #111: Fixed compilation issues for Xcode 12.4

0.7.6

23 May 14:51
Compare
Choose a tag to compare

Released on 2021-05-23.

  • Added support for inspecting Alert, ActionSheet and Sheet. Instructions are provided in the guide.

  • New func isResponsive() -> Bool for checking if the control is responsive to the user's touch input.

  • All controls that are disabled, hidden or with allowsHitTesting(false) now throw an exception on attempt to programmatically trigger a user interaction.

  • Many of the view modifiers that impose their effect on the enclosed hierarchy, such as hidden, are now associated with the inner views as well.

  • Merged PR #107: Disabled Button throws an exception on tap attempt.

  • Merged PR #109: Added API for selecting a date with DatePicker

  • Fixed #104