@sellmate/design-system-vue
v1.0.22
Published
Design System - Vue Component Wrappers
Readme
Sellmate Design System - Vue
Vue 3 component wrappers for Sellmate Design System built with Stencil web components.
📦 Installation
npm install @sellmate/design-system-vueor
yarn add @sellmate/design-system-vue🛠 Setup
Vue 3
import '@sellmate/design-system/styles.css';
import { createApp } from 'vue';
import { StencilVuePlugin } from '@sellmate/design-system-vue';
import App from './App.vue';
const app = createApp(App);
app.use(StencilVuePlugin);
app.mount('#app');Import @sellmate/design-system/styles.css once at app entry so global token CSS variables are available for components like sd-button.
Vite Configuration
If you are using Vite, you need to configure vite-plugin-static-copy to serve the design system assets (icons, lazy-loaded components) correctly.
- Install
vite-plugin-static-copy:
npm install -D vite-plugin-static-copyor
yarn add -D vite-plugin-static-copy- Update
vite.config.ts:
import { defineConfig } from 'vite';
import { viteStaticCopy } from 'vite-plugin-static-copy';
export default defineConfig({
plugins: [
viteStaticCopy({
targets: [
{
src: 'node_modules/@sellmate/design-system/dist/esm/*',
dest: 'assets',
},
],
}),
],
});🚀 Quick Start
Basic Component Usage
<template>
<div>
<SdButton @click="handleClick"> Click me </SdButton>
</div>
</template>
<script setup lang="ts">
import { SdButton } from '@sellmate/design-system-vue';
const handleClick = () => {
console.log('Button clicked');
};
</script>📚 Available Components
SdButton- Button componentSdInput- Input componentSdCheckbox- Checkbox componentSdSelect- Select dropdown componentSdTable- Table componentSdTag- Tag componentSdIcon- Icon componentSdTooltip- Tooltip componentSdPopover- Popover componentSdDatePicker- Date picker componentSdDateRangePicker- Date range picker componentSdPagination- Pagination component
📋 Requirements
- Vue 3.0.0 or higher
- @sellmate/design-system (peer dependency)
📝 License
MIT
