ordering-ui-external 2.4.6 → 2.5.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/_bundles/{0.ordering-ui.038c4b4d536032472bc7.js → 0.ordering-ui.5657c6a53b3791887fd7.js} +1 -1
- package/_bundles/{1.ordering-ui.038c4b4d536032472bc7.js → 1.ordering-ui.5657c6a53b3791887fd7.js} +1 -1
- package/_bundles/{2.ordering-ui.038c4b4d536032472bc7.js → 2.ordering-ui.5657c6a53b3791887fd7.js} +1 -1
- package/_bundles/{4.ordering-ui.038c4b4d536032472bc7.js → 4.ordering-ui.5657c6a53b3791887fd7.js} +1 -1
- package/_bundles/{5.ordering-ui.038c4b4d536032472bc7.js → 5.ordering-ui.5657c6a53b3791887fd7.js} +1 -1
- package/_bundles/{6.ordering-ui.038c4b4d536032472bc7.js → 6.ordering-ui.5657c6a53b3791887fd7.js} +1 -1
- package/_bundles/{7.ordering-ui.038c4b4d536032472bc7.js → 7.ordering-ui.5657c6a53b3791887fd7.js} +2 -2
- package/_bundles/{8.ordering-ui.038c4b4d536032472bc7.js → 8.ordering-ui.5657c6a53b3791887fd7.js} +1 -1
- package/_bundles/{9.ordering-ui.038c4b4d536032472bc7.js → 9.ordering-ui.5657c6a53b3791887fd7.js} +1 -1
- package/_bundles/ordering-ui.5657c6a53b3791887fd7.js +2 -0
- package/_modules/components/OrdersOption/styles.js +1 -1
- package/_modules/components/VerticalOrdersLayout/SingleOrderCard/index.js +15 -8
- package/_modules/components/VerticalOrdersLayout/styles.js +2 -2
- package/_modules/contexts/ThemeContext/index.js +1 -0
- package/_modules/themes/five/src/components/AddressList/index.js +8 -7
- package/_modules/themes/five/src/components/BusinessBasicInformation/index.js +28 -22
- package/_modules/themes/five/src/components/BusinessBasicInformation/styles.js +22 -21
- package/_modules/themes/five/src/components/BusinessController/index.js +5 -3
- package/_modules/themes/five/src/components/BusinessInformation/index.js +16 -10
- package/_modules/themes/five/src/components/BusinessItemAccordion/index.js +5 -8
- package/_modules/themes/five/src/components/BusinessListingSearch/index.js +93 -74
- package/_modules/themes/five/src/components/BusinessListingSearch/styles.js +10 -4
- package/_modules/themes/five/src/components/BusinessProductsCategories/index.js +7 -2
- package/_modules/themes/five/src/components/BusinessProductsCategories/styles.js +1 -1
- package/_modules/themes/five/src/components/BusinessProductsList/index.js +1 -1
- package/_modules/themes/five/src/components/BusinessProductsListing/index.js +38 -13
- package/_modules/themes/five/src/components/BusinessProductsListing/styles.js +20 -9
- package/_modules/themes/five/src/components/BusinessesListing/layouts/OriginalBusinessesListing/index.js +35 -23
- package/_modules/themes/five/src/components/Cart/index.js +7 -3
- package/_modules/themes/five/src/components/Checkout/index.js +12 -11
- package/_modules/themes/five/src/components/Checkout/styles.js +8 -4
- package/_modules/themes/five/src/components/GiftCard/GiftCardUI/index.js +1 -0
- package/_modules/themes/five/src/components/GiftCard/PurchaseGiftCard/index.js +4 -3
- package/_modules/themes/five/src/components/GiftCard/PurchaseGiftCard/styles.js +14 -8
- package/_modules/themes/five/src/components/GiftCard/RedeemGiftCard/index.js +1 -1
- package/_modules/themes/five/src/components/Header/index.js +29 -21
- package/_modules/themes/five/src/components/Header/styles.js +44 -40
- package/_modules/themes/five/src/components/MultiCheckout/index.js +18 -16
- package/_modules/themes/five/src/components/MultiOrdersDetails/SingleOrderCard.js +6 -4
- package/_modules/themes/five/src/components/MyOrders/index.js +16 -10
- package/_modules/themes/five/src/components/MyOrders/styles.js +15 -12
- package/_modules/themes/five/src/components/OrderDetails/OrderEta.js +5 -2
- package/_modules/themes/five/src/components/OrderDetails/OrderHistory.js +2 -2
- package/_modules/themes/five/src/components/OrderDetails/index.js +2 -2
- package/_modules/themes/five/src/components/OrderItAgain/styles.js +1 -1
- package/_modules/themes/five/src/components/OrderProgress/index.js +15 -4
- package/_modules/themes/five/src/components/OrderTypeSelectorContent/index.js +16 -4
- package/_modules/themes/five/src/components/PageBanner/styles.js +1 -1
- package/_modules/themes/five/src/components/ProductForm/index.js +27 -7
- package/_modules/themes/five/src/components/ProductForm/styles.js +40 -31
- package/_modules/themes/five/src/components/ProductItemAccordion/index.js +6 -6
- package/_modules/themes/five/src/components/RenderProductsLayout/index.js +3 -3
- package/_modules/themes/five/src/components/ReviewProduct/index.js +9 -4
- package/_modules/themes/five/src/components/ServiceForm/index.js +22 -3
- package/_modules/themes/five/src/components/ServiceForm/styles.js +9 -3
- package/_modules/themes/five/src/components/SidebarMenu/index.js +19 -10
- package/_modules/themes/five/src/components/SignUpForm/index.js +56 -29
- package/_modules/themes/five/src/components/SingleOrderCard/index.js +1 -1
- package/_modules/themes/five/src/components/SingleOrderCard/styles.js +26 -24
- package/_modules/themes/five/src/components/SingleProductCard/layouts/original/index.js +9 -5
- package/_modules/themes/five/src/components/SingleProductCard/layouts/original/styles.js +2 -2
- package/_modules/themes/five/src/components/UpsellingPage/index.js +2 -1
- package/_modules/themes/five/src/components/UserFormDetails/index.js +58 -18
- package/_modules/themes/five/src/components/UserFormDetails/styles.js +7 -3
- package/_modules/themes/five/src/components/UserPopover/index.js +41 -25
- package/_modules/themes/five/src/components/UserProfileForm/index.js +19 -11
- package/_modules/themes/five/src/styles/Buttons/index.js +68 -58
- package/_modules/themes/five/src/styles/Inputs/index.js +40 -16
- package/_modules/utils/index.js +8 -2
- package/index.html +1 -1
- package/package.json +3 -2
- package/src/components/OrdersOption/styles.js +1 -0
- package/src/components/VerticalOrdersLayout/SingleOrderCard/index.js +35 -17
- package/src/components/VerticalOrdersLayout/styles.js +9 -0
- package/src/contexts/ThemeContext/index.js +1 -0
- package/src/themes/five/src/components/AddressList/index.js +6 -6
- package/src/themes/five/src/components/BusinessBasicInformation/index.js +24 -22
- package/src/themes/five/src/components/BusinessBasicInformation/styles.js +24 -3
- package/src/themes/five/src/components/BusinessController/index.js +4 -2
- package/src/themes/five/src/components/BusinessInformation/index.js +24 -12
- package/src/themes/five/src/components/BusinessItemAccordion/index.js +5 -6
- package/src/themes/five/src/components/BusinessListingSearch/index.js +127 -101
- package/src/themes/five/src/components/BusinessListingSearch/styles.js +15 -0
- package/src/themes/five/src/components/BusinessProductsCategories/index.js +7 -2
- package/src/themes/five/src/components/BusinessProductsCategories/styles.js +1 -1
- package/src/themes/five/src/components/BusinessProductsList/index.js +1 -1
- package/src/themes/five/src/components/BusinessProductsListing/index.js +34 -9
- package/src/themes/five/src/components/BusinessProductsListing/styles.js +26 -0
- package/src/themes/five/src/components/BusinessesListing/layouts/OriginalBusinessesListing/index.js +9 -2
- package/src/themes/five/src/components/Cart/index.js +3 -4
- package/src/themes/five/src/components/Checkout/index.js +18 -4
- package/src/themes/five/src/components/Checkout/styles.js +22 -0
- package/src/themes/five/src/components/GiftCard/GiftCardUI/index.js +1 -0
- package/src/themes/five/src/components/GiftCard/PurchaseGiftCard/index.js +41 -31
- package/src/themes/five/src/components/GiftCard/PurchaseGiftCard/styles.js +15 -4
- package/src/themes/five/src/components/GiftCard/RedeemGiftCard/index.js +2 -2
- package/src/themes/five/src/components/Header/index.js +17 -5
- package/src/themes/five/src/components/Header/styles.js +9 -6
- package/src/themes/five/src/components/MultiCheckout/index.js +9 -10
- package/src/themes/five/src/components/MultiOrdersDetails/SingleOrderCard.js +8 -5
- package/src/themes/five/src/components/MyOrders/index.js +13 -9
- package/src/themes/five/src/components/MyOrders/styles.js +3 -1
- package/src/themes/five/src/components/OrderDetails/OrderEta.js +3 -2
- package/src/themes/five/src/components/OrderDetails/OrderHistory.js +8 -2
- package/src/themes/five/src/components/OrderDetails/index.js +2 -2
- package/src/themes/five/src/components/OrderItAgain/styles.js +1 -1
- package/src/themes/five/src/components/OrderProgress/index.js +16 -5
- package/src/themes/five/src/components/OrderTypeSelectorContent/index.js +7 -4
- package/src/themes/five/src/components/PageBanner/styles.js +1 -4
- package/src/themes/five/src/components/ProductForm/index.js +23 -5
- package/src/themes/five/src/components/ProductForm/styles.js +36 -1
- package/src/themes/five/src/components/ProductItemAccordion/index.js +37 -29
- package/src/themes/five/src/components/RenderProductsLayout/index.js +3 -3
- package/src/themes/five/src/components/ReviewProduct/index.js +14 -6
- package/src/themes/five/src/components/ServiceForm/index.js +22 -4
- package/src/themes/five/src/components/ServiceForm/styles.js +16 -0
- package/src/themes/five/src/components/SidebarMenu/index.js +162 -144
- package/src/themes/five/src/components/SignUpForm/index.js +4 -3
- package/src/themes/five/src/components/SingleOrderCard/index.js +1 -1
- package/src/themes/five/src/components/SingleOrderCard/styles.js +9 -1
- package/src/themes/five/src/components/SingleProductCard/layouts/original/index.js +13 -3
- package/src/themes/five/src/components/SingleProductCard/layouts/original/styles.js +2 -2
- package/src/themes/five/src/components/UpsellingPage/index.js +1 -1
- package/src/themes/five/src/components/UserFormDetails/index.js +58 -14
- package/src/themes/five/src/components/UserFormDetails/styles.js +16 -0
- package/src/themes/five/src/components/UserPopover/index.js +26 -15
- package/src/themes/five/src/components/UserProfileForm/index.js +18 -9
- package/src/themes/five/src/styles/Buttons/index.js +11 -0
- package/src/themes/five/src/styles/Inputs/index.js +34 -0
- package/src/utils/index.js +5 -0
- package/template/app.js +5 -3
- package/template/theme.json +335 -24
- package/_bundles/ordering-ui.038c4b4d536032472bc7.js +0 -2
- /package/_bundles/{7.ordering-ui.038c4b4d536032472bc7.js.LICENSE.txt → 7.ordering-ui.5657c6a53b3791887fd7.js.LICENSE.txt} +0 -0
- /package/_bundles/{ordering-ui.038c4b4d536032472bc7.js.LICENSE.txt → ordering-ui.5657c6a53b3791887fd7.js.LICENSE.txt} +0 -0
|
@@ -208,3 +208,19 @@ export const SwitchWrapper = styled.div`
|
|
|
208
208
|
justify-content: space-between;
|
|
209
209
|
width: 100%;
|
|
210
210
|
`
|
|
211
|
+
|
|
212
|
+
export const TextLinkWrapper = styled.span`
|
|
213
|
+
width: 100%;
|
|
214
|
+
display: flex;
|
|
215
|
+
justify-content: center;
|
|
216
|
+
margin-top: 15px;
|
|
217
|
+
span {
|
|
218
|
+
font-size: 14px;
|
|
219
|
+
text-align: center;
|
|
220
|
+
cursor: pointer;
|
|
221
|
+
color: ${props => props.theme.colors.primary};
|
|
222
|
+
&:hover {
|
|
223
|
+
text-decoration: underline;
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
`
|
|
@@ -16,12 +16,7 @@ import { DropDownCircleImage } from '../../../../../components/Dropdown/style'
|
|
|
16
16
|
import FaUserAlt from '@meronex/icons/fa/FaUserAlt'
|
|
17
17
|
import { capitalize } from '../../../../../utils'
|
|
18
18
|
import AiOutlineMenu from '@meronex/icons/ai/AiOutlineMenu'
|
|
19
|
-
|
|
20
|
-
const optionsDefault = [
|
|
21
|
-
{ name: 'search', pathname: '/explore', displayName: 'My home', key: 'my_home' },
|
|
22
|
-
{ name: 'business_search', pathname: '/business_search', displayName: 'Browse & Search', key: 'browse_search' },
|
|
23
|
-
{ name: 'orders', pathname: '/profile/orders', displayName: 'orders', key: 'orders' }
|
|
24
|
-
]
|
|
19
|
+
import { useTheme } from 'styled-components'
|
|
25
20
|
|
|
26
21
|
export const UserPopover = (props) => {
|
|
27
22
|
const {
|
|
@@ -38,7 +33,7 @@ export const UserPopover = (props) => {
|
|
|
38
33
|
const [{ configs }] = useConfig()
|
|
39
34
|
const [orderingTheme] = useOrderingTheme()
|
|
40
35
|
const [orderStatus] = useOrder()
|
|
41
|
-
|
|
36
|
+
const theme = useTheme()
|
|
42
37
|
const referenceElement = useRef()
|
|
43
38
|
const popperElement = useRef()
|
|
44
39
|
const arrowElement = useRef()
|
|
@@ -48,14 +43,30 @@ export const UserPopover = (props) => {
|
|
|
48
43
|
const isAddressListNewPage = orderingTheme?.theme?.profile?.components?.address_list?.components?.layout?.position === 'new_page'
|
|
49
44
|
const isChew = orderingTheme?.theme?.header?.components?.layout?.type?.toLowerCase() === 'chew'
|
|
50
45
|
|
|
46
|
+
const hideBrowse = theme?.bar_menu?.components?.browse?.hidden
|
|
47
|
+
const hideOrders = theme?.bar_menu?.components?.orders?.hidden
|
|
48
|
+
const hideProfile = theme?.bar_menu?.components?.profile?.hidden
|
|
49
|
+
const hideWallet = theme?.bar_menu?.components?.wallet?.hidden
|
|
50
|
+
const hideMessages = theme?.bar_menu?.components?.messages?.hidden
|
|
51
|
+
const hideHelp = theme?.bar_menu?.components?.help?.hidden
|
|
52
|
+
const hideFavorites = theme?.bar_menu?.components?.favortes?.hidden
|
|
53
|
+
const hideSession = theme?.bar_menu?.components?.sessions?.hidden
|
|
54
|
+
const hidePromotions = theme?.bar_menu?.components?.promotions?.hidden
|
|
55
|
+
|
|
56
|
+
const optionsDefault = [
|
|
57
|
+
{ name: 'search', pathname: '/explore', displayName: 'My home', key: 'my_home', isActive: true },
|
|
58
|
+
{ name: 'business_search', pathname: '/business_search', displayName: 'Browse & Search', key: 'browse_search', isActive: !hideBrowse },
|
|
59
|
+
{ name: 'orders', pathname: '/profile/orders', displayName: 'orders', key: 'orders', isActive: !hideOrders }
|
|
60
|
+
]
|
|
61
|
+
|
|
51
62
|
const extraOptions = [
|
|
52
|
-
{ name: 'profile', pathname: '/profile', displayName: 'view account', key: 'view_account', isActive:
|
|
53
|
-
{ name: 'wallets', pathname: '/wallets', displayName: 'wallets', key: 'wallets', isActive: isWalletEnabled && !isCustomerMode },
|
|
54
|
-
{ name: 'promotions', pathname: '/promotions', displayName: 'promotions', key: 'promotions', isActive: isPromotionsEnabled },
|
|
55
|
-
{ name: 'messages', pathname: '/messages', displayName: 'messages', key: 'messages', isActive: !isCustomerMode },
|
|
56
|
-
{ name: 'help', pathname: '/help', displayName: 'help', key: 'help', isActive:
|
|
57
|
-
{ name: 'sessions', pathname: '/sessions', displayName: 'sessions', key: 'sessions', isActive:
|
|
58
|
-
{ name: 'favorite', pathname: '/favorite', displayName: 'favorites', key: 'favorites', isActive:
|
|
63
|
+
{ name: 'profile', pathname: '/profile', displayName: 'view account', key: 'view_account', isActive: !hideProfile },
|
|
64
|
+
{ name: 'wallets', pathname: '/wallets', displayName: 'wallets', key: 'wallets', isActive: !hideWallet && isWalletEnabled && !isCustomerMode },
|
|
65
|
+
{ name: 'promotions', pathname: '/promotions', displayName: 'promotions', key: 'promotions', isActive: !hidePromotions && isPromotionsEnabled },
|
|
66
|
+
{ name: 'messages', pathname: '/messages', displayName: 'messages', key: 'messages', isActive: !hideMessages && !isCustomerMode },
|
|
67
|
+
{ name: 'help', pathname: '/help', displayName: 'help', key: 'help', isActive: !hideHelp },
|
|
68
|
+
{ name: 'sessions', pathname: '/sessions', displayName: 'sessions', key: 'sessions', isActive: !hideSession },
|
|
69
|
+
{ name: 'favorite', pathname: '/favorite', displayName: 'favorites', key: 'favorites', isActive: !hideFavorites },
|
|
59
70
|
{ name: 'addresses', pathname: '/profile/addresses', displayName: 'places', key: 'places', isActive: isAddressListNewPage }
|
|
60
71
|
]
|
|
61
72
|
|
|
@@ -149,7 +160,7 @@ export const UserPopover = (props) => {
|
|
|
149
160
|
<PopoverBody ref={popperElement} style={popStyle} {...attributes.popper}>
|
|
150
161
|
<PopoverList>
|
|
151
162
|
{options && options.length > 0 && (
|
|
152
|
-
options.map((option, i) => (
|
|
163
|
+
options.filter(option => option.isActive).map((option, i) => (
|
|
153
164
|
<PopoverListLink
|
|
154
165
|
key={i}
|
|
155
166
|
active={window.location.pathname === option.pathname}
|
|
@@ -41,6 +41,7 @@ import {
|
|
|
41
41
|
ListLink,
|
|
42
42
|
ListItem
|
|
43
43
|
} from './styles'
|
|
44
|
+
import { useTheme } from 'styled-components'
|
|
44
45
|
|
|
45
46
|
const LogoutActionUI = (props) => {
|
|
46
47
|
const [, t] = useLanguage()
|
|
@@ -95,6 +96,7 @@ const UserProfileFormUI = (props) => {
|
|
|
95
96
|
const [events] = useEvent()
|
|
96
97
|
const [{ user }] = useSession()
|
|
97
98
|
const [{ configs }] = useConfig()
|
|
99
|
+
const theme = useTheme()
|
|
98
100
|
const [orderingTheme] = useOrderingTheme()
|
|
99
101
|
const [willVerifyOtpState, setWillVerifyOtpState] = useState(false)
|
|
100
102
|
const [otpLeftTime, , resetOtpLeftTime] = useCountdownTimer(
|
|
@@ -103,9 +105,9 @@ const UserProfileFormUI = (props) => {
|
|
|
103
105
|
const inputRef = useRef(null)
|
|
104
106
|
const windowSize = useWindowSize()
|
|
105
107
|
|
|
106
|
-
const showCustomerPicture = !
|
|
107
|
-
const showAddressList = !
|
|
108
|
-
const userFormLayoutRow =
|
|
108
|
+
const showCustomerPicture = !theme?.profile?.components?.picture?.hidden
|
|
109
|
+
const showAddressList = !theme?.profile?.components?.address_list?.hidden
|
|
110
|
+
const userFormLayoutRow = theme?.profile?.components?.layout?.position === 'row'
|
|
109
111
|
|
|
110
112
|
const isPromotionsEnabled = configs?.advanced_offers_module?.value === '1' || configs?.advanced_offers_module?.value === true
|
|
111
113
|
const isAddressListNewPage = orderingTheme?.theme?.profile?.components?.address_list?.components?.layout?.position === 'new_page'
|
|
@@ -113,13 +115,20 @@ const UserProfileFormUI = (props) => {
|
|
|
113
115
|
configs?.wallet_enabled?.value === '1' &&
|
|
114
116
|
(configs?.wallet_cash_enabled?.value === '1' || configs?.wallet_credit_point_enabled?.value === '1')
|
|
115
117
|
|
|
118
|
+
const hideWallet = theme?.bar_menu?.components?.wallet?.hidden
|
|
119
|
+
const hideMessages = theme?.bar_menu?.components?.messages?.hidden
|
|
120
|
+
const hideHelp = theme?.bar_menu?.components?.help?.hidden
|
|
121
|
+
const hideFavorites = theme?.bar_menu?.components?.favortes?.hidden
|
|
122
|
+
const hideSession = theme?.bar_menu?.components?.sessions?.hidden
|
|
123
|
+
const hidePromotions = theme?.bar_menu?.components?.promotions?.hidden
|
|
124
|
+
|
|
116
125
|
const profileOptions = [
|
|
117
|
-
{ name: 'wallets', pathname: '/wallets', displayName: 'wallets', key: 'wallets', isActive: isWalletEnabled && !isCustomerMode },
|
|
118
|
-
{ name: 'promotions', pathname: '/promotions', displayName: 'promotions', key: 'promotions', isActive: isPromotionsEnabled },
|
|
119
|
-
{ name: 'messages', pathname: '/messages', displayName: 'messages', key: 'messages', isActive: !isCustomerMode },
|
|
120
|
-
{ name: 'help', pathname: '/help', displayName: 'help', key: 'help', isActive:
|
|
121
|
-
{ name: 'sessions', pathname: '/sessions', displayName: 'sessions', key: 'sessions', isActive:
|
|
122
|
-
{ name: 'favorite', pathname: '/favorite', displayName: 'favorites', key: 'favorites', isActive:
|
|
126
|
+
{ name: 'wallets', pathname: '/wallets', displayName: 'wallets', key: 'wallets', isActive: !hideWallet && isWalletEnabled && !isCustomerMode },
|
|
127
|
+
{ name: 'promotions', pathname: '/promotions', displayName: 'promotions', key: 'promotions', isActive: !hidePromotions && isPromotionsEnabled },
|
|
128
|
+
{ name: 'messages', pathname: '/messages', displayName: 'messages', key: 'messages', isActive: !hideMessages && !isCustomerMode },
|
|
129
|
+
{ name: 'help', pathname: '/help', displayName: 'help', key: 'help', isActive: !hideHelp },
|
|
130
|
+
{ name: 'sessions', pathname: '/sessions', displayName: 'sessions', key: 'sessions', isActive: !hideSession },
|
|
131
|
+
{ name: 'favorite', pathname: '/favorite', displayName: 'favorites', key: 'favorites', isActive: !hideFavorites },
|
|
123
132
|
{ name: 'addresses', pathname: '/profile/addresses', displayName: 'places', key: 'places', isActive: isAddressListNewPage }
|
|
124
133
|
]
|
|
125
134
|
|
|
@@ -44,6 +44,17 @@ export const Button = styled.button`
|
|
|
44
44
|
`}
|
|
45
45
|
}
|
|
46
46
|
`}
|
|
47
|
+
${({ theme }) => theme?.general?.components?.buttons?.borderRadius && css`
|
|
48
|
+
border-radius: ${theme?.general?.components?.buttons?.borderRadius};
|
|
49
|
+
`}
|
|
50
|
+
${({ theme }) => Object.values(theme?.general?.components?.buttons?.shadow?.components || {}).some(val => !!val) && css`
|
|
51
|
+
box-shadow:
|
|
52
|
+
${theme?.general?.components?.buttons?.shadow?.components?.x || '0px'}
|
|
53
|
+
${theme?.general?.components?.buttons?.shadow?.components?.y || '0px'}
|
|
54
|
+
${theme?.general?.components?.buttons?.shadow?.components?.blur || '0px'}
|
|
55
|
+
${theme?.general?.components?.buttons?.shadow?.components?.spread || '0px'}
|
|
56
|
+
${theme?.general?.components?.buttons?.shadow?.components?.color || '#000'};
|
|
57
|
+
`}
|
|
47
58
|
${({ outline }) => outline && css`
|
|
48
59
|
background: #FFF;
|
|
49
60
|
color: #CCC;
|
|
@@ -31,6 +31,23 @@ export const Input = styled.input`
|
|
|
31
31
|
${({ isError }) => isError && css`
|
|
32
32
|
border-color: ${props => props.theme.colors?.danger500} !important;
|
|
33
33
|
`}
|
|
34
|
+
|
|
35
|
+
${({ theme }) => theme?.general?.components?.inputs?.borderRadius && css`
|
|
36
|
+
border-radius: ${theme?.general?.components?.inputs?.borderRadius};
|
|
37
|
+
`}
|
|
38
|
+
|
|
39
|
+
${({ theme }) => theme?.general?.components?.inputs?.color && css`
|
|
40
|
+
color: ${theme?.general?.components?.inputs?.color};
|
|
41
|
+
`}
|
|
42
|
+
|
|
43
|
+
${({ theme }) => theme?.general?.components?.inputs?.borderColor && css`
|
|
44
|
+
border: 1px solid ${theme?.general?.components?.inputs?.borderColor};
|
|
45
|
+
&::placeholder,
|
|
46
|
+
&::-webkit-input-placeholder,
|
|
47
|
+
&:-ms-input-placeholder {
|
|
48
|
+
color: ${theme?.general?.components?.inputs?.borderColor};
|
|
49
|
+
}
|
|
50
|
+
`}
|
|
34
51
|
`
|
|
35
52
|
|
|
36
53
|
export const InputGroup = styled.div`
|
|
@@ -95,6 +112,23 @@ export const TextArea = styled.textarea`
|
|
|
95
112
|
&:-ms-input-placeholder {
|
|
96
113
|
color: #DBDCDB;
|
|
97
114
|
}
|
|
115
|
+
|
|
116
|
+
${({ theme }) => theme?.general?.components?.inputs?.borderRadius && css`
|
|
117
|
+
border-radius: ${theme?.general?.components?.inputs?.borderRadius};
|
|
118
|
+
`}
|
|
119
|
+
|
|
120
|
+
${({ theme }) => theme?.general?.components?.inputs?.color && css`
|
|
121
|
+
color: ${theme?.general?.components?.inputs?.color};
|
|
122
|
+
`}
|
|
123
|
+
|
|
124
|
+
${({ theme }) => theme?.general?.components?.inputs?.borderColor && css`
|
|
125
|
+
border: 1px solid ${theme?.general?.components?.inputs?.borderColor};
|
|
126
|
+
&::placeholder,
|
|
127
|
+
&::-webkit-input-placeholder,
|
|
128
|
+
&:-ms-input-placeholder {
|
|
129
|
+
color: ${theme?.general?.components?.inputs?.borderColor};
|
|
130
|
+
}
|
|
131
|
+
`}
|
|
98
132
|
`
|
|
99
133
|
|
|
100
134
|
export const InputGroupRight = styled(InputGroupLeft)`
|
package/src/utils/index.js
CHANGED
|
@@ -357,6 +357,11 @@ export const priceList = [
|
|
|
357
357
|
{ level: '5', content: '$$$$$' }
|
|
358
358
|
]
|
|
359
359
|
|
|
360
|
+
/**
|
|
361
|
+
* List of order type
|
|
362
|
+
*/
|
|
363
|
+
export const orderTypeList = ['delivery', 'pickup', 'eatin', 'curbside', 'drivethru', 'seatdelivery']
|
|
364
|
+
|
|
360
365
|
/**
|
|
361
366
|
* function to manage review comment list
|
|
362
367
|
* @param {number} param0 type of reviews to return
|
package/template/app.js
CHANGED
|
@@ -346,7 +346,7 @@ export const App = () => {
|
|
|
346
346
|
const oldLink = document.getElementById('favicon')
|
|
347
347
|
link.id = 'favicon'
|
|
348
348
|
link.rel = 'icon'
|
|
349
|
-
link.href = themeUpdated?.general?.components?.favicon
|
|
349
|
+
link.href = themeUpdated?.general?.components?.favicon?.components?.image || themeUpdated?.general?.components?.favicon
|
|
350
350
|
if (oldLink) {
|
|
351
351
|
document.head.removeChild(oldLink)
|
|
352
352
|
}
|
|
@@ -356,7 +356,8 @@ export const App = () => {
|
|
|
356
356
|
const fontElement = window.document.getElementById(`${name}-font-styles`)
|
|
357
357
|
if (
|
|
358
358
|
(fontElement?.name !== fontFamily.name && fontFamily.name) ||
|
|
359
|
-
(fontElement?.href !== fontFamily?.href && fontFamily?.href)
|
|
359
|
+
(fontElement?.href !== fontFamily?.href && fontFamily?.href) ||
|
|
360
|
+
(JSON.stringify(fontElement?.weights) !== JSON.stringify(fontFamily?.weights) && fontFamily?.weights)
|
|
360
361
|
) {
|
|
361
362
|
window.document.body.removeChild(window.document.getElementById(`${name}-font-styles`))
|
|
362
363
|
const font = window.document.createElement('link')
|
|
@@ -365,7 +366,8 @@ export const App = () => {
|
|
|
365
366
|
font.async = true
|
|
366
367
|
font.defer = true
|
|
367
368
|
font.name = fontFamily.name
|
|
368
|
-
|
|
369
|
+
const weights = typeof fontFamily?.weights === 'number' ? fontFamily?.weights : JSON.parse(fontFamily?.weights)?.join?.(';')
|
|
370
|
+
font.href = fontFamily.href || `https://fonts.googleapis.com/css2?family=${fontFamily?.name}:wght@${weights || [400]}&display=swap`
|
|
369
371
|
|
|
370
372
|
window.document.body.appendChild(font)
|
|
371
373
|
if (name === 'primary') {
|