Browse Source

Merge pull request #113 from krisbulman/7.x

added metadata to fieldset, switched box model to border box to avoid tr...
pull/114/head
Jonathan Green 13 years ago
parent
commit
677a13c519
  1. 36
      islandora_basic_image/css/islandora_basic_image.theme.css
  2. 7
      islandora_basic_image/islandora-basic-image.tpl.php
  3. 2
      islandora_basic_image/islandora_basic_image.module

36
islandora_basic_image/css/islandora_basic_image.theme.css

@ -18,8 +18,8 @@
} }
.islandora-basic-image-metadata { .islandora-basic-image-metadata {
clear: both; display: block;
padding-top: 1.5em; clear: both
} }
dl.islandora-basic-image-fields { dl.islandora-basic-image-fields {
@ -33,15 +33,25 @@ dl.islandora-basic-image-fields {
/* /*
* The width + left/right padding of DTs/DDs equals 88% when compensating for an image * The width + left/right padding of DTs/DDs equals 88% when compensating for an image
*/ */
.islandora-basic-image-metadata * {
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
}
.islandora-basic-image-metadata dt { .islandora-basic-image-metadata dt {
margin-right:-1px; margin-right:-1px;
width:12.5%; width:15.625%;
font-weight: bold; font-weight: normal;
text-align: right; text-align: right;
font-weight: bold;
padding-right: 0;
} }
.islandora-basic-image-metadata dd { .islandora-basic-image-metadata dd {
width:77%; width:84.375%;
padding-left: 40px;
} }
/* /*
@ -55,15 +65,15 @@ dl.islandora-basic-image-fields {
letter-spacing:normal; letter-spacing:normal;
word-spacing:normal; word-spacing:normal;
vertical-align:top; vertical-align:top;
padding:5px 0 3px 3%; padding-top: 6px;
padding-bottom: 4px;
margin:0; margin:0;
border-top:1px solid #ddd; border-top:1px solid #e5e5e5;
-ms-word-break: break-all; }
word-break: break-all;
word-break: break-word; /* webkit */ .islandora-basic-image-metadata dt.first,
-webkit-hyphens: auto; .islandora-basic-image-metadata dd.first {
-moz-hyphens: auto; border-top:0;
hyphens: auto;
} }
.islandora-basic-image-sidebar, .islandora-basic-image-sidebar,

7
islandora_basic_image/islandora-basic-image.tpl.php

@ -32,8 +32,10 @@
<h3><?php print $dc_array['dc:description']['label']; ?></h3> <h3><?php print $dc_array['dc:description']['label']; ?></h3>
<p><?php print $dc_array['dc:description']['value']; ?></p> <p><?php print $dc_array['dc:description']['value']; ?></p>
</div> </div>
<div class="islandora-basic-image-metadata">
<h4>Details</h4> <fieldset class="collapsible collapsed islandora-basic-image-metadata">
<legend><span class="fieldset-legend">Extended Details</span></legend>
<div class="fieldset-wrapper">
<dl class="islandora-basic-image-fields"> <dl class="islandora-basic-image-fields">
<?php $row_field = 0; ?> <?php $row_field = 0; ?>
<?php foreach($dc_array as $key => $value): ?> <?php foreach($dc_array as $key => $value): ?>
@ -47,4 +49,5 @@
<?php endforeach; ?> <?php endforeach; ?>
</dl> </dl>
</div> </div>
</fieldset>
</div> </div>

2
islandora_basic_image/islandora_basic_image.module

@ -200,6 +200,8 @@ function islandora_basic_image_islandora_view_object($object, $user, $page_numbe
* an array of variables that will be passed to the theme function * an array of variables that will be passed to the theme function
*/ */
function islandora_basic_image_preprocess_islandora_basic_image(&$variables) { function islandora_basic_image_preprocess_islandora_basic_image(&$variables) {
drupal_add_js('misc/form.js');
drupal_add_js('misc/collapse.js');
$islandora_object = $variables['islandora_object']; $islandora_object = $variables['islandora_object'];
module_load_include('inc', 'islandora', 'includes/islandora_dublin_core'); module_load_include('inc', 'islandora', 'includes/islandora_dublin_core');
try { try {

Loading…
Cancel
Save