rockin 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.
@@ -0,0 +1,26 @@
1
+ // src/loader.tsx
2
+ import { ProgressProvider } from "@bprogress/next/app";
3
+ import { jsx } from "react/jsx-runtime";
4
+ function TopLoader({
5
+ children,
6
+ color = "var(--brand)",
7
+ height = "2px",
8
+ options,
9
+ showSpinner = false,
10
+ ...props
11
+ }) {
12
+ return /* @__PURE__ */ jsx(
13
+ ProgressProvider,
14
+ {
15
+ ...props,
16
+ color,
17
+ height,
18
+ options: { showSpinner, ...options },
19
+ children
20
+ }
21
+ );
22
+ }
23
+
24
+ export {
25
+ TopLoader
26
+ };
package/dist/index.d.ts CHANGED
@@ -3,12 +3,6 @@ export { default as NumberFlow } from '@number-flow/react';
3
3
  export * from 'goey-toast';
4
4
  export * from 'motion/react';
5
5
  export * from 'next-themes';
6
- import * as React$1 from 'react';
7
-
8
- type TopLoaderProps = {
9
- children: React.ReactNode;
10
- height?: string;
11
- };
12
- declare function TopLoader({ children, height, }: TopLoaderProps): React$1.JSX.Element;
13
-
14
- export { TopLoader };
6
+ export { TopLoader, TopLoaderProps } from './loader.js';
7
+ import 'react';
8
+ import '@bprogress/next/app';
package/dist/index.js CHANGED
@@ -1,3 +1,6 @@
1
+ import {
2
+ TopLoader
3
+ } from "./chunk-3ZGQJTWY.js";
1
4
  import {
2
5
  BellIcon,
3
6
  IconSwap,
@@ -9,25 +12,6 @@ import { default as default2 } from "@number-flow/react";
9
12
  export * from "goey-toast";
10
13
  export * from "motion/react";
11
14
  export * from "next-themes";
12
-
13
- // src/loader.tsx
14
- import { ProgressProvider } from "@bprogress/next/app";
15
- import { jsx } from "react/jsx-runtime";
16
- function TopLoader({
17
- children,
18
- height = "4px"
19
- }) {
20
- return /* @__PURE__ */ jsx(
21
- ProgressProvider,
22
- {
23
- height,
24
- color: "var(--navigation-progress-color, var(--primary))",
25
- options: { showSpinner: false },
26
- shallowRouting: true,
27
- children
28
- }
29
- );
30
- }
31
15
  export {
32
16
  BellIcon,
33
17
  IconSwap,
@@ -0,0 +1,19 @@
1
+ import * as React from 'react';
2
+ import { ComponentProps, ReactNode } from 'react';
3
+ import { ProgressProvider } from '@bprogress/next/app';
4
+
5
+ type ProgressProviderProps = ComponentProps<typeof ProgressProvider>;
6
+ type TopLoaderProps = Omit<ProgressProviderProps, 'children' | 'color' | 'height' | 'options'> & {
7
+ children: ReactNode;
8
+ /** Progress bar color. Accepts any valid CSS color, including a token. */
9
+ color?: string;
10
+ /** Progress bar height. Accepts any valid CSS length. */
11
+ height?: string;
12
+ /** Show the provider's spinner alongside the top progress bar. */
13
+ showSpinner?: boolean;
14
+ /** Additional BProgress options. These override the component defaults. */
15
+ options?: ProgressProviderProps['options'];
16
+ };
17
+ declare function TopLoader({ children, color, height, options, showSpinner, ...props }: TopLoaderProps): React.JSX.Element;
18
+
19
+ export { TopLoader, type TopLoaderProps };
package/dist/loader.js ADDED
@@ -0,0 +1,7 @@
1
+ "use client";
2
+ import {
3
+ TopLoader
4
+ } from "./chunk-3ZGQJTWY.js";
5
+ export {
6
+ TopLoader
7
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rockin",
3
- "version": "0.0.8",
3
+ "version": "0.0.10",
4
4
  "description": "Shared React UI components, icons, hooks, utilities, and styles.",
5
5
  "type": "module",
6
6
  "private": false,
@@ -26,6 +26,10 @@
26
26
  "types": "./dist/cn.d.ts",
27
27
  "import": "./dist/cn.js"
28
28
  },
29
+ "./loader": {
30
+ "types": "./dist/loader.d.ts",
31
+ "import": "./dist/loader.js"
32
+ },
29
33
  "./lucide": {
30
34
  "types": "./dist/lucide.d.ts",
31
35
  "import": "./dist/lucide.js"