Custom Section in summary

Hello, I would be interested in having a section on my summary part with custom html inside. A bit like how a smart view component is working. I went through the documentation but I cannot seem to wrap my head around a working solution

I also would like to know if its possible to display, again in the summary, a section which fetch data from an API call, basically make a http request from a summary section

is that possible by any chance ?
Thanks for your help

Hello @Nicolas_Girardot,

For the moment it’s not possible to use custom section in the details view, but I’m adding your suggestion in our product board, that regroups all feature requests.

Thanks for the reply, so It doesn’t work it the details view, but neither in the summary section right ?

If I want to show a custom made progress bar which is generated from the collection data. It seems like it’s not possible either. Am i mistaking ?

You are right, we cannot use custom code in this part of the app either.

Hi @Nicolas_Girardot,

If you want to show a static progress bar based on your record data, you can create a Smart Field for it.

In the get function you will return your HTML directly, something like:

    {
      field: 'progress',
      type: 'String',
      get: (record) => {
        return `<progress id="file" value="${record.value}" max="100"> ${record.value} </progress>`;
      },
    }

and you need to set the display widget of this field to Rich Text in the display settings of the field.

Then you will be able to add, with the layout editor, this field to a section of your summary view and have something like that

image

You can use the same smart field approach to make asynchronous calls to external APIs and render the data in the UI.

Let me know if that helps or if you have any further questions.

Thanks @olesyak, I’m starting to get the hang of it.

It seems like the progress bar though cannot be showed in a table view, only on the display view of the collection. Am I mistaking ?

Thanks in advance !

Hi @Nicolas_Girardot,

You are right, we do not support the Rich text widget for the table view.

But this will for sure work on the summary view :slightly_smiling_face:

I might push this request to our product team, but as far as I remember this was already discussed and rejected :confused:

1 Like