How to customize the Restore button (colvis).

How to customize the Restore button (colvis).

lenamtllenamtl Posts: 261Questions: 64Answers: 1
edited August 8 in Free community support

Hi,

I'm looking for a way to customize the Restore button (colvis).
The restore button look like the column button and this is not very intuitive.

I would like to add an icon before the name or something that would make the icon look like different.
Any clue?

Ref
https://datatables.net/extensions/buttons/examples/column_visibility/restore.html
Note I'm using BS5

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 56,837Questions: 1Answers: 9,033 Site admin

    It has the class of buttons-colvisRestore which you can use to customise its styling and you can use the language option language.buttons.colvisRestore in the DataTables initialisation to customise the text.

    Allan

  • lenamtllenamtl Posts: 261Questions: 64Answers: 1

    Is there a way to add an icon / CSS in language....

  • allanallan Posts: 56,837Questions: 1Answers: 9,033 Site admin
    Answer ✓

    Yes:

    .buttons-colvisRstore::before {
      display: block;
      content: '...'; // change to a utf8 icon of your choice
    }
    

    Or you could just use the language option.

    Allan

Sign In or Register to comment.