@hhgtech/hhg-components
Version:
Hello Health Group common components
69 lines (66 loc) • 3.25 kB
JavaScript
import { _ as __rest } from './tslib.es6-107c23d7.js';
import React__default from 'react';
import { u as useTranslations } from './index-1215bc9f.js';
import { C as CommonGAssets } from './index-461f72c9.js';
import { f as formatUserProfileUrl } from './dataTransform-7a8ce18a.js';
import { H as HealthToolCardWrapper } from './index-cf0a3778.js';
import { T as ThrForm } from './index-4ed9d391.js';
import './translationsContext-40d5537d.js';
import './constantsDomainLocales.js';
import './Locale-f790f969.js';
import './constantsIsProduction.js';
import '@mantine/core';
import '@hhgtech/icons/other';
import './index-2a289da8.js';
import '@mantine/hooks';
import './index-f880dc21.js';
import './utils-50ee2849.js';
import '@emotion/styled';
import '@mantine/carousel';
import './index-a5768260.js';
import './text-48aef61b.js';
import './index-6ae951d5.js';
import 'dayjs';
import './index-6482e49b.js';
import '@mantine/notifications';
import './index-e053201b.js';
import 'date-fns/locale';
import './constantsSite.js';
import './constantsRiskScreener.js';
import './miscTheme.js';
import './shared-887e5430.js';
import 'classnames';
import './useUniqueId-17d236b9.js';
import '@hhgtech/icons/core';
import './index-92ed0334.js';
import '@mantine/dates';
import './index.styles-05fc133d.js';
import './index-7f1ed00b.js';
import './miscDefaultClassWrapper.js';
import '@mantine/form';
import './useHealthToolCache-c58ca506.js';
import './miscGetDynamicHealthTool.js';
import './normalizeLink-8db8cf91.js';
import './core-4e16b9f7.js';
import './constants-19687a3a.js';
import './index-ade3e4b4.js';
import './index-ee39db81.js';
import './index-2cbb6421.js';
import 'react-keyed-flatten-children';
const THRCardEmbed = (_a) => {
var _b, _c;
var { thrContent, formProps } = _a, props = __rest(_a, ["thrContent", "formProps"]);
const { t } = useTranslations();
return (React__default.createElement(HealthToolCardWrapper, Object.assign({}, props),
React__default.createElement(HealthToolCardWrapper.Banner, { icon: React__default.createElement("img", { alt: "health-tool-icon", src: (thrContent === null || thrContent === void 0 ? void 0 : thrContent.featured_image) ||
CommonGAssets.getAssetPath('health-tools/target-heart-rate-icon.svg'), loading: "lazy" }), heading: (thrContent === null || thrContent === void 0 ? void 0 : thrContent.title) || t('targetHearRate.heading'), medicalReview: ((_b = thrContent === null || thrContent === void 0 ? void 0 : thrContent.reviewedBy) === null || _b === void 0 ? void 0 : _b.display_name)
? {
link: formatUserProfileUrl(thrContent === null || thrContent === void 0 ? void 0 : thrContent.reviewedBy),
reviewer: (_c = thrContent === null || thrContent === void 0 ? void 0 : thrContent.reviewedBy) === null || _c === void 0 ? void 0 : _c.display_name,
date: thrContent === null || thrContent === void 0 ? void 0 : thrContent.reviewedDate,
}
: undefined }),
React__default.createElement(HealthToolCardWrapper.Body, null,
React__default.createElement(ThrForm, Object.assign({}, formProps)))));
};
export { THRCardEmbed };