MDL-31496 mod_data Replacing inline styles for CSS classes in text inputs

This commit is contained in:
David Monllao 2012-08-20 17:17:24 +08:00
parent 0d284a8bd6
commit f70a4f124b
3 changed files with 12 additions and 6 deletions

View file

@ -16,27 +16,27 @@
<td class="c0"><label for="param1">
<?php echo get_string('fieldwidthsingleview', 'data');?></label></td>
<td class="c1">
<input style="width:70px;" type="text" name="param1" id="param1" value="<?php if (!empty($this->field->param1)) p($this->field->param1); ?>" />
<input class="picturefieldsize" type="text" name="param1" id="param1" value="<?php if (!empty($this->field->param1)) p($this->field->param1); ?>" />
</td>
</tr>
<tr>
<td class="c0"><label for="param2">
<?php echo get_string('fieldheightsingleview', 'data');?></label></td>
<td class="c1">
<input style="width:70px;" type="text" name="param2" id="param2" value="<?php if (!empty($this->field->param2)) p($this->field->param2); ?>" />
<input class="picturefieldsize" type="text" name="param2" id="param2" value="<?php if (!empty($this->field->param2)) p($this->field->param2); ?>" />
</td>
</tr>
<tr>
<td class="c0"><label for="param4">
<?php echo get_string('fieldwidthlistview', 'data');?></label></td>
<td class="c1"><input style="width:70px;" type="text" name="param4" id="param4" value="<?php if (!empty($this->field->param4)) p($this->field->param4); ?>" />
<td class="c1"><input class="picturefieldsize" type="text" name="param4" id="param4" value="<?php if (!empty($this->field->param4)) p($this->field->param4); ?>" />
</td>
</tr>
<tr>
<td class="c0"><label for="param5">
<?php echo get_string('fieldheightlistview', 'data');?></label></td>
<td class="c1">
<input style="width:70px;" type="text" name="param5" id="param5" value="<?php if (!empty($this->field->param5)) p($this->field->param5); ?>" />
<input class="picturefieldsize" type="text" name="param5" id="param5" value="<?php if (!empty($this->field->param5)) p($this->field->param5); ?>" />
</td>
</tr>
<tr>

View file

@ -14,7 +14,7 @@
<td class="c0"><label for="param2">
<?php echo get_string('fieldwidth', 'data'); ?></label></td>
<td class="c1">
<input style="width:50px;" type="text" name="param2" id="param2" value=
<input class="textareafieldsize" type="text" name="param2" id="param2" value=
<?php
if (empty($this->field->param2)) {
echo('"60"');
@ -28,7 +28,7 @@
<td class="c0"><label for="param3">
<?php echo get_string('fieldheight', 'data'); ?></label></td>
<td class="c1">
<input style="width:50px;" type="text" name="param3" id="param3" value=
<input class="textareafieldsize" type="text" name="param3" id="param3" value=
<?php
if (empty($this->field->param3)) {
echo('"35"');

View file

@ -41,6 +41,12 @@
width:300px;
height:150px;
}
.path-mod-data-field input.textareafieldsize {
width:50px;
}
.path-mod-data-field input.picturefieldsize {
width:70px;
}
/** UI Usability Hacks **/
#page-mod-data-export #notice span {padding:0 10px;}