@teo-garcia/react-shared 0.1.1 → 0.1.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 CHANGED
@@ -19,3 +19,6 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
19
  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
20
  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
21
  SOFTWARE.
22
+
23
+
24
+
package/README.md CHANGED
@@ -32,13 +32,13 @@ pnpm add -D msw
32
32
 
33
33
  ## Features
34
34
 
35
- - 🎨 **Components**: Ready-to-use UI components (ThemeSwitch, ViewportInfo, ErrorBoundary)
36
- - 🪝 **Hooks**: Reusable React hooks (useHealthcheck)
37
- - 🛠️ **Utilities**: Pure helper functions (environment detection, MSW setup)
38
- - 🔌 **Adapters**: Framework bridges for theme providers and environment detection
39
- - 📦 **Framework Agnostic**: Works with Next.js, React Router, and other React frameworks
40
- - 🎯 **TypeScript**: Full type safety with TypeScript definitions
41
- - 🌲 **Tree-shakeable**: Import only what you need
35
+ - **Components**: Ready-to-use UI components (ThemeSwitch, ViewportInfo, ErrorBoundary)
36
+ - **Hooks**: Reusable React hooks (useHealthcheck)
37
+ - **Utilities**: Pure helper functions (environment detection, MSW setup)
38
+ - **Adapters**: Framework bridges for theme providers and environment detection
39
+ - **Framework Agnostic**: Works with Next.js, React Router, and other React frameworks
40
+ - **TypeScript**: Full type safety with TypeScript definitions
41
+ - **Tree-shakeable**: Import only what you need
42
42
 
43
43
  ## Usage
44
44
 
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Environment adapters - abstract environment detection across different frameworks
3
3
  */
4
- export { nextEnvironmentAdapter } from './next';
5
- export { viteEnvironmentAdapter } from './vite';
4
+ export { nextEnvironmentAdapter } from './next.js';
5
+ export { viteEnvironmentAdapter } from './vite.js';
6
6
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/adapters/environment/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,sBAAsB,EAAE,MAAM,QAAQ,CAAA;AAC/C,OAAO,EAAE,sBAAsB,EAAE,MAAM,QAAQ,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/adapters/environment/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,sBAAsB,EAAE,MAAM,WAAW,CAAA;AAClD,OAAO,EAAE,sBAAsB,EAAE,MAAM,WAAW,CAAA"}
@@ -1,5 +1,5 @@
1
1
  /**
2
2
  * Environment adapters - abstract environment detection across different frameworks
3
3
  */
4
- export { nextEnvironmentAdapter } from './next';
5
- export { viteEnvironmentAdapter } from './vite';
4
+ export { nextEnvironmentAdapter } from './next.js';
5
+ export { viteEnvironmentAdapter } from './vite.js';
@@ -4,6 +4,6 @@
4
4
  * Adapters allow our components to work with different theme libraries,
5
5
  * environment detection systems, and other framework-specific APIs
6
6
  */
7
- export * from './environment';
8
- export * from './theme';
7
+ export * from './environment/index.js';
8
+ export * from './theme/index.js';
9
9
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/adapters/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,cAAc,eAAe,CAAA;AAC7B,cAAc,SAAS,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/adapters/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,cAAc,wBAAwB,CAAA;AACtC,cAAc,kBAAkB,CAAA"}
@@ -4,5 +4,5 @@
4
4
  * Adapters allow our components to work with different theme libraries,
5
5
  * environment detection systems, and other framework-specific APIs
6
6
  */
7
- export * from './environment';
8
- export * from './theme';
7
+ export * from './environment/index.js';
8
+ export * from './theme/index.js';
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Theme adapters - bridge between different theme libraries and our components
3
3
  */
4
- export { createCustomThemeAdapter } from './custom';
5
- export { useNextThemesAdapter } from './next-themes';
4
+ export { createCustomThemeAdapter } from './custom.js';
5
+ export { useNextThemesAdapter } from './next-themes.js';
6
6
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/adapters/theme/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,wBAAwB,EAAE,MAAM,UAAU,CAAA;AACnD,OAAO,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/adapters/theme/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,wBAAwB,EAAE,MAAM,aAAa,CAAA;AACtD,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAA"}
@@ -1,5 +1,5 @@
1
1
  /**
2
2
  * Theme adapters - bridge between different theme libraries and our components
3
3
  */
4
- export { createCustomThemeAdapter } from './custom';
5
- export { useNextThemesAdapter } from './next-themes';
4
+ export { createCustomThemeAdapter } from './custom.js';
5
+ export { useNextThemesAdapter } from './next-themes.js';
@@ -1,2 +1,2 @@
1
- export { ErrorBoundary } from './error-boundary';
1
+ export { ErrorBoundary } from './error-boundary.js';
2
2
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/error-boundary/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/error-boundary/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAA"}
@@ -1 +1 @@
1
- export { ErrorBoundary } from './error-boundary';
1
+ export { ErrorBoundary } from './error-boundary.js';
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Components - Reusable React UI components
3
3
  */
4
- export * from './error-boundary';
5
- export * from './theme-switch';
6
- export * from './viewport-info';
4
+ export * from './error-boundary/index.js';
5
+ export * from './theme-switch/index.js';
6
+ export * from './viewport-info/index.js';
7
7
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/components/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,kBAAkB,CAAA;AAChC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,iBAAiB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/components/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,2BAA2B,CAAA;AACzC,cAAc,yBAAyB,CAAA;AACvC,cAAc,0BAA0B,CAAA"}
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Components - Reusable React UI components
3
3
  */
4
- export * from './error-boundary';
5
- export * from './theme-switch';
6
- export * from './viewport-info';
4
+ export * from './error-boundary/index.js';
5
+ export * from './theme-switch/index.js';
6
+ export * from './viewport-info/index.js';
@@ -1,3 +1,3 @@
1
- export { ThemeSwitch } from './theme-switch';
2
- export type { ThemeSwitchProps } from './theme-switch';
1
+ export { ThemeSwitch } from './theme-switch.js';
2
+ export type { ThemeSwitchProps } from './theme-switch.js';
3
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/theme-switch/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AAC5C,YAAY,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/theme-switch/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,YAAY,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAA"}
@@ -1 +1 @@
1
- export { ThemeSwitch } from './theme-switch';
1
+ export { ThemeSwitch } from './theme-switch.js';
@@ -1,3 +1,3 @@
1
- export { ViewportInfo } from './viewport-info';
2
- export type { ViewportInfoProps } from './viewport-info';
1
+ export { ViewportInfo } from './viewport-info.js';
2
+ export type { ViewportInfoProps } from './viewport-info.js';
3
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/viewport-info/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AAC9C,YAAY,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/viewport-info/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AACjD,YAAY,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAA"}
@@ -1 +1 @@
1
- export { ViewportInfo } from './viewport-info';
1
+ export { ViewportInfo } from './viewport-info.js';
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Hooks - Reusable React hooks for common functionality
3
3
  */
4
- export { useHealthcheck } from './use-healthcheck';
5
- export type { UseHealthcheckOptions } from './use-healthcheck';
4
+ export { useHealthcheck } from './use-healthcheck.js';
5
+ export type { UseHealthcheckOptions } from './use-healthcheck.js';
6
6
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAA;AAClD,YAAY,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AACrD,YAAY,EAAE,qBAAqB,EAAE,MAAM,sBAAsB,CAAA"}
@@ -1,4 +1,4 @@
1
1
  /**
2
2
  * Hooks - Reusable React hooks for common functionality
3
3
  */
4
- export { useHealthcheck } from './use-healthcheck';
4
+ export { useHealthcheck } from './use-healthcheck.js';
package/dist/index.d.ts CHANGED
@@ -8,9 +8,9 @@
8
8
  *
9
9
  * @packageDocumentation
10
10
  */
11
- export * from './components';
12
- export * from './hooks';
13
- export * from './utils';
14
- export * from './adapters';
15
- export * from './types';
11
+ export * from './components/index.js';
12
+ export * from './hooks/index.js';
13
+ export * from './utils/index.js';
14
+ export * from './adapters/index.js';
15
+ export * from './types.js';
16
16
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,cAAc,cAAc,CAAA;AAG5B,cAAc,SAAS,CAAA;AAGvB,cAAc,SAAS,CAAA;AAGvB,cAAc,YAAY,CAAA;AAG1B,cAAc,SAAS,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,cAAc,uBAAuB,CAAA;AAGrC,cAAc,kBAAkB,CAAA;AAGhC,cAAc,kBAAkB,CAAA;AAGhC,cAAc,qBAAqB,CAAA;AAGnC,cAAc,YAAY,CAAA"}
package/dist/index.js CHANGED
@@ -9,12 +9,12 @@
9
9
  * @packageDocumentation
10
10
  */
11
11
  // Export all components
12
- export * from './components';
12
+ export * from './components/index.js';
13
13
  // Export all hooks
14
- export * from './hooks';
14
+ export * from './hooks/index.js';
15
15
  // Export all utilities
16
- export * from './utils';
16
+ export * from './utils/index.js';
17
17
  // Export all adapters
18
- export * from './adapters';
18
+ export * from './adapters/index.js';
19
19
  // Export all types
20
- export * from './types';
20
+ export * from './types.js';
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Utilities - Pure functions and helpers
3
3
  */
4
- export * from './environment';
5
- export * from './msw';
4
+ export * from './environment.js';
5
+ export * from './msw.js';
6
6
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,eAAe,CAAA;AAC7B,cAAc,OAAO,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,kBAAkB,CAAA;AAChC,cAAc,UAAU,CAAA"}
@@ -1,5 +1,5 @@
1
1
  /**
2
2
  * Utilities - Pure functions and helpers
3
3
  */
4
- export * from './environment';
5
- export * from './msw';
4
+ export * from './environment.js';
5
+ export * from './msw.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teo-garcia/react-shared",
3
- "version": "0.1.1",
3
+ "version": "0.1.8",
4
4
  "description": "Shared React components, hooks, utilities, and adapters for fullstack web templates",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -80,6 +80,10 @@
80
80
  ],
81
81
  "author": "teo-garcia",
82
82
  "license": "MIT",
83
+ "repository": {
84
+ "type": "git",
85
+ "url": "git+https://github.com/teo-garcia/react-shared.git"
86
+ },
83
87
  "engines": {
84
88
  "node": ">=20"
85
89
  },