fix(omega-mac): support macOS 14 by replacing macOS 15-only APIs

- Add `indirect` to recursive JSONSchemaAdditional enum
- Replace `.accent` ShapeStyle (macOS 15+) with `Color.accentColor`
- Add .gitignore for .build directory
This commit is contained in:
Ajax Davis 2026-02-09 22:32:37 +10:00
parent dda28d642c
commit 894f9842d1
8 changed files with 41 additions and 7 deletions

1
apps/omega-mac/.gitignore vendored Normal file
View file

@ -0,0 +1 @@
.build

View file

@ -89,7 +89,7 @@ struct JSONSchemaProperty: Encodable {
}
}
enum JSONSchemaAdditional: Encodable {
indirect enum JSONSchemaAdditional: Encodable {
case bool(Bool)
case typed(JSONSchemaProperty)

View file

@ -32,7 +32,7 @@ struct ChatInputBar: View {
Button(action: onSend) {
Image(systemName: "arrow.up.circle.fill")
.font(.title2)
.foregroundStyle(canSend ? .accent : .tertiary)
.foregroundStyle(canSend ? Color.accentColor : Color.secondary)
}
.buttonStyle(.borderless)
.disabled(!canSend)

View file

@ -23,7 +23,7 @@ struct MessageBubble: View {
.font(.body)
.foregroundStyle(.white)
.padding(12)
.background(.accent)
.background(Color.accentColor)
.clipShape(RoundedRectangle(cornerRadius: 12))
.textSelection(.enabled)
}

View file

@ -71,7 +71,7 @@ struct MessageList: View {
if isStreaming {
Rectangle()
.fill(.accent)
.fill(Color.accentColor)
.frame(width: 2, height: 16)
.opacity(0.8)
.modifier(PulseAnimation())

View file

@ -7,7 +7,7 @@ struct StreamingIndicator: View {
var body: some View {
HStack(spacing: 6) {
Image(systemName: "sparkles")
.foregroundStyle(.accent)
.foregroundStyle(Color.accentColor)
.font(.caption)
Text("Omega is thinking" + String(repeating: ".", count: dotCount))

View file

@ -7,7 +7,7 @@ struct EmptyStateView: View {
VStack(spacing: 20) {
Image(systemName: "star.circle.fill")
.font(.system(size: 56))
.foregroundStyle(.accent)
.foregroundStyle(Color.accentColor)
.symbolEffect(.pulse, options: .repeating)
Text("Omega")
@ -43,7 +43,7 @@ struct EmptyStateView: View {
HStack(spacing: 10) {
Image(systemName: icon)
.frame(width: 20)
.foregroundStyle(.accent)
.foregroundStyle(Color.accentColor)
Text(text)
.font(.callout)
.foregroundStyle(.secondary)

View file

@ -0,0 +1,33 @@
{
"originHash" : "4ab20d6f9b3760314be6c8d471432a312fe8c0dbb4f3f28d71f6a6e9d6f6262d",
"pins" : [
{
"identity" : "networkimage",
"kind" : "remoteSourceControl",
"location" : "https://github.com/gonzalezreal/NetworkImage",
"state" : {
"revision" : "2849f5323265386e200484b0d0f896e73c3411b9",
"version" : "6.0.1"
}
},
{
"identity" : "swift-cmark",
"kind" : "remoteSourceControl",
"location" : "https://github.com/swiftlang/swift-cmark",
"state" : {
"revision" : "5d9bdaa4228b381639fff09403e39a04926e2dbe",
"version" : "0.7.1"
}
},
{
"identity" : "swift-markdown-ui",
"kind" : "remoteSourceControl",
"location" : "https://github.com/gonzalezreal/swift-markdown-ui",
"state" : {
"revision" : "5f613358148239d0292c0cef674a3c2314737f9e",
"version" : "2.4.1"
}
}
],
"version" : 3
}