From 05bad5f45dca018a105590368bc276eace0a41a2 Mon Sep 17 00:00:00 2001 From: carwack Date: Sat, 7 Oct 2023 23:50:02 +0200 Subject: [PATCH 1/5] fix(components): Add missing as prop on some layout components --- @types/components.d.ts | 2 +- components.d.ts | 2 +- packages/layout/examples/base-stack.vue | 2 +- packages/layout/src/container.tsx | 3 ++- packages/layout/src/kbd.tsx | 1 + packages/layout/src/link.tsx | 6 +----- packages/layout/src/stack.tsx | 1 + packages/layout/src/text.tsx | 1 + 8 files changed, 9 insertions(+), 9 deletions(-) diff --git a/@types/components.d.ts b/@types/components.d.ts index 86c53590..31bed42b 100755 --- a/@types/components.d.ts +++ b/@types/components.d.ts @@ -6,7 +6,7 @@ * * This is a generated file. Do not edit it's contents. * - * This file was generated on 2023-05-20T11:19:16.919Z + * This file was generated on 2023-09-11T16:17:50.573Z */ import { ChakraProps, chakra } from "@chakra-ui/vue-system" diff --git a/components.d.ts b/components.d.ts index 86c53590..31bed42b 100755 --- a/components.d.ts +++ b/components.d.ts @@ -6,7 +6,7 @@ * * This is a generated file. Do not edit it's contents. * - * This file was generated on 2023-05-20T11:19:16.919Z + * This file was generated on 2023-09-11T16:17:50.573Z */ import { ChakraProps, chakra } from "@chakra-ui/vue-system" diff --git a/packages/layout/examples/base-stack.vue b/packages/layout/examples/base-stack.vue index 65811349..c5213c0d 100644 --- a/packages/layout/examples/base-stack.vue +++ b/packages/layout/examples/base-stack.vue @@ -20,7 +20,7 @@ Vertical - + 1 2 3 diff --git a/packages/layout/src/container.tsx b/packages/layout/src/container.tsx index 0d4157ab..68333fa1 100644 --- a/packages/layout/src/container.tsx +++ b/packages/layout/src/container.tsx @@ -12,7 +12,7 @@ import type * as CSS from "csstype" export interface ContainerProps extends HTMLChakraProps<"div">, - ThemingProps<"Container"> { + ThemingProps<"Container"> { /** * If `true`, container will center its children * regardless of their width. @@ -54,6 +54,7 @@ export const CContainer = defineComponent({ return () => ( ( diff --git a/packages/layout/src/link.tsx b/packages/layout/src/link.tsx index aabca8ec..72004f9a 100644 --- a/packages/layout/src/link.tsx +++ b/packages/layout/src/link.tsx @@ -1,11 +1,7 @@ import { vueThemingProps } from "@chakra-ui/vue-utils" import { HTMLChakraProps } from "@chakra-ui/vue-system" import { h, defineComponent, PropType, computed } from "vue" -import { - chakra, - DOMElements, - useStyleConfig, -} from "@chakra-ui/vue-system" +import { chakra, DOMElements, useStyleConfig } from "@chakra-ui/vue-system" import { ThemingProps } from "@chakra-ui/styled-system" import { filterUndefined } from "@chakra-ui/utils" import type * as CSS from "csstype" diff --git a/packages/layout/src/stack.tsx b/packages/layout/src/stack.tsx index fe2b68f1..1afcd8aa 100644 --- a/packages/layout/src/stack.tsx +++ b/packages/layout/src/stack.tsx @@ -180,6 +180,7 @@ export const CStack = defineComponent({ return ( { return ( Date: Sat, 7 Oct 2023 23:54:59 +0200 Subject: [PATCH 2/5] fix(components): Add example for as prop --- packages/layout/examples/base-stack.vue | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/packages/layout/examples/base-stack.vue b/packages/layout/examples/base-stack.vue index c5213c0d..e4d1f564 100644 --- a/packages/layout/examples/base-stack.vue +++ b/packages/layout/examples/base-stack.vue @@ -2,33 +2,43 @@ Stack Default - + 1 2 3 - + Horizontal - + 1 2 3 - + Vertical - + 1 2 3 - + + + + + As prop UL + + 1 + 2 + 3 + + diff --git a/packages/layout/examples/base-stack.vue b/packages/layout/examples/base-stack.vue index e4d1f564..158cefb4 100644 --- a/packages/layout/examples/base-stack.vue +++ b/packages/layout/examples/base-stack.vue @@ -39,7 +39,6 @@ - diff --git a/packages/layout/examples/base-text.vue b/packages/layout/examples/base-text.vue index 744e5309..74a1509d 100644 --- a/packages/layout/examples/base-text.vue +++ b/packages/layout/examples/base-text.vue @@ -1,27 +1,30 @@ From 2bfa6291e063a6a264b82a4910682e1f987f1210 Mon Sep 17 00:00:00 2001 From: Sybren W Date: Sun, 8 Oct 2023 00:07:27 +0200 Subject: [PATCH 4/5] Create lemon-toes-end.md --- .changeset/lemon-toes-end.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/lemon-toes-end.md diff --git a/.changeset/lemon-toes-end.md b/.changeset/lemon-toes-end.md new file mode 100644 index 00000000..6c0ecb35 --- /dev/null +++ b/.changeset/lemon-toes-end.md @@ -0,0 +1,5 @@ +--- +"@chakra-ui/vue-layout": patch +--- + +fix(components): Add missing `as` prop on some layout components From 8c7d7ef54ed7fb77c1e733f7ab413a40baa29224 Mon Sep 17 00:00:00 2001 From: carwack Date: Mon, 9 Oct 2023 21:18:58 +0200 Subject: [PATCH 5/5] fix(components): Change default as prop of kbd to kdb from h2 --- packages/layout/src/kbd.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/layout/src/kbd.tsx b/packages/layout/src/kbd.tsx index 0f567463..746073f4 100644 --- a/packages/layout/src/kbd.tsx +++ b/packages/layout/src/kbd.tsx @@ -29,7 +29,7 @@ export const CKbd = defineComponent({ props: { as: { type: [String, Object] as PropType, - default: "h2", + default: "kbd", }, ...vueThemingProps, },