Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New JS folder / Check Repositories last update #90

Open
wants to merge 29 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
3b0a5ee
Added new JS folder to hold scripts
rxchun Oct 21, 2024
0eab8b1
Check Repositories last update
rxchun Oct 21, 2024
ffe1e13
Refactored Github Repository dates, finished 2020 design
rxchun Nov 18, 2024
85e71a7
Check Homepage Popup early
rxchun Nov 18, 2024
8dfd5f0
Mobile Responsiveness
rxchun Nov 18, 2024
de04b8f
Mobile Responsiveness
rxchun Nov 18, 2024
e007af8
Fix for null JS .selected-nav
rxchun Nov 19, 2024
f175570
UX
rxchun Nov 19, 2024
f3ec222
Homepage Notice
rxchun Nov 19, 2024
2b6e4ed
Repository Links UX color swap
rxchun Nov 21, 2024
466faec
Refactored 'last updated' function, to check for 'max_q2a' key first
rxchun Nov 23, 2024
0006806
Tested with Q2A
rxchun Nov 23, 2024
ef06a84
Tested with version N
rxchun Nov 23, 2024
67a7817
Mobile Responsiveness
rxchun Nov 23, 2024
5ccfc31
Mobile Responsive
rxchun Nov 23, 2024
93f5020
Replace Emoji colors on DOM load
rxchun Nov 23, 2024
6341eb1
Markdown Editor description
rxchun Nov 23, 2024
1628583
Brought back the original Markdown Editor link
rxchun Nov 23, 2024
713c301
ReOrdered Plugins Alphabetically
rxchun Nov 23, 2024
e1d02de
Added pupi1985 newest free plugins and mine as well
rxchun Nov 24, 2024
4d2e1a0
Removed duplicate link inside the same instance
rxchun Nov 24, 2024
e68aa7a
CSS fix
rxchun Nov 24, 2024
1307d4c
Fix for weird indentations on GitHub but not IDE
rxchun Nov 24, 2024
d3d9670
Better Phrasing
rxchun Nov 29, 2024
d455d61
Seperated GithubLinks script, from main scripts, since they're only u…
rxchun Dec 7, 2024
441f921
Mobile Menu patches
rxchun Dec 7, 2024
a580522
Syntax Error fix for _layouts\default, and UX patches
rxchun Dec 8, 2024
9e5c873
Consistent case sensitive
rxchun Dec 8, 2024
65e8ccd
Fix for null child-repository
rxchun Dec 15, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,18 @@ nav:
- name: Code
path: /code/external/
sub: code

second:
- name: Contribute
path: /contribute/
sub: contribute
- name: Add-Ons
path: /addons/
sub: addons

second:
third:
- name: Services
url: /services/
class: main-nav-link-separate
- name: Sites
url: https://www.question2answer.org/sites.php
- name: Q&A
Expand Down Expand Up @@ -103,12 +104,12 @@ nav:
path: /contribute/docs/

addons:
- name: Translations
path: /addons/translations/
- name: Themes
path: /addons/themes/
- name: Plugins
path: /addons/plugins/
- name: Clients
path: /addons/clients/
- name: Translations
path: /addons/translations/

17 changes: 17 additions & 0 deletions _includes/breadcrumbs.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<nav class="breadcrumbs-container">
<ul class="breadcrumbs">
{% assign crumbs = page.url | remove:'/index.html' | split: '/' %}
<li class="breadcrumb-item">
<a href="{% if site.baseurl == '/' %}{{ site.baseurl }}{% else %}{{ site.baseurl }}/{% endif %}">Home</a>
</li>
{% for crumb in crumbs offset: 1 %}
{% if forloop.last %}
<li class="breadcrumb-item">{{ page.title }}</li>
{% else %}
<li class="breadcrumb-item">
<a href="{{ site.baseurl }}{% assign crumb_limit = forloop.index | plus: 1 %}{% for crumb in crumbs limit: crumb_limit %}{{ crumb | append: '/' | replace:'without-plugin/','without-plugins/' }}{% endfor %}">{{ crumb | replace:'-',' ' | remove:'.html' | capitalize }}</a>
</li>
{% endif %}
{% endfor %}
</ul>
</nav>
28 changes: 20 additions & 8 deletions _includes/footer.html
Original file line number Diff line number Diff line change
@@ -1,11 +1,23 @@
<div class="jump-top-container">
<div id="jump-top" class="jump-top noSelect desktop-only"><span class="material-icons">arrow_upward</span></div>
</div>

<div class="page-status-container"></div>

<footer class="footer">
<nav class="footer-nav">
{% for navpage in site.nav.footer %}
<a class="footer-nav-link" href="{{ navpage.url }}">{{ navpage.name }}</a>
{% endfor %}
</nav>
<div class="credit">
Created by <a href="http://www.gidgreen.com/">Gideon Greenspan</a>, <a href="https://github.com/svivian">Scott Vivian</a>,
and <a href="https://github.com/q2a/question2answer/graphs/contributors">contributors</a>
<div class="footer-container">
<nav class="footer-nav">
<ul>
{% for navpage in site.nav.footer %}
<li>
<a class="footer-nav-link" href="{% if navpage.url contains 'http' %}{{ navpage.url }}{% else %}{{ site.baseurl }}{{ navpage.url }}{% endif %}">{{ navpage.name }}</a>
</li>
{% endfor %}
</ul>
</nav>
<div class="credit">
Created by <a href="http://www.gidgreen.com/">Gideon Greenspan</a>, <a href="https://github.com/svivian">Scott Vivian</a>,
and <a href="https://github.com/q2a/question2answer/graphs/contributors">contributors</a>
</div>
</div>
</footer>
89 changes: 79 additions & 10 deletions _includes/header.html
Original file line number Diff line number Diff line change
@@ -1,15 +1,84 @@
{% if page.slug == 'homepage' %}
<div class="wave-container"></div>
{% endif %}

<header class="header">
<div class="header-logo">
<a href="/"><img class="logo-img normal-logo" src="/images/question2answer-logo-white-350x40.png" alt="Question2Answer logo"></a>
<div class="header-container flex-row">
<div class="flex-item logo-container">
<div id="main-nav-trigger" class="material-icons noSelect mobile-only">menu</div>
<a href="{% if site.baseurl == '/' %}{{ site.baseurl }}{% else %}{{ site.baseurl }}/{% endif %}" class="header-logo">
<img class="logo-img normal-logo" src="{{ site.baseurl }}/images/question2answer-logo-350x40.webp" alt="Question2Answer logo">
{% if page.slug == 'homepage' %}
<img class="logo-img white-logo" src="{{ site.baseurl }}/images/question2answer-logo-white-350x40.webp" alt="Question2Answer logo">
{% endif %}
</a>
</div>

<nav class="nav-container flex-item flex-middle no-select">
<a href="{% if site.baseurl == '/' %}{{ site.baseurl }}{% else %}{{ site.baseurl }}/{% endif %}" class="header-logo mobile-only">
<img class="logo-img normal-logo" src="{{ site.baseurl }}/images/question2answer-logo-350x40.webp" alt="Question2Answer logo">
</a>
<ul class="nav mega-menu flex-item">
<span class="mega-menu-trigger">
<span class="nav-item" tabindex="0">
Documentation
<span class="docs-caret"></span>
</span>
</span>

<ul class="nav nav-main flex-item display-none">
{% for navpage in site.nav.main %}{% capture parent_url %}{{ navpage.path }}{% endcapture %}
<li>
<span class="nav-item toggleChildren{% if page.url == parent_url %} selected-nav{% endif %}" tabindex="0">
{{ navpage.name }}
<span class="docs-caret"></span>
</span>
{% if navpage.sub %}
<ul class="sub-nav display-none">
{% for subnavpage in site.nav[navpage.sub] %}{% capture child_url %}{{ subnavpage.path }}{% endcapture %}
<li><a href="{{ site.baseurl }}{{ subnavpage.path }}"
class="sub-nav-item{% if page.url == child_url %} selected-nav{% endif %}">{{ subnavpage.name }}</a></li>
{% endfor %}
</ul>
{% endif %}
</li>
{% endfor %}
</ul>
<ul class="nav nav-main-second flex-item">
{% for navpage in site.nav.second %}{% capture parent_url %}{{ navpage.path }}{% endcapture %}
<li>
<span class="nav-item toggleChildren{% if page.url == parent_url %} selected-nav{% endif %}" tabindex="0">
{{ navpage.name }}
<span class="docs-caret"></span>
</span>
{% if navpage.sub %}
<ul class="sub-nav display-none">
{% for subnavpage in site.nav[navpage.sub] %}{% capture child_url %}{{ subnavpage.path }}{% endcapture %}
<li><a href="{{ site.baseurl }}{{ subnavpage.path }}"
class="sub-nav-item{% if page.url == child_url %} selected-nav{% endif %}">{{ subnavpage.name }}</a></li>
{% endfor %}
</ul>
{% endif %}
</li>
{% endfor %}
</ul>
</ul>
<ul class="nav nav-main-third flex-item">
{% for navpage in site.nav.third %}{% capture parent_url %}{{ navpage.path }}{% endcapture %}
<li>
<a class="nav-item
{% if page.url == parent_url %} selected-nav {% endif %}
{{ navpage.class | default: '' }}"
href="{% if navpage.url contains 'http' %}{{ navpage.url }}{% else %}{{ site.baseurl }}{{ navpage.url }}{% endif %}">{{ navpage.name }}</a>
</li>
{% endfor %}
</ul>
</nav>

<div class="darkPane"></div>
</div>
<nav class="top-nav main-nav">
{% for navpage in site.nav.main %}
<a class="main-nav-link" href="{{ navpage.path }}">{{ navpage.name }}</a>
{% endfor %}
{% for navpage in site.nav.second %}
<a class="main-nav-link {{ navpage.class | default: '' }}" href="{{ navpage.url }}">{{ navpage.name }}</a>
{% endfor %}
</nav>
</header>

{% if page.slug != 'homepage' %}
{% include breadcrumbs.html %}
{% endif %}
15 changes: 0 additions & 15 deletions _includes/nav-sub.html

This file was deleted.

7 changes: 7 additions & 0 deletions _includes/sidebar.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<section>
<nav class="page-sidebar-content">
<ul class="docs-nav">
<!-- will populate -->
</ul>
</nav>
</section>
82 changes: 36 additions & 46 deletions _layouts/default.html
Original file line number Diff line number Diff line change
@@ -1,49 +1,39 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width initial-scale=1" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">

<link rel="preconnect" href="https://fonts.gstatic.com">
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,400;0,700;1,400;1,700">
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
<link rel="stylesheet" href="/css/styles2020.css">

<title>{% if page.title %}{{ page.title | escape }}{% else %}{{ site.title }}{% endif %}</title>
<meta name="description" content="{{ site.description }}">

<link rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: site.url }}">
<link rel="shortcut icon" type="image/x-icon" href="/favicon.ico">
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
{% include analytics.html %}
</head>

<body class="page">

{% include header.html %}

<main class="page-container">
{{ content }}
</main>

{% include footer.html %}

<script>
window.addEventListener('load', stickyHeader);
window.addEventListener('scroll', stickyHeader, {passive: true});

// Get the offset position of the navbar
var header = document.querySelector('header.header');
var stickyPos = header ? header.offsetTop : 0;

function stickyHeader() {
if (window.scrollY > stickyPos) {
header.classList.add('sticky');
} else {
header.classList.remove('sticky');
}
}
</script>
</body>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width initial-scale=1" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">

<link rel="preconnect" href="https://fonts.gstatic.com">
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,400;0,500;0,700;1,400;1,500;1,700&amp;display=swap">
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
<link rel="stylesheet" href="{{ site.baseurl }}/css/styles.css">

<title>{% if page.title %}{{ page.title | escape }}{% else %}{{ site.title }}{% endif %}</title>
<meta name="description" content="{{ site.description }}">

<link rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: site.url }}">
<link rel="shortcut icon" type="image/x-icon" href="{{ site.baseurl }}/favicon.ico">
<link rel="apple-touch-icon" sizes="180x180" href="{{ site.baseurl }}/apple-touch-icon.png">
{% include analytics.html %}
</head>

<body class="page{% if page.slug %} template-{{ page.slug }}{% endif %}">

{% include header.html %}

<main class="page-container">
{{ content }}
</main>

{% include footer.html %}

<script src="{{ site.baseurl }}/js/scripts.js"></script>

{% if page.slug == 'addons-plugins' or page.slug == 'addons-themes' %}
<script src="{{ site.baseurl }}/js/GithubLinks.js"></script>
{% endif %}

</body>
</html>
48 changes: 30 additions & 18 deletions _layouts/home.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,23 @@
layout: default
---

<h1 class="home-intro"><strong>Question2Answer</strong> (Q2A) is a popular open source Q&A platform for PHP/MySQL, currently running on <a href="https://www.question2answer.org/sites.php">24,500+ sites in 40 languages</a>.</h1>
<div class="home-intro-container">
<h1 class="home-intro"><strong>Question2Answer</strong> (Q2A) is a popular open source Q&A platform for PHP/MySQL, currently running on <a href="https://www.question2answer.org/sites.php">24,500+ sites in 40 languages</a>.</h1>
</div>

{{ content }}
<div class="notice-container display-none">
<div class="notice">
<div class="close-notice material-icons">close</div>
<div class="notice-image"></div>
<div class="notice-text home-intro-card">
{{ content }}
</div>
<div class="clear"></div>
</div>
<div class="close-sheet"></div>
</div>

<div class="showcase-cols">
<article class="showcase-cols">

{% capture answerText %}
<p>A Q&amp;A site helps your online community to share knowledge.
Expand All @@ -23,8 +35,8 @@ <h1 class="home-intro"><strong>Question2Answer</strong> (Q2A) is a popular open
{% include card-showcase.html icon="people" title="Why offer Q&amp;A on my site?" answer=answerText %}

{% capture answerText %}
<p><a href="https://www.question2answer.org/question2answer-latest.zip"><b>Download Question2Answer</b></a>, then read <a href="/install/">how to install</a>.
Version 1.8.8 was <a href="/install/versions/">released</a> on July 25th, 2023.
<p><a href="https://www.question2answer.org/question2answer-latest.zip"><b>Download Question2Answer</b></a>, then read <a href="{{ site.baseurl }}/install/">how to install</a>.
Version 1.8.8 was <a href="{{ site.baseurl }}/install/versions/">released</a> on July 25th, 2023.
Also <a href="https://github.com/q2a/question2answer">on GitHub</a>.</p>
<p>Question2Answer is open source, <a href="https://www.question2answer.org/license.php">licensed under GPL v2+</a>.</p>
{% endcapture %}
Expand All @@ -43,9 +55,9 @@ <h1 class="home-intro"><strong>Question2Answer</strong> (Q2A) is a popular open

{% capture answerText %}
<ul>
<li>Q2A takes 5 minutes (or less!) to <a href="/install/">install</a>.</li>
<li>Easy styling with <a href="/themes/">CSS themes</a>.</li>
<li>Supports <a href="/translate/">translation</a> into any language.</li>
<li>Q2A takes 5 minutes (or less!) to <a href="{{ site.baseurl }}/install/">install</a>.</li>
<li>Easy styling with <a href="{{ site.baseurl }}/themes/">CSS themes</a>.</li>
<li>Supports <a href="{{ site.baseurl }}/translate/">translation</a> into any language.</li>
<li>Custom sidebar, widgets, pages and links.</li>
<li>SEO features such as <a href="https://www.sitemaps.org/">XML Sitemap</a> and neat URLs.</li>
</ul>
Expand All @@ -68,35 +80,35 @@ <h1 class="home-intro"><strong>Question2Answer</strong> (Q2A) is a popular open
<li>Create experts, editors, moderators and admins.</li>
<li>User avatars (or <a href="https://en.gravatar.com/">Gravatar</a>) and custom fields.</li>
<li>Private messages and public wall posts.</li>
<li>Log in via Facebook or others (using <a href="/addons/plugins/">plugins</a>).</li>
<li>Log in via Facebook or others (using <a href="{{ site.baseurl }}/addons/plugins/">plugins</a>).</li>
</ul>
{% endcapture %}
{% include card-showcase.html icon="face" title="Built-in user account management ..." answer=answerText %}

{% capture answerText %}
<ul>
<li>Out-of-the-box <a href="/install/wordpress/">WordPress</a> and Joomla integration.</li>
<li>Custom <a href="/install/single-sign-on/">single sign-on</a> support for other sites.</li>
<li>Deep integration and customization via <a href="/plugins/">plugins</a>.</li>
<li>Out-of-the-box <a href="{{ site.baseurl }}/install/wordpress/">WordPress</a> and Joomla integration.</li>
<li>Custom <a href="{{ site.baseurl }}/install/single-sign-on/">single sign-on</a> support for other sites.</li>
<li>Deep integration and customization via <a href="{{ site.baseurl }}/plugins/">plugins</a>.</li>
</ul>
{% endcapture %}
{% include card-showcase.html icon="assignment_ind" title="... or integrate with existing sites" answer=answerText %}

{% capture answerText %}
<ul>
<li>PHP/MySQL <a href="/install/optimize/">scalable</a> to millions of users and posts.</li>
<li><a href="/install/security/">Safe from</a> XSS, CSRF and SQL injection attacks.</li>
<li>PHP/MySQL <a href="{{ site.baseurl }}/install/optimize/">scalable</a> to millions of users and posts.</li>
<li><a href="{{ site.baseurl }}/install/security/">Safe from</a> XSS, CSRF and SQL injection attacks.</li>
<li>Beat spam with captchas, moderation and/or flagging.</li>
</ul>
{% endcapture %}
{% include card-showcase.html icon="policy" title="Fast and secure" answer=answerText %}

{% capture answerText %}
<p>Contribute <a href="https://github.com/q2a/question2answer">via Github</a>,
create a <a href="/themes/">theme</a>,
<a href="/plugins/">plugin</a> or
<a href="/translate/">translation</a>.</p>
create a <a href="{{ site.baseurl }}/themes/">theme</a>,
<a href="{{ site.baseurl }}/plugins/">plugin</a> or
<a href="{{ site.baseurl }}/translate/">translation</a>.</p>
{% endcapture %}
{% include card-showcase.html icon="translate" title="How can I help?" answer=answerText %}

</div>
</article>
Loading