From 0e3b18c80b67687300fcd50ffa6930029cb757b9 Mon Sep 17 00:00:00 2001 From: Nicolas Merget <104347736+nmerget@users.noreply.github.com> Date: Wed, 10 Apr 2024 19:11:13 +0200 Subject: [PATCH] Docs merge accordion and accordion item docs (#2482) * docs: removes accordion item route from pattern hub * feat: adds merged variants to default component * docs: try to merge docs * docs: merge accordion and accordion item overview * chore: moved properties for accordion-item into accordion fix: typescript issues with react --------- Co-authored-by: brunoschadeck --- .../src/components/accordion/docs/Angular.md | 4 +- .../src/components/accordion/docs/React.md | 2 +- .../src/components/accordion/docs/Vue.md | 2 +- showcases/patternhub/components/index.tsx | 103 +++++++++++++----- showcases/patternhub/data/routes.ts | 15 ++- .../patternhub/scripts/get-code-files.js | 3 +- .../src/components/accordion-item/index.tsx | 6 +- .../src/components/accordion/index.tsx | 17 ++- showcases/shared/default-component-data.ts | 6 + 9 files changed, 112 insertions(+), 46 deletions(-) diff --git a/packages/components/src/components/accordion/docs/Angular.md b/packages/components/src/components/accordion/docs/Angular.md index 80fab4c8a58..c06e029be22 100644 --- a/packages/components/src/components/accordion/docs/Angular.md +++ b/packages/components/src/components/accordion/docs/Angular.md @@ -6,12 +6,12 @@ For general installation and configuration look at the [ngx-components](https:// ```ts app.component.ts // app.component.ts -import { DBAccordion } from '@db-ui/ngx-components'; +import { DBAccordion, DBAccordionItem } from '@db-ui/ngx-components'; @Component({ // ... standalone: true, - imports: [..., DBAccordion], + imports: [..., DBAccordion, DBAccordionItem], // ... }) ``` diff --git a/packages/components/src/components/accordion/docs/React.md b/packages/components/src/components/accordion/docs/React.md index 270eb705e06..081317a348c 100644 --- a/packages/components/src/components/accordion/docs/React.md +++ b/packages/components/src/components/accordion/docs/React.md @@ -6,7 +6,7 @@ For general installation and configuration look at the [react-components](https: ```tsx App.tsx // App.tsx -import { DBAccordion } from "@db-ui/react-components"; +import { DBAccordion, DBAccordionItem } from "@db-ui/react-components"; const App = () => ( diff --git a/packages/components/src/components/accordion/docs/Vue.md b/packages/components/src/components/accordion/docs/Vue.md index b0419cd22fb..64149be8e82 100644 --- a/packages/components/src/components/accordion/docs/Vue.md +++ b/packages/components/src/components/accordion/docs/Vue.md @@ -7,7 +7,7 @@ For general installation and configuration look at the [v-components](https://ww ```vue App.vue