@laerdal/life-react-components 2.2.1-dev.4.full → 2.2.1-dev.5.full
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/HorizontalCard/HorizontalCardThumbnail.cjs +1 -1
- package/dist/Card/HorizontalCard/HorizontalCardThumbnail.cjs.map +1 -1
- package/dist/Card/HorizontalCard/HorizontalCardThumbnail.js +1 -1
- package/dist/Card/HorizontalCard/HorizontalCardThumbnail.js.map +1 -1
- package/package.json +1 -1
|
@@ -12,7 +12,7 @@ var _styles = require("../../styles");
|
|
|
12
12
|
var _Image = require("../../Image");
|
|
13
13
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
14
14
|
var _templateObject, _templateObject2;
|
|
15
|
-
var HorizontalCardIconContainer = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n justify-content:
|
|
15
|
+
var HorizontalCardIconContainer = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n justify-content: flex-end;\n align-items: center;\n width: 64px;\n height: 80px;\n\n color: ", ";\n\n .disabled & {\n color: ", ";\n }\n"])), _styles.COLORS.black, _styles.COLORS.neutral_500);
|
|
16
16
|
exports.HorizontalCardIconContainer = HorizontalCardIconContainer;
|
|
17
17
|
var HorizontalCardImageContainer = _styledComponents.default.div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n height: 100%;\n overflow: hidden;\n border-bottom-left-radius: 8px;\n border-top-left-radius: 8px;\n width: 120px;\n\n img {\n mix-blend-mode: multiply;\n object-fit: cover;\n width: 100%;\n height: 100%;\n\n }\n\n .disabled & {\n img {\n filter: grayscale(100%);\n }\n }\n\n"])));
|
|
18
18
|
exports.HorizontalCardImageContainer = HorizontalCardImageContainer;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HorizontalCardThumbnail.cjs","names":["HorizontalCardIconContainer","styled","div","COLORS","black","neutral_500","HorizontalCardImageContainer","HorizontalCardThumbnail","image","icon","React","cloneElement","width","height","fallbackSrc","src","alt","loader"],"sources":["../../../src/Card/HorizontalCard/HorizontalCardThumbnail.tsx"],"sourcesContent":["import React from 'react';\nimport {HorizontalCardProps} from './types';\nimport styled from 'styled-components';\nimport {COLORS} from '../../styles';\nimport {ImageWithFallbacks} from \"../../Image\";\n\nexport const HorizontalCardIconContainer = styled.div`\n display: flex;\n justify-content:
|
|
1
|
+
{"version":3,"file":"HorizontalCardThumbnail.cjs","names":["HorizontalCardIconContainer","styled","div","COLORS","black","neutral_500","HorizontalCardImageContainer","HorizontalCardThumbnail","image","icon","React","cloneElement","width","height","fallbackSrc","src","alt","loader"],"sources":["../../../src/Card/HorizontalCard/HorizontalCardThumbnail.tsx"],"sourcesContent":["import React from 'react';\nimport {HorizontalCardProps} from './types';\nimport styled from 'styled-components';\nimport {COLORS} from '../../styles';\nimport {ImageWithFallbacks} from \"../../Image\";\n\nexport const HorizontalCardIconContainer = styled.div`\n display: flex;\n justify-content: flex-end;\n align-items: center;\n width: 64px;\n height: 80px;\n\n color: ${COLORS.black};\n\n .disabled & {\n color: ${COLORS.neutral_500};\n }\n`;\n\n\nexport const HorizontalCardImageContainer = styled.div`\n height: 100%;\n overflow: hidden;\n border-bottom-left-radius: 8px;\n border-top-left-radius: 8px;\n width: 120px;\n\n img {\n mix-blend-mode: multiply;\n object-fit: cover;\n width: 100%;\n height: 100%;\n\n }\n\n .disabled & {\n img {\n filter: grayscale(100%);\n }\n }\n\n`;\n\ntype Props = Pick<HorizontalCardProps, 'image' | 'icon'>;\n\nexport const HorizontalCardThumbnail: React.FunctionComponent<Props> = ({\n image,\n icon\n }) => {\n\n return (\n <>\n {\n icon &&\n <HorizontalCardIconContainer>\n {React.cloneElement(icon, {width: 48, height: 48})}\n </HorizontalCardIconContainer>\n }\n {\n image &&\n <HorizontalCardImageContainer>\n <ImageWithFallbacks fallbacks={image.fallbackSrc ?? ''} src={image.src} alt={image.alt}\n loader={image.loader ?? false} width={image.width} height={image.height}/>\n </HorizontalCardImageContainer>\n }\n </>\n )\n};\n"],"mappings":";;;;;;;;AAAA;AAEA;AACA;AACA;AAA+C;AAAA;AAExC,IAAMA,2BAA2B,GAAGC,yBAAM,CAACC,GAAG,2PAO1CC,cAAM,CAACC,KAAK,EAGVD,cAAM,CAACE,WAAW,CAE9B;AAAC;AAGK,IAAMC,4BAA4B,GAAGL,yBAAM,CAACC,GAAG,2YAqBrD;AAAC;AAIK,IAAMK,uBAAuD,GAAG,SAA1DA,uBAAuD,OAGU;EAAA;EAAA,IAFJC,KAAK,QAALA,KAAK;IACLC,IAAI,QAAJA,IAAI;EAG5E,oBACE;IAAA,WAEIA,IAAI,iBACF,qBAAC,2BAA2B;MAAA,uBACzBC,cAAK,CAACC,YAAY,CAACF,IAAI,EAAE;QAACG,KAAK,EAAE,EAAE;QAAEC,MAAM,EAAE;MAAE,CAAC;IAAC,EACtB,EAGhCL,KAAK,iBACH,qBAAC,4BAA4B;MAAA,uBACzB,qBAAC,yBAAkB;QAAC,SAAS,wBAAEA,KAAK,CAACM,WAAW,mEAAI,EAAG;QAAC,GAAG,EAAEN,KAAK,CAACO,GAAI;QAAC,GAAG,EAAEP,KAAK,CAACQ,GAAI;QACnE,MAAM,mBAAER,KAAK,CAACS,MAAM,yDAAI,KAAM;QAAC,KAAK,EAAET,KAAK,CAACI,KAAM;QAAC,MAAM,EAAEJ,KAAK,CAACK;MAAO;IAAE,EACnE;EAAA,EAElC;AAEP,CAAC;AAAC"}
|
|
@@ -7,7 +7,7 @@ import { ImageWithFallbacks } from "../../Image";
|
|
|
7
7
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
8
8
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
9
9
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
10
|
-
export var HorizontalCardIconContainer = styled.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n justify-content:
|
|
10
|
+
export var HorizontalCardIconContainer = styled.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n justify-content: flex-end;\n align-items: center;\n width: 64px;\n height: 80px;\n\n color: ", ";\n\n .disabled & {\n color: ", ";\n }\n"])), COLORS.black, COLORS.neutral_500);
|
|
11
11
|
export var HorizontalCardImageContainer = styled.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n height: 100%;\n overflow: hidden;\n border-bottom-left-radius: 8px;\n border-top-left-radius: 8px;\n width: 120px;\n\n img {\n mix-blend-mode: multiply;\n object-fit: cover;\n width: 100%;\n height: 100%;\n\n }\n\n .disabled & {\n img {\n filter: grayscale(100%);\n }\n }\n\n"])));
|
|
12
12
|
export var HorizontalCardThumbnail = function HorizontalCardThumbnail(_ref) {
|
|
13
13
|
var _image$fallbackSrc, _image$loader;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HorizontalCardThumbnail.js","names":["React","styled","COLORS","ImageWithFallbacks","HorizontalCardIconContainer","div","black","neutral_500","HorizontalCardImageContainer","HorizontalCardThumbnail","image","icon","cloneElement","width","height","fallbackSrc","src","alt","loader"],"sources":["../../../src/Card/HorizontalCard/HorizontalCardThumbnail.tsx"],"sourcesContent":["import React from 'react';\nimport {HorizontalCardProps} from './types';\nimport styled from 'styled-components';\nimport {COLORS} from '../../styles';\nimport {ImageWithFallbacks} from \"../../Image\";\n\nexport const HorizontalCardIconContainer = styled.div`\n display: flex;\n justify-content:
|
|
1
|
+
{"version":3,"file":"HorizontalCardThumbnail.js","names":["React","styled","COLORS","ImageWithFallbacks","HorizontalCardIconContainer","div","black","neutral_500","HorizontalCardImageContainer","HorizontalCardThumbnail","image","icon","cloneElement","width","height","fallbackSrc","src","alt","loader"],"sources":["../../../src/Card/HorizontalCard/HorizontalCardThumbnail.tsx"],"sourcesContent":["import React from 'react';\nimport {HorizontalCardProps} from './types';\nimport styled from 'styled-components';\nimport {COLORS} from '../../styles';\nimport {ImageWithFallbacks} from \"../../Image\";\n\nexport const HorizontalCardIconContainer = styled.div`\n display: flex;\n justify-content: flex-end;\n align-items: center;\n width: 64px;\n height: 80px;\n\n color: ${COLORS.black};\n\n .disabled & {\n color: ${COLORS.neutral_500};\n }\n`;\n\n\nexport const HorizontalCardImageContainer = styled.div`\n height: 100%;\n overflow: hidden;\n border-bottom-left-radius: 8px;\n border-top-left-radius: 8px;\n width: 120px;\n\n img {\n mix-blend-mode: multiply;\n object-fit: cover;\n width: 100%;\n height: 100%;\n\n }\n\n .disabled & {\n img {\n filter: grayscale(100%);\n }\n }\n\n`;\n\ntype Props = Pick<HorizontalCardProps, 'image' | 'icon'>;\n\nexport const HorizontalCardThumbnail: React.FunctionComponent<Props> = ({\n image,\n icon\n }) => {\n\n return (\n <>\n {\n icon &&\n <HorizontalCardIconContainer>\n {React.cloneElement(icon, {width: 48, height: 48})}\n </HorizontalCardIconContainer>\n }\n {\n image &&\n <HorizontalCardImageContainer>\n <ImageWithFallbacks fallbacks={image.fallbackSrc ?? ''} src={image.src} alt={image.alt}\n loader={image.loader ?? false} width={image.width} height={image.height}/>\n </HorizontalCardImageContainer>\n }\n </>\n )\n};\n"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AAEzB,OAAOC,MAAM,MAAM,mBAAmB;AACtC,SAAQC,MAAM,QAAO,cAAc;AACnC,SAAQC,kBAAkB,QAAO,aAAa;AAAC;AAAA;AAAA;AAE/C,OAAO,IAAMC,2BAA2B,GAAGH,MAAM,CAACI,GAAG,6OAO1CH,MAAM,CAACI,KAAK,EAGVJ,MAAM,CAACK,WAAW,CAE9B;AAGD,OAAO,IAAMC,4BAA4B,GAAGP,MAAM,CAACI,GAAG,6XAqBrD;AAID,OAAO,IAAMI,uBAAuD,GAAG,SAA1DA,uBAAuD,OAGU;EAAA;EAAA,IAFJC,KAAK,QAALA,KAAK;IACLC,IAAI,QAAJA,IAAI;EAG5E,oBACE;IAAA,WAEIA,IAAI,iBACF,KAAC,2BAA2B;MAAA,uBACzBX,KAAK,CAACY,YAAY,CAACD,IAAI,EAAE;QAACE,KAAK,EAAE,EAAE;QAAEC,MAAM,EAAE;MAAE,CAAC;IAAC,EACtB,EAGhCJ,KAAK,iBACH,KAAC,4BAA4B;MAAA,uBACzB,KAAC,kBAAkB;QAAC,SAAS,wBAAEA,KAAK,CAACK,WAAW,mEAAI,EAAG;QAAC,GAAG,EAAEL,KAAK,CAACM,GAAI;QAAC,GAAG,EAAEN,KAAK,CAACO,GAAI;QACnE,MAAM,mBAAEP,KAAK,CAACQ,MAAM,yDAAI,KAAM;QAAC,KAAK,EAAER,KAAK,CAACG,KAAM;QAAC,MAAM,EAAEH,KAAK,CAACI;MAAO;IAAE,EACnE;EAAA,EAElC;AAEP,CAAC"}
|