Skip to content

Commit b6f8c1b

Browse files
committed
Merge branch 'dev'
2 parents 8c6c03a + 111f56d commit b6f8c1b

File tree

13 files changed

+348
-98
lines changed

13 files changed

+348
-98
lines changed

.frontmatter/database/mediaDb.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

content/changelog/CHANGELOG.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,16 @@
88

99
### 🎨 Enhancements
1010

11+
- [#441](https://github.com/estruyf/vscode-front-matter/issues/441): Show input descriptions for snippet and data forms
12+
- [#442](https://github.com/estruyf/vscode-front-matter/issues/442): Hide sidebar on data view when data file is selected + show dropdown of data files
13+
- [#788](https://github.com/estruyf/vscode-front-matter/issues/788): Show a warning on setting update when it exists in an extended configuration
1114
- [#798](https://github.com/estruyf/vscode-front-matter/issues/798): Changed dialog to slide-over for the snippet forms
12-
- [#799](https://github.com/estruyf/vscode-front-matter/issues/799): Added `frontMatter.logging` setting to define the logging output. Options are `info`, `warn`, `error`, and `verbose`. Default is `info`.
15+
- [#799](https://github.com/estruyf/vscode-front-matter/issues/799): Added `frontMatter.logging` setting to define the logging output. Options are `info`, `warn`, `error`, and `verbose`. The default is `info`.
1316
- [#800](https://github.com/estruyf/vscode-front-matter/issues/800): Add colors for the Front Matter CMS output
17+
- [#808](https://github.com/estruyf/vscode-front-matter/issues/808): Add support to generate field groups and `block` fields in content type generation
1418
- [#810](https://github.com/estruyf/vscode-front-matter/issues/810): Update the tab title based on the view
19+
- [#811](https://github.com/estruyf/vscode-front-matter/issues/811): Added `panel.gitActions` view mode option to hide the Git actions in the panel
20+
- [#812](https://github.com/estruyf/vscode-front-matter/issues/812): Added the `{{locale}}` placeholder, which can be used in the `previewPath` property
1521

1622
### ⚡️ Optimizations
1723

content/changelog/v10.2.0.md

Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
---
2+
title: Version 10.2.0 release notes
3+
description: Get the latest version of Front Matter CMS with improved logging, snippet card actions, and multilingual support.
4+
date: 2024-06-12T10:18:54.532Z
5+
lastmod: 2024-06-12T10:18:55.082Z
6+
slug: v10.2.0
7+
type: changelog
8+
---
9+
10+
## Logging improvements
11+
12+
In this release, we have added a new setting `frontMatter.logging` which allows you to define the logging output. The options are `info`, `warn`, `error`, and `verbose`. The default is `info`.
13+
14+
We also added some colors to highlight the different logging levels in the Front Matter CMS output.
15+
16+
![Front Matter CMS logging](/releases/v10.2.0/logging-levels.webp)
17+
18+
## Snippet card actions
19+
20+
Similar to the previous release, we have added common actions at the bottom of the snippet cards. This allows you to perform actions on the snippets without having to open the snippet menu.
21+
22+
![Snippet card actions](/releases/v10.2.0/snippet-actions.webp)
23+
24+
## Snippets dialog is now a slide-over
25+
26+
The snippets dialog has been updated to be a slide-over dialog. This makes it easier to work with longer snippet forms.
27+
28+
## Hiding the data sidebar when editing data files
29+
30+
When you are editing a data file, the data sidebar will now be hidden. This allows you to focus on the data file you are editing. Additionally, a dropdown of data files is shown, allowing you to switch between data files.
31+
32+
![Data sidebar](/releases/v10.2.0/data-sidebar.webp)
33+
34+
## Enhance multilingual support by adding the locale placeholder
35+
36+
We have added a new placeholder `{{locale}}` which can be used in the `previewPath` property. This allows you to generate different preview URLs based on the locale of the content.
37+
38+
```json {{ "title": "Example: Use the locale in your preview path" }}
39+
"frontMatter.content.pageFolders": [
40+
{
41+
"title": "docs",
42+
"path": "[[workspace]]/src/content/docs",
43+
"previewPath": "/{{locale|ignore:en}}",
44+
"trailingSlash": true,
45+
"contentTypes": ["blog"]
46+
}
47+
]
48+
```
49+
50+
The preview path will generate the following path for English content: `/<slug>/`. For other locales, the preview path will generate the following path: `/<locale>/<slug>/` (e.g. `/nl/<slug>/`).
51+
52+
> **Info**: You can read more about the `{{locale}}` placeholder in the [special placeholders](/docs/content-creation/placeholders#example-5-using-the-locale-placeholder) section.
53+
54+
## Added support for trailing slashes in the preview path
55+
56+
You can now define whether you want to have trailing slashes in the preview path. This can be done by setting the `trailingSlash` property to `true` or `false`. The setting can be defined on global, content folder, and content type levels.
57+
58+
```json {{ "title": "Example: Use trailing slashes in the preview path" }}
59+
{
60+
"frontMatter.preview.trailingSlash": true
61+
}
62+
```
63+
64+
## Related issues/enhancements
65+
66+
### ✨ New features
67+
68+
- [#797](https://github.com/estruyf/vscode-front-matter/issues/797): Adding common actions at the bottom of the snippet cards
69+
70+
### 🎨 Enhancements
71+
72+
- [#441](https://github.com/estruyf/vscode-front-matter/issues/441): Show input descriptions for snippet and data forms
73+
- [#442](https://github.com/estruyf/vscode-front-matter/issues/442): Hide sidebar on data view when data file is selected + show dropdown of data files
74+
- [#788](https://github.com/estruyf/vscode-front-matter/issues/788): Show a warning on setting update when it exists in an extended configuration
75+
- [#798](https://github.com/estruyf/vscode-front-matter/issues/798): Changed dialog to slide-over for the snippet forms
76+
- [#799](https://github.com/estruyf/vscode-front-matter/issues/799): Added `frontMatter.logging` setting to define the logging output. Options are `info`, `warn`, `error`, and `verbose`. The default is `info`.
77+
- [#800](https://github.com/estruyf/vscode-front-matter/issues/800): Add colors for the Front Matter CMS output
78+
- [#808](https://github.com/estruyf/vscode-front-matter/issues/808): Add support to generate field groups and `block` fields in content type generation
79+
- [#810](https://github.com/estruyf/vscode-front-matter/issues/810): Update the tab title based on the view
80+
- [#811](https://github.com/estruyf/vscode-front-matter/issues/811): Added `panel.gitActions` view mode option to hide the Git actions in the panel
81+
- [#812](https://github.com/estruyf/vscode-front-matter/issues/812): Added the `{{locale}}` placeholder, which can be used in the `previewPath` property
82+
83+
### ⚡️ Optimizations
84+
85+
- [#802](https://github.com/estruyf/vscode-front-matter/issues/802): Update `glob` to the latest version and remove the sync method
86+
87+
### 🐞 Fixes
88+
89+
- [#796](https://github.com/estruyf/vscode-front-matter/issues/796): Fix issue in retrieving folders/files on dashboard load
90+
- [#801](https://github.com/estruyf/vscode-front-matter/issues/801): Faster folder processing on updates
91+
- [#804](https://github.com/estruyf/vscode-front-matter/issues/804): Fix blinking of the front matter content area
92+
- [#806](https://github.com/estruyf/vscode-front-matter/issues/804): Fix preview URL for `index.md` files in root of the page folder path
93+
- [#809](https://github.com/estruyf/vscode-front-matter/issues/809): Fix retrieving the `filePrefix` when updating the file name on slug change

content/docs/content-creation/placeholders.md

Lines changed: 62 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: Placeholders
33
slug: content-creation/placeholders
44
description: Learn how to use placeholders in Front Matter CMS
55
date: 2022-03-14T08:42:21.626Z
6-
lastmod: 2024-02-24T13:18:09.798Z
6+
lastmod: 2024-06-10T13:21:59.465Z
77
weight: 200.51
88
---
99

@@ -29,12 +29,14 @@ automatically fill in values when creating a new content.
2929

3030
## Special placeholders
3131

32-
| Placeholder | Description | Works for |
33-
| ----------------------- | ------------------------------------------------------------------------------------------------------------------ | ----------------------------------------------------- |
34-
| `{{seoTitle}}` | This creates a SEO friendly slug from the title. More info can be found in the [slug][02] section. | `slugTemplate` properties. |
35-
| `{{fm.<field name>}}` | The value of the field in the front matter | `slugTemplate` and `previewPath` properties. |
36-
| `{{pathToken.<index>}}` | The value of the path token at the index | `previewPath` on the page folder or the content-type. |
37-
| `{{pathToken.relPath}}` | The relative value path staring from the page folder' path | `previewPath` on the page folder or the content-type. |
32+
| Placeholder | Description | Works for |
33+
| --- | --- | --- |
34+
| `{{seoTitle}}` | This creates a SEO friendly slug from the title. More info can be found in the [slug][02] section. | `slugTemplate` properties |
35+
| `{{date\|<format>}}` | Use the publishing date of your article in the preview URL. Example: `/blog/{{date\|yyyy-MM}}` | `previewPath` property |
36+
| `{{locale}}` | The locale of the page. | `previewPath` property |
37+
| `{{fm.<field name>}}` | The value of the field in the front matter | `slugTemplate` and `previewPath` properties |
38+
| `{{pathToken.<index>}}` | The value of the path token at the index | `previewPath` on the page folder or the content-type |
39+
| `{{pathToken.relPath}}` | The relative value path staring from the page folder' path | `previewPath` on the page folder or the content-type |
3840

3941
### Example 1
4042

@@ -90,6 +92,59 @@ The above configuration results in the following path: `/blog/25/02/23/`.
9092

9193
![Placeholder field formatting](/releases/v9.0.0/placeholder-formatting.png)
9294

95+
### Example 4: using the {{date\|\<format\>}} placeholder
96+
97+
The `{{date|<format>}}` placeholder can be used in the `previewPath` property and uses the field
98+
with the name `date` or a date field where the `isPublishDate` property is set to `true`.
99+
100+
```json {{ "title": "Using the date placeholder", "description": "" }}
101+
"frontMatter.content.pageFolders": [
102+
{
103+
"title": "blog",
104+
"filePrefix": null,
105+
"previewPath": "/{{fm.type}}/{{date|yyyy}}",
106+
"path": "[[workspace]]/content"
107+
}
108+
]
109+
```
110+
111+
The above configuration results in the following path: `/blog/2024/`.
112+
113+
### Example 5: using the {{locale}} placeholder
114+
115+
The `{{locale}}` placeholder will return the locale of the page when you have
116+
a [multi-language setup](/docs/content-creation/multilingual).
117+
118+
```json {{ "title": "Using the locale placeholder", "description": "" }}
119+
"frontMatter.content.pageFolders": [
120+
{
121+
"title": "blog",
122+
"filePrefix": null,
123+
"previewPath": "/{{locale}}",
124+
"path": "[[workspace]]/content"
125+
}
126+
]
127+
```
128+
129+
The above configuration results in the following path for English content: `/en/<slug>/`.
130+
131+
You can also ignore a specific locale by using the `ignore:<locale>` option.
132+
133+
```json {{ "title": "Ignoring a specific locale", "description": "" }}
134+
"frontMatter.content.pageFolders": [
135+
{
136+
"title": "blog",
137+
"filePrefix": null,
138+
"previewPath": "/{{locale|ignore:en}}",
139+
"path": "[[workspace]]/content"
140+
}
141+
]
142+
```
143+
144+
The above configuration results in the following path for English content: `/<slug>/`.
145+
For other locales, the preview path will generate the following path:
146+
`/<locale>/<slug>/` (e.g. `/nl/<slug>/`).
147+
93148
## Custom placeholders
94149

95150
You can define you own placeholders within the `frontMatter.content.placeholders` setting. There are

content/docs/panel.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: Editor panel
33
slug: panel
44
description: null
55
date: 2021-08-30T16:13:00.546Z
6-
lastmod: 2023-10-06T13:47:51.482Z
6+
lastmod: 2024-06-10T08:24:04.381Z
77
weight: 400
88
---
99

@@ -200,6 +200,7 @@ You define a mode with an `id` and a set of features. The allowed features are t
200200
### Panel
201201

202202
- `panel.globalSettings`: Show the global settings section.
203+
- `panel.gitActions`: Show the git actions section.
203204
- `panel.seo`: Show the SEO status section.
204205
- `panel.actions`: Show the actions section.
205206
- `panel.metadata`: Show the metadata section.

content/docs/settings/available-settings.md

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: Settings overview
33
slug: settings/overview
44
description: null
55
date: 2023-02-13T16:44:09.618Z
6-
lastmod: 2024-02-26T17:54:04.814Z
6+
lastmod: 2024-06-10T09:13:40.409Z
77
weight: 1000.2
88
---
99

@@ -13,6 +13,23 @@ Here you can find an overview of all available settings.
1313

1414
## Available settings
1515

16+
### frontMatter.logging
17+
18+
Specify the logging level you want to use for the extension.
19+
20+
- Type: `string`
21+
- Default: `info`
22+
23+
Options:
24+
25+
- `verbose`
26+
- `info`
27+
- `warning`
28+
- `error`
29+
30+
> **Info**: More information on how to use it can be found in the
31+
> [troubleshooting - logging](/docs/troubleshooting#logging) section.
32+
1633
### frontMatter.config.dynamicFilePath
1734

1835
Allows you to specify a dynamic config file path which will be used during the initialization of
@@ -509,6 +526,13 @@ field value.
509526
> characters you enter. In case you want to skip some characters or all of them, you need to wrap
510527
> that part between two single quotes. Example: `"'blog/'yyyy/MM"` will result in: `blog/2021/08`.
511528
529+
### frontMatter.preview.trailingSlash
530+
531+
Specify if you want to add a trailing slash to the preview URL.
532+
533+
- Type: `boolean`
534+
- Default: `false`
535+
512536
### frontMatter.projects
513537

514538
Allows you to specify a list of projects you want to manage with Front Matter CMS. Each project

0 commit comments

Comments
 (0)