
Security News
The Nightmare Before Deployment
Season’s greetings from Socket, and here’s to a calm end of year: clean dependencies, boring pipelines, no surprises.
miles-wang-vue-components
Advanced tools
A high-quality Vue 3 component library with TypeScript support, built for modern web applications.
npm install miles-wang-vue-components
# or
yarn add miles-wang-vue-components
# or
pnpm add miles-wang-vue-components
// main.js
import { createApp } from 'vue'
import VueComponents from 'miles-wang-vue-components'
import App from './App.vue'
const app = createApp(App)
app.use(VueComponents)
app.mount('#app')
<template>
<TaskCard
title="待分配"
tag="请购单"
:number="5"
unit="张"
icon-type="clipboard"
/>
</template>
<script setup>
import { TaskCard } from 'miles-wang-vue-components'
</script>
<template>
<TaskCard
title="待处理"
tag="审批"
:number="12"
unit="项"
icon-type="task"
:clickable="true"
@click="handleCardClick"
/>
</template>
<script setup>
import { TaskCard } from 'miles-wang-vue-components'
const handleCardClick = (data) => {
console.log('Card clicked:', data)
}
</script>
| Prop | Type | Default | Description |
|---|---|---|---|
title | string | - | Card title (required) |
tag | string | - | Tag text (required) |
number | number | string | - | Number value (required) |
unit | string | - | Unit text (required) |
iconType | IconType | 'clipboard' | Icon type |
clickable | boolean | false | Whether the card is clickable |
customClass | string | '' | Custom CSS class |
clickData | any | undefined | Data passed to click event |
| Event | Description | Parameters |
|---|---|---|
click | Fired when card is clicked | (data?: any) |
| Value | Description | Use Case |
|---|---|---|
clipboard | Clipboard icon | Documents, forms |
shopping-cart | Shopping cart icon | Shopping, purchases |
folder | Folder icon | File management, tasks |
document | Document icon | Files, reports |
calendar | Calendar icon | Schedules, events |
task | Task icon | Todo items, tasks |
<template>
<div class="dashboard">
<div class="card-grid">
<TaskCard
title="待分配"
tag="请购单"
:number="5"
unit="张"
icon-type="clipboard"
:clickable="true"
@click="handlePurchaseClick"
/>
<TaskCard
title="待审核"
tag="采购单"
:number="6"
unit="张"
icon-type="shopping-cart"
:clickable="true"
@click="handleProcurementClick"
/>
<TaskCard
title="日程"
tag="我的任务"
:number="8"
unit="笔"
icon-type="folder"
:clickable="true"
@click="handleTaskClick"
/>
</div>
</div>
</template>
<script setup>
import { TaskCard } from '@miles-wang/task-card'
const handlePurchaseClick = () => {
// Handle purchase click
}
const handleProcurementClick = () => {
// Handle procurement click
}
const handleTaskClick = () => {
// Handle task click
}
</script>
<style scoped>
.dashboard {
padding: 20px;
background: #f7f7fa;
}
.card-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
gap: 20px;
}
</style>
<template>
<div class="icon-showcase">
<TaskCard
title="文档"
tag="文件"
:number="15"
unit="个"
icon-type="document"
/>
<TaskCard
title="日程"
tag="会议"
:number="3"
unit="场"
icon-type="calendar"
/>
<TaskCard
title="任务"
tag="待办"
:number="9"
unit="项"
icon-type="task"
/>
</div>
</template>
<script setup>
import { TaskCard } from '@miles-wang/task-card'
</script>
You can customize the component appearance using CSS variables:
.task-card {
--card-padding: 24px;
--card-radius: 16px;
--card-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
--card-hover-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
}
<style>
:root {
--task-card-primary: #8B5CF6;
--task-card-text-primary: #1F2937;
--task-card-text-secondary: #6B7280;
--task-card-bg-white: #ffffff;
--task-card-bg-gray: #F3F4F6;
}
</style>
# Clone the repository
git clone https://github.com/miles-wang/vue-components.git
cd vue-components
# Install dependencies
npm install
# Start development
npm run dev
# 创建新组件
node scripts/create-component.js Button
# 创建输入框组件
node scripts/create-component.js Input
# 创建模态框组件
node scripts/create-component.js Modal
# Build the library
npm run build
# Type checking
npm run type-check
# Linting
npm run lint
Contributions are welcome! Please feel free to submit a Pull Request.
git checkout -b feature/AmazingFeature)git commit -m 'Add some AmazingFeature')git push origin feature/AmazingFeature)This project is licensed under the MIT License - see the LICENSE file for details.
If you have any questions or need help, please:
Made with ❤️ by Miles Wang
FAQs
A high-quality Vue 3 component library with TypeScript support
The npm package miles-wang-vue-components receives a total of 1 weekly downloads. As such, miles-wang-vue-components popularity was classified as not popular.
We found that miles-wang-vue-components demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Season’s greetings from Socket, and here’s to a calm end of year: clean dependencies, boring pipelines, no surprises.

Research
/Security News
Impostor NuGet package Tracer.Fody.NLog typosquats Tracer.Fody and its author, using homoglyph tricks, and exfiltrates Stratis wallet JSON/passwords to a Russian IP address.

Security News
Deno 2.6 introduces deno audit with a new --socket flag that plugs directly into Socket to bring supply chain security checks into the Deno CLI.