@lanaco/lnc-react-ui 4.0.117 → 4.0.119

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.
@@ -1,4 +1,4 @@
1
- "use strict";const e=require("react/jsx-runtime"),h=require("react"),r=require("./index-BpbMKBf_.cjs"),q=require("./Chip.cjs"),v=require("./emotion-styled.browser.esm-BtEseadx.cjs"),T=require("./consts-goSZX3xP.cjs"),N=require("./useDetectMobile-zkbzoOGV.cjs"),j=require("./Icon.cjs"),P=require("./IconButton.cjs"),C=require("./Button.cjs"),M=v.styled.div`
1
+ "use strict";const e=require("react/jsx-runtime"),f=require("react"),n=require("./index-BpbMKBf_.cjs"),q=require("./Chip.cjs"),b=require("./emotion-styled.browser.esm-BtEseadx.cjs"),v=require("./consts-goSZX3xP.cjs"),N=require("./useDetectMobile-zkbzoOGV.cjs"),j=require("./Icon.cjs"),P=require("./IconButton.cjs"),C=require("./Button.cjs"),M=b.styled.div`
2
2
  display: flex;
3
3
  gap: 0.75rem;
4
4
  align-items: center;
@@ -34,7 +34,7 @@
34
34
  }
35
35
  }
36
36
 
37
- @media (max-width: ${T.MOBILE_SIZE_PX+"px"}) {
37
+ @media (max-width: ${v.MOBILE_SIZE_PX+"px"}) {
38
38
  width: 100%;
39
39
  overflow-x: auto;
40
40
  white-space: nowrap;
@@ -53,7 +53,7 @@
53
53
  /* Safari and Chrome */
54
54
  }
55
55
  }
56
- `,E=v.styled.div`
56
+ `,E=b.styled.div`
57
57
  display: flex;
58
58
  gap: 1.25rem;
59
59
  width: 100%;
@@ -78,10 +78,10 @@
78
78
  }
79
79
  }
80
80
 
81
- @media (max-width: ${T.MOBILE_SIZE_PX+"px"}) {
81
+ @media (max-width: ${v.MOBILE_SIZE_PX+"px"}) {
82
82
  flex-direction: column;
83
83
  }
84
- `,$=v.styled.div`
84
+ `,$=b.styled.div`
85
85
  width: 100%;
86
86
  height: fit-content;
87
87
  background: var(--white, #fff);
@@ -161,7 +161,7 @@
161
161
  }
162
162
  }
163
163
 
164
- @media (max-width: ${T.MOBILE_SIZE_PX+"px"}) {
164
+ @media (max-width: ${v.MOBILE_SIZE_PX+"px"}) {
165
165
  & .card__impression {
166
166
  justify-content: space-between;
167
167
 
@@ -170,7 +170,7 @@
170
170
  }
171
171
  }
172
172
  }
173
- `,I=h.forwardRef(({tags:s=[],selectedTagCode:a=null,onSelectTag:l=()=>{}},g)=>e.jsx(M,{children:s==null?void 0:s.map((t,d)=>e.jsx(q,{label:t==null?void 0:t.name,borderRadius:"curved",color:"neutral",className:`tags__item ${a===(t==null?void 0:t.code)?"active":""}`,onClick:()=>{l(t)}},`faq-section-tag__${d+1}`))}));I.propTypes={tags:r.PropTypes.array,onSelectTag:r.PropTypes.func};const b=({title:s,description:a,questionText:l,feedbackText:g,impressions:t=!1,onSelectItem:d=()=>{},onImpressed:u=()=>{}})=>{const[p,_]=h.useState(!1),[m,x]=h.useState(!1),f=()=>{_(o=>!o),d()},i=(o,c)=>{o==null||o.stopPropagation(),x(!0),u(c)};return e.jsxs($,{className:p?"expanded":"",onClick:f,children:[e.jsxs("div",{className:"card__heading",children:[e.jsx("div",{className:"card__title",children:s}),e.jsx(j,{icon:p?" mng-lnc-subtract":" mng-lnc-add",sizeInUnits:"1.25rem",className:"card__icon"})]}),p&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"card__description",children:a}),t&&e.jsx(e.Fragment,{children:m?e.jsxs("div",{className:"card__impression feedback",children:[e.jsx(j,{icon:" mng-lnc-checkmark--outline",sizeInUnits:"1.25rem",color:"success"}),e.jsx("div",{className:"imppression__question",children:g})]}):e.jsxs("div",{className:"card__impression",children:[e.jsx("div",{className:"imppression__question",children:l}),e.jsxs("div",{className:"impression__actions",children:[e.jsx(P,{icon:" mng-lnc-thumbs-up",borderRadius:"curved",btnType:"outline",onClick:o=>i(o,!0)}),e.jsx(P,{icon:" mng-lnc-thumbs-down",borderRadius:"curved",btnType:"outline",onClick:o=>i(o,!1)})]})]})})]})]})},S=h.forwardRef(({items:s=[],questionText:a,feedbackText:l,showMoreText:g,impressions:t=!1,onSelectItem:d=()=>{},onImpressed:u=()=>{}},p)=>{const _=N.useDetectMobile(),[m,x]=h.useState(!1),f=()=>{x(o=>!o)},i=h.useMemo(()=>{if(_)return s==null?void 0:s.map((n,y)=>e.jsx(b,{title:n==null?void 0:n.title,description:n==null?void 0:n.description,questionText:a,feedbackText:l,impressions:t,onSelectItem:()=>d(n),onImpressed:w=>u(n,w)},`faq-section-item__${y+1}`));const o=[],c=[];return s==null||s.forEach((n,y)=>{y%2===0?o.push(e.jsx(b,{title:n==null?void 0:n.title,description:n==null?void 0:n.description,questionText:a,feedbackText:l,impressions:t,onSelectItem:()=>d(n),onImpressed:w=>u(n,w)},`faq-section-item__${y+1}`)):c.push(e.jsx(b,{title:n==null?void 0:n.title,description:n==null?void 0:n.description,questionText:a,feedbackText:l,impressions:t,onSelectItem:()=>d(n),onImpressed:w=>u(n,w)},`faq-section-item__${y+1}`))}),e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"section__column",children:o}),e.jsx("div",{className:"section__column",children:c})]})},[s,_]);return e.jsx(E,{children:_?m?i:e.jsxs(e.Fragment,{children:[i==null?void 0:i.slice(0,4),(i==null?void 0:i.length)>4&&e.jsx(C,{text:g,btnType:"basic",color:"neutral",className:"section__show-more",onClick:f})]}):i})});b.propTypes={title:r.PropTypes.string,description:r.PropTypes.string,questionText:r.PropTypes.string,feedbackText:r.PropTypes.string,showMoreText:r.PropTypes.string,impressions:r.PropTypes.bool,onSelectItem:r.PropTypes.func,onImpressed:r.PropTypes.func};S.propTypes={items:r.PropTypes.array,questionText:r.PropTypes.string,feedbackText:r.PropTypes.string,showMoreText:r.PropTypes.string,impressions:r.PropTypes.bool,onSelectItem:r.PropTypes.func,onImpressed:r.PropTypes.func};const F=v.styled.div`
173
+ `,I=f.forwardRef(({tags:i=[],allTagText:c,selectedTagCode:l=null,onSelectTag:h=()=>{}},d)=>e.jsx(M,{children:[{name:c,code:null},...i].map((t,p)=>e.jsx(q,{label:t==null?void 0:t.name,borderRadius:"curved",color:"neutral",className:`tags__item ${l===(t==null?void 0:t.code)?"active":""}`,onClick:()=>{h(t)}},`faq-section-tag__${p+1}`))}));I.propTypes={tags:n.PropTypes.array,allTagText:n.PropTypes.string,onSelectTag:n.PropTypes.func};const w=({title:i,description:c,questionText:l,feedbackText:h,impressions:d=!1,onSelectItem:t=()=>{},onImpressed:p=()=>{}})=>{const[u,a]=f.useState(!1),[_,m]=f.useState(!1),x=()=>{a(o=>!o),t()},s=(o,g)=>{o==null||o.stopPropagation(),m(!0),p(g)};return e.jsxs($,{className:u?"expanded":"",onClick:x,children:[e.jsxs("div",{className:"card__heading",children:[e.jsx("div",{className:"card__title",children:i}),e.jsx(j,{icon:u?" mng-lnc-subtract":" mng-lnc-add",sizeInUnits:"1.25rem",className:"card__icon"})]}),u&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"card__description",children:c}),d&&e.jsx(e.Fragment,{children:_?e.jsxs("div",{className:"card__impression feedback",children:[e.jsx(j,{icon:" mng-lnc-checkmark--outline",sizeInUnits:"1.25rem",color:"success"}),e.jsx("div",{className:"imppression__question",children:h})]}):e.jsxs("div",{className:"card__impression",children:[e.jsx("div",{className:"imppression__question",children:l}),e.jsxs("div",{className:"impression__actions",children:[e.jsx(P,{icon:" mng-lnc-thumbs-up",borderRadius:"curved",btnType:"outline",onClick:o=>s(o,!0)}),e.jsx(P,{icon:" mng-lnc-thumbs-down",borderRadius:"curved",btnType:"outline",onClick:o=>s(o,!1)})]})]})})]})]})},S=f.forwardRef(({items:i=[],questionText:c,feedbackText:l,showMoreText:h,impressions:d=!1,onSelectItem:t=()=>{},onImpressed:p=()=>{}},u)=>{const a=N.useDetectMobile(),[_,m]=f.useState(!1),x=()=>{m(o=>!o)},s=f.useMemo(()=>{if(a)return i==null?void 0:i.map((r,y)=>e.jsx(w,{title:r==null?void 0:r.title,description:r==null?void 0:r.description,questionText:c,feedbackText:l,impressions:d,onSelectItem:()=>t(r),onImpressed:T=>p(r,T)},`faq-section-item__${y+1}`));const o=[],g=[];return i==null||i.forEach((r,y)=>{y%2===0?o.push(e.jsx(w,{title:r==null?void 0:r.title,description:r==null?void 0:r.description,questionText:c,feedbackText:l,impressions:d,onSelectItem:()=>t(r),onImpressed:T=>p(r,T)},`faq-section-item__${y+1}`)):g.push(e.jsx(w,{title:r==null?void 0:r.title,description:r==null?void 0:r.description,questionText:c,feedbackText:l,impressions:d,onSelectItem:()=>t(r),onImpressed:T=>p(r,T)},`faq-section-item__${y+1}`))}),e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"section__column",children:o}),e.jsx("div",{className:"section__column",children:g})]})},[i,a]);return e.jsx(E,{children:a?_?s:e.jsxs(e.Fragment,{children:[s==null?void 0:s.slice(0,4),(s==null?void 0:s.length)>4&&e.jsx(C,{text:h,btnType:"basic",color:"neutral",className:"section__show-more",onClick:x})]}):s})});w.propTypes={title:n.PropTypes.string,description:n.PropTypes.string,questionText:n.PropTypes.string,feedbackText:n.PropTypes.string,showMoreText:n.PropTypes.string,impressions:n.PropTypes.bool,onSelectItem:n.PropTypes.func,onImpressed:n.PropTypes.func};S.propTypes={items:n.PropTypes.array,questionText:n.PropTypes.string,feedbackText:n.PropTypes.string,showMoreText:n.PropTypes.string,impressions:n.PropTypes.bool,onSelectItem:n.PropTypes.func,onImpressed:n.PropTypes.func};const F=b.styled.div`
174
174
  display: flex;
175
175
  flex-direction: column;
176
176
  align-items: center;
@@ -202,7 +202,7 @@
202
202
  line-height: 1.5rem;
203
203
  }
204
204
 
205
- @media (max-width: ${T.MOBILE_SIZE_PX+"px"}) {
205
+ @media (max-width: ${v.MOBILE_SIZE_PX+"px"}) {
206
206
  & .section__title {
207
207
  font-size: 1rem;
208
208
  font-weight: 500;
@@ -216,4 +216,4 @@
216
216
  letter-spacing: 0.25px;
217
217
  }
218
218
  }
219
- `,k=h.forwardRef(({title:s,description:a,questionText:l="What do you think about this answer?",feedbackText:g="Thank you for feedback!",showMoreText:t="Show more",impressions:d=!1,tags:u=[],items:p=[],onSelectItem:_=()=>{},onImpressed:m=()=>{}},x)=>{const[f,i]=h.useState(null),o=c=>{i(c==null?void 0:c.code)};return e.jsxs(F,{ref:x,children:[e.jsxs("div",{className:"section__heading",children:[s&&e.jsx("div",{className:"section__title",children:s}),a&&e.jsx("div",{className:"section__description",children:a})]}),e.jsx(I,{tags:u,selectedTagCode:f,onSelectTag:o}),e.jsx(S,{items:f===null?p:p==null?void 0:p.filter(c=>(c==null?void 0:c.tagCode)===f),questionText:l,feedbackText:g,showMoreText:t,impressions:d,onSelectItem:_,onImpressed:m},`faq-section-items__${f}`)]})});k.propTypes={title:r.PropTypes.string,description:r.PropTypes.string,tags:r.PropTypes.array,items:r.PropTypes.array,questionText:r.PropTypes.string,feedbackText:r.PropTypes.string,showMoreText:r.PropTypes.string,impressions:r.PropTypes.bool,onSelectItem:r.PropTypes.func,onImpressed:r.PropTypes.func};module.exports=k;
219
+ `,k=f.forwardRef(({title:i,description:c,questionText:l="What do you think about this answer?",feedbackText:h="Thank you for feedback!",showMoreText:d="Show more",allTagText:t="All",impressions:p=!1,tags:u=[],items:a=[],onSelectItem:_=()=>{},onImpressed:m=()=>{}},x)=>{const[s,o]=f.useState(null),g=r=>{o(r==null?void 0:r.code)};return e.jsxs(F,{ref:x,children:[e.jsxs("div",{className:"section__heading",children:[i&&e.jsx("div",{className:"section__title",children:i}),c&&e.jsx("div",{className:"section__description",children:c})]}),e.jsx(I,{tags:u,allTagText:t,selectedTagCode:s,onSelectTag:g}),e.jsx(S,{items:s===null?a:a==null?void 0:a.filter(r=>(r==null?void 0:r.tagCode)===s),questionText:l,feedbackText:h,showMoreText:d,impressions:p,onSelectItem:_,onImpressed:m},`faq-section-items__${s}`)]})});k.propTypes={title:n.PropTypes.string,description:n.PropTypes.string,tags:n.PropTypes.array,items:n.PropTypes.array,questionText:n.PropTypes.string,feedbackText:n.PropTypes.string,showMoreText:n.PropTypes.string,allTagText:n.PropTypes.string,impressions:n.PropTypes.bool,onSelectItem:n.PropTypes.func,onImpressed:n.PropTypes.func};module.exports=k;
@@ -1,14 +1,14 @@
1
- import { jsx as r, jsxs as l, Fragment as x } from "react/jsx-runtime";
2
- import { forwardRef as S, useState as k, useMemo as $ } from "react";
3
- import { P as e } from "./index-CblbdqjE.js";
1
+ import { jsx as r, jsxs as l, Fragment as y } from "react/jsx-runtime";
2
+ import { forwardRef as S, useState as T, useMemo as $ } from "react";
3
+ import { P as n } from "./index-CblbdqjE.js";
4
4
  import z from "./Chip.js";
5
- import { s as T } from "./emotion-styled.browser.esm-BNN1dTl3.js";
5
+ import { s as k } from "./emotion-styled.browser.esm-BNN1dTl3.js";
6
6
  import { M as I } from "./consts-BuFChS64.js";
7
7
  import { u as E } from "./useDetectMobile-Bkvj0VMa.js";
8
8
  import N from "./Icon.js";
9
9
  import C from "./IconButton.js";
10
10
  import F from "./Button.js";
11
- const j = T.div`
11
+ const j = k.div`
12
12
  display: flex;
13
13
  gap: 0.75rem;
14
14
  align-items: center;
@@ -63,7 +63,7 @@ const j = T.div`
63
63
  /* Safari and Chrome */
64
64
  }
65
65
  }
66
- `, P = T.div`
66
+ `, P = k.div`
67
67
  display: flex;
68
68
  gap: 1.25rem;
69
69
  width: 100%;
@@ -91,7 +91,7 @@ const j = T.div`
91
91
  @media (max-width: ${I + "px"}) {
92
92
  flex-direction: column;
93
93
  }
94
- `, R = T.div`
94
+ `, R = k.div`
95
95
  width: 100%;
96
96
  height: fit-content;
97
97
  background: var(--white, #fff);
@@ -181,61 +181,62 @@ const j = T.div`
181
181
  }
182
182
  }
183
183
  `, q = S(
184
- ({ tags: o = [], selectedTagCode: c = null, onSelectTag: d = () => {
185
- } }, u) => /* @__PURE__ */ r(j, { children: o == null ? void 0 : o.map((t, f) => /* @__PURE__ */ r(
184
+ ({ tags: s = [], allTagText: a, selectedTagCode: d = null, onSelectTag: h = () => {
185
+ } }, p) => /* @__PURE__ */ r(j, { children: [{ name: a, code: null }, ...s].map((i, f) => /* @__PURE__ */ r(
186
186
  z,
187
187
  {
188
- label: t == null ? void 0 : t.name,
188
+ label: i == null ? void 0 : i.name,
189
189
  borderRadius: "curved",
190
190
  color: "neutral",
191
- className: `tags__item ${c === (t == null ? void 0 : t.code) ? "active" : ""}`,
191
+ className: `tags__item ${d === (i == null ? void 0 : i.code) ? "active" : ""}`,
192
192
  onClick: () => {
193
- d(t);
193
+ h(i);
194
194
  }
195
195
  },
196
196
  `faq-section-tag__${f + 1}`
197
197
  )) })
198
198
  );
199
199
  q.propTypes = {
200
- tags: e.array,
201
- onSelectTag: e.func
200
+ tags: n.array,
201
+ allTagText: n.string,
202
+ onSelectTag: n.func
202
203
  };
203
- const y = ({
204
- title: o,
205
- description: c,
204
+ const b = ({
205
+ title: s,
206
+ description: a,
206
207
  questionText: d,
207
- feedbackText: u,
208
- impressions: t = !1,
209
- onSelectItem: f = () => {
208
+ feedbackText: h,
209
+ impressions: p = !1,
210
+ onSelectItem: i = () => {
210
211
  },
211
- onImpressed: m = () => {
212
+ onImpressed: f = () => {
212
213
  }
213
214
  }) => {
214
- const [p, g] = k(!1), [_, w] = k(!1), h = () => {
215
- g((i) => !i), f();
216
- }, s = (i, a) => {
217
- i == null || i.stopPropagation(), w(!0), m(a);
215
+ const [m, c] = T(!1), [g, u] = T(!1), _ = () => {
216
+ c((t) => !t), i();
217
+ }, o = (t, w) => {
218
+ t == null || t.stopPropagation(), u(!0), f(w);
218
219
  };
219
220
  return /* @__PURE__ */ l(
220
221
  R,
221
222
  {
222
- className: p ? "expanded" : "",
223
- onClick: h,
223
+ className: m ? "expanded" : "",
224
+ onClick: _,
224
225
  children: [
225
226
  /* @__PURE__ */ l("div", { className: "card__heading", children: [
226
- /* @__PURE__ */ r("div", { className: "card__title", children: o }),
227
+ /* @__PURE__ */ r("div", { className: "card__title", children: s }),
227
228
  /* @__PURE__ */ r(
228
229
  N,
229
230
  {
230
- icon: p ? " mng-lnc-subtract" : " mng-lnc-add",
231
+ icon: m ? " mng-lnc-subtract" : " mng-lnc-add",
231
232
  sizeInUnits: "1.25rem",
232
233
  className: "card__icon"
233
234
  }
234
235
  )
235
236
  ] }),
236
- p && /* @__PURE__ */ l(x, { children: [
237
- /* @__PURE__ */ r("div", { className: "card__description", children: c }),
238
- t && /* @__PURE__ */ r(x, { children: _ ? /* @__PURE__ */ l("div", { className: "card__impression feedback", children: [
237
+ m && /* @__PURE__ */ l(y, { children: [
238
+ /* @__PURE__ */ r("div", { className: "card__description", children: a }),
239
+ p && /* @__PURE__ */ r(y, { children: g ? /* @__PURE__ */ l("div", { className: "card__impression feedback", children: [
239
240
  /* @__PURE__ */ r(
240
241
  N,
241
242
  {
@@ -244,7 +245,7 @@ const y = ({
244
245
  color: "success"
245
246
  }
246
247
  ),
247
- /* @__PURE__ */ r("div", { className: "imppression__question", children: u })
248
+ /* @__PURE__ */ r("div", { className: "imppression__question", children: h })
248
249
  ] }) : /* @__PURE__ */ l("div", { className: "card__impression", children: [
249
250
  /* @__PURE__ */ r("div", { className: "imppression__question", children: d }),
250
251
  /* @__PURE__ */ l("div", { className: "impression__actions", children: [
@@ -254,7 +255,7 @@ const y = ({
254
255
  icon: " mng-lnc-thumbs-up",
255
256
  borderRadius: "curved",
256
257
  btnType: "outline",
257
- onClick: (i) => s(i, !0)
258
+ onClick: (t) => o(t, !0)
258
259
  }
259
260
  ),
260
261
  /* @__PURE__ */ r(
@@ -263,7 +264,7 @@ const y = ({
263
264
  icon: " mng-lnc-thumbs-down",
264
265
  borderRadius: "curved",
265
266
  btnType: "outline",
266
- onClick: (i) => s(i, !1)
267
+ onClick: (t) => o(t, !1)
267
268
  }
268
269
  )
269
270
  ] })
@@ -274,104 +275,104 @@ const y = ({
274
275
  );
275
276
  }, M = S(
276
277
  ({
277
- items: o = [],
278
- questionText: c,
278
+ items: s = [],
279
+ questionText: a,
279
280
  feedbackText: d,
280
- showMoreText: u,
281
- impressions: t = !1,
282
- onSelectItem: f = () => {
281
+ showMoreText: h,
282
+ impressions: p = !1,
283
+ onSelectItem: i = () => {
283
284
  },
284
- onImpressed: m = () => {
285
+ onImpressed: f = () => {
285
286
  }
286
- }, p) => {
287
- const g = E(), [_, w] = k(!1), h = () => {
288
- w((i) => !i);
289
- }, s = $(() => {
290
- if (g)
291
- return o == null ? void 0 : o.map((n, v) => /* @__PURE__ */ r(
292
- y,
287
+ }, m) => {
288
+ const c = E(), [g, u] = T(!1), _ = () => {
289
+ u((t) => !t);
290
+ }, o = $(() => {
291
+ if (c)
292
+ return s == null ? void 0 : s.map((e, v) => /* @__PURE__ */ r(
293
+ b,
293
294
  {
294
- title: n == null ? void 0 : n.title,
295
- description: n == null ? void 0 : n.description,
296
- questionText: c,
295
+ title: e == null ? void 0 : e.title,
296
+ description: e == null ? void 0 : e.description,
297
+ questionText: a,
297
298
  feedbackText: d,
298
- impressions: t,
299
- onSelectItem: () => f(n),
300
- onImpressed: (b) => m(n, b)
299
+ impressions: p,
300
+ onSelectItem: () => i(e),
301
+ onImpressed: (x) => f(e, x)
301
302
  },
302
303
  `faq-section-item__${v + 1}`
303
304
  ));
304
- const i = [], a = [];
305
- return o == null || o.forEach((n, v) => {
306
- v % 2 === 0 ? i.push(
305
+ const t = [], w = [];
306
+ return s == null || s.forEach((e, v) => {
307
+ v % 2 === 0 ? t.push(
307
308
  /* @__PURE__ */ r(
308
- y,
309
+ b,
309
310
  {
310
- title: n == null ? void 0 : n.title,
311
- description: n == null ? void 0 : n.description,
312
- questionText: c,
311
+ title: e == null ? void 0 : e.title,
312
+ description: e == null ? void 0 : e.description,
313
+ questionText: a,
313
314
  feedbackText: d,
314
- impressions: t,
315
- onSelectItem: () => f(n),
316
- onImpressed: (b) => m(n, b)
315
+ impressions: p,
316
+ onSelectItem: () => i(e),
317
+ onImpressed: (x) => f(e, x)
317
318
  },
318
319
  `faq-section-item__${v + 1}`
319
320
  )
320
- ) : a.push(
321
+ ) : w.push(
321
322
  /* @__PURE__ */ r(
322
- y,
323
+ b,
323
324
  {
324
- title: n == null ? void 0 : n.title,
325
- description: n == null ? void 0 : n.description,
326
- questionText: c,
325
+ title: e == null ? void 0 : e.title,
326
+ description: e == null ? void 0 : e.description,
327
+ questionText: a,
327
328
  feedbackText: d,
328
- impressions: t,
329
- onSelectItem: () => f(n),
330
- onImpressed: (b) => m(n, b)
329
+ impressions: p,
330
+ onSelectItem: () => i(e),
331
+ onImpressed: (x) => f(e, x)
331
332
  },
332
333
  `faq-section-item__${v + 1}`
333
334
  )
334
335
  );
335
- }), /* @__PURE__ */ l(x, { children: [
336
- /* @__PURE__ */ r("div", { className: "section__column", children: i }),
337
- /* @__PURE__ */ r("div", { className: "section__column", children: a })
336
+ }), /* @__PURE__ */ l(y, { children: [
337
+ /* @__PURE__ */ r("div", { className: "section__column", children: t }),
338
+ /* @__PURE__ */ r("div", { className: "section__column", children: w })
338
339
  ] });
339
- }, [o, g]);
340
- return /* @__PURE__ */ r(P, { children: g ? _ ? s : /* @__PURE__ */ l(x, { children: [
341
- s == null ? void 0 : s.slice(0, 4),
342
- (s == null ? void 0 : s.length) > 4 && /* @__PURE__ */ r(
340
+ }, [s, c]);
341
+ return /* @__PURE__ */ r(P, { children: c ? g ? o : /* @__PURE__ */ l(y, { children: [
342
+ o == null ? void 0 : o.slice(0, 4),
343
+ (o == null ? void 0 : o.length) > 4 && /* @__PURE__ */ r(
343
344
  F,
344
345
  {
345
- text: u,
346
+ text: h,
346
347
  btnType: "basic",
347
348
  color: "neutral",
348
349
  className: "section__show-more",
349
- onClick: h
350
+ onClick: _
350
351
  }
351
352
  )
352
- ] }) : s });
353
+ ] }) : o });
353
354
  }
354
355
  );
355
- y.propTypes = {
356
- title: e.string,
357
- description: e.string,
358
- questionText: e.string,
359
- feedbackText: e.string,
360
- showMoreText: e.string,
361
- impressions: e.bool,
362
- onSelectItem: e.func,
363
- onImpressed: e.func
356
+ b.propTypes = {
357
+ title: n.string,
358
+ description: n.string,
359
+ questionText: n.string,
360
+ feedbackText: n.string,
361
+ showMoreText: n.string,
362
+ impressions: n.bool,
363
+ onSelectItem: n.func,
364
+ onImpressed: n.func
364
365
  };
365
366
  M.propTypes = {
366
- items: e.array,
367
- questionText: e.string,
368
- feedbackText: e.string,
369
- showMoreText: e.string,
370
- impressions: e.bool,
371
- onSelectItem: e.func,
372
- onImpressed: e.func
367
+ items: n.array,
368
+ questionText: n.string,
369
+ feedbackText: n.string,
370
+ showMoreText: n.string,
371
+ impressions: n.bool,
372
+ onSelectItem: n.func,
373
+ onImpressed: n.func
373
374
  };
374
- const B = T.div`
375
+ const B = k.div`
375
376
  display: flex;
376
377
  flex-direction: column;
377
378
  align-items: center;
@@ -419,62 +420,65 @@ const B = T.div`
419
420
  }
420
421
  `, U = S(
421
422
  ({
422
- title: o,
423
- description: c,
423
+ title: s,
424
+ description: a,
424
425
  questionText: d = "What do you think about this answer?",
425
- feedbackText: u = "Thank you for feedback!",
426
- showMoreText: t = "Show more",
426
+ feedbackText: h = "Thank you for feedback!",
427
+ showMoreText: p = "Show more",
428
+ allTagText: i = "All",
427
429
  impressions: f = !1,
428
430
  tags: m = [],
429
- items: p = [],
431
+ items: c = [],
430
432
  onSelectItem: g = () => {
431
433
  },
432
- onImpressed: _ = () => {
434
+ onImpressed: u = () => {
433
435
  }
434
- }, w) => {
435
- const [h, s] = k(null);
436
- return /* @__PURE__ */ l(B, { ref: w, children: [
436
+ }, _) => {
437
+ const [o, t] = T(null);
438
+ return /* @__PURE__ */ l(B, { ref: _, children: [
437
439
  /* @__PURE__ */ l("div", { className: "section__heading", children: [
438
- o && /* @__PURE__ */ r("div", { className: "section__title", children: o }),
439
- c && /* @__PURE__ */ r("div", { className: "section__description", children: c })
440
+ s && /* @__PURE__ */ r("div", { className: "section__title", children: s }),
441
+ a && /* @__PURE__ */ r("div", { className: "section__description", children: a })
440
442
  ] }),
441
443
  /* @__PURE__ */ r(
442
444
  q,
443
445
  {
444
446
  tags: m,
445
- selectedTagCode: h,
446
- onSelectTag: (a) => {
447
- s(a == null ? void 0 : a.code);
447
+ allTagText: i,
448
+ selectedTagCode: o,
449
+ onSelectTag: (e) => {
450
+ t(e == null ? void 0 : e.code);
448
451
  }
449
452
  }
450
453
  ),
451
454
  /* @__PURE__ */ r(
452
455
  M,
453
456
  {
454
- items: h === null ? p : p == null ? void 0 : p.filter((a) => (a == null ? void 0 : a.tagCode) === h),
457
+ items: o === null ? c : c == null ? void 0 : c.filter((e) => (e == null ? void 0 : e.tagCode) === o),
455
458
  questionText: d,
456
- feedbackText: u,
457
- showMoreText: t,
459
+ feedbackText: h,
460
+ showMoreText: p,
458
461
  impressions: f,
459
462
  onSelectItem: g,
460
- onImpressed: _
463
+ onImpressed: u
461
464
  },
462
- `faq-section-items__${h}`
465
+ `faq-section-items__${o}`
463
466
  )
464
467
  ] });
465
468
  }
466
469
  );
467
470
  U.propTypes = {
468
- title: e.string,
469
- description: e.string,
470
- tags: e.array,
471
- items: e.array,
472
- questionText: e.string,
473
- feedbackText: e.string,
474
- showMoreText: e.string,
475
- impressions: e.bool,
476
- onSelectItem: e.func,
477
- onImpressed: e.func
471
+ title: n.string,
472
+ description: n.string,
473
+ tags: n.array,
474
+ items: n.array,
475
+ questionText: n.string,
476
+ feedbackText: n.string,
477
+ showMoreText: n.string,
478
+ allTagText: n.string,
479
+ impressions: n.bool,
480
+ onSelectItem: n.func,
481
+ onImpressed: n.func
478
482
  };
479
483
  export {
480
484
  U as default