Skip to content

Commit ca7f6f8

Browse files
committed
chore: fix README logo path and update package references
- Fix logo src from site/ to apps/docs/ to match current monorepo structure - Update all npm badge and install references from tiny-design to @tiny-design/react - Update component counts and categories to reflect current state - Add Packages table with @tiny-design/react and @tiny-design/tokens - Update theming docs to use @use with @tiny-design/tokens
1 parent 2378f8d commit ca7f6f8

2 files changed

Lines changed: 48 additions & 28 deletions

File tree

README.md

Lines changed: 36 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,69 +1,79 @@
11
<p align="center">
22
<a href="https://tiny-design.dev">
3-
<img width="200" src="https://github.com/wangdicoder/tiny-design/blob/master/site/src/assets/logo/logo.svg">
3+
<img width="200" src="https://github.com/wangdicoder/tiny-design/blob/master/apps/docs/src/assets/logo/logo.svg">
44
</a>
55
</p>
66

7-
<h1 align="center">Tiny UI</h1>
7+
<h1 align="center">Tiny Design</h1>
88
<p align="center">A friendly UI component set for React</p>
99

1010
<p align="center">
11-
<a href="https://www.npmjs.com/package/tiny-design">
12-
<img src="https://img.shields.io/npm/v/tiny-design.svg?style=flat-square" alt="npm version"/>
11+
<a href="https://www.npmjs.com/package/@tiny-design/react">
12+
<img src="https://img.shields.io/npm/v/@tiny-design/react.svg?style=flat-square" alt="npm version"/>
1313
</a>
14-
<a href="https://www.npmjs.com/package/tiny-design">
15-
<img src="https://img.shields.io/npm/dm/tiny-design.svg?style=flat-square" alt="npm downloads"/>
14+
<a href="https://www.npmjs.com/package/@tiny-design/react">
15+
<img src="https://img.shields.io/npm/dm/@tiny-design/react.svg?style=flat-square" alt="npm downloads"/>
1616
</a>
17-
<a href="https://bundlephobia.com/package/tiny-design">
18-
<img src="https://img.shields.io/bundlephobia/minzip/tiny-design.svg?style=flat-square" alt="bundle size"/>
17+
<a href="https://bundlephobia.com/package/@tiny-design/react">
18+
<img src="https://img.shields.io/bundlephobia/minzip/@tiny-design/react.svg?style=flat-square" alt="bundle size"/>
1919
</a>
2020
<a href="https://react.dev">
2121
<img src="https://img.shields.io/static/v1?label=react&message=%3E=18&color=61dafb&style=flat-square" alt="react version"/>
2222
</a>
2323
<a href="https://github.com/wangdicoder/tiny-design/blob/master/LICENSE">
24-
<img src="https://img.shields.io/npm/l/tiny-design.svg?style=flat-square" alt="license"/>
24+
<img src="https://img.shields.io/npm/l/@tiny-design/react.svg?style=flat-square" alt="license"/>
2525
</a>
2626
</p>
2727

2828
---
2929

3030
## Features
3131

32-
- 65+ high-quality React components
32+
- 80+ high-quality React components
3333
- Written in **TypeScript** with complete type definitions
3434
- Entirely built with function components and **React Hooks**
3535
- **Dark mode** support with system preference detection
3636
- **i18n** built-in — English and Chinese out of the box
3737
- Follows [WAI-ARIA](https://www.w3.org/WAI/standards-guidelines/aria/) accessibility standards
38-
- Customisable themes via SCSS variables
38+
- Customisable themes via design tokens and SCSS variables
3939
- Supports tree-shaking for minimal bundle size
4040

41+
## Packages
42+
43+
| Package | Description |
44+
| ------- | ----------- |
45+
| [@tiny-design/react](./packages/react) | Core component library |
46+
| [@tiny-design/tokens](./packages/tokens) | Design tokens and foundational styles |
47+
4148
## Component Categories
4249

4350
| Category | Components | Examples |
4451
| -------- | :--------: | -------- |
4552
| Foundation | 5 | Button, Icon, Image, Link, Typography |
46-
| Layout | 6 | Grid, Space, Split, Divider, Aspect Ratio |
47-
| Navigation | 5 | Menu, Breadcrumb, Dropdown, Pagination, Steps |
48-
| Data Display | 15 | Card, Carousel, Collapse, Tag, Tooltip, Tree |
49-
| Form | 17 | Input, Select, DatePicker, TimePicker, Checkbox, Radio, Slider |
50-
| Feedback | 12 | Modal, Drawer, Message, Notification, Alert, Skeleton |
51-
| Miscellany | 5 | ConfigProvider, BackTop, Sticky, Keyboard |
53+
| Layout | 7 | Grid, Flex, Space, Split, Divider, Aspect Ratio |
54+
| Navigation | 7 | Menu, Breadcrumb, Dropdown, Pagination, Steps, Anchor, SpeedDial |
55+
| Data Display | 19 | Card, Carousel, Collapse, Tag, Tooltip, Tree, Table |
56+
| Form | 22 | Input, Select, DatePicker, TimePicker, Checkbox, Radio, Slider |
57+
| Feedback | 13 | Modal, Drawer, Overlay, Message, Notification, Alert, Skeleton |
58+
| Miscellany | 5 | ConfigProvider, BackTop, Sticky, Keyboard, CopyToClipboard |
5259

5360
## Install
5461

5562
```bash
5663
# npm
57-
npm install tiny-design
64+
npm install @tiny-design/react
5865

5966
# yarn
60-
yarn add tiny-design
67+
yarn add @tiny-design/react
68+
69+
# pnpm
70+
pnpm add @tiny-design/react
6171
```
6272

6373
## Quick Start
6474

6575
```jsx
66-
import { Button, Switch } from 'tiny-design';
76+
import { Button, Switch } from '@tiny-design/react';
6777

6878
const App = () => (
6979
<>
@@ -80,7 +90,7 @@ Styles are automatically imported alongside each component — no separate CSS i
8090
### Dark mode
8191

8292
```jsx
83-
import { ConfigProvider } from 'tiny-design';
93+
import { ConfigProvider } from '@tiny-design/react';
8494

8595
<ConfigProvider theme="dark">
8696
<App />
@@ -92,9 +102,10 @@ import { ConfigProvider } from 'tiny-design';
92102
Override SCSS variables to customise colours, borders, fonts, and more:
93103

94104
```scss
95-
$primary-color: #007bff;
96-
$font-path: '~tiny-design/themes/fonts';
97-
@import '~tiny-design/themes/index.scss';
105+
@use '@tiny-design/tokens/scss/variables' with (
106+
$primary-color: #007bff
107+
);
108+
@use '@tiny-design/tokens/scss/base';
98109
```
99110

100111
See the [Theme Customisation Guide](https://tiny-design.dev/guide/customise-theme) for details.
@@ -104,7 +115,7 @@ See the [Theme Customisation Guide](https://tiny-design.dev/guide/customise-them
104115
Built-in locale support for English and Chinese. Set locale via `ConfigProvider` or `IntlProvider`:
105116

106117
```jsx
107-
import { ConfigProvider, zh_CN } from 'tiny-design';
118+
import { ConfigProvider, zh_CN } from '@tiny-design/react';
108119

109120
<ConfigProvider locale={zh_CN}>
110121
<App />

packages/tokens/css/base.css

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -800,6 +800,7 @@ html[data-tiny-theme=dark] {
800800
--ty-calendar-hover: #2a2a2a;
801801
}
802802
}
803+
/* stylelint-disable scss/comment-no-empty */
803804
/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */
804805
/**
805806
* 1. Correct the line height in all browsers.
@@ -808,7 +809,9 @@ html[data-tiny-theme=dark] {
808809
html {
809810
font-size: 14px;
810811
line-height: 1.15; /* 1 */
811-
-webkit-text-size-adjust: 100%; /* 2 */
812+
-webkit-text-size-adjust: 100%;
813+
-moz-text-size-adjust: 100%;
814+
text-size-adjust: 100%; /* 2 */
812815
}
813816

814817
/* Sections
@@ -1000,6 +1003,8 @@ button,
10001003
[type=reset],
10011004
[type=submit] {
10021005
-webkit-appearance: button;
1006+
-moz-appearance: button;
1007+
appearance: button;
10031008
}
10041009

10051010
/**
@@ -1082,7 +1087,9 @@ textarea {
10821087
* 2. Correct the outline style in Safari.
10831088
*/
10841089
[type=search] {
1085-
-webkit-appearance: textfield; /* 1 */
1090+
-webkit-appearance: textfield;
1091+
-moz-appearance: textfield;
1092+
appearance: textfield; /* 1 */
10861093
outline-offset: -2px; /* 2 */
10871094
}
10881095

@@ -1091,14 +1098,16 @@ textarea {
10911098
*/
10921099
[type=search]::-webkit-search-decoration {
10931100
-webkit-appearance: none;
1101+
appearance: none;
10941102
}
10951103

10961104
/**
10971105
* 1. Correct the inability to style clickable types in iOS and Safari.
10981106
* 2. Change font properties to `inherit` in Safari.
10991107
*/
11001108
::-webkit-file-upload-button {
1101-
-webkit-appearance: button; /* 1 */
1109+
-webkit-appearance: button;
1110+
appearance: button; /* 1 */
11021111
font: inherit; /* 2 */
11031112
}
11041113

0 commit comments

Comments
 (0)