npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@tongziyang/uni-calendar-plugin

v1.0.1

Published

A comprehensive calendar plugin for uniapp with support for Gregorian and Lunar calendars, date selection, hotel booking, check-in functionality, and more.

Downloads

1

Readme

uni-calendar-plugin

一个功能丰富的日历插件,专为uniapp开发,使用Vue3 + Composition API + TypeScript构建。

功能特点

  • 支持公历日历和农历日历显示
  • 支持单选日期和区间日期选择
  • 酒店入住选择功能,可显示价格
  • 打卡功能和往期打卡标记
  • 节假日标记(休息标签)
  • 支持年、月、周、日视图切换
  • 高度自动伸缩适应内容
  • 兼容所有平台(H5、App、微信小程序等)

安装

# 使用npm
npm install uni-calendar-plugin

# 使用yarn
yarn add uni-calendar-plugin

# 使用pnpm
pnpm add uni-calendar-plugin

使用方法

<template>
  <uni-calendar-plugin 
    v-model="selectedDate"
    :mode="mode"
    :show-lunar="showLunar"
    @date-click="handleDateClick"
  />
</template>

<script setup lang="ts">
import { ref } from 'vue';
import UniCalendarPlugin from 'uni-calendar-plugin';

const selectedDate = ref(new Date());
const mode = ref('month'); // 'year', 'month', 'week', 'day'
const showLunar = ref(true);

const handleDateClick = (date: Date) => {
  console.log('Selected date:', date);
};
</script>

配置选项

| 属性 | 类型 | 默认值 | 说明 | | --- | --- | --- | --- | | v-model | Date/[Date, Date] | 当前日期 | 选中的日期,可以是单个日期或日期区间 | | mode | string | 'month' | 显示模式,可选值:'year', 'month', 'week', 'day' | | showLunar | boolean | false | 是否显示农历 | | showHoliday | boolean | true | 是否显示节假日标记 | | showPrice | boolean | false | 是否显示价格(酒店模式下) | | priceData | object | {} | 价格数据,格式为 {日期: 价格} | | checkInData | array | [] | 打卡数据,日期数组 | | rangeMode | boolean | false | 是否开启区间选择模式 |

事件

| 事件名 | 说明 | 参数 | | --- | --- | --- | | date-click | 点击日期时触发 | date: Date | | range-change | 区间变化时触发 | [startDate: Date, endDate: Date] | | month-change | 月份变化时触发 | date: Date | | check-in | 打卡时触发 | date: Date |

插槽

| 插槽名 | 说明 | | --- | --- | | date-cell | 自定义日期单元格内容 | | header | 自定义日历头部 | | footer | 自定义日历底部 |

贡献

欢迎提交问题和功能请求。

许可证

MIT