@laerdal/life-react-components 1.5.1-dev.33.full → 1.5.1-dev.34
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/Card/CardBottomSection.cjs +9 -13
- package/dist/Card/CardBottomSection.cjs.map +1 -1
- package/dist/Card/CardBottomSection.d.ts +1 -1
- package/dist/Card/CardBottomSection.js +9 -12
- package/dist/Card/CardBottomSection.js.map +1 -1
- package/dist/Card/CardMiddleSection.cjs +3 -7
- package/dist/Card/CardMiddleSection.cjs.map +1 -1
- package/dist/Card/CardMiddleSection.js +3 -7
- package/dist/Card/CardMiddleSection.js.map +1 -1
- package/dist/Card/CardTopSection.cjs +1 -1
- package/dist/Card/CardTopSection.cjs.map +1 -1
- package/dist/Card/CardTopSection.js +1 -1
- package/dist/Card/CardTopSection.js.map +1 -1
- package/dist/index.cjs +47 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -19,8 +19,6 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
|
19
19
|
|
|
20
20
|
var _ = require("..");
|
|
21
21
|
|
|
22
|
-
var _assets = require("../assets");
|
|
23
|
-
|
|
24
22
|
var _Button = require("../Button");
|
|
25
23
|
|
|
26
24
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
@@ -31,15 +29,15 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
31
29
|
|
|
32
30
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
33
31
|
|
|
34
|
-
var ProgressContainer = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)([""])));
|
|
32
|
+
var ProgressContainer = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n padding: 8px 0;\n"])));
|
|
35
33
|
|
|
36
|
-
var NotesContainer = _styledComponents.default.div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n height:
|
|
34
|
+
var NotesContainer = _styledComponents.default.div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n height: 48px;\n position: relative;\n color: ", ";\n display: flex;\n flex-direction: row;\n align-items: center;\n"])), _.COLORS.neutral_500);
|
|
37
35
|
|
|
38
|
-
var AuthorContainer = _styledComponents.default.div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n
|
|
39
|
-
return props.disabled ? "\n color: ".concat(_.COLORS.neutral_300, ";\n
|
|
36
|
+
var AuthorContainer = _styledComponents.default.div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n flex-direction: row;\n align-items: center;\n height: 48px;\n\n div:first-child {\n flex-grow: 2;\n }\n\n svg, img {\n width: 80px;\n }\n\n ", "\n"])), function (props) {
|
|
37
|
+
return props.disabled ? "\n color: ".concat(_.COLORS.neutral_300, ";\n svg, img {\n filter: grayscale(100%);\n }\n \n ") : '';
|
|
40
38
|
});
|
|
41
39
|
|
|
42
|
-
var Divider = _styledComponents.default.div(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2.default)(["\n border-top: 1px;\n border-top-color: ", ";\n border-top-style: solid;\n width: 100%;\n
|
|
40
|
+
var Divider = _styledComponents.default.div(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2.default)(["\n border-top: 1px;\n border-top-color: ", ";\n border-top-style: solid;\n width: 100%;\n"])), _.COLORS.neutral_100);
|
|
43
41
|
|
|
44
42
|
var NoteLeft = _styledComponents.default.div(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2.default)(["\n position: absolute;\n top: 0px;\n left: 0px;\n display: flex;\n flex-direction: row;\n align-items: center;\n\n svg {\n margin-right: 4px;\n }\n"])));
|
|
45
43
|
|
|
@@ -64,6 +62,7 @@ var CardBottomSection = function CardBottomSection(_ref) {
|
|
|
64
62
|
noteRight = _ref.noteRight,
|
|
65
63
|
noteRightIcon = _ref.noteRightIcon,
|
|
66
64
|
authorName = _ref.authorName,
|
|
65
|
+
logo = _ref.logo,
|
|
67
66
|
actions = _ref.actions,
|
|
68
67
|
disabled = _ref.disabled;
|
|
69
68
|
var haveAtLeastSomething = progressLevel != undefined || noteLeft || noteLeftIcon || noteRight || noteRightIcon || authorName;
|
|
@@ -92,14 +91,11 @@ var CardBottomSection = function CardBottomSection(_ref) {
|
|
|
92
91
|
children: noteRight
|
|
93
92
|
})]
|
|
94
93
|
})]
|
|
95
|
-
}), authorName && /*#__PURE__*/(0, _jsxRuntime.jsxs)(AuthorContainer, {
|
|
94
|
+
}), (authorName || logo) && /*#__PURE__*/(0, _jsxRuntime.jsxs)(AuthorContainer, {
|
|
96
95
|
disabled: disabled,
|
|
97
96
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_.ComponentXXS, {
|
|
98
97
|
children: authorName
|
|
99
|
-
}),
|
|
100
|
-
width: "80px",
|
|
101
|
-
height: "43px"
|
|
102
|
-
})]
|
|
98
|
+
}), logo]
|
|
103
99
|
}), actions && /*#__PURE__*/(0, _jsxRuntime.jsx)(ButtonRowContainer, {
|
|
104
100
|
children: actions.map(function (x) {
|
|
105
101
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Button.IconButton, {
|
|
@@ -129,7 +125,7 @@ CardBottomSection.propTypes = {
|
|
|
129
125
|
icon: _propTypes.default.node.isRequired,
|
|
130
126
|
onClick: _propTypes.default.func.isRequired
|
|
131
127
|
})),
|
|
132
|
-
|
|
128
|
+
logo: _propTypes.default.node,
|
|
133
129
|
disabled: _propTypes.default.bool.isRequired
|
|
134
130
|
};
|
|
135
131
|
var _default = CardBottomSection;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/Card/CardBottomSection.tsx"],"names":["ProgressContainer","styled","div","NotesContainer","COLORS","neutral_500","AuthorContainer","props","disabled","neutral_300","Divider","neutral_100","NoteLeft","NoteRight","ButtonRowContainer","neutral_600","Container","interactionType","InteractionType","Clickable","CardBottomSection","progressLevel","progressMax","progressType","LinearProgressType","Line","noteLeft","noteLeftIcon","noteRight","noteRightIcon","authorName","actions","haveAtLeastSomething","undefined","Size","Small","LinearProgressVariant","Normal","ComponentTextStyle","Bold","map","x","e","stopPropagation","onClick","icon"
|
|
1
|
+
{"version":3,"sources":["../../src/Card/CardBottomSection.tsx"],"names":["ProgressContainer","styled","div","NotesContainer","COLORS","neutral_500","AuthorContainer","props","disabled","neutral_300","Divider","neutral_100","NoteLeft","NoteRight","ButtonRowContainer","neutral_600","Container","interactionType","InteractionType","Clickable","CardBottomSection","progressLevel","progressMax","progressType","LinearProgressType","Line","noteLeft","noteLeftIcon","noteRight","noteRightIcon","authorName","logo","actions","haveAtLeastSomething","undefined","Size","Small","LinearProgressVariant","Normal","ComponentTextStyle","Bold","map","x","e","stopPropagation","onClick","icon"],"mappings":";;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AAEA;;;;;;;;;;AAwBA,IAAMA,iBAAiB,GAAGC,0BAAOC,GAAV,wGAAvB;;AAIA,IAAMC,cAAc,GAAGF,0BAAOC,GAAV,kNAGTE,SAAOC,WAHE,CAApB;;AASA,IAAMC,eAAe,GAAGL,0BAAOC,GAAV,2QAcjB,UAAAK,KAAK;AAAA,SAAI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C,IAFsB;AAAA,MAzB3B,EA8BGC,OAAO,iBAAI,qBAAC,kBAAD;AAAA,gBACTA,OAAO,CAACS,GAAR,CAAY,UAAAC,CAAC;AAAA,4BACZ,qBAAC,kBAAD;AAAY,UAAA,QAAQ,EAAElC,QAAtB;AAAgC,UAAA,OAAO,EAAC,WAAxC;AAAoD,UAAA,KAAK,EAAC,UAA1D;AAAqE,UAAA,MAAM,EAAE,gBAACmC,CAAD,EAAO;AAACA,YAAAA,CAAC,SAAD,IAAAA,CAAC,WAAD,YAAAA,CAAC,CAAEC,eAAH;AAAsBF,YAAAA,CAAC,CAACG,OAAF;AAAa,WAAxH;AAAA,oBACGH,CAAC,CAACI;AADL,UADY;AAAA,OAAb;AADS,MA9Bd;AAAA,IADF;AAwCD,CAxDD;;;AArHEzB,EAAAA,a;AACAC,EAAAA,W;AAGAI,EAAAA,Q;AACAC,EAAAA,Y;AACAC,EAAAA,S;AACAC,EAAAA,a;AAEAC,EAAAA,U;AACAE,EAAAA,O;AAhBAc,IAAAA,I;AACAD,IAAAA,O;;AAgBAd,EAAAA,I;AACAvB,EAAAA,Q;;eAmKaY,iB","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { COLORS, ComponentTextStyle, ComponentXXS, InteractionType, LinearProgress, LinearProgressType, LinearProgressVariant, Size } from '..';\nimport { LaerdalLogo } from '../assets';\nimport { IconButton } from '../Button';\n\nexport interface ActionItem {\n icon: React.ReactNode;\n onClick: () => void;\n}\n\nexport interface CardBottomSectionProps {\n interactionType: InteractionType;\n progressLevel?: number;\n progressMax?: number;\n progressType?: LinearProgressType;\n\n noteLeft?: string;\n noteLeftIcon?: React.ReactNode;\n noteRight?: string;\n noteRightIcon?: React.ReactNode;\n \n authorName?: string;\n actions?: ActionItem[];\n logo?: React.ReactNode;\n disabled: boolean;\n}\n\nconst ProgressContainer = styled.div`\n padding: 8px 0;\n`;\n\nconst NotesContainer = styled.div`\n height: 48px;\n position: relative;\n color: ${COLORS.neutral_500};\n display: flex;\n flex-direction: row;\n align-items: center;\n`;\n\nconst AuthorContainer = styled.div<{disabled: boolean}>`\n display: flex;\n flex-direction: row;\n align-items: center;\n height: 48px;\n\n div:first-child {\n flex-grow: 2;\n }\n\n svg, img {\n width: 80px;\n }\n\n ${props => props.disabled ? `\n color: ${COLORS.neutral_300};\n svg, img {\n filter: grayscale(100%);\n }\n \n ` : ''}\n`;\n\nconst Divider = styled.div`\n border-top: 1px;\n border-top-color: ${COLORS.neutral_100};\n border-top-style: solid;\n width: 100%;\n`;\n\nconst NoteLeft = styled.div`\n position: absolute;\n top: 0px;\n left: 0px;\n display: flex;\n flex-direction: row;\n align-items: center;\n\n svg {\n margin-right: 4px;\n }\n`;\n\nconst NoteRight = styled.div`\n position: absolute;\n top: 0px;\n right: 0px;\n display: flex;\n flex-direction: row;\n align-items: center;\n\n svg {\n margin-right: 4px;\n }\n`;\n\nconst ButtonRowContainer = styled.div`\n display: flex;\n flex-direction: row;\n justify-content: flex-end;\n align-items: center;\n border-top: 1px;\n border-top-color: ${COLORS.neutral_100};\n border-top-style: solid;\n\n button:last-child{\n margin: 8px 0px 0px 0px;\n }\n\n button:not(:last-child) {\n margin: 8px 0px 0px 0px;\n }\n\n svg {\n color: ${COLORS.neutral_600};\n }\n`;\n\nconst Container = styled.div<{interactionType: InteractionType; disabled: boolean}>`\n padding: 0px 16px 8px 16px;\n width: calc(100% - 32px);\n cursor: ${props => props.disabled ? 'not-allowed' : 'pointer'};\n\n ${ButtonRowContainer} {\n ${props => props.interactionType == InteractionType.Clickable ? \n `cursor: ${props.disabled ? 'not-allowed' : 'auto'};` : ''}\n }\n`;\n\nconst CardBottomSection: React.FunctionComponent<CardBottomSectionProps> = ({\n interactionType,\n progressLevel,\n progressMax,\n progressType = LinearProgressType.Line,\n noteLeft,\n noteLeftIcon,\n noteRight,\n noteRightIcon,\n authorName,\n logo,\n actions,\n disabled\n}: CardBottomSectionProps) => {\n\n const haveAtLeastSomething = progressLevel != undefined || noteLeft || noteLeftIcon || noteRight || noteRightIcon || authorName;\n return (\n <Container disabled={disabled} interactionType={interactionType}>\n {haveAtLeastSomething && <Divider />}\n {progressLevel != undefined && <ProgressContainer>\n <LinearProgress size={Size.Small}\n type={progressType}\n variant={LinearProgressVariant.Normal}\n value={progressLevel}\n max={progressMax ?? progressLevel} />\n </ProgressContainer>}\n\n {(noteLeft || noteLeftIcon || noteRight || noteRightIcon) && <NotesContainer>\n {(noteLeft || noteLeftIcon) && (\n <NoteLeft>\n {noteLeftIcon}\n <ComponentXXS color={COLORS.neutral_500} textStyle={ComponentTextStyle.Bold}>{noteLeft}</ComponentXXS>\n </NoteLeft>\n )}\n {(noteRight || noteRightIcon) && (\n <NoteRight>\n {noteRightIcon}\n <ComponentXXS color={COLORS.neutral_500} textStyle={ComponentTextStyle.Bold}>{noteRight}</ComponentXXS>\n </NoteRight>\n )}\n </NotesContainer>}\n\n {(authorName || logo) && <AuthorContainer disabled={disabled}>\n <ComponentXXS>{authorName}</ComponentXXS>\n {logo}\n </AuthorContainer>}\n\n {actions && <ButtonRowContainer>\n {actions.map(x => (\n <IconButton disabled={disabled} variant=\"secondary\" shape=\"circular\" action={(e) => {e?.stopPropagation(); x.onClick();}}>\n {x.icon}\n </IconButton>\n ))}\n </ButtonRowContainer>}\n </Container>\n );\n};\n\nexport default CardBottomSection;\n"],"file":"CardBottomSection.cjs"}
|
|
@@ -15,7 +15,7 @@ export interface CardBottomSectionProps {
|
|
|
15
15
|
noteRightIcon?: React.ReactNode;
|
|
16
16
|
authorName?: string;
|
|
17
17
|
actions?: ActionItem[];
|
|
18
|
-
|
|
18
|
+
logo?: React.ReactNode;
|
|
19
19
|
disabled: boolean;
|
|
20
20
|
}
|
|
21
21
|
declare const CardBottomSection: React.FunctionComponent<CardBottomSectionProps>;
|
|
@@ -6,16 +6,15 @@ var _templateObject, _templateObject2, _templateObject3, _templateObject4, _temp
|
|
|
6
6
|
import * as React from 'react';
|
|
7
7
|
import styled from 'styled-components';
|
|
8
8
|
import { COLORS, ComponentTextStyle, ComponentXXS, InteractionType, LinearProgress, LinearProgressType, LinearProgressVariant, Size } from '..';
|
|
9
|
-
import { LaerdalLogo } from '../assets';
|
|
10
9
|
import { IconButton } from '../Button';
|
|
11
10
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
12
11
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
-
var ProgressContainer = styled.div(_templateObject || (_templateObject = _taggedTemplateLiteral([""])));
|
|
14
|
-
var NotesContainer = styled.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n height:
|
|
15
|
-
var AuthorContainer = styled.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n
|
|
16
|
-
return props.disabled ? "\n color: ".concat(COLORS.neutral_300, ";\n
|
|
12
|
+
var ProgressContainer = styled.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n padding: 8px 0;\n"])));
|
|
13
|
+
var NotesContainer = styled.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n height: 48px;\n position: relative;\n color: ", ";\n display: flex;\n flex-direction: row;\n align-items: center;\n"])), COLORS.neutral_500);
|
|
14
|
+
var AuthorContainer = styled.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n align-items: center;\n height: 48px;\n\n div:first-child {\n flex-grow: 2;\n }\n\n svg, img {\n width: 80px;\n }\n\n ", "\n"])), function (props) {
|
|
15
|
+
return props.disabled ? "\n color: ".concat(COLORS.neutral_300, ";\n svg, img {\n filter: grayscale(100%);\n }\n \n ") : '';
|
|
17
16
|
});
|
|
18
|
-
var Divider = styled.div(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n border-top: 1px;\n border-top-color: ", ";\n border-top-style: solid;\n width: 100%;\n
|
|
17
|
+
var Divider = styled.div(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n border-top: 1px;\n border-top-color: ", ";\n border-top-style: solid;\n width: 100%;\n"])), COLORS.neutral_100);
|
|
19
18
|
var NoteLeft = styled.div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n position: absolute;\n top: 0px;\n left: 0px;\n display: flex;\n flex-direction: row;\n align-items: center;\n\n svg {\n margin-right: 4px;\n }\n"])));
|
|
20
19
|
var NoteRight = styled.div(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n position: absolute;\n top: 0px;\n right: 0px;\n display: flex;\n flex-direction: row;\n align-items: center;\n\n svg {\n margin-right: 4px;\n }\n"])));
|
|
21
20
|
var ButtonRowContainer = styled.div(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n justify-content: flex-end;\n align-items: center;\n border-top: 1px;\n border-top-color: ", ";\n border-top-style: solid;\n\n button:last-child{\n margin: 8px 0px 0px 0px;\n }\n\n button:not(:last-child) {\n margin: 8px 0px 0px 0px;\n }\n\n svg {\n color: ", ";\n }\n"])), COLORS.neutral_100, COLORS.neutral_600);
|
|
@@ -36,6 +35,7 @@ var CardBottomSection = function CardBottomSection(_ref) {
|
|
|
36
35
|
noteRight = _ref.noteRight,
|
|
37
36
|
noteRightIcon = _ref.noteRightIcon,
|
|
38
37
|
authorName = _ref.authorName,
|
|
38
|
+
logo = _ref.logo,
|
|
39
39
|
actions = _ref.actions,
|
|
40
40
|
disabled = _ref.disabled;
|
|
41
41
|
var haveAtLeastSomething = progressLevel != undefined || noteLeft || noteLeftIcon || noteRight || noteRightIcon || authorName;
|
|
@@ -64,14 +64,11 @@ var CardBottomSection = function CardBottomSection(_ref) {
|
|
|
64
64
|
children: noteRight
|
|
65
65
|
})]
|
|
66
66
|
})]
|
|
67
|
-
}), authorName && /*#__PURE__*/_jsxs(AuthorContainer, {
|
|
67
|
+
}), (authorName || logo) && /*#__PURE__*/_jsxs(AuthorContainer, {
|
|
68
68
|
disabled: disabled,
|
|
69
69
|
children: [/*#__PURE__*/_jsx(ComponentXXS, {
|
|
70
70
|
children: authorName
|
|
71
|
-
}),
|
|
72
|
-
width: "80px",
|
|
73
|
-
height: "43px"
|
|
74
|
-
})]
|
|
71
|
+
}), logo]
|
|
75
72
|
}), actions && /*#__PURE__*/_jsx(ButtonRowContainer, {
|
|
76
73
|
children: actions.map(function (x) {
|
|
77
74
|
return /*#__PURE__*/_jsx(IconButton, {
|
|
@@ -101,7 +98,7 @@ CardBottomSection.propTypes = {
|
|
|
101
98
|
icon: _pt.node.isRequired,
|
|
102
99
|
onClick: _pt.func.isRequired
|
|
103
100
|
})),
|
|
104
|
-
|
|
101
|
+
logo: _pt.node,
|
|
105
102
|
disabled: _pt.bool.isRequired
|
|
106
103
|
};
|
|
107
104
|
export default CardBottomSection;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/Card/CardBottomSection.tsx"],"names":["React","styled","COLORS","ComponentTextStyle","ComponentXXS","InteractionType","LinearProgress","LinearProgressType","LinearProgressVariant","Size","
|
|
1
|
+
{"version":3,"sources":["../../src/Card/CardBottomSection.tsx"],"names":["React","styled","COLORS","ComponentTextStyle","ComponentXXS","InteractionType","LinearProgress","LinearProgressType","LinearProgressVariant","Size","IconButton","ProgressContainer","div","NotesContainer","neutral_500","AuthorContainer","props","disabled","neutral_300","Divider","neutral_100","NoteLeft","NoteRight","ButtonRowContainer","neutral_600","Container","interactionType","Clickable","CardBottomSection","progressLevel","progressMax","progressType","Line","noteLeft","noteLeftIcon","noteRight","noteRightIcon","authorName","logo","actions","haveAtLeastSomething","undefined","Small","Normal","Bold","map","x","e","stopPropagation","onClick","icon"],"mappings":";;;;;AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAASC,MAAT,EAAiBC,kBAAjB,EAAqCC,YAArC,EAAmDC,eAAnD,EAAoEC,cAApE,EAAoFC,kBAApF,EAAwGC,qBAAxG,EAA+HC,IAA/H,QAA2I,IAA3I;AAEA,SAASC,UAAT,QAA2B,WAA3B;;;AAwBA,IAAMC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Y,WAA5B;AAAyC,UAAA,SAAS,EAAEX,kBAAkB,CAACyC,IAAvE;AAAA,oBAA8ET;AAA9E,UAFF;AAAA,QARyD;AAAA,MAV/D,EAyBG,CAACE,UAAU,IAAIC,IAAf,kBAAwB,MAAC,eAAD;AAAiB,MAAA,QAAQ,EAAErB,QAA3B;AAAA,8BACvB,KAAC,YAAD;AAAA,kBAAeoB;AAAf,QADuB,EAEtBC,IAFsB;AAAA,MAzB3B,EA8BGC,OAAO,iBAAI,KAAC,kBAAD;AAAA,gBACTA,OAAO,CAACM,GAAR,CAAY,UAAAC,CAAC;AAAA,4BACZ,KAAC,UAAD;AAAY,UAAA,QAAQ,EAAE7B,QAAtB;AAAgC,UAAA,OAAO,EAAC,WAAxC;AAAoD,UAAA,KAAK,EAAC,UAA1D;AAAqE,UAAA,MAAM,EAAE,gBAAC8B,CAAD,EAAO;AAACA,YAAAA,CAAC,SAAD,IAAAA,CAAC,WAAD,YAAAA,CAAC,CAAEC,eAAH;AAAsBF,YAAAA,CAAC,CAACG,OAAF;AAAa,WAAxH;AAAA,oBACGH,CAAC,CAACI;AADL,UADY;AAAA,OAAb;AADS,MA9Bd;AAAA,IADF;AAwCD,CAxDD;;;AArHErB,EAAAA,a;AACAC,EAAAA,W;AAGAG,EAAAA,Q;AACAC,EAAAA,Y;AACAC,EAAAA,S;AACAC,EAAAA,a;AAEAC,EAAAA,U;AACAE,EAAAA,O;AAhBAW,IAAAA,I;AACAD,IAAAA,O;;AAgBAX,EAAAA,I;AACArB,EAAAA,Q;;AAmKF,eAAeW,iBAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { COLORS, ComponentTextStyle, ComponentXXS, InteractionType, LinearProgress, LinearProgressType, LinearProgressVariant, Size } from '..';\nimport { LaerdalLogo } from '../assets';\nimport { IconButton } from '../Button';\n\nexport interface ActionItem {\n icon: React.ReactNode;\n onClick: () => void;\n}\n\nexport interface CardBottomSectionProps {\n interactionType: InteractionType;\n progressLevel?: number;\n progressMax?: number;\n progressType?: LinearProgressType;\n\n noteLeft?: string;\n noteLeftIcon?: React.ReactNode;\n noteRight?: string;\n noteRightIcon?: React.ReactNode;\n \n authorName?: string;\n actions?: ActionItem[];\n logo?: React.ReactNode;\n disabled: boolean;\n}\n\nconst ProgressContainer = styled.div`\n padding: 8px 0;\n`;\n\nconst NotesContainer = styled.div`\n height: 48px;\n position: relative;\n color: ${COLORS.neutral_500};\n display: flex;\n flex-direction: row;\n align-items: center;\n`;\n\nconst AuthorContainer = styled.div<{disabled: boolean}>`\n display: flex;\n flex-direction: row;\n align-items: center;\n height: 48px;\n\n div:first-child {\n flex-grow: 2;\n }\n\n svg, img {\n width: 80px;\n }\n\n ${props => props.disabled ? `\n color: ${COLORS.neutral_300};\n svg, img {\n filter: grayscale(100%);\n }\n \n ` : ''}\n`;\n\nconst Divider = styled.div`\n border-top: 1px;\n border-top-color: ${COLORS.neutral_100};\n border-top-style: solid;\n width: 100%;\n`;\n\nconst NoteLeft = styled.div`\n position: absolute;\n top: 0px;\n left: 0px;\n display: flex;\n flex-direction: row;\n align-items: center;\n\n svg {\n margin-right: 4px;\n }\n`;\n\nconst NoteRight = styled.div`\n position: absolute;\n top: 0px;\n right: 0px;\n display: flex;\n flex-direction: row;\n align-items: center;\n\n svg {\n margin-right: 4px;\n }\n`;\n\nconst ButtonRowContainer = styled.div`\n display: flex;\n flex-direction: row;\n justify-content: flex-end;\n align-items: center;\n border-top: 1px;\n border-top-color: ${COLORS.neutral_100};\n border-top-style: solid;\n\n button:last-child{\n margin: 8px 0px 0px 0px;\n }\n\n button:not(:last-child) {\n margin: 8px 0px 0px 0px;\n }\n\n svg {\n color: ${COLORS.neutral_600};\n }\n`;\n\nconst Container = styled.div<{interactionType: InteractionType; disabled: boolean}>`\n padding: 0px 16px 8px 16px;\n width: calc(100% - 32px);\n cursor: ${props => props.disabled ? 'not-allowed' : 'pointer'};\n\n ${ButtonRowContainer} {\n ${props => props.interactionType == InteractionType.Clickable ? \n `cursor: ${props.disabled ? 'not-allowed' : 'auto'};` : ''}\n }\n`;\n\nconst CardBottomSection: React.FunctionComponent<CardBottomSectionProps> = ({\n interactionType,\n progressLevel,\n progressMax,\n progressType = LinearProgressType.Line,\n noteLeft,\n noteLeftIcon,\n noteRight,\n noteRightIcon,\n authorName,\n logo,\n actions,\n disabled\n}: CardBottomSectionProps) => {\n\n const haveAtLeastSomething = progressLevel != undefined || noteLeft || noteLeftIcon || noteRight || noteRightIcon || authorName;\n return (\n <Container disabled={disabled} interactionType={interactionType}>\n {haveAtLeastSomething && <Divider />}\n {progressLevel != undefined && <ProgressContainer>\n <LinearProgress size={Size.Small}\n type={progressType}\n variant={LinearProgressVariant.Normal}\n value={progressLevel}\n max={progressMax ?? progressLevel} />\n </ProgressContainer>}\n\n {(noteLeft || noteLeftIcon || noteRight || noteRightIcon) && <NotesContainer>\n {(noteLeft || noteLeftIcon) && (\n <NoteLeft>\n {noteLeftIcon}\n <ComponentXXS color={COLORS.neutral_500} textStyle={ComponentTextStyle.Bold}>{noteLeft}</ComponentXXS>\n </NoteLeft>\n )}\n {(noteRight || noteRightIcon) && (\n <NoteRight>\n {noteRightIcon}\n <ComponentXXS color={COLORS.neutral_500} textStyle={ComponentTextStyle.Bold}>{noteRight}</ComponentXXS>\n </NoteRight>\n )}\n </NotesContainer>}\n\n {(authorName || logo) && <AuthorContainer disabled={disabled}>\n <ComponentXXS>{authorName}</ComponentXXS>\n {logo}\n </AuthorContainer>}\n\n {actions && <ButtonRowContainer>\n {actions.map(x => (\n <IconButton disabled={disabled} variant=\"secondary\" shape=\"circular\" action={(e) => {e?.stopPropagation(); x.onClick();}}>\n {x.icon}\n </IconButton>\n ))}\n </ButtonRowContainer>}\n </Container>\n );\n};\n\nexport default CardBottomSection;\n"],"file":"CardBottomSection.js"}
|
|
@@ -27,7 +27,7 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
27
27
|
|
|
28
28
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
29
29
|
|
|
30
|
-
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n flex-grow: 1;\n width: calc(100% -
|
|
30
|
+
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n flex-grow: 1;\n width: calc(100% - 32px);\n position: relative;\n flex-direction: column;\n padding: 16px;\n gap: 8px;\n\n .descriptionBlock {\n padding: 2px 0;\n }\n\n .titleBlock {\n padding: 2px 0;\n }\n\n ", "\n"])), function (props) {
|
|
31
31
|
return props.interactionType == _.InteractionType.Clickable ? "\n cursor: ".concat(props.disabled ? 'not-allowed' : 'pointer', ";\n ") : '';
|
|
32
32
|
});
|
|
33
33
|
|
|
@@ -35,15 +35,11 @@ var ColorBand = _styledComponents.default.div(_templateObject2 || (_templateObje
|
|
|
35
35
|
return props.$color;
|
|
36
36
|
});
|
|
37
37
|
|
|
38
|
-
var TagsContainer = _styledComponents.default.div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n flex-direction: row;\n"])));
|
|
38
|
+
var TagsContainer = _styledComponents.default.div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n flex-direction: row;\n padding: 4px 0;\n gap: 4px;\n"])));
|
|
39
39
|
|
|
40
40
|
var Tag = _styledComponents.default.div(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2.default)(["\n padding: 4px 8px 4px 8px;\n background-color: ", ";\n margin-right: 4px;\n border-radius: 2px;\n"])), _.COLORS.neutral_100);
|
|
41
41
|
|
|
42
|
-
var CategoryContainer = _styledComponents.default.div(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n flex-direction: row;\n align-items: center;\n
|
|
43
|
-
return props.extraTopMargin ? '24px' : '22px';
|
|
44
|
-
}, function (props) {
|
|
45
|
-
return props.bottomMargin ? '10px' : '0px';
|
|
46
|
-
}, _.COLORS.neutral_500);
|
|
42
|
+
var CategoryContainer = _styledComponents.default.div(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: none;\n gap: 6px;\n \n svg {\n margin-right: 6px;\n color: ", ";\n }\n"])), _.COLORS.neutral_500);
|
|
47
43
|
|
|
48
44
|
var CardMiddleSection = function CardMiddleSection(_ref) {
|
|
49
45
|
var interactionType = _ref.interactionType,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/Card/CardMiddleSection.tsx"],"names":["Container","styled","div","props","interactionType","InteractionType","Clickable","disabled","ColorBand","$color","TagsContainer","Tag","COLORS","neutral_100","CategoryContainer","
|
|
1
|
+
{"version":3,"sources":["../../src/Card/CardMiddleSection.tsx"],"names":["Container","styled","div","props","interactionType","InteractionType","Clickable","disabled","ColorBand","$color","TagsContainer","Tag","COLORS","neutral_100","CategoryContainer","neutral_500","CardMiddleSection","colorBandColor","categoryIcon","categoryLabel","title","description","tags","Boolean","ComponentTextStyle","Bold","black","neutral_600","map","x"],"mappings":";;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;;;;;;;;;AAaA,IAAMA,SAAS,GAAGC,0BAAOC,GAAV,iVAiBX,UAAAC,KAAK;AAAA,SACLA,KAA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,QAFF;AAAA,MAFF,eAQE,qBAAC,aAAD;AAAa,MAAA,SAAS,EAAC,YAAvB;AAAoC,MAAA,SAAS,EAAEK,qBAAmBC,IAAlE;AAAwE,MAAA,KAAK,EAAElB,QAAQ,GAAGK,SAAOG,WAAV,GAAwBH,SAAOc,KAAtH;AAAA,gBACGN;AADH,MARF,EAWGC,WAAW,iBACV,qBAAC,YAAD;AAAY,MAAA,SAAS,EAAC,kBAAtB;AAAyC,MAAA,KAAK,EAAET,SAAOe,WAAvD;AAAA,gBACGN;AADH,MAZJ,EAgBGC,IAAI,iBACH,qBAAC,aAAD;AAAA,gBACGA,IAAI,CAACM,GAAL,CAAS,UAAAC,CAAC;AAAA,4BACT,qBAAC,GAAD;AAAA,iCACE,qBAAC,aAAD;AAAa,YAAA,SAAS,EAAEL,qBAAmBC,IAA3C;AAAiD,YAAA,KAAK,EAAEb,SAAOe,WAA/D;AAAA,sBACGE;AADH;AADF,UADS;AAAA,OAAV;AADH,MAjBJ;AAAA,IADF;AA8BD,CAxCD;;;AAvEEZ,EAAAA,c;AAEAC,EAAAA,Y;AACAC,EAAAA,a;AACAC,EAAAA,K;AACAC,EAAAA,W;AACAC,EAAAA,I;AACAf,EAAAA,Q;;eA0GaS,iB","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { COLORS, ComponentS, ComponentTextStyle, ComponentXL, ComponentXS, InteractionType } from '..';\n\nexport interface CardMiddleSectionProps {\n colorBandColor?: string;\n interactionType: InteractionType;\n categoryIcon?: React.ReactNode;\n categoryLabel?: string;\n title: string;\n description?: string;\n tags?: string[];\n disabled: boolean;\n}\n\nconst Container = styled.div<{ interactionType: InteractionType; disabled: boolean }>`\n display: flex;\n flex-grow: 1;\n width: calc(100% - 32px);\n position: relative;\n flex-direction: column;\n padding: 16px;\n gap: 8px;\n\n .descriptionBlock {\n padding: 2px 0;\n }\n\n .titleBlock {\n padding: 2px 0;\n }\n\n ${props =>\n props.interactionType == InteractionType.Clickable\n ? `\n cursor: ${props.disabled ? 'not-allowed' : 'pointer'};\n `\n : ''}\n`;\n\nconst ColorBand = styled.div<{ $color: string }>`\n position: absolute;\n width: 100%;\n top: 0px;\n left: 0px;\n height: 8px;\n background-color: ${props => props.$color};\n`;\n\nconst TagsContainer = styled.div`\n display: flex;\n flex-direction: row;\n padding: 4px 0;\n gap: 4px;\n`;\n\nconst Tag = styled.div`\n padding: 4px 8px 4px 8px;\n background-color: ${COLORS.neutral_100};\n margin-right: 4px;\n border-radius: 2px;\n`;\n\nconst CategoryContainer = styled.div<{ extraTopMargin: boolean; bottomMargin: boolean }>`\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: none;\n gap: 6px;\n \n svg {\n margin-right: 6px;\n color: ${COLORS.neutral_500};\n }\n`;\n\nconst CardMiddleSection: React.FunctionComponent<CardMiddleSectionProps> = ({\n interactionType,\n colorBandColor,\n categoryIcon,\n categoryLabel,\n title,\n description,\n tags,\n disabled\n}: CardMiddleSectionProps) => {\n return (\n <Container disabled={disabled} interactionType={interactionType}>\n {colorBandColor && <ColorBand $color={colorBandColor} />}\n <CategoryContainer extraTopMargin={Boolean(colorBandColor)} bottomMargin={Boolean(categoryIcon || categoryLabel)}>\n {categoryIcon}\n <ComponentS textStyle={ComponentTextStyle.Bold} color={COLORS.neutral_500}>\n {categoryLabel}\n </ComponentS>\n </CategoryContainer>\n <ComponentXL className=\"titleBlock\" textStyle={ComponentTextStyle.Bold} color={disabled ? COLORS.neutral_500 : COLORS.black}>\n {title}\n </ComponentXL>\n {description && (\n <ComponentS className=\"descriptionBlock\" color={COLORS.neutral_600}>\n {description}\n </ComponentS>\n )}\n {tags && (\n <TagsContainer>\n {tags.map(x => (\n <Tag>\n <ComponentXS textStyle={ComponentTextStyle.Bold} color={COLORS.neutral_600}>\n {x}\n </ComponentXS>\n </Tag>\n ))}\n </TagsContainer>\n )}\n </Container>\n );\n};\n\nexport default CardMiddleSection;\n"],"file":"CardMiddleSection.cjs"}
|
|
@@ -8,19 +8,15 @@ import styled from 'styled-components';
|
|
|
8
8
|
import { COLORS, ComponentS, ComponentTextStyle, ComponentXL, ComponentXS, InteractionType } from '..';
|
|
9
9
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
10
10
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
11
|
-
var Container = styled.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n flex-grow: 1;\n width: calc(100% -
|
|
11
|
+
var Container = styled.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n flex-grow: 1;\n width: calc(100% - 32px);\n position: relative;\n flex-direction: column;\n padding: 16px;\n gap: 8px;\n\n .descriptionBlock {\n padding: 2px 0;\n }\n\n .titleBlock {\n padding: 2px 0;\n }\n\n ", "\n"])), function (props) {
|
|
12
12
|
return props.interactionType == InteractionType.Clickable ? "\n cursor: ".concat(props.disabled ? 'not-allowed' : 'pointer', ";\n ") : '';
|
|
13
13
|
});
|
|
14
14
|
var ColorBand = styled.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n position: absolute;\n width: 100%;\n top: 0px;\n left: 0px;\n height: 8px;\n background-color: ", ";\n"])), function (props) {
|
|
15
15
|
return props.$color;
|
|
16
16
|
});
|
|
17
|
-
var TagsContainer = styled.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n"])));
|
|
17
|
+
var TagsContainer = styled.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n padding: 4px 0;\n gap: 4px;\n"])));
|
|
18
18
|
var Tag = styled.div(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n padding: 4px 8px 4px 8px;\n background-color: ", ";\n margin-right: 4px;\n border-radius: 2px;\n"])), COLORS.neutral_100);
|
|
19
|
-
var CategoryContainer = styled.div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n align-items: center;\n
|
|
20
|
-
return props.extraTopMargin ? '24px' : '22px';
|
|
21
|
-
}, function (props) {
|
|
22
|
-
return props.bottomMargin ? '10px' : '0px';
|
|
23
|
-
}, COLORS.neutral_500);
|
|
19
|
+
var CategoryContainer = styled.div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: none;\n gap: 6px;\n \n svg {\n margin-right: 6px;\n color: ", ";\n }\n"])), COLORS.neutral_500);
|
|
24
20
|
|
|
25
21
|
var CardMiddleSection = function CardMiddleSection(_ref) {
|
|
26
22
|
var interactionType = _ref.interactionType,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/Card/CardMiddleSection.tsx"],"names":["React","styled","COLORS","ComponentS","ComponentTextStyle","ComponentXL","ComponentXS","InteractionType","Container","div","props","interactionType","Clickable","disabled","ColorBand","$color","TagsContainer","Tag","neutral_100","CategoryContainer","
|
|
1
|
+
{"version":3,"sources":["../../src/Card/CardMiddleSection.tsx"],"names":["React","styled","COLORS","ComponentS","ComponentTextStyle","ComponentXL","ComponentXS","InteractionType","Container","div","props","interactionType","Clickable","disabled","ColorBand","$color","TagsContainer","Tag","neutral_100","CategoryContainer","neutral_500","CardMiddleSection","colorBandColor","categoryIcon","categoryLabel","title","description","tags","Boolean","Bold","black","neutral_600","map","x"],"mappings":";;;;;AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAASC,MAAT,EAAiBC,UAAjB,EAA6BC,kBAA7B,EAAiDC,WAAjD,EAA8DC,WAA9D,EAA2EC,eAA3E,QAAkG,IAAlG;;;AAaA,IAAMC,SAAS,GAAGP,MAAM,CAACQ,GAAV,mUAiBX,UAAAC,KAAK;AAAA,SACLA,KAAK,CAACC,eAAN,IAAyBJ,eAAe,CAACK,SAAzC,2BAEUF,KAAK,CAACG,QAAN,GAAiB,aAAjB,GAAiC,SAF3C,aAII,EALC;AAAA,CAjBM,CAAf;AAy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AEpB,kBAAkB,CAACyB,IAAlE;AAAwE,MAAA,KAAK,EAAEhB,QAAQ,GAAGX,MAAM,CAACkB,WAAV,GAAwBlB,MAAM,CAAC4B,KAAtH;AAAA,gBACGL;AADH,MARF,EAWGC,WAAW,iBACV,KAAC,UAAD;AAAY,MAAA,SAAS,EAAC,kBAAtB;AAAyC,MAAA,KAAK,EAAExB,MAAM,CAAC6B,WAAvD;AAAA,gBACGL;AADH,MAZJ,EAgBGC,IAAI,iBACH,KAAC,aAAD;AAAA,gBACGA,IAAI,CAACK,GAAL,CAAS,UAAAC,CAAC;AAAA,4BACT,KAAC,GAAD;AAAA,iCACE,KAAC,WAAD;AAAa,YAAA,SAAS,EAAE7B,kBAAkB,CAACyB,IAA3C;AAAiD,YAAA,KAAK,EAAE3B,MAAM,CAAC6B,WAA/D;AAAA,sBACGE;AADH;AADF,UADS;AAAA,OAAV;AADH,MAjBJ;AAAA,IADF;AA8BD,CAxCD;;;AAvEEX,EAAAA,c;AAEAC,EAAAA,Y;AACAC,EAAAA,a;AACAC,EAAAA,K;AACAC,EAAAA,W;AACAC,EAAAA,I;AACAd,EAAAA,Q;;AA0GF,eAAeQ,iBAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { COLORS, ComponentS, ComponentTextStyle, ComponentXL, ComponentXS, InteractionType } from '..';\n\nexport interface CardMiddleSectionProps {\n colorBandColor?: string;\n interactionType: InteractionType;\n categoryIcon?: React.ReactNode;\n categoryLabel?: string;\n title: string;\n description?: string;\n tags?: string[];\n disabled: boolean;\n}\n\nconst Container = styled.div<{ interactionType: InteractionType; disabled: boolean }>`\n display: flex;\n flex-grow: 1;\n width: calc(100% - 32px);\n position: relative;\n flex-direction: column;\n padding: 16px;\n gap: 8px;\n\n .descriptionBlock {\n padding: 2px 0;\n }\n\n .titleBlock {\n padding: 2px 0;\n }\n\n ${props =>\n props.interactionType == InteractionType.Clickable\n ? `\n cursor: ${props.disabled ? 'not-allowed' : 'pointer'};\n `\n : ''}\n`;\n\nconst ColorBand = styled.div<{ $color: string }>`\n position: absolute;\n width: 100%;\n top: 0px;\n left: 0px;\n height: 8px;\n background-color: ${props => props.$color};\n`;\n\nconst TagsContainer = styled.div`\n display: flex;\n flex-direction: row;\n padding: 4px 0;\n gap: 4px;\n`;\n\nconst Tag = styled.div`\n padding: 4px 8px 4px 8px;\n background-color: ${COLORS.neutral_100};\n margin-right: 4px;\n border-radius: 2px;\n`;\n\nconst CategoryContainer = styled.div<{ extraTopMargin: boolean; bottomMargin: boolean }>`\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: none;\n gap: 6px;\n \n svg {\n margin-right: 6px;\n color: ${COLORS.neutral_500};\n }\n`;\n\nconst CardMiddleSection: React.FunctionComponent<CardMiddleSectionProps> = ({\n interactionType,\n colorBandColor,\n categoryIcon,\n categoryLabel,\n title,\n description,\n tags,\n disabled\n}: CardMiddleSectionProps) => {\n return (\n <Container disabled={disabled} interactionType={interactionType}>\n {colorBandColor && <ColorBand $color={colorBandColor} />}\n <CategoryContainer extraTopMargin={Boolean(colorBandColor)} bottomMargin={Boolean(categoryIcon || categoryLabel)}>\n {categoryIcon}\n <ComponentS textStyle={ComponentTextStyle.Bold} color={COLORS.neutral_500}>\n {categoryLabel}\n </ComponentS>\n </CategoryContainer>\n <ComponentXL className=\"titleBlock\" textStyle={ComponentTextStyle.Bold} color={disabled ? COLORS.neutral_500 : COLORS.black}>\n {title}\n </ComponentXL>\n {description && (\n <ComponentS className=\"descriptionBlock\" color={COLORS.neutral_600}>\n {description}\n </ComponentS>\n )}\n {tags && (\n <TagsContainer>\n {tags.map(x => (\n <Tag>\n <ComponentXS textStyle={ComponentTextStyle.Bold} color={COLORS.neutral_600}>\n {x}\n </ComponentXS>\n </Tag>\n ))}\n </TagsContainer>\n )}\n </Container>\n );\n};\n\nexport default CardMiddleSection;\n"],"file":"CardMiddleSection.js"}
|
|
@@ -35,7 +35,7 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
35
35
|
|
|
36
36
|
var Img = _styledComponents.default.img(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n object-fit: cover;\n width: 100%;\n height: 100%;\n border-top-right-radius: 8px;\n border-top-left-radius: 8px;\n"])));
|
|
37
37
|
|
|
38
|
-
var TagContainer = _styledComponents.default.div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n
|
|
38
|
+
var TagContainer = _styledComponents.default.div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n position: absolute;\n\n top: 16px;\n left: 16px;\n"])));
|
|
39
39
|
|
|
40
40
|
var Container = _styledComponents.default.div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n position: relative;\n width: 100%;\n height: 200px;\n overflow: visible;\n\n ", "\n\n ", "\n"])), function (props) {
|
|
41
41
|
return props.disabled ? "\n img, svg {\n filter: grayscale(100%);\n }" : '';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/Card/CardTopSection.tsx"],"names":["Img","styled","img","TagContainer","div","
|
|
1
|
+
{"version":3,"sources":["../../src/Card/CardTopSection.tsx"],"names":["Img","styled","img","TagContainer","div","Container","props","disabled","interactionType","InteractionType","Clickable","RibbonContainer","$backgroundColor","$color","CheckboxContainer","COLORS","white","CardTopSection","selected","setSelected","image","tagLabel","tagIcon","tagVariant","highlightRibbonIcon","highlightRibbonText","highlightRibbonContentColor","highlightRibbonBgColor","undefined","Selectable","neutral_300","ComponentTextStyle","Regular"],"mappings":";;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AAEA;;;;;;;;;;AAiBA,IAAMA,GAAG,GAAGC,0BAAOC,GAAV,6MAAT;;AAQA,IAAMC,YAAY,GAAGF,0BAAOG,GAAV,6IAAlB;;AAOA,IAAMC,SAAS,GAAGJ,0BAAOG,GAAV,2LAMX,UAAAE,KAAK;AAAA,SAAIA,KAAK,CAACC,QAAN,y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BAAC,iBAAD;AAAU,QAAA,MAAM,EAAE,gBAACX,QAAD;AAAA,iBAAuBC,WAAW,CAACD,QAAD,CAAlC;AAAA,SAAlB;AAAgE,QAAA,QAAQ,EAAEA;AAA1E;AADF,MAHJ,EAOG,CAACG,QAAQ,IAAIC,OAAb,kBACC,qBAAC,YAAD;AAAA,6BACE,qBAAC,QAAD;AAAK,QAAA,KAAK,EAAED,QAAZ;AAAsB,QAAA,OAAO,EAAEE,UAA/B;AAA2C,QAAA,IAAI,EAAED;AAAjD;AADF,MARJ,EAYG,CAACE,mBAAmB,IAAIC,mBAAxB,kBACC,sBAAC,eAAD;AAAiB,MAAA,MAAM,EAAEC,2BAAF,aAAEA,2BAAF,cAAEA,2BAAF,GAAiC,EAAxD;AAA4D,MAAA,gBAAgB,EAAEnB,QAAQ,GAAGQ,SAAOe,WAAV,GAAwBH,sBAAxB,aAAwBA,sBAAxB,cAAwBA,sBAAxB,GAAkD,EAAxI;AAAA,iBACGH,mBADH,EAEGC,mBAAmB,iBAClB,qBAAC,sBAAD;AAAY,QAAA,KAAK,EAAEC,2BAAF,aAAEA,2BAAF,cAAEA,2BAAF,GAAiC,EAAlD;AAAsD,QAAA,SAAS,EAAEK,+BAAmBC,OAApF;AAAA,kBACGP;AADH,QAHJ;AAAA,MAbJ;AAAA,IADF;AAyBD,CAvCD;;;AA7EEP,EAAAA,Q;AACAC,EAAAA,W;AACAE,EAAAA,Q;AACAC,EAAAA,O;AAEAG,EAAAA,mB;AACAD,EAAAA,mB;AACAE,EAAAA,2B;AACAC,EAAAA,sB;AACAP,EAAAA,K;AACAb,EAAAA,Q;;eA4GaU,c","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { ComponentS, ComponentTextStyle } from '../styles/typography';\nimport Checkbox, { StyledCheckBox } from '../InputFields/Checkbox';\nimport { Tag, TagVariants } from '../Tag';\n\nimport { COLORS, InteractionType } from '..';\n\nexport interface CardTopSectionProps {\n interactionType: InteractionType;\n selected: boolean;\n setSelected: (arg0: boolean) => void;\n tagLabel?: string;\n tagIcon?: React.ReactNode;\n tagVariant?: TagVariants;\n highlightRibbonText?: string;\n highlightRibbonIcon?: string;\n highlightRibbonContentColor?: string;\n highlightRibbonBgColor?: string;\n image?: string;\n disabled: boolean;\n}\n\nconst Img = styled.img`\n object-fit: cover;\n width: 100%;\n height: 100%;\n border-top-right-radius: 8px;\n border-top-left-radius: 8px;\n`;\n\nconst TagContainer = styled.div`\n position: absolute;\n\n top: 16px;\n left: 16px;\n`;\n\nconst Container = styled.div<{ interactionType: InteractionType; disabled: boolean }>`\n position: relative;\n width: 100%;\n height: 200px;\n overflow: visible;\n\n ${props => props.disabled ? `\n img, svg {\n filter: grayscale(100%);\n }` : ''}\n\n ${props =>\n props.interactionType == InteractionType.Clickable\n ? `\n cursor: ${props.disabled ? 'not-allowed' : 'pointer'};\n `\n : ''}\n`;\n\nconst RibbonContainer = styled.div<{ $color: string; $backgroundColor: string }>`\n height: calc(40px - 16px);\n background-color: ${props => props.$backgroundColor};\n width: calc(100% - 32px);\n position: absolute;\n bottom: 0px;\n left: 0px;\n padding: 8px 16px 8px 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n\n svg {\n color: ${props => props.$color};\n margin-right: 9px;\n width: 24px;\n height: 24px;\n }\n`;\n\nconst CheckboxContainer = styled.div`\n position: absolute;\n top: 0px;\n right: 0px;\n\n .checkbox-icon {\n background-color: ${COLORS.white};\n }\n`;\n\nconst CardTopSection: React.FunctionComponent<CardTopSectionProps> = ({\n interactionType,\n selected,\n setSelected,\n image,\n tagLabel,\n tagIcon,\n tagVariant = 'positive',\n highlightRibbonIcon,\n highlightRibbonText,\n highlightRibbonContentColor,\n highlightRibbonBgColor,\n disabled\n}: CardTopSectionProps) => {\n return (\n <Container disabled={disabled} interactionType={interactionType}>\n <Img src={image} />\n {(selected !== undefined || setSelected !== undefined) && interactionType == InteractionType.Selectable && (\n <CheckboxContainer>\n <Checkbox select={(selected: boolean) => setSelected(selected)} selected={selected} />\n </CheckboxContainer>\n )}\n {(tagLabel || tagIcon) && (\n <TagContainer>\n <Tag label={tagLabel} variant={tagVariant} icon={tagIcon} />\n </TagContainer>\n )}\n {(highlightRibbonIcon || highlightRibbonText) && (\n <RibbonContainer $color={highlightRibbonContentColor ?? ''} $backgroundColor={disabled ? COLORS.neutral_300 : highlightRibbonBgColor ?? ''}>\n {highlightRibbonIcon}\n {highlightRibbonText && (\n <ComponentS color={highlightRibbonContentColor ?? ''} textStyle={ComponentTextStyle.Regular}>\n {highlightRibbonText}\n </ComponentS>\n )}\n </RibbonContainer>\n )}\n </Container>\n );\n};\n\nexport default CardTopSection;\n"],"file":"CardTopSection.cjs"}
|
|
@@ -12,7 +12,7 @@ import { COLORS, InteractionType } from '..';
|
|
|
12
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
13
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
14
|
var Img = styled.img(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n object-fit: cover;\n width: 100%;\n height: 100%;\n border-top-right-radius: 8px;\n border-top-left-radius: 8px;\n"])));
|
|
15
|
-
var TagContainer = styled.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n
|
|
15
|
+
var TagContainer = styled.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n position: absolute;\n\n top: 16px;\n left: 16px;\n"])));
|
|
16
16
|
var Container = styled.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n position: relative;\n width: 100%;\n height: 200px;\n overflow: visible;\n\n ", "\n\n ", "\n"])), function (props) {
|
|
17
17
|
return props.disabled ? "\n img, svg {\n filter: grayscale(100%);\n }" : '';
|
|
18
18
|
}, function (props) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/Card/CardTopSection.tsx"],"names":["React","styled","ComponentS","ComponentTextStyle","Checkbox","Tag","COLORS","InteractionType","Img","img","TagContainer","div","
|
|
1
|
+
{"version":3,"sources":["../../src/Card/CardTopSection.tsx"],"names":["React","styled","ComponentS","ComponentTextStyle","Checkbox","Tag","COLORS","InteractionType","Img","img","TagContainer","div","Container","props","disabled","interactionType","Clickable","RibbonContainer","$backgroundColor","$color","CheckboxContainer","white","CardTopSection","selected","setSelected","image","tagLabel","tagIcon","tagVariant","highlightRibbonIcon","highlightRibbonText","highlightRibbonContentColor","highlightRibbonBgColor","undefined","Selectable","neutral_300","Regular"],"mappings":";;;;;AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAASC,UAAT,EAAqBC,kBAArB,QAA+C,sBAA/C;AACA,OAAOC,QAAP,MAAyC,yBAAzC;AACA,SAASC,GAAT,QAAiC,QAAjC;AAEA,SAASC,MAAT,EAAiBC,eAAjB,QAAwC,IAAxC;;;AAiBA,IAAMC,GAAG,GAAGP,MAAM,CAACQ,GAAV,+LAAT;AAQA,IAAMC,YAAY,GAAGT,MAAM,CAACU,GAAV,+HAAlB;AAOA,IAAMC,SAAS,GAAGX,MAAM,CAACU,GAAV,6KAMX,UAAAE,KAAK;AAAA,SAAIA,KAAK,CAACC,QAAN,yDAGN,EAHE;AAAA,CANM,EAWX,UAAAD,KAAK;AAAA,SACLA,KAAK,CAACE,eAAN,IAAyBR,eAAe,CAACS,SAAzC,2BAEUH,KAAK,CAACC,QAAN,GAAiB,aAAjB,GAAiC,SAF3C,aAII,EALC;AAAA,CAXM,CAAf;AAmBA,IAAMG,eAAe,GAAGhB,MAAM,CAACU,GAAV,qZAEC,UAAAE,KAAK;AAAA,SAAIA,KAAK,CAACK,gBAAV;AAAA,CAFN,EAaR,UAAAL,KAAK;AAAA,SAAIA,KAAK,CAACM,MAAV;AAAA,CAbG,CAArB;AAoBA,IAAMC,iBAAiB,GAAGnB,MAAM,CAACU,GAAV,qLAMCL,MAAM,CAACe,KANR,CAAvB;;AAUA,IAAMC,cAA4D,GAAG,SAA/DA,cAA+D,OAa1C;AAAA,MAZ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jB,QAAQ,GAAGR,MAAM,CAAC6B,WAAV,GAAwBH,sBAAxB,aAAwBA,sBAAxB,cAAwBA,sBAAxB,GAAkD,EAAxI;AAAA,iBACGH,mBADH,EAEGC,mBAAmB,iBAClB,KAAC,UAAD;AAAY,QAAA,KAAK,EAAEC,2BAAF,aAAEA,2BAAF,cAAEA,2BAAF,GAAiC,EAAlD;AAAsD,QAAA,SAAS,EAAE5B,kBAAkB,CAACiC,OAApF;AAAA,kBACGN;AADH,QAHJ;AAAA,MAbJ;AAAA,IADF;AAyBD,CAvCD;;;AA7EEP,EAAAA,Q;AACAC,EAAAA,W;AACAE,EAAAA,Q;AACAC,EAAAA,O;AAEAG,EAAAA,mB;AACAD,EAAAA,mB;AACAE,EAAAA,2B;AACAC,EAAAA,sB;AACAP,EAAAA,K;AACAX,EAAAA,Q;;AA4GF,eAAeQ,cAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { ComponentS, ComponentTextStyle } from '../styles/typography';\nimport Checkbox, { StyledCheckBox } from '../InputFields/Checkbox';\nimport { Tag, TagVariants } from '../Tag';\n\nimport { COLORS, InteractionType } from '..';\n\nexport interface CardTopSectionProps {\n interactionType: InteractionType;\n selected: boolean;\n setSelected: (arg0: boolean) => void;\n tagLabel?: string;\n tagIcon?: React.ReactNode;\n tagVariant?: TagVariants;\n highlightRibbonText?: string;\n highlightRibbonIcon?: string;\n highlightRibbonContentColor?: string;\n highlightRibbonBgColor?: string;\n image?: string;\n disabled: boolean;\n}\n\nconst Img = styled.img`\n object-fit: cover;\n width: 100%;\n height: 100%;\n border-top-right-radius: 8px;\n border-top-left-radius: 8px;\n`;\n\nconst TagContainer = styled.div`\n position: absolute;\n\n top: 16px;\n left: 16px;\n`;\n\nconst Container = styled.div<{ interactionType: InteractionType; disabled: boolean }>`\n position: relative;\n width: 100%;\n height: 200px;\n overflow: visible;\n\n ${props => props.disabled ? `\n img, svg {\n filter: grayscale(100%);\n }` : ''}\n\n ${props =>\n props.interactionType == InteractionType.Clickable\n ? `\n cursor: ${props.disabled ? 'not-allowed' : 'pointer'};\n `\n : ''}\n`;\n\nconst RibbonContainer = styled.div<{ $color: string; $backgroundColor: string }>`\n height: calc(40px - 16px);\n background-color: ${props => props.$backgroundColor};\n width: calc(100% - 32px);\n position: absolute;\n bottom: 0px;\n left: 0px;\n padding: 8px 16px 8px 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n\n svg {\n color: ${props => props.$color};\n margin-right: 9px;\n width: 24px;\n height: 24px;\n }\n`;\n\nconst CheckboxContainer = styled.div`\n position: absolute;\n top: 0px;\n right: 0px;\n\n .checkbox-icon {\n background-color: ${COLORS.white};\n }\n`;\n\nconst CardTopSection: React.FunctionComponent<CardTopSectionProps> = ({\n interactionType,\n selected,\n setSelected,\n image,\n tagLabel,\n tagIcon,\n tagVariant = 'positive',\n highlightRibbonIcon,\n highlightRibbonText,\n highlightRibbonContentColor,\n highlightRibbonBgColor,\n disabled\n}: CardTopSectionProps) => {\n return (\n <Container disabled={disabled} interactionType={interactionType}>\n <Img src={image} />\n {(selected !== undefined || setSelected !== undefined) && interactionType == InteractionType.Selectable && (\n <CheckboxContainer>\n <Checkbox select={(selected: boolean) => setSelected(selected)} selected={selected} />\n </CheckboxContainer>\n )}\n {(tagLabel || tagIcon) && (\n <TagContainer>\n <Tag label={tagLabel} variant={tagVariant} icon={tagIcon} />\n </TagContainer>\n )}\n {(highlightRibbonIcon || highlightRibbonText) && (\n <RibbonContainer $color={highlightRibbonContentColor ?? ''} $backgroundColor={disabled ? COLORS.neutral_300 : highlightRibbonBgColor ?? ''}>\n {highlightRibbonIcon}\n {highlightRibbonText && (\n <ComponentS color={highlightRibbonContentColor ?? ''} textStyle={ComponentTextStyle.Regular}>\n {highlightRibbonText}\n </ComponentS>\n )}\n </RibbonContainer>\n )}\n </Container>\n );\n};\n\nexport default CardTopSection;\n"],"file":"CardTopSection.js"}
|
package/dist/index.cjs
CHANGED
|
@@ -3,11 +3,21 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
+
var _exportNames = {
|
|
7
|
+
LaerdalLogo: true
|
|
8
|
+
};
|
|
9
|
+
Object.defineProperty(exports, "LaerdalLogo", {
|
|
10
|
+
enumerable: true,
|
|
11
|
+
get: function get() {
|
|
12
|
+
return _assets.LaerdalLogo;
|
|
13
|
+
}
|
|
14
|
+
});
|
|
6
15
|
|
|
7
16
|
var _styles = require("./styles");
|
|
8
17
|
|
|
9
18
|
Object.keys(_styles).forEach(function (key) {
|
|
10
19
|
if (key === "default" || key === "__esModule") return;
|
|
20
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
11
21
|
if (key in exports && exports[key] === _styles[key]) return;
|
|
12
22
|
Object.defineProperty(exports, key, {
|
|
13
23
|
enumerable: true,
|
|
@@ -21,6 +31,7 @@ var _icons = require("./icons");
|
|
|
21
31
|
|
|
22
32
|
Object.keys(_icons).forEach(function (key) {
|
|
23
33
|
if (key === "default" || key === "__esModule") return;
|
|
34
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
24
35
|
if (key in exports && exports[key] === _icons[key]) return;
|
|
25
36
|
Object.defineProperty(exports, key, {
|
|
26
37
|
enumerable: true,
|
|
@@ -34,6 +45,7 @@ var _types = require("./types");
|
|
|
34
45
|
|
|
35
46
|
Object.keys(_types).forEach(function (key) {
|
|
36
47
|
if (key === "default" || key === "__esModule") return;
|
|
48
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
37
49
|
if (key in exports && exports[key] === _types[key]) return;
|
|
38
50
|
Object.defineProperty(exports, key, {
|
|
39
51
|
enumerable: true,
|
|
@@ -47,6 +59,7 @@ var _AuthPage = require("./AuthPage");
|
|
|
47
59
|
|
|
48
60
|
Object.keys(_AuthPage).forEach(function (key) {
|
|
49
61
|
if (key === "default" || key === "__esModule") return;
|
|
62
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
50
63
|
if (key in exports && exports[key] === _AuthPage[key]) return;
|
|
51
64
|
Object.defineProperty(exports, key, {
|
|
52
65
|
enumerable: true,
|
|
@@ -60,6 +73,7 @@ var _Button = require("./Button");
|
|
|
60
73
|
|
|
61
74
|
Object.keys(_Button).forEach(function (key) {
|
|
62
75
|
if (key === "default" || key === "__esModule") return;
|
|
76
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
63
77
|
if (key in exports && exports[key] === _Button[key]) return;
|
|
64
78
|
Object.defineProperty(exports, key, {
|
|
65
79
|
enumerable: true,
|
|
@@ -73,6 +87,7 @@ var _Breadcrumb = require("./Breadcrumb");
|
|
|
73
87
|
|
|
74
88
|
Object.keys(_Breadcrumb).forEach(function (key) {
|
|
75
89
|
if (key === "default" || key === "__esModule") return;
|
|
90
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
76
91
|
if (key in exports && exports[key] === _Breadcrumb[key]) return;
|
|
77
92
|
Object.defineProperty(exports, key, {
|
|
78
93
|
enumerable: true,
|
|
@@ -86,6 +101,7 @@ var _Chips = require("./Chips");
|
|
|
86
101
|
|
|
87
102
|
Object.keys(_Chips).forEach(function (key) {
|
|
88
103
|
if (key === "default" || key === "__esModule") return;
|
|
104
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
89
105
|
if (key in exports && exports[key] === _Chips[key]) return;
|
|
90
106
|
Object.defineProperty(exports, key, {
|
|
91
107
|
enumerable: true,
|
|
@@ -99,6 +115,7 @@ var _SkipToContent = require("./SkipToContent");
|
|
|
99
115
|
|
|
100
116
|
Object.keys(_SkipToContent).forEach(function (key) {
|
|
101
117
|
if (key === "default" || key === "__esModule") return;
|
|
118
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
102
119
|
if (key in exports && exports[key] === _SkipToContent[key]) return;
|
|
103
120
|
Object.defineProperty(exports, key, {
|
|
104
121
|
enumerable: true,
|
|
@@ -112,6 +129,7 @@ var _Footer = require("./Footer");
|
|
|
112
129
|
|
|
113
130
|
Object.keys(_Footer).forEach(function (key) {
|
|
114
131
|
if (key === "default" || key === "__esModule") return;
|
|
132
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
115
133
|
if (key in exports && exports[key] === _Footer[key]) return;
|
|
116
134
|
Object.defineProperty(exports, key, {
|
|
117
135
|
enumerable: true,
|
|
@@ -125,6 +143,7 @@ var _LoadingIndicator = require("./LoadingIndicator");
|
|
|
125
143
|
|
|
126
144
|
Object.keys(_LoadingIndicator).forEach(function (key) {
|
|
127
145
|
if (key === "default" || key === "__esModule") return;
|
|
146
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
128
147
|
if (key in exports && exports[key] === _LoadingIndicator[key]) return;
|
|
129
148
|
Object.defineProperty(exports, key, {
|
|
130
149
|
enumerable: true,
|
|
@@ -138,6 +157,7 @@ var _MiniProductCard = require("./MiniProductCard");
|
|
|
138
157
|
|
|
139
158
|
Object.keys(_MiniProductCard).forEach(function (key) {
|
|
140
159
|
if (key === "default" || key === "__esModule") return;
|
|
160
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
141
161
|
if (key in exports && exports[key] === _MiniProductCard[key]) return;
|
|
142
162
|
Object.defineProperty(exports, key, {
|
|
143
163
|
enumerable: true,
|
|
@@ -151,6 +171,7 @@ var _NavItem = require("./NavItem");
|
|
|
151
171
|
|
|
152
172
|
Object.keys(_NavItem).forEach(function (key) {
|
|
153
173
|
if (key === "default" || key === "__esModule") return;
|
|
174
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
154
175
|
if (key in exports && exports[key] === _NavItem[key]) return;
|
|
155
176
|
Object.defineProperty(exports, key, {
|
|
156
177
|
enumerable: true,
|
|
@@ -164,6 +185,7 @@ var _Layouts = require("./Layouts");
|
|
|
164
185
|
|
|
165
186
|
Object.keys(_Layouts).forEach(function (key) {
|
|
166
187
|
if (key === "default" || key === "__esModule") return;
|
|
188
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
167
189
|
if (key in exports && exports[key] === _Layouts[key]) return;
|
|
168
190
|
Object.defineProperty(exports, key, {
|
|
169
191
|
enumerable: true,
|
|
@@ -177,6 +199,7 @@ var _GlobalNavigationBar = require("./GlobalNavigationBar");
|
|
|
177
199
|
|
|
178
200
|
Object.keys(_GlobalNavigationBar).forEach(function (key) {
|
|
179
201
|
if (key === "default" || key === "__esModule") return;
|
|
202
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
180
203
|
if (key in exports && exports[key] === _GlobalNavigationBar[key]) return;
|
|
181
204
|
Object.defineProperty(exports, key, {
|
|
182
205
|
enumerable: true,
|
|
@@ -190,6 +213,7 @@ var _Tabs = require("./Tabs");
|
|
|
190
213
|
|
|
191
214
|
Object.keys(_Tabs).forEach(function (key) {
|
|
192
215
|
if (key === "default" || key === "__esModule") return;
|
|
216
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
193
217
|
if (key in exports && exports[key] === _Tabs[key]) return;
|
|
194
218
|
Object.defineProperty(exports, key, {
|
|
195
219
|
enumerable: true,
|
|
@@ -203,6 +227,7 @@ var _Banners = require("./Banners");
|
|
|
203
227
|
|
|
204
228
|
Object.keys(_Banners).forEach(function (key) {
|
|
205
229
|
if (key === "default" || key === "__esModule") return;
|
|
230
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
206
231
|
if (key in exports && exports[key] === _Banners[key]) return;
|
|
207
232
|
Object.defineProperty(exports, key, {
|
|
208
233
|
enumerable: true,
|
|
@@ -216,6 +241,7 @@ var _Toasters = require("./Toasters");
|
|
|
216
241
|
|
|
217
242
|
Object.keys(_Toasters).forEach(function (key) {
|
|
218
243
|
if (key === "default" || key === "__esModule") return;
|
|
244
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
219
245
|
if (key in exports && exports[key] === _Toasters[key]) return;
|
|
220
246
|
Object.defineProperty(exports, key, {
|
|
221
247
|
enumerable: true,
|
|
@@ -229,6 +255,7 @@ var _InputFields = require("./InputFields");
|
|
|
229
255
|
|
|
230
256
|
Object.keys(_InputFields).forEach(function (key) {
|
|
231
257
|
if (key === "default" || key === "__esModule") return;
|
|
258
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
232
259
|
if (key in exports && exports[key] === _InputFields[key]) return;
|
|
233
260
|
Object.defineProperty(exports, key, {
|
|
234
261
|
enumerable: true,
|
|
@@ -242,6 +269,7 @@ var _Dropdown = require("./Dropdown");
|
|
|
242
269
|
|
|
243
270
|
Object.keys(_Dropdown).forEach(function (key) {
|
|
244
271
|
if (key === "default" || key === "__esModule") return;
|
|
272
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
245
273
|
if (key in exports && exports[key] === _Dropdown[key]) return;
|
|
246
274
|
Object.defineProperty(exports, key, {
|
|
247
275
|
enumerable: true,
|
|
@@ -255,6 +283,7 @@ var _Switcher = require("./Switcher");
|
|
|
255
283
|
|
|
256
284
|
Object.keys(_Switcher).forEach(function (key) {
|
|
257
285
|
if (key === "default" || key === "__esModule") return;
|
|
286
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
258
287
|
if (key in exports && exports[key] === _Switcher[key]) return;
|
|
259
288
|
Object.defineProperty(exports, key, {
|
|
260
289
|
enumerable: true,
|
|
@@ -268,6 +297,7 @@ var _LoadingPage = require("./LoadingPage");
|
|
|
268
297
|
|
|
269
298
|
Object.keys(_LoadingPage).forEach(function (key) {
|
|
270
299
|
if (key === "default" || key === "__esModule") return;
|
|
300
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
271
301
|
if (key in exports && exports[key] === _LoadingPage[key]) return;
|
|
272
302
|
Object.defineProperty(exports, key, {
|
|
273
303
|
enumerable: true,
|
|
@@ -281,6 +311,7 @@ var _List = require("./List");
|
|
|
281
311
|
|
|
282
312
|
Object.keys(_List).forEach(function (key) {
|
|
283
313
|
if (key === "default" || key === "__esModule") return;
|
|
314
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
284
315
|
if (key in exports && exports[key] === _List[key]) return;
|
|
285
316
|
Object.defineProperty(exports, key, {
|
|
286
317
|
enumerable: true,
|
|
@@ -294,6 +325,7 @@ var _Modals = require("./Modals");
|
|
|
294
325
|
|
|
295
326
|
Object.keys(_Modals).forEach(function (key) {
|
|
296
327
|
if (key === "default" || key === "__esModule") return;
|
|
328
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
297
329
|
if (key in exports && exports[key] === _Modals[key]) return;
|
|
298
330
|
Object.defineProperty(exports, key, {
|
|
299
331
|
enumerable: true,
|
|
@@ -307,6 +339,7 @@ var _Paginator = require("./Paginator");
|
|
|
307
339
|
|
|
308
340
|
Object.keys(_Paginator).forEach(function (key) {
|
|
309
341
|
if (key === "default" || key === "__esModule") return;
|
|
342
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
310
343
|
if (key in exports && exports[key] === _Paginator[key]) return;
|
|
311
344
|
Object.defineProperty(exports, key, {
|
|
312
345
|
enumerable: true,
|
|
@@ -320,6 +353,7 @@ var _Table = require("./Table");
|
|
|
320
353
|
|
|
321
354
|
Object.keys(_Table).forEach(function (key) {
|
|
322
355
|
if (key === "default" || key === "__esModule") return;
|
|
356
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
323
357
|
if (key in exports && exports[key] === _Table[key]) return;
|
|
324
358
|
Object.defineProperty(exports, key, {
|
|
325
359
|
enumerable: true,
|
|
@@ -333,6 +367,7 @@ var _Toggles = require("./Toggles");
|
|
|
333
367
|
|
|
334
368
|
Object.keys(_Toggles).forEach(function (key) {
|
|
335
369
|
if (key === "default" || key === "__esModule") return;
|
|
370
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
336
371
|
if (key in exports && exports[key] === _Toggles[key]) return;
|
|
337
372
|
Object.defineProperty(exports, key, {
|
|
338
373
|
enumerable: true,
|
|
@@ -346,6 +381,7 @@ var _HyperLink = require("./HyperLink");
|
|
|
346
381
|
|
|
347
382
|
Object.keys(_HyperLink).forEach(function (key) {
|
|
348
383
|
if (key === "default" || key === "__esModule") return;
|
|
384
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
349
385
|
if (key in exports && exports[key] === _HyperLink[key]) return;
|
|
350
386
|
Object.defineProperty(exports, key, {
|
|
351
387
|
enumerable: true,
|
|
@@ -359,6 +395,7 @@ var _NotificationDot = require("./NotificationDot");
|
|
|
359
395
|
|
|
360
396
|
Object.keys(_NotificationDot).forEach(function (key) {
|
|
361
397
|
if (key === "default" || key === "__esModule") return;
|
|
398
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
362
399
|
if (key in exports && exports[key] === _NotificationDot[key]) return;
|
|
363
400
|
Object.defineProperty(exports, key, {
|
|
364
401
|
enumerable: true,
|
|
@@ -372,6 +409,7 @@ var _Accordion = require("./Accordion");
|
|
|
372
409
|
|
|
373
410
|
Object.keys(_Accordion).forEach(function (key) {
|
|
374
411
|
if (key === "default" || key === "__esModule") return;
|
|
412
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
375
413
|
if (key in exports && exports[key] === _Accordion[key]) return;
|
|
376
414
|
Object.defineProperty(exports, key, {
|
|
377
415
|
enumerable: true,
|
|
@@ -385,6 +423,7 @@ var _Tooltips = require("./Tooltips");
|
|
|
385
423
|
|
|
386
424
|
Object.keys(_Tooltips).forEach(function (key) {
|
|
387
425
|
if (key === "default" || key === "__esModule") return;
|
|
426
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
388
427
|
if (key in exports && exports[key] === _Tooltips[key]) return;
|
|
389
428
|
Object.defineProperty(exports, key, {
|
|
390
429
|
enumerable: true,
|
|
@@ -398,6 +437,7 @@ var _common = require("./common");
|
|
|
398
437
|
|
|
399
438
|
Object.keys(_common).forEach(function (key) {
|
|
400
439
|
if (key === "default" || key === "__esModule") return;
|
|
440
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
401
441
|
if (key in exports && exports[key] === _common[key]) return;
|
|
402
442
|
Object.defineProperty(exports, key, {
|
|
403
443
|
enumerable: true,
|
|
@@ -411,6 +451,7 @@ var _QuizButton = require("./QuizButton");
|
|
|
411
451
|
|
|
412
452
|
Object.keys(_QuizButton).forEach(function (key) {
|
|
413
453
|
if (key === "default" || key === "__esModule") return;
|
|
454
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
414
455
|
if (key in exports && exports[key] === _QuizButton[key]) return;
|
|
415
456
|
Object.defineProperty(exports, key, {
|
|
416
457
|
enumerable: true,
|
|
@@ -424,6 +465,7 @@ var _LinearProgress = require("./LinearProgress");
|
|
|
424
465
|
|
|
425
466
|
Object.keys(_LinearProgress).forEach(function (key) {
|
|
426
467
|
if (key === "default" || key === "__esModule") return;
|
|
468
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
427
469
|
if (key in exports && exports[key] === _LinearProgress[key]) return;
|
|
428
470
|
Object.defineProperty(exports, key, {
|
|
429
471
|
enumerable: true,
|
|
@@ -437,6 +479,7 @@ var _SegmentControl = require("./SegmentControl");
|
|
|
437
479
|
|
|
438
480
|
Object.keys(_SegmentControl).forEach(function (key) {
|
|
439
481
|
if (key === "default" || key === "__esModule") return;
|
|
482
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
440
483
|
if (key in exports && exports[key] === _SegmentControl[key]) return;
|
|
441
484
|
Object.defineProperty(exports, key, {
|
|
442
485
|
enumerable: true,
|
|
@@ -450,6 +493,7 @@ var _Card = require("./Card");
|
|
|
450
493
|
|
|
451
494
|
Object.keys(_Card).forEach(function (key) {
|
|
452
495
|
if (key === "default" || key === "__esModule") return;
|
|
496
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
453
497
|
if (key in exports && exports[key] === _Card[key]) return;
|
|
454
498
|
Object.defineProperty(exports, key, {
|
|
455
499
|
enumerable: true,
|
|
@@ -463,6 +507,7 @@ var _Tag = require("./Tag");
|
|
|
463
507
|
|
|
464
508
|
Object.keys(_Tag).forEach(function (key) {
|
|
465
509
|
if (key === "default" || key === "__esModule") return;
|
|
510
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
466
511
|
if (key in exports && exports[key] === _Tag[key]) return;
|
|
467
512
|
Object.defineProperty(exports, key, {
|
|
468
513
|
enumerable: true,
|
|
@@ -471,4 +516,6 @@ Object.keys(_Tag).forEach(function (key) {
|
|
|
471
516
|
}
|
|
472
517
|
});
|
|
473
518
|
});
|
|
519
|
+
|
|
520
|
+
var _assets = require("./assets");
|
|
474
521
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;A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A;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AACA","sourcesContent":["export * from './styles';\nexport * from './icons';\nexport * from './types';\nexport * from './AuthPage';\nexport * from './Button';\nexport * from './Breadcrumb';\nexport * from './Chips';\nexport * from './SkipToContent';\nexport * from './Footer';\nexport * from './LoadingIndicator';\nexport * from './MiniProductCard';\nexport * from './NavItem';\nexport * from './Layouts';\nexport * from './GlobalNavigationBar';\nexport * from './Tabs';\nexport * from './Banners';\nexport * from './Toasters';\nexport * from './InputFields';\nexport * from './Dropdown';\nexport * from './Switcher';\nexport * from './LoadingPage';\nexport * from './List';\nexport * from './Modals';\nexport * from './Paginator';\nexport * from './Table';\nexport * from './Toggles';\nexport * from './HyperLink';\nexport * from './NotificationDot';\nexport * from './Accordion';\nexport * from './Tooltips';\nexport * from './common';\nexport * from './QuizButton';\nexport * from './LinearProgress';\nexport * from './SegmentControl';\nexport * from './Card';\nexport * from './Tag';\nexport {LaerdalLogo} from './assets';\n"],"file":"index.cjs"}
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAd;AACA,cAAc,SAAd;AACA,cAAc,SAAd;AACA,cAAc,YAAd;AACA,cAAc,UAAd;AACA,cAAc,cAAd;AACA,cAAc,SAAd;AACA,cAAc,iBAAd;AACA,cAAc,UAAd;AACA,cAAc,oBAAd;AACA,cAAc,mBAAd;AACA,cAAc,WAAd;AACA,cAAc,WAAd;AACA,cAAc,uBAAd;AACA,cAAc,QAAd;AACA,cAAc,WAAd;AACA,cAAc,YAAd;AACA,cAAc,eAAd;AACA,cAAc,YAAd;AACA,cAAc,YAAd;AACA,cAAc,eAAd;AACA,cAAc,QAAd;AACA,cAAc,UAAd;AACA,cAAc,aAAd;AACA,cAAc,SAAd;AACA,cAAc,WAAd;AACA,cAAc,aAAd;AACA,cAAc,mBAAd;AACA,cAAc,aAAd;AACA,cAAc,YAAd;AACA,cAAc,UAAd;AACA,cAAc,cAAd;AACA,cAAc,kBAAd;AACA,cAAc,kBAAd;AACA,cAAc,QAAd;AACA,cAAc,OAAd","sourcesContent":["export * from './styles';\nexport * from './icons';\nexport * from './types';\nexport * from './AuthPage';\nexport * from './Button';\nexport * from './Breadcrumb';\nexport * from './Chips';\nexport * from './SkipToContent';\nexport * from './Footer';\nexport * from './LoadingIndicator';\nexport * from './MiniProductCard';\nexport * from './NavItem';\nexport * from './Layouts';\nexport * from './GlobalNavigationBar';\nexport * from './Tabs';\nexport * from './Banners';\nexport * from './Toasters';\nexport * from './InputFields';\nexport * from './Dropdown';\nexport * from './Switcher';\nexport * from './LoadingPage';\nexport * from './List';\nexport * from './Modals';\nexport * from './Paginator';\nexport * from './Table';\nexport * from './Toggles';\nexport * from './HyperLink';\nexport * from './NotificationDot';\nexport * from './Accordion';\nexport * from './Tooltips';\nexport * from './common';\nexport * from './QuizButton';\nexport * from './LinearProgress';\nexport * from './SegmentControl';\nexport * from './Card';\nexport * from './Tag';\n"],"file":"index.js"}
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"names":["LaerdalLogo"],"mappings":"AAAA,cAAc,UAAd;AACA,cAAc,SAAd;AACA,cAAc,SAAd;AACA,cAAc,YAAd;AACA,cAAc,UAAd;AACA,cAAc,cAAd;AACA,cAAc,SAAd;AACA,cAAc,iBAAd;AACA,cAAc,UAAd;AACA,cAAc,oBAAd;AACA,cAAc,mBAAd;AACA,cAAc,WAAd;AACA,cAAc,WAAd;AACA,cAAc,uBAAd;AACA,cAAc,QAAd;AACA,cAAc,WAAd;AACA,cAAc,YAAd;AACA,cAAc,eAAd;AACA,cAAc,YAAd;AACA,cAAc,YAAd;AACA,cAAc,eAAd;AACA,cAAc,QAAd;AACA,cAAc,UAAd;AACA,cAAc,aAAd;AACA,cAAc,SAAd;AACA,cAAc,WAAd;AACA,cAAc,aAAd;AACA,cAAc,mBAAd;AACA,cAAc,aAAd;AACA,cAAc,YAAd;AACA,cAAc,UAAd;AACA,cAAc,cAAd;AACA,cAAc,kBAAd;AACA,cAAc,kBAAd;AACA,cAAc,QAAd;AACA,cAAc,OAAd;AACA,SAAQA,WAAR,QAA0B,UAA1B","sourcesContent":["export * from './styles';\nexport * from './icons';\nexport * from './types';\nexport * from './AuthPage';\nexport * from './Button';\nexport * from './Breadcrumb';\nexport * from './Chips';\nexport * from './SkipToContent';\nexport * from './Footer';\nexport * from './LoadingIndicator';\nexport * from './MiniProductCard';\nexport * from './NavItem';\nexport * from './Layouts';\nexport * from './GlobalNavigationBar';\nexport * from './Tabs';\nexport * from './Banners';\nexport * from './Toasters';\nexport * from './InputFields';\nexport * from './Dropdown';\nexport * from './Switcher';\nexport * from './LoadingPage';\nexport * from './List';\nexport * from './Modals';\nexport * from './Paginator';\nexport * from './Table';\nexport * from './Toggles';\nexport * from './HyperLink';\nexport * from './NotificationDot';\nexport * from './Accordion';\nexport * from './Tooltips';\nexport * from './common';\nexport * from './QuizButton';\nexport * from './LinearProgress';\nexport * from './SegmentControl';\nexport * from './Card';\nexport * from './Tag';\nexport {LaerdalLogo} from './assets';\n"],"file":"index.js"}
|