@cuemath/leap 2.9.10 → 2.9.11
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/features/post-game-stats/digital-meter/constants.js +12 -11
- 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 +15 -16
- 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 +88 -86
- package/dist/features/post-game-stats/digital-meter/digital-meter.js.map +1 -1
- package/dist/features/post-game-stats/digital-meter/helper.js +3 -13
- package/dist/features/post-game-stats/digital-meter/helper.js.map +1 -1
- package/dist/features/ui/animated-arc/animated-arc-constants.js +6 -0
- package/dist/features/ui/animated-arc/animated-arc-constants.js.map +1 -0
- package/dist/features/ui/animated-arc/animated-arc-helpers.js +14 -0
- package/dist/features/ui/animated-arc/animated-arc-helpers.js.map +1 -0
- package/dist/features/ui/animated-arc/animated-arc-styled.js +33 -0
- package/dist/features/ui/animated-arc/animated-arc-styled.js.map +1 -0
- package/dist/features/ui/animated-arc/animated-arc.js +49 -0
- package/dist/features/ui/animated-arc/animated-arc.js.map +1 -0
- package/dist/features/ui/context-menu/context-menu.js +28 -18
- package/dist/features/ui/context-menu/context-menu.js.map +1 -1
- package/dist/features/ui/image/image.js +12 -12
- package/dist/features/ui/image/image.js.map +1 -1
- package/dist/features/ui/inputs/base-input/base-input-styled.js +77 -67
- package/dist/features/ui/inputs/base-input/base-input-styled.js.map +1 -1
- package/dist/features/ui/inputs/base-input/base-input.js +49 -47
- package/dist/features/ui/inputs/base-input/base-input.js.map +1 -1
- package/dist/features/ui/inputs/text-input/text-input.js +14 -12
- package/dist/features/ui/inputs/text-input/text-input.js.map +1 -1
- package/dist/features/ui/lottie-animation/lottie-animation.js +37 -28
- package/dist/features/ui/lottie-animation/lottie-animation.js.map +1 -1
- package/dist/features/ui/text/text.js +29 -27
- package/dist/features/ui/text/text.js.map +1 -1
- package/dist/features/ui/theme/button.js +17 -0
- package/dist/features/ui/theme/button.js.map +1 -1
- package/dist/features/ui/theme/input.js +67 -14
- package/dist/features/ui/theme/input.js.map +1 -1
- package/dist/index.d.ts +31 -2
- package/dist/index.js +229 -225
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/features/post-game-stats/digital-meter/comp/animated-arc/animated-arc-styled.js +0 -17
- package/dist/features/post-game-stats/digital-meter/comp/animated-arc/animated-arc-styled.js.map +0 -1
- package/dist/features/post-game-stats/digital-meter/comp/animated-arc/animated-arc.js +0 -50
- package/dist/features/post-game-stats/digital-meter/comp/animated-arc/animated-arc.js.map +0 -1
- package/dist/features/post-game-stats/digital-meter/comp/animated-arc/constants.js +0 -6
- package/dist/features/post-game-stats/digital-meter/comp/animated-arc/constants.js.map +0 -1
@@ -1,8 +1,8 @@
|
|
1
1
|
import { jsx as a } from "react/jsx-runtime";
|
2
|
-
import { forwardRef as
|
3
|
-
import
|
4
|
-
import { Input as
|
5
|
-
const i = "regular",
|
2
|
+
import { forwardRef as I } from "react";
|
3
|
+
import T from "../base-input/base-input.js";
|
4
|
+
import { Input as b } from "./text-input-styled.js";
|
5
|
+
const i = "regular", g = I((o, p) => {
|
6
6
|
const {
|
7
7
|
type: e,
|
8
8
|
label: l,
|
@@ -14,12 +14,13 @@ const i = "regular", x = b((o, p) => {
|
|
14
14
|
willShowMessage: d,
|
15
15
|
siblingElement: f,
|
16
16
|
errorMessage: c,
|
17
|
-
shape:
|
17
|
+
shape: h,
|
18
18
|
isTransparent: n,
|
19
|
-
|
19
|
+
helperText: w,
|
20
|
+
...x
|
20
21
|
} = o;
|
21
22
|
return /* @__PURE__ */ a(
|
22
|
-
|
23
|
+
T,
|
23
24
|
{
|
24
25
|
renderAs: r,
|
25
26
|
label: l,
|
@@ -29,11 +30,12 @@ const i = "regular", x = b((o, p) => {
|
|
29
30
|
disabled: s,
|
30
31
|
willShowMessage: d,
|
31
32
|
size: i,
|
32
|
-
shape:
|
33
|
+
shape: h,
|
33
34
|
errorMessage: c,
|
35
|
+
helperText: w,
|
34
36
|
isTransparent: n,
|
35
37
|
inputElement: /* @__PURE__ */ a(
|
36
|
-
|
38
|
+
b,
|
37
39
|
{
|
38
40
|
ref: p,
|
39
41
|
type: e,
|
@@ -42,14 +44,14 @@ const i = "regular", x = b((o, p) => {
|
|
42
44
|
$size: i,
|
43
45
|
disabled: s,
|
44
46
|
$isTransparent: n,
|
45
|
-
...
|
47
|
+
...x
|
46
48
|
}
|
47
49
|
),
|
48
50
|
siblingElement: f
|
49
51
|
}
|
50
52
|
);
|
51
|
-
}),
|
53
|
+
}), z = g;
|
52
54
|
export {
|
53
|
-
|
55
|
+
z as default
|
54
56
|
};
|
55
57
|
//# sourceMappingURL=text-input.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"text-input.js","sources":["../../../../../src/features/ui/inputs/text-input/text-input.tsx"],"sourcesContent":["import type { ITextInputProps } from './text-input-types';\nimport type { Ref } from 'react';\n\nimport { forwardRef } from 'react';\n\nimport BaseInput from '../base-input/base-input';\nimport * as Styled from './text-input-styled';\n\nconst SIZE = 'regular';\n\nconst TextInput = forwardRef((props: ITextInputProps, ref: Ref<HTMLInputElement>) => {\n const {\n type,\n label,\n value,\n renderAs,\n width,\n widthX,\n disabled,\n willShowMessage,\n siblingElement,\n errorMessage,\n shape,\n isTransparent,\n ...rest\n } = props;\n\n return (\n <BaseInput\n renderAs={renderAs}\n label={label}\n stickyLabel={!!value || type === 'date'}\n width={width}\n widthX={widthX}\n disabled={disabled}\n willShowMessage={willShowMessage}\n size={SIZE}\n shape={shape}\n errorMessage={errorMessage}\n isTransparent={isTransparent}\n inputElement={\n <Styled.Input\n ref={ref}\n type={type}\n value={value ?? ''}\n $renderAs={renderAs}\n $size={SIZE}\n disabled={disabled}\n $isTransparent={isTransparent}\n {...rest}\n />\n }\n siblingElement={siblingElement}\n />\n );\n});\n\nexport default TextInput;\n"],"names":["SIZE","TextInput","forwardRef","props","ref","type","label","value","renderAs","width","widthX","disabled","willShowMessage","siblingElement","errorMessage","shape","isTransparent","rest","jsx","BaseInput","Styled.Input","TextInput$1"],"mappings":";;;;AAQA,MAAMA,IAAO,WAEPC,IAAYC,EAAW,CAACC,GAAwBC,MAA+B;AAC7E,QAAA;AAAA,IACJ,MAAAC;AAAA,IACA,OAAAC;AAAA,IACA,OAAAC;AAAA,IACA,UAAAC;AAAA,IACA,OAAAC;AAAA,IACA,QAAAC;AAAA,IACA,UAAAC;AAAA,IACA,iBAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,cAAAC;AAAA,IACA,OAAAC;AAAA,IACA,eAAAC;AAAA,IACA,GAAGC;AAAA,EACD,
|
1
|
+
{"version":3,"file":"text-input.js","sources":["../../../../../src/features/ui/inputs/text-input/text-input.tsx"],"sourcesContent":["import type { ITextInputProps } from './text-input-types';\nimport type { Ref } from 'react';\n\nimport { forwardRef } from 'react';\n\nimport BaseInput from '../base-input/base-input';\nimport * as Styled from './text-input-styled';\n\nconst SIZE = 'regular';\n\nconst TextInput = forwardRef((props: ITextInputProps, ref: Ref<HTMLInputElement>) => {\n const {\n type,\n label,\n value,\n renderAs,\n width,\n widthX,\n disabled,\n willShowMessage,\n siblingElement,\n errorMessage,\n shape,\n isTransparent,\n helperText,\n ...rest\n } = props;\n\n return (\n <BaseInput\n renderAs={renderAs}\n label={label}\n stickyLabel={!!value || type === 'date'}\n width={width}\n widthX={widthX}\n disabled={disabled}\n willShowMessage={willShowMessage}\n size={SIZE}\n shape={shape}\n errorMessage={errorMessage}\n helperText={helperText}\n isTransparent={isTransparent}\n inputElement={\n <Styled.Input\n ref={ref}\n type={type}\n value={value ?? ''}\n $renderAs={renderAs}\n $size={SIZE}\n disabled={disabled}\n $isTransparent={isTransparent}\n {...rest}\n />\n }\n siblingElement={siblingElement}\n />\n );\n});\n\nexport default TextInput;\n"],"names":["SIZE","TextInput","forwardRef","props","ref","type","label","value","renderAs","width","widthX","disabled","willShowMessage","siblingElement","errorMessage","shape","isTransparent","helperText","rest","jsx","BaseInput","Styled.Input","TextInput$1"],"mappings":";;;;AAQA,MAAMA,IAAO,WAEPC,IAAYC,EAAW,CAACC,GAAwBC,MAA+B;AAC7E,QAAA;AAAA,IACJ,MAAAC;AAAA,IACA,OAAAC;AAAA,IACA,OAAAC;AAAA,IACA,UAAAC;AAAA,IACA,OAAAC;AAAA,IACA,QAAAC;AAAA,IACA,UAAAC;AAAA,IACA,iBAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,cAAAC;AAAA,IACA,OAAAC;AAAA,IACA,eAAAC;AAAA,IACA,YAAAC;AAAA,IACA,GAAGC;AAAA,EACD,IAAAf;AAGF,SAAA,gBAAAgB;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,UAAAZ;AAAA,MACA,OAAAF;AAAA,MACA,aAAa,CAAC,CAACC,KAASF,MAAS;AAAA,MACjC,OAAAI;AAAA,MACA,QAAAC;AAAA,MACA,UAAAC;AAAA,MACA,iBAAAC;AAAA,MACA,MAAMZ;AAAA,MACN,OAAAe;AAAA,MACA,cAAAD;AAAA,MACA,YAAAG;AAAA,MACA,eAAAD;AAAA,MACA,cACE,gBAAAG;AAAA,QAACE;AAAAA,QAAA;AAAA,UACC,KAAAjB;AAAA,UACA,MAAAC;AAAA,UACA,OAAOE,KAAS;AAAA,UAChB,WAAWC;AAAA,UACX,OAAOR;AAAA,UACP,UAAAW;AAAA,UACA,gBAAgBK;AAAA,UACf,GAAGE;AAAA,QAAA;AAAA,MACN;AAAA,MAEF,gBAAAL;AAAA,IAAA;AAAA,EAAA;AAGN,CAAC,GAEDS,IAAerB;"}
|
@@ -1,51 +1,60 @@
|
|
1
|
-
import { jsx as
|
2
|
-
import
|
3
|
-
import { memo as
|
1
|
+
import { jsx as E } from "react/jsx-runtime";
|
2
|
+
import g from "lottie-web";
|
3
|
+
import { memo as w, forwardRef as y, useRef as u, useImperativeHandle as b, useEffect as A } from "react";
|
4
4
|
import I from "../layout/flex-view.js";
|
5
5
|
import { fetchLottie as $ } from "./helper.js";
|
6
|
-
const x =
|
6
|
+
const x = y((v, p) => {
|
7
7
|
const {
|
8
|
-
src:
|
9
|
-
width:
|
10
|
-
height:
|
11
|
-
settings:
|
12
|
-
eventListener:
|
13
|
-
onRender:
|
14
|
-
animateOnIntersect:
|
15
|
-
} =
|
16
|
-
return
|
17
|
-
|
8
|
+
src: m,
|
9
|
+
width: L = "100%",
|
10
|
+
height: h = "100%",
|
11
|
+
settings: l,
|
12
|
+
eventListener: n,
|
13
|
+
onRender: a,
|
14
|
+
animateOnIntersect: c
|
15
|
+
} = v, o = u(null), r = u(null), s = u(null);
|
16
|
+
return b(
|
17
|
+
p,
|
18
18
|
() => ({
|
19
|
-
playSegments: (
|
20
|
-
|
19
|
+
playSegments: (i, e) => {
|
20
|
+
var t;
|
21
|
+
return (t = r.current) == null ? void 0 : t.playSegments(i, e);
|
22
|
+
},
|
23
|
+
addEventListener: (i, e) => {
|
24
|
+
var t;
|
25
|
+
return (t = r.current) == null ? void 0 : t.addEventListener(i, e);
|
26
|
+
},
|
27
|
+
removeEventListener: (i, e) => {
|
28
|
+
var t;
|
29
|
+
return (t = r.current) == null ? void 0 : t.removeEventListener(i, e);
|
21
30
|
}
|
22
31
|
}),
|
23
32
|
[]
|
24
|
-
),
|
33
|
+
), A(() => ((async () => {
|
25
34
|
try {
|
26
|
-
const e = await $(
|
27
|
-
|
28
|
-
container:
|
35
|
+
const e = await $(m);
|
36
|
+
o.current && (r.current = g.loadAnimation({
|
37
|
+
container: o.current,
|
29
38
|
animationData: e,
|
30
39
|
renderer: "svg",
|
31
40
|
loop: !0,
|
32
41
|
autoplay: !0,
|
33
|
-
...
|
34
|
-
}),
|
35
|
-
([
|
42
|
+
...l
|
43
|
+
}), c && (s.current = new IntersectionObserver(
|
44
|
+
([t]) => {
|
36
45
|
var f, d;
|
37
|
-
|
46
|
+
t && t.isIntersecting ? (f = r.current) == null || f.play() : (d = r.current) == null || d.pause();
|
38
47
|
},
|
39
48
|
{ threshold: 0 }
|
40
|
-
),
|
49
|
+
), o.current && s.current.observe(o.current)), a == null || a(), n && r.current.addEventListener(n.name, n.callback));
|
41
50
|
} catch (e) {
|
42
51
|
throw Error(`Error loading Lottie animation: ${e}`);
|
43
52
|
}
|
44
53
|
})(), () => {
|
45
54
|
var e;
|
46
|
-
|
47
|
-
}), [
|
48
|
-
}), F =
|
55
|
+
r.current && (n && r.current.removeEventListener(n.name, n.callback), c && ((e = s.current) == null || e.disconnect()), r.current.destroy());
|
56
|
+
}), [m, n, a, c, l]), /* @__PURE__ */ E(I, { ref: o, $width: L, $height: h });
|
57
|
+
}), F = w(x);
|
49
58
|
export {
|
50
59
|
F as default
|
51
60
|
};
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"lottie-animation.js","sources":["../../../../src/features/ui/lottie-animation/lottie-animation.tsx"],"sourcesContent":["import type { ILottieAnimationProps, ILottieAnimationRef } from './types';\nimport type { AnimationItem, AnimationSegment } from 'lottie-web';\n\nimport lottie from 'lottie-web';\nimport { forwardRef, memo, useEffect, useImperativeHandle, useRef } from 'react';\n\nimport FlexView from '../layout/flex-view';\nimport { fetchLottie } from './helper';\n\nconst LottieAnimation = forwardRef<ILottieAnimationRef, ILottieAnimationProps>((props, ref) => {\n const {\n src,\n width = '100%',\n height = '100%',\n settings,\n eventListener,\n onRender,\n animateOnIntersect,\n } = props;\n\n const container = useRef<HTMLDivElement>(null);\n const animationInstance = useRef<AnimationItem | null>(null);\n const intersectionObserver = useRef<IntersectionObserver | null>(null);\n\n useImperativeHandle(\n ref,\n () => ({\n playSegments: (segments: AnimationSegment, forceFlag?: boolean) =>
|
1
|
+
{"version":3,"file":"lottie-animation.js","sources":["../../../../src/features/ui/lottie-animation/lottie-animation.tsx"],"sourcesContent":["import type { ILottieAnimationProps, ILottieAnimationRef } from './types';\nimport type { AnimationEventName, AnimationItem, AnimationSegment } from 'lottie-web';\n\nimport lottie from 'lottie-web';\nimport { forwardRef, memo, useEffect, useImperativeHandle, useRef } from 'react';\n\nimport FlexView from '../layout/flex-view';\nimport { fetchLottie } from './helper';\n\nconst LottieAnimation = forwardRef<ILottieAnimationRef, ILottieAnimationProps>((props, ref) => {\n const {\n src,\n width = '100%',\n height = '100%',\n settings,\n eventListener,\n onRender,\n animateOnIntersect,\n } = props;\n\n const container = useRef<HTMLDivElement>(null);\n const animationInstance = useRef<AnimationItem | null>(null);\n const intersectionObserver = useRef<IntersectionObserver | null>(null);\n\n useImperativeHandle(\n ref,\n () => ({\n playSegments: (segments: AnimationSegment, forceFlag?: boolean) =>\n animationInstance.current?.playSegments(segments, forceFlag),\n addEventListener: (eventName: string, callback: () => void) =>\n animationInstance.current?.addEventListener(eventName as AnimationEventName, callback),\n removeEventListener: (eventName: string, callback: () => void) =>\n animationInstance.current?.removeEventListener(eventName as AnimationEventName, callback),\n }),\n [],\n );\n\n useEffect(() => {\n const loadAnimation = async () => {\n try {\n const animationData = await fetchLottie(src);\n\n if (container.current) {\n animationInstance.current = lottie.loadAnimation({\n container: container.current,\n animationData,\n renderer: 'svg',\n loop: true,\n autoplay: true,\n ...settings,\n });\n\n if (animateOnIntersect) {\n intersectionObserver.current = new IntersectionObserver(\n ([entry]) => {\n if (entry && entry.isIntersecting) {\n animationInstance.current?.play();\n } else {\n animationInstance.current?.pause();\n }\n },\n { threshold: 0 },\n );\n\n if (container.current) {\n intersectionObserver.current.observe(container.current);\n }\n }\n\n onRender?.();\n if (eventListener) {\n animationInstance.current.addEventListener(eventListener.name, eventListener.callback);\n }\n }\n } catch (error) {\n throw Error(`Error loading Lottie animation: ${error}`);\n }\n };\n\n loadAnimation();\n\n return () => {\n if (animationInstance.current) {\n if (eventListener) {\n animationInstance.current.removeEventListener(eventListener.name, eventListener.callback);\n }\n\n if (animateOnIntersect) {\n intersectionObserver.current?.disconnect();\n }\n animationInstance.current.destroy();\n }\n };\n }, [src, eventListener, onRender, animateOnIntersect, settings]);\n\n return <FlexView ref={container} $width={width} $height={height} />;\n});\n\nexport default memo(LottieAnimation);\n"],"names":["LottieAnimation","forwardRef","props","ref","src","width","height","settings","eventListener","onRender","animateOnIntersect","container","useRef","animationInstance","intersectionObserver","useImperativeHandle","segments","forceFlag","_a","eventName","callback","useEffect","animationData","fetchLottie","lottie","entry","_b","error","FlexView","LottieAnimation$1","memo"],"mappings":";;;;;AASA,MAAMA,IAAkBC,EAAuD,CAACC,GAAOC,MAAQ;AACvF,QAAA;AAAA,IACJ,KAAAC;AAAA,IACA,OAAAC,IAAQ;AAAA,IACR,QAAAC,IAAS;AAAA,IACT,UAAAC;AAAA,IACA,eAAAC;AAAA,IACA,UAAAC;AAAA,IACA,oBAAAC;AAAA,EACE,IAAAR,GAEES,IAAYC,EAAuB,IAAI,GACvCC,IAAoBD,EAA6B,IAAI,GACrDE,IAAuBF,EAAoC,IAAI;AAErE,SAAAG;AAAA,IACEZ;AAAA,IACA,OAAO;AAAA,MACL,cAAc,CAACa,GAA4BC,MACzC;;AAAA,gBAAAC,IAAAL,EAAkB,YAAlB,gBAAAK,EAA2B,aAAaF,GAAUC;AAAA;AAAA,MACpD,kBAAkB,CAACE,GAAmBC,MACpC;;AAAA,gBAAAF,IAAAL,EAAkB,YAAlB,gBAAAK,EAA2B,iBAAiBC,GAAiCC;AAAA;AAAA,MAC/E,qBAAqB,CAACD,GAAmBC,MACvC;;AAAA,gBAAAF,IAAAL,EAAkB,YAAlB,gBAAAK,EAA2B,oBAAoBC,GAAiCC;AAAA;AAAA,IAAQ;AAAA,IAE5F,CAAC;AAAA,EAAA,GAGHC,EAAU,QACc,YAAY;AAC5B,QAAA;AACI,YAAAC,IAAgB,MAAMC,EAAYnB,CAAG;AAE3C,MAAIO,EAAU,YACME,EAAA,UAAUW,EAAO,cAAc;AAAA,QAC/C,WAAWb,EAAU;AAAA,QACrB,eAAAW;AAAA,QACA,UAAU;AAAA,QACV,MAAM;AAAA,QACN,UAAU;AAAA,QACV,GAAGf;AAAA,MAAA,CACJ,GAEGG,MACFI,EAAqB,UAAU,IAAI;AAAA,QACjC,CAAC,CAACW,CAAK,MAAM;;AACP,UAAAA,KAASA,EAAM,kBACjBP,IAAAL,EAAkB,YAAlB,QAAAK,EAA2B,UAE3BQ,IAAAb,EAAkB,YAAlB,QAAAa,EAA2B;AAAA,QAE/B;AAAA,QACA,EAAE,WAAW,EAAE;AAAA,MAAA,GAGbf,EAAU,WACSG,EAAA,QAAQ,QAAQH,EAAU,OAAO,IAI/CF,KAAA,QAAAA,KACPD,KACFK,EAAkB,QAAQ,iBAAiBL,EAAc,MAAMA,EAAc,QAAQ;AAAA,aAGlFmB,GAAO;AACR,YAAA,MAAM,mCAAmCA,CAAK,EAAE;AAAA,IACxD;AAAA,EAAA,MAKK,MAAM;;AACX,IAAId,EAAkB,YAChBL,KACFK,EAAkB,QAAQ,oBAAoBL,EAAc,MAAMA,EAAc,QAAQ,GAGtFE,OACFQ,IAAAJ,EAAqB,YAArB,QAAAI,EAA8B,eAEhCL,EAAkB,QAAQ;EAC5B,IAED,CAACT,GAAKI,GAAeC,GAAUC,GAAoBH,CAAQ,CAAC,qBAEvDqB,GAAS,EAAA,KAAKjB,GAAW,QAAQN,GAAO,SAASC,EAAQ,CAAA;AACnE,CAAC,GAEcuB,IAAAC,EAAK9B,CAAe;"}
|
@@ -1,48 +1,50 @@
|
|
1
|
-
import
|
2
|
-
const x =
|
1
|
+
import k from "styled-components";
|
2
|
+
const x = k.div(
|
3
3
|
({
|
4
|
-
theme:
|
5
|
-
$renderAs:
|
4
|
+
theme: f,
|
5
|
+
$renderAs: c,
|
6
6
|
$color: n,
|
7
|
-
$align:
|
7
|
+
$align: y = "left",
|
8
8
|
$width: t,
|
9
9
|
$widthX: o,
|
10
10
|
$marginBottom: e,
|
11
11
|
$marginBottomX: i,
|
12
12
|
$alignSelf: l,
|
13
|
-
$opacity:
|
14
|
-
$inline:
|
15
|
-
$textDecoration: p
|
13
|
+
$opacity: u = 1,
|
14
|
+
$inline: m,
|
15
|
+
$textDecoration: p,
|
16
|
+
$whiteSpace: $
|
16
17
|
}) => {
|
17
|
-
const { text:
|
18
|
-
fontFamily:
|
19
|
-
fontSize:
|
20
|
-
lineHeight:
|
21
|
-
letterSpacing:
|
22
|
-
textTransform:
|
23
|
-
} =
|
18
|
+
const { text: b, colors: r, layout: a } = f, {
|
19
|
+
fontFamily: g,
|
20
|
+
fontSize: d,
|
21
|
+
lineHeight: T,
|
22
|
+
letterSpacing: s,
|
23
|
+
textTransform: h = "none"
|
24
|
+
} = b[c];
|
24
25
|
return `
|
25
|
-
display: ${
|
26
|
-
font-family: ${
|
27
|
-
font-size: ${
|
28
|
-
text-align: ${
|
29
|
-
line-height: ${
|
30
|
-
text-transform: ${
|
31
|
-
${typeof
|
26
|
+
display: ${m ? "inline-block" : "block"};
|
27
|
+
font-family: ${g};
|
28
|
+
font-size: ${d}px;
|
29
|
+
text-align: ${y};
|
30
|
+
line-height: ${T}px;
|
31
|
+
text-transform: ${h};
|
32
|
+
${typeof s == "number" ? `letter-spacing: ${s}px;` : ""}
|
32
33
|
color: ${n ? r[n] : r.BLACK};
|
33
|
-
opacity: ${
|
34
|
+
opacity: ${u};
|
34
35
|
width: ${t ? `${t}` : "auto"}${typeof t == "number" ? "px" : ""};
|
35
|
-
${o ? `width: ${o *
|
36
|
+
${o ? `width: ${o * a.gutter}px;` : ""}
|
36
37
|
margin-bottom: ${e ? `${e}` : "initial"}${typeof e == "number" ? "px" : ""};
|
37
|
-
${i ? `margin-bottom: ${i *
|
38
|
+
${i ? `margin-bottom: ${i * a.gutter}px;` : ""}
|
38
39
|
${l ? `align-self: ${l};` : ""}
|
39
40
|
${p ? `text-decoration: ${p};` : ""}
|
41
|
+
${$ ? `white-space: ${$};` : ""}
|
40
42
|
`;
|
41
43
|
}
|
42
44
|
);
|
43
45
|
x.displayName = "Text";
|
44
|
-
const
|
46
|
+
const v = x;
|
45
47
|
export {
|
46
|
-
|
48
|
+
v as default
|
47
49
|
};
|
48
50
|
//# sourceMappingURL=text.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"text.js","sources":["../../../../src/features/ui/text/text.tsx"],"sourcesContent":["import type { TColorNames, TTextVariants } from '../types';\n\nimport styled from 'styled-components';\n\nexport interface TextProps {\n $renderAs: TTextVariants;\n $color?: TColorNames;\n $align?: 'auto' | 'left' | 'right' | 'center' | 'justify';\n $alignSelf?: 'auto' | 'flex-start' | 'flex-end' | 'center' | 'baseline' | 'stretch';\n $opacity?: number | undefined;\n $width?: number | string;\n $widthX?: number;\n $marginBottom?: number;\n $marginBottomX?: number;\n $inline?: boolean;\n $textDecoration?: string;\n}\n\n/**\n * @param $renderAs - The text variant to render as (ah1-ah4, ab1-ab3, ac1-ac4, ub1-ub3), anything else is deprecated\n */\nconst Text = styled.div<TextProps>(\n ({\n theme,\n $renderAs,\n $color,\n $align = 'left',\n $width,\n $widthX,\n $marginBottom,\n $marginBottomX,\n $alignSelf,\n $opacity = 1,\n $inline,\n $textDecoration,\n }) => {\n const { text, colors, layout } = theme;\n const {\n fontFamily,\n fontSize,\n lineHeight,\n letterSpacing,\n textTransform = 'none',\n } = text[$renderAs];\n\n return `\n display: ${$inline ? 'inline-block' : 'block'};\n font-family: ${fontFamily};\n font-size: ${fontSize}px;\n text-align: ${$align};\n line-height: ${lineHeight}px;\n text-transform: ${textTransform};\n ${typeof letterSpacing === 'number' ? `letter-spacing: ${letterSpacing}px;` : ''}\n color: ${$color ? colors[$color] : colors.BLACK};\n opacity: ${$opacity};\n width: ${$width ? `${$width}` : 'auto'}${typeof $width === 'number' ? 'px' : ''};\n ${$widthX ? `width: ${$widthX * layout.gutter}px;` : ''}\n margin-bottom: ${$marginBottom ? `${$marginBottom}` : 'initial'}${\n typeof $marginBottom === 'number' ? 'px' : ''\n };\n ${$marginBottomX ? `margin-bottom: ${$marginBottomX * layout.gutter}px;` : ''}\n ${$alignSelf ? `align-self: ${$alignSelf};` : ''}\n ${$textDecoration ? `text-decoration: ${$textDecoration};` : ''}\n `;\n },\n);\n\nText.displayName = 'Text';\n\nexport default Text;\n"],"names":["Text","styled","theme","$renderAs","$color","$align","$width","$widthX","$marginBottom","$marginBottomX","$alignSelf","$opacity","$inline","$textDecoration","text","colors","layout","fontFamily","fontSize","lineHeight","letterSpacing","textTransform","Text$1"],"mappings":";
|
1
|
+
{"version":3,"file":"text.js","sources":["../../../../src/features/ui/text/text.tsx"],"sourcesContent":["import type { TColorNames, TTextVariants } from '../types';\n\nimport styled from 'styled-components';\n\nexport interface TextProps {\n $renderAs: TTextVariants;\n $color?: TColorNames;\n $align?: 'auto' | 'left' | 'right' | 'center' | 'justify';\n $alignSelf?: 'auto' | 'flex-start' | 'flex-end' | 'center' | 'baseline' | 'stretch';\n $opacity?: number | undefined;\n $width?: number | string;\n $widthX?: number;\n $marginBottom?: number;\n $marginBottomX?: number;\n $inline?: boolean;\n $textDecoration?: string;\n $whiteSpace?: 'pre-line' | 'normal' | 'pre-wrap' | 'no-wrap' | 'pre' | 'break-spaces';\n}\n\n/**\n * @param $renderAs - The text variant to render as (ah1-ah4, ab1-ab3, ac1-ac4, ub1-ub3), anything else is deprecated\n */\nconst Text = styled.div<TextProps>(\n ({\n theme,\n $renderAs,\n $color,\n $align = 'left',\n $width,\n $widthX,\n $marginBottom,\n $marginBottomX,\n $alignSelf,\n $opacity = 1,\n $inline,\n $textDecoration,\n $whiteSpace,\n }) => {\n const { text, colors, layout } = theme;\n const {\n fontFamily,\n fontSize,\n lineHeight,\n letterSpacing,\n textTransform = 'none',\n } = text[$renderAs];\n\n return `\n display: ${$inline ? 'inline-block' : 'block'};\n font-family: ${fontFamily};\n font-size: ${fontSize}px;\n text-align: ${$align};\n line-height: ${lineHeight}px;\n text-transform: ${textTransform};\n ${typeof letterSpacing === 'number' ? `letter-spacing: ${letterSpacing}px;` : ''}\n color: ${$color ? colors[$color] : colors.BLACK};\n opacity: ${$opacity};\n width: ${$width ? `${$width}` : 'auto'}${typeof $width === 'number' ? 'px' : ''};\n ${$widthX ? `width: ${$widthX * layout.gutter}px;` : ''}\n margin-bottom: ${$marginBottom ? `${$marginBottom}` : 'initial'}${\n typeof $marginBottom === 'number' ? 'px' : ''\n };\n ${$marginBottomX ? `margin-bottom: ${$marginBottomX * layout.gutter}px;` : ''}\n ${$alignSelf ? `align-self: ${$alignSelf};` : ''}\n ${$textDecoration ? `text-decoration: ${$textDecoration};` : ''}\n ${$whiteSpace ? `white-space: ${$whiteSpace};` : ''}\n `;\n },\n);\n\nText.displayName = 'Text';\n\nexport default Text;\n"],"names":["Text","styled","theme","$renderAs","$color","$align","$width","$widthX","$marginBottom","$marginBottomX","$alignSelf","$opacity","$inline","$textDecoration","$whiteSpace","text","colors","layout","fontFamily","fontSize","lineHeight","letterSpacing","textTransform","Text$1"],"mappings":";AAsBA,MAAMA,IAAOC,EAAO;AAAA,EAClB,CAAC;AAAA,IACC,OAAAC;AAAA,IACA,WAAAC;AAAA,IACA,QAAAC;AAAA,IACA,QAAAC,IAAS;AAAA,IACT,QAAAC;AAAA,IACA,SAAAC;AAAA,IACA,eAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,YAAAC;AAAA,IACA,UAAAC,IAAW;AAAA,IACX,SAAAC;AAAA,IACA,iBAAAC;AAAA,IACA,aAAAC;AAAA,EAAA,MACI;AACJ,UAAM,EAAE,MAAAC,GAAM,QAAAC,GAAQ,QAAAC,EAAA,IAAWf,GAC3B;AAAA,MACJ,YAAAgB;AAAA,MACA,UAAAC;AAAA,MACA,YAAAC;AAAA,MACA,eAAAC;AAAA,MACA,eAAAC,IAAgB;AAAA,IAAA,IACdP,EAAKZ,CAAS;AAEX,WAAA;AAAA,iBACMS,IAAU,iBAAiB,OAAO;AAAA,qBAC9BM,CAAU;AAAA,mBACZC,CAAQ;AAAA,oBACPd,CAAM;AAAA,qBACLe,CAAU;AAAA,wBACPE,CAAa;AAAA,QAC7B,OAAOD,KAAkB,WAAW,mBAAmBA,CAAa,QAAQ,EAAE;AAAA,eACvEjB,IAASY,EAAOZ,CAAM,IAAIY,EAAO,KAAK;AAAA,iBACpCL,CAAQ;AAAA,eACVL,IAAS,GAAGA,CAAM,KAAK,MAAM,GAAG,OAAOA,KAAW,WAAW,OAAO,EAAE;AAAA,QAC7EC,IAAU,UAAUA,IAAUU,EAAO,MAAM,QAAQ,EAAE;AAAA,uBACtCT,IAAgB,GAAGA,CAAa,KAAK,SAAS,GAC7D,OAAOA,KAAkB,WAAW,OAAO,EAC7C;AAAA,QACEC,IAAiB,kBAAkBA,IAAiBQ,EAAO,MAAM,QAAQ,EAAE;AAAA,QAC3EP,IAAa,eAAeA,CAAU,MAAM,EAAE;AAAA,QAC9CG,IAAkB,oBAAoBA,CAAe,MAAM,EAAE;AAAA,QAC7DC,IAAc,gBAAgBA,CAAW,MAAM,EAAE;AAAA;AAAA,EAEvD;AACF;AAEAd,EAAK,cAAc;AAEnB,MAAAuB,IAAevB;"}
|
@@ -95,6 +95,23 @@ const o = (i) => ({ sizes: {
|
|
95
95
|
active: "RED",
|
96
96
|
disabled: "GREY_3"
|
97
97
|
}
|
98
|
+
},
|
99
|
+
"secondary-dark": {
|
100
|
+
backgroundColorName: {
|
101
|
+
inactive: "WHITE",
|
102
|
+
active: "BLACK",
|
103
|
+
disabled: "WHITE_T_10"
|
104
|
+
},
|
105
|
+
colorName: {
|
106
|
+
inactive: "BLACK",
|
107
|
+
active: "WHITE",
|
108
|
+
disabled: "WHITE_T_38"
|
109
|
+
},
|
110
|
+
borderColorName: {
|
111
|
+
inactive: "WHITE",
|
112
|
+
active: "BLACK",
|
113
|
+
disabled: "WHITE_T_15"
|
114
|
+
}
|
98
115
|
}
|
99
116
|
// 'yellow': {
|
100
117
|
// backgroundColorName: {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"button.js","sources":["../../../../src/features/ui/theme/button.ts"],"sourcesContent":["import type {\n IButtonSizeConfig,\n TButtonSizes,\n IButtonVariantConfig,\n TButtonVariants,\n} from '../types';\n\ninterface IGetButtonConfig {\n (gutter: number): {\n sizes: Record<TButtonSizes, IButtonSizeConfig>;\n variants: Record<TButtonVariants, IButtonVariantConfig>;\n };\n}\n\nconst getButtonConfig: IGetButtonConfig = (gutter: number) => {\n const sizes: Record<TButtonSizes, IButtonSizeConfig> = {\n xsmall: {\n height: gutter * 2,\n paddingHorizontal: gutter * (1 + 0.375),\n textVariant: 'ub3-bold',\n borderWidth: 1,\n iconSize: gutter,\n iconPadding: gutter * 0.25,\n loaderSize: gutter * 1.25,\n },\n small: {\n height: gutter * 2.5,\n paddingHorizontal: gutter * (1 + 0.625),\n textVariant: 'ub2-bold',\n borderWidth: 1,\n iconSize: gutter * 1.25,\n iconPadding: gutter * 0.375,\n loaderSize: gutter * 1.5,\n },\n regular: {\n height: gutter * 3,\n paddingHorizontal: gutter * (1 + 0.875),\n textVariant: 'ub1-bold',\n borderWidth: 1,\n iconSize: gutter * 1.5,\n iconPadding: gutter * 0.5,\n loaderSize: gutter * 1.75,\n },\n medium: {\n height: gutter * 3.5,\n paddingHorizontal: gutter * (1 + 1.125),\n textVariant: 'ub1-bold',\n borderWidth: 1.5,\n iconSize: gutter * 1.5,\n iconPadding: gutter * 0.5,\n loaderSize: gutter * 2,\n },\n large: {\n height: gutter * 4,\n paddingHorizontal: gutter * (1 + 1.375),\n textVariant: 'ub1-bold',\n borderWidth: 2,\n iconSize: gutter * 1.5,\n iconPadding: gutter * 0.5,\n loaderSize: gutter * 2.25,\n },\n };\n\n const variants: Record<TButtonVariants, IButtonVariantConfig> = {\n primary: {\n backgroundColorName: {\n inactive: 'YELLOW_4',\n active: 'BLACK',\n disabled: 'GREY_3',\n },\n colorName: {\n inactive: 'BLACK',\n active: 'WHITE',\n disabled: 'BLACK',\n },\n borderColorName: {\n inactive: 'BLACK',\n active: 'BLACK',\n disabled: 'GREY_3',\n },\n },\n secondary: {\n backgroundColorName: {\n inactive: 'WHITE',\n active: 'BLACK',\n disabled: 'GREY_3',\n },\n colorName: {\n inactive: 'BLACK',\n active: 'WHITE',\n disabled: 'BLACK',\n },\n borderColorName: {\n inactive: 'BLACK',\n active: 'BLACK',\n disabled: 'GREY_3',\n },\n },\n tertiary: {\n backgroundColorName: {\n inactive: 'WHITE',\n active: 'RED',\n disabled: 'GREY_3',\n },\n colorName: {\n inactive: 'RED',\n active: 'WHITE',\n disabled: 'BLACK',\n },\n borderColorName: {\n inactive: 'RED',\n active: 'RED',\n disabled: 'GREY_3',\n },\n },\n // 'yellow': {\n // backgroundColorName: {\n // inactive: 'YELLOW_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // colorName: {\n // inactive: 'BLACK_4',\n // active: 'WHITE_4',\n // disabled: 'BLACK_T_35',\n // },\n // },\n // 'yellow-dark': {\n // backgroundColorName: {\n // inactive: 'YELLOW_4',\n // active: 'WHITE_4',\n // disabled: 'WHITE_T_40',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'WHITE_T_40',\n // },\n // colorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'WHITE_T_40',\n // },\n // },\n // 'white': {\n // backgroundColorName: {\n // inactive: 'WHITE_1',\n // active: 'BLACK_T_35',\n // disabled: 'BLACK_T_35',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // colorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // },\n // 'white-dark': {\n // backgroundColorName: {\n // inactive: 'WHITE_4',\n // active: 'WHITE_T_70',\n // disabled: 'WHITE_T_40',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'WHITE_T_40',\n // },\n // colorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'WHITE_T_40',\n // },\n // },\n // 'black': {\n // backgroundColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_T_60',\n // disabled: 'BLACK_T_35',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // colorName: {\n // inactive: 'WHITE_4',\n // active: 'WHITE_4',\n // disabled: 'BLACK_T_35',\n // },\n // },\n // 'black-dark': {\n // backgroundColorName: {\n // inactive: 'BLACK_4',\n // active: 'WHITE_T_40',\n // disabled: 'WHITE_T_40',\n // },\n // borderColorName: {\n // inactive: 'WHITE_4',\n // active: 'WHITE_4',\n // disabled: 'WHITE_T_40',\n // },\n // colorName: {\n // inactive: 'WHITE_4',\n // active: 'WHITE_4',\n // disabled: 'WHITE_T_40',\n // },\n // },\n };\n\n return { sizes, variants };\n};\n\nexport default getButtonConfig;\n"],"names":["getButtonConfig","gutter"],"mappings":"AAcM,MAAAA,IAAoC,CAACC,
|
1
|
+
{"version":3,"file":"button.js","sources":["../../../../src/features/ui/theme/button.ts"],"sourcesContent":["import type {\n IButtonSizeConfig,\n TButtonSizes,\n IButtonVariantConfig,\n TButtonVariants,\n} from '../types';\n\ninterface IGetButtonConfig {\n (gutter: number): {\n sizes: Record<TButtonSizes, IButtonSizeConfig>;\n variants: Record<TButtonVariants, IButtonVariantConfig>;\n };\n}\n\nconst getButtonConfig: IGetButtonConfig = (gutter: number) => {\n const sizes: Record<TButtonSizes, IButtonSizeConfig> = {\n xsmall: {\n height: gutter * 2,\n paddingHorizontal: gutter * (1 + 0.375),\n textVariant: 'ub3-bold',\n borderWidth: 1,\n iconSize: gutter,\n iconPadding: gutter * 0.25,\n loaderSize: gutter * 1.25,\n },\n small: {\n height: gutter * 2.5,\n paddingHorizontal: gutter * (1 + 0.625),\n textVariant: 'ub2-bold',\n borderWidth: 1,\n iconSize: gutter * 1.25,\n iconPadding: gutter * 0.375,\n loaderSize: gutter * 1.5,\n },\n regular: {\n height: gutter * 3,\n paddingHorizontal: gutter * (1 + 0.875),\n textVariant: 'ub1-bold',\n borderWidth: 1,\n iconSize: gutter * 1.5,\n iconPadding: gutter * 0.5,\n loaderSize: gutter * 1.75,\n },\n medium: {\n height: gutter * 3.5,\n paddingHorizontal: gutter * (1 + 1.125),\n textVariant: 'ub1-bold',\n borderWidth: 1.5,\n iconSize: gutter * 1.5,\n iconPadding: gutter * 0.5,\n loaderSize: gutter * 2,\n },\n large: {\n height: gutter * 4,\n paddingHorizontal: gutter * (1 + 1.375),\n textVariant: 'ub1-bold',\n borderWidth: 2,\n iconSize: gutter * 1.5,\n iconPadding: gutter * 0.5,\n loaderSize: gutter * 2.25,\n },\n };\n\n const variants: Record<TButtonVariants, IButtonVariantConfig> = {\n 'primary': {\n backgroundColorName: {\n inactive: 'YELLOW_4',\n active: 'BLACK',\n disabled: 'GREY_3',\n },\n colorName: {\n inactive: 'BLACK',\n active: 'WHITE',\n disabled: 'BLACK',\n },\n borderColorName: {\n inactive: 'BLACK',\n active: 'BLACK',\n disabled: 'GREY_3',\n },\n },\n 'secondary': {\n backgroundColorName: {\n inactive: 'WHITE',\n active: 'BLACK',\n disabled: 'GREY_3',\n },\n colorName: {\n inactive: 'BLACK',\n active: 'WHITE',\n disabled: 'BLACK',\n },\n borderColorName: {\n inactive: 'BLACK',\n active: 'BLACK',\n disabled: 'GREY_3',\n },\n },\n 'tertiary': {\n backgroundColorName: {\n inactive: 'WHITE',\n active: 'RED',\n disabled: 'GREY_3',\n },\n colorName: {\n inactive: 'RED',\n active: 'WHITE',\n disabled: 'BLACK',\n },\n borderColorName: {\n inactive: 'RED',\n active: 'RED',\n disabled: 'GREY_3',\n },\n },\n 'secondary-dark': {\n backgroundColorName: {\n inactive: 'WHITE',\n active: 'BLACK',\n disabled: 'WHITE_T_10',\n },\n colorName: {\n inactive: 'BLACK',\n active: 'WHITE',\n disabled: 'WHITE_T_38',\n },\n borderColorName: {\n inactive: 'WHITE',\n active: 'BLACK',\n disabled: 'WHITE_T_15',\n },\n },\n // 'yellow': {\n // backgroundColorName: {\n // inactive: 'YELLOW_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // colorName: {\n // inactive: 'BLACK_4',\n // active: 'WHITE_4',\n // disabled: 'BLACK_T_35',\n // },\n // },\n // 'yellow-dark': {\n // backgroundColorName: {\n // inactive: 'YELLOW_4',\n // active: 'WHITE_4',\n // disabled: 'WHITE_T_40',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'WHITE_T_40',\n // },\n // colorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'WHITE_T_40',\n // },\n // },\n // 'white': {\n // backgroundColorName: {\n // inactive: 'WHITE_1',\n // active: 'BLACK_T_35',\n // disabled: 'BLACK_T_35',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // colorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // },\n // 'white-dark': {\n // backgroundColorName: {\n // inactive: 'WHITE_4',\n // active: 'WHITE_T_70',\n // disabled: 'WHITE_T_40',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'WHITE_T_40',\n // },\n // colorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'WHITE_T_40',\n // },\n // },\n // 'black': {\n // backgroundColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_T_60',\n // disabled: 'BLACK_T_35',\n // },\n // borderColorName: {\n // inactive: 'BLACK_4',\n // active: 'BLACK_4',\n // disabled: 'BLACK_T_35',\n // },\n // colorName: {\n // inactive: 'WHITE_4',\n // active: 'WHITE_4',\n // disabled: 'BLACK_T_35',\n // },\n // },\n // 'black-dark': {\n // backgroundColorName: {\n // inactive: 'BLACK_4',\n // active: 'WHITE_T_40',\n // disabled: 'WHITE_T_40',\n // },\n // borderColorName: {\n // inactive: 'WHITE_4',\n // active: 'WHITE_4',\n // disabled: 'WHITE_T_40',\n // },\n // colorName: {\n // inactive: 'WHITE_4',\n // active: 'WHITE_4',\n // disabled: 'WHITE_T_40',\n // },\n // },\n };\n\n return { sizes, variants };\n};\n\nexport default getButtonConfig;\n"],"names":["getButtonConfig","gutter"],"mappings":"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"}
|
@@ -1,5 +1,5 @@
|
|
1
|
-
const
|
2
|
-
const
|
1
|
+
const l = (a) => {
|
2
|
+
const o = {
|
3
3
|
regular: {
|
4
4
|
height: a * 2.75,
|
5
5
|
// height of input
|
@@ -51,7 +51,7 @@ const n = (a) => {
|
|
51
51
|
iconPadding: a * 0.5
|
52
52
|
// padding between left of icon and input
|
53
53
|
}
|
54
|
-
},
|
54
|
+
}, e = {
|
55
55
|
valueColorName: {
|
56
56
|
inactive: "BLACK",
|
57
57
|
active: "BLACK",
|
@@ -76,8 +76,8 @@ const n = (a) => {
|
|
76
76
|
disabled: 0.5,
|
77
77
|
enabled: 1
|
78
78
|
}
|
79
|
-
},
|
80
|
-
...
|
79
|
+
}, d = {
|
80
|
+
...e,
|
81
81
|
backgroundColorName: "GREY_1",
|
82
82
|
optionHoverColorName: "WHITE",
|
83
83
|
borderColorName: {
|
@@ -85,12 +85,38 @@ const n = (a) => {
|
|
85
85
|
inactive: "TRANSPARENT",
|
86
86
|
disabled: "TRANSPARENT"
|
87
87
|
}
|
88
|
-
},
|
89
|
-
|
90
|
-
|
88
|
+
}, i = {
|
89
|
+
opacity: e.opacity,
|
90
|
+
labelBackgroundColorName: "TRANSPARENT",
|
91
|
+
backgroundColorName: "TRANSPARENT",
|
92
|
+
errorMessageColorName: "ORANGE_4",
|
93
|
+
valueColorName: {
|
94
|
+
inactive: "WHITE",
|
95
|
+
active: "WHITE",
|
96
|
+
disabled: "WHITE_T_10"
|
97
|
+
},
|
98
|
+
borderColorName: {
|
99
|
+
inactive: "WHITE_T_15",
|
100
|
+
active: "WHITE",
|
101
|
+
disabled: "WHITE_T_15"
|
102
|
+
},
|
103
|
+
labelColorName: {
|
104
|
+
inactive: "WHITE_T_60",
|
105
|
+
active: "WHITE_T_60",
|
106
|
+
disabled: "WHITE_T_15"
|
107
|
+
},
|
108
|
+
messageColorName: {
|
109
|
+
inactive: "WHITE_T_60",
|
110
|
+
active: "WHITE_T_60",
|
111
|
+
disabled: "WHITE_T_15"
|
112
|
+
}
|
113
|
+
}, r = {
|
114
|
+
primary: e,
|
115
|
+
"primary-dark": i,
|
116
|
+
secondary: d,
|
91
117
|
success: {
|
92
|
-
opacity:
|
93
|
-
valueColorName:
|
118
|
+
opacity: e.opacity,
|
119
|
+
valueColorName: e.valueColorName,
|
94
120
|
borderColorName: {
|
95
121
|
inactive: "GREEN_5",
|
96
122
|
active: "GREEN_5",
|
@@ -107,9 +133,22 @@ const n = (a) => {
|
|
107
133
|
disabled: "GREEN_5"
|
108
134
|
}
|
109
135
|
},
|
136
|
+
"success-dark": {
|
137
|
+
...i,
|
138
|
+
borderColorName: {
|
139
|
+
inactive: "GREEN_4",
|
140
|
+
active: "GREEN_4",
|
141
|
+
disabled: "GREEN_4"
|
142
|
+
},
|
143
|
+
messageColorName: {
|
144
|
+
inactive: "GREEN_4",
|
145
|
+
active: "GREEN_4",
|
146
|
+
disabled: "GREEN_4"
|
147
|
+
}
|
148
|
+
},
|
110
149
|
error: {
|
111
|
-
opacity:
|
112
|
-
valueColorName:
|
150
|
+
opacity: e.opacity,
|
151
|
+
valueColorName: e.valueColorName,
|
113
152
|
borderColorName: {
|
114
153
|
inactive: "RED",
|
115
154
|
active: "RED",
|
@@ -125,11 +164,25 @@ const n = (a) => {
|
|
125
164
|
active: "RED",
|
126
165
|
disabled: "RED"
|
127
166
|
}
|
167
|
+
},
|
168
|
+
"error-dark": {
|
169
|
+
...i,
|
170
|
+
errorMessageColorName: "ORANGE_4",
|
171
|
+
borderColorName: {
|
172
|
+
inactive: "ORANGE_4",
|
173
|
+
active: "ORANGE_4",
|
174
|
+
disabled: "ORANGE_4"
|
175
|
+
},
|
176
|
+
messageColorName: {
|
177
|
+
inactive: "ORANGE_4",
|
178
|
+
active: "ORANGE_4",
|
179
|
+
disabled: "ORANGE_4"
|
180
|
+
}
|
128
181
|
}
|
129
182
|
};
|
130
|
-
return { sizes:
|
183
|
+
return { sizes: o, variants: r };
|
131
184
|
};
|
132
185
|
export {
|
133
|
-
|
186
|
+
l as default
|
134
187
|
};
|
135
188
|
//# sourceMappingURL=input.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"input.js","sources":["../../../../src/features/ui/theme/input.ts"],"sourcesContent":["import type { IInputSizeConfig, IInputVariantConfig, TInputSizes, TInputVariants } from '../types';\n\ninterface IGetInputConfig {\n (gutter: number): {\n sizes: Record<TInputSizes, IInputSizeConfig>;\n variants: Record<TInputVariants, IInputVariantConfig>;\n };\n}\nconst getInputConfig: IGetInputConfig = gutter => {\n const sizes: Record<TInputSizes, IInputSizeConfig> = {\n regular: {\n height: gutter * 2.75, // height of input\n marginTop: gutter * 0.5, // extra space when label is on top of input\n marginBottom: gutter * 1.5, // extra space for message comes on bottom of input\n paddingLeft: gutter,\n paddingRight: gutter * 0.75,\n borderRadius: gutter * 0.5,\n inputTextVariant: 'body1',\n labelTextVariant: 'body1',\n messageTextVariant: 'body3',\n iconsize: gutter * 1.5,\n iconPadding: gutter, // padding between left of icon and input\n },\n small: {\n height: gutter * 2.125, // height of input\n marginTop: gutter * 0.5, // extra space when label is on top of input\n marginBottom: 0, // extra space for message comes on bottom of input\n paddingLeft: gutter * 0.5,\n paddingRight: gutter * 0.5,\n borderRadius: gutter * 0.5,\n inputTextVariant: 'body3',\n labelTextVariant: 'body3',\n messageTextVariant: 'body3',\n iconsize: gutter * 1.25,\n iconPadding: gutter * 0.5, // padding between left of icon and input\n },\n xsmall: {\n height: gutter * 1.75, // height of input\n marginTop: 0, // extra space when label is on top of input\n marginBottom: 0, // extra space for message comes on bottom of input\n paddingLeft: gutter * 0.75,\n paddingRight: gutter * 0.5,\n borderRadius: gutter * 0.5,\n inputTextVariant: 'body3',\n labelTextVariant: 'body3',\n messageTextVariant: 'body3',\n iconsize: gutter,\n iconPadding: gutter * 0.5, // padding between left of icon and input\n },\n };\n const primaryVariant: IInputVariantConfig = {\n valueColorName: {\n inactive: 'BLACK',\n active: 'BLACK',\n disabled: 'BLACK_50',\n },\n borderColorName: {\n inactive: 'BLACK_T_15',\n active: 'BLACK_T_87',\n disabled: 'BLACK_T_15',\n },\n labelColorName: {\n inactive: 'BLACK_75',\n active: 'BLACK',\n disabled: 'BLACK_50',\n },\n messageColorName: {\n inactive: 'BLACK_75',\n active: 'BLACK_75',\n disabled: 'BLACK_50',\n },\n opacity: {\n disabled: 0.5,\n enabled: 1,\n },\n };\n\n const secondaryVariant: IInputVariantConfig = {\n ...primaryVariant,\n backgroundColorName: 'GREY_1',\n optionHoverColorName: 'WHITE',\n borderColorName: {\n active: 'TRANSPARENT',\n inactive: 'TRANSPARENT',\n disabled: 'TRANSPARENT',\n },\n };\n\n const variants: Record<TInputVariants, IInputVariantConfig> = {\n primary: primaryVariant,\n secondary: secondaryVariant,\n success: {\n opacity: primaryVariant.opacity,\n valueColorName: primaryVariant.valueColorName,\n borderColorName: {\n inactive: 'GREEN_5',\n active: 'GREEN_5',\n disabled: 'GREEN_5',\n },\n labelColorName: {\n inactive: 'GREEN_5',\n active: 'GREEN_5',\n disabled: 'GREEN_5',\n },\n messageColorName: {\n inactive: 'GREEN_5',\n active: 'GREEN_5',\n disabled: 'GREEN_5',\n },\n },\n error: {\n opacity: primaryVariant.opacity,\n valueColorName: primaryVariant.valueColorName,\n borderColorName: {\n inactive: 'RED',\n active: 'RED',\n disabled: 'RED',\n },\n labelColorName: {\n inactive: 'RED',\n active: 'RED',\n disabled: 'RED',\n },\n messageColorName: {\n inactive: 'RED',\n active: 'RED',\n disabled: 'RED',\n },\n },\n };\n\n return { sizes, variants };\n};\n\nexport default getInputConfig;\n"],"names":["getInputConfig","gutter","sizes","primaryVariant","secondaryVariant","variants"],"mappings":"AAQA,MAAMA,IAAkC,CAAUC,MAAA;AAChD,QAAMC,IAA+C;AAAA,IACnD,SAAS;AAAA,MACP,QAAQD,IAAS;AAAA;AAAA,MACjB,WAAWA,IAAS;AAAA;AAAA,MACpB,cAAcA,IAAS;AAAA;AAAA,MACvB,aAAaA;AAAA,MACb,cAAcA,IAAS;AAAA,MACvB,cAAcA,IAAS;AAAA,MACvB,kBAAkB;AAAA,MAClB,kBAAkB;AAAA,MAClB,oBAAoB;AAAA,MACpB,UAAUA,IAAS;AAAA,MACnB,aAAaA;AAAA;AAAA,IACf;AAAA,IACA,OAAO;AAAA,MACL,QAAQA,IAAS;AAAA;AAAA,MACjB,WAAWA,IAAS;AAAA;AAAA,MACpB,cAAc;AAAA;AAAA,MACd,aAAaA,IAAS;AAAA,MACtB,cAAcA,IAAS;AAAA,MACvB,cAAcA,IAAS;AAAA,MACvB,kBAAkB;AAAA,MAClB,kBAAkB;AAAA,MAClB,oBAAoB;AAAA,MACpB,UAAUA,IAAS;AAAA,MACnB,aAAaA,IAAS;AAAA;AAAA,IACxB;AAAA,IACA,QAAQ;AAAA,MACN,QAAQA,IAAS;AAAA;AAAA,MACjB,WAAW;AAAA;AAAA,MACX,cAAc;AAAA;AAAA,MACd,aAAaA,IAAS;AAAA,MACtB,cAAcA,IAAS;AAAA,MACvB,cAAcA,IAAS;AAAA,MACvB,kBAAkB;AAAA,MAClB,kBAAkB;AAAA,MAClB,oBAAoB;AAAA,MACpB,UAAUA;AAAA,MACV,aAAaA,IAAS;AAAA;AAAA,IACxB;AAAA,EAAA,GAEIE,IAAsC;AAAA,IAC1C,gBAAgB;AAAA,MACd,UAAU;AAAA,MACV,QAAQ;AAAA,MACR,UAAU;AAAA,IACZ;AAAA,IACA,iBAAiB;AAAA,MACf,UAAU;AAAA,MACV,QAAQ;AAAA,MACR,UAAU;AAAA,IACZ;AAAA,IACA,gBAAgB;AAAA,MACd,UAAU;AAAA,MACV,QAAQ;AAAA,MACR,UAAU;AAAA,IACZ;AAAA,IACA,kBAAkB;AAAA,MAChB,UAAU;AAAA,MACV,QAAQ;AAAA,MACR,UAAU;AAAA,IACZ;AAAA,IACA,SAAS;AAAA,MACP,UAAU;AAAA,MACV,SAAS;AAAA,IACX;AAAA,EAAA,GAGIC,IAAwC;AAAA,IAC5C,GAAGD;AAAA,IACH,qBAAqB;AAAA,IACrB,sBAAsB;AAAA,IACtB,iBAAiB;AAAA,MACf,QAAQ;AAAA,MACR,UAAU;AAAA,MACV,UAAU;AAAA,IACZ;AAAA,EAAA,
|
1
|
+
{"version":3,"file":"input.js","sources":["../../../../src/features/ui/theme/input.ts"],"sourcesContent":["import type { IInputSizeConfig, IInputVariantConfig, TInputSizes, TInputVariants } from '../types';\n\ninterface IGetInputConfig {\n (gutter: number): {\n sizes: Record<TInputSizes, IInputSizeConfig>;\n variants: Record<TInputVariants, IInputVariantConfig>;\n };\n}\nconst getInputConfig: IGetInputConfig = gutter => {\n const sizes: Record<TInputSizes, IInputSizeConfig> = {\n regular: {\n height: gutter * 2.75, // height of input\n marginTop: gutter * 0.5, // extra space when label is on top of input\n marginBottom: gutter * 1.5, // extra space for message comes on bottom of input\n paddingLeft: gutter,\n paddingRight: gutter * 0.75,\n borderRadius: gutter * 0.5,\n inputTextVariant: 'body1',\n labelTextVariant: 'body1',\n messageTextVariant: 'body3',\n iconsize: gutter * 1.5,\n iconPadding: gutter, // padding between left of icon and input\n },\n small: {\n height: gutter * 2.125, // height of input\n marginTop: gutter * 0.5, // extra space when label is on top of input\n marginBottom: 0, // extra space for message comes on bottom of input\n paddingLeft: gutter * 0.5,\n paddingRight: gutter * 0.5,\n borderRadius: gutter * 0.5,\n inputTextVariant: 'body3',\n labelTextVariant: 'body3',\n messageTextVariant: 'body3',\n iconsize: gutter * 1.25,\n iconPadding: gutter * 0.5, // padding between left of icon and input\n },\n xsmall: {\n height: gutter * 1.75, // height of input\n marginTop: 0, // extra space when label is on top of input\n marginBottom: 0, // extra space for message comes on bottom of input\n paddingLeft: gutter * 0.75,\n paddingRight: gutter * 0.5,\n borderRadius: gutter * 0.5,\n inputTextVariant: 'body3',\n labelTextVariant: 'body3',\n messageTextVariant: 'body3',\n iconsize: gutter,\n iconPadding: gutter * 0.5, // padding between left of icon and input\n },\n };\n const primaryVariant: IInputVariantConfig = {\n valueColorName: {\n inactive: 'BLACK',\n active: 'BLACK',\n disabled: 'BLACK_50',\n },\n borderColorName: {\n inactive: 'BLACK_T_15',\n active: 'BLACK_T_87',\n disabled: 'BLACK_T_15',\n },\n labelColorName: {\n inactive: 'BLACK_75',\n active: 'BLACK',\n disabled: 'BLACK_50',\n },\n messageColorName: {\n inactive: 'BLACK_75',\n active: 'BLACK_75',\n disabled: 'BLACK_50',\n },\n opacity: {\n disabled: 0.5,\n enabled: 1,\n },\n };\n\n const secondaryVariant: IInputVariantConfig = {\n ...primaryVariant,\n backgroundColorName: 'GREY_1',\n optionHoverColorName: 'WHITE',\n borderColorName: {\n active: 'TRANSPARENT',\n inactive: 'TRANSPARENT',\n disabled: 'TRANSPARENT',\n },\n };\n const primaryDarkVariant: IInputVariantConfig = {\n opacity: primaryVariant.opacity,\n labelBackgroundColorName: 'TRANSPARENT',\n backgroundColorName: 'TRANSPARENT',\n errorMessageColorName: 'ORANGE_4',\n valueColorName: {\n inactive: 'WHITE',\n active: 'WHITE',\n disabled: 'WHITE_T_10',\n },\n borderColorName: {\n inactive: 'WHITE_T_15',\n active: 'WHITE',\n disabled: 'WHITE_T_15',\n },\n labelColorName: {\n inactive: 'WHITE_T_60',\n active: 'WHITE_T_60',\n disabled: 'WHITE_T_15',\n },\n messageColorName: {\n inactive: 'WHITE_T_60',\n active: 'WHITE_T_60',\n disabled: 'WHITE_T_15',\n },\n };\n\n const variants: Record<TInputVariants, IInputVariantConfig> = {\n 'primary': primaryVariant,\n 'primary-dark': primaryDarkVariant,\n 'secondary': secondaryVariant,\n 'success': {\n opacity: primaryVariant.opacity,\n valueColorName: primaryVariant.valueColorName,\n borderColorName: {\n inactive: 'GREEN_5',\n active: 'GREEN_5',\n disabled: 'GREEN_5',\n },\n labelColorName: {\n inactive: 'GREEN_5',\n active: 'GREEN_5',\n disabled: 'GREEN_5',\n },\n messageColorName: {\n inactive: 'GREEN_5',\n active: 'GREEN_5',\n disabled: 'GREEN_5',\n },\n },\n 'success-dark': {\n ...primaryDarkVariant,\n borderColorName: {\n inactive: 'GREEN_4',\n active: 'GREEN_4',\n disabled: 'GREEN_4',\n },\n messageColorName: {\n inactive: 'GREEN_4',\n active: 'GREEN_4',\n disabled: 'GREEN_4',\n },\n },\n 'error': {\n opacity: primaryVariant.opacity,\n valueColorName: primaryVariant.valueColorName,\n borderColorName: {\n inactive: 'RED',\n active: 'RED',\n disabled: 'RED',\n },\n labelColorName: {\n inactive: 'RED',\n active: 'RED',\n disabled: 'RED',\n },\n messageColorName: {\n inactive: 'RED',\n active: 'RED',\n disabled: 'RED',\n },\n },\n 'error-dark': {\n ...primaryDarkVariant,\n errorMessageColorName: 'ORANGE_4',\n borderColorName: {\n inactive: 'ORANGE_4',\n active: 'ORANGE_4',\n disabled: 'ORANGE_4',\n },\n messageColorName: {\n inactive: 'ORANGE_4',\n active: 'ORANGE_4',\n disabled: 'ORANGE_4',\n },\n },\n };\n\n return { sizes, variants };\n};\n\nexport default getInputConfig;\n"],"names":["getInputConfig","gutter","sizes","primaryVariant","secondaryVariant","primaryDarkVariant","variants"],"mappings":"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"}
|
package/dist/index.d.ts
CHANGED
@@ -11,6 +11,7 @@ import { ForwardRefExoticComponent } from 'react';
|
|
11
11
|
import { HTMLAttributes } from 'react';
|
12
12
|
import { IChannelMessage } from '@cuemath/cue-message-broker';
|
13
13
|
import type { IframeHTMLAttributes } from 'react';
|
14
|
+
import type { ImgHTMLAttributes } from 'react';
|
14
15
|
import type { InputHTMLAttributes } from 'react';
|
15
16
|
import { IProvidedProps } from 'google-maps-react';
|
16
17
|
import { IStyledComponent } from 'styled-components';
|
@@ -50,6 +51,8 @@ export declare const AchievementShareInstructionModal: React_2.FC<IShareInstruct
|
|
50
51
|
|
51
52
|
export declare const AlertIcon: React_2.FC<React_2.SVGProps<SVGSVGElement>>;
|
52
53
|
|
54
|
+
export declare const AnimatedArc: React_2.FC<IAnimatedArcProps>;
|
55
|
+
|
53
56
|
export declare const AppLoader: FC<IAppLoaderProps>;
|
54
57
|
|
55
58
|
export declare const ArcButton: MemoExoticComponent<ForwardRefExoticComponent<IArcButtonProps & {
|
@@ -495,6 +498,18 @@ declare interface IActionData {
|
|
495
498
|
dimension?: IViewport;
|
496
499
|
}
|
497
500
|
|
501
|
+
declare interface IAnimatedArcProps {
|
502
|
+
radius: number;
|
503
|
+
strokeWidth: number;
|
504
|
+
color: TColorNames;
|
505
|
+
targetAngle: number;
|
506
|
+
startAngle?: number;
|
507
|
+
mode?: 'draw' | 'fade';
|
508
|
+
duration?: number;
|
509
|
+
delay?: number;
|
510
|
+
showAnimatedRainbowArc?: boolean;
|
511
|
+
}
|
512
|
+
|
498
513
|
declare interface IAppLoaderProps {
|
499
514
|
width?: string | number;
|
500
515
|
height?: string | number;
|
@@ -565,6 +580,7 @@ declare interface IBaseInputProps {
|
|
565
580
|
canSiblingInteract?: boolean;
|
566
581
|
willShowMessage?: boolean;
|
567
582
|
errorMessage?: string;
|
583
|
+
helperText?: string;
|
568
584
|
mandatory?: boolean;
|
569
585
|
shape?: TInputShapes;
|
570
586
|
isTransparent?: boolean;
|
@@ -936,6 +952,7 @@ declare interface IContextMenuProps {
|
|
936
952
|
menuZIndex?: number;
|
937
953
|
startLeft?: boolean;
|
938
954
|
placeTop?: boolean;
|
955
|
+
onMenuVisibilityChange?: (visible: boolean) => void;
|
939
956
|
}
|
940
957
|
|
941
958
|
declare interface ICountdownTimer {
|
@@ -1229,6 +1246,12 @@ declare interface IIconButtonProps extends Omit<IButtonProps, 'label' | 'shape'
|
|
1229
1246
|
renderAs: TButtonVariants;
|
1230
1247
|
}
|
1231
1248
|
|
1249
|
+
declare interface IImageProps extends ImgHTMLAttributes<HTMLImageElement> {
|
1250
|
+
withLoader: boolean;
|
1251
|
+
borderRadius?: number;
|
1252
|
+
borderColor?: TColorNames;
|
1253
|
+
}
|
1254
|
+
|
1232
1255
|
export declare interface IInfoMessage {
|
1233
1256
|
message: string;
|
1234
1257
|
position: 'top' | 'bottom';
|
@@ -1275,6 +1298,8 @@ export declare interface IInputVariantConfig {
|
|
1275
1298
|
};
|
1276
1299
|
backgroundColorName?: TColorNames;
|
1277
1300
|
optionHoverColorName?: TColorNames;
|
1301
|
+
labelBackgroundColorName?: TColorNames;
|
1302
|
+
errorMessageColorName?: TColorNames;
|
1278
1303
|
}
|
1279
1304
|
|
1280
1305
|
declare interface IIsOkayTypeQuestion {
|
@@ -1733,6 +1758,9 @@ declare interface ILPARSheetCallbacks extends ISATSheetItemCallbacks {
|
|
1733
1758
|
onReview?: (sheet: TLPARSheetData) => void;
|
1734
1759
|
}
|
1735
1760
|
|
1761
|
+
declare const Image_2: React.FC<IImageProps>;
|
1762
|
+
export { Image_2 as Image }
|
1763
|
+
|
1736
1764
|
export declare const ImageIcon: React.FC<React.SVGProps<SVGSVGElement>>;
|
1737
1765
|
|
1738
1766
|
export declare const IMAGES: {
|
@@ -4053,7 +4081,7 @@ declare type TBlockType = keyof typeof BLOCK_TYPE;
|
|
4053
4081
|
|
4054
4082
|
export declare type TButtonSizes = 'xsmall' | 'small' | 'regular' | 'medium' | 'large';
|
4055
4083
|
|
4056
|
-
export declare type TButtonVariants = 'primary' | 'secondary' | 'tertiary';
|
4084
|
+
export declare type TButtonVariants = 'primary' | 'secondary' | 'tertiary' | 'secondary-dark';
|
4057
4085
|
|
4058
4086
|
declare type TCallback = (messages: TInclassMessage[]) => void;
|
4059
4087
|
|
@@ -4197,6 +4225,7 @@ declare interface TextProps {
|
|
4197
4225
|
$marginBottomX?: number;
|
4198
4226
|
$inline?: boolean;
|
4199
4227
|
$textDecoration?: string;
|
4228
|
+
$whiteSpace?: 'pre-line' | 'normal' | 'pre-wrap' | 'no-wrap' | 'pre' | 'break-spaces';
|
4200
4229
|
}
|
4201
4230
|
|
4202
4231
|
export declare type TFontFamilyNames = `${'Athletics'}-${'Light' | 'Regular' | 'Medium' | 'Bold' | 'Black'}` | `${'UntitledSans'}-${'Regular' | 'Medium'}`;
|
@@ -4422,7 +4451,7 @@ export declare type TInputShapes = 'border' | 'borderLess' | 'curved';
|
|
4422
4451
|
|
4423
4452
|
export declare type TInputSizes = 'small' | 'regular' | 'xsmall';
|
4424
4453
|
|
4425
|
-
export declare type TInputVariants = 'primary' | 'secondary' | 'success' | 'error';
|
4454
|
+
export declare type TInputVariants = 'primary' | 'secondary' | 'success' | 'error' | 'primary-dark' | 'success-dark' | 'error-dark';
|
4426
4455
|
|
4427
4456
|
declare type TInstructorStimulus = 'SystemIntro' | 'Intro' | 'Concept-Intro' | 'Instruction' | 'Task' | 'Try' | 'Learn' | 'Apply';
|
4428
4457
|
|