@chakra-ui/vue
TypeScript icon, indicating that this package has built-in type declarations

0.13.1 • Public • Published

Build & Test Components Netlify Status All contributors

chakra-ui symbol

Build scalable and accessible Vue.js applications with ease.

@chakra-ui/vue gives you a set of accessible and composable Vue components that you can use to build your favourite applications and sites.

Made for Vue 2.X

Looking for the documentation?

Head over here => https://vue.chakra-ui.com

中文文档翻译Github问题

Features

  • Ease of Styling: Chakra UI contains a set of layout components like CBox, CFlex and CStack that make it easy to style your components by passing props. Learn more
  • Flexible & composable: Chakra UI components are built on top of a Vue UI Primitive for endless composability.
  • Accessible. Chakra UI components follows the WAI-ARIA guidelines specifications and have the right aria-* attributes.
  • Dark Mode 😍: Most components in Chakra UI are dark mode compatible.

Table of Contents

  1. Installation
  2. Usage a. With Nuxt

Installation

yarn add @chakra-ui/vue emotion

or

npm install @chakra-ui/vue emotion

Note: If you're using Nuxt, you need to install @nuxtjs/emotion package as well to server-side render your styles.

yarn add @chakra-ui/vue emotion @nuxtjs/emotion

Usage

1. Import the Chakra UI plugin in your main.js file.

import Vue from 'vue'
import Chakra from '@chakra-ui/vue'
import App from './App.vue'

Vue.use(Chakra)

new Vue({
  el: '#app',
  render: (h) => h(App)
}).$mount()

2. Wrap your application inside the Chakra CThemeProvider. We also recommend that you include the CReset component to normalize all browser styling.

In your App.vue file.

<template>
  <CThemeProvider>
    <CReset />

    <!--
      Your application code goes here! 😁
    -->
  </CThemeProvider>
</template>

<script>
  import { CThemeProvider, CReset } from '@chakra-ui/vue'

  export default {
    name: 'App',
    components: {
      CThemeProvider,
      CReset
    }
  }
</script>

If you'd like to toggle your app between dark and light mode, you can also wrap your application inside the ColorModeProvider component.

3. Hurray!🎉 Now the fun can begin. You can start using components like so:

<template>
  <CThemeProvider>
    <CReset />

    <!--
      Your application code goes here! 😁
    -->
    <CButton variantColor="blue">
      Chakra consumed ⚡️
    </CButton>
  </CThemeProvider>
</template>

<script>
  import { CThemeProvider, CReset, CButton } from '@chakra-ui/vue'

  export default {
    name: 'App',
    components: {
      CThemeProvider,
      CReset,
      CButton
    }
  }
</script>

Codesandbox starters

Storybook Components

You can also view all developed components in Storybook!

Development for Contributing:

Interested in contributing? See our open issues! Remember to take a look at our CONTRIBUTORS guide.

yarn install
yarn bootstrap
yarn dev

Related

Created by Jonathan Bakebwa

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
0.10.2-next.00next
0.13.185latest

Version History

VersionDownloads (Last 7 Days)Published
0.13.185
0.13.03
0.12.010
0.11.00
0.10.21,156
0.10.2-next.00
0.10.10
0.9.416
0.9.30
0.9.20
0.9.11
0.9.09
0.8.11
0.8.02
0.7.40
0.7.5-next.00
0.7.30
0.7.20
0.7.2-next.00
0.7.10
0.7.00
0.7.0-next.20
0.7.0-next.00
0.6.63
0.6.50
0.6.40
0.6.30
0.6.20
0.6.2-next.00
0.6.10
0.6.00
0.5.110
0.5.100
0.5.10-next.10
0.5.10-next.00
0.5.90
0.5.80
0.5.6-next.00
0.5.70
0.5.60
0.5.50
0.5.40
0.5.30
0.5.20
0.5.10
0.5.00
0.4.20
0.4.10
0.4.00
0.3.130
0.3.120
0.3.110
0.3.100
0.3.90
0.3.80
0.3.71
0.3.60
0.3.40
0.3.30
0.3.10
0.2.60
0.2.50
0.2.40
0.2.20
0.2.10

Package Sidebar

Install

npm i @chakra-ui/vue

Weekly Downloads

1,064

Version

0.13.1

License

MIT

Unpacked Size

2.72 MB

Total Files

571

Last publish

Collaborators

  • segunadebayo