@windstream/react-shared-components 0.0.2 → 0.0.3

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 (30) hide show
  1. package/README.md +226 -73
  2. package/dist/contentful/index.d.ts +62 -0
  3. package/dist/contentful/index.esm.js +2 -0
  4. package/dist/contentful/index.esm.js.map +1 -0
  5. package/dist/contentful/index.js +2 -0
  6. package/dist/contentful/index.js.map +1 -0
  7. package/dist/core.d.ts +6 -6
  8. package/dist/index.d.ts +5 -5
  9. package/package.json +9 -1
  10. package/src/contentful/blocks/accordion/index.tsx +7 -0
  11. package/src/contentful/blocks/accordion/types.ts +1 -0
  12. package/src/contentful/blocks/callout/index.tsx +7 -0
  13. package/src/contentful/blocks/callout/types.ts +1 -0
  14. package/src/contentful/blocks/cards/index.tsx +7 -0
  15. package/src/contentful/blocks/cards/types.ts +1 -0
  16. package/src/contentful/blocks/carousel/index.tsx +7 -0
  17. package/src/contentful/blocks/carousel/types.ts +1 -0
  18. package/src/contentful/blocks/floating-banner/index.tsx +7 -0
  19. package/src/contentful/blocks/floating-banner/types.ts +1 -0
  20. package/src/contentful/blocks/footer/index.tsx +7 -0
  21. package/src/contentful/blocks/footer/types.ts +1 -0
  22. package/src/contentful/blocks/image-promo-bar/index.tsx +7 -0
  23. package/src/contentful/blocks/image-promo-bar/types.ts +1 -0
  24. package/src/contentful/blocks/navigation/index.tsx +7 -0
  25. package/src/contentful/blocks/navigation/types.ts +1 -0
  26. package/src/contentful/blocks/primary-hero/index.tsx +7 -0
  27. package/src/contentful/blocks/primary-hero/types.ts +1 -0
  28. package/src/contentful/blocks/text/index.tsx +6 -0
  29. package/src/contentful/blocks/text/types.ts +1 -0
  30. package/src/contentful/index.ts +31 -0
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @windstream/react-shared-components
2
2
 
3
- A comprehensive React component library built with TypeScript and Tailwind CSS, designed for Kinetic applications.
3
+ A comprehensive React component library built with TypeScript and Tailwind CSS, designed for Kinetic applications. This library provides a complete set of reusable UI components following the Kinetic design system.
4
4
 
5
5
  ## 🚀 Features
6
6
 
@@ -10,6 +10,9 @@ A comprehensive React component library built with TypeScript and Tailwind CSS,
10
10
  - **Accessible**: Components follow accessibility best practices
11
11
  - **Customizable**: Easy to customize with CSS variables and Tailwind classes
12
12
  - **Tree-shakeable**: Optimized for bundle size with proper exports
13
+ - **Storybook**: Interactive component documentation and development environment
14
+ - **Design System**: Comprehensive design tokens following Kinetic brand guidelines
15
+ - **Material Icons**: Built-in Material Symbols Rounded icon support
13
16
 
14
17
  ## 📦 Installation
15
18
 
@@ -23,51 +26,40 @@ pnpm add @windstream/react-shared-components
23
26
 
24
27
  ## 🔧 Setup
25
28
 
26
- ### Tailwind CSS
27
-
28
- This library requires Tailwind CSS to be installed in your project. Make sure you have Tailwind CSS configured:
29
-
30
- ```bash
31
- npm install -D tailwindcss postcss autoprefixer
32
- npx tailwindcss init -p
33
- ```
34
-
35
- ### Import Styles
29
+ ### Prerequisites
36
30
 
37
- **Important**: Styles are NOT automatically included when you import components. You MUST manually import the CSS file in your application.
31
+ - React 18.0.0 or higher
32
+ - React DOM 18.0.0 or higher
33
+ - Tailwind CSS 3.4+ (for styling)
38
34
 
39
- Import the library styles in your main CSS file (recommended approach):
35
+ ### Tailwind CSS Configuration
40
36
 
41
- ```css
42
- @import '@windstream/react-shared-components/dist/styles.css';
43
- ```
37
+ This library requires Tailwind CSS to be installed and configured in your project. You can extend the library's Tailwind configuration:
44
38
 
45
- Or import it directly in your JavaScript/TypeScript entry file:
39
+ ```js
40
+ // tailwind.config.js
41
+ const sharedConfig = require('@windstream/react-shared-components/tailwind.config');
46
42
 
47
- ```tsx
48
- import '@windstream/react-shared-components/dist/styles.css';
43
+ module.exports = {
44
+ ...sharedConfig,
45
+ content: [
46
+ './src/**/*.{js,jsx,ts,tsx}',
47
+ './node_modules/@windstream/react-shared-components/src/**/*.{js,jsx,ts,tsx}',
48
+ ],
49
+ };
49
50
  ```
50
51
 
51
- **CSS Import Order**: The order in which you import styles matters:
52
- - If you want to override package styles with your own `globals.css`, import the package styles **before** your `globals.css`
53
- - If you want package styles to take precedence, import them **after** your `globals.css`
54
-
55
- Example with CSS import order control:
56
-
57
- ```css
58
- /* In your main CSS file (e.g., globals.css) */
59
- /* Import package styles first */
60
- @import '@windstream/react-shared-components/dist/styles.css';
61
-
62
- /* Then your app-specific overrides */
63
- @tailwind base;
64
- @tailwind components;
65
- @tailwind utilities;
66
-
67
- /* Your custom styles that can override package styles */
68
- .bg-bg-fill-brand {
69
- background-color: #your-custom-color;
70
- }
52
+ Or import the Tailwind config directly:
53
+
54
+ ```js
55
+ // tailwind.config.js
56
+ module.exports = {
57
+ presets: [require('@windstream/react-shared-components/tailwind.config')],
58
+ content: [
59
+ './src/**/*.{js,jsx,ts,tsx}',
60
+ './node_modules/@windstream/react-shared-components/src/**/*.{js,jsx,ts,tsx}',
61
+ ],
62
+ };
71
63
  ```
72
64
 
73
65
  ## 🎯 Usage
@@ -88,6 +80,25 @@ function MyComponent() {
88
80
  }
89
81
  ```
90
82
 
83
+ ### Import Paths
84
+
85
+ The library provides multiple export paths for different use cases:
86
+
87
+ ```tsx
88
+ // Core components (recommended)
89
+ import { Button, Input, Text } from '@windstream/react-shared-components/core';
90
+
91
+ // Utilities
92
+ import { cx, clsx } from '@windstream/react-shared-components/utils';
93
+
94
+ // Styles (required - styles are not automatically included)
95
+ import '@windstream/react-shared-components/dist/styles.css';
96
+ // Or in CSS: @import '@windstream/react-shared-components/dist/styles.css';
97
+
98
+ // Tailwind config
99
+ const tailwindConfig = require('@windstream/react-shared-components/tailwind.config');
100
+ ```
101
+
91
102
  ### Component Examples
92
103
 
93
104
  #### Button
@@ -115,14 +126,24 @@ import { Button } from '@windstream/react-shared-components/core';
115
126
  #### Input
116
127
 
117
128
  ```tsx
118
- import { Input } from '@windstream/react-shared-components/core';
129
+ import { Input, InputField, TextInput } from '@windstream/react-shared-components/core';
119
130
 
131
+ // Input, InputField, and TextInput are all aliases for the same component
120
132
  <Input
121
133
  placeholder="Enter text"
122
134
  type="text"
123
135
  variant="default"
124
136
  size="medium"
125
137
  />
138
+
139
+ <InputField
140
+ placeholder="Enter text"
141
+ label="Name"
142
+ />
143
+
144
+ <TextInput
145
+ placeholder="Enter text"
146
+ />
126
147
  ```
127
148
 
128
149
  #### Text
@@ -137,10 +158,32 @@ import { Text } from '@windstream/react-shared-components/core';
137
158
 
138
159
  ### Utilities
139
160
 
161
+ The `cx` utility is an enhanced version of `clsx` that intelligently merges Tailwind classes:
162
+
140
163
  ```tsx
141
164
  import { cx, clsx } from '@windstream/react-shared-components/utils';
142
165
 
143
- const classes = cx('btn', condition && 'btn-primary');
166
+ // cx automatically merges conflicting Tailwind classes
167
+ const classes = cx('btn', 'btn-primary', condition && 'btn-secondary');
168
+ // If condition is true, btn-secondary will override btn-primary
169
+
170
+ // clsx is also available for basic class name concatenation
171
+ const basicClasses = clsx('btn', condition && 'active');
172
+ ```
173
+
174
+ ### Hooks
175
+
176
+ ```tsx
177
+ import { useBodyScrollLock } from '@windstream/react-shared-components/core';
178
+
179
+ function Modal({ isOpen }) {
180
+ // Lock body scroll when modal is open
181
+ useBodyScrollLock(isOpen, true);
182
+
183
+ return (
184
+ // Modal content
185
+ );
186
+ }
144
187
  ```
145
188
 
146
189
  ## 🎨 Available Components
@@ -150,9 +193,12 @@ All components are available from the `/core` export path:
150
193
  ```tsx
151
194
  import {
152
195
  Button,
153
- Input,
196
+ Input,
197
+ InputField,
198
+ TextInput,
154
199
  Link,
155
- List,
200
+ List,
201
+ ListItem,
156
202
  MaterialIcon,
157
203
  Spinner,
158
204
  Text,
@@ -170,54 +216,96 @@ import {
170
216
  SeeMore,
171
217
  SelectPlanButton,
172
218
  Skeleton,
219
+ PageSkeleton,
173
220
  Tooltip,
174
- ViewCartButton
221
+ ViewCartButton,
222
+ useBodyScrollLock
175
223
  } from '@windstream/react-shared-components/core';
176
224
  ```
177
225
 
178
226
  ### Core Components
179
227
 
180
228
  - **Button** - Versatile button component with multiple variants and sizes
181
- - **Input** - Form input component with validation states
229
+ - **Input / InputField / TextInput** - Form input component with validation states (all are aliases)
182
230
  - **Link** - Accessible link component
183
- - **List** - List and list item components
184
- - **MaterialIcon** - Material Design icon component
231
+ - **List / ListItem** - List and list item components
232
+ - **MaterialIcon** - Material Design icon component using Material Symbols Rounded
185
233
  - **Spinner** - Loading spinner component
186
- - **Text** - Typography component with predefined variants
234
+ - **Text** - Typography component with predefined variants (heading1-6, body1-3, etc.)
187
235
  - **CallButton** - Button component for call-to-action
188
- - **Modal** - Modal dialog component
236
+ - **Modal** - Modal dialog component with customizable size, shape, and animations
189
237
  - **Accordion** - Collapsible accordion component
190
238
  - **Checkbox** - Checkbox input component
191
- - **Select** - Select dropdown component
239
+ - **Select** - Select dropdown component (powered by react-select)
192
240
  - **AlertCard** - Alert notification card component
193
- - **BrandButton** - Branded button variant
241
+ - **BrandButton** - Branded button variant with responsive sizing
194
242
  - **Checklist** - Checklist component
195
243
  - **Collapse** - Collapsible content component
196
244
  - **Divider** - Divider/separator component
197
245
  - **RadioButton** - Radio button input component
198
246
  - **SeeMore** - Expandable content component
199
247
  - **SelectPlanButton** - Plan selection button
200
- - **Skeleton** - Loading skeleton component
248
+ - **Skeleton / PageSkeleton** - Loading skeleton components
201
249
  - **Tooltip** - Tooltip component
202
250
  - **ViewCartButton** - Shopping cart button component
203
251
 
252
+ ### Custom Hooks
253
+
254
+ - **useBodyScrollLock** - Hook to lock/unlock body scroll (useful for modals)
255
+
204
256
  ### Component Variants
205
257
 
206
258
  Each component comes with multiple variants and sizes to fit different use cases:
207
259
 
208
260
  - **Variants**: default, primary, secondary, outline, unstyled
209
- - **Sizes**: small, medium, large
261
+ - **Sizes**: small (btn-small), medium (btn-medium), large (btn-large), x-large (btn-x-large)
210
262
  - **States**: loading, disabled, error, success
211
263
 
264
+ ### Typography Variants
265
+
266
+ The `Text` component supports the following typography variants via className:
267
+
268
+ - **Headings**: `heading1`, `heading2`, `heading3`, `heading4`, `heading5`, `heading6`
269
+ - **Subheadings**: `subheading1`, `subheading2`, `subheading3`, `subheading4`, `subheading5`, `subheading6`
270
+ - **Body**: `body1`, `body2`, `body3`
271
+ - **Labels**: `label1`, `label2`, `label3`, `label4`, `label5`, `label6`
272
+ - **Other**: `footnote`, `micro`
273
+
212
274
  ## 🎨 Design System
213
275
 
214
- This library follows the Kinetic design system with:
276
+ This library follows the Kinetic design system with comprehensive design tokens:
277
+
278
+ ### Color System
279
+
280
+ - **Brand Colors**: Primary brand color (#24A76A) with variants (accent, active, hover, disabled, etc.)
281
+ - **Semantic Colors**: Success, critical (error), info, inverse
282
+ - **Surface Colors**: Background fills, surfaces with states (active, hover, selected, disabled)
283
+ - **Text Colors**: Default, brand, critical, secondary, inverse, disabled
284
+ - **Border Colors**: Default, brand, critical, focus, hover, disabled
285
+ - **Icon Colors**: Brand, critical, default, info, inverse, secondary, success
286
+
287
+ ### Typography
288
+
289
+ - **Font Families**:
290
+ - Sans-serif (configurable via CSS variable `--win-site-font`)
291
+ - Material Symbols Rounded (for icons)
292
+ - Figtree (for body text)
293
+ - **Font Sizes**: Comprehensive scale from micro (12px) to heading1 (48px)
294
+ - **Line Heights**: Standardized line heights for optimal readability
215
295
 
216
- - **Color Palette**: Primary, secondary, and semantic colors
217
- - **Typography**: Consistent font sizes and line heights
218
- - **Spacing**: Standardized spacing scale
219
- - **Shadows**: Consistent shadow system
220
- - **Border Radius**: Unified border radius values
296
+ ### Spacing & Layout
297
+
298
+ - **Spacing Scale**: Custom spacing values (1.5, 2, 3, 4, 4.5, 6, 7, 13, 15, 17, 18, 26)
299
+ - **Border Radius**: Custom radius values (2.5, 3.5, 2xl, 2.5xl, 4xl)
300
+ - **Shadows**: drop, light, cardDrop, card
301
+
302
+ ### Responsive Breakpoints
303
+
304
+ - `sm`: 640px
305
+ - `md`: 768px
306
+ - `lg`: 1024px
307
+ - `xl`: 1280px
308
+ - `max`: 1200px
221
309
 
222
310
  ## 🔧 Development
223
311
 
@@ -236,7 +324,7 @@ cd kinetic-react-shared-components
236
324
  # Install dependencies
237
325
  npm install
238
326
 
239
- # Start development mode
327
+ # Start development mode (watch mode)
240
328
  npm run dev
241
329
 
242
330
  # Build the library
@@ -245,11 +333,32 @@ npm run build
245
333
  # Run tests
246
334
  npm test
247
335
 
336
+ # Run tests in watch mode
337
+ npm run test:watch
338
+
248
339
  # Run linting
249
340
  npm run lint
250
341
 
342
+ # Fix linting issues
343
+ npm run lint:fix
344
+
251
345
  # Format code
252
346
  npm run format
347
+
348
+ # Check code formatting
349
+ npm run format:check
350
+
351
+ # Type check
352
+ npm run type-check
353
+
354
+ # Start Storybook (component documentation)
355
+ npm run storybook
356
+
357
+ # Build Storybook
358
+ npm run build-storybook
359
+
360
+ # Clean build artifacts
361
+ npm run clean
253
362
  ```
254
363
 
255
364
  ### Project Structure
@@ -290,17 +399,30 @@ src/
290
399
 
291
400
  The library is built using Rollup with the following outputs:
292
401
 
293
- - **CommonJS**: `dist/index.js`
294
- - **ES Modules**: `dist/index.esm.js`
295
- - **TypeScript declarations**: `dist/index.d.ts`
402
+ - **CommonJS**: `dist/index.js` and `dist/utils/index.js`
403
+ - **ES Modules**: `dist/index.esm.js` and `dist/utils/index.esm.js`
404
+ - **TypeScript declarations**: `dist/index.d.ts`, `dist/core.d.ts`, and `dist/utils/index.d.ts`
405
+ - **Styles**: `dist/styles.css` (extracted and minified)
296
406
 
297
407
  All components are exported from a single entry point (`src/index.ts`), which allows for:
298
408
  - Simplified build process
299
409
  - Consistent import path: `@windstream/react-shared-components/core`
300
410
  - Tree-shaking support for optimal bundle sizes
411
+ - Separate utils export path for utility-only imports
412
+
413
+ ### Package Exports
414
+
415
+ The package provides the following export paths:
416
+
417
+ - `@windstream/react-shared-components/core` - All components and hooks
418
+ - `@windstream/react-shared-components/utils` - Utility functions (cx, clsx)
419
+ - `@windstream/react-shared-components/styles.css` - Compiled CSS styles
420
+ - `@windstream/react-shared-components/tailwind.config` - Tailwind configuration
301
421
 
302
422
  ## 🧪 Testing
303
423
 
424
+ The library uses Jest and React Testing Library for testing:
425
+
304
426
  ```bash
305
427
  # Run tests
306
428
  npm test
@@ -312,6 +434,8 @@ npm run test:watch
312
434
  npm run test:coverage
313
435
  ```
314
436
 
437
+ Test files should be named `*.test.ts` or `*.test.tsx` and placed alongside the components they test.
438
+
315
439
  ## 📝 Contributing
316
440
 
317
441
  1. Fork the repository
@@ -342,19 +466,48 @@ For support and questions:
342
466
 
343
467
  ## 🔄 Changelog
344
468
 
345
- ### v0.1.0
346
- - Initial release
347
- - Core components: Button, Input, Link, List, MaterialIcon, Spinner, Text
348
- - Additional components: CallButton, Modal, Accordion, Checkbox, Select, AlertCard, BrandButton, Checklist, Collapse, Divider, RadioButton, SeeMore, SelectPlanButton, Skeleton, Tooltip, ViewCartButton
349
- - TypeScript support
350
- - Tailwind CSS integration
351
- - Unified `/core` export path for all components
352
- - Simplified build process with single entry point
353
- - Comprehensive documentation
469
+ ### v0.0.2
470
+ - Current version
471
+ - 23+ React components with full TypeScript support
472
+ - Comprehensive design system with Tailwind CSS
473
+ - Material Symbols Rounded icon support
474
+ - Storybook integration for component documentation
475
+ - Custom hooks (useBodyScrollLock)
476
+ - Utility functions (cx, clsx) with Tailwind class merging
477
+ - Multiple export paths (core, utils, styles, tailwind.config)
478
+ - CommonJS and ES Module builds
479
+ - Full type definitions
480
+
481
+ ### Components Included
482
+ - **Form Components**: Button, Input, Checkbox, RadioButton, Select
483
+ - **Layout Components**: List, ListItem, Divider, Collapse, Accordion
484
+ - **Feedback Components**: Spinner, Skeleton, PageSkeleton, AlertCard, Tooltip
485
+ - **Navigation Components**: Link, Modal, SeeMore
486
+ - **Specialized Components**: CallButton, BrandButton, SelectPlanButton, ViewCartButton
487
+ - **Typography**: Text component with comprehensive variant system
488
+ - **Icons**: MaterialIcon component
354
489
 
355
490
  ## 📚 Additional Resources
356
491
 
357
492
  - [React Documentation](https://reactjs.org/)
358
493
  - [Tailwind CSS Documentation](https://tailwindcss.com/)
359
494
  - [TypeScript Documentation](https://www.typescriptlang.org/)
360
- - [Kinetic Design System](https://design.kinetic.com/)
495
+ - [Storybook Documentation](https://storybook.js.org/)
496
+ - [Material Symbols](https://fonts.google.com/icons)
497
+ - [React Testing Library](https://testing-library.com/react)
498
+ - [Jest Documentation](https://jestjs.io/)
499
+
500
+ ## 📦 Package Information
501
+
502
+ - **Package Name**: `@windstream/react-shared-components`
503
+ - **Current Version**: `0.0.2`
504
+ - **License**: MIT
505
+ - **Repository**: [GitHub](https://github.com/kinetic/react-shared-components)
506
+ - **Issues**: [GitHub Issues](https://github.com/kinetic/react-shared-components/issues)
507
+
508
+ ## 🔗 Related Packages
509
+
510
+ This package is part of the Kinetic ecosystem and works seamlessly with:
511
+ - Kinetic design system tokens
512
+ - Kinetic applications and services
513
+ - Other Windstream/Kinetic React packages
@@ -0,0 +1,62 @@
1
+ type AccordionProps = {};
2
+
3
+ declare const Accordion: React.FC<{
4
+ fields: AccordionProps;
5
+ }>;
6
+
7
+ type CalloutProps = {};
8
+
9
+ declare const Callout: React.FC<{
10
+ fields: CalloutProps;
11
+ }>;
12
+
13
+ type CardsProps = {};
14
+
15
+ declare const Cards: React.FC<{
16
+ fields: CardsProps;
17
+ }>;
18
+
19
+ type CarouselProps = {};
20
+
21
+ declare const Carousel: React.FC<{
22
+ fields: CarouselProps;
23
+ }>;
24
+
25
+ type FloatingBannerProps = {};
26
+
27
+ declare const FloatingBanner: React.FC<{
28
+ fields: FloatingBannerProps;
29
+ }>;
30
+
31
+ type FooterProps = {};
32
+
33
+ declare const Footer: React.FC<{
34
+ fields: FooterProps;
35
+ }>;
36
+
37
+ type ImagePromoBarProps = {};
38
+
39
+ declare const ImagePromoBar: React.FC<{
40
+ fields: ImagePromoBarProps;
41
+ }>;
42
+
43
+ type NavigationProps = {};
44
+
45
+ declare const Navigation: React.FC<{
46
+ fields: NavigationProps;
47
+ }>;
48
+
49
+ type PrimaryHeroProps = {};
50
+
51
+ declare const PrimaryHero: React.FC<{
52
+ fields: PrimaryHeroProps;
53
+ }>;
54
+
55
+ type TextProps = {};
56
+
57
+ declare const Text: React.FC<{
58
+ fields: TextProps;
59
+ }>;
60
+
61
+ export { Accordion, Callout, Cards, Carousel, FloatingBanner, Footer, ImagePromoBar, Navigation, PrimaryHero, Text };
62
+ export type { AccordionProps, CalloutProps, CardsProps, CarouselProps, FloatingBannerProps, FooterProps, ImagePromoBarProps, NavigationProps, PrimaryHeroProps, TextProps };
@@ -0,0 +1,2 @@
1
+ import{jsx as i}from"react/jsx-runtime";const d=({fields:d})=>i("div",{children:"Accordion"}),e=({fields:d})=>i("div",{children:"Callout"}),l=({fields:d})=>i("div",{children:"Cards"}),r=({fields:d})=>i("div",{children:"Carousel"}),n=({fields:d})=>i("div",{children:"FloatingBanner"}),o=({fields:d})=>i("div",{children:"Footer component"}),c=({fields:d})=>i("div",{children:"Image Promo Bar"}),s=({fields:d})=>i("div",{children:"Navigation"}),a=({fields:d})=>i("div",{children:"Primary Hero"}),f=({fields:d})=>i("div",{children:"Text Block"});export{d as Accordion,e as Callout,l as Cards,r as Carousel,n as FloatingBanner,o as Footer,c as ImagePromoBar,s as Navigation,a as PrimaryHero,f as Text};
2
+ //# sourceMappingURL=index.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.esm.js","sources":["../../src/contentful/blocks/accordion/index.tsx","../../src/contentful/blocks/callout/index.tsx","../../src/contentful/blocks/cards/index.tsx","../../src/contentful/blocks/carousel/index.tsx","../../src/contentful/blocks/floating-banner/index.tsx","../../src/contentful/blocks/footer/index.tsx","../../src/contentful/blocks/image-promo-bar/index.tsx","../../src/contentful/blocks/navigation/index.tsx","../../src/contentful/blocks/primary-hero/index.tsx","../../src/contentful/blocks/text/index.tsx"],"sourcesContent":[null,null,null,null,null,null,null,null,null,null],"names":["Accordion","fields","_jsx","Callout","Cards","Carousel","FloatingBanner","Footer","ImagePromoBar","Navigation","PrimaryHero","Text"],"mappings":"8CAEaA,EAAkD,EAAGC,YACzDC,gCCDIC,EAA8C,EAAGF,YACrDC,8BCDIE,EAA0C,EAAGH,YACjDC,4BCDIG,EAAgD,EAAGJ,YACvDC,+BCDII,EAA0D,EAAGL,YACjEC,qCCDIK,EAA4C,EAAGN,YACnDC,uCCDIM,EAA0D,EAAGP,YACjEC,sCCDIO,EAAoD,EAAGR,YAC3DC,iCCDIQ,EAAsD,EAAGT,YAC7DC,mCCDIS,EAAwC,EAAGV,YAC/CC"}
@@ -0,0 +1,2 @@
1
+ "use strict";var e=require("react/jsx-runtime");exports.Accordion=({fields:r})=>e.jsx("div",{children:"Accordion"}),exports.Callout=({fields:r})=>e.jsx("div",{children:"Callout"}),exports.Cards=({fields:r})=>e.jsx("div",{children:"Cards"}),exports.Carousel=({fields:r})=>e.jsx("div",{children:"Carousel"}),exports.FloatingBanner=({fields:r})=>e.jsx("div",{children:"FloatingBanner"}),exports.Footer=({fields:r})=>e.jsx("div",{children:"Footer component"}),exports.ImagePromoBar=({fields:r})=>e.jsx("div",{children:"Image Promo Bar"}),exports.Navigation=({fields:r})=>e.jsx("div",{children:"Navigation"}),exports.PrimaryHero=({fields:r})=>e.jsx("div",{children:"Primary Hero"}),exports.Text=({fields:r})=>e.jsx("div",{children:"Text Block"});
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../src/contentful/blocks/accordion/index.tsx","../../src/contentful/blocks/callout/index.tsx","../../src/contentful/blocks/cards/index.tsx","../../src/contentful/blocks/carousel/index.tsx","../../src/contentful/blocks/floating-banner/index.tsx","../../src/contentful/blocks/footer/index.tsx","../../src/contentful/blocks/image-promo-bar/index.tsx","../../src/contentful/blocks/navigation/index.tsx","../../src/contentful/blocks/primary-hero/index.tsx","../../src/contentful/blocks/text/index.tsx"],"sourcesContent":[null,null,null,null,null,null,null,null,null,null],"names":["fields","_jsx"],"mappings":"kEAE+D,EAAGA,YACzDC,EAAAA,kDCDkD,EAAGD,YACrDC,EAAAA,8CCD8C,EAAGD,YACjDC,EAAAA,+CCDoD,EAAGD,YACvDC,EAAAA,wDCD8D,EAAGD,YACjEC,EAAAA,sDCDgD,EAAGD,YACnDC,EAAAA,+DCD8D,EAAGD,YACjEC,EAAAA,2DCDwD,EAAGD,YAC3DC,EAAAA,uDCD0D,EAAGD,YAC7DC,EAAAA,kDCD4C,EAAGD,YAC/CC,EAAAA"}
package/dist/core.d.ts CHANGED
@@ -55,16 +55,16 @@ type InputFieldProps = Omit<InputHTMLAttributes<HTMLInputElement>, "size"> & {
55
55
 
56
56
  declare const InputField: ForwardRefRenderFunction<HTMLInputElement, InputFieldProps>;
57
57
  declare const Input: React$1.ForwardRefExoticComponent<Omit<React$1.InputHTMLAttributes<HTMLInputElement>, "size"> & {
58
- state?: "default" | "error" | "filled" | "active" | "focus" | "hover" | undefined;
59
- size?: "medium" | "large" | "slim" | undefined;
58
+ state?: "default" | "focus" | "active" | "hover" | "filled" | "error" | undefined;
59
+ size?: "slim" | "medium" | "large" | undefined;
60
60
  label?: string | undefined;
61
61
  errorText?: string | undefined;
62
62
  prefixIconName?: "search" | "location_on" | undefined;
63
- prefixIconSize?: 24 | 20 | 40 | 48 | undefined;
63
+ prefixIconSize?: 20 | 24 | 40 | 48 | undefined;
64
64
  prefixIconFill?: boolean | undefined;
65
65
  suffixIconFill?: boolean | undefined;
66
- suffixIconName?: "visibility" | "lock" | "visibility_off" | undefined;
67
- suffixIconSize?: 24 | 20 | 40 | 48 | undefined;
66
+ suffixIconName?: "visibility" | "visibility_off" | "lock" | undefined;
67
+ suffixIconSize?: 20 | 24 | 40 | 48 | undefined;
68
68
  containerClassName?: string | undefined;
69
69
  prefixIconClassName?: string | undefined;
70
70
  loading?: boolean | undefined;
@@ -295,7 +295,7 @@ type ButtonCustomProps = {
295
295
  };
296
296
  type ButtonProps = ButtonCustomProps & Omit<ButtonHTMLAttributes<HTMLButtonElement>, "children" | "className">;
297
297
 
298
- declare const BrandButton: React$1.ForwardRefExoticComponent<_shared_components_brand_button_types.ButtonCustomProps & Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, "children" | "className"> & React$1.RefAttributes<HTMLButtonElement>>;
298
+ declare const BrandButton: React$1.ForwardRefExoticComponent<_shared_components_brand_button_types.ButtonCustomProps & Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, "className" | "children"> & React$1.RefAttributes<HTMLButtonElement>>;
299
299
 
300
300
  declare const Checklist: React__default.FC<ChecklistProps>;
301
301
 
package/dist/index.d.ts CHANGED
@@ -55,15 +55,15 @@ type InputFieldProps = Omit<InputHTMLAttributes<HTMLInputElement>, "size"> & {
55
55
 
56
56
  declare const InputField: ForwardRefRenderFunction<HTMLInputElement, InputFieldProps>;
57
57
  declare const Input: React$1.ForwardRefExoticComponent<Omit<React$1.InputHTMLAttributes<HTMLInputElement>, "size"> & {
58
- state?: "error" | "default" | "filled" | "active" | "focus" | "hover" | undefined;
59
- size?: "medium" | "large" | "slim" | undefined;
58
+ state?: "default" | "focus" | "active" | "hover" | "filled" | "error" | undefined;
59
+ size?: "slim" | "medium" | "large" | undefined;
60
60
  label?: string | undefined;
61
61
  errorText?: string | undefined;
62
- prefixIconName?: "search" | "location_on" | undefined;
62
+ prefixIconName?: "location_on" | "search" | undefined;
63
63
  prefixIconSize?: 20 | 24 | 40 | 48 | undefined;
64
64
  prefixIconFill?: boolean | undefined;
65
65
  suffixIconFill?: boolean | undefined;
66
- suffixIconName?: "visibility" | "lock" | "visibility_off" | undefined;
66
+ suffixIconName?: "visibility" | "visibility_off" | "lock" | undefined;
67
67
  suffixIconSize?: 20 | 24 | 40 | 48 | undefined;
68
68
  containerClassName?: string | undefined;
69
69
  prefixIconClassName?: string | undefined;
@@ -295,7 +295,7 @@ type ButtonCustomProps = {
295
295
  };
296
296
  type ButtonProps = ButtonCustomProps & Omit<ButtonHTMLAttributes<HTMLButtonElement>, "children" | "className">;
297
297
 
298
- declare const BrandButton: React$1.ForwardRefExoticComponent<_shared_components_brand_button_types.ButtonCustomProps & Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, "children" | "className"> & React$1.RefAttributes<HTMLButtonElement>>;
298
+ declare const BrandButton: React$1.ForwardRefExoticComponent<_shared_components_brand_button_types.ButtonCustomProps & Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, "className" | "children"> & React$1.RefAttributes<HTMLButtonElement>>;
299
299
 
300
300
  declare const Checklist: React__default.FC<ChecklistProps>;
301
301
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@windstream/react-shared-components",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "type": "module",
5
5
  "description": "Shared React components for Kinetic applications",
6
6
  "main": "dist/index.js",
@@ -13,6 +13,9 @@
13
13
  ],
14
14
  "utils": [
15
15
  "./dist/utils/index.d.ts"
16
+ ],
17
+ "contentful": [
18
+ "./dist/contentful/index.d.ts"
16
19
  ]
17
20
  }
18
21
  },
@@ -32,6 +35,11 @@
32
35
  "import": "./dist/utils/index.esm.js",
33
36
  "require": "./dist/utils/index.js"
34
37
  },
38
+ "./contentful": {
39
+ "types": "./dist/contentful/index.d.ts",
40
+ "import": "./dist/contentful/index.esm.js",
41
+ "require": "./dist/contentful/index.js"
42
+ },
35
43
  "./tailwind.config": {
36
44
  "types": "./tailwind.config.cjs",
37
45
  "require": "./tailwind.config.cjs",
@@ -0,0 +1,7 @@
1
+ import { AccordionProps } from "./types";
2
+
3
+ export const Accordion: React.FC<{ fields: AccordionProps }> = ({ fields }) => {
4
+ return <div>Accordion</div>;
5
+ };
6
+
7
+ export default Accordion;
@@ -0,0 +1 @@
1
+ export type AccordionProps = {}
@@ -0,0 +1,7 @@
1
+ import { CalloutProps } from "./types";
2
+
3
+ export const Callout: React.FC<{ fields: CalloutProps }> = ({ fields }) => {
4
+ return <div>Callout</div>;
5
+ };
6
+
7
+ export default Callout;
@@ -0,0 +1 @@
1
+ export type CalloutProps = {}
@@ -0,0 +1,7 @@
1
+ import { CardsProps } from "./types";
2
+
3
+ export const Cards: React.FC<{ fields: CardsProps }> = ({ fields }) => {
4
+ return <div>Cards</div>;
5
+ };
6
+
7
+ export default Cards;
@@ -0,0 +1 @@
1
+ export type CardsProps = {}
@@ -0,0 +1,7 @@
1
+ import { CarouselProps } from "./types";
2
+
3
+ export const Carousel: React.FC<{ fields: CarouselProps }> = ({ fields }) => {
4
+ return <div>Carousel</div>;
5
+ };
6
+
7
+ export default Carousel;
@@ -0,0 +1 @@
1
+ export type CarouselProps = {}
@@ -0,0 +1,7 @@
1
+ import { FloatingBannerProps } from "./types";
2
+
3
+ export const FloatingBanner: React.FC<{fields: FloatingBannerProps}> = ({ fields }) => {
4
+ return <div>FloatingBanner</div>;
5
+ };
6
+
7
+ export default FloatingBanner;
@@ -0,0 +1 @@
1
+ export type FloatingBannerProps = {}
@@ -0,0 +1,7 @@
1
+ import { FooterProps } from "./types";
2
+
3
+ export const Footer: React.FC<{ fields: FooterProps }> = ({ fields }) => {
4
+ return <div>Footer component</div>;
5
+ };
6
+
7
+ export default Footer;
@@ -0,0 +1 @@
1
+ export type FooterProps = {}
@@ -0,0 +1,7 @@
1
+ import { ImagePromoBarProps } from "./types";
2
+
3
+ export const ImagePromoBar: React.FC<{ fields: ImagePromoBarProps }> = ({ fields }) => {
4
+ return <div>Image Promo Bar</div>;
5
+ };
6
+
7
+ export default ImagePromoBar;
@@ -0,0 +1 @@
1
+ export type ImagePromoBarProps = {}
@@ -0,0 +1,7 @@
1
+ import { NavigationProps } from "./types";
2
+
3
+ export const Navigation: React.FC<{ fields: NavigationProps }> = ({ fields }) => {
4
+ return <div>Navigation</div>;
5
+ };
6
+
7
+ export default Navigation;
@@ -0,0 +1 @@
1
+ export type NavigationProps = {}
@@ -0,0 +1,7 @@
1
+ import { PrimaryHeroProps } from "./types";
2
+
3
+ export const PrimaryHero: React.FC<{ fields: PrimaryHeroProps }> = ({ fields }) => {
4
+ return <div>Primary Hero</div>;
5
+ };
6
+
7
+ export default PrimaryHero;
@@ -0,0 +1 @@
1
+ export type PrimaryHeroProps = {}
@@ -0,0 +1,6 @@
1
+ import { TextProps } from "./types";
2
+
3
+ export const Text: React.FC<{ fields: TextProps }> = ({ fields }) => {
4
+ return <div>Text Block</div>;
5
+ };
6
+ export default Text;
@@ -0,0 +1 @@
1
+ export type TextProps = {}
@@ -0,0 +1,31 @@
1
+ // Contentful Blocks
2
+ export { Accordion } from "./blocks/accordion";
3
+ export type { AccordionProps } from "./blocks/accordion/types";
4
+
5
+ export { Callout } from "./blocks/callout";
6
+ export type { CalloutProps } from "./blocks/callout/types";
7
+
8
+ export { Cards } from "./blocks/cards";
9
+ export type { CardsProps } from "./blocks/cards/types";
10
+
11
+ export { Carousel } from "./blocks/carousel";
12
+ export type { CarouselProps } from "./blocks/carousel/types";
13
+
14
+ export { FloatingBanner } from "./blocks/floating-banner";
15
+ export type { FloatingBannerProps } from "./blocks/floating-banner/types";
16
+
17
+ export { Footer } from "./blocks/footer";
18
+ export type { FooterProps } from "./blocks/footer/types";
19
+
20
+ export { ImagePromoBar } from "./blocks/image-promo-bar";
21
+ export type { ImagePromoBarProps } from "./blocks/image-promo-bar/types";
22
+
23
+ export { Navigation } from "./blocks/navigation";
24
+ export type { NavigationProps } from "./blocks/navigation/types";
25
+
26
+ export { PrimaryHero } from "./blocks/primary-hero";
27
+ export type { PrimaryHeroProps } from "./blocks/primary-hero/types";
28
+
29
+ export { Text } from "./blocks/text";
30
+ export type { TextProps } from "./blocks/text/types";
31
+