@mgks/docmd 0.1.3 → 0.1.4

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.
@@ -23,11 +23,11 @@ jobs:
23
23
  - name: Set up Node.js ⚙️
24
24
  uses: actions/setup-node@v4
25
25
  with:
26
- node-version: '22' # Use Node.js 22
26
+ node-version: '22'
27
27
  cache: 'npm'
28
28
 
29
29
  - name: Install Dependencies 📦
30
- run: npm ci # Use ci for cleaner installs in CI
30
+ run: npm ci
31
31
 
32
32
  - name: Build docmd's Own Docs 🛠️
33
33
  run: node ./bin/docmd.js build
@@ -335,6 +335,9 @@
335
335
  :root {
336
336
  --container-padding: 1.5rem;
337
337
  }
338
+ body {
339
+ overflow: auto;
340
+ }
338
341
 
339
342
  .content-side {
340
343
  padding: 2rem 0;
@@ -353,7 +356,20 @@
353
356
  }
354
357
 
355
358
  .header-top {
356
- right: 1.5rem;
359
+ padding: 1rem 0;
360
+ text-align: center;
361
+ right: 1rem;
362
+ }
363
+ h1 {
364
+ font-size: 2.5rem;
365
+ }
366
+ .tagline{
367
+ font-size: 1em;
368
+ font-weight: 500;
369
+ }
370
+ .landing-container {
371
+ padding: 1rem;
372
+ flex-direction: column;
357
373
  }
358
374
  }
359
375
  .social-links .lucide-heart-handshake {
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
package/config.js CHANGED
@@ -31,7 +31,7 @@ module.exports = {
31
31
 
32
32
  // Custom JavaScript Files
33
33
  customJs: [ // Array of paths to custom JS files, loaded at end of body
34
- // '/assets/js/docmd-image-lightbox.js', // Image lightbox functionality (commented out)
34
+ '/assets/js/docmd-image-lightbox.js', // Image lightbox functionality
35
35
  ],
36
36
 
37
37
  // Plugins Configuration (Object format)
@@ -127,7 +127,9 @@ module.exports = {
127
127
  { title: 'Deployment', path: '/deployment', icon: 'upload-cloud' },
128
128
  { title: 'Contributing', path: '/contributing', icon: 'users-2' },
129
129
 
130
- { title: 'GitHub', path: 'https://github.com/mgks/docmd', icon: 'github', external: true }
130
+ { title: 'GitHub', path: 'https://github.com/mgks/docmd', icon: 'github', external: true },
131
+ { title: 'Discussions', path: 'https://github.com/mgks/docmd/discussions', icon: 'message-square', external: true },
132
+ { title: 'Issues', path: 'https://github.com/mgks/docmd/issues', icon: 'badge-alert', external: true }
131
133
  ],
132
134
 
133
135
  // Footer Configuration
@@ -85,8 +85,7 @@ This provides a fast feedback loop, allowing you to see your changes almost inst
85
85
  * **Description:** Preserves existing asset files instead of updating them. Use this flag if you've customized any of the default assets and want to keep your modifications.
86
86
  * **Example:** `docmd dev --preserve`
87
87
 
88
- * `-p, --port <port_number>` (Future Option)
89
- * **Description:** While not yet implemented, a future version might allow specifying a custom port for the development server. Currently, it defaults to port 3000 or the next available port if 3000 is in use.
88
+ **Note:** The development server starts on port 3000 by default. If port 3000 is already in use, the server will automatically try the next available port (3001, 3002, etc.) until it finds an open port.
90
89
 
91
90
  ## Global Options (Apply to all commands)
92
91
 
@@ -24,7 +24,7 @@ module.exports = {
24
24
  outputDir: 'site',
25
25
 
26
26
  theme: {
27
- name: 'default', // Name of the built-in theme to use (e.g., 'default', 'classic')
27
+ name: 'sky', // Name of the built-in theme to use (e.g., 'sky', 'default')
28
28
  defaultMode: 'light', // 'light' or 'dark'
29
29
  enableModeToggle: true, // Show UI button to toggle light/dark modes
30
30
  customCss: [ // Array of paths to your custom CSS files
@@ -37,20 +37,32 @@ module.exports = {
37
37
  // '/js/extra-functionality.js', // Loaded at the end of the body
38
38
  ],
39
39
 
40
- plugins: [
41
- // Example: Enable built-in SEO enhancements
42
- // ['seo', {
43
- // defaultDescription: 'A fantastic site about interesting things.',
44
- // openGraph: { defaultImage: '/assets/images/og-social-default.png' },
45
- // twitter: { cardType: 'summary_large_image', siteUsername: '@MyProject' }
46
- // }],
47
-
48
- // Example: Enable Google Analytics (Universal Analytics)
49
- // ['analytics-google-ua', { trackingId: 'UA-XXXXXXXXX-Y' }],
40
+ plugins: {
41
+ // SEO Plugin Configuration
42
+ seo: {
43
+ defaultDescription: 'A fantastic site about interesting things.',
44
+ openGraph: {
45
+ defaultImage: '/assets/images/og-social-default.png'
46
+ },
47
+ twitter: {
48
+ cardType: 'summary_large_image',
49
+ siteUsername: '@MyProject'
50
+ }
51
+ },
50
52
 
51
- // Example: Enable Google Analytics 4
52
- // ['analytics-google-v4', { measurementId: 'G-XXXXXXXXXX' }],
53
- ],
53
+ // Google Analytics 4
54
+ analytics: {
55
+ googleV4: {
56
+ measurementId: 'G-XXXXXXXXXX'
57
+ }
58
+ },
59
+
60
+ // Sitemap generation
61
+ sitemap: {
62
+ defaultChangefreq: 'weekly',
63
+ defaultPriority: 0.8
64
+ }
65
+ },
54
66
 
55
67
  navigation: [
56
68
  { title: 'Home', path: '/', icon: 'home' }, // Icon names correspond to SVGs
@@ -137,15 +149,15 @@ Configures the visual theme of your site.
137
149
  * **Paths:** Should be relative to the `outputDir` root (e.g., `'/js/my-analytics-alternative.js'`).
138
150
  * **Example:** `customJs: ['/assets/js/interactive-component.js']`
139
151
 
140
- ## `plugins` (Array)
141
- * **Type:** `Array`
142
- * **Default:** `[]`
143
- * **Description:** An array to configure and enable plugins. `docmd` will ship with some core "local" plugins (like SEO and Analytics) that you can enable here. Future versions might support third-party plugins.
144
- * **Format:** Each item in the array is typically another array: `['plugin-name', { pluginOptions }]` or a direct `require()` for local project plugins (advanced usage).
152
+ ## `plugins` (Object)
153
+ * **Type:** `Object`
154
+ * **Default:** `{}`
155
+ * **Description:** An object to configure and enable plugins. `docmd` ships with core plugins like SEO, Analytics, and Sitemap that you can configure here.
156
+ * **Format:** Each key in the object represents a plugin name, and its value is an object containing the plugin's configuration options.
145
157
  * **Built-in Plugin Examples:**
146
- * `['seo', { defaultDescription: '...', openGraph: { ... }, ... }]`
147
- * `['analytics-google-ua', { trackingId: 'UA-...' }]`
148
- * `['analytics-google-v4', { measurementId: 'G-...' }]`
158
+ * `seo: { defaultDescription: '...', openGraph: { ... }, ... }`
159
+ * `analytics: { googleV4: { measurementId: 'G-XXXXXXXXXX' } }`
160
+ * `sitemap: { defaultChangefreq: 'weekly', defaultPriority: 0.8 }`
149
161
  * **See Also:** [Plugins](/plugins/)
150
162
 
151
163
  ## `navigation` (Array of Objects)
@@ -26,7 +26,7 @@ tags:
26
26
  * **`title`** (String, Required)
27
27
  * **Purpose:** This is the primary title of the page.
28
28
  * **Usage:**
29
- * Used for the HTML `<title>` tag (e.g., `Page Title | Site Title`).
29
+ * Used for the HTML `<title>` tag (e.g., `Page Title : Site Title`).
30
30
  * Often used as the main heading (`<h1>`) on the page by default (though themes can customize this).
31
31
  * Used as the display text for links in the navigation sidebar if the path matches.
32
32
  * **Example:** `title: "Installation Guide"`
@@ -68,7 +68,7 @@ This guide will walk you through installing our application...
68
68
  ```
69
69
 
70
70
  In this example:
71
- * The browser tab will show "Installation Steps | Your Site Title".
71
+ * The browser tab will show "Installation Steps : Your Site Title".
72
72
  * The `<meta name="description">` will be set.
73
73
  * The `order: 1` field is available if you later want to sort "guides" pages by this value.
74
74
 
@@ -9,9 +9,10 @@ docmd uses Markdown files to create beautiful documentation. This section covers
9
9
 
10
10
  ## Available Guides
11
11
 
12
- - [**Frontmatter**](/content/frontmatter) - Learn how to add metadata to your pages
13
- - [**Markdown Syntax**](/content/markdown-syntax) - Basic and advanced Markdown features
14
- - [**Images**](/content/images) - How to add and style images in your documentation
15
- - [**Custom Containers**](/content/custom-containers) - Special content blocks like callouts and cards
12
+ - [**Frontmatter**](/content/frontmatter/) - Learn how to add metadata to your pages
13
+ - [**Markdown Syntax**](/content/markdown-syntax/) - Basic and advanced Markdown features
14
+ - [**Images**](/content/images/) - How to add and style images in your documentation
15
+ - [**Custom Containers**](/content/custom-containers/) - Special content blocks like callouts and cards
16
+ - [**noStyle Pages**](/content/no-style-pages/) - Create custom standalone pages with complete HTML control
16
17
 
17
18
  Choose a topic from the sidebar to get started.
@@ -51,7 +51,7 @@ You can use all standard Markdown elements:
51
51
  ```markdown
52
52
  [Link Text](https://www.example.com)
53
53
  [Link with Title](https://www.example.com "Link Title")
54
- [Relative Link to another page](../section/other-page.md)
54
+ [Relative Link to another page](../section/other-page/)
55
55
  ```
56
56
  *Note: For internal links to other documentation pages, use relative paths to the `.md` files. `docmd` will convert these to the correct HTML paths during the build.*
57
57
 
@@ -152,7 +152,7 @@ Because `markdown-it` is configured with `html: true`, you can embed raw HTML di
152
152
  </div>
153
153
  ```
154
154
 
155
- For most formatting needs, standard Markdown and `docmd`'s [Custom Containers](./custom-containers.md) should suffice.
155
+ For most formatting needs, standard Markdown and `docmd`'s [Custom Containers](/content/custom-containers/) should suffice.
156
156
 
157
157
  # Advanced Markdown Capabilities
158
158
 
@@ -264,7 +264,7 @@ $$
264
264
  ## Container Extensions
265
265
 
266
266
  Beyond standard Markdown, docmd provides custom containers for enhanced formatting.
267
- These are detailed in the [Custom Containers](./custom-containers.md) guide, and include:
267
+ These are detailed in the [Custom Containers](/content/custom-containers/) guide, and include:
268
268
 
269
269
  ::: callout info
270
270
  Use containers for callouts, cards, and steps to structure your documentation.
@@ -274,4 +274,4 @@ Use containers for callouts, cards, and steps to structure your documentation.
274
274
 
275
275
  Markdown provides a powerful yet simple way to write and format documentation. With docmd's extensions and customizations, you can create rich, beautiful documentation that's easy to maintain.
276
276
 
277
- For more examples and practical applications, check the rest of the documentation or browse the source of this page by viewing its Markdown file.
277
+ For more examples and practical applications, check the rest of the documentation or browse the source of this page by viewing its Markdown file.
@@ -105,6 +105,6 @@ bodyClass: "no-style-example"
105
105
  without affecting the rest of your site.
106
106
  </p>
107
107
 
108
- <a href="/content/no-style-pages" class="button">Get Back to No-Style Pages Documentation</a>
108
+ <a href="/content/no-style-pages/" class="button">Get Back to No-Style Pages Documentation</a>
109
109
  </div>
110
110
  </div>
@@ -58,6 +58,13 @@ To set up `docmd` for local development:
58
58
  * Follow the existing code style and formatting.
59
59
  * Consider running `npm run lint` to check for style issues (if set up).
60
60
 
61
+ ### Environment Setup
62
+
63
+ To enable live change tracking for internal files during development, set the DOCMD_DEV environment variable:
64
+
65
+ - **Temporarily:** Run `export DOCMD_DEV=true` in your terminal before starting the dev server.
66
+ - **Permanently:** Add `export DOCMD_DEV=true` to your `~/.zshrc` file and run `source ~/.zshrc`.
67
+
61
68
  ## Pull Request Process
62
69
 
63
70
  Once you're satisfied with your changes:
@@ -59,14 +59,12 @@ The most robust and automated way to deploy to GitHub Pages is using a GitHub Ac
59
59
  Create a file at `.github/workflows/deploy-docs.yml` with the following content:
60
60
 
61
61
  ```yaml
62
- name: Deploy docmd docs to Pages
62
+ name: Deploy docmd docs to GitHub Pages
63
63
 
64
64
  on:
65
- # Run on pushes to main branch
66
65
  push:
67
- branches: ["main"]
68
- # Allows manual workflow trigger from Actions tab
69
- workflow_dispatch:
66
+ branches: ["main"] # Your default branch
67
+ workflow_dispatch: # Allows manual workflow trigger from Actions tab
70
68
 
71
69
  # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
72
70
  permissions:
@@ -74,46 +72,39 @@ permissions:
74
72
  pages: write
75
73
  id-token: write
76
74
 
77
- # Allow only one concurrent deployment
78
- concurrency:
79
- group: "pages"
80
- cancel-in-progress: false
81
-
82
75
  jobs:
83
- build:
76
+ build-and-deploy:
84
77
  runs-on: ubuntu-latest
78
+ environment:
79
+ name: github-pages
80
+ url: ${{ steps.deployment.outputs.page_url }}
85
81
  steps:
86
82
  - name: Checkout
87
- uses: actions/checkout@v3
88
- - name: Setup Node.js
89
- uses: actions/setup-node@v3
83
+ uses: actions/checkout@v4
84
+
85
+ - name: Set up Node.js
86
+ uses: actions/setup-node@v4
90
87
  with:
91
- node-version: '20' # Or the Node.js version docmd supports/requires
88
+ node-version: '22'
92
89
  cache: 'npm'
90
+
93
91
  - name: Install docmd (globally or from devDependencies)
94
- # If docmd is a dev dependency of the project being documented:
95
- # run: npm ci && npm run build:docs # Assuming 'build:docs' script runs 'docmd build'
96
- # If installing docmd globally for this action:
97
- run: npm install -g docmd # Or your scoped package name e.g. @mgks/docmd
92
+ run: npm install -g @mgks/docmd
93
+
98
94
  - name: Build site with docmd
99
95
  run: docmd build # Assumes config.js is in the root and correctly points to srcDir/outputDir
96
+
100
97
  - name: Setup Pages
101
- uses: actions/configure-pages@v3
98
+ uses: actions/configure-pages@v5
99
+
102
100
  - name: Upload artifact
103
- uses: actions/upload-pages-artifact@v2
101
+ uses: actions/upload-pages-artifact@v3
104
102
  with:
105
- # This should be your outputDir path
106
- path: './site' # or './docs' if you set outputDir: 'docs'
107
- deploy:
108
- environment:
109
- name: github-pages
110
- url: ${{ steps.deployment.outputs.page_url }}
111
- runs-on: ubuntu-latest
112
- needs: build
113
- steps:
103
+ path: ./site # This should be your outputDir path
104
+
114
105
  - name: Deploy to GitHub Pages
115
106
  id: deployment
116
- uses: actions/deploy-pages@v2
107
+ uses: actions/deploy-pages@v4
117
108
  ```
118
109
 
119
110
  Then:
@@ -36,6 +36,7 @@ Create your Markdown (`.md`) files inside the `docs/` directory. You can organiz
36
36
 
37
37
  ```
38
38
  my-awesome-docs/
39
+ ├── assets/
39
40
  ├── docs/
40
41
  │ ├── index.md
41
42
  │ └── api/
@@ -47,7 +48,7 @@ my-awesome-docs/
47
48
  └── config.js
48
49
  ```
49
50
 
50
- Each Markdown file should start with YAML frontmatter to define metadata like the page title. See [Writing Content > Frontmatter](/writing-content/frontmatter/) for details.
51
+ Each Markdown file should start with YAML frontmatter to define metadata like the page title. See [Content > Frontmatter](/content/frontmatter/) for details.
51
52
 
52
53
  ## 3. Preview Your Site (`docmd dev`)
53
54
 
@@ -85,4 +86,4 @@ This command:
85
86
 
86
87
  The contents of the `site/` directory are all you need to deploy your documentation. You can upload this folder to any static web hosting provider. See [Deployment](/deployment/) for more information.
87
88
 
88
- This covers the fundamental workflow of using `docmd`. Next, you'll want to learn more about [Writing Content](/writing-content/) and [Configuration](/configuration/).
89
+ This covers the fundamental workflow of using `docmd`. Next, you'll want to learn more about [Content](/content/) and [Configuration](/configuration/).
@@ -11,11 +11,11 @@ Whether you're documenting a new open-source project, an internal tool, or just
11
11
 
12
12
  ## What You'll Learn:
13
13
 
14
- * **[Installation](./installation.md):** How to install `docmd` on your system using npm.
15
- * **[Basic Usage](./basic-usage.md):**
14
+ * **[Installation](/getting-started/installation/):** How to install `docmd` on your system using npm.
15
+ * **[Basic Usage](/getting-started/basic-usage/):**
16
16
  * Initializing a new `docmd` project with `docmd init`.
17
17
  * Adding and structuring your Markdown content.
18
18
  * Building your static site with `docmd build`.
19
19
  * Previewing your site with live reloading using `docmd dev`.
20
20
 
21
- Ready to begin? Let's start with [Installation](./installation.md).
21
+ Ready to begin? Let's start with [Installation](/getting-started/installation/).
@@ -5,7 +5,7 @@ description: "Learn how to install docmd on your system globally or as a project
5
5
 
6
6
  # Installation
7
7
 
8
- You can install `docmd` using npm (Node Package Manager), which comes with Node.js. If you don't have Node.js and npm installed, please visit [nodejs.org](https://nodejs.org/) to download and install them first (Node.js version 20.x or higher is recommended for `docmd`).
8
+ You can install `docmd` using npm (Node Package Manager), which comes with Node.js. If you don't have Node.js and npm installed, please visit [nodejs.org](https://nodejs.org/) to download and install them first (Node.js version 22.x or higher is required for `docmd`).
9
9
 
10
10
  ## Global Installation (Recommended for CLI Use)
11
11
 
package/docs/index.md CHANGED
@@ -1,5 +1,5 @@
1
1
  ---
2
- title: "docmd: Documentation. Zero Clutter. Just Content."
2
+ title: "Documentation. Zero Clutter. Just Content."
3
3
  description: "A lightweight static documentation site generator that transforms Markdown into beautiful, responsive documentation websites."
4
4
  noStyle: true
5
5
  components:
@@ -7,10 +7,9 @@ components:
7
7
  favicon: true
8
8
  css: false
9
9
  theme: false
10
- scripts: true
11
- themeToggle: false
12
- lightbox: false
10
+ scripts: false
13
11
  customHead: |
12
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
14
13
  <link rel="preconnect" href="https://fonts.googleapis.com">
15
14
  <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
16
15
  <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=PT+Mono:wght@700&display=swap" rel="stylesheet">
@@ -26,7 +25,7 @@ customHead: |
26
25
  document.body.setAttribute('data-theme', prefersDark ? 'dark' : 'light');
27
26
  }
28
27
  }
29
-
28
+
30
29
  // Toggle theme between light and dark
31
30
  function toggleTheme() {
32
31
  const currentTheme = document.body.getAttribute('data-theme');
@@ -34,7 +33,7 @@ customHead: |
34
33
  document.body.setAttribute('data-theme', newTheme);
35
34
  localStorage.setItem('docmd-theme', newTheme);
36
35
  }
37
-
36
+
38
37
  // Run on page load
39
38
  document.addEventListener('DOMContentLoaded', initTheme);
40
39
  </script>
@@ -101,8 +100,6 @@ customHead: |
101
100
  </div>
102
101
  </div>
103
102
 
104
- <a href="https://www.producthunt.com/posts/docmd?embed=true&amp;utm_source=badge-featured&amp;utm_medium=badge&amp;utm_souce=badge-docmd" target="_blank" style="margin-bottom: .5em;"><img src="https://api.producthunt.com/widgets/embed-image/v1/featured.svg?post_id=963681&amp;theme=dark&amp;t=1747100482899" alt="docmd - Generate beautiful, light documentation sites from Markdown. | Product Hunt" style="width: 250px; height: 54px;" width="250" height="54"></a>
105
-
106
103
  <div class="buttons">
107
104
  <a href="/getting-started/" class="btn btn-primary">
108
105
  <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-rocket-icon lucide-rocket"><path d="M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09z"/><path d="m12 15-3-3a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.35 22.35 0 0 1-4 2z"/><path d="M9 12H4s.55-3.03 2-4c1.62-1.08 5 0 5 0"/><path d="M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5"/></svg>
@@ -118,9 +115,9 @@ customHead: |
118
115
  <a href="https://github.com/sponsors/mgks" target="_blank" rel="noopener" class="social-link" title="Buy me a Coffee – GitHub Sponsors">
119
116
  <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-heart-handshake-icon lucide-heart-handshake"><path d="M19 14c1.49-1.46 3-3.21 3-5.5A5.5 5.5 0 0 0 16.5 3c-1.76 0-3 .5-4.5 2-1.5-1.5-2.74-2-4.5-2A5.5 5.5 0 0 0 2 8.5c0 2.3 1.5 4.05 3 5.5l7 7Z"/><path d="M12 5 9.04 7.96a2.17 2.17 0 0 0 0 3.08c.82.82 2.13.85 3 .07l2.07-1.9a2.82 2.82 0 0 1 3.79 0l2.96 2.66"/><path d="m18 15-2-2"/><path d="m15 18-2-2"/></svg>
120
117
  </a>
121
- <!--<a href="https://twitter.com/share?url=https://docmd.mgks.dev" target="_blank" rel="noopener" class="social-link">
118
+ <a href="https://twitter.com/share?url=https://docmd.mgks.dev" target="_blank" rel="noopener" class="social-link">
122
119
  <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M22 4s-.7 2.1-2 3.4c1.6 10-9.4 17.3-18 11.6 2.2.1 4.4-.6 6-2C3 15.5.5 9.6 3 5c2.2 2.6 5.6 4.1 9 4.5-.9-4.2 4-6.6 7-3.8 1.1 0 3-1.2 3-1.2z"></path></svg>
123
- </a>-->
120
+ </a>
124
121
  </div>
125
122
  </div>
126
123
 
@@ -140,4 +137,4 @@ customHead: |
140
137
  </div>
141
138
  </div>
142
139
  </div>
143
- </div>
140
+ </div>
@@ -85,4 +85,4 @@ sitemap: false
85
85
 
86
86
  ## Verifying Your Sitemap
87
87
 
88
- After building your site, check the generated sitemap at `your-site/sitemap.xml`. You can also submit the sitemap URL to search engines like Google Search Console or Bing Webmaster Tools to help them discover and index your content more efficiently.
88
+ After building your site, check the generated sitemap at `your-site/sitemap.xml`. You can also submit the sitemap URL to search engines like Google Search Console or Bing Webmaster Tools to help them discover and index your content more efficiently.
@@ -123,4 +123,4 @@ For more information on deployment, see the [Deployment](/deployment/) documenta
123
123
  ## Related Topics
124
124
 
125
125
  - [Custom CSS & JS](/theming/custom-css-js/) - Learn how to configure custom CSS and JavaScript
126
- - [Theming](/theming/) - Explore other theming options for your documentation site
126
+ - [Theming](/theming/) - Explore other theming options for your documentation site
@@ -7,79 +7,57 @@ description: "An overview of the built-in themes provided by docmd."
7
7
 
8
8
  `docmd` allows you to choose from a selection of built-in themes to quickly change the overall look and feel of your documentation site. You can specify the theme in your `config.js` file using the `theme.name` property.
9
9
 
10
- ## 1. `default` Theme
11
-
12
- * **`theme.name: 'default'`** (This is the default if `theme.name` is not specified)
13
- * **Description:** The standard `docmd` theme. It's designed to be clean, modern, responsive, and highly readable. It features:
14
- * A collapsible sidebar for navigation.
15
- * Support for light and dark color modes.
16
- * Clear typography optimized for documentation.
17
- * Well-styled custom containers (callouts, cards, steps).
18
- * Effective syntax highlighting for code blocks.
19
- * **When to use:** A great general-purpose theme suitable for most documentation projects.
20
-
21
10
  ```javascript
22
11
  // config.js
23
12
  module.exports = {
24
13
  // ...
25
14
  theme: {
26
- name: 'default',
27
- defaultMode: 'light',
15
+ name: 'theme-name', // Options: 'default', 'sky', 'ruby'
16
+ defaultMode: 'light', // or 'dark'
28
17
  // ...
29
18
  },
30
19
  // ...
31
20
  };
32
21
  ```
33
22
 
23
+ ## 1. `default` Theme
24
+
25
+ * **`theme.name: 'default'`**
26
+ * **Description:** The foundation of all docmd themes. This is not a separate theme but the base styling that's always included regardless of which theme you select. It provides:
27
+ * Basic layout structure with sidebar and content area
28
+ * Essential typography and spacing
29
+ * Core styling for documentation elements like code blocks, tables, and custom containers
30
+ * Light and dark mode foundation
31
+ * **When to use:** When you want a minimalist, clean interface without additional styling layers. This is the most lightweight option.
32
+
34
33
  ## 2. `sky` Theme
35
34
 
36
- * **`theme.name: 'sky'`**
35
+ * **`theme.name: 'sky'`** (This is the default if `theme.name` is not specified)
37
36
  * **Description:** A modern theme inspired by popular documentation platforms, with a fresh and airy design. It features:
38
- * A clean, minimalist interface with subtle shadows and rounded corners.
39
- * Custom typography with improved readability.
40
- * Refined color palette for both light and dark modes.
41
- * Enhanced callout and container styles.
42
- * Premium documentation feel with careful attention to spacing and contrast.
37
+ * A clean, minimalist interface with subtle shadows and rounded corners
38
+ * Custom typography with improved readability
39
+ * Refined color palette for both light and dark modes
40
+ * Enhanced callout and container styles
41
+ * Premium documentation feel with careful attention to spacing and contrast
43
42
  * **When to use:** When you want a premium, polished look for your documentation site.
44
43
 
45
- ```javascript
46
- // config.js
47
- module.exports = {
48
- // ...
49
- theme: {
50
- name: 'sky',
51
- defaultMode: 'light', // or 'dark'
52
- // ...
53
- },
54
- // ...
55
- };
56
- ```
57
-
58
- ## Light and Dark Mode
59
-
60
- All themes support both light and dark color modes. You can set the default mode using the `theme.defaultMode` property and enable a toggle button with `theme.enableModeToggle`:
61
-
62
- ```javascript
63
- // config.js
64
- module.exports = {
65
- // ...
66
- theme: {
67
- name: 'sky', // or 'default'
68
- defaultMode: 'dark', // Start in dark mode
69
- enableModeToggle: true, // Show a toggle button in the sidebar
70
- // ...
71
- },
72
- // ...
73
- };
74
- ```
44
+ ## 3. `ruby` Theme
75
45
 
76
- Users can switch between modes using the toggle button in the sidebar, and their preference will be saved in localStorage for future visits.
46
+ * **`theme.name: 'ruby'`**
47
+ * **Description:** An elegant, vibrant theme inspired by the precious gemstone. It features:
48
+ * Rich, jewel-toned color palette centered around ruby reds and complementary colors
49
+ * Sophisticated typography with serif headings and sans-serif body text
50
+ * Distinctive card and callout designs with gem-like faceted styling
51
+ * Subtle gradients and depth effects that evoke the brilliance of gemstones
52
+ * Luxurious dark mode with deep, rich backgrounds and vibrant accent colors
53
+ * **When to use:** When you want your documentation to have a distinctive, premium feel with rich colors and elegant typography.
77
54
 
78
55
  ## How Themes Work
79
56
 
80
57
  Each theme consists of CSS files located within `docmd`'s internal assets. When you select a theme name, `docmd` links the corresponding stylesheet in your site's HTML:
81
58
 
82
59
  - `default` theme uses the base CSS with no additional theme stylesheet
83
- - `sky` theme loads `theme-sky.css` with its custom styling
60
+ - `sky` theme loads `docmd-theme-sky.css` with its custom styling on top of the default CSS
61
+ - `ruby` theme loads `docmd-theme-ruby.css` with its custom styling on top of the default CSS
84
62
 
85
63
  You can further customize any chosen theme using the `theme.customCss` option in your `config.js` to add your own overrides or additional styles. See [Custom CSS & JS](/theming/custom-css-js/) for details.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mgks/docmd",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "description": "Generate beautiful, lightweight static documentation sites directly from your Markdown files. Zero clutter, just content.",
5
5
  "main": "src/index.js",
6
6
  "bin": {
@@ -142,8 +142,9 @@
142
142
  flex-grow: 1;
143
143
  display: flex;
144
144
  flex-direction: column;
145
+ overflow: hidden;
145
146
  }
146
-
147
+
147
148
  .page-header {
148
149
  padding: 15px 30px;
149
150
  border-bottom: 1px solid var(--header-border);
@@ -0,0 +1,606 @@
1
+ /* docmd-theme-ruby.css - Ruby theme for docmd */
2
+
3
+ /* Import Google Fonts for Ruby theme */
4
+ @import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700&family=Source+Sans+Pro:wght@300;400;600;700&display=swap');
5
+
6
+ :root [data-theme="light"] {
7
+ /* Font family */
8
+ --ruby-font-family-sans: 'Source Sans Pro', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
9
+ --ruby-font-family-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
10
+ --ruby-font-family-mono: 'JetBrains Mono', 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
11
+
12
+ /* Color palette - Light mode */
13
+ --ruby-primary: #b30000; /* Deep ruby red */
14
+ --ruby-primary-light: #ffebee; /* Very light red */
15
+ --ruby-primary-dark: #8e0000; /* Darker ruby red */
16
+ --ruby-accent: #7b1fa2; /* Complementary purple */
17
+ --ruby-accent-light: #f3e5f5; /* Light purple */
18
+ --ruby-text: #2d2d2d; /* Nearly black text */
19
+ --ruby-text-light: #5a5a5a; /* Medium gray text */
20
+ --ruby-text-lightest: #757575; /* Light gray text */
21
+ --ruby-background: #ffffff; /* White background */
22
+ --ruby-background-alt: #fafafa; /* Very light gray background */
23
+ --ruby-border: #e0e0e0; /* Light gray border */
24
+ --ruby-border-light: #f0f0f0; /* Very light gray border */
25
+
26
+ /* Apply colors to CSS variables */
27
+ --bg-color: var(--ruby-background);
28
+ --text-color: var(--ruby-text);
29
+ --sidebar-bg: #f8f5f5;
30
+ --sidebar-text: var(--ruby-text-light);
31
+ --sidebar-link-active-bg: #f8e7e7;
32
+ --sidebar-link-active-text: var(--ruby-primary);
33
+ --link-color: var(--ruby-primary);
34
+ --border-color: var(--ruby-border);
35
+ --code-bg: var(--ruby-primary-light);
36
+ --code-text: var(--ruby-primary-dark);
37
+ --header-bg: var(--ruby-background);
38
+ --header-border: var(--ruby-border);
39
+
40
+ /* Box shadows with ruby tint */
41
+ --shadow-sm: 0 2px 4px rgba(179, 0, 0, 0.05);
42
+ --shadow-md: 0 4px 8px rgba(179, 0, 0, 0.1);
43
+ --shadow-lg: 0 8px 16px rgba(179, 0, 0, 0.15);
44
+
45
+ /* Image styling variables */
46
+ --image-border-color: var(--ruby-border);
47
+ --image-shadow: var(--shadow-md);
48
+ --image-caption-bg: var(--ruby-background-alt);
49
+ --image-caption-text: var(--ruby-text-light);
50
+ --image-hover-transform: translateY(-3px);
51
+ --image-hover-shadow: var(--shadow-lg);
52
+ --image-border-radius: 6px;
53
+ --image-transition: all 0.3s ease;
54
+ }
55
+
56
+ /* Dark mode */
57
+ :root [data-theme="dark"] {
58
+ /* Color palette - Dark mode */
59
+ --ruby-primary: #ff5252; /* Bright ruby red */
60
+ --ruby-primary-light: #3c1a1a; /* Dark red background */
61
+ --ruby-primary-dark: #ff7b7b; /* Lighter ruby red */
62
+ --ruby-accent: #ce93d8; /* Light purple */
63
+ --ruby-accent-light: #2a1a2a; /* Dark purple background */
64
+ --ruby-text: #f0f0f0; /* Nearly white text */
65
+ --ruby-text-light: #c0c0c0; /* Light gray text */
66
+ --ruby-text-lightest: #a0a0a0; /* Medium gray text */
67
+ --ruby-background: #1a0a0a; /* Very dark red-tinted background */
68
+ --ruby-background-alt: #2a1515; /* Dark red-tinted background */
69
+ --ruby-border: #3a2020; /* Dark red-tinted border */
70
+ --ruby-border-light: #2a1818; /* Very dark red-tinted border */
71
+
72
+ /* Apply colors to CSS variables */
73
+ --bg-color: var(--ruby-background);
74
+ --text-color: var(--ruby-text);
75
+ --sidebar-bg: #1a0a0a;
76
+ --sidebar-text: var(--ruby-text-light);
77
+ --sidebar-link-active-bg: #2a1515;
78
+ --sidebar-link-active-text: var(--ruby-primary);
79
+ --link-color: var(--ruby-primary);
80
+ --border-color: var(--ruby-border);
81
+ --code-bg: var(--ruby-primary-light);
82
+ --code-text: var(--ruby-text);
83
+ --header-bg: var(--ruby-background);
84
+ --header-border: var(--ruby-border);
85
+
86
+ /* Box shadows for dark mode */
87
+ --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
88
+ --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.4);
89
+ --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.5);
90
+
91
+ /* Image styling variables for dark mode */
92
+ --image-border-color: var(--ruby-border);
93
+ --image-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
94
+ --image-caption-bg: var(--ruby-background-alt);
95
+ --image-caption-text: var(--ruby-text-light);
96
+ --image-hover-transform: translateY(-3px);
97
+ --image-hover-shadow: 0 6px 12px rgba(0, 0, 0, 0.7);
98
+ --image-border-radius: 6px;
99
+ --image-transition: all 0.3s ease;
100
+ }
101
+
102
+ /* Apply theme styles */
103
+
104
+ /* Typography improvements */
105
+ body {
106
+ font-family: var(--ruby-font-family-sans);
107
+ line-height: 1.7;
108
+ letter-spacing: 0.01em;
109
+ }
110
+
111
+ h1, h2, h3, h4, h5, h6 {
112
+ font-family: var(--ruby-font-family-serif);
113
+ font-weight: 600;
114
+ line-height: 1.3;
115
+ margin-top: 2em;
116
+ margin-bottom: 0.7em;
117
+ color: var(--ruby-text);
118
+ letter-spacing: -0.01em;
119
+ }
120
+
121
+ h1 {
122
+ font-size: 2.5rem;
123
+ font-weight: 700;
124
+ margin-top: 0;
125
+ position: relative;
126
+ padding-bottom: 0.5rem;
127
+ }
128
+
129
+ h1::after {
130
+ content: "";
131
+ position: absolute;
132
+ bottom: 0;
133
+ left: 0;
134
+ width: 60px;
135
+ height: 3px;
136
+ background: linear-gradient(90deg, var(--ruby-primary), var(--ruby-accent));
137
+ border-radius: 3px;
138
+ }
139
+
140
+ h2 {
141
+ font-size: 1.9rem;
142
+ border-bottom: 1px solid var(--ruby-border-light);
143
+ padding-bottom: 0.5rem;
144
+ }
145
+
146
+ h3 {
147
+ font-size: 1.6rem;
148
+ }
149
+
150
+ h4 {
151
+ font-size: 1.3rem;
152
+ }
153
+
154
+ a {
155
+ color: var(--link-color);
156
+ text-decoration: none;
157
+ transition: color 0.2s ease;
158
+ position: relative;
159
+ }
160
+
161
+ a:hover {
162
+ color: var(--ruby-primary-dark);
163
+ }
164
+
165
+ /* Stylish underline effect for links in content */
166
+ .content-area a:not(.button):not(.no-underline)::after {
167
+ content: '';
168
+ position: absolute;
169
+ width: 100%;
170
+ height: 1px;
171
+ bottom: 0;
172
+ left: 0;
173
+ background: linear-gradient(90deg, var(--ruby-primary), var(--ruby-accent));
174
+ transform: scaleX(0);
175
+ transform-origin: bottom right;
176
+ transition: transform 0.3s ease;
177
+ }
178
+
179
+ .content-area a:not(.button):not(.no-underline):hover::after {
180
+ transform: scaleX(1);
181
+ transform-origin: bottom left;
182
+ }
183
+
184
+ p {
185
+ margin: 0.7em 0;
186
+ padding: 0.3em 0;
187
+ line-height: 1.8;
188
+ }
189
+
190
+ /* Sidebar refinements */
191
+ .sidebar {
192
+ box-shadow: var(--shadow-sm);
193
+ border-right: 1px solid var(--ruby-border);
194
+ }
195
+
196
+ .sidebar-header {
197
+ border-bottom: 2px solid var(--ruby-border);
198
+ margin-bottom: 1.5rem;
199
+ padding-bottom: 1rem;
200
+ }
201
+
202
+ .sidebar nav li a {
203
+ border-radius: 4px;
204
+ margin-bottom: 3px;
205
+ transition: all 0.3s ease;
206
+ padding: 0.6rem 0.8rem;
207
+ font-weight: 400;
208
+ }
209
+
210
+ .sidebar nav li a:hover {
211
+ background-color: var(--sidebar-link-active-bg);
212
+ color: var(--ruby-primary);
213
+ transform: translateX(3px);
214
+ }
215
+
216
+ .sidebar nav li a.active {
217
+ background-color: var(--sidebar-link-active-bg);
218
+ color: var(--sidebar-link-active-text);
219
+ font-weight: 600;
220
+ border-left: 3px solid var(--ruby-primary);
221
+ }
222
+
223
+ /* Content area */
224
+ .content-area {
225
+ padding: 2.5rem 5%;
226
+ }
227
+
228
+ /* Code blocks */
229
+ pre {
230
+ background-color: var(--code-bg);
231
+ border-radius: 6px;
232
+ margin: 1.5em 0;
233
+ padding: 1.25em;
234
+ box-shadow: var(--shadow-sm);
235
+ border-left: 3px solid var(--ruby-primary);
236
+ }
237
+
238
+ code {
239
+ font-family: var(--ruby-font-family-mono);
240
+ font-size: 0.9em;
241
+ border-radius: 4px;
242
+ padding: 0.2em 0.4em;
243
+ }
244
+
245
+ /* Tables */
246
+ table {
247
+ width: 100%;
248
+ border-collapse: separate;
249
+ border-spacing: 0;
250
+ margin: 1.5em 0;
251
+ border-radius: 6px;
252
+ overflow: hidden;
253
+ box-shadow: var(--shadow-sm);
254
+ }
255
+
256
+ th {
257
+ background-color: var(--ruby-primary-light);
258
+ color: var(--ruby-primary-dark);
259
+ text-align: left;
260
+ font-weight: 600;
261
+ padding: 0.75rem 1rem;
262
+ border-bottom: 2px solid var(--ruby-border);
263
+ }
264
+
265
+ td {
266
+ padding: 0.75rem 1rem;
267
+ border-top: 1px solid var(--ruby-border-light);
268
+ }
269
+
270
+ tr:hover {
271
+ background-color: var(--ruby-background-alt);
272
+ }
273
+
274
+ /* Custom container styling for Ruby theme */
275
+ .docmd-container {
276
+ padding: 1.2rem 1.5rem;
277
+ margin: 1.75rem 0;
278
+ border-radius: 6px;
279
+ border: 1px solid var(--ruby-border-light);
280
+ background-color: var(--ruby-background);
281
+ box-shadow: var(--shadow-sm);
282
+ position: relative;
283
+ overflow: hidden;
284
+ }
285
+
286
+ /* Add gem-like facet to containers */
287
+ .docmd-container::before {
288
+ content: '';
289
+ position: absolute;
290
+ top: 0;
291
+ left: 0;
292
+ width: 100%;
293
+ height: 3px;
294
+ background: linear-gradient(90deg, var(--ruby-primary), var(--ruby-accent));
295
+ }
296
+
297
+ /* Callouts */
298
+ .callout {
299
+ position: relative;
300
+ border: none;
301
+ border-left: 4px solid;
302
+ background-color: var(--ruby-background-alt);
303
+ }
304
+
305
+ .callout-title {
306
+ font-family: var(--ruby-font-family-serif);
307
+ font-weight: 600;
308
+ margin-bottom: 0.75em;
309
+ display: flex;
310
+ align-items: center;
311
+ font-size: 1.1em;
312
+ }
313
+
314
+ .callout-title::before {
315
+ margin-right: 0.5rem;
316
+ font-size: 1.1em;
317
+ }
318
+
319
+ .callout-info {
320
+ border-left-color: var(--ruby-primary);
321
+ }
322
+
323
+ .callout-info .callout-title {
324
+ color: var(--ruby-primary);
325
+ }
326
+
327
+ .callout-warning {
328
+ border-left-color: #f39c12;
329
+ }
330
+
331
+ .callout-warning .callout-title {
332
+ color: #f39c12;
333
+ }
334
+
335
+ .callout-tip {
336
+ border-left-color: #2ecc71;
337
+ }
338
+
339
+ .callout-tip .callout-title {
340
+ color: #2ecc71;
341
+ }
342
+
343
+ .callout-danger {
344
+ border-left-color: #e74c3c;
345
+ }
346
+
347
+ .callout-danger .callout-title {
348
+ color: #e74c3c;
349
+ }
350
+
351
+ .callout-success {
352
+ border-left-color: #2ecc71;
353
+ }
354
+
355
+ .callout-success .callout-title {
356
+ color: #2ecc71;
357
+ }
358
+
359
+ /* Cards with gem-like styling */
360
+ .card {
361
+ border: none;
362
+ border-radius: 6px;
363
+ background: linear-gradient(135deg, var(--ruby-background) 0%, var(--ruby-background-alt) 100%);
364
+ box-shadow: var(--shadow-md);
365
+ transition: all 0.3s ease;
366
+ overflow: hidden;
367
+ }
368
+
369
+ .card:hover {
370
+ transform: translateY(-5px);
371
+ box-shadow: var(--shadow-lg);
372
+ }
373
+
374
+ .card .card-title {
375
+ font-family: var(--ruby-font-family-serif);
376
+ font-weight: 600;
377
+ padding: 1rem 1.5rem;
378
+ margin: 0;
379
+ background: linear-gradient(90deg, var(--ruby-primary-light), var(--ruby-accent-light));
380
+ color: var(--ruby-primary-dark);
381
+ border-bottom: 1px solid var(--ruby-border);
382
+ }
383
+
384
+ .card .card-content {
385
+ padding: 1rem 1.5rem;
386
+ }
387
+
388
+ /* Steps styling */
389
+ .steps {
390
+ counter-reset: step-counter;
391
+ position: relative;
392
+ padding-left: 1rem;
393
+ }
394
+
395
+ .steps h4 {
396
+ position: relative;
397
+ padding-left: 2.5rem;
398
+ margin-top: 2rem;
399
+ margin-bottom: 1rem;
400
+ font-family: var(--ruby-font-family-serif);
401
+ }
402
+
403
+ .steps h4::before {
404
+ content: counter(step-counter);
405
+ counter-increment: step-counter;
406
+ position: absolute;
407
+ left: 0;
408
+ top: 50%;
409
+ transform: translateY(-50%);
410
+ width: 1.8rem;
411
+ height: 1.8rem;
412
+ background: linear-gradient(135deg, var(--ruby-primary) 0%, var(--ruby-accent) 100%);
413
+ color: white;
414
+ border-radius: 50%;
415
+ display: flex;
416
+ align-items: center;
417
+ justify-content: center;
418
+ font-size: 0.9rem;
419
+ font-weight: 600;
420
+ box-shadow: var(--shadow-sm);
421
+ }
422
+
423
+ /* Buttons */
424
+ button, .button {
425
+ background: linear-gradient(135deg, var(--ruby-primary) 0%, var(--ruby-accent) 100%);
426
+ color: white;
427
+ border: none;
428
+ padding: 0.6rem 1.2rem;
429
+ border-radius: 4px;
430
+ font-weight: 600;
431
+ cursor: pointer;
432
+ transition: all 0.3s ease;
433
+ box-shadow: var(--shadow-sm);
434
+ }
435
+
436
+ button:hover, .button:hover {
437
+ box-shadow: var(--shadow-md);
438
+ transform: translateY(-2px);
439
+ }
440
+
441
+ .theme-toggle-button {
442
+ background: transparent;
443
+ color: var(--ruby-text-light);
444
+ box-shadow: none;
445
+ }
446
+
447
+ .theme-toggle-button:hover {
448
+ background: var(--ruby-background-alt);
449
+ color: var(--ruby-primary);
450
+ box-shadow: var(--shadow-sm);
451
+ transform: translateY(0);
452
+ }
453
+
454
+ /* Responsive adjustments */
455
+ @media (max-width: 768px) {
456
+ .content-area {
457
+ padding: 1.5rem 1rem;
458
+ }
459
+
460
+ h1 {
461
+ font-size: 2rem;
462
+ }
463
+
464
+ h2 {
465
+ font-size: 1.6rem;
466
+ }
467
+
468
+ h3 {
469
+ font-size: 1.3rem;
470
+ }
471
+ }
472
+
473
+ /* Image styling */
474
+ img {
475
+ max-width: 100%;
476
+ height: auto;
477
+ border-radius: var(--image-border-radius);
478
+ transition: var(--image-transition);
479
+ }
480
+
481
+ img.with-border {
482
+ border: 1px solid var(--image-border-color);
483
+ padding: 4px;
484
+ }
485
+
486
+ img.with-shadow {
487
+ box-shadow: var(--image-shadow);
488
+ }
489
+
490
+ img.with-shadow:hover {
491
+ box-shadow: var(--image-hover-shadow);
492
+ transform: var(--image-hover-transform);
493
+ }
494
+
495
+ figure {
496
+ margin: 1.5em 0;
497
+ text-align: center;
498
+ transition: var(--image-transition);
499
+ }
500
+
501
+ figure:hover {
502
+ transform: var(--image-hover-transform);
503
+ }
504
+
505
+ figure img {
506
+ max-width: 100%;
507
+ border-radius: var(--image-border-radius);
508
+ }
509
+
510
+ figcaption {
511
+ background-color: var(--image-caption-bg);
512
+ color: var(--image-caption-text);
513
+ padding: 0.5em;
514
+ font-size: 0.9em;
515
+ border-radius: 0 0 var(--image-border-radius) var(--image-border-radius);
516
+ font-style: italic;
517
+ }
518
+
519
+ /* Image gallery */
520
+ .image-gallery {
521
+ display: grid;
522
+ grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
523
+ gap: 1rem;
524
+ margin: 1.5em 0;
525
+ }
526
+
527
+ .image-gallery figure {
528
+ margin: 0;
529
+ height: 100%;
530
+ display: flex;
531
+ flex-direction: column;
532
+ border-radius: var(--image-border-radius);
533
+ overflow: hidden;
534
+ box-shadow: var(--shadow-sm);
535
+ }
536
+
537
+ .image-gallery figure:hover {
538
+ box-shadow: var(--shadow-md);
539
+ }
540
+
541
+ .image-gallery img {
542
+ width: 100%;
543
+ height: 100%;
544
+ object-fit: cover;
545
+ border-radius: var(--image-border-radius) var(--image-border-radius) 0 0;
546
+ transition: transform 0.3s ease;
547
+ }
548
+
549
+ .image-gallery figcaption {
550
+ padding: 0.5rem;
551
+ background-color: var(--image-caption-bg);
552
+ color: var(--image-caption-text);
553
+ font-size: 0.85rem;
554
+ border-radius: 0;
555
+ }
556
+
557
+ /* Zoom effect for gallery images */
558
+ .image-gallery.zoom img {
559
+ transition: transform 0.3s ease;
560
+ }
561
+
562
+ .image-gallery.zoom figure:hover img {
563
+ transform: scale(1.05);
564
+ }
565
+
566
+ /* Lightbox image styling */
567
+ img.lightbox {
568
+ cursor: zoom-in;
569
+ }
570
+
571
+ /* Framed image styling */
572
+ img.framed {
573
+ border: 8px solid white;
574
+ box-shadow: 0 0 0 1px var(--ruby-border), var(--shadow-md);
575
+ border-radius: 3px;
576
+ }
577
+
578
+ /* Polaroid-style image */
579
+ figure.polaroid {
580
+ background: white;
581
+ padding: 10px 10px 20px;
582
+ box-shadow: var(--shadow-md);
583
+ border-radius: 3px;
584
+ }
585
+
586
+ figure.polaroid img {
587
+ border-radius: 2px;
588
+ }
589
+
590
+ figure.polaroid figcaption {
591
+ background: white;
592
+ color: var(--ruby-text);
593
+ font-family: var(--ruby-font-family-serif);
594
+ font-style: italic;
595
+ }
596
+
597
+ /* Mobile responsiveness for images */
598
+ @media (max-width: 768px) {
599
+ .image-gallery {
600
+ grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
601
+ }
602
+
603
+ .image-gallery img {
604
+ height: 120px;
605
+ }
606
+ }
@@ -44,6 +44,9 @@ async function startDevServer(configPathOption, options = { preserve: false }) {
44
44
  let paths = resolveConfigPaths(config);
45
45
 
46
46
  // docmd's internal templates and assets (for live dev of docmd itself)
47
+ const DOCMD_COMMANDS_DIR = path.resolve(__dirname, '..', 'commands');
48
+ const DOCMD_CORE_DIR = path.resolve(__dirname, '..', 'core');
49
+ const DOCMD_PLUGINS_DIR = path.resolve(__dirname, '..', 'plugins');
47
50
  const DOCMD_TEMPLATES_DIR = path.resolve(__dirname, '..', 'templates');
48
51
  const DOCMD_ASSETS_DIR = path.resolve(__dirname, '..', 'assets');
49
52
 
@@ -199,13 +202,13 @@ async function startDevServer(configPathOption, options = { preserve: false }) {
199
202
  }
200
203
 
201
204
  // Add internal paths for docmd development (not shown to end users)
202
- const internalPaths = [DOCMD_TEMPLATES_DIR, DOCMD_ASSETS_DIR];
205
+ const internalPaths = [DOCMD_TEMPLATES_DIR, DOCMD_ASSETS_DIR, DOCMD_COMMANDS_DIR, DOCMD_CORE_DIR, DOCMD_PLUGINS_DIR];
203
206
 
204
207
  // Only in development environments, we might want to watch internal files too
205
208
  if (process.env.DOCMD_DEV === 'true') {
206
209
  watchedPaths.push(...internalPaths);
207
210
  }
208
-
211
+
209
212
  console.log(`👀 Watching for changes in:`);
210
213
  console.log(` - Source: ${formatPathForDisplay(paths.srcDirToWatch, CWD)}`);
211
214
  console.log(` - Config: ${formatPathForDisplay(paths.configFileToWatch, CWD)}`);
@@ -35,6 +35,7 @@ module.exports = {
35
35
  // Custom JavaScript Files
36
36
  customJs: [ // Array of paths to custom JS files, loaded at end of body
37
37
  // '/assets/js/custom-script.js', // Paths relative to outputDir root
38
+ '/assets/js/docmd-image-lightbox.js', // Image lightbox functionality
38
39
  ],
39
40
 
40
41
  // Plugins Configuration
@@ -85,6 +86,7 @@ module.exports = {
85
86
  { title: 'Documentation', path: 'https://docmd.mgks.dev', icon: 'scroll', external: true },
86
87
  { title: 'Installation', path: 'https://docmd.mgks.dev/getting-started/installation', icon: 'download', external: true },
87
88
  { title: 'Basic Usage', path: 'https://docmd.mgks.dev/getting-started/basic-usage', icon: 'play', external: true },
89
+ { title: 'Content', path: 'https://docmd.mgks.dev/content', icon: 'layout-template', external: true },
88
90
  ],
89
91
  },
90
92
  // External links:
@@ -6,7 +6,7 @@
6
6
 
7
7
  <%- metaTagsHtml || '' %> <%# SEO Plugin Meta Tags %>
8
8
 
9
- <title><%= pageTitle %> | <%= siteTitle %></title>
9
+ <title><%= pageTitle %> : <%= siteTitle %></title>
10
10
  <% if (description && !(metaTagsHtml && metaTagsHtml.includes('name="description"'))) { %>
11
11
  <meta name="description" content="<%= description %>">
12
12
  <% } %>