mevebu 1.0.0 → 1.1.0
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/mevebu/app/mevebu.js +10 -10
- package/mevebu/app/tailwind.css +2795 -0
- package/mevebu/app/tailwind.src.css +1188 -0
- package/mevebu/index.html +2 -3
- package/mevebu/libs/js/core.js +1 -1
- package/mevebu/libs/js/tools/hash-generator.js +2 -2
- package/mevebu/libs/js/tools/name-picker.js +1 -1
- package/mevebu/libs/js/tools/qr-scanner.js +1 -1
- package/package.json +6 -2
- package/mevebu/app/mevebu.css +0 -1207
- package/mevebu/libs/css/tools.css +0 -237
package/mevebu/app/mevebu.js
CHANGED
|
@@ -336,14 +336,14 @@ function toolRow(tool, onToggle) {
|
|
|
336
336
|
return el(
|
|
337
337
|
"li",
|
|
338
338
|
{
|
|
339
|
-
class: "mvb-
|
|
339
|
+
class: "mvb-listrow",
|
|
340
340
|
dataset: { href: toolHref(tool), haystack: `${tool.name} ${tool.note} ${tool.keywords ?? ""}`.toLowerCase() },
|
|
341
341
|
},
|
|
342
342
|
el(
|
|
343
343
|
"a",
|
|
344
|
-
{ class: "mvb-
|
|
345
|
-
el("span", { class: "mvb-
|
|
346
|
-
el("span", { class: "mvb-
|
|
344
|
+
{ class: "mvb-listrow__link", href: toolHref(tool) },
|
|
345
|
+
el("span", { class: "mvb-listrow__name" }, tool.name),
|
|
346
|
+
el("span", { class: "mvb-listrow__note" }, tool.note)
|
|
347
347
|
),
|
|
348
348
|
starButton(tool, onToggle)
|
|
349
349
|
);
|
|
@@ -367,21 +367,21 @@ function filterBar(placeholder = "Search tools") {
|
|
|
367
367
|
);
|
|
368
368
|
}
|
|
369
369
|
|
|
370
|
-
/** Live filters `.mvb-card` grids and `.mvb-
|
|
370
|
+
/** Live filters `.mvb-card` grids and `.mvb-listrow` lists already in the tree. */
|
|
371
371
|
function wireFilter(root, meta) {
|
|
372
372
|
const input = root.querySelector(".mvb-filter__in");
|
|
373
373
|
if (!input) return;
|
|
374
374
|
const run = () => {
|
|
375
375
|
const query = input.value.trim().toLowerCase();
|
|
376
376
|
let shown = 0;
|
|
377
|
-
for (const item of root.querySelectorAll(".mvb-card, .mvb-
|
|
377
|
+
for (const item of root.querySelectorAll(".mvb-card, .mvb-listrow")) {
|
|
378
378
|
const hay = item.dataset.haystack ?? item.textContent.toLowerCase();
|
|
379
379
|
const hit = !query || hay.includes(query);
|
|
380
380
|
item.hidden = !hit;
|
|
381
381
|
if (hit) shown++;
|
|
382
382
|
}
|
|
383
383
|
for (const section of root.querySelectorAll("[data-mvb-group]")) {
|
|
384
|
-
const any = [...section.querySelectorAll(".mvb-card, .mvb-
|
|
384
|
+
const any = [...section.querySelectorAll(".mvb-card, .mvb-listrow")].some((item) => !item.hidden);
|
|
385
385
|
section.hidden = !any;
|
|
386
386
|
}
|
|
387
387
|
meta.textContent = query ? `${shown} of ${TOOLS.length} tools` : `${TOOLS.length} tools`;
|
|
@@ -389,7 +389,7 @@ function wireFilter(root, meta) {
|
|
|
389
389
|
input.addEventListener("input", run);
|
|
390
390
|
input.addEventListener("keydown", (event) => {
|
|
391
391
|
if (event.key !== "Enter") return;
|
|
392
|
-
const first = [...root.querySelectorAll(".mvb-card, .mvb-
|
|
392
|
+
const first = [...root.querySelectorAll(".mvb-card, .mvb-listrow")].find((item) => !item.hidden);
|
|
393
393
|
if (first) {
|
|
394
394
|
const href = first.tagName === "A" ? first.getAttribute("href") : first.dataset.href;
|
|
395
395
|
go(href.slice(1));
|
|
@@ -532,7 +532,7 @@ function favoritesPage() {
|
|
|
532
532
|
"Tap the star on any tool to keep it here. ",
|
|
533
533
|
el("a", { class: "mvb-link", href: "#/tools" }, "Browse the tools")),
|
|
534
534
|
el("section", { class: "mvb-section" },
|
|
535
|
-
el("ul", { class: "mvb-
|
|
535
|
+
el("ul", { class: "mvb-list" }, ...saved.map((tool) => toolRow(tool, rerenderFavorites))))
|
|
536
536
|
);
|
|
537
537
|
}
|
|
538
538
|
|
|
@@ -653,7 +653,7 @@ function aboutPage() {
|
|
|
653
653
|
el("p", {}, "Add one object to ", el("code", {}, "mevebu/libs/js/registry.js"), " and one file in ", el("code", {}, "mevebu/libs/js/tools/"), ". The home page, the index, the categories, search and the route all come from that entry.")),
|
|
654
654
|
|
|
655
655
|
block("Built with",
|
|
656
|
-
el("p", {}, "
|
|
656
|
+
el("p", {}, "Hand written HTML, CSS and JavaScript, with Tailwind for the stylesheet. Icons are Lucide and the QR decoder is jsQR."),
|
|
657
657
|
el("p", {}, "Source and issues: ",
|
|
658
658
|
el("a", { class: "mvb-link", href: REPO_URL, target: "_blank", rel: "noopener" }, "github.com/mevebu/mevebu")),
|
|
659
659
|
el("p", {}, copyButton(() => location.href, "Copy this page link")))
|