Skip to content

Commit

Permalink
Merge pull request #134 from ciar4n/mod-latest
Browse files Browse the repository at this point in the history
Recent articles item state styling
  • Loading branch information
C-Lodder authored Nov 9, 2016
2 parents 1255adc + 703618e commit 912e34a
Show file tree
Hide file tree
Showing 7 changed files with 42 additions and 14 deletions.
4 changes: 3 additions & 1 deletion Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,7 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-cssmin');
grunt.loadNpmTasks('grunt-scss-lint');
grunt.loadNpmTasks('grunt-sass');
grunt.loadNpmTasks('grunt-shell');
grunt.loadNpmTasks('grunt-fetch-pages');
Expand Down Expand Up @@ -376,10 +377,11 @@ module.exports = function(grunt) {
grunt.registerTask('compile', 'Compiles the stylesheet files.', function() {
grunt.task.run([
'uglify:templates',
'scsslint',
'sass:dist',
'postcss',
'cssmin:templates'
]);
});
});

};
4 changes: 2 additions & 2 deletions administrator/modules/mod_latest/tmpl/default.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@
defined('_JEXEC') or die;

JHtml::_('bootstrap.tooltip');

?>
<ul class="list-group list-group-flush">
<?php if (count($list)) : ?>
<?php foreach ($list as $i => $item) : ?>
<li class="list-group-item">
<?php echo JHtml::_('jgrid.published', $item->state, $i, '', false); ?>
<li class="list-group-item <?php echo $item->state == 1 ? 'published' : 'unpublished'; ?>">
<?php if ($item->checked_out) : ?>
<?php echo JHtml::_('jgrid.checkedout', $i, $item->editor, $item->checked_out_time); ?>
<?php endif; ?>
Expand Down
25 changes: 19 additions & 6 deletions administrator/templates/atum/css/template.css
Original file line number Diff line number Diff line change
Expand Up @@ -8417,9 +8417,13 @@ small, .small {
.com_cpanel .card {
box-shadow: 0 0 3px rgba(0, 0, 0, 0.075); }
.com_cpanel .card .list-group-item:first-child {
border-top: 0; }
border-top: 0;
border-top-left-radius: 0;
border-top-right-radius: 0; }
.com_cpanel .card .list-group-item:last-child {
border-bottom: 0; }
border-bottom: 0;
border-top-left-radius: 0;
border-top-right-radius: 0; }

.com_cpanel .card-title {
position: relative;
Expand All @@ -8436,14 +8440,23 @@ small, .small {
border-radius: 0.25rem 0.25rem 0 0;
box-shadow: 0 1px #fff inset, 0 2px 3px -3px rgba(0, 0, 0, 0.15); }

.com_cpanel .list-group-flush {
.com_cpanel .list-group {
margin-top: -0.75rem;
margin-right: -1.25rem;
margin-bottom: -1.25rem;
margin-left: -1.25rem; }
.com_cpanel .list-group-flush > li {
padding: 0.7rem 1.25rem; }
.com_cpanel .list-group-flush:first-of-type {
.com_cpanel .list-group > li {
padding: 0.7rem 1.25rem;
overflow: hidden; }
.com_cpanel .list-group > li.published {
border-left: 5px solid #5cb85c;
padding-left: .9rem;
padding-left: .9rem; }
.com_cpanel .list-group > li.unpublished {
border-left: 5px solid #d9534f;
padding-left: .9rem;
padding-left: .9rem; }
.com_cpanel .list-group:first-of-type {
border-top: 0; }

.com_cpanel .module-dropdown {
Expand Down
2 changes: 1 addition & 1 deletion administrator/templates/atum/css/template.css.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion administrator/templates/atum/css/template.min.css

Large diffs are not rendered by default.

15 changes: 14 additions & 1 deletion administrator/templates/atum/scss/template.scss
Original file line number Diff line number Diff line change
Expand Up @@ -123,9 +123,13 @@ small, .small {
box-shadow: 0 0 3px rgba(0,0,0,.075);
.list-group-item:first-child {
border-top: 0;
border-top-left-radius: 0;
border-top-right-radius: 0;
}
.list-group-item:last-child {
border-bottom: 0;
border-top-left-radius: 0;
border-top-right-radius: 0;
}
}
.card-title {
Expand All @@ -143,13 +147,22 @@ small, .small {
border-radius: $border-radius $border-radius 0 0;
box-shadow: 0 1px #fff inset, 0 2px 3px -3px rgba(0, 0, 0, .15);
}
.list-group-flush {
.list-group {
margin-top: - $card-spacer-y;
margin-right: - $card-spacer-x;
margin-bottom: - $card-spacer-x;
margin-left: - $card-spacer-x;
> li {
padding: .7rem $card-spacer-x;
overflow: hidden;
&.published {
padding-left: .9rem;
border-left: 5px solid $brand-success;
}
&.unpublished {
padding-left: .9rem;
border-left: 5px solid $brand-danger;
}
}
&:first-of-type {
border-top: 0;
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
"grunt-contrib-copy": "latest",
"grunt-contrib-cssmin": "latest",
"grunt-contrib-uglify": "latest",
"grunt-scss-lint": "^0.5.0"
"grunt-scss-lint": "^0.5.0",
"grunt-fetch-pages": "^2.0.0",
"grunt-shell": "latest",
"grunt-sass": "^1.2.1",
"grunt-sass": "^1.2.1"
},
"license": "GPL-2.0+"
}

0 comments on commit 912e34a

Please sign in to comment.