0.8.3 • Published 1 day ago

@a-type/ui v0.8.3

Weekly downloads
-
License
-
Repository
-
Last release
1 day ago

@a-type/ui

My personal UI component library. This exists mostly to reduce the startup cost of new projects for me and avoid reinventing components I use frequently. It won't be well-documented or approachable for others, but if you're here you're welcome to check out the source.

How to use

Install @a-type/ui unocss

In your uno.config.ts:

import { defineConfig } from 'unocss';
import atype from '@a-type/ui/uno-preset';

export default defineConfig({
	presets: [atype()],
});

The source files of this library include a directive which tells UnoCSS to include them when extracting styles in your app, but for it to work you must exclude @a-type/ui from Vite's optimizeDeps:

// in vite.config.ts config definition
optimizeDeps: {
	exclude: ['@a-type/ui'],
},

Then, styles from library components should be properly added to your CSS.

Alternative: import full compiled CSS

Rather than configuring your build pipeline to include this library's source files, you can opt to import the entire CSS needed to style it from @a-type/ui/css. However, this will be less efficient; when integrating with your build pipeline, components which aren't used won't have CSS included in your final build.

Customizing theme colors

To customize colors, either override the base palettes or the theme colors using CSS custom property declarations in a preflight. Base palettes are used by theme colors to compose 'semantic' colors like "primary."

Base palettes:

// basic color ranges
--palette-red-[00,10,20,30,40,50,60,70,80,90]
--palette-green-[00,10,20,30,40,50,60,70,80,90]
--palette-yellow-[00,10,20,30,40,50,60,70,80,90]
--palette-blue-[00,10,20,30,40,50,60,70,80,90]
--palette-purple-[00,10,20,30,40,50,60,70,80,90]
--palette-gray-[0-9] // sorry

// utility colors
--palette-dark-blend-warm
--palette-dark-blend-cool
--palette-light-blend-warm
--palette-light-blend-cool
--palette-gray-ex-1
--palette-gray-ex-2
--palette-gray-blend
--palette-gray-dark-blend
--palette-light-gray-blend
--palette-light-gray-dark-blend
--palette-overlay
--palette-black
--palette-white
--palette-light
--palette-dark

Theme colors:

--color-primary
--color-primary-light
--color-primary-dark
--color-primary-wash
--color-accent
--color-accent-light
--color-accent-dark
--color-accent-wash
--color-attention
--color-attention-light
--color-attention-dark
--color-gray-[0-9]
--color-light-blend
--color-dark-blend
--color-dark-blend-warm
--color-dark-blend-cool
--color-light-blend-warm
--color-light-blend-cool
--color-light-blend
--color-overlay
--color-black
--color-white
--color-wash
0.8.3

1 day ago

0.8.2

6 days ago

0.8.1

13 days ago

0.8.0

13 days ago

0.7.13

14 days ago

0.7.12

14 days ago

0.7.11

16 days ago

0.7.10

16 days ago

0.7.9

20 days ago

0.7.8

20 days ago

0.7.6

21 days ago

0.7.5

21 days ago

0.7.7

21 days ago

0.7.4

22 days ago

0.7.2

24 days ago

0.7.3

24 days ago

0.7.1

28 days ago

0.6.29

29 days ago

0.6.28

29 days ago

0.6.27

29 days ago

0.7.0

29 days ago

0.6.30

29 days ago

0.6.26

1 month ago

0.6.23

1 month ago

0.6.22

1 month ago

0.6.25

1 month ago

0.6.24

1 month ago

0.6.21

1 month ago

0.6.20

1 month ago

0.6.19

1 month ago

0.6.18

1 month ago

0.6.17

2 months ago

0.6.16

2 months ago

0.6.15

2 months ago

0.6.14

2 months ago

0.6.13

3 months ago

0.6.12

4 months ago

0.6.11

4 months ago

0.6.10

4 months ago

0.6.9

4 months ago

0.6.7

4 months ago

0.6.8

4 months ago

0.6.6

4 months ago

0.6.5

4 months ago

0.5.3

5 months ago

0.6.3

5 months ago

0.6.2

5 months ago

0.6.4

5 months ago

0.6.1

5 months ago

0.6.0

5 months ago

0.5.0

5 months ago

0.5.2

5 months ago

0.5.1

5 months ago

0.4.9

5 months ago

0.4.8

5 months ago

0.4.5

5 months ago

0.4.4

5 months ago

0.4.7

5 months ago

0.4.6

5 months ago

0.4.1

5 months ago

0.4.0

5 months ago

0.4.3

5 months ago

0.4.2

5 months ago

0.3.3

5 months ago

0.3.0

5 months ago

0.3.2

5 months ago

0.3.1

5 months ago

0.2.3

5 months ago

0.2.5

5 months ago

0.2.4

5 months ago

0.2.1

5 months ago

0.2.2

5 months ago

0.2.0

5 months ago

0.1.17

5 months ago

0.1.16

5 months ago

0.1.14

6 months ago

0.1.15

6 months ago

0.1.10

8 months ago

0.1.11

8 months ago

0.1.12

7 months ago

0.1.13

7 months ago

0.1.8

8 months ago

0.1.7

8 months ago

0.1.9

8 months ago

0.1.6

9 months ago

0.1.5

10 months ago

0.1.4

11 months ago

0.1.3

12 months ago

0.1.2

12 months ago

0.1.1

12 months ago

0.1.0

12 months ago