@popmenu/ordering-ui 0.75.0 → 0.77.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/build/components/Button/Button.d.ts +1 -1
- package/build/components/Button/ButtonProps.d.ts +4 -5
- package/build/components/Button/index.d.ts +1 -1
- package/build/components/index.d.ts +2 -1
- package/build/index.d.ts +1 -0
- package/build/index.es.js +144 -109
- package/build/index.es.js.map +1 -1
- package/build/index.js +152 -109
- package/build/index.js.map +1 -1
- package/build/theme/index.d.ts +1 -0
- package/build/theme/overrides.d.ts +2 -0
- package/build/theme/palette.d.ts +2 -0
- package/build/theme/props.d.ts +2 -0
- package/build/theme/theme.d.ts +2 -0
- package/build/theme/typography.d.ts +2 -0
- package/package.json +2 -2
- package/build/components/Button/Button.styles.d.ts +0 -6
- package/build/components/Button/util/deriveButtonProps.d.ts +0 -5
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ButtonProps } from './ButtonProps';
|
|
3
|
-
export declare const Button: React.ForwardRefExoticComponent<Pick<ButtonProps, "className" | "style" | "classes" | "innerRef" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "form" | "key" | "autoFocus" | "disabled" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "name" | "type" | "value" | "
|
|
3
|
+
export declare const Button: React.ForwardRefExoticComponent<Pick<ButtonProps, "className" | "style" | "classes" | "innerRef" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "form" | "key" | "autoFocus" | "disabled" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "name" | "type" | "value" | "disableElevation" | "fullWidth" | "startIcon" | "endIcon" | "variation" | "disableFocusRipple" | "href" | "size" | "variant" | "action" | "buttonRef" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "onFocusVisible" | "TouchRippleProps"> & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { ButtonProps as
|
|
2
|
-
export interface ButtonProps extends
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
variant?: 'primary' | 'secondary' | 'text';
|
|
1
|
+
import { ButtonProps as MuiButtonProps } from '@material-ui/core';
|
|
2
|
+
export interface ButtonProps extends MuiButtonProps {
|
|
3
|
+
/** design system variation, not to be confused with "variant" which is an MUI prop */
|
|
4
|
+
variation?: 'primary' | 'secondary' | 'none';
|
|
6
5
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { Button
|
|
1
|
+
export { Button } from './Button';
|
|
2
2
|
export { ButtonProps } from './ButtonProps';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
export
|
|
1
|
+
export * from '@material-ui/core';
|
|
2
|
+
export { Button, ButtonProps } from './Button';
|
|
2
3
|
export { default as DishCard, DishCardProps } from './DishCard';
|
|
3
4
|
export { default as DishCheckoutCard, DishCheckoutCardProps } from './DishCheckoutCard';
|
|
4
5
|
export { default as DishDetailsReview, DishDetailsReviewProps } from './DishDetailsReview';
|
package/build/index.d.ts
CHANGED
package/build/index.es.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import { Button as Button$2, makeStyles, Typography as Typography$1, Link as Link$1, Paper as Paper$1, Box, Avatar as Avatar$1, useTheme as useTheme$1, FormControl, Select, InputAdornment, MenuItem, FormControlLabel as FormControlLabel$1, Checkbox as Checkbox$1, Radio as Radio$1, Menu, TextField } from '@material-ui/core';
|
|
2
|
+
export * from '@material-ui/core';
|
|
1
3
|
import * as React from 'react';
|
|
2
4
|
import React__default, { forwardRef, createElement, useState } from 'react';
|
|
3
5
|
import '@material-ui/lab/Alert';
|
|
4
|
-
import { makeStyles, Typography as Typography$1, Link as Link$1, Paper as Paper$1, Box, Avatar as Avatar$1, useTheme as useTheme$1, FormControl, Select, InputAdornment, MenuItem, FormControlLabel as FormControlLabel$1, Checkbox as Checkbox$1, Radio as Radio$1, Button as Button$2, Menu, TextField } from '@material-ui/core';
|
|
5
6
|
import '@material-ui/core/AppBar';
|
|
6
7
|
import MuiAvatar from '@material-ui/core/Avatar';
|
|
7
8
|
import { makeStyles as makeStyles$1, useTheme, lighten } from '@material-ui/core/styles';
|
|
@@ -86,6 +87,23 @@ function __rest$1(s, e) {
|
|
|
86
87
|
return t;
|
|
87
88
|
}
|
|
88
89
|
|
|
90
|
+
var Button$1 = forwardRef(function (props, ref) {
|
|
91
|
+
var _a = props.variation, variation = _a === void 0 ? 'primary' : _a, muiProps = __rest$1(props, ["variation"]);
|
|
92
|
+
var variationProps = {};
|
|
93
|
+
switch (variation) {
|
|
94
|
+
case 'primary':
|
|
95
|
+
variationProps.variant = 'contained';
|
|
96
|
+
variationProps.color = 'primary';
|
|
97
|
+
break;
|
|
98
|
+
case 'secondary':
|
|
99
|
+
variationProps.variant = 'outlined';
|
|
100
|
+
variationProps.color = 'primary';
|
|
101
|
+
break;
|
|
102
|
+
}
|
|
103
|
+
return React__default.createElement(Button$2, __assign$1({}, variationProps, muiProps, { ref: ref }));
|
|
104
|
+
});
|
|
105
|
+
Button$1.displayName = 'Button';
|
|
106
|
+
|
|
89
107
|
/*! *****************************************************************************
|
|
90
108
|
Copyright (c) Microsoft Corporation.
|
|
91
109
|
|
|
@@ -472,7 +490,7 @@ makeStyles$1(function (theme) { return ({
|
|
|
472
490
|
},
|
|
473
491
|
}); });
|
|
474
492
|
|
|
475
|
-
var useButtonStyles
|
|
493
|
+
var useButtonStyles = makeStyles$1(function () { return ({
|
|
476
494
|
root: {
|
|
477
495
|
minWidth: 'unset',
|
|
478
496
|
},
|
|
@@ -484,10 +502,10 @@ var useButtonStyles$1 = makeStyles$1(function () { return ({
|
|
|
484
502
|
},
|
|
485
503
|
}); });
|
|
486
504
|
|
|
487
|
-
var Button
|
|
505
|
+
var Button = forwardRef(function (props, ref) {
|
|
488
506
|
props.textTransform; var loading = props.loading, classesOverride = props.classes, className = props.className, muiProps = __rest(props, ["textTransform", "loading", "classes", "className"]);
|
|
489
507
|
props.classes; var styleProps = __rest(props, ["classes"]);
|
|
490
|
-
var classes = useButtonStyles
|
|
508
|
+
var classes = useButtonStyles(styleProps);
|
|
491
509
|
var typography = useTheme().typography;
|
|
492
510
|
var loadingIndicator = {
|
|
493
511
|
startIcon: React__default.createElement(CircularProgress, { color: "inherit", size: typography.button.fontSize }),
|
|
@@ -495,7 +513,7 @@ var Button$1 = forwardRef(function (props, ref) {
|
|
|
495
513
|
};
|
|
496
514
|
return (React__default.createElement(MuiButton, __assign({ ref: ref, classes: __assign(__assign({}, classes), classesOverride), className: classNames$1([className, 'pm-button']) }, muiProps, (loading && loadingIndicator))));
|
|
497
515
|
});
|
|
498
|
-
Button
|
|
516
|
+
Button.displayName = 'Button';
|
|
499
517
|
|
|
500
518
|
var Checkbox = forwardRef(function (props, ref) {
|
|
501
519
|
var label = props.label, disabled = props.disabled, LabelProps = props.LabelProps, muiProps = __rest(props, ["label", "disabled", "LabelProps"]);
|
|
@@ -504,7 +522,7 @@ var Checkbox = forwardRef(function (props, ref) {
|
|
|
504
522
|
});
|
|
505
523
|
Checkbox.displayName = 'Checkbox';
|
|
506
524
|
|
|
507
|
-
var getBackground
|
|
525
|
+
var getBackground = function (theme) { return function (props) {
|
|
508
526
|
var variant = props.variant, severity = props.severity;
|
|
509
527
|
var background = theme.palette.grey[100];
|
|
510
528
|
var backgrounds = {
|
|
@@ -523,7 +541,7 @@ var getBackground$1 = function (theme) { return function (props) {
|
|
|
523
541
|
}
|
|
524
542
|
return background;
|
|
525
543
|
}; };
|
|
526
|
-
var getColor
|
|
544
|
+
var getColor = function (theme) { return function (props) {
|
|
527
545
|
var variant = props.variant, severity = props.severity;
|
|
528
546
|
var textColor;
|
|
529
547
|
if (variant === 'outlined' && severity) {
|
|
@@ -565,8 +583,8 @@ var getBorder = function (theme) { return function (props) {
|
|
|
565
583
|
}; };
|
|
566
584
|
var useChipStyles = makeStyles$1(function (theme) { return ({
|
|
567
585
|
root: {
|
|
568
|
-
background: getBackground
|
|
569
|
-
color: getColor
|
|
586
|
+
background: getBackground(theme),
|
|
587
|
+
color: getColor(theme),
|
|
570
588
|
borderColor: getBorder(theme),
|
|
571
589
|
borderRadius: theme.spacing(0.5),
|
|
572
590
|
},
|
|
@@ -932,103 +950,6 @@ makeStyles(function (theme) { return ({
|
|
|
932
950
|
},
|
|
933
951
|
}); });
|
|
934
952
|
|
|
935
|
-
var getColor = function (theme) { return function (props) {
|
|
936
|
-
var variant = props.variant;
|
|
937
|
-
if (variant === 'primary') {
|
|
938
|
-
return theme.palette.common.white;
|
|
939
|
-
}
|
|
940
|
-
else if (variant === 'text') {
|
|
941
|
-
return theme.palette.info.main;
|
|
942
|
-
}
|
|
943
|
-
return theme.palette.common.black;
|
|
944
|
-
}; };
|
|
945
|
-
var getBackground = function (theme) { return function (props) {
|
|
946
|
-
var variant = props.variant;
|
|
947
|
-
if (variant === 'primary') {
|
|
948
|
-
return '#0A202F';
|
|
949
|
-
}
|
|
950
|
-
else {
|
|
951
|
-
return theme.palette.common.white;
|
|
952
|
-
}
|
|
953
|
-
}; };
|
|
954
|
-
var getFontSize = function () { return function (props) {
|
|
955
|
-
var variant = props.variant;
|
|
956
|
-
if (variant === 'primary') {
|
|
957
|
-
return '1rem';
|
|
958
|
-
}
|
|
959
|
-
else {
|
|
960
|
-
return '0.875rem';
|
|
961
|
-
}
|
|
962
|
-
}; };
|
|
963
|
-
var buttonTypography = {
|
|
964
|
-
fontWeight: 400,
|
|
965
|
-
lineHeight: '1.25rem',
|
|
966
|
-
};
|
|
967
|
-
var useButtonStyles = makeStyles$1(function (theme) { return ({
|
|
968
|
-
root: {
|
|
969
|
-
borderRadius: theme.spacing(6),
|
|
970
|
-
color: getColor(theme),
|
|
971
|
-
background: getBackground(theme),
|
|
972
|
-
fontSize: getFontSize(),
|
|
973
|
-
textTransform: 'none',
|
|
974
|
-
minWidth: 'unset',
|
|
975
|
-
},
|
|
976
|
-
disabled: {
|
|
977
|
-
'&$root': {
|
|
978
|
-
background: theme.palette.grey[300],
|
|
979
|
-
},
|
|
980
|
-
},
|
|
981
|
-
contained: {
|
|
982
|
-
padding: theme.spacing(2),
|
|
983
|
-
'&:hover': {
|
|
984
|
-
background: getBackground(theme),
|
|
985
|
-
},
|
|
986
|
-
},
|
|
987
|
-
outlined: {
|
|
988
|
-
padding: theme.spacing(2),
|
|
989
|
-
},
|
|
990
|
-
sizeSmall: {
|
|
991
|
-
padding: theme.spacing(1, 2),
|
|
992
|
-
},
|
|
993
|
-
text: {
|
|
994
|
-
padding: theme.spacing(1),
|
|
995
|
-
margin: 'auto',
|
|
996
|
-
},
|
|
997
|
-
label: __assign$1({}, buttonTypography),
|
|
998
|
-
}); });
|
|
999
|
-
|
|
1000
|
-
var deriveButtonProps = function (buttonProps) {
|
|
1001
|
-
var variant = buttonProps.variant;
|
|
1002
|
-
var derived = {};
|
|
1003
|
-
switch (variant) {
|
|
1004
|
-
case 'primary':
|
|
1005
|
-
derived.variant = 'contained';
|
|
1006
|
-
break;
|
|
1007
|
-
case 'secondary':
|
|
1008
|
-
derived.variant = 'outlined';
|
|
1009
|
-
break;
|
|
1010
|
-
case 'text':
|
|
1011
|
-
derived.variant = 'text';
|
|
1012
|
-
break;
|
|
1013
|
-
default:
|
|
1014
|
-
derived.variant = variant;
|
|
1015
|
-
break;
|
|
1016
|
-
}
|
|
1017
|
-
return derived;
|
|
1018
|
-
};
|
|
1019
|
-
|
|
1020
|
-
var Button = forwardRef(function (props, ref) {
|
|
1021
|
-
var children = props.children; props.variant; var classesOverride = props.classes, commonProps = __rest$1(props, ["children", "variant", "classes"]);
|
|
1022
|
-
var classes = useButtonStyles(props);
|
|
1023
|
-
var derivedProps = deriveButtonProps(props);
|
|
1024
|
-
var mergedProps = __assign$1(__assign$1({}, derivedProps), commonProps);
|
|
1025
|
-
return (React__default.createElement(Button$1, __assign$1({ ref: ref, classes: __assign$1(__assign$1({}, classes), classesOverride), disableElevation: true }, mergedProps), children));
|
|
1026
|
-
});
|
|
1027
|
-
Button.defaultProps = {
|
|
1028
|
-
variant: 'primary',
|
|
1029
|
-
};
|
|
1030
|
-
Button.displayName = 'Button';
|
|
1031
|
-
|
|
1032
953
|
var _path$1f;
|
|
1033
954
|
|
|
1034
955
|
function _extends$2M() { _extends$2M = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$2M.apply(this, arguments); }
|
|
@@ -1527,7 +1448,7 @@ var DishCheckoutCard = function (props) {
|
|
|
1527
1448
|
specialInstructions,
|
|
1528
1449
|
"\"")),
|
|
1529
1450
|
React__default.createElement(Box, { display: "flex", gridGap: 1, height: "100%" },
|
|
1530
|
-
React__default.createElement(Button, { variant: "text", onClick: onEdit }, "Edit"),
|
|
1451
|
+
React__default.createElement(Button$1, { variant: "text", onClick: onEdit }, "Edit"),
|
|
1531
1452
|
React__default.createElement(IconButton, { onClick: onDelete },
|
|
1532
1453
|
React__default.createElement(Icon, { icon: SvgTrash, className: classes.deleteIcon })))),
|
|
1533
1454
|
React__default.createElement(Box, { display: "flex", gridGap: 16, alignItems: "center" },
|
|
@@ -1739,7 +1660,7 @@ DishModifierCard.displayName = 'DishModifierCard';
|
|
|
1739
1660
|
var useLocationCardStyles = makeStyles$1(function (theme) {
|
|
1740
1661
|
var _a = theme.palette, info = _a.info, grey = _a.grey, secondary = _a.secondary, spacing = theme.spacing;
|
|
1741
1662
|
var selectedBackgroundColor = lighten(theme.palette.info.light, 0.9);
|
|
1742
|
-
var backgroundColor = theme.palette.
|
|
1663
|
+
var backgroundColor = theme.palette.background.default;
|
|
1743
1664
|
return {
|
|
1744
1665
|
root: {
|
|
1745
1666
|
background: '#FFF',
|
|
@@ -2074,5 +1995,119 @@ var SelectableChipGroup = function (props) {
|
|
|
2074
1995
|
React__default.createElement(Box, { minWidth: "1px" })));
|
|
2075
1996
|
};
|
|
2076
1997
|
|
|
2077
|
-
|
|
1998
|
+
var palette = {
|
|
1999
|
+
primary: {
|
|
2000
|
+
light: '#7B7FA3',
|
|
2001
|
+
main: '#2E3042',
|
|
2002
|
+
dark: '#1A1D20',
|
|
2003
|
+
},
|
|
2004
|
+
secondary: {
|
|
2005
|
+
light: '#DA777E',
|
|
2006
|
+
main: '#F04649',
|
|
2007
|
+
dark: '#B3212B',
|
|
2008
|
+
},
|
|
2009
|
+
info: {
|
|
2010
|
+
light: '#52B7FF',
|
|
2011
|
+
main: '#0076CB',
|
|
2012
|
+
dark: '#164B54',
|
|
2013
|
+
},
|
|
2014
|
+
success: {
|
|
2015
|
+
light: '#48D3AB',
|
|
2016
|
+
main: '#00B485',
|
|
2017
|
+
dark: '#00663E',
|
|
2018
|
+
contrastText: '#FFFFFF',
|
|
2019
|
+
},
|
|
2020
|
+
error: {
|
|
2021
|
+
light: '#DA777E',
|
|
2022
|
+
main: '#E52021',
|
|
2023
|
+
dark: '#A80005',
|
|
2024
|
+
},
|
|
2025
|
+
warning: {
|
|
2026
|
+
light: '#F0DFBA',
|
|
2027
|
+
main: '#F5C364',
|
|
2028
|
+
dark: '#E57E45',
|
|
2029
|
+
},
|
|
2030
|
+
};
|
|
2031
|
+
|
|
2032
|
+
var overrides = {
|
|
2033
|
+
MuiButton: {
|
|
2034
|
+
root: {
|
|
2035
|
+
borderRadius: 32,
|
|
2036
|
+
textTransform: 'none',
|
|
2037
|
+
},
|
|
2038
|
+
},
|
|
2039
|
+
};
|
|
2040
|
+
|
|
2041
|
+
var props = {
|
|
2042
|
+
MuiButton: {
|
|
2043
|
+
disableElevation: true,
|
|
2044
|
+
},
|
|
2045
|
+
};
|
|
2046
|
+
|
|
2047
|
+
var fonts = ['"Poppins"', '"sans-serif"'];
|
|
2048
|
+
var typography = {
|
|
2049
|
+
htmlFontSize: 16,
|
|
2050
|
+
fontFamily: fonts.join(', '),
|
|
2051
|
+
h1: {
|
|
2052
|
+
fontWeight: 400,
|
|
2053
|
+
fontSize: '6rem',
|
|
2054
|
+
lineHeight: '9rem',
|
|
2055
|
+
},
|
|
2056
|
+
h2: {
|
|
2057
|
+
fontWeight: 400,
|
|
2058
|
+
fontSize: '3.75rem',
|
|
2059
|
+
lineHeight: '5.625rem',
|
|
2060
|
+
},
|
|
2061
|
+
h3: {
|
|
2062
|
+
fontWeight: 400,
|
|
2063
|
+
fontSize: '3rem',
|
|
2064
|
+
lineHeight: '4.5rem',
|
|
2065
|
+
},
|
|
2066
|
+
h4: {
|
|
2067
|
+
fontWeight: 400,
|
|
2068
|
+
fontSize: '2.125rem',
|
|
2069
|
+
lineHeight: '3.25rem',
|
|
2070
|
+
},
|
|
2071
|
+
h5: {
|
|
2072
|
+
fontWeight: 500,
|
|
2073
|
+
fontSize: '1.5rem',
|
|
2074
|
+
lineHeight: '2.25rem',
|
|
2075
|
+
},
|
|
2076
|
+
h6: {
|
|
2077
|
+
fontWeight: 500,
|
|
2078
|
+
fontSize: '1.25rem',
|
|
2079
|
+
lineHeight: '1.875rem',
|
|
2080
|
+
},
|
|
2081
|
+
body1: {
|
|
2082
|
+
fontWeight: 400,
|
|
2083
|
+
fontSize: '1rem',
|
|
2084
|
+
lineHeight: '1.5rem',
|
|
2085
|
+
},
|
|
2086
|
+
body2: {
|
|
2087
|
+
fontWeight: 400,
|
|
2088
|
+
fontSize: '0.875rem',
|
|
2089
|
+
lineHeight: '1.25rem',
|
|
2090
|
+
},
|
|
2091
|
+
subtitle1: {
|
|
2092
|
+
fontWeight: 400,
|
|
2093
|
+
fontSize: '0.75rem',
|
|
2094
|
+
lineHeight: '1.125rem',
|
|
2095
|
+
color: '#9E9E9E',
|
|
2096
|
+
},
|
|
2097
|
+
button: {
|
|
2098
|
+
fontWeight: 500,
|
|
2099
|
+
fontSize: '0.875rem',
|
|
2100
|
+
lineHeight: '1.25rem',
|
|
2101
|
+
textTransform: 'capitalize',
|
|
2102
|
+
},
|
|
2103
|
+
};
|
|
2104
|
+
|
|
2105
|
+
var orderingTheme = {
|
|
2106
|
+
typography: typography,
|
|
2107
|
+
palette: palette,
|
|
2108
|
+
overrides: overrides,
|
|
2109
|
+
props: props,
|
|
2110
|
+
};
|
|
2111
|
+
|
|
2112
|
+
export { Button$1 as Button, DishCard, DishCheckoutCard, DishDetailsReview, DishModifierCard, ItemTag, ItemTagGroup, LocationCard, MenuDropdown, MenuFilter, QuantityPicker, ReactionCounter, ReactionCounterGroup, SelectableChip, SelectableChipGroup, StatusTag, orderingTheme };
|
|
2078
2113
|
//# sourceMappingURL=index.es.js.map
|