@umami/react-zen 0.39.0 → 0.40.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.css CHANGED
@@ -2572,7 +2572,7 @@ body a.Button_button__N2NhN {
2572
2572
  }
2573
2573
 
2574
2574
  /* virtual-css:css:e93e399a7d084c43e7eb6d4a64b3f486 */
2575
- .Dialog_dialog__YjBmO {
2575
+ .Dialog_dialog__OTEwM {
2576
2576
  position: relative;
2577
2577
  padding: var(--spacing-6);
2578
2578
  box-shadow: var(--box-shadow-4);
@@ -2581,11 +2581,18 @@ body a.Button_button__N2NhN {
2581
2581
  border-radius: var(--border-radius);
2582
2582
  outline: none;
2583
2583
  }
2584
- .Dialog_title__MmNiZ {
2584
+ .Dialog_title__MTE4N {
2585
2585
  font-size: var(--font-size-4);
2586
2586
  font-weight: 700;
2587
2587
  margin-bottom: var(--spacing-3);
2588
2588
  }
2589
+ .Dialog_sheet__MWQ0Z {
2590
+ width: 100%;
2591
+ height: 100%;
2592
+ border-radius: 0;
2593
+ box-shadow: none;
2594
+ z-index: 9999;
2595
+ }
2589
2596
 
2590
2597
  /* virtual-css:css:e1347b3b22ddaaeb1276bb5bb9f2f2b8 */
2591
2598
  .AlertDialog_dialog__NDdlY {
@@ -3223,7 +3230,7 @@ body a.Button_button__N2NhN {
3223
3230
  }
3224
3231
 
3225
3232
  /* virtual-css:css:2e838e52dc8fe0aeb7a209b02dafe189 */
3226
- .Modal_overlay__NDQ5M {
3233
+ .Modal_overlay__MzYwN {
3227
3234
  position: fixed;
3228
3235
  top: 0;
3229
3236
  left: 0;
@@ -3233,20 +3240,85 @@ body a.Button_button__N2NhN {
3233
3240
  display: flex;
3234
3241
  align-items: center;
3235
3242
  justify-content: center;
3243
+ --modal-offset: 50%;
3236
3244
  }
3237
- .Modal_overlay__NDQ5M[data-entering] {
3238
- animation: Modal_modal-fade__ZWUyZ 200ms;
3245
+ .Modal_overlay__MzYwN[data-entering] {
3246
+ animation: Modal_modal-fade-in__MDBkZ 200ms;
3239
3247
  }
3240
- .Modal_overlay__NDQ5M[data-exiting] {
3241
- animation: Modal_modal-fade__ZWUyZ 150ms reverse ease-in;
3248
+ .Modal_overlay__MzYwN[data-exiting] {
3249
+ animation: Modal_modal-fade-in__MDBkZ 200ms reverse ease-in;
3242
3250
  }
3243
- .Modal_modal__ZmIxM {
3251
+ .Modal_modal__ZTRjZ {
3244
3252
  position: relative;
3253
+ z-index: 9999;
3254
+ }
3255
+ .Modal_modal__ZTRjZ.Modal_left__NWIxM {
3256
+ position: absolute;
3257
+ top: 0;
3258
+ left: 0;
3259
+ bottom: 0;
3260
+ margin: auto;
3261
+ width: calc(100dvw - var(--modal-offset, 0));
3262
+ }
3263
+ .Modal_modal__ZTRjZ.Modal_right__MGNkY {
3264
+ position: absolute;
3265
+ top: 0;
3266
+ right: 0;
3267
+ bottom: 0;
3268
+ margin: auto;
3269
+ width: calc(100dvw - var(--modal-offset, 0));
3270
+ }
3271
+ .Modal_modal__ZTRjZ.Modal_top__ZmViY {
3272
+ position: absolute;
3273
+ top: 0;
3274
+ left: 0;
3275
+ right: 0;
3276
+ margin: auto;
3277
+ height: calc(100dvh - var(--modal-offset, 0));
3278
+ }
3279
+ .Modal_modal__ZTRjZ.Modal_bottom__Zjg4M {
3280
+ position: absolute;
3281
+ left: 0;
3282
+ right: 0;
3283
+ bottom: 0;
3284
+ margin: auto;
3285
+ height: calc(100dvh - var(--modal-offset, 0));
3286
+ }
3287
+ .Modal_modal__ZTRjZ.Modal_fullscreen__NmZiM {
3288
+ width: 100dvw;
3289
+ height: 100dvh;
3290
+ }
3291
+ .Modal_modal__ZTRjZ.Modal_center__ZWFmO[data-entering] {
3292
+ animation: Modal_modal-zoom__MmU0M 300ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
3245
3293
  }
3246
- .Modal_modal__ZmIxM[data-entering] {
3247
- animation: Modal_modal-zoom__MDZmY 300ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
3294
+ .Modal_modal__ZTRjZ.Modal_left__NWIxM[data-entering] {
3295
+ animation: Modal_modal-left__MWY5M 200ms ease-out;
3248
3296
  }
3249
- @keyframes Modal_modal-fade__ZWUyZ {
3297
+ .Modal_modal__ZTRjZ.Modal_left__NWIxM[data-exiting] {
3298
+ animation: Modal_modal-left__MWY5M 200ms reverse ease-out;
3299
+ }
3300
+ .Modal_modal__ZTRjZ.Modal_right__MGNkY[data-entering] {
3301
+ animation: Modal_modal-right__OWVlM 200ms ease-out;
3302
+ }
3303
+ .Modal_modal__ZTRjZ.Modal_right__MGNkY[data-exiting] {
3304
+ animation: Modal_modal-right__OWVlM 200ms reverse ease-in;
3305
+ }
3306
+ .Modal_modal__ZTRjZ.Modal_top__ZmViY[data-entering] {
3307
+ animation: Modal_modal-top__NDc4M 200ms ease-out;
3308
+ }
3309
+ .Modal_modal__ZTRjZ.Modal_top__ZmViY[data-exiting] {
3310
+ animation: Modal_modal-top__NDc4M 200ms reverse ease-in;
3311
+ }
3312
+ .Modal_modal__ZTRjZ.Modal_bottom__Zjg4M[data-entering] {
3313
+ animation: Modal_modal-bottom__YTE1Z 200ms ease-out;
3314
+ }
3315
+ .Modal_modal__ZTRjZ.Modal_bottom__Zjg4M[data-exiting] {
3316
+ animation: Modal_modal-bottom__YTE1Z 200ms reverse ease-in;
3317
+ }
3318
+ .Modal_modal__ZTRjZ.Modal_fullscreen__NmZiM[data-entering] {
3319
+ animation: Modal_modal-fade-in__MDBkZ 200ms ease-out;
3320
+ }
3321
+ @keyframes Modal_modal-fade-in__MDBkZ {
3250
3322
  from {
3251
3323
  opacity: 0;
3252
3324
  }
@@ -3254,7 +3326,7 @@ body a.Button_button__N2NhN {
3254
3326
  opacity: 1;
3255
3327
  }
3256
3328
  }
3257
- @keyframes Modal_modal-zoom__MDZmY {
3329
+ @keyframes Modal_modal-zoom__MmU0M {
3258
3330
  from {
3259
3331
  transform: scale(0.8);
3260
3332
  }
@@ -3262,21 +3334,37 @@ body a.Button_button__N2NhN {
3262
3334
  transform: scale(1);
3263
3335
  }
3264
3336
  }
3265
-
3266
- /* virtual-css:css:3bfbb09f24953e4c776b7494b4f2e619 */
3267
- .MobileMenuButton_modal__YjAxN,
3268
- .MobileMenuButton_dialog__Mzc5Y {
3269
- width: 100dvw !important;
3270
- height: 100dvh !important;
3271
- overflow: hidden;
3337
+ @keyframes Modal_modal-left__MWY5M {
3338
+ from {
3339
+ transform: translateX(-100%);
3340
+ }
3341
+ to {
3342
+ transform: translateX(0);
3343
+ }
3272
3344
  }
3273
- .MobileMenuButton_dialog__Mzc5Y {
3274
- border: 0;
3275
- border-radius: 0;
3276
- box-shadow: none;
3345
+ @keyframes Modal_modal-right__OWVlM {
3346
+ from {
3347
+ transform: translateX(100%);
3348
+ }
3349
+ to {
3350
+ transform: translateX(0);
3351
+ }
3277
3352
  }
3278
- .MobileMenuButton_content__MjQ3N {
3279
- overflow: auto;
3353
+ @keyframes Modal_modal-top__NDc4M {
3354
+ from {
3355
+ transform: translateY(-100%);
3356
+ }
3357
+ to {
3358
+ transform: translateX(0);
3359
+ }
3360
+ }
3361
+ @keyframes Modal_modal-bottom__YTE1Z {
3362
+ from {
3363
+ transform: translateY(100%);
3364
+ }
3365
+ to {
3366
+ transform: translateX(0);
3367
+ }
3280
3368
  }
3281
3369
 
3282
3370
  /* virtual-css:css:f06faaaaad4324b9459c87ab9d58d827 */
package/dist/index.d.ts CHANGED
@@ -48,7 +48,6 @@ declare module '@umami/react-zen' {
48
48
  import { LoadingButton } from '@umami/react-zen/LoadingButton';
49
49
  import { Menu } from '@umami/react-zen/Menu';
50
50
  import { MenuItem } from '@umami/react-zen/MenuItem';
51
- import { MobileMenuButton } from '@umami/react-zen/MobileMenuButton';
52
51
  import { Modal } from '@umami/react-zen/Modal';
53
52
  import { NavigationMenu, NavigationMenuItem } from '@umami/react-zen/NavigationMenu';
54
53
  import { PasswordField } from '@umami/react-zen/PasswordField';
@@ -74,7 +73,7 @@ declare module '@umami/react-zen' {
74
73
  import { ToggleGroup, ToggleGroupItem } from '@umami/react-zen/ToggleGroup';
75
74
  import { Tooltip } from '@umami/react-zen/Tooltip';
76
75
  import { ZenProvider } from '@umami/react-zen/ZenProvider';
77
- export { Form, FormField, FormResetButton, FormSubmitButton, Toast, Toaster, ToastProvider, useDebounce, useTheme, useToast, Accordion, AccordionItem, AlertBanner, AlertDialog, Blockquote, Box, Breadcrumb, Breadcrumbs, Button, Calendar, Checkbox, Code, Column, Combobox, Container, ConfirmationDialog, DataTable, DataColumn, Dialog, DialogTrigger, Dots, FileTrigger, Flexbox, Grid, Heading, HoverTrigger, Icon, Icons, InlineEditField, Label, List, ListItem, ListSection, Loading, LoadingButton, Menu, MenuItem, MenuTrigger, MobileMenuButton, Modal, NavigationMenu, NavigationMenuItem, PasswordField, Popover, ProgressBar, ProgressCircle, Radio, RadioGroup, Row, SearchField, Select, ListSeparator, Slider, Slot, Spinner, StatusLight, SubmenuTrigger, Switch, Table, TableHeader, TableBody, TableRow, TableColumn, TableCell, Tab, Tabs, TabList, TabPanel, Text, TextField, TextArea, ThemeButton, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipTrigger, ZenProvider, };
76
+ export { Form, FormField, FormResetButton, FormSubmitButton, Toast, Toaster, ToastProvider, useDebounce, useTheme, useToast, Accordion, AccordionItem, AlertBanner, AlertDialog, Blockquote, Box, Breadcrumb, Breadcrumbs, Button, Calendar, Checkbox, Code, Column, Combobox, Container, ConfirmationDialog, DataTable, DataColumn, Dialog, DialogTrigger, Dots, FileTrigger, Flexbox, Grid, Heading, HoverTrigger, Icon, Icons, InlineEditField, Label, List, ListItem, ListSection, Loading, LoadingButton, Menu, MenuItem, MenuTrigger, Modal, NavigationMenu, NavigationMenuItem, PasswordField, Popover, ProgressBar, ProgressCircle, Radio, RadioGroup, Row, SearchField, Select, ListSeparator, Slider, Slot, Spinner, StatusLight, SubmenuTrigger, Switch, Table, TableHeader, TableBody, TableRow, TableColumn, TableCell, Tab, Tabs, TabList, TabPanel, Text, TextField, TextArea, ThemeButton, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipTrigger, ZenProvider, };
78
77
  }
79
78
 
80
79
  declare module '@umami/react-zen/forms/Form' {
@@ -412,8 +411,9 @@ declare module '@umami/react-zen/Dialog' {
412
411
  import { DialogProps as AriaDialogProps } from 'react-aria-components';
413
412
  interface DialogProps extends AriaDialogProps {
414
413
  title?: ReactNode;
414
+ variant?: 'sheet';
415
415
  }
416
- function Dialog({ title, children, className, ...props }: DialogProps): import("react").JSX.Element;
416
+ function Dialog({ title, variant, children, className, ...props }: DialogProps): import("react").JSX.Element;
417
417
  export { Dialog };
418
418
  export type { DialogProps };
419
419
  }
@@ -625,24 +625,17 @@ declare module '@umami/react-zen/MenuItem' {
625
625
  export default MenuItem;
626
626
  }
627
627
 
628
- declare module '@umami/react-zen/MobileMenuButton' {
629
- import { ButtonProps } from '@umami/react-zen/Button';
630
- export interface MobileMenuButtonProps extends ButtonProps {
631
- title?: string;
632
- }
633
- export function MobileMenuButton({ title, children, ...props }: MobileMenuButtonProps): import("react").JSX.Element;
634
- }
635
-
636
628
  declare module '@umami/react-zen/Modal' {
637
629
  import { ReactNode } from 'react';
638
- import { ModalRenderProps } from 'react-aria-components';
639
- interface ModalProps {
640
- className?: string;
630
+ import { ModalOverlayProps as AriaModalOverlayProps, ModalRenderProps } from 'react-aria-components';
631
+ interface ModalProps extends AriaModalOverlayProps {
632
+ position?: 'center' | 'top' | 'bottom' | 'left' | 'right' | 'fullscreen';
633
+ offset?: string;
641
634
  children?: ReactNode | ((values: ModalRenderProps & {
642
635
  defaultChildren: ReactNode;
643
636
  }) => ReactNode);
644
637
  }
645
- function Modal({ children, className, ...props }: ModalProps): import("react").JSX.Element;
638
+ function Modal({ position, offset, children, className, style, ...props }: ModalProps): import("react").JSX.Element;
646
639
  export { Modal };
647
640
  export type { ModalProps };
648
641
  }