Skip to content

Commit 7482379

Browse files
committed
feat(plugin): add warning banner to plugin pages
1 parent 6ad095f commit 7482379

File tree

6 files changed

+19
-6
lines changed

6 files changed

+19
-6
lines changed

_includes/icons/warning.svg

Lines changed: 1 addition & 0 deletions
Loading

content/index.njk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ layout: layouts/base.njk
1212
<p>New plugin releases will not be processed.</p>
1313
<hr/>
1414
<p>The jQuery Plugin Registry is preserved for historical purposes. Search is still supported.</p>
15-
<p class="italic">We do not recommend using any plugins from this registry. Please find jQuery plugins on <a href="https://www.npmjs.com/search?q=keywords:jquery-plugin">npm</a>.</p>
15+
<p class="italic">We do not recommend using any versions of plugins from this registry. Please find jQuery plugins on <a href="https://www.npmjs.com/search?q=keywords:jquery-plugin">npm</a>.</p>
1616
</div>
1717

1818
<div class="flex flex-col px-6 py-5 lg:w-[300px]">

content/plugin.njk

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,18 @@
3636
---
3737

3838
<div class="flex flex-col gap-5 py-5 px-6 lg:flex-row">
39+
3940
<div class="flex flex-col gap-2 grow">
41+
<div class="flex flex-row justify-center gap-1 mb-3 p-4 text-center bg-warning rounded">
42+
<div class="pt-px">
43+
{% include "icons/warning.svg" %}
44+
</div>
45+
<div class="text-lg">
46+
This version is old school.
47+
Please find jQuery plugins on <a href="https://www.npmjs.com/search?q=keywords:jquery-plugin">npm</a>.
48+
</div>
49+
</div>
50+
4051
<h1 class="lg:text-4xl">{{ plugin.name }}</h1>
4152

4253
<div>

eleventy.config.js

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,6 @@ export default function eleventyConfig(eleventyConfig) {
7878
)
7979
})
8080

81-
eleventyConfig.addFilter('htmlDateString', (dateObj) => {
82-
// dateObj input: https://html.spec.whatwg.org/multipage/common-microsyntaxes.html#valid-date-string
83-
return DateTime.fromJSDate(dateObj, { zone: 'utc' }).toFormat('yyyy-LL-dd')
84-
})
85-
8681
// Get the first `n` elements of a collection.
8782
eleventyConfig.addFilter('head', (array, n) => {
8883
if (!Array.isArray(array) || array.length === 0) {

styles/tailwind.config.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,9 @@ module.exports = {
5353
hover: '#e6e6e6'
5454
},
5555
transparent: 'transparent',
56+
warning: {
57+
DEFAULT: '#ffffaa'
58+
},
5659
white: {
5760
DEFAULT: '#ffffff',
5861
dark: '#f2f2f2',

styles/tailwind.css

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@
4343
hr {
4444
@apply bg-gray-lightest my-3 h-3 border-none;
4545
}
46+
svg {
47+
@apply shrink-0;
48+
}
4649

4750
h1 svg,
4851
h2 svg,

0 commit comments

Comments
 (0)