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 : update the dev branch to the latest changes of the components #27

Merged
merged 20 commits into from
Mar 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
636f429
Merge pull request #12 from BelkacemYerfa/dev
BelkacemYerfa Mar 8, 2024
561fa47
Merge pull request #17 from BelkacemYerfa/dev
BelkacemYerfa Mar 26, 2024
9b338ae
fix : the compatibility of file upload component with validation libs
BelkacemYerfa Mar 27, 2024
a85c135
feat : add the file upload doc
BelkacemYerfa Mar 27, 2024
0aea08e
feat : add the section example for breadcrumb component
BelkacemYerfa Mar 27, 2024
3313dfa
feat : add the last doc updates for the new launch
BelkacemYerfa Mar 28, 2024
daf2d8a
Merge branch 'playground'
BelkacemYerfa Mar 28, 2024
1c326b4
fix : the keyboard func for breadcrumb component
BelkacemYerfa Mar 28, 2024
d348a88
fix : tree view guide
BelkacemYerfa Mar 28, 2024
e5e5da4
fix : the banner website naming
BelkacemYerfa Mar 28, 2024
58ca659
feat : add the navigation mobile menu , feat : add the breadcrumb ac…
BelkacemYerfa Mar 29, 2024
70613c7
Merge pull request #21 from BelkacemYerfa/master
BelkacemYerfa Mar 29, 2024
d6eea84
Merge pull request #22 from BelkacemYerfa/playground
BelkacemYerfa Mar 29, 2024
e0d3053
feat : add mobile menu navigation , feat : add more breadcrumb examples
BelkacemYerfa Mar 29, 2024
fb99f62
Merge branch 'playground' of https://github.com/BelkacemYerfa/shadcn-…
BelkacemYerfa Mar 29, 2024
10e2c11
👌 IMPROVE(carousel): fix missing classname, use data attribute for th…
ahmedrowaihi Mar 29, 2024
eede795
FIX: missing data-active attribute
ahmedrowaihi Mar 29, 2024
a01c0c5
Merge pull request #23 from ahmedrowaihi/patch-1
BelkacemYerfa Mar 29, 2024
65b932e
cleanup ✨
BelkacemYerfa Mar 30, 2024
42ba5bd
cleanup ✨
BelkacemYerfa Mar 30, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,5 @@ yarn-error.log*
next-env.d.ts

.contentlayer
.vscode
tsconfig.tsbuildinfo
30 changes: 14 additions & 16 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,36 +69,34 @@

// Toggle excluded files
"files.exclude": {
"**/.DS_Store": true,
"**/.editorconfig": true,
"**/.env.example": true,
"**/.eslintrc.cjs": true,
"**/.git": true,
"**/.svn": true,
"**/.hg": true,
"**/CVS": true,
"**/.DS_Store": true,
"**/Thumbs.db": true,
"**/node_modules": true,
"**/.next": true,
"**/.husky": true,
"**/drizzle": true,
"**/dist": true,
"**/.todo.md": true,
"**/.vscode": true,
"**/.eslintrc.cjs": true,
"**/.editorconfig": true,
"**/.lintstagedrc.mjs": true,
"**/.markdownlint.json": true,
"**/.markdownlintignore": true,
"**/.prettierignore": true,
"**/.svn": true,
"**/.todo.md": true,
"**/bun.lockb": true,
"**/cspell.json": true,
"**/CVS": true,
"**/dist": true,
"**/drizzle": true,
"**/drizzle.config.ts": true,
"**/migrate.ts": true,
"**/next-env.d.ts": true,
"**/node_modules": true,
"**/package-lock.json": true,
"**/pnpm-lock.yaml": true,
"**/next-env.d.ts": true,
"**/postcss.config.cjs": true,
"**/prettier.config.js": true,
"**/README.md": true,
"**/drizzle.config.ts": true,
"**/migrate.ts": true,
"**/.env.example": true
"**/Thumbs.db": true
},

// Misc
Expand Down
41 changes: 40 additions & 1 deletion content/docs/breadcrumb.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ links:
url: https://ui.shadcn.com/docs/components/popover
---

<ComponentPreview name="breadcrumb-example" className="[&_.preview]:p-2" />
<ComponentPreview name="breadcrumb-demo" />

## Installation

Expand Down Expand Up @@ -217,3 +217,42 @@ import { Link } from "next/link";
```

## Examples

### Orientation

<ComponentPreview name="breadcrumb-orientation" />

### BreadCrumb Separator

<ComponentPreview name="breadcrumb-separator" />

### BreadCrumb variants

By default, the Breadcrumb component uses the `default` variant for each item. You can change the variant by passing the `variant` prop to the `BreadcrumbItem` component.

<ComponentPreview name="breadcrumb-variants" />

### BreadCrumb Active Item

You can indicate the active item by passing the `isActive` prop to the `BreadcrumbItem` component.

<ComponentPreview name="breadcrumb-active" />

<Alert className="mt-4" variant="info">
<MdxIcons.Info className="size-4" />
<AlertTitle>Good to know</AlertTitle>
<AlertDescription>
The `variant` prop is the same as the button variants from shadcn, you can check the
button [documentation](https://ui.shadcn.com/docs/components/popover) for more information.
</AlertDescription>
</Alert>

### Active BreadCrumb

<ComponentPreview name="breadcrumb-active" />

### BreadCrumb Popover

This popover can be used to display the full path if it's too long to fit in the screen.

<ComponentPreview name="breadcrumb-popover" />
2 changes: 1 addition & 1 deletion content/docs/carousel.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ links:
<Step>Run the following command:</Step>

```bash
npm embla-carousel embla-carousel-react
npm i embla-carousel embla-carousel-react
```

<Step>Copy and paste the following code into your project.</Step>
Expand Down
14 changes: 14 additions & 0 deletions content/docs/changelog.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title : Changelog
description : All last changes in the project with announcements
---


## March 2024 - New docs

We are happy to announce that we have updated our documentation. We have added new features. We hope you will find it useful. If you have any questions or suggestions, please let us know.





17 changes: 16 additions & 1 deletion content/docs/file-upload.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ links:
url: https://sonner.emilkowal.ski/
---

<ComponentPreview name="file-upload-example" />
<ComponentPreview name="file-upload-demo" />

## Installation

Expand Down Expand Up @@ -208,3 +208,18 @@ import {
</FileUploaderContent>
</FileUploader>
```

## Example


### DropzoneOptions

The `dropzoneOptions` prop is an object that can be passed to the `FileUploader` component to customize the useDropzone hook behavior. You can find the full list of options [here](https://react-dropzone.js.org/#src).

<ComponentPreview name="file-upload-dropzone" />

### Form

This form uses the reSelect prop to remove all the current selected files when new files are selected.

<ComponentPreview name="file-upload-zod" />
4 changes: 2 additions & 2 deletions content/docs/introduction.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Shadcn extension is a set of components that are built on top of Shadcn-ui . It

- **Customizable**: Shadcn extension is designed to be highly customizable. It provides a set of components that can be easily customized to fit your needs.
- **Easy to use**: Shadcn extension is designed to be easy to use. It provides a set of components that are easy to use and can be easily integrated into your web application.
- **No need for installation**: Shadcn extension does not require any installation. just copy past the code and install the shadcn/ui component that it uses.
- **No need for installation**: Shadcn extension does not require any installation. just Copy&Paste the code and install the shadcn/ui component that it uses.

## Getting Started

Expand All @@ -25,7 +25,7 @@ To install shadcn extension, you need to configure the shadcn/ui component that

## Usage

To use Shadcn extension, you need to copy past the components that you want to use from the **shadcn extension** . You can then use these components in your web application.
To use Shadcn extension, you need to Copy&Paste the components that you want to use from the **shadcn extension** . You can then use these components in your web application.

Example:

Expand Down
57 changes: 10 additions & 47 deletions content/docs/tree-view.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -460,50 +460,6 @@ const elements :TreeViewElement[] = [
},
],
},
{
id: "9",
name: "registry",
children: [
{
id: "10",
name: "default",
children: [
{
id: "11",
name: "extension",
children: [
{
id: "12",
name: "tree-view.tsx",
},
{
id: "13",
name: "tree-view-api.tsx",
},
],
},
{
id: "14",
name: "dashboard-tree.tsx",
},
],
},
{
id: "15",
name: "pages",
children: [
{
id: "16",
name: "page.tsx",
},
{
id: "17",
name: "page-guide.tsx",
},
],
},
],
},
{
id: "18",
name: "env.ts",
Expand All @@ -515,10 +471,12 @@ const elements :TreeViewElement[] = [

<Steps>

<Step> First we create the TOC component </Step>
<Step> TOC component </Step>

First we create the TOC component.

```tsx showLineNumbers title="components/Table_of_content/tree.tsx"
import { Tree , TreeViewElement } from "@/components/extension/tree-view-api";
import { Tree , TreeViewElement , CollapseButton } from "@/components/extension/tree-view-api";
import { TreeItem } from "./tree-item.tsx"

type TOCProps = {
Expand All @@ -534,12 +492,17 @@ return (
<TreeItem key={element.id} elements={[element]} />
)
}
<CollapseButton elements={toc} expandAll={true} />
</Tree>
)
}
```

<Step> Then the TreeItem element </Step>
Here we can see that we created a `TOC` component that will be responsible for rendering all the tree , the CollapseButton is used for the expandAll functionality.

<Step> TreeItem component </Step>

Then the TreeItem element.

```tsx showLineNumbers title="components/Table_of_content/tree-item.tsx"
import { File , Folder , TreeViewElement } from "@/components/extension/tree-view-api";
Expand Down
5 changes: 0 additions & 5 deletions contentlayer.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,6 @@ export const Doc = defineDocumentType(() => ({
default: true,
required: false,
},
state: {
type: "enum",
values: ["deprecated", "new", "updated"],
required: false,
},
},
computedFields,
}));
Expand Down
Loading