@streamlayer/react-ui 0.81.0 → 0.81.1

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.
@@ -15,6 +15,7 @@ interface FeedbackProps {
15
15
  votedInCurrentRender: boolean;
16
16
  votedAfterQuestionClosed: boolean;
17
17
  enteredAnActiveQuestion: boolean;
18
+ marketClosed: boolean;
18
19
  }
19
20
  export declare const Feedback: React.FC<FeedbackProps>;
20
21
  export {};
@@ -1,65 +1,66 @@
1
- import { jsxs as r, Fragment as o, jsx as i } from "react/jsx-runtime";
2
- import { QuestionType as t, QuestionStatus as R } from "@streamlayer/sdk-web-types";
1
+ import { jsxs as r, Fragment as t, jsx as i } from "react/jsx-runtime";
2
+ import { QuestionType as n, QuestionStatus as Q } from "@streamlayer/sdk-web-types";
3
3
  import { SvgIcon as l } from "../../../icons/index.js";
4
- import { Container as L, FeedbackIconWrap as h, FeedbackHeader as a, FeedbackDescription as d, FeedbackText as s, IconPrediction as N, FeedbackTitle as Q } from "./styles.js";
4
+ import { Container as f, FeedbackIconWrap as h, FeedbackHeader as p, FeedbackDescription as d, FeedbackText as s, IconPrediction as L, FeedbackTitle as j } from "./styles.js";
5
5
  import "@linaria/react";
6
6
  import "react";
7
- const Y = ({
7
+ const B = ({
8
8
  feedbackMessages: e,
9
- questionVotedCorrectly: P,
10
- questionVoted: m,
11
- questionType: n,
12
- hasCorrectAnswer: u,
13
- questionStatus: E,
14
- showExpiredNotification: I,
9
+ questionVotedCorrectly: I,
10
+ questionVoted: a,
11
+ questionType: c,
12
+ hasCorrectAnswer: F,
13
+ questionStatus: S,
14
+ showExpiredNotification: u,
15
15
  showClosedNotificationTrivia: w,
16
- votedInCurrentRender: p,
17
- votedAfterQuestionClosed: S,
18
- enteredAnActiveQuestion: x
16
+ votedInCurrentRender: m,
17
+ votedAfterQuestionClosed: y,
18
+ enteredAnActiveQuestion: E,
19
+ marketClosed: N
19
20
  }) => {
20
- const T = m && (n === t.TRIVIA || n === t.PREDICTION) && p && E !== R.RESOLVED, b = n === t.PREDICTION && !u, k = E === R.RESOLVED && n === t.PREDICTION && !m && !x || n === t.PREDICTION && S && p && x, D = T && b, O = T && u, y = m && n === t.POLL && p;
21
- if (!I && !w && !D && !O && !k && !y)
21
+ const b = a && (c === n.TRIVIA || c === n.PREDICTION) && m && S !== Q.RESOLVED, x = c === n.PREDICTION && !F, T = N && c === n.PREDICTION && !a && !E || c === n.PREDICTION && y && m && E, k = b && x, D = b && F, O = c === n.PREDICTION && a && m && F, R = a && c === n.POLL && m;
22
+ if (!u && !w && !k && !D && !T && !R && !O)
22
23
  return null;
23
- const F = P ? "correct" : "incorrect", c = P ? e == null ? void 0 : e.correctFeedback : e == null ? void 0 : e.incorrectFeedback;
24
- return /* @__PURE__ */ r(L, { "data-isPrediction": b, children: [
25
- I && /* @__PURE__ */ r(o, { children: [
24
+ const P = I ? "correct" : "incorrect", o = I ? e == null ? void 0 : e.correctFeedback : e == null ? void 0 : e.incorrectFeedback;
25
+ return /* @__PURE__ */ r(f, { "data-isPrediction": x, children: [
26
+ u && /* @__PURE__ */ r(t, { children: [
26
27
  /* @__PURE__ */ i(h, { children: /* @__PURE__ */ i(l, { name: "questionExpired" }) }),
27
28
  /* @__PURE__ */ r("div", { children: [
28
- /* @__PURE__ */ i(a, { children: /* @__PURE__ */ i(d, { children: "Question Expired" }) }),
29
+ /* @__PURE__ */ i(p, { children: /* @__PURE__ */ i(d, { children: "Question Expired" }) }),
29
30
  /* @__PURE__ */ i(s, { children: "You can still answer to see if you're correct, but no points are awarded for expired questions." })
30
31
  ] })
31
32
  ] }),
32
- w && /* @__PURE__ */ r(o, { children: [
33
+ w && /* @__PURE__ */ r(t, { children: [
33
34
  /* @__PURE__ */ i(h, { children: /* @__PURE__ */ i(l, { name: "questionExpired" }) }),
34
35
  /* @__PURE__ */ r("div", { children: [
35
- /* @__PURE__ */ i(a, { children: /* @__PURE__ */ i(d, { children: "Question Closed" }) }),
36
+ /* @__PURE__ */ i(p, { children: /* @__PURE__ */ i(d, { children: "Question Closed" }) }),
36
37
  /* @__PURE__ */ i(s, { children: "This question was answered after the moderator closed the question. So the points for this answer won’t tally." })
37
38
  ] })
38
39
  ] }),
39
- k && /* @__PURE__ */ r(o, { children: [
40
+ T && /* @__PURE__ */ r(t, { children: [
40
41
  /* @__PURE__ */ i(h, { children: /* @__PURE__ */ i(l, { name: "questionExpired" }) }),
41
42
  /* @__PURE__ */ r("div", { children: [
42
- /* @__PURE__ */ i(a, { children: /* @__PURE__ */ i(d, { children: "Question Closed" }) }),
43
+ /* @__PURE__ */ i(p, { children: /* @__PURE__ */ i(d, { children: "Question Closed" }) }),
43
44
  /* @__PURE__ */ i(s, { children: "This event has already taken place, so the ability to make a prediction on its outcome is no longer available." })
44
45
  ] })
45
46
  ] }),
46
- D && /* @__PURE__ */ r(o, { children: [
47
- /* @__PURE__ */ i(N, { name: "icon-prediction" }),
47
+ k && /* @__PURE__ */ r(t, { children: [
48
+ /* @__PURE__ */ i(L, { name: "icon-prediction" }),
48
49
  /* @__PURE__ */ i(d, { children: "Stay tuned to see if your prediction was correct." })
49
50
  ] }),
50
- y && /* @__PURE__ */ r(o, { children: [
51
+ R && /* @__PURE__ */ r(t, { children: [
51
52
  /* @__PURE__ */ i(h, { "data-feedbackType": "correct", children: /* @__PURE__ */ i(l, { name: "correct" }) }),
52
53
  /* @__PURE__ */ i(d, { children: "That's for answering. Please stay tuned for the next question." })
53
54
  ] }),
54
- O && /* @__PURE__ */ r(o, { children: [
55
- /* @__PURE__ */ i(h, { "data-feedbackType": F, children: /* @__PURE__ */ i(l, { name: F }) }),
56
- /* @__PURE__ */ i("div", { children: /* @__PURE__ */ r(a, { children: [
57
- /* @__PURE__ */ i(Q, { "data-feedbackType": F, children: c == null ? void 0 : c.title }),
58
- /* @__PURE__ */ i(d, { children: c == null ? void 0 : c.description })
55
+ (D || O) && /* @__PURE__ */ r(t, { children: [
56
+ /* @__PURE__ */ i(h, { "data-feedbackType": P, children: /* @__PURE__ */ i(l, { name: P }) }),
57
+ /* @__PURE__ */ i("div", { children: /* @__PURE__ */ r(p, { children: [
58
+ /* @__PURE__ */ i(j, { "data-feedbackType": P, children: o == null ? void 0 : o.title }),
59
+ /* @__PURE__ */ i(d, { children: o == null ? void 0 : o.description })
59
60
  ] }) })
60
61
  ] })
61
62
  ] });
62
63
  };
63
64
  export {
64
- Y as Feedback
65
+ B as Feedback
65
66
  };
@@ -1,12 +1,12 @@
1
- import { jsx as c, jsxs as D, Fragment as K } from "react/jsx-runtime";
2
- import { useState as l, useEffect as Y, useCallback as p, useMemo as m } from "react";
3
- import { QuestionStatus as V, QuestionType as o } from "@streamlayer/sdk-web-types";
4
- import { SDKScrollContainer as z } from "../../app/styles.js";
5
- import { ExpiredAlert as G } from "./expired-alert/index.js";
6
- import { Feedback as J } from "./feedback/index.js";
7
- import { Container as U, Content as X, Title as Z, Options as _ } from "./styles.js";
8
- import { VotingOption as $ } from "./vote-option/index.js";
9
- import { WinBar as Q } from "./win-bar/index.js";
1
+ import { jsx as a, jsxs as g, Fragment as Y } from "react/jsx-runtime";
2
+ import { useState as T, useEffect as z, useCallback as A, useMemo as o } from "react";
3
+ import { QuestionType as c, QuestionStatus as w } from "@streamlayer/sdk-web-types";
4
+ import { SDKScrollContainer as G } from "../../app/styles.js";
5
+ import { ExpiredAlert as J } from "./expired-alert/index.js";
6
+ import { Feedback as U } from "./feedback/index.js";
7
+ import { Container as X, Content as Z, Title as _, Options as $ } from "./styles.js";
8
+ import { VotingOption as Q } from "./vote-option/index.js";
9
+ import { WinBar as tt } from "./win-bar/index.js";
10
10
  import "@linaria/react";
11
11
  import "../../icons/index.js";
12
12
  import "./expired-alert/styles.js";
@@ -18,104 +18,106 @@ import "../../timer/index.js";
18
18
  import "react-countdown-circle-timer";
19
19
  import "../../theme/constants.js";
20
20
  import "./win-bar/styles.js";
21
- const pt = ({ openedQuestion: t, isLoading: y, vote: v, close: C }) => {
22
- var S, q;
23
- const g = t.subject, T = t.type, a = t.status, E = (S = t.options) == null ? void 0 : S.options, [d, b] = l(!1), [h, N] = l(!1), [n, P] = l(!0), [e, k] = l(!1), [u, x] = l(""), I = t == null ? void 0 : t.id;
24
- Y(() => {
25
- a === V.RESOLVED && P(!1);
21
+ const At = ({ openedQuestion: t, isLoading: I, vote: v, close: p }) => {
22
+ var D, k;
23
+ const N = t.subject, l = t.type, e = t.status, E = (D = t.options) == null ? void 0 : D.options, V = t.marketClosed, [R, P] = T(!1), [y, b] = T(!1), [n, u] = T(!0), [s, L] = T(!1), [x, O] = T(""), d = t == null ? void 0 : t.id;
24
+ z(() => {
25
+ l === c.PREDICTION ? V && u(!1) : e === w.RESOLVED && u(!1);
26
26
  }, []);
27
- const L = p((i) => {
28
- N(i), b(!0);
29
- }, []), R = p(
27
+ const M = A((i) => {
28
+ b(i), P(!0);
29
+ }, []), q = A(
30
30
  async (i) => {
31
- if (I) {
31
+ if (d) {
32
32
  const f = i.currentTarget.value;
33
- x(f), await v(I, f);
33
+ O(f), await v(d, f);
34
34
  }
35
35
  },
36
- [I, x, v]
37
- ), M = p(() => {
38
- k(!0), setTimeout(C, 3e3);
39
- }, [C]), r = m(
36
+ [d, O, v]
37
+ ), j = A(() => {
38
+ L(!0), setTimeout(p, 3e3);
39
+ }, [p]), r = o(
40
40
  () => t == null ? void 0 : t.answers.find((i) => i.youVoted === !0),
41
41
  [t]
42
- ), A = m(
42
+ ), h = o(
43
43
  () => !!(t != null && t.answers.find((i) => i.correct === !0)),
44
44
  [t]
45
- ), w = m(
45
+ ), C = o(
46
46
  () => t == null ? void 0 : t.answers.find((i) => i.correct === !0),
47
47
  [t]
48
- ), j = m(() => t ? t.answers.map((i) => {
48
+ ), B = o(() => t ? t.answers.map((i) => {
49
49
  var f;
50
50
  return {
51
51
  ...i,
52
52
  questionVoted: !!r,
53
- youSelected: u === i.id,
54
- isLoading: y,
55
- hasCorrectAnswer: A,
53
+ youSelected: x === i.id,
54
+ isLoading: I,
55
+ hasCorrectAnswer: h,
56
56
  questionType: t.type,
57
- answerTimeExpired: e,
58
- questionStatus: a,
57
+ answerTimeExpired: s,
58
+ questionStatus: e,
59
59
  imageMode: (f = t.appearance) == null ? void 0 : f.images,
60
- onVote: R
60
+ onVote: q
61
61
  };
62
62
  }) : [], [
63
- A,
64
- e,
65
- y,
63
+ h,
64
+ s,
65
+ I,
66
66
  t,
67
67
  r,
68
- a,
69
- R,
70
- u
71
- ]), B = E && (E.case === "trivia" || E.case === "prediction") ? E.value : void 0, s = a === V.RESOLVED && T === o.TRIVIA && !r && !n, O = T === o.TRIVIA && h && d && n, F = m(() => {
72
- if (!(s || e))
73
- return a === V.RESOLVED ? 0 : r ? r.correct ? r.points : 0 : w == null ? void 0 : w.points;
74
- }, [e, r, w, a, s]), W = m(() => s || e ? "Time expired" : t.type === o.POLL ? "Time remaining" : r ? "You won" : "To win", [e, t.type, r, s]), H = r || s || O || T === o.TRIVIA && a === V.RESOLVED && n;
75
- return /* @__PURE__ */ c(z, { "data-question-header": "true", children: /* @__PURE__ */ c(U, { children: /* @__PURE__ */ D(X, { children: [
76
- /* @__PURE__ */ c(
77
- J,
68
+ e,
69
+ q,
70
+ x
71
+ ]), F = E && (E.case === "trivia" || E.case === "prediction") ? E.value : void 0, m = e === w.RESOLVED && l === c.TRIVIA && !r && !n, S = l === c.TRIVIA && y && R && n, W = o(() => {
72
+ if (!(m || s))
73
+ return e === w.RESOLVED ? 0 : r ? r.correct ? r.points : 0 : C == null ? void 0 : C.points;
74
+ }, [s, r, C, e, m]), H = o(() => m || s ? "Time expired" : t.type === c.POLL ? "Time remaining" : r ? "You won" : "To win", [s, t.type, r, m]), K = r || m || S || l === c.TRIVIA && e === w.RESOLVED && n;
75
+ return /* @__PURE__ */ a(G, { "data-question-header": "true", children: /* @__PURE__ */ a(X, { children: /* @__PURE__ */ g(Z, { children: [
76
+ /* @__PURE__ */ a(
77
+ U,
78
78
  {
79
- feedbackMessages: B,
79
+ feedbackMessages: F,
80
80
  questionVoted: !!r,
81
81
  questionVotedCorrectly: r == null ? void 0 : r.correct,
82
- questionType: T,
83
- hasCorrectAnswer: A,
84
- questionStatus: a,
85
- showExpiredNotification: s,
86
- showClosedNotificationTrivia: O,
87
- votedInCurrentRender: d,
88
- votedAfterQuestionClosed: h,
89
- enteredAnActiveQuestion: n
82
+ questionType: l,
83
+ hasCorrectAnswer: h,
84
+ questionStatus: e,
85
+ showExpiredNotification: m,
86
+ showClosedNotificationTrivia: S,
87
+ votedInCurrentRender: R,
88
+ votedAfterQuestionClosed: y,
89
+ enteredAnActiveQuestion: n,
90
+ marketClosed: V
90
91
  }
91
92
  ),
92
- t.type !== o.PREDICTION && /* @__PURE__ */ c(
93
- Q,
93
+ t.type !== c.PREDICTION && /* @__PURE__ */ a(
94
+ tt,
94
95
  {
95
- title: W,
96
- points: F,
97
- onTimerExpired: M,
96
+ title: H,
97
+ points: W,
98
+ onTimerExpired: j,
98
99
  questionType: t.type,
99
- isTimer: !y,
100
+ isTimer: !I,
100
101
  isPlayingTimer: !r,
101
- timerDuration: H ? 0 : Number(((q = t == null ? void 0 : t.appearance) == null ? void 0 : q.autoHideInterval) || "30")
102
+ timerDuration: K ? 0 : Number(((k = t == null ? void 0 : t.appearance) == null ? void 0 : k.autoHideInterval) || "30")
102
103
  }
103
104
  ),
104
- e ? /* @__PURE__ */ c(
105
- G,
105
+ s ? /* @__PURE__ */ a(
106
+ J,
106
107
  {
107
108
  title: "More to come...",
108
109
  description: "Watch for additional enhanced stream interactive experience."
109
110
  }
110
- ) : /* @__PURE__ */ D(K, { children: [
111
- /* @__PURE__ */ c(Z, { "data-isPrediction": t.type === o.PREDICTION, children: g }),
112
- /* @__PURE__ */ c(_, { children: j.map((i) => /* @__PURE__ */ c(
113
- $,
111
+ ) : /* @__PURE__ */ g(Y, { children: [
112
+ /* @__PURE__ */ a(_, { "data-isPrediction": t.type === c.PREDICTION, children: N }),
113
+ /* @__PURE__ */ a($, { children: B.map((i) => /* @__PURE__ */ a(
114
+ Q,
114
115
  {
115
116
  ...i,
116
- markThatVoted: L,
117
- votedAfterQuestionClosed: h,
118
- enteredAnActiveQuestion: n
117
+ markThatVoted: M,
118
+ votedAfterQuestionClosed: y,
119
+ enteredAnActiveQuestion: n,
120
+ marketClosed: V
119
121
  },
120
122
  i.id
121
123
  )) })
@@ -123,5 +125,5 @@ const pt = ({ openedQuestion: t, isLoading: y, vote: v, close: C }) => {
123
125
  ] }) }) });
124
126
  };
125
127
  export {
126
- pt as Vote
128
+ At as Vote
127
129
  };
@@ -11,6 +11,7 @@ export type VotingOptionProps = ExtendedQuestionAnswer & {
11
11
  questionStatus: QuestionStatus;
12
12
  votedAfterQuestionClosed: boolean;
13
13
  enteredAnActiveQuestion: boolean;
14
+ marketClosed: boolean;
14
15
  onVote: (e: React.MouseEvent<HTMLButtonElement>) => void;
15
16
  markThatVoted: (votedAfterQuestionClosed: boolean) => void;
16
17
  };
@@ -1,76 +1,79 @@
1
- import { jsx as n, jsxs as f } from "react/jsx-runtime";
2
- import { QuestionImages as s, QuestionStatus as I, QuestionType as c } from "@streamlayer/sdk-web-types";
3
- import { AnimatedCounter as x } from "../../../animated-counter/index.js";
4
- import { IconDefault as L, IconContainer as Q, IconWrap as v, IconCircle as B, ButtonContainer as V, ButtonPct as b, ButtonBody as j, Title as U, Indicators as $, CheckIcon as M, Percentage as W } from "./styles.js";
1
+ import { jsx as r, jsxs as m } from "react/jsx-runtime";
2
+ import { QuestionImages as s, QuestionType as i, QuestionStatus as p } from "@streamlayer/sdk-web-types";
3
+ import { AnimatedCounter as L } from "../../../animated-counter/index.js";
4
+ import { IconDefault as Q, IconContainer as v, IconWrap as B, IconCircle as V, ButtonContainer as b, ButtonPct as j, ButtonBody as U, Title as $, Indicators as M, CheckIcon as W, Percentage as y } from "./styles.js";
5
5
  import "react-countup";
6
6
  import "@linaria/react";
7
7
  import "../../../icons/index.js";
8
8
  import "react";
9
- const m = {
10
- [s.CENTERED]: (t) => /* @__PURE__ */ n(L, { alt: "option-icon", src: t }),
11
- [s.TRANSPARENT]: (t) => /* @__PURE__ */ n(Q, { children: /* @__PURE__ */ n(v, { style: { backgroundImage: `url(${t})` } }) }),
12
- [s.ROUNDED]: (t) => /* @__PURE__ */ n(B, { alt: "option-icon", src: t }),
9
+ const I = {
10
+ [s.CENTERED]: (t) => /* @__PURE__ */ r(Q, { alt: "option-icon", src: t }),
11
+ [s.TRANSPARENT]: (t) => /* @__PURE__ */ r(v, { children: /* @__PURE__ */ r(B, { style: { backgroundImage: `url(${t})` } }) }),
12
+ [s.ROUNDED]: (t) => /* @__PURE__ */ r(V, { alt: "option-icon", src: t }),
13
13
  [s.NONE]: () => null,
14
14
  [s.UNSET]: () => null
15
- }, y = ({ questionType: t, hasCorrectAnswer: i, correct: e, youVoted: r, questionVoted: o }) => {
16
- if (t === c.POLL && r)
15
+ }, z = ({ questionType: t, hasCorrectAnswer: c, correct: e, youVoted: n, questionVoted: o }) => {
16
+ if (t === i.POLL && n)
17
17
  return "correct";
18
- if (t === c.PREDICTION) {
19
- if (i && o)
20
- return r ? e ? "correct" : "incorrect" : "unset";
21
- if (r)
18
+ if (t === i.PREDICTION) {
19
+ if (c && o)
20
+ return n ? e ? "correct" : "incorrect" : "unset";
21
+ if (n)
22
22
  return "correct";
23
23
  }
24
- return t === c.TRIVIA && o && r ? e ? "correct" : "incorrect" : "unset";
25
- }, z = ({
24
+ return t === i.TRIVIA && o && n ? e ? "correct" : "incorrect" : "unset";
25
+ }, F = ({
26
26
  questionType: t,
27
- questionVoted: i,
27
+ questionVoted: c,
28
28
  correct: e,
29
- hasCorrectAnswer: r,
29
+ hasCorrectAnswer: n,
30
30
  questionStatus: o
31
- }) => t === c.TRIVIA ? i && e : t === c.PREDICTION ? i && e && r || o === I.RESOLVED && e : !1, q = (t) => {
32
- var R;
31
+ }) => t === i.TRIVIA ? c && e : t === i.PREDICTION ? c && e && n || o === p.RESOLVED && e : !1, tt = (t) => {
32
+ var S;
33
33
  const {
34
34
  // option props
35
- id: i,
35
+ id: c,
36
36
  icon: e,
37
- text: r,
37
+ text: n,
38
38
  percentageDecimal: o,
39
39
  // extra props
40
- onVote: p,
40
+ onVote: T,
41
41
  markThatVoted: D,
42
- youSelected: E,
42
+ youSelected: f,
43
43
  questionVoted: a,
44
44
  // ToDo: Figure out why imageMode is not in the response, and delete default value
45
- imageMode: h,
46
- answerTimeExpired: T,
47
- questionStatus: d,
48
- isLoading: g,
49
- questionType: C,
50
- correct: w,
51
- hasCorrectAnswer: A,
52
- votedAfterQuestionClosed: O,
53
- enteredAnActiveQuestion: S
54
- } = t, l = y(t), P = z({ questionType: C, questionVoted: a, correct: w, hasCorrectAnswer: A, questionStatus: d }), u = d === I.RESOLVED && C === c.PREDICTION, N = a || u;
55
- return /* @__PURE__ */ f(
56
- V,
45
+ imageMode: C,
46
+ answerTimeExpired: g,
47
+ questionStatus: h,
48
+ isLoading: w,
49
+ questionType: d,
50
+ correct: A,
51
+ hasCorrectAnswer: O,
52
+ votedAfterQuestionClosed: P,
53
+ enteredAnActiveQuestion: E,
54
+ marketClosed: N
55
+ } = t, l = z(t), k = F({ questionType: d, questionVoted: a, correct: A, hasCorrectAnswer: O, questionStatus: h }), u = N && d === i.PREDICTION, R = a || u;
56
+ return /* @__PURE__ */ m(
57
+ b,
57
58
  {
58
- value: i,
59
- "data-selected": E,
59
+ value: c,
60
+ "data-selected": f,
60
61
  "data-answerState": l,
61
- disabled: a || g || T || u && !S || u && S && O,
62
- "data-isNotChecked": a && !E && l !== "incorrect",
63
- onClick: (k) => {
64
- D(d === I.RESOLVED), p(k);
62
+ disabled: a || w || g || u && !E || u && E && P,
63
+ "data-isNotChecked": a && !f && l !== "incorrect",
64
+ onClick: (x) => {
65
+ D(
66
+ d === i.PREDICTION ? N : h === p.RESOLVED
67
+ ), T(x);
65
68
  },
66
69
  children: [
67
- /* @__PURE__ */ n(b, { "data-answerState": l, style: { width: `${N ? o : 0}%` } }),
68
- /* @__PURE__ */ f(j, { children: [
69
- e && h && ((R = m[h]) == null ? void 0 : R.call(m, e)),
70
- /* @__PURE__ */ n(U, { children: r }),
71
- N && /* @__PURE__ */ f($, { children: [
72
- P && /* @__PURE__ */ n(M, { name: "selected" }),
73
- /* @__PURE__ */ n(W, { children: /* @__PURE__ */ n(x, { value: o, suffix: "%" }) })
70
+ /* @__PURE__ */ r(j, { "data-answerState": l, style: { width: `${R ? o : 0}%` } }),
71
+ /* @__PURE__ */ m(U, { children: [
72
+ e && C && ((S = I[C]) == null ? void 0 : S.call(I, e)),
73
+ /* @__PURE__ */ r($, { children: n }),
74
+ R && /* @__PURE__ */ m(M, { children: [
75
+ k && /* @__PURE__ */ r(W, { name: "selected" }),
76
+ /* @__PURE__ */ r(y, { children: /* @__PURE__ */ r(L, { value: o, suffix: "%" }) })
74
77
  ] })
75
78
  ] })
76
79
  ]
@@ -78,5 +81,5 @@ const m = {
78
81
  );
79
82
  };
80
83
  export {
81
- q as VotingOption
84
+ tt as VotingOption
82
85
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@streamlayer/react-ui",
3
- "version": "0.81.0",
3
+ "version": "0.81.1",
4
4
  "type": "module",
5
5
  "main": "./src/index.js",
6
6
  "typings": "./lib/index.d.ts",
@@ -92,6 +92,6 @@
92
92
  "vite-plugin-svgr": "^4.1.0",
93
93
  "vite-svg-loader": "^4.0.0",
94
94
  "vite-tsconfig-paths": "^4.2.1",
95
- "@streamlayer/react": "^0.33.0"
95
+ "@streamlayer/react": "^0.33.1"
96
96
  }
97
97
  }