@bigbinary/neeto-molecules 1.0.78-beta → 1.0.79-beta

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.
@@ -7,7 +7,7 @@ import { useTranslation, Trans } from 'react-i18next';
7
7
  import { Column, Download, Filter, MenuVertical, Search, MenuHorizontal, Info, Copy, Check } from '@bigbinary/neeto-icons';
8
8
  import ManageColumns from '@bigbinary/neeto-molecules/Columns';
9
9
  import { Filters } from '@bigbinary/neeto-filters-frontend';
10
- import { withEventTargetValue, joinHyphenCase, copyToClipboard, timeFormat } from '@bigbinary/neeto-commons-frontend/utils';
10
+ import { withEventTargetValue, joinHyphenCase, copyToClipboard } from '@bigbinary/neeto-commons-frontend/utils';
11
11
  import { Link } from 'react-router-dom';
12
12
  import { Formik, Form } from 'formik';
13
13
  import { Input as Input$1 } from '@bigbinary/neetoui/formik';
@@ -1587,7 +1587,7 @@ var RightBlock = function RightBlock(_ref) {
1587
1587
  }, downloadButtonProps && /*#__PURE__*/React__default.createElement(DownloadButton, downloadButtonProps), columnsButtonProps && /*#__PURE__*/React__default.createElement(Columns, columnsButtonProps), filterProps && /*#__PURE__*/React__default.createElement(FilterButton, filterProps));
1588
1588
  };
1589
1589
 
1590
- var css$1 = ".neeto-molecules-subheader{align-items:center;background-color:rgb(var(--neeto-ui-white));display:flex;flex-direction:row;justify-content:space-between;margin-bottom:var(--neeto-ui-sub-header-bottom-margin);min-height:var(--neeto-ui-sub-header-height);width:100%}.neeto-molecules-subheader .neeto-molecules-subheader__left-wrapper{display:flex;flex-grow:1}.neeto-molecules-subheader .neeto-molecules-subheader__left-wrapper .neeto-molecules-subheader__left{align-items:center;display:flex;flex-direction:row;justify-content:flex-start}.neeto-molecules-subheader .neeto-molecules-subheader__left-wrapper .neeto-molecules-subheader__left .neeto-molecules-input__prefix{color:rgb(var(--neeto-ui-gray-400))}.neeto-molecules-subheader .neeto-molecules-subheader__right{align-items:center;display:flex;flex-direction:row;gap:12px;justify-content:flex-end}.neeto-molecules-subheader .neeto-molecules-subheader__right-actions{align-items:center;display:flex;flex-direction:row;gap:8px;justify-content:flex-end}.neeto-molecules-subheader .neeto-molecules-subheader__right-actions>:not([hidden])~:not([hidden]){border-left:thin solid rgb(var(--neeto-ui-gray-300));padding-left:8px}.neeto-molecules-subheader__download{position:relative}.neeto-molecules-subheader__download-count{align-items:center;background-color:rgb(var(--neeto-ui-primary-500));border-radius:var(--neeto-ui-rounded-full);color:rgb(var(--neeto-ui-white));display:inline-flex;font-size:10px;justify-content:center;min-height:16px;min-width:16px;position:absolute;right:-2px;text-align:center;top:-2px;z-index:1}";
1590
+ var css$1 = ":root{--neeto-molecules-sub-header-height:37px;--neeto-molecules-sub-header-bottom-margin:20px}.neeto-molecules-subheader{align-items:center;background-color:rgb(var(--neeto-ui-white));display:flex;flex-direction:row;justify-content:space-between;margin-bottom:20px;margin-bottom:var(--neeto-molecules-sub-header-bottom-margin);min-height:37px;min-height:var(--neeto-molecules-sub-header-height);width:100%}.neeto-molecules-subheader .neeto-molecules-subheader__left-wrapper{display:flex;flex-grow:1}.neeto-molecules-subheader .neeto-molecules-subheader__left-wrapper .neeto-molecules-subheader__left{align-items:center;display:flex;flex-direction:row;justify-content:flex-start}.neeto-molecules-subheader .neeto-molecules-subheader__left-wrapper .neeto-molecules-subheader__left .neeto-molecules-input__prefix{color:rgb(var(--neeto-ui-gray-400))}.neeto-molecules-subheader .neeto-molecules-subheader__right{align-items:center;display:flex;flex-direction:row;gap:12px;justify-content:flex-end}.neeto-molecules-subheader .neeto-molecules-subheader__right-actions{align-items:center;display:flex;flex-direction:row;gap:8px;justify-content:flex-end}.neeto-molecules-subheader .neeto-molecules-subheader__right-actions>:not([hidden])~:not([hidden]){border-left:thin solid rgb(var(--neeto-ui-gray-300));padding-left:8px}.neeto-molecules-subheader__download{position:relative}.neeto-molecules-subheader__download-count{align-items:center;background-color:rgb(var(--neeto-ui-primary-500));border-radius:var(--neeto-ui-rounded-full);color:rgb(var(--neeto-ui-white));display:inline-flex;font-size:10px;justify-content:center;min-height:16px;min-width:16px;position:absolute;right:-2px;text-align:center;top:-2px;z-index:1}";
1591
1591
  n(css$1,{});
1592
1592
 
1593
1593
  var SubHeader = function SubHeader(_ref) {
@@ -1633,7 +1633,7 @@ var DeleteAlert = function DeleteAlert(_ref) {
1633
1633
  });
1634
1634
  };
1635
1635
 
1636
- var css = ".neeto-molecules-header{align-items:flex-start!important;background:rgb(var(--neeto-ui-white));display:flex;flex-direction:row;justify-content:space-between;min-height:auto!important;padding:40px 0 24px!important;width:100%}.neeto-molecules-header .neeto-molecules-header__toggle-menubar-btn{margin-right:8px}.neeto-molecules-header .neeto-molecules-header__left{align-items:flex-start!important;display:flex;flex-direction:row;flex-wrap:wrap;justify-content:flex-start}.neeto-molecules-header .neeto-molecules-header__left-data-wrap{display:flex;flex-wrap:wrap}.neeto-molecules-header .neeto-molecules-header__page-title{align-items:center;display:flex;flex-direction:row;gap:12px;margin-top:-16px;width:100%}.neeto-molecules-header .neeto-molecules-header__page-title h2{font-size:40px;line-height:48px}.neeto-molecules-header .neeto-molecules-header__page-title--has-breadcrumbs{margin-top:0}.neeto-molecules-header .neeto-molecules-header__breadcrumbs-wrap{display:flex;margin:0 0 40px}.neeto-molecules-header .neeto-molecules-header__breadcrumb{align-items:center;display:flex;flex-direction:row;justify-content:flex-start;line-height:1}.neeto-molecules-header .neeto-molecules-header__breadcrumb a{text-decoration:none;transition:all .3s ease-in-out}.neeto-molecules-header .neeto-molecules-header__breadcrumb a:focus-visible{border-radius:var(--neeto-ui-rounded-sm);outline:3px solid rgba(var(--neeto-ui-primary-500),50%)}.neeto-molecules-header .neeto-molecules-header__breadcrumb-separator{font-size:12px;line-height:16px;margin:0 12px!important}.neeto-molecules-header .neeto-molecules-header__right{align-items:center;display:flex;flex-direction:row;justify-content:flex-end}";
1636
+ var css = ":root{--neeto-molecules-main-header-height:96px;--neeto-molecules-main-header-with-breadcrumbs-height:168px}.neeto-molecules-header{align-items:flex-start!important;background:rgb(var(--neeto-ui-white));display:flex;flex-direction:row;justify-content:space-between;min-height:96px;min-height:var(--neeto-molecules-main-header-height);padding:40px 0 24px!important;width:100%}.neeto-molecules-header .neeto-molecules-header__toggle-menubar-btn{margin-right:8px}.neeto-molecules-header .neeto-molecules-header__left{align-items:flex-start!important;display:flex;flex-direction:row;flex-wrap:wrap;justify-content:flex-start}.neeto-molecules-header .neeto-molecules-header__left-data-wrap{display:flex;flex-wrap:wrap}.neeto-molecules-header .neeto-molecules-header__page-title{align-items:center;display:flex;flex-direction:row;gap:12px;margin-top:-16px;width:100%}.neeto-molecules-header .neeto-molecules-header__page-title h2{font-size:40px;line-height:48px}.neeto-molecules-header .neeto-molecules-header__breadcrumbs-wrap{display:flex;margin:0 0 40px}.neeto-molecules-header .neeto-molecules-header__breadcrumb{align-items:center;display:flex;flex-direction:row;justify-content:flex-start;line-height:1}.neeto-molecules-header .neeto-molecules-header__breadcrumb a{text-decoration:none;transition:all .3s ease-in-out}.neeto-molecules-header .neeto-molecules-header__breadcrumb a:focus-visible{border-radius:var(--neeto-ui-rounded-sm);outline:3px solid rgba(var(--neeto-ui-primary-500),50%)}.neeto-molecules-header .neeto-molecules-header__breadcrumb-separator{font-size:12px;line-height:16px;margin:0 12px!important}.neeto-molecules-header .neeto-molecules-header__right{align-items:center;display:flex;flex-direction:row;justify-content:flex-end}.neeto-molecules-header--has-breadcrumbs{min-height:168px;min-height:var(--neeto-molecules-main-header-with-breadcrumbs-height)}.neeto-molecules-header--has-breadcrumbs .neeto-molecules-header__page-title{margin-top:0}";
1637
1637
  n(css,{});
1638
1638
 
1639
1639
  var Breadcrumbs = function Breadcrumbs(_ref) {
@@ -1642,7 +1642,8 @@ var Breadcrumbs = function Breadcrumbs(_ref) {
1642
1642
  className: "neeto-molecules-header__breadcrumbs-wrap"
1643
1643
  }, breadcrumbs.map(function (_ref2, index) {
1644
1644
  var text = _ref2.text,
1645
- link = _ref2.link;
1645
+ _ref2$link = _ref2.link,
1646
+ link = _ref2$link === void 0 ? "#" : _ref2$link;
1646
1647
  return /*#__PURE__*/React__default.createElement("div", {
1647
1648
  className: "neeto-molecules-header__breadcrumb",
1648
1649
  key: index
@@ -1684,7 +1685,9 @@ var Header$2 = function Header(_ref) {
1684
1685
  var _useTranslation = useTranslation(),
1685
1686
  t = _useTranslation.t;
1686
1687
  return /*#__PURE__*/React__default.createElement("div", {
1687
- className: classnames(["neeto-molecules-header", className])
1688
+ className: classnames(["neeto-molecules-header", {
1689
+ "neeto-molecules-header--has-breadcrumbs": isNotEmpty(breadcrumbs)
1690
+ }, className])
1688
1691
  }, /*#__PURE__*/React__default.createElement("div", {
1689
1692
  className: "neeto-molecules-header__left"
1690
1693
  }, /*#__PURE__*/React__default.createElement("div", {
@@ -1692,9 +1695,7 @@ var Header$2 = function Header(_ref) {
1692
1695
  }, isNotEmpty(breadcrumbs) && /*#__PURE__*/React__default.createElement(Breadcrumbs$1, {
1693
1696
  breadcrumbs: breadcrumbs
1694
1697
  }), /*#__PURE__*/React__default.createElement("div", {
1695
- className: classnames("neeto-molecules-header__page-title", {
1696
- "neeto-molecules-header__page-title--has-breadcrumbs": isNotEmpty(breadcrumbs)
1697
- })
1698
+ className: "neeto-molecules-header__page-title"
1698
1699
  }, /*#__PURE__*/React__default.createElement(Typography, {
1699
1700
  "data-cy": "main-header",
1700
1701
  "data-test-id": "main-header",
@@ -1754,10 +1755,8 @@ var INITIAL_VALUES = {
1754
1755
 
1755
1756
  var TagBlock = function TagBlock(_ref) {
1756
1757
  var status = _ref.status,
1757
- isCnameRecordsAdded = _ref.isCnameRecordsAdded,
1758
1758
  _ref$stacked = _ref.stacked,
1759
- stacked = _ref$stacked === void 0 ? false : _ref$stacked,
1760
- handleValidateCname = _ref.handleValidateCname;
1759
+ stacked = _ref$stacked === void 0 ? false : _ref$stacked;
1761
1760
  var _useTranslation = useTranslation(),
1762
1761
  t = _useTranslation.t;
1763
1762
  var isDomainValidated = status === "active" || status === "pending_cname_validation";
@@ -1782,11 +1781,6 @@ var TagBlock = function TagBlock(_ref) {
1782
1781
  indicatorStyle: status === "active" ? "success" : "warning",
1783
1782
  style: "secondary",
1784
1783
  label: t("neetoMolecules.customDomain.status.cname.".concat(camelCasedStatus))
1785
- }), isCnameRecordsAdded && status === "pending_cname_validation" && /*#__PURE__*/React__default.createElement(Button, {
1786
- className: "text-xs",
1787
- style: "link",
1788
- label: t("neetoMolecules.customDomain.validation.buttonLabel.cnameCheck"),
1789
- onClick: handleValidateCname
1790
1784
  }))));
1791
1785
  };
1792
1786
  var TagBlock$1 = /*#__PURE__*/React__default.memo(TagBlock);
@@ -1845,8 +1839,11 @@ var recordData = function recordData(customDomain) {
1845
1839
  var recordName = isDomainValidated ? hostname : cnameValidationParams === null || cnameValidationParams === void 0 ? void 0 : cnameValidationParams.name;
1846
1840
  var recordValue = isDomainValidated ? dnsTarget : cnameValidationParams === null || cnameValidationParams === void 0 ? void 0 : cnameValidationParams.value;
1847
1841
  var recordType = isDomainValidated ? t$1("neetoMolecules.customDomain.cname") : t$1("neetoMolecules.customDomain.domainValidationCname");
1848
- var recordDescription = t$1("neetoMolecules.customDomain.validation.desc", {
1842
+ var recordDescription = isDomainValidated ? t$1("neetoMolecules.customDomain.validation.desc", {
1849
1843
  record: recordType
1844
+ }) : t$1("neetoMolecules.customDomain.validation.desc", {
1845
+ record: recordType,
1846
+ proxyMessage: t$1("neetoMolecules.customDomain.validation.proxyMessage")
1850
1847
  });
1851
1848
  var recordNameLabel = t$1("neetoMolecules.customDomain.validation.record", {
1852
1849
  record: recordType,
@@ -1906,28 +1903,25 @@ var Record = function Record(_ref) {
1906
1903
  };
1907
1904
  var Record$1 = /*#__PURE__*/React__default.memo(Record);
1908
1905
 
1909
- var CustomDomainInfo = function CustomDomainInfo(_ref) {
1910
- var time = _ref.time;
1911
- var _useTranslation = useTranslation(),
1912
- t = _useTranslation.t;
1906
+ var StatusInfo = function StatusInfo() {
1907
+ var helpUrl = "https://help.".concat(globalProps.appName.toLowerCase(), ".com/articles/custom-domains");
1913
1908
  return /*#__PURE__*/React__default.createElement("div", {
1914
1909
  className: "space-y-6"
1915
1910
  }, /*#__PURE__*/React__default.createElement("div", {
1916
1911
  className: "neeto-ui-rounded neeto-ui-bg-gray-100 neeto-ui-text-gray-700 space-y-3 p-4"
1917
1912
  }, /*#__PURE__*/React__default.createElement(Trans, {
1918
- i18nKey: "neetoMolecules.customDomain.messageBlock.dnsStatus"
1919
- }), /*#__PURE__*/React__default.createElement(Button, {
1920
- href: "mailto:support@neeto.com",
1921
- label: "support@neeto.com",
1922
- style: "link"
1923
- })), /*#__PURE__*/React__default.createElement(Callout, {
1924
- icon: Info,
1925
- style: "info"
1926
- }, t("neetoMolecules.customDomain.messageBlock.cnameAddedTime", {
1927
- time: timeFormat.fromNow(time)
1913
+ i18nKey: "neetoMolecules.customDomain.messageBlock.dnsStatus",
1914
+ components: {
1915
+ a: /*#__PURE__*/React__default.createElement("a", {
1916
+ className: "neeto-ui-btn--style-link",
1917
+ href: helpUrl,
1918
+ rel: "noreferrer",
1919
+ target: "_blank"
1920
+ })
1921
+ }
1928
1922
  })));
1929
1923
  };
1930
- var StatusInfo = /*#__PURE__*/React__default.memo(CustomDomainInfo);
1924
+ var StatusInfo$1 = /*#__PURE__*/React__default.memo(StatusInfo);
1931
1925
 
1932
1926
  var getCustomDomainValidationSchema = function getCustomDomainValidationSchema() {
1933
1927
  return Yup.object().shape({
@@ -2136,14 +2130,12 @@ var Manage = function Manage(_ref) {
2136
2130
  loading: isValidating,
2137
2131
  label: t("neetoMolecules.customDomain.validation.buttonLabel.domain"),
2138
2132
  onClick: handleValidateDomain
2139
- }), customDomain.status === "pending_cname_validation" && !customDomain.addedCnameAt && /*#__PURE__*/React__default.createElement(Button, {
2133
+ }), customDomain.status === "pending_cname_validation" && /*#__PURE__*/React__default.createElement(Button, {
2140
2134
  "data-cy": "validate-cname-record-button",
2141
2135
  loading: isCnameValidating || isUpdating,
2142
2136
  label: t("neetoMolecules.customDomain.validation.buttonLabel.cnameAdded"),
2143
2137
  onClick: handleUpdateCname
2144
- }), customDomain.status === "pending_cname_validation" && customDomain.addedCnameAt && /*#__PURE__*/React__default.createElement(StatusInfo, {
2145
- time: customDomain.addedCnameAt
2146
- })))));
2138
+ }), /*#__PURE__*/React__default.createElement(StatusInfo$1, null)))));
2147
2139
  }));
2148
2140
  };
2149
2141