Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🎨 Added fillers for the onboarding and app creation page #117

Merged
merged 1 commit into from
Mar 4, 2024

Conversation

abdheshnayak
Copy link
Member

No description provided.

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Type: Enhancement

PR Summary: This pull request introduces visual enhancements to the onboarding and app creation pages by adding filler images and updating UI components. It includes the addition of new filler components for various steps in the app creation process, updates to the design system's tailwind configuration for shadows, and the introduction of a new SplitWrapper component to manage layout changes dynamically based on the presence of filler images. The changes aim to improve the user experience during the onboarding and app creation process by providing visual cues and a more engaging interface.

Decision: Comment

📝 Type: 'Enhancement' - not supported yet.
  • Sourcery currently only approves 'Typo fix' PRs.
✅ Issue addressed: this change correctly addresses the issue or implements the desired feature.
No details provided.
📝 Complexity: the changes are too large or complex for Sourcery to approve.
  • Unsupported files: the diff contains files that Sourcery does not currently support during reviews.
  • Big diff: the diff is too large to approve with confidence.

General suggestions:

  • Consider refactoring the getFiller function to use a mapping object instead of a switch statement for scalability and ease of maintenance.
  • For the newly introduced SVG components, explore breaking them down into smaller, reusable components or loading them as external files for better maintainability.
  • Review the use of default exports across the newly added components. If the project's convention leans towards named exports for consistency and easier refactoring, consider adjusting accordingly.
  • Given the significant changes to the UI components and the introduction of new visual elements, ensure comprehensive testing, including unit and snapshot tests, to maintain high code quality and prevent regressions.

Thanks for using Sourcery. We offer it for free for open source projects and would be very grateful if you could help us grow. If you like it, would you consider sharing Sourcery on your favourite social media? ✨

Share Sourcery

Help me be more useful! Please click 👍 or 👎 on each comment to tell me if it was helpful.

Comment on lines +33 to +48
const getFiller = useCallback((): ReactNode => {
switch (currentStep) {
case 1:
return <FillerAppDetail />;
case 2:
return <FillerAppCompute />;
case 3:
return <FillerAppEnv />;
case 4:
return <FillerAppNetwork />;
case 5:
return <FillerAppReview />;
default:
return null;
}
}, [currentStep]);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (llm): The implementation of getFiller using a switch statement is clear and straightforward. However, consider if this could be refactored into a more dynamic approach, such as a mapping object, to reduce boilerplate and improve scalability if more steps are added in the future.

Comment on lines +6 to +11
xmlns="http://www.w3.org/2000/svg"
width="413"
height="649"
fill="none"
viewBox="0 0 413 649"
>
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (llm): The SVG component is quite large and complex. Consider breaking it down into smaller, reusable components for each distinct part of the SVG. This can improve readability and maintainability of the code.

Comment on lines +1 to +157
<path fill="#F4F4F5" d="M157.078 5.243H226.053V43.978H157.078z" />
<rect
width="85.222"
height="50.858"
x="283.662"
y="244.538"
fill="#fff"
rx="4"
/>
<rect
width="85.222"
height="50.858"
x="283.662"
y="244.538"
stroke="#D4D4D8"
rx="4"
/>
<path
fill="#F4F4F5"
d="M287.662 248.538H364.88399999999996V291.396H287.662z"
/>
<rect
width="75.6"
height="39.862"
x="-29.738"
y="16.363"
fill="#fff"
rx="4"
/>
<rect
width="75.6"
height="39.862"
x="-29.738"
y="16.363"
stroke="#D4D4D8"
rx="4"
/>
<path
fill="#F4F4F5"
d="M-25.738 20.363H41.861999999999995V46.224999999999994H-25.738z"
/>
<path
fill="#F4F4F5"
d="M-25.738 50.225H41.861999999999995V52.225H-25.738z"
/>
<circle cx="110.992" cy="222.081" r="100.559" fill="#DBEAFE" />
<path
fill="#FAFAFA"
stroke="#71717A"
strokeLinecap="round"
strokeLinejoin="round"
strokeWidth="8"
d="M111.29 297.36c41.419 0 74.996-33.577 74.996-74.996 0-41.42-33.577-74.997-74.996-74.997-41.42 0-74.997 33.577-74.997 74.997 0 41.419 33.577 74.996 74.997 74.996z"
/>
<path
stroke="#71717A"
strokeLinecap="round"
strokeLinejoin="round"
strokeWidth="8"
d="M111.285 244.666c16.514 0 29.901-13.387 29.901-29.901 0-16.513-13.387-29.9-29.901-29.9-16.513 0-29.9 13.387-29.9 29.9 0 16.514 13.387 29.901 29.9 29.901zM111.285 244.666c-22.053 0-39.93 17.878-39.93 39.931 13.257 9.192 47.79 22.062 79.861 0 0-22.053-17.878-39.931-39.931-39.931z"
/>
<path
fill="#3B82F6"
d="M177.084 234.325a622.892 622.892 0 0019.363 63.421 438.809 438.809 0 0032.76 66.42 2.397 2.397 0 001.891 1.046 2.45 2.45 0 002.524-2.359 2.61 2.61 0 00-.054-.557s-7.175-41.986-18.477-71.99a618.38 618.38 0 00-27.11-60.197 3.06 3.06 0 00-2.522-1.396 9.301 9.301 0 00-4.287.54 9.3 9.3 0 00-3.578 2.422 2.885 2.885 0 00-.51 2.65z"
/>
<path
fill="#111827"
d="M156.187 198.68a27.385 27.385 0 0119.291 5.799 13.474 13.474 0 013.147 3.421c3.09-1.058 5.034-3.144 8.487-1.168a12.866 12.866 0 00-.808-1.337l-.696-.945-.094-.115a1.653 1.653 0 00-.478-.399l-.432-.47-.559-.539-1.281-1.138-1.351-1.011-1.463-.809a26.523 26.523 0 00-9.634-3.189l-.719-.069-.177-.097-.823-.061a29.631 29.631 0 00-5.095.278c-.753.11-1.442.224-2.119.376l-1.76.443-.758.239-.669.256a5.713 5.713 0 00-1.049.408 7.068 7.068 0 00-.881.402l-.079-.275zM233.777 362.872a2.604 2.604 0 00-.054-.557s-7.175-41.986-18.477-71.99c-7.608-20.187-17.162-40.429-22.736-51.551l-6.547 3.855s47.276 121.692 45.29 122.602a2.451 2.451 0 002.524-2.359z"
opacity="0.1"
/>
<path
fill="#4B5563"
d="M181.462 229.269c.285-2.182 1.888-14.01-2.851-21.343a9.092 9.092 0 01-3.35.518c-4.407-.132-5.239-3.689-8.535-4.162-3.296-.473-4.818 5.372-4.845 5.423a25.706 25.706 0 003.976 15.08 25.94 25.94 0 0011.215 9.5l11.052-4.196-6.662-.82z"
/>
<path
fill="#111827"
d="M187.11 206.732c-3.455-1.912-5.398.11-8.487 1.168 4.725 7.358 3.122 19.187 2.851 21.343l6.673.859c.286-1.291.628-2.683.962-4.178l.227-1.126c.122-.756.272-1.563.357-2.372.156-1.294.228-2.597.215-3.901a27.386 27.386 0 00-.153-2.819 29.923 29.923 0 00-1.38-6.199 17.662 17.662 0 00-1.265-2.775z"
/>
<path
fill="#3B82F6"
d="M187.076 206.68a12.703 12.703 0 00-.809-1.337l-.696-.945-.094-.115a1.64 1.64 0 00-.478-.399l-.432-.47-.558-.539-1.281-1.137-1.352-1.012-1.462-.809a26.53 26.53 0 00-9.634-3.189l-.72-.069-.176-.097-.824-.06a29.52 29.52 0 00-5.094.277c-.753.111-1.442.224-2.119.376l-1.76.443-.759.239-.668.256a5.723 5.723 0 00-1.05.408 7.203 7.203 0 00-.881.402 10.379 10.379 0 015.245 7.25 18.78 18.78 0 01.463 3.748s1.505-5.756 4.846-5.423c3.34.333 4.128 4.03 8.535 4.163a9.072 9.072 0 003.35-.519c3.089-1.058 5.034-3.144 8.487-1.168l-.079-.274z"
/>
<path
fill="#F3F4F6"
d="M188.131 230.127a3.06 3.06 0 00-2.523-1.395 9.27 9.27 0 00-4.286.54 9.263 9.263 0 00-3.578 2.422 2.872 2.872 0 00-.833 2.636c1.089 4.522 2.393 9.428 3.816 14.596a3.806 3.806 0 011.047-3.44 11.732 11.732 0 019.91-3.74 3.714 3.714 0 013.066 1.96 294.938 294.938 0 00-6.619-13.579z"
/>
<path
fill="#E4E4E7"
d="M185.966 242.629a10.921 10.921 0 015.894-.889 3.715 3.715 0 013.067 1.96 1115.571 1115.571 0 00-6.76-13.623 3.052 3.052 0 00-2.522-1.396 8.996 8.996 0 00-4.319.543l-.07.126 4.57 13.234.14.045z"
/>
<path
fill="#3B82F6"
d="M111.51 142.917c-43.897 0-79.62 35.472-79.62 79.369a80.039 80.039 0 0013.225 44.035c2.421 3.67 6.246 6.289 10.6 6.911 8.312 1.187 12.668-1.718 24.387-15.462l44.177-65.238c5.252-7.209 22.058-21.621 47.538-21.621-14.578-17.033-36.13-27.994-60.307-27.994z"
opacity="0.7"
/>
</svg>
);
}

export default FillerCreateTeam;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (llm): The SVG component is well-structured and follows a clear hierarchy, making it easy to understand the visual representation it aims to create. However, consider encapsulating the SVG paths and shapes into smaller, reusable components if the SVGs become more complex or if similar patterns emerge across different SVG components. This can improve maintainability and readability.

Comment on lines +1 to +151
<rect
width="68.527"
height="8"
x="-13.518"
y="251.541"
fill="#F4F4F5"
rx="4"
/>
<rect
width="68.527"
height="8"
x="-13.518"
y="412.172"
fill="#F4F4F5"
rx="4"
/>
<rect
width="68.527"
height="8"
x="-13.518"
y="490.788"
fill="#F4F4F5"
rx="4"
/>
<rect
width="68.527"
height="8"
x="151.279"
y="412.172"
fill="#F4F4F5"
rx="4"
/>
<rect
width="155.239"
height="30.961"
x="151.279"
y="558.287"
fill="#E4E4E7"
rx="8"
/>
<rect
width="68.527"
height="8"
x="151.279"
y="176.925"
fill="#F4F4F5"
rx="4"
/>
<defs>
<filter
id="filter0_dd_9315_121984"
width="403.886"
height="556.735"
x="-58.936"
y="67.781"
colorInterpolationFilters="sRGB"
filterUnits="userSpaceOnUse"
>
<feFlood floodOpacity="0" result="BackgroundImageFix" />
<feColorMatrix
in="SourceAlpha"
result="hardAlpha"
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
/>
<feOffset dy="2" />
<feGaussianBlur stdDeviation="8" />
<feColorMatrix values="0 0 0 0 0.129412 0 0 0 0 0.168627 0 0 0 0 0.211765 0 0 0 0.08 0" />
<feBlend
in2="BackgroundImageFix"
result="effect1_dropShadow_9315_121984"
/>
<feColorMatrix
in="SourceAlpha"
result="hardAlpha"
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
/>
<feMorphology
in="SourceAlpha"
operator="dilate"
radius="1"
result="effect2_dropShadow_9315_121984"
/>
<feOffset />
<feColorMatrix values="0 0 0 0 0.0235294 0 0 0 0 0.172549 0 0 0 0 0.321569 0 0 0 0.1 0" />
<feBlend
in2="effect1_dropShadow_9315_121984"
result="effect2_dropShadow_9315_121984"
/>
<feBlend
in="SourceGraphic"
in2="effect2_dropShadow_9315_121984"
result="shape"
/>
</filter>
</defs>
</svg>
);
}

export default FillerAppDetail;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (llm): The implementation of the SVG directly within the React component is clear and straightforward for static assets. However, for scalability and maintainability, consider if this SVG will be reused or modified frequently. If so, it might be beneficial to explore loading it as an external file or using a dedicated SVG management library. This approach can help in reducing the component size and improving the project's structure.

@@ -0,0 +1,114 @@
import React from 'react';
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick (llm): While importing React is standard practice in a React component file, it's worth noting that with the newer versions of React (17+), importing React is no longer necessary for using JSX. This change is due to the new JSX transform. However, if your project's React version or linting rules still require this import, then it remains necessary.

@@ -0,0 +1,157 @@
function FillerCreateTeam() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (llm): I noticed that this pull request adds new SVG assets but does not include any tests to verify their correct integration or rendering within the application. While SVG assets themselves might not require traditional unit tests, it's important to ensure they are correctly integrated and displayed in the UI. Consider adding snapshot tests for the components that use these SVGs to ensure they render as expected.

@@ -0,0 +1,130 @@
function FillerTeam() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (llm): Similar to my previous comment, this file also introduces a new SVG asset without accompanying tests to verify its integration. Adding snapshot tests for the components that incorporate this SVG would help ensure it renders correctly in the UI and that any future changes do not inadvertently break its appearance.

@@ -0,0 +1,151 @@
import React from 'react';
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (llm): It appears that this pull request adds a new React component for displaying filler details in SVG format. However, I couldn't find any associated tests for this new component. While it's primarily a presentational component, having some basic render tests using a library like React Testing Library could help ensure that the component renders without errors and behaves as expected under different props or states if applicable in the future. Could you add some basic unit tests to verify the rendering of this component?

@@ -0,0 +1,114 @@
import React from 'react';
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (llm): It appears that this pull request adds a new React component but does not include any tests for it. While this component might be purely presentational, it's still important to ensure it renders correctly under various conditions. Could you add some basic snapshot tests to verify that the component renders as expected? This would help catch any unintentional changes in the future.

@@ -0,0 +1,88 @@
function FillerProject() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (llm): It appears this pull request introduces a new visual component (FillerProject) without accompanying unit tests or visual regression tests. While the component might be purely static, adding tests can help ensure its integrity over time, especially if it's subject to future modifications. Consider adding snapshot tests to verify that the rendered output remains consistent, or unit tests to check any logic that might be introduced later.

@abdheshnayak abdheshnayak merged commit d749ee6 into main Mar 4, 2024
4 checks passed
@abdheshnayak abdheshnayak deleted the feature/fillers branch March 4, 2024 13:05
abdheshnayak added a commit that referenced this pull request Oct 28, 2024
🎨 Added fillers for the onboarding and app creation page
tulsiojha pushed a commit that referenced this pull request Nov 1, 2024
🎨 Added fillers for the onboarding and app creation page
abdheshnayak added a commit that referenced this pull request Nov 5, 2024
🎨 Added fillers for the onboarding and app creation page
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant