Skip to content

Commit

Permalink
Merge branch 'master' into fix/roadmap_modal
Browse files Browse the repository at this point in the history
  • Loading branch information
codingmickey authored Jul 15, 2023
2 parents c6091d1 + 8549ce7 commit 2858c75
Show file tree
Hide file tree
Showing 30 changed files with 495 additions and 84 deletions.
19 changes: 19 additions & 0 deletions .all-contributorsrc
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,25 @@
"contributions": [
"code"
]
},
{
"login": "vishvamsinh28",
"name": "Vishvamsinh Vaghela",
"avatar_url": "https://avatars.githubusercontent.com/u/90895835?v=4",
"profile": "https://github.com/vishvamsinh28",
"contributions": [
"code"
]
},
{
"login": "AnimeshKumar923",
"name": "Animesh Kumar",
"avatar_url": "https://avatars.githubusercontent.com/u/99868037?v=4",
"profile": "https://github.com/AnimeshKumar923",
"contributions": [
"doc",
"review"
]
}
],
"contributorsPerLine": 7,
Expand Down
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
**
4 changes: 2 additions & 2 deletions CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
# For more details, read the following article on GitHub: https://help.github.com/articles/about-codeowners/.

# The default owners are automatically added as reviewers when you open a pull request unless different owners are specified in the file.
* @derberg @akshatnema @magicmatatjahu @asyncapi-bot-eve
* @derberg @akshatnema @magicmatatjahu @mayaleeeee @asyncapi-bot-eve

# All .md files
*.md @alequetzalli @asyncapi-bot-eve

pages/blog/*.md @thulieblack @alequetzalli
pages/community/*.md @thulieblack @alequetzalli

README.md @alequetzalli @derberg @akshatnema @magicmatatjahu @asyncapi-bot-eve
README.md @alequetzalli @derberg @akshatnema @magicmatatjahu @mayaleeeee @asyncapi-bot-eve
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
---

<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
[![All Contributors](https://img.shields.io/badge/all_contributors-50-orange.svg?style=flat-square)](#contributors-)
[![All Contributors](https://img.shields.io/badge/all_contributors-52-orange.svg?style=flat-square)](#contributors-)
<!-- ALL-CONTRIBUTORS-BADGE:END -->

[![Netlify Status](https://api.netlify.com/api/v1/badges/b2137407-b765-46c4-95b5-a72d9b1592ab/deploy-status)](https://app.netlify.com/sites/asyncapi-website/deploys)
Expand Down Expand Up @@ -214,6 +214,8 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
</tr>
<tr>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/reachaadrika"><img src="https://avatars.githubusercontent.com/u/64789514?v=4?s=100" width="100px;" alt="Aadrika Bhargava"/><br /><sub><b>Aadrika Bhargava</b></sub></a><br /><a href="https://github.com/asyncapi/website/commits?author=reachaadrika" title="Code">💻</a></td>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/vishvamsinh28"><img src="https://avatars.githubusercontent.com/u/90895835?v=4?s=100" width="100px;" alt="Vishvamsinh Vaghela"/><br /><sub><b>Vishvamsinh Vaghela</b></sub></a><br /><a href="https://github.com/asyncapi/website/commits?author=vishvamsinh28" title="Code">💻</a></td>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/AnimeshKumar923"><img src="https://avatars.githubusercontent.com/u/99868037?v=4?s=100" width="100px;" alt="Animesh Kumar"/><br /><sub><b>Animesh Kumar</b></sub></a><br /><a href="https://github.com/asyncapi/website/commits?author=AnimeshKumar923" title="Documentation">📖</a> <a href="https://github.com/asyncapi/website/pulls?q=is%3Apr+reviewed-by%3AAnimeshKumar923" title="Reviewed Pull Requests">👀</a></td>
</tr>
</tbody>
</table>
Expand Down
8 changes: 4 additions & 4 deletions components/buttons/Button.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,16 @@ export default function Button({

if (!href) {
return (
<button {...props} type={type} className={buttonSize === 'small' ? smallButtonClasses : classNames}>
<button {...props} type={type} className={buttonSize === 'small' ? smallButtonClasses : classNames} data-testid="Button-main" >
{
icon && iconPosition === 'left' && (
<span className="inline-block mr-2">{icon}</span>
<span className="inline-block mr-2" data-testid="Button-icon-left">{icon}</span>
)
}
<span className="inline-block">{text}</span>
{
icon && iconPosition === 'right' && (
<span className="inline-block ml-2">{icon}</span>
<span className="inline-block ml-2" data-testid="Button-icon-right">{icon}</span>
)
}
</button>
Expand All @@ -37,7 +37,7 @@ export default function Button({

return (
<Link href={href} passHref>
<a {...props} target={target} rel="noopener noreferrer" className={buttonSize === 'small' ? smallButtonClasses : classNames}>
<a {...props} target={target} rel="noopener noreferrer" className={buttonSize === 'small' ? smallButtonClasses : classNames} data-testid="Button-link">
{
icon && iconPosition === 'left' && (
<span className="inline-block mr-2">{icon}</span>
Expand Down
1 change: 1 addition & 0 deletions components/buttons/ChapterSuggestion.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ export default function ChapterSuggestion({
rel="noopener noreferrer"
title={description}
className={`${className} flex flex-col mt-4 p-6 max-w-lg rounded shadow-md border border-gray-200 text-gray-900 transition-all duration-300 ease-in-out hover:shadow-lg hover:border-gray-300`}
data-testid="ChapterSuggestion-link"
>
<h5 className="text-lg font-medium font-sans antialiased mb-2">{title}</h5>
<p className="flex-1 mb-2 font-normal text-gray-600 font-sans antialiased">{description}</p>
Expand Down
8 changes: 4 additions & 4 deletions components/buttons/DocsButton.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export default function DocsButton({ post, className='' }) {
{ post?.prevPage && <Link href={post.prevPage.href} passHref>
<a>
<div className="p-4 rounded shadow-md border border-gray-200 transition-all duration-300 ease-in-out hover:shadow-lg hover:border-gray-300 text-center lg:text-left cursor-pointer">
<div className="text-secondary-500">
<div className="text-secondary-500" data-testid="DocsButton-Prevdiv">
<svg
xmlns="http://www.w3.org/2000/svg"
className="h-6 w-6 inline mr-1"
Expand All @@ -26,7 +26,7 @@ export default function DocsButton({ post, className='' }) {
Go Back
</div>
</div>
<div className="font-medium text-base my-2">{post.prevPage.title}</div>
<div className="font-medium text-base my-2" data-testid="DocsButton-PrevPage" >{post.prevPage.title}</div>
</div>
</a>
</Link>
Expand All @@ -36,7 +36,7 @@ export default function DocsButton({ post, className='' }) {
{ post?.nextPage && <Link href={post.nextPage.href} className='h-auto' passHref>
<a>
<div className="p-4 rounded shadow-md border border-gray-200 transition-all duration-300 ease-in-out hover:shadow-lg hover:border-gray-300 text-center lg:text-right cursor-pointer">
<div className="text-secondary-500">
<div className="text-secondary-500" data-testid="DocsButton-Nextdiv">
<div className="font-bold my-auto text-sm inline uppercase">
Up Next
</div>
Expand All @@ -55,7 +55,7 @@ export default function DocsButton({ post, className='' }) {
/>
</svg>
</div>
<div className="font-medium text-base my-2">{post.nextPage.title}</div>
<div className="font-medium text-base my-2" data-testid="DocsButton-NextPage">{post.nextPage.title}</div>
</div>
</a>
</Link>
Expand Down
2 changes: 1 addition & 1 deletion components/buttons/GitHubIssue.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react'

export default function GitHubIssue({className=''}) {
return (
<a className={`bg-black text-white flex flex-row lg:w-6/12 shadow-md hover:shadow-lg transition-all duration-500 ease-in-out py-2 rounded justify-center ${className}`} href='https://github.com/asyncapi/website/issues/new?assignees=alequetzalli+-&labels=%F0%9F%93%91+docs&template=docs.yml&title=%5B%F0%9F%93%91+Docs%5D%3A+' target='_blank' rel='noopener noreferrer'>
<a className={`bg-black text-white flex flex-row lg:w-6/12 shadow-md hover:shadow-lg transition-all duration-500 ease-in-out py-2 rounded justify-center ${className}`} href='https://github.com/asyncapi/website/issues/new?assignees=alequetzalli+-&labels=%F0%9F%93%91+docs&template=docs.yml&title=%5B%F0%9F%93%91+Docs%5D%3A+' target='_blank' rel='noopener noreferrer' data-testid="GithubIssue-Link">
<img src='/img/logos/github-fill.svg' className='mr-2' alt="Github:AsyncAPI" />
Create Issue on GitHub
</a>
Expand Down
2 changes: 1 addition & 1 deletion components/buttons/ICSFileButton.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import Button from './Button';
import IconCalendar from '../icons/Calendar';

export default function GoogleCalendarButton({
export default function ICSFButton({
text = 'Download ICS File',
href,
target = '_blank',
Expand Down
12 changes: 12 additions & 0 deletions config/MAINTAINERS.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,16 @@
[
{
"name": "Aishat Muibudeen",
"github": "mayaleeeee",
"linkedin": "aishatmuibudeen",
"slack": "U03CNHGEUR1",
"twitter": "maya_ux_ui",
"availableForHire": true,
"isTscMember": true,
"repos": [
"website"
]
},
{
"name": "Aayush Sahu",
"github": "aayushmau5",
Expand Down
16 changes: 15 additions & 1 deletion config/casestudies/adeo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,22 @@ schemas:
description: Avro 1.9
storage: Git repository where source code is. During release they are published to Confluent Schema Registry.
registry: Confluent Schema Registry.
versioning: Versioning is based on git tags. The schema version pushed to Confluent Schema Registry matches the git tag version of the product. Every schema has a `version` information that matches with product tag version.
validation: Based on validation using Confluent Schema Registry.
versioning: |
Versioning is based on git tags. The schema version pushed to Confluent Schema Registry
matches the git tag version of the product. Every schema has a `version` information
that matches with product tag version.
Example Avro schema with version information:
```json
{
"namespace": "com.adeo.casestudy.costingrequest",
"type": "record",
"name": "CostingRequestPayload",
"version": "1.1.0",
"fields": [ ... ]
}
```
asyncapi:
usecase: |
Document the API of the product, so its users know how it works and how to use it. AsyncAPI was selected as the standard that allows you to generate documentation from a machine-readable document that describes the API.
Expand Down
20 changes: 14 additions & 6 deletions config/meetings.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
[
{
"title": "Community Meeting",
"calLink": "https://www.google.com/calendar/event?eid=czRmMG5maHRsYjduM2g3dmwxMDM1Z3R0NzAgY19xOXRzZWlnbG9tZHNqNm5qdWh2YnB0czExY0Bn",
"url": "https://github.com/asyncapi/community/issues/645",
"date": "2023-04-04T08:00:00.000Z"
},
{
"title": "Spec 3.0 Meeting",
"calLink": "https://www.google.com/calendar/event?eid=djhsdjZvbmRsampvb2tsYzhkZWFyc3FtYTAgY19xOXRzZWlnbG9tZHNqNm5qdWh2YnB0czExY0Bn",
Expand Down Expand Up @@ -220,5 +214,19 @@
"url": "https://github.com/asyncapi/community/issues/791",
"banner": "",
"date": "2023-08-03T14:30:00.000Z"
},
{
"title": "Community Meeting",
"calLink": "https://www.google.com/calendar/event?eid=MmpwYXMxYjBscjlnYWhtMHR2MnQ2MTMwM2cgY19xOXRzZWlnbG9tZHNqNm5qdWh2YnB0czExY0Bn",
"url": "https://github.com/asyncapi/community/issues/798",
"banner": "https://user-images.githubusercontent.com/40604284/252807786-f93110e3-c344-4080-9c4f-9d32cb324680.png",
"date": "2023-07-25T08:00:00.000Z"
},
{
"title": "Design meeting",
"calLink": "https://www.google.com/calendar/event?eid=czVxbG5jZXV2MThxczJjczdhMmtxZzE1djAgY19xOXRzZWlnbG9tZHNqNm5qdWh2YnB0czExY0Bn",
"url": "https://github.com/asyncapi/community/issues/800",
"banner": "",
"date": "2023-07-18T08:00:00.000Z"
}
]
24 changes: 12 additions & 12 deletions config/newsroom_videos.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,16 @@
[
{
"image_url": "https://i.ytimg.com/vi/WlD5rqmfezw/hqdefault.jpg",
"title": "Open Standards and Private Products: A DevRel&#39;s Dream or Nightmare",
"description": "We are discussing the impact of open standards and working with private products as a DevRel.",
"videoId": "WlD5rqmfezw"
},
{
"image_url": "https://i.ytimg.com/vi/5o5BHJqGxIg/hqdefault.jpg",
"title": "Community Meeting (July 11th 2023)",
"description": "https://github.com/asyncapi/community/issues/784.",
"videoId": "5o5BHJqGxIg"
},
{
"image_url": "https://i.ytimg.com/vi/Lunp8eSLONc/hqdefault.jpg",
"title": "Spec 3.0 DOCS Meeting (July 6th 2023)",
Expand All @@ -16,17 +28,5 @@
"title": "Community Meeting, Tuesday June 27th 2023",
"description": "https://github.com/asyncapi/community/issues/762.",
"videoId": "EvC2PZXEM0M"
},
{
"image_url": "https://i.ytimg.com/vi/1jiRDmuA-zg/hqdefault.jpg",
"title": "Fran AMA AsyncAPI — 23 June 2023",
"description": "https://github.com/asyncapi/community/issues/764 AI-generated summary: - Fran and Benjamin discussed the release of version ...",
"videoId": "1jiRDmuA-zg"
},
{
"image_url": "https://i.ytimg.com/vi/dRu9itGfJ1E/hqdefault.jpg",
"title": "AsyncAPI Spec 3.0 Docs Meeting",
"description": "https://github.com/asyncapi/community/issues/749.",
"videoId": "dRu9itGfJ1E"
}
]
22 changes: 22 additions & 0 deletions cypress/test/buttons/ApplyJob.cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import React from 'react';
import { mount } from 'cypress/react';
import ApplyJobButton from '../../../components/buttons/ApplyJob';

describe('ApplyJobButton', () => {
const job = {
contact: 'https://www.asyncapi.com/',
};

beforeEach(() => {
mount(<ApplyJobButton job={job} />);
});

it('renders the ApplyJobButton component', () => {
cy.contains('Apply for this job').should('exist');
});

it('sets the correct href and target attributes', () => {
cy.get('[data-testid="Button-link"]').should('have.attr', 'href', 'https://www.asyncapi.com/');
cy.get('[data-testid="Button-link"]').should('have.attr', 'target', '_blank');
});
});
64 changes: 64 additions & 0 deletions cypress/test/buttons/Buttons.cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
import React from 'react';
import { mount } from 'cypress/react';
import Button from '../../../components/buttons/Button';
import IconGithub from '../../../components/icons/Github'
describe('Button component', () => {
it('renders a button without href', () => {
const text = 'Click me';
const type = 'button';
const icon = <IconGithub />;
mount(
<Button text={text} type={type} icon={icon} />
);
cy.get('[data-testid="Button-main"]').should('have.text', text);
cy.get('[data-testid="Button-main"]').should('have.attr', 'type', type);
cy.get('[data-testid="Button-link"]').should('not.exist');
});

it('renders a button with href', () => {
const text = 'Click me';
const href = '/link';
const target = '_blank';
mount(
<Button text={text} href={href} target={target} />
);
cy.get('[data-testid="Button-link"]').should('have.text', text);
cy.get('[data-testid="Button-link"]').should('have.attr', 'href', href);
cy.get('[data-testid="Button-link"]').should('have.attr', 'target', target);
cy.get('[data-testid="Button-main"]').should('not.exist');
});

it('renders a small button', () => {
const text = 'Click me';
const buttonSize = 'small';
mount(
<Button text={text} buttonSize={buttonSize} />
);
cy.get('[data-testid="Button-main"]').should('have.class', 'px-3 py-2 text-sm');
});
it('renders a button with custom class', () => {
const text = 'Click me';
const className = 'custom-button';

mount(
<Button text={text} className={className} />
);
cy.get('[data-testid="Button-main"]').should('have.class', className);
});

it('does not render an icon with position left in the button', () => {
const text = 'Click me';
mount(
<Button text={text} />
);
cy.get('[data-testid="Button-icon-left"]').should('not.exist');
});

it('does not render an icon with position left in the button', () => {
const text = 'Click me';
mount(
<Button text={text} />
);
cy.get('[data-testid="Button-icon-right"]').should('not.exist');
});
});
40 changes: 40 additions & 0 deletions cypress/test/buttons/ChapterSuggestion.cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
import React from 'react';
import { mount } from 'cypress/react';
import ChapterSuggestion from '../../../components/buttons/ChapterSuggestion';
describe('ChapterSuggestion', () => {
const chapter = {
href: 'https://www.asyncapi.com/',
target: '_self',
title: 'Chapter Title',
description: 'Chapter Description',
linkText: 'Read More',
className: 'custom-class',
};
beforeEach(() => {
mount(<ChapterSuggestion {...chapter} />);
});

it('renders the ChapterSuggestion component', () => {
cy.contains(chapter.title).should('exist');
cy.contains(chapter.description).should('exist');
cy.contains(chapter.linkText).should('exist');
cy.get('[data-testid="ChapterSuggestion-link"]').should('have.attr', 'href', chapter.href);
});

it('applies the correct className', () => {
cy.get('[data-testid="ChapterSuggestion-link"]').should('have.class', chapter.className);
});

it('sets the target attribute', () => {
cy.get('[data-testid="ChapterSuggestion-link"]').should('have.attr', 'target', chapter.target);
});

it('sets the title attribute', () => {
cy.get('[data-testid="ChapterSuggestion-link"]').should('have.attr', 'title', chapter.description);
});

it('renders the link text and IconArrowRight', () => {
cy.contains(chapter.linkText).should('exist');
cy.get('svg').should('have.class', 'h-4');
});
});
Loading

0 comments on commit 2858c75

Please sign in to comment.