@marvalt/digivalt-core 0.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/CHANGELOG.md +17 -0
- package/LICENSE +21 -0
- package/README.md +13 -0
- package/dist/components/WordPressFooter.d.ts +17 -0
- package/dist/components/index.d.ts +9 -0
- package/dist/components/integrations/chatwoot-widget.d.ts +51 -0
- package/dist/components/integrations/mautic-tracking.d.ts +9 -0
- package/dist/components/molecules/CaseStudyCard.d.ts +10 -0
- package/dist/components/molecules/DynamicHeroSection.d.ts +56 -0
- package/dist/components/molecules/MemberCard.d.ts +12 -0
- package/dist/components/molecules/NavMenu.d.ts +13 -0
- package/dist/components/molecules/ProjectCard.d.ts +10 -0
- package/dist/components/molecules/SearchForm.d.ts +7 -0
- package/dist/components/molecules/TestimonialCard/TestimonialCard.d.ts +7 -0
- package/dist/components/molecules/WordPressNavMenu.d.ts +25 -0
- package/dist/components/molecules/breadcrumbs.d.ts +17 -0
- package/dist/components/molecules/hero-section.d.ts +41 -0
- package/dist/components/organisms/GravityFormPopup/GravityFormPopup.d.ts +8 -0
- package/dist/components/organisms/GravityFormSubmissions/GravityFormSubmissionsComponent.d.ts +9 -0
- package/dist/components/organisms/GravityFormSubmissions/index.d.ts +1 -0
- package/dist/components/organisms/Header.d.ts +6 -0
- package/dist/components/organisms/Hero.d.ts +2 -0
- package/dist/components/organisms/MauticForm/MauticForm.d.ts +9 -0
- package/dist/components/organisms/MauticForm/ThemedMauticForm.d.ts +9 -0
- package/dist/components/organisms/MauticForm/index.d.ts +1 -0
- package/dist/components/organisms/MauticFormPopup/MauticFormPopup.d.ts +9 -0
- package/dist/components/organisms/MemberProfileDialog.d.ts +9 -0
- package/dist/components/organisms/StaticGravityForm/StaticGravityForm.d.ts +40 -0
- package/dist/components/organisms/StaticGravityForm/index.d.ts +2 -0
- package/dist/components/organisms/SuiteCRMLeadForm/SuiteCRMLeadForm.d.ts +12 -0
- package/dist/components/organisms/SuiteCRMLeadForm/index.d.ts +2 -0
- package/dist/config/app-customization.d.ts +92 -0
- package/dist/config/environment.d.ts +69 -0
- package/dist/config/index.d.ts +2 -0
- package/dist/config/integrations.d.ts +234 -0
- package/dist/config/themes.d.ts +30 -0
- package/dist/config/widths.d.ts +47 -0
- package/dist/data/gravityFormsDataStore.d.ts +83 -0
- package/dist/data/mauticDataStore.d.ts +17 -0
- package/dist/data/mauticDataStoreTest.d.ts +48 -0
- package/dist/data/staticDataStore.d.ts +280 -0
- package/dist/data/staticDataStore.local.d.ts +251 -0
- package/dist/data/staticDataStoreProduction.d.ts +3 -0
- package/dist/data/wordpressDataStore.d.ts +117 -0
- package/dist/generators/gf.d.ts +3 -0
- package/dist/generators/index.d.ts +5 -0
- package/dist/generators/mautic.d.ts +3 -0
- package/dist/generators/suitecrm.d.ts +3 -0
- package/dist/generators/wp.d.ts +3 -0
- package/dist/hooks/use-mobile.d.ts +1 -0
- package/dist/hooks/use-toast.d.ts +43 -0
- package/dist/hooks/useCaseStudies.d.ts +30 -0
- package/dist/hooks/useCfWpWebhook.d.ts +29 -0
- package/dist/hooks/useCustomization.d.ts +71 -0
- package/dist/hooks/useGravityForms.d.ts +50 -0
- package/dist/hooks/useGravityFormsNew.d.ts +27 -0
- package/dist/hooks/useGravityFormsSubmissions.d.ts +15 -0
- package/dist/hooks/useMautic.d.ts +36 -0
- package/dist/hooks/useMembers.d.ts +31 -0
- package/dist/hooks/useProjects.d.ts +30 -0
- package/dist/hooks/useSuiteCRM.d.ts +72 -0
- package/dist/hooks/useTestimonials.d.ts +12 -0
- package/dist/hooks/useWordPressData.d.ts +115 -0
- package/dist/hooks/useWordPressDataNew.d.ts +77 -0
- package/dist/index.cjs +10433 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.ts +1352 -0
- package/dist/index.esm.js +10404 -0
- package/dist/index.esm.js.map +1 -0
- package/dist/lib/structured-data.d.ts +49 -0
- package/dist/lib/utils.d.ts +42 -0
- package/dist/services/cf-wp-webhook.d.ts +79 -0
- package/dist/services/gravityForms.d.ts +26 -0
- package/dist/services/index.d.ts +5 -0
- package/dist/services/mautic.d.ts +82 -0
- package/dist/services/suitecrm.d.ts +98 -0
- package/dist/services/wordpress.d.ts +1 -0
- package/dist/static/wpStatic.d.ts +189 -0
- package/dist/types/caseStudies.d.ts +92 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/members.d.ts +85 -0
- package/dist/types/projects.d.ts +90 -0
- package/dist/types/wordpress.d.ts +132 -0
- package/dist/utils/cfImages.d.ts +21 -0
- package/dist/utils/eventStaticData.d.ts +11 -0
- package/dist/utils/extractDescriptionFromContent.d.ts +12 -0
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/mauticTrackingUtils.d.ts +78 -0
- package/dist/utils/memberImageUtils.d.ts +4 -0
- package/dist/utils/memberStaticData.d.ts +11 -0
- package/dist/utils/normalizeMemberForProfile.d.ts +10 -0
- package/dist/utils/passwordUtils.d.ts +24 -0
- package/dist/utils/placeholderReplacer.d.ts +34 -0
- package/dist/utils/testimonialStaticData.d.ts +12 -0
- package/dist/utils/wpRegistry.d.ts +13 -0
- package/package.json +69 -0
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
export interface EnvironmentConfig {
|
|
2
|
+
mode: 'local' | 'remote' | 'production' | 'error';
|
|
3
|
+
authMode: 'direct' | 'cloudflare_proxy' | 'supabase_proxy' | 'error';
|
|
4
|
+
dataSource: 'static' | 'dynamic' | 'hybrid';
|
|
5
|
+
baseUrl: string;
|
|
6
|
+
headers: Record<string, string>;
|
|
7
|
+
description: string;
|
|
8
|
+
mautic?: {
|
|
9
|
+
url?: string;
|
|
10
|
+
proxyUrl?: string;
|
|
11
|
+
appId?: string;
|
|
12
|
+
workerSecret?: string;
|
|
13
|
+
};
|
|
14
|
+
suiteCRM: {
|
|
15
|
+
url?: string;
|
|
16
|
+
proxyUrl?: string;
|
|
17
|
+
appId?: string;
|
|
18
|
+
workerSecret?: string;
|
|
19
|
+
oauth2?: {
|
|
20
|
+
clientId?: string;
|
|
21
|
+
clientSecret?: string;
|
|
22
|
+
username?: string;
|
|
23
|
+
password?: string;
|
|
24
|
+
tokenUrl?: string;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
export interface DevelopmentConfig {
|
|
29
|
+
local: EnvironmentConfig;
|
|
30
|
+
remote: EnvironmentConfig;
|
|
31
|
+
production: EnvironmentConfig;
|
|
32
|
+
}
|
|
33
|
+
export declare const getEnvironmentConfig: () => EnvironmentConfig;
|
|
34
|
+
export declare const getDevelopmentConfigs: () => DevelopmentConfig;
|
|
35
|
+
export declare const getEnvironmentStatus: () => {
|
|
36
|
+
currentConfig: EnvironmentConfig;
|
|
37
|
+
diagnostics: {
|
|
38
|
+
isLocalDevelopment: boolean;
|
|
39
|
+
authMode: string;
|
|
40
|
+
hasCloudflareCredentials: boolean;
|
|
41
|
+
hasWordpressApiUrl: boolean;
|
|
42
|
+
cloudflareWorkerUrl: boolean;
|
|
43
|
+
cfAccessId: boolean;
|
|
44
|
+
cfAccessSecret: boolean;
|
|
45
|
+
mauticProxyUrl: boolean;
|
|
46
|
+
};
|
|
47
|
+
recommendations: {
|
|
48
|
+
authMode: any;
|
|
49
|
+
cloudflare: any;
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
export declare const currentEnv: EnvironmentConfig;
|
|
53
|
+
export declare const envStatus: {
|
|
54
|
+
currentConfig: EnvironmentConfig;
|
|
55
|
+
diagnostics: {
|
|
56
|
+
isLocalDevelopment: boolean;
|
|
57
|
+
authMode: string;
|
|
58
|
+
hasCloudflareCredentials: boolean;
|
|
59
|
+
hasWordpressApiUrl: boolean;
|
|
60
|
+
cloudflareWorkerUrl: boolean;
|
|
61
|
+
cfAccessId: boolean;
|
|
62
|
+
cfAccessSecret: boolean;
|
|
63
|
+
mauticProxyUrl: boolean;
|
|
64
|
+
};
|
|
65
|
+
recommendations: {
|
|
66
|
+
authMode: any;
|
|
67
|
+
cloudflare: any;
|
|
68
|
+
};
|
|
69
|
+
};
|
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Integration Configuration
|
|
3
|
+
* Centralized configuration for all third-party integrations
|
|
4
|
+
*/
|
|
5
|
+
export interface IntegrationConfig {
|
|
6
|
+
wordpress: {
|
|
7
|
+
enabled: boolean;
|
|
8
|
+
apiUrl: string;
|
|
9
|
+
authMode: 'direct' | 'supabase_proxy';
|
|
10
|
+
wpAuthToken?: string;
|
|
11
|
+
};
|
|
12
|
+
supabase: {
|
|
13
|
+
enabled: boolean;
|
|
14
|
+
url: string;
|
|
15
|
+
anonKey: string;
|
|
16
|
+
serviceRoleKey?: string;
|
|
17
|
+
};
|
|
18
|
+
gravityForms: {
|
|
19
|
+
enabled: boolean;
|
|
20
|
+
url?: string;
|
|
21
|
+
proxyUrl?: string;
|
|
22
|
+
consumerKey?: string;
|
|
23
|
+
consumerSecret?: string;
|
|
24
|
+
frontendSecret?: string;
|
|
25
|
+
forms: {
|
|
26
|
+
[formId: string]: {
|
|
27
|
+
name: string;
|
|
28
|
+
type: 'contact' | 'lead' | 'newsletter' | 'support' | 'custom';
|
|
29
|
+
redirectUrl?: string;
|
|
30
|
+
successMessage?: string;
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
mautic: {
|
|
35
|
+
enabled: boolean;
|
|
36
|
+
url?: string;
|
|
37
|
+
proxyUrl?: string;
|
|
38
|
+
apiPublicKey?: string;
|
|
39
|
+
apiSecretKey?: string;
|
|
40
|
+
appId?: string;
|
|
41
|
+
workerSecret?: string;
|
|
42
|
+
forms: {
|
|
43
|
+
[formId: string]: {
|
|
44
|
+
name: string;
|
|
45
|
+
type: 'newsletter' | 'lead' | 'contact' | 'custom';
|
|
46
|
+
redirectUrl?: string;
|
|
47
|
+
successMessage?: string;
|
|
48
|
+
postAction?: 'message' | 'redirect' | 'return';
|
|
49
|
+
postActionProperty?: string;
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
suiteCRM: {
|
|
54
|
+
enabled: boolean;
|
|
55
|
+
url?: string;
|
|
56
|
+
proxyUrl?: string;
|
|
57
|
+
appId?: string;
|
|
58
|
+
workerSecret?: string;
|
|
59
|
+
oauth2?: {
|
|
60
|
+
clientId?: string;
|
|
61
|
+
clientSecret?: string;
|
|
62
|
+
username?: string;
|
|
63
|
+
password?: string;
|
|
64
|
+
tokenUrl?: string;
|
|
65
|
+
};
|
|
66
|
+
};
|
|
67
|
+
chatwoot: {
|
|
68
|
+
enabled: boolean;
|
|
69
|
+
websiteToken: string;
|
|
70
|
+
baseUrl: string;
|
|
71
|
+
locale: string;
|
|
72
|
+
type: 'standard' | 'expanded_bubble';
|
|
73
|
+
launcherTitle: string;
|
|
74
|
+
hideMessageBubble: boolean;
|
|
75
|
+
position: 'left' | 'right';
|
|
76
|
+
showPopoutButton: boolean;
|
|
77
|
+
};
|
|
78
|
+
analytics: {
|
|
79
|
+
googleAnalytics: {
|
|
80
|
+
enabled: boolean;
|
|
81
|
+
measurementId?: string;
|
|
82
|
+
};
|
|
83
|
+
googleTagManager: {
|
|
84
|
+
enabled: boolean;
|
|
85
|
+
containerId?: string;
|
|
86
|
+
};
|
|
87
|
+
facebookPixel: {
|
|
88
|
+
enabled: boolean;
|
|
89
|
+
pixelId?: string;
|
|
90
|
+
};
|
|
91
|
+
linkedinInsight: {
|
|
92
|
+
enabled: boolean;
|
|
93
|
+
partnerId?: string;
|
|
94
|
+
};
|
|
95
|
+
};
|
|
96
|
+
seo: {
|
|
97
|
+
defaultTitle: string;
|
|
98
|
+
defaultDescription: string;
|
|
99
|
+
defaultImage: string;
|
|
100
|
+
siteName: string;
|
|
101
|
+
siteUrl: string;
|
|
102
|
+
twitterHandle?: string;
|
|
103
|
+
facebookAppId?: string;
|
|
104
|
+
googleSiteVerification?: string;
|
|
105
|
+
bingSiteVerification?: string;
|
|
106
|
+
};
|
|
107
|
+
performance: {
|
|
108
|
+
enableLazyLoading: boolean;
|
|
109
|
+
enableImageOptimization: boolean;
|
|
110
|
+
enableCodeSplitting: boolean;
|
|
111
|
+
enableServiceWorker: boolean;
|
|
112
|
+
enableCaching: boolean;
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* Get integration configuration with environment variable fallbacks
|
|
117
|
+
*/
|
|
118
|
+
export declare function getIntegrationConfig(): IntegrationConfig;
|
|
119
|
+
/**
|
|
120
|
+
* Validate integration configuration
|
|
121
|
+
* Only validates integrations that are actually enabled
|
|
122
|
+
*/
|
|
123
|
+
export declare function validateIntegrationConfig(): string[];
|
|
124
|
+
/**
|
|
125
|
+
* Get specific integration configuration
|
|
126
|
+
*/
|
|
127
|
+
export declare function getWordPressConfig(): {
|
|
128
|
+
enabled: boolean;
|
|
129
|
+
apiUrl: string;
|
|
130
|
+
authMode: "direct" | "supabase_proxy";
|
|
131
|
+
wpAuthToken?: string;
|
|
132
|
+
};
|
|
133
|
+
export declare function getSupabaseConfig(): {
|
|
134
|
+
enabled: boolean;
|
|
135
|
+
url: string;
|
|
136
|
+
anonKey: string;
|
|
137
|
+
serviceRoleKey?: string;
|
|
138
|
+
};
|
|
139
|
+
export declare function getGravityFormsConfig(): {
|
|
140
|
+
enabled: boolean;
|
|
141
|
+
url?: string;
|
|
142
|
+
proxyUrl?: string;
|
|
143
|
+
consumerKey?: string;
|
|
144
|
+
consumerSecret?: string;
|
|
145
|
+
frontendSecret?: string;
|
|
146
|
+
forms: {
|
|
147
|
+
[formId: string]: {
|
|
148
|
+
name: string;
|
|
149
|
+
type: "contact" | "lead" | "newsletter" | "support" | "custom";
|
|
150
|
+
redirectUrl?: string;
|
|
151
|
+
successMessage?: string;
|
|
152
|
+
};
|
|
153
|
+
};
|
|
154
|
+
};
|
|
155
|
+
export declare function getMauticConfig(): {
|
|
156
|
+
enabled: boolean;
|
|
157
|
+
url?: string;
|
|
158
|
+
proxyUrl?: string;
|
|
159
|
+
apiPublicKey?: string;
|
|
160
|
+
apiSecretKey?: string;
|
|
161
|
+
appId?: string;
|
|
162
|
+
workerSecret?: string;
|
|
163
|
+
forms: {
|
|
164
|
+
[formId: string]: {
|
|
165
|
+
name: string;
|
|
166
|
+
type: "newsletter" | "lead" | "contact" | "custom";
|
|
167
|
+
redirectUrl?: string;
|
|
168
|
+
successMessage?: string;
|
|
169
|
+
postAction?: "message" | "redirect" | "return";
|
|
170
|
+
postActionProperty?: string;
|
|
171
|
+
};
|
|
172
|
+
};
|
|
173
|
+
};
|
|
174
|
+
export declare function getSuiteCRMConfig(): {
|
|
175
|
+
enabled: boolean;
|
|
176
|
+
url?: string;
|
|
177
|
+
proxyUrl?: string;
|
|
178
|
+
appId?: string;
|
|
179
|
+
workerSecret?: string;
|
|
180
|
+
oauth2?: {
|
|
181
|
+
clientId?: string;
|
|
182
|
+
clientSecret?: string;
|
|
183
|
+
username?: string;
|
|
184
|
+
password?: string;
|
|
185
|
+
tokenUrl?: string;
|
|
186
|
+
};
|
|
187
|
+
};
|
|
188
|
+
export declare function getChatwootConfig(): {
|
|
189
|
+
enabled: boolean;
|
|
190
|
+
websiteToken: string;
|
|
191
|
+
baseUrl: string;
|
|
192
|
+
locale: string;
|
|
193
|
+
type: "standard" | "expanded_bubble";
|
|
194
|
+
launcherTitle: string;
|
|
195
|
+
hideMessageBubble: boolean;
|
|
196
|
+
position: "left" | "right";
|
|
197
|
+
showPopoutButton: boolean;
|
|
198
|
+
};
|
|
199
|
+
export declare function getAnalyticsConfig(): {
|
|
200
|
+
googleAnalytics: {
|
|
201
|
+
enabled: boolean;
|
|
202
|
+
measurementId?: string;
|
|
203
|
+
};
|
|
204
|
+
googleTagManager: {
|
|
205
|
+
enabled: boolean;
|
|
206
|
+
containerId?: string;
|
|
207
|
+
};
|
|
208
|
+
facebookPixel: {
|
|
209
|
+
enabled: boolean;
|
|
210
|
+
pixelId?: string;
|
|
211
|
+
};
|
|
212
|
+
linkedinInsight: {
|
|
213
|
+
enabled: boolean;
|
|
214
|
+
partnerId?: string;
|
|
215
|
+
};
|
|
216
|
+
};
|
|
217
|
+
export declare function getSEOConfig(): {
|
|
218
|
+
defaultTitle: string;
|
|
219
|
+
defaultDescription: string;
|
|
220
|
+
defaultImage: string;
|
|
221
|
+
siteName: string;
|
|
222
|
+
siteUrl: string;
|
|
223
|
+
twitterHandle?: string;
|
|
224
|
+
facebookAppId?: string;
|
|
225
|
+
googleSiteVerification?: string;
|
|
226
|
+
bingSiteVerification?: string;
|
|
227
|
+
};
|
|
228
|
+
export declare function getPerformanceConfig(): {
|
|
229
|
+
enableLazyLoading: boolean;
|
|
230
|
+
enableImageOptimization: boolean;
|
|
231
|
+
enableCodeSplitting: boolean;
|
|
232
|
+
enableServiceWorker: boolean;
|
|
233
|
+
enableCaching: boolean;
|
|
234
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Theme loading and management system
|
|
3
|
+
*
|
|
4
|
+
* Supports:
|
|
5
|
+
* - WordPress themes (from static data)
|
|
6
|
+
* - Custom themes (from src/themes/ directory)
|
|
7
|
+
* - Lovable themes (shadcn/ui format with HSL CSS variables)
|
|
8
|
+
*/
|
|
9
|
+
import type { ThemeStyles, DesignTokens } from '@marvalt/dstyler';
|
|
10
|
+
/**
|
|
11
|
+
* Get WordPress theme styles from static data
|
|
12
|
+
*/
|
|
13
|
+
export declare function getThemeStyles(): ThemeStyles | undefined;
|
|
14
|
+
/**
|
|
15
|
+
* Load custom theme from src/themes/ directory
|
|
16
|
+
*
|
|
17
|
+
* @param themeName - Name of the theme (e.g., 'digivalt_core', 'lovable-demo')
|
|
18
|
+
* @returns DesignTokens or null if theme not found
|
|
19
|
+
*/
|
|
20
|
+
export declare function loadTheme(themeName?: string): Promise<DesignTokens | null>;
|
|
21
|
+
/**
|
|
22
|
+
* Parse Lovable theme (shadcn/ui format) to DesignTokens
|
|
23
|
+
*
|
|
24
|
+
* Lovable themes use HSL CSS variables in the format:
|
|
25
|
+
* --primary: 222.2 47.4% 11.2%;
|
|
26
|
+
*
|
|
27
|
+
* @param lovableTheme - Theme object with CSS variables or Tailwind config
|
|
28
|
+
* @returns DesignTokens
|
|
29
|
+
*/
|
|
30
|
+
export declare function parseLovableTheme(lovableTheme: any): DesignTokens;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Width configuration for WordPress block alignment
|
|
3
|
+
*
|
|
4
|
+
* This module provides configurable widths for WordPress block alignments:
|
|
5
|
+
* - Default (None): Standard content width (default: 1280px)
|
|
6
|
+
* - Wide: Wider content width (default: 1340px)
|
|
7
|
+
* - Full: Full window width (no constraint)
|
|
8
|
+
*
|
|
9
|
+
* Widths can be configured via environment variables:
|
|
10
|
+
* - VITE_DEFAULT_WIDTH: Default width in pixels (e.g., "1280px" or "1280")
|
|
11
|
+
* - VITE_WIDE_WIDTH: Wide width in pixels (e.g., "1340px" or "1340")
|
|
12
|
+
*
|
|
13
|
+
* If environment variables are not set, defaults are used.
|
|
14
|
+
*/
|
|
15
|
+
/**
|
|
16
|
+
* Get default width (for "None" alignment)
|
|
17
|
+
* Default: 1280px
|
|
18
|
+
* Configurable via: VITE_DEFAULT_WIDTH
|
|
19
|
+
*/
|
|
20
|
+
export declare function getDefaultWidth(): string;
|
|
21
|
+
/**
|
|
22
|
+
* Get wide width (for "Wide" alignment)
|
|
23
|
+
* Default: 1340px
|
|
24
|
+
* Configurable via: VITE_WIDE_WIDTH
|
|
25
|
+
*/
|
|
26
|
+
export declare function getWideWidth(): string;
|
|
27
|
+
/**
|
|
28
|
+
* Get container class or style for a given alignment
|
|
29
|
+
*
|
|
30
|
+
* @param align - WordPress block alignment: 'wide', 'full', or undefined/null (None)
|
|
31
|
+
* @returns Object with className and/or style for width constraint
|
|
32
|
+
*/
|
|
33
|
+
export declare function getAlignmentWidth(align: string | undefined | null): {
|
|
34
|
+
className?: string;
|
|
35
|
+
style?: React.CSSProperties;
|
|
36
|
+
};
|
|
37
|
+
/**
|
|
38
|
+
* Get container class for default alignment (None)
|
|
39
|
+
* This is used when we want to use Tailwind's container class
|
|
40
|
+
* but ensure it respects the configured default width
|
|
41
|
+
*/
|
|
42
|
+
export declare function getDefaultContainerClass(): string;
|
|
43
|
+
/**
|
|
44
|
+
* Get container class or style for wide alignment
|
|
45
|
+
* Returns style object for consistency with default alignment
|
|
46
|
+
*/
|
|
47
|
+
export declare function getWideContainerStyle(): React.CSSProperties;
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
export interface GravityFormField {
|
|
2
|
+
id: string;
|
|
3
|
+
type: string;
|
|
4
|
+
label: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
isRequired: boolean;
|
|
7
|
+
placeholder?: string;
|
|
8
|
+
defaultValue?: string;
|
|
9
|
+
choices?: Array<{
|
|
10
|
+
text: string;
|
|
11
|
+
value: string;
|
|
12
|
+
isSelected?: boolean;
|
|
13
|
+
}>;
|
|
14
|
+
inputs?: Array<{
|
|
15
|
+
id: string;
|
|
16
|
+
label: string;
|
|
17
|
+
placeholder?: string;
|
|
18
|
+
isHidden?: boolean;
|
|
19
|
+
}>;
|
|
20
|
+
validation?: {
|
|
21
|
+
message?: string;
|
|
22
|
+
pattern?: string;
|
|
23
|
+
};
|
|
24
|
+
conditionalLogic?: {
|
|
25
|
+
actionType: 'show' | 'hide';
|
|
26
|
+
logicType: 'all' | 'any';
|
|
27
|
+
rules: Array<{
|
|
28
|
+
fieldId: string;
|
|
29
|
+
operator: string;
|
|
30
|
+
value: string;
|
|
31
|
+
}>;
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
export interface GravityForm {
|
|
35
|
+
id: string;
|
|
36
|
+
title: string;
|
|
37
|
+
description?: string;
|
|
38
|
+
fields: GravityFormField[];
|
|
39
|
+
button: {
|
|
40
|
+
text: string;
|
|
41
|
+
type: 'text' | 'image';
|
|
42
|
+
imageUrl?: string;
|
|
43
|
+
};
|
|
44
|
+
confirmation: {
|
|
45
|
+
type: 'message' | 'page' | 'redirect';
|
|
46
|
+
message?: string;
|
|
47
|
+
url?: string;
|
|
48
|
+
pageId?: string;
|
|
49
|
+
queryString?: string;
|
|
50
|
+
isDefault?: boolean;
|
|
51
|
+
};
|
|
52
|
+
settings: {
|
|
53
|
+
enableHoneypot?: boolean;
|
|
54
|
+
enableAnimation?: boolean;
|
|
55
|
+
validationSummary?: boolean;
|
|
56
|
+
saveAndContinue?: boolean;
|
|
57
|
+
limitEntries?: {
|
|
58
|
+
enabled: boolean;
|
|
59
|
+
limit?: number;
|
|
60
|
+
message?: string;
|
|
61
|
+
};
|
|
62
|
+
scheduleForm?: {
|
|
63
|
+
enabled: boolean;
|
|
64
|
+
start?: string;
|
|
65
|
+
end?: string;
|
|
66
|
+
message?: string;
|
|
67
|
+
};
|
|
68
|
+
};
|
|
69
|
+
isActive?: boolean;
|
|
70
|
+
isPublished?: boolean;
|
|
71
|
+
}
|
|
72
|
+
export interface GravityFormsDataStore {
|
|
73
|
+
generated_at: string;
|
|
74
|
+
total_forms: number;
|
|
75
|
+
forms: GravityForm[];
|
|
76
|
+
}
|
|
77
|
+
declare let gravityFormsData: GravityFormsDataStore;
|
|
78
|
+
export { gravityFormsData };
|
|
79
|
+
export declare const loadGravityFormsData: () => Promise<GravityFormsDataStore>;
|
|
80
|
+
export declare const getActiveForms: () => GravityForm[];
|
|
81
|
+
export declare const getPublishedForms: () => GravityForm[];
|
|
82
|
+
export declare const getFormById: (id: string | number) => GravityForm;
|
|
83
|
+
export declare const getFormByTitle: (title: string) => GravityForm;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
interface MauticForm {
|
|
2
|
+
id: number;
|
|
3
|
+
alias?: string;
|
|
4
|
+
isPublished?: boolean;
|
|
5
|
+
postAction?: string;
|
|
6
|
+
postActionProperty?: string;
|
|
7
|
+
[key: string]: any;
|
|
8
|
+
}
|
|
9
|
+
interface MauticDataStore {
|
|
10
|
+
generated_at: string;
|
|
11
|
+
forms: MauticForm[];
|
|
12
|
+
}
|
|
13
|
+
export declare const mauticData: MauticDataStore;
|
|
14
|
+
export declare const getPublishedForms: () => MauticForm[];
|
|
15
|
+
export declare const getFormById: (id: number) => MauticForm;
|
|
16
|
+
export declare const getFormByAlias: (alias: string) => MauticForm;
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
export interface MauticFormField {
|
|
2
|
+
id: number;
|
|
3
|
+
label: string;
|
|
4
|
+
alias: string;
|
|
5
|
+
type: 'text' | 'email' | 'textarea' | 'select' | 'checkbox' | 'radio' | 'hidden' | 'submit' | 'button';
|
|
6
|
+
isRequired: boolean;
|
|
7
|
+
defaultValue?: string;
|
|
8
|
+
helpMessage?: string;
|
|
9
|
+
validationMessage?: string;
|
|
10
|
+
properties?: {
|
|
11
|
+
[key: string]: any;
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
export interface MauticForm {
|
|
15
|
+
id: number;
|
|
16
|
+
name: string;
|
|
17
|
+
description?: string;
|
|
18
|
+
type: string;
|
|
19
|
+
isPublished: boolean;
|
|
20
|
+
fields: MauticFormField[];
|
|
21
|
+
actions: {
|
|
22
|
+
[key: string]: any;
|
|
23
|
+
};
|
|
24
|
+
created_at: string;
|
|
25
|
+
updated_at: string;
|
|
26
|
+
}
|
|
27
|
+
export interface MauticConfig {
|
|
28
|
+
enabled: boolean;
|
|
29
|
+
url?: string;
|
|
30
|
+
proxy_url?: string;
|
|
31
|
+
app_id?: string;
|
|
32
|
+
worker_secret?: string;
|
|
33
|
+
forms: {
|
|
34
|
+
[formId: string]: {
|
|
35
|
+
name: string;
|
|
36
|
+
type: string;
|
|
37
|
+
successMessage?: string;
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
export interface MauticDataStore {
|
|
42
|
+
generated_at: string;
|
|
43
|
+
config: MauticConfig;
|
|
44
|
+
forms: {
|
|
45
|
+
[formId: string]: MauticForm;
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
export declare const mauticData: MauticDataStore;
|