@koehler8/cms 1.0.0-beta.5
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 +202 -0
- package/bin/cms-generate-public-assets.js +27 -0
- package/bin/cms-validate-extensions.js +18 -0
- package/bin/cms-validate-themes.js +7 -0
- package/extensions/manifest.schema.json +125 -0
- package/package.json +84 -0
- package/public/img/preloaders/preloader-black.svg +1 -0
- package/public/img/preloaders/preloader-white.svg +1 -0
- package/public/robots.txt +5 -0
- package/scripts/check-overflow.mjs +33 -0
- package/scripts/generate-public-assets.js +401 -0
- package/scripts/patch-lru-cache-tla.js +164 -0
- package/scripts/validate-extensions.mjs +392 -0
- package/scripts/validate-themes.mjs +64 -0
- package/src/App.vue +3 -0
- package/src/components/About.vue +481 -0
- package/src/components/AboutValue.vue +361 -0
- package/src/components/BackToTop.vue +42 -0
- package/src/components/ComingSoon.vue +411 -0
- package/src/components/ComingSoonModal.vue +230 -0
- package/src/components/Contact.vue +518 -0
- package/src/components/Footer.vue +65 -0
- package/src/components/FooterMinimal.vue +153 -0
- package/src/components/Header.vue +583 -0
- package/src/components/Hero.vue +327 -0
- package/src/components/Home.vue +144 -0
- package/src/components/Intro.vue +130 -0
- package/src/components/IntroGate.vue +444 -0
- package/src/components/Plan.vue +116 -0
- package/src/components/Portfolio.vue +459 -0
- package/src/components/Preloader.vue +20 -0
- package/src/components/Principles.vue +67 -0
- package/src/components/Spacer15.vue +9 -0
- package/src/components/Spacer30.vue +9 -0
- package/src/components/Spacer40.vue +9 -0
- package/src/components/Spacer60.vue +9 -0
- package/src/components/StickyCTA.vue +263 -0
- package/src/components/Team.vue +432 -0
- package/src/components/icons/IconLinkedIn.vue +22 -0
- package/src/components/icons/IconX.vue +22 -0
- package/src/components/ui/SbCard.vue +52 -0
- package/src/components/ui/SkeletonPulse.vue +117 -0
- package/src/components/ui/UnitChip.vue +69 -0
- package/src/composables/useComingSoonConfig.js +120 -0
- package/src/composables/useComingSoonInterstitial.js +27 -0
- package/src/composables/useComponentResolver.js +196 -0
- package/src/composables/useEngagementTracking.js +187 -0
- package/src/composables/useIntroGate.js +46 -0
- package/src/composables/useLazyImage.js +77 -0
- package/src/composables/usePageConfig.js +184 -0
- package/src/composables/usePageMeta.js +76 -0
- package/src/composables/usePromoBackgroundStyles.js +67 -0
- package/src/constants/locales.js +20 -0
- package/src/extensions/extensionLoader.js +512 -0
- package/src/main.js +175 -0
- package/src/router/index.js +112 -0
- package/src/styles/base.css +896 -0
- package/src/styles/layout.css +342 -0
- package/src/styles/theme-base.css +84 -0
- package/src/themes/themeLoader.js +124 -0
- package/src/themes/themeManager.js +257 -0
- package/src/themes/themeValidator.js +380 -0
- package/src/utils/analytics.js +100 -0
- package/src/utils/appInfo.js +9 -0
- package/src/utils/assetResolver.js +162 -0
- package/src/utils/componentRegistry.js +46 -0
- package/src/utils/contentRequirements.js +67 -0
- package/src/utils/cookieConsent.js +281 -0
- package/src/utils/ctaCopy.js +58 -0
- package/src/utils/formatNumber.js +115 -0
- package/src/utils/imageSources.js +179 -0
- package/src/utils/inflateFlatConfig.js +30 -0
- package/src/utils/loadConfig.js +271 -0
- package/src/utils/semver.js +49 -0
- package/src/utils/siteStyles.js +40 -0
- package/src/utils/themeColors.js +65 -0
- package/src/utils/trackingContext.js +142 -0
- package/src/utils/unwrapDefault.js +14 -0
- package/src/utils/useScrollReveal.js +48 -0
- package/templates/index.html +36 -0
- package/themes/base/README.md +23 -0
- package/themes/base/theme.config.js +214 -0
- package/vite-plugin.js +637 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Chris Koehler
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
# Vertex CMS
|
|
2
|
+
|
|
3
|
+
[](LICENSE)
|
|
4
|
+
[](https://github.com/koehler8/cms/packages)
|
|
5
|
+
|
|
6
|
+
Vertex CMS is a lightweight, config-driven Vue 3 framework with theming, extensions, and SSG support.
|
|
7
|
+
|
|
8
|
+
## Quick Start
|
|
9
|
+
|
|
10
|
+
### 1. Create a site repo
|
|
11
|
+
|
|
12
|
+
```
|
|
13
|
+
my-site/
|
|
14
|
+
site/
|
|
15
|
+
config/
|
|
16
|
+
site.json # Site metadata and settings
|
|
17
|
+
shared.json # Shared content blocks
|
|
18
|
+
pages/
|
|
19
|
+
home.json # Per-page content
|
|
20
|
+
assets/ # Images and media
|
|
21
|
+
style.css # Site-specific overrides (optional)
|
|
22
|
+
.env
|
|
23
|
+
package.json
|
|
24
|
+
vite.config.js
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
### 2. Install
|
|
28
|
+
|
|
29
|
+
Configure npm to use GitHub Packages for the `@koehler8` scope:
|
|
30
|
+
|
|
31
|
+
```
|
|
32
|
+
@koehler8:registry=https://npm.pkg.github.com
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
Then install:
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
npm install @koehler8/cms vue vue-router vite vite-ssg @vitejs/plugin-vue
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### 3. Configure Vite
|
|
42
|
+
|
|
43
|
+
```js
|
|
44
|
+
// vite.config.js
|
|
45
|
+
import cmsPlugin from '@koehler8/cms/vite';
|
|
46
|
+
|
|
47
|
+
export default {
|
|
48
|
+
plugins: [
|
|
49
|
+
cmsPlugin({
|
|
50
|
+
siteDir: './site',
|
|
51
|
+
themes: ['@koehler8/cms-theme-neon'],
|
|
52
|
+
extensions: ['@koehler8/cms-ext-compliance'],
|
|
53
|
+
}),
|
|
54
|
+
],
|
|
55
|
+
};
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
### 4. Run
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
npm run dev # Development server
|
|
62
|
+
npm run build # Production build
|
|
63
|
+
vite-ssg build # Static site generation
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
## Plugin Options
|
|
67
|
+
|
|
68
|
+
| Option | Default | Description |
|
|
69
|
+
|--------|---------|-------------|
|
|
70
|
+
| `siteDir` | `'./site'` | Path to site content directory |
|
|
71
|
+
| `frameworkRoot` | (auto) | Path to `@koehler8/cms` package root |
|
|
72
|
+
| `locales` | all 15 supported | Array of locale codes to enable |
|
|
73
|
+
| `themes` | `[]` | Theme package names to register |
|
|
74
|
+
| `extensions` | `[]` | Extension package names to register |
|
|
75
|
+
|
|
76
|
+
## Site Configuration
|
|
77
|
+
|
|
78
|
+
Site content lives in `site/config/`:
|
|
79
|
+
|
|
80
|
+
- **`site.json`** -- Site-level metadata (title, description, URL, theme, Google Analytics ID)
|
|
81
|
+
- **`shared.json`** -- Content blocks shared across pages (header, footer, socials)
|
|
82
|
+
- **`pages/*.json`** -- Per-page content keyed by page ID
|
|
83
|
+
|
|
84
|
+
### Locale Overrides
|
|
85
|
+
|
|
86
|
+
Place locale-specific configs in `site/config/i18n/{locale}/` mirroring the same structure. They are deep-merged over the base config at runtime.
|
|
87
|
+
|
|
88
|
+
**Supported locales:** en, fr, es, de, ja, ko, pt, ru, tr, vi, id, zh, th, hi, fil
|
|
89
|
+
|
|
90
|
+
## Themes
|
|
91
|
+
|
|
92
|
+
Themes export a manifest with design tokens (palette, typography, surfaces, CTAs, etc.) that are applied as CSS variables at runtime.
|
|
93
|
+
|
|
94
|
+
- Set `site.theme` in `site.json` to a theme slug
|
|
95
|
+
- Omit it to use the built-in `base` theme
|
|
96
|
+
- External themes are npm packages registered via the `themes` plugin option
|
|
97
|
+
|
|
98
|
+
See `themes/base/theme.config.js` for the full token structure.
|
|
99
|
+
|
|
100
|
+
## Extensions
|
|
101
|
+
|
|
102
|
+
Extensions are npm packages that provide additional components, content defaults, and setup hooks.
|
|
103
|
+
|
|
104
|
+
Each extension has an `extension.config.json` manifest defining:
|
|
105
|
+
|
|
106
|
+
- **components** -- Vue components with metadata (name, configKey, allowedPages, requiredContent)
|
|
107
|
+
- **entry / setup** -- Optional initialization hooks
|
|
108
|
+
- **assets** -- CSS and static file references
|
|
109
|
+
- **dependencies** -- Required npm packages
|
|
110
|
+
|
|
111
|
+
Validate extension manifests with:
|
|
112
|
+
|
|
113
|
+
```bash
|
|
114
|
+
npx cms-validate-extensions --site-dir ./site
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
## Built-in Components
|
|
118
|
+
|
|
119
|
+
| Component | Description |
|
|
120
|
+
|-----------|-------------|
|
|
121
|
+
| `Header` | Site header with navigation |
|
|
122
|
+
| `Footer` / `FooterMinimal` | Full and minimal footer variants |
|
|
123
|
+
| `Hero` | Hero banner section |
|
|
124
|
+
| `About` / `AboutValue` | About and value proposition sections |
|
|
125
|
+
| `Contact` | Contact form (Google Forms backend) |
|
|
126
|
+
| `Team` | Team member grid |
|
|
127
|
+
| `Portfolio` | Portfolio showcase |
|
|
128
|
+
| `Plan` | Pricing/plan comparison |
|
|
129
|
+
| `Principles` | Principles/values section |
|
|
130
|
+
| `Intro` / `IntroGate` | Intro modal and gate |
|
|
131
|
+
| `ComingSoon` / `ComingSoonModal` | Coming soon page and modal |
|
|
132
|
+
| `StickyCTA` | Sticky call-to-action bar |
|
|
133
|
+
| `BackToTop` | Scroll-to-top button |
|
|
134
|
+
| `Preloader` | Page loading indicator |
|
|
135
|
+
| `Spacer15/30/40/60` | Vertical spacing utilities |
|
|
136
|
+
|
|
137
|
+
### UI Components
|
|
138
|
+
|
|
139
|
+
- `SbCard` -- Card component
|
|
140
|
+
- `SkeletonPulse` -- Loading skeleton
|
|
141
|
+
- `UnitChip` -- Unit/badge chip
|
|
142
|
+
|
|
143
|
+
## Composables
|
|
144
|
+
|
|
145
|
+
| Composable | Description |
|
|
146
|
+
|------------|-------------|
|
|
147
|
+
| `usePageConfig` | Load and cache page configuration |
|
|
148
|
+
| `useComponentResolver` | Resolve and validate component definitions |
|
|
149
|
+
| `usePageMeta` | Apply head/meta tags via @unhead |
|
|
150
|
+
| `useEngagementTracking` | Scroll depth and engagement analytics |
|
|
151
|
+
| `useIntroGate` | Intro modal state management |
|
|
152
|
+
| `useComingSoonConfig` | Coming-soon page configuration |
|
|
153
|
+
| `useLazyImage` | Lazy image loading with IntersectionObserver |
|
|
154
|
+
| `usePromoBackgroundStyles` | Promo section background styling |
|
|
155
|
+
|
|
156
|
+
## Testing
|
|
157
|
+
|
|
158
|
+
The framework uses [Vitest](https://vitest.dev/) with happy-dom for unit testing.
|
|
159
|
+
|
|
160
|
+
```bash
|
|
161
|
+
npm test # Run all tests
|
|
162
|
+
npm run test:watch # Watch mode
|
|
163
|
+
npm run test:coverage # Coverage report
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
Tests live in `tests/` mirroring the source structure (`tests/utils/`, `tests/composables/`, `tests/themes/`, etc.). See `vitest.config.js` for configuration.
|
|
167
|
+
|
|
168
|
+
## CLI Commands
|
|
169
|
+
|
|
170
|
+
```bash
|
|
171
|
+
# Generate favicon.ico, logo.png, og-image.jpg from source assets
|
|
172
|
+
npx cms-generate-public-assets --site-dir ./site
|
|
173
|
+
|
|
174
|
+
# Validate theme manifests
|
|
175
|
+
npx cms-validate-themes
|
|
176
|
+
|
|
177
|
+
# Validate extension manifests
|
|
178
|
+
npx cms-validate-extensions --site-dir ./site
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
## Exports
|
|
182
|
+
|
|
183
|
+
```js
|
|
184
|
+
import cmsPlugin from '@koehler8/cms/vite'; // Vite plugin
|
|
185
|
+
import { createCmsApp } from '@koehler8/cms/app'; // App factory
|
|
186
|
+
import { loadConfigData } from '@koehler8/cms/utils/loadConfig';
|
|
187
|
+
import { resolveAsset, resolveMedia } from '@koehler8/cms/utils/assetResolver';
|
|
188
|
+
import { useResponsiveImage } from '@koehler8/cms/utils/imageSources';
|
|
189
|
+
// ... and all other utils/*, composables/*, components/*, etc.
|
|
190
|
+
```
|
|
191
|
+
|
|
192
|
+
## Environment Variables
|
|
193
|
+
|
|
194
|
+
| Variable | Used By | Description |
|
|
195
|
+
|----------|---------|-------------|
|
|
196
|
+
| `VITE_SHOW_COOKIE_BANNER` | cookieConsent | Enable cookie consent banner |
|
|
197
|
+
| `CMS_SITE_DIR` | generate-public-assets | Site directory path (build scripts) |
|
|
198
|
+
| `FAVICON_BG` / `FAVICON_FG` | generate-public-assets | Favicon background/foreground colors |
|
|
199
|
+
|
|
200
|
+
## License
|
|
201
|
+
|
|
202
|
+
MIT
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// Wrapper that runs the framework's generate-public-assets.js from the
|
|
3
|
+
// consuming site repo's CWD. Accepts --site-dir <path> to locate site assets;
|
|
4
|
+
// defaults to ./site.
|
|
5
|
+
|
|
6
|
+
import path from 'node:path';
|
|
7
|
+
import { fileURLToPath, pathToFileURL } from 'node:url';
|
|
8
|
+
|
|
9
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
10
|
+
const __dirname = path.dirname(__filename);
|
|
11
|
+
|
|
12
|
+
// Parse --site-dir arg
|
|
13
|
+
const args = process.argv.slice(2);
|
|
14
|
+
let siteDir = './site';
|
|
15
|
+
for (let i = 0; i < args.length; i++) {
|
|
16
|
+
if (args[i] === '--site-dir' && args[i + 1]) {
|
|
17
|
+
siteDir = args[i + 1];
|
|
18
|
+
i++;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
// Expose for the underlying script via env var
|
|
23
|
+
process.env.CMS_SITE_DIR = path.resolve(process.cwd(), siteDir);
|
|
24
|
+
|
|
25
|
+
// Resolve and import the actual script (it runs on import)
|
|
26
|
+
const scriptPath = path.resolve(__dirname, '..', 'scripts', 'generate-public-assets.js');
|
|
27
|
+
await import(pathToFileURL(scriptPath).href);
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { fileURLToPath, pathToFileURL } from 'node:url';
|
|
4
|
+
|
|
5
|
+
const args = process.argv.slice(2);
|
|
6
|
+
let siteDir = './site';
|
|
7
|
+
for (let i = 0; i < args.length; i++) {
|
|
8
|
+
if (args[i] === '--site-dir' && args[i + 1]) {
|
|
9
|
+
siteDir = args[i + 1];
|
|
10
|
+
i++;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
process.env.CMS_SITE_DIR = path.resolve(process.cwd(), siteDir);
|
|
15
|
+
|
|
16
|
+
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
17
|
+
const scriptPath = path.resolve(__dirname, '..', 'scripts', 'validate-extensions.mjs');
|
|
18
|
+
await import(pathToFileURL(scriptPath).href);
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { fileURLToPath, pathToFileURL } from 'node:url';
|
|
4
|
+
|
|
5
|
+
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
6
|
+
const scriptPath = path.resolve(__dirname, '..', 'scripts', 'validate-themes.mjs');
|
|
7
|
+
await import(pathToFileURL(scriptPath).href);
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$id": "https://raw.githubusercontent.com/koehler8/cms/main/extensions/manifest.schema.json",
|
|
3
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4
|
+
"title": "Component Extension Manifest",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["slug", "version", "provider", "license", "components"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": {
|
|
10
|
+
"type": "string"
|
|
11
|
+
},
|
|
12
|
+
"slug": {
|
|
13
|
+
"type": "string",
|
|
14
|
+
"pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
|
|
15
|
+
},
|
|
16
|
+
"version": {
|
|
17
|
+
"type": "string",
|
|
18
|
+
"pattern": "^\\d+\\.\\d+\\.\\d+(?:-[A-Za-z0-9.-]+)?$"
|
|
19
|
+
},
|
|
20
|
+
"provider": {
|
|
21
|
+
"type": "object",
|
|
22
|
+
"required": ["name"],
|
|
23
|
+
"additionalProperties": false,
|
|
24
|
+
"properties": {
|
|
25
|
+
"name": { "type": "string", "minLength": 1 },
|
|
26
|
+
"url": { "type": "string", "format": "uri" },
|
|
27
|
+
"contact": { "type": "string" }
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
"entry": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"pattern": "^\\./"
|
|
33
|
+
},
|
|
34
|
+
"setup": {
|
|
35
|
+
"type": "string",
|
|
36
|
+
"pattern": "^\\./"
|
|
37
|
+
},
|
|
38
|
+
"license": {
|
|
39
|
+
"type": "string",
|
|
40
|
+
"minLength": 3
|
|
41
|
+
},
|
|
42
|
+
"components": {
|
|
43
|
+
"type": "array",
|
|
44
|
+
"minItems": 1,
|
|
45
|
+
"items": {
|
|
46
|
+
"type": "object",
|
|
47
|
+
"additionalProperties": false,
|
|
48
|
+
"required": ["name", "label", "description", "configKey"],
|
|
49
|
+
"properties": {
|
|
50
|
+
"name": {
|
|
51
|
+
"type": "string",
|
|
52
|
+
"pattern": "^[A-Z][A-Za-z0-9]+$"
|
|
53
|
+
},
|
|
54
|
+
"module": {
|
|
55
|
+
"type": "string",
|
|
56
|
+
"pattern": "^\\./.*$"
|
|
57
|
+
},
|
|
58
|
+
"label": { "type": "string", "minLength": 1 },
|
|
59
|
+
"description": { "type": "string", "minLength": 1 },
|
|
60
|
+
"configKey": {
|
|
61
|
+
"type": "string",
|
|
62
|
+
"pattern": "^[a-z][A-Za-z0-9]*$"
|
|
63
|
+
},
|
|
64
|
+
"propsInterface": {
|
|
65
|
+
"type": "string",
|
|
66
|
+
"pattern": "^\\./"
|
|
67
|
+
},
|
|
68
|
+
"slots": {
|
|
69
|
+
"type": "array",
|
|
70
|
+
"items": { "type": "string", "pattern": "^[A-Za-z0-9_-]+$" },
|
|
71
|
+
"uniqueItems": true
|
|
72
|
+
},
|
|
73
|
+
"events": {
|
|
74
|
+
"type": "array",
|
|
75
|
+
"items": { "type": "string", "pattern": "^[a-z][a-z0-9-]*$" },
|
|
76
|
+
"uniqueItems": true
|
|
77
|
+
},
|
|
78
|
+
"requiredContent": {
|
|
79
|
+
"type": "array",
|
|
80
|
+
"items": { "type": "string", "minLength": 1 },
|
|
81
|
+
"uniqueItems": true
|
|
82
|
+
},
|
|
83
|
+
"allowedPages": {
|
|
84
|
+
"type": "array",
|
|
85
|
+
"items": { "type": "string", "pattern": "^[a-z0-9_-]+$" },
|
|
86
|
+
"uniqueItems": true
|
|
87
|
+
},
|
|
88
|
+
"minAppVersion": {
|
|
89
|
+
"type": "string",
|
|
90
|
+
"pattern": "^\\d+\\.\\d+\\.\\d+(?:-[A-Za-z0-9.-]+)?$"
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
|
+
"assets": {
|
|
96
|
+
"type": "object",
|
|
97
|
+
"additionalProperties": false,
|
|
98
|
+
"properties": {
|
|
99
|
+
"styles": {
|
|
100
|
+
"type": "array",
|
|
101
|
+
"items": { "type": "string", "pattern": "^\\./" },
|
|
102
|
+
"uniqueItems": true
|
|
103
|
+
},
|
|
104
|
+
"static": {
|
|
105
|
+
"type": "array",
|
|
106
|
+
"items": { "type": "string", "pattern": "^\\./" },
|
|
107
|
+
"uniqueItems": true
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
},
|
|
111
|
+
"dependencies": {
|
|
112
|
+
"type": "object",
|
|
113
|
+
"additionalProperties": false,
|
|
114
|
+
"properties": {
|
|
115
|
+
"npm": {
|
|
116
|
+
"type": "object",
|
|
117
|
+
"propertyNames": {
|
|
118
|
+
"pattern": "^[a-z0-9@][a-z0-9@/_-]*$"
|
|
119
|
+
},
|
|
120
|
+
"additionalProperties": { "type": "string", "minLength": 1 }
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@koehler8/cms",
|
|
3
|
+
"version": "1.0.0-beta.5",
|
|
4
|
+
"description": "Vertex CMS — lightweight, config-driven Vue 3 framework with theming, extensions, and SSG support",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"repository": {
|
|
8
|
+
"type": "git",
|
|
9
|
+
"url": "git+https://github.com/koehler8/cms.git"
|
|
10
|
+
},
|
|
11
|
+
"author": "Chris Koehler",
|
|
12
|
+
"homepage": "https://github.com/koehler8/cms#readme",
|
|
13
|
+
"bugs": {
|
|
14
|
+
"url": "https://github.com/koehler8/cms/issues"
|
|
15
|
+
},
|
|
16
|
+
"keywords": ["vue", "cms", "vite", "ssg", "theming", "extensions", "config-driven"],
|
|
17
|
+
"scripts": {
|
|
18
|
+
"postinstall": "node scripts/patch-lru-cache-tla.js",
|
|
19
|
+
"test": "vitest run",
|
|
20
|
+
"test:watch": "vitest",
|
|
21
|
+
"test:coverage": "vitest run --coverage"
|
|
22
|
+
},
|
|
23
|
+
"exports": {
|
|
24
|
+
"./vite": "./vite-plugin.js",
|
|
25
|
+
"./app": "./src/main.js",
|
|
26
|
+
"./utils/loadConfig": "./src/utils/loadConfig.js",
|
|
27
|
+
"./utils/siteStyles": "./src/utils/siteStyles.js",
|
|
28
|
+
"./utils/assetResolver": "./src/utils/assetResolver.js",
|
|
29
|
+
"./utils/*.js": "./src/utils/*.js",
|
|
30
|
+
"./utils/*": "./src/utils/*.js",
|
|
31
|
+
"./composables/*.js": "./src/composables/*.js",
|
|
32
|
+
"./composables/*": "./src/composables/*.js",
|
|
33
|
+
"./components/*.vue": "./src/components/*.vue",
|
|
34
|
+
"./components/*.js": "./src/components/*.js",
|
|
35
|
+
"./components/*": "./src/components/*",
|
|
36
|
+
"./router": "./src/router/index.js",
|
|
37
|
+
"./themes/*.js": "./src/themes/*.js",
|
|
38
|
+
"./themes/*": "./src/themes/*.js",
|
|
39
|
+
"./extensions/*.js": "./src/extensions/*.js",
|
|
40
|
+
"./extensions/*": "./src/extensions/*.js",
|
|
41
|
+
"./constants/*.js": "./src/constants/*.js",
|
|
42
|
+
"./constants/*": "./src/constants/*.js",
|
|
43
|
+
"./plugins/*.js": "./src/plugins/*.js",
|
|
44
|
+
"./plugins/*": "./src/plugins/*.js",
|
|
45
|
+
"./package.json": "./package.json"
|
|
46
|
+
},
|
|
47
|
+
"bin": {
|
|
48
|
+
"cms-generate-public-assets": "./bin/cms-generate-public-assets.js",
|
|
49
|
+
"cms-validate-themes": "./bin/cms-validate-themes.js",
|
|
50
|
+
"cms-validate-extensions": "./bin/cms-validate-extensions.js"
|
|
51
|
+
},
|
|
52
|
+
"files": [
|
|
53
|
+
"src",
|
|
54
|
+
"extensions",
|
|
55
|
+
"themes",
|
|
56
|
+
"scripts",
|
|
57
|
+
"public",
|
|
58
|
+
"templates",
|
|
59
|
+
"bin",
|
|
60
|
+
"vite-plugin.js",
|
|
61
|
+
"README.md"
|
|
62
|
+
],
|
|
63
|
+
"peerDependencies": {
|
|
64
|
+
"@vitejs/plugin-vue": "^6.0.0",
|
|
65
|
+
"vite": "^8.0.0",
|
|
66
|
+
"vite-ssg": "^28.0.0",
|
|
67
|
+
"vue": "^3.5.0",
|
|
68
|
+
"vue-router": "^5.0.0"
|
|
69
|
+
},
|
|
70
|
+
"dependencies": {
|
|
71
|
+
"@unhead/vue": "^2.0.19",
|
|
72
|
+
"ajv": "^8.17.1",
|
|
73
|
+
"ajv-formats": "^3.0.1",
|
|
74
|
+
"canvas": "^3.2.0",
|
|
75
|
+
"dotenv": "^17.2.3",
|
|
76
|
+
"pinia": "^3.0.1",
|
|
77
|
+
"png-to-ico": "^3.0.1"
|
|
78
|
+
},
|
|
79
|
+
"devDependencies": {
|
|
80
|
+
"@vue/test-utils": "^2.4.6",
|
|
81
|
+
"happy-dom": "^20.8.9",
|
|
82
|
+
"vitest": "^4.1.4"
|
|
83
|
+
}
|
|
84
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8" standalone="no"?><svg xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.0" width="34px" height="34px" viewBox="0 0 128 128" xml:space="preserve"><g><path d="M75.4 126.63a11.43 11.43 0 0 1-2.1-22.65 40.9 40.9 0 0 0 30.5-30.6 11.4 11.4 0 1 1 22.27 4.87h.02a63.77 63.77 0 0 1-47.8 48.05v-.02a11.38 11.38 0 0 1-2.93.37z" fill="#000000" fill-opacity="1"/><animateTransform attributeName="transform" type="rotate" from="0 64 64" to="360 64 64" dur="800ms" repeatCount="indefinite"></animateTransform></g></svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8" standalone="no"?><svg xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.0" width="34px" height="34px" viewBox="0 0 128 128" xml:space="preserve"><g><path d="M75.4 126.63a11.43 11.43 0 0 1-2.1-22.65 40.9 40.9 0 0 0 30.5-30.6 11.4 11.4 0 1 1 22.27 4.87h.02a63.77 63.77 0 0 1-47.8 48.05v-.02a11.38 11.38 0 0 1-2.93.37z" fill="#ffffff" fill-opacity="1"/><animateTransform attributeName="transform" type="rotate" from="0 64 64" to="360 64 64" dur="800ms" repeatCount="indefinite"></animateTransform></g></svg>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { chromium } from 'playwright';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { fileURLToPath } from 'node:url';
|
|
4
|
+
|
|
5
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = path.dirname(__filename);
|
|
7
|
+
const distIndex = path.resolve(__dirname, '../dist/index.html');
|
|
8
|
+
|
|
9
|
+
const browser = await chromium.launch();
|
|
10
|
+
const page = await browser.newPage({ viewport: { width: 412, height: 915 } });
|
|
11
|
+
await page.goto(`file://${distIndex}`);
|
|
12
|
+
await page.waitForTimeout(2000);
|
|
13
|
+
const result = await page.evaluate(() => ({
|
|
14
|
+
scrollWidth: document.documentElement.scrollWidth,
|
|
15
|
+
clientWidth: document.documentElement.clientWidth,
|
|
16
|
+
bodyScrollWidth: document.body.scrollWidth,
|
|
17
|
+
bodyClientWidth: document.body.clientWidth,
|
|
18
|
+
overflowElements: Array.from(document.querySelectorAll('*')).map(el => {
|
|
19
|
+
const rect = el.getBoundingClientRect();
|
|
20
|
+
const docWidth = document.documentElement.clientWidth;
|
|
21
|
+
const overflowX = rect.right > docWidth + 1;
|
|
22
|
+
return overflowX ? {
|
|
23
|
+
tag: el.tagName.toLowerCase(),
|
|
24
|
+
classes: el.className,
|
|
25
|
+
rectRight: rect.right,
|
|
26
|
+
rectLeft: rect.left,
|
|
27
|
+
width: rect.width,
|
|
28
|
+
text: el.textContent?.trim().slice(0, 120)
|
|
29
|
+
} : null;
|
|
30
|
+
}).filter(Boolean)
|
|
31
|
+
}));
|
|
32
|
+
console.log(JSON.stringify(result, null, 2));
|
|
33
|
+
await browser.close();
|