@vuetify/v0 0.0.6 → 0.0.8

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/LICENSE.md ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2016-now Vuetify, LLC
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
package/README.md CHANGED
@@ -1,10 +1,26 @@
1
1
  <div align="center">
2
- <picture>
3
- <source media="(prefers-color-scheme: dark)" srcset="https://vuetifyjs.b-cdn.net/docs/images/logos/vzero-logo-dark.png">
4
- <img alt="Vuetify One Logo" src="https://vuetifyjs.b-cdn.net/docs/images/logos/vzero-logo-light.png" height="150">
5
- </picture>
2
+ <picture>
3
+ <source media="(prefers-color-scheme: dark)" srcset="https://vuetifyjs.b-cdn.net/docs/images/logos/vzero-logo-dark.png">
4
+ <img alt="Vuetify One Logo" src="https://vuetifyjs.b-cdn.net/docs/images/logos/vzero-logo-light.png" height="150">
5
+ </picture>
6
6
  </div>
7
7
 
8
+ <p align="center">
9
+ <a href="https://www.npmjs.com/package/@vuetify/v0">
10
+ <img src="https://img.shields.io/npm/dt/@vuetify/v0.svg" alt="Downloads">
11
+ </a>
12
+ <a href="https://www.npmjs.com/package/@vuetify/v0">
13
+ <img src="https://img.shields.io/npm/dm/@vuetify/v0.svg" alt="Downloads">
14
+ </a>
15
+ <br>
16
+ <a href="https://github.com/vuetifyjs/@vuetify/v0/blob/master/LICENSE.md">
17
+ <img src="https://img.shields.io/npm/l/@vuetify/v0.svg" alt="License">
18
+ </a>
19
+ <a href="https://community.vuetifyjs.com">
20
+ <img src="https://discordapp.com/api/guilds/340160225338195969/widget.png" alt="Chat">
21
+ </a>
22
+ </p>
23
+
8
24
  # @vuetify/v0
9
25
 
10
26
  Core foundational package from providing components and composables for building modern applications. `@vuetify/v0` is the foundational layer of the Vuetify ecosystem, offering lightweight, headless building blocks with TypeScript support and accessibility features built-in that serve as building blocks for higher-order UI libraries and custom design systems.
@@ -12,11 +28,13 @@ Core foundational package from providing components and composables for building
12
28
  ## 🚀 Installation
13
29
 
14
30
  ```bash
15
- npm install @vuetify/v0
31
+ npm install @vuetify/v0@latest
16
32
  # or
17
33
  pnpm add @vuetify/v0
18
34
  # or
19
35
  yarn add @vuetify/v0
36
+ # or
37
+ bun add @vuetify/v0
20
38
  ```
21
39
 
22
40
  ## 📦 What's Included
@@ -24,202 +42,62 @@ yarn add @vuetify/v0
24
42
  ### Components
25
43
 
26
44
  - **`Atom`** - Base element wrapper with renderless capabilities
27
- - **`Breakpoints`** - Responsive breakpoint utilities
28
- - **`Context`** - Context injection/provision system
29
- - **`Group`** - Selection grouping with multiple/single modes
30
- - **`Hydration`** - Client-side hydration utilities
45
+ - **`Avatar`** - User avatar component
31
46
  - **`Popover`** - CSS anchor-positioned popup components
32
- - **`Step`** - Step-based navigation system
33
- - **`Theme`** - Theme management and CSS variable injection
34
47
 
35
48
  ### Composables
36
49
 
37
- - **`useBreakpoints`** - Responsive breakpoint detection
38
- - **`createContext`** - Type-safe context management
39
- - **`useEventListener`** - Event listener utilities
50
+ #### Factories
51
+
52
+ - **`createContext`** - Context factory with type safety
53
+ - **`createPlugin`** - Vue plugin factory
54
+ - **`createTrinity`** - Trinity pattern factory
55
+
56
+ #### Registration
57
+
58
+ - **`useRegistry`** - Component registration and retrieval system
59
+ - **`useProxyRegistry`** - Make any registry reactive
60
+ - **`useQueue`** - Registry for managing ordered items
61
+ - **`useTimeline`** - Registry for managing timeline items
62
+ - **`useTokens`** - Design token system
63
+
64
+ #### Selection
65
+
40
66
  - **`useFilter`** - Collection filtering utilities
41
- - **`useForm`** - Form validation and management
67
+ - **`useSelection`** - Selection management
42
68
  - **`useGroup`** - Selection group management
43
- - **`useHydration`** - SSR hydration helpers
69
+ - **`useSingle`** - Single selection utilities
70
+ - **`useStep`** - Step navigation logic
71
+
72
+ #### Forms
73
+
74
+ - **`useForm`** - Form validation and state management
75
+ - **`useProxyModel`** - Proxy registry for Vue reactive models
76
+
77
+ #### System
78
+ - **`useEventListener`** - Event listener utilities
44
79
  - **`useIntersectionObserver`** - Intersection observer utilities
45
80
  - **`useKeydown`** - Keyboard event handling
46
- - **`useLocale`** - Internationalization support
47
- - **`useLogger`** - Development logging utilities
48
81
  - **`useMutationObserver`** - DOM mutation observation
49
- - **`useProxyModel`** - Model proxy utilities
50
- - **`useRegistry`** - Component registration system
51
82
  - **`useResizeObserver`** - Resize observer utilities
52
- - **`useSelection`** - Selection management
53
- - **`useSingle`** - Single selection utilities
54
- - **`useStep`** - Step navigation logic
55
- - **`useStorage`** - Local/session storage utilities
56
- - **`useTheme`** - Theme switching and CSS variable management
57
- - **`useTokens`** - Design token system
58
83
 
59
- ### Factories
60
84
 
61
- - **`createContext`** - Context factory with type safety
62
- - **`createPlugin`** - Vue plugin factory
63
- - **`createRootProvider`** - Root provider factory
64
- - **`createTrinity`** - Trinity pattern factory
85
+ #### Plugins
86
+
87
+ - **`useBreakpoints`** - Responsive breakpoint detection
88
+ - **`useFeatures`** - Feature detection utilities
89
+ - **`useHydration`** - SSR hydration helpers
90
+ - **`useLocale`** - Internationalization support
91
+ - **`useLogger`** - Development logging utilities
92
+ - **`usePermissions`** - User permission management
93
+ - **`useStorage`** - Local/session storage utilities
94
+ - **`useTheme`** - Theme switching and CSS variable management
65
95
 
66
96
  ### Transformers
67
97
 
68
98
  - **`toArray`** - Array transformation utilities
69
99
  - **`toReactive`** - Reactive object conversion
70
100
 
71
- ### Utilities
72
-
73
- - **Type guards** - `isString`, `isNumber`, `isObject`, etc.
74
- - **Object utilities** - `mergeDeep`, `genId`
75
- - **Performance utilities** - Benchmarking tools
76
-
77
-
78
- ## 📖 Basic Usage
79
-
80
- ### Theme Setup
81
-
82
- ```vue
83
- <script setup>
84
- import { createThemePlugin } from '@vuetify/v0'
85
-
86
- // Install theme plugin in your main.js
87
- app.use(createThemePlugin({
88
- default: 'light',
89
- themes: {
90
- light: {
91
- colors: {
92
- primary: '#1976d2',
93
- secondary: '#424242',
94
- background: '#ffffff'
95
- }
96
- },
97
- dark: {
98
- colors: {
99
- primary: '#2196f3',
100
- secondary: '#616161',
101
- background: '#121212'
102
- }
103
- }
104
- }
105
- }))
106
- </script>
107
- ```
108
-
109
- ### Using Components
110
-
111
- ```vue
112
- <script setup>
113
- import { Atom, Group, Step } from '@vuetify/v0'
114
- import { ref } from 'vue'
115
-
116
- const selectedItems = ref([])
117
- const currentStep = ref(0)
118
- </script>
119
-
120
- <template>
121
- <!-- Base Atom component -->
122
- <Atom as="section" class="container">
123
- <h1>My Application</h1>
124
- </Atom>
125
-
126
- <!-- Group selection -->
127
- <Group v-model="selectedItems" multiple>
128
- <template #default="{ select, isSelected }">
129
- <button
130
- v-for="item in items"
131
- :key="item.id"
132
- @click="select(item.id)"
133
- :class="{ active: isSelected(item.id) }"
134
- >
135
- {{ item.name }}
136
- </button>
137
- </template>
138
- </Group>
139
-
140
- <!-- Step navigation -->
141
- <Step v-model="currentStep" :max="3">
142
- <template #default="{ step, next, prev, canNext, canPrev }">
143
- <div class="step-content">
144
- Step {{ step + 1 }} content
145
- </div>
146
- <div class="step-actions">
147
- <button @click="prev" :disabled="!canPrev">Previous</button>
148
- <button @click="next" :disabled="!canNext">Next</button>
149
- </div>
150
- </template>
151
- </Step>
152
- </template>
153
- ```
154
-
155
- ### Using Composables
156
-
157
- ```vue
158
- <script setup>
159
- import { useBreakpoints, useTheme, useForm } from '@vuetify/v0'
160
- import { ref } from 'vue'
161
-
162
- // Responsive breakpoints
163
- const { isMobile, mdAndUp } = useBreakpoints()
164
-
165
- // Theme management
166
- const { theme, setTheme, colors } = useTheme()
167
-
168
- // Form management
169
- const { register, validate, errors } = useForm({
170
- validateOn: 'change'
171
- })
172
-
173
- const email = ref('')
174
- const password = ref('')
175
-
176
- // Register form fields
177
- register('email', email, [
178
- (value) => !!value || 'Email is required',
179
- (value) => /.+@.+\..+/.test(value) || 'Email must be valid'
180
- ])
181
-
182
- register('password', password, [
183
- (value) => !!value || 'Password is required',
184
- (value) => value.length >= 8 || 'Password must be at least 8 characters'
185
- ])
186
-
187
- const handleSubmit = async () => {
188
- const isValid = await validate()
189
- if (isValid) {
190
- // Submit form
191
- }
192
- }
193
- </script>
194
-
195
- <template>
196
- <div :class="{ mobile: isMobile, desktop: mdAndUp }">
197
- <button @click="setTheme(theme === 'light' ? 'dark' : 'light')">
198
- Toggle Theme ({{ theme }})
199
- </button>
200
-
201
- <form @submit.prevent="handleSubmit">
202
- <input
203
- v-model="email"
204
- type="email"
205
- placeholder="Email"
206
- :style="{ borderColor: colors.primary }"
207
- />
208
- <div v-if="errors.email" class="error">{{ errors.email[0] }}</div>
209
-
210
- <input
211
- v-model="password"
212
- type="password"
213
- placeholder="Password"
214
- />
215
- <div v-if="errors.password" class="error">{{ errors.password[0] }}</div>
216
-
217
- <button type="submit">Submit</button>
218
- </form>
219
- </div>
220
- </template>
221
- ```
222
-
223
101
  ## 🏗️ Design Principles
224
102
 
225
103
  - **Headless First**: Components provide logic and accessibility without imposed styling
@@ -233,14 +111,9 @@ const handleSubmit = async () => {
233
111
 
234
112
  For detailed API documentation, type definitions, and examples, visit our [documentation site](https://0.vuetifyjs.com) or explore the TypeScript definitions included in this package.
235
113
 
236
- ## 🔗 Related Packages
237
-
238
- - **[@vuetify/paper](https://npmjs.com/package/@vuetify/paper)** - Styling and layout primitives
239
- - **[Vuetify 3](https://vuetifyjs.com)** - Full-featured Material Design component library
240
-
241
114
  ## 🤝 Contributing
242
115
 
243
- Contributions are welcome! Please read our contributing guidelines and ensure all tests pass before submitting a pull request.
116
+ We are not currently accepting contributions to this package, check back later.
244
117
 
245
118
  ## 📄 License
246
119