@reldens/cms 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/LICENSE +21 -0
- package/README.md +125 -0
- package/bin/reldens-cms.js +21 -0
- package/index.js +15 -0
- package/install/css/installer.css +117 -0
- package/install/index.html +100 -0
- package/install/js/installer.js +32 -0
- package/lib/admin-dist-helper.js +56 -0
- package/lib/admin-entities-generator.js +32 -0
- package/lib/admin-manager-validator.js +37 -0
- package/lib/admin-manager.js +1059 -0
- package/lib/admin-translations.js +262 -0
- package/lib/installer.js +283 -0
- package/lib/manager.js +171 -0
- package/lib/storefront.js +228 -0
- package/lib/templates-list.js +50 -0
- package/migrations/default-user.sql +11 -0
- package/migrations/install.sql +84 -0
- package/package.json +42 -0
- package/templates/.env.dist +16 -0
- package/templates/404.html +30 -0
- package/templates/css/styles.css +102 -0
- package/templates/js/scripts.js +12 -0
- package/templates/page.html +38 -0
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
/* Storefront styles */
|
|
2
|
+
body {
|
|
3
|
+
font-family: 'Open Sans', sans-serif;
|
|
4
|
+
line-height: 1.6;
|
|
5
|
+
color: #333;
|
|
6
|
+
margin: 0;
|
|
7
|
+
padding: 0;
|
|
8
|
+
background-color: #f7f8fa;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.container {
|
|
12
|
+
max-width: 1200px;
|
|
13
|
+
margin: 0 auto;
|
|
14
|
+
padding: 20px;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
header {
|
|
18
|
+
background-color: #fff;
|
|
19
|
+
padding: 20px 0;
|
|
20
|
+
box-shadow: 0 2px 5px rgba(0,0,0,0.1);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
header .container {
|
|
24
|
+
display: flex;
|
|
25
|
+
justify-content: space-between;
|
|
26
|
+
align-items: center;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
nav a {
|
|
30
|
+
margin-left: 20px;
|
|
31
|
+
text-decoration: none;
|
|
32
|
+
color: #3498db;
|
|
33
|
+
font-weight: 600;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
nav a:hover {
|
|
37
|
+
color: #2980b9;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
nav a.active {
|
|
41
|
+
border-bottom: 2px solid #3498db;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
main {
|
|
45
|
+
background-color: #fff;
|
|
46
|
+
padding: 40px;
|
|
47
|
+
margin: 20px 0;
|
|
48
|
+
border-radius: 8px;
|
|
49
|
+
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
h1, h2, h3 {
|
|
53
|
+
color: #1a2b49;
|
|
54
|
+
margin-top: 0;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
footer {
|
|
58
|
+
text-align: center;
|
|
59
|
+
padding: 20px;
|
|
60
|
+
color: #666;
|
|
61
|
+
font-size: 14px;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
a {
|
|
65
|
+
color: #3498db;
|
|
66
|
+
text-decoration: none;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
a:hover {
|
|
70
|
+
color: #2980b9;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.error-container {
|
|
74
|
+
text-align: center;
|
|
75
|
+
padding: 50px 20px;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.error-container h1 {
|
|
79
|
+
font-size: 36px;
|
|
80
|
+
margin-bottom: 20px;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.button {
|
|
84
|
+
display: inline-block;
|
|
85
|
+
background-color: #3498db;
|
|
86
|
+
color: white;
|
|
87
|
+
padding: 12px 24px;
|
|
88
|
+
border-radius: 4px;
|
|
89
|
+
font-weight: 600;
|
|
90
|
+
transition: background-color 0.3s;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.button:hover {
|
|
94
|
+
background-color: #2980b9;
|
|
95
|
+
color: white;
|
|
96
|
+
text-decoration: none;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
img {
|
|
100
|
+
max-width: 100%;
|
|
101
|
+
height: auto;
|
|
102
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
// Storefront JavaScript
|
|
2
|
+
document.addEventListener('DOMContentLoaded', function() {
|
|
3
|
+
// Add active class to current navigation item
|
|
4
|
+
const currentPath = window.location.pathname;
|
|
5
|
+
const navLinks = document.querySelectorAll('nav a');
|
|
6
|
+
|
|
7
|
+
navLinks.forEach(link => {
|
|
8
|
+
if (link.getAttribute('href') === currentPath) {
|
|
9
|
+
link.classList.add('active');
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
});
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html>
|
|
3
|
+
<head>
|
|
4
|
+
<title>{{title}}</title>
|
|
5
|
+
<meta name="description" content="{{meta_description}}">
|
|
6
|
+
<meta property="og:title" content="{{og_title}}">
|
|
7
|
+
<meta property="og:description" content="{{og_description}}">
|
|
8
|
+
<meta property="og:image" content="{{og_image}}">
|
|
9
|
+
<meta name="twitter:card" content="{{twitter_card_type}}">
|
|
10
|
+
<meta name="robots" content="{{meta_robots}}">
|
|
11
|
+
{{#canonical_url}}<link rel="canonical" href="{{canonical_url}}">{{/canonical_url}}
|
|
12
|
+
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
|
|
13
|
+
<link rel="stylesheet" href="/css/styles.css">
|
|
14
|
+
<script src="/js/scripts.js"></script>
|
|
15
|
+
</head>
|
|
16
|
+
<body>
|
|
17
|
+
<header>
|
|
18
|
+
<div class="container">
|
|
19
|
+
<h1>Reldens CMS</h1>
|
|
20
|
+
<nav>
|
|
21
|
+
<a href="/">Home</a>
|
|
22
|
+
{{#navigation}}
|
|
23
|
+
<a href="{{url}}">{{label}}</a>
|
|
24
|
+
{{/navigation}}
|
|
25
|
+
</nav>
|
|
26
|
+
</div>
|
|
27
|
+
</header>
|
|
28
|
+
<div class="container">
|
|
29
|
+
<main>
|
|
30
|
+
<h1>{{title}}</h1>
|
|
31
|
+
{{{content}}}
|
|
32
|
+
</main>
|
|
33
|
+
</div>
|
|
34
|
+
<footer>
|
|
35
|
+
<p>© {{current_year}} - Built with Reldens CMS</p>
|
|
36
|
+
</footer>
|
|
37
|
+
</body>
|
|
38
|
+
</html>
|