Skip to content

Commit

Permalink
p3x-robot sunday release 2018-5-13 00:04:51
Browse files Browse the repository at this point in the history
  • Loading branch information
p3x-robot committed May 12, 2018
1 parent 4fde749 commit 39a9864
Show file tree
Hide file tree
Showing 25 changed files with 106 additions and 48 deletions.
2 changes: 1 addition & 1 deletion INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ UrlToolkit {

---

[**GITLIST**](https://pages.corifeus.com/gitlist) Build v1.1.8
[**GITLIST**](https://pages.corifeus.com/gitlist) Build v1.1.9

[![Like Corifeus @ Facebook](https://img.shields.io/badge/LIKE-Corifeus-3b5998.svg)](https://www.facebook.com/corifeus.software) [![Donate for Corifeus / P3X](https://img.shields.io/badge/Donate-Corifeus-003087.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=QZVM4V6HVZJW6) [![Contact Corifeus / P3X](https://img.shields.io/badge/Contact-P3X-ff9900.svg)](https://www.patrikx3.com/en/front/contact)

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@



# 🤖 P3X Gitlist v1.1.8
# 🤖 P3X Gitlist v1.1.9

# Description

Expand Down Expand Up @@ -113,7 +113,7 @@ npm run less-watch

---

[**GITLIST**](https://pages.corifeus.com/gitlist) Build v1.1.8
[**GITLIST**](https://pages.corifeus.com/gitlist) Build v1.1.9

[![Like Corifeus @ Facebook](https://img.shields.io/badge/LIKE-Corifeus-3b5998.svg)](https://www.facebook.com/corifeus.software) [![Donate for Corifeus / P3X](https://img.shields.io/badge/Donate-Corifeus-003087.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=QZVM4V6HVZJW6) [![Contact Corifeus / P3X](https://img.shields.io/badge/Contact-P3X-ff9900.svg)](https://www.patrikx3.com/en/front/contact)

Expand Down
2 changes: 1 addition & 1 deletion artifacts/php-7.2-ubuntu.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ sudo apt upgrade -y

---

[**GITLIST**](https://pages.corifeus.com/gitlist) Build v1.1.8
[**GITLIST**](https://pages.corifeus.com/gitlist) Build v1.1.9

[![Like Corifeus @ Facebook](https://img.shields.io/badge/LIKE-Corifeus-3b5998.svg)](https://www.facebook.com/corifeus.software) [![Donate for Corifeus / P3X](https://img.shields.io/badge/Donate-Corifeus-003087.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=QZVM4V6HVZJW6) [![Contact Corifeus / P3X](https://img.shields.io/badge/Contact-P3X-ff9900.svg)](https://www.patrikx3.com/en/front/contact)

Expand Down
9 changes: 8 additions & 1 deletion changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@
[//]: #@corifeus-header:end

### v1.1.20
* in progress

### v1.1.9
* we automatically load the next commit, when we are on the bottom of the page
* minor toast fix

### v1.1.8
The `config.ini` file with `url_subdir` or later `clone_subdir` variable has been changed to the `git_clone_subdir` variable.

Expand Down Expand Up @@ -106,7 +113,7 @@ require('codemirror/mode/yaml/yaml');

---

[**GITLIST**](https://pages.corifeus.com/gitlist) Build v1.1.8
[**GITLIST**](https://pages.corifeus.com/gitlist) Build v1.1.9

[![Like Corifeus @ Facebook](https://img.shields.io/badge/LIKE-Corifeus-3b5998.svg)](https://www.facebook.com/corifeus.software) [![Donate for Corifeus / P3X](https://img.shields.io/badge/Donate-Corifeus-003087.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=QZVM4V6HVZJW6) [![Contact Corifeus / P3X](https://img.shields.io/badge/Contact-P3X-ff9900.svg)](https://www.patrikx3.com/en/front/contact)

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"build": "grunt && webpack --production",
"webpack-watch": "grunt && webpack --watch",
"less-watch": "grunt watch:less",
"watch": "concurrently \"webpack --watch\" \"grunt watch:less\""
"watch": "grunt && concurrently \"webpack --watch\" \"grunt watch:less\""
},
"description": "🤖 P3X Gitlist",
"version": "1.1.9",
Expand Down
2 changes: 1 addition & 1 deletion public/css/bootstrap-cerulean.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-cosmo.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-cyborg.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-darkly.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-default.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-flatly.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-journal.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-lumen.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-paper.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-readable.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-sandstone.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-simplex.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-slate.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-spacelab.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-superhero.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-united.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/css/bootstrap-yeti.css

Large diffs are not rendered by default.

73 changes: 55 additions & 18 deletions public/js/paginate.js
Original file line number Diff line number Diff line change
@@ -1,26 +1,63 @@
document.addEventListener("DOMContentLoaded", function(event) {
function paginate() {
const $pager = $('.pager');

$pager.find('.next a').one('click', function (e) {
e.preventDefault();
const url = new URL(this.href);
const retrieve = `${location.pathname}${url.search}`

$.ajax({
url: retrieve,
type: "GET",
cache: false,
success: function (html) {
$pager.after(html);
$pager.remove();
paginate();
}
});
let $pager;
let loading = false;
let button;
let noMore = false;

const nextCommitListItem = () => {

if (loading === true) {
return;
}
loading = true;
const href = button.attr('href');
//console.log(href);
if (href === undefined) {
loading = false;
if (!noMore) {
$.snackbar({
htmlAllowed: true,
content: `There are no more commits.`
});
noMore = true;
}
return
}
noMore = false;
const retrieve = `${location.pathname}${href}`

$.ajax({
url: retrieve,
async: true,
type: "GET",
}).then(function(html) {
$pager.after(html);
$pager.remove();
loading = false;
paginate();
});
}


$pager.find('.previous').remove();

function paginate() {
$pager = $('.pager');
button = $pager.find('.next a');
button.one('click', function (e) {
e.preventDefault();
nextCommitListItem()
return false;
});
}
paginate();

if (button.length > 0) {
$(window).scroll(function () {
if ($(window).scrollTop() >= $(document).height() - $(window).height() - 10) {
nextCommitListItem();
}
});
}

})
18 changes: 18 additions & 0 deletions public/less/default.less
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,24 @@
right: 20px !important;
}

@media (max-width: 767px) {
#snackbar-container {
left: 0px !important;
right: 0px !important;
width: 100%;
.snackbar {
min-width: 100%;
}
[class="snackbar snackbar-opened"] ~ .snackbar.toast {
margin-top: 20px;
}
[class="snackbar snackbar-opened"] {
border-radius: 0;
margin-bottom: 0;
}
}
}

.header {
margin-bottom: @line-height-computed;
}
Expand Down
10 changes: 3 additions & 7 deletions twig/commits_list.twig
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,10 @@

{% if page != 'searchcommits' %}
<ul class="pager">
{% if pager.current != 0 %}
<li class="previous">
<a href="?page={{ pager.previous }}">&larr; Newer</a>
</li>
{% endif %}

{% if pager.current != pager.last %}
<li class="next">
<a href="?page={{ pager.next }}">Older &rarr;</a>
<li class="next" id="p3x-gitlist-commit-list-next">
<a href="?page={{ pager.next }}">Older / Next &rarr;</a>
</li>
{% endif %}
</ul>
Expand Down

0 comments on commit 39a9864

Please sign in to comment.