Contents

AssignedDocumentLabel

A view that displays the status or date information of the assigned document.

Declaration

@MainActor @preconcurrency struct AssignedDocumentLabel

Overview

AssignedDocumentLabel displays information about an assigned document for students, including submission status and relevant dates like due dates. The view automatically updates its appearance based on assigned document state, showing past-due items in red.

VStack(alignment: .leading) {
    Text("My Document")
        .font(.headline)

    HStack {
        AssignedDocumentLabel(role: .status, documentURL: documentURL)
        AssignedDocumentLabel(role: .date, documentURL: documentURL)
    }
    .font(.caption)
}

Topics

Structures

Initializers