diff --git a/components/content/examples/center/IconCenter.vue b/components/content/examples/center/IconCenter.vue new file mode 100644 index 0000000..a62a0e2 --- /dev/null +++ b/components/content/examples/center/IconCenter.vue @@ -0,0 +1,13 @@ + + diff --git a/components/content/examples/center/SimpleCenter.vue b/components/content/examples/center/SimpleCenter.vue new file mode 100644 index 0000000..1547b66 --- /dev/null +++ b/components/content/examples/center/SimpleCenter.vue @@ -0,0 +1,5 @@ + diff --git a/components/content/examples/center/SquareAndCircle.vue b/components/content/examples/center/SquareAndCircle.vue new file mode 100644 index 0000000..73216c1 --- /dev/null +++ b/components/content/examples/center/SquareAndCircle.vue @@ -0,0 +1,10 @@ + \ No newline at end of file diff --git a/content/4.components/center.md b/content/4.components/center.md new file mode 100644 index 0000000..3044dbf --- /dev/null +++ b/content/4.components/center.md @@ -0,0 +1,76 @@ +--- +title: Center +description: Center Component +version: 2.0+ +--- + +# Center + +Center is a layout component that centers its child within itself. + +## Import + +```js +import { CCenter, CCircle, CSquare } from '@chakra-ui/vue-next'; +``` + +- CCenter: centers its child given `width` and `height` +- CSquare: centers its child given `size` (width and height) +- CCircle: a Square with round `border-radius` + +## Usage + +Put any child element inside it, give it any `width` or/and `height`, it'll ensure the child is centered. + +::showcase + ::simple-center{width=full} + :: +:: + +```html + + This is the Center + +``` + +## With Icons + +CCenter can be used to create frames around icons or numbers. + +::showcase +::icon-center +:: +:: + +```html + + + + + + + 1 + + + +``` + +## Square and Circle + +The Square and Circle components automatically centers its children given the size. + +::showcase +::square-and-circle +:: +:: + +```html + + + + + + + + + ``` diff --git a/content/4.components/checkbox.md b/content/4.components/checkbox.md index aadc11d..d1e7326 100644 --- a/content/4.components/checkbox.md +++ b/content/4.components/checkbox.md @@ -1,8 +1,6 @@ --- title: Checkbox -description: - Checkbox component is used in forms when a user needs to select multiple - values from several options. +description: Checkbox Component version: 2.0+ --- @@ -13,7 +11,7 @@ Checkbox component is used in forms when a user needs to select multiple values ## Import ```js -import { CCheckbox, CCheckboxGroup } from '@chakra-ui/vue' +import { CCheckbox, CCheckboxGroup } from '@chakra-ui/vue-next'; ``` ## Usage