@cuemath/leap 3.4.4-aa0 → 3.4.4-akm-2
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/dist/assets/illustrations/illustrations.js +7 -0
- package/dist/assets/illustrations/illustrations.js.map +1 -1
- package/dist/features/av/av-preview/helper.js +40 -0
- package/dist/features/av/av-preview/helper.js.map +1 -0
- package/dist/features/av/av-preview/hooks/use-media-devices.js +129 -50
- package/dist/features/av/av-preview/hooks/use-media-devices.js.map +1 -1
- package/dist/features/circle-games/game-launcher/comps/segmented-game-card/constants.js +2 -9
- package/dist/features/circle-games/game-launcher/comps/segmented-game-card/constants.js.map +1 -1
- package/dist/features/circle-games/game-launcher/game-launcher-analytics-events.js +6 -8
- package/dist/features/circle-games/game-launcher/game-launcher-analytics-events.js.map +1 -1
- package/dist/features/circle-games/{game-launcher → game-launcher-v2}/api/get-content-for-today/constants.js +1 -1
- package/dist/features/circle-games/game-launcher-v2/api/get-content-for-today/constants.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/api/get-content-for-today/get-circle-home-api.js +10 -0
- package/dist/features/circle-games/game-launcher-v2/api/get-content-for-today/get-circle-home-api.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/card-container/card-container-styled.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/card-container/card-container.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/card-container/constants.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel/carousel-styled.js +120 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel/carousel-styled.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel/carousel.js +57 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel/carousel.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-badge-style.js +20 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-badge-style.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-badge.js +17 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-badge.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-single-badge.js +20 -0
- package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-single-badge.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/circular-game-card/circular-game-card-styled.js +48 -0
- package/dist/features/circle-games/game-launcher-v2/comps/circular-game-card/circular-game-card-styled.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/circular-game-card/circular-game-card.js +66 -0
- package/dist/features/circle-games/game-launcher-v2/comps/circular-game-card/circular-game-card.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/circular-game-card/constants.js +7 -0
- package/dist/features/circle-games/game-launcher-v2/comps/circular-game-card/constants.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/game-card-content/constants.js +6 -0
- package/dist/features/circle-games/game-launcher-v2/comps/game-card-content/constants.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/game-card-content/game-card-content-styled.js +62 -0
- package/dist/features/circle-games/game-launcher-v2/comps/game-card-content/game-card-content-styled.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/game-card-content/game-card-content.js +13 -0
- package/dist/features/circle-games/game-launcher-v2/comps/game-card-content/game-card-content.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/constants.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/infinite-button/infinite-mode-launcher-button.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/spl-events-text/constants.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/spl-events-text/spl-events-text-style.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/spl-events-text/spl-events-text-types.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/spl-events-text/spl-events-text.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/table-mode/table-mode-styled.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/table-mode/table-mode.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/table-mode-star/constants.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/table-mode-star/table-mode-star-styled.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/table-mode-star/table-mode-star.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/table-segment-star/table-segment-star-styled.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/table-segment-star/table-segment-star.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/tables-card-styled.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/comps/tables-card/tables-card.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/dal/use-get-circle-home-details-dal/helper.js +94 -0
- package/dist/features/circle-games/game-launcher-v2/dal/use-get-circle-home-details-dal/helper.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/dal/use-get-circle-home-details-dal/use-get-circle-home-details-dal.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/game-launcher-analytics-events.js +7 -0
- package/dist/features/circle-games/game-launcher-v2/game-launcher-analytics-events.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/game-launcher-v2.js +246 -0
- package/dist/features/circle-games/game-launcher-v2/game-launcher-v2.js.map +1 -0
- package/dist/features/circle-games/game-launcher-v2/helpers.js +8 -0
- package/dist/features/circle-games/game-launcher-v2/helpers.js.map +1 -0
- package/dist/features/hooks/use-cancellable-promise.js +22 -0
- package/dist/features/hooks/use-cancellable-promise.js.map +1 -0
- package/dist/features/post-game-stats/accuracy/accuracy-styled.js +2 -2
- package/dist/features/post-game-stats/accuracy/accuracy-styled.js.map +1 -1
- package/dist/features/post-game-stats/clock/clock-styled.js +2 -2
- package/dist/features/post-game-stats/clock/clock-styled.js.map +1 -1
- package/dist/features/post-game-stats/digital-meter/constants.js +1 -1
- package/dist/features/post-game-stats/digital-meter/constants.js.map +1 -1
- package/dist/features/post-game-stats/digital-meter/digital-meter-styled.js +1 -1
- package/dist/features/post-game-stats/digital-meter/digital-meter-styled.js.map +1 -1
- package/dist/features/post-game-stats/digital-meter/digital-meter.js +1 -1
- package/dist/features/post-game-stats/digital-meter/digital-meter.js.map +1 -1
- package/dist/features/post-game-stats/points/points.js +5 -4
- package/dist/features/post-game-stats/points/points.js.map +1 -1
- package/dist/features/post-game-stats/post-game-stats-styled.js +9 -8
- package/dist/features/post-game-stats/post-game-stats-styled.js.map +1 -1
- package/dist/features/post-game-stats/post-game-stats.js +107 -105
- package/dist/features/post-game-stats/post-game-stats.js.map +1 -1
- package/dist/features/post-game-stats/score/score-styled.js +2 -2
- package/dist/features/post-game-stats/score/score-styled.js.map +1 -1
- package/dist/features/post-game-stats/streak/constants.js +1 -1
- package/dist/features/post-game-stats/streak/constants.js.map +1 -1
- package/dist/features/post-game-stats/streak/streak-styled.js +2 -2
- package/dist/features/post-game-stats/streak/streak-styled.js.map +1 -1
- package/dist/index.d.ts +44 -4
- package/dist/index.js +5 -5
- package/dist/static/accuracy-badge.2e161f00.svg +1 -0
- package/dist/static/clock-badge.0adb4ba6.svg +1 -0
- package/dist/static/down-arrow-badge.f462f615.svg +1 -0
- package/dist/static/green-tick.43b94c3a.svg +1 -0
- package/dist/static/points-badge.96bdecc9.svg +1 -0
- package/dist/static/star-badge.5450c267.svg +1 -0
- package/dist/static/up-arrow-badge.71fe7ad1.svg +1 -0
- package/package.json +1 -1
- package/dist/assets/line-icons/icons/carat-left.js +0 -26
- package/dist/assets/line-icons/icons/carat-left.js.map +0 -1
- package/dist/assets/line-icons/icons/carat-right.js +0 -26
- package/dist/assets/line-icons/icons/carat-right.js.map +0 -1
- package/dist/features/circle-games/game-launcher/api/get-content-for-today/constants.js.map +0 -1
- package/dist/features/circle-games/game-launcher/api/get-content-for-today/get-circle-home-api.js +0 -10
- package/dist/features/circle-games/game-launcher/api/get-content-for-today/get-circle-home-api.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/card-container/card-container-styled.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/card-container/card-container.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/card-container/constants.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/carousel/carousel-styled.js +0 -39
- package/dist/features/circle-games/game-launcher/comps/carousel/carousel-styled.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/carousel/carousel.js +0 -85
- package/dist/features/circle-games/game-launcher/comps/carousel/carousel.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/segmented-game-card/segmented-game-card-styled.js +0 -138
- package/dist/features/circle-games/game-launcher/comps/segmented-game-card/segmented-game-card-styled.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/segmented-game-card/segmented-game-card.js +0 -105
- package/dist/features/circle-games/game-launcher/comps/segmented-game-card/segmented-game-card.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/constants.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/infinite-button/infinite-mode-launcher-button.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/spl-events-text/constants.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/spl-events-text/spl-events-text-style.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/spl-events-text/spl-events-text-types.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/spl-events-text/spl-events-text.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/table-mode/table-mode-styled.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/table-mode/table-mode.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/table-mode-star/constants.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/table-mode-star/table-mode-star-styled.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/table-mode-star/table-mode-star.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/table-segment-star/table-segment-star-styled.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/table-segment-star/table-segment-star.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/tables-card-styled.js.map +0 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/tables-card.js.map +0 -1
- package/dist/features/circle-games/game-launcher/dal/use-get-circle-home-details-dal/helper.js +0 -73
- package/dist/features/circle-games/game-launcher/dal/use-get-circle-home-details-dal/helper.js.map +0 -1
- package/dist/features/circle-games/game-launcher/dal/use-get-circle-home-details-dal/use-get-circle-home-details-dal.js.map +0 -1
- package/dist/features/circle-games/game-launcher/game-launcher.js +0 -219
- package/dist/features/circle-games/game-launcher/game-launcher.js.map +0 -1
- package/dist/features/circle-games/game-launcher/hooks/use-game-launcher-journey/constants.js +0 -8
- package/dist/features/circle-games/game-launcher/hooks/use-game-launcher-journey/constants.js.map +0 -1
- package/dist/features/circle-games/game-launcher/hooks/use-game-launcher-journey/use-game-launcher-journey.js +0 -286
- package/dist/features/circle-games/game-launcher/hooks/use-game-launcher-journey/use-game-launcher-journey.js.map +0 -1
- package/dist/features/circle-games/game-launcher/hooks/use-table-infinite-launcher-journey/constants.js +0 -10
- package/dist/features/circle-games/game-launcher/hooks/use-table-infinite-launcher-journey/constants.js.map +0 -1
- package/dist/features/circle-games/game-launcher/hooks/use-table-infinite-launcher-journey/use-table-infinite-launcher-journey-styled.js +0 -13
- package/dist/features/circle-games/game-launcher/hooks/use-table-infinite-launcher-journey/use-table-infinite-launcher-journey-styled.js.map +0 -1
- package/dist/features/circle-games/game-launcher/hooks/use-table-infinite-launcher-journey/use-table-infinite-launcher-journey.js +0 -137
- package/dist/features/circle-games/game-launcher/hooks/use-table-infinite-launcher-journey/use-table-infinite-launcher-journey.js.map +0 -1
- package/dist/features/circle-games/game-launcher/hooks/use-table-launcher-journey/constants.js +0 -14
- package/dist/features/circle-games/game-launcher/hooks/use-table-launcher-journey/constants.js.map +0 -1
- package/dist/features/circle-games/game-launcher/hooks/use-table-launcher-journey/use-table-launcher-journey-styled.js +0 -13
- package/dist/features/circle-games/game-launcher/hooks/use-table-launcher-journey/use-table-launcher-journey-styled.js.map +0 -1
- package/dist/features/circle-games/game-launcher/hooks/use-table-launcher-journey/use-table-launcher-journey.js +0 -230
- package/dist/features/circle-games/game-launcher/hooks/use-table-launcher-journey/use-table-launcher-journey.js.map +0 -1
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/card-container/card-container-styled.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/card-container/card-container.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/card-container/constants.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/constants.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/infinite-button/infinite-mode-launcher-button.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/spl-events-text/constants.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/spl-events-text/spl-events-text-style.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/spl-events-text/spl-events-text-types.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/spl-events-text/spl-events-text.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/table-mode/table-mode-styled.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/table-mode/table-mode.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/table-mode-star/constants.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/table-mode-star/table-mode-star-styled.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/table-mode-star/table-mode-star.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/table-segment-star/table-segment-star-styled.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/table-segment-star/table-segment-star.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/tables-card-styled.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/comps/tables-card/tables-card.js +0 -0
- /package/dist/features/circle-games/{game-launcher → game-launcher-v2}/dal/use-get-circle-home-details-dal/use-get-circle-home-details-dal.js +0 -0
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import t, { css as o } from "styled-components";
|
|
2
|
+
import n from "../../../../ui/layout/flex-view.js";
|
|
3
|
+
import { GAME_LAUNCHER_SIZE as r } from "../card-container/constants.js";
|
|
4
|
+
const l = t.div`
|
|
5
|
+
width: 100%;
|
|
6
|
+
height: 100%;
|
|
7
|
+
position: relative;
|
|
8
|
+
display: flex;
|
|
9
|
+
justify-content: center;
|
|
10
|
+
`, c = t.div`
|
|
11
|
+
display: flex;
|
|
12
|
+
width: 100%;
|
|
13
|
+
flex-grow: 1;
|
|
14
|
+
transform: ${({ $translate: e = 0 }) => `translateX(${-e}%)`};
|
|
15
|
+
transition: ${({ $translateDuration: e }) => `all ${e}ms ease-in`};
|
|
16
|
+
`, d = t.div`
|
|
17
|
+
width: 100%;
|
|
18
|
+
display: flex;
|
|
19
|
+
align-items: center;
|
|
20
|
+
justify-content: center;
|
|
21
|
+
flex-grow: 1;
|
|
22
|
+
flex-shrink: 0;
|
|
23
|
+
`, f = t.div`
|
|
24
|
+
display: flex;
|
|
25
|
+
flex-direction: row;
|
|
26
|
+
align-items: center;
|
|
27
|
+
padding: 2px;
|
|
28
|
+
gap: 4px;
|
|
29
|
+
background: ${({ theme: e }) => e.colors.BLACK_5 || "#313131"};
|
|
30
|
+
border-radius: 24px;
|
|
31
|
+
margin-top: 20px;
|
|
32
|
+
${({ theme: e }) => e.mediaQueries.minWidthTablet} {
|
|
33
|
+
padding: 8px;
|
|
34
|
+
gap: 8px;
|
|
35
|
+
margin-top: 16px;
|
|
36
|
+
}
|
|
37
|
+
`, x = t.div`
|
|
38
|
+
width: 28px;
|
|
39
|
+
height: 28px;
|
|
40
|
+
display: flex;
|
|
41
|
+
align-items: center;
|
|
42
|
+
justify-content: center;
|
|
43
|
+
flex-shrink: 0;
|
|
44
|
+
`, g = t.img`
|
|
45
|
+
width: 100%;
|
|
46
|
+
height: 100%;
|
|
47
|
+
object-fit: contain;
|
|
48
|
+
`, u = t.div`
|
|
49
|
+
box-sizing: border-box;
|
|
50
|
+
position: absolute;
|
|
51
|
+
|
|
52
|
+
/* ------ MOBILE FIRST STYLES ------ */
|
|
53
|
+
width: 20px;
|
|
54
|
+
height: 20px;
|
|
55
|
+
border-radius: 13.33px;
|
|
56
|
+
|
|
57
|
+
font-family: 'Athletics';
|
|
58
|
+
font-style: normal;
|
|
59
|
+
font-size: 12px;
|
|
60
|
+
line-height: 16px;
|
|
61
|
+
letter-spacing: 0.5px;
|
|
62
|
+
text-align: center;
|
|
63
|
+
text-transform: uppercase;
|
|
64
|
+
|
|
65
|
+
display: flex;
|
|
66
|
+
align-items: center;
|
|
67
|
+
justify-content: center;
|
|
68
|
+
|
|
69
|
+
font-weight: ${({ $isCompleted: e }) => e ? 900 : 700};
|
|
70
|
+
color: ${({ $isCompleted: e }) => e ? "transparent" : "#0D0D0D"};
|
|
71
|
+
|
|
72
|
+
background: ${({ $isSelected: e, $isCompleted: i }) => i && e ? "#00E573" : i ? "#007038" : e ? "#FFFFFF" : "#313131"};
|
|
73
|
+
|
|
74
|
+
/* ------ DESKTOP OVERRIDES ------ */
|
|
75
|
+
${({ theme: e }) => e.mediaQueries.minWidthTablet} {
|
|
76
|
+
width: 28px;
|
|
77
|
+
height: 28px;
|
|
78
|
+
border-radius: 16px;
|
|
79
|
+
font-size: 16px;
|
|
80
|
+
line-height: 20px;
|
|
81
|
+
letter-spacing: 1px;
|
|
82
|
+
|
|
83
|
+
font-weight: ${({ $isCompleted: e }) => e ? 900 : 700};
|
|
84
|
+
color: ${({ $isCompleted: e, $isSelected: i }) => e && !i ? "transparent" : i ? "#0D0D0D" : "rgba(255, 255, 255, 0.6)"};
|
|
85
|
+
|
|
86
|
+
border: ${({ $isCompleted: e }) => e ? "none" : "1px solid rgba(255, 255, 255, 0.38)"};
|
|
87
|
+
|
|
88
|
+
${({ $isCompleted: e, $isSelected: i }) => !i && !e && o`
|
|
89
|
+
&:hover {
|
|
90
|
+
background: rgba(255, 255, 255, 0.38);
|
|
91
|
+
border: 1px solid #ffffff;
|
|
92
|
+
color: #ffffff;
|
|
93
|
+
}
|
|
94
|
+
`}
|
|
95
|
+
}
|
|
96
|
+
`, h = t(n)`
|
|
97
|
+
position: absolute;
|
|
98
|
+
top: calc(50% + ${r / 2}px);
|
|
99
|
+
`, m = t(n)`
|
|
100
|
+
position: absolute;
|
|
101
|
+
top: calc(50% + ${56 + r / 2}px);
|
|
102
|
+
justify-content: center;
|
|
103
|
+
align-items: center;
|
|
104
|
+
pointer-events: none;
|
|
105
|
+
${({ theme: e }) => e.mediaQueries.minWidthTablet} {
|
|
106
|
+
top: calc(50% + ${66 + r / 2}px);
|
|
107
|
+
}
|
|
108
|
+
`;
|
|
109
|
+
export {
|
|
110
|
+
l as Carousel,
|
|
111
|
+
f as CarouselContainer,
|
|
112
|
+
u as CarouselItem,
|
|
113
|
+
d as CarouselItemContainer,
|
|
114
|
+
x as CarouselItemWrapper,
|
|
115
|
+
c as CarouselWrapper,
|
|
116
|
+
h as ExtendedFlexView,
|
|
117
|
+
m as StyledCarouselBadgeWrapper,
|
|
118
|
+
g as TickIcon
|
|
119
|
+
};
|
|
120
|
+
//# sourceMappingURL=carousel-styled.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"carousel-styled.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/carousel/carousel-styled.tsx"],"sourcesContent":["import styled, { css } from 'styled-components';\n\nimport FlexView from '../../../../ui/layout/flex-view';\nimport { GAME_LAUNCHER_SIZE } from '../card-container/constants';\n\nexport const Carousel = styled.div`\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n justify-content: center;\n`;\nexport const CarouselWrapper = styled.div<{ $translate?: number; $translateDuration?: number }>`\n display: flex;\n width: 100%;\n flex-grow: 1;\n transform: ${({ $translate = 0 }) => `translateX(${-$translate}%)`};\n transition: ${({ $translateDuration }) => `all ${$translateDuration}ms ease-in`};\n`;\n\nexport const CarouselItemContainer = styled.div`\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n flex-grow: 1;\n flex-shrink: 0;\n`;\n\n// StyledComponents.ts\n\nexport const CarouselContainer = styled.div`\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 2px;\n gap: 4px;\n background: ${({ theme }) => theme.colors.BLACK_5 || '#313131'};\n border-radius: 24px;\n margin-top: 20px;\n ${({ theme }) => theme.mediaQueries.minWidthTablet} {\n padding: 8px;\n gap: 8px;\n margin-top: 16px;\n }\n`;\n\ninterface CarouselItemProps {\n $isSelected?: boolean;\n $isCompleted?: boolean;\n $isHovered?: boolean; // Optional, most hover styling should use :hover pseudo-class\n}\n\nexport const CarouselItemWrapper = styled.div`\n width: 28px;\n height: 28px;\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n`;\n\nexport const TickIcon = styled.img`\n width: 100%;\n height: 100%;\n object-fit: contain;\n`;\n\nexport const CarouselItem = styled.div<CarouselItemProps>`\n box-sizing: border-box;\n position: absolute;\n\n /* ------ MOBILE FIRST STYLES ------ */\n width: 20px;\n height: 20px;\n border-radius: 13.33px;\n\n font-family: 'Athletics';\n font-style: normal;\n font-size: 12px;\n line-height: 16px;\n letter-spacing: 0.5px;\n text-align: center;\n text-transform: uppercase;\n\n display: flex;\n align-items: center;\n justify-content: center;\n\n font-weight: ${({ $isCompleted }) => ($isCompleted ? 900 : 700)};\n color: ${({ $isCompleted }) => ($isCompleted ? 'transparent' : '#0D0D0D')};\n\n background: ${({ $isSelected, $isCompleted }) => {\n if ($isCompleted && $isSelected) return '#00E573';\n\n if ($isCompleted) return '#007038';\n\n if ($isSelected) return '#FFFFFF';\n\n return '#313131';\n }};\n\n /* ------ DESKTOP OVERRIDES ------ */\n ${({ theme }) => theme.mediaQueries.minWidthTablet} {\n width: 28px;\n height: 28px;\n border-radius: 16px;\n font-size: 16px;\n line-height: 20px;\n letter-spacing: 1px;\n\n font-weight: ${({ $isCompleted }) => ($isCompleted ? 900 : 700)};\n color: ${({ $isCompleted, $isSelected }) => {\n if ($isCompleted && !$isSelected) return 'transparent';\n\n if ($isSelected) return '#0D0D0D';\n\n return 'rgba(255, 255, 255, 0.6)';\n }};\n\n border: ${({ $isCompleted }) =>\n $isCompleted ? 'none' : '1px solid rgba(255, 255, 255, 0.38)'};\n\n ${({ $isCompleted, $isSelected }) =>\n !$isSelected &&\n !$isCompleted &&\n css`\n &:hover {\n background: rgba(255, 255, 255, 0.38);\n border: 1px solid #ffffff;\n color: #ffffff;\n }\n `}\n }\n`;\n\nexport const ExtendedFlexView = styled(FlexView)`\n position: absolute;\n top: calc(50% + ${GAME_LAUNCHER_SIZE / 2}px);\n`;\n\nexport const StyledCarouselBadgeWrapper = styled(FlexView)`\n position: absolute;\n top: calc(50% + ${56 + GAME_LAUNCHER_SIZE / 2}px);\n justify-content: center;\n align-items: center;\n pointer-events: none;\n ${({ theme }) => theme.mediaQueries.minWidthTablet} {\n top: calc(50% + ${66 + GAME_LAUNCHER_SIZE / 2}px);\n }\n`;\n"],"names":["Carousel","styled","CarouselWrapper","$translate","$translateDuration","CarouselItemContainer","CarouselContainer","theme","CarouselItemWrapper","TickIcon","CarouselItem","$isCompleted","$isSelected","css","ExtendedFlexView","FlexView","GAME_LAUNCHER_SIZE","StyledCarouselBadgeWrapper"],"mappings":";;;AAKO,MAAMA,IAAWC,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GAOlBC,IAAkBD,EAAO;AAAA;AAAA;AAAA;AAAA,eAIvB,CAAC,EAAE,YAAAE,IAAa,QAAQ,cAAc,CAACA,CAAU,IAAI;AAAA,gBACpD,CAAC,EAAE,oBAAAC,EAAyB,MAAA,OAAOA,CAAkB,YAAY;AAAA,GAGpEC,IAAwBJ,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GAW/BK,IAAoBL,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,gBAMxB,CAAC,EAAE,OAAAM,QAAYA,EAAM,OAAO,WAAW,SAAS;AAAA;AAAA;AAAA,IAG5D,CAAC,EAAE,OAAAA,EAAA,MAAYA,EAAM,aAAa,cAAc;AAAA;AAAA;AAAA;AAAA;AAAA,GAavCC,IAAsBP,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GAS7BQ,IAAWR,EAAO;AAAA;AAAA;AAAA;AAAA,GAMlBS,IAAeT,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iBAqBlB,CAAC,EAAE,cAAAU,EAAA,MAAoBA,IAAe,MAAM,GAAI;AAAA,WACtD,CAAC,EAAE,cAAAA,EAAA,MAAoBA,IAAe,gBAAgB,SAAU;AAAA;AAAA,gBAE3D,CAAC,EAAE,aAAAC,GAAa,cAAAD,QACxBA,KAAgBC,IAAoB,YAEpCD,IAAqB,YAErBC,IAAoB,YAEjB,SACR;AAAA;AAAA;AAAA,IAGC,CAAC,EAAE,OAAAL,EAAA,MAAYA,EAAM,aAAa,cAAc;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAQjC,CAAC,EAAE,cAAAI,EAAA,MAAoBA,IAAe,MAAM,GAAI;AAAA,aACtD,CAAC,EAAE,cAAAA,GAAc,aAAAC,QACpBD,KAAgB,CAACC,IAAoB,gBAErCA,IAAoB,YAEjB,0BACR;AAAA;AAAA,cAES,CAAC,EAAE,cAAAD,EAAA,MACXA,IAAe,SAAS,qCAAqC;AAAA;AAAA,MAE7D,CAAC,EAAE,cAAAA,GAAc,aAAAC,EAAA,MACjB,CAACA,KACD,CAACD,KACDE;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,OAMC;AAAA;AAAA,GAIMC,IAAmBb,EAAOc,CAAQ;AAAA;AAAA,oBAE3BC,IAAqB,CAAC;AAAA,GAG7BC,IAA6BhB,EAAOc,CAAQ;AAAA;AAAA,oBAErC,KAAKC,IAAqB,CAAC;AAAA;AAAA;AAAA;AAAA,IAI3C,CAAC,EAAE,OAAAT,EAAA,MAAYA,EAAM,aAAa,cAAc;AAAA,sBAC9B,KAAKS,IAAqB,CAAC;AAAA;AAAA;"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { jsxs as I, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { memo as T, forwardRef as g, useRef as u, useState as $, useMemo as E, createRef as R, useCallback as k, useImperativeHandle as B, useEffect as i } from "react";
|
|
3
|
+
import { useTheme as S } from "styled-components";
|
|
4
|
+
import { ILLUSTRATIONS as x } from "../../../../../assets/illustrations/illustrations.js";
|
|
5
|
+
import A from "../../../../ui/text/text.js";
|
|
6
|
+
import { EDeviceType as L } from "../../../../ui/theme/constants.js";
|
|
7
|
+
import { Carousel as W, CarouselWrapper as b, CarouselItemContainer as j, ExtendedFlexView as v, CarouselContainer as w, CarouselItemWrapper as y, CarouselItem as D, TickIcon as F, StyledCarouselBadgeWrapper as _ } from "./carousel-styled.js";
|
|
8
|
+
const H = ({ items: e, defaultIndex: l = 0 }, p) => {
|
|
9
|
+
var s;
|
|
10
|
+
const { device: C } = S(), d = C <= L.TABLET, m = u(null), c = u(!0), [n, a] = $(l), f = E(() => e.map(() => R()), [e]), h = k((r) => {
|
|
11
|
+
a(r);
|
|
12
|
+
}, []);
|
|
13
|
+
return B(p, () => ({
|
|
14
|
+
nextBtnRef: m,
|
|
15
|
+
indicatorRefs: f,
|
|
16
|
+
currentIndex: n,
|
|
17
|
+
goToIndex: (r) => {
|
|
18
|
+
a(r);
|
|
19
|
+
}
|
|
20
|
+
})), i(() => {
|
|
21
|
+
c.current && (c.current = !1);
|
|
22
|
+
}, []), i(() => {
|
|
23
|
+
a((r) => e.length <= 1 || r >= e.length ? 0 : l);
|
|
24
|
+
}, [l, e.length]), /* @__PURE__ */ I(W, { children: [
|
|
25
|
+
/* @__PURE__ */ o(
|
|
26
|
+
b,
|
|
27
|
+
{
|
|
28
|
+
...e.length > 1 && {
|
|
29
|
+
$translate: n * 100,
|
|
30
|
+
$translateDuration: c.current ? 0 : 300
|
|
31
|
+
},
|
|
32
|
+
children: e.map((r, t) => /* @__PURE__ */ o(j, { children: r.element }, t))
|
|
33
|
+
}
|
|
34
|
+
),
|
|
35
|
+
e.length > 1 && /* @__PURE__ */ o(v, { $flexDirection: "row", $alignItems: "center", $justifyContent: "center", children: /* @__PURE__ */ o(w, { children: e.map((r, t) => /* @__PURE__ */ o(y, { children: /* @__PURE__ */ o(
|
|
36
|
+
D,
|
|
37
|
+
{
|
|
38
|
+
$isSelected: t === n,
|
|
39
|
+
$isCompleted: r.isCompleted,
|
|
40
|
+
onClick: () => h(t),
|
|
41
|
+
children: r.isCompleted && t !== n ? /* @__PURE__ */ o(F, { src: x.GREEN_TICK, alt: "completed" }) : /* @__PURE__ */ o(
|
|
42
|
+
A,
|
|
43
|
+
{
|
|
44
|
+
$renderAs: d ? "ac4-black" : "ac3-black",
|
|
45
|
+
$color: t === n ? "BLACK" : "WHITE_T_60",
|
|
46
|
+
children: t + 1
|
|
47
|
+
}
|
|
48
|
+
)
|
|
49
|
+
}
|
|
50
|
+
) }, t)) }) }),
|
|
51
|
+
((s = e[n]) == null ? void 0 : s.carouselBadge) && /* @__PURE__ */ o(_, { children: e[n].carouselBadge })
|
|
52
|
+
] });
|
|
53
|
+
}, q = T(g(H));
|
|
54
|
+
export {
|
|
55
|
+
q as Carousel
|
|
56
|
+
};
|
|
57
|
+
//# sourceMappingURL=carousel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"carousel.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/carousel/carousel.tsx"],"sourcesContent":["import type { ForwardRefRenderFunction } from 'react';\nimport {\n memo,\n useCallback,\n useEffect,\n useMemo,\n useRef,\n useState,\n forwardRef,\n useImperativeHandle,\n createRef,\n} from 'react';\nimport { useTheme } from 'styled-components';\n\nimport { ILLUSTRATIONS } from '../../../../../assets/illustrations/illustrations';\nimport Text from '../../../../ui/text/text';\nimport { EDeviceType } from '../../../../ui/theme/constants';\nimport * as Styled from './carousel-styled';\nimport {\n CarouselItem,\n CarouselItemWrapper,\n TickIcon,\n StyledCarouselBadgeWrapper,\n} from './carousel-styled';\nimport type { ICarouselProps, ICarouselRefs } from './carousel-types';\n\nconst CarouselComponent: ForwardRefRenderFunction<ICarouselRefs, ICarouselProps> = (\n { items, defaultIndex = 0 },\n ref,\n) => {\n const { device } = useTheme();\n const useSmallFont = device <= EDeviceType.TABLET;\n // const memoizedAnalyticsPrev = useMemo(() => analyticsPrev, [analyticsPrev]);\n // const memoizedAnalyticsNext = useMemo(() => analyticsNext, [analyticsNext]);\n\n const nextBtnRef = useRef<HTMLDivElement>(null) as React.RefObject<HTMLDivElement>;\n const isFirstMount = useRef(true);\n const [currIndex, setCurrIndex] = useState(defaultIndex);\n\n // Create a stable array of refs for indicators\n const indicatorRefs = useMemo(() => items.map(() => createRef<HTMLDivElement>()), [items]);\n\n // const handleCarouselPrev = useCallback(() => {\n // onPrev?.();\n // setCurrIndex(prev => prev - 1);\n // }, [onPrev]);\n\n // const handleCarouselNext = useCallback(() => {\n // onNext?.();\n // setCurrIndex(prev => prev + 1);\n // }, [onNext]);\n\n const handleCarouselIndicatorClick = useCallback((index: number) => {\n setCurrIndex(index);\n }, []);\n\n useImperativeHandle(ref, () => ({\n nextBtnRef,\n indicatorRefs,\n currentIndex: currIndex,\n goToIndex: (index: number) => {\n setCurrIndex(index);\n },\n }));\n\n useEffect(() => {\n if (isFirstMount.current) {\n isFirstMount.current = false;\n }\n }, []);\n\n // Change index from parent\n useEffect(() => {\n setCurrIndex(prev => {\n if (items.length <= 1) return 0;\n\n if (prev >= items.length) return 0;\n\n return defaultIndex;\n });\n }, [defaultIndex, items.length]);\n\n return (\n <Styled.Carousel>\n <Styled.CarouselWrapper\n {...(items.length > 1 && {\n $translate: currIndex * 100,\n $translateDuration: isFirstMount.current ? 0 : 300,\n })}\n >\n {items.map((item, index) => (\n <Styled.CarouselItemContainer key={index}>{item.element}</Styled.CarouselItemContainer>\n ))}\n </Styled.CarouselWrapper>\n\n {/* 👇 Will come below the carousel content */}\n {items.length > 1 && (\n <Styled.ExtendedFlexView $flexDirection=\"row\" $alignItems=\"center\" $justifyContent=\"center\">\n <Styled.CarouselContainer>\n {items.map((item, index) => (\n <CarouselItemWrapper key={index}>\n <CarouselItem\n $isSelected={index === currIndex}\n $isCompleted={item.isCompleted}\n onClick={() => handleCarouselIndicatorClick(index)}\n >\n {item.isCompleted && index !== currIndex ? (\n <TickIcon src={ILLUSTRATIONS.GREEN_TICK} alt=\"completed\" />\n ) : (\n <Text\n $renderAs={useSmallFont ? 'ac4-black' : 'ac3-black'}\n $color={index === currIndex ? 'BLACK' : 'WHITE_T_60'}\n >\n {index + 1}\n </Text>\n )}\n </CarouselItem>\n </CarouselItemWrapper>\n ))}\n </Styled.CarouselContainer>\n </Styled.ExtendedFlexView>\n )}\n\n {/* 👇 Will come below indicators */}\n {items[currIndex]?.carouselBadge && (\n <StyledCarouselBadgeWrapper>{items[currIndex].carouselBadge}</StyledCarouselBadgeWrapper>\n )}\n </Styled.Carousel>\n );\n};\n\nexport const Carousel = memo(forwardRef(CarouselComponent));\n"],"names":["CarouselComponent","items","defaultIndex","ref","device","useTheme","useSmallFont","EDeviceType","nextBtnRef","useRef","isFirstMount","currIndex","setCurrIndex","useState","indicatorRefs","useMemo","createRef","handleCarouselIndicatorClick","useCallback","index","useImperativeHandle","useEffect","prev","jsxs","Styled.Carousel","jsx","Styled.CarouselWrapper","item","Styled.CarouselItemContainer","Styled.ExtendedFlexView","Styled.CarouselContainer","CarouselItemWrapper","CarouselItem","TickIcon","ILLUSTRATIONS","Text","_a","StyledCarouselBadgeWrapper","Carousel","memo","forwardRef"],"mappings":";;;;;;;AA0BA,MAAMA,IAA6E,CACjF,EAAE,OAAAC,GAAO,cAAAC,IAAe,EAAA,GACxBC,MACG;;AACG,QAAA,EAAE,QAAAC,MAAWC,KACbC,IAAeF,KAAUG,EAAY,QAIrCC,IAAaC,EAAuB,IAAI,GACxCC,IAAeD,EAAO,EAAI,GAC1B,CAACE,GAAWC,CAAY,IAAIC,EAASX,CAAY,GAGjDY,IAAgBC,EAAQ,MAAMd,EAAM,IAAI,MAAMe,GAA2B,GAAG,CAACf,CAAK,CAAC,GAYnFgB,IAA+BC,EAAY,CAACC,MAAkB;AAClE,IAAAP,EAAaO,CAAK;AAAA,EACpB,GAAG,CAAE,CAAA;AAEL,SAAAC,EAAoBjB,GAAK,OAAO;AAAA,IAC9B,YAAAK;AAAA,IACA,eAAAM;AAAA,IACA,cAAcH;AAAA,IACd,WAAW,CAACQ,MAAkB;AAC5B,MAAAP,EAAaO,CAAK;AAAA,IACpB;AAAA,EACA,EAAA,GAEFE,EAAU,MAAM;AACd,IAAIX,EAAa,YACfA,EAAa,UAAU;AAAA,EAE3B,GAAG,CAAE,CAAA,GAGLW,EAAU,MAAM;AACd,IAAAT,EAAa,CAAQU,MACfrB,EAAM,UAAU,KAEhBqB,KAAQrB,EAAM,SAAe,IAE1BC,CACR;AAAA,EACA,GAAA,CAACA,GAAcD,EAAM,MAAM,CAAC,GAG7B,gBAAAsB,EAACC,GAAA,EACC,UAAA;AAAA,IAAA,gBAAAC;AAAA,MAACC;AAAAA,MAAA;AAAA,QACE,GAAIzB,EAAM,SAAS,KAAK;AAAA,UACvB,YAAYU,IAAY;AAAA,UACxB,oBAAoBD,EAAa,UAAU,IAAI;AAAA,QACjD;AAAA,QAEC,UAAMT,EAAA,IAAI,CAAC0B,GAAMR,MAChB,gBAAAM,EAACG,GAAA,EAA0C,UAAAD,EAAK,QAAb,GAAAR,CAAqB,CACzD;AAAA,MAAA;AAAA,IACH;AAAA,IAGClB,EAAM,SAAS,KACd,gBAAAwB,EAACI,GAAA,EAAwB,gBAAe,OAAM,aAAY,UAAS,iBAAgB,UACjF,UAAA,gBAAAJ,EAACK,GAAA,EACE,UAAA7B,EAAM,IAAI,CAAC0B,GAAMR,MAChB,gBAAAM,EAACM,GACC,EAAA,UAAA,gBAAAN;AAAA,MAACO;AAAA,MAAA;AAAA,QACC,aAAab,MAAUR;AAAA,QACvB,cAAcgB,EAAK;AAAA,QACnB,SAAS,MAAMV,EAA6BE,CAAK;AAAA,QAEhD,UAAAQ,EAAK,eAAeR,MAAUR,IAC7B,gBAAAc,EAACQ,GAAS,EAAA,KAAKC,EAAc,YAAY,KAAI,YAAA,CAAY,IAEzD,gBAAAT;AAAA,UAACU;AAAA,UAAA;AAAA,YACC,WAAW7B,IAAe,cAAc;AAAA,YACxC,QAAQa,MAAUR,IAAY,UAAU;AAAA,YAEvC,UAAQQ,IAAA;AAAA,UAAA;AAAA,QACX;AAAA,MAAA;AAAA,IAdoB,EAAA,GAAAA,CAiB1B,CACD,EACH,CAAA,GACF;AAAA,MAIDiB,IAAAnC,EAAMU,CAAS,MAAf,gBAAAyB,EAAkB,oCAChBC,GAA4B,EAAA,UAAApC,EAAMU,CAAS,EAAE,cAAc,CAAA;AAAA,EAEhE,EAAA,CAAA;AAEJ,GAEa2B,IAAWC,EAAKC,EAAWxC,CAAiB,CAAC;"}
|
package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-badge-style.js
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import e from "styled-components";
|
|
2
|
+
const t = e.div`
|
|
3
|
+
display: flex;
|
|
4
|
+
gap: 16px;
|
|
5
|
+
height: 24px;
|
|
6
|
+
`, p = e.div`
|
|
7
|
+
display: flex;
|
|
8
|
+
align-items: center;
|
|
9
|
+
height: 24px;
|
|
10
|
+
`, d = e.img`
|
|
11
|
+
width: 24px;
|
|
12
|
+
height: 24px;
|
|
13
|
+
flex-shrink: 0;
|
|
14
|
+
`;
|
|
15
|
+
export {
|
|
16
|
+
p as Badge,
|
|
17
|
+
t as BadgeContainer,
|
|
18
|
+
d as StyledIcon
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=carousel-badge-style.js.map
|
package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-badge-style.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"carousel-badge-style.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-badge-style.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nexport const BadgeContainer = styled.div`\n display: flex;\n gap: 16px;\n height: 24px;\n`;\n\nexport const Badge = styled.div`\n display: flex;\n align-items: center;\n height: 24px;\n`;\n\nexport const StyledIcon = styled.img`\n width: 24px;\n height: 24px;\n flex-shrink: 0;\n`;\n"],"names":["BadgeContainer","styled","Badge","StyledIcon"],"mappings":";AAEO,MAAMA,IAAiBC,EAAO;AAAA;AAAA;AAAA;AAAA,GAMxBC,IAAQD,EAAO;AAAA;AAAA;AAAA;AAAA,GAMfE,IAAaF,EAAO;AAAA;AAAA;AAAA;AAAA;"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { BadgeContainer as e } from "./carousel-badge-style.js";
|
|
3
|
+
import { SingleBadge as a } from "./carousel-single-badge.js";
|
|
4
|
+
const u = ({ badges: l, style: t }) => /* @__PURE__ */ r(e, { style: t, children: l.map((o, i) => /* @__PURE__ */ r(
|
|
5
|
+
a,
|
|
6
|
+
{
|
|
7
|
+
illustration: o.illustration,
|
|
8
|
+
value: o.value,
|
|
9
|
+
color: o.color,
|
|
10
|
+
label: o.label
|
|
11
|
+
},
|
|
12
|
+
i
|
|
13
|
+
)) });
|
|
14
|
+
export {
|
|
15
|
+
u as BadgesGroup
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=carousel-badge.js.map
|
package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-badge.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"carousel-badge.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-badge.tsx"],"sourcesContent":["import type { IBadgeData } from './carousel-badge-type';\n\nimport { BadgeContainer } from './carousel-badge-style';\nimport { SingleBadge } from './carousel-single-badge';\n\ninterface BadgesGroupProps {\n badges: IBadgeData[];\n style?: React.CSSProperties;\n}\n\nexport const BadgesGroup: React.FC<BadgesGroupProps> = ({ badges, style }) => {\n return (\n <BadgeContainer style={style}>\n {badges.map((badge, index) => (\n <SingleBadge\n key={index}\n illustration={badge.illustration}\n value={badge.value}\n color={badge.color}\n label={badge.label}\n />\n ))}\n </BadgeContainer>\n );\n};\n"],"names":["BadgesGroup","badges","style","BadgeContainer","badge","index","jsx","SingleBadge"],"mappings":";;;AAUO,MAAMA,IAA0C,CAAC,EAAE,QAAAC,GAAQ,OAAAC,0BAE7DC,GAAe,EAAA,OAAAD,GACb,YAAO,IAAI,CAACE,GAAOC,MAClB,gBAAAC;AAAA,EAACC;AAAA,EAAA;AAAA,IAEC,cAAcH,EAAM;AAAA,IACpB,OAAOA,EAAM;AAAA,IACb,OAAOA,EAAM;AAAA,IACb,OAAOA,EAAM;AAAA,EAAA;AAAA,EAJRC;AAMR,CAAA,EACH,CAAA;"}
|
package/dist/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-single-badge.js
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { jsxs as r, jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { useTheme as s } from "styled-components";
|
|
3
|
+
import d from "../../../../ui/text/text.js";
|
|
4
|
+
import { EDeviceType as p } from "../../../../ui/theme/constants.js";
|
|
5
|
+
import { Badge as l, StyledIcon as f } from "./carousel-badge-style.js";
|
|
6
|
+
const h = ({ illustration: o, value: t, color: m, label: e }) => {
|
|
7
|
+
const { device: c } = s(), i = c <= p.TABLET;
|
|
8
|
+
return /* @__PURE__ */ r(l, { children: [
|
|
9
|
+
/* @__PURE__ */ n(f, { src: o, alt: e || "badge" }),
|
|
10
|
+
/* @__PURE__ */ r(d, { $renderAs: i ? "ub3" : "ub2", $color: m, children: [
|
|
11
|
+
t,
|
|
12
|
+
" ",
|
|
13
|
+
e
|
|
14
|
+
] })
|
|
15
|
+
] });
|
|
16
|
+
};
|
|
17
|
+
export {
|
|
18
|
+
h as SingleBadge
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=carousel-single-badge.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"carousel-single-badge.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/carousel-badge/carousel-single-badge.tsx"],"sourcesContent":["import type { TColorNames } from '../../../../ui/types';\n\nimport { useTheme } from 'styled-components';\n\nimport Text from '../../../../ui/text/text';\nimport { EDeviceType } from '../../../../ui/theme/constants';\nimport { Badge, StyledIcon } from './carousel-badge-style';\n\nexport interface SingleBadgeProps {\n illustration: string;\n value: number | string;\n color: TColorNames;\n label?: string;\n}\n\nexport const SingleBadge: React.FC<SingleBadgeProps> = ({ illustration, value, color, label }) => {\n const { device } = useTheme();\n const useSmallFont = device <= EDeviceType.TABLET;\n\n return (\n <Badge>\n <StyledIcon src={illustration} alt={label || 'badge'} />\n <Text $renderAs={useSmallFont ? 'ub3' : 'ub2'} $color={color}>\n {value} {label}\n </Text>\n </Badge>\n );\n};\n"],"names":["SingleBadge","illustration","value","color","label","device","useTheme","useSmallFont","EDeviceType","Badge","jsx","StyledIcon","Text"],"mappings":";;;;;AAeO,MAAMA,IAA0C,CAAC,EAAE,cAAAC,GAAc,OAAAC,GAAO,OAAAC,GAAO,OAAAC,QAAY;AAC1F,QAAA,EAAE,QAAAC,MAAWC,KACbC,IAAeF,KAAUG,EAAY;AAE3C,2BACGC,GACC,EAAA,UAAA;AAAA,IAAA,gBAAAC,EAACC,GAAW,EAAA,KAAKV,GAAc,KAAKG,KAAS,SAAS;AAAA,sBACrDQ,GAAK,EAAA,WAAWL,IAAe,QAAQ,OAAO,QAAQJ,GACpD,UAAA;AAAA,MAAAD;AAAA,MAAM;AAAA,MAAEE;AAAA,IAAA,GACX;AAAA,EACF,EAAA,CAAA;AAEJ;"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import i from "styled-components";
|
|
2
|
+
import { GAME_LAUNCHER_SIZE as e } from "../card-container/constants.js";
|
|
3
|
+
import { BORDER_WIDTH as o, GAME_LAUNCHER_ASSET_PADDING as t } from "./constants.js";
|
|
4
|
+
const d = i.div`
|
|
5
|
+
position: absolute;
|
|
6
|
+
z-index: 5;
|
|
7
|
+
height: ${e}px;
|
|
8
|
+
width: ${e}px;
|
|
9
|
+
border-radius: 50%;
|
|
10
|
+
border: ${o}px solid #fff;
|
|
11
|
+
cursor: pointer;
|
|
12
|
+
`, s = i.div`
|
|
13
|
+
position: absolute;
|
|
14
|
+
height: ${e + t}px;
|
|
15
|
+
width: ${e + t}px;
|
|
16
|
+
border-radius: 50%;
|
|
17
|
+
top: ${-t / 2 - o}px;
|
|
18
|
+
left: ${-t / 2 - o}px;
|
|
19
|
+
z-index: 4;
|
|
20
|
+
`;
|
|
21
|
+
i.div`
|
|
22
|
+
position: absolute;
|
|
23
|
+
width: ${e}px;
|
|
24
|
+
height: ${e}px;
|
|
25
|
+
border-radius: 50%;
|
|
26
|
+
background: transparent;
|
|
27
|
+
overflow: hidden;
|
|
28
|
+
|
|
29
|
+
display: flex;
|
|
30
|
+
align-items: center;
|
|
31
|
+
justify-content: center;
|
|
32
|
+
flex: 1;
|
|
33
|
+
|
|
34
|
+
transform-origin: center;
|
|
35
|
+
transform: rotate(0deg); // change dynamically if needed
|
|
36
|
+
`;
|
|
37
|
+
const p = i.img`
|
|
38
|
+
position: absolute;
|
|
39
|
+
width: 100%;
|
|
40
|
+
object-fit: contain;
|
|
41
|
+
pointer-events: none;
|
|
42
|
+
`;
|
|
43
|
+
export {
|
|
44
|
+
d as CircularGameCardWrapper,
|
|
45
|
+
p as DisplayNameImage,
|
|
46
|
+
s as ProgressRingLottieContainer
|
|
47
|
+
};
|
|
48
|
+
//# sourceMappingURL=circular-game-card-styled.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"circular-game-card-styled.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/circular-game-card/circular-game-card-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport { GAME_LAUNCHER_SIZE } from '../card-container/constants';\nimport { GAME_LAUNCHER_ASSET_PADDING, BORDER_WIDTH } from './constants';\n\nexport const CircularGameCardWrapper = styled.div`\n position: absolute;\n z-index: 5;\n height: ${GAME_LAUNCHER_SIZE}px;\n width: ${GAME_LAUNCHER_SIZE}px;\n border-radius: 50%;\n border: ${BORDER_WIDTH}px solid #fff;\n cursor: pointer;\n`;\n\nexport const ProgressRingLottieContainer = styled.div`\n position: absolute;\n height: ${GAME_LAUNCHER_SIZE + GAME_LAUNCHER_ASSET_PADDING}px;\n width: ${GAME_LAUNCHER_SIZE + GAME_LAUNCHER_ASSET_PADDING}px;\n border-radius: 50%;\n top: ${-GAME_LAUNCHER_ASSET_PADDING / 2 - BORDER_WIDTH}px;\n left: ${-GAME_LAUNCHER_ASSET_PADDING / 2 - BORDER_WIDTH}px;\n z-index: 4;\n`;\n\nexport const GameCardSegmentWrapper = styled.div`\n position: absolute;\n width: ${GAME_LAUNCHER_SIZE}px;\n height: ${GAME_LAUNCHER_SIZE}px;\n border-radius: 50%;\n background: transparent;\n overflow: hidden;\n\n display: flex;\n align-items: center;\n justify-content: center;\n flex: 1;\n\n transform-origin: center;\n transform: rotate(0deg); // change dynamically if needed\n`;\n\nexport const DisplayNameImage = styled.img`\n position: absolute;\n width: 100%;\n object-fit: contain;\n pointer-events: none;\n`;\n"],"names":["CircularGameCardWrapper","styled","GAME_LAUNCHER_SIZE","BORDER_WIDTH","ProgressRingLottieContainer","GAME_LAUNCHER_ASSET_PADDING","DisplayNameImage"],"mappings":";;;AAKO,MAAMA,IAA0BC,EAAO;AAAA;AAAA;AAAA,YAGlCC,CAAkB;AAAA,WACnBA,CAAkB;AAAA;AAAA,YAEjBC,CAAY;AAAA;AAAA,GAIXC,IAA8BH,EAAO;AAAA;AAAA,YAEtCC,IAAqBG,CAA2B;AAAA,WACjDH,IAAqBG,CAA2B;AAAA;AAAA,SAElD,CAACA,IAA8B,IAAIF,CAAY;AAAA,UAC9C,CAACE,IAA8B,IAAIF,CAAY;AAAA;AAAA;AAInBF,EAAO;AAAA;AAAA,WAElCC,CAAkB;AAAA,YACjBA,CAAkB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAcvB,MAAMI,IAAmBL,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA;"}
|
package/dist/features/circle-games/game-launcher-v2/comps/circular-game-card/circular-game-card.js
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { jsx as o, jsxs as y } from "react/jsx-runtime";
|
|
2
|
+
import { memo as E, forwardRef as G, useRef as p, useState as C, useCallback as f, useImperativeHandle as S, useMemo as u } from "react";
|
|
3
|
+
import { LOTTIE as W } from "../../../../../assets/lottie/lottie.js";
|
|
4
|
+
import _ from "../../../../ui/lottie-animation/lottie-animation.js";
|
|
5
|
+
import { CardContainer as k } from "../card-container/card-container.js";
|
|
6
|
+
import { GameCardContent as v } from "../game-card-content/game-card-content.js";
|
|
7
|
+
import { CircularGameCardWrapper as F, ProgressRingLottieContainer as H, DisplayNameImage as M } from "./circular-game-card-styled.js";
|
|
8
|
+
const N = ({ data: e, label: d, initialValue: t = 0, value: i, maxValue: n = 1 }, I) => {
|
|
9
|
+
const s = p(null), m = p(null), [l, g] = C(!1), [T, b] = C("WHITE_T_87"), R = f(() => {
|
|
10
|
+
var r;
|
|
11
|
+
(r = e == null ? void 0 : e.onPress) == null || r.call(e);
|
|
12
|
+
}, [e]), A = f((r) => {
|
|
13
|
+
g(!0), b(r);
|
|
14
|
+
}, []);
|
|
15
|
+
S(I, () => ({
|
|
16
|
+
labelRef: s,
|
|
17
|
+
circularCardWrapperRef: m,
|
|
18
|
+
startLabelAnimation: A
|
|
19
|
+
}));
|
|
20
|
+
const a = u(() => {
|
|
21
|
+
if (n <= 0)
|
|
22
|
+
return;
|
|
23
|
+
const r = 92, c = r / n, P = Math.min(c * t, r), h = Math.min(c * i + 1, r);
|
|
24
|
+
return [P, h];
|
|
25
|
+
}, [t, n, i]), L = u(
|
|
26
|
+
() => ({
|
|
27
|
+
renderer: "canvas",
|
|
28
|
+
autoplay: !0,
|
|
29
|
+
loop: !1,
|
|
30
|
+
initialSegment: a
|
|
31
|
+
}),
|
|
32
|
+
[a]
|
|
33
|
+
);
|
|
34
|
+
return /* @__PURE__ */ o(
|
|
35
|
+
k,
|
|
36
|
+
{
|
|
37
|
+
ref: m,
|
|
38
|
+
labelRef: s,
|
|
39
|
+
label: d,
|
|
40
|
+
isAnimated: l,
|
|
41
|
+
labelColor: l ? T : "WHITE_T_60",
|
|
42
|
+
children: /* @__PURE__ */ y(F, { onClick: R, children: [
|
|
43
|
+
/* @__PURE__ */ o(H, { children: /* @__PURE__ */ o(
|
|
44
|
+
_,
|
|
45
|
+
{
|
|
46
|
+
src: W.LEVELUP_RINGS,
|
|
47
|
+
settings: L,
|
|
48
|
+
animateOnIntersect: !0
|
|
49
|
+
}
|
|
50
|
+
) }),
|
|
51
|
+
/* @__PURE__ */ o(v, { card: e.card, isCompleted: e.isCompleted }),
|
|
52
|
+
/* @__PURE__ */ o(
|
|
53
|
+
M,
|
|
54
|
+
{
|
|
55
|
+
src: e.displayNameImage || void 0,
|
|
56
|
+
alt: `${e.name} label`
|
|
57
|
+
}
|
|
58
|
+
)
|
|
59
|
+
] })
|
|
60
|
+
}
|
|
61
|
+
);
|
|
62
|
+
}, q = E(G(N));
|
|
63
|
+
export {
|
|
64
|
+
q as CircularGameCard
|
|
65
|
+
};
|
|
66
|
+
//# sourceMappingURL=circular-game-card.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"circular-game-card.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/circular-game-card/circular-game-card.tsx"],"sourcesContent":["import type { ForwardRefRenderFunction } from 'react';\nimport React, {\n forwardRef,\n memo,\n useCallback,\n useImperativeHandle,\n useMemo,\n useRef,\n useState,\n} from 'react';\n\nimport { LOTTIE } from '../../../../../assets/lottie/lottie';\nimport LottieAnimation from '../../../../ui/lottie-animation/lottie-animation';\nimport type { TColorNames } from '../../../../ui/types';\nimport { CardContainer } from '../card-container/card-container';\nimport { GameCardContent } from '../game-card-content/game-card-content';\nimport * as Styled from './circular-game-card-styled';\nimport type { ICircularGameCardProps, ICircularGameCardRefs } from './circular-game-card-types';\n\nconst CircularGameCardComponent: ForwardRefRenderFunction<\n ICircularGameCardRefs,\n ICircularGameCardProps\n> = ({ data, label: gameCategoryLabel, initialValue = 0, value, maxValue = 1 }, ref) => {\n const labelRef = useRef<HTMLDivElement>(null) as React.RefObject<HTMLDivElement>;\n const cardWrapperRef = useRef<HTMLDivElement>(null) as React.RefObject<HTMLDivElement>;\n\n const [isAnimated, setIsAnimated] = useState(false);\n const [animatedColor, setAnimatedColor] = useState<TColorNames>('WHITE_T_87');\n\n const onCardClick = useCallback(() => {\n data?.onPress?.();\n }, [data]);\n\n const startLabelAnimation = useCallback((color: TColorNames) => {\n setIsAnimated(true);\n setAnimatedColor(color);\n }, []);\n\n useImperativeHandle(ref, () => ({\n labelRef,\n circularCardWrapperRef: cardWrapperRef,\n startLabelAnimation,\n }));\n\n const animationSegments: [number, number] | undefined = useMemo(() => {\n if (maxValue <= 0) {\n return;\n }\n\n const totalFrames = 92;\n const framesPerValue = totalFrames / maxValue;\n\n const initialFrameToPlay = Math.min(framesPerValue * initialValue, totalFrames);\n const finalFrameToPlay = Math.min(framesPerValue * value + 1, totalFrames);\n\n return [initialFrameToPlay, finalFrameToPlay];\n }, [initialValue, maxValue, value]);\n\n const levelUpAnimationSettings = useMemo(\n () => ({\n renderer: 'canvas',\n autoplay: true,\n loop: false,\n initialSegment: animationSegments,\n }),\n [animationSegments],\n );\n\n return (\n <CardContainer\n ref={cardWrapperRef}\n labelRef={labelRef}\n label={gameCategoryLabel}\n isAnimated={isAnimated}\n labelColor={isAnimated ? animatedColor : 'WHITE_T_60'}\n >\n <Styled.CircularGameCardWrapper onClick={onCardClick}>\n <Styled.ProgressRingLottieContainer>\n <LottieAnimation\n src={LOTTIE.LEVELUP_RINGS}\n settings={levelUpAnimationSettings}\n animateOnIntersect\n />\n </Styled.ProgressRingLottieContainer>\n <GameCardContent card={data.card} isCompleted={data.isCompleted} />\n\n <Styled.DisplayNameImage\n src={data.displayNameImage || undefined}\n alt={`${data.name} label`}\n />\n </Styled.CircularGameCardWrapper>\n </CardContainer>\n );\n};\n\nexport const CircularGameCard = memo(forwardRef(CircularGameCardComponent));\n"],"names":["CircularGameCardComponent","data","gameCategoryLabel","initialValue","value","maxValue","ref","labelRef","useRef","cardWrapperRef","isAnimated","setIsAnimated","useState","animatedColor","setAnimatedColor","onCardClick","useCallback","_a","startLabelAnimation","color","useImperativeHandle","animationSegments","useMemo","totalFrames","framesPerValue","initialFrameToPlay","finalFrameToPlay","levelUpAnimationSettings","jsx","CardContainer","jsxs","Styled.CircularGameCardWrapper","Styled.ProgressRingLottieContainer","LottieAnimation","LOTTIE","GameCardContent","Styled.DisplayNameImage","CircularGameCard","memo","forwardRef"],"mappings":";;;;;;;AAmBA,MAAMA,IAGF,CAAC,EAAE,MAAAC,GAAM,OAAOC,GAAmB,cAAAC,IAAe,GAAG,OAAAC,GAAO,UAAAC,IAAW,EAAE,GAAGC,MAAQ;AAChF,QAAAC,IAAWC,EAAuB,IAAI,GACtCC,IAAiBD,EAAuB,IAAI,GAE5C,CAACE,GAAYC,CAAa,IAAIC,EAAS,EAAK,GAC5C,CAACC,GAAeC,CAAgB,IAAIF,EAAsB,YAAY,GAEtEG,IAAcC,EAAY,MAAM;;AACpC,KAAAC,IAAAhB,KAAA,gBAAAA,EAAM,YAAN,QAAAgB,EAAA,KAAAhB;AAAA,EAAgB,GACf,CAACA,CAAI,CAAC,GAEHiB,IAAsBF,EAAY,CAACG,MAAuB;AAC9D,IAAAR,EAAc,EAAI,GAClBG,EAAiBK,CAAK;AAAA,EACxB,GAAG,CAAE,CAAA;AAEL,EAAAC,EAAoBd,GAAK,OAAO;AAAA,IAC9B,UAAAC;AAAA,IACA,wBAAwBE;AAAA,IACxB,qBAAAS;AAAA,EACA,EAAA;AAEI,QAAAG,IAAkDC,EAAQ,MAAM;AACpE,QAAIjB,KAAY;AACd;AAGF,UAAMkB,IAAc,IACdC,IAAiBD,IAAclB,GAE/BoB,IAAqB,KAAK,IAAID,IAAiBrB,GAAcoB,CAAW,GACxEG,IAAmB,KAAK,IAAIF,IAAiBpB,IAAQ,GAAGmB,CAAW;AAElE,WAAA,CAACE,GAAoBC,CAAgB;AAAA,EAC3C,GAAA,CAACvB,GAAcE,GAAUD,CAAK,CAAC,GAE5BuB,IAA2BL;AAAA,IAC/B,OAAO;AAAA,MACL,UAAU;AAAA,MACV,UAAU;AAAA,MACV,MAAM;AAAA,MACN,gBAAgBD;AAAA,IAAA;AAAA,IAElB,CAACA,CAAiB;AAAA,EAAA;AAIlB,SAAA,gBAAAO;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,KAAKpB;AAAA,MACL,UAAAF;AAAA,MACA,OAAOL;AAAA,MACP,YAAAQ;AAAA,MACA,YAAYA,IAAaG,IAAgB;AAAA,MAEzC,UAAC,gBAAAiB,EAAAC,GAAA,EAA+B,SAAShB,GACvC,UAAA;AAAA,QAAC,gBAAAa,EAAAI,GAAA,EACC,UAAA,gBAAAJ;AAAA,UAACK;AAAA,UAAA;AAAA,YACC,KAAKC,EAAO;AAAA,YACZ,UAAUP;AAAA,YACV,oBAAkB;AAAA,UAAA;AAAA,QAAA,GAEtB;AAAA,0BACCQ,GAAgB,EAAA,MAAMlC,EAAK,MAAM,aAAaA,EAAK,aAAa;AAAA,QAEjE,gBAAA2B;AAAA,UAACQ;AAAAA,UAAA;AAAA,YACC,KAAKnC,EAAK,oBAAoB;AAAA,YAC9B,KAAK,GAAGA,EAAK,IAAI;AAAA,UAAA;AAAA,QACnB;AAAA,MAAA,GACF;AAAA,IAAA;AAAA,EAAA;AAGN,GAEaoC,IAAmBC,EAAKC,EAAWvC,CAAyB,CAAC;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/circular-game-card/constants.ts"],"sourcesContent":["import { GAME_LAUNCHER_SIZE } from '../card-container/constants';\n\nexport const GAME_LAUNCHER_ASSET_PADDING = (GAME_LAUNCHER_SIZE * 17.5) / 100;\n\nexport const BORDER_WIDTH = 2;\n"],"names":["GAME_LAUNCHER_ASSET_PADDING","GAME_LAUNCHER_SIZE","BORDER_WIDTH"],"mappings":";AAEa,MAAAA,IAA+BC,IAAqB,OAAQ,KAE5DC,IAAe;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/game-card-content/constants.ts"],"sourcesContent":["import { GAME_LAUNCHER_SIZE } from '../card-container/constants';\n\nexport const ASSET_CONTAINER_SIZE = Math.ceil((GAME_LAUNCHER_SIZE * 120) / 100);\n"],"names":["ASSET_CONTAINER_SIZE","GAME_LAUNCHER_SIZE"],"mappings":";AAEO,MAAMA,IAAuB,KAAK,KAAMC,IAAqB,MAAO,GAAG;"}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import t from "styled-components";
|
|
2
|
+
import { GAME_LAUNCHER_SIZE as r } from "../card-container/constants.js";
|
|
3
|
+
import { ASSET_CONTAINER_SIZE as e } from "./constants.js";
|
|
4
|
+
const s = t.div`
|
|
5
|
+
position: absolute;
|
|
6
|
+
width: ${r}px;
|
|
7
|
+
height: ${r}px;
|
|
8
|
+
border-radius: 50%;
|
|
9
|
+
background: transparent;
|
|
10
|
+
overflow: hidden;
|
|
11
|
+
|
|
12
|
+
display: flex;
|
|
13
|
+
align-items: center;
|
|
14
|
+
justify-content: center;
|
|
15
|
+
flex: 1;
|
|
16
|
+
|
|
17
|
+
transform-origin: center;
|
|
18
|
+
transform: rotate(0deg); // change dynamically if needed
|
|
19
|
+
`, d = t.div`
|
|
20
|
+
position: absolute;
|
|
21
|
+
top: 50%;
|
|
22
|
+
left: 50%;
|
|
23
|
+
transform: translate(-50%, -50%);
|
|
24
|
+
|
|
25
|
+
width: ${e}px;
|
|
26
|
+
height: ${e}px;
|
|
27
|
+
|
|
28
|
+
display: flex;
|
|
29
|
+
align-items: center;
|
|
30
|
+
justify-content: center;
|
|
31
|
+
|
|
32
|
+
overflow: hidden;
|
|
33
|
+
background-color: transparent;
|
|
34
|
+
z-index: 1;
|
|
35
|
+
flex-shrink: 0;
|
|
36
|
+
|
|
37
|
+
&:hover {
|
|
38
|
+
background: ${({ theme: n }) => n.colors.WHITE_T_15};
|
|
39
|
+
cursor: pointer;
|
|
40
|
+
}
|
|
41
|
+
`, l = t.div`
|
|
42
|
+
position: absolute;
|
|
43
|
+
height: ${e}px;
|
|
44
|
+
width: ${e}px;
|
|
45
|
+
z-index: 5;
|
|
46
|
+
backdrop-filter: blur(16px);
|
|
47
|
+
-webkit-backdrop-filter: blur(16px);
|
|
48
|
+
/* pointer-events: none; */
|
|
49
|
+
display: flex;
|
|
50
|
+
align-items: center;
|
|
51
|
+
justify-content: center;
|
|
52
|
+
`, p = t.div`
|
|
53
|
+
position: absolute;
|
|
54
|
+
z-index: 6;
|
|
55
|
+
`;
|
|
56
|
+
export {
|
|
57
|
+
d as AssetContainer,
|
|
58
|
+
l as CircularOverlay,
|
|
59
|
+
s as GameCardSegmentWrapper,
|
|
60
|
+
p as IconWrapper
|
|
61
|
+
};
|
|
62
|
+
//# sourceMappingURL=game-card-content-styled.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"game-card-content-styled.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/game-card-content/game-card-content-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport { GAME_LAUNCHER_SIZE } from '../card-container/constants';\nimport { ASSET_CONTAINER_SIZE } from './constants';\n\nexport const GameCardSegmentWrapper = styled.div`\n position: absolute;\n width: ${GAME_LAUNCHER_SIZE}px;\n height: ${GAME_LAUNCHER_SIZE}px;\n border-radius: 50%;\n background: transparent;\n overflow: hidden;\n\n display: flex;\n align-items: center;\n justify-content: center;\n flex: 1;\n\n transform-origin: center;\n transform: rotate(0deg); // change dynamically if needed\n`;\n\nexport const AssetContainer = styled.div`\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n\n width: ${ASSET_CONTAINER_SIZE}px;\n height: ${ASSET_CONTAINER_SIZE}px;\n\n display: flex;\n align-items: center;\n justify-content: center;\n\n overflow: hidden;\n background-color: transparent;\n z-index: 1;\n flex-shrink: 0;\n\n &:hover {\n background: ${({ theme }) => theme.colors.WHITE_T_15};\n cursor: pointer;\n }\n`;\n\nexport const CircularOverlay = styled.div`\n position: absolute;\n height: ${ASSET_CONTAINER_SIZE}px;\n width: ${ASSET_CONTAINER_SIZE}px;\n z-index: 5;\n backdrop-filter: blur(16px);\n -webkit-backdrop-filter: blur(16px);\n /* pointer-events: none; */\n display: flex;\n align-items: center;\n justify-content: center;\n`;\n\nexport const IconWrapper = styled.div`\n position: absolute;\n z-index: 6;\n`;\n"],"names":["GameCardSegmentWrapper","styled","GAME_LAUNCHER_SIZE","AssetContainer","ASSET_CONTAINER_SIZE","theme","CircularOverlay","IconWrapper"],"mappings":";;;AAKO,MAAMA,IAAyBC,EAAO;AAAA;AAAA,WAElCC,CAAkB;AAAA,YACjBA,CAAkB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GAcjBC,IAAiBF,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,WAM1BG,CAAoB;AAAA,YACnBA,CAAoB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAYd,CAAC,EAAE,OAAAC,EAAA,MAAYA,EAAM,OAAO,UAAU;AAAA;AAAA;AAAA,GAK3CC,IAAkBL,EAAO;AAAA;AAAA,YAE1BG,CAAoB;AAAA,WACrBA,CAAoB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GAUlBG,IAAcN,EAAO;AAAA;AAAA;AAAA;"}
|
package/dist/features/circle-games/game-launcher-v2/comps/game-card-content/game-card-content.js
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { jsxs as n, jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { memo as o } from "react";
|
|
3
|
+
import { ILLUSTRATIONS as i } from "../../../../../assets/illustrations/illustrations.js";
|
|
4
|
+
import m from "../../../../ui/lottie-animation/lottie-animation.js";
|
|
5
|
+
import { GameCardSegmentWrapper as a, AssetContainer as s, CircularOverlay as c, IconWrapper as p } from "./game-card-content-styled.js";
|
|
6
|
+
const d = { renderer: "canvas", loop: !0 }, h = o(({ isCompleted: e, card: t }) => /* @__PURE__ */ n(a, { children: [
|
|
7
|
+
/* @__PURE__ */ r(s, { children: /* @__PURE__ */ r(m, { src: t, settings: d, animateOnIntersect: !0 }) }),
|
|
8
|
+
e && /* @__PURE__ */ r(c, { children: /* @__PURE__ */ r(p, { children: /* @__PURE__ */ r("img", { src: i.GREEN_TICK }) }) })
|
|
9
|
+
] }));
|
|
10
|
+
export {
|
|
11
|
+
h as GameCardContent
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=game-card-content.js.map
|
package/dist/features/circle-games/game-launcher-v2/comps/game-card-content/game-card-content.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"game-card-content.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/game-card-content/game-card-content.tsx"],"sourcesContent":["import type { IGameCardContentProps } from './game-card-content-types';\n\nimport { memo } from 'react';\n\nimport { ILLUSTRATIONS } from '../../../../../assets/illustrations/illustrations';\nimport LottieAnimation from '../../../../ui/lottie-animation/lottie-animation';\nimport * as Styled from './game-card-content-styled';\n\nconst renderSettings = { renderer: 'canvas', loop: true };\n\nexport const GameCardContent = memo(({ isCompleted, card }: IGameCardContentProps) => {\n return (\n <Styled.GameCardSegmentWrapper>\n <Styled.AssetContainer>\n <LottieAnimation src={card} settings={renderSettings} animateOnIntersect />\n </Styled.AssetContainer>\n\n {isCompleted && (\n <Styled.CircularOverlay>\n <Styled.IconWrapper>\n <img src={ILLUSTRATIONS.GREEN_TICK} />\n </Styled.IconWrapper>\n </Styled.CircularOverlay>\n )}\n </Styled.GameCardSegmentWrapper>\n );\n});\n"],"names":["renderSettings","GameCardContent","memo","isCompleted","card","jsxs","Styled.GameCardSegmentWrapper","jsx","Styled.AssetContainer","LottieAnimation","Styled.CircularOverlay","Styled.IconWrapper","ILLUSTRATIONS"],"mappings":";;;;;AAQA,MAAMA,IAAiB,EAAE,UAAU,UAAU,MAAM,GAAK,GAE3CC,IAAkBC,EAAK,CAAC,EAAE,aAAAC,GAAa,MAAAC,QAEhD,gBAAAC,EAACC,GAAA,EACC,UAAA;AAAA,EAAC,gBAAAC,EAAAC,GAAA,EACC,UAAC,gBAAAD,EAAAE,GAAA,EAAgB,KAAKL,GAAM,UAAUJ,GAAgB,oBAAkB,GAAA,CAAC,EAC3E,CAAA;AAAA,EAECG,KACC,gBAAAI,EAACG,GAAA,EACC,UAAC,gBAAAH,EAAAI,GAAA,EACC,4BAAC,OAAI,EAAA,KAAKC,EAAc,WAAY,CAAA,EACtC,CAAA,GACF;AAEJ,EAAA,CAAA,CAEH;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.js","sources":["../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/constants.ts"],"sourcesContent":["import type { TColorNames } from '../../../../ui/types';\nimport type { TTableMode } from '../../dal/use-get-circle-home-details-dal/use-get-circle-home-dal-types';\nimport type { AnimationSegment } from 'lottie-web';\n\nexport const TABLE_REVEAL_ANIMATION = {\n REVEAL: [0, 15] as AnimationSegment,\n REVEAL_CONTENT: [8, 15] as AnimationSegment,\n DISAPPEAR_CONTENT: [21, 29] as AnimationSegment,\n DISAPPEAR: [21, 38] as AnimationSegment,\n};\n\nexport const TABLE_MODE_LABEL_COLOR: Partial<Record<TTableMode, TColorNames>> = {\n random: 'BLUE_4',\n sequence: 'YELLOW_4',\n advance: 'PURPLE_4',\n};\n\n// z-index 1 to 20 are for table number arc segments\nexport const TABLE_CARD_SHADOW_Z_INDEX = 50;\nexport const INFINITE_MODE_Z_INDEX = TABLE_CARD_SHADOW_Z_INDEX + 1;\nexport const TABLE_MODE_CONTAINER_Z_INDEX = 100;\n\n// table modes\nexport const TABLE_MODE_OVERLAY_Z_INDEX = 1;\nexport const ABSOLUTE_VIEW_Z_INDEX = 2;\nexport const INFINITE_MODE_TEXT = 'INFINITY MODE';\n\nexport const NORMAL_TABLE_MODES = ['sequence', 'random', 'advance'] as Exclude<\n TTableMode,\n 'infinite'\n>[];\n"],"names":["TABLE_REVEAL_ANIMATION","TABLE_MODE_LABEL_COLOR","TABLE_CARD_SHADOW_Z_INDEX","INFINITE_MODE_Z_INDEX","TABLE_MODE_CONTAINER_Z_INDEX","TABLE_MODE_OVERLAY_Z_INDEX","ABSOLUTE_VIEW_Z_INDEX","INFINITE_MODE_TEXT","NORMAL_TABLE_MODES"],"mappings":"AAIO,MAAMA,IAAyB;AAAA,EACpC,QAAQ,CAAC,GAAG,EAAE;AAAA,EACd,gBAAgB,CAAC,GAAG,EAAE;AAAA,EACtB,mBAAmB,CAAC,IAAI,EAAE;AAAA,EAC1B,WAAW,CAAC,IAAI,EAAE;AACpB,GAEaC,IAAmE;AAAA,EAC9E,QAAQ;AAAA,EACR,UAAU;AAAA,EACV,SAAS;AACX,GAGaC,IAA4B,IAC5BC,IAAwBD,IAA4B,GACpDE,IAA+B,KAG/BC,IAA6B,GAC7BC,IAAwB,GACxBC,IAAqB,iBAErBC,IAAqB,CAAC,YAAY,UAAU,SAAS;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"infinite-mode-launcher-button.js","sources":["../../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/infinite-button/infinite-mode-launcher-button.tsx"],"sourcesContent":["import type { InfiniteButtonCardProps } from './infinite-mode-launcher-button-type';\n\nimport React from 'react';\n\nimport { LOTTIE } from '../../../../../../assets/lottie/lottie';\nimport LottieAnimation from '../../../../../ui/lottie-animation/lottie-animation';\nimport * as Styled from '../tables-card-styled';\n\nconst rendererSettings = {\n renderer: 'canvas',\n};\n\nconst InfiniteButtonCard: React.FC<InfiniteButtonCardProps> = ({\n onClick,\n onMouseOver,\n onMouseLeave,\n buttonRef,\n}) => {\n return (\n <Styled.InfiniteButtonWrapper\n ref={buttonRef}\n onClick={onClick}\n onMouseOver={onMouseOver}\n onMouseLeave={onMouseLeave}\n >\n <Styled.ExtendedAbsoluteView>\n <LottieAnimation\n src={LOTTIE.INFINITE_BUTTON_BG}\n settings={rendererSettings}\n animateOnIntersect\n />\n </Styled.ExtendedAbsoluteView>\n <Styled.ExtendedAbsoluteView>\n <LottieAnimation\n src={LOTTIE.INFINITE_BUTTON_SYMBOL}\n settings={rendererSettings}\n animateOnIntersect\n />\n </Styled.ExtendedAbsoluteView>\n </Styled.InfiniteButtonWrapper>\n );\n};\n\nexport default React.memo(InfiniteButtonCard);\n"],"names":["rendererSettings","InfiniteButtonCard","onClick","onMouseOver","onMouseLeave","buttonRef","jsxs","Styled.InfiniteButtonWrapper","jsx","Styled.ExtendedAbsoluteView","LottieAnimation","LOTTIE","InfiniteButtonCard$1","React"],"mappings":";;;;;AAQA,MAAMA,IAAmB;AAAA,EACvB,UAAU;AACZ,GAEMC,IAAwD,CAAC;AAAA,EAC7D,SAAAC;AAAA,EACA,aAAAC;AAAA,EACA,cAAAC;AAAA,EACA,WAAAC;AACF,MAEI,gBAAAC;AAAA,EAACC;AAAAA,EAAA;AAAA,IACC,KAAKF;AAAA,IACL,SAAAH;AAAA,IACA,aAAAC;AAAA,IACA,cAAAC;AAAA,IAEA,UAAA;AAAA,MAAC,gBAAAI,EAAAC,GAAA,EACC,UAAA,gBAAAD;AAAA,QAACE;AAAA,QAAA;AAAA,UACC,KAAKC,EAAO;AAAA,UACZ,UAAUX;AAAA,UACV,oBAAkB;AAAA,QAAA;AAAA,MAAA,GAEtB;AAAA,MACA,gBAAAQ,EAACC,GAAA,EACC,UAAA,gBAAAD;AAAA,QAACE;AAAA,QAAA;AAAA,UACC,KAAKC,EAAO;AAAA,UACZ,UAAUX;AAAA,UACV,oBAAkB;AAAA,QAAA;AAAA,MAAA,GAEtB;AAAA,IAAA;AAAA,EAAA;AAAA,GAKNY,IAAeC,EAAM,KAAKZ,CAAkB;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.js","sources":["../../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/spl-events-text/constants.ts"],"sourcesContent":["import { LOTTIE } from '../../../../../../assets/lottie/lottie';\nimport { CircleSoundKey } from '../../../../hooks/use-circle-sounds/use-circle-sounds-enums';\nimport { TSplEventsLottieType } from './spl-events-text-types';\n\nexport const LOTTIE_MAP: Record<TSplEventsLottieType, { src: string; audio: string }> = {\n [TSplEventsLottieType.KEEP_IT_UP]: {\n src: LOTTIE.KEEP_IT_UP,\n audio: CircleSoundKey.KEEP_IT_UP,\n },\n [TSplEventsLottieType.DOING_GREAT]: {\n src: LOTTIE.DOING_GREAT,\n audio: CircleSoundKey.DOING_GREAT,\n },\n [TSplEventsLottieType.ALL_DONE]: {\n src: LOTTIE.ALL_DONE,\n audio: CircleSoundKey.ALL_DONE,\n },\n};\n\nexport const COMPLETED_MODES_TO_SPL_EVENT_TYPE_MAP: Record<number, TSplEventsLottieType> = {\n 1: TSplEventsLottieType.KEEP_IT_UP,\n 2: TSplEventsLottieType.DOING_GREAT,\n 3: TSplEventsLottieType.ALL_DONE,\n};\n\nexport const splEventsLottieSettings = { loop: false, autoplay: true };\n"],"names":["LOTTIE_MAP","TSplEventsLottieType","LOTTIE","CircleSoundKey","COMPLETED_MODES_TO_SPL_EVENT_TYPE_MAP","splEventsLottieSettings"],"mappings":";;;AAIO,MAAMA,IAA2E;AAAA,EACtF,CAACC,EAAqB,UAAU,GAAG;AAAA,IACjC,KAAKC,EAAO;AAAA,IACZ,OAAOC,EAAe;AAAA,EACxB;AAAA,EACA,CAACF,EAAqB,WAAW,GAAG;AAAA,IAClC,KAAKC,EAAO;AAAA,IACZ,OAAOC,EAAe;AAAA,EACxB;AAAA,EACA,CAACF,EAAqB,QAAQ,GAAG;AAAA,IAC/B,KAAKC,EAAO;AAAA,IACZ,OAAOC,EAAe;AAAA,EACxB;AACF,GAEaC,IAA8E;AAAA,EACzF,GAAGH,EAAqB;AAAA,EACxB,GAAGA,EAAqB;AAAA,EACxB,GAAGA,EAAqB;AAC1B,GAEaI,IAA0B,EAAE,MAAM,IAAO,UAAU,GAAK;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"spl-events-text-style.js","sources":["../../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/spl-events-text/spl-events-text-style.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport FlexView from '../../../../../ui/layout/flex-view';\nimport { GAME_LAUNCHER_SIZE } from '../../card-container/constants';\n\nexport const StyledSpecialEventsText = styled(FlexView)`\n position: absolute;\n top: 90%;\n width: ${GAME_LAUNCHER_SIZE}px;\n display: flex;\n justify-content: center;\n align-items: center;\n pointer-events: none;\n`;\n"],"names":["StyledSpecialEventsText","styled","FlexView","GAME_LAUNCHER_SIZE"],"mappings":";;;AAKa,MAAAA,IAA0BC,EAAOC,CAAQ;AAAA;AAAA;AAAA,WAG3CC,CAAkB;AAAA;AAAA;AAAA;AAAA;AAAA;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"spl-events-text-types.js","sources":["../../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/spl-events-text/spl-events-text-types.ts"],"sourcesContent":["import type { TTableMode } from '../../../dal/use-get-circle-home-details-dal/use-get-circle-home-dal-types';\n\nexport enum TSplEventsLottieType {\n KEEP_IT_UP = 'KEEP_IT_UP',\n DOING_GREAT = 'DOING_GREAT',\n ALL_DONE = 'ALL_DONE',\n}\n\nexport type ISplEventsTextProps = {\n completedModes: TTableMode[];\n};\n"],"names":["TSplEventsLottieType"],"mappings":"AAEY,IAAAA,sBAAAA,OACVA,EAAA,aAAa,cACbA,EAAA,cAAc,eACdA,EAAA,WAAW,YAHDA,IAAAA,KAAA,CAAA,CAAA;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"spl-events-text.js","sources":["../../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/spl-events-text/spl-events-text.tsx"],"sourcesContent":["import type { CircleSoundKey } from '../../../../hooks/use-circle-sounds/use-circle-sounds-enums';\nimport type { ISplEventsTextProps } from './spl-events-text-types';\n\nimport React from 'react';\n\nimport LottieAnimation from '../../../../../ui/lottie-animation/lottie-animation';\nimport { useCircleSounds } from '../../../../hooks/use-circle-sounds/use-circle-sounds';\nimport {\n COMPLETED_MODES_TO_SPL_EVENT_TYPE_MAP,\n LOTTIE_MAP,\n splEventsLottieSettings,\n} from './constants';\nimport { StyledSpecialEventsText } from './spl-events-text-style';\nimport { TSplEventsLottieType } from './spl-events-text-types';\n\nexport const SplEventsText = React.memo(({ completedModes }: ISplEventsTextProps) => {\n const { play } = useCircleSounds();\n const completedModesCount = completedModes.length;\n\n const splEvent =\n COMPLETED_MODES_TO_SPL_EVENT_TYPE_MAP[completedModesCount] || TSplEventsLottieType.KEEP_IT_UP;\n\n const { src, audio } = LOTTIE_MAP[splEvent];\n\n return (\n <StyledSpecialEventsText>\n <LottieAnimation\n src={src}\n settings={splEventsLottieSettings}\n onRender={() => play(audio as CircleSoundKey)}\n />\n </StyledSpecialEventsText>\n );\n});\n"],"names":["SplEventsText","React","completedModes","play","useCircleSounds","completedModesCount","splEvent","COMPLETED_MODES_TO_SPL_EVENT_TYPE_MAP","TSplEventsLottieType","src","audio","LOTTIE_MAP","StyledSpecialEventsText","jsx","LottieAnimation","splEventsLottieSettings"],"mappings":";;;;;;;AAeO,MAAMA,IAAgBC,EAAM,KAAK,CAAC,EAAE,gBAAAC,QAA0C;AAC7E,QAAA,EAAE,MAAAC,MAASC,KACXC,IAAsBH,EAAe,QAErCI,IACJC,EAAsCF,CAAmB,KAAKG,EAAqB,YAE/E,EAAE,KAAAC,GAAK,OAAAC,EAAM,IAAIC,EAAWL,CAAQ;AAE1C,2BACGM,GACC,EAAA,UAAA,gBAAAC;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,KAAAL;AAAA,MACA,UAAUM;AAAA,MACV,UAAU,MAAMZ,EAAKO,CAAuB;AAAA,IAAA;AAAA,EAEhD,EAAA,CAAA;AAEJ,CAAC;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"table-mode-styled.js","sources":["../../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/table-mode/table-mode-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport { GAME_LAUNCHER_SIZE } from '../../card-container/constants';\n\nexport const ModeContentSquareBlock = styled.div<{ $isBorderRightRequired?: boolean }>`\n border: 1px solid ${({ theme }) => theme.colors.WHITE};\n border-right-width: ${({ $isBorderRightRequired }) => ($isBorderRightRequired ? '1px' : '0px')};\n height: ${GAME_LAUNCHER_SIZE * 0.081}px;\n width: ${GAME_LAUNCHER_SIZE * 0.081}px;\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: ${({ theme }) => theme.colors.BLACK_1};\n position: relative;\n`;\n\nexport const TableModeLottieContainer = styled.div<{ $bottom?: string; $right?: string }>`\n position: absolute;\n height: auto;\n width: ${GAME_LAUNCHER_SIZE * 0.081}px;\n right: ${({ $right = '0px' }) => $right};\n bottom: ${({ $bottom = 'unset' }) => $bottom};\n`;\n"],"names":["ModeContentSquareBlock","styled","theme","$isBorderRightRequired","GAME_LAUNCHER_SIZE","TableModeLottieContainer","$right","$bottom"],"mappings":";;AAIO,MAAMA,IAAyBC,EAAO;AAAA,sBACvB,CAAC,EAAE,OAAAC,EAAA,MAAYA,EAAM,OAAO,KAAK;AAAA,wBAC/B,CAAC,EAAE,wBAAAC,EAAA,MAA8BA,IAAyB,QAAQ,KAAM;AAAA,YACpFC,IAAqB,KAAK;AAAA,WAC3BA,IAAqB,KAAK;AAAA;AAAA;AAAA;AAAA,sBAIf,CAAC,EAAE,OAAAF,EAAA,MAAYA,EAAM,OAAO,OAAO;AAAA;AAAA,GAI5CG,IAA2BJ,EAAO;AAAA;AAAA;AAAA,WAGpCG,IAAqB,KAAK;AAAA,WAC1B,CAAC,EAAE,QAAAE,IAAS,MAAA,MAAYA,CAAM;AAAA,YAC7B,CAAC,EAAE,SAAAC,IAAU,QAAA,MAAcA,CAAO;AAAA;"}
|
package/dist/features/circle-games/game-launcher-v2/comps/tables-card/table-mode/table-mode.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"table-mode.js","sources":["../../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/table-mode/table-mode.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { memo } from 'react';\n\nimport { LOTTIE } from '../../../../../../assets/lottie/lottie';\nimport FlexView from '../../../../../ui/layout/flex-view';\nimport LottieAnimation from '../../../../../ui/lottie-animation/lottie-animation';\nimport Separator from '../../../../../ui/separator/separator';\nimport Text from '../../../../../ui/text/text';\nimport type { TTableMode } from '../../../dal/use-get-circle-home-details-dal/use-get-circle-home-dal-types';\nimport { GAME_LAUNCHER_SIZE, GAME_LAUNCHER_SIZE_LARGE } from '../../card-container/constants';\nimport TableStar from '../table-mode-star/table-mode-star';\nimport * as Styled from './table-mode-styled';\nimport type { ITableModeProps } from './table-mode-types';\n\nconst LOAD_LOTTIE: Partial<Record<TTableMode, string>> = {\n sequence: LOTTIE.SEQUENCE_MODE_SEGMENT_LOTTIE,\n random: LOTTIE.RANDOM_MODE_SEGMENT_LOTTIE,\n advance: LOTTIE.ADVANCE_MODE_SEGMENT_LOTTIE,\n};\n\nconst settings = {\n renderer: 'svg',\n};\n\nconst TableMode: FC<ITableModeProps> = memo(({ tableNumber, isStarAchieved, type, rewardStar }) => {\n return (\n <FlexView $alignItems=\"center\">\n <TableStar isStarAchieved={isStarAchieved} rewardStar={rewardStar} />\n <Separator height={GAME_LAUNCHER_SIZE * 0.055} />\n <FlexView $flexDirection=\"row\">\n <Styled.ModeContentSquareBlock>\n <Text\n $renderAs={GAME_LAUNCHER_SIZE === GAME_LAUNCHER_SIZE_LARGE ? 'ac3-black' : 'ab2-bold'}\n $color=\"WHITE\"\n >\n {tableNumber}\n </Text>\n </Styled.ModeContentSquareBlock>\n <Styled.ModeContentSquareBlock>\n <Text\n $renderAs={GAME_LAUNCHER_SIZE === GAME_LAUNCHER_SIZE_LARGE ? 'ac3-black' : 'ab2-bold'}\n $color=\"WHITE\"\n >\n ×\n </Text>\n </Styled.ModeContentSquareBlock>\n <Styled.ModeContentSquareBlock $isBorderRightRequired={type === 'advance'}>\n <Styled.TableModeLottieContainer\n $bottom={type === 'advance' ? '-1px' : 'unset'}\n $right={type === 'advance' ? '-1px' : 'unset'}\n >\n <LottieAnimation src={LOAD_LOTTIE[type] ?? ''} settings={settings} />\n </Styled.TableModeLottieContainer>\n </Styled.ModeContentSquareBlock>\n </FlexView>\n </FlexView>\n );\n});\n\nexport default TableMode;\n"],"names":["LOAD_LOTTIE","LOTTIE","settings","TableMode","memo","tableNumber","isStarAchieved","type","rewardStar","jsxs","FlexView","jsx","TableStar","Separator","GAME_LAUNCHER_SIZE","Styled.ModeContentSquareBlock","Text","GAME_LAUNCHER_SIZE_LARGE","Styled.TableModeLottieContainer","LottieAnimation"],"mappings":";;;;;;;;;;AAcA,MAAMA,IAAmD;AAAA,EACvD,UAAUC,EAAO;AAAA,EACjB,QAAQA,EAAO;AAAA,EACf,SAASA,EAAO;AAClB,GAEMC,IAAW;AAAA,EACf,UAAU;AACZ,GAEMC,IAAiCC,EAAK,CAAC,EAAE,aAAAC,GAAa,gBAAAC,GAAgB,MAAAC,GAAM,YAAAC,QAE9E,gBAAAC,EAACC,GAAS,EAAA,aAAY,UACpB,UAAA;AAAA,EAAC,gBAAAC,EAAAC,GAAA,EAAU,gBAAAN,GAAgC,YAAAE,EAAwB,CAAA;AAAA,EAClE,gBAAAG,EAAAE,GAAA,EAAU,QAAQC,IAAqB,MAAO,CAAA;AAAA,EAC/C,gBAAAL,EAACC,GAAS,EAAA,gBAAe,OACvB,UAAA;AAAA,IAAC,gBAAAC,EAAAI,GAAA,EACC,UAAA,gBAAAJ;AAAA,MAACK;AAAA,MAAA;AAAA,QACC,WAAWF,MAAuBG,IAA2B,cAAc;AAAA,QAC3E,QAAO;AAAA,QAEN,UAAAZ;AAAA,MAAA;AAAA,IAAA,GAEL;AAAA,IACA,gBAAAM,EAACI,GAAA,EACC,UAAA,gBAAAJ;AAAA,MAACK;AAAA,MAAA;AAAA,QACC,WAAWF,MAAuBG,IAA2B,cAAc;AAAA,QAC3E,QAAO;AAAA,QACR,UAAA;AAAA,MAAA;AAAA,IAAA,GAGH;AAAA,sBACCF,GAAA,EAA8B,wBAAwBR,MAAS,WAC9D,UAAA,gBAAAI;AAAA,MAACO;AAAAA,MAAA;AAAA,QACC,SAASX,MAAS,YAAY,SAAS;AAAA,QACvC,QAAQA,MAAS,YAAY,SAAS;AAAA,QAEtC,4BAACY,GAAgB,EAAA,KAAKnB,EAAYO,CAAI,KAAK,IAAI,UAAAL,GAAoB;AAAA,MAAA;AAAA,IAAA,GAEvE;AAAA,EAAA,GACF;AACF,EAAA,CAAA,CAEH;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.js","sources":["../../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/table-mode-star/constants.ts"],"sourcesContent":["import { GAME_LAUNCHER_SIZE } from '../../card-container/constants';\n\nexport const STAR_SIZE = GAME_LAUNCHER_SIZE * 0.05;\n"],"names":["STAR_SIZE","GAME_LAUNCHER_SIZE"],"mappings":";AAEO,MAAMA,IAAYC,IAAqB;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"table-mode-star-styled.js","sources":["../../../../../../../src/features/circle-games/game-launcher-v2/comps/tables-card/table-mode-star/table-mode-star-styled.tsx"],"sourcesContent":["import type { TColorNames } from '../../../../../ui/types';\n\nimport styled from 'styled-components';\n\nimport { STAR_SIZE } from './constants';\n\nexport const StarContainer = styled.div`\n position: relative;\n height: ${STAR_SIZE}px;\n width: ${STAR_SIZE}px;\n display: flex;\n align-items: center;\n justify-content: center;\n`;\n\nexport const LottieContainer = styled.div`\n position: absolute;\n height: ${STAR_SIZE * 2}px;\n width: ${STAR_SIZE * 2}px;\n`;\n\nexport const Circle = styled.circle<{ $fill: TColorNames }>`\n fill: ${({ $fill, theme }) => theme.colors[$fill]};\n`;\n\nexport const Path = styled.path<{ $fill: TColorNames }>`\n fill: ${({ $fill, theme }) => theme.colors[$fill]};\n`;\n"],"names":["StarContainer","styled","STAR_SIZE","LottieContainer","Circle","$fill","theme","Path"],"mappings":";;AAMO,MAAMA,IAAgBC,EAAO;AAAA;AAAA,YAExBC,CAAS;AAAA,WACVA,CAAS;AAAA;AAAA;AAAA;AAAA,GAMPC,IAAkBF,EAAO;AAAA;AAAA,YAE1BC,IAAY,CAAC;AAAA,WACdA,IAAY,CAAC;AAAA,GAGXE,IAASH,EAAO;AAAA,UACnB,CAAC,EAAE,OAAAI,GAAO,OAAAC,EAAA,MAAYA,EAAM,OAAOD,CAAK,CAAC;AAAA,GAGtCE,IAAON,EAAO;AAAA,UACjB,CAAC,EAAE,OAAAI,GAAO,OAAAC,EAAA,MAAYA,EAAM,OAAOD,CAAK,CAAC;AAAA;"}
|