One Logo Pool Ball
ClassKitUI · IOS API REFERENCE

AssignedDocumentDeferredMenuElement

class · iOS 26.4+ · SDK 27.1

@MainActor @objc @preconcurrency class AssignedDocumentDeferredMenuElement

A deferred menu element that provides assigned document submission functionality. `AssignedDocumentDeferredMenuElement` enables students to submit and withdraw assigned documents directly from UIKit menus. The menu element loads asynchronously, fetching document metadata from ClassKit and displaying the appropriate action based on the current submission status. The element shows an in-line spinner during both initial loading and submission processing. The following example shows how to create an assigned document menu item and customize its behavior with validation and completion actions: ```swift // Create a basic assigned document submission menu element let menuElement = AssignedDocumentDeferredMenuElement(documentURL: documentURL) menu.children = [menuElement] // Create menu item with validation and logging let menuElement = AssignedDocumentDeferredMenuElement( documentURL: documentURL, willSubmit: { url in // Validate the assigned document before submission guard await validateDocument(url) else { await showAlert("Please complete all sections before submitting") return false // Prevents submission } return true // Allows submission to continue }, didSubmit: { url in // Handle successful submission logEvent("Assigned document submitted successfully!") } ) // Add the configured item to the menu menu.addItem(menuItem) ```

Members (0)

This type has no directly callable members in this snapshot. See the framework’s skipped declarations for unsupported APIs.

Skipped declarations

1 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.

AssignedDocumentDeferredMenuElement.init(documentURL:willSubmit:didSubmit:willWithdraw:didWithdraw:)

This Swift callback must itself suspend asynchronously. (nonthrowing, so a rejected promise cannot reach swift)

All ClassKitUI types →