@ostack.tech/ui-exhibit 0.10.5 → 0.11.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.
@@ -1,5 +1,5 @@
1
1
  import { jsxs, jsx, Fragment as Fragment$1 } from "react/jsx-runtime";
2
- import { useCssVars, Stack, Heading, Link, VisuallyHidden, AlertDialog, AlertDialogTrigger, Button, AlertDialogContent, AlertDialogHeader, AlertDialogTitle, AlertDialogBody, AlertDialogDescription, AlertDialogFooter, AlertDialogCancel, AlertDialogAction, Alert, AlertTitle, ButtonGroup, IconButton, Calendar, Field, Label, CheckboxGroup, Checkbox, Feedback, HelperText, Code, useSpacing, Collapsible, CollapsibleTrigger, CollapsibleContent, useKeyboardShortcut, Keybinds, CommandMenuDialog, CommandMenu, CommandMenuGroup, CommandMenuItem, DataTable, DataTableFilter, DataTableContent, DataTableRowsPerPage, DataTablePagination, DateInput, DateRangeInput, Dialog, DialogTrigger, DialogContent, DialogHeader, DialogTitle, DialogBody, DialogDescription, Input, DialogFooter, DialogClose, DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuCheckboxItem, DropdownMenuSub, DropdownMenuSubTrigger, DropdownMenuSubContent, FieldGroup, FieldGroupHeader, FieldGroupTitle, FieldGroupBody, Keyboard, Mark, MenuList, MenuListGroup, MenuListItem, NumericInput, ControlAddon, Output, Popover, PopoverTrigger, PopoverContent, TextArea, RadioGroup, Radio, Select, Option, Spinner, Table, TableHead, TableColumn, TableBody, TableRow, TableCell, TableFoot, Tabs, TabList, Tab, TabContent, Tag, useToastManager, Tooltip, Root, enGB, Container } from "@ostack.tech/ui";
2
+ import { useCssVars, Stack, Heading, Link, VisuallyHidden, AlertDialog, AlertDialogTrigger, Button, AlertDialogContent, AlertDialogHeader, AlertDialogTitle, AlertDialogBody, AlertDialogDescription, AlertDialogFooter, AlertDialogCancel, AlertDialogAction, Alert, AlertTitle, ButtonGroup, IconButton, Calendar, Field, Label, CheckboxGroup, Checkbox, Feedback, HelperText, Code, useSpacing, Collapsible, CollapsibleTrigger, CollapsibleContent, useKeyboardShortcut, Keybinds, CommandMenuDialog, CommandMenu, CommandMenuGroup, CommandMenuItem, DataTable, DataTableFilter, DataTableContent, DataTableRowsPerPage, DataTablePagination, DateInput, DateRangeInput, DescriptionList, DescriptionListItem, Tag, Dialog, DialogTrigger, DialogContent, DialogHeader, DialogTitle, DialogBody, DialogDescription, Input, DialogFooter, DialogClose, DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuCheckboxItem, DropdownMenuSub, DropdownMenuSubTrigger, DropdownMenuSubContent, FieldGroup, FieldGroupHeader, FieldGroupTitle, FieldGroupBody, Keyboard, Mark, MenuList, MenuListGroup, MenuListItem, NumericInput, ControlAddon, Output, Popover, PopoverTrigger, PopoverContent, TextArea, RadioGroup, Radio, Select, Option, Spinner, Stepper, StepList, Step, StepContent, StepperPreviousTrigger, StepperNextTrigger, StepperFinishTrigger, Table, TableHead, TableColumn, TableBody, TableRow, TableCell, TableFoot, Tabs, TabList, Tab, TabContent, useToastManager, Tooltip, Root, enGB, Container } from "@ostack.tech/ui";
3
3
  import { createContext, useContext, Fragment, useState } from "react";
4
4
  import { faFolderOpen, faSave, faTrashCan, faBolt, faCaretUp, faCaretDown, faGear, faWifi, faNetworkWired, faDisplay, faVolumeHigh, faKeyboard, faPrint, faClock, faUser, faCircleXmark, faSeedling, faEye, faPencil, faComment, faStar, faBookmark } from "@fortawesome/free-solid-svg-icons";
5
5
  const ExhibitContext = createContext(null);
@@ -574,10 +574,6 @@ function DataTableSection() {
574
574
  renderItem: ({ col }) => /* @__PURE__ */ jsx(Field, { style: { width: 450 }, children: /* @__PURE__ */ jsxs(
575
575
  DataTable,
576
576
  {
577
- displayMode: col === "scrolled" ? col : void 0,
578
- showSelectionColumn: col === "showSelectionColumn",
579
- rowKey: "id",
580
- defaultLimit: 5,
581
577
  columns: {
582
578
  student: {
583
579
  label: "Student",
@@ -594,6 +590,10 @@ function DataTableSection() {
594
590
  }
595
591
  },
596
592
  rows: ROWS$1,
593
+ rowKey: "id",
594
+ displayMode: col === "scrolled" ? col : void 0,
595
+ showSelectionColumn: col === "showSelectionColumn",
596
+ defaultLimit: 5,
597
597
  children: [
598
598
  /* @__PURE__ */ jsx(Label, { children: "Exam grades" }),
599
599
  /* @__PURE__ */ jsx(DataTableFilter, {}),
@@ -707,6 +707,33 @@ function DateRangeInputSection() {
707
707
  }
708
708
  );
709
709
  }
710
+ function DescriptionListSection() {
711
+ return /* @__PURE__ */ jsx(
712
+ ExhibitSection,
713
+ {
714
+ title: "Description list",
715
+ docsPage: "ostack-ui-data-display-description-list",
716
+ children: /* @__PURE__ */ jsxs(DescriptionList, { children: [
717
+ /* @__PURE__ */ jsx(DescriptionListItem, { term: "Instance ID", xs: 6, md: 4, lg: 3, xl: 2, children: /* @__PURE__ */ jsx(Code, { children: "i-04f29a87bca612" }) }),
718
+ /* @__PURE__ */ jsx(DescriptionListItem, { term: "Status", xs: 6, md: 4, lg: 3, xl: 2, children: /* @__PURE__ */ jsx(Tag, { color: "success", children: "Running" }) }),
719
+ /* @__PURE__ */ jsx(DescriptionListItem, { term: "Public IPv4", xs: 6, md: 4, lg: 3, xl: 2, children: /* @__PURE__ */ jsx(Link, { href: "http://203.0.113.88", external: true, children: "203.0.113.88" }) }),
720
+ /* @__PURE__ */ jsx(DescriptionListItem, { term: "Storage", xs: 6, md: 4, lg: 3, xl: 2, children: "20 GB (SSD)" }),
721
+ /* @__PURE__ */ jsx(
722
+ DescriptionListItem,
723
+ {
724
+ term: "Availability Zone",
725
+ xs: 6,
726
+ md: 4,
727
+ lg: 3,
728
+ xl: 2,
729
+ children: /* @__PURE__ */ jsx(Code, { children: "us-east-1a" })
730
+ }
731
+ ),
732
+ /* @__PURE__ */ jsx(DescriptionListItem, { term: "Launch Time", xs: 6, md: 4, lg: 3, xl: 2, children: "2026-02-12 14:30 UTC" })
733
+ ] })
734
+ }
735
+ );
736
+ }
710
737
  function DialogSection() {
711
738
  return /* @__PURE__ */ jsx(ExhibitSection, { title: "Dialog", docsPage: "ostack-ui-overlay-dialog", children: /* @__PURE__ */ jsx(
712
739
  ExhibitGrid,
@@ -1261,6 +1288,31 @@ function SpinnerSection() {
1261
1288
  }
1262
1289
  ) });
1263
1290
  }
1291
+ function StepperSection() {
1292
+ const spacing = useSpacing();
1293
+ return /* @__PURE__ */ jsx(
1294
+ ExhibitSection,
1295
+ {
1296
+ title: "Stepper",
1297
+ docsPage: "ostack-ui-data-disclosure-stepper",
1298
+ children: /* @__PURE__ */ jsxs(Stepper, { style: { maxWidth: 600 }, children: [
1299
+ /* @__PURE__ */ jsxs(StepList, { children: [
1300
+ /* @__PURE__ */ jsx(Step, { children: "Account Details" }),
1301
+ /* @__PURE__ */ jsx(Step, { children: "Shipping Address" }),
1302
+ /* @__PURE__ */ jsx(Step, { children: "Payment Method" }),
1303
+ /* @__PURE__ */ jsx(Step, { children: "Review & Confirm" })
1304
+ ] }),
1305
+ /* @__PURE__ */ jsx(StepContent, { style: { marginBlock: spacing(2) }, children: "Enter your contact information…" }),
1306
+ /* @__PURE__ */ jsx(StepContent, { style: { marginBlock: spacing(2) }, children: "Select your shipping address…" }),
1307
+ /* @__PURE__ */ jsx(StepContent, { style: { marginBlock: spacing(2) }, children: "Select your payment method…" }),
1308
+ /* @__PURE__ */ jsx(StepContent, { style: { marginBlock: spacing(2) }, children: "Double-check your order…" }),
1309
+ /* @__PURE__ */ jsx(StepperPreviousTrigger, {}),
1310
+ /* @__PURE__ */ jsx(StepperNextTrigger, {}),
1311
+ /* @__PURE__ */ jsx(StepperFinishTrigger, {})
1312
+ ] })
1313
+ }
1314
+ );
1315
+ }
1264
1316
  const ROWS = [
1265
1317
  { student: "Avi Everett", grade: 82.5 },
1266
1318
  { student: "Evan Gutierrez", grade: 67.8 },
@@ -1442,7 +1494,7 @@ function ExhibitApp({
1442
1494
  prefix,
1443
1495
  actions
1444
1496
  }) {
1445
- return /* @__PURE__ */ jsx(ExhibitContext, { value: { docsUrl }, children: /* @__PURE__ */ jsxs(Root, { prefix, locale: enGB, children: [
1497
+ return /* @__PURE__ */ jsx(ExhibitContext.Provider, { value: { docsUrl }, children: /* @__PURE__ */ jsxs(Root, { prefix, locale: enGB, children: [
1446
1498
  /* @__PURE__ */ jsx(VisuallyHidden, { focusable: true, asChild: true, children: /* @__PURE__ */ jsx(Link, { href: "#exhibit-main", style: { top: 6, left: 6 }, children: "Skip to main content" }) }),
1447
1499
  /* @__PURE__ */ jsx(Container, { asChild: true, children: /* @__PURE__ */ jsxs("header", { id: "exhibit-header", children: [
1448
1500
  /* @__PURE__ */ jsx(Heading, { level: 1, id: "exhibit-title", children: title }),
@@ -1462,6 +1514,7 @@ function ExhibitApp({
1462
1514
  /* @__PURE__ */ jsx(DataTableSection, {}),
1463
1515
  /* @__PURE__ */ jsx(DateInputSection, {}),
1464
1516
  /* @__PURE__ */ jsx(DateRangeInputSection, {}),
1517
+ /* @__PURE__ */ jsx(DescriptionListSection, {}),
1465
1518
  /* @__PURE__ */ jsx(DialogSection, {}),
1466
1519
  /* @__PURE__ */ jsx(DropdownMenuSection, {}),
1467
1520
  /* @__PURE__ */ jsx(FieldGroupSection, {}),
@@ -1476,6 +1529,7 @@ function ExhibitApp({
1476
1529
  /* @__PURE__ */ jsx(RadioGroupSection, {}),
1477
1530
  /* @__PURE__ */ jsx(SelectSection, {}),
1478
1531
  /* @__PURE__ */ jsx(SpinnerSection, {}),
1532
+ /* @__PURE__ */ jsx(StepperSection, {}),
1479
1533
  /* @__PURE__ */ jsx(TableSection, {}),
1480
1534
  /* @__PURE__ */ jsx(TabsSection, {}),
1481
1535
  /* @__PURE__ */ jsx(TagSection, {}),