Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion website/docs/getting-started/introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,9 @@ const activityUI = (
<Voltra.Symbol name="car.fill" type="hierarchical" scale="large" tintColor="#38BDF8" />
<Voltra.Text style={{ color: '#F8FAFC', fontSize: 18, fontWeight: '600' }}>Driver en route</Voltra.Text>
<Voltra.Text style={{ color: '#94A3B8', fontSize: 12, marginTop: 8 }}>Building A · Lobby pickup</Voltra.Text>
<Voltra.Button title="Contact driver" id="contact-driver" style={{ marginTop: 12 }} />
<Voltra.Button id="contact-driver" style={{ marginTop: 12 }}>
<Voltra.Text>Contact driver</Voltra.Text>
</Voltra.Button>
</Voltra.VStack>
)

Expand Down
4 changes: 3 additions & 1 deletion website/docs/ios/components/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ const MyComponent = () => {
return (
<Voltra.VStack spacing={8}>
<Voltra.Text>Hello Live Activity!</Voltra.Text>
<Voltra.Button title="Tap me" />
<Voltra.Button>
<Voltra.Text>Tap me</Voltra.Text>
</Voltra.Button>
</Voltra.VStack>
)
}
Expand Down
4 changes: 3 additions & 1 deletion website/docs/ios/development/developing-live-activities.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,9 @@ function MyComponent() {
<Voltra.VStack style={{ padding: 16, backgroundColor: '#101828' }}>
<Voltra.Text style={{ color: '#F8FAFC', fontSize: 18, fontWeight: '600' }}>Test Live Activity</Voltra.Text>
<Voltra.Text style={{ color: '#94A3B8', fontSize: 12, marginTop: 8 }}>This is how it will look</Voltra.Text>
<Voltra.Button title="Test Button" id="test-button" style={{ marginTop: 12 }} />
<Voltra.Button id="test-button" style={{ marginTop: 12 }}>
<Voltra.Text>Test Button</Voltra.Text>
</Voltra.Button>
</Voltra.VStack>
</VoltraView>
)
Expand Down
12 changes: 9 additions & 3 deletions website/docs/ios/development/interactions.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@ Each interaction event contains:
To receive interaction events, make sure your interactive components have unique identifiers:

```typescript
<Voltra.Button title="Contact driver" id="contact-driver" />
<Voltra.Button id="contact-driver">
<Voltra.Text>Contact driver</Voltra.Text>
</Voltra.Button>
<Voltra.Toggle title="Enable notifications" id="notifications-toggle" />
```

Expand Down Expand Up @@ -140,8 +142,12 @@ function MyLiveActivity() {
lockScreen: (
<Voltra.VStack>
<Voltra.Text>Music Player</Voltra.Text>
<Voltra.Button title="Play" id="play-button" />
<Voltra.Button title="Pause" id="pause-button" />
<Voltra.Button id="play-button">
<Voltra.Text>Play</Voltra.Text>
</Voltra.Button>
<Voltra.Button id="pause-button">
<Voltra.Text>Pause</Voltra.Text>
</Voltra.Button>
<Voltra.Toggle title="Shuffle" id="shuffle-toggle" />
</Voltra.VStack>
),
Expand Down
11 changes: 9 additions & 2 deletions website/docs/ios/development/server-side-updates.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ The `renderLiveActivityToString` function accepts a `LiveActivityVariants` objec

When sending push notifications to update Live Activities, you need to structure your APNS payload correctly. For detailed information about APNS payload structure, see Apple's [official ActivityKit push notification documentation](https://developer.apple.com/documentation/activitykit/starting-and-updating-live-activities-with-activitykit-push-notifications).

You can also use Apple’s [CloudKit - Push Notifications tool](https://icloud.developer.apple.com/dashboard/notifications/) to send test push notifications during development.

### Required APNS headers

```
Expand Down Expand Up @@ -132,18 +134,23 @@ Replace `<your.app.bundle.id>` with your app's bundle identifier (e.g., `com.exa
"name": "some-name",
"deepLinkUrl": "app://some-deep-link-url"
},
"timestamp": 1764145755
"timestamp": 1764145755,
"alert": {
"title": "Driver arrived",
"body": "Ready for pickup"
}
}
}
```

**Key fields:**

- `aps.event`: Set to `"update"` for updating an existing Live Activity, or `"start"` for push-to-start (iOS 17.2+)
- `aps.content-state.uiJsonData`: The JSON string returned by `renderLiveActivityToString`, embedded as a string value
- `aps.content-state.uiJsonData`: The JSON string returned by `renderLiveActivityToString`, embedded as a string value eg. `ixOAeyJ2IjoxLCJscyI6eyJ0IjowLCJjIjoiSGVsbG8sIHdvcmxkISJ9fQM=`
- `aps.timestamp`: Unix timestamp in seconds (required for Live Activities)
- `aps.attributes-type`: For push-to-start, must be `"VoltraAttributes"`
- `aps.attributes.name`: For push-to-start, a user-defined name for the activity (can be any string you choose)
- `aps.alert`: Required field for push-to-start

:::danger
ActivityKit enforces a strict payload size limit of approximately 4 KB. Keep your UI JSON minimal to stay within this limit. Avoid deeply nested component trees and excessive styling to ensure your payloads fit within the constraint.
Expand Down
4 changes: 3 additions & 1 deletion website/docs/ios/introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ const activityUI = (
<Voltra.Symbol name="car.fill" type="hierarchical" scale="large" tintColor="#38BDF8" />
<Voltra.Text style={{ color: '#F8FAFC', fontSize: 18, fontWeight: '600' }}>Driver en route</Voltra.Text>
<Voltra.Text style={{ color: '#94A3B8', fontSize: 12, marginTop: 8 }}>Building A · Lobby pickup</Voltra.Text>
<Voltra.Button title="Contact driver" id="contact-driver" style={{ marginTop: 12 }} />
<Voltra.Button id="contact-driver" style={{ marginTop: 12 }}>
<Voltra.Text>Contact driver</Voltra.Text>
</Voltra.Button>
</Voltra.VStack>
)

Expand Down
Loading