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

UI components #76

Merged
merged 2 commits into from
Jun 3, 2024
Merged

UI components #76

merged 2 commits into from
Jun 3, 2024

Conversation

Swathi-eGov
Copy link
Contributor

No description provided.

Copy link
Contributor

coderabbitai bot commented Jun 3, 2024

Walkthrough

This update introduces significant enhancements to the react/css and react/ui-components libraries, focusing on the Popup component. Key changes include the addition of an overlay for Popup, new styles for various elements, and the introduction of new components like Error Message, Info Button, and Stepper. The changes also include updates to existing components' styles and functionality, ensuring a more responsive and visually appealing user experience.

Changes

File(s) Change Summary
react/css/README.md Added overlay for Popup and updated styles for Panel, Popup, tag, and stepper.
react/css/src/digitv2/components/popUpV2.scss Repositioned popup overlay and adjusted styles for various elements within the popup component.
react/example/public/index.html Updated linked CSS file version to 1.8.2-coreui.24.
react/ui-components/README.md Documented new components and enhancements in version 0.0.2.
react/ui-components/src/atoms/PopUp.js Restructured rendering logic for Popup component and added onOverlayClick handler.
react/ui-components/src/hoc/stories/PopUp.stories.js Added overlayClassName and onOverlayClick controls for storybook.

Poem

In the realm of code, a Popup shines bright,
With overlays and styles, it takes flight. 🌟
Panels and tags join the dance,
New components seize their chance.
Buttons, Dropdowns, all enhanced anew,
For a UI that's vibrant, fresh, and true.
Hooray for updates, the journey's delight! 🚀


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 4

Outside diff range and nitpick comments (1)
react/ui-components/src/atoms/PopUp.js (1)

Line range hint 34-34: Correct the dependencies for useEffect hooks.

- }, [props.children]);
+ }, []);

Also applies to: 50-50

Tools
Biome

[error] 112-112: Enforce to have the onClick mouse event with the onKeyUp, the onKeyDown, or the onKeyPress keyboard event.


[error] 196-200: Enforce to have the onClick mouse event with the onKeyUp, the onKeyDown, or the onKeyPress keyboard event.

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 96416c1 and a126669.

Files ignored due to path filters (7)
  • react/css/package.json is excluded by !**/*.json
  • react/example/package.json is excluded by !**/*.json
  • react/modules/Project/package.json is excluded by !**/*.json
  • react/modules/core/package.json is excluded by !**/*.json
  • react/modules/sample/package.json is excluded by !**/*.json
  • react/package.json is excluded by !**/*.json
  • react/ui-components/package.json is excluded by !**/*.json
Files selected for processing (6)
  • react/css/README.md (1 hunks)
  • react/css/src/digitv2/components/popUpV2.scss (1 hunks)
  • react/example/public/index.html (1 hunks)
  • react/ui-components/README.md (2 hunks)
  • react/ui-components/src/atoms/PopUp.js (2 hunks)
  • react/ui-components/src/hoc/stories/PopUp.stories.js (3 hunks)
Additional context used
LanguageTool
react/css/README.md

[uncategorized] ~20-~20: A comma might be missing here.
Context: ...it UI's ``` ## Usage After adding the dependency make sure you have this dependency in ...


[grammar] ~95-~95: This phrase is duplicated. You should probably use “DIGIT Core” only once.
Context: ...ishnakole-wtt-egov] ## Published from DIGIT Core Digit Core Repo (https://github.com/egovernments/D...

react/ui-components/README.md

[uncategorized] ~18-~18: Possible missing comma found.
Context: ...ssion's ``` ## Usage After adding the dependency make sure you have this dependency in ...


[style] ~101-~101: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...ent. - Added Info Button Component. - Added Panels Component. - Added Popup Compon...


[style] ~102-~102: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...omponent. - Added Panels Component. - Added Popup Component With Two Variants defua...


[uncategorized] ~102-~102: Possible missing comma found.
Context: ...nent. - Added Popup Component With Two Variants defualt and alert. - Added RemoveableT...


[style] ~103-~103: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...With Two Variants defualt and alert. - Added RemoveableTag Component. - Added Stepp...


[style] ~104-~104: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...t. - Added RemoveableTag Component. - Added Stepper Component. - Added TextBlock Co...


[style] ~105-~105: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...omponent. - Added Stepper Component. - Added TextBlock Component. - Added Timeline C...


[style] ~106-~106: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...mponent. - Added TextBlock Component. - Added Timeline Component. - Added Uploader Co...


[style] ~107-~107: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...omponent. - Added Timeline Component. - Added Uploader Component With Three Varinats ...


[style] ~108-~108: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...loadFile,UploadPopup and UploadImage. - Added PanelCard Molecule. ### Enhancements ...


[style] ~114-~114: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...t Styles and Added SelectAll Option. - Updated InfoCard Component Styles. - Added Ani...

Markdownlint
react/css/README.md

93-93: Expected: 0 or 2; Actual: 1
Trailing spaces


95-95: Expected: 0 or 2; Actual: 1
Trailing spaces


42-42: Expected: 1; Actual: 0; Above
Headings should be surrounded by blank lines


91-91: Expected: 1; Actual: 0; Above
Headings should be surrounded by blank lines


95-95: Expected: 1; Actual: 0; Below
Headings should be surrounded by blank lines


41-41: null
Fenced code blocks should be surrounded by blank lines


90-90: null
Fenced code blocks should be surrounded by blank lines


96-96: null
Bare URL used


100-100: null
Files should end with a single newline character

react/ui-components/README.md

43-43: Expected: 0 or 2; Actual: 1
Trailing spaces


99-99: Expected: 0 or 2; Actual: 1
Trailing spaces


100-100: Expected: 0 or 2; Actual: 1
Trailing spaces


101-101: Expected: 0 or 2; Actual: 1
Trailing spaces


102-102: Expected: 0 or 2; Actual: 1
Trailing spaces


103-103: Expected: 0 or 2; Actual: 1
Trailing spaces


110-110: Expected: 0 or 2; Actual: 1
Trailing spaces


112-112: Expected: 0 or 2; Actual: 1
Trailing spaces


113-113: Expected: 0 or 2; Actual: 1
Trailing spaces


114-114: Expected: 0 or 2; Actual: 1
Trailing spaces


115-115: Expected: 0 or 2; Actual: 1
Trailing spaces


116-116: Expected: 0 or 2; Actual: 1
Trailing spaces


117-117: Expected: 0 or 2; Actual: 1
Trailing spaces


124-124: Expected: 0 or 2; Actual: 1
Trailing spaces


57-57: Expected: 1; Actual: 2
Multiple consecutive blank lines


133-133: Expected: 1; Actual: 2
Multiple consecutive blank lines


134-134: Expected: 1; Actual: 3
Multiple consecutive blank lines


154-154: Expected: 1; Actual: 2
Multiple consecutive blank lines


173-173: Expected: 1; Actual: 2
Multiple consecutive blank lines


42-42: Expected: 1; Actual: 0; Below
Headings should be surrounded by blank lines


127-127: null
Fenced code blocks should be surrounded by blank lines


141-141: null
Fenced code blocks should be surrounded by blank lines


145-145: null
Fenced code blocks should be surrounded by blank lines


147-147: null
Fenced code blocks should be surrounded by blank lines


157-157: null
Bare URL used


165-165: null
Bare URL used

Biome
react/ui-components/src/atoms/PopUp.js

[error] 76-79: This else clause can be omitted because previous branches break early.


[error] 112-112: Enforce to have the onClick mouse event with the onKeyUp, the onKeyDown, or the onKeyPress keyboard event.


[error] 196-200: Enforce to have the onClick mouse event with the onKeyUp, the onKeyDown, or the onKeyPress keyboard event.


[error] 34-34: This hook does not specify all of its dependencies: checkOverflow


[error] 34-34: This hook specifies more dependencies than necessary: props.children


[error] 50-50: This hook does not specify all of its dependencies: checkOverflow


[error] 50-50: This hook does not specify all of its dependencies: onResize

react/ui-components/src/hoc/stories/PopUp.stories.js

[error] 120-126: Missing key property for this element in iterable.


[error] 127-133: Missing key property for this element in iterable.


[error] 137-143: Missing key property for this element in iterable.


[error] 147-153: Missing key property for this element in iterable.


[error] 154-160: Missing key property for this element in iterable.


[error] 161-167: Missing key property for this element in iterable.


[error] 168-174: Missing key property for this element in iterable.


[error] 175-181: Missing key property for this element in iterable.


[error] 182-188: Missing key property for this element in iterable.


[error] 192-192: Missing key property for this element in iterable.


[error] 193-197: Missing key property for this element in iterable.


[error] 201-201: Missing key property for this element in iterable.


[error] 202-206: Missing key property for this element in iterable.


[error] 207-211: Missing key property for this element in iterable.


[error] 212-216: Missing key property for this element in iterable.


[error] 217-221: Missing key property for this element in iterable.


[error] 222-226: Missing key property for this element in iterable.


[error] 227-231: Missing key property for this element in iterable.


[error] 232-236: Missing key property for this element in iterable.


[error] 237-241: Missing key property for this element in iterable.

Additional comments not posted (5)
react/example/public/index.html (1)

12-12: Update the CSS version to ensure the latest styles are applied.

react/ui-components/README.md (1)

61-61: Great job documenting the new components and enhancements.

react/css/src/digitv2/components/popUpV2.scss (1)

1-292: The updated styles enhance the Popup component's responsiveness and aesthetics.

react/ui-components/src/hoc/stories/PopUp.stories.js (2)

15-20: Adding controls for overlay interaction is a good enhancement for storybook testing.
[APROVED]


114-116: Logging overlay clicks in storybook helps in debugging and interaction testing.

@jagankumar-egov jagankumar-egov merged commit 40db04f into develop Jun 3, 2024
1 check passed
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.

2 participants