@lynx-js/config-rsbuild-plugin 0.2.1 → 0.2.3

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/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  # @lynx-js/config-rsbuild-plugin
2
2
 
3
+ ## 0.2.3
4
+
5
+ ### Patch Changes
6
+
7
+ - Declare the build host as an optional peer dependency. `@rsbuild/core` covers a plain Rsbuild build, and `@lynx-js/rspeedy` covers an Rspeedy one, so whichever host is installed is version-checked. ([#3678](https://github.com/lynx-family/lynx-stack/pull/3678))
8
+
9
+ - **BREAKING CHANGE**: Require `@lynx-js/rspeedy` `^0.17.0` in the plugins that read the build engine config through `Symbol.for('@lynx-js/rsbuild-plugin:config')`, since the engine that ships with `0.16` does not expose it. The plugins that do not touch the engine keep their existing range and add `^0.17.0` to it. ([#3682](https://github.com/lynx-family/lynx-stack/pull/3682))
10
+
11
+ - Updated dependency `@lynx-js/type-config` to `4.2.0`. ([#3771](https://github.com/lynx-family/lynx-stack/pull/3771))
12
+
13
+ ## 0.2.2
14
+
15
+ ### Patch Changes
16
+
17
+ - Use a real exported config key (`alignMouseEventWithW3C`) in the usage ([#3385](https://github.com/lynx-family/lynx-stack/pull/3385))
18
+ examples, and drop the hard-coded link to the development-version config
19
+ reference.
20
+
3
21
  ## 0.2.1
4
22
 
5
23
  ### Patch Changes
package/dist/index.d.ts CHANGED
@@ -11,7 +11,7 @@
11
11
  * export default defineConfig({
12
12
  * plugins: [
13
13
  * pluginLynxConfig({
14
- * enableCheckExposureOptimize: false,
14
+ * alignMouseEventWithW3C: true,
15
15
  * }),
16
16
  * ],
17
17
  * })
@@ -25,8 +25,6 @@ import type { RsbuildPlugin } from '@lynx-js/rspeedy';
25
25
  /**
26
26
  * A configuration interface for Lynx Config defined by `@lynx-js/type-config`.
27
27
  *
28
- * See all available options in {@link https://lynxjs.org/next/api/lynx-config/config-reference.html}.
29
- *
30
28
  * @public
31
29
  */
32
30
  export declare interface Config extends Config_2, CompilerOptions {
@@ -83,7 +81,7 @@ export declare interface Options {
83
81
  * export default defineConfig({
84
82
  * plugins: [
85
83
  * pluginLynxConfig({
86
- * enableCheckExposureOptimize: false,
84
+ * alignMouseEventWithW3C: true,
87
85
  * }),
88
86
  * ],
89
87
  * })
package/dist/index.js CHANGED
@@ -535,7 +535,7 @@ const typiaPathToStandardSchemaPath = (path)=>{
535
535
  const picocolors = __webpack_require__("../../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js");
536
536
  var picocolors_default = /*#__PURE__*/ __webpack_require__.n(picocolors);
537
537
  const validateConfig = (()=>{
538
- const _io0 = (input, _exceptionable = true)=>(void 0 === input.alignMouseEventWithW3C || "boolean" == typeof input.alignMouseEventWithW3C) && (void 0 === input.disableLongpressAfterScroll || "boolean" == typeof input.disableLongpressAfterScroll) && (void 0 === input.enableA11y || "boolean" == typeof input.enableA11y) && (void 0 === input.enableAccessibilityElement || "boolean" == typeof input.enableAccessibilityElement) && (void 0 === input.enableCSSInheritance || "boolean" == typeof input.enableCSSInheritance) && (void 0 === input.enableCSSInlineVariables || "boolean" == typeof input.enableCSSInlineVariables) && (void 0 === input.enableCSSRule || "boolean" == typeof input.enableCSSRule) && (void 0 === input.enableEndGestureAtLastFingerUp || "boolean" == typeof input.enableEndGestureAtLastFingerUp) && (void 0 === input.enableEventHandleRefactor || "boolean" == typeof input.enableEventHandleRefactor) && (void 0 === input.enableEventThrough || "boolean" == typeof input.enableEventThrough) && (void 0 === input.enableFetchAPIStandardStreaming || "boolean" == typeof input.enableFetchAPIStandardStreaming) && (void 0 === input.enableFixedNew || "boolean" == typeof input.enableFixedNew) && (void 0 === input.enableFlexBasisZeroPercent || "boolean" == typeof input.enableFlexBasisZeroPercent) && (void 0 === input.enableGridPlacementShorthands || "boolean" == typeof input.enableGridPlacementShorthands) && (void 0 === input.enableJsBindingApiThrowException || "boolean" == typeof input.enableJsBindingApiThrowException) && (void 0 === input.enableListNewArchitecture || "boolean" == typeof input.enableListNewArchitecture) && (void 0 === input.enableMultiTouch || "boolean" == typeof input.enableMultiTouch) && (void 0 === input.enableNativeList || "boolean" == typeof input.enableNativeList) && (void 0 === input.enableNewGesture || "boolean" == typeof input.enableNewGesture) && (void 0 === input.enableNewIntersectionObserver || "boolean" == typeof input.enableNewIntersectionObserver) && (void 0 === input.enableNewTransformOrigin || "boolean" == typeof input.enableNewTransformOrigin) && (void 0 === input.enableParseIntFlex || "boolean" == typeof input.enableParseIntFlex) && (void 0 === input.enableReloadLifecycle || "boolean" == typeof input.enableReloadLifecycle) && (void 0 === input.enableSimultaneousTap || "boolean" == typeof input.enableSimultaneousTap) && (void 0 === input.enableTextOverflow || "boolean" == typeof input.enableTextOverflow) && (void 0 === input.enableTransformedTouchPosition || "boolean" == typeof input.enableTransformedTouchPosition) && (void 0 === input.fontScaleEffectiveOnlyOnSp || "boolean" == typeof input.fontScaleEffectiveOnlyOnSp) && (void 0 === input.includeFontPadding || "boolean" == typeof input.includeFontPadding) && (void 0 === input.keyboardCallbackPassRelativeHeight || "boolean" == typeof input.keyboardCallbackPassRelativeHeight) && (void 0 === input.longPressDuration || "number" == typeof input.longPressDuration) && (void 0 === input.removeDescendantSelectorScope || "boolean" == typeof input.removeDescendantSelectorScope) && (void 0 === input.tapSlop || "string" == typeof input.tapSlop) && (void 0 === input.unifyVWVHBehavior || "boolean" == typeof input.unifyVWVHBehavior) && (0 === Object.keys(input).length || Object.keys(input).every((key)=>{
538
+ const _io0 = (input, _exceptionable = true)=>(void 0 === input.alignMouseEventWithW3C || "boolean" == typeof input.alignMouseEventWithW3C) && (void 0 === input.disableLongpressAfterScroll || "boolean" == typeof input.disableLongpressAfterScroll) && (void 0 === input.enableA11y || "boolean" == typeof input.enableA11y) && (void 0 === input.enableAccessibilityElement || "boolean" == typeof input.enableAccessibilityElement) && (void 0 === input.enableCSSInheritance || "boolean" == typeof input.enableCSSInheritance) && (void 0 === input.enableCSSInlineVariables || "boolean" == typeof input.enableCSSInlineVariables) && (void 0 === input.enableCSSRule || "boolean" == typeof input.enableCSSRule) && (void 0 === input.enableEndGestureAtLastFingerUp || "boolean" == typeof input.enableEndGestureAtLastFingerUp) && (void 0 === input.enableEventHandleRefactor || "boolean" == typeof input.enableEventHandleRefactor) && (void 0 === input.enableEventThrough || "boolean" == typeof input.enableEventThrough) && (void 0 === input.enableEventThroughInheritFromPage || "boolean" == typeof input.enableEventThroughInheritFromPage) && (void 0 === input.enableFetchAPIStandardStreaming || "boolean" == typeof input.enableFetchAPIStandardStreaming) && (void 0 === input.enableFixedNew || "boolean" == typeof input.enableFixedNew) && (void 0 === input.enableFlexBasisZeroPercent || "boolean" == typeof input.enableFlexBasisZeroPercent) && (void 0 === input.enableGridPlacementShorthands || "boolean" == typeof input.enableGridPlacementShorthands) && (void 0 === input.enableJsBindingApiThrowException || "boolean" == typeof input.enableJsBindingApiThrowException) && (void 0 === input.enableLayoutOnlyEventThrough || "boolean" == typeof input.enableLayoutOnlyEventThrough) && (void 0 === input.enableListNewArchitecture || "boolean" == typeof input.enableListNewArchitecture) && (void 0 === input.enableMouseDragScroll || "boolean" == typeof input.enableMouseDragScroll) && (void 0 === input.enableMultiTouch || "boolean" == typeof input.enableMultiTouch) && (void 0 === input.enableNativeList || "boolean" == typeof input.enableNativeList) && (void 0 === input.enableNewGesture || "boolean" == typeof input.enableNewGesture) && (void 0 === input.enableNewIntersectionObserver || "boolean" == typeof input.enableNewIntersectionObserver) && (void 0 === input.enableNewTransformOrigin || "boolean" == typeof input.enableNewTransformOrigin) && (void 0 === input.enableParseIntFlex || "boolean" == typeof input.enableParseIntFlex) && (void 0 === input.enableReloadLifecycle || "boolean" == typeof input.enableReloadLifecycle) && (void 0 === input.enableSimultaneousTap || "boolean" == typeof input.enableSimultaneousTap) && (void 0 === input.enableTextOverflow || "boolean" == typeof input.enableTextOverflow) && (void 0 === input.enableTransformedTouchPosition || "boolean" == typeof input.enableTransformedTouchPosition) && (void 0 === input.fontScaleEffectiveOnlyOnSp || "boolean" == typeof input.fontScaleEffectiveOnlyOnSp) && (void 0 === input.includeFontPadding || "boolean" == typeof input.includeFontPadding) && (void 0 === input.keyboardCallbackPassRelativeHeight || "boolean" == typeof input.keyboardCallbackPassRelativeHeight) && (void 0 === input.longPressDuration || "number" == typeof input.longPressDuration) && (void 0 === input.removeDescendantSelectorScope || "boolean" == typeof input.removeDescendantSelectorScope) && (void 0 === input.tapSlop || "string" == typeof input.tapSlop) && (void 0 === input.unifyVWVHBehavior || "boolean" == typeof input.unifyVWVHBehavior) && (0 === Object.keys(input).length || Object.keys(input).every((key)=>{
539
539
  if ([
540
540
  "alignMouseEventWithW3C",
541
541
  "disableLongpressAfterScroll",
@@ -547,12 +547,15 @@ const validateConfig = (()=>{
547
547
  "enableEndGestureAtLastFingerUp",
548
548
  "enableEventHandleRefactor",
549
549
  "enableEventThrough",
550
+ "enableEventThroughInheritFromPage",
550
551
  "enableFetchAPIStandardStreaming",
551
552
  "enableFixedNew",
552
553
  "enableFlexBasisZeroPercent",
553
554
  "enableGridPlacementShorthands",
554
555
  "enableJsBindingApiThrowException",
556
+ "enableLayoutOnlyEventThrough",
555
557
  "enableListNewArchitecture",
558
+ "enableMouseDragScroll",
556
559
  "enableMultiTouch",
557
560
  "enableNativeList",
558
561
  "enableNewGesture",
@@ -626,6 +629,11 @@ const validateConfig = (()=>{
626
629
  expected: "(boolean | undefined)",
627
630
  value: input.enableEventThrough
628
631
  }),
632
+ void 0 === input.enableEventThroughInheritFromPage || "boolean" == typeof input.enableEventThroughInheritFromPage || _report(_exceptionable, {
633
+ path: _path + ".enableEventThroughInheritFromPage",
634
+ expected: "(boolean | undefined)",
635
+ value: input.enableEventThroughInheritFromPage
636
+ }),
629
637
  void 0 === input.enableFetchAPIStandardStreaming || "boolean" == typeof input.enableFetchAPIStandardStreaming || _report(_exceptionable, {
630
638
  path: _path + ".enableFetchAPIStandardStreaming",
631
639
  expected: "(boolean | undefined)",
@@ -651,11 +659,21 @@ const validateConfig = (()=>{
651
659
  expected: "(boolean | undefined)",
652
660
  value: input.enableJsBindingApiThrowException
653
661
  }),
662
+ void 0 === input.enableLayoutOnlyEventThrough || "boolean" == typeof input.enableLayoutOnlyEventThrough || _report(_exceptionable, {
663
+ path: _path + ".enableLayoutOnlyEventThrough",
664
+ expected: "(boolean | undefined)",
665
+ value: input.enableLayoutOnlyEventThrough
666
+ }),
654
667
  void 0 === input.enableListNewArchitecture || "boolean" == typeof input.enableListNewArchitecture || _report(_exceptionable, {
655
668
  path: _path + ".enableListNewArchitecture",
656
669
  expected: "(boolean | undefined)",
657
670
  value: input.enableListNewArchitecture
658
671
  }),
672
+ void 0 === input.enableMouseDragScroll || "boolean" == typeof input.enableMouseDragScroll || _report(_exceptionable, {
673
+ path: _path + ".enableMouseDragScroll",
674
+ expected: "(boolean | undefined)",
675
+ value: input.enableMouseDragScroll
676
+ }),
659
677
  void 0 === input.enableMultiTouch || "boolean" == typeof input.enableMultiTouch || _report(_exceptionable, {
660
678
  path: _path + ".enableMultiTouch",
661
679
  expected: "(boolean | undefined)",
@@ -753,12 +771,15 @@ const validateConfig = (()=>{
753
771
  "enableEndGestureAtLastFingerUp",
754
772
  "enableEventHandleRefactor",
755
773
  "enableEventThrough",
774
+ "enableEventThroughInheritFromPage",
756
775
  "enableFetchAPIStandardStreaming",
757
776
  "enableFixedNew",
758
777
  "enableFlexBasisZeroPercent",
759
778
  "enableGridPlacementShorthands",
760
779
  "enableJsBindingApiThrowException",
780
+ "enableLayoutOnlyEventThrough",
761
781
  "enableListNewArchitecture",
782
+ "enableMouseDragScroll",
762
783
  "enableMultiTouch",
763
784
  "enableNativeList",
764
785
  "enableNewGesture",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lynx-js/config-rsbuild-plugin",
3
- "version": "0.2.1",
3
+ "version": "0.2.3",
4
4
  "description": "An rsbuild plugin for config Lynx Config defined by @lynx-js/type-config.",
5
5
  "keywords": [
6
6
  "rsbuild",
@@ -32,33 +32,43 @@
32
32
  "README.md"
33
33
  ],
34
34
  "dependencies": {
35
- "@lynx-js/type-config": "4.1.3"
35
+ "@lynx-js/type-config": "4.2.0"
36
36
  },
37
37
  "devDependencies": {
38
- "@rsbuild/core": "2.1.7",
39
- "@rspack/core": "2.1.5",
40
- "@rstest/core": "0.11.3",
38
+ "@microsoft/api-extractor": "7.58.12",
39
+ "@rsbuild/core": "2.2.3",
40
+ "@rspack/core": "2.2.2",
41
+ "@rstest/core": "0.11.12",
41
42
  "@types/object.pick": "^1.3.4",
42
- "expect-type": "^1.2.1",
43
+ "expect-type": "^1.4.0",
43
44
  "object.pick": "^1.3.0",
44
45
  "picocolors": "^1.1.1",
45
46
  "terminal-link": "^5.0.0",
46
47
  "typia": "12.1.1",
47
48
  "typia-rspack-plugin": "3.0.1",
48
- "@lynx-js/rspeedy": "0.16.2",
49
- "@lynx-js/template-webpack-plugin": "0.14.1",
49
+ "@lynx-js/rspeedy": "0.17.0",
50
+ "@lynx-js/template-webpack-plugin": "0.16.0",
50
51
  "@lynx-js/test-tools": "0.0.0"
51
52
  },
52
53
  "peerDependencies": {
53
- "@lynx-js/rspeedy": "^0.7.0 || ^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^0.14.0 || ^0.15.0 || ^0.16.0"
54
+ "@lynx-js/rspeedy": "^0.7.0 || ^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^0.14.0 || ^0.15.0 || ^0.16.0 || ^0.17.0",
55
+ "@rsbuild/core": "^2.0.0"
56
+ },
57
+ "peerDependenciesMeta": {
58
+ "@lynx-js/rspeedy": {
59
+ "optional": true
60
+ },
61
+ "@rsbuild/core": {
62
+ "optional": true
63
+ }
54
64
  },
55
65
  "engines": {
56
66
  "node": ">=18"
57
67
  },
58
68
  "scripts": {
59
- "api-extractor": "api-extractor run --verbose",
69
+ "api-extractor": "node scripts/api-extractor.mjs",
60
70
  "build": "rslib build",
61
71
  "test": "rstest",
62
- "test:type": "tsc --noEmit"
72
+ "test:type": "tsc6 --noEmit"
63
73
  }
64
74
  }