Gauge
原生 SwiftUI 仪表,支持线性和圆形附属样式。
#导入
从 @quickgui/solid/swift-ui 导入 Gauge。
import { Host, Gauge } from "@quickgui/solid/swift-ui";#用法
<Host matchContents>
<Gauge
value={storageUsed()}
min={0}
max={100}
label="Storage"
currentValueLabel={String(storageUsed()) + "%"}
style="accessoryCircularCapacity"
/>
</Host>#API 参考
展开条目查看说明和完整签名。短横线表示声明中未记录默认值。
Gauge
查看源码Gauge(props: GaugeProps): NativeNodetestIDstring—
modifiersViewModifier[]—
valuenumber—
minnumber—
maxnumber—
labelstring—
currentValueLabelstring—
Declares currentValueLabel (optional). Reactive JSX expressions update this property in place.
string查看源码minimumValueLabelstring—
Declares minimumValueLabel (optional). Reactive JSX expressions update this property in place.
string查看源码maximumValueLabelstring—
Declares maximumValueLabel (optional). Reactive JSX expressions update this property in place.
string查看源码styleGaugeStyle—
ref((node: NativeNode) => void) | NativeNode—
Declares ref (optional). Reactive JSX expressions update this property in place.
((node: NativeNode) => void) | NativeNode查看源码