From 9f3706ebffa4279e21861cb0e5d767e7e6e9ae18 Mon Sep 17 00:00:00 2001 From: Proksh Luthra <35415752+proksh@users.noreply.github.com> Date: Mon, 30 Sep 2024 22:07:01 +0530 Subject: [PATCH] finilised the page --- README.md | 4 +- package-lock.json | 657 +----------------- packages/website/package.json | 6 +- .../src/app/docs/[[...slug]]/layout.tsx | 16 - .../website/src/app/docs/[[...slug]]/page.tsx | 43 -- packages/website/src/app/page.tsx | 16 +- .../website/src/components/common/dialog.tsx | 2 +- .../website/src/components/common/tabs.tsx | 7 +- .../src/components/docs/Pagination.tsx | 29 - packages/website/src/components/docs/Toc.tsx | 20 - .../website/src/components/docs/anchor.tsx | 31 - packages/website/src/components/docs/copy.tsx | 24 - .../src/components/docs/docs-breadcrumb.tsx | 37 - .../website/src/components/docs/footer.tsx | 47 -- .../website/src/components/docs/leftbar.tsx | 80 --- packages/website/src/components/docs/pre.tsx | 15 - .../src/components/docs/toc-observer.tsx | 68 -- .../src/components/homepage/DownloadModal.tsx | 115 +++ .../src/components/homepage/IconComponent.tsx | 114 ++- .../docs/getting-started/introduction.mdx | 20 - .../src/contents/docs/installation/cdn.mdx | 39 -- .../src/contents/docs/installation/react.mdx | 57 -- packages/website/src/lib/markdown.tsx | 104 --- packages/website/src/lib/routes-config.ts | 25 - packages/website/tailwind.config.ts | 2 +- 25 files changed, 235 insertions(+), 1343 deletions(-) delete mode 100644 packages/website/src/app/docs/[[...slug]]/layout.tsx delete mode 100644 packages/website/src/app/docs/[[...slug]]/page.tsx delete mode 100644 packages/website/src/components/docs/Pagination.tsx delete mode 100644 packages/website/src/components/docs/Toc.tsx delete mode 100644 packages/website/src/components/docs/anchor.tsx delete mode 100644 packages/website/src/components/docs/copy.tsx delete mode 100644 packages/website/src/components/docs/docs-breadcrumb.tsx delete mode 100644 packages/website/src/components/docs/footer.tsx delete mode 100644 packages/website/src/components/docs/leftbar.tsx delete mode 100644 packages/website/src/components/docs/pre.tsx delete mode 100644 packages/website/src/components/docs/toc-observer.tsx create mode 100644 packages/website/src/components/homepage/DownloadModal.tsx delete mode 100644 packages/website/src/contents/docs/getting-started/introduction.mdx delete mode 100644 packages/website/src/contents/docs/installation/cdn.mdx delete mode 100644 packages/website/src/contents/docs/installation/react.mdx delete mode 100644 packages/website/src/lib/markdown.tsx delete mode 100644 packages/website/src/lib/routes-config.ts diff --git a/README.md b/README.md index 1382df05..08c71fb0 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,8 @@ -# Proxy Icons - React Components for Your Project +# Proxy Icons [![npm version](https://img.shields.io/npm/v/proxy-icons.svg?style=flat-square)](https://www.npmjs.com/package/proxy-icons) -This library provides a collection of React components for commonly used icons. Easily integrate these icons into your React applications to enhance user experience. +Easily integrate these icons into your application by using Font cdn or React components to enhance user experience. ## Installation with CDN diff --git a/package-lock.json b/package-lock.json index 9c7d4b32..3ab28933 100644 --- a/package-lock.json +++ b/package-lock.json @@ -6554,11 +6554,6 @@ "prettier": "*" } }, - "node_modules/@types/prismjs": { - "version": "1.26.4", - "resolved": "https://registry.npmjs.org/@types/prismjs/-/prismjs-1.26.4.tgz", - "integrity": "sha512-rlAnzkW2sZOjbqZ743IHUhFcvzaGbqijwOu8QZnZCjfQzBqFE3s4lOTJEsxikImav9uzz/42I+O7YUs1mWgMlg==" - }, "node_modules/@types/prop-types": { "version": "15.7.12", "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.12.tgz", @@ -12509,11 +12504,6 @@ "ini": "^1.3.2" } }, - "node_modules/github-slugger": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/github-slugger/-/github-slugger-2.0.0.tgz", - "integrity": "sha512-IaOQ9puYtjrkq7Y0Ygl9KDZnrf/aiUJYUpVf89y8kyaxbRG7Y1SrX/jaumrv81vc61+kiMempujsM3Yw7w5qcw==" - }, "node_modules/glob": { "version": "10.3.15", "resolved": "https://registry.npmjs.org/glob/-/glob-10.3.15.tgz", @@ -12886,125 +12876,6 @@ "node": ">= 0.4" } }, - "node_modules/hast": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/hast/-/hast-1.0.0.tgz", - "integrity": "sha512-vFUqlRV5C+xqP76Wwq2SrM0kipnmpxJm7OfvVXpB35Fp+Fn4MV+ozr+JZr5qFvyR1q/U+Foim2x+3P+x9S1PLA==", - "deprecated": "Renamed to rehype" - }, - "node_modules/hast-util-from-html": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/hast-util-from-html/-/hast-util-from-html-2.0.1.tgz", - "integrity": "sha512-RXQBLMl9kjKVNkJTIO6bZyb2n+cUH8LFaSSzo82jiLT6Tfc+Pt7VQCS+/h3YwG4jaNE2TA2sdJisGWR+aJrp0g==", - "dependencies": { - "@types/hast": "^3.0.0", - "devlop": "^1.1.0", - "hast-util-from-parse5": "^8.0.0", - "parse5": "^7.0.0", - "vfile": "^6.0.0", - "vfile-message": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-from-parse5": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/hast-util-from-parse5/-/hast-util-from-parse5-8.0.1.tgz", - "integrity": "sha512-Er/Iixbc7IEa7r/XLtuG52zoqn/b3Xng/w6aZQ0xGVxzhw5xUFxcRqdPzP6yFi/4HBYRaifaI5fQ1RH8n0ZeOQ==", - "dependencies": { - "@types/hast": "^3.0.0", - "@types/unist": "^3.0.0", - "devlop": "^1.0.0", - "hastscript": "^8.0.0", - "property-information": "^6.0.0", - "vfile": "^6.0.0", - "vfile-location": "^5.0.0", - "web-namespaces": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-from-parse5/node_modules/hast-util-parse-selector": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/hast-util-parse-selector/-/hast-util-parse-selector-4.0.0.tgz", - "integrity": "sha512-wkQCkSYoOGCRKERFWcxMVMOcYE2K1AaNLU8DXS9arxnLOUEWbOXKXiJUNzEpqZ3JOKpnha3jkFrumEjVliDe7A==", - "dependencies": { - "@types/hast": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-from-parse5/node_modules/hastscript": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/hastscript/-/hastscript-8.0.0.tgz", - "integrity": "sha512-dMOtzCEd3ABUeSIISmrETiKuyydk1w0pa+gE/uormcTpSYuaNJPbX1NU3JLyscSLjwAQM8bWMhhIlnCqnRvDTw==", - "dependencies": { - "@types/hast": "^3.0.0", - "comma-separated-tokens": "^2.0.0", - "hast-util-parse-selector": "^4.0.0", - "property-information": "^6.0.0", - "space-separated-tokens": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-heading-rank": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/hast-util-heading-rank/-/hast-util-heading-rank-3.0.0.tgz", - "integrity": "sha512-EJKb8oMUXVHcWZTDepnr+WNbfnXKFNf9duMesmr4S8SXTJBJ9M4Yok08pu9vxdJwdlGRhVumk9mEhkEvKGifwA==", - "dependencies": { - "@types/hast": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-is-element": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/hast-util-is-element/-/hast-util-is-element-3.0.0.tgz", - "integrity": "sha512-Val9mnv2IWpLbNPqc/pUem+a7Ipj2aHacCwgNfTiK0vJKl0LF+4Ba4+v1oPHFpf3bLYmreq0/l3Gud9S5OH42g==", - "dependencies": { - "@types/hast": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-parse-selector": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/hast-util-parse-selector/-/hast-util-parse-selector-3.1.1.tgz", - "integrity": "sha512-jdlwBjEexy1oGz0aJ2f4GKMaVKkA9jwjr4MjAAI22E5fM/TXVZHuS5OpONtdeIkRKqAaryQ2E9xNQxijoThSZA==", - "dependencies": { - "@types/hast": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-parse-selector/node_modules/@types/hast": { - "version": "2.3.10", - "resolved": "https://registry.npmjs.org/@types/hast/-/hast-2.3.10.tgz", - "integrity": "sha512-McWspRw8xx8J9HurkVBfYj0xKoE25tOFlHGdx4MJ5xORQrMGZNqJhVQWaIbm6Oyla5kYOXtDiopzKRJzEOkwJw==", - "dependencies": { - "@types/unist": "^2" - } - }, - "node_modules/hast-util-parse-selector/node_modules/@types/unist": { - "version": "2.0.11", - "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.11.tgz", - "integrity": "sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==" - }, "node_modules/hast-util-to-estree": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/hast-util-to-estree/-/hast-util-to-estree-3.1.0.tgz", @@ -13081,18 +12952,6 @@ "inline-style-parser": "0.2.3" } }, - "node_modules/hast-util-to-string": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/hast-util-to-string/-/hast-util-to-string-3.0.0.tgz", - "integrity": "sha512-OGkAxX1Ua3cbcW6EJ5pT/tslVb90uViVkcJ4ZZIMW/R33DX/AkcJcRrPebPwJkHYwlDHXz4aIwvAAaAdtrACFA==", - "dependencies": { - "@types/hast": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/hast-util-whitespace": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/hast-util-whitespace/-/hast-util-whitespace-3.0.0.tgz", @@ -13105,35 +12964,6 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/hastscript": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/hastscript/-/hastscript-7.2.0.tgz", - "integrity": "sha512-TtYPq24IldU8iKoJQqvZOuhi5CyCQRAbvDOX0x1eW6rsHSxa/1i2CCiptNTotGHJ3VoHRGmqiv6/D3q113ikkw==", - "dependencies": { - "@types/hast": "^2.0.0", - "comma-separated-tokens": "^2.0.0", - "hast-util-parse-selector": "^3.0.0", - "property-information": "^6.0.0", - "space-separated-tokens": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hastscript/node_modules/@types/hast": { - "version": "2.3.10", - "resolved": "https://registry.npmjs.org/@types/hast/-/hast-2.3.10.tgz", - "integrity": "sha512-McWspRw8xx8J9HurkVBfYj0xKoE25tOFlHGdx4MJ5xORQrMGZNqJhVQWaIbm6Oyla5kYOXtDiopzKRJzEOkwJw==", - "dependencies": { - "@types/unist": "^2" - } - }, - "node_modules/hastscript/node_modules/@types/unist": { - "version": "2.0.11", - "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.11.tgz", - "integrity": "sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==" - }, "node_modules/hosted-git-info": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", @@ -16849,15 +16679,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/markdown-table": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/markdown-table/-/markdown-table-3.0.3.tgz", - "integrity": "sha512-Z1NL3Tb1M9wH4XESsCDEksWoKTdlUafKc4pt0GRwjUyXaCFZ+dc3g2erqB6zm3szA2IUSi7VnPI+o/9jnxh9hw==", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, "node_modules/maxstache": { "version": "1.0.7", "resolved": "https://registry.npmjs.org/maxstache/-/maxstache-1.0.7.tgz", @@ -16891,45 +16712,6 @@ "through2": "~2.0.0" } }, - "node_modules/mdast-util-find-and-replace": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/mdast-util-find-and-replace/-/mdast-util-find-and-replace-3.0.1.tgz", - "integrity": "sha512-SG21kZHGC3XRTSUhtofZkBzZTJNM5ecCi0SK2IMKmSXR8vO3peL+kb1O0z7Zl83jKtutG4k5Wv/W7V3/YHvzPA==", - "dependencies": { - "@types/mdast": "^4.0.0", - "escape-string-regexp": "^5.0.0", - "unist-util-is": "^6.0.0", - "unist-util-visit-parents": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-find-and-replace/node_modules/escape-string-regexp": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz", - "integrity": "sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/mdast-util-find-and-replace/node_modules/unist-util-visit-parents": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-6.0.1.tgz", - "integrity": "sha512-L/PqWzfTP9lzzEa6CKs0k2nARxTdZduw3zyh8d2NVBnsyvHjSX4TWse388YrrQKbvI8w20fGjGlhgT96WwKykw==", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-is": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/mdast-util-from-markdown": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/mdast-util-from-markdown/-/mdast-util-from-markdown-2.0.1.tgz", @@ -16953,101 +16735,6 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/mdast-util-gfm": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm/-/mdast-util-gfm-3.0.0.tgz", - "integrity": "sha512-dgQEX5Amaq+DuUqf26jJqSK9qgixgd6rYDHAv4aTBuA92cTknZlKpPfa86Z/s8Dj8xsAQpFfBmPUHWJBWqS4Bw==", - "dependencies": { - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-gfm-autolink-literal": "^2.0.0", - "mdast-util-gfm-footnote": "^2.0.0", - "mdast-util-gfm-strikethrough": "^2.0.0", - "mdast-util-gfm-table": "^2.0.0", - "mdast-util-gfm-task-list-item": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-autolink-literal": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-autolink-literal/-/mdast-util-gfm-autolink-literal-2.0.0.tgz", - "integrity": "sha512-FyzMsduZZHSc3i0Px3PQcBT4WJY/X/RCtEJKuybiC6sjPqLv7h1yqAkmILZtuxMSsUyaLUWNp71+vQH2zqp5cg==", - "dependencies": { - "@types/mdast": "^4.0.0", - "ccount": "^2.0.0", - "devlop": "^1.0.0", - "mdast-util-find-and-replace": "^3.0.0", - "micromark-util-character": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-footnote": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-footnote/-/mdast-util-gfm-footnote-2.0.0.tgz", - "integrity": "sha512-5jOT2boTSVkMnQ7LTrd6n/18kqwjmuYqo7JUPe+tRCY6O7dAuTFMtTPauYYrMPpox9hlN0uOx/FL8XvEfG9/mQ==", - "dependencies": { - "@types/mdast": "^4.0.0", - "devlop": "^1.1.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0", - "micromark-util-normalize-identifier": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-strikethrough": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-strikethrough/-/mdast-util-gfm-strikethrough-2.0.0.tgz", - "integrity": "sha512-mKKb915TF+OC5ptj5bJ7WFRPdYtuHv0yTRxK2tJvi+BDqbkiG7h7u/9SI89nRAYcmap2xHQL9D+QG/6wSrTtXg==", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-table": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-table/-/mdast-util-gfm-table-2.0.0.tgz", - "integrity": "sha512-78UEvebzz/rJIxLvE7ZtDd/vIQ0RHv+3Mh5DR96p7cS7HsBhYIICDBCu8csTNWNO6tBWfqXPWekRuj2FNOGOZg==", - "dependencies": { - "@types/mdast": "^4.0.0", - "devlop": "^1.0.0", - "markdown-table": "^3.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-task-list-item": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-task-list-item/-/mdast-util-gfm-task-list-item-2.0.0.tgz", - "integrity": "sha512-IrtvNvjxC1o06taBAVJznEnkiHxLFTzgonUdy8hzFVeDun0uTjxxrRGVaNFqkU1wJR3RBPEfsxmU6jDWPofrTQ==", - "dependencies": { - "@types/mdast": "^4.0.0", - "devlop": "^1.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/mdast-util-mdx": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/mdast-util-mdx/-/mdast-util-mdx-3.0.0.tgz", @@ -17400,120 +17087,6 @@ "micromark-util-types": "^2.0.0" } }, - "node_modules/micromark-extension-gfm": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm/-/micromark-extension-gfm-3.0.0.tgz", - "integrity": "sha512-vsKArQsicm7t0z2GugkCKtZehqUm31oeGBV/KVSorWSy8ZlNAv7ytjFhvaryUiCUJYqs+NoE6AFhpQvBTM6Q4w==", - "dependencies": { - "micromark-extension-gfm-autolink-literal": "^2.0.0", - "micromark-extension-gfm-footnote": "^2.0.0", - "micromark-extension-gfm-strikethrough": "^2.0.0", - "micromark-extension-gfm-table": "^2.0.0", - "micromark-extension-gfm-tagfilter": "^2.0.0", - "micromark-extension-gfm-task-list-item": "^2.0.0", - "micromark-util-combine-extensions": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-autolink-literal": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-autolink-literal/-/micromark-extension-gfm-autolink-literal-2.1.0.tgz", - "integrity": "sha512-oOg7knzhicgQ3t4QCjCWgTmfNhvQbDDnJeVu9v81r7NltNCVmhPy1fJRX27pISafdjL+SVc4d3l48Gb6pbRypw==", - "dependencies": { - "micromark-util-character": "^2.0.0", - "micromark-util-sanitize-uri": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-footnote": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-footnote/-/micromark-extension-gfm-footnote-2.1.0.tgz", - "integrity": "sha512-/yPhxI1ntnDNsiHtzLKYnE3vf9JZ6cAisqVDauhp4CEHxlb4uoOTxOCJ+9s51bIB8U1N1FJ1RXOKTIlD5B/gqw==", - "dependencies": { - "devlop": "^1.0.0", - "micromark-core-commonmark": "^2.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-normalize-identifier": "^2.0.0", - "micromark-util-sanitize-uri": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-strikethrough": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-strikethrough/-/micromark-extension-gfm-strikethrough-2.1.0.tgz", - "integrity": "sha512-ADVjpOOkjz1hhkZLlBiYA9cR2Anf8F4HqZUO6e5eDcPQd0Txw5fxLzzxnEkSkfnD0wziSGiv7sYhk/ktvbf1uw==", - "dependencies": { - "devlop": "^1.0.0", - "micromark-util-chunked": "^2.0.0", - "micromark-util-classify-character": "^2.0.0", - "micromark-util-resolve-all": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-table": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-table/-/micromark-extension-gfm-table-2.1.0.tgz", - "integrity": "sha512-Ub2ncQv+fwD70/l4ou27b4YzfNaCJOvyX4HxXU15m7mpYY+rjuWzsLIPZHJL253Z643RpbcP1oeIJlQ/SKW67g==", - "dependencies": { - "devlop": "^1.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-tagfilter": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-tagfilter/-/micromark-extension-gfm-tagfilter-2.0.0.tgz", - "integrity": "sha512-xHlTOmuCSotIA8TW1mDIM6X2O1SiX5P9IuDtqGonFhEK0qgRI4yeC6vMxEV2dgyr2TiD+2PQ10o+cOhdVAcwfg==", - "dependencies": { - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-task-list-item": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-task-list-item/-/micromark-extension-gfm-task-list-item-2.1.0.tgz", - "integrity": "sha512-qIBZhqxqI6fjLDYFTBIa4eivDMnP+OZqsNwmQ3xNLE4Cxwc+zfQEfbs6tzAo2Hjq+bh6q5F+Z8/cksrLFYWQQw==", - "dependencies": { - "devlop": "^1.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/micromark-extension-mdx-expression": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/micromark-extension-mdx-expression/-/micromark-extension-mdx-expression-3.0.0.tgz", @@ -20397,11 +19970,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/parse-numeric-range": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/parse-numeric-range/-/parse-numeric-range-1.3.0.tgz", - "integrity": "sha512-twN+njEipszzlMJd4ONUYgSfZPDxgHhT9Ahed5uTigpQn90FggW4SA/AIPq/6a149fTbE9qBEcSwE3FAEp6wQQ==" - }, "node_modules/parse-path": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/parse-path/-/parse-path-7.0.0.tgz", @@ -21746,34 +21314,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/refractor": { - "version": "4.8.1", - "resolved": "https://registry.npmjs.org/refractor/-/refractor-4.8.1.tgz", - "integrity": "sha512-/fk5sI0iTgFYlmVGYVew90AoYnNMP6pooClx/XKqyeeCQXrL0Kvgn8V0VEht5ccdljbzzF1i3Q213gcntkRExg==", - "dependencies": { - "@types/hast": "^2.0.0", - "@types/prismjs": "^1.0.0", - "hastscript": "^7.0.0", - "parse-entities": "^4.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/refractor/node_modules/@types/hast": { - "version": "2.3.10", - "resolved": "https://registry.npmjs.org/@types/hast/-/hast-2.3.10.tgz", - "integrity": "sha512-McWspRw8xx8J9HurkVBfYj0xKoE25tOFlHGdx4MJ5xORQrMGZNqJhVQWaIbm6Oyla5kYOXtDiopzKRJzEOkwJw==", - "dependencies": { - "@types/unist": "^2" - } - }, - "node_modules/refractor/node_modules/@types/unist": { - "version": "2.0.11", - "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.11.tgz", - "integrity": "sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==" - }, "node_modules/regenerate": { "version": "1.4.2", "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.2.tgz", @@ -21887,127 +21427,6 @@ "jsesc": "bin/jsesc" } }, - "node_modules/rehype-autolink-headings": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/rehype-autolink-headings/-/rehype-autolink-headings-7.1.0.tgz", - "integrity": "sha512-rItO/pSdvnvsP4QRB1pmPiNHUskikqtPojZKJPPPAVx9Hj8i8TwMBhofrrAYRhYOOBZH9tgmG5lPqDLuIWPWmw==", - "dependencies": { - "@types/hast": "^3.0.0", - "@ungap/structured-clone": "^1.0.0", - "hast-util-heading-rank": "^3.0.0", - "hast-util-is-element": "^3.0.0", - "unified": "^11.0.0", - "unist-util-visit": "^5.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/rehype-code-titles": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/rehype-code-titles/-/rehype-code-titles-1.2.0.tgz", - "integrity": "sha512-bSr2YJ0GHbHFarUNDZ3VpcGi9HqjLNrA9Lj3nuyox2aGGLhN53dFP2WJtPRnnRqU/vpbCatIgOYxEvWP1YYKrw==", - "hasInstallScript": true, - "dependencies": { - "hast": "~1.0.0", - "unist-util-visit": "~4.1.2" - }, - "engines": { - "node": ">=16" - } - }, - "node_modules/rehype-code-titles/node_modules/@types/unist": { - "version": "2.0.11", - "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.11.tgz", - "integrity": "sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==" - }, - "node_modules/rehype-code-titles/node_modules/unist-util-is": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-5.2.1.tgz", - "integrity": "sha512-u9njyyfEh43npf1M+yGKDGVPbY/JWEemg5nH05ncKPfi+kBbKBJoTdsogMu33uhytuLlv9y0O7GH7fEdwLdLQw==", - "dependencies": { - "@types/unist": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/rehype-code-titles/node_modules/unist-util-visit": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-4.1.2.tgz", - "integrity": "sha512-MSd8OUGISqHdVvfY9TPhyK2VdUrPgxkUtWSuMHF6XAAFuL4LokseigBnZtPnJMu+FbynTkFNnFlyjxpVKujMRg==", - "dependencies": { - "@types/unist": "^2.0.0", - "unist-util-is": "^5.0.0", - "unist-util-visit-parents": "^5.1.1" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/rehype-parse": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/rehype-parse/-/rehype-parse-9.0.0.tgz", - "integrity": "sha512-WG7nfvmWWkCR++KEkZevZb/uw41E8TsH4DsY9UxsTbIXCVGbAs4S+r8FrQ+OtH5EEQAs+5UxKC42VinkmpA1Yw==", - "dependencies": { - "@types/hast": "^3.0.0", - "hast-util-from-html": "^2.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/rehype-prism-plus": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/rehype-prism-plus/-/rehype-prism-plus-2.0.0.tgz", - "integrity": "sha512-FeM/9V2N7EvDZVdR2dqhAzlw5YI49m9Tgn7ZrYJeYHIahM6gcXpH0K1y2gNnKanZCydOMluJvX2cB9z3lhY8XQ==", - "dependencies": { - "hast-util-to-string": "^3.0.0", - "parse-numeric-range": "^1.3.0", - "refractor": "^4.8.0", - "rehype-parse": "^9.0.0", - "unist-util-filter": "^5.0.0", - "unist-util-visit": "^5.0.0" - } - }, - "node_modules/rehype-slug": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/rehype-slug/-/rehype-slug-6.0.0.tgz", - "integrity": "sha512-lWyvf/jwu+oS5+hL5eClVd3hNdmwM1kAC0BUvEGD19pajQMIzcNUd/k9GsfQ+FfECvX+JE+e9/btsKH0EjJT6A==", - "dependencies": { - "@types/hast": "^3.0.0", - "github-slugger": "^2.0.0", - "hast-util-heading-rank": "^3.0.0", - "hast-util-to-string": "^3.0.0", - "unist-util-visit": "^5.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/remark-gfm": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/remark-gfm/-/remark-gfm-4.0.0.tgz", - "integrity": "sha512-U92vJgBPkbw4Zfu/IiW2oTZLSL3Zpv+uI7My2eq8JxKgqraFdU8YUGicEJCEgSbeaG+QDFqIcwwfMTOEelPxuA==", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-gfm": "^3.0.0", - "micromark-extension-gfm": "^3.0.0", - "remark-parse": "^11.0.0", - "remark-stringify": "^11.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/remark-mdx": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/remark-mdx/-/remark-mdx-3.0.1.tgz", @@ -22052,20 +21471,6 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/remark-stringify": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/remark-stringify/-/remark-stringify-11.0.0.tgz", - "integrity": "sha512-1OSmLd3awB/t8qdoEOMazZkNsfVTeY4fTsgzcQFdXNq8ToTN4ZGwrMnlda4K6smTFKD+GRV6O48i6Z4iKgPPpw==", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-to-markdown": "^2.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/remove-trailing-separator": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz", @@ -24678,6 +24083,15 @@ "node": ">=14.0.0" } }, + "node_modules/tailwindcss-animate": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/tailwindcss-animate/-/tailwindcss-animate-1.0.7.tgz", + "integrity": "sha512-bl6mpH3T7I3UFxuvDEXLxy/VuFxBk5bbzplh7tXI68mwMokNYd1t9qPBHlnyTwfa4JGC4zP516I1hYYtQ/vspA==", + "dev": true, + "peerDependencies": { + "tailwindcss": ">=3.0.0 || insiders" + } + }, "node_modules/tailwindcss/node_modules/arg": { "version": "5.0.2", "resolved": "https://registry.npmjs.org/arg/-/arg-5.0.2.tgz", @@ -26516,29 +25930,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/unist-util-filter": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/unist-util-filter/-/unist-util-filter-5.0.1.tgz", - "integrity": "sha512-pHx7D4Zt6+TsfwylH9+lYhBhzyhEnCXs/lbq/Hstxno5z4gVdyc2WEW0asfjGKPyG4pEKrnBv5hdkO6+aRnQJw==", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-is": "^6.0.0", - "unist-util-visit-parents": "^6.0.0" - } - }, - "node_modules/unist-util-filter/node_modules/unist-util-visit-parents": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-6.0.1.tgz", - "integrity": "sha512-L/PqWzfTP9lzzEa6CKs0k2nARxTdZduw3zyh8d2NVBnsyvHjSX4TWse388YrrQKbvI8w20fGjGlhgT96WwKykw==", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-is": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/unist-util-is": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-6.0.0.tgz", @@ -26964,19 +26355,6 @@ "url": "https://opencollective.com/unified" } }, - "node_modules/vfile-location": { - "version": "5.0.3", - "resolved": "https://registry.npmjs.org/vfile-location/-/vfile-location-5.0.3.tgz", - "integrity": "sha512-5yXvWDEgqeiYiBe1lbxYF7UMAIm/IcopxMHrMQDq3nvKcjPKIhZklUKL+AE7J7uApI4kwe2snsK+eI6UTj9EHg==", - "dependencies": { - "@types/unist": "^3.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/vfile-matter": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/vfile-matter/-/vfile-matter-5.0.0.tgz", @@ -27053,15 +26431,6 @@ "defaults": "^1.0.3" } }, - "node_modules/web-namespaces": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/web-namespaces/-/web-namespaces-2.0.1.tgz", - "integrity": "sha512-bKr1DkiNa2krS7qxNtdrtHAmzuYGFQLiQ13TsorsdT6ULTkPLKuu5+GsFpDlg6JFjUTwX2DyhMPG2be8uPrqsQ==", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, "node_modules/web-streams-polyfill": { "version": "3.3.3", "resolved": "https://registry.npmjs.org/web-streams-polyfill/-/web-streams-polyfill-3.3.3.tgz", @@ -27921,7 +27290,7 @@ }, "packages/react": { "name": "proxy-icons", - "version": "0.0.1", + "version": "0.0.2", "license": "MIT", "dependencies": { "react": "^18.2.0" @@ -27968,11 +27337,6 @@ "next-mdx-remote": "^5.0.0", "react": "^18", "react-dom": "^18", - "rehype-autolink-headings": "^7.1.0", - "rehype-code-titles": "^1.2.0", - "rehype-prism-plus": "^2.0.0", - "rehype-slug": "^6.0.0", - "remark-gfm": "^4.0.0", "tailwind-merge": "^2.3.0" }, "devDependencies": { @@ -27985,6 +27349,7 @@ "eslint-config-next": "14.2.3", "postcss": "^8", "tailwindcss": "^3.4.1", + "tailwindcss-animate": "^1.0.7", "typescript": "^5" } }, diff --git a/packages/website/package.json b/packages/website/package.json index c253a15c..900b5614 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -21,11 +21,6 @@ "next-mdx-remote": "^5.0.0", "react": "^18", "react-dom": "^18", - "rehype-autolink-headings": "^7.1.0", - "rehype-code-titles": "^1.2.0", - "rehype-prism-plus": "^2.0.0", - "rehype-slug": "^6.0.0", - "remark-gfm": "^4.0.0", "tailwind-merge": "^2.3.0" }, "devDependencies": { @@ -38,6 +33,7 @@ "eslint-config-next": "14.2.3", "postcss": "^8", "tailwindcss": "^3.4.1", + "tailwindcss-animate": "^1.0.7", "typescript": "^5" } } diff --git a/packages/website/src/app/docs/[[...slug]]/layout.tsx b/packages/website/src/app/docs/[[...slug]]/layout.tsx deleted file mode 100644 index ce35b1e3..00000000 --- a/packages/website/src/app/docs/[[...slug]]/layout.tsx +++ /dev/null @@ -1,16 +0,0 @@ -import Header from '@/components/common/header'; -import { Leftbar } from '@/components/docs/leftbar'; - -export default function DocsLayout({ - children, -}: Readonly<{ - children: React.ReactNode; -}>) { - return ( -
-
- -
{children}
{' '} -
- ); -} diff --git a/packages/website/src/app/docs/[[...slug]]/page.tsx b/packages/website/src/app/docs/[[...slug]]/page.tsx deleted file mode 100644 index 6eeb5b0d..00000000 --- a/packages/website/src/app/docs/[[...slug]]/page.tsx +++ /dev/null @@ -1,43 +0,0 @@ -import React, { PropsWithChildren, cache } from 'react'; -// import Pagination from '@/components/pagination'; -import { getMarkdownForSlug } from '@/lib/markdown'; -import { notFound } from 'next/navigation'; -import DocsBreadcrumb from '@/components/docs/docs-breadcrumb'; -import Header from '@/components/common/header'; -import Toc from '@/components/docs/Toc'; - -type PageProps = { - params: { slug: string[] }; -}; - -const cachedGetMarkdownForSlug = cache(getMarkdownForSlug); - -export default async function page({ params: { slug = [] } }: PageProps) { - const pathName = slug.join('/'); - const res = await cachedGetMarkdownForSlug(pathName); - - if (!res) notFound(); - - return ( -
-
- - -

{res.frontmatter.title}

-

{res.frontmatter.description}

-
{res.content}
- {/* */} -
-
- -
- ); -} - -function Markdown({ children }: PropsWithChildren) { - return ( -
- {children} -
- ); -} diff --git a/packages/website/src/app/page.tsx b/packages/website/src/app/page.tsx index f8025cb8..804c91d9 100644 --- a/packages/website/src/app/page.tsx +++ b/packages/website/src/app/page.tsx @@ -4,6 +4,7 @@ import SearchInput from '@/components/homepage/SearchInput'; import { filtedFlattenIcons } from '@/components/common/helperFunctions'; import { IconArrayItemType } from '@/components/common/types'; import Header from '@/components/common/header'; +import DownloadModal from '@/components/homepage/DownloadModal'; export default function Home({ searchParams }: { searchParams: { search?: string } }) { if (!icons) { @@ -23,15 +24,12 @@ export default function Home({ searchParams }: { searchParams: { search?: string
- - - Download - + + +
{Object.keys(responseIcons).map((category) => { diff --git a/packages/website/src/components/common/dialog.tsx b/packages/website/src/components/common/dialog.tsx index 6fe3b4c2..a1d83c43 100644 --- a/packages/website/src/components/common/dialog.tsx +++ b/packages/website/src/components/common/dialog.tsx @@ -36,7 +36,7 @@ const DialogContent = React.forwardRef< (({ className, ...props }, ref) => ( )); @@ -29,7 +26,7 @@ const TabsTrigger = React.forwardRef< -
- {res.prev && ( - - {/* */} -

{res.prev.title}

- - )} -
-
- {res.next && ( - -

{res.next.title}

- {/* */} - - )} -
-
- ); -} diff --git a/packages/website/src/components/docs/Toc.tsx b/packages/website/src/components/docs/Toc.tsx deleted file mode 100644 index 4c08e029..00000000 --- a/packages/website/src/components/docs/Toc.tsx +++ /dev/null @@ -1,20 +0,0 @@ -import { getTocs } from '@/lib/markdown'; -import TocObserver from './toc-observer'; -import { ScrollArea } from '@/components/common/scroll-area'; - -export default async function Toc({ path }: { path: string }) { - const tocs = await getTocs(path); - - return ( -
-
- -
-

On this page

- -
-
-
-
- ); -} diff --git a/packages/website/src/components/docs/anchor.tsx b/packages/website/src/components/docs/anchor.tsx deleted file mode 100644 index 69bcf9b2..00000000 --- a/packages/website/src/components/docs/anchor.tsx +++ /dev/null @@ -1,31 +0,0 @@ -'use client'; - -import { cn } from '@/lib/utils'; -import Link from 'next/link'; -import { usePathname } from 'next/navigation'; -import { ComponentProps } from 'react'; - -type AnchorProps = ComponentProps & { - absolute?: boolean; - activeClassName?: string; - disabled?: boolean; -}; - -export default function Anchor({ - absolute, - className = '', - activeClassName = '', - disabled, - children, - ...props -}: AnchorProps) { - const path = usePathname(); - const isMatch = absolute ? props.href.toString().split('/')[1] == path.split('/')[1] : path === props.href; - - if (disabled) return
{children}
; - return ( - - {children} - - ); -} diff --git a/packages/website/src/components/docs/copy.tsx b/packages/website/src/components/docs/copy.tsx deleted file mode 100644 index eb7c278e..00000000 --- a/packages/website/src/components/docs/copy.tsx +++ /dev/null @@ -1,24 +0,0 @@ -'use client'; - -// import { CheckIcon, CopyIcon } from 'lucide-react'; -import { Button } from '@/components/common/button'; -import { useState } from 'react'; - -export default function Copy({ content }: { content: string }) { - const [isCopied, setIsCopied] = useState(false); - - async function handleCopy() { - await navigator.clipboard.writeText(content); - setIsCopied(true); - - setTimeout(() => { - setIsCopied(false); - }, 2000); - } - - return ( - - ); -} diff --git a/packages/website/src/components/docs/docs-breadcrumb.tsx b/packages/website/src/components/docs/docs-breadcrumb.tsx deleted file mode 100644 index 0774de95..00000000 --- a/packages/website/src/components/docs/docs-breadcrumb.tsx +++ /dev/null @@ -1,37 +0,0 @@ -import { - Breadcrumb, - BreadcrumbItem, - BreadcrumbLink, - BreadcrumbList, - BreadcrumbPage, - BreadcrumbSeparator, -} from '@/components/common/breadcrumb'; -import { Fragment } from 'react'; - -export default function DocsBreadcrumb({ paths }: { paths: string[] }) { - return ( -
- - - - Docs - - {paths.map((path) => ( - - - - {toTitleCase(path)} - - - ))} - - -
- ); -} - -function toTitleCase(input: string): string { - const words = input.split('-'); - const capitalizedWords = words.map((word) => word.charAt(0).toUpperCase() + word.slice(1)); - return capitalizedWords.join(' '); -} diff --git a/packages/website/src/components/docs/footer.tsx b/packages/website/src/components/docs/footer.tsx deleted file mode 100644 index 76b21ffb..00000000 --- a/packages/website/src/components/docs/footer.tsx +++ /dev/null @@ -1,47 +0,0 @@ -import Link from 'next/link'; -// import { buttonVariants } from './ui/button'; -// import { HeartIcon, TriangleIcon } from 'lucide-react'; - -export function Footer() { - return ( -
-
-

- Build by{' '} - - nisabmohd - - . The source code is available on{' '} - - GitHub - - . -

-
- -
-
-
- ); -} - -export function FooterButtons() { - return ( - <> - - {/* */} - Deploy - - - {/* */} - Sponsor - - - ); -} diff --git a/packages/website/src/components/docs/leftbar.tsx b/packages/website/src/components/docs/leftbar.tsx deleted file mode 100644 index 406662ff..00000000 --- a/packages/website/src/components/docs/leftbar.tsx +++ /dev/null @@ -1,80 +0,0 @@ -import { ROUTES } from '@/lib/routes-config'; -import Anchor from './anchor'; -import { ScrollArea } from '@/components/common/scroll-area'; -import { Sheet, SheetClose, SheetContent, SheetHeader, SheetTrigger } from '@/components/common/sheet'; -import { FooterButtons } from './footer'; -import { Button } from '../common/button'; - -export function Leftbar() { - return ( - - ); -} - -export function SheetLeftbar() { - return ( - - - - - - - - {/* */} - - - -
{/* */}
-
- -
-
- -
-
-
-
- ); -} - -function Menu({ isSheet = false }) { - return ( -
- {ROUTES.map(({ href, items, title }) => { - return ( -
-

{title}

-
- {items.map((subItem) => { - const key = `/docs/${href}${subItem.href}`; - const Comp = ( - - {subItem.title} - - ); - return isSheet ? ( - - {Comp} - - ) : ( - Comp - ); - })} -
-
- ); - })} -
- ); -} diff --git a/packages/website/src/components/docs/pre.tsx b/packages/website/src/components/docs/pre.tsx deleted file mode 100644 index 3c0faeeb..00000000 --- a/packages/website/src/components/docs/pre.tsx +++ /dev/null @@ -1,15 +0,0 @@ -import { ComponentProps } from 'react'; -import Copy from './copy'; - -export default function Pre({ children, raw, ...rest }: ComponentProps<'pre'> & { raw?: string }) { - return ( -
-
- -
-
-
{children}
-
-
- ); -} diff --git a/packages/website/src/components/docs/toc-observer.tsx b/packages/website/src/components/docs/toc-observer.tsx deleted file mode 100644 index 5e8def82..00000000 --- a/packages/website/src/components/docs/toc-observer.tsx +++ /dev/null @@ -1,68 +0,0 @@ -'use client'; - -import { getTocs } from '@/lib/markdown'; -import clsx from 'clsx'; -import Link from 'next/link'; -import { useState, useRef, useEffect } from 'react'; - -type Props = { data: Awaited> }; - -export default function TocObserver({ data }: Props) { - const [activeId, setActiveId] = useState(null); - const observer = useRef(null); - - useEffect(() => { - const handleIntersect = (entries: IntersectionObserverEntry[]) => { - const visibleEntry = entries.find((entry) => entry.isIntersecting); - if (visibleEntry) { - setActiveId(visibleEntry.target.id); - } - }; - - observer.current = new IntersectionObserver(handleIntersect, { - root: null, - rootMargin: '-20px 0px 0px 0px', - threshold: 0.1, - }); - - const elements = data.map((item) => document.getElementById(item.href.slice(1))); - - elements.forEach((el) => { - if (el && observer.current) { - observer.current.observe(el); - } - }); - - return () => { - if (observer.current) { - elements.forEach((el) => { - if (el) { - observer.current!.unobserve(el); - } - }); - } - }; - }, [data]); - - return ( -
- {data.map(({ href, level, text }) => { - return ( - - {text} - - ); - })} -
- ); -} diff --git a/packages/website/src/components/homepage/DownloadModal.tsx b/packages/website/src/components/homepage/DownloadModal.tsx new file mode 100644 index 00000000..daafc122 --- /dev/null +++ b/packages/website/src/components/homepage/DownloadModal.tsx @@ -0,0 +1,115 @@ +'use client'; + +import React, { ReactNode, useState } from 'react'; +import { Dialog, DialogContent, DialogTitle, DialogTrigger } from '@/components/common/dialog'; +import icons from '../../../icons-json.json'; + +export default function DownloadModal({ children }: { children: ReactNode }) { + const totalIcons = Object.values(icons).reduce((agg: number, val: any) => { + return Object.keys(val).length + agg; + }, 0); + + return ( + + {children} + + Download Icons +
+
+ +
+
+

Icon pack

+

Contains all {totalIcons} .svgs icons

+
+ + + +
+
+
+
+ +
+
+

Icon fonts

+

+ Contain .css / .less / .eot / .ttf / .woff / .woff2 / svg-sprite files +

+
+ + + +
+
+
+
+ +
+
+

Npm Package

+

npm install proxyicons --save

+
+ +
+ {/*
+
+
+ +
+
+

Figma File

+

Contains all the icons in Figma file

+
+ + + +
*/} + +
+ ); +} + +const CopyIconButton = ({ copyText }: { copyText: string }) => { + const [copied, setCopied] = useState(false); + + const handleCopyClick = async () => { + try { + await navigator.clipboard.writeText(copyText); + setCopied(true); + setTimeout(() => setCopied(false), 2000); + } catch (err) { + console.error('Failed to copy text: ', err); + } + }; + + if (copied) { + return ( + + ); + } + + return ( + + ); +}; diff --git a/packages/website/src/components/homepage/IconComponent.tsx b/packages/website/src/components/homepage/IconComponent.tsx index f3d8888f..eeeadae1 100644 --- a/packages/website/src/components/homepage/IconComponent.tsx +++ b/packages/website/src/components/homepage/IconComponent.tsx @@ -6,6 +6,7 @@ import { saveAs } from 'file-saver'; import { IconArrayItemType } from '../common/types'; import { useState } from 'react'; import { cn } from '../common/utils'; +import { Tabs, TabsList, TabsContent, TabsTrigger } from '../common/tabs'; export default function IconComponent({ icon, className }: { icon: IconArrayItemType; className?: string }) { const handleSvgDownload = () => { @@ -46,17 +47,20 @@ export default function IconComponent({ icon, className }: { icon: IconArrayItem - -
+ +
- pro-{icon.iconName} + +

pro-{icon.iconName}

+ +
- +
-
-          {``}
-        
-
-          {``}
-        
-
-          {``}
-        
-
-          {icon.svgContent}
-        
+ + + Font + SVG + React + + +
+
+
+                  {``}
+                
+
+ `} /> +
+
+
+
+                  {``}
+                
+
+ `} /> +
+
+
+ + +
+
+
+                  {icon.svgContent}
+                
+
+ +
+
+
+
+ +
+
+
+                  {``}
+                
+
+ `} + /> +
+
+
+
+ ); } -const CopyButton = ({ copyText }: { copyText: string }) => { +const CopyButton = ({ text, successText, copyText }: { text?: string; successText?: string; copyText: string }) => { const [copied, setCopied] = useState(false); const handleCopyClick = async () => { @@ -108,7 +153,7 @@ const CopyButton = ({ copyText }: { copyText: string }) => { return ( ); } @@ -118,7 +163,38 @@ const CopyButton = ({ copyText }: { copyText: string }) => { onClick={handleCopyClick} className="text-md flex items-center font-medium bg-orange-500 hover:bg-orange-500/80 transition-all gap-1 px-3 py-2 rounded-xl text-white" > - Copy SVG + {text ? text : } + + ); +}; + +const CopyIconButton = ({ copyText }: { copyText: string }) => { + const [copied, setCopied] = useState(false); + + const handleCopyClick = async () => { + try { + await navigator.clipboard.writeText(copyText); + setCopied(true); + setTimeout(() => setCopied(false), 2000); + } catch (err) { + console.error('Failed to copy text: ', err); + } + }; + + if (copied) { + return ( + + ); + } + + return ( + ); }; diff --git a/packages/website/src/contents/docs/getting-started/introduction.mdx b/packages/website/src/contents/docs/getting-started/introduction.mdx deleted file mode 100644 index f9d1a21b..00000000 --- a/packages/website/src/contents/docs/getting-started/introduction.mdx +++ /dev/null @@ -1,20 +0,0 @@ ---- -title: Introduction -description: Proxy Icon offers a sleek, open-source collection of 2500+ minimalist icons, ideal for both designers and developers. Unlike many icon libraries that can feel disjointed, Proxy Icon provides a cohesive set, with each icon meticulously crafted for clarity and visual consistency. Available in both 'Outlined' and 'Filled' styles, these icons are designed on a 24x24 grid to ensure pixel-perfect precision. Best of all, Proxy Icon is completely free to use in both personal and commercial projects. ---- - - - - - - - - diff --git a/packages/website/src/contents/docs/installation/cdn.mdx b/packages/website/src/contents/docs/installation/cdn.mdx deleted file mode 100644 index 2ce9f4ed..00000000 --- a/packages/website/src/contents/docs/installation/cdn.mdx +++ /dev/null @@ -1,39 +0,0 @@ ---- -title: CDN Installation -description: Installation guide using a CDN link for Proxy Icons. ---- - -## Installation Steps - -1. **Add CDN Link**: To integrate Proxy Icons into your project, copy the following CDN link and paste it within the `` tag of your HTML document: - - ```html - - ``` - - Alternatively, you can download the proxy-icons.css file and include it in the `` tag of your HTML document. - -2. **Use Icons**: To use an icon, add an `` tag with the appropriate class name. The class name follows the convention: `pro-{name}-{style}`. - - ```html - - ``` - - Note: Replace `{name}` with the icon name and `{style}` with the desired style (e.g., line for outlined icons or fill for filled icons). - -3. **Sizing**: You can resize Proxy Icons using inline styles or predefined classes. For example: - - ```html - - ``` - - If you're using a CSS framework like Tailwind CSS or Bootstrap, you can apply their text sizing classes directly: - - ```html - - - - ``` diff --git a/packages/website/src/contents/docs/installation/react.mdx b/packages/website/src/contents/docs/installation/react.mdx deleted file mode 100644 index 96f10e6b..00000000 --- a/packages/website/src/contents/docs/installation/react.mdx +++ /dev/null @@ -1,57 +0,0 @@ ---- -title: React Installation -description: Installation guide for using Proxy Icons as React components. ---- - -## Installation Steps - -1. **Install the Package**: Add the Proxy Icons package to your React project using npm, yarn, or pnpm. - - ```bash - npm install proxy-icons - # or - yarn add proxy-icons - # or - pnpm install proxy-icons - ``` - -2. **Usage**: Import the desired icon and use it within your React components. - - ```jsx - import { ProUserFill } from 'proxy-icons'; - - const MyComponent = () => { - return ( - - ); - }; - ``` - - Note: Replace ProUserFill with any icon component from the proxy-icons package that suits your needs. - -3. **Sizing**: Apply styles or classes to adjust the size of your icons. - - ```jsx - import { ProUserFill } from 'proxy-icons'; - - const MyComponent = () => { - return ( - - ); - }; - ``` - -Note: The example shows using Tailwind CSS for sizing with text-xs, but you can customize this based on your CSS framework or design system. - -## Additional Notes - -- **Icon Import:** Only import the icons you need to keep your bundle size small. -- **Custom Styles:** You can further customize the icons using additional CSS classes or inline styles as required. -- **Responsive Sizing:** Consider using responsive classes or media queries to adjust icon sizes based on screen size. - -This refined version enhances clarity, offers more detailed instructions, and includes additional notes to help with efficient usage in React projects. Let me know if you need further adjustments! diff --git a/packages/website/src/lib/markdown.tsx b/packages/website/src/lib/markdown.tsx deleted file mode 100644 index 062aca3e..00000000 --- a/packages/website/src/lib/markdown.tsx +++ /dev/null @@ -1,104 +0,0 @@ -import { compileMDX } from 'next-mdx-remote/rsc'; -import path from 'path'; -import { promises as fs } from 'fs'; -import remarkGfm from 'remark-gfm'; -import rehypePrism from 'rehype-prism-plus'; -import rehypeAutolinkHeadings from 'rehype-autolink-headings'; -import rehypeSlug from 'rehype-slug'; -import rehypeCodeTitles from 'rehype-code-titles'; -import { page_routes } from './routes-config'; -import { visit } from 'unist-util-visit'; - -import { Tabs, TabsContent, TabsList, TabsTrigger } from '@/components/common/tabs'; -import Pre from '@/components/docs/pre'; - -type MdxFrontmatter = { - title: string; - description: string; -}; - -// add custom components -const components = { - Tabs, - TabsContent, - TabsList, - TabsTrigger, - pre: Pre, -}; - -export async function getMarkdownForSlug(slug: string) { - try { - const contentPath = getContentPath(slug); - const rawMdx = await fs.readFile(contentPath, 'utf-8'); - return await compileMDX({ - source: rawMdx, - options: { - parseFrontmatter: true, - mdxOptions: { - rehypePlugins: [preProcess, rehypeCodeTitles, rehypePrism, rehypeSlug, rehypeAutolinkHeadings, postProcess], - remarkPlugins: [remarkGfm], - }, - }, - components, - }); - } catch (err) { - console.log(err); - } -} - -export async function getTocs(slug: string) { - const contentPath = getContentPath(slug); - const rawMdx = await fs.readFile(contentPath, 'utf-8'); - // captures between ## - #### can modify accordingly - const headingsRegex = /^(#{2,4})\s(.+)$/gm; - let match; - const extractedHeadings = []; - while ((match = headingsRegex.exec(rawMdx)) !== null) { - const headingLevel = match[1].length; - const headingText = match[2].trim(); - const slug = sluggify(headingText); - extractedHeadings.push({ - level: headingLevel, - text: headingText, - href: `#${slug}`, - }); - } - return extractedHeadings; -} - -export function getPreviousNext(path: string) { - const index = page_routes.findIndex(({ href }: { href: string }) => href == path); - return { - prev: page_routes[index - 1], - next: page_routes[index + 1], - }; -} - -function sluggify(text: string) { - const slug = text.toLowerCase().replace(/\s+/g, '-'); - return slug.replace(/[^a-z0-9-]/g, ''); -} - -function getContentPath(slug: string) { - return path.join(process.cwd(), '/src/contents/docs/', `${slug}.mdx`); -} - -// for copying the code -const preProcess = () => (tree: any) => { - visit(tree, (node: any) => { - if (node?.type === 'element' && node?.tagName === 'pre') { - const [codeEl] = node.children; - if (codeEl.tagName !== 'code') return; - node.raw = codeEl.children?.[0].value; - } - }); -}; - -const postProcess = () => (tree: any) => { - visit(tree, 'element', (node: any) => { - if (node?.type === 'element' && node?.tagName === 'pre') { - node.properties['raw'] = node.raw; - // console.log(node); - } - }); -}; diff --git a/packages/website/src/lib/routes-config.ts b/packages/website/src/lib/routes-config.ts deleted file mode 100644 index 55bbdea3..00000000 --- a/packages/website/src/lib/routes-config.ts +++ /dev/null @@ -1,25 +0,0 @@ -// for page navigation & to sort on leftbar -export const ROUTES = [ - { - title: 'Getting Started', - href: 'getting-started', - items: [{ title: 'Introduction', href: '/introduction' }], - }, - { - title: 'Installation', - href: 'installation', - items: [ - { title: 'CDN', href: '/cdn' }, - { title: 'React', href: '/react' }, - ], - }, -]; - -export const page_routes = ROUTES.map(({ href, items }) => { - return items.map((link) => { - return { - title: link.title, - href: href + link.href, - }; - }); -}).flat(); diff --git a/packages/website/tailwind.config.ts b/packages/website/tailwind.config.ts index 7239cdc8..748926a3 100644 --- a/packages/website/tailwind.config.ts +++ b/packages/website/tailwind.config.ts @@ -18,6 +18,6 @@ const config: Config = { }, }, }, - plugins: [], + plugins: [require('tailwindcss-animate')], }; export default config;