Skip to content

Commit 29e2b15

Browse files
committed
chore: add eleventy stuff from bugs site
1 parent f194d4a commit 29e2b15

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+6829
-209
lines changed

.editorconfig

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# EditorConfig is awesome: editorconfig.org
2+
3+
# top-most EditorConfig file
4+
root = true
5+
6+
[*]
7+
end_of_line = lf
8+
insert_final_newline = true
9+
charset = utf-8
10+
indent_size = 2
11+
indent_style = space

.github/workflows/deploy.yml

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
name: Deploy site
2+
3+
on:
4+
# Runs on pushes targeting the default branch
5+
# push:
6+
# branches: ['main']
7+
8+
# Allows you to run this workflow manually from the Actions tab
9+
workflow_dispatch:
10+
11+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
12+
permissions:
13+
contents: write
14+
id-token: write
15+
16+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
17+
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
18+
concurrency:
19+
group: 'pages'
20+
cancel-in-progress: false
21+
22+
# Default to bash
23+
defaults:
24+
run:
25+
shell: bash
26+
27+
jobs:
28+
deploy:
29+
runs-on: ubuntu-latest
30+
env:
31+
DEPLOY_DIR: _site/
32+
DEPLOY_BRANCH: gh-pages
33+
steps:
34+
- name: Checkout
35+
uses: actions/checkout@v3
36+
with:
37+
submodules: recursive
38+
39+
- name: Prepare deployment branch
40+
run: |
41+
mkdir "${DEPLOY_DIR}"
42+
cd "${DEPLOY_DIR}"
43+
# Clone and checkout existing branch, or initialise with a new and empty branch
44+
git clone --depth 5 --branch "${DEPLOY_BRANCH}" "https://github.com/${GITHUB_REPOSITORY}.git" . || git init -b "${DEPLOY_BRANCH}"
45+
46+
- name: Install Node.js dependencies
47+
run: npm ci
48+
49+
- name: Build with Eleventy
50+
env:
51+
NODE_ENV: production
52+
NODE_OPTIONS: '--max_old_space_size=4096'
53+
run: npm run build
54+
55+
- name: Push to branch
56+
# Inspired by https://github.com/helaili/jekyll-action/blob/2.2.0/entrypoint.sh
57+
env:
58+
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
59+
run: |
60+
cd "${DEPLOY_DIR}"
61+
touch .nojekyll
62+
git config user.name "${GITHUB_ACTOR}" && \
63+
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" && \
64+
git add . && \
65+
git commit --allow-empty -m "Build commit ${GITHUB_SHA}" && \
66+
git push "https://${GITHUB_ACTOR}:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git" "HEAD:${DEPLOY_BRANCH}"

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,3 +128,6 @@ dist
128128
.yarn/build-state.yml
129129
.yarn/install-state.gz
130130
.pnp.*
131+
132+
# eleventy
133+
_site

.prettierrc.cjs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
module.exports = {
2+
semi: false,
3+
singleQuote: true,
4+
arrowParens: 'always',
5+
trailingComma: 'none',
6+
endOfLine: 'auto'
7+
}

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2023 Timmy Willison
3+
Copyright (c) 2023 OpenJS Foundation
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal
File renamed without changes.
File renamed without changes.
File renamed without changes.

_includes/layouts/base.njk

Lines changed: 167 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,167 @@
1+
<!doctype html>
2+
<html lang="{{ metadata.language }}">
3+
<head>
4+
<meta charset="utf-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
6+
<title data-pagefind-meta="title">{{ title or metadata.title }}</title>
7+
<meta name="description" content="{{ description or metadata.description }}">
8+
{% favicon './public/favicon.svg' %}
9+
{#
10+
CSS bundles are provided via the `eleventy-plugin-bundle` plugin:
11+
1. You can add to them using `{% css %}`
12+
2. You can get from them using `{% getBundle "css" %}` or `{% getBundleFileUrl "css" %}`
13+
3. You can do the same for JS: {% js %}{% endjs %} and <script>{% getBundle "js" %}</script>
14+
4. Learn more: https://github.com/11ty/eleventy-plugin-bundle
15+
#}
16+
{#
17+
Hot reload isn't working with the bundle plugin on windows
18+
See https://github.com/11ty/eleventy/issues/2807
19+
#}
20+
{%- css %}{% include "public/css/index.css" %}{% endcss %}
21+
{%- css %}{% include "public/css/search.css" %}{% endcss %}
22+
{# These are in the njk so the path prefix is respected #}
23+
{%- css %}
24+
body {
25+
background-image: url({{ '/img/bg-interior-tile-drk.jpg' | htmlBaseUrl }});
26+
}
27+
a.ext-link .icon {
28+
background: url({{ '/img/extlink.png' | htmlBaseUrl }}) 0 50% no-repeat;
29+
}
30+
#search:after {
31+
background: url({{ '/img/icon-search.png' | htmlBaseUrl }}) 0 0 no-repeat;
32+
}
33+
{% endcss %}
34+
{# Add an arbitrary string to the bundle #}
35+
{# {%- css %}* { box-sizing: border-box; }{% endcss %} #}
36+
{# Render the CSS bundle using Inlined CSS (for the fastest site performance in production) #}
37+
<style>
38+
{% getBundle "css" %}
39+
</style>
40+
{#- Renders the CSS bundle using a separate file, if you can't set CSP directive style-src: 'unsafe-inline' #}
41+
{# <link rel="stylesheet" href="{% getBundleFileUrl "css" %}"> #}
42+
</head>
43+
<body>
44+
<div class="banner flex-center">
45+
<span>jQuery issues have moved to <a href="https://github.com/jquery/jquery/issues">GitHub</a>. This site is now a static archive of the old <a href="https://trac.edgewall.org/">Trac</a> bugs site. Some functions and pages are no longer available.</span>
46+
</div>
47+
<div class="container">
48+
<a href="#skip" class="visually-hidden">Skip to main content</a>
49+
<header class="flex-column">
50+
<div class="flex-row flex-between-start">
51+
<a id="jq-siteLogo" href="/" title="jQuery Home">
52+
<img src="/img/logo.svg" width="215" alt="jQuery: Write Less, Do More." />
53+
</a>
54+
<input class="hamburger-toggle visually-hidden" id="jq-menutoggle" type="checkbox" />
55+
<label aria-label="Toggle Menu" for="jq-menutoggle" class="hamburger-lines flex-column flex-between-center">
56+
<span class="hamburger-line"></span>
57+
<span class="hamburger-line"></span>
58+
<span class="hamburger-line"></span>
59+
</label>
60+
<div id="jq-menus">
61+
<nav id="jq-primaryNavigation">
62+
<h2 class="visually-hidden">jQuery sites navigation menu</h2>
63+
<ul class="nav">
64+
<li class="jq-jquery active">
65+
<a href="https://jquery.com/" title="jQuery Home">jQuery</a>
66+
</li>
67+
<li class="jq-plugins">
68+
<a href="https://plugins.jquery.com/" title="jQuery Plugins">Plugins</a>
69+
</li>
70+
<li class="jq-ui">
71+
<a href="https://jqueryui.com/" title="jQuery UI">UI</a>
72+
</li>
73+
<li class="jq-meetup">
74+
<a href="https://meetups.jquery.com/" title="jQuery Meetups">Meetups</a>
75+
</li>
76+
<li class="jq-forum">
77+
<a href="https://forum.jquery.com/" title="jQuery Forum">Forum</a>
78+
</li>
79+
<li class="jq-blog">
80+
<a href="https://blog.jquery.com/" title="jQuery Blog">Blog</a>
81+
</li>
82+
<li class="jq-about">
83+
<a href="https://openjsf.org" title="About jQuery and OpenJS">About</a>
84+
</li>
85+
<li class="jq-donate">
86+
<a href="https://openjsf.org/about/project-funding-opportunities/" title="Donate to OpenJS">Donate</a>
87+
</li>
88+
</ul>
89+
</nav>
90+
<nav id="jq-secondaryNavigation">
91+
<h2 class="visually-hidden">jQuery Core navigation menu</h2>
92+
<ul class="nav">
93+
<li class="jq-download">
94+
<a href="https://jquery.com/download/">
95+
Download
96+
</a>
97+
</li>
98+
<li class="jq-documentation">
99+
<a href="https://api.jquery.com/">
100+
Documentation
101+
</a>
102+
</li>
103+
<li class="jq-tutorials">
104+
<a href="https://learn.jquery.com/">
105+
Tutorials
106+
</a>
107+
</li>
108+
<li class="jq-bugTracker">
109+
<a href="https://github.com/jquery/jquery/issues">
110+
Bug Tracker
111+
</a>
112+
</li>
113+
<li class="jq-discussion">
114+
<a href="https://forum.jquery.com/">
115+
Discussion
116+
</a>
117+
</li>
118+
</ul>
119+
</nav>
120+
</div>
121+
</div>
122+
<div id="bug-tracker-form" class="flex-column flex-between-center">
123+
<h1>Bug Tracker</h1>
124+
<div id="search"></div>
125+
{# <form class="flex-row flex-start-center" action="/search" method="get">
126+
<label for="jq-primarySearch">Search Tickets</label>
127+
<input type="text" value="" title="Search jQuery" name="q" id="jq-primarySearch">
128+
<button type="submit" name="go" id="jq-searchButton">
129+
<span class="visually-hidden">Search</span>
130+
</button>
131+
</form> #}
132+
</div>
133+
</header>
134+
<main id="skip" class="flex-column">
135+
<h2 class="visually-hidden">Side navigation</h2>
136+
<nav id="jq-sidenav" class="flex-column white-box">
137+
<h5 class="sidenav-header">Bug Tracker</h5>
138+
<a href="/newticket">New Ticket</a>
139+
<a href="/report">View Tickets</a>
140+
<a href="/ticketgraph">Ticket Graph</a>
141+
<a href="/roadmap">Roadmap</a>
142+
<a href="/timeline">Recent Changes</a>
143+
</nav>
144+
<div id="jq-content" class="white-box">
145+
{{ content | safe }}
146+
</div>
147+
</main>
148+
<footer>
149+
Copyright &copy; {% currentYear %}
150+
<a href="https://openjsf.org">The OpenJS Foundation</a>
151+
</footer>
152+
</div>
153+
<script src="/pagefind/pagefind-ui.js" type="text/javascript"></script>
154+
<script>
155+
window.addEventListener('DOMContentLoaded', (event) => {
156+
new PagefindUI({
157+
element: "#search",
158+
showImages: false,
159+
translations: {
160+
placeholder: '',
161+
zero_results: 'No matches found.'
162+
}
163+
})
164+
})
165+
</script>
166+
</body>
167+
</html>

_includes/layouts/ticket.njk

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
layout: layouts/base.njk
3+
---
4+
5+
{%- css %}{% include "public/css/ticket.css" %}{% endcss %}
6+
7+
<div class="flex-column" data-pagefind-body>
8+
{{ content | safe }}
9+
</div>

0 commit comments

Comments
 (0)