Skip to content

Commit a2e05ba

Browse files
authored
Merge pull request #8 from make-software/component-reorganisation
Component reorganisation
2 parents 61259d9 + c193ceb commit a2e05ba

File tree

86 files changed

+1318
-525
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

86 files changed

+1318
-525
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,4 @@ yarn-error.log*
2525
/src/stories/
2626

2727
*storybook.log
28+
/dist/

.storybook/manager.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@ import { addons } from 'storybook/manager-api';
22
import yourTheme from './theme';
33

44
addons.setConfig({
5-
theme: yourTheme,
6-
});
5+
theme: yourTheme,
6+
});

.storybook/preview.tsx

Lines changed: 30 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React from 'react';
1+
import React, { useEffect } from 'react';
22
import 'react-loading-skeleton/dist/skeleton.css';
33
import type { Preview } from '@storybook/react-vite';
44

@@ -16,11 +16,35 @@ const GlobalStyles = createGlobalStyle`
1616
const preview: Preview = {
1717
// tags: ['autodocs'], // turn on when fix some components stories
1818
decorators: [
19-
(Story) => (
20-
<ThemeProvider theme={themeConfig}>
21-
<Story />
22-
</ThemeProvider>
23-
),
19+
(Story) => {
20+
useEffect(() => {
21+
// Google Analytics tracking code
22+
const script = document.createElement('script');
23+
script.async = true;
24+
script.src = 'https://www.googletagmanager.com/gtag/js?id=G-H4X1J4017T'; // Replace with your GA4 Measurement ID
25+
document.head.appendChild(script);
26+
27+
script.onload = () => {
28+
window.dataLayer = window.dataLayer || [];
29+
function gtag() {
30+
dataLayer.push(arguments);
31+
}
32+
gtag('js', new Date());
33+
gtag('config', 'G-H4X1J4017T'); // Replace with your GA4 Measurement ID
34+
};
35+
36+
return () => {
37+
// Optional: Clean up the script if needed
38+
document.head.removeChild(script);
39+
};
40+
}, []);
41+
42+
return (
43+
<ThemeProvider theme={themeConfig}>
44+
<Story />
45+
</ThemeProvider>
46+
);
47+
},
2448
withThemeFromJSXProvider({
2549
themes: {
2650
light: themeConfig.light,

dist/lib/components/cspr/cspr.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ export interface CsprProps {
44
precisionCase?: PrecisionCase;
55
hideCsprCurrency?: boolean;
66
}
7-
export declare function Cspr({ motes, precisionCase, hideCsprCurrency }: CsprProps): import("react/jsx-runtime").JSX.Element;
8-
export default Cspr;
7+
export declare function CSPR({ motes, precisionCase, hideCsprCurrency }: CsprProps): import("react/jsx-runtime").JSX.Element;
8+
export default CSPR;
99
//# sourceMappingURL=cspr.d.ts.map

favicon-16x16.png

1.61 KB
Loading

favicon-32x32.png

1.21 KB
Loading

favicon.ico

852 Bytes
Binary file not shown.

manifest.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@
88
"type": "image/x-icon"
99
},
1010
{
11-
"src": "favicon-16x16.png",
12-
"type": "image/png",
11+
"src": "favicon-16x16.svg",
12+
"type": "image/svg",
1313
"sizes": "192x192"
1414
},
1515
{
16-
"src": "favicon-32x32.png",
17-
"type": "image/png",
16+
"src": "favicon-32x32.svg",
17+
"type": "image/svg",
1818
"sizes": "512x512"
1919
}
2020
],

0 commit comments

Comments
 (0)