luna-one 1.0.243 → 1.0.245
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/global-styles/fonts/opensans.scss +5 -0
- package/dist/global-styles/global-vars.scss +2 -2
- package/dist/global-styles/mixins/_typography.scss +11 -11
- package/dist/luna/components/AdminCategoryData/AdminCategoryData.js +13 -9
- package/dist/luna/components/AdminCategoryData/AdminCategoryData.scss +1 -1
- package/dist/luna/components/AdminCategoryData/AdminCategoryDataMethods.js +13 -16
- package/dist/luna/components/AdminProductData/AdminProductData.js +28 -27
- package/dist/luna/components/AdminProductData/AdminProductDataMethods.js +5 -5
- package/dist/luna/components/BrowserSupportBanner/BrowserSupportBanner.js +23 -27
- package/dist/luna/components/EventCard/EventCard.js +15 -13
- package/dist/luna/components/EventCard/EventCard.scss +2 -2
- package/dist/luna/components/Heading/Heading.js +7 -5
- package/dist/luna/components/LanguageSelector/LanguageSelector.js +18 -23
- package/dist/luna/components/LanguageSelector/LanguageSelectorHooks.js +8 -12
- package/dist/luna/components/LanguageSelector/LanguageSelectorMethods.js +5 -7
- package/dist/luna/components/MegaMenu/MegaMenu.js +23 -33
- package/dist/luna/components/MegaMenu/MegaMenu.scss +2 -2
- package/dist/luna/components/MegaMenu/RightSection.js +3 -3
- package/dist/luna/components/MiniFeatDropdown/MiniFeatDropdown.js +40 -50
- package/dist/luna/components/MiniFeatDropdown/MiniFeatDropdown.scss +1 -1
- package/dist/luna/components/MobileMegaMenu/MobileMegaMenu.js +16 -22
- package/dist/luna/components/MobileMegaMenu/MobileMegaMenu.scss +3 -3
- package/dist/luna/components/MobileMegaMenu/MobileMegaMenuCategory.js +10 -10
- package/dist/luna/components/MobileMegaMenu/MobileMegaMenuPartialCategory.js +7 -5
- package/dist/luna/components/MobileMenu/MobileMenu.js +10 -10
- package/dist/luna/components/MobileMenu/MobileMenu.scss +1 -1
- package/dist/luna/components/MobileNav/MobileNav.js +25 -33
- package/dist/luna/components/MobileNav/MobileNav.scss +1 -1
- package/dist/luna/components/MobileNav/TopMobileNav.js +21 -23
- package/dist/luna/components/NavBarTop/NavBarTop.js +100 -118
- package/dist/luna/components/NavSearch/NavSearch.js +9 -7
- package/dist/luna/components/ParallaxController/ParallaxController.js +8 -8
- package/dist/luna/components/RegionCard/RegionCard.js +15 -15
- package/dist/luna/components/ScrollToTop/ScrollToTop.js +5 -4
- package/dist/luna/components/StoreFrontCard/StoreFrontCard.js +10 -19
- package/dist/luna/components/SupportCard/SupportCard.js +13 -11
- package/dist/luna/components/SupportCard/SupportCard.scss +2 -2
- package/dist/luna/components/SupportCard/SupportCardMethods.js +7 -7
- package/dist/luna/components/VariableContentCard/VariableContentCard.js +35 -54
- package/dist/luna/components/VariableContentCard/VariableContentCard.scss +2 -2
- package/dist/luna/components/VidyardModal/VidyardModal.js +9 -7
- package/dist/luna/depracated/Feat10/Feat10.js +20 -17
- package/dist/luna/depracated/Feat10/Feat10.scss +1 -1
- package/dist/luna/depracated/Feat4Flex/Feat4Flex.js +34 -30
- package/dist/luna/depracated/Feat4Flex/Feat4FlexMethods.js +8 -8
- package/dist/luna/depracated/Feat5/Feat5.js +28 -24
- package/dist/luna/depracated/Feat5/Feat5Methods.js +8 -8
- package/dist/luna/depracated/Feat7/Feat7.js +41 -34
- package/dist/luna/depracated/Feat8/Feat8.js +40 -36
- package/dist/luna/depracated/Feat8/Feat8Methods.js +3 -3
- package/dist/luna/depracated/Hero5/Hero5.js +18 -15
- package/dist/luna/depracated/MegaFeat/MegaFeat.js +29 -25
- package/dist/luna/depracated/MegaFeat/MegaFeatMethods.js +15 -15
- package/dist/luna/depracated/MegaMenu/MegaMenu.js +19 -23
- package/dist/luna/depracated/MegaMenu/MegaMenu.scss +1 -1
- package/dist/luna/depracated/MegaMenu/MegaMenuUtils.js +17 -17
- package/dist/luna/depracated/ParallaxBackground/ParallaxBackground.js +56 -70
- package/dist/luna/featurettes/CustomFeat/CustomFeat.js +72 -85
- package/dist/luna/featurettes/Feat1/Feat1.js +27 -23
- package/dist/luna/featurettes/Feat1/feat1Methods.js +1 -1
- package/dist/luna/featurettes/Feat2A/Feat2A.js +12 -10
- package/dist/luna/featurettes/Feat2B/Feat2B.js +14 -12
- package/dist/luna/featurettes/Feat2B/Feat2BMethods.js +5 -5
- package/dist/luna/featurettes/Feat3/Feat3.js +10 -9
- package/dist/luna/featurettes/Feat4/Feat4.js +17 -19
- package/dist/luna/featurettes/Feat4/LazyBackgroundImage.js +7 -4
- package/dist/luna/featurettes/Feat5/Feat5.js +48 -56
- package/dist/luna/featurettes/Feat5/Feat5.scss +1 -1
- package/dist/luna/featurettes/Feat5/Feat5Methods.js +1 -1
- package/dist/luna/featurettes/Feat6/Feat6.js +15 -14
- package/dist/luna/featurettes/Feat6/Feat6.scss +1 -1
- package/dist/luna/featurettes/Feat7/Feat7.js +13 -10
- package/dist/luna/featurettes/Feat7/Feat7.scss +2 -2
- package/dist/luna/featurettes/Feat8/Feat8.js +10 -9
- package/dist/luna/heroes/FilterHero/FilterHero.js +83 -91
- package/dist/luna/heroes/FilterHero/FilterHero.scss +1 -1
- package/dist/luna/heroes/Hero1/Hero1.js +24 -30
- package/dist/luna/heroes/Hero1/Hero1Methods.js +3 -5
- package/dist/luna/heroes/Hero2/Hero2.js +12 -13
- package/dist/luna/heroes/Hero3/Hero3.js +38 -48
- package/dist/luna/heroes/Hero3/Hero4Methods.js +1 -1
- package/dist/luna/heroes/Hero4/Hero4.js +19 -18
- package/dist/luna/heroes/Hero4/hero4Methods.js +1 -1
- package/dist/luna/heroes/Hero6/Hero6.js +18 -18
- package/dist/luna/heroes/Hero6/Hero6Methods.js +2 -2
- package/dist/luna/heroes/HeroRatioWrapper/HeroRatioWrapper.js +6 -4
- package/dist/luna/list-feats/ListFeat/ListFeat.js +22 -23
- package/dist/luna/list-feats/ListFeat/ListFeat.scss +2 -2
- package/dist/luna/list-feats/ListFeat1/ListFeat1.js +10 -7
- package/dist/luna/list-feats/ListFeat1/ListFeat1.scss +1 -1
- package/dist/luna/list-feats/ListFeat1/listFeat1Methods.js +1 -1
- package/dist/luna/list-feats/ListFeat2/ListFeat2.js +7 -5
- package/dist/luna/list-feats/ListFeat2/ListFeat2Methods.js +4 -4
- package/dist/luna/list-feats/ListFeat3/ListFeat3.js +10 -8
- package/dist/luna/list-feats/ListFeat4/ListFeat4.js +7 -5
- package/dist/luna/list-feats/ListFeat5/ListFeat5.js +7 -5
- package/dist/luna/list-feats/ListFeat5/ListFeat5Methods.js +2 -2
- package/dist/luna/list-feats/ListFeat6/ListFeat6.js +11 -9
- package/dist/luna/list-feats/ListFeat7/ListFeat7.js +26 -23
- package/dist/luna/list-feats/ListFeat7/ListFeat7Methods.js +17 -15
- package/dist/luna/list-feats/ListFeat8/ListFeat8.js +10 -8
- package/dist/luna/list-feats/ListFeat9/ListFeat9.js +10 -8
- package/dist/luna/list-feats/ListFeatCustom/ListFeatCustom.js +5 -3
- package/dist/luna/list-feats/methods/listFeatMethods.js +7 -7
- package/dist/luna/other-organisms/Footer/Footer.js +25 -21
- package/dist/luna/other-organisms/Footer/Footer.scss +2 -2
- package/dist/luna/other-organisms/MarketoForm/MarketoForm.js +61 -74
- package/dist/luna/other-organisms/NavBar/NavBar.js +151 -181
- package/dist/luna/other-organisms/NavBar/NavBar.scss +4 -4
- package/dist/luna/other-organisms/NavBar/NavBarMethods.js +16 -24
- package/dist/luna/utils/calcRatioPadding.js +1 -1
- package/dist/luna/utils/checkForDangerouslySet.js +5 -5
- package/dist/luna/utils/checkThemeForBrand.js +9 -9
- package/dist/luna/utils/formatID.js +1 -1
- package/dist/luna/utils/generateBackgroundImage.js +19 -18
- package/dist/luna/utils/generateID.js +1 -1
- package/dist/luna/utils/generateLinks.js +35 -26
- package/dist/luna/utils/generateStyles.js +5 -5
- package/dist/luna/utils/generateThemeClassName.js +2 -2
- package/dist/luna/utils/getOffsetTop.js +1 -1
- package/dist/luna/utils/globalVariables.js +1 -1
- package/dist/luna/utils/hooks/useVariableContent.js +18 -28
- package/dist/luna/utils/hooks/useVideo.js +17 -27
- package/dist/luna/utils/removeSpaces.js +1 -1
- package/dist/luna/utils/testForPassiveScroll.js +3 -3
- package/package.json +2 -2
- package/dist/global-styles/fonts/benton.scss +0 -5
|
@@ -213,7 +213,7 @@ $box-shadows: (
|
|
|
213
213
|
);
|
|
214
214
|
|
|
215
215
|
// font family
|
|
216
|
-
$font-sans-serif: "
|
|
216
|
+
$font-sans-serif: "Open Sans", -apple-system, BlinkMacSystemFont,
|
|
217
217
|
"helvetica neue", helvetica, ubuntu, roboto, noto, "segoe ui", arial,
|
|
218
218
|
sans-serif;
|
|
219
219
|
$font-serif: georgia, times, serif;
|
|
@@ -242,7 +242,7 @@ $pagination-border-active-color: color("brand-1");
|
|
|
242
242
|
|
|
243
243
|
// headers
|
|
244
244
|
$header-font-color: color("gray-8");
|
|
245
|
-
$header-font-family: "
|
|
245
|
+
$header-font-family: "Open Sans", $font-sans-serif;
|
|
246
246
|
$header-font-weight: font-weight("extra-bold");
|
|
247
247
|
|
|
248
248
|
// links
|
|
@@ -27,21 +27,21 @@
|
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
// sets font-size
|
|
30
|
-
$normal-font-family: "
|
|
30
|
+
$normal-font-family: "Open Sans", -apple-system, BlinkMacSystemFont,
|
|
31
31
|
"helvetica neue", helvetica, ubuntu, roboto, noto, "segoe ui", arial,
|
|
32
32
|
sans-serif;
|
|
33
33
|
|
|
34
34
|
$light-font-weight: 100;
|
|
35
|
-
$light-font-family: "
|
|
35
|
+
$light-font-family: "Open Sans Light", -apple-system, BlinkMacSystemFont,
|
|
36
36
|
"helvetica neue", helvetica, ubuntu, roboto, noto, "segoe ui", arial,
|
|
37
37
|
sans-serif;
|
|
38
38
|
|
|
39
|
-
$medium-font-weight:
|
|
40
|
-
$medium-font-family: "
|
|
39
|
+
$medium-font-weight: 600;
|
|
40
|
+
$medium-font-family: "Open Sans Medium", -apple-system, BlinkMacSystemFont,
|
|
41
41
|
"helvetica neue", helvetica, ubuntu, roboto, noto, "segoe ui", arial,
|
|
42
42
|
sans-serif;
|
|
43
43
|
|
|
44
|
-
$very-bold-font-family: "
|
|
44
|
+
$very-bold-font-family: "Open Sans ExtraBold", -apple-system,
|
|
45
45
|
BlinkMacSystemFont, "helvetica neue", helvetica, ubuntu, roboto, noto,
|
|
46
46
|
"segoe ui", arial, sans-serif;
|
|
47
47
|
|
|
@@ -50,21 +50,21 @@ $very-bold-font-family: "Benton Sans W05 Black", -apple-system,
|
|
|
50
50
|
}
|
|
51
51
|
|
|
52
52
|
// NEW BENTING FONT STYLING
|
|
53
|
-
@mixin
|
|
53
|
+
@mixin opensans-normal() {
|
|
54
54
|
font-family: $normal-font-family;
|
|
55
55
|
}
|
|
56
56
|
|
|
57
|
-
@mixin
|
|
57
|
+
@mixin opensans-light() {
|
|
58
58
|
font-family: $light-font-family;
|
|
59
59
|
font-weight: $light-font-weight;
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
@mixin
|
|
62
|
+
@mixin opensans-medium() {
|
|
63
63
|
font-family: $medium-font-family;
|
|
64
64
|
font-weight: $medium-font-weight;
|
|
65
65
|
}
|
|
66
66
|
|
|
67
|
-
@mixin
|
|
67
|
+
@mixin opensans-very-bold() {
|
|
68
68
|
font-family: $very-bold-font-family;
|
|
69
69
|
}
|
|
70
70
|
|
|
@@ -72,9 +72,9 @@ h3,
|
|
|
72
72
|
h4,
|
|
73
73
|
h1,
|
|
74
74
|
h2 {
|
|
75
|
-
@include
|
|
75
|
+
@include opensans-very-bold();
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
strong {
|
|
79
|
-
@include
|
|
79
|
+
@include opensans-medium();
|
|
80
80
|
}
|
|
@@ -1,21 +1,25 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import "./AdminCategoryData.scss";
|
|
3
3
|
import CategoryTranslationData from "./AdminCategoryDataMethods";
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
4
|
+
const AdminCategoryData = _ref => {
|
|
5
|
+
let {
|
|
6
|
+
content,
|
|
7
|
+
currentLanguageURL
|
|
8
|
+
} = _ref;
|
|
9
|
+
const {
|
|
10
|
+
name,
|
|
11
|
+
industry,
|
|
12
|
+
url,
|
|
13
|
+
languageOptions,
|
|
14
|
+
translations
|
|
15
|
+
} = content;
|
|
12
16
|
return /*#__PURE__*/React.createElement("div", {
|
|
13
17
|
className: "luna-admin-category-data"
|
|
14
18
|
}, name && /*#__PURE__*/React.createElement("h4", {
|
|
15
19
|
className: "luna-admin-category-data__name"
|
|
16
20
|
}, name), industry && /*#__PURE__*/React.createElement("p", {
|
|
17
21
|
className: "luna-admin-category-data__industry"
|
|
18
|
-
}, /*#__PURE__*/React.createElement("span", null, "Industry:"), " ", industry), translations && /*#__PURE__*/React.createElement(React.Fragment, null, translations.map(
|
|
22
|
+
}, /*#__PURE__*/React.createElement("span", null, "Industry:"), " ", industry), translations && /*#__PURE__*/React.createElement(React.Fragment, null, translations.map((translation, index) => {
|
|
19
23
|
return /*#__PURE__*/React.createElement(CategoryTranslationData, {
|
|
20
24
|
key: translation.name + index,
|
|
21
25
|
content: translation,
|
|
@@ -1,21 +1,18 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { NavLink } from "react-router-dom";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
content =
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
text = _content$text === void 0 ? "" : _content$text,
|
|
17
|
-
_content$teaserImage = content.teaserImage,
|
|
18
|
-
teaserImage = _content$teaserImage === void 0 ? {} : _content$teaserImage;
|
|
3
|
+
const CategoryTranslationData = _ref => {
|
|
4
|
+
let {
|
|
5
|
+
content = {},
|
|
6
|
+
url = "",
|
|
7
|
+
currentLanguageURL,
|
|
8
|
+
languageOptions = {}
|
|
9
|
+
} = _ref;
|
|
10
|
+
const {
|
|
11
|
+
language = "",
|
|
12
|
+
name = "",
|
|
13
|
+
text = "",
|
|
14
|
+
teaserImage = {}
|
|
15
|
+
} = content;
|
|
19
16
|
return /*#__PURE__*/React.createElement("div", {
|
|
20
17
|
className: "luna-category-translation-data"
|
|
21
18
|
}, teaserImage.url && /*#__PURE__*/React.createElement("img", {
|
|
@@ -2,14 +2,18 @@ import React from "react";
|
|
|
2
2
|
import { renderRegions } from "./AdminProductDataMethods";
|
|
3
3
|
import "./AdminProductData.scss";
|
|
4
4
|
import { NavLink } from "react-router-dom";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
5
|
+
const AdminProductData = _ref => {
|
|
6
|
+
let {
|
|
7
|
+
content,
|
|
8
|
+
currentLanguageURL
|
|
9
|
+
} = _ref;
|
|
10
|
+
const {
|
|
11
|
+
name,
|
|
12
|
+
regions,
|
|
13
|
+
translations,
|
|
14
|
+
url,
|
|
15
|
+
languageOptions
|
|
16
|
+
} = content;
|
|
13
17
|
return /*#__PURE__*/React.createElement("div", {
|
|
14
18
|
className: "luna-admin-product-data"
|
|
15
19
|
}, name && /*#__PURE__*/React.createElement("h4", {
|
|
@@ -18,7 +22,7 @@ var AdminProductData = function AdminProductData(_ref) {
|
|
|
18
22
|
className: "luna-admin-product-data__region-wrapper"
|
|
19
23
|
}, /*#__PURE__*/React.createElement("p", {
|
|
20
24
|
className: "luna-admin-product-data__regions"
|
|
21
|
-
}, "Regions:"), renderRegions(regions)), translations && /*#__PURE__*/React.createElement(React.Fragment, null, translations.map(
|
|
25
|
+
}, "Regions:"), renderRegions(regions)), translations && /*#__PURE__*/React.createElement(React.Fragment, null, translations.map((translation, index) => {
|
|
22
26
|
return /*#__PURE__*/React.createElement(TranslationData, {
|
|
23
27
|
key: translation.teaserName + index,
|
|
24
28
|
content: translation,
|
|
@@ -29,22 +33,19 @@ var AdminProductData = function AdminProductData(_ref) {
|
|
|
29
33
|
})), /*#__PURE__*/React.createElement("div", null));
|
|
30
34
|
};
|
|
31
35
|
export default AdminProductData;
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
content =
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
teaserName = _content$teaserName === void 0 ? "" : _content$teaserName,
|
|
46
|
-
_content$teaserText = content.teaserText,
|
|
47
|
-
teaserText = _content$teaserText === void 0 ? "" : _content$teaserText;
|
|
36
|
+
const TranslationData = _ref2 => {
|
|
37
|
+
let {
|
|
38
|
+
content = {},
|
|
39
|
+
url = "",
|
|
40
|
+
currentLanguageURL,
|
|
41
|
+
languageOptions = {}
|
|
42
|
+
} = _ref2;
|
|
43
|
+
const {
|
|
44
|
+
language = "",
|
|
45
|
+
teaserImage = {},
|
|
46
|
+
teaserName = "",
|
|
47
|
+
teaserText = ""
|
|
48
|
+
} = content;
|
|
48
49
|
return /*#__PURE__*/React.createElement("div", {
|
|
49
50
|
className: "luna-translation-data"
|
|
50
51
|
}, /*#__PURE__*/React.createElement("img", {
|
|
@@ -67,8 +68,8 @@ var TranslationData = function TranslationData(_ref2) {
|
|
|
67
68
|
to: "/".concat(currentLanguageURL, "/admin").concat(url, "/").concat(language)
|
|
68
69
|
}, "/admin".concat(url, "/").concat(language)))));
|
|
69
70
|
};
|
|
70
|
-
|
|
71
|
-
|
|
71
|
+
const truncateString = function (str) {
|
|
72
|
+
let num = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 30;
|
|
72
73
|
if (str.length <= num) {
|
|
73
74
|
return str;
|
|
74
75
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
|
|
2
|
+
const addSpace = (regions, index) => {
|
|
3
3
|
if (index === 0 && regions.length > 1) {
|
|
4
4
|
return true;
|
|
5
5
|
} else if (index !== 0 && index !== regions.length - 1) {
|
|
@@ -8,12 +8,12 @@ var addSpace = function addSpace(regions, index) {
|
|
|
8
8
|
return false;
|
|
9
9
|
}
|
|
10
10
|
};
|
|
11
|
-
export
|
|
12
|
-
|
|
11
|
+
export const renderRegions = function () {
|
|
12
|
+
let regions = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
13
13
|
return /*#__PURE__*/React.createElement("ul", {
|
|
14
14
|
className: "luna-admin-product-data__region-list"
|
|
15
|
-
}, regions.map(
|
|
16
|
-
|
|
15
|
+
}, regions.map((region, index) => {
|
|
16
|
+
const space = addSpace(regions, index);
|
|
17
17
|
return /*#__PURE__*/React.createElement("li", {
|
|
18
18
|
className: "luna-admin-product-data__region-list-item ".concat(space ? "luna-admin-product-data__region-list-item--add-space" : "luna-admin-product-data__region-list-item--default"),
|
|
19
19
|
key: region
|
|
@@ -1,40 +1,38 @@
|
|
|
1
|
-
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
2
1
|
import React, { useEffect, useState } from "react";
|
|
3
2
|
import { Alert } from "terra-component-lib";
|
|
4
3
|
import "./BrowserSupportBanner.scss";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
useEffect(function () {
|
|
4
|
+
const BrowserSupportBanner = _ref => {
|
|
5
|
+
let {
|
|
6
|
+
content
|
|
7
|
+
} = _ref;
|
|
8
|
+
const [activeBanner, setActiveBanner] = useState(true);
|
|
9
|
+
useEffect(() => {
|
|
12
10
|
checkBrowser();
|
|
13
11
|
});
|
|
14
|
-
|
|
12
|
+
const checkBrowser = () => {
|
|
15
13
|
// the !! will convert the response to a boolean. Without doing so, the following will return either an array or null.
|
|
16
14
|
|
|
17
15
|
// Opera 8.0+
|
|
18
|
-
|
|
16
|
+
const Opera = !!window.opera || navigator.userAgent.indexOf(" OPR/") >= 0;
|
|
19
17
|
|
|
20
18
|
// Firefox 1.0+
|
|
21
|
-
|
|
19
|
+
const Firefox = typeof InstallTrigger !== "undefined";
|
|
22
20
|
|
|
23
21
|
// Safari 3.0+ "[object HTMLElementConstructor]"
|
|
24
|
-
|
|
22
|
+
const Safari = checkForSafari();
|
|
25
23
|
|
|
26
24
|
// Internet Explorer 6-11
|
|
27
|
-
|
|
25
|
+
const IE = !!document.documentMode || checkForIE();
|
|
28
26
|
|
|
29
27
|
// Edge 20+
|
|
30
|
-
|
|
28
|
+
const Edge = !IE && !!window.StyleMedia;
|
|
31
29
|
|
|
32
30
|
// Chrome 1 - 79
|
|
33
|
-
|
|
31
|
+
const Chrome = !!window.chrome && (!!window.chrome.webstore || !!window.chrome.runtime);
|
|
34
32
|
|
|
35
33
|
// Edge (based on chromium) detection
|
|
36
|
-
|
|
37
|
-
|
|
34
|
+
const EdgeChromium = Chrome && navigator.userAgent.indexOf("Edg") != -1;
|
|
35
|
+
const output = {
|
|
38
36
|
firefox: Firefox,
|
|
39
37
|
safari: Safari,
|
|
40
38
|
ie: IE,
|
|
@@ -42,8 +40,8 @@ var BrowserSupportBanner = function BrowserSupportBanner(_ref) {
|
|
|
42
40
|
chrome: Chrome,
|
|
43
41
|
EdgeChromium: EdgeChromium
|
|
44
42
|
};
|
|
45
|
-
|
|
46
|
-
for (
|
|
43
|
+
let currentBrowser;
|
|
44
|
+
for (let i in output) {
|
|
47
45
|
if (output[i] === true) {
|
|
48
46
|
currentBrowser = i;
|
|
49
47
|
}
|
|
@@ -54,30 +52,28 @@ var BrowserSupportBanner = function BrowserSupportBanner(_ref) {
|
|
|
54
52
|
setActiveBanner(false);
|
|
55
53
|
}
|
|
56
54
|
};
|
|
57
|
-
|
|
55
|
+
const checkForSafari = () => {
|
|
58
56
|
if (navigator.vendor.match(/apple/i)) {
|
|
59
57
|
return true;
|
|
60
58
|
} else {
|
|
61
59
|
return false;
|
|
62
60
|
}
|
|
63
61
|
};
|
|
64
|
-
|
|
65
|
-
|
|
62
|
+
const checkForIE = () => {
|
|
63
|
+
const userAgent = navigator.userAgent;
|
|
66
64
|
|
|
67
65
|
// MSIE used to detect old browsers and Trident used to newer ones
|
|
68
|
-
|
|
66
|
+
const is_ie = userAgent.indexOf("MSIE ") > -1 || userAgent.indexOf("Trident/") > -1;
|
|
69
67
|
return is_ie;
|
|
70
68
|
};
|
|
71
|
-
|
|
69
|
+
const removeAlert = () => {
|
|
72
70
|
setActiveBanner(!activeBanner);
|
|
73
71
|
};
|
|
74
72
|
return /*#__PURE__*/React.createElement("div", {
|
|
75
73
|
className: activeBanner ? "browser-support-banner" : " browser-support-banner remove-alert"
|
|
76
74
|
}, /*#__PURE__*/React.createElement(Alert, {
|
|
77
75
|
text: content.text,
|
|
78
|
-
onClick:
|
|
79
|
-
return removeAlert();
|
|
80
|
-
},
|
|
76
|
+
onClick: () => removeAlert(),
|
|
81
77
|
type: content.type || "default"
|
|
82
78
|
}));
|
|
83
79
|
};
|
|
@@ -3,19 +3,21 @@ import { Icon } from "terra-component-lib";
|
|
|
3
3
|
import "./EventCard.scss";
|
|
4
4
|
import { IconLink } from "../../utils/generateLinks";
|
|
5
5
|
import { removeSpaces } from "../../utils/removeSpaces";
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
content =
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
6
|
+
const EventCard = _ref => {
|
|
7
|
+
let {
|
|
8
|
+
content = {}
|
|
9
|
+
} = _ref;
|
|
10
|
+
const {
|
|
11
|
+
date,
|
|
12
|
+
year,
|
|
13
|
+
industry,
|
|
14
|
+
industryLabel,
|
|
15
|
+
name,
|
|
16
|
+
location,
|
|
17
|
+
description,
|
|
18
|
+
image,
|
|
19
|
+
link = {}
|
|
20
|
+
} = content;
|
|
19
21
|
return /*#__PURE__*/React.createElement("div", {
|
|
20
22
|
className: "mep-event-card"
|
|
21
23
|
}, /*#__PURE__*/React.createElement("div", {
|
|
@@ -55,7 +55,7 @@ $event-card-border: 1px solid color("gray-4");
|
|
|
55
55
|
|
|
56
56
|
&__date {
|
|
57
57
|
margin-bottom: 10px;
|
|
58
|
-
@include
|
|
58
|
+
@include opensans-medium();
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
&__image {
|
|
@@ -88,7 +88,7 @@ $event-card-border: 1px solid color("gray-4");
|
|
|
88
88
|
&__name {
|
|
89
89
|
font-size: 16px;
|
|
90
90
|
line-height: 20px;
|
|
91
|
-
@include
|
|
91
|
+
@include opensans-medium();
|
|
92
92
|
}
|
|
93
93
|
|
|
94
94
|
&__description {
|
|
@@ -4,12 +4,14 @@ import React from "react";
|
|
|
4
4
|
* Render a single Heading tag with specified level.
|
|
5
5
|
* If text is undefined or null, nothing is rendered.
|
|
6
6
|
*/
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
const Heading = _ref => {
|
|
8
|
+
let {
|
|
9
|
+
level,
|
|
10
|
+
className,
|
|
11
|
+
text
|
|
12
|
+
} = _ref;
|
|
11
13
|
return React.createElement("h".concat(level), {
|
|
12
|
-
className
|
|
14
|
+
className
|
|
13
15
|
}, text);
|
|
14
16
|
};
|
|
15
17
|
export default Heading;
|
|
@@ -4,22 +4,23 @@ import globe from "../../images/worldwide.svg";
|
|
|
4
4
|
import closeIcon from "../../images/close-button.svg";
|
|
5
5
|
import { useSelection } from "./LanguageSelectorHooks";
|
|
6
6
|
import { renderRegions, selectLanguage } from "./LanguageSelectorMethods";
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
7
|
+
const LanguageSelector = _ref => {
|
|
8
|
+
let {
|
|
9
|
+
currentRegionLanguage,
|
|
10
|
+
close,
|
|
11
|
+
labels,
|
|
12
|
+
regions,
|
|
13
|
+
companyDivision,
|
|
14
|
+
activeRegion,
|
|
15
|
+
setLanguage
|
|
16
|
+
} = _ref;
|
|
17
|
+
const {
|
|
18
|
+
selection,
|
|
19
|
+
handleSelection
|
|
20
|
+
} = useSelection();
|
|
18
21
|
return /*#__PURE__*/React.createElement("aside", {
|
|
19
22
|
className: "luna-language-selector ".concat(regions && regions.length <= 1 ? "luna-language-selector--centered" : "luna-language-selector--default"),
|
|
20
|
-
onClick:
|
|
21
|
-
return e.stopPropagation();
|
|
22
|
-
}
|
|
23
|
+
onClick: e => e.stopPropagation()
|
|
23
24
|
}, /*#__PURE__*/React.createElement("section", {
|
|
24
25
|
className: "luna-language-selector__top-section"
|
|
25
26
|
}, /*#__PURE__*/React.createElement("div", {
|
|
@@ -35,9 +36,7 @@ var LanguageSelector = function LanguageSelector(_ref) {
|
|
|
35
36
|
className: "luna-language-selector__current-region-label"
|
|
36
37
|
}, "Current Language ", " ", " | ", " "), /*#__PURE__*/React.createElement("span", null, currentRegionLanguage.language.toUpperCase()))), /*#__PURE__*/React.createElement("button", {
|
|
37
38
|
className: "luna-language-selector__close-btn",
|
|
38
|
-
onClick:
|
|
39
|
-
return close();
|
|
40
|
-
}
|
|
39
|
+
onClick: () => close()
|
|
41
40
|
}, /*#__PURE__*/React.createElement("img", {
|
|
42
41
|
className: "luna-language-selector__close-icon",
|
|
43
42
|
loading: "lazy",
|
|
@@ -49,14 +48,10 @@ var LanguageSelector = function LanguageSelector(_ref) {
|
|
|
49
48
|
className: "luna-language-selector__bottom-section"
|
|
50
49
|
}, /*#__PURE__*/React.createElement("button", {
|
|
51
50
|
className: "luna-language-selector__bottom-button",
|
|
52
|
-
onClick:
|
|
53
|
-
return close();
|
|
54
|
-
}
|
|
51
|
+
onClick: () => close()
|
|
55
52
|
}, labels.cancel), /*#__PURE__*/React.createElement("button", {
|
|
56
53
|
className: "luna-language-selector__bottom-button",
|
|
57
|
-
onClick:
|
|
58
|
-
return selectLanguage(setLanguage, selection);
|
|
59
|
-
}
|
|
54
|
+
onClick: () => selectLanguage(setLanguage, selection)
|
|
60
55
|
}, labels.save)));
|
|
61
56
|
};
|
|
62
57
|
export default LanguageSelector;
|
|
@@ -1,19 +1,15 @@
|
|
|
1
|
-
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
2
1
|
import { useState } from "react";
|
|
3
|
-
export
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
selection = _useState2[0],
|
|
8
|
-
updateSelection = _useState2[1];
|
|
9
|
-
var handleSelection = function handleSelection(region, language) {
|
|
2
|
+
export const useSelection = function () {
|
|
3
|
+
let initialState = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
|
|
4
|
+
const [selection, updateSelection] = useState(null);
|
|
5
|
+
const handleSelection = (region, language) => {
|
|
10
6
|
updateSelection({
|
|
11
|
-
region
|
|
12
|
-
language
|
|
7
|
+
region,
|
|
8
|
+
language
|
|
13
9
|
});
|
|
14
10
|
};
|
|
15
11
|
return {
|
|
16
|
-
selection
|
|
17
|
-
handleSelection
|
|
12
|
+
selection,
|
|
13
|
+
handleSelection
|
|
18
14
|
};
|
|
19
15
|
};
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import React, { lazy, Suspense } from "react";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export var renderRegions = function renderRegions(regions, handleSelection, currentRegionLanguage, companyDivision, selection, activeRegion) {
|
|
6
|
-
return regions.map(function (region) {
|
|
2
|
+
const RegionCard = lazy(() => import("../RegionCard/RegionCard"));
|
|
3
|
+
export const renderRegions = (regions, handleSelection, currentRegionLanguage, companyDivision, selection, activeRegion) => {
|
|
4
|
+
return regions.map(region => {
|
|
7
5
|
return /*#__PURE__*/React.createElement(Suspense, {
|
|
8
6
|
fallback: "Loading..."
|
|
9
7
|
}, /*#__PURE__*/React.createElement(RegionCard, {
|
|
@@ -18,7 +16,7 @@ export var renderRegions = function renderRegions(regions, handleSelection, curr
|
|
|
18
16
|
}));
|
|
19
17
|
});
|
|
20
18
|
};
|
|
21
|
-
export
|
|
19
|
+
export const determineActive = (region, selection, activeRegion) => {
|
|
22
20
|
if (selection && selection.region !== region) {
|
|
23
21
|
return false;
|
|
24
22
|
}
|
|
@@ -28,7 +26,7 @@ export var determineActive = function determineActive(region, selection, activeR
|
|
|
28
26
|
return false;
|
|
29
27
|
}
|
|
30
28
|
};
|
|
31
|
-
export
|
|
29
|
+
export const selectLanguage = (setLanguage, selection) => {
|
|
32
30
|
if (selection) {
|
|
33
31
|
setLanguage(selection);
|
|
34
32
|
} else {
|