Skip to content

Commit 63e4f92

Browse files
Updated CI to Xcode 13.3
1 parent 3a5c7d1 commit 63e4f92

File tree

10 files changed

+21
-16
lines changed

10 files changed

+21
-16
lines changed

.github/workflows/smoke-checks.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ env:
2121
jobs:
2222
automated-code-review:
2323
name: Automated Code Review
24-
runs-on: macos-11
24+
runs-on: macos-12
2525
steps:
2626
- uses: actions/checkout@v1
2727
- uses: ./.github/actions/set-build-image-var
@@ -49,7 +49,7 @@ jobs:
4949

5050
build-and-test-ui-debug:
5151
name: Test SwiftUI (Debug)
52-
runs-on: macos-11
52+
runs-on: macos-12
5353
steps:
5454
- uses: actions/checkout@v1
5555
- name: Set build image var
@@ -69,14 +69,14 @@ jobs:
6969
key: ${{ runner.os }}-mint-${{ hashFiles('./Mintfile') }}
7070
restore-keys: ${{ runner.os }}-mint-
7171
- uses: ./.github/actions/bootstrap
72-
- name: Prepare iPhone 12 with iOS 15.0
72+
- name: Prepare iPhone 12 with iOS 15.3
7373
uses: ./.github/actions/prepare-ios-simulator
7474
with:
7575
device: "iPhone 12"
76-
ios: "15.2"
77-
xcode: "13.2.1"
76+
ios: "15.3"
77+
xcode: "13.3"
7878
- name: Run Tests (Debug)
79-
run: bundle exec fastlane test_ui device:"iPhone 12 (15.2)"
79+
run: bundle exec fastlane test_ui device:"iPhone 12 (15.3)"
8080
- uses: codecov/codecov-action@v1
8181
with:
8282
token: ${{ secrets.CODECOV_TOKEN }}
@@ -96,7 +96,7 @@ jobs:
9696

9797
build-apps:
9898
name: Build Demo App
99-
runs-on: macos-11
99+
runs-on: macos-12
100100
steps:
101101
- uses: actions/checkout@v1
102102
- name: Set build image var

DemoAppSwiftUI/CustomComposerAttachmentView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class CustomAttachmentsFactory: ViewFactory {
8080
) -> some View {
8181
let contactAttachments = message.attachments(payloadType: ContactAttachmentPayload.self)
8282
return VStack {
83-
ForEach(0..<contactAttachments.count) { i in
83+
ForEach(0..<contactAttachments.count, id: \.self) { i in
8484
let contact = contactAttachments[i]
8585
CustomContactAttachmentPreview(
8686
contact: CustomAttachment(

Sources/StreamChatSwiftUI/ChatChannel/Composer/Suggestions/InstantCommands/InstantCommandsView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ struct InstantCommandsView: View {
2020
InstantCommandsHeader()
2121
.standardPadding()
2222

23-
ForEach(0..<instantCommands.count) { i in
23+
ForEach(0..<instantCommands.count, id: \.self) { i in
2424
let command = instantCommands[i]
2525
if let displayInfo = command.displayInfo {
2626
InstantCommandView(displayInfo: displayInfo)

Sources/StreamChatSwiftUI/ChatChannel/Gallery/GalleryView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ struct GalleryView: View {
3838
)
3939

4040
TabView(selection: $selected) {
41-
ForEach(0..<sources.count) { index in
41+
ForEach(0..<sources.count, id: \.self) { index in
4242
let url = sources[index]
4343
ZoomableScrollView {
4444
VStack {

Sources/StreamChatSwiftUI/ChatChannel/MessageList/GiphyAttachmentView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public struct GiphyAttachmentView<Factory: ViewFactory>: View {
4848

4949
if !giphyActions.isEmpty {
5050
HStack {
51-
ForEach(0..<giphyActions.count) { index in
51+
ForEach(0..<giphyActions.count, id: \.self) { index in
5252
let action = giphyActions[index]
5353
Button {
5454
execute(action: action)

StreamChatSwiftUI.xcodeproj/xcshareddata/xcschemes/DemoAppSwiftUI.xcscheme

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,11 +47,6 @@
4747
BlueprintName = "StreamChatSwiftUITests"
4848
ReferencedContainer = "container:StreamChatSwiftUI.xcodeproj">
4949
</BuildableReference>
50-
<SkippedTests>
51-
<Test
52-
Identifier = "MessageContainerView_Tests">
53-
</Test>
54-
</SkippedTests>
5550
</TestableReference>
5651
</Testables>
5752
</TestAction>
Loading
Loading
Loading

docusaurus/docs/iOS/swiftui/view-customizations.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,13 @@ var body: some Scene {
4545
```
4646

4747
And that's everything we need to do to provide our own version of some of the views used in the SDK.
48+
49+
### Build Time Improvements
50+
51+
If you are customizing many view slots (over 15) from the SDK, and you have many generics in your codebase, it's good idea to explicitly specify the types of your custom views with `typealias`. This will improve the build time of your project.
52+
53+
```swift
54+
typealias MoreActionsView = MoreChannelActionsView
55+
```
56+
57+
You can find all the associated types we use in the `ViewFactory` [here](https://github.com/GetStream/stream-chat-swiftui/blob/main/Sources/StreamChatSwiftUI/ViewFactory.swift).

0 commit comments

Comments
 (0)