diff --git a/.storybook/pages/CoursePlannerEdit/CoursePlannerEdit.module.css b/.storybook/pages/CoursePlannerEdit/CoursePlannerEdit.module.css deleted file mode 100644 index a510da6c69..0000000000 --- a/.storybook/pages/CoursePlannerEdit/CoursePlannerEdit.module.css +++ /dev/null @@ -1,58 +0,0 @@ -@import '../../../src/design-tokens/mixins.css'; -/*-----------------------------------------*\ - # COURSE PLANNER EDIT CLASSES -\*-----------------------------------------*/ - -/** - * Margin top xl mobile - * - * Forces margin top to 2rem (on smaller viewports only). - */ -.button--mobile { - margin-top: var(--eds-size-4) !important; - - @media all and (min-width: $eds-bp-md) { - margin-top: unset !important; - } -} - -/** - * Destructive variant of the Menu item. - * - * For indicating deletion of the project. - */ -.menu-item--destructive { - color: var(--eds-theme-color-text-utility-error); -} - -/*------------------------------------*\ - # TABLE CARD -\*------------------------------------*/ - -/** - * Card with a title, table, and button within - */ - -/** -* Table card table -* -* Actual table within the card. -*/ -.table-card__table { - color: var(--eds-theme-color-text-neutral-subtle); - margin-bottom: var(--eds-size-2); -} - -/** -* Table card table header cell -*/ -.table-card__table-header-cell { - /** - * First child within table card table header cell - */ - &:first-child { - @media all and (min-width: $eds-bp-md) { - width: 11.875rem; - } - } -} diff --git a/.storybook/pages/CoursePlannerEdit/CoursePlannerEdit.stories.ts b/.storybook/pages/CoursePlannerEdit/CoursePlannerEdit.stories.ts deleted file mode 100644 index ee1f2b64d1..0000000000 --- a/.storybook/pages/CoursePlannerEdit/CoursePlannerEdit.stories.ts +++ /dev/null @@ -1,13 +0,0 @@ -import type { StoryObj, Meta } from '@storybook/react'; -import type { ComponentProps } from 'react'; - -import { CoursePlannerEdit } from './CoursePlannerEdit'; - -export default { - title: 'Pages/Course Planner/Edit', - component: CoursePlannerEdit, -} as Meta; - -type Args = ComponentProps; - -export const Default: StoryObj = {}; diff --git a/.storybook/pages/CoursePlannerEdit/CoursePlannerEdit.tsx b/.storybook/pages/CoursePlannerEdit/CoursePlannerEdit.tsx deleted file mode 100644 index e4d00973b6..0000000000 --- a/.storybook/pages/CoursePlannerEdit/CoursePlannerEdit.tsx +++ /dev/null @@ -1,669 +0,0 @@ -import clsx from 'clsx'; -import React, { useState } from 'react'; -import type { ReactNode } from 'react'; - -import ProjectCard from './ProjectCard'; - -import { - Button, - ButtonGroup, - Card, - DataBar, - DragDrop, - Grid, - Heading, - HorizontalStepper, - Icon, - Layout, - LayoutContainer, - LayoutSection, - Menu, - NumberIcon, - PageHeader, - Panel, - Table, - Text, -} from '../../../src'; - -import type { NewState } from '../../../src/components/DragDrop/DragDrop'; - -import CardWithNotification from '../../recipes/CardWithNotification'; -import NumberIconList from '../../recipes/NumberIconList'; - -import EmptyImage from '../../static/hand-pencil.svg'; -import styles from './CoursePlannerEdit.module.css'; - -NumberIconList; -const CognitiveSkillColumns = [ - { - title: 'Least covered Cognitive Skills', - }, - { - title: 'Planned Projects', - }, -]; - -const CognitiveSkillRows = [ - { - value1: 'Argumentative Claim', - projects: [ - { - 'aria-label': 'Project 1', - complete: true, - }, - { - 'aria-label': 'Project 2', - complete: true, - }, - { - 'aria-label': 'Project 3', - complete: false, - }, - { - 'aria-label': 'Project 4', - complete: false, - }, - { - 'aria-label': 'Project 5', - complete: false, - }, - { - 'aria-label': 'Project 6', - complete: false, - }, - { - 'aria-label': 'Project 7', - complete: false, - }, - { - 'aria-label': 'Project 8', - complete: false, - }, - { - 'aria-label': 'Project 9', - complete: false, - }, - { - 'aria-label': 'Project 10', - complete: false, - }, - ], - }, - { - value1: 'Making Connections and Inferences', - projects: [ - { - 'aria-label': 'Project 1', - complete: true, - }, - ], - }, - { - value1: 'A longer heading that is super duper long', - projects: [ - { - 'aria-label': 'Project 1', - complete: true, - }, - { - 'aria-label': 'Project 2', - complete: true, - }, - { - 'aria-label': 'Project 3', - complete: true, - }, - { - 'aria-label': 'Project 4', - complete: true, - }, - { - 'aria-label': 'Project 5', - complete: true, - }, - ], - }, -]; - -const StandardsColumns = [ - { - title: 'Least covered Stan', - }, - { - title: 'Planned Projects', - }, -]; - -const StandardsRows = [ - { - value1: 'NGSS.3-5-ETS1-1', - projects: [ - { - 'aria-label': 'Project 1', - complete: true, - }, - { - 'aria-label': 'Project 2', - complete: true, - }, - { - 'aria-label': 'Project 3', - complete: false, - }, - { - 'aria-label': 'Project 4', - complete: false, - }, - { - 'aria-label': 'Project 5', - complete: false, - }, - { - 'aria-label': 'Project 6', - complete: false, - }, - { - 'aria-label': 'Project 7', - complete: false, - }, - { - 'aria-label': 'Project 8', - complete: false, - }, - { - 'aria-label': 'Project 9', - complete: false, - }, - { - 'aria-label': 'Project 10', - complete: false, - }, - ], - }, - { - value1: 'NGSS.3-5.ESS1.C', - projects: [ - { - 'aria-label': 'Project 1', - complete: true, - }, - ], - }, - { - value1: 'NGSS.3-5.ESS1.E', - projects: [ - { - 'aria-label': 'Project 1', - complete: true, - }, - { - 'aria-label': 'Project 2', - complete: true, - }, - { - 'aria-label': 'Project 3', - complete: true, - }, - { - 'aria-label': 'Project 4', - complete: true, - }, - { - 'aria-label': 'Project 5', - complete: true, - }, - ], - }, - { - value1: 'NGSS.3-5.PS3.C', - projects: [ - { - 'aria-label': 'Project 1', - complete: false, - }, - { - 'aria-label': 'Project 2', - complete: false, - }, - { - 'aria-label': 'Project 3', - complete: false, - }, - { - 'aria-label': 'Project 4', - complete: false, - }, - { - 'aria-label': 'Project 5', - complete: false, - }, - ], - }, - { - value1: 'NGSS.3-5.PS3.E', - projects: [ - { - 'aria-label': 'Project 1', - complete: false, - }, - { - 'aria-label': 'Project 2', - complete: true, - }, - { - 'aria-label': 'Project 3', - complete: false, - }, - { - 'aria-label': 'Project 4', - complete: false, - }, - { - 'aria-label': 'Project 5', - complete: false, - }, - ], - }, -]; - -interface Item { - 'aria-label': string; - complete: boolean; -} - -interface Row { - value1: string; - projects: Item[]; -} - -interface Column { - title: string; -} - -interface CardProps { - /** - * CSS class names that can be appended to the component. - */ - className?: string; - title?: string; - buttonContent?: ReactNode; - tableColumns: Column[]; - tableRows: Row[]; -} - -/** - * A Card containing a Table. - */ -export const TableCard = ({ - className, - title, - buttonContent, - tableRows, - tableColumns, - ...other -}: CardProps) => { - const componentClassName = clsx(styles['table-card'], className); - - return ( - - - - {title} - - - - - {tableColumns.map((item, index) => { - return ( - - {item.title} - - ); - })} - - - - {tableRows.map((item) => { - return ( - - - {item.value1} - - - - {item.projects.map((item, index) => { - return ( - - ); - })} - - - - ); - })} - -
-
- - - -
- ); -}; - -export const CoursePlannerEdit = () => { - const container1EmptyContent = () => { - return ( - <> - - There are no more available projects to create your course plan - - hand with pencil - - ); - }; - - const container2EmptyContent = () => { - return ( - <> - - Drag in available projects to build your course plan - - hand with pencil - - ); - }; - - const projectCardMenuItems = () => { - return ( - <> - Move to other section - Move up - Move down - Move view details - - ); - }; - - const projectCardMenuItemsWithDelete = () => { - return ( - <> - Move to other section - Move up - Move down - - Delete item - - - ); - }; - - const [indexState, setIndexState] = useState(2); - const [containers, setContainers] = useState({ - 'container-1': { - itemIds: ['item-1', 'item-2', 'item-3', 'item-4', 'item-5'], - emptyContent: container1EmptyContent(), - header: ( - -
- - Available projects - -
- -
-
-
- ), - }, - 'container-2': { - itemIds: [], - emptyContent: container2EmptyContent(), - header: ( - -
- - Planned projects - -
- -
-
-
- ), - }, - }); - const [items, setItems] = useState({ - 'item-1': { - title: 'Project #1', - children: ( - - ), - }, - 'item-2': { - title: 'Project #2', - children: ( - - ), - }, - 'item-3': { - title: 'Project #3', - children: ( - - ), - }, - 'item-4': { - title: 'Project #4', - children: ( - - ), - }, - 'item-5': { - title: 'Project #5', - children: ( - - ), - }, - 'item-6': { - title: 'Project #6', - children: ( - - ), - }, - }); - const returnUpdatedItems = (updatedItems: any) => { - setContainers(updatedItems.containers); - setItems(updatedItems.items); - updatedItems.containers['container-2'].itemIds.map( - (item: string, index: number) => { - if (item === 'item-2') { - updatedItems.items['item-2'].behavior = 'hover'; - setIndexState(index + 1); - } - }, - ); - }; - return ( - <> - - - - } - headingSize="title-sm" - orientation="2up" - right={ - // The parent class of this ButtonGroup is .page-header, - // which uses flex-direction:column, with a media query - // that changes flex-direction to row at the medium - // breakpoint. This ButtonGroup needs to have a margin - // above it only when the flex-direction is column, so - // this utility class was written with a media query - // that matches the behavior of .page-header - - - - - } - title="Course Planner: History 6" - /> - - - - - - - - Select projects for your History 6 plan - -
- - Make a plan so that you can stay connected to learning - objectives even as changes occur throughout the year. - - - Room for more instructional copy per Content Strategy lorem - ipsum dolor sit amet, consectetur adipiscing elit. Phasellus - est quam, consequat iaculis pretium accumsan, fringilla id - ligula. - -
- - - returnUpdatedItems(updatedItems) - } - items={items} - multipleContainers={false} - unstyledItems - /> -
-
- - - - - - - - - - - - - - - -
-
- - ); -}; diff --git a/.storybook/pages/CoursePlannerEdit/ProjectCard/ProjectCard.module.css b/.storybook/pages/CoursePlannerEdit/ProjectCard/ProjectCard.module.css deleted file mode 100644 index ee6c152803..0000000000 --- a/.storybook/pages/CoursePlannerEdit/ProjectCard/ProjectCard.module.css +++ /dev/null @@ -1,61 +0,0 @@ -@import '../../../../src/design-tokens/mixins.css'; - -/*------------------------------------*\ - # PROJECT CARD -\*------------------------------------*/ - -/** - * Primary UI components acts as container for card components. - */ -.project-card { - position: relative; - transition: all var(--eds-anim-fade-quick) var(--eds-anim-fade-quick); - - @media screen and (prefers-reduced-motion) { - transition: none; - } -} - -.project-card__header.project-card__header { - margin-right: var(--eds-size-1); - - /** - * Project card header within draggable project card. - */ - .project-card--draggable & { - /* Allows room for the handle to show on hover without overlaying content. */ - min-width: var(--eds-size-2-and-half); - } -} - -.project-card__body { - flex-direction: row; - gap: var(--eds-); -} - -.project-card__footer { - display: flex; - flex-direction: column; - align-items: center; - justify-content: center; -} - -.project-card__title { - min-height: var(--eds-size-6); -} - -.project-card__menu-button { - padding-top: var(--eds-size-2); - padding-bottom: var(--eds-size-2); -} - -.project-card__meta { - font: var(--eds-theme-typography-body-xs); - color: var(--eds-theme-color-text-neutral-subtle); -} - -.project-card__meta-icon { - margin-right: var(--eds-size-1); - position: relative; - bottom: 1px; -} diff --git a/.storybook/pages/CoursePlannerEdit/ProjectCard/ProjectCard.tsx b/.storybook/pages/CoursePlannerEdit/ProjectCard/ProjectCard.tsx deleted file mode 100644 index f2588d15ca..0000000000 --- a/.storybook/pages/CoursePlannerEdit/ProjectCard/ProjectCard.tsx +++ /dev/null @@ -1,151 +0,0 @@ -import clsx from 'clsx'; -import type { ReactNode } from 'react'; -import React from 'react'; - -import { Card, Heading, Icon, Menu, NumberIcon } from '../../../../src'; -import type { HeadingElement } from '../../../../src/components/Heading'; - -import type { IconName } from '../../../../src/components/Icon'; -import styles from './ProjectCard.module.css'; - -export interface Props { - /** - * Determines type of clickable - * - **draggable** renders a card that is used to drag with space for the handle on the left - */ - behavior?: 'draggable'; - /** - * Menu items - * - * If not declared, the menu does not render. - */ - menuItems?: ReactNode; - /** - * CSS class names that can be appended to the component. - */ - className?: string; - /** - * Heading as element. Needed to create semantic heading order on page depending on - * where this is placed - */ - headingAs?: HeadingElement; - /** - * Project card title - */ - title?: string; - /** - * Project card meta data (e.g. calendar) - */ - meta?: string; - /** - * Project card meta icon name. Should be appropriate EDS icon name. - */ - metaIconName?: IconName; - /** - * Project card number - */ - number?: number; - /** - * Number aria label. Required if number prop is passed. - */ - numberAriaLabel?: string; - /** - * Property passed in to style draggable project card - */ - isDragging?: boolean; -} - -/** - * A card containing project information to be used in the `DragDrop` component. - */ -export const ProjectCard = ({ - behavior, - className, - title, - meta, - metaIconName, - number, - headingAs = 'h3', - menuItems, - numberAriaLabel, - isDragging, - ...other -}: Props) => { - if (number && !numberAriaLabel && process.env.NODE_ENV !== 'production') { - throw new Error( - 'You must provide a "numberAriaLabel" for the number icon if a "number" has been passed', - ); - } - const componentClassName = clsx( - styles['project-card'], - behavior === 'draggable' && styles['project-card--draggable'], - className, - ); - return ( - - - {number && numberAriaLabel && ( - - )} - - - - {title} - - {meta && ( -
- {metaIconName && ( - - )} - {meta} -
- )} -
- {menuItems && ( - - - - - - {menuItems} - - - )} -
- ); -}; diff --git a/.storybook/pages/CoursePlannerEdit/ProjectCard/index.ts b/.storybook/pages/CoursePlannerEdit/ProjectCard/index.ts deleted file mode 100644 index 2c62b813b8..0000000000 --- a/.storybook/pages/CoursePlannerEdit/ProjectCard/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { ProjectCard as default } from './ProjectCard'; diff --git a/.storybook/pages/CoursePlannerEdit/index.ts b/.storybook/pages/CoursePlannerEdit/index.ts deleted file mode 100644 index 03be063f24..0000000000 --- a/.storybook/pages/CoursePlannerEdit/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { CoursePlannerEdit as default } from './CoursePlannerEdit'; diff --git a/.storybook/pages/CoursePlannerModal/CoursePlannerModal.stories.tsx b/.storybook/pages/CoursePlannerModal/CoursePlannerModal.stories.tsx deleted file mode 100644 index adb255b4b3..0000000000 --- a/.storybook/pages/CoursePlannerModal/CoursePlannerModal.stories.tsx +++ /dev/null @@ -1,30 +0,0 @@ -import type { StoryObj } from '@storybook/react'; -import React from 'react'; - -import { ModalBrand } from './ModalBrand'; -import { ModalFinalStep } from './ModalFinalStep'; -import { ModalFirstStep } from './ModalFirstStep'; - -export default { - title: 'Pages/Course Planner/Modal', - parameters: { - axe: { - /** - * Axe testing is flaky here, but is tested across the component modal stories and would be testing Headless Dialog functionality anyways. - */ - disabledRules: ['aria-dialog-name'], - }, - }, -}; - -export const FirstStep: StoryObj = { - render: () => , -}; - -export const Brand: StoryObj = { - render: () => , -}; - -export const FinalStep: StoryObj = { - render: () => , -}; diff --git a/.storybook/pages/CoursePlannerModal/ModalBrand.tsx b/.storybook/pages/CoursePlannerModal/ModalBrand.tsx deleted file mode 100644 index c5fc4ac369..0000000000 --- a/.storybook/pages/CoursePlannerModal/ModalBrand.tsx +++ /dev/null @@ -1,24 +0,0 @@ -import React from 'react'; - -import { Button, Modal, Heading, Text } from '../../../src'; - -import CompassSolo from '../../static/compass-solo.svg'; - -export const ModalBrand = () => ( - {}} open variant="brand"> - }> - Check out the new course planner - - - - Intro header copy - - Content pieces go here - - - - - -); diff --git a/.storybook/pages/CoursePlannerModal/ModalFinalStep.tsx b/.storybook/pages/CoursePlannerModal/ModalFinalStep.tsx deleted file mode 100644 index 2a24271796..0000000000 --- a/.storybook/pages/CoursePlannerModal/ModalFinalStep.tsx +++ /dev/null @@ -1,27 +0,0 @@ -import React from 'react'; - -import { Button, Modal, Text } from '../../../src'; - -import CadSuccess from '../../static/cad-success.svg'; - -export const ModalFinalStep = () => ( - {}} open> - -
- a checkmark -
- Simple image and headline -
- - Supporting copy goes here - - - - -
-); diff --git a/.storybook/pages/CoursePlannerModal/ModalFirstStep.tsx b/.storybook/pages/CoursePlannerModal/ModalFirstStep.tsx deleted file mode 100644 index e76f1e6893..0000000000 --- a/.storybook/pages/CoursePlannerModal/ModalFirstStep.tsx +++ /dev/null @@ -1,73 +0,0 @@ -import React, { useState } from 'react'; - -import { - Button, - ButtonGroup, - Heading, - Icon, - Modal, - Radio, - Fieldset, -} from '../../../src'; - -export const ModalFirstStep = () => { - const [checked, setChecked] = useState([false, false, false]); - const handleChange = (index: number) => { - const newChecked = [false, false, false]; - newChecked[index] = true; - setChecked(newChecked); - }; - return ( - {}} open> - - - Before we start, tell us your planning needs - - - We’ll need to know how to set up your plan. Can you tell us how you’ll - use the planner? - - - -
- - - handleChange(0)} - value="radio1" - /> - handleChange(1)} - value="radio2" - /> - handleChange(2)} - value="radio3" - /> - -
-
- - - - - - - -
- ); -}; diff --git a/.storybook/pages/CoursePlannerStep1/CoursePlannerStep1.module.css b/.storybook/pages/CoursePlannerStep1/CoursePlannerStep1.module.css deleted file mode 100644 index 236c1fd2a3..0000000000 --- a/.storybook/pages/CoursePlannerStep1/CoursePlannerStep1.module.css +++ /dev/null @@ -1,13 +0,0 @@ -@import '../../../../edu-design-system/src/design-tokens/mixins.css'; - -/*------------------------------------*\ - # TYPOGRAPHY USAGE UTILITY CLASS -\*------------------------------------*/ - -/** - * Utility classes to apply typography usage mixins to elements for Course Planner Step module - */ - -.course-planner-step1__text{ - font: var(--eds-typography-preset-004); - } \ No newline at end of file diff --git a/.storybook/pages/CoursePlannerStep1/CoursePlannerStep1.stories.ts b/.storybook/pages/CoursePlannerStep1/CoursePlannerStep1.stories.ts deleted file mode 100644 index 188bc6563e..0000000000 --- a/.storybook/pages/CoursePlannerStep1/CoursePlannerStep1.stories.ts +++ /dev/null @@ -1,13 +0,0 @@ -import type { StoryObj } from '@storybook/react'; -import type { ComponentProps } from 'react'; - -import { CoursePlannerStep1 } from './CoursePlannerStep1'; - -export default { - title: 'Pages/Course Planner/Step 1', - component: CoursePlannerStep1, -}; - -type Args = ComponentProps; - -export const Default: StoryObj = {}; diff --git a/.storybook/pages/CoursePlannerStep1/CoursePlannerStep1.tsx b/.storybook/pages/CoursePlannerStep1/CoursePlannerStep1.tsx deleted file mode 100644 index 4f9ebf0d2b..0000000000 --- a/.storybook/pages/CoursePlannerStep1/CoursePlannerStep1.tsx +++ /dev/null @@ -1,105 +0,0 @@ -import clsx from 'clsx'; -import React from 'react'; - -import { - Button, - ButtonGroup, - Grid, - Heading, - HorizontalStepper, - Icon, - InputField, - Layout, - LayoutContainer, - LayoutSection, - PageHeader, - Panel, - Text, -} from '../../../src'; - -import CompassCenter from '../../static/compass-center.svg'; -import styles from './CoursePlannerStep1.module.css'; - -export const CoursePlannerStep1 = () => { - const textClassName = clsx(styles['course-planner-step1__text'], '!mb-2'); - return ( - <> - - - - } - headingSize="title-md" - orientation="2up" - right={ - - - - - } - title="Course Planner: History 6" - /> - - - - - - - compass vignette - - Let's start planning, Amy Frankle. - - - - The course planner can help you set off on the right track, and - navigate whatever comes your way. - - - -
- - Tell us how often your course meets. - - - We’ll adjust project plans based on your schedule. This way, you - can get a more accurate estimate of how long the course will - actually take. - - - If you teach multiple sections of this course, you can enter the - average amounts for each question below. - -
- - How many times per week do you have class? - - - - How many minutes is each class? - - -
-
-
- - ); -}; diff --git a/.storybook/pages/FeedbackOverview/FeedbackOverview.module.css b/.storybook/pages/FeedbackOverview/FeedbackOverview.module.css deleted file mode 100644 index 133f69f59d..0000000000 --- a/.storybook/pages/FeedbackOverview/FeedbackOverview.module.css +++ /dev/null @@ -1,6 +0,0 @@ -@import '../../../src/design-tokens/mixins.css'; - -.feedback-overview__card-header { - margin-bottom: var(--eds-size-1); - font: var(--eds-theme-typography-title-md); -} diff --git a/.storybook/pages/FeedbackOverview/FeedbackOverview.stories.ts b/.storybook/pages/FeedbackOverview/FeedbackOverview.stories.ts deleted file mode 100644 index de41f4d741..0000000000 --- a/.storybook/pages/FeedbackOverview/FeedbackOverview.stories.ts +++ /dev/null @@ -1,39 +0,0 @@ -import type { StoryObj } from '@storybook/react'; -import type { ComponentProps } from 'react'; - -import { FeedbackOverview } from './FeedbackOverview'; -import { chromaticViewports } from '../../../src/util/viewports'; - -export default { - title: 'Pages/Projects/Feedback', - component: FeedbackOverview, -}; - -type Args = ComponentProps; - -export const Overview: StoryObj = { - parameters: { - chromatic: { - viewports: [ - chromaticViewports.googlePixel2, - chromaticViewports.ipadMini, - chromaticViewports.chromebook, - ], - }, - }, -}; - -export const Checkpoint: StoryObj = { - args: { - activeIndex: 1, - }, - parameters: { - chromatic: { - viewports: [ - chromaticViewports.googlePixel2, - chromaticViewports.ipadMini, - chromaticViewports.chromebook, - ], - }, - }, -}; diff --git a/.storybook/pages/FeedbackOverview/FeedbackOverview.tsx b/.storybook/pages/FeedbackOverview/FeedbackOverview.tsx deleted file mode 100644 index 046e8a223d..0000000000 --- a/.storybook/pages/FeedbackOverview/FeedbackOverview.tsx +++ /dev/null @@ -1,572 +0,0 @@ -import { debounce } from 'lodash'; -import React, { useEffect, useState } from 'react'; -import { - Button, - Breadcrumbs, - Card, - Heading, - Icon, - NumberIcon, - PageHeader, - Panel, - Tab, - Tabs, - Table, - Text, - TimelineNav, -} from '../../../src'; - -import breakpoint from '../../../src/design-tokens/tier-1-definitions/breakpoints'; - -import { - EdsThemeColorIconNeutralSubtle, - EdsThemeColorIconBrandPrimary, -} from '../../../src/tokens-dist/ts/colors'; -import NumberIconList from '../../recipes/NumberIconList'; -import { PageShell } from '../../recipes/PageShell/PageShell'; -import styles from './FeedbackOverview.module.css'; - -export interface Props { - /** - * Active index of the table to switch between stories - */ - activeIndex?: number; -} - -export const FeedbackOverview = ({ activeIndex = 0 }: Props) => { - const [isTable, setIsTable] = useState(false); - /** - * Display data as cards if mobile, table if not. - */ - const tableBreakpoint = parseInt(breakpoint['eds-bp-md'], 10) * 16; - const updateScreenSize = debounce( - () => { - if (window.innerWidth >= tableBreakpoint && !isTable) { - setIsTable(true); - } - if (window.innerWidth < tableBreakpoint && isTable) { - setIsTable(false); - } - }, - 200, - { leading: true }, - ); - useEffect(() => { - updateScreenSize(); - window.addEventListener('resize', updateScreenSize); - return () => { - window.removeEventListener('resize', updateScreenSize); - }; - }, [updateScreenSize]); - - const studentCheckpoints = [ - { - student: 'Araya, Raquel', - checkpoints: 10, - }, - { - student: 'Jesse Banet', - checkpoints: 5, - }, - { - student: 'Julie Davis', - checkpoints: 10, - }, - { - student: 'Hussain, Adnan', - checkpoints: 10, - }, - { - student: 'Ilango, Megha', - checkpoints: 10, - }, - { - student: 'Jaffer, Arman', - checkpoints: 10, - }, - { - student: 'Kang, Michelle', - checkpoints: 10, - }, - { - student: 'Lewine, Chris', - checkpoints: 10, - }, - { - student: 'Luo, Celia', - checkpoints: 10, - }, - ]; - - const feedbackOverviews = studentCheckpoints.map( - ({ student, checkpoints }) => { - const status = Array(checkpoints).fill( -
, - ); - return { - student, - checkpointsStatus: status, - }; - }, - ); - - const checkpointProgresses = [ - { - student: 'Araya, Raquel', - status: 'Stop and Revise', - cogSkill: 3, - timeSubmitted: '2 hours ago', - }, - { - student: 'Jesse Banet', - status: 'Stop and Revise', - cogSkill: 1, - timeSubmitted: '3 days ago', - }, - { - student: 'Julie Davis', - status: 'Working', - cogSkill: 0, - timeSubmitted: '3 days ago', - }, - { - student: 'Hussain, Adnan', - status: 'Review Feedback', - cogSkill: 0, - timeSubmitted: '3 days ago', - }, - { - student: 'Ilango, Megha', - status: 'Needs Feedback', - cogSkill: 3, - timeSubmitted: '3 days ago', - }, - { - student: 'Jaffer, Arman', - status: 'Needs Feedback', - cogSkill: 1, - timeSubmitted: '3 days ago', - }, - { - student: 'Kang, Michelle', - status: 'Review Feedback', - cogSkill: 1, - timeSubmitted: '3 days ago', - }, - { - student: 'Lewine, Chris', - status: 'Continue Working', - cogSkill: 2, - timeSubmitted: '3 days ago', - }, - { - student: 'Luo, Celia', - status: 'Review Feedback', - cogSkill: 1, - timeSubmitted: '3 days ago', - }, - ]; - - return ( - - - - - - -
More options
- - - } - title="Page title as Headline" - /> - - - -
Overview
-
- -
Learners
-
- -
Plans
-
- - - -
- - Feedback Overview - -
- -
-
- {isTable && ( - - - - Student - Checkpoints Status - Final Product - - - - - - - - - - - - - - - - - - - - - - {feedbackOverviews.map((overview) => ( - - {overview.student} - - {overview.checkpointsStatus} - - - - - - - - ))} - -
- )} - {!isTable && - feedbackOverviews.map((overview) => ( - - - {overview.student} - - -
- - Checkpoint Status - -
- {overview.checkpointsStatus} -
-
-
- - Final product - -
- - - -
-
-
-
- ))} -
- - - } - variant="number" - > -
- - Checkpoint Progress - -
- -
-
- {isTable && ( - - - - Students - Status - Cog skill - Time submitted - - - - {checkpointProgresses.map((progress) => ( - - {progress.student} - {progress.status} - {progress.cogSkill} - {progress.timeSubmitted} - - ))} - -
- )} - {!isTable && - checkpointProgresses.map((progress) => ( - - - {progress.student} - - -
- - Status - - - {progress.status} - -
-
- - Cog skill - - - {progress.cogSkill} - -
-
- - Time submitted - - - {progress.timeSubmitted} - -
-
-
- ))} -
- - -
- - Research and Model Cells - - - Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed - do eiusmod tempor incididunt ut labore et dolore magna - aliqua. Ut enim ad minim veniam, quis nostrud exercitation - ullamco laboris nisi ut aliquip ex - -
-
- -
- - Research and Model Body Systems - - - Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed - do eiusmod tempor incididunt ut labore et dolore magna - aliqua. Ut enim ad minim veniam, quis nostrud exercitation - ullamco laboris nisi ut aliquip ex - -
-
- -
- - Draft Your Book - - - Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed - do eiusmod tempor incididunt ut labore et dolore magna - aliqua. Ut enim ad minim veniam, quis nostrud exercitation - ullamco laboris nisi ut aliquip ex - -
-
- -
- - Critique a Peer's Book - - - Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed - do eiusmod tempor incididunt ut labore et dolore magna - aliqua. Ut enim ad minim veniam, quis nostrud exercitation - ullamco laboris nisi ut aliquip ex - -
-
- -
- - Human Body Book - - - Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed - do eiusmod tempor incididunt ut labore et dolore magna - aliqua. Ut enim ad minim veniam, quis nostrud exercitation - ullamco laboris nisi ut aliquip ex - -
-
- -
- - Book Review - - - Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed - do eiusmod tempor incididunt ut labore et dolore magna - aliqua. Ut enim ad minim veniam, quis nostrud exercitation - ullamco laboris nisi ut aliquip ex - -
-
-
-
-
-
-
- ); -}; diff --git a/.storybook/pages/ProjectOverview/ProjectOverview.module.css b/.storybook/pages/ProjectOverview/ProjectOverview.module.css deleted file mode 100644 index ff579f954e..0000000000 --- a/.storybook/pages/ProjectOverview/ProjectOverview.module.css +++ /dev/null @@ -1,12 +0,0 @@ -@import '../../../../edu-design-system/src/design-tokens/mixins.css'; - -/** - * Utility classes to apply typography usage mixins to Project Overview in body text xs bold - */ -.project-overview__text { - font: var(--eds-theme-typography-body-xs); -} - -.project-overview__link-description { - @apply mt-2; -} diff --git a/.storybook/pages/ProjectOverview/ProjectOverview.stories.ts b/.storybook/pages/ProjectOverview/ProjectOverview.stories.ts deleted file mode 100644 index 7e1eaedc1b..0000000000 --- a/.storybook/pages/ProjectOverview/ProjectOverview.stories.ts +++ /dev/null @@ -1,19 +0,0 @@ -import type { StoryObj } from '@storybook/react'; -import type { ComponentProps } from 'react'; - -import { ProjectOverview } from './ProjectOverview'; - -export default { - title: 'Pages/Projects/Project', - component: ProjectOverview, -}; - -type Args = ComponentProps; - -export const StudentView: StoryObj = {}; - -export const ProjectCheckpoint: StoryObj = { - args: { - activeIndex: 1, - }, -}; diff --git a/.storybook/pages/ProjectOverview/ProjectOverview.tsx b/.storybook/pages/ProjectOverview/ProjectOverview.tsx deleted file mode 100644 index 33414e5924..0000000000 --- a/.storybook/pages/ProjectOverview/ProjectOverview.tsx +++ /dev/null @@ -1,398 +0,0 @@ -import React from 'react'; - -import { - Breadcrumbs, - Button, - Card, - Grid, - Heading, - Hr, - Icon, - Link, - PageHeader, - Section, - Text, - TimelineNav, -} from '../../../src'; -// Project Overview pilot components -- not yet exported from src/index.ts -import ButtonActionCalloutCard from '../../recipes/ButtonActionCalloutCard'; - -import { PageShell } from '../../recipes/PageShell/PageShell'; -import styles from './ProjectOverview.module.css'; - -export interface Props { - /** - * Passed down to initially set the activeIndex state - */ - activeIndex?: number; -} - -export const ProjectOverview = ({ activeIndex = 0 }: Props) => { - return ( - - - - - - - View plan - - - } - title="Feudal Honor Codes and Values" - /> - - - - What is this Project About? - - - Consectetur adipiscing elit. Ac id velit ut egestas arcu. At - maecenas urna, risus donec praesent eu consectetur. Nunc non eu - mattis sem turpis id dictum. Volutpat ornare turpis ultrices augue - bibendum pellentesque. Habitasse. - - - - Essential Questions - -
-
    -
  • - How are structures in the body organized? -
  • -
  • - How do these structures work together to support life? But - really need to see what it looks like if we have an extra long - question. -
  • -
  • - How are structures in the body organized? -
  • -
-
- - Key Take Aways - -
-
    -
  1. - Groups of specialized cells make up organs and body systems, - which work together to support an organism’s survival. -
  2. -
  3. - How are structures in the body organized? More text blah blah - blah. -
  4. -
  5. - How are structures in the body organized? -
  6. -
-
-
- -
FPO Brand asset
-
- - - } - > - - - - What Was Medieval Japan Like? - - - In this Focus Area, you explore the main question: How does - the structures of organisms enable life’s functions? - - - - - - - What Was Medieval Japan Like? - - - In this Focus Area, you explore the main question: How does - the structures of organisms enable life’s functions? - - - - - - - What Was Medieval Japan Like? - - - In this Focus Area, you explore the main question: How does - the structures of organisms enable life’s functions? - - - -
-
- - - - What Was Medieval Japan Like? - - - In this Focus Area, you explore the main question: How does - the structures of organisms enable life’s functions? - - - - - - - What Was Medieval Japan Like? - - - In this Focus Area, you explore the main question: How does - the structures of organisms enable life’s functions? - - - -
-
- - -
- Estimated schedule: Days 4,5,6 - - } - overline={Overline above title} - title="Expectations of Samuri in Feudal Japan" - > - - What to Focus on this Checkpoint - - - Students individually develop a follow up question that builds - from their group’s experiment and describe their follow up - question in their conclusion. Students craft evidence-supported - explanations of how the body is organized and functions. - -
-
Term 1:
-
- Constructing and Evidence based Explanation -
-
- - - Students collaboratively develop a single group research question - to frame their shared experiment, then describe the group research - question in the introduction. - -
-
Term 1:
-
- Constructing and Evidence based Explanation -
-
- - Preview} - className="!mb-8" - title="Do This Checkpoint" - > - Develop the text of your Body Book, crafting evidence-supported - explanations on how the body is organized and its functions. - - -
- - - Resources for You - - - - - This is a link - - This is a stacked block description - - - - This is a link - - This is a stacked block description - - - - This is a link - - This is a stacked block description - - - - This is a link - - This is a stacked block description - - - - - - Resources for You - - - - - This is a link - - This is a stacked block description - - - - This is a link - - This is a stacked block description - - - - This is a link - - This is a stacked block description - - - - This is a link - - This is a stacked block description - - - -
-
-
- - -
- Estimated schedule: Days 4,5,6 - - } - overline={Checkpoint 2} - title="Expectations of Samuri in Feudal Japan" - > - - Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut - enim ad minim veniam, quis nostrud exercitation ullamco laboris - nisi ut aliquip ex - -
-
- -
- Estimated schedule: Days 4,5,6 - - } - overline={Checkpoint 3} - title="Expectations of Samuri in Feudal Japan" - > - - Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut - enim ad minim veniam, quis nostrud exercitation ullamco laboris - nisi ut aliquip ex - -
-
- -
- Estimated schedule: Days 4,5,6 - - } - overline={Checkpoint 4} - title="Expectations of Samuri in Feudal Japan" - > - - Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut - enim ad minim veniam, quis nostrud exercitation ullamco laboris - nisi ut aliquip ex - -
-
-
-
- ); -}; diff --git a/.storybook/pages/StudentRefinement/StudentRefinement.module.css b/.storybook/pages/StudentRefinement/StudentRefinement.module.css deleted file mode 100644 index 97f4189572..0000000000 --- a/.storybook/pages/StudentRefinement/StudentRefinement.module.css +++ /dev/null @@ -1,154 +0,0 @@ -@import '../../../src/design-tokens/mixins.css'; - -.student-refinement__summary-cards { - display: flex; - gap: var(--eds-size-2); - margin-bottom: 2.875rem; - flex-wrap: wrap; - justify-content: center; -} - -.student-refinement__summary-card.student-refinement__summary-card { - width: 11rem; - flex-shrink: 0; -} - -@media all and (min-width: $eds-bp-xl) { - .student-refinement__table-control-button-group { - justify-content: flex-end; - } -} - -.student-refinement__header-row { - border-top: var(--eds-theme-border-width) solid - var(--eds-theme-color-border-neutral-strong); -} - -.student-refinement__name-cell { - display: grid; - grid-template-columns: 7rem auto; - align-items: center; -} - -/** - * Shifts score left to align with scores without grades. - */ -.student-refinement__cell--inset-left::after { - display: inline-block; - content: ''; - width: var(--eds-size-2-and-half); -} - -/*------------------------------------*\ - # DATA SUMMARY CARD -\*------------------------------------*/ - -/** - * Data Summary Card centers and wraps header, data, and footnote. - */ -.data-summary-card { - width: 12.75rem; - height: 9.25rem; - position: relative; - overflow: hidden; - - border: 0; - box-shadow: var(--eds-box-shadow-sm); - - align-items: center; -} -.data-summary-card:hover { - border: var(--eds-border-width-sm) solid - var(--eds-theme-color-border-neutral-default); -} - -/** - * The header wraps the title. - */ -.data-summary-card__header { - margin-top: var(--eds-size-2); - margin-bottom: var(--eds-size-half); -} - -/** - * Prevents jitter of the card components when hovering due to border spawning. - * Transparent border can't be used due to off-track variant indicator needing full width. - */ -.data-summary-card:hover > .data-summary-card__header { - margin-top: calc(var(--eds-size-2) - var(--eds-border-width-sm)); -} - -/** - * The title communicates card organization. - */ -.data-summary-card__title { - font: var(--eds-theme-typography-overline-sm); - text-transform: uppercase; -} - -/** - * The body wraps data and description text. - */ -.data-summary-card__body { - display: flex; - flex-direction: column; - align-items: center; -} - -/** - * The data is the main content for the card. - */ -.data-summary-card__data { - font: var(--eds-theme-typography-headline-lg); - - @media all and (max-width: $eds-bp-md) { - font: var(--eds-typography-preset-001-mobile); - } - - display: flex; - align-items: center; - gap: var(--eds-size-half); - - margin-bottom: var(--eds-size-half); -} - -/** - * The data unit provides a unit of measurement for the data to make it relevant. - */ -.data-summary-card__data-unit { - font: var(--eds-theme-typography-headline-sm); - - @media all and (max-width: $eds-bp-md) { - font: var(--eds-typography-preset-003-mobile); - } -} - -/** - * The Description provides more elucidation for the data. - */ -.data-summary-card__description { - font: var(--eds-theme-typography-caption-sm); - font-weight: var(--eds-font-weight-light); -} - -/** - * Off track variant, bottom orange border indicates off track status. - */ -.data-summary-card__indicator--off-track { - width: 100%; - height: 8px; - - position: absolute; - bottom: 0; - left: 0; - - background-color: var(--eds-theme-color-icon-utility-warning); -} - -/** - * Prevents jitter of the card components when hovering due to border spawning. - * Transparent border can't be used due to off-track variant indicator needing full width. - */ -.data-summary-card:hover > .data-summary-card__indicator--off-track { - height: 7px; -} diff --git a/.storybook/pages/StudentRefinement/StudentRefinement.stories.ts b/.storybook/pages/StudentRefinement/StudentRefinement.stories.ts deleted file mode 100644 index d63094c438..0000000000 --- a/.storybook/pages/StudentRefinement/StudentRefinement.stories.ts +++ /dev/null @@ -1,23 +0,0 @@ -import type { StoryObj, Meta } from '@storybook/react'; - -import { StudentRefinement } from './StudentRefinement'; -import { chromaticViewports } from '../../../src/util/viewports'; - -export default { - title: 'Pages/SDT/StudentRefinement', - component: StudentRefinement, -} as Meta; - -type Args = React.ComponentProps; - -export const Default: StoryObj = { - parameters: { - chromatic: { - viewports: [ - chromaticViewports.googlePixel2, - chromaticViewports.ipadMini, - chromaticViewports.chromebook, - ], - }, - }, -}; diff --git a/.storybook/pages/StudentRefinement/StudentRefinement.tsx b/.storybook/pages/StudentRefinement/StudentRefinement.tsx deleted file mode 100644 index e0c7044dd4..0000000000 --- a/.storybook/pages/StudentRefinement/StudentRefinement.tsx +++ /dev/null @@ -1,624 +0,0 @@ -import clsx from 'clsx'; -import { debounce } from 'lodash'; -import React, { useEffect, useState } from 'react'; - -import { - Breadcrumbs, - Button, - ButtonGroup, - Card, - Checkbox, - FiltersCheckboxField, - FiltersDrawer, - Heading, - Icon, - Layout, - PageHeader, - Panel, - SearchBar, - Score, - Tab, - Tabs, - Table, - Tag, - Text, -} from '../../../src'; -import type { HeadingElement } from '../../../src/components/Heading'; - -import breakpoint from '../../../src/design-tokens/tier-1-definitions/breakpoints'; - -import { EdsThemeColorIconUtilityWarning } from '../../../src/tokens-dist/ts/colors'; - -import { PageShell } from '../../recipes/PageShell/PageShell'; -import styles from './StudentRefinement.module.css'; - -interface DataSummaryProps { - /** - * CSS class names that can be appended to the component. - */ - className?: string; - /** - * Main data text of the card. - */ - dataAmount: string; - /** - * Text that provides a unit of measurement for the data. - */ - dataUnit?: string; - /** - * Text to provide more context for the data. - */ - description?: string; - /** - * Specifies the heading element to render the card heading as. - */ - headingElement?: HeadingElement; - /** - * Title text of the data represented. - */ - title: string; - /** - * Off track variant to indicate status. - */ - variant?: 'off-track'; -} - -const DataSummaryCard = ({ - className, - dataAmount, - dataUnit, - description, - headingElement, - title, - variant, - ...other -}: DataSummaryProps) => { - const componentClassName = clsx(styles['data-summary-card'], className); - return ( - - - - {title} - - - - - {dataAmount} - {dataUnit && ( - - {dataUnit} - - )} - - {description && ( - - {description} - - )} - - {variant === 'off-track' && ( -
- )} - - ); -}; - -export const StudentRefinement = () => { - const [isTable, setIsTable] = useState(false); - /** - * Display data as cards if mobile, table if not. - */ - const tableBreakpoint = parseInt(breakpoint['eds-bp-md'], 10) * 16; - const updateScreenSize = debounce( - () => { - if (window.innerWidth >= tableBreakpoint && !isTable) { - setIsTable(true); - } - if (window.innerWidth < tableBreakpoint && isTable) { - setIsTable(false); - } - }, - 200, - { leading: true }, - ); - useEffect(() => { - updateScreenSize(); - window.addEventListener('resize', updateScreenSize); - return () => { - window.removeEventListener('resize', updateScreenSize); - }; - }, [updateScreenSize]); - - const students = [ - { - name: 'Caroline Garcia', - offTrack: true, - grade: { - offTrack: true, - score: '53%', - }, - cogSkillAvg: { - offTrack: true, - score: '30%', - }, - projects: { - score: 3, - }, - powerFocusAreas: { - score: 8, - }, - }, - { - name: 'Anthony Smith', - grade: { - grade: 'A', - score: '93%', - }, - cogSkillAvg: { - score: '84%', - }, - projects: { - offTrack: true, - score: 2, - }, - powerFocusAreas: { - score: 4, - }, - }, - { - name: 'Sai Kumar', - grade: { - grade: 'B-', - score: '81%', - }, - cogSkillAvg: { - score: '78%', - }, - projects: { - offTrack: true, - score: 1, - }, - powerFocusAreas: { - score: 7, - }, - }, - { - name: 'Rachel Campbell', - grade: { - offTrack: true, - score: '68%', - }, - cogSkillAvg: { - score: '73%', - }, - projects: { - score: 3, - }, - powerFocusAreas: { - score: 5, - }, - }, - { - name: 'Emily Tran', - offTrack: true, - grade: { - offTrack: true, - score: '30%', - }, - cogSkillAvg: { - score: '100%', - }, - projects: { - offTrack: true, - score: 2, - }, - powerFocusAreas: { - offTrack: true, - score: 3, - }, - }, - { - name: 'Wei Zhang', - grade: { - grade: 'C', - score: '73%', - }, - cogSkillAvg: { - score: '75%', - }, - projects: { - score: 3, - }, - powerFocusAreas: { - score: 6, - }, - }, - ]; - const studentsTable = ( - - - - Students (32) - Grade - - Cog Skill Avg - - Projects - - Power Focus Areas - - - - - {students.map((student) => ( - - - - {student.name} - - {student.offTrack && ( - - )} - - - {student.grade.offTrack && ( - - )} - {student.grade.grade && ( - - {student.grade.grade} - - )} - - - - {student.cogSkillAvg.offTrack && ( - - )} - - - - {student.projects.offTrack && ( - - )} - - - - {student.powerFocusAreas.offTrack && ( - - )} - - - - ))} - -
- ); - const studentsCards = ( -
- {students.map((student) => ( - - - - {student.name} - - {student.offTrack && ( - - )} - - -
- - Grade - -
- {student.grade.offTrack && ( - - )} - {student.grade.grade && ( - - {student.grade.grade} - - )} - -
-
-
- - Cog Skill Avg - -
- {student.cogSkillAvg.offTrack && ( - - )} - -
-
-
- - Project - -
- {student.projects.offTrack && ( - - )} - -
-
-
- - Power Focus Area - -
- {student.powerFocusAreas.offTrack && ( - - )} - -
-
-
-
- ))} -
- ); - return ( - - - - -
- - -
- - - -
Overview
-
- -
-
- - - - - -
- - - - - - - -
Toggle Switch FPO
- - - - - - - - - - - - - - - - - - - - - -
- -
-
- {isTable && studentsTable} - {!isTable && studentsCards} -
-
- -
Assessments
-
- -
Goals
-
-
-
-
- ); -}; diff --git a/.storybook/recipes/CalendarCard/CalendarCard.module.css b/.storybook/recipes/CalendarCard/CalendarCard.module.css deleted file mode 100644 index 55c0411265..0000000000 --- a/.storybook/recipes/CalendarCard/CalendarCard.module.css +++ /dev/null @@ -1,98 +0,0 @@ -@import '../../../src/design-tokens/mixins.css'; - -/*------------------------------------*\ - # CALENDAR CARD -\*------------------------------------*/ - -/** - * Card recipe for displaying calendar data with a colored left border (color dependent on variant) - */ -.calendar-card { - background-color: var(--eds-theme-color-background-neutral-default-hover); -} -/** - * Brand variant (default): brand colored left border - */ -.calendar-card--brand { - border-left: var(--eds-border-width-lg) solid - var(--eds-theme-color-border-brand-primary-strong); -} - -/** - * Revise variant - */ -.calendar-card--revise { - border-left: var(--eds-border-width-lg) solid - var(--eds-theme-color-border-grade-revise-strong); -} - -/** - * Success variant - */ -.calendar-card--success { - border-left: var(--eds-border-width-lg) solid - var(--eds-theme-color-border-utility-success-strong); -} - -/** - * Stack the card's contents in a flex column. - */ -.calendar-card__body { - display: flex; - flex-direction: column; - justify-content: space-between; - gap: var(--eds-size-1); -} - -/** - * Card title row which holds an optional icon and a text string. - */ -.calendar-card__title { - display: flex; - align-items: flex-start; - /** - * Keeps the icon positioned at the top of the cross-axis if the text string expands to use multiple lines. - */ - justify-content: flex-start; - /** - * If icon is used, the gap setting will maintain spacing between icon and text. - */ - gap: var(--eds-size-1); -} - -/** - * Span to hold optional icon. - */ -.calendar-card__title-icon { - min-width: 1.2rem; -} - -/** - * Card calendar row which holds an icon and a combination of text strings. - * - * Keeps the icon positioned at the top of the cross-axis if the text strings expands to use multiple lines. - * - * The gap setting will maintain spacing between icon and text. - */ -.calendar-card__dates { - display: flex; - align-items: flex-start; - justify-content: flex-start; - gap: var(--eds-size-1); -} - -/* - * Span to hold icon before calendar text - */ -.calendar-card__dates-icon { - min-width: 1.2rem; -} - -/* - * Keeps tags evenly spaced in rows, wrapping when needed - */ -.calendar-card__tags { - display: flex; - flex-wrap: wrap; - gap: var(--eds-size-1); -} diff --git a/.storybook/recipes/CalendarCard/CalendarCard.stories.tsx b/.storybook/recipes/CalendarCard/CalendarCard.stories.tsx deleted file mode 100644 index afbe146a85..0000000000 --- a/.storybook/recipes/CalendarCard/CalendarCard.stories.tsx +++ /dev/null @@ -1,82 +0,0 @@ -import type { StoryObj, Meta } from '@storybook/react'; -import React from 'react'; -import { CalendarCard } from './CalendarCard'; - -export default { - title: 'Recipes/CalendarCard', - component: CalendarCard, - decorators: [(Story) =>
{Story()}
], -} as Meta; - -type Args = React.ComponentProps; - -export const Default: StoryObj = { - args: { - dateEnd: 'Feb 2, 2022', - dateStart: 'Apr 1', - title: 'Project name here', - }, -}; - -export const ExtraMetadata: StoryObj = { - args: { - dateEnd: 'Feb 2, 2022', - dateStart: 'Apr 1', - meta: '(12 days)', - title: 'Project name here', - }, -}; - -export const SingleTag: StoryObj = { - args: { - dateEnd: 'Feb 2, 2022', - dateStart: 'Apr 1', - tags: [{ text: 'Ancient Mayan History' }], - title: 'Project name here', - }, -}; - -export const LongerTextStrings: StoryObj = { - args: { - dateEnd: 'Feb 2, 2022', - dateStart: 'Apr 1', - meta: '(Wednesday and Thursday only until further notice)', - tags: [{ text: 'Ancient Mayan History' }], - title: 'Project name here with extra long title', - variant: 'revise', - }, -}; - -export const MultipleTags: StoryObj = { - args: { - dateEnd: 'Feb 2, 2022', - dateStart: 'Apr 1', - tags: [ - { text: 'Tag One' }, - { text: '2' }, - { text: 'Three' }, - { text: 'Tag with a longer text string' }, - ], - title: 'Project name here', - }, -}; - -export const ReviseVariant: StoryObj = { - args: { - dateEnd: 'Feb 2, 2022', - dateStart: 'Apr 1', - tags: [{ text: 'Ancient Mayan History' }], - title: 'Project name here', - variant: 'revise', - }, -}; - -export const SuccessVariant: StoryObj = { - args: { - dateEnd: 'Feb 2, 2022', - dateStart: 'Apr 1', - tags: [{ text: 'Ancient Mayan History' }], - title: 'Project name here', - variant: 'success', - }, -}; diff --git a/.storybook/recipes/CalendarCard/CalendarCard.tsx b/.storybook/recipes/CalendarCard/CalendarCard.tsx deleted file mode 100644 index 3ef4647249..0000000000 --- a/.storybook/recipes/CalendarCard/CalendarCard.tsx +++ /dev/null @@ -1,115 +0,0 @@ -import clsx from 'clsx'; -import type { ReactNode } from 'react'; -import React from 'react'; - -import { Card, Heading, Icon, Tag, Text } from '../../../src'; -import type { Variant as TagVariant } from '../../../src/components/Tag/Tag'; -import styles from './CalendarCard.module.css'; - -export const VARIANTS = ['brand', 'revise', 'success'] as const; - -export type Variant = (typeof VARIANTS)[number]; - -export interface Props { - /** - * CSS class names that can be appended to the component. - */ - className?: string; - /** - * Card sub components that are nested within the Card wrapper. - */ - children?: ReactNode; - /** - * End of date range - */ - dateEnd?: string; - /** - * Start of date range - */ - dateStart?: string; - /** - * Additional text for date range - */ - meta?: string; - /** - * Text for tag(s) - */ - tags?: TagType[]; - /** - * The title text - */ - title: string; - /** - * Notification variant for the card. - */ - variant?: Variant; -} - -interface TagType { - text: string; - variant?: TagVariant; - hasOutline?: boolean; -} - -/** - * Recipe for a Card component to represent an event within calendar UI. - */ -export const CalendarCard = ({ - children, - className, - dateEnd, - dateStart, - meta, - tags, - title, - variant = 'brand', - ...other -}: Props) => { - const componentClassName = clsx( - className, - styles['calendar-card'], - styles[`calendar-card--${variant}`], - ); - return ( - - - - {(variant === 'success' || variant === 'revise') && ( - - - - )} - {title} - - - - - - {dateStart} — {dateEnd} {meta} - -
- {tags?.map(({ hasOutline = true, text, variant = 'neutral' }) => ( - - ))} -
- {children} -
-
- ); -}; diff --git a/.storybook/recipes/CalendarCard/index.ts b/.storybook/recipes/CalendarCard/index.ts deleted file mode 100644 index a23c53d2bc..0000000000 --- a/.storybook/recipes/CalendarCard/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { CalendarCard as default } from './CalendarCard'; diff --git a/.storybook/recipes/CardWithNotification/CardWithNotification.stories.tsx b/.storybook/recipes/CardWithNotification/CardWithNotification.stories.tsx index 5e2b47bf44..563a131ee5 100644 --- a/.storybook/recipes/CardWithNotification/CardWithNotification.stories.tsx +++ b/.storybook/recipes/CardWithNotification/CardWithNotification.stories.tsx @@ -7,17 +7,7 @@ import { DataBar, Card } from '../../../src'; export default { title: 'Recipes/CardWithNotification', component: CardWithNotification, - decorators: [ - (Story) => ( -
- {Story()} -
- ), - ], + decorators: [(Story) =>
{Story()}
], argTypes: { children: { control: { diff --git a/.storybook/recipes/PageShell/PageShell.module.css b/.storybook/recipes/PageShell/PageShell.module.css deleted file mode 100644 index 1caaaae757..0000000000 --- a/.storybook/recipes/PageShell/PageShell.module.css +++ /dev/null @@ -1,41 +0,0 @@ -@import '../../../src/design-tokens/mixins.css'; - -/*------------------------------------*\ - # PAGE SHELL -\*------------------------------------*/ - -/** - * Primary shell around the entire page. - */ -.page-shell { - position: relative; -} - -/** - * Skip link – allows the user to skip past the main navigation to the page content. - */ -.page-shell__skip-link { - position: absolute; - top: 0; - left: 50%; - z-index: 9999; - transform: translateY(-100%); - transition: transform var(--eds-anim-fade-quick); - - &:focus { - transform: translateY(0%); - } - - @media screen and (prefers-reduced-motion) { - transition: none; - } -} - -.page-shell__main { - padding-bottom: var(--eds-size-8); - padding-top: var(--eds-size-4); - - @media all and (min-width: $eds-bp-xl) { - padding-top: var(--eds-size-6); - } -} diff --git a/.storybook/recipes/PageShell/PageShell.stories.ts b/.storybook/recipes/PageShell/PageShell.stories.ts deleted file mode 100644 index 6fc37cf5f4..0000000000 --- a/.storybook/recipes/PageShell/PageShell.stories.ts +++ /dev/null @@ -1,16 +0,0 @@ -import type { StoryObj, Meta } from '@storybook/react'; -import type { ComponentProps } from 'react'; - -import { PageShell } from './PageShell'; - -export default { - title: 'Recipes/PageShell', - component: PageShell, - args: { - children: 'Test', - }, -} as Meta; - -type Args = ComponentProps; - -export const Default: StoryObj = {}; diff --git a/.storybook/recipes/PageShell/PageShell.tsx b/.storybook/recipes/PageShell/PageShell.tsx deleted file mode 100644 index b651664b09..0000000000 --- a/.storybook/recipes/PageShell/PageShell.tsx +++ /dev/null @@ -1,85 +0,0 @@ -import clsx from 'clsx'; -import type { ReactNode } from 'react'; -import React from 'react'; -import { Link, Layout, LayoutContainer, LayoutSection } from '../../../src'; - -import styles from './PageShell.module.css'; - -export interface Props { - /** - * Child node(s) that can be nested inside component. - */ - children: ReactNode; - /** - * CSS class names that can be appended to the component. - */ - className?: string; - /** - * Search students primary nav item is active - */ - searchStudentsIsActive?: boolean; - /** - * Announcements primary nav item is active - */ - announcementsIsActive?: boolean; - /** - * Subject primary nav item is active - */ - subjectIsActive?: boolean; - /** - * Mentoring primary nav item is active - */ - mentoringIsActive?: boolean; - /** - * Student progress primary nav item is active - */ - studentProgressIsActive?: boolean; - /** - * Search students primary nav item is active - */ - educatorToolsIsActive?: boolean; - /** - * Search students primary nav item is active - */ - curriculumIsActive?: boolean; -} - -/** - * A general wrapper for pages, comes with a stub for a header component baked in. - */ -export const PageShell = ({ - children, - className, - searchStudentsIsActive, - announcementsIsActive, - subjectIsActive, - mentoringIsActive, - studentProgressIsActive, - educatorToolsIsActive, - curriculumIsActive, - ...other -}: Props) => { - const componentClassName = clsx(styles['page-shell'], className, {}); - return ( - - - Skip to content - - - -
Sidebar Goes Here
-
- -
- {children} -
-
-
- - ); -}; diff --git a/.storybook/recipes/PrimaryNav/PrimaryNav.module.css b/.storybook/recipes/PrimaryNav/PrimaryNav.module.css deleted file mode 100755 index 91f5a76c4a..0000000000 --- a/.storybook/recipes/PrimaryNav/PrimaryNav.module.css +++ /dev/null @@ -1,90 +0,0 @@ -@import '../../../src/design-tokens/mixins.css'; - -/*------------------------------------*\ - # PRIMARY NAVIGATION ITEM -\*------------------------------------*/ - -/** - * Primary nav link - * - * Individual link within each primary nav item. - */ -.primary-nav__link { - display: flex; - color: var(--eds-theme-color-text-neutral-default-inverse); - text-decoration: none; - white-space: nowrap; - padding: var(--eds-size-1); - border-radius: var(--eds-border-radius-md); - transition: background var(--eds-anim-fade-quick) var(--eds-anim-ease); - - &:hover, - &:focus-visible { - background: var(--eds-theme-color-button-primary-brand-background-hover); - } - - &:active { - background: var(--eds-theme-color-button-primary-brandbackground-active); - } - - &:focus-visible { - @mixin focusInverted; - } - - @supports not selector(:focus-visible) { - &:hover, - &:focus { - background: var(--eds-theme-color-button-primary-brand-background-hover); - } - - &:focus { - @mixin focusInverted; - } - } - @media screen and (prefers-reduced-motion) { - transition: none; - } -} - -/** - * Active primary nav link - */ -.primary-nav__link--active { - background: var(--eds-theme-color-button-primary-brand-background-active); -} - -/** - * Primary nav icon - */ -.primary-nav__icon { - margin-right: var(--eds-size-2-and-half); - color: var(--eds-theme-color-text-neutral-default-inverse); -} - -/*------------------------------------*\ - # PRIMARY NAVIGATION -\*------------------------------------*/ - -/** - * Primary navigation existing in the header and maybe the footer. - * - * The outer