cf-elements 1.0.0 → 1.0.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/README.md +3 -1
- package/cf-elements.js +29 -0
- package/package.json +6 -8
package/README.md
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
# cf-elements
|
|
2
2
|
|
|
3
|
-
Zero-dependency
|
|
3
|
+
Zero-dependency markup library that renders ClickFunnels-style HTML with inline styles.
|
|
4
|
+
|
|
5
|
+
It is intended use is for building "ClickFunnels mockups" in LLMs like Claude/ChatGPT/etc, which then can be converted to ClickFunnels ready JSON via the `cf-pagetree-parser` package.
|
|
4
6
|
|
|
5
7
|
## Installation
|
|
6
8
|
|
package/cf-elements.js
CHANGED
|
@@ -70,6 +70,35 @@
|
|
|
70
70
|
}
|
|
71
71
|
})();
|
|
72
72
|
|
|
73
|
+
// ==========================================================================
|
|
74
|
+
// BACKGROUND STYLES - Inject CSS for background image classes
|
|
75
|
+
// ==========================================================================
|
|
76
|
+
|
|
77
|
+
// Inject background styles immediately
|
|
78
|
+
(function injectBgStyles() {
|
|
79
|
+
const style = document.createElement('style');
|
|
80
|
+
style.id = 'cf-bg-styles';
|
|
81
|
+
style.textContent = `
|
|
82
|
+
/* Background style classes - matches ClickFunnels options */
|
|
83
|
+
.bgCover { background-size: cover !important; background-repeat: no-repeat !important; }
|
|
84
|
+
.bgCoverCenter { background-size: cover !important; background-position: center center !important; background-repeat: no-repeat !important; }
|
|
85
|
+
.bgCoverV2 { background-attachment: fixed !important; background-size: cover !important; background-position: center center !important; background-repeat: no-repeat !important; }
|
|
86
|
+
.bgW100 { background-size: 100% auto !important; background-repeat: no-repeat !important; }
|
|
87
|
+
.bgW100H100 { background-size: 100% 100% !important; background-repeat: no-repeat !important; }
|
|
88
|
+
.bgNoRepeat { background-repeat: no-repeat !important; }
|
|
89
|
+
.bgRepeat { background-repeat: repeat !important; }
|
|
90
|
+
.bgRepeatX { background-repeat: repeat-x !important; }
|
|
91
|
+
.bgRepeatY { background-repeat: repeat-y !important; }
|
|
92
|
+
`;
|
|
93
|
+
if (document.head) {
|
|
94
|
+
document.head.appendChild(style);
|
|
95
|
+
} else {
|
|
96
|
+
document.addEventListener('DOMContentLoaded', () => {
|
|
97
|
+
document.head.appendChild(style);
|
|
98
|
+
});
|
|
99
|
+
}
|
|
100
|
+
})();
|
|
101
|
+
|
|
73
102
|
// ==========================================================================
|
|
74
103
|
// CONSTANTS & MAPPINGS
|
|
75
104
|
// ==========================================================================
|
package/package.json
CHANGED
|
@@ -1,30 +1,28 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cf-elements",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"description": "Zero-dependency
|
|
3
|
+
"version": "1.0.2",
|
|
4
|
+
"description": "Zero-dependency markup library that generates ClickFunnels compatible HTML with inline styles",
|
|
5
5
|
"main": "cf-elements.js",
|
|
6
6
|
"browser": "cf-elements.js",
|
|
7
7
|
"unpkg": "cf-elements.js",
|
|
8
8
|
"jsdelivr": "cf-elements.js",
|
|
9
9
|
"files": [
|
|
10
|
-
"cf-elements.js"
|
|
10
|
+
"cf-elements.js",
|
|
11
|
+
"bg-styles.css"
|
|
11
12
|
],
|
|
12
13
|
"scripts": {
|
|
13
14
|
"test": "echo \"No tests yet\""
|
|
14
15
|
},
|
|
15
16
|
"keywords": [
|
|
16
|
-
"web-components",
|
|
17
17
|
"clickfunnels",
|
|
18
18
|
"funnelwind",
|
|
19
|
-
"landing-pages"
|
|
20
|
-
"no-code",
|
|
21
|
-
"inline-styles"
|
|
19
|
+
"landing-pages"
|
|
22
20
|
],
|
|
23
21
|
"author": "BarnumPT",
|
|
24
22
|
"license": "MIT",
|
|
25
23
|
"repository": {
|
|
26
24
|
"type": "git",
|
|
27
|
-
"url": "https://github.com/barnumpt/cf-elements.git"
|
|
25
|
+
"url": "git+https://github.com/barnumpt/cf-elements.git"
|
|
28
26
|
},
|
|
29
27
|
"homepage": "https://barnumpt.app/docs/funnelwind",
|
|
30
28
|
"bugs": {
|