@popmenu/ordering-ui 0.113.0 → 0.113.2
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.
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
|
|
2
|
+
import { BoxProps } from '@material-ui/core';
|
|
3
|
+
export interface MenuSectionProps extends BoxProps {
|
|
3
4
|
/** when true, will render a skeleton in place of the section title */
|
|
4
5
|
loading?: boolean;
|
|
5
6
|
/** the name of a section, will render as the section's title */
|
package/build/index.es.js
CHANGED
|
@@ -1517,12 +1517,12 @@ StatusTag.defaultProps = {
|
|
|
1517
1517
|
StatusTag.displayName = 'StatusTag';
|
|
1518
1518
|
|
|
1519
1519
|
var MenuItem = forwardRef(function (props, ref) {
|
|
1520
|
-
var onClick = props.onClick, id = props.id, description = props.description, isOutOfStock = props.isOutOfStock, title = props.title, loading = props.loading, isFeatured = props.isFeatured, image = props.image, likeCount = props.likeCount, reviewCount = props.reviewCount, price = props.price, available = props.available, itemTags = props.itemTags, className = props.className;
|
|
1520
|
+
var onClick = props.onClick, id = props.id, description = props.description, isOutOfStock = props.isOutOfStock, title = props.title, loading = props.loading, isFeatured = props.isFeatured, image = props.image, likeCount = props.likeCount, reviewCount = props.reviewCount, price = props.price, available = props.available, itemTags = props.itemTags, className = props.className, restProps = __rest$1(props, ["onClick", "id", "description", "isOutOfStock", "title", "loading", "isFeatured", "image", "likeCount", "reviewCount", "price", "available", "itemTags", "className"]);
|
|
1521
1521
|
var classes = useMenuItemStyles(props);
|
|
1522
1522
|
var handleClick = function (event) {
|
|
1523
1523
|
onClick(id, event);
|
|
1524
1524
|
};
|
|
1525
|
-
return (React__default.createElement(Card, { className: classNames(classes.card, className), ref: ref, elevation: 0, "data-component-type": "menu-item" },
|
|
1525
|
+
return (React__default.createElement(Card, __assign$1({ className: classNames(classes.card, className), ref: ref, elevation: 0, "data-component-type": "menu-item" }, restProps),
|
|
1526
1526
|
React__default.createElement(CardActionArea, { className: classes.cardActionArea, onClick: handleClick, disabled: loading },
|
|
1527
1527
|
React__default.createElement(MenuItemInfo, null,
|
|
1528
1528
|
isFeatured && React__default.createElement(StatusTag, { color: "highlight", label: "Featured", variant: "filled", size: "sm" }),
|
|
@@ -1812,7 +1812,7 @@ var QuantityPicker = function (props) {
|
|
|
1812
1812
|
onChange(event, { quantity: parseInt(event.target.value), reason: 'change' });
|
|
1813
1813
|
}
|
|
1814
1814
|
};
|
|
1815
|
-
return (React__default.createElement(TextField, { classes: fieldClasses, type: "number", variant: variation === 'itemCount' ? 'filled' : 'standard',
|
|
1815
|
+
return (React__default.createElement(TextField, { classes: fieldClasses, type: "number", variant: variation === 'itemCount' ? 'filled' : 'standard', value: value, disabled: disabled, onChange: handleChange, InputProps: {
|
|
1816
1816
|
classes: inputClasses,
|
|
1817
1817
|
disableUnderline: true,
|
|
1818
1818
|
endAdornment: (React__default.createElement(IconButton, { "aria-label": "plus one", className: endAdornmentClasses.root, color: "default", onClick: onIncrement, disabled: disabled || disableIncrement },
|
|
@@ -2049,6 +2049,10 @@ var useMenuDropdownStyles = makeStyles(function (theme) {
|
|
|
2049
2049
|
},
|
|
2050
2050
|
select: {
|
|
2051
2051
|
'& .MuiSelect-root': (_b = {
|
|
2052
|
+
'&:focus': {
|
|
2053
|
+
outline: '2px solid #0076CB',
|
|
2054
|
+
borderRadius: 8,
|
|
2055
|
+
},
|
|
2052
2056
|
color: '#212121',
|
|
2053
2057
|
padding: theme.spacing(1, 0.5, 1, 0.5),
|
|
2054
2058
|
zIndex: 10
|
|
@@ -2075,7 +2079,7 @@ var MenuDropdown = function (props) {
|
|
|
2075
2079
|
return breakpoints.down('md');
|
|
2076
2080
|
});
|
|
2077
2081
|
return (React__default.createElement(FormControl, { hiddenLabel: true, classes: { root: classes.formControl } },
|
|
2078
|
-
React__default.createElement(Select, { open: open, value: selectedOptionId, id: "menu-dropdown-select", onClick: function () { return setOpen(!open); }, disableUnderline: true, onChange: function (event) { return onSelect(event.target.value); }, fullWidth: true, startAdornment: React__default.createElement(InputAdornment, { position: "start" },
|
|
2082
|
+
React__default.createElement(Select, { open: open, value: selectedOptionId, id: "menu-dropdown-select", "aria-label": props.label, onClick: function () { return setOpen(!open); }, disableUnderline: true, onChange: function (event) { return onSelect(event.target.value); }, fullWidth: true, startAdornment: React__default.createElement(InputAdornment, { position: "start" },
|
|
2079
2083
|
React__default.createElement(Icon, { icon: SvgRestaurantMenu, size: isMobile ? 'extra-large' : 'large' })), IconComponent: function () { return (React__default.createElement(InputAdornment, { position: "end" },
|
|
2080
2084
|
React__default.createElement(Icon, { color: "#0076CB", icon: open ? SvgChevronUp : SvgChevronDown, size: "large" }))); }, MenuProps: {
|
|
2081
2085
|
disablePortal: true,
|
|
@@ -2511,10 +2515,12 @@ var overrides = {
|
|
|
2511
2515
|
},
|
|
2512
2516
|
MuiCssBaseline: {
|
|
2513
2517
|
'@global': {
|
|
2514
|
-
'*:focus-visible': {
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
+
'*:focus-visible, a:focus-visible': {
|
|
2519
|
+
'&': {
|
|
2520
|
+
outline: '2px solid #0076CB',
|
|
2521
|
+
outlineOffset: '-4px',
|
|
2522
|
+
borderRadius: 8,
|
|
2523
|
+
},
|
|
2518
2524
|
},
|
|
2519
2525
|
},
|
|
2520
2526
|
},
|