@wix/ditto-codegen-public 1.0.361 → 1.0.362

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.
Files changed (2) hide show
  1. package/dist/out.js +27 -1
  2. package/package.json +2 -2
package/dist/out.js CHANGED
@@ -12694,6 +12694,31 @@ var require_internal_paths = __commonJS({
12694
12694
  }
12695
12695
  });
12696
12696
 
12697
+ // dist/opencode-integration/normalize-tool-string.js
12698
+ var require_normalize_tool_string = __commonJS({
12699
+ "dist/opencode-integration/normalize-tool-string.js"(exports2) {
12700
+ "use strict";
12701
+ Object.defineProperty(exports2, "__esModule", { value: true });
12702
+ exports2.normalizeToolString = normalizeToolString;
12703
+ function unescapeString(str) {
12704
+ return str.replace(/\\(n|t|r|"|\\)/g, (_, c) => {
12705
+ if (c === "n")
12706
+ return "\n";
12707
+ if (c === "t")
12708
+ return " ";
12709
+ if (c === "r")
12710
+ return "\r";
12711
+ if (c === '"')
12712
+ return '"';
12713
+ return "\\";
12714
+ });
12715
+ }
12716
+ function normalizeToolString(text) {
12717
+ return unescapeString(text).replace(/\r\n/g, "\n");
12718
+ }
12719
+ }
12720
+ });
12721
+
12697
12722
  // dist/opencode-integration/parser.js
12698
12723
  var require_parser = __commonJS({
12699
12724
  "dist/opencode-integration/parser.js"(exports2) {
@@ -12712,6 +12737,7 @@ var require_parser = __commonJS({
12712
12737
  var types_1 = require_types4();
12713
12738
  var constants_1 = require_constants5();
12714
12739
  var internal_paths_1 = require_internal_paths();
12740
+ var normalize_tool_string_1 = require_normalize_tool_string();
12715
12741
  function parseEvents(output, type) {
12716
12742
  return output.split("\n").filter((line) => line.trim()).map((line) => (0, types_1.tryParseJson)(line)).filter((event) => event !== null && event.type === type);
12717
12743
  }
@@ -12745,7 +12771,7 @@ var require_parser = __commonJS({
12745
12771
  const declared = event.part.state.input?.output;
12746
12772
  if (typeof declared !== "string")
12747
12773
  continue;
12748
- markdown = declared;
12774
+ markdown = (0, normalize_tool_string_1.normalizeToolString)(declared);
12749
12775
  }
12750
12776
  return markdown;
12751
12777
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/ditto-codegen-public",
3
- "version": "1.0.361",
3
+ "version": "1.0.362",
4
4
  "description": "AI-powered Wix CLI app generator - standalone executable",
5
5
  "scripts": {
6
6
  "build": "node build.mjs",
@@ -29,5 +29,5 @@
29
29
  "esbuild": "^0.27.2",
30
30
  "vitest": "^4.0.16"
31
31
  },
32
- "falconPackageHash": "7b4f927c3fdd53219a51a891cc6b6828c72bd0ebe13e7d33b7da4cd1"
32
+ "falconPackageHash": "17c320c3fae4886b3e20248ff6adb58607f4d0e2e93af6aa054a5928"
33
33
  }