@sveltia/cms 0.77.0 → 0.77.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -76,6 +76,7 @@ The free, open source alternative/successor to Netlify/Decap CMS is now in publi
76
76
  - [Disabling stock assets](#disabling-stock-assets)
77
77
  - [Editing data files with a top-level list](#editing-data-files-with-a-top-level-list)
78
78
  - [Changing the input type of a DateTime field](#changing-the-input-type-of-a-datetime-field)
79
+ - [Rendering soft line breaks as hard line breaks in Markdown](#rendering-soft-line-breaks-as-hard-line-breaks-in-markdown)
79
80
  - [Controlling data output](#controlling-data-output)
80
81
  - [Disabling automatic deployments](#disabling-automatic-deployments)
81
82
  - [Setting up Content Security Policy](#setting-up-content-security-policy)
@@ -130,8 +131,9 @@ While we fix reported bugs as quickly as possible, usually within 24 hours, our
130
131
  - Tackling as many [Netlify/Decap CMS issues](https://github.com/decaporg/decap-cms/issues) as possible
131
132
  - So far, 210+ issues, or 420+ if including duplicates, have been effectively solved in Sveltia CMS
132
133
  - Target:
133
- - 200 issues, or 400 if including duplicates, by GA (we did it!)
134
+ - 200 issues, or 400 if including duplicates, by GA We did it! 🎉
134
135
  - 350 issues, or 700 if including duplicates, in the future
136
+ - or everything that’s relevant, fixable and worthwhile 💪
135
137
  - Issues include everything from feature requests to bug reports and [issues closed as stale](https://github.com/decaporg/decap-cms/issues?q=is%3Aissue+%22Closing+as+stale%22) or without an effective solution, as well as [discussions](https://github.com/decaporg/decap-cms/discussions) and stalled [pull requests](https://github.com/decaporg/decap-cms/pulls)
136
138
  - Most of the bugs, including annoying crashes, are already solved
137
139
  - Many of their [top-voted features](https://github.com/decaporg/decap-cms/issues?q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc) are on our table or already implemented in Sveltia CMS
@@ -148,7 +150,7 @@ Netlify/Decap CMS users will definitely be pleased and surprised by the numerous
148
150
 
149
151
  ### Better UX
150
152
 
151
- - Created and actively maintained by an [experienced UX engineer](https://github.com/kyoshino) who loves code, design and marketing. You can expect constant improvements to the user experience (UX) and developer experience (DX) across the platform.
153
+ - Created and actively maintained by an [experienced UX engineer](https://github.com/kyoshino) who loves code, design, marketing and problem solving. You can expect constant improvements to the user experience (UX) and developer experience (DX) across the platform.
152
154
  - The maintainer tries to respond to bug reports as quickly as possible. While there are no guarantees, the typical turnaround time for a bug fix is less than 24 hours.
153
155
  - Frequent releases deliver new features and enhancements to users faster. Most of our minor [releases](https://github.com/sveltia/sveltia-cms/releases) address one or more Netlify/Decap CMS issues, giving you even more reasons to switch from the legacy predecessor.
154
156
  - Offers a modern, intuitive user interface that utilizes the full viewport,[^178] inspired in part by the Netlify CMS v3 prototype.[^1][^211][^212][^213][^214]
@@ -174,6 +176,7 @@ Netlify/Decap CMS users will definitely be pleased and surprised by the numerous
174
176
  - Uses caching, lazy loading and infinite scrolling techniques. A list of repository files is stored locally for faster startup and bandwidth savings.
175
177
  - Thumbnails of assets, including videos and PDF files, are generated and cached for faster rendering of the Asset Library and other parts of the CMS.[^39][^38]
176
178
  - No typing lag on input widgets, especially within nested lists and objects.[^77]
179
+ - The entry preview doesn’t use an `<iframe>` because it’s a performance overhead.[^179]
177
180
 
178
181
  ### Better productivity
179
182
 
@@ -404,7 +407,7 @@ Sveltia CMS has been built with a multilingual architecture from the very beginn
404
407
  - A required List field with no subfield or value is marked as invalid.[^43] No need to set the `min` and `max` options for the `required` option to work.
405
408
  - An optional List field with no subfield or value is saved as an empty array, rather than nothing.[^44]
406
409
  - An optional List field won’t populate an item by default when the subfield has the `default` value.[^162]
407
- - A simple list field with no subfields is displayed as a multiline text field,[^219] where users can enter spaces and commas.[^50][^220]
410
+ - A simple List field with no subfields is displayed as a multiline text field,[^219] where users can use spaces[^50] and commas[^220] for list items. A comma is no longer treated as a list delimiter.
408
411
  - Users can preview variable types without having to register a preview template.[^42]
409
412
  - It’s possible to omit `fields` in a variable type object.[^163] In that case, only the `typeKey` (default: `type`) is saved in the output.
410
413
  - A collapsed List field will not display a programmatic summary like `List [ Map { "key": "value" } ]` if the `summary` option is not set.[^183]
@@ -419,7 +422,7 @@ Sveltia CMS has been built with a multilingual architecture from the very beginn
419
422
  - The built-in `code-block` component is implemented just like a blockquote. You can simply convert a normal paragraph into a code block instead of adding a component.
420
423
  - Code in a code block in the editor can be copied as expected.[^165]
421
424
  - Language-annotated code block doesn’t trigger unsaved changes.[^189]
422
- - Line breaks are rendered as line breaks in the Preview Pane according to GitHub Flavored Markdown (GFM).
425
+ - Soft line breaks are [rendered as hard line breaks](#rendering-soft-line-breaks-as-hard-line-breaks-in-markdown) in the Preview Pane.
423
426
  - Number
424
427
  - If the `value_type` option is `int` (default) or `float`, the `required` option is `false`, and the value is not entered, the field will be saved as `null` instead of an empty string.[^157] If `value_type` is anything else, the data type will remain a string.
425
428
  - Object
@@ -432,9 +435,10 @@ Sveltia CMS has been built with a multilingual architecture from the very beginn
432
435
  - Template strings with a wildcard like `{{cities.*.name}}` can also be used for `value_field`.[^94]
433
436
  - `display_fields` is displayed in the Preview Pane instead of `value_field`.
434
437
  - The redundant `search_fields` option is optional in Sveltia CMS, as it defaults to `display_fields`, `value_field` or the collection’s `identifier_field`, which is `title` by default.
435
- - The `value_field` option is also optional in Sveltia CMS, as it defaults to entry slugs (`{{slug}}`).
438
+ - The `value_field` option is also optional in Sveltia CMS, as it defaults to `{{slug}}` (entry slugs).
436
439
  - A new item created in a referenced collection is immediately available in the options.[^138]
437
- - It’s possible to refer to a list field with the `field` option, which produces a single subfield but does not output the subfield `name` in the data, using the `value_field: cities.*.name` syntax. ([Discussion](https://github.com/sveltia/sveltia-cms/discussions/400))
440
+ - A referenced DateTime field value is displayed in the specified format.[^221]
441
+ - It’s possible to refer to a List field with the `field` option, which produces a single subfield but does not output the subfield `name` in the data, using the `value_field: cities.*.name` syntax. ([Discussion](https://github.com/sveltia/sveltia-cms/discussions/400))
438
442
  - Select
439
443
  - It’s possible to select an option with value `0`.[^56]
440
444
  - `label` is displayed in the Preview Pane instead of `value`.
@@ -1118,6 +1122,22 @@ Use `date_format: false` to hide the date picker and make the input [time only](
1118
1122
 
1119
1123
  We understand that this configuration may be a bit confusing, but it’s necessary to maintain backward compatibility with Netlify CMS. We plan to improve the widget options and introduce new input types: [month](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/month) and [week](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/week).
1120
1124
 
1125
+ ### Rendering soft line breaks as hard line breaks in Markdown
1126
+
1127
+ This tip is not really specific to Sveltia CMS, but some developers have asked the maintainer about it:
1128
+
1129
+ In the Markdown editor, pressing `Shift+Enter` inserts a [soft line break](https://spec.commonmark.org/0.31.2/#soft-line-breaks) (`\n`). We can’t change the behaviour to add a [hard line break](https://spec.commonmark.org/0.31.2/#hard-line-breaks) (`<br>`) — it’s a limitation of the underlying [Lexical](https://lexical.dev/) framework. However, if you look at the preview, you may notice that a soft line break is rendered as a hard line break. That’s because the preview is using the [Marked](https://github.com/markedjs/marked) library with the [`breaks` option](https://marked.js.org/using_advanced#options) enabled, which mimics how comments are rendered on GitHub.
1130
+
1131
+ Chances are the Markdown parser you use for your frontend can do the same:
1132
+
1133
+ - [markdown-it](https://github.com/markdown-it/markdown-it) (used in Eleventy and VitePress) also has the `breaks` option
1134
+ - [remarkable](https://github.com/jonschlinkert/remarkable) also has the `breaks` option
1135
+ - [Showdown](https://github.com/showdownjs/showdown) has the `simpleLineBreaks` option
1136
+ - [goldmark](https://github.com/yuin/goldmark/) (used in Hugo) has the `html.WithHardWraps` option
1137
+ - [kramdown](https://github.com/gettalong/kramdown) (used in Jekyll) has the `hard_wrap` option with the GFM parser
1138
+ - [remark](https://github.com/remarkjs/remark) (used in Astro) offers a [plugin](https://github.com/remarkjs/remark-breaks)
1139
+ - [micromark](https://github.com/micromark/micromark) clarifies it doesn’t have such an option and recommends alternatives
1140
+
1121
1141
  ### Controlling data output
1122
1142
 
1123
1143
  Sveltia CMS supports some [data output](#better-data-output) options, including JSON/YAML formatting preferences, at the root level of the configuration file. The default options are listed below:
@@ -1284,7 +1304,7 @@ A Release Notes link will now appear under the Account menu with the current app
1284
1304
 
1285
1305
  While we don’t have dedicated developer/user support resources, you can post [quick questions](https://github.com/sveltia/sveltia-cms/discussions/new?category=q-a) on the [Discussions](https://github.com/sveltia/sveltia-cms/discussions) page of our GitHub repository. [Feedback](https://github.com/sveltia/sveltia-cms/discussions/new?category=ideas) is also welcome, but please check the [Compatibility](#compatibility) and [Roadmap](#roadmap) sections of this README before starting a new discussion — your idea may already be covered.
1286
1306
 
1287
- Hop on [our Discord server](https://discord.gg/5hwCGqup5b) for casual chat.
1307
+ Join us on [Discord](https://discord.gg/5hwCGqup5b) or ping us on [Bluesky](https://bsky.app/profile/sveltiacms.app) for a casual chat.
1288
1308
 
1289
1309
  As described throughout this README, Sveltia CMS is being built as a replacement for Netlify/Decap CMS. At this point, we assume that most developers and users are moving from the other product. We are happy to help you migrate, but **we cannot help you set up Sveltia CMS from scratch** through our free support channels.
1290
1310
 
@@ -1492,7 +1512,7 @@ This software is provided “as is” without any express or implied warranty. W
1492
1512
 
1493
1513
  [^72]: Netlify/Decap CMS [#7047](https://github.com/decaporg/decap-cms/issues/7047)
1494
1514
 
1495
- [^73]: Netlify/Decap CMS [#6993](https://github.com/decaporg/decap-cms/issues/6993), [#7123](https://github.com/decaporg/decap-cms/issues/7123), [#7127](https://github.com/decaporg/decap-cms/issues/7127), [#7128](https://github.com/decaporg/decap-cms/issues/7128), [#7237](https://github.com/decaporg/decap-cms/issues/7237), [#7251](https://github.com/decaporg/decap-cms/issues/7251), [#7361](https://github.com/decaporg/decap-cms/issues/7361), [#7391](https://github.com/decaporg/decap-cms/issues/7391), [#7393](https://github.com/decaporg/decap-cms/issues/7393), [#7470](https://github.com/decaporg/decap-cms/issues/7470)
1515
+ [^73]: Netlify/Decap CMS [#6993](https://github.com/decaporg/decap-cms/issues/6993), [#7123](https://github.com/decaporg/decap-cms/issues/7123), [#7127](https://github.com/decaporg/decap-cms/issues/7127), [#7128](https://github.com/decaporg/decap-cms/issues/7128), [#7237](https://github.com/decaporg/decap-cms/issues/7237), [#7251](https://github.com/decaporg/decap-cms/issues/7251), [#7361](https://github.com/decaporg/decap-cms/issues/7361), [#7391](https://github.com/decaporg/decap-cms/issues/7391), [#7393](https://github.com/decaporg/decap-cms/issues/7393), [#7470](https://github.com/decaporg/decap-cms/issues/7470), [#7475](https://github.com/decaporg/decap-cms/issues/7475)
1496
1516
 
1497
1517
  [^74]: Netlify/Decap CMS [#4209](https://github.com/decaporg/decap-cms/issues/4209)
1498
1518
 
@@ -1787,3 +1807,5 @@ This software is provided “as is” without any express or implied warranty. W
1787
1807
  [^219]: Netlify/Decap CMS [#3018](https://github.com/decaporg/decap-cms/issues/3018)
1788
1808
 
1789
1809
  [^220]: Netlify/Decap CMS [#2153](https://github.com/decaporg/decap-cms/issues/2153)
1810
+
1811
+ [^221]: Netlify/Decap CMS [#3421](https://github.com/decaporg/decap-cms/issues/3421)