Comment out unused Card html, remove unused react-icons-all-files pkg, remove fuse.js

This commit is contained in:
Xevion
2023-02-16 14:30:22 -06:00
parent 3cf51db942
commit 9c5627935a
3 changed files with 4 additions and 22 deletions

View File

@@ -10,10 +10,8 @@
},
"dependencies": {
"@loadable/component": "^5.15.3",
"@react-icons/all-files": "^4.1.0",
"babel-plugin-codegen": "^4.1.5",
"babel-plugin-macros": "^3.1.0",
"fuse.js": "^6.6.2",
"next": "13.1.6",
"react": "18.2.0",
"react-dom": "18.2.0",
@@ -28,8 +26,8 @@
"@types/node": "^18.11.18",
"@types/prettier": "^2.7.2",
"@types/react": "^18.0.26",
"@types/react-no-ssr": "^1.1.3",
"@types/react-dom": "^18.0.10",
"@types/react-no-ssr": "^1.1.3",
"@typescript-eslint/eslint-plugin": "^5.47.1",
"@typescript-eslint/parser": "^5.47.1",
"autoprefixer": "^10.4.7",

View File

@@ -1,18 +1,14 @@
import {type NextPage} from "next";
import Head from "next/head";
import Card from "../components/Card";
// @ts-ignore
import iconList from "@utils/iconList";
import {useEffect, useMemo, useState} from "react";
import {useDebounce} from "usehooks-ts";
// import Fuse from "fuse.js";
import {AiOutlineLoading3Quarters} from "react-icons/ai";
import IconCatalog from "@components/render/IconCatalog";
import NoSSR from 'react-no-ssr';
const icons = iconList as { id: string, setId: string }[];
// const fuse = new Fuse(icons, {keys: ["id", "setId"], threshold: 0.2})
const maximumResults = 10000;
const Home: NextPage = () => {
const [query, setQuery] = useState("");
@@ -60,9 +56,7 @@ const Home: NextPage = () => {
{showLoading ? <AiOutlineLoading3Quarters className="animate-spin h-5 w-5"/>
: (query.length == 0
? icons.length
: (filtered.length === maximumResults
? `${maximumResults}+`
: filtered.length))}
: filtered.length)}
</span>
{
timing !== 0
@@ -74,7 +68,7 @@ const Home: NextPage = () => {
<div>
{catalog}
</div>
<ul role="list" className="hidden grid gap-4 p-0 link-card-grid"
{/*<ul role="list" className="grid gap-4 p-0 link-card-grid"
style={{gridTemplateColumns: "repeat(auto-fit, minmax(24ch, 1fr))"}}>
<Card
href="https://docs.astro.build/"
@@ -96,7 +90,7 @@ const Home: NextPage = () => {
title="Community"
body="Come say hi to our amazing Discord community. ❤️"
/>
</ul>
</ul>*/}
</main>
</>
);

View File

@@ -183,11 +183,6 @@
tiny-glob "^0.2.9"
tslib "^2.4.0"
"@react-icons/all-files@^4.1.0":
version "4.1.0"
resolved "https://registry.yarnpkg.com/@react-icons/all-files/-/all-files-4.1.0.tgz#477284873a0821928224b6fc84c62d2534d6650b"
integrity sha512-hxBI2UOuVaI3O/BhQfhtb4kcGn9ft12RWAFVMUeNjqqhLsHvFtzIkFaptBJpFDANTKoDfdVoHTKZDlwKCACbMQ==
"@rushstack/eslint-patch@^1.1.3":
version "1.2.0"
resolved "https://registry.yarnpkg.com/@rushstack/eslint-patch/-/eslint-patch-1.2.0.tgz#8be36a1f66f3265389e90b5f9c9962146758f728"
@@ -1266,11 +1261,6 @@ functions-have-names@^1.2.2:
resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834"
integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==
fuse.js@^6.6.2:
version "6.6.2"
resolved "https://registry.yarnpkg.com/fuse.js/-/fuse.js-6.6.2.tgz#fe463fed4b98c0226ac3da2856a415576dc9a111"
integrity sha512-cJaJkxCCxC8qIIcPBF9yGxY0W/tVZS3uEISDxhYIdtk8OL93pe+6Zj7LjCqVV4dzbqcriOZ+kQ/NE4RXZHsIGA==
get-intrinsic@^1.0.2, get-intrinsic@^1.1.1, get-intrinsic@^1.1.3, get-intrinsic@^1.2.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.0.tgz#7ad1dc0535f3a2904bba075772763e5051f6d05f"