Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@cloudcannon/configuration-types

Package Overview
Dependencies
Maintainers
0
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cloudcannon/configuration-types - npm Package Compare versions

Comparing version 0.0.20 to 0.0.21

2

package.json
{
"name": "@cloudcannon/configuration-types",
"version": "0.0.20",
"version": "0.0.21",
"description": "Contains TypeScript declarations and generates JSONSchema files for the CloudCannon configuration file.",

@@ -5,0 +5,0 @@ "author": "CloudCannon <support@cloudcannon.com>",

@@ -91,3 +91,5 @@ import type { CollectionConfig, Configuration, DataConfigEntry, Paths } from './configuration';

export interface BuildCoupledCollectionConfig extends Omit<CollectionConfig, 'url'>, Filterable {
export interface BuildCoupledCollectionConfig
extends Omit<CollectionConfig, 'url' | 'path'>,
Filterable {
/**

@@ -98,8 +100,13 @@ * Overrides the default singular input key of the collection. This is used for naming conventions

singular_key?: string;
/**
* The top-most folder where the files in this collection are stored. It is relative to `source`.
*/
path?: string;
}
interface BuildCoupledConfiguration
extends Omit<Configuration, 'data_config'>,
extends Omit<Configuration, 'data_config' | 'collections_config'>,
WithCollectionsConfigOverride {
paths?: BuildCoupledPaths;
collections_config?: BuildCoupledCollectionConfig;
}

@@ -106,0 +113,0 @@

@@ -1272,53 +1272,60 @@ import type Scrapbooker from '@cloudcannon/snippet-types';

export type AddOption =
| {
/**
* The text displayed for the menu item. Defaults to using name from the matching schema if
* set.
*/
name?: string;
/**
* The icon next to the text in the menu item. Defaults to using icon from the matching schema
* if set, then falls back to add.
*/
icon?: Icon;
/**
* The editor to open the new file in. Defaults to an appropriate editor for new file's type
* if possible. If no default editor can be calculated, or the editor does not support the new
* file type, a warning is shown in place of the editor.
*/
editor?: EditorKey;
/**
* Enforces a path for new files to be created in, regardless of path the user is currently
* navigated to within the collection file list. Relative to the path of the collection
* defined in collection. Defaults to the path within the collection the user is currently
* navigated to.
*/
base_path?: string;
/**
* Sets which collection this action is creating a file in. This is used when matching the
* value for schema. Defaults to the containing collection these `add_options` are configured
* in.
*/
collection?: string;
/**
* The schema that new files are created from with this action. This schema is not restricted
* to the containing collection, and is instead relative to the collection specified with
* collection. Defaults to default if schemas are configured for the collection.
*/
schema?: string;
/**
* The path to a file used to populate the initial contents of a new file if no schemas are
* configured. We recommend using schemas, and this is ignored if a schema is available.
*/
default_content_file?: string;
}
| {
/**
* The link that opens when the option is clicked. Can either be an external or internal link.
* If internal, the link is relative to the current site.
*/
href: string;
};
export type HrefAddOption = {
/**
* The text displayed for the menu item.
*/
name?: string;
/**
* The icon next to the text in the menu item.
*
* @default add
*/
icon?: Icon;
/**
* The link that opens when the option is clicked. Can either be an external or internal link. If
* internal, the link is relative to the current site.
*/
href: string;
};
export type AddOption = {
/**
* The text displayed for the menu item. Defaults to using name from the matching schema if set.
*/
name?: string;
/**
* The icon next to the text in the menu item. Defaults to using icon from the matching schema if
* set, then falls back to add.
*/
icon?: Icon;
/**
* The editor to open the new file in. Defaults to an appropriate editor for new file's type if
* possible. If no default editor can be calculated, or the editor does not support the new file
* type, a warning is shown in place of the editor.
*/
editor?: EditorKey;
/**
* Enforces a path for new files to be created in, regardless of path the user is currently
* navigated to within the collection file list. Relative to the path of the collection defined in
* collection. Defaults to the path within the collection the user is currently navigated to.
*/
base_path?: string;
/**
* Sets which collection this action is creating a file in. This is used when matching the value
* for schema. Defaults to the containing collection these `add_options` are configured in.
*/
collection?: string;
/**
* The schema that new files are created from with this action. This schema is not restricted to
* the containing collection, and is instead relative to the collection specified with collection.
* Defaults to default if schemas are configured for the collection.
*/
schema?: string;
/**
* The path to a file used to populate the initial contents of a new file if no schemas are
* configured. We recommend using schemas, and this is ignored if a schema is available.
*/
default_content_file?: string;
};
interface WithPreview {

@@ -1492,3 +1499,3 @@ /**

*/
add_options?: AddOption[];
add_options?: (AddOption | HrefAddOption)[];
/**

@@ -1495,0 +1502,0 @@ * The create path definition to control where new files are saved to inside this collection.

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc