@react-native-ohos/react-native-svg 15.12.1-rc.1 → 15.12.1-rc.11

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 (79) hide show
  1. package/LICENSE +21 -21
  2. package/README.OpenSource +10 -10
  3. package/README.md +13 -13
  4. package/css/package.json +5 -5
  5. package/harmony/svg/BuildProfile.ets +16 -16
  6. package/harmony/svg/build-profile.json5 +9 -9
  7. package/harmony/svg/hvigorfile.ts +1 -1
  8. package/harmony/svg/index.ets +6 -6
  9. package/harmony/svg/oh-package.json5 +13 -13
  10. package/harmony/svg/src/main/cpp/CMakeLists.txt +6 -1
  11. package/harmony/svg/src/main/cpp/SVGPackage.h +14 -0
  12. package/harmony/svg/src/main/cpp/SvgArkUINode.cpp +3 -0
  13. package/harmony/svg/src/main/cpp/SvgArkUINode.h +15 -9
  14. package/harmony/svg/src/main/cpp/SvgFilter.cpp +505 -505
  15. package/harmony/svg/src/main/cpp/SvgFilter.h +112 -112
  16. package/harmony/svg/src/main/cpp/SvgForeignObjectNode.cpp +86 -0
  17. package/harmony/svg/src/main/cpp/SvgForeignObjectNode.h +81 -0
  18. package/harmony/svg/src/main/cpp/SvgForeignObjectNodeDelegate.h +30 -0
  19. package/harmony/svg/src/main/cpp/SvgForeignProps.h +39 -0
  20. package/harmony/svg/src/main/cpp/SvgGradient.cpp +1 -0
  21. package/harmony/svg/src/main/cpp/SvgGroup.cpp +8 -1
  22. package/harmony/svg/src/main/cpp/SvgNode.cpp +109 -3
  23. package/harmony/svg/src/main/cpp/SvgNode.h +43 -13
  24. package/harmony/svg/src/main/cpp/SvgViewManager.cpp +3 -0
  25. package/harmony/svg/src/main/cpp/SvgViewManager.h +2 -0
  26. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeBlendComponentInstance.cpp +40 -40
  27. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeBlendComponentInstance.h +48 -48
  28. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeColorMatrixComponentInstance.cpp +33 -33
  29. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeColorMatrixComponentInstance.h +48 -48
  30. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeCompositeComponentInstance.cpp +39 -39
  31. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeCompositeComponentInstance.h +55 -55
  32. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeFloodComponentInstance.cpp +33 -33
  33. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeFloodComponentInstance.h +49 -49
  34. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeGaussianBlurComponentInstance.cpp +34 -34
  35. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeGaussianBlurComponentInstance.h +48 -48
  36. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeOffsetComponentInstance.cpp +35 -35
  37. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFeOffsetComponentInstance.h +45 -45
  38. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFilterComponentInstance.cpp +198 -198
  39. package/harmony/svg/src/main/cpp/componentInstances/RNSVGFilterComponentInstance.h +48 -48
  40. package/harmony/svg/src/main/cpp/componentInstances/RNSVGForeignObjectComponentInstance.cpp +93 -0
  41. package/harmony/svg/src/main/cpp/componentInstances/RNSVGForeignObjectComponentInstance.h +55 -0
  42. package/harmony/svg/src/main/cpp/componentInstances/RNSVGGroupComponentInstance.h +8 -4
  43. package/harmony/svg/src/main/cpp/componentInstances/RNSVGImageComponentInstance.cpp +4 -1
  44. package/harmony/svg/src/main/cpp/componentInstances/RNSVGSvgViewComponentInstance.cpp +38 -0
  45. package/harmony/svg/src/main/cpp/componentInstances/RNSVGSvgViewComponentInstance.h +11 -2
  46. package/harmony/svg/src/main/cpp/downloadUtils/HttpTaskProcessor.cpp +69 -10
  47. package/harmony/svg/src/main/cpp/downloadUtils/ImageSourceResolver.cpp +54 -26
  48. package/harmony/svg/src/main/cpp/downloadUtils/ImageSourceResolver.h +6 -10
  49. package/harmony/svg/src/main/cpp/generated/RNOH/generated/components/RNSVGFeBlendJSIBinder.h +26 -26
  50. package/harmony/svg/src/main/cpp/generated/RNOH/generated/components/RNSVGFeColorMatrixJSIBinder.h +26 -26
  51. package/harmony/svg/src/main/cpp/generated/RNOH/generated/components/RNSVGFeCompositeJSIBinder.h +30 -30
  52. package/harmony/svg/src/main/cpp/generated/RNOH/generated/components/RNSVGFeFloodJSIBinder.h +26 -26
  53. package/harmony/svg/src/main/cpp/generated/RNOH/generated/components/RNSVGFeGaussianBlurJSIBinder.h +26 -26
  54. package/harmony/svg/src/main/cpp/generated/RNOH/generated/components/RNSVGFeOffsetJSIBinder.h +26 -26
  55. package/harmony/svg/src/main/cpp/generated/RNOH/generated/components/RNSVGFilterJSIBinder.h +44 -44
  56. package/harmony/svg/src/main/cpp/generated/react/renderer/components/react_native_svg/Props.cpp +977 -977
  57. package/harmony/svg/src/main/cpp/generated/react/renderer/components/react_native_svg/Props.h +1280 -1280
  58. package/harmony/svg/src/main/cpp/properties/Dimension.h +14 -0
  59. package/harmony/svg/src/main/cpp/turboModules/RNSVGImageModule.cpp +30 -1
  60. package/harmony/svg/src/main/cpp/utils/DynamicUtils.h +55 -55
  61. package/harmony/svg/src/main/cpp/utils/FilterManager.h +190 -190
  62. package/harmony/svg/src/main/ets/RNSVGImageModule.ts +21 -21
  63. package/harmony/svg/src/main/ets/RNSVGRenderableModule.ts +16 -16
  64. package/harmony/svg/src/main/ets/RNSVGSvgViewModule.ts +18 -18
  65. package/harmony/svg/src/main/ets/SvgPackage.ts +57 -57
  66. package/harmony/svg/src/main/module.json5 +7 -7
  67. package/harmony/svg/src/main/resources/base/element/string.json +8 -8
  68. package/harmony/svg/src/main/resources/en_US/element/string.json +8 -8
  69. package/harmony/svg/src/main/resources/zh_CN/element/string.json +8 -8
  70. package/harmony/svg/ts.ts +7 -7
  71. package/harmony/svg.har +0 -0
  72. package/lib/commonjs/css/index.js.map +1 -1
  73. package/lib/commonjs/index.js.map +1 -1
  74. package/lib/module/css/index.js.map +1 -1
  75. package/lib/module/index.js.map +1 -1
  76. package/package.json +53 -54
  77. package/src/css/index.tsx +19 -19
  78. package/src/index.tsx +2 -2
  79. package/tsconfig.json +11 -11
@@ -1,58 +1,58 @@
1
- /*
2
- * Copyright (c) 2024 Huawei Device Co., Ltd. All rights reserved
3
- * Use of this source code is governed by a MIT license that can be
4
- * found in the LICENSE file.
5
- */
6
-
7
- import { RNPackage, TurboModulesFactory } from '@rnoh/react-native-openharmony/ts';
8
- import type { TurboModule, TurboModuleContext } from '@rnoh/react-native-openharmony/ts';
9
- import { RNSVGSvgViewModule } from './RNSVGSvgViewModule';
10
- import { RNSVGRenderableModule } from './RNSVGRenderableModule';
11
- import { RNSVGImageModule } from './RNSVGImageModule';
12
- import { hilog } from '@kit.PerformanceAnalysisKit';
13
-
14
- class MyLog {
15
- static e(logTag: string, content: string) {
16
- const maxSize = 1024;
17
- if (content.length <= maxSize) {
18
- // 长度小于等于限制直接打印
19
- hilog.error(0xFF00, logTag, '%{public}s', content);
20
- } else {
21
- while (content.length > maxSize) {
22
- // 循环分段打印
23
- let logContent = content.substring(0, maxSize);
24
- content = content.replace(logContent, '');
25
- hilog.error(0xFF00, logTag, '%{public}s', logContent); // 打印剩余日志
26
- }
27
- }
28
- }
29
- }
30
-
31
- class SvgTurboModulesFactory extends TurboModulesFactory {
32
-
33
- createTurboModule(name: string): TurboModule | null {
34
- console.log('[kuang] SvgPackage createTurboModule = ', name)
35
-
36
- if (name === 'RNSVGSvgViewModule') {
37
- return new RNSVGSvgViewModule(this.ctx);
38
- }
39
- if (name === 'RNSVGRenderableModule') {
40
- return new RNSVGRenderableModule(this.ctx);
41
- }
42
- if (name === 'RNSVGImageModule') {
43
- return new RNSVGImageModule(this.ctx);
44
- }
45
- return null;
46
- }
47
-
48
- hasTurboModule(name: string): boolean {
49
- return name === 'RNSVGSvgViewModule' || name === 'RNSVGRenderableModule' || name === 'RNSVGImageModule';
50
- }
51
- }
52
-
53
- export class SvgPackage extends RNPackage {
54
- createTurboModulesFactory(ctx: TurboModuleContext): TurboModulesFactory {
55
- MyLog.e('[kuang] SvgPackage createTurboModulesFactory = ', JSON.stringify(ctx));
56
- return new SvgTurboModulesFactory(ctx);
57
- }
1
+ /*
2
+ * Copyright (c) 2024 Huawei Device Co., Ltd. All rights reserved
3
+ * Use of this source code is governed by a MIT license that can be
4
+ * found in the LICENSE file.
5
+ */
6
+
7
+ import { RNPackage, TurboModulesFactory } from '@rnoh/react-native-openharmony/ts';
8
+ import type { TurboModule, TurboModuleContext } from '@rnoh/react-native-openharmony/ts';
9
+ import { RNSVGSvgViewModule } from './RNSVGSvgViewModule';
10
+ import { RNSVGRenderableModule } from './RNSVGRenderableModule';
11
+ import { RNSVGImageModule } from './RNSVGImageModule';
12
+ import { hilog } from '@kit.PerformanceAnalysisKit';
13
+
14
+ class MyLog {
15
+ static e(logTag: string, content: string) {
16
+ const maxSize = 1024;
17
+ if (content.length <= maxSize) {
18
+ // 长度小于等于限制直接打印
19
+ hilog.error(0xFF00, logTag, '%{public}s', content);
20
+ } else {
21
+ while (content.length > maxSize) {
22
+ // 循环分段打印
23
+ let logContent = content.substring(0, maxSize);
24
+ content = content.replace(logContent, '');
25
+ hilog.error(0xFF00, logTag, '%{public}s', logContent); // 打印剩余日志
26
+ }
27
+ }
28
+ }
29
+ }
30
+
31
+ class SvgTurboModulesFactory extends TurboModulesFactory {
32
+
33
+ createTurboModule(name: string): TurboModule | null {
34
+ console.log('[kuang] SvgPackage createTurboModule = ', name)
35
+
36
+ if (name === 'RNSVGSvgViewModule') {
37
+ return new RNSVGSvgViewModule(this.ctx);
38
+ }
39
+ if (name === 'RNSVGRenderableModule') {
40
+ return new RNSVGRenderableModule(this.ctx);
41
+ }
42
+ if (name === 'RNSVGImageModule') {
43
+ return new RNSVGImageModule(this.ctx);
44
+ }
45
+ return null;
46
+ }
47
+
48
+ hasTurboModule(name: string): boolean {
49
+ return name === 'RNSVGSvgViewModule' || name === 'RNSVGRenderableModule' || name === 'RNSVGImageModule';
50
+ }
51
+ }
52
+
53
+ export class SvgPackage extends RNPackage {
54
+ createTurboModulesFactory(ctx: TurboModuleContext): TurboModulesFactory {
55
+ MyLog.e('[kuang] SvgPackage createTurboModulesFactory = ', JSON.stringify(ctx));
56
+ return new SvgTurboModulesFactory(ctx);
57
+ }
58
58
  }
@@ -1,7 +1,7 @@
1
- {
2
- module: {
3
- name: 'svg',
4
- type: 'har',
5
- deviceTypes: ['default'],
6
- },
7
- }
1
+ {
2
+ module: {
3
+ name: 'svg',
4
+ type: 'har',
5
+ deviceTypes: ['default'],
6
+ },
7
+ }
@@ -1,8 +1,8 @@
1
- {
2
- "string": [
3
- {
4
- "name": "page_show",
5
- "value": "page from npm package"
6
- }
7
- ]
8
- }
1
+ {
2
+ "string": [
3
+ {
4
+ "name": "page_show",
5
+ "value": "page from npm package"
6
+ }
7
+ ]
8
+ }
@@ -1,8 +1,8 @@
1
- {
2
- "string": [
3
- {
4
- "name": "page_show",
5
- "value": "page from npm package"
6
- }
7
- ]
8
- }
1
+ {
2
+ "string": [
3
+ {
4
+ "name": "page_show",
5
+ "value": "page from npm package"
6
+ }
7
+ ]
8
+ }
@@ -1,8 +1,8 @@
1
- {
2
- "string": [
3
- {
4
- "name": "page_show",
5
- "value": "page from npm package"
6
- }
7
- ]
8
- }
1
+ {
2
+ "string": [
3
+ {
4
+ "name": "page_show",
5
+ "value": "page from npm package"
6
+ }
7
+ ]
8
+ }
package/harmony/svg/ts.ts CHANGED
@@ -1,8 +1,8 @@
1
- /*
2
- * Copyright (c) 2024 Huawei Device Co., Ltd. All rights reserved
3
- * Use of this source code is governed by a MIT license that can be
4
- * found in the LICENSE file.
5
- */
6
-
7
- export * from './src/main/ets/SvgPackage'
1
+ /*
2
+ * Copyright (c) 2024 Huawei Device Co., Ltd. All rights reserved
3
+ * Use of this source code is governed by a MIT license that can be
4
+ * found in the LICENSE file.
5
+ */
6
+
7
+ export * from './src/main/ets/SvgPackage'
8
8
  export * from './src/main/ets/RNSVGSvgViewModule'
package/harmony/svg.har CHANGED
Binary file
@@ -1 +1 @@
1
- {"version":3,"names":["_css","require"],"sourceRoot":"../../../src","sources":["css/index.tsx"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,IAAA,GAAAC,OAAA","ignoreList":[]}
1
+ {"version":3,"names":["_css","require"],"sourceRoot":"..\\..\\..\\src","sources":["css/index.tsx"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,IAAA,GAAAC,OAAA","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["_ReactNativeSVG","_interopRequireWildcard","require","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","set","getOwnPropertyDescriptor"],"sourceRoot":"../../src","sources":["index.tsx"],"mappings":";;;;;;;;;;;;AAAA,IAAAA,eAAA,GAAAC,uBAAA,CAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAJ,eAAA,EAAAK,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAN,eAAA,CAAAM,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAd,eAAA,CAAAM,GAAA;IAAA;EAAA;AAAA;AAAoD,SAAAL,wBAAAc,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAhB,uBAAA,YAAAA,CAAAc,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAP,GAAA,CAAAC,CAAA,GAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAR,cAAA,CAAAC,IAAA,CAAAM,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAlB,MAAA,CAAAS,cAAA,KAAAT,MAAA,CAAAyB,wBAAA,CAAAb,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAR,GAAA,IAAAQ,CAAA,CAAAK,GAAA,IAAAN,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,CAAA,KAAAR,CAAA,EAAAC,CAAA","ignoreList":[]}
1
+ {"version":3,"names":["_ReactNativeSVG","_interopRequireWildcard","require","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","set","getOwnPropertyDescriptor"],"sourceRoot":"..\\..\\src","sources":["index.tsx"],"mappings":";;;;;;;;;;;;AAAA,IAAAA,eAAA,GAAAC,uBAAA,CAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAJ,eAAA,EAAAK,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAN,eAAA,CAAAM,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAd,eAAA,CAAAM,GAAA;IAAA;EAAA;AAAA;AAAoD,SAAAL,wBAAAc,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAhB,uBAAA,YAAAA,CAAAc,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAP,GAAA,CAAAC,CAAA,GAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAR,cAAA,CAAAC,IAAA,CAAAM,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAlB,MAAA,CAAAS,cAAA,KAAAT,MAAA,CAAAyB,wBAAA,CAAAb,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAR,GAAA,IAAAQ,CAAA,CAAAK,GAAA,IAAAN,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,CAAA,KAAAR,CAAA,EAAAC,CAAA","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["SvgCss","SvgCssUri","SvgWithCss","SvgWithCssUri","inlineStyles","LocalSvg","WithLocalSvg","loadLocalRawResource"],"sourceRoot":"../../../src","sources":["css/index.tsx"],"mappings":"AAAA,SACIA,MAAM,EACNC,SAAS,EACTC,UAAU,EACVC,aAAa,EACbC,YAAY,QACP,sBAAsB;AAE7B,SAASC,QAAQ,EAAEC,YAAY,EAAEC,oBAAoB,QAAQ,sBAAsB;AAEnF,SACEP,MAAM,EACNC,SAAS,EACTC,UAAU,EACVC,aAAa,EACbC,YAAY,EACZC,QAAQ,EACRC,YAAY,EACZC,oBAAoB","ignoreList":[]}
1
+ {"version":3,"names":["SvgCss","SvgCssUri","SvgWithCss","SvgWithCssUri","inlineStyles","LocalSvg","WithLocalSvg","loadLocalRawResource"],"sourceRoot":"..\\..\\..\\src","sources":["css/index.tsx"],"mappings":"AAAA,SACIA,MAAM,EACNC,SAAS,EACTC,UAAU,EACVC,aAAa,EACbC,YAAY,QACP,sBAAsB;AAE7B,SAASC,QAAQ,EAAEC,YAAY,EAAEC,oBAAoB,QAAQ,sBAAsB;AAEnF,SACEP,MAAM,EACNC,SAAS,EACTC,UAAU,EACVC,aAAa,EACbC,YAAY,EACZC,QAAQ,EACRC,YAAY,EACZC,oBAAoB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["default"],"sourceRoot":"../../src","sources":["index.tsx"],"mappings":"AAAA,cAAc,qCAAqC;AAEnD,SAASA,OAAO,QAAQ,qCAAqC","ignoreList":[]}
1
+ {"version":3,"names":["default"],"sourceRoot":"..\\..\\src","sources":["index.tsx"],"mappings":"AAAA,cAAc,qCAAqC;AAEnD,SAASA,OAAO,QAAQ,qCAAqC","ignoreList":[]}
package/package.json CHANGED
@@ -1,54 +1,53 @@
1
- {
2
- "name": "@react-native-ohos/react-native-svg",
3
- "version": "15.12.1-rc.1",
4
- "description": "",
5
- "react-native": "src/index",
6
- "main": "lib/commonjs/index",
7
- "module": "lib/module/index",
8
- "types": "lib/typescript/index.d.ts",
9
- "scripts": {
10
- "prepack": "bob build",
11
- "prepublishOnly": "npm run prepack && react-native verify-package-harmony --package-path . --skip-checks oh_package_name_is_derived_from_npm_package_name",
12
- "update_version": "node ./scripts/update-version.js",
13
- "deploy": "node ./scripts/deploy.js",
14
- "codegen-lib": "react-native codegen-lib-harmony --no-safety-check --npm-package-name react-native-svg --cpp-output-path ./harmony/svg/src/main/cpp/generated --ets-output-path ./harmony/svg/src/main/ets/generated --cpp-components-spec-paths ./node_modules/react-native-svg/src/fabric"
15
- },
16
- "author": "",
17
- "license": "MIT",
18
- "peerDependencies": {
19
- "react": "*",
20
- "react-native": "*",
21
- "react-native-svg": "15.12.0"
22
- },
23
- "devDependencies": {
24
- "@rnoh/react-native-harmony-cli": "./packages/rnoh-react-native-harmony-cli-0.77.10.tgz",
25
- "@react-native-community/cli": "15.0.1",
26
- "@tsconfig/react-native": "^3.0.0",
27
- "@types/jest": "^29.5.1",
28
- "@types/node": "^24.0.8",
29
- "@types/react": "^19.1.7",
30
- "@types/react-native": "^0.71.6",
31
- "react-native-builder-bob": "^0.20.4",
32
- "typescript": "^5.8.3"
33
- },
34
- "harmony": {
35
- "alias": "react-native-svg",
36
- "redirectInternalImports": true
37
- },
38
- "files": [
39
- "harmony",
40
- "src",
41
- "lib",
42
- "css",
43
- "./*.json"
44
- ],
45
- "react-native-builder-bob": {
46
- "source": "src",
47
- "output": "lib",
48
- "targets": [
49
- "commonjs",
50
- "module",
51
- "typescript"
52
- ]
53
- }
54
- }
1
+ {
2
+ "name": "@react-native-ohos/react-native-svg",
3
+ "version": "15.12.1-rc.11",
4
+ "description": "",
5
+ "react-native": "src/index",
6
+ "main": "lib/commonjs/index",
7
+ "module": "lib/module/index",
8
+ "types": "lib/typescript/index.d.ts",
9
+ "scripts": {
10
+ "prepack": "bob build",
11
+ "prepublishOnly": "npm run prepack && react-native verify-package-harmony --package-path . --skip-checks oh_package_name_is_derived_from_npm_package_name",
12
+ "update_version": "node ./scripts/update-version.js",
13
+ "deploy": "node ./scripts/deploy.js",
14
+ "codegen-lib": "react-native codegen-lib-harmony --no-safety-check --npm-package-name react-native-svg --cpp-output-path ./harmony/svg/src/main/cpp/generated --ets-output-path ./harmony/svg/src/main/ets/generated --cpp-components-spec-paths ./node_modules/react-native-svg/src/fabric"
15
+ },
16
+ "author": "",
17
+ "license": "MIT",
18
+ "peerDependencies": {
19
+ "react": "*",
20
+ "react-native": "*",
21
+ "react-native-svg": "15.12.0"
22
+ },
23
+ "devDependencies": {
24
+ "@react-native-community/cli": "15.0.1",
25
+ "@tsconfig/react-native": "^3.0.0",
26
+ "@types/jest": "^29.5.1",
27
+ "@types/node": "^24.0.8",
28
+ "@types/react": "^19.1.7",
29
+ "@types/react-native": "^0.71.6",
30
+ "react-native-builder-bob": "^0.20.4",
31
+ "typescript": "^5.8.3"
32
+ },
33
+ "harmony": {
34
+ "alias": "react-native-svg",
35
+ "redirectInternalImports": true
36
+ },
37
+ "files": [
38
+ "harmony",
39
+ "src",
40
+ "lib",
41
+ "css",
42
+ "./*.json"
43
+ ],
44
+ "react-native-builder-bob": {
45
+ "source": "src",
46
+ "output": "lib",
47
+ "targets": [
48
+ "commonjs",
49
+ "module",
50
+ "typescript"
51
+ ]
52
+ }
53
+ }
package/src/css/index.tsx CHANGED
@@ -1,20 +1,20 @@
1
- import {
2
- SvgCss,
3
- SvgCssUri,
4
- SvgWithCss,
5
- SvgWithCssUri,
6
- inlineStyles,
7
- } from 'react-native-svg/css';
8
-
9
- import { LocalSvg, WithLocalSvg, loadLocalRawResource } from 'react-native-svg/css';
10
-
11
- export {
12
- SvgCss,
13
- SvgCssUri,
14
- SvgWithCss,
15
- SvgWithCssUri,
16
- inlineStyles,
17
- LocalSvg,
18
- WithLocalSvg,
19
- loadLocalRawResource,
1
+ import {
2
+ SvgCss,
3
+ SvgCssUri,
4
+ SvgWithCss,
5
+ SvgWithCssUri,
6
+ inlineStyles,
7
+ } from 'react-native-svg/css';
8
+
9
+ import { LocalSvg, WithLocalSvg, loadLocalRawResource } from 'react-native-svg/css';
10
+
11
+ export {
12
+ SvgCss,
13
+ SvgCssUri,
14
+ SvgWithCss,
15
+ SvgWithCssUri,
16
+ inlineStyles,
17
+ LocalSvg,
18
+ WithLocalSvg,
19
+ loadLocalRawResource,
20
20
  };
package/src/index.tsx CHANGED
@@ -1,3 +1,3 @@
1
- export * from 'react-native-svg/src/ReactNativeSVG';
2
-
1
+ export * from 'react-native-svg/src/ReactNativeSVG';
2
+
3
3
  export { default } from 'react-native-svg/src/ReactNativeSVG';
package/tsconfig.json CHANGED
@@ -1,12 +1,12 @@
1
- {
2
- "extends": [
3
- "@tsconfig/react-native/tsconfig.json",
4
- ],
5
- "compilerOptions": {
6
- "noEmit": false
7
- },
8
- "exclude": [
9
- "lib",
10
- "harmony"
11
- ]
1
+ {
2
+ "extends": [
3
+ "@tsconfig/react-native/tsconfig.json",
4
+ ],
5
+ "compilerOptions": {
6
+ "noEmit": false
7
+ },
8
+ "exclude": [
9
+ "lib",
10
+ "harmony"
11
+ ]
12
12
  }