@common-stack/generate-plugin 8.2.2-alpha.0 → 8.2.2-alpha.2
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/CHANGELOG.md +8 -0
- package/lib/generators/add-backend/files/package.json +1 -1
- package/lib/generators/add-frontend/frameworks/tailwindui/src/entry.client.tsx.template +11 -15
- package/lib/generators/add-frontend/frameworks/tailwindui/src/entry.server.tsx.template +9 -10
- package/lib/generators/add-frontend/frameworks/tailwindui/src/root.tsx.template +68 -42
- package/lib/generators/add-frontend/frameworks/tailwindui/tailwind.config.ts.template +288 -9
- package/lib/generators/add-frontend/templates/package.json +3 -7
- package/lib/generators/add-frontend/templates/server.js +11 -10
- package/lib/generators/add-frontend/templates/src/routes.ts.template +38 -0
- package/lib/generators/add-frontend/templates/vite.config.ts.template +91 -48
- package/lib/generators/add-fullstack/files/package.json +3 -3
- package/lib/generators/add-moleculer/files/package.json +5 -5
- package/lib/generators/add-package/files/browser/package.json +1 -1
- package/lib/generators/add-package/files/server/package.json +3 -3
- package/package.json +3 -3
- package/src/generators/add-backend/files/package.json +1 -1
- package/src/generators/add-frontend/frameworks/tailwindui/src/entry.client.tsx.template +11 -15
- package/src/generators/add-frontend/frameworks/tailwindui/src/entry.server.tsx.template +9 -10
- package/src/generators/add-frontend/frameworks/tailwindui/src/root.tsx.template +68 -42
- package/src/generators/add-frontend/frameworks/tailwindui/tailwind.config.ts.template +288 -9
- package/src/generators/add-frontend/templates/package.json +3 -7
- package/src/generators/add-frontend/templates/server.js +11 -10
- package/src/generators/add-frontend/templates/src/routes.ts.template +38 -0
- package/src/generators/add-frontend/templates/vite.config.ts.template +91 -48
- package/src/generators/add-fullstack/files/package.json +3 -3
- package/src/generators/add-moleculer/files/package.json +5 -5
- package/src/generators/add-package/files/browser/package.json +1 -1
- package/src/generators/add-package/files/server/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,14 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [8.2.2-alpha.2](https://github.com/cdmbase/common-stack/compare/v8.2.2-alpha.1...v8.2.2-alpha.2) (2025-11-29)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @common-stack/generate-plugin
|
|
9
|
+
|
|
10
|
+
## [8.2.2-alpha.1](https://github.com/cdmbase/common-stack/compare/v8.2.2-alpha.0...v8.2.2-alpha.1) (2025-11-28)
|
|
11
|
+
|
|
12
|
+
**Note:** Version bump only for package @common-stack/generate-plugin
|
|
13
|
+
|
|
6
14
|
## [8.2.2-alpha.0](https://github.com/cdmbase/common-stack/compare/v7.2.1-alpha.82...v8.2.2-alpha.0) (2025-11-25)
|
|
7
15
|
|
|
8
16
|
**Note:** Version bump only for package @common-stack/generate-plugin
|
|
@@ -64,7 +64,7 @@
|
|
|
64
64
|
"dependencies": {
|
|
65
65
|
"@apollo/client": "^3.9.0",
|
|
66
66
|
"@babel/runtime": "^7.20.1",
|
|
67
|
-
"@common-stack/server-stack": "
|
|
67
|
+
"@common-stack/server-stack": "8.2.2-alpha.1",
|
|
68
68
|
"@remix-run/node": "~2.15.3",
|
|
69
69
|
"lodash": "^4.17.15",
|
|
70
70
|
"react": "18.2.0"
|
|
@@ -55,21 +55,17 @@ async function hydrate() {
|
|
|
55
55
|
startTransition(() => {
|
|
56
56
|
hydrateRoot(
|
|
57
57
|
document,
|
|
58
|
-
|
|
59
|
-
<
|
|
60
|
-
<
|
|
61
|
-
<
|
|
62
|
-
<
|
|
63
|
-
<
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
</ReduxProvider>
|
|
70
|
-
</StrictMode>
|
|
71
|
-
</I18nextProvider>
|
|
72
|
-
) as any,
|
|
58
|
+
<I18nextProvider i18n={i18next}>
|
|
59
|
+
<ReduxProvider store={store}>
|
|
60
|
+
<SlotFillProvider>
|
|
61
|
+
<InversifyProvider container={container} modules={clientModules}>
|
|
62
|
+
<ApolloProvider client={client}>
|
|
63
|
+
<RemixBrowser />
|
|
64
|
+
</ApolloProvider>
|
|
65
|
+
</InversifyProvider>
|
|
66
|
+
</SlotFillProvider>
|
|
67
|
+
</ReduxProvider>
|
|
68
|
+
</I18nextProvider>,
|
|
73
69
|
);
|
|
74
70
|
});
|
|
75
71
|
}
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* For more information, see https://remix.run/file-conventions/entry.server
|
|
5
5
|
*/
|
|
6
6
|
import * as React from 'react';
|
|
7
|
+
import 'reflect-metadata';
|
|
7
8
|
(global as any).__CLIENT__ = false;
|
|
8
9
|
(global as any).__SERVER__ = true;
|
|
9
10
|
import { PassThrough, Transform } from 'node:stream';
|
|
@@ -28,7 +29,8 @@ import config from '@app/cde-webconfig.json';
|
|
|
28
29
|
// @ts-ignore
|
|
29
30
|
import type { IAppLoadContext } from '@common-stack/client-core';
|
|
30
31
|
|
|
31
|
-
|
|
32
|
+
// Reject/cancel all pending promises after 5 seconds
|
|
33
|
+
export const streamTimeout = 5000;
|
|
32
34
|
|
|
33
35
|
class ConstantsTransform extends Transform {
|
|
34
36
|
_fills: string[];
|
|
@@ -120,7 +122,7 @@ function handleBotRequest(
|
|
|
120
122
|
let shellRendered = false;
|
|
121
123
|
const { pipe, abort } = renderToPipeableStream(
|
|
122
124
|
<I18nextProvider i18n={i18nInstance}>
|
|
123
|
-
<RemixServer context={remixContext} url={request.url}
|
|
125
|
+
<RemixServer context={remixContext} url={request.url} />
|
|
124
126
|
</I18nextProvider>,
|
|
125
127
|
{
|
|
126
128
|
onAllReady() {
|
|
@@ -154,7 +156,7 @@ function handleBotRequest(
|
|
|
154
156
|
},
|
|
155
157
|
);
|
|
156
158
|
|
|
157
|
-
setTimeout(abort,
|
|
159
|
+
setTimeout(abort, streamTimeout + 1000);
|
|
158
160
|
});
|
|
159
161
|
}
|
|
160
162
|
|
|
@@ -184,11 +186,7 @@ function handleBrowserRequest(
|
|
|
184
186
|
<SlotFillProvider context={slotFillContext}>
|
|
185
187
|
<InversifyProvider container={container} modules={clientModules as any}>
|
|
186
188
|
<ApolloProvider client={client}>
|
|
187
|
-
<RemixServer
|
|
188
|
-
context={remixContext}
|
|
189
|
-
url={request.url}
|
|
190
|
-
abortDelay={ABORT_DELAY}
|
|
191
|
-
/>
|
|
189
|
+
<RemixServer context={remixContext} url={request.url} />
|
|
192
190
|
</ApolloProvider>
|
|
193
191
|
</InversifyProvider>
|
|
194
192
|
</SlotFillProvider>
|
|
@@ -203,8 +201,9 @@ function handleBrowserRequest(
|
|
|
203
201
|
const apolloState = { ...client.extract() };
|
|
204
202
|
const reduxState = { ...store.getState() };
|
|
205
203
|
const fills = Object.keys(slotFillContext.fills);
|
|
204
|
+
const styleSheet = '';
|
|
206
205
|
|
|
207
|
-
const transform = new ConstantsTransform(fills, apolloState, reduxState,
|
|
206
|
+
const transform = new ConstantsTransform(fills, apolloState, reduxState, styleSheet);
|
|
208
207
|
|
|
209
208
|
responseHeaders.set('Content-Type', 'text/html');
|
|
210
209
|
|
|
@@ -233,6 +232,6 @@ function handleBrowserRequest(
|
|
|
233
232
|
},
|
|
234
233
|
);
|
|
235
234
|
|
|
236
|
-
setTimeout(abort,
|
|
235
|
+
setTimeout(abort, streamTimeout + 1000);
|
|
237
236
|
});
|
|
238
237
|
}
|
|
@@ -1,27 +1,38 @@
|
|
|
1
1
|
import 'reflect-metadata';
|
|
2
2
|
import * as React from 'react';
|
|
3
|
-
import {
|
|
4
|
-
|
|
3
|
+
import {
|
|
4
|
+
Links,
|
|
5
|
+
Meta,
|
|
6
|
+
Outlet,
|
|
7
|
+
Scripts,
|
|
8
|
+
ScrollRestoration,
|
|
9
|
+
useLoaderData,
|
|
10
|
+
useRouteError,
|
|
11
|
+
useRouteLoaderData,
|
|
12
|
+
data,
|
|
13
|
+
} from '@remix-run/react';
|
|
5
14
|
// @ts-ignore
|
|
6
15
|
import publicEnv from '@src/config/public-config';
|
|
7
16
|
import { PluginArea } from '@common-stack/client-react';
|
|
8
17
|
import { subscribeReduxRouter } from '@common-stack/remix-router-redux';
|
|
18
|
+
import { ApplicationErrorHandler, RemixErrorBoundary as ErrorBoundary } from '@admin-layout/tailwind-ui';
|
|
9
19
|
// @ts-ignore
|
|
10
20
|
import clientModules, { plugins } from '@app/frontend-stack-react/modules.js';
|
|
11
21
|
// @ts-ignore
|
|
12
22
|
import { useChangeLanguage } from 'remix-i18next/react';
|
|
13
23
|
import { useTranslation } from 'react-i18next';
|
|
24
|
+
// @ts-ignore
|
|
25
|
+
import { i18nextInstance as i18next } from '@app/frontend-stack-react/i18n-localization/i18next.server.js';
|
|
14
26
|
import { LayoutCookieProvider } from '@admin-layout/client';
|
|
15
27
|
import { settingsLoaderUtil } from '@admin-layout/client/lib/components/UpdateSettings/UpdateSettings.server';
|
|
16
|
-
import { IAppLoadContext
|
|
28
|
+
import type { IAppLoadContext } from '@common-stack/client-core';
|
|
29
|
+
import type { IResourceParams } from '@common-stack/core';
|
|
17
30
|
import { FillRenderProvider, PluginsLoader } from '@common-stack/components-pro';
|
|
18
|
-
// @ts-ignore
|
|
19
|
-
import { i18nextInstance as i18next } from '@app/frontend-stack-react/i18n-localization/i18next.server.js';
|
|
20
|
-
import stylesheet from "./tailwind.css?url";
|
|
21
31
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
32
|
+
// eslint-disable-next-line import/no-unresolved
|
|
33
|
+
import styles from '../tailwind.css?url';
|
|
34
|
+
|
|
35
|
+
export const links = () => [{ rel: 'stylesheet', href: styles }];
|
|
25
36
|
|
|
26
37
|
export const loader = async ({
|
|
27
38
|
request,
|
|
@@ -32,37 +43,49 @@ export const loader = async ({
|
|
|
32
43
|
context: IAppLoadContext;
|
|
33
44
|
params: IResourceParams;
|
|
34
45
|
}) => {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
46
|
+
// Fetch settings with error handling - don't let settings failures break the app
|
|
47
|
+
let settingsResponse: any = {};
|
|
48
|
+
try {
|
|
49
|
+
settingsResponse =
|
|
50
|
+
(await settingsLoaderUtil({
|
|
51
|
+
request,
|
|
52
|
+
context,
|
|
53
|
+
params,
|
|
54
|
+
})) || {};
|
|
55
|
+
} catch (error) {
|
|
56
|
+
console.error('❌ Failed to load settings, using defaults:', error);
|
|
57
|
+
// Continue without settings - the app should still work
|
|
58
|
+
}
|
|
38
59
|
|
|
39
|
-
|
|
60
|
+
const [locale] = await Promise.all([i18next.getLocale(request)]);
|
|
61
|
+
const loadedPlugins = await PluginsLoader(plugins, { request, context, params });
|
|
62
|
+
return data(
|
|
40
63
|
{
|
|
41
64
|
__ENV__: publicEnv,
|
|
42
65
|
locale,
|
|
43
|
-
settings: settingsResponse?.settings,
|
|
66
|
+
settings: settingsResponse?.settings || {},
|
|
44
67
|
loadedPlugins,
|
|
45
68
|
},
|
|
46
69
|
{
|
|
47
70
|
headers: [
|
|
48
71
|
['Cache-Control', 'max-age=300, s-maxage=600'],
|
|
49
|
-
['Set-Cookie', settingsResponse
|
|
50
|
-
],
|
|
72
|
+
settingsResponse?.setCookie ? ['Set-Cookie', settingsResponse.setCookie] : null,
|
|
73
|
+
].filter(Boolean) as [string, string][],
|
|
51
74
|
},
|
|
52
75
|
);
|
|
53
76
|
};
|
|
54
77
|
|
|
55
78
|
export const handle = {
|
|
56
|
-
i18n: 'common',
|
|
79
|
+
i18n: ['common', 'translations', 'projects'],
|
|
57
80
|
};
|
|
58
81
|
|
|
59
|
-
export
|
|
60
|
-
return params.defaultShouldRevalidate && params.currentUrl.pathname !== params.nextUrl.pathname;
|
|
61
|
-
}
|
|
82
|
+
export const shouldRevalidate = () => false;
|
|
62
83
|
|
|
63
84
|
export function Layout({ children }: { children: React.ReactNode }) {
|
|
64
|
-
|
|
65
|
-
|
|
85
|
+
// useLoaderData is for happy paths with Error boundary it will fail
|
|
86
|
+
// https://github.com/remix-run/remix/issues/8951#issuecomment-1973321870
|
|
87
|
+
const loaderData = useRouteLoaderData<{ locale: any; __ENV__?: any }>('root');
|
|
88
|
+
const locale = loaderData?.locale || 'en';
|
|
66
89
|
|
|
67
90
|
const { i18n } = useTranslation();
|
|
68
91
|
|
|
@@ -78,7 +101,7 @@ export function Layout({ children }: { children: React.ReactNode }) {
|
|
|
78
101
|
<>
|
|
79
102
|
<script
|
|
80
103
|
dangerouslySetInnerHTML={{
|
|
81
|
-
__html: `window.__ENV__ = ${JSON.stringify((
|
|
104
|
+
__html: `window.__ENV__ = ${JSON.stringify((loaderData as any)?.__ENV__ || {})}`,
|
|
82
105
|
}}
|
|
83
106
|
/>
|
|
84
107
|
<script
|
|
@@ -106,15 +129,28 @@ export function Layout({ children }: { children: React.ReactNode }) {
|
|
|
106
129
|
<head>
|
|
107
130
|
<meta charSet="utf-8" />
|
|
108
131
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
132
|
+
{/* CRITICAL: Load Symbol.observable polyfill BEFORE any other scripts */}
|
|
133
|
+
<script
|
|
134
|
+
dangerouslySetInnerHTML={{
|
|
135
|
+
__html: `
|
|
136
|
+
(function() {
|
|
137
|
+
if (typeof Symbol !== 'undefined' && typeof Symbol.for === 'function') {
|
|
138
|
+
if (!Symbol.observable) {
|
|
139
|
+
Symbol.observable = Symbol.for('observable');
|
|
140
|
+
}
|
|
141
|
+
console.log('[Symbol.observable polyfill] Loaded in head:', Symbol.observable);
|
|
142
|
+
}
|
|
143
|
+
})();
|
|
144
|
+
`,
|
|
145
|
+
}}
|
|
146
|
+
/>
|
|
109
147
|
<Meta />
|
|
110
148
|
<Links />
|
|
111
149
|
{typeof window === 'undefined' ? `[__STYLESHEET__]` : ''}
|
|
112
150
|
</head>
|
|
113
151
|
<body>
|
|
114
152
|
<PluginArea />
|
|
115
|
-
<FillRenderProvider>
|
|
116
|
-
{clientModules.getWrappedRoot(children)}
|
|
117
|
-
</FillRenderProvider>
|
|
153
|
+
<FillRenderProvider>{clientModules.getWrappedRoot(children)}</FillRenderProvider>
|
|
118
154
|
<ScrollRestoration />
|
|
119
155
|
<Scripts />
|
|
120
156
|
{getConstants()}
|
|
@@ -123,24 +159,14 @@ export function Layout({ children }: { children: React.ReactNode }) {
|
|
|
123
159
|
);
|
|
124
160
|
}
|
|
125
161
|
|
|
126
|
-
const TestComponent = () => {
|
|
127
|
-
return (
|
|
128
|
-
<div className="min-h-screen flex items-center justify-center bg-gray-100">
|
|
129
|
-
<div className="p-6 max-w-sm mx-auto bg-white rounded-xl shadow-md space-y-4">
|
|
130
|
-
<h1 className="text-2xl font-bold text-center">Hello, Tailwind CSS!</h1>
|
|
131
|
-
<p className="text-gray-500 text-center">This is a test page using React and Tailwind CSS.</p>
|
|
132
|
-
</div>
|
|
133
|
-
</div>
|
|
134
|
-
);
|
|
135
|
-
}
|
|
136
|
-
|
|
137
162
|
export default function App() {
|
|
138
163
|
return (
|
|
139
|
-
<
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
164
|
+
<ApplicationErrorHandler plugins={plugins}>
|
|
165
|
+
<LayoutCookieProvider>
|
|
166
|
+
<Outlet />
|
|
167
|
+
</LayoutCookieProvider>
|
|
168
|
+
</ApplicationErrorHandler>
|
|
143
169
|
);
|
|
144
170
|
}
|
|
145
171
|
|
|
146
|
-
|
|
172
|
+
export { ErrorBoundary };
|
|
@@ -1,12 +1,291 @@
|
|
|
1
|
-
|
|
1
|
+
/** @type {import('tailwindcss').Config} */
|
|
2
|
+
|
|
3
|
+
import path from 'node:path';
|
|
2
4
|
|
|
3
5
|
export default {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}
|
|
6
|
+
darkMode: ['class'],
|
|
7
|
+
variants: {
|
|
8
|
+
typography: ['dark'],
|
|
9
|
+
},
|
|
10
|
+
content: [
|
|
11
|
+
'./src/**/*.{ts,tsx}',
|
|
12
|
+
'./src/**/{**,.client,.server}/**/*.{js,jsx,ts,tsx}',
|
|
13
|
+
'./app/**/{**,.client,.server}/**/*.{js,jsx,ts,tsx}',
|
|
14
|
+
'./node_modules/@tremor/**/*.{js,ts,jsx,tsx}',
|
|
15
|
+
],
|
|
16
|
+
important: true,
|
|
17
|
+
theme: {
|
|
18
|
+
container: {
|
|
19
|
+
center: true,
|
|
20
|
+
padding: '2rem',
|
|
21
|
+
screens: {
|
|
22
|
+
'2xl': '1400px',
|
|
23
|
+
},
|
|
24
|
+
},
|
|
25
|
+
extend: {
|
|
26
|
+
colors: {
|
|
27
|
+
// light mode
|
|
28
|
+
tremor: {
|
|
29
|
+
brand: {
|
|
30
|
+
faint: '#eff6ff', // blue-50
|
|
31
|
+
muted: '#bfdbfe', // blue-200
|
|
32
|
+
subtle: '#60a5fa', // blue-400
|
|
33
|
+
DEFAULT: '#3b82f6', // blue-500
|
|
34
|
+
emphasis: '#1d4ed8', // blue-700
|
|
35
|
+
inverted: '#ffffff', // white
|
|
36
|
+
},
|
|
37
|
+
background: {
|
|
38
|
+
muted: '#f9fafb', // gray-50
|
|
39
|
+
subtle: '#f3f4f6', // gray-100
|
|
40
|
+
DEFAULT: '#ffffff', // white
|
|
41
|
+
emphasis: '#374151', // gray-700
|
|
42
|
+
},
|
|
43
|
+
border: {
|
|
44
|
+
DEFAULT: '#e5e7eb', // gray-200
|
|
45
|
+
},
|
|
46
|
+
ring: {
|
|
47
|
+
DEFAULT: '#e5e7eb', // gray-200
|
|
48
|
+
},
|
|
49
|
+
content: {
|
|
50
|
+
subtle: '#9ca3af', // gray-400
|
|
51
|
+
DEFAULT: '#6b7280', // gray-500
|
|
52
|
+
emphasis: '#374151', // gray-700
|
|
53
|
+
strong: '#111827', // gray-900
|
|
54
|
+
inverted: '#ffffff', // white
|
|
55
|
+
},
|
|
56
|
+
},
|
|
57
|
+
// dark mode
|
|
58
|
+
'dark-tremor': {
|
|
59
|
+
brand: {
|
|
60
|
+
faint: '#0B1229', // custom
|
|
61
|
+
muted: '#172554', // blue-950
|
|
62
|
+
subtle: '#1e40af', // blue-800
|
|
63
|
+
DEFAULT: '#3b82f6', // blue-500
|
|
64
|
+
emphasis: '#60a5fa', // blue-400
|
|
65
|
+
inverted: '#030712', // gray-950
|
|
66
|
+
},
|
|
67
|
+
background: {
|
|
68
|
+
muted: '#131A2B', // custom
|
|
69
|
+
subtle: '#1f2937', // gray-800
|
|
70
|
+
DEFAULT: '#111827', // gray-900
|
|
71
|
+
emphasis: '#d1d5db', // gray-300
|
|
72
|
+
},
|
|
73
|
+
border: {
|
|
74
|
+
DEFAULT: '#1f2937', // gray-800
|
|
75
|
+
},
|
|
76
|
+
ring: {
|
|
77
|
+
DEFAULT: '#1f2937', // gray-800
|
|
78
|
+
},
|
|
79
|
+
content: {
|
|
80
|
+
subtle: '#4b5563', // gray-600
|
|
81
|
+
DEFAULT: '#6b7280', // gray-600
|
|
82
|
+
emphasis: '#e5e7eb', // gray-200
|
|
83
|
+
strong: '#f9fafb', // gray-50
|
|
84
|
+
inverted: '#000000', // black
|
|
85
|
+
},
|
|
86
|
+
},
|
|
87
|
+
|
|
88
|
+
border: 'hsl(var(--border))',
|
|
89
|
+
input: 'hsl(var(--input))',
|
|
90
|
+
ring: 'hsl(var(--ring))',
|
|
91
|
+
background: 'hsl(var(--background))',
|
|
92
|
+
foreground: 'hsl(var(--foreground))',
|
|
93
|
+
primary: {
|
|
94
|
+
DEFAULT: 'hsl(var(--primary))',
|
|
95
|
+
foreground: 'hsl(var(--primary-foreground))',
|
|
96
|
+
},
|
|
97
|
+
secondary: {
|
|
98
|
+
DEFAULT: 'hsl(var(--secondary))',
|
|
99
|
+
foreground: 'hsl(var(--secondary-foreground))',
|
|
100
|
+
},
|
|
101
|
+
destructive: {
|
|
102
|
+
DEFAULT: 'hsl(var(--destructive))',
|
|
103
|
+
foreground: 'hsl(var(--destructive-foreground))',
|
|
104
|
+
},
|
|
105
|
+
muted: {
|
|
106
|
+
DEFAULT: 'hsl(var(--muted))',
|
|
107
|
+
foreground: 'hsl(var(--muted-foreground))',
|
|
108
|
+
},
|
|
109
|
+
accent: {
|
|
110
|
+
DEFAULT: 'hsl(var(--accent))',
|
|
111
|
+
foreground: 'hsl(var(--accent-foreground))',
|
|
112
|
+
},
|
|
113
|
+
popover: {
|
|
114
|
+
DEFAULT: 'hsl(var(--popover))',
|
|
115
|
+
foreground: 'hsl(var(--popover-foreground))',
|
|
116
|
+
},
|
|
117
|
+
card: {
|
|
118
|
+
DEFAULT: 'hsl(var(--card))',
|
|
119
|
+
foreground: 'hsl(var(--card-foreground))',
|
|
120
|
+
},
|
|
121
|
+
},
|
|
122
|
+
borderRadius: {
|
|
123
|
+
lg: 'var(--radius)',
|
|
124
|
+
md: 'calc(var(--radius) - 2px)',
|
|
125
|
+
sm: 'calc(var(--radius) - 4px)',
|
|
126
|
+
'tremor-small': '0.375rem',
|
|
127
|
+
'tremor-default': '0.5rem',
|
|
128
|
+
'tremor-full': '9999px',
|
|
129
|
+
},
|
|
130
|
+
keyframes: {
|
|
131
|
+
'accordion-down': {
|
|
132
|
+
from: { height: 0 },
|
|
133
|
+
to: { height: 'var(--radix-accordion-content-height)' },
|
|
134
|
+
},
|
|
135
|
+
'accordion-up': {
|
|
136
|
+
from: { height: 'var(--radix-accordion-content-height)' },
|
|
137
|
+
to: { height: 0 },
|
|
138
|
+
},
|
|
139
|
+
grid: {
|
|
140
|
+
'0%': { transform: 'translateY(-50%)' },
|
|
141
|
+
'100%': { transform: 'translateY(0)' },
|
|
142
|
+
},
|
|
143
|
+
marquee: {
|
|
144
|
+
from: { transform: 'translateX(0)' },
|
|
145
|
+
to: { transform: 'translateX(calc(-100% - var(--gap)))' },
|
|
146
|
+
},
|
|
147
|
+
'marquee-vertical': {
|
|
148
|
+
from: { transform: 'translateY(0)' },
|
|
149
|
+
to: { transform: 'translateY(calc(-100% - var(--gap)))' },
|
|
150
|
+
},
|
|
151
|
+
shimmer: {
|
|
152
|
+
from: {
|
|
153
|
+
backgroundPosition: '0 0',
|
|
154
|
+
},
|
|
155
|
+
to: {
|
|
156
|
+
backgroundPosition: '-200% 0',
|
|
157
|
+
},
|
|
158
|
+
},
|
|
159
|
+
'spin-around': {
|
|
160
|
+
'0%': {
|
|
161
|
+
transform: 'translateZ(0) rotate(0)',
|
|
162
|
+
},
|
|
163
|
+
'15%, 35%': {
|
|
164
|
+
transform: 'translateZ(0) rotate(90deg)',
|
|
165
|
+
},
|
|
166
|
+
'65%, 85%': {
|
|
167
|
+
transform: 'translateZ(0) rotate(270deg)',
|
|
168
|
+
},
|
|
169
|
+
'100%': {
|
|
170
|
+
transform: 'translateZ(0) rotate(360deg)',
|
|
171
|
+
},
|
|
172
|
+
},
|
|
173
|
+
slide: {
|
|
174
|
+
to: {
|
|
175
|
+
transform: 'translate(calc(100cqw - 100%), 0)',
|
|
176
|
+
},
|
|
177
|
+
},
|
|
178
|
+
},
|
|
179
|
+
animation: {
|
|
180
|
+
'accordion-down': 'accordion-down 0.2s ease-out',
|
|
181
|
+
'accordion-up': 'accordion-up 0.2s ease-out',
|
|
182
|
+
grid: 'grid 15s linear infinite',
|
|
183
|
+
marquee: 'marquee var(--duration) linear infinite',
|
|
184
|
+
'marquee-vertical': 'marquee-vertical var(--duration) linear infinite',
|
|
185
|
+
shimmer: 'shimmer 2s linear infinite',
|
|
186
|
+
'spin-around': 'spin-around calc(var(--speed) * 2) infinite linear',
|
|
187
|
+
slide: 'slide var(--speed) ease-in-out infinite alternate',
|
|
188
|
+
},
|
|
189
|
+
boxShadow: {
|
|
190
|
+
// light
|
|
191
|
+
'tremor-input': '0 1px 2px 0 rgb(0 0 0 / 0.05)',
|
|
192
|
+
'tremor-card': '0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1)',
|
|
193
|
+
'tremor-dropdown': '0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)',
|
|
194
|
+
// dark
|
|
195
|
+
'dark-tremor-input': '0 1px 2px 0 rgb(0 0 0 / 0.05)',
|
|
196
|
+
'dark-tremor-card': '0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1)',
|
|
197
|
+
'dark-tremor-dropdown': '0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)',
|
|
198
|
+
// custom shadows
|
|
199
|
+
glass: '0 8px 32px 0 rgba(31, 38, 135, 0.37)',
|
|
200
|
+
light: 'rgba(50, 50, 93, 0.25) 0px 6px 12px -2px, rgba(0, 0, 0, 0.3) 0px 3px 7px -3px',
|
|
201
|
+
dark: 'rgba(205, 205, 162, 0.25) 0px 6px 12px -2px, rgba(255,255,255, 0.3) 0px 3px 7px -3px',
|
|
202
|
+
},
|
|
203
|
+
fontSize: {
|
|
204
|
+
'tremor-label': ['0.75rem'],
|
|
205
|
+
'tremor-default': ['0.875rem', { lineHeight: '1.25rem' }],
|
|
206
|
+
'tremor-title': ['1.125rem', { lineHeight: '1.75rem' }],
|
|
207
|
+
'tremor-metric': ['1.875rem', { lineHeight: '2.25rem' }],
|
|
208
|
+
},
|
|
209
|
+
backgroundImage: {
|
|
210
|
+
'gradient-radial': 'radial-gradient(var(--tw-gradient-stops))',
|
|
211
|
+
},
|
|
212
|
+
backdropBlur: {
|
|
213
|
+
glass: '4px',
|
|
214
|
+
},
|
|
215
|
+
},
|
|
216
|
+
},
|
|
217
|
+
safelist: [
|
|
218
|
+
{
|
|
219
|
+
pattern:
|
|
220
|
+
/^(bg-(?:slate|gray|zinc|neutral|stone|red|orange|amber|yellow|lime|green|emerald|teal|cyan|sky|blue|indigo|violet|purple|fuchsia|pink|rose)-(?:50|100|200|300|400|500|600|700|800|900|950))$/,
|
|
221
|
+
variants: ['hover', 'ui-selected'],
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
pattern:
|
|
225
|
+
/^(text-(?:slate|gray|zinc|neutral|stone|red|orange|amber|yellow|lime|green|emerald|teal|cyan|sky|blue|indigo|violet|purple|fuchsia|pink|rose)-(?:50|100|200|300|400|500|600|700|800|900|950))$/,
|
|
226
|
+
variants: ['hover', 'ui-selected'],
|
|
227
|
+
},
|
|
228
|
+
{
|
|
229
|
+
pattern:
|
|
230
|
+
/^(border-(?:slate|gray|zinc|neutral|stone|red|orange|amber|yellow|lime|green|emerald|teal|cyan|sky|blue|indigo|violet|purple|fuchsia|pink|rose)-(?:50|100|200|300|400|500|600|700|800|900|950))$/,
|
|
231
|
+
variants: ['hover', 'ui-selected'],
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
pattern:
|
|
235
|
+
/^(ring-(?:slate|gray|zinc|neutral|stone|red|orange|amber|yellow|lime|green|emerald|teal|cyan|sky|blue|indigo|violet|purple|fuchsia|pink|rose)-(?:50|100|200|300|400|500|600|700|800|900|950))$/,
|
|
236
|
+
},
|
|
237
|
+
{
|
|
238
|
+
pattern:
|
|
239
|
+
/^(stroke-(?:slate|gray|zinc|neutral|stone|red|orange|amber|yellow|lime|green|emerald|teal|cyan|sky|blue|indigo|violet|purple|fuchsia|pink|rose)-(?:50|100|200|300|400|500|600|700|800|900|950))$/,
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
pattern:
|
|
243
|
+
/^(fill-(?:slate|gray|zinc|neutral|stone|red|orange|amber|yellow|lime|green|emerald|teal|cyan|sky|blue|indigo|violet|purple|fuchsia|pink|rose)-(?:50|100|200|300|400|500|600|700|800|900|950))$/,
|
|
244
|
+
},
|
|
245
|
+
// Additional utility classes
|
|
246
|
+
'w-full',
|
|
247
|
+
'max-w-4xl',
|
|
248
|
+
'mx-auto',
|
|
249
|
+
'px-4',
|
|
250
|
+
'animate-fade-in-up-delay-3',
|
|
251
|
+
'animate-fade-in-up-delay-4',
|
|
252
|
+
'bg-white/10',
|
|
253
|
+
'backdrop-blur-lg',
|
|
254
|
+
'rounded-2xl',
|
|
255
|
+
'p-8',
|
|
256
|
+
'text-center',
|
|
257
|
+
'border',
|
|
258
|
+
'border-white/20',
|
|
259
|
+
'text-white',
|
|
260
|
+
'text-2xl',
|
|
261
|
+
'font-semibold',
|
|
262
|
+
'mb-4',
|
|
263
|
+
'text-gray-300',
|
|
264
|
+
'mb-6',
|
|
265
|
+
'bg-white',
|
|
266
|
+
'text-[#1C2536]',
|
|
267
|
+
'px-8',
|
|
268
|
+
'py-3',
|
|
269
|
+
'rounded-full',
|
|
270
|
+
'hover:bg-gray-100',
|
|
271
|
+
'transition-all',
|
|
272
|
+
'duration-300',
|
|
273
|
+
'transform',
|
|
274
|
+
'hover:scale-105',
|
|
275
|
+
'hover:shadow-lg',
|
|
276
|
+
'inline-flex',
|
|
277
|
+
'items-center',
|
|
278
|
+
'gap-2',
|
|
279
|
+
'group',
|
|
280
|
+
'group-hover:translate-x-1',
|
|
281
|
+
'transition-transform',
|
|
282
|
+
'!h-[calc(100vh_-_150px)]',
|
|
283
|
+
],
|
|
284
|
+
plugins: [
|
|
285
|
+
require('tailwindcss-animate'),
|
|
286
|
+
require('@tailwindcss/forms'),
|
|
287
|
+
require('@tailwindcss/aspect-ratio'),
|
|
288
|
+
require('@tailwindcss/typography'),
|
|
289
|
+
],
|
|
290
|
+
};
|
|
12
291
|
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"main": "index.js",
|
|
18
18
|
"scripts": {
|
|
19
19
|
"prebuild": "yarn build:clean && yarn genconfig",
|
|
20
|
-
"build": "cross-env SSR=true NODE_OPTIONS='--max_old_space_size=
|
|
20
|
+
"build": "cross-env SSR=true NODE_OPTIONS='--max_old_space_size=6096' NODE_ENV=production remix vite:build",
|
|
21
21
|
"build:SSR": "cross-env SSR=true NODE_ENV=production remix vite:build",
|
|
22
22
|
"build:clean": "rimraf dist build node_modules/.vite",
|
|
23
23
|
"build:debug": "cross-env DEBUGGING=true NODE_ENV=production remix vite:build",
|
|
@@ -56,16 +56,12 @@
|
|
|
56
56
|
"common": "link:./common"
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
|
-
"@common-stack/frontend-stack-react": "
|
|
59
|
+
"@common-stack/frontend-stack-react": "8.2.2-alpha.1",
|
|
60
60
|
"@react-icons/all-files": "^4.1.0",
|
|
61
61
|
"classnames": "^2.2.6",
|
|
62
|
-
"compression": "^1.7.4",
|
|
63
62
|
"glob-all": "^3.3.1",
|
|
64
63
|
"immutability-helper": "^3.0.1",
|
|
65
64
|
"is-plain-obj": "^3.0.0",
|
|
66
|
-
"isomorphic-fetch": "^2.2.1",
|
|
67
|
-
"lodash": "^4.17.15",
|
|
68
|
-
"lodash-es": "^4.17.21",
|
|
69
65
|
"moment": "2.29.1",
|
|
70
66
|
"ramda": "^0.30.1",
|
|
71
67
|
"react-ga4": "^2.1.0",
|
|
@@ -81,7 +77,7 @@
|
|
|
81
77
|
},
|
|
82
78
|
"devDependencies": {
|
|
83
79
|
"@cdmbase/vite-plugin-i18next-loader": "^2.0.12",
|
|
84
|
-
"@common-stack/rollup-vite-utils": "
|
|
80
|
+
"@common-stack/rollup-vite-utils": "8.2.2-alpha.1",
|
|
85
81
|
"@remix-run/dev": "~2.15.3",
|
|
86
82
|
"@remix-run/serve": "~2.15.3",
|
|
87
83
|
"cross-env": "^7.0.3",
|