Calendar change

This commit is contained in:
Bill 2022-03-16 03:22:01 -04:00
parent 1d17067b02
commit 079a57c012
2 changed files with 4 additions and 26 deletions

View File

@ -1,15 +1,15 @@
import { FC } from 'react';
import { GetConfiguration, GetRoomEngine, GetSessionDataManager } from '../../api';
import { Base, Column, Flex, LayoutImage } from '../../common';
import { CalendarItem } from './common/CalendarItem';
import { CalendarItemState } from './common/CalendarItemState';
import { ICalendarItem } from './common/ICalendarItem';
interface CalendarItemViewProps
{
itemId: number;
state: number;
active?: boolean;
product?: CalendarItem;
product?: ICalendarItem;
onClick: (itemId: number) => void;
}

View File

@ -2,14 +2,14 @@ import { FC, useState } from 'react';
import { GetSessionDataManager, LocalizeText } from '../../api';
import { Base, Button, Column, Flex, Grid, NitroCardContentView, NitroCardHeaderView, NitroCardView, Text } from '../../common';
import { CalendarItemView } from './CalendarItemView';
import { CalendarItem } from './common/CalendarItem';
import { CalendarItemState } from './common/CalendarItemState';
import { ICalendarItem } from './common/ICalendarItem';
interface CalendarViewProps
{
close(): void;
openPackage(id: number, asStaff: boolean): void;
receivedProducts: Map<number, CalendarItem>;
receivedProducts: Map<number, ICalendarItem>;
campaignName: string;
currentDay: number;
numDays: number;
@ -139,28 +139,6 @@ export const CalendarView: FC<CalendarViewProps> = props =>
<Base pointer className="campaign-spritesheet next" onClick={ onClickNext } />
</Flex>
</Flex>
{/* <Grid fullHeight alignItems="center" gap={ 1 }>
<Column fullHeight center size={ 1 }>
<Base pointer className="campaign-spritesheet prev" onClick={ onClickPrev } />
</Column>
<Column fullHeight size={ 10 }>
<Grid fullHeight columnCount={ TOTAL_SHOWN_ITEMS } gap={ 1 }>
{ [...Array(TOTAL_SHOWN_ITEMS)].map((e, i) =>
{
const day = (index + i);
return (
<Column key={ i } overflow="hidden">
<CalendarItemView itemId={ day } state={ getDayState(day) } active={ (selectedDay === day) } productName={ receivedProducts.has(day) ? receivedProducts.get(day) : null } onClick={ onClickItem } />
</Column>
);
}) }
</Grid>
</Column>
<Column fullHeight center size={ 1 }>
<Base pointer className="campaign-spritesheet next" onClick={ onClickNext } />
</Column>
</Grid> */}
</NitroCardContentView>
</NitroCardView>
)