Format Boolean 'tick' box in Display Form

Home Forums General discussion Format Boolean 'tick' box in Display Form

Tagged: ,

Viewing 2 reply threads
  • Author
    Posts
    • #23660
      Maciek Grischke
      Participant

        Hello,

        I enjoy DFFS every single day! Thank you so much for what you do Alexander!!!

        I’m struggling to get my idea across. I want to customise a tick box,

        screenshot

        I’d like to change its colour or even change it to Yes/No text.

        How can I achieve this?

      • #23668
        Alexander Bautz
        Keymaster

          Hi,
          I’m happy to hear you like DFFS!

          You can add this snippet to your Custom JS to hide the checkbox and show Yes / No instead:

          function dffs_ready(){
              setTimeout(function(){
                  jQuery(".spjs_boolean_readonly").parent().hide().prev().removeClass("spjshidden");
              },10);
          }

          If you want to style it instead, you can add this to your Custom CSS:

          .spjs_boolean_readonly{
              font-size:18px!important;
              color:green!important;
          }

          Alexander

        • #23816
          Maciek Grischke
          Participant

            Thanks Alexander, this worked great!

        Viewing 2 reply threads
        • You must be logged in to reply to this topic.