Styling a window in NGClient

Forum to discuss the new web client version of Servoy.

Styling a window in NGClient

Postby marco.rossi » Fri Feb 28, 2020 2:48 pm

Hi all,
I would like to modify the aspect of a window title (which is giant and blue into the ngclient).

I saw there's a property called "setCSSClass".
I put the CSS-classes (which are into the example provided with the "setCSSClass" property) into the globals.css which is used by the solution and I filled the "setCSSClass" property by the following way:
Code: Select all
var window = application.createWindow(windowName,(isModal)?JSWindow.MODAL_DIALOG:JSWindow.DIALOG)
      window.setCSSClass("mydlg")
      window.title = (windowTitle)?windowTitle:""
      window.show(_formName)


But nothing happens

Code: Select all
.mydlg {
      border-radius: initial;  show edged dialog corners
      -webkit-box-shadow: 0 5px 15px rgba(0,0,0,.0);  hide dialog box shadow
      box-shadow: 0 5px 15px rgba(0,0,0,.0);  hide dialog box shadow
   }

    dialog header styling
   .mydlg .window-header {
      background: green;
      font-size: 10pt;
   }

    style/hide dialog close button
   .mydlg .window-header .svy-dialog-close {
      display: none;
   }

    dialog body styling
   .mydlg .window-body {
      background: yellow;
   }

    dialog footer styling/hiding
   .mydlg .window-footer {
      background: blue;
      display: none !important;
   }


Thank you in advance for your time

Marco
Marco Rossi
Senior Analyst Developer
Freelance Consultant

IT Manager @Mantho
Webmaster @Sitoliquido
marco.rossi
 
Posts: 110
Joined: Sun Apr 12, 2015 9:33 pm

Re: Styling a window in NGClient

Postby dev-ws-011 » Tue Aug 04, 2020 3:27 pm

Hi Marco,

I just need to ask that did you create less file inheriting your css?

Regards.
Servoy Developer
dev-ws-011
 
Posts: 73
Joined: Fri Oct 21, 2016 8:23 am


Return to Servoy NGClient

Who is online

Users browsing this forum: No registered users and 3 guests