@revova/hydrogen 1.0.2 → 1.1.0
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/README.md +9 -2
- package/dist/index.cjs +1043 -714
- package/dist/index.d.cts +8 -5
- package/dist/index.d.ts +8 -5
- package/dist/index.js +1015 -686
- package/dist/styles.css +629 -0
- package/package.json +4 -3
package/README.md
CHANGED
|
@@ -72,6 +72,7 @@ const creds = {
|
|
|
72
72
|
|
|
73
73
|
```tsx
|
|
74
74
|
// app/routes/products.$handle.tsx
|
|
75
|
+
import '@revova/hydrogen/styles.css'; // import once in app/root.tsx instead
|
|
75
76
|
import { ReviewWidget, FloatingReviewButton } from '@revova/hydrogen';
|
|
76
77
|
|
|
77
78
|
export async function loader({ context, params }: LoaderArgs) {
|
|
@@ -408,9 +409,15 @@ const { vote, loading, voted } = useHelpfulVote(creds);
|
|
|
408
409
|
|
|
409
410
|
## Styling
|
|
410
411
|
|
|
411
|
-
|
|
412
|
+
The package ships a bundled CSS file. Import it **once** in your app root (e.g. `app/root.tsx`):
|
|
412
413
|
|
|
413
|
-
|
|
414
|
+
```ts
|
|
415
|
+
import '@revova/hydrogen/styles.css';
|
|
416
|
+
```
|
|
417
|
+
|
|
418
|
+
This applies the full `rv-*` design system — cards, stars, modal, form, ticker animation, popup, gallery lightbox, and all widget layouts. All class names are prefixed `rv-` so they won't conflict with your theme styles.
|
|
419
|
+
|
|
420
|
+
To customise, pass a `className` prop on any component and override the relevant `rv-*` classes in your own CSS. The `starColor` prop (default `#f59e0b`) is available on every component that renders stars.
|
|
414
421
|
|
|
415
422
|
---
|
|
416
423
|
|