Displaying a notification

MacLib gives you access to a built-in notification system, providing you with an easy way to display alerts and messages seamlessly within your UI.

Window:Notify({
    Title <string>
    Description <string>
    Lifetime <number>
    Scale <number>
    SizeX = <number>
    Style <string: "None", "Confirm", "Cancel"> -- The type of button that the user interacts with, input "None" for no interactable (or leave nil), input "Confirm" for a checkmark, and input "Cancel" for a crossmark.
    Callback <function(): void>
})

Functions

:UpdateTitle(<string>)
:UpdateDescription(<string>)
:Resize(<number>) -- Only X, Y is automatically determined by the content size
:Cancel()

Example

Window:Notify({
    Title = "Kuzu Hub",
    Description = "Hello, World!",
    Lifetime = 5
})

Last updated

Was this helpful?