Customize save button

  • 0
  • 1
  • Question
  • Updated 5 months ago
  • Answered
How much, if at all, is it possible to customize the main "Save" button and indeed anything else along that top bar. I'm getting requests to change the colour/text, add new buttons next to the save button, and more. I'd like to be able to tell the requesters for certain whether or not it is possible. 

Thanks
Photo of Alex Gale

Alex Gale

  • 1,124 Points 1k badge 2x thumb

Posted 5 months ago

  • 0
  • 1
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 26,522 Points 20k badge 2x thumb
You can customize anything with script. In reference to the screenshot below showing HTML id attributes, what exactly do you mean by "top bar

Photo of Alex Gale

Alex Gale

  • 1,124 Points 1k badge 2x thumb
#pageNavBar. Do you mind giving me an example? Say I wanted to change the colour of the "+ New" button there to blue? How would I do that? 
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 26,522 Points 20k badge 2x thumb
The following one line of script manually applied from the console will make that change.


$("#stdAddRecButton").css({backgroundColor: "hsl(193, 98.3%, 46.3%)"})

To make this automatic you have to use one of the JavaScript injection techniques (IOL, BOL, SW etc)
Photo of Alex Gale

Alex Gale

  • 1,124 Points 1k badge 2x thumb
Huh. That's a bit above my level right now I'm afraid. Something to look into though. If I did make this change using one of those injection techniques, would it work for all users of my app? 

Thanks
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 26,522 Points 20k badge 2x thumb
I would suggest you get comfortable with the idea even if you don't implement it.

(1) Navigate to the page in question
(2) press F12 to expose the dev tools and move the the Console tab
(3) paste the one line of code into the console and hit enter.

The change should appear and you will be overcome with an exhilarating feeling of power and control over your application.
(Edited)
Photo of Alex Gale

Alex Gale

  • 1,124 Points 1k badge 2x thumb
I tried that, worked perfectly. It's taking the next step and being able to understand and write that code myself, as well as applying it to these javascript injection things, that's going to slow me down a bit.

Still, it's nice to know that these changes are possible, and if my supervisors really push for it I'll be happy to take the time to dig into the code.