Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,4 @@ yarn-error.log*
/src/stories/

*storybook.log
/dist/
4 changes: 2 additions & 2 deletions .storybook/manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ import { addons } from 'storybook/manager-api';
import yourTheme from './theme';

addons.setConfig({
theme: yourTheme,
});
theme: yourTheme,
});
36 changes: 30 additions & 6 deletions .storybook/preview.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React from 'react';
import React, { useEffect } from 'react';
import 'react-loading-skeleton/dist/skeleton.css';
import type { Preview } from '@storybook/react-vite';

Expand All @@ -16,11 +16,35 @@ const GlobalStyles = createGlobalStyle`
const preview: Preview = {
// tags: ['autodocs'], // turn on when fix some components stories
decorators: [
(Story) => (
<ThemeProvider theme={themeConfig}>
<Story />
</ThemeProvider>
),
(Story) => {
useEffect(() => {
// Google Analytics tracking code
const script = document.createElement('script');
script.async = true;
script.src = 'https://www.googletagmanager.com/gtag/js?id=G-H4X1J4017T'; // Replace with your GA4 Measurement ID
document.head.appendChild(script);

script.onload = () => {
window.dataLayer = window.dataLayer || [];
function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());
gtag('config', 'G-H4X1J4017T'); // Replace with your GA4 Measurement ID
};

return () => {
// Optional: Clean up the script if needed
document.head.removeChild(script);
};
}, []);

return (
<ThemeProvider theme={themeConfig}>
<Story />
</ThemeProvider>
);
},
withThemeFromJSXProvider({
themes: {
light: themeConfig.light,
Expand Down
4 changes: 2 additions & 2 deletions dist/lib/components/cspr/cspr.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ export interface CsprProps {
precisionCase?: PrecisionCase;
hideCsprCurrency?: boolean;
}
export declare function Cspr({ motes, precisionCase, hideCsprCurrency }: CsprProps): import("react/jsx-runtime").JSX.Element;
export default Cspr;
export declare function CSPR({ motes, precisionCase, hideCsprCurrency }: CsprProps): import("react/jsx-runtime").JSX.Element;
export default CSPR;
//# sourceMappingURL=cspr.d.ts.map
Binary file modified favicon-16x16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified favicon-32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified favicon.ico
Binary file not shown.
8 changes: 4 additions & 4 deletions manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
"type": "image/x-icon"
},
{
"src": "favicon-16x16.png",
"type": "image/png",
"src": "favicon-16x16.svg",
"type": "image/svg",
"sizes": "192x192"
},
{
"src": "favicon-32x32.png",
"type": "image/png",
"src": "favicon-32x32.svg",
"type": "image/svg",
"sizes": "512x512"
}
],
Expand Down
Loading