From f858b8aa6879d13d20baf9de9b2dd2d66c505ebb Mon Sep 17 00:00:00 2001 From: Ajay-Dhangar Date: Tue, 17 Sep 2024 13:06:49 +0530 Subject: [PATCH 1/4] add update code --- docusaurus.config.js | 15 +++++++++++---- src/css/custom.css | 30 ++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+), 4 deletions(-) diff --git a/docusaurus.config.js b/docusaurus.config.js index ad5551b11..8f1818459 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -256,12 +256,19 @@ const config = { type: "search", position: "right", }, + // { + // href: "https://github.com/codeharborhub/codeharborhub", + // position: "right", + // className: "header-github-link", + // "aria-label": "GitHub repository", + // }, { - href: "https://github.com/codeharborhub/codeharborhub", + href: "https://www.codeharborhub.live/register", position: "right", - className: "header-github-link", - "aria-label": "GitHub repository", - }, + className: "header-signup-link", + "aria-label": "Auth", + label: "Auth", + }, ], // hideOnScroll: true, }, diff --git a/src/css/custom.css b/src/css/custom.css index 5dd1185cb..af6779aaa 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -407,3 +407,33 @@ td, th { background: rgba(15, 23, 42, 0.862); border-bottom: 1px solid #4e8da0db; } + +.header-signup-link { + background: linear-gradient( + 90deg, + rgb(252 176 69 / 100%) 0%, + rgb(253 29 29 / 100%) 50%, + rgb(131 58 180 / 100%) 100% + ); + background-clip: text; + -webkit-text-fill-color: transparent; + padding: 1px 4px; + text-decoration: none; + margin: 0 5px; + font-weight: 700; + font-size: 1.2em; + border-radius: 5px; + transition: all 0.3s ease; + border: 1px solid transparent; +} + +.header-signup-link:hover { + background: linear-gradient( + 90deg, + rgb(252 176 69 / 100%) 0%, + rgb(253 29 29 / 100%) 50%, + rgb(131 58 180 / 100%) 100% + ); + background-clip: text; + -webkit-text-fill-color: transparent; +} \ No newline at end of file From 06aa4276a73aac49cde3ab945cc4378d11f18a0d Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Tue, 17 Sep 2024 07:47:20 +0000 Subject: [PATCH 2/4] Restyled by clang-format --- docusaurus.config.js | 886 ++++++++++++++++++++++--------------------- 1 file changed, 445 insertions(+), 441 deletions(-) diff --git a/docusaurus.config.js b/docusaurus.config.js index df749359e..d3d10e7bf 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -1,5 +1,5 @@ -import { default as npm2yarn } from "@docusaurus/remark-plugin-npm2yarn"; -import { themes as prismThemes } from "prism-react-renderer"; +import {default as npm2yarn} from "@docusaurus/remark-plugin-npm2yarn"; +import {themes as prismThemes} from "prism-react-renderer"; const remarkMath = require("remark-math"); const rehypeKatex = require("rehype-katex"); @@ -9,135 +9,135 @@ require("dotenv").config(); /** @type {import('@docusaurus/types').Config} */ const config = { - title: "CodeHarborHub", - tagline: "A place to learn and grow", - favicon: "img/favicon_io/favicon.ico", - url: process.env.URL || "https://codeharborhub.github.io/", - baseUrl: "/", - customFields: { - admin: "Ajay Dhangar", - superman: "Shivay", - serviceId: process.env.EMAILJS_SERVICE_ID, - templateId: process.env.EMAILJS_TEMPLATE_ID, - userId: process.env.EMAILJS_USER_ID, - emailService: process.env.EMAIL_SERVICE, + title : "CodeHarborHub", + tagline : "A place to learn and grow", + favicon : "img/favicon_io/favicon.ico", + url : process.env.URL || "https://codeharborhub.github.io/", + baseUrl : "/", + customFields : { + admin : "Ajay Dhangar", + superman : "Shivay", + serviceId : process.env.EMAILJS_SERVICE_ID, + templateId : process.env.EMAILJS_TEMPLATE_ID, + userId : process.env.EMAILJS_USER_ID, + emailService : process.env.EMAIL_SERVICE, }, - organizationName: "codeharborhub", - projectName: "codeharborhub.github.io", + organizationName : "codeharborhub", + projectName : "codeharborhub.github.io", - onBrokenLinks: "throw", - onBrokenMarkdownLinks: "warn", + onBrokenLinks : "throw", + onBrokenMarkdownLinks : "warn", - presets: [ + presets : [ [ "@docusaurus/preset-classic", /** @type {import('@docusaurus/preset-classic').Options} */ ({ - debug: true, - docs: { - path: "docs", - sidebarPath: "sidebars.js", - numberPrefixParser: false, - showLastUpdateAuthor: true, - showLastUpdateTime: true, - admonitions: { - keywords: ["my-custom-admonition"], - extendDefaults: true, + debug : true, + docs : { + path : "docs", + sidebarPath : "sidebars.js", + numberPrefixParser : false, + showLastUpdateAuthor : true, + showLastUpdateTime : true, + admonitions : { + keywords : [ "my-custom-admonition" ], + extendDefaults : true, }, - editUrl: - "https://github.com/codeharborhub/codeharborhub.github.io/edit/main/", - remarkPlugins: [remarkMath], - rehypePlugins: [rehypeKatex], + editUrl : + "https://github.com/codeharborhub/codeharborhub.github.io/edit/main/", + remarkPlugins : [ remarkMath ], + rehypePlugins : [ rehypeKatex ], }, - pages: { - remarkPlugins: [npm2yarn], + pages : { + remarkPlugins : [ npm2yarn ], }, - blog: { - showReadingTime: true, - editUrl: - "https://github.com/codeharborhub/codeharborhub.github.io/edit/main/", - remarkPlugins: [[npm2yarn, { converters: ["pnpm"] }]], + blog : { + showReadingTime : true, + editUrl : + "https://github.com/codeharborhub/codeharborhub.github.io/edit/main/", + remarkPlugins : [ [ npm2yarn, {converters : [ "pnpm" ]} ] ], }, - theme: { - customCss: "./src/css/custom.css", + theme : { + customCss : "./src/css/custom.css", }, }), ], ], - stylesheets: [ + stylesheets : [ { - href: "https://cdn.jsdelivr.net/npm/katex@0.13.24/dist/katex.min.css", - type: "text/css", - integrity: - "sha384-odtC+0UGzzFL/6PNoE8rX/SPcQDXBJ+uRepguP4QkPCm2LBxH3FA3y+fKSiJ+AmM", - crossorigin: "anonymous", + href : "https://cdn.jsdelivr.net/npm/katex@0.13.24/dist/katex.min.css", + type : "text/css", + integrity : + "sha384-odtC+0UGzzFL/6PNoE8rX/SPcQDXBJ+uRepguP4QkPCm2LBxH3FA3y+fKSiJ+AmM", + crossorigin : "anonymous", }, ], - themeConfig: - /** @type {import('@docusaurus/preset-classic').ThemeConfig} */ - ({ - image: "img/codeharborhub-social-card.jpg", - announcementBar: { - id: "announcementBar", - content: - '🐐 Check out our latest project Goat Farming! Learn more about sustainable farming practices. 🌱', - isCloseable: true, - backgroundColor: "#4d5061", - }, - - metadata: [ - { - name: "keywords", - content: - "CodeHarborHub, Docs, Tutorials, Courses, DSA, Problems, Solutions, Showcase, Community, Blog, Web Dev, Live Editor, Quiz, Tags, Donate, Careers, Team, GitHub, Products, LinkedIn, YouTube, Discord, Twitter, Privacy Policy, Terms of Service, Code of Conduct, Cookie Policy, Licensing, Web Development, React, JavaScript, Python, Java, Tailwind CSS, CPP, NextJs, MATLAB, Julia, HTML, CSS, TypeScript, DSA, Data Structures, Algorithms, Competitive Programming", - }, - { name: "twitter:card", content: "summary_large_image" }, - { name: "twitter:site", content: "@CodesWithAjay" }, - { name: "twitter:creator", content: "@CodesWithAjay" }, - { property: "og:type", content: "website" }, - { property: "og:site_name", content: "CodeHarborHub" }, - { - property: "og:title", - content: "CodeHarborHub - A place to learn and grow", - }, - { - property: "og:description", - content: - "CodeHarborHub is a place to learn and grow. We provide accessible and comprehensive educational resources to learners of all levels, from beginners to advanced professionals.", - }, - { - property: "og:image", - content: - "https://codeharborhub.github.io/img/codeharborhub-social-card.jpg", + themeConfig : + /** @type {import('@docusaurus/preset-classic').ThemeConfig} */ + ({ + image : "img/codeharborhub-social-card.jpg", + announcementBar : { + id : "announcementBar", + content : + '🐐 Check out our latest project Goat Farming! Learn more about sustainable farming practices. 🌱', + isCloseable : true, + backgroundColor : "#4d5061", }, - { property: "og:url", content: "https://codeharborhub.github.io" }, - ], - algolia: { - apiKey: "9a235effc3fe5f0b7b18245f309910c5", - indexName: "codeharborhubio", - appId: "ZF3MPCPQHR", - contextualSearch: false, - }, + metadata : [ + { + name : "keywords", + content : + "CodeHarborHub, Docs, Tutorials, Courses, DSA, Problems, Solutions, Showcase, Community, Blog, Web Dev, Live Editor, Quiz, Tags, Donate, Careers, Team, GitHub, Products, LinkedIn, YouTube, Discord, Twitter, Privacy Policy, Terms of Service, Code of Conduct, Cookie Policy, Licensing, Web Development, React, JavaScript, Python, Java, Tailwind CSS, CPP, NextJs, MATLAB, Julia, HTML, CSS, TypeScript, DSA, Data Structures, Algorithms, Competitive Programming", + }, + {name : "twitter:card", content : "summary_large_image"}, + {name : "twitter:site", content : "@CodesWithAjay"}, + {name : "twitter:creator", content : "@CodesWithAjay"}, + {property : "og:type", content : "website"}, + {property : "og:site_name", content : "CodeHarborHub"}, + { + property : "og:title", + content : "CodeHarborHub - A place to learn and grow", + }, + { + property : "og:description", + content : + "CodeHarborHub is a place to learn and grow. We provide accessible and comprehensive educational resources to learners of all levels, from beginners to advanced professionals.", + }, + { + property : "og:image", + content : + "https://codeharborhub.github.io/img/codeharborhub-social-card.jpg", + }, + {property : "og:url", content : "https://codeharborhub.github.io"}, + ], - navbar: { - title: "CodeHarborHub", - logo: { - alt: "CodeHarborHub Logo", - src: "img/nav-logo.jpg", + algolia : { + apiKey : "9a235effc3fe5f0b7b18245f309910c5", + indexName : "codeharborhubio", + appId : "ZF3MPCPQHR", + contextualSearch : false, }, - items: [ - { - type: "dropdown", - html: 'πŸ“š Docs', - position: "left", - items: [ - { - type: "html", - value: `