@cuemath/leap 3.5.19-as1 → 3.5.19-as2
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/constants/app-config.js +5 -0
- package/dist/constants/app-config.js.map +1 -0
- package/dist/features/timeline/comps/accordion-item/accordion-item.js +38 -50
- package/dist/features/timeline/comps/accordion-item/accordion-item.js.map +1 -1
- package/dist/features/ui/buttons/text-button/text-button-styled.js +7 -6
- package/dist/features/ui/buttons/text-button/text-button-styled.js.map +1 -1
- package/package.json +1 -1
- package/dist/features/timeline/comps/accordion-item/accordian-item-styled.js +0 -30
- package/dist/features/timeline/comps/accordion-item/accordian-item-styled.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app-config.js","sources":["../../src/constants/app-config.ts"],"sourcesContent":["export const IS_TOUCH_DEVICE = window.ReactNativeWebView;\n"],"names":["IS_TOUCH_DEVICE"],"mappings":"AAAO,MAAMA,IAAkB,OAAO;"}
|
|
@@ -1,71 +1,59 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { memo as
|
|
3
|
-
import
|
|
4
|
-
import z from "../../../ui/buttons/text-button/text-button.js";
|
|
1
|
+
import { jsxs as t, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { memo as S, useMemo as K, useCallback as $ } from "react";
|
|
3
|
+
import u from "../../../ui/buttons/text-button/text-button.js";
|
|
5
4
|
import l from "../../../ui/layout/flex-view.js";
|
|
6
|
-
import
|
|
7
|
-
import { getStateConf as
|
|
8
|
-
import { BLOCK_TYPE as
|
|
9
|
-
import { CODING_ACTIVITY_NODE_TYPES as
|
|
10
|
-
import { NODE_STATE as
|
|
5
|
+
import d from "../../../ui/text/text.js";
|
|
6
|
+
import { getStateConf as N } from "../utils.js";
|
|
7
|
+
import { BLOCK_TYPE as g } from "../../../chapters-v2/constants/block-constants.js";
|
|
8
|
+
import { CODING_ACTIVITY_NODE_TYPES as O } from "../constants.js";
|
|
9
|
+
import { NODE_STATE as k, CARD_TYPE as P, USER_TYPE as i } from "../../daily-timeline-types.js";
|
|
11
10
|
import { NODE_TYPES as Y } from "../../../../types/models/worksheet.js";
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
const
|
|
15
|
-
({ type: T, userType: o, card: d, onPuzzleClick: n, onReviewClick: m }) => {
|
|
16
|
-
const { textButton: C } = g(), {
|
|
11
|
+
const G = S(
|
|
12
|
+
({ type: T, userType: o, card: s, onPuzzleClick: n, onReviewClick: m }) => {
|
|
13
|
+
const {
|
|
17
14
|
label: b,
|
|
18
15
|
title: h,
|
|
19
|
-
state:
|
|
20
|
-
subtext:
|
|
21
|
-
user_node_id:
|
|
16
|
+
state: E,
|
|
17
|
+
subtext: _,
|
|
18
|
+
user_node_id: a,
|
|
22
19
|
block_type: p,
|
|
23
|
-
user_block_id:
|
|
20
|
+
user_block_id: C,
|
|
24
21
|
node_type: f
|
|
25
|
-
} =
|
|
22
|
+
} = s, c = p === g.SAT_MOCK_TEST, x = f === Y.PUZZLE_CARD, [A, w, B] = N(E), r = E === k.COMPLETED, D = K(() => T === P.CIRCLE ? !1 : o === i.TEACHER ? !c || r : o === i.STUDENT ? r && !O.includes(
|
|
26
23
|
f
|
|
27
|
-
) : !1, [o, T,
|
|
28
|
-
n == null || n(
|
|
29
|
-
}, [n,
|
|
30
|
-
m &&
|
|
31
|
-
}, [
|
|
32
|
-
return /* @__PURE__ */
|
|
33
|
-
/* @__PURE__ */ e(l, { $justifyContent: "flex-end", $height: 18, $background: "WHITE", children: /* @__PURE__ */ e(l, { $background: w, $borderColor: "BLACK_1", $borderRadiusX: 0.8, children:
|
|
34
|
-
/* @__PURE__ */
|
|
35
|
-
/* @__PURE__ */
|
|
36
|
-
/* @__PURE__ */
|
|
24
|
+
) : !1, [o, T, c, r, f]), I = r && (o === i.STUDENT || o === i.PARENT) || o === i.TEACHER, L = $(() => {
|
|
25
|
+
n == null || n(s);
|
|
26
|
+
}, [n, s]), R = $(() => {
|
|
27
|
+
m && a && m(a, c, C);
|
|
28
|
+
}, [c, m, C, a]);
|
|
29
|
+
return /* @__PURE__ */ t(l, { $flexDirection: "row", $flexGapX: 1.5, children: [
|
|
30
|
+
/* @__PURE__ */ e(l, { $justifyContent: "flex-end", $height: 18, $background: "WHITE", children: /* @__PURE__ */ e(l, { $background: w, $borderColor: "BLACK_1", $borderRadiusX: 0.8, children: A && /* @__PURE__ */ e(A, { width: 14, height: 14, color: B }) }) }),
|
|
31
|
+
/* @__PURE__ */ t(l, { $flexRowGapX: 0.25, children: [
|
|
32
|
+
/* @__PURE__ */ t(d, { $renderAs: "ub2", $color: "BLACK_1", children: [
|
|
33
|
+
/* @__PURE__ */ t(d, { $renderAs: "ub2-bold", $inline: !0, $color: "BLACK_1", children: [
|
|
37
34
|
b,
|
|
38
35
|
":"
|
|
39
36
|
] }),
|
|
40
37
|
" ",
|
|
41
38
|
h
|
|
42
39
|
] }),
|
|
43
|
-
x ?
|
|
44
|
-
|
|
40
|
+
x ? I ? /* @__PURE__ */ e(
|
|
41
|
+
u,
|
|
45
42
|
{
|
|
46
43
|
label: r ? "View reviewed puzzle" : "View assigned puzzle",
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
G,
|
|
51
|
-
{
|
|
52
|
-
$color: "BLACK_T_60",
|
|
53
|
-
$renderAs: C.sizes.small.textVariant,
|
|
54
|
-
$buttonSize: "small",
|
|
55
|
-
$isParent: o === t.PARENT,
|
|
56
|
-
children: r ? "View reviewed puzzle" : "View assigned puzzle"
|
|
57
|
-
}
|
|
58
|
-
)
|
|
44
|
+
size: "small",
|
|
45
|
+
color: "BLACK_T_60",
|
|
46
|
+
onClick: L
|
|
59
47
|
}
|
|
60
|
-
) : /* @__PURE__ */ e(
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
48
|
+
) : /* @__PURE__ */ e(d, { $renderAs: "ub3", $color: "BLACK_T_60", children: _ }) : /* @__PURE__ */ t(l, { $flexDirection: "row", $flexGapX: 0.75, $alignItems: "center", children: [
|
|
49
|
+
_ && /* @__PURE__ */ e(d, { $renderAs: "ub3", $color: "BLACK_T_60", children: _ }),
|
|
50
|
+
D && /* @__PURE__ */ e(
|
|
51
|
+
u,
|
|
64
52
|
{
|
|
65
53
|
label: "Review",
|
|
66
54
|
size: "small",
|
|
67
55
|
color: "BLACK_T_60",
|
|
68
|
-
onClick:
|
|
56
|
+
onClick: R
|
|
69
57
|
}
|
|
70
58
|
)
|
|
71
59
|
] })
|
|
@@ -73,8 +61,8 @@ const M = I(
|
|
|
73
61
|
] });
|
|
74
62
|
}
|
|
75
63
|
);
|
|
76
|
-
|
|
64
|
+
G.displayName = "AccordionItem";
|
|
77
65
|
export {
|
|
78
|
-
|
|
66
|
+
G as default
|
|
79
67
|
};
|
|
80
68
|
//# sourceMappingURL=accordion-item.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"accordion-item.js","sources":["../../../../../src/features/timeline/comps/accordion-item/accordion-item.tsx"],"sourcesContent":["import { memo, useCallback, useMemo, type FC } from 'react';\
|
|
1
|
+
{"version":3,"file":"accordion-item.js","sources":["../../../../../src/features/timeline/comps/accordion-item/accordion-item.tsx"],"sourcesContent":["import { memo, useCallback, useMemo, type FC } from 'react';\n\nimport TextButton from '../../../ui/buttons/text-button/text-button';\nimport FlexView from '../../../ui/layout/flex-view';\nimport Text from '../../../ui/text/text';\nimport type { IAccordionItemProps } from './accordion-item-types';\nimport { getStateConf } from '../utils';\nimport { BLOCK_TYPE } from '../../../chapters-v2/constants/block-constants';\nimport { type TColorNames } from '../../../ui/types';\nimport { CODING_ACTIVITY_NODE_TYPES } from '../constants';\nimport { CARD_TYPE, NODE_STATE, USER_TYPE } from '../../daily-timeline-types';\nimport { NODE_TYPES } from '../../../../types/models/worksheet';\n\nconst AccordionItem: FC<IAccordionItemProps> = memo(\n ({ type, userType, card, onPuzzleClick, onReviewClick }) => {\n const {\n label,\n title,\n state,\n subtext,\n user_node_id: userNodeId,\n block_type: blockType,\n user_block_id: userBlockId,\n node_type: nodeType,\n } = card;\n const isSatMockTestBlock = blockType === BLOCK_TYPE.SAT_MOCK_TEST;\n const isPuzzleCard = nodeType === NODE_TYPES.PUZZLE_CARD;\n const [Icon, bgColor, color] = getStateConf(state) as [\n FC<React.SVGProps<SVGSVGElement>>,\n TColorNames,\n TColorNames,\n ];\n const isCompleted = state === NODE_STATE.COMPLETED;\n const shouldShowReview = useMemo(() => {\n if (type === CARD_TYPE.CIRCLE) return false;\n\n if (userType === USER_TYPE.TEACHER) return !isSatMockTestBlock || isCompleted;\n\n if (userType === USER_TYPE.STUDENT)\n return (\n isCompleted &&\n !CODING_ACTIVITY_NODE_TYPES.includes(\n nodeType as (typeof CODING_ACTIVITY_NODE_TYPES)[number],\n )\n );\n\n return false;\n }, [userType, type, isSatMockTestBlock, isCompleted, nodeType]);\n\n const canReviewPuzzle =\n (isCompleted && (userType === USER_TYPE.STUDENT || userType === USER_TYPE.PARENT)) ||\n userType === USER_TYPE.TEACHER;\n\n const handlePuzzleClick = useCallback(() => {\n onPuzzleClick?.(card);\n }, [onPuzzleClick, card]);\n\n const handleReviewClick = useCallback(() => {\n if (onReviewClick && userNodeId) {\n onReviewClick(userNodeId, isSatMockTestBlock, userBlockId);\n }\n }, [isSatMockTestBlock, onReviewClick, userBlockId, userNodeId]);\n\n return (\n <FlexView $flexDirection=\"row\" $flexGapX={1.5}>\n <FlexView $justifyContent=\"flex-end\" $height={18} $background=\"WHITE\">\n <FlexView $background={bgColor} $borderColor=\"BLACK_1\" $borderRadiusX={0.8}>\n {Icon && <Icon width={14} height={14} color={color} />}\n </FlexView>\n </FlexView>\n <FlexView $flexRowGapX={0.25}>\n <Text $renderAs=\"ub2\" $color=\"BLACK_1\">\n <Text $renderAs=\"ub2-bold\" $inline $color=\"BLACK_1\">\n {label}:\n </Text>{' '}\n {title}\n </Text>\n {isPuzzleCard ? (\n canReviewPuzzle ? (\n <TextButton\n label={isCompleted ? 'View reviewed puzzle' : 'View assigned puzzle'}\n size=\"small\"\n color=\"BLACK_T_60\"\n onClick={handlePuzzleClick}\n />\n ) : (\n <Text $renderAs=\"ub3\" $color=\"BLACK_T_60\">\n {subtext}\n </Text>\n )\n ) : (\n <FlexView $flexDirection=\"row\" $flexGapX={0.75} $alignItems=\"center\">\n {subtext && (\n <Text $renderAs=\"ub3\" $color=\"BLACK_T_60\">\n {subtext}\n </Text>\n )}\n {shouldShowReview && (\n <TextButton\n label=\"Review\"\n size=\"small\"\n color=\"BLACK_T_60\"\n onClick={handleReviewClick}\n />\n )}\n </FlexView>\n )}\n </FlexView>\n </FlexView>\n );\n },\n);\n\nAccordionItem.displayName = 'AccordionItem';\n\nexport default AccordionItem;\n"],"names":["AccordionItem","memo","type","userType","card","onPuzzleClick","onReviewClick","label","title","state","subtext","userNodeId","blockType","userBlockId","nodeType","isSatMockTestBlock","BLOCK_TYPE","isPuzzleCard","NODE_TYPES","Icon","bgColor","color","getStateConf","isCompleted","NODE_STATE","shouldShowReview","useMemo","CARD_TYPE","USER_TYPE","CODING_ACTIVITY_NODE_TYPES","canReviewPuzzle","handlePuzzleClick","useCallback","handleReviewClick","jsxs","FlexView","jsx","Text","TextButton"],"mappings":";;;;;;;;;;AAaA,MAAMA,IAAyCC;AAAA,EAC7C,CAAC,EAAE,MAAAC,GAAM,UAAAC,GAAU,MAAAC,GAAM,eAAAC,GAAe,eAAAC,QAAoB;AACpD,UAAA;AAAA,MACJ,OAAAC;AAAA,MACA,OAAAC;AAAA,MACA,OAAAC;AAAA,MACA,SAAAC;AAAA,MACA,cAAcC;AAAA,MACd,YAAYC;AAAA,MACZ,eAAeC;AAAA,MACf,WAAWC;AAAA,IACT,IAAAV,GACEW,IAAqBH,MAAcI,EAAW,eAC9CC,IAAeH,MAAaI,EAAW,aACvC,CAACC,GAAMC,GAASC,CAAK,IAAIC,EAAab,CAAK,GAK3Cc,IAAcd,MAAUe,EAAW,WACnCC,IAAmBC,EAAQ,MAC3BxB,MAASyB,EAAU,SAAe,KAElCxB,MAAayB,EAAU,UAAgB,CAACb,KAAsBQ,IAE9DpB,MAAayB,EAAU,UAEvBL,KACA,CAACM,EAA2B;AAAA,MAC1Bf;AAAA,IAAA,IAIC,IACN,CAACX,GAAUD,GAAMa,GAAoBQ,GAAaT,CAAQ,CAAC,GAExDgB,IACHP,MAAgBpB,MAAayB,EAAU,WAAWzB,MAAayB,EAAU,WAC1EzB,MAAayB,EAAU,SAEnBG,IAAoBC,EAAY,MAAM;AAC1C,MAAA3B,KAAA,QAAAA,EAAgBD;AAAA,IAAI,GACnB,CAACC,GAAeD,CAAI,CAAC,GAElB6B,IAAoBD,EAAY,MAAM;AAC1C,MAAI1B,KAAiBK,KACLL,EAAAK,GAAYI,GAAoBF,CAAW;AAAA,OAE1D,CAACE,GAAoBT,GAAeO,GAAaF,CAAU,CAAC;AAE/D,WACG,gBAAAuB,EAAAC,GAAA,EAAS,gBAAe,OAAM,WAAW,KACxC,UAAA;AAAA,MAAC,gBAAAC,EAAAD,GAAA,EAAS,iBAAgB,YAAW,SAAS,IAAI,aAAY,SAC5D,UAAA,gBAAAC,EAACD,GAAS,EAAA,aAAaf,GAAS,cAAa,WAAU,gBAAgB,KACpE,UAAQD,KAAA,gBAAAiB,EAACjB,GAAK,EAAA,OAAO,IAAI,QAAQ,IAAI,OAAAE,EAAc,CAAA,EAAA,CACtD,EACF,CAAA;AAAA,MACA,gBAAAa,EAACC,GAAS,EAAA,cAAc,MACtB,UAAA;AAAA,QAAA,gBAAAD,EAACG,GAAK,EAAA,WAAU,OAAM,QAAO,WAC3B,UAAA;AAAA,UAAA,gBAAAH,EAACG,KAAK,WAAU,YAAW,SAAO,IAAC,QAAO,WACvC,UAAA;AAAA,YAAA9B;AAAA,YAAM;AAAA,UAAA,GACT;AAAA,UAAQ;AAAA,UACPC;AAAA,QAAA,GACH;AAAA,QACCS,IACCa,IACE,gBAAAM;AAAA,UAACE;AAAA,UAAA;AAAA,YACC,OAAOf,IAAc,yBAAyB;AAAA,YAC9C,MAAK;AAAA,YACL,OAAM;AAAA,YACN,SAASQ;AAAA,UAAA;AAAA,QAAA,IAGV,gBAAAK,EAAAC,GAAA,EAAK,WAAU,OAAM,QAAO,cAC1B,UAAA3B,EACH,CAAA,IAGF,gBAAAwB,EAACC,KAAS,gBAAe,OAAM,WAAW,MAAM,aAAY,UACzD,UAAA;AAAA,UAAAzB,uBACE2B,GAAK,EAAA,WAAU,OAAM,QAAO,cAC1B,UACH3B,GAAA;AAAA,UAEDe,KACC,gBAAAW;AAAA,YAACE;AAAA,YAAA;AAAA,cACC,OAAM;AAAA,cACN,MAAK;AAAA,cACL,OAAM;AAAA,cACN,SAASL;AAAA,YAAA;AAAA,UACX;AAAA,QAAA,GAEJ;AAAA,MAAA,GAEJ;AAAA,IACF,EAAA,CAAA;AAAA,EAEJ;AACF;AAEAjC,EAAc,cAAc;"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import i from "styled-components";
|
|
2
|
-
import
|
|
3
|
-
import { ClickableWrapper as
|
|
4
|
-
|
|
2
|
+
import d from "../../text/text.js";
|
|
3
|
+
import { ClickableWrapper as c } from "../clickable/clickable-styled.js";
|
|
4
|
+
import { IS_TOUCH_DEVICE as x } from "../../../../constants/app-config.js";
|
|
5
|
+
const u = i(d)(({ theme: t, $buttonSize: n }) => {
|
|
5
6
|
const { textButton: o } = t, { underlineHeight: e, underlineOffset: r } = o.sizes[n];
|
|
6
7
|
return `
|
|
7
8
|
text-decoration: underline;
|
|
@@ -9,7 +10,7 @@ const p = i(c)(({ theme: t, $buttonSize: n }) => {
|
|
|
9
10
|
text-underline-offset: ${r}px;
|
|
10
11
|
|
|
11
12
|
&:hover {
|
|
12
|
-
text-decoration: none;
|
|
13
|
+
text-decoration: ${x ? "underline" : "none"};
|
|
13
14
|
}
|
|
14
15
|
|
|
15
16
|
&:active {
|
|
@@ -17,7 +18,7 @@ const p = i(c)(({ theme: t, $buttonSize: n }) => {
|
|
|
17
18
|
text-decoration-thickness: ${e}px;
|
|
18
19
|
}
|
|
19
20
|
|
|
20
|
-
${
|
|
21
|
+
${c}[aria-disabled='true'] & {
|
|
21
22
|
text-decoration: underline;
|
|
22
23
|
text-decoration-thickness: ${e}px;
|
|
23
24
|
opacity: 0.5;
|
|
@@ -25,6 +26,6 @@ const p = i(c)(({ theme: t, $buttonSize: n }) => {
|
|
|
25
26
|
`;
|
|
26
27
|
});
|
|
27
28
|
export {
|
|
28
|
-
|
|
29
|
+
u as Text
|
|
29
30
|
};
|
|
30
31
|
//# sourceMappingURL=text-button-styled.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-button-styled.js","sources":["../../../../../src/features/ui/buttons/text-button/text-button-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport UIText from '../../text/text';\nimport { ClickableWrapper } from '../clickable/clickable-styled';\nimport type { ITextButtonProps } from './text-button-types';\n\ninterface IStyledTextProps {\n $buttonSize: NonNullable<ITextButtonProps['size']>;\n}\n\nconst Text = styled(UIText)<IStyledTextProps>(({ theme, $buttonSize }) => {\n const { textButton } = theme;\n const { underlineHeight, underlineOffset } = textButton.sizes[$buttonSize];\n\n return `\n text-decoration: underline;\n text-decoration-thickness: ${underlineHeight}px;\n text-underline-offset: ${underlineOffset}px;\n\n &:hover {\n text-decoration: none;\n }\n\n &:active {\n text-decoration: underline;\n text-decoration-thickness: ${underlineHeight}px;\n }\n\n ${ClickableWrapper}[aria-disabled='true'] & {\n text-decoration: underline;\n text-decoration-thickness: ${underlineHeight}px;\n opacity: 0.5;\n }\n `;\n});\n\nexport { Text };\n"],"names":["Text","styled","UIText","theme","$buttonSize","textButton","underlineHeight","underlineOffset","ClickableWrapper"],"mappings":"
|
|
1
|
+
{"version":3,"file":"text-button-styled.js","sources":["../../../../../src/features/ui/buttons/text-button/text-button-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport UIText from '../../text/text';\nimport { ClickableWrapper } from '../clickable/clickable-styled';\nimport type { ITextButtonProps } from './text-button-types';\nimport { IS_TOUCH_DEVICE } from '../../../../constants/app-config';\n\ninterface IStyledTextProps {\n $buttonSize: NonNullable<ITextButtonProps['size']>;\n}\n\nconst Text = styled(UIText)<IStyledTextProps>(({ theme, $buttonSize }) => {\n const { textButton } = theme;\n const { underlineHeight, underlineOffset } = textButton.sizes[$buttonSize];\n\n return `\n text-decoration: underline;\n text-decoration-thickness: ${underlineHeight}px;\n text-underline-offset: ${underlineOffset}px;\n\n &:hover {\n text-decoration: ${IS_TOUCH_DEVICE ? 'underline' : 'none'};\n }\n\n &:active {\n text-decoration: underline;\n text-decoration-thickness: ${underlineHeight}px;\n }\n\n ${ClickableWrapper}[aria-disabled='true'] & {\n text-decoration: underline;\n text-decoration-thickness: ${underlineHeight}px;\n opacity: 0.5;\n }\n `;\n});\n\nexport { Text };\n"],"names":["Text","styled","UIText","theme","$buttonSize","textButton","underlineHeight","underlineOffset","IS_TOUCH_DEVICE","ClickableWrapper"],"mappings":";;;;AAWM,MAAAA,IAAOC,EAAOC,CAAM,EAAoB,CAAC,EAAE,OAAAC,GAAO,aAAAC,QAAkB;AAClE,QAAA,EAAE,YAAAC,EAAe,IAAAF,GACjB,EAAE,iBAAAG,GAAiB,iBAAAC,EAAA,IAAoBF,EAAW,MAAMD,CAAW;AAElE,SAAA;AAAA;AAAA,iCAEwBE,CAAe;AAAA,6BACnBC,CAAe;AAAA;AAAA;AAAA,yBAGnBC,IAAkB,cAAc,MAAM;AAAA;AAAA;AAAA;AAAA;AAAA,mCAK5BF,CAAe;AAAA;AAAA;AAAA,MAG5CG,CAAgB;AAAA;AAAA,mCAEaH,CAAe;AAAA;AAAA;AAAA;AAIlD,CAAC;"}
|
package/package.json
CHANGED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import d from "styled-components";
|
|
2
|
-
import c from "../../../ui/text/text.js";
|
|
3
|
-
import { ClickableWrapper as x } from "../../../ui/buttons/clickable/clickable-styled.js";
|
|
4
|
-
const p = d(c)(({ theme: t, $buttonSize: n, $isParent: o }) => {
|
|
5
|
-
const { textButton: r } = t, { underlineHeight: e, underlineOffset: i } = r.sizes[n];
|
|
6
|
-
return `
|
|
7
|
-
text-decoration: underline;
|
|
8
|
-
text-decoration-thickness: ${e}px;
|
|
9
|
-
text-underline-offset: ${i}px;
|
|
10
|
-
|
|
11
|
-
&:active {
|
|
12
|
-
text-decoration: underline;
|
|
13
|
-
text-decoration-thickness: ${e}px;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
&:hover {
|
|
17
|
-
text-decoration: ${o ? "underline" : "none"};
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
${x}[aria-disabled='true'] & {
|
|
21
|
-
text-decoration: underline;
|
|
22
|
-
text-decoration-thickness: ${e}px;
|
|
23
|
-
opacity: 0.5;
|
|
24
|
-
}
|
|
25
|
-
`;
|
|
26
|
-
});
|
|
27
|
-
export {
|
|
28
|
-
p as Text
|
|
29
|
-
};
|
|
30
|
-
//# sourceMappingURL=accordian-item-styled.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"accordian-item-styled.js","sources":["../../../../../src/features/timeline/comps/accordion-item/accordian-item-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport UIText from '../../../ui/text/text';\nimport { type ITextButtonProps } from '../../../ui/buttons/text-button/text-button-types';\nimport { ClickableWrapper } from '../../../ui/buttons/clickable/clickable-styled';\n\ninterface IStyledTextProps {\n $buttonSize: NonNullable<ITextButtonProps['size']>;\n $isParent: boolean;\n}\n\nexport const Text = styled(UIText)<IStyledTextProps>(({ theme, $buttonSize, $isParent }) => {\n const { textButton } = theme;\n const { underlineHeight, underlineOffset } = textButton.sizes[$buttonSize];\n\n return `\n text-decoration: underline;\n text-decoration-thickness: ${underlineHeight}px;\n text-underline-offset: ${underlineOffset}px;\n\n &:active {\n text-decoration: underline;\n text-decoration-thickness: ${underlineHeight}px;\n }\n\n &:hover {\n text-decoration: ${$isParent ? 'underline' : 'none'};\n }\n\n ${ClickableWrapper}[aria-disabled='true'] & {\n text-decoration: underline;\n text-decoration-thickness: ${underlineHeight}px;\n opacity: 0.5;\n }\n `;\n});\n"],"names":["Text","styled","UIText","theme","$buttonSize","$isParent","textButton","underlineHeight","underlineOffset","ClickableWrapper"],"mappings":";;;AAWa,MAAAA,IAAOC,EAAOC,CAAM,EAAoB,CAAC,EAAE,OAAAC,GAAO,aAAAC,GAAa,WAAAC,QAAgB;AACpF,QAAA,EAAE,YAAAC,EAAe,IAAAH,GACjB,EAAE,iBAAAI,GAAiB,iBAAAC,EAAA,IAAoBF,EAAW,MAAMF,CAAW;AAElE,SAAA;AAAA;AAAA,iCAEwBG,CAAe;AAAA,6BACnBC,CAAe;AAAA;AAAA;AAAA;AAAA,mCAITD,CAAe;AAAA;AAAA;AAAA;AAAA,yBAIzBF,IAAY,cAAc,MAAM;AAAA;AAAA;AAAA,MAGnDI,CAAgB;AAAA;AAAA,mCAEaF,CAAe;AAAA;AAAA;AAAA;AAIlD,CAAC;"}
|