JillElaine / jquery-idleTimeout

Idle activity timeout and logout redirect for jQuery for multiple windows & tabs
Other
72 stars 79 forks source link

More configuration variables #19

Closed Frankwin closed 9 years ago

Frankwin commented 9 years ago

It would be nice to have a couple more configuration variables such as:

JillElaine commented 9 years ago

You may change the position of the dialog box by adding the 'position' option to the function that creates the dialog box. I am unlikely to modify the code to add 'position' as it adds unnecessary complexity, in my opinion.

In the unminified code, edit the .js file, section starting with //----------- WARNING DIALOG FUNCTIONS --------------//

openWarningDialog = function () {

  var dialogContent = "<div id='idletimer_warning_dialog'><p>" + currentConfig.dialogText + "</p><p style='display:inline'>" + currentConfig.dialogTimeRemaining + ": <div style='display:inline' id='countdownDisplay'></div></p></div>";

  $(dialogContent).dialog({
    // add 'position' option
    position: { my: 'center', at: 'center', of: window },  // default value
    buttons: [{
      text: currentConfig.dialogStayLoggedInButton,
...

More information on the dialog 'position' option: https://api.jqueryui.com/dialog/#option-position https://api.jqueryui.com/position/

Your other requests are for 'styling' of the dialog, which is not included with the plugin. You can create your own custom CSS for jquery ui or use one of the ready-made themes from the Gallery. The themes will include styling for the dialog box. Please see this site: http://jqueryui.com/themeroller/

Note that rounded corners of the dialog box does not work in Internet Explorer 6 & 7.

I hope this I have understood your request correctly. Please let me know. Thank you.

Frankwin commented 9 years ago

Awesome. Thank you.

Best Regards,

Frankwin Hooglander

JillElaine commented 9 years ago

Closing issue.