Modifiers
imageScale
Scales SF Symbols within this view relative to the surrounding text, using one of the standard sizes.
imageScale(scale)
| Parameter | Type | Description |
|---|---|---|
scale | 'small' | 'medium' | 'large' | The relative image scale. |
Scales SF Symbols within this view relative to the surrounding text, using one of the standard sizes.
Returns: ModifierConfig
See: Official SwiftUI documentation.
Works with
You can add imageScale to any view. It changes what you see on 25 of the 39 components.
No visible effect
These components accept it, but you see no change.
| Component | Why nothing happens |
|---|---|
| Spacer | It changes only SF Symbols, and Spacer shows none. |
| Divider | It changes only SF Symbols, and Divider shows none. |
| Toggle | It changes only SF Symbols, and Toggle shows none. |
| Checkbox | It changes only SF Symbols, and Checkbox shows none. |
| Slider | It changes only SF Symbols, and Slider shows none. |
| Picker | It changes only SF Symbols, and Picker shows none. |
| DatePicker | It changes only SF Symbols, and DatePicker shows none. |
| ColorPicker | It changes only SF Symbols, and ColorPicker shows none. |
| TextField | It changes only SF Symbols, and TextField shows none. |
| SecureField | It changes only SF Symbols, and SecureField shows none. |
| Text | It changes only SF Symbols, and Text shows none. |
| ProgressView | It changes only SF Symbols, and ProgressView shows none. |
| Gauge | It changes only SF Symbols, and Gauge shows none. |
| AccessoryWidgetBackground | It changes only SF Symbols, and AccessoryWidgetBackground shows none. |
Sources
The original Expo docs for this page:
- imageScale (Modifiers) (
source-of-truth/versions/v57.0.0/sdk/ui/swift-ui/modifiers.md)