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

feat(docs): docs changes #2868

Merged
merged 8 commits into from May 4, 2024
Merged

feat(docs): docs changes #2868

merged 8 commits into from May 4, 2024

Conversation

wingkwong
Copy link
Member

@wingkwong wingkwong commented Apr 25, 2024

Closes #

📝 Description

to be merged to canary once the new gitflow is applied

⛳️ Current behavior (updates)

Please describe the current behavior that you are modifying

🚀 New behavior

Please describe the behavior or changes this PR adds

💣 Is this a breaking change (Yes/No):

📝 Additional Information

Summary by CodeRabbit

  • New Features

    • Enhanced search result sorting based on item type.
    • Expanded locale support in the NextUIProvider, including a detailed list of supported locales and an example for setting a specific locale.
    • Updated the DateRangePicker to allow displaying up to three visible months without affecting other properties.
    • Added comprehensive customization options for the Range Calendar, including styling, behavior, and content management.
    • Improved CLI commands for initializing and setting up a NextUI project with detailed installation and server start-up instructions.
  • Bug Fixes

    • Standardized error message display across various input components to enhance user experience and consistency.
  • Documentation

    • Updated API references and guides with clearer instructions and examples for setting locales, managing date ranges, and initializing projects.

@wingkwong wingkwong added the 📋 Scope : Docs Related to the documentation label Apr 25, 2024
Copy link

changeset-bot bot commented Apr 25, 2024

⚠️ No Changeset found

Latest commit: b155c7c

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link
Contributor

coderabbitai bot commented Apr 25, 2024

Warning

Rate Limit Exceeded

@wingkwong has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 0 minutes and 31 seconds before requesting another review.

How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.
Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.
Please see our FAQ for further information.

Commits Files that changed from the base of the PR and between 9ee9f6e and b155c7c.

Walkthrough

The update focuses on enhancing UI components and documentation in a software project. Changes include sorting functions in search components, consistent error messaging in input validations, and state type updates in form components. Documentation improvements cover API references, component guides, and project setup instructions, aiming for better usability and developer guidance.

Changes

File Path Change Summary
.../cmdk.tsx, .../input/regex-validation.ts, .../tabs/form.ts Updated sorting functions, error messages, and state type handling in UI components.
.../nextui-provider.mdx, .../date-range-picker.mdx, .../input.mdx, .../range-calendar.mdx, .../cli.mdx, .../installation.mdx Enhanced documentation for API references, component guidelines, and project setup instructions.
.../range-calendar.stories.tsx Adjusted storybook properties for calendar components.

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.

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 a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @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

vercel bot commented Apr 25, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
nextui-docs-v2 ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 4, 2024 3:56pm
nextui-storybook-v2 ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 4, 2024 3:56pm

* docs(guide): add an explanation for the installation guide

* docs(guide): add an explanation for the cli guide

* docs(guide): add support for cli output
kuri-sun and others added 2 commits April 26, 2024 11:32
#2881)

* chore(calendar): remove showMonthAndYearPickers from range calendar story

* docs(date-range-picker): remove showMonthAndYearPickers info

* docs(range-calendar): remove unsupported props
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: 1

Out of diff range and nitpick comments (4)
apps/docs/content/docs/components/date-range-picker.mdx (4)

Line range hint 5-5: Ensure the sentence starts with an uppercase letter for consistency.

- date Range Picker combines two DateInputs and a RangeCalendar popover to allow users to enter or select a date and time range.
+ Date Range Picker combines two DateInputs and a RangeCalendar popover to allow users to enter or select a date and time range.

Line range hint 64-64: Clarify the comma usage before "if" to improve readability.

- By default, the calendar popover displays a single month. The `visibleMonths` prop allows displaying up to 3 months at a time, if screen space permits.
+ By default, the calendar popover displays a single month. The `visibleMonths` prop allows displaying up to 3 months at a time if screen space permits.

Line range hint 285-285: Capitalize the first letter of the sentence for consistency.

- - **base**: base element. it handles alignment, placement, and general appearance.
+ - **base**: Base element. It handles alignment, placement, and general appearance.

Line range hint 323-323: Use "an" instead of "a" before words that start with a vowel sound.

- When the date-range-picker has a end content. Base on those `endContent` prop.
+ When the date-range-picker has an end content. Based on those `endContent` prop.

apps/docs/content/docs/components/input.mdx Show resolved Hide resolved
@wingkwong wingkwong marked this pull request as draft April 29, 2024 14:44
@wingkwong wingkwong changed the base branch from main to canary April 30, 2024 03:11
@wingkwong wingkwong marked this pull request as ready for review April 30, 2024 03:11
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: 2

Out of diff range and nitpick comments (2)
apps/docs/content/docs/api-references/nextui-provider.mdx (2)

42-42: Consider using a hyphen in "client side" to form the compound adjective "client-side".

The phrase "client side router" should be "client-side router" to correctly form the compound adjective modifying "router".


154-157: Clarify the interaction between disableAnimation and skipFramerMotionAnimations properties.

The description of how disableAnimation interacts with skipFramerMotionAnimations could be clearer. Consider rephrasing to explicitly state the conditions under which each property affects the animations.

@@ -5,80 +5,167 @@ description: API References for NextUI Provider

# NextUI Provider

API reference for the `NextUIProvider`.
Copy link
Contributor

Choose a reason for hiding this comment

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

Ensure consistency in the description of the NextUIProvider.

The description "API reference for the NextUIProvider." could be expanded to provide more context about what NextUIProvider does, rather than just stating that this is an API reference.

Comment on lines +112 to +125
For example, if your application only supports Gregorian dates, you could implement a `createCalendar`
function like this:

```tsx
import {GregorianCalendar} from '@internationalized/date';

function createCalendar(identifier) {
switch (identifier) {
case 'gregory':
return new GregorianCalendar();
default:
throw new Error(`Unsupported calendar ${identifier}`);
}
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Ensure the createCalendar function handles all necessary cases.

The createCalendar function currently only handles the 'gregory' identifier. Consider adding more cases or a default handler to ensure that the function can manage different calendar types if necessary.

@jrgarciadev jrgarciadev merged commit dc24587 into canary May 4, 2024
8 checks passed
@jrgarciadev jrgarciadev deleted the docs/for-next-release branch May 4, 2024 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📋 Scope : Docs Related to the documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants