DEV Community

Thom
Thom

Posted on

6 3

UI Builder: Add a page-level success alert message

If you want to add a success or any other notification, you can fire an event in a client script. The OOTB event you can fire is the 'NOW_UXF_PAGE#ADD_NOTIFICATIONS'.

To see what other configuration you can make to the alert message, you can use the component playground:
Component Playground

    api.emit('NOW_UXF_PAGE#ADD_NOTIFICATIONS', {
        items: [{
            status: 'positive',
            icon: 'thumbs-up-outline',
            header: 'Success: ',
            content: 'Record was created',
            action: {
                type: 'dismiss'
            }
        }]
    });
Enter fullscreen mode Exit fullscreen mode

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay