Browse Source

Merge pull request #123 from krisbulman/7.x

css cleanup, markup change for list view
pull/124/merge
Jonathan Green 13 years ago
parent
commit
d57e247c6f
  1. 47
      islandora_basic_collection/css/islandora_basic_collection.base.css
  2. 80
      islandora_basic_collection/css/islandora_basic_collection.theme.css
  3. 2
      islandora_basic_collection/theme/islandora-basic-collection-grid.tpl.php
  4. 8
      islandora_basic_collection/theme/islandora-basic-collection-wrapper.tpl.php
  5. 21
      islandora_basic_collection/theme/islandora-basic-collection.tpl.php

47
islandora_basic_collection/css/islandora_basic_collection.base.css

@ -1,8 +1,51 @@
/* /*
Document : islandora_basic_collection.base.css Document : islandora_basic_collection.base.css
Created on : May 23, 2012, 11:22:04 AM Created on : May 23, 2012, 11:22:04 AM
Description: Description: Base css, for structural layout,
Purpose of the stylesheet follows. positioning, and to generally make things function in
the most basic form.
*/ */
/* List - Displays lists using a dt on the left and dd on the right */
.islandora-basic-collection-list-item {
clear: both;
width: 100%;
}
.islandora-basic-collection-list-item dl dt {
clear: left;
float: left;
padding: 3px 0 0;
text-align: center;
width: 100px;
}
.islandora-basic-collection-list-item dl dd {
margin: 0 0 0 130px;
}
/* Grid - Displays grid using dl formatted inline */
.islandora-basic-collection-grid dl
{
width: 20%;
min-width: 100px;
min-height: 180px;
display: -moz-inline-stack;
display: inline-block;
vertical-align: top;
margin: 1.5em 2%;
zoom: 1;
*display: inline;
_height: 180px;
}
.islandora-basic-collection-grid dd
{
margin: 0;
padding: 0;
}
.islandora-basic-collection-display-switch {
float: right;
}

80
islandora_basic_collection/css/islandora_basic_collection.theme.css

@ -1,86 +1,46 @@
/* /*
Document : islandora_basic_collection.theme Document : islandora_basic_collection.theme
Created on : May 23, 2012, 11:23:56 AM Created on : May 23, 2012, 11:23:56 AM
Description: Description: Theme css, like margins, padding, borders, colors, etc
Purpose of the stylesheet follows.
*/ */
/* Make flexible and assure content doesn't go off the page */
.islandora-basic-collection { .islandora-basic-collection {
overflow: hidden; overflow: hidden;
width: 100%; width: 100%;
margin: 0 auto; margin: 0 auto;
} }
.islandora-basic-collection-object { /* Round borders on images */
margin: 1.5em auto 3em; .islandora-basic-collection-object dt img {
}
.islandora-basic-collection-grid dl.islandora-basic-collection-object
{
width: 20%;
min-width: 100px;
min-height: 180px;
display: -moz-inline-stack;
display: inline-block;
vertical-align: top;
margin: 1.5em 2%;
zoom: 1;
*display: inline;
_height: 180px;
}
.islandora-basic-collection-grid .islandora-basic-collection-object dt img {
max-width: 100%;
*width: 100%;
-webkit-border-radius: 5px; -webkit-border-radius: 5px;
-moz-border-radius: 5px; -moz-border-radius: 5px;
border-radius: 5px; border-radius: 5px;
} }
.islandora-basic-collection-grid .islandora-basic-collection-object dd /* Set space between objects */
{ .islandora-basic-collection-object {
margin: 0; margin: 1.5em auto;
padding: 0;
}
/* to be moved to admin when it is added */
#islandora-collection-deletion-form table th.select-all,
#islandora-collection-migrate-form table th.select-all {
width: 20px;
} }
/* the base css for lists is set in islandora, just adding details */ /* Set space between dd items */
.islandora-basic-collection-object dd {
dl.islandora-basic-collection-thumb padding-top: 2px;
{ padding-bottom: 2px;
float: left;
width: 15%;
margin: 0;
} }
.islandora-basic-collection-thumb dt, /* LIST VIEW */
.islandora-basic-collection-thumb dd
{
margin: 0;
}
dl.islandora-basic-collection-fields /* Borders to seperate collection objects */
{ .islandora-basic-collection-list-item {
float: right; padding-bottom: 1.5em;
width: 83%; border-bottom: 1px solid #ddd;
border-top: 0px solid #ddd;
padding-left: 10px;
} }
.islandora-basic-collection-fields dt,
.islandora-basic-collection-fields dd
{
border-top: 1px solid #ddd;
}
.islandora-basic-collection-fields dt.first, /* to be moved to admin when it is added */
.islandora-basic-collection-fields dd.first #islandora-collection-deletion-form table th.select-all,
{ #islandora-collection-migrate-form table th.select-all {
border-top: 1px solid #ddd; width: 20px;
} }

2
islandora_basic_collection/theme/islandora-basic-collection-grid.tpl.php

@ -23,7 +23,7 @@
?> ?>
<div class="islandora-basic-collection-wrapper"> <div class="islandora islandora-basic-collection">
<div class="islandora-basic-collection-grid clearfix"> <div class="islandora-basic-collection-grid clearfix">
<?php foreach($associated_objects_array as $key => $value): ?> <?php foreach($associated_objects_array as $key => $value): ?>
<dl class="islandora-basic-collection-object <?php print $value['class']; ?>"> <dl class="islandora-basic-collection-object <?php print $value['class']; ?>">

8
islandora_basic_collection/theme/islandora-basic-collection-wrapper.tpl.php

@ -25,9 +25,9 @@
<div class="islandora-basic-collection-wrapper"> <div class="islandora-basic-collection-wrapper">
<div class="islandora-basic-collection clearfix"> <div class="islandora-basic-collection clearfix">
<?php print ($switch_view_link) ?> <span class="islandora-basic-collection-display-switch"><?php print $switch_view_link; ?></span>
<?php print($collection_pager); ?> <?php print $collection_pager; ?>
<?php print ($collection_content); ?> <?php print $collection_content; ?>
<?php print($collection_pager); ?> <?php print $collection_pager; ?>
</div> </div>
</div> </div>

21
islandora_basic_collection/theme/islandora-basic-collection.tpl.php

@ -23,31 +23,24 @@
?> ?>
<?php drupal_set_title($islandora_object->label); ?> <?php drupal_set_title($islandora_object->label); ?>
<div class="islandora islandora-basic-collection-wrapper"> <div class="islandora islandora-basic-collection">
<?php $row_field = 0; ?> <?php $row_field = 0; ?>
<?php foreach($associated_objects_array as $associated_object): ?> <?php foreach($associated_objects_array as $associated_object): ?>
<div class="islandora-basic-collection-object clearfix"> <div class="islandora-basic-collection-object islandora-basic-collection-list-item clearfix">
<dl class="islandora-basic-collection-thumb <?php print $associated_object['class']; ?>"> <dl class="<?php print $associated_object['class']; ?>">
<dt><?php print $associated_object['thumb_link']; ?></dt> <dt>
<dd></dd> <?php print $associated_object['thumb_link']; ?>
</dl>
<dl class="islandora-inline-metadata islandora-basic-collection-fields">
<dt class="collection-label <?php print $associated_object['dc_array']['dc:title']['class']; ?> <?php print $row_field == 0 ? ' first' : ''; ?>">
<?php print $associated_object['dc_array']['dc:title']['label']; ?>
</dt> </dt>
<dd class="collection-value <?php print $associated_object['dc_array']['dc:title']['class']; ?> <?php print $row_field == 0 ? ' first' : ''; ?>"> <dd class="collection-value <?php print $associated_object['dc_array']['dc:title']['class']; ?> <?php print $row_field == 0 ? ' first' : ''; ?>">
<?php print $associated_object['title_link']; ?> <strong><?php print $associated_object['title_link']; ?></strong>
</dd> </dd>
<?php if ($associated_object['dc_array']['dc:description']['value']): ?> <?php if ($associated_object['dc_array']['dc:description']['value']): ?>
<dt class="collection-label <?php print $associated_object['dc_array']['dc:description']['class']; ?>">
<?php print $associated_object['dc_array']['dc:description']['label']; ?>
</dt>
<dd class="collection-value <?php print $associated_object['dc_array']['dc:description']['class']; ?>"> <dd class="collection-value <?php print $associated_object['dc_array']['dc:description']['class']; ?>">
<?php print $associated_object['dc_array']['dc:description']['value']; ?> <?php print $associated_object['dc_array']['dc:description']['value']; ?>
</dd> </dd>
<?php $row_field++; ?>
<?php endif; ?> <?php endif; ?>
</dl> </dl>
</div> </div>
<?php $row_field++; ?>
<?php endforeach; ?> <?php endforeach; ?>
</div> </div>
Loading…
Cancel
Save