Fullscreen Dialog

Displays content in a modal overlaid onto the primary content.

New Account
New account transfers earn extraGet a bonus when you move your funds over
Name
Account Number
Routing Number
Account Type
Transfer Requirements
Slots
children
Icon Button5 props
Alert5 props
Text Field8 props
Input2 props
Text Field8 props
Input2 props
Text Field8 props
Input2 props
Radio Card Group1 prop
Radio Card4 props
Radio Card4 props
Checkbox Card4 props
Checkbox Card4 props
Checkbox Card4 props
Button7 props
Button7 props

Installation

Usage

Example
Source Code
"use client";

import React from "react";
import { Alert } from "@/ui/components/Alert";
import { Button } from "@/ui/components/Button";
import { CheckboxCard } from "@/ui/components/CheckboxCard";
import { FullscreenDialog } from "@/ui/components/FullscreenDialog";
import { IconButton } from "@/ui/components/IconButton";
import { RadioCardGroup } from "@/ui/components/RadioCardGroup";
import { TextField } from "@/ui/components/TextField";
import { FeatherX } from "@subframe/core";

function FullscreenDialogExample() {
  return (
    <FullscreenDialog open={false} onOpenChange={(open: boolean) => {}}>
      <div className="flex w-full items-center justify-between border-b border-solid border-neutral-border px-4 py-4">
        <img
          className="h-8 w-8 flex-none object-cover"
          src="https://res.cloudinary.com/subframe/image/upload/v1711417507/shared/y2rsnhq3mex4auk54aye.png"
        />
        <span className="text-body-bold font-body-bold text-default-font">
          New Account
        </span>
        <IconButton
          icon={<FeatherX />}
          onClick={(event: React.MouseEvent<HTMLButtonElement>) => {}}
        />
      </div>
      <div className="container max-w-none flex w-full grow shrink-0 basis-0 flex-col items-center gap-12 py-12 overflow-auto">
        <div className="flex w-full max-w-[384px] grow shrink-0 basis-0 flex-col items-center gap-6">
          <Alert
            variant="brand"
            title="New account transfers earn extra"
            description="Get a bonus when you move your funds over"
          />
          <TextField
            className="h-auto w-full flex-none"
            label="Name"
            helpText=""
          >
            <TextField.Input
              placeholder="Your name"
              value=""
              onChange={(event: React.ChangeEvent<HTMLInputElement>) => {}}
            />
          </TextField>
          <TextField
            className="h-auto w-full flex-none"
            label="Account Number"
            helpText=""
          >
            <TextField.Input
              placeholder="###-#######"
              value=""
              onChange={(event: React.ChangeEvent<HTMLInputElement>) => {}}
            />
          </TextField>
          <TextField
            className="h-auto w-full flex-none"
            label="Routing Number"
            helpText=""
          >
            <TextField.Input
              placeholder="###-#######"
              value=""
              onChange={(event: React.ChangeEvent<HTMLInputElement>) => {}}
            />
          </TextField>
          <div className="flex w-full flex-col items-start gap-2">
            <span className="text-body-bold font-body-bold text-default-font">
              Account Type
            </span>
            <RadioCardGroup
              className="h-auto w-full flex-none"
              value=""
              onValueChange={(value: string) => {}}
            >
              <div className="flex grow shrink-0 basis-0 flex-wrap items-start gap-2">
                <RadioCardGroup.RadioCard
                  disabled={false}
                  hideRadio={false}
                  value="0e713a53"
                >
                  <div className="flex flex-col items-start pr-2">
                    <span className="w-full text-body-bold font-body-bold text-default-font">
                      Checking
                    </span>
                  </div>
                </RadioCardGroup.RadioCard>
                <RadioCardGroup.RadioCard
                  disabled={false}
                  hideRadio={false}
                  value="e52fbcc9"
                >
                  <div className="flex flex-col items-start pr-2">
                    <span className="w-full text-body-bold font-body-bold text-default-font">
                      Savings
                    </span>
                  </div>
                </RadioCardGroup.RadioCard>
              </div>
            </RadioCardGroup>
          </div>
          <div className="flex w-full flex-col items-start gap-2">
            <span className="text-body-bold font-body-bold text-default-font">
              Transfer Requirements
            </span>
            <CheckboxCard
              className="h-auto w-full flex-none"
              checked={false}
              onCheckedChange={(checked: boolean) => {}}
            >
              <span className="text-body-bold font-body-bold text-default-font">
                I&#39;m transferring a retirement account
              </span>
            </CheckboxCard>
            <CheckboxCard
              className="h-auto w-full flex-none"
              checked={false}
              onCheckedChange={(checked: boolean) => {}}
            >
              <span className="text-body-bold font-body-bold text-default-font">
                I&#39;m a US citizen or pernament resident
              </span>
            </CheckboxCard>
            <CheckboxCard
              className="h-auto w-full flex-none"
              checked={false}
              onCheckedChange={(checked: boolean) => {}}
            >
              <span className="text-body-bold font-body-bold text-default-font">
                I&#39;ve held assets in this account for &gt; 1 year
              </span>
            </CheckboxCard>
          </div>
        </div>
      </div>
      <div className="flex w-full items-center justify-between border-t border-solid border-neutral-border px-4 py-4">
        <Button
          variant="neutral-secondary"
          onClick={(event: React.MouseEvent<HTMLButtonElement>) => {}}
        >
          Cancel
        </Button>
        <Button onClick={(event: React.MouseEvent<HTMLButtonElement>) => {}}>
          Save
        </Button>
      </div>
    </FullscreenDialog>
  );
}

export default FullscreenDialogExample;

Props

Fullscreen Dialog Props
Prop
Type
Default value
Notes
children
React.ReactNode
open
boolean
Whether the dialog is currently opened.
onOpenChange
(open: boolean) => void
Handler called when opened or closed.

Examples

Basics

Use open and onOpenChange props to control the open state.