swiftui_SwiftUI中的活动指示器

swiftui

Some of the examples below use a timer to control the loading screen. In real-life scenarios, you might need to use the number of bytes downloaded or uploaded or whatever value makes sense to you and works with your project.

下面的一些示例使用计时器来控制加载屏幕。 在现实生活中,您可能需要使用下载或上传的字节数或任何对您有意义的值,并可以与您的项目一起使用。

We will start with the basic activity indicator.

我们将从基本活动指标开始。

基本活动指标 (Basic Activity Indicator)

Image for post
Basic activity indicator code
基本活动指标代码
Image for post
Basic activity indicator
基本活动指标

微调器活动指示器 (Spinner Activity Indicator)

Image for post
Spinner — activity indicator
微调框-活动指示器
Image for post
Spinner — activity indicator
微调框-活动指示器

载入文字 (Loading Text)

Image for post
Loading text code — activity indicator
加载文本代码-活动指示器
Image for post
Loading text — activity indicator
载入文字-活动指示器

加载栏 (Loading Bar)

Image for post
Loading bar code — activity indicator
加载条形码-活动指示器
Image for post
Loading bar — activity indicator
加载栏-活动指示器

半圆微调器 (Half-Circles Spinner)

Image for post
Half-circles spinner code — activity indicator
半圆微调器代码-活动指示器
Image for post
Half-circles spinner— activity indicator
半圆微调器-活动指示器

加载圈 (Loading Circle)

Image for post
Loading circle code— activity indicator
正在加载圈子代码-活动指示器
Image for post
Loading circle — activity indicator
加载圈-活动指示器

Thanks for reading!

谢谢阅读!

翻译自: https://medium.com/better-programming/activity-indicators-in-swiftui-17b66e6c0137

swiftui

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值