From 6ab6cc64fd2eeeb8b6bd4a5d58f01a5f5b40bca5 Mon Sep 17 00:00:00 2001 From: asyncapi-bot Date: Sat, 17 Jun 2023 02:30:57 +0200 Subject: [PATCH 001/230] chore: update meetings.json and newsrooom_videos.json (#1799) --- config/meetings.json | 6 -- dashboard.json | 185 ++++++++++++++++--------------------------- 2 files changed, 70 insertions(+), 121 deletions(-) diff --git a/config/meetings.json b/config/meetings.json index 80432da1f84..6dc62d86fb4 100644 --- a/config/meetings.json +++ b/config/meetings.json @@ -5,12 +5,6 @@ "url": "https://github.com/asyncapi/community/issues/624", "date": "2023-03-15T16:00:00.000Z" }, - { - "title": "Career Empowerment and Embracing Equity in Tech", - "calLink": "https://www.google.com/calendar/event?eid=aGc1cDIybTM5MWtsdGFmMjNhOWdqY2MwYzggY19xOXRzZWlnbG9tZHNqNm5qdWh2YnB0czExY0Bn", - "url": "https://github.com/asyncapi/community/issues/625", - "date": "2023-03-08T14:00:00.000Z" - }, { "title": "Spec 3.0 Meeting", "calLink": "https://www.google.com/calendar/event?eid=bjE2ZTdnZGJ1bHNxMWhrcW9rcjh0bGRxN3MgY19xOXRzZWlnbG9tZHNqNm5qdWh2YnB0czExY0Bn", diff --git a/dashboard.json b/dashboard.json index a6eb4638d01..8a91a1cf5c6 100644 --- a/dashboard.json +++ b/dashboard.json @@ -11,6 +11,17 @@ "labels": [], "score": 22.68679251119144 }, + { + "id": "I_kwDOBGu-185CELGB", + "isPR": false, + "isAssigned": false, + "title": "Work on 3.0 release", + "author": "jonaslagoni", + "resourcePath": "/asyncapi/spec/issues/691", + "repo": "asyncapi/spec", + "labels": [], + "score": 21.538094156194408 + }, { "id": "MDU6SXNzdWU5OTMxODc5ODM=", "isPR": false, @@ -27,17 +38,6 @@ ], "score": 20.96374497869589 }, - { - "id": "I_kwDOBGu-185CELGB", - "isPR": false, - "isAssigned": false, - "title": "Work on 3.0 release", - "author": "jonaslagoni", - "resourcePath": "/asyncapi/spec/issues/691", - "repo": "asyncapi/spec", - "labels": [], - "score": 20.67657038994663 - }, { "id": "I_kwDOGJ23c85V9C3c", "isPR": false, @@ -54,17 +54,6 @@ ], "score": 19.815046623698855 }, - { - "id": "PR_kwDOE8Qh385SnNFz", - "isPR": true, - "isAssigned": false, - "title": "chore(website): add info for the general options", - "author": "SumantxD", - "resourcePath": "/asyncapi/modelina/pull/1398", - "repo": "asyncapi/modelina", - "labels": [], - "score": 19 - }, { "id": "I_kwDODou01c5AqLB8", "isPR": false, @@ -81,30 +70,6 @@ ], "score": 18.37917367995256 }, - { - "id": "I_kwDOG115t85D93P0", - "isPR": false, - "isAssigned": true, - "title": "Website UI Kit design/dev project", - "author": "mcturco", - "resourcePath": "/asyncapi/design-system/issues/4", - "repo": "asyncapi/design-system", - "labels": [ - { - "name": "enhancement", - "color": "a2eeef" - }, - { - "name": "gsoc", - "color": "F4D03F" - }, - { - "name": "🎨 design", - "color": "0D67D3" - } - ], - "score": 17.517649913704783 - }, { "id": "PR_kwDOBW5R_c5KIyGW", "isPR": true, @@ -113,28 +78,8 @@ "author": "sambhavgupta0705", "resourcePath": "/asyncapi/website/pull/1349", "repo": "asyncapi/website", - "labels": [ - { - "name": "πŸ“‘ docs", - "color": "E50E99" - }, - { - "name": "area/docs", - "color": "e50e99" - } - ], - "score": 15.220253203710714 - }, - { - "id": "PR_kwDOCoBobc5I0WzT", - "isPR": true, - "isAssigned": false, - "title": "docs: document rules", - "author": "magicmatatjahu", - "resourcePath": "/asyncapi/parser-js/pull/700", - "repo": "asyncapi/parser-js", "labels": [], - "score": 14.645904026212197 + "score": 16.36895155870775 }, { "id": "PR_kwDODCuNRs5Nh35U", @@ -147,6 +92,37 @@ "labels": [], "score": 14.358729437462937 }, + { + "id": "PR_kwDOBW5R_c5Jw5C6", + "isPR": true, + "isAssigned": true, + "title": "docs: new style guide - Inclusive Language", + "author": "BhaswatiRoy", + "resourcePath": "/asyncapi/website/pull/1327", + "repo": "asyncapi/website", + "labels": [], + "score": 14.07155484871368 + }, + { + "id": "PR_kwDOBW5R_c5J9Eji", + "isPR": true, + "isAssigned": true, + "title": "docs: new style guide - Grammar", + "author": "Arya-Gupta", + "resourcePath": "/asyncapi/website/pull/1343", + "repo": "asyncapi/website", + "labels": [ + { + "name": "πŸ“‘ docs", + "color": "E50E99" + }, + { + "name": "area/docs", + "color": "e50e99" + } + ], + "score": 13.78438025996442 + }, { "id": "PR_kwDOFDnrNc5RUbi_", "isPR": true, @@ -159,18 +135,39 @@ "score": 13.497205671215161 }, { - "id": "PR_kwDOE8Qh385SsTxJ", + "id": "I_kwDOCVQpZM5M_dcV", + "isPR": false, + "isAssigned": false, + "title": "DocsUI: Messages Object output", + "author": "mcturco", + "resourcePath": "/asyncapi/asyncapi-react/issues/618", + "repo": "asyncapi/asyncapi-react", + "labels": [], + "score": 12.922856493716644 + }, + { + "id": "PR_kwDOBGu-185KHmXZ", "isPR": true, "isAssigned": false, - "title": "chore: added java options to playground #1396", - "author": "SumantxD", - "resourcePath": "/asyncapi/modelina/pull/1400", - "repo": "asyncapi/modelina", + "title": "feat: new traits merge mechanism", + "author": "magicmatatjahu", + "resourcePath": "/asyncapi/spec/pull/907", + "repo": "asyncapi/spec", "labels": [], - "score": 13 + "score": 12.061332727468868 } ], "goodFirstIssues": [ + { + "id": "I_kwDOFLhIt85o9dDJ", + "title": "Add 2023 mentorship directory", + "isAssigned": false, + "resourcePath": "/asyncapi/community/issues/753", + "repo": "asyncapi/community", + "author": "AceTheCreator", + "area": "Unknown", + "labels": [] + }, { "id": "I_kwDOFLhIt85oSfWg", "title": "As A user, the CI should prevent me schedule an adhoc meeting in the past", @@ -186,29 +183,6 @@ } ] }, - { - "id": "I_kwDOE8Qh385oPFUl", - "title": "Add Java options to the playground", - "isAssigned": false, - "resourcePath": "/asyncapi/modelina/issues/1396", - "repo": "asyncapi/modelina", - "author": "jonaslagoni", - "area": "Unknown", - "labels": [ - { - "name": "enhancement", - "color": "a2eeef" - }, - { - "name": "Java generator", - "color": "d4c5f9" - }, - { - "name": "website", - "color": "57A793" - } - ] - }, { "id": "I_kwDOE8Qh385nTDiB", "title": "Add descriptions for options in playground", @@ -653,25 +627,6 @@ } ] }, - { - "id": "I_kwDOCoBobc5KYpv0", - "title": "Document how to fix randomly failing tests during development", - "isAssigned": false, - "resourcePath": "/asyncapi/parser-js/issues/558", - "repo": "asyncapi/parser-js", - "author": "derberg", - "area": "docs", - "labels": [ - { - "name": "enhancement", - "color": "a2eeef" - }, - { - "name": "stale", - "color": "ededed" - } - ] - }, { "id": "I_kwDOBW5R_c5IRxcq", "title": "[πŸ“‘ Docs]: update docs issues in ALL repos that are missing the `area/docs` label ", From 0b0ab18cf55ae6fb2bb022f717f66897e88a89b6 Mon Sep 17 00:00:00 2001 From: Aadrika Bhargava <64789514+reachaadrika@users.noreply.github.com> Date: Sat, 17 Jun 2023 16:28:36 +0530 Subject: [PATCH 002/230] feat: adding unit tests for typography component (#1793) Co-authored-by: Akshat Nema <76521428+akshatnema@users.noreply.github.com> --- components/typography/Paragraph.js | 2 +- components/typography/TextLink.js | 2 +- cypress/test/typography/Heading.cy.js | 25 +++++++++++++++++++ cypress/test/typography/Paragraph.cy.js | 32 ++++++++++++++++++++++++ cypress/test/typography/TextLink.cy.js | 33 +++++++++++++++++++++++++ 5 files changed, 92 insertions(+), 2 deletions(-) create mode 100644 cypress/test/typography/Heading.cy.js create mode 100644 cypress/test/typography/Paragraph.cy.js create mode 100644 cypress/test/typography/TextLink.cy.js diff --git a/components/typography/Paragraph.js b/components/typography/Paragraph.js index 6da9faa1b63..c99b621d5d7 100644 --- a/components/typography/Paragraph.js +++ b/components/typography/Paragraph.js @@ -23,6 +23,6 @@ export default function Paragraph({ } return ( -

{children}

+

{children}

) } \ No newline at end of file diff --git a/components/typography/TextLink.js b/components/typography/TextLink.js index 2810218811e..a9782b91548 100644 --- a/components/typography/TextLink.js +++ b/components/typography/TextLink.js @@ -14,7 +14,7 @@ export default function TextLink({ <> {' '} - + {children} diff --git a/cypress/test/typography/Heading.cy.js b/cypress/test/typography/Heading.cy.js new file mode 100644 index 00000000000..9081127df4b --- /dev/null +++ b/cypress/test/typography/Heading.cy.js @@ -0,0 +1,25 @@ +import { mount } from '@cypress/react'; +import Heading from '../../../components/typography/Heading' +describe('Heading Component', () => { + beforeEach(() => { + cy.mount(Default Heading); + }); + + it('renders the heading with the default props', () => { + cy.get('h2').should('have.class', 'text-primary-800'); + cy.get('h2').should( 'have.class','font-heading text-heading-md font-bold tracking-heading md:text-heading-lg' ); + cy.get('h2').should('contain', 'Default Heading'); + }); + + it('renders the heading with custom props', () => { + cy.mount( + + Heading with custom styles + + ); + cy.get('h3').should('have.class', 'text-red-500'); + cy.get('h3').should( 'have.class','font-heading text-heading-sm font-semibold tracking-heading'); + cy.get('h3').should('contain', 'Heading with custom styles'); + }); + }); + \ No newline at end of file diff --git a/cypress/test/typography/Paragraph.cy.js b/cypress/test/typography/Paragraph.cy.js new file mode 100644 index 00000000000..2d30074acd8 --- /dev/null +++ b/cypress/test/typography/Paragraph.cy.js @@ -0,0 +1,32 @@ +import { mount } from '@cypress/react'; +import Paragraph from '../../../components/typography/Paragraph'; +describe('Paragraph Component', () => { + beforeEach(() => { + cy.mount( + + Default Paragraph + + ); + }); + + it('renders the paragraph with the default props', () => { + cy.get('[data-testid="Paragraph-test" ]').should('have.class', 'text-gray-700'); + cy.get('[data-testid="Paragraph-test" ]').should('have.class', 'text-lg'); + cy.get('[data-testid="Paragraph-test" ]').should('have.class', 'font-bold'); + cy.get('[data-testid="Paragraph-test" ]').should('contain', 'Default Paragraph'); + }); + + it('renders the paragraph with custom props', () => { + cy.mount( + + Paragraph with custom styles + + ); + + cy.get('[data-testid="Paragraph-test" ]').should('have.class', 'text-blue-500'); + cy.get('[data-testid="Paragraph-test" ]').should('have.class', 'text-md'); + cy.get('[data-testid="Paragraph-test" ]').should('have.class', 'font-semibold'); + cy.get('[data-testid="Paragraph-test" ]').should('contain', 'Paragraph with custom styles'); + }); + }); + \ No newline at end of file diff --git a/cypress/test/typography/TextLink.cy.js b/cypress/test/typography/TextLink.cy.js new file mode 100644 index 00000000000..4e19c7f23e8 --- /dev/null +++ b/cypress/test/typography/TextLink.cy.js @@ -0,0 +1,33 @@ +import { mount } from '@cypress/react'; +import TextLink from '../../../components/typography/TextLink' +describe('TextLink Component', () => { + it('renders a Textlink with the provided props and content', () => { + const href = '/test'; + const className = 'custom-class'; + const target = '_blank'; + const id = 'test-link'; + const children = 'Test Link'; + + cy.mount( + + {children} + + ); + + cy.get('[data-testid="TextLink-href" ]') + .should('have.attr', 'href', href) + .should('have.class', 'text-secondary-500') + .should('have.class', 'underline') + .should('have.class', 'hover:text-gray-800') + .should('have.class', 'font-medium') + .should('have.class', 'transition') + .should('have.class', 'ease-in-out') + .should('have.class', 'duration-300') + .should('have.class', className) + .should('have.attr', 'target', target) + .should('have.attr', 'rel', 'noreferrer noopener') + .should('have.attr', 'id', id) + .should('contain', children); + }); + }); + \ No newline at end of file From 0e6fcabad00352b9ef79e5df8cb6c7ad12d351ca Mon Sep 17 00:00:00 2001 From: Aadrika Bhargava <64789514+reachaadrika@users.noreply.github.com> Date: Sat, 17 Jun 2023 17:58:49 +0530 Subject: [PATCH 003/230] feat: adding unit tests for docsCards and feature folders (#1763) Co-authored-by: Akshat Nema <76521428+akshatnema@users.noreply.github.com> --- components/docs/DocsCards.js | 12 +++--- components/features/FeatureList.js | 50 ++++++++++++++++++++++++ components/features/index.jsx | 62 ++++-------------------------- cypress/test/docs/DocsCards.cy.js | 46 ++++++++++++++++++++++ cypress/test/features/index.cy.js | 29 ++++++++++++++ 5 files changed, 139 insertions(+), 60 deletions(-) create mode 100644 components/features/FeatureList.js create mode 100644 cypress/test/docs/DocsCards.cy.js create mode 100644 cypress/test/features/index.cy.js diff --git a/components/docs/DocsCards.js b/components/docs/DocsCards.js index 39aa1bd733a..8262e37ac97 100644 --- a/components/docs/DocsCards.js +++ b/components/docs/DocsCards.js @@ -6,10 +6,12 @@ import { buckets } from '../data/buckets'; export function DocsCards() { return ( -
+
{buckets.map(card => ( + ))} +
); } @@ -17,17 +19,17 @@ export function DocsCards() { function Card({ title, description, link, className, Icon }) { return ( - +
-
+
-
- +
+
{title}
diff --git a/components/features/FeatureList.js b/components/features/FeatureList.js new file mode 100644 index 00000000000..c8fec12b78c --- /dev/null +++ b/components/features/FeatureList.js @@ -0,0 +1,50 @@ +export const features = [ + { + name: "Specification", + description: + "Allows you to define the interfaces of asynchronous APIs and is protocol agnostic.", + links: [{ label: "Documentation", href: "docs/specifications/latest", id:'whyasyncapi-spec-documentation-link' }], + }, + { + name: "Document APIs", + description: + "Use our tools to generate documentation at the build level, on a server, and on a client.", + links: [ + { + label: "HTML Template", + href: "https://github.com/asyncapi/html-template", + id:'whyasyncapi-apis-htmltemplate-link' + }, + { + label: "React Component", + href: "https://github.com/asyncapi/asyncapi-react/", + id:'whyasyncapi-apis-reactcomponents-link' + }, + ], + }, + { + name: "Code Generation", + description: + "Generate documentation, Code (TypeScript, Java, C#, etc), and more out of your AsyncAPI files.", + links: [{ label: "Generator", href: "tools/generator", id:'whyasyncapi-generation-generator-link' }, { label: "Modelina", href: "tools/modelina", id:'whyasyncapi-generation-modelina-link' }], + }, + { + name: "Community", + description: "We're a community of great people who are passionate about AsyncAPI and event-driven architectures.", + links: [ + { label: "Join our Slack", href: "https://asyncapi.com/slack-invite", id:'whyasyncapi-community-slack-link' }, + ], + }, + { + name: "Open Governance", + description: + "Our Open-Source project is part of Linux Foundation and works under an Open Governance model.", + links: [{ label: "Read more about Open Governance", href: "blog/governance-motivation", id:'whyasyncapi-governance-more-link' }, { label: "TSC Members", href: "community/tsc", id:'whyasyncapi-governance-tsc-link' }], + }, + { + name: "And much more...", + description: + "We have many different tools and welcome you to explore our ideas and propose new ideas to AsyncAPI.", + links: [{ label: "View GitHub Discussions", href: "https://github.com/asyncapi/community/discussions", id:'whyasyncapi-muchmore-github-link' }], + }, + ]; \ No newline at end of file diff --git a/components/features/index.jsx b/components/features/index.jsx index f6c2627ebc9..3ec6b0d00fb 100644 --- a/components/features/index.jsx +++ b/components/features/index.jsx @@ -2,57 +2,7 @@ import Heading from "../typography/Heading"; import Paragraph from "../typography/Paragraph"; import TextLink from "../typography/TextLink"; import Link from 'next/link' - -const features = [ - { - name: "Specification", - description: - "Allows you to define the interfaces of asynchronous APIs and is protocol agnostic.", - links: [{ label: "Documentation", href: "docs/specifications/latest", id:'whyasyncapi-spec-documentation-link' }], - }, - { - name: "Document APIs", - description: - "Use our tools to generate documentation at the build level, on a server, and on a client.", - links: [ - { - label: "HTML Template", - href: "https://github.com/asyncapi/html-template", - id:'whyasyncapi-apis-htmltemplate-link' - }, - { - label: "React Component", - href: "https://github.com/asyncapi/asyncapi-react/", - id:'whyasyncapi-apis-reactcomponents-link' - }, - ], - }, - { - name: "Code Generation", - description: - "Generate documentation, Code (TypeScript, Java, C#, etc), and more out of your AsyncAPI files.", - links: [{ label: "Generator", href: "tools/generator", id:'whyasyncapi-generation-generator-link' }, { label: "Modelina", href: "tools/modelina", id:'whyasyncapi-generation-modelina-link' }], - }, - { - name: "Community", - description: "We're a community of great people who are passionate about AsyncAPI and event-driven architectures.", - links: [ - { label: "Join our Slack", href: "https://asyncapi.com/slack-invite", id:'whyasyncapi-community-slack-link' }, - ], - }, - { - name: "Open Governance", - description: - "Our Open-Source project is part of Linux Foundation and works under an Open Governance model.", - links: [{ label: "Read more about Open Governance", href: "blog/governance-motivation", id:'whyasyncapi-governance-more-link' }, { label: "TSC Members", href: "community/tsc", id:'whyasyncapi-governance-tsc-link' }], - }, - { - name: "And much more...", - description: - "We have many different tools and welcome you to explore our ideas and propose new ideas to AsyncAPI.", - links: [{ label: "View GitHub Discussions", href: "https://github.com/asyncapi/community/discussions", id:'whyasyncapi-muchmore-github-link' }], - }, -]; +import { features } from "./FeatureList"; export default function Features() { return ( @@ -69,14 +19,16 @@ export default function Features() { Improving the current state of Event-Driven Architectures (EDA)
-