refactor(island): move dialog to atoms, modal and sheet to molecules
Imports and the root index follow the new paths. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
605feabb40
commit
0bee35290d
|
|
@ -3,9 +3,9 @@
|
||||||
import { useEffect, useEffectEvent, useRef, useState } from 'react';
|
import { useEffect, useEffectEvent, useRef, useState } from 'react';
|
||||||
import type { MouseEvent, PointerEvent, SyntheticEvent } from 'react';
|
import type { MouseEvent, PointerEvent, SyntheticEvent } from 'react';
|
||||||
|
|
||||||
import { FlexBox } from '../../atoms/flex-box';
|
import { FlexBox } from '../flex-box';
|
||||||
import { cn } from '../../tools/cn';
|
import { cn } from '../../tools/cn';
|
||||||
import { Element } from '../element';
|
import { Element } from '../../primitives/element';
|
||||||
import {
|
import {
|
||||||
DIALOG_CLOSE_EVENT,
|
DIALOG_CLOSE_EVENT,
|
||||||
DIALOG_OPEN_EVENT,
|
DIALOG_OPEN_EVENT,
|
||||||
|
|
@ -16,6 +16,13 @@ export type {
|
||||||
CountdownProps,
|
CountdownProps,
|
||||||
CountdownTone,
|
CountdownTone,
|
||||||
} from './atoms/countdown';
|
} from './atoms/countdown';
|
||||||
|
export {
|
||||||
|
Dialog,
|
||||||
|
DIALOG_CLOSE_EVENT,
|
||||||
|
DIALOG_OPEN_EVENT,
|
||||||
|
DIALOG_PANEL_SELECTOR,
|
||||||
|
} from './atoms/dialog';
|
||||||
|
export type { DialogProps } from './atoms/dialog';
|
||||||
export { FlexBox } from './atoms/flex-box';
|
export { FlexBox } from './atoms/flex-box';
|
||||||
export type {
|
export type {
|
||||||
AlignContent,
|
AlignContent,
|
||||||
|
|
@ -94,6 +101,8 @@ export { LockedTeaser } from './molecules/locked-teaser';
|
||||||
export type { LockedTeaserProps } from './molecules/locked-teaser';
|
export type { LockedTeaserProps } from './molecules/locked-teaser';
|
||||||
export { MediaCarousel } from './molecules/media-carousel';
|
export { MediaCarousel } from './molecules/media-carousel';
|
||||||
export type { MediaCarouselProps, MediaItem } from './molecules/media-carousel';
|
export type { MediaCarouselProps, MediaItem } from './molecules/media-carousel';
|
||||||
|
export { Modal } from './molecules/modal';
|
||||||
|
export type { ModalProps } from './molecules/modal';
|
||||||
export {
|
export {
|
||||||
NetworkStatus,
|
NetworkStatus,
|
||||||
networkStatusVariants,
|
networkStatusVariants,
|
||||||
|
|
@ -110,6 +119,8 @@ export type {
|
||||||
ResendCodeProps,
|
ResendCodeProps,
|
||||||
ResendStatus,
|
ResendStatus,
|
||||||
} from './molecules/resend-code';
|
} from './molecules/resend-code';
|
||||||
|
export { Sheet } from './molecules/sheet';
|
||||||
|
export type { SheetPlacement, SheetProps } from './molecules/sheet';
|
||||||
export { StateMessage, stateMessageVariants } from './molecules/state-message';
|
export { StateMessage, stateMessageVariants } from './molecules/state-message';
|
||||||
export type {
|
export type {
|
||||||
StateMessageProps,
|
StateMessageProps,
|
||||||
|
|
@ -145,8 +156,6 @@ export type {
|
||||||
LightboxLabels,
|
LightboxLabels,
|
||||||
LightboxProps,
|
LightboxProps,
|
||||||
} from './organisms/lightbox';
|
} from './organisms/lightbox';
|
||||||
export { Modal } from './organisms/modal';
|
|
||||||
export type { ModalProps } from './organisms/modal';
|
|
||||||
export { PostCard } from './organisms/post-card';
|
export { PostCard } from './organisms/post-card';
|
||||||
export type {
|
export type {
|
||||||
PostAuthor,
|
PostAuthor,
|
||||||
|
|
@ -165,8 +174,6 @@ export type {
|
||||||
PredictionRangeValues,
|
PredictionRangeValues,
|
||||||
PredictionStatus,
|
PredictionStatus,
|
||||||
} from './organisms/prediction-card';
|
} from './organisms/prediction-card';
|
||||||
export { Sheet } from './organisms/sheet';
|
|
||||||
export type { SheetPlacement, SheetProps } from './organisms/sheet';
|
|
||||||
export { SkeletonPreset } from './organisms/skeleton-preset';
|
export { SkeletonPreset } from './organisms/skeleton-preset';
|
||||||
export type {
|
export type {
|
||||||
SkeletonPresetName,
|
SkeletonPresetName,
|
||||||
|
|
@ -190,13 +197,6 @@ export type {
|
||||||
TierOptionLabels,
|
TierOptionLabels,
|
||||||
TierOptionProps,
|
TierOptionProps,
|
||||||
} from './organisms/tier-option';
|
} from './organisms/tier-option';
|
||||||
export {
|
|
||||||
Dialog,
|
|
||||||
DIALOG_CLOSE_EVENT,
|
|
||||||
DIALOG_OPEN_EVENT,
|
|
||||||
DIALOG_PANEL_SELECTOR,
|
|
||||||
} from './primitives/dialog';
|
|
||||||
export type { DialogProps } from './primitives/dialog';
|
|
||||||
export { Element } from './primitives/element';
|
export { Element } from './primitives/element';
|
||||||
export type {
|
export type {
|
||||||
ElementProps,
|
ElementProps,
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ import { useId } from 'react';
|
||||||
import { Button } from '../../atoms/button';
|
import { Button } from '../../atoms/button';
|
||||||
import { FlexBox } from '../../atoms/flex-box';
|
import { FlexBox } from '../../atoms/flex-box';
|
||||||
import { Typography } from '../../atoms/typography';
|
import { Typography } from '../../atoms/typography';
|
||||||
import { Dialog } from '../../primitives/dialog';
|
import { Dialog } from '../../atoms/dialog';
|
||||||
import { Element } from '../../primitives/element';
|
import { Element } from '../../primitives/element';
|
||||||
import { cn } from '../../tools/cn';
|
import { cn } from '../../tools/cn';
|
||||||
import type { ModalProps } from './types';
|
import type { ModalProps } from './types';
|
||||||
|
|
@ -2,7 +2,7 @@ import { useId } from 'react';
|
||||||
|
|
||||||
import { FlexBox } from '../../atoms/flex-box';
|
import { FlexBox } from '../../atoms/flex-box';
|
||||||
import { Typography } from '../../atoms/typography';
|
import { Typography } from '../../atoms/typography';
|
||||||
import { Dialog } from '../../primitives/dialog';
|
import { Dialog } from '../../atoms/dialog';
|
||||||
import { Element } from '../../primitives/element';
|
import { Element } from '../../primitives/element';
|
||||||
import { cn } from '../../tools/cn';
|
import { cn } from '../../tools/cn';
|
||||||
import { SheetHead } from './components/SheetHead';
|
import { SheetHead } from './components/SheetHead';
|
||||||
|
|
@ -5,7 +5,7 @@ import type { CSSProperties } from 'react';
|
||||||
import { createPortal } from 'react-dom';
|
import { createPortal } from 'react-dom';
|
||||||
import { Toaster as SonnerToaster } from 'sonner';
|
import { Toaster as SonnerToaster } from 'sonner';
|
||||||
|
|
||||||
import { DIALOG_CLOSE_EVENT, DIALOG_OPEN_EVENT } from '../../primitives/dialog';
|
import { DIALOG_CLOSE_EVENT, DIALOG_OPEN_EVENT } from '../../atoms/dialog';
|
||||||
import type { ToasterProps } from './types';
|
import type { ToasterProps } from './types';
|
||||||
|
|
||||||
const noSubscription = () => () => {};
|
const noSubscription = () => () => {};
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ import type { KeyboardEvent, PointerEvent } from 'react';
|
||||||
import { FlexBox } from '../../atoms/flex-box';
|
import { FlexBox } from '../../atoms/flex-box';
|
||||||
import { GridBox } from '../../atoms/grid-box';
|
import { GridBox } from '../../atoms/grid-box';
|
||||||
import { Typography } from '../../atoms/typography';
|
import { Typography } from '../../atoms/typography';
|
||||||
import { Dialog } from '../../primitives/dialog';
|
import { Dialog } from '../../atoms/dialog';
|
||||||
import { Element } from '../../primitives/element';
|
import { Element } from '../../primitives/element';
|
||||||
import { cn } from '../../tools/cn';
|
import { cn } from '../../tools/cn';
|
||||||
import { LightboxButton } from './components/LightboxButton';
|
import { LightboxButton } from './components/LightboxButton';
|
||||||
|
|
|
||||||
|
|
@ -2,8 +2,8 @@ import { FlexBox } from '../../atoms/flex-box';
|
||||||
import { Icon } from '../../atoms/icon';
|
import { Icon } from '../../atoms/icon';
|
||||||
import { Link } from '../../atoms/link';
|
import { Link } from '../../atoms/link';
|
||||||
import { Typography } from '../../atoms/typography';
|
import { Typography } from '../../atoms/typography';
|
||||||
import { Modal } from '../modal';
|
import { Modal } from '../../molecules/modal';
|
||||||
import { Sheet } from '../sheet';
|
import { Sheet } from '../../molecules/sheet';
|
||||||
import { SupportRow } from './components/SupportRow';
|
import { SupportRow } from './components/SupportRow';
|
||||||
import type { SupportSheetProps } from './types';
|
import type { SupportSheetProps } from './types';
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue