Skip to content
Verified Avatar preview
Rendered from the SwiftUI source on this page.

Verified Avatar

From syxUI — written for both platforms, not translated between them.

An avatar with a verified badge.

Avatars · SwiftUI · iOS 17

  • avatars
  • swiftui

The actual source

AvatarBadgeVerified.swift
// Verified Avatar · syxUI · https://syxui.dev/components/avatar-verified
// Free in any project. Keep this line and credit syxUI where a person can read it.

import SwiftUI

let avBlue = Color(red: 0.0, green: 0.47, blue: 1.0)

func av(_ name: String, _ d: CGFloat) -> some View { Image(name).resizable().scaledToFill().frame(width: d, height: d).clipShape(Circle()) }

struct AvatarBadgeVerified: View { var body: some View { av("person_5", 66).overlay(alignment: .bottomTrailing) { Image(systemName: "checkmark.seal.fill").font(.system(size: 22)).foregroundStyle(avBlue).background(Circle().fill(Color(.systemBackground)).frame(width: 20, height: 20)) } } }
iOS 17 · 1 dependencies

Dependencies

SwiftUI
  • person_5 (image asset)

Requires iOS 17