@uniformdev/transformer 1.1.23 → 1.1.25

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/dist/cli/index.js CHANGED
@@ -592,11 +592,13 @@ var CompositionConverterService = class {
592
592
  contentTypesDir,
593
593
  entriesDir,
594
594
  compositionTypes,
595
- componentsToReferences,
596
- componentsToBlocks,
595
+ componentsToReferences: rawComponentsToReferences,
596
+ componentsToBlocks: rawComponentsToBlocks,
597
597
  whatIf,
598
598
  strict
599
599
  } = options;
600
+ const componentsToReferences = [...new Set(rawComponentsToReferences)];
601
+ const componentsToBlocks = [...new Set(rawComponentsToBlocks)];
600
602
  const compositionsDirFull = this.fileSystem.resolvePath(rootDir, compositionsDir);
601
603
  const componentsDirFull = this.fileSystem.resolvePath(rootDir, componentsDir);
602
604
  const contentTypesDirFull = this.fileSystem.resolvePath(rootDir, contentTypesDir);
@@ -870,7 +872,7 @@ var CompositionConverterService = class {
870
872
  type: "contentReference",
871
873
  typeConfig: {
872
874
  isMulti: true,
873
- allowedContentTypes: [refType]
875
+ allowedTypes: [refType]
874
876
  },
875
877
  localizable: false
876
878
  });
@@ -892,7 +894,7 @@ var CompositionConverterService = class {
892
894
  name: resolvedBlockId,
893
895
  type: "$block",
894
896
  typeConfig: {
895
- allowedContentTypes: [resolvedBlockId]
897
+ allowedTypes: [resolvedBlockId]
896
898
  },
897
899
  localizable: false
898
900
  });
@@ -4330,7 +4332,7 @@ function createConvertCompositionsToEntriesCommand() {
4330
4332
  );
4331
4333
  try {
4332
4334
  const compositionTypes = options.compositionTypes.split("|").map((t) => t.trim()).filter((t) => t.length > 0);
4333
- const parsePipeSeparated = (value) => value ? value.split("|").map((t) => t.trim()).filter((t) => t.length > 0) : [];
4335
+ const parsePipeSeparated = (value) => value ? [...new Set(value.split("|").map((t) => t.trim()).filter((t) => t.length > 0))] : [];
4334
4336
  const componentsToReferences = parsePipeSeparated(options.componentsToReferences);
4335
4337
  const componentsToBlocks = parsePipeSeparated(options.componentsToBlocks);
4336
4338
  const result = await converter.convert({
@@ -4903,7 +4905,7 @@ function createRemoveFieldCommand() {
4903
4905
  // package.json
4904
4906
  var package_default = {
4905
4907
  name: "@uniformdev/transformer",
4906
- version: "1.1.23",
4908
+ version: "1.1.25",
4907
4909
  description: "CLI tool for transforming Uniform.dev serialization files offline",
4908
4910
  type: "module",
4909
4911
  bin: {