@open-tender/utils
Version:
A library of utils for use with Open Tender applications that utilize our cloud-based Order API.
66 lines (65 loc) • 2.29 kB
TypeScript
import { Auth, CartItem, ConfigDisplaySetting, FavoritesLookup } from '@open-tender/types';
export declare const useMenuItem: (builtItem: CartItem, auth: Auth | null, lookup: FavoritesLookup, cartId: number | null, displaySettings?: ConfigDisplaySetting) => {
description: string | null;
tags: string[];
allergens: string[];
displayPrice: string;
displayCals: number | null;
totalPoints: number | null;
totalAllergens: string[];
auth: Auth | null;
favoriteId: number | null;
isIncomplete: boolean;
hasTagsAllergens: boolean;
hasTags: boolean;
hasAllergens: boolean;
hasGroups: boolean;
pos_ext_id: string | null;
sizeGroup: import("@open-tender/types").CartItemGroup | null | undefined;
sizeSelected: boolean;
nonSizeGroups: import("@open-tender/types").CartItemGroup[] | null;
requiresCustomization: boolean;
hasCals: boolean;
hasIngredients: boolean | "" | null;
hasInfo: boolean | "" | null;
hasMadeFor: boolean;
hasNotes: boolean;
hasSelections: boolean;
cartGuestId: number | null;
customerId: number | null;
index?: number | undefined;
madeFor: string | null;
notes: string | null;
signature?: string | undefined;
similarItems: number[];
upsellItems: number[];
list_name: string | null;
list_id: string | null;
menu_position: number | null;
allergens_list?: import("@open-tender/types").MenuItemAllergens | undefined;
cals: number | null;
groups: import("@open-tender/types").CartItemGroups;
id: number;
imageUrl: string | null;
appImageUrl?: string | null | undefined;
increment: number;
ingredients: string | null;
isSoldOut: boolean;
max: number;
min: number;
name: string;
nutritionalInfo: import("@open-tender/types").NutritionalInfo | null;
points: number | null;
price: number;
quantity: number;
shorthand: string | null;
shortDescription: string | null;
shortName: string;
slug: string;
suspend_until: number | null;
tags_list?: import("@open-tender/types").MenuItemTags | undefined;
totalCals: number | null;
totalPrice: number | null;
itemShape: import("@open-tender/types").PizzaShape | null;
excludeFromBuilder: boolean;
};