build: update storybook (#214)

* chore: Update updatedAt dates in schedules

Set updatedAt dates to be fixed to '2024-01-01 12:00' for all schedules in
UserScheduleStore.

* build: update storybook

* chore: Removed unnecessary eslint-disable-next-line statements.
This commit is contained in:
Razboy20
2024-05-20 17:08:36 -05:00
committed by GitHub
parent 88c0061187
commit d4611952d4
10 changed files with 1704 additions and 2261 deletions

View File

@@ -38,23 +38,11 @@ const meta: Meta<typeof ScheduleDropdown> = {
layout: 'centered',
},
tags: ['autodocs'],
argTypes: {
defaultOpen: {
control: {
type: 'boolean',
},
},
children: {
control: {
type: 'node',
},
},
},
render: (args: ScheduleDropdownProps) => {
// eslint-disable-next-line react-hooks/rules-of-hooks
const [activeSchedule, schedules] = useSchedules();
// eslint-disable-next-line react-hooks/rules-of-hooks
useEffect(() => {
console.log(activeSchedule);
}, [activeSchedule]);

View File

@@ -12,13 +12,6 @@ const meta = {
parameters: {
layout: 'centered',
},
argTypes: {
schedule: {
control: {
type: 'UserSchedule',
},
},
},
args: {
schedule: exampleSchedule,
},
@@ -30,7 +23,7 @@ type Story = StoryObj<typeof meta>;
export const Active: Story = {
render(args) {
// eslint-disable-next-line react-hooks/rules-of-hooks
const [activeSchedule] = useSchedules();
return (

View File

@@ -117,6 +117,7 @@ export const Default: Story = {
export const Empty: Story = {
args: {
courseCells: [],
setCourse: () => {},
},
render: props => (
<div className='outline-red outline w-292.5!'>

View File

@@ -135,5 +135,6 @@ export const Default: Story = {
args: {
saturdayClass: true,
courseCells: testData,
setCourse: () => {},
},
};

View File

@@ -15,7 +15,7 @@ const meta = {
},
tags: ['autodocs'],
render(args) {
// eslint-disable-next-line react-hooks/rules-of-hooks
const [isOpen, setIsOpen] = useState(args.open);
return <CourseCatalogInjectedPopup {...args} open={isOpen} onClose={() => setIsOpen(false)} />;