@mittwald/flow-react-components 0.1.0-alpha.420 → 0.1.0-alpha.422

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.
@@ -0,0 +1,6 @@
1
+ import { Align } from '..';
2
+ import { Meta, StoryObj } from '@storybook/react';
3
+ declare const meta: Meta<typeof Align>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof Align>;
6
+ export declare const Default: Story;
@@ -23,7 +23,7 @@ export declare const typedList: <T>() => {
23
23
  children?: import('react').ReactNode | undefined;
24
24
  } & import('../../lib/types/props').PropsWithClassName) => import("react").JSX.Element;
25
25
  TableHeader: (ignoredProps: import('./model/table/types').TableHeaderShape) => null;
26
- TableColumn: (ignoredProps: import('react-aria-components').ColumnProps) => null;
26
+ TableColumn: (ignoredProps: import('../Table').TableColumnProps) => null;
27
27
  TableBody: (ignoredProps: import('./model/table/types').TableBodyShape<T>) => null;
28
28
  TableRow: (ignoredProps: {
29
29
  footer?: boolean | undefined;
@@ -2,6 +2,8 @@ import { FC, PropsWithChildren } from 'react';
2
2
  import * as Aria from "react-aria-components";
3
3
  export interface TableCellProps extends Omit<Aria.CellProps, "children" | "style">, PropsWithChildren {
4
4
  rowHeader?: boolean;
5
+ /** @default "start" */
6
+ horizontalAlign?: "start" | "center";
5
7
  }
6
8
  export declare const TableCell: FC<TableCellProps>;
7
9
  export default TableCell;
@@ -1,5 +1,8 @@
1
1
  import { FC } from 'react';
2
2
  import * as Aria from "react-aria-components";
3
- export type TableColumnProps = Aria.ColumnProps;
3
+ export interface TableColumnProps extends Aria.ColumnProps {
4
+ /** @default "start" */
5
+ horizontalAlign?: "start" | "center";
6
+ }
4
7
  export declare const TableColumn: FC<TableColumnProps>;
5
8
  export default TableColumn;
@@ -7,3 +7,4 @@ export declare const Default: Story;
7
7
  export declare const VerticallyCenteredRows: Story;
8
8
  export declare const WithFooter: Story;
9
9
  export declare const WithRowHeader: Story;
10
+ export declare const HorizontallyCenteredColumns: Story;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mittwald/flow-react-components",
3
- "version": "0.1.0-alpha.420",
3
+ "version": "0.1.0-alpha.422",
4
4
  "type": "module",
5
5
  "description": "A React implementation of Flow, mittwald’s design system",
6
6
  "homepage": "https://mittwald.github.io/flow",
@@ -440,7 +440,7 @@
440
440
  "@chakra-ui/live-region": "^2.1.0",
441
441
  "@internationalized/date": "^3.6.0",
442
442
  "@internationalized/string-compiler": "^3.2.6",
443
- "@mittwald/react-tunnel": "^0.1.0-alpha.420",
443
+ "@mittwald/react-tunnel": "^0.1.0-alpha.422",
444
444
  "@mittwald/react-use-promise": "^2.6.0",
445
445
  "@react-aria/form": "^3.0.11",
446
446
  "@react-aria/utils": "^3.26.0",
@@ -471,7 +471,7 @@
471
471
  },
472
472
  "devDependencies": {
473
473
  "@faker-js/faker": "^9.2.0",
474
- "@mittwald/flow-design-tokens": "^0.1.0-alpha.420",
474
+ "@mittwald/flow-design-tokens": "^0.1.0-alpha.422",
475
475
  "@mittwald/react-use-promise": "^2.6.0",
476
476
  "@nx/storybook": "^20.1.3",
477
477
  "@storybook/addon-a11y": "^8.4.5",
@@ -566,5 +566,5 @@
566
566
  }
567
567
  }
568
568
  },
569
- "gitHead": "194f7486f370f7dd0d0051ecbe50ab126fec46cd"
569
+ "gitHead": "3141032e1b503684253c1c16c5314e5b751d9090"
570
570
  }
@@ -1,58 +0,0 @@
1
- "use client"
2
- /* */
3
- import s, { Suspense as i } from "react";
4
- import * as n from "react-aria-components";
5
- import m from "clsx";
6
- import { S as d } from "./SkeletonText-B5ZghZhO.js";
7
- const f = "flow--table--table-container", N = "flow--table", w = "flow--table--column", u = "flow--table--cell", C = "flow--table--header", h = "flow--table--body", T = "flow--table--row", E = "flow--table--footer", r = {
8
- tableContainer: f,
9
- table: N,
10
- column: w,
11
- cell: u,
12
- header: C,
13
- body: h,
14
- row: T,
15
- footer: E,
16
- "vertical-align-middle": "flow--table--vertical-align-middle"
17
- }, x = (a) => {
18
- const { children: l, className: e, ...o } = a, t = m(r.body, e);
19
- return /* @__PURE__ */ s.createElement(n.TableBody, { className: t, ...o }, l);
20
- }, H = (a) => {
21
- const { children: l, className: e, rowHeader: o, ...t } = a, c = m(r.cell, e), b = /* @__PURE__ */ s.createElement(i, { fallback: /* @__PURE__ */ s.createElement(d, { width: "100px" }) }, l);
22
- return o ? /* @__PURE__ */ s.createElement(p, { className: c, ...t }, b) : /* @__PURE__ */ s.createElement(n.Cell, { className: c, ...t }, b);
23
- }, p = (a) => {
24
- const { children: l, className: e, ...o } = a, t = m(r.column, e);
25
- return /* @__PURE__ */ s.createElement(n.Column, { isRowHeader: !0, className: t, ...o }, l);
26
- }, R = (a) => {
27
- const { children: l, className: e, ...o } = a, t = m(r.header, e);
28
- return /* @__PURE__ */ s.createElement(n.TableHeader, { className: t, ...o }, l);
29
- }, S = (a) => {
30
- const { children: l, className: e, footer: o, ...t } = a;
31
- return /* @__PURE__ */ s.createElement(
32
- n.Row,
33
- {
34
- className: (c) => m(
35
- r.row,
36
- o && r.footer,
37
- typeof e == "function" ? e(c) : e
38
- ),
39
- ...t
40
- },
41
- l
42
- );
43
- }, k = (a) => {
44
- const { children: l, className: e, verticalAlign: o = "top", ...t } = a, c = m(
45
- r.table,
46
- r[`vertical-align-${o}`],
47
- e
48
- );
49
- return /* @__PURE__ */ s.createElement("div", { className: r.tableContainer }, /* @__PURE__ */ s.createElement(n.Table, { className: c, ...t }, l));
50
- };
51
- export {
52
- S as T,
53
- k as a,
54
- x as b,
55
- H as c,
56
- p as d,
57
- R as e
58
- };