@7shifts/sous-chef 3.30.1 → 3.31.0
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/forms/DateRangeField/DateRangeField.d.ts +2 -2
- package/dist/index.css +13 -0
- package/dist/index.js +52 -35
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +52 -35
- package/dist/index.modern.js.map +1 -1
- package/dist/utils/date.d.ts +4 -0
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -9340,7 +9340,7 @@ var ToDate = function ToDate(_ref, ref) {
|
|
|
9340
9340
|
var ToDate$1 = forwardRef(ToDate);
|
|
9341
9341
|
|
|
9342
9342
|
var DateRangeField = function DateRangeField(_ref) {
|
|
9343
|
-
var _classnames;
|
|
9343
|
+
var _classnames, _disabledDays$start, _disabledDays$end;
|
|
9344
9344
|
var name = _ref.name,
|
|
9345
9345
|
inputId = _ref.id,
|
|
9346
9346
|
value = _ref.value,
|
|
@@ -9396,7 +9396,7 @@ var DateRangeField = function DateRangeField(_ref) {
|
|
|
9396
9396
|
weekStart: weekStart,
|
|
9397
9397
|
maxDays: maxDays,
|
|
9398
9398
|
disabled: disabled,
|
|
9399
|
-
disabledDays: disabledDays,
|
|
9399
|
+
disabledDays: typeof disabledDays === 'object' && ('start' in disabledDays || 'end' in disabledDays) ? (_disabledDays$start = disabledDays.start) != null ? _disabledDays$start : undefined : disabledDays,
|
|
9400
9400
|
readOnly: readOnly,
|
|
9401
9401
|
onChange: function onChange(val) {
|
|
9402
9402
|
return controllers.onChange({
|
|
@@ -9421,7 +9421,7 @@ var DateRangeField = function DateRangeField(_ref) {
|
|
|
9421
9421
|
weekStart: weekStart,
|
|
9422
9422
|
maxDays: maxDays,
|
|
9423
9423
|
disabled: disabled,
|
|
9424
|
-
disabledDays: disabledDays,
|
|
9424
|
+
disabledDays: typeof disabledDays === 'object' && ('start' in disabledDays || 'end' in disabledDays) ? (_disabledDays$end = disabledDays.end) != null ? _disabledDays$end : undefined : disabledDays,
|
|
9425
9425
|
readOnly: readOnly,
|
|
9426
9426
|
onBlur: controllers.onBlur,
|
|
9427
9427
|
onChange: function onChange(val) {
|
|
@@ -9823,6 +9823,8 @@ var TimeRangeField = function TimeRangeField(_ref) {
|
|
|
9823
9823
|
})));
|
|
9824
9824
|
};
|
|
9825
9825
|
|
|
9826
|
+
var styles$14 = {"currency-field__mask-display":"_2K8Ob"};
|
|
9827
|
+
|
|
9826
9828
|
var _excluded$2D = ["currencySymbol", "step"];
|
|
9827
9829
|
var CurrencyFieldElement = function CurrencyFieldElement(_ref, ref) {
|
|
9828
9830
|
var _ref$currencySymbol = _ref.currencySymbol,
|
|
@@ -9835,8 +9837,16 @@ var CurrencyFieldElement = function CurrencyFieldElement(_ref, ref) {
|
|
|
9835
9837
|
})),
|
|
9836
9838
|
inputProps = _useTextField.inputProps,
|
|
9837
9839
|
fieldProps = _useTextField.fieldProps;
|
|
9840
|
+
var hasValue = !!inputProps.value;
|
|
9841
|
+
var _useState = useState(hasValue),
|
|
9842
|
+
showMask = _useState[0],
|
|
9843
|
+
setShowMask = _useState[1];
|
|
9838
9844
|
var isWholeNumber = Number.isInteger(step);
|
|
9839
|
-
|
|
9845
|
+
var formatThousandsSparator = function formatThousandsSparator(value) {
|
|
9846
|
+
var numberValue = parseFloat(value).toFixed(isWholeNumber ? 0 : 2);
|
|
9847
|
+
return numberValue.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',');
|
|
9848
|
+
};
|
|
9849
|
+
return React__default.createElement(Field, _extends({}, fieldProps), React__default.createElement(Fragment, null, React__default.createElement(AffixContainer, {
|
|
9840
9850
|
prefix: currencySymbol
|
|
9841
9851
|
}, React__default.createElement("input", _extends({}, inputProps, {
|
|
9842
9852
|
type: "number",
|
|
@@ -9855,11 +9865,18 @@ var CurrencyFieldElement = function CurrencyFieldElement(_ref, ref) {
|
|
|
9855
9865
|
e.currentTarget.value = parseFloat(e.currentTarget.value).toFixed(isWholeNumber ? 0 : 2);
|
|
9856
9866
|
inputProps.onChange(e);
|
|
9857
9867
|
inputProps.onBlur(e);
|
|
9868
|
+
setShowMask(true);
|
|
9858
9869
|
},
|
|
9859
9870
|
onWheel: function onWheel(e) {
|
|
9860
9871
|
e.target.blur();
|
|
9872
|
+
},
|
|
9873
|
+
onFocus: function onFocus(e) {
|
|
9874
|
+
setShowMask(false);
|
|
9875
|
+
inputProps.onFocus(e);
|
|
9861
9876
|
}
|
|
9862
|
-
})))
|
|
9877
|
+
}))), showMask && !!inputProps.value && React__default.createElement("div", {
|
|
9878
|
+
className: styles$14['currency-field__mask-display']
|
|
9879
|
+
}, formatThousandsSparator(inputProps.value.toString() || ''))));
|
|
9863
9880
|
};
|
|
9864
9881
|
var CurrencyField = forwardRef(CurrencyFieldElement);
|
|
9865
9882
|
|
|
@@ -9951,7 +9968,7 @@ var FormFeedback = function FormFeedback(_ref) {
|
|
|
9951
9968
|
}, children);
|
|
9952
9969
|
};
|
|
9953
9970
|
|
|
9954
|
-
var styles$
|
|
9971
|
+
var styles$15 = {"phone-field":"_1uJbR","phone-field__input--with-square-borders":"_1zowl","phone-field__flag":"_Fc99X"};
|
|
9955
9972
|
|
|
9956
9973
|
var usePhoneFieldControllers = function usePhoneFieldControllers(_ref) {
|
|
9957
9974
|
var name = _ref.name,
|
|
@@ -10812,7 +10829,7 @@ var COUNTRIES = {
|
|
|
10812
10829
|
};
|
|
10813
10830
|
var COUNTRY_CODES = Object.keys(COUNTRIES);
|
|
10814
10831
|
|
|
10815
|
-
var styles$
|
|
10832
|
+
var styles$16 = {"country-selector":"_2T1pu","country-selector--with-error":"_1OxwW","country-selector__trigger":"_3mUO5","country-selector--disabled":"_10MbE","country-selector__trigger--with-error":"_5Dh7e","country-selector__trigger--disabled":"_2myDP","country-selector__trigger-flag":"_IHf11","country-selector__flag":"_1KMRs"};
|
|
10816
10833
|
|
|
10817
10834
|
var flagIcons = {"fi":"_M2doN","fis":"_3vbi0","fi-ac":"_30baC","fi-ad":"_3ZYxj","fi-ae":"_2LJGN","fi-af":"_lqly3","fi-ag":"_B1gnt","fi-ai":"_1NIqt","fi-al":"_20Sg9","fi-am":"_JXRFR","fi-ao":"_3dUc_","fi-ar":"_2zSuY","fi-as":"_31Bje","fi-at":"_1_3ab","fi-au":"_3ifhl","fi-aw":"_3H9aN","fi-ax":"_3A_KZ","fi-az":"_2ObKm","fi-ba":"_3v41n","fi-bb":"_1fjfa","fi-bd":"_24NEp","fi-be":"_3AF8j","fi-bf":"_2jlZh","fi-bg":"_2ACy1","fi-bh":"_298rj","fi-bi":"_AP8aY","fi-bj":"_1SvG2","fi-bl":"_10exo","fi-bm":"_dPwTT","fi-bn":"_1e3FY","fi-bo":"_1P6lb","fi-bq":"_3yLu_","fi-br":"_2reHT","fi-bs":"_34VqI","fi-bt":"_3L-ek","fi-bw":"_2P46Z","fi-by":"_3k3ji","fi-bz":"_Wm-7Z","fi-ca":"_3mCU8","fi-cc":"_1TnnA","fi-cd":"_1n3mG","fi-cf":"_mRVOk","fi-cg":"_3yqWy","fi-ch":"_S-QqO","fi-ci":"_3yq28","fi-ck":"_1MnXX","fi-cl":"_2BAiD","fi-cm":"_17muc","fi-cn":"_zHGeX","fi-co":"_2xeW0","fi-cr":"_2PCnB","fi-cu":"_BFNAl","fi-cv":"_G2jRt","fi-cw":"_1grh-","fi-cx":"_1QOKC","fi-cy":"_3ld7b","fi-cz":"_bN_Fv","fi-de":"_280yy","fi-dj":"_3cZp9","fi-dk":"_23TZO","fi-dm":"_1sbTf","fi-do":"_1M5wH","fi-dz":"_2cicq","fi-ec":"_3caqA","fi-ee":"_3ZCIU","fi-eg":"_23ytE","fi-eh":"_pmU44","fi-er":"_1B8BU","fi-es":"_2jhKE","fi-et":"_sk0P2","fi-fi":"_1SEmk","fi-fj":"_sSQMg","fi-fk":"_27XSg","fi-fm":"_ClziM","fi-fo":"_uI-xC","fi-fr":"_M2iAw","fi-ga":"_2dwxx","fi-gb":"_1e-nA","fi-gd":"_2RZeE","fi-ge":"_2EvCn","fi-gf":"_3IH4K","fi-gg":"_1Jcke","fi-gh":"_2EPke","fi-gi":"_12Nbn","fi-gl":"_3__lH","fi-gm":"_2V2JG","fi-gn":"_1snaM","fi-gp":"_3Ra5n","fi-gq":"_3sbjK","fi-gr":"_-xgIE","fi-gt":"_1IL-n","fi-gu":"_X2BnD","fi-gw":"_183f_","fi-gy":"_3euCo","fi-hk":"_3vkSA","fi-hn":"_2wum3","fi-hr":"_394Be","fi-ht":"_2SZVb","fi-hu":"_1LPfs","fi-id":"_XxFIw","fi-ie":"_38xYb","fi-il":"_xsU9l","fi-im":"_1hyCQ","fi-in":"_1WZwW","fi-io":"_2OqV4","fi-iq":"_wS2T_","fi-ir":"_2gomh","fi-is":"_1DFTj","fi-it":"_2xqL9","fi-je":"_1YQZ8","fi-jm":"_2e2gd","fi-jo":"_3SD_b","fi-jp":"_2iU8m","fi-ke":"_2HTh-","fi-kg":"_P_BgY","fi-kh":"_3cL-5","fi-ki":"_UVsN_","fi-km":"_5_aHV","fi-kn":"_1ytYB","fi-kp":"_3h4nD","fi-kr":"_5Ayl_","fi-kw":"_11J0K","fi-ky":"_3JNZj","fi-kz":"_odoDB","fi-la":"_1NsIw","fi-lb":"_3sNSR","fi-lc":"_qIIiy","fi-li":"_2EYin","fi-lk":"_YC0sS","fi-lr":"_3M5Be","fi-ls":"_3mNd-","fi-lt":"_3Lod8","fi-lu":"_PADgP","fi-lv":"_1edmr","fi-ly":"_2Qaxl","fi-ma":"_3woQF","fi-mc":"_3Tcvg","fi-md":"_304sg","fi-me":"_3Y4qN","fi-mf":"_2Ta4d","fi-mg":"_3cyLg","fi-mh":"_3oa6y","fi-mk":"_2JG9M","fi-ml":"_E244m","fi-mm":"_3vntQ","fi-mn":"_1NFiz","fi-mo":"_17P3Y","fi-mp":"_2TsiM","fi-mq":"_1y2tW","fi-mr":"_hmY4g","fi-ms":"_2Rj7s","fi-mt":"_1nmC4","fi-mu":"_xO9Yk","fi-mv":"_13arY","fi-mw":"_2NJbp","fi-mx":"_3jDAz","fi-my":"_1R-kq","fi-mz":"_2JrIx","fi-na":"_2bezu","fi-nc":"_RXHw0","fi-ne":"_17FYh","fi-nf":"_2f17Z","fi-ng":"_pkj4b","fi-ni":"_2M9Kl","fi-nl":"_XP4Cy","fi-no":"_vWBdS","fi-np":"_3HCj0","fi-nr":"_35I9J","fi-nu":"_1qVGc","fi-nz":"_3sy04","fi-om":"_1ru-J","fi-pa":"_gVRbx","fi-pe":"_rPJml","fi-pf":"_b_9in","fi-pg":"_3svVP","fi-ph":"_qf4jP","fi-pk":"_ETc1B","fi-pl":"_2iKV_","fi-pm":"_3rKup","fi-pr":"_18qkQ","fi-ps":"_2QUjB","fi-pt":"_3XlFj","fi-pw":"_2-I7x","fi-py":"_2VRS9","fi-qa":"_XL4IN","fi-re":"_1Heg1","fi-ro":"_9Ds_F","fi-rs":"_2NBRF","fi-ru":"_27vE7","fi-rw":"_15XW2","fi-sa":"_2FNqc","fi-sb":"_nZ0tS","fi-sc":"_2c7r2","fi-sd":"_31SMO","fi-se":"_2g80W","fi-sg":"_1fXM6","fi-sh":"_3jXVn","fi-si":"_1dCS9","fi-sj":"_Fw6EH","fi-sk":"_3ZIrQ","fi-sl":"_2CXXP","fi-sm":"_9Z6OF","fi-sn":"_27QPB","fi-so":"_3u0ej","fi-sr":"_aWap6","fi-ss":"_jgut9","fi-st":"_1ZG6d","fi-sv":"_1LyCh","fi-sx":"_29HpR","fi-sy":"_36XMC","fi-sz":"_uhQEf","fi-ta":"_1VKa_","fi-tc":"_1zZqn","fi-td":"_zPDQp","fi-tg":"_1uL0e","fi-th":"_2hgJx","fi-tj":"_3wIE0","fi-tk":"_2duh0","fi-tl":"_2KUDp","fi-tm":"_2CfPc","fi-tn":"_2P42O","fi-to":"_2WFbJ","fi-tr":"_3Az7i","fi-tt":"_1pNPS","fi-tv":"_1pgP-","fi-tw":"_2ctah","fi-tz":"_3LhmF","fi-ua":"_ySobg","fi-ug":"_L0cww","fi-us":"_1dJbI","fi-uy":"_1mu4a","fi-uz":"_2jO3C","fi-va":"_3Wjh-","fi-vc":"_2SLDw","fi-ve":"_33s_c","fi-vg":"_14DB7","fi-vi":"_yup8e","fi-vn":"_2mLwZ","fi-vu":"_32cC-","fi-wf":"_2a5ap","fi-ws":"_3wY8H","fi-xk":"_3X7px","fi-ye":"_16y86","fi-yt":"_4eJM-","fi-za":"_3c6fy","fi-zm":"_21Ocp","fi-zw":"_2GLu6"};
|
|
10818
10835
|
|
|
@@ -10823,15 +10840,15 @@ var CountrySelector = function CountrySelector(_ref) {
|
|
|
10823
10840
|
hasError = _ref.hasError,
|
|
10824
10841
|
disabled = _ref.disabled;
|
|
10825
10842
|
return React__default.createElement("div", {
|
|
10826
|
-
className: classnames(styles$
|
|
10843
|
+
className: classnames(styles$16['country-selector'], (_classNames = {}, _classNames[styles$16['country-selector--with-error']] = hasError, _classNames[styles$16['country-selector--disabled']] = disabled, _classNames))
|
|
10827
10844
|
}, React__default.createElement(Dropdown, {
|
|
10828
10845
|
trigger: React__default.createElement("div", {
|
|
10829
|
-
className: classnames(styles$
|
|
10846
|
+
className: classnames(styles$16['country-selector__trigger'], (_classNames2 = {}, _classNames2[styles$16['country-selector__trigger--with-error']] = hasError, _classNames2[styles$16['country-selector__trigger--disabled']] = disabled, _classNames2))
|
|
10830
10847
|
}, React__default.createElement(Inline, {
|
|
10831
10848
|
space: 8,
|
|
10832
10849
|
alignItems: "center"
|
|
10833
10850
|
}, React__default.createElement("span", {
|
|
10834
|
-
className: classnames(flagIcons['fi'], flagIcons["fi-" + country.toLocaleLowerCase()], styles$
|
|
10851
|
+
className: classnames(flagIcons['fi'], flagIcons["fi-" + country.toLocaleLowerCase()], styles$16['country-selector__trigger-flag'])
|
|
10835
10852
|
}), React__default.createElement(IconChevronDown, {
|
|
10836
10853
|
color: "grey-400",
|
|
10837
10854
|
size: "medium"
|
|
@@ -10848,7 +10865,7 @@ var CountrySelector = function CountrySelector(_ref) {
|
|
|
10848
10865
|
alignItems: "center",
|
|
10849
10866
|
space: 12
|
|
10850
10867
|
}, React__default.createElement("span", {
|
|
10851
|
-
className: classnames(flagIcons['fi'], flagIcons["fi-" + countryCode.toLocaleLowerCase()], styles$
|
|
10868
|
+
className: classnames(flagIcons['fi'], flagIcons["fi-" + countryCode.toLocaleLowerCase()], styles$16['country-selector__flag'])
|
|
10852
10869
|
}), React__default.createElement(Text, null, COUNTRIES[countryCode].countryName)));
|
|
10853
10870
|
}))));
|
|
10854
10871
|
};
|
|
@@ -10920,7 +10937,7 @@ var PhoneField = function PhoneField(_ref) {
|
|
|
10920
10937
|
}
|
|
10921
10938
|
}, [fieldValue === null || fieldValue === void 0 ? void 0 : fieldValue.internationalPhone]);
|
|
10922
10939
|
return React__default.createElement(Field, _extends({}, fieldProps), React__default.createElement("div", {
|
|
10923
|
-
className: styles$
|
|
10940
|
+
className: styles$15['phone-field']
|
|
10924
10941
|
}, !disabledCountry && React__default.createElement(CountrySelector, {
|
|
10925
10942
|
country: selectedCountry,
|
|
10926
10943
|
onChange: handleCountryChange,
|
|
@@ -10931,17 +10948,17 @@ var PhoneField = function PhoneField(_ref) {
|
|
|
10931
10948
|
space: 4,
|
|
10932
10949
|
alignItems: "center"
|
|
10933
10950
|
}, React__default.createElement("span", {
|
|
10934
|
-
className: classnames(flagIcons['fi'], flagIcons["fi-" + selectedCountry.toLocaleLowerCase()], styles$
|
|
10951
|
+
className: classnames(flagIcons['fi'], flagIcons["fi-" + selectedCountry.toLocaleLowerCase()], styles$15['country-selector__flag'])
|
|
10935
10952
|
}), React__default.createElement("span", null, "+", getCountryCallingCode(selectedCountry))) : "+" + getCountryCallingCode(selectedCountry)
|
|
10936
10953
|
}, React__default.createElement("input", _extends({}, inputProps, {
|
|
10937
10954
|
type: "tel",
|
|
10938
|
-
className: classnames(inputProps.className, (_classNames = {}, _classNames[styles$
|
|
10955
|
+
className: classnames(inputProps.className, (_classNames = {}, _classNames[styles$15['phone-field__input--with-square-borders']] = !disabledCountry, _classNames)),
|
|
10939
10956
|
onChange: handlePhoneChange,
|
|
10940
10957
|
onBlur: handlePhoneBlur
|
|
10941
10958
|
})))));
|
|
10942
10959
|
};
|
|
10943
10960
|
|
|
10944
|
-
var styles$
|
|
10961
|
+
var styles$17 = {"badge":"_1QLaK","badge--warning":"_qsFWw","badge--danger":"_359Cc","badge--success":"_2AOEK","badge--info":"_1mLjf"};
|
|
10945
10962
|
|
|
10946
10963
|
var _excluded$2G = ["children", "theme", "title", "testId"];
|
|
10947
10964
|
var Badge = function Badge(_ref, forwardedRef) {
|
|
@@ -10962,16 +10979,16 @@ var Badge = function Badge(_ref, forwardedRef) {
|
|
|
10962
10979
|
overlay: title,
|
|
10963
10980
|
ref: ref
|
|
10964
10981
|
}, React__default.createElement("div", _extends({
|
|
10965
|
-
className: classnames(styles$
|
|
10982
|
+
className: classnames(styles$17['badge'], (_classnames = {}, _classnames[styles$17['badge--success']] = theme === 'success', _classnames[styles$17['badge--danger']] = theme === 'danger', _classnames[styles$17['badge--info']] = theme === 'info', _classnames[styles$17['badge--warning']] = theme === 'warning', _classnames)),
|
|
10966
10983
|
ref: ref,
|
|
10967
10984
|
"data-testid": testId
|
|
10968
10985
|
}, otherProps), children));
|
|
10969
10986
|
};
|
|
10970
10987
|
var Badge$1 = forwardRef(Badge);
|
|
10971
10988
|
|
|
10972
|
-
var styles$
|
|
10989
|
+
var styles$18 = {"avatar":"_1X7La","avatar--small":"_o5x6S","avatar__badge":"_NN8-D","avatar--medium":"_VxW5y","avatar--large":"_ec7jQ","avatar--extra-large":"_3VS00"};
|
|
10973
10990
|
|
|
10974
|
-
var styles$
|
|
10991
|
+
var styles$19 = {"avatar-image":"_bbI2F"};
|
|
10975
10992
|
|
|
10976
10993
|
var AvatarImage = function AvatarImage(_ref) {
|
|
10977
10994
|
var url = _ref.url,
|
|
@@ -10993,7 +11010,7 @@ var AvatarImage = function AvatarImage(_ref) {
|
|
|
10993
11010
|
});
|
|
10994
11011
|
}
|
|
10995
11012
|
return React__default.createElement("div", {
|
|
10996
|
-
className: styles$
|
|
11013
|
+
className: styles$19['avatar-image']
|
|
10997
11014
|
}, React__default.createElement(IconUserSolid, {
|
|
10998
11015
|
size: "flexible",
|
|
10999
11016
|
color: color
|
|
@@ -11058,7 +11075,7 @@ var Avatar = function Avatar(_ref) {
|
|
|
11058
11075
|
defaultProfilePictureColors = _useState2[0];
|
|
11059
11076
|
var backgroundColor = url ? COLORS['grey-200'] : getColor(color);
|
|
11060
11077
|
return React__default.createElement("div", {
|
|
11061
|
-
className: classnames(styles$
|
|
11078
|
+
className: classnames(styles$18['avatar'], (_classnames = {}, _classnames[styles$18['avatar--small']] = size === 'small', _classnames[styles$18['avatar--medium']] = size === 'medium', _classnames[styles$18['avatar--large']] = size === 'large', _classnames[styles$18['avatar--extra-large']] = size === 'extra-large', _classnames)),
|
|
11062
11079
|
style: {
|
|
11063
11080
|
backgroundColor: children || url && !showIconInsteadOfImage ? backgroundColor : defaultProfilePictureColors.backgroundColor
|
|
11064
11081
|
},
|
|
@@ -11071,7 +11088,7 @@ var Avatar = function Avatar(_ref) {
|
|
|
11071
11088
|
return setShowIconInsteadOfImage(true);
|
|
11072
11089
|
}
|
|
11073
11090
|
}), badge && size !== 'small' && React__default.createElement("div", {
|
|
11074
|
-
className: styles$
|
|
11091
|
+
className: styles$18['avatar__badge']
|
|
11075
11092
|
}, badge));
|
|
11076
11093
|
};
|
|
11077
11094
|
|
|
@@ -11084,7 +11101,7 @@ var CHIP_THEME = {
|
|
|
11084
11101
|
DANGER: 'danger'
|
|
11085
11102
|
};
|
|
11086
11103
|
|
|
11087
|
-
var styles$
|
|
11104
|
+
var styles$1a = {"chip":"_3e7Of","chip--marketing":"_2ZlMr","chip--success":"_g3pvh","chip--upsell":"_3GeNC","chip--warning":"_2jbr_","chip--info":"_1rrIw","chip--danger":"_1fKe8"};
|
|
11088
11105
|
|
|
11089
11106
|
var Chip = function Chip(_ref) {
|
|
11090
11107
|
var _classnames;
|
|
@@ -11094,11 +11111,11 @@ var Chip = function Chip(_ref) {
|
|
|
11094
11111
|
testId = _ref.testId;
|
|
11095
11112
|
return React__default.createElement("div", {
|
|
11096
11113
|
"data-testid": testId,
|
|
11097
|
-
className: classnames(styles$
|
|
11114
|
+
className: classnames(styles$1a['chip'], (_classnames = {}, _classnames[styles$1a['chip--marketing']] = theme === CHIP_THEME.MARKETING, _classnames[styles$1a['chip--success']] = theme === CHIP_THEME.SUCCESS, _classnames[styles$1a['chip--upsell']] = theme === CHIP_THEME.UPSELL, _classnames[styles$1a['chip--warning']] = theme === CHIP_THEME.WARNING, _classnames[styles$1a['chip--info']] = theme === CHIP_THEME.INFO, _classnames[styles$1a['chip--danger']] = theme === CHIP_THEME.DANGER, _classnames))
|
|
11098
11115
|
}, children);
|
|
11099
11116
|
};
|
|
11100
11117
|
|
|
11101
|
-
var styles$
|
|
11118
|
+
var styles$1b = {"pill":"_1vA9B","pill--default":"_2mTVo","pill--success":"_3CYqE","pill--danger":"_1WFdK","pill--warning":"_1Mp_n","pill--info":"_10zFn"};
|
|
11102
11119
|
|
|
11103
11120
|
var PILL_THEME = {
|
|
11104
11121
|
INFO: 'info',
|
|
@@ -11116,7 +11133,7 @@ var Pill = function Pill(_ref) {
|
|
|
11116
11133
|
testId = _ref.testId;
|
|
11117
11134
|
return React__default.createElement("div", {
|
|
11118
11135
|
"data-testid": testId,
|
|
11119
|
-
className: classnames(styles$
|
|
11136
|
+
className: classnames(styles$1b['pill'], (_classnames = {}, _classnames[styles$1b['pill--default']] = theme === PILL_THEME.DEFAULT, _classnames[styles$1b['pill--warning']] = theme === PILL_THEME.WARNING, _classnames[styles$1b['pill--success']] = theme === PILL_THEME.SUCCESS, _classnames[styles$1b['pill--danger']] = theme === PILL_THEME.DANGER, _classnames[styles$1b['pill--info']] = theme === PILL_THEME.INFO, _classnames))
|
|
11120
11137
|
}, children);
|
|
11121
11138
|
};
|
|
11122
11139
|
|
|
@@ -11126,9 +11143,9 @@ var EMPTY_STATE_SIZE = {
|
|
|
11126
11143
|
LARGE: 'large'
|
|
11127
11144
|
};
|
|
11128
11145
|
|
|
11129
|
-
var styles$
|
|
11146
|
+
var styles$1c = {"empty-state-container-stack":"_11ygA","empty-state-container-stack__content":"_6o4Ut","empty-state-container-stack__content--full-page":"_1bs2I","empty-state-container-stack__content--inline-horizontal":"_WwD-g","empty-state-container-stack__body":"_1b3C0"};
|
|
11130
11147
|
|
|
11131
|
-
var styles$
|
|
11148
|
+
var styles$1d = {"empty-state-container-cta":"_3q5OJ","empty-state-container-cta--inside-modal":"_3DOZC"};
|
|
11132
11149
|
|
|
11133
11150
|
var EmptyStateContainerCTA = function EmptyStateContainerCTA(_ref) {
|
|
11134
11151
|
var _actions$primary, _actions$secondary, _classNames;
|
|
@@ -11145,7 +11162,7 @@ var EmptyStateContainerCTA = function EmptyStateContainerCTA(_ref) {
|
|
|
11145
11162
|
size: BUTTON_SIZES.MIN_WIDTH_100
|
|
11146
11163
|
});
|
|
11147
11164
|
return React__default.createElement("div", {
|
|
11148
|
-
className: classnames(styles$
|
|
11165
|
+
className: classnames(styles$1d['empty-state-container-cta'], (_classNames = {}, _classNames[styles$1d['empty-state-container-cta--inside-modal']] = isInsideModal, _classNames))
|
|
11149
11166
|
}, primaryButton, secondaryButton);
|
|
11150
11167
|
};
|
|
11151
11168
|
|
|
@@ -11160,7 +11177,7 @@ var EmptyStateContainerStack = function EmptyStateContainerStack(_ref) {
|
|
|
11160
11177
|
isPaywall = _ref$isPaywall === void 0 ? false : _ref$isPaywall,
|
|
11161
11178
|
testId = _ref.testId;
|
|
11162
11179
|
return React__default.createElement("div", {
|
|
11163
|
-
className: styles$
|
|
11180
|
+
className: styles$1c['empty-state-container-stack'],
|
|
11164
11181
|
"data-testid": testId
|
|
11165
11182
|
}, React__default.createElement("img", {
|
|
11166
11183
|
src: mediaUrl,
|
|
@@ -11176,7 +11193,7 @@ var EmptyStateContainerStack = function EmptyStateContainerStack(_ref) {
|
|
|
11176
11193
|
emphasis: "bold",
|
|
11177
11194
|
as: "body"
|
|
11178
11195
|
}, title), React__default.createElement("div", {
|
|
11179
|
-
className: styles$
|
|
11196
|
+
className: styles$1c['empty-state-container-stack__body']
|
|
11180
11197
|
}, children)), React__default.createElement(Stack, {
|
|
11181
11198
|
space: 8,
|
|
11182
11199
|
alignItems: "center"
|
|
@@ -11188,7 +11205,7 @@ var EmptyStateContainerStack = function EmptyStateContainerStack(_ref) {
|
|
|
11188
11205
|
}, caption)));
|
|
11189
11206
|
};
|
|
11190
11207
|
|
|
11191
|
-
var styles$
|
|
11208
|
+
var styles$1e = {"empty-state-container-inline":"_1AdW7","empty-state-container-inline--inside-modal":"_Y1L-A","empty-state-container-inline__content":"_1E308","empty-state-container-inline__content--full-page":"_P5jRb","empty-state-container-inline__content--inline-horizontal":"_vkAs2","empty-state-container-inline__body":"_1o2PF","empty-state-container-inline__image":"_mfMlg"};
|
|
11192
11209
|
|
|
11193
11210
|
var EmptyStateContainerInline = function EmptyStateContainerInline(_ref) {
|
|
11194
11211
|
var _classNames, _classnames;
|
|
@@ -11206,10 +11223,10 @@ var EmptyStateContainerInline = function EmptyStateContainerInline(_ref) {
|
|
|
11206
11223
|
var _useModalContext = useModalContext(),
|
|
11207
11224
|
isInsideModal = _useModalContext.isModalMounted;
|
|
11208
11225
|
return React__default.createElement("div", {
|
|
11209
|
-
className: classnames(styles$
|
|
11226
|
+
className: classnames(styles$1e['empty-state-container-inline'], (_classNames = {}, _classNames[styles$1e['empty-state-container-inline--inside-modal']] = isInsideModal, _classNames)),
|
|
11210
11227
|
"data-testid": testId
|
|
11211
11228
|
}, React__default.createElement("div", {
|
|
11212
|
-
className: classnames(styles$
|
|
11229
|
+
className: classnames(styles$1e['empty-state-container-inline__content'], (_classnames = {}, _classnames[styles$1e['empty-state-container__content--full-page']] = size === EMPTY_STATE_SIZE.LARGE, _classnames[styles$1e['empty-state-container__content--inline-horizontal']] = size === EMPTY_STATE_SIZE.MEDIUM, _classnames))
|
|
11213
11230
|
}, React__default.createElement(Stack, {
|
|
11214
11231
|
space: 8
|
|
11215
11232
|
}, header && React__default.createElement(Text, {
|
|
@@ -11218,7 +11235,7 @@ var EmptyStateContainerInline = function EmptyStateContainerInline(_ref) {
|
|
|
11218
11235
|
}, header), React__default.createElement(Text, {
|
|
11219
11236
|
as: "h1"
|
|
11220
11237
|
}, title)), React__default.createElement("div", {
|
|
11221
|
-
className: styles$
|
|
11238
|
+
className: styles$1e['empty-state-container-inline__body']
|
|
11222
11239
|
}, children), React__default.createElement(Stack, {
|
|
11223
11240
|
space: 8,
|
|
11224
11241
|
marginTop: 12
|
|
@@ -11229,7 +11246,7 @@ var EmptyStateContainerInline = function EmptyStateContainerInline(_ref) {
|
|
|
11229
11246
|
}), caption && React__default.createElement(Text, {
|
|
11230
11247
|
as: "caption"
|
|
11231
11248
|
}, caption))), React__default.createElement("div", {
|
|
11232
|
-
className: styles$
|
|
11249
|
+
className: styles$1e['empty-state-container-inline__image']
|
|
11233
11250
|
}, React__default.createElement("img", {
|
|
11234
11251
|
src: mediaUrl,
|
|
11235
11252
|
alt: String(title),
|