awwwards-mcp 1.7.1 → 1.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/server.js +3 -2
- package/package.json +3 -2
package/dist/server.js
CHANGED
|
@@ -83,6 +83,7 @@ function errorResponse(err) {
|
|
|
83
83
|
export const MOTION_DNA_TTL_MS = 90 * 24 * 60 * 60 * 1000;
|
|
84
84
|
export function createHandlers(deps) {
|
|
85
85
|
const { client, cache } = deps;
|
|
86
|
+
const nowMs = deps.now ?? Date.now;
|
|
86
87
|
// Which filter wins the URL (combined filter URLs 404 on awwwards.com).
|
|
87
88
|
const urlSource = (f) => f.color ? "color" : f.award ? "award" : f.technology ? "technology" : f.tags?.length ? "tag" : "none";
|
|
88
89
|
// Two modes:
|
|
@@ -793,7 +794,7 @@ export function createHandlers(deps) {
|
|
|
793
794
|
// ---- longitudinal monitoring ----
|
|
794
795
|
async function new_winners(args) {
|
|
795
796
|
try {
|
|
796
|
-
const res = await fetchNewWinners(client, cache, { award: args.award ?? "sotd" });
|
|
797
|
+
const res = await fetchNewWinners(client, cache, { award: args.award ?? "sotd", now: nowMs });
|
|
797
798
|
// Seed the sites cache too — next search_sites serves these rows
|
|
798
799
|
// without re-fetching the same listing.
|
|
799
800
|
if (res.newWinners.length > 0)
|
|
@@ -808,7 +809,7 @@ export function createHandlers(deps) {
|
|
|
808
809
|
for (const site of res.newWinners) {
|
|
809
810
|
try {
|
|
810
811
|
const html = await client.getHtml(site.detailPath);
|
|
811
|
-
records.push(...recordsFromSiteHtml(html, site, Math.floor(
|
|
812
|
+
records.push(...recordsFromSiteHtml(html, site, Math.floor(nowMs() / 1000)));
|
|
812
813
|
backfilled++;
|
|
813
814
|
}
|
|
814
815
|
catch {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "awwwards-mcp",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.2",
|
|
4
4
|
"description": "Free MCP server giving AI agents design inspiration from Awwwards: search award-winning sites with inline screenshots and extract design DNA.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -50,10 +50,11 @@
|
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
52
|
"@types/node": "^24.0.0",
|
|
53
|
+
"@vitest/mocker": "^4.1.11",
|
|
53
54
|
"ffmpeg-static": "^5.3.0",
|
|
54
55
|
"playwright": "^1.63.0",
|
|
55
56
|
"tsx": "^4.19.0",
|
|
56
57
|
"typescript": "^5.6.0",
|
|
57
|
-
"vitest": "^
|
|
58
|
+
"vitest": "^4.1.11"
|
|
58
59
|
}
|
|
59
60
|
}
|