How to display static text in a Pega Constellation view?

I’m working with Pega Constellation and need to display a piece of static text in a view.

For example, I want to show a message like:

“Your country is USA”

What’s the best way to add static or read-only text to a Constellation view?

Ideally, I’m looking for something similar to a label, paragraph, or a read-only field.

@AchinthaJ the Constellation Design System has four places for showing information in context to a business user:

  1. Additional Information on a field- this shows up as an Information Icon, once clicked it will show the text
    1. This can be found in the advanced section when creating a new field in the Data Model Tab of a Case or Data Object
  2. Helper text on a field - this shows up as helper text under the field. Configured in a View
  3. Assignment instructions - this shows up at the top of a form. Configured in the top level View
  4. Contextual message to a field - a warning shown based on conditions
    1. New to infinity '25

Outside of that, you can also look at extending your Constellation UI to do banners. You’d have to assess if extending your Constellation is worth the time/investment but we provide an example on our Gitbhub to get you started:

More information can be found here.

Thanks for the clarification @MarcCheong. However, I wasn’t referring to additional information, helper text, or assignment instructions.

What I’m actually looking for is a way to display static text, similar to how we used labels in section rules in the traditional Pega UI.

For example, if a user selects “USA” from the country dropdown, I want to show a static text/label below the field saying: “Your country is USA.”

That’s the kind of behavior I’m trying to implement.

@AchinthaJ

I don’t believe there is currently a direct equivalent. I’ve dealt with a similar customer requirement. There are a things to try:

  1. The Banner Input control listed above can work, if you want to alert the user in a prominent area of the screen.
  2. You could use a text field to display this info. You’ll need a data transform to set the text value. If you want do set this dynamically, you might want to use the Form Refresh settings to call your DT upon change of your dropdown.
  3. You could create a custom DX component based on a text field and changes the behavior. This is an enhancement of option #2. I built one of these a while ago, so you can could configure the text value statically at design time, without using a data transform.

Hope this helps!

@AchinthaJas @len01 has articulated, there are multiple options.

One word of caution, the option 2 mentioned (rich text), did trigger a memory for me. I have seen projects do this and as a result the screen layout is quite messy.

  • Anything you do, would not be associated with your “select country” control.
  • Screenreaders would not read it correctly
  • Responsiveness and wrapping of controls won’t be visually group.

As a result you start to break the usability and accessibility that is built out of the box. You get a lot with the Constellation Design System, things you no longer have to worry about - if you start breaking apart that design system then total cost of ownership will increase.