@startupjs-ui/carousel 0.2.0 → 0.3.0
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 +11 -0
- package/index.d.ts +2 -0
- package/index.tsx +4 -1
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [0.3.0](https://github.com/startupjs/startupjs-ui/compare/v0.2.3...v0.3.0) (2026-05-27)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* [BREAKING] [0.3] improve accessibility props for E2E tests. Support testID everywhere ([#31](https://github.com/startupjs/startupjs-ui/issues/31)) ([882588c](https://github.com/startupjs/startupjs-ui/commit/882588ca37d5e1fd14b5717b5697cf9ed47042e4))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
6
17
|
# [0.2.0](https://github.com/startupjs/startupjs-ui/compare/v0.1.23...v0.2.0) (2026-05-04)
|
|
7
18
|
|
|
8
19
|
|
package/index.d.ts
CHANGED
|
@@ -34,6 +34,8 @@ export interface CarouselProps {
|
|
|
34
34
|
children?: any[];
|
|
35
35
|
/** Callback fired when active slide changes */
|
|
36
36
|
onChange?: (index: number) => void;
|
|
37
|
+
/** Test identifier */
|
|
38
|
+
testID?: string;
|
|
37
39
|
/** Ref exposing active child and navigation helpers */
|
|
38
40
|
ref?: Ref<any>;
|
|
39
41
|
}
|
package/index.tsx
CHANGED
|
@@ -57,6 +57,8 @@ export interface CarouselProps {
|
|
|
57
57
|
children?: any[]
|
|
58
58
|
/** Callback fired when active slide changes */
|
|
59
59
|
onChange?: (index: number) => void
|
|
60
|
+
/** Test identifier */
|
|
61
|
+
testID?: string
|
|
60
62
|
/** Ref exposing active child and navigation helpers */
|
|
61
63
|
ref?: Ref<any>
|
|
62
64
|
}
|
|
@@ -76,6 +78,7 @@ function Carousel ({
|
|
|
76
78
|
duration = 300,
|
|
77
79
|
children = [],
|
|
78
80
|
onChange,
|
|
81
|
+
testID,
|
|
79
82
|
ref
|
|
80
83
|
}: CarouselProps): ReactNode {
|
|
81
84
|
arrowBackStyle = StyleSheet.flatten(arrowBackStyle)
|
|
@@ -503,7 +506,7 @@ function Carousel ({
|
|
|
503
506
|
})
|
|
504
507
|
|
|
505
508
|
return pug`
|
|
506
|
-
Div.wrapper(style=[style, { opacity: isRender ? 1 : 0 }])
|
|
509
|
+
Div.wrapper(style=[style, { opacity: isRender ? 1 : 0 }] testID=testID)
|
|
507
510
|
Div.carousel(styleName=variant)
|
|
508
511
|
if hasArrows
|
|
509
512
|
Div.arrow.arrowBack(
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@startupjs-ui/carousel",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -8,14 +8,14 @@
|
|
|
8
8
|
"types": "index.d.ts",
|
|
9
9
|
"type": "module",
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"@startupjs-ui/core": "^0.
|
|
12
|
-
"@startupjs-ui/div": "^0.
|
|
13
|
-
"@startupjs-ui/icon": "^0.
|
|
11
|
+
"@startupjs-ui/core": "^0.3.0",
|
|
12
|
+
"@startupjs-ui/div": "^0.3.0",
|
|
13
|
+
"@startupjs-ui/icon": "^0.3.0"
|
|
14
14
|
},
|
|
15
15
|
"peerDependencies": {
|
|
16
16
|
"react": "*",
|
|
17
17
|
"react-native": "*",
|
|
18
18
|
"startupjs": "*"
|
|
19
19
|
},
|
|
20
|
-
"gitHead": "
|
|
20
|
+
"gitHead": "8d212b47680af1dfe582f9759b38724b46488e25"
|
|
21
21
|
}
|