Commit b47f30c1 authored by Chenu Denis's avatar Chenu Denis

Fixed issue #08735: "Exit and clear survey" css style for shiped template

Dev: fix some issue with IE7
Dev: add button class to some other submit button
parent 29800901
......@@ -989,7 +989,7 @@ function buildsurveysession($surveyid,$preview=false)
</li>";
}
echo "<li>
<input class='submit' type='submit' value='".$clang->gT("Continue")."' />
<input class='submit button' type='submit' value='".$clang->gT("Continue")."' />
</li>
</ul>
</form></div>";
......
......@@ -506,7 +506,7 @@ function templatereplace($line, $replacements = array(), &$redata = array(), $de
$_saveform .="<tr><td align='right'>" . $clang->gT("Security question") . ":</td><td><table><tr><td valign='middle'><img src='".Yii::app()->getController()->createUrl('/verification/image/sid/'.((isset($surveyid)) ? $surveyid : ''))."' alt6='' /></td><td valign='middle' style='text-align:left'><input type='text' size='5' maxlength='3' name='loadsecurity' value='' /></td></tr></table></td></tr>\n";
}
$_saveform .= "<tr><td align='right'></td><td></td></tr>\n"
. "<tr><td></td><td><input type='submit' id='savebutton' name='savesubmit' value='" . $clang->gT("Save Now") . "' /></td></tr>\n"
. "<tr><td></td><td><input type='submit' id='savebutton' name='savesubmit' class='button' value='" . $clang->gT("Save Now") . "' /></td></tr>\n"
. "</table>";
// Load Form
......@@ -527,7 +527,7 @@ function templatereplace($line, $replacements = array(), &$redata = array(), $de
$_loadform .="<tr><td align='right'>" . $clang->gT("Security question") . ":</td><td><table><tr><td valign='middle'><img src='".Yii::app()->getController()->createUrl('/verification/image/sid/'.((isset($surveyid)) ? $surveyid : ''))."' alt='' /></td><td valign='middle'><input type='text' size='5' maxlength='3' name='loadsecurity' value='' alt=''/></td></tr></table></td></tr>\n";
}
$_loadform .="<tr><td align='right'></td><td></td></tr>\n"
. "<tr><td></td><td><input type='submit' id='loadbutton' value='" . $clang->gT("Load now") . "' /></td></tr></table>\n";
. "<tr><td></td><td><input type='submit' id='loadbutton' class='button' value='" . $clang->gT("Load now") . "' /></td></tr></table>\n";
// Registration Form
if (isset($surveyid) || (isset($registerdata) && $debugSrc == 'register.php'))
......@@ -589,7 +589,7 @@ function templatereplace($line, $replacements = array(), &$redata = array(), $de
{
$_registerform .="<tr><td align='right'>" . $clang->gT("Security Question") . ":</td><td><table><tr><td valign='middle'><img src='".Yii::app()->getController()->createUrl('/verification/image/sid/'.$surveyid)."' alt='' /></td><td valign='middle'><input type='text' size='5' maxlength='3' name='loadsecurity' value='' /></td></tr></table></td></tr>\n";
}
$_registerform .= "<tr><td></td><td><input id='registercontinue' class='submit' type='submit' value='" . $clang->gT("Continue") . "' />"
$_registerform .= "<tr><td></td><td><input id='registercontinue' class='submit button' type='submit' value='" . $clang->gT("Continue") . "' />"
. "</td></tr>\n"
. "</table>\n";
......
......@@ -91,11 +91,11 @@ function setJsVar(){
// Deactivate all other button on submit
function limesurveySubmitHandler(){
$(document).on("click",".disabled",function(){return false;});
$(document).on('click',"button[type='submit'],a.button", function(event){
$("button[type='submit']").not($(this)).prop('disabled',true);
$("a.button").not($(this)).addClass('disabled');
$(document).on('click',".button", function(event){
$(".button.ui-button" ).not($(this)).button( "option", "disabled", true );
$(".button").not($(this)).prop('disabled',true).addClass('disabled');
});
if('v'=='\v'){ // Quick hack for IE6/7/ Alternative ? http://tanalin.com/en/articles/ie-version-js/ ?
if (document.all && !document.querySelector) { // IE7 or lower
$(function() {
$("#defaultbtn").css('display','inline').css('width','0').css('height','0').css('padding','0').css('margin','0').css('overflow','hidden');
$("#limesurvey [type='submit']").not("#defaultbtn").first().before($("#defaultbtn"));
......@@ -111,18 +111,10 @@ function needConfirmHandler(){
if (confirm(text)) {
return true;
}
$(".button.ui-button" ).button( "option", "disabled", false );
$(".button").prop('disabled',false).removeClass('disabled');
return false;
});
/* 130712 IE7 need this */
$(function() {
$("a.confirm-needed").click(function(e){
text=$(this).attr('title');
if (confirm(text)) {
return true;
}
return false;
});
});
}
/**
* checkconditions : javascript function attach to some element
......
/*** Start jQuery UI Theme Styles ***/
button.ui-button::-moz-focus-inner {
.ui-button::-moz-focus-inner {
border: 0;
padding: 0; /* Get rid of extra padding in focused button in FF */
}
......@@ -15,20 +15,17 @@ button.ui-button::-moz-focus-inner {
line-height: normal;
}
button.ui-state-default,
input.ui-state-default {
.ui-state-default{
color: #333333;
border: 1px solid #A0A0A0;
}
button.ui-state-hover,
input.ui-state-hover {
.ui-state-hover {
color: #212121;
border: 1px solid #999999;
}
button.ui-state-active,
input.ui-state-active {
.ui-state-active {
color: #212121;
border: 1px solid #AAAAAA;
}
......
......@@ -44,7 +44,7 @@ abbr,acronym {
/*** Start jQuery UI Theme Styles ***/
button.ui-button::-moz-focus-inner {
.ui-button::-moz-focus-inner {
border: 0;
padding: 0; /* Get rid of extra padding in focused button in FF */
}
......@@ -59,22 +59,19 @@ button.ui-button::-moz-focus-inner {
line-height: normal;
}
button.ui-state-default,
input.ui-state-default {
.ui-state-default {
color: #333333;
border: 1px solid #A0A0A0;
background: #FAFAFA none;
}
button.ui-state-hover,
input.ui-state-hover {
.ui-state-hover {
color: #212121;
border: 1px solid #999999;
background: #EBEBEB none;
}
button.ui-state-active,
input.ui-state-active {
.ui-state-active {
color: #212121;
border: 1px solid #AAAAAA;
background: #DCDCDC none;
......
......@@ -30,8 +30,7 @@ h4{font-size:1.1em}
ul,ol{margin:.75em 0 .75em 32px;padding:0}
address{font-style:italic;margin:.75em 0}
a{text-decoration:underline}
a:link,a:visited{color:#11C}
a:visited{color:#339}
a{color:#11C}
a:hover,a:focus,a:active{color:#00F}
a:active{outline:none}
a img{border:none}
......@@ -72,8 +71,7 @@ input, button, select {vertical-align: middle;}
/* Colors and themes */
body {background:#FEFEFE;color:#444;font-size:.85em;font-family:Verdana, "DejaVu Sans", "Bitstream Vera Sans", Geneva, sans-serif;}
a:link {color: #5670A1;}
a:visited {color: #5670A1;}
a {color: #5670A1;}
a:hover, a:focus, a:active {background-color: #E5F8A8;color: #5670A1;text-decoration:none;}
/* Head decoration */
......@@ -150,6 +148,7 @@ input.checkbox[disabled],input.radio[disabled]{opacity: 0.3;}
/* survey tool decoration */
.tools select,.button
{
line-height:1.5;
border:1px solid #ABB8D1;background:#FEFEFE;color:#415479;
-moz-box-shadow: 2px 2px 5px #ccc;-webkit-box-shadow: 2px 2px 5px #ccc;box-shadow: 2px 2px 5px #ccc;
font-family:Tahoma, Geneva, Kalimati, sans-serif;font-size:1em;vertical-align:middle;
......@@ -159,7 +158,8 @@ input.checkbox[disabled],input.radio[disabled]{opacity: 0.3;}
.tools select
{padding:1px 2px;}
.button
{box-sizing: border-box;-webkit-box-sizing: border-box;-moz-box-sizing: border-box;-ms-box-sizing: border-box;}/* same box sizing for link and button */
{display:inline-block;
box-sizing: border-box;-webkit-box-sizing: border-box;-moz-box-sizing: border-box;-ms-box-sizing: border-box;}/* same box sizing for link and button */
.tools select:hover,.button:hover,.button:focus
{
border-color:#ABB8D1;color:#415479;background:#f0f0f0;
......
......@@ -63,18 +63,15 @@ button.ui-button::-moz-focus-inner { /* Get rid of extra padding in focused butt
line-height: normal;
}
button.ui-state-default,
input.ui-state-default {
.ui-state-default {
color: #2E648B;
}
button.ui-state-hover,
input.ui-state-hover {
.ui-state-hover {
color: #0070A3;
}
button.ui-state-active,
input.ui-state-active {
.ui-state-active {
color: #FFFFFF;
}
......@@ -241,7 +238,7 @@ h3 {
padding-bottom: 10px;
}
a:link,a:visited {
a {
color: #819d26;
text-decoration: none;
}
......
......@@ -2,7 +2,7 @@
/*** Start jQuery UI Theme Styles ***/
button.ui-button::-moz-focus-inner {
.ui-button::-moz-focus-inner {
border: 0;
padding: 0; /* Get rid of extra padding in focused button in FF */
}
......@@ -17,20 +17,17 @@ button.ui-button::-moz-focus-inner {
line-height: normal;
}
button.ui-state-default,
input.ui-state-default {
.ui-state-default {
color: #333333;
border: 1px solid #A0A0A0;
}
button.ui-state-hover,
input.ui-state-hover {
.ui-state-hover {
color: #212121;
border: 1px solid #999999;
}
button.ui-state-active,
input.ui-state-active {
.ui-state-active {
color: #212121;
border: 1px solid #AAAAAA;
}
......
/*** Start jQuery UI Theme Styles ***/
button.ui-button::-moz-focus-inner {
.ui-button::-moz-focus-inner {
border: 0;
padding: 0; /* Get rid of extra padding in focused button in FF */
}
......@@ -21,22 +21,19 @@ button.ui-button::-moz-focus-inner {
line-height: normal;
}
button.ui-state-default,
input.ui-state-default {
.ui-state-default {
color: #333333;
background: #E0FCFF none;
border: 1px solid #86B8BC;
}
button.ui-state-hover,
input.ui-state-hover {
.ui-state-hover {
color: #212121;
background: #C2F9FF none;
border: 1px solid #00677D;
}
button.ui-state-active,
input.ui-state-active {
.ui-state-active {
color: #FFFFFF;
background: #7BBBCC none !important;
border: 1px solid #00677D;
......@@ -423,19 +420,14 @@ div#footer .rk-2 {
text-align: justify;
}
.submit {
.button {
background-color: #e0fcff;
border: 1px solid #86b8bc;
cursor: pointer;
font-size: 13px;
}
.submit:hover {
background: #c2f9ff;
border: 1px solid #00677d;
}
input.submit:hover {
.button:hover {
background: #c2f9ff;
border: 1px solid #00677d;
}
......@@ -649,13 +641,13 @@ table.question tr.array2:hover {
.assessments td{
text-align: center;
}
A:link,A:visited,A:active {
a {
text-decoration: none;
color: #00677d;
border-bottom: 1px dashed #00677d;
}
A:hover {
a:hover {
text-decoration: none;
color: #004554;;
border-bottom: 1px solid #004554;
......
......@@ -25,7 +25,7 @@ table {
/*** Start jQuery UI Theme Styles ***/
button.ui-button::-moz-focus-inner {
.ui-button::-moz-focus-inner {
border: 0;
padding: 0; /* Get rid of extra padding in focused button in FF */
}
......@@ -40,24 +40,21 @@ button.ui-button::-moz-focus-inner {
line-height: normal;
}
button.ui-state-default,
input.ui-state-default {
.ui-state-default {
color: #333333;
border: 1px solid #A0A0A0;
}
button.ui-state-hover,
input.ui-state-hover {
.ui-state-active .ui-button-text{color:#333333; }
.ui-state-hover {
color: #212121;
border: 1px solid #999999;
}
button.ui-state-active,
input.ui-state-active {
.ui-state-hover .ui-button-text{color:#212121; }
.ui-state-active {
color: #212121;
border: 1px solid #AAAAAA;
}
.ui-state-active .ui-button-text{color:#212121; }
.ui-button-icon-only {
width: 2.2em; /* To make room for the icon, a width needs to be set here */
}
......@@ -155,20 +152,11 @@ a {
color: #fff;
}
a:link {
color: #fff;
}
a:hover {
color: #fff;
text-decoration: none;
}
a:visited {
color: #fff;
text-decoration: none;
}
/* headings --------------------------------------------------------------------- */
h1,h2,h3,h4,h5,h6 {
margin: 15px 0 10px 0;
......
......@@ -2,7 +2,7 @@
/*** Start jQuery UI Theme Styles ***/
button.ui-button::-moz-focus-inner {
.ui-button::-moz-focus-inner {
border: 0;
padding: 0; /* Get rid of extra padding in focused button in FF */
}
......@@ -26,18 +26,15 @@ button.ui-button::-moz-focus-inner {
line-height: normal;
}
button.ui-state-default,
input.ui-state-default {
.ui-state-default{
color: #2E648B;
}
button.ui-state-hover,
input.ui-state-hover {
.ui-state-hover {
color: #0070A3;
}
button.ui-state-active,
input.ui-state-active {
.ui-state-active {
color: #FFFFFF;
}
......
/*** Start jQuery UI Theme Styles ***/
button.ui-button::-moz-focus-inner {
.ui-button::-moz-focus-inner {
border: 0;
padding: 0; /* Get rid of extra padding in focused button in FF */
}
......@@ -16,20 +16,17 @@ button.ui-button::-moz-focus-inner {
line-height: normal;
}
button.ui-state-default,
input.ui-state-default {
.ui-state-defaultt {
/* color: #333333; */
/* border: 1px solid #A0A0A0;*/
}
button.ui-state-hover,
input.ui-state-hover {
.ui-state-hover {
/* color: #212121; */
/* border: 1px solid #999999;*/
}
button.ui-state-active,
input.ui-state-active {
.ui-state-active {
/* color: #212121; */
/* border: 1px solid #AAAAAA; */
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment