@vue/language-core 2.0.21 → 2.0.22

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 (49) hide show
  1. package/lib/codegen/common.js +6 -6
  2. package/lib/codegen/script/component.js +4 -5
  3. package/lib/codegen/script/context.js +1 -2
  4. package/lib/codegen/script/globalTypes.js +26 -18
  5. package/lib/codegen/script/index.js +20 -2
  6. package/lib/codegen/script/internalComponent.js +1 -2
  7. package/lib/codegen/script/scriptSetup.js +2 -15
  8. package/lib/codegen/script/src.js +1 -2
  9. package/lib/codegen/script/template.js +2 -3
  10. package/lib/codegen/template/camelized.js +1 -2
  11. package/lib/codegen/template/context.d.ts +1 -1
  12. package/lib/codegen/template/context.js +1 -2
  13. package/lib/codegen/template/element.js +4 -5
  14. package/lib/codegen/template/elementChildren.js +1 -2
  15. package/lib/codegen/template/elementDirectives.js +1 -2
  16. package/lib/codegen/template/elementEvents.js +8 -9
  17. package/lib/codegen/template/elementProps.js +6 -7
  18. package/lib/codegen/template/index.js +2 -3
  19. package/lib/codegen/template/interpolation.js +2 -3
  20. package/lib/codegen/template/objectProperty.js +1 -2
  21. package/lib/codegen/template/propertyAccess.js +1 -2
  22. package/lib/codegen/template/slotOutlet.js +1 -2
  23. package/lib/codegen/template/stringLiteralKey.js +1 -2
  24. package/lib/codegen/template/templateChild.js +3 -4
  25. package/lib/codegen/template/vFor.js +2 -3
  26. package/lib/codegen/template/vIf.js +3 -4
  27. package/lib/languageModule.js +1 -2
  28. package/lib/parsers/scriptRanges.js +1 -2
  29. package/lib/parsers/scriptSetupRanges.d.ts +27 -27
  30. package/lib/parsers/scriptSetupRanges.js +5 -6
  31. package/lib/plugins/file-md.js +6 -4
  32. package/lib/plugins/vue-tsx.d.ts +33 -33
  33. package/lib/plugins.d.ts +5 -5
  34. package/lib/plugins.js +1 -2
  35. package/lib/types.d.ts +2 -1
  36. package/lib/utils/buildMappings.d.ts +3 -0
  37. package/lib/utils/buildMappings.js +23 -0
  38. package/lib/utils/parseCssClassNames.js +1 -2
  39. package/lib/utils/parseCssVars.js +2 -3
  40. package/lib/utils/parseSfc.js +1 -2
  41. package/lib/utils/shared.js +3 -3
  42. package/lib/utils/ts.js +3 -4
  43. package/lib/virtualFile/computedFiles.d.ts +1 -1
  44. package/lib/virtualFile/computedFiles.js +6 -6
  45. package/lib/virtualFile/computedMappings.d.ts +1 -1
  46. package/lib/virtualFile/computedMappings.js +3 -4
  47. package/lib/virtualFile/computedSfc.js +1 -2
  48. package/lib/virtualFile/computedVueSfc.js +1 -2
  49. package/package.json +4 -3
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.computedMappings = void 0;
4
- const language_core_1 = require("@volar/language-core");
3
+ exports.computedMappings = computedMappings;
5
4
  const computeds_1 = require("computeds");
5
+ const muggle_string_1 = require("muggle-string");
6
6
  const shared_1 = require("../plugins/shared");
7
7
  function computedMappings(snapshot, sfc) {
8
8
  return (0, computeds_1.computed)(() => {
@@ -15,7 +15,7 @@ function computedMappings(snapshot, sfc) {
15
15
  ...sfc.customBlocks,
16
16
  ]) {
17
17
  if (block) {
18
- (0, language_core_1.replaceSourceRange)(str, undefined, block.startTagEnd, block.endTagStart, '\n\n');
18
+ (0, muggle_string_1.replaceSourceRange)(str, undefined, block.startTagEnd, block.endTagStart, '\n\n');
19
19
  }
20
20
  }
21
21
  const mappings = str
@@ -62,5 +62,4 @@ function computedMappings(snapshot, sfc) {
62
62
  return mappings;
63
63
  });
64
64
  }
65
- exports.computedMappings = computedMappings;
66
65
  //# sourceMappingURL=computedMappings.js.map
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.computedSfc = void 0;
3
+ exports.computedSfc = computedSfc;
4
4
  const computeds_1 = require("computeds");
5
5
  const parseCssClassNames_1 = require("../utils/parseCssClassNames");
6
6
  const parseCssVars_1 = require("../utils/parseCssVars");
@@ -226,7 +226,6 @@ function computedSfc(ts, plugins, fileName, snapshot, parsed) {
226
226
  };
227
227
  }
228
228
  }
229
- exports.computedSfc = computedSfc;
230
229
  function mergeObject(a, b) {
231
230
  return Object.defineProperties(a, Object.getOwnPropertyDescriptors(b));
232
231
  }
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.computedVueSfc = void 0;
3
+ exports.computedVueSfc = computedVueSfc;
4
4
  const computeds_1 = require("computeds");
5
5
  function computedVueSfc(plugins, fileName, snapshot) {
6
6
  let cache;
@@ -37,5 +37,4 @@ function computedVueSfc(plugins, fileName, snapshot) {
37
37
  }
38
38
  });
39
39
  }
40
- exports.computedVueSfc = computedVueSfc;
41
40
  //# sourceMappingURL=computedVueSfc.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vue/language-core",
3
- "version": "2.0.21",
3
+ "version": "2.0.22",
4
4
  "license": "MIT",
5
5
  "files": [
6
6
  "**/*.js",
@@ -12,11 +12,12 @@
12
12
  "directory": "packages/language-core"
13
13
  },
14
14
  "dependencies": {
15
- "@volar/language-core": "~2.3.0-alpha.15",
15
+ "@volar/language-core": "~2.3.1",
16
16
  "@vue/compiler-dom": "^3.4.0",
17
17
  "@vue/shared": "^3.4.0",
18
18
  "computeds": "^0.0.1",
19
19
  "minimatch": "^9.0.3",
20
+ "muggle-string": "^0.4.1",
20
21
  "path-browserify": "^1.0.1",
21
22
  "vue-template-compiler": "^2.7.14"
22
23
  },
@@ -34,5 +35,5 @@
34
35
  "optional": true
35
36
  }
36
37
  },
37
- "gitHead": "a5af80e3939a39694abd9dd09a5496bc5fbf6e06"
38
+ "gitHead": "884c8a553d4fd240167fcb97c6a738564f9d697a"
38
39
  }