@candy.thieves/ui-kit-lumos 0.0.8 → 0.0.10

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.
Files changed (78) hide show
  1. package/README.md +87 -94
  2. package/dist/favicon-dark-108.svg +1 -0
  3. package/dist/favicon-dark-16.svg +4 -0
  4. package/dist/favicon-dark-24.svg +4 -0
  5. package/dist/favicon-dark-48.svg +4 -0
  6. package/dist/favicon-dark-72.svg +1 -0
  7. package/dist/favicon-light-108.svg +4 -0
  8. package/dist/favicon-light-16.svg +1 -0
  9. package/dist/favicon-light-24.svg +4 -0
  10. package/dist/favicon-light-48.svg +1 -0
  11. package/dist/favicon-light-72.svg +1 -0
  12. package/dist/index.css +1 -1
  13. package/dist/index.js +2082 -1114
  14. package/dist/index.js.map +1 -1
  15. package/dist/types/assets/icons/ErrorIcon.d.ts +3 -0
  16. package/dist/types/assets/icons/FileIcon.d.ts +3 -0
  17. package/dist/types/assets/icons/Sending.d.ts +3 -0
  18. package/dist/types/assets/index.d.ts +4 -0
  19. package/dist/types/assets/logo/Logo.d.ts +10 -0
  20. package/dist/types/components/AudioPlayer/AudioPlayer.d.ts +6 -0
  21. package/dist/types/components/AudioPlayer/index.d.ts +1 -0
  22. package/dist/types/components/Avatar/Avatar.d.ts +17 -0
  23. package/dist/types/components/Avatar/AvatarBlock.d.ts +15 -0
  24. package/dist/types/components/Avatar/MainAvatar.d.ts +20 -0
  25. package/dist/types/components/Avatar/index.d.ts +3 -0
  26. package/dist/types/components/Button/Button.d.ts +19 -0
  27. package/dist/types/components/Button/ButtonLegacy.d.ts +41 -0
  28. package/dist/types/components/Button/index.d.ts +2 -0
  29. package/dist/types/components/Cards/Cards.d.ts +7 -0
  30. package/dist/types/components/Cards/index.d.ts +1 -0
  31. package/dist/types/components/Checkbox/FormCheckbox.d.ts +1 -2
  32. package/dist/types/components/Checkbox/index.d.ts +2 -2
  33. package/dist/types/components/CircularProgress/CircularProgress.d.ts +10 -0
  34. package/dist/types/components/CircularProgress/index.d.ts +1 -0
  35. package/dist/types/components/Input/FormInput.d.ts +1 -2
  36. package/dist/types/components/Input/index.d.ts +2 -2
  37. package/dist/types/components/LinearProgress/LinearProgress.d.ts +14 -0
  38. package/dist/types/components/LinearProgress/index.d.ts +1 -0
  39. package/dist/types/components/Message/AttachmentItem.d.ts +2 -0
  40. package/dist/types/components/Message/Message.d.ts +2 -0
  41. package/dist/types/components/Message/MessageStatus.d.ts +2 -0
  42. package/dist/types/components/Message/ReplyPreview.d.ts +2 -0
  43. package/dist/types/components/Message/index.d.ts +2 -0
  44. package/dist/types/components/Message/types.d.ts +40 -0
  45. package/dist/types/components/PasswordInput/FormPasswordInput.d.ts +2 -3
  46. package/dist/types/components/PasswordInput/PasswordInput.d.ts +2 -1
  47. package/dist/types/components/PasswordInput/index.d.ts +2 -2
  48. package/dist/types/components/ReadMore/ReadMore.d.ts +8 -0
  49. package/dist/types/components/ReadMore/index.d.ts +1 -0
  50. package/dist/types/components/SearchInput/SearchInput.d.ts +1 -1
  51. package/dist/types/components/SearchInput/index.d.ts +1 -1
  52. package/dist/types/components/Select/Select.d.ts +66 -0
  53. package/dist/types/components/Select/index.d.ts +1 -0
  54. package/dist/types/components/Table/Table.d.ts +6 -0
  55. package/dist/types/components/Table/index.d.ts +1 -0
  56. package/dist/types/components/Tabs/Tabs.d.ts +18 -0
  57. package/dist/types/components/Tabs/index.d.ts +1 -0
  58. package/dist/types/components/Tooltip/Tooltip.d.ts +12 -0
  59. package/dist/types/components/Tooltip/index.d.ts +1 -0
  60. package/dist/types/components/Typography/Typography.d.ts +4 -5
  61. package/dist/types/components/index.d.ts +18 -3
  62. package/dist/types/constants/constants.d.ts +3 -0
  63. package/dist/types/constants/index.d.ts +1 -0
  64. package/dist/types/demo/index.d.ts +1 -0
  65. package/dist/types/index.d.ts +1 -0
  66. package/dist/types/types/index.d.ts +1 -0
  67. package/dist/types/types/types.d.ts +4 -0
  68. package/dist/types/utils/formatTime.d.ts +1 -0
  69. package/dist/types/utils/getFirstLetterCapitalized.d.ts +1 -0
  70. package/dist/types/utils/index.d.ts +5 -0
  71. package/dist/types/utils/isAudioAttachment.d.ts +2 -0
  72. package/dist/types/utils/isThemeColor.d.ts +2 -0
  73. package/dist/types/utils/truncateText.d.ts +1 -0
  74. package/package.json +5 -1
  75. package/dist/favicon.svg +0 -1
  76. package/dist/icons.svg +0 -24
  77. package/dist/types/components/TestMixins/index.d.ts +0 -1
  78. /package/dist/types/{components → demo}/TestMixins/TestMixins.d.ts +0 -0
package/README.md CHANGED
@@ -1,141 +1,134 @@
1
-
2
- # Lumos UI Kit
1
+ # Lumos UI-kit
3
2
 
4
3
  🎨 **Component library for **Lumos app** — a unified design system and interface elements.**
5
4
 
6
5
  **📖 Description:**
7
6
  UI Kit is a centralized library of reusable components created to ensure interface consistency across the **Lumos app** ecosystem.
8
7
 
9
- The project is built on *React* and *TypeScript*, using *Storybook* for component documentation and visual testing. Build is optimized with *Vite*.
8
+ The project is built on _React_ and _TypeScript_, using _Storybook_ for component documentation and visual testing. Build is optimized with _Vite_.
10
9
 
11
10
  👥 Team:
12
11
 
13
- **PM** - *Yana Korotenko*
12
+ **PM** - _Yana Korotenko_
14
13
 
15
- **Team-lead** - *Vladislav Kravchenko*
14
+ **Team-lead** - _Vladislav Kravchenko_
16
15
 
17
16
  **Front-end:**
18
- * [Vikastgn](https://github.com/Vikastgn) - Viktoriya Stognieva (**Main**)
19
- * [Intrstng](https://github.com/intrstng) - Andrei Babich
20
- * [hoakiin](https://github.com/hoakiin) - Ekaterina Olesik
21
- * [VladSkij](https://github.com/VladSkij) - Vladislav Skalskij
22
- * [tymanskaya](https://github.com/tymanskaya) - Ekaterina Tymanskaya
23
-
24
- ## 🌐 Deploy
25
17
 
26
- * [Deploy link](https://vercel.com/)
27
-
28
- ## 🔗 Related Projects
29
- [Lumos app](https://github.com/candysthieves/lumos-ui-kit) — main application using the UI Kit
30
-
31
- [Figma Design](https://www.figma.com/design/UehOuThHVruUR8jcC22FXS/Inctagram?m=auto&t=DixPh2DJFl4iZtwB-6) — mockups and design system
18
+ - [Vikastgn](https://github.com/Vikastgn) - Viktoriya Stognieva (**Main**)
19
+ - [Intrstng](https://github.com/intrstng) - Andrei Babich
20
+ - [hoakiin](https://github.com/hoakiin) - Ekaterina Olesik
21
+ - [VladSkij](https://github.com/VladSkij) - Vladislav Skalskij
22
+ - [tymanskaya](https://github.com/tymanskaya) - Ekaterina Tymanskaya
32
23
 
33
- ## 🚀Getting Started locally
24
+ ## 🔄 Deploy
34
25
 
35
- Follow these steps to run the application locally:
26
+ - [UI-kit Storybook deploy link](https://lumos-ui-kit-storybook.vercel.app/)
36
27
 
37
- 1. **Clone the repository:**
38
-
39
- ```bash
40
- git clone https://github.com/candysthieves/lumos-ui-kit.git
41
- ```
42
-
43
- 2. **Navigate to the project directory:**
44
-
45
- ```bash
46
- cd lumos-ui-kit
47
- ```
28
+ ## 🔗 Related Projects
48
29
 
49
- 3. **Switch to the `develop` branch:**
30
+ [UI-kit Lumos npm-package](https://www.npmjs.com/package/@candy.thieves/ui-kit-lumos) — a UI component library (UI-kit) for the Lumos application
50
31
 
51
- ```bash
52
- git checkout develop
53
- ```
32
+ [Lumos app](https://github.com/candysthieves/lumos-ui-kit) — main application using the UI Kit
54
33
 
55
- 4. **Install dependencies:**
34
+ [Figma Design](https://www.figma.com/design/UehOuThHVruUR8jcC22FXS/Inctagram?m=auto&t=DixPh2DJFl4iZtwB-6) — mockups and design system
56
35
 
57
- ```bash
58
- pnpm install
59
- ```
36
+ ## 📋 Instructions for Integrating UI-kit with the app
60
37
 
61
- *If you have problems with running the script, use the following command in the CLI:*
38
+ ### 📦 UI-kit library installation
62
39
 
63
- ```bash
64
- pnpm install --legacy-peer-deps
65
- ```
40
+ ```bash
41
+ npm install @candy.thieves/ui-kit-lumos@latest
42
+ # or
43
+ yarn add @candy.thieves/ui-kit-lumos@latest
44
+ # or
45
+ pnpm add @candy.thieves/ui-kit-lumos@latest
46
+ ```
66
47
 
67
- 5. **Launch the StoryBook local development server to visually test components:**
48
+ ### ⚙️ Basic Setup
68
49
 
69
- ```bash
70
- pnpm run storybook
71
- ```
50
+ 🌐 **Global Style import for _React app (Vite, CRA)_**
72
51
 
73
- 6. **Access the application:**
52
+ 🎨 _Add the styles to main.tsx:_
74
53
 
75
- Open your browser and navigate to the link provided in the CLI.*
54
+ ```tsx
55
+ // my-vite-app/src/main.tsx
76
56
 
77
- ## ⚙️Available Scripts
57
+ import '@candy.thieves/ui-kit-lumos/dist/index.css'
58
+ ```
78
59
 
79
- * **`dev`:** 💻 Starts a local Vite development server for quick debugging of the application.
60
+ 💻 **Using Components**
80
61
 
81
- ```bash
82
- pnpm run dev
83
- ```
84
- * **`build`:** 📦 Checks the TypeScript, then it builds an optimised production build of the project.
62
+ ```tsx
63
+ // my-vite-app/src/components/MyComponent.tsx
85
64
 
86
- ```bash
87
- pnpm run build
88
- ```
89
- * **`type:check`:** 🔷 Checks TypeScript types without generating files; for validation purposes only.
65
+ import { Button } from '@candy.thieves/ui-kit-lumos'
66
+ import { Typography } from '@candy.thieves/ui-kit-lumos'
90
67
 
91
- ```bash
92
- pnpm run type:check
93
- ```
68
+ export const MyComponent = () => {
69
+ return (
70
+ <div>
71
+ <Typography variant={'h2'} color={'green'}>
72
+ How to use UI-kit components
73
+ </Typography>
94
74
 
95
- * **`stylelint:check`:** 🎨 Checks SCSS files for stylelint errors.
75
+ <Button variant="primary" fullWidth onClick={() => console.log('clicked')}>
76
+ Click me!
77
+ </Button>
78
+ </div>
79
+ )
80
+ }
81
+ ```
96
82
 
97
- ```bash
98
- pnpm run stylelint:check
99
- ```
83
+ <hr>
100
84
 
101
- * **`stylelint:fix`:** 🔧 Automatically fixes SCSS stylelint errors.
85
+ 🌐 **Global Style import for _Next.js_ (App Router)**
102
86
 
103
- ```bash
104
- pnpm run stylelint:fix
105
- ```
87
+ 🎨 _Add the styles to your root layout file:_
106
88
 
107
- * **`format`:** ✅ Checks and automatically formats code with Prettier.
89
+ ```tsx
90
+ // my-next-app/app/layout.tsx
108
91
 
109
- ```bash
110
- pnpm run format
111
- ```
92
+ import '@candy.thieves/ui-kit-lumos/dist/index.css'
93
+ import type { Metadata } from 'next'
112
94
 
113
- * **`lint`:** 🔍 Runs ESLint to check for code quality issues and automatically fixes ESLint errors.
95
+ export const metadata: Metadata = {
96
+ title: 'My Next.js App',
97
+ }
114
98
 
115
- ```bash
116
- pnpm run lint
117
- ```
99
+ export default function RootLayout({ children }: { children: React.ReactNode }) {
100
+ return (
101
+ <html lang="en">
102
+ <body>{children}</body>
103
+ </html>
104
+ )
105
+ }
106
+ ```
118
107
 
119
- * **`preview`:** 👀 Starts a local server to preview the production build.
108
+ 💻 **Using Components**
120
109
 
121
- ```bash
122
- pnpm run preview
123
- ```
110
+ ```tsx
111
+ // my-next-app/components/MyComponent.tsx
124
112
 
125
- * **`storybook`:** ✨ Starts a local server to preview the production build.
113
+ 'use client'
126
114
 
127
- ```bash
128
- pnpm run storybook
129
- ```
115
+ import { Button, Typography } from '@candy.thieves/ui-kit-lumos'
130
116
 
131
- * **`build-storybook`:** 🌐 Starts a local server to preview the production build.
117
+ export const MyComponent = () => {
118
+ return (
119
+ <div>
120
+ <Typography variant={'h2'} color={'green'}>
121
+ How to use UI-kit components
122
+ </Typography>
132
123
 
133
- ```bash
134
- pnpm run build-storybook
135
- ```
124
+ <Button variant="primary" fullWidth onClick={() => console.log('clicked')}>
125
+ Click me!
126
+ </Button>
127
+ </div>
128
+ )
129
+ }
130
+ ```
136
131
 
137
- * **`prepare`:** ⚙️A lifecycle script that Husky uses to set up Git hooks. This is automatically run after `npm install`.
132
+ ## 🚀 Getting started locally with the UI-kit library
138
133
 
139
- ```bash
140
- pnpm run build-storybook
141
- ```
134
+ [Instructions for getting started locally](./instructions.md)
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="108" height="108" fill="none"><rect width="108" height="108" fill="#fff" rx="15"/><circle cx="54" cy="54" r="25" fill="#4c8dff" stroke="#333" stroke-width="10"/></svg>
@@ -0,0 +1,4 @@
1
+ <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="16" height="16" rx="3" fill="white"/>
3
+ <circle cx="8" cy="8" r="3" fill="#4C8DFF" stroke="#333333" stroke-width="2"/>
4
+ </svg>
@@ -0,0 +1,4 @@
1
+ <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="24" height="24" rx="5" fill="white"/>
3
+ <circle cx="12" cy="12" r="4.5" fill="#4C8DFF" stroke="#333333" stroke-width="3"/>
4
+ </svg>
@@ -0,0 +1,4 @@
1
+ <svg width="48" height="48" viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="48" height="48" rx="10" fill="white"/>
3
+ <circle cx="24" cy="24" r="9.5" fill="#4C8DFF" stroke="#333333" stroke-width="5"/>
4
+ </svg>
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="72" height="72" fill="none"><rect width="72" height="72" fill="#fff" rx="15"/><circle cx="36" cy="36" r="16" fill="#4c8dff" stroke="#333" stroke-width="8"/></svg>
@@ -0,0 +1,4 @@
1
+ <svg width="108" height="108" viewBox="0 0 108 108" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="108" height="108" rx="15" fill="#333333"/>
3
+ <circle cx="54" cy="54" r="25" fill="#4C8DFF" stroke="white" stroke-width="10"/>
4
+ </svg>
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="none"><rect width="16" height="16" fill="#333" rx="3"/><circle cx="8" cy="8" r="3" fill="#4c8dff" stroke="#fff" stroke-width="2"/></svg>
@@ -0,0 +1,4 @@
1
+ <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="24" height="24" rx="5" fill="#333333"/>
3
+ <circle cx="12" cy="12" r="4.5" fill="#4C8DFF" stroke="white" stroke-width="3"/>
4
+ </svg>
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" fill="none"><rect width="48" height="48" fill="#333" rx="10"/><circle cx="24" cy="24" r="9.5" fill="#4c8dff" stroke="#fff" stroke-width="5"/></svg>
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="72" height="72" fill="none"><rect width="72" height="72" fill="#333" rx="15"/><circle cx="36" cy="36" r="16" fill="#4c8dff" stroke="#fff" stroke-width="8"/></svg>