cos-design 3.7.4 → 3.7.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +45 -0
- package/README.md +9 -8
- package/dist/index.cjs +3 -3
- package/dist/index.css +1 -1
- package/dist/index.js +2547 -2349
- package/dist/src/components/aurora/index.d.ts +2 -0
- package/dist/src/components/bubbleField/types.d.ts +2 -0
- package/dist/src/components/confetti/index.d.ts +2 -0
- package/dist/src/components/cyberGrid/index.d.ts +2 -0
- package/dist/src/components/fireworks/index.d.ts +2 -0
- package/dist/src/components/matrixRain/index.d.ts +2 -0
- package/dist/src/components/meteorRain/index.d.ts +2 -0
- package/dist/src/components/particleNetwork/index.d.ts +2 -0
- package/dist/src/components/redPacketRain/index.d.ts +2 -0
- package/dist/src/components/rippleWater/index.d.ts +2 -0
- package/dist/src/components/smokeFog/index.d.ts +2 -0
- package/dist/src/components/snowfall/index.d.ts +2 -0
- package/dist/src/components/starfield/index.d.ts +2 -0
- package/dist/src/components/weatherBackground/types.d.ts +2 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,51 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [Unreleased]
|
|
9
|
+
|
|
10
|
+
## [3.7.6] - 2026-08-26
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- `@cos-design/shared`:新增 `useCanvasBox`(fill 尺寸一站式 hook)
|
|
15
|
+
- 背景组件全面支持 `fill`:`WeatherBackground`、`Aurora`、`Starfield`、`Snowfall`、`MeteorRain`、`CyberGrid`、`SmokeFog`、`BubbleField`、`RippleWater`
|
|
16
|
+
- `Starfield` / `Snowfall` / `MeteorRain` / `CyberGrid` / `Aurora` 接入 `prefers-reduced-motion` 静态降级
|
|
17
|
+
- Playground 配方「全屏氛围 Hero」;Next.js 接入示例 [docs/examples/next-app-router.md](./docs/examples/next-app-router.md)
|
|
18
|
+
|
|
19
|
+
### Changed
|
|
20
|
+
|
|
21
|
+
- AGENTS / Cursor Skill / QUICKSTART 同步扩展 `fill` 组件列表与发现文档入口
|
|
22
|
+
- @cos-design/shared: 3.5.5 → 3.5.6
|
|
23
|
+
- @cos-design/aurora: 3.5.3 → 3.5.4
|
|
24
|
+
- @cos-design/bubble-field: 3.7.0 → 3.7.1
|
|
25
|
+
- @cos-design/cyber-grid: 3.5.3 → 3.5.4
|
|
26
|
+
- @cos-design/meteor-rain: 3.5.3 → 3.5.4
|
|
27
|
+
- @cos-design/ripple-water: 3.5.4 → 3.5.5
|
|
28
|
+
- @cos-design/smoke-fog: 3.5.4 → 3.5.5
|
|
29
|
+
- @cos-design/snowfall: 3.5.3 → 3.5.4
|
|
30
|
+
- @cos-design/starfield: 3.5.3 → 3.5.4
|
|
31
|
+
- @cos-design/weather-background: 3.5.4 → 3.5.5
|
|
32
|
+
- cos-design: 聚合包更新至 3.7.6
|
|
33
|
+
|
|
34
|
+
## [3.7.5] - 2026-08-21
|
|
35
|
+
|
|
36
|
+
### Added
|
|
37
|
+
|
|
38
|
+
- `@cos-design/shared`:新增 `useElementSize` / `resolveCanvasBoxSize`(React peer)
|
|
39
|
+
- Canvas 组件支持 `fill` 铺满父容器:`Fireworks`、`Confetti`、`RedPacketRain`、`MatrixRain`、`ParticleNetwork`
|
|
40
|
+
- Playground 活动配方新增:充电开宝箱、老虎机大奖
|
|
41
|
+
|
|
42
|
+
### Changed
|
|
43
|
+
|
|
44
|
+
- QUICKSTART / README / AGENTS 补充 `fill` 尺寸用法说明
|
|
45
|
+
- @cos-design/shared: 3.5.4 → 3.5.5
|
|
46
|
+
- @cos-design/confetti: 3.5.4 → 3.5.5
|
|
47
|
+
- @cos-design/fireworks: 3.5.4 → 3.5.5
|
|
48
|
+
- @cos-design/matrix-rain: 3.5.3 → 3.5.4
|
|
49
|
+
- @cos-design/particle-network: 3.5.3 → 3.5.4
|
|
50
|
+
- @cos-design/red-packet-rain: 3.5.4 → 3.5.5
|
|
51
|
+
- cos-design: 聚合包更新至 3.7.5
|
|
52
|
+
|
|
8
53
|
## [3.7.4] - 2026-08-10
|
|
9
54
|
|
|
10
55
|
### Added
|
package/README.md
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
[](https://react.dev/)
|
|
12
12
|
[](https://www.typescriptlang.org/)
|
|
13
13
|
|
|
14
|
-
[Playground](https://jiaxiantao.github.io/cos-design/) · [Quickstart](./QUICKSTART.md) · [llms.txt](https://jiaxiantao.github.io/cos-design/llms.txt) · [AI discovery](./docs/ai-discovery.md) · [EN guide](./website-content/cos-design-marketing-effects-en.md) · [中文指南](./website-content/cos-design-intro.md) · [Changelog](./CHANGELOG.md)
|
|
14
|
+
[Playground](https://jiaxiantao.github.io/cos-design/) · [Quickstart](./QUICKSTART.md) · [llms.txt](https://jiaxiantao.github.io/cos-design/llms.txt) · [AI discovery](./docs/ai-discovery.md) · [Next.js example](./docs/examples/next-app-router.md) · [EN guide](./website-content/cos-design-marketing-effects-en.md) · [中文指南](./website-content/cos-design-intro.md) · [Changelog](./CHANGELOG.md)
|
|
15
15
|
|
|
16
16
|
</div>
|
|
17
17
|
|
|
@@ -114,6 +114,7 @@ export default function Page() {
|
|
|
114
114
|
| [llms.txt](https://jiaxiantao.github.io/cos-design/llms.txt) | 供 Agent 抓取的索引(场景 → 组件 → 安装命令) |
|
|
115
115
|
| [llms-full.txt](https://jiaxiantao.github.io/cos-design/llms-full.txt) | 站点上的完整 AI 参考(与 docs/ai.md 同步) |
|
|
116
116
|
| [docs/ai.md](./docs/ai.md) | 84 个组件的完整 AI 参考(安装 / import / 示例 / Props) |
|
|
117
|
+
| [docs/examples/next-app-router.md](./docs/examples/next-app-router.md) | Next.js App Router 接入(SSR + fill) |
|
|
117
118
|
| [docs/ai-discovery.md](./docs/ai-discovery.md) | Context7 提交、Cursor Skill 安装、项目 Rule 片段 |
|
|
118
119
|
| [AGENTS.md](./AGENTS.md) | 仓库级 Agent 规则,可复制到用户项目 |
|
|
119
120
|
| [.cursor/skills/cos-design](./.cursor/skills/cos-design/SKILL.md) | Cursor Skill |
|
|
@@ -141,13 +142,13 @@ Context7: /jiaxiantao/cos-design
|
|
|
141
142
|
|
|
142
143
|
### 使用注意(摘要)
|
|
143
144
|
|
|
144
|
-
| 注意点 | 说明
|
|
145
|
-
| -------- |
|
|
146
|
-
| **SSR** | Canvas 组件需在 Next.js 等框架中 `dynamic(..., { ssr: false })`
|
|
147
|
-
| **尺寸** | Canvas 组件需明确 `width` / `height
|
|
148
|
-
| **密度** | 建议每页「一个强背景 + 若干局部交互」,避免多 Canvas 抢性能
|
|
149
|
-
| **权限** | `AudioVisualizer` 开启麦克风时需 HTTPS 与用户授权
|
|
150
|
-
| **省电** | 标签页隐藏时,多数 Canvas 动画自动暂停
|
|
145
|
+
| 注意点 | 说明 |
|
|
146
|
+
| -------- | -------------------------------------------------------------------- |
|
|
147
|
+
| **SSR** | Canvas 组件需在 Next.js 等框架中 `dynamic(..., { ssr: false })` |
|
|
148
|
+
| **尺寸** | Canvas 组件需明确 `width` / `height`,或设 `fill` 铺满有高度的父容器 |
|
|
149
|
+
| **密度** | 建议每页「一个强背景 + 若干局部交互」,避免多 Canvas 抢性能 |
|
|
150
|
+
| **权限** | `AudioVisualizer` 开启麦克风时需 HTTPS 与用户授权 |
|
|
151
|
+
| **省电** | 标签页隐藏时,多数 Canvas 动画自动暂停 |
|
|
151
152
|
|
|
152
153
|
---
|
|
153
154
|
|