@dxos/react-ui-table 0.6.13-main.ed424a1 → 0.6.13
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/lib/browser/index.mjs +127 -43
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/types/src/components/ColumnMenu/ColumnMenu.d.ts +3 -6
- package/dist/types/src/components/ColumnMenu/ColumnMenu.d.ts.map +1 -1
- package/dist/types/src/components/ColumnMenu/ColumnMenu.stories.d.ts +3 -3
- package/dist/types/src/components/ColumnMenu/ColumnMenu.stories.d.ts.map +1 -1
- package/dist/types/src/components/ColumnMenu/ColumnSettingsForm.d.ts +12 -0
- package/dist/types/src/components/ColumnMenu/ColumnSettingsForm.d.ts.map +1 -0
- package/dist/types/src/components/ColumnMenu/ColumnSettingsForm.stories.d.ts +63 -0
- package/dist/types/src/components/ColumnMenu/ColumnSettingsForm.stories.d.ts.map +1 -0
- package/dist/types/src/components/ColumnMenu/index.d.ts +1 -1
- package/dist/types/src/components/ColumnMenu/index.d.ts.map +1 -1
- package/dist/types/src/components/Table/Table.d.ts.map +1 -1
- package/dist/types/src/components/Table/Table.stories.d.ts +9 -21
- package/dist/types/src/components/Table/Table.stories.d.ts.map +1 -1
- package/dist/types/src/components/Table/TableContext.d.ts +4 -2
- package/dist/types/src/components/Table/TableContext.d.ts.map +1 -1
- package/dist/types/src/components/Table/TableHead.d.ts.map +1 -1
- package/dist/types/src/components/Table/index.d.ts +1 -2
- package/dist/types/src/components/Table/index.d.ts.map +1 -1
- package/dist/types/src/helpers.d.ts +1 -1
- package/dist/types/src/helpers.d.ts.map +1 -1
- package/dist/types/src/hooks/useRowSelection.d.ts.map +1 -1
- package/dist/types/src/schema/{Schema.stories.d.ts → SchemaToTable.stories.d.ts} +3 -2
- package/dist/types/src/schema/SchemaToTable.stories.d.ts.map +1 -0
- package/dist/types/src/schema/index.d.ts +1 -1
- package/dist/types/src/schema/index.d.ts.map +1 -1
- package/dist/types/src/schema/schema.d.ts +5 -0
- package/dist/types/src/schema/schema.d.ts.map +1 -0
- package/dist/types/src/schema/schema.test.d.ts +2 -0
- package/dist/types/src/schema/schema.test.d.ts.map +1 -0
- package/dist/types/src/schema/{column-utils.d.ts → schemaToColumns.d.ts} +2 -2
- package/dist/types/src/schema/schemaToColumns.d.ts.map +1 -0
- package/dist/types/src/schema/types.d.ts +4 -10
- package/dist/types/src/schema/types.d.ts.map +1 -1
- package/package.json +20 -21
- package/src/components/ColumnMenu/ColumnMenu.stories.tsx +12 -13
- package/src/components/ColumnMenu/ColumnMenu.tsx +5 -8
- package/src/components/ColumnMenu/{ColumnSettings.stories.tsx → ColumnSettingsForm.stories.tsx} +23 -27
- package/src/components/ColumnMenu/{ColumnSettings.tsx → ColumnSettingsForm.tsx} +43 -44
- package/src/components/ColumnMenu/index.ts +1 -1
- package/src/components/Table/Table.stories.tsx +85 -97
- package/src/components/Table/Table.tsx +9 -8
- package/src/components/Table/TableContext.tsx +7 -13
- package/src/components/Table/TableHead.tsx +1 -0
- package/src/components/Table/index.ts +1 -2
- package/src/components/Table/props.ts +4 -4
- package/src/helpers.tsx +6 -4
- package/src/hooks/useRowSelection.ts +0 -1
- package/src/schema/{Schema.stories.tsx → SchemaToTable.stories.tsx} +23 -11
- package/src/schema/index.ts +1 -1
- package/src/schema/schema.test.ts +148 -0
- package/src/schema/schema.ts +93 -0
- package/src/schema/{column-utils.ts → schemaToColumns.ts} +9 -9
- package/src/schema/types.ts +6 -14
- package/src/translations.ts +1 -1
- package/dist/types/src/components/ColumnMenu/ColumnSettings.d.ts +0 -15
- package/dist/types/src/components/ColumnMenu/ColumnSettings.d.ts.map +0 -1
- package/dist/types/src/components/ColumnMenu/ColumnSettings.stories.d.ts +0 -84
- package/dist/types/src/components/ColumnMenu/ColumnSettings.stories.d.ts.map +0 -1
- package/dist/types/src/schema/Schema.stories.d.ts.map +0 -1
- package/dist/types/src/schema/column-utils.d.ts.map +0 -1
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
import '@dxos-theme';
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { FieldValueType } from '@dxos/schema';
|
|
4
|
-
import { type ColumnSettingsProps } from './ColumnSettings';
|
|
5
|
-
import { type TableDef } from '../../schema';
|
|
6
|
-
declare const _default: {
|
|
7
|
-
title: string;
|
|
8
|
-
component: ({ column, tableDef, tablesToReference, onUpdate, onDelete, onClose, }: ColumnSettingsProps) => React.JSX.Element;
|
|
9
|
-
decorators: import("@storybook/react/*").Decorator[];
|
|
10
|
-
parameters: {
|
|
11
|
-
translations: {
|
|
12
|
-
'en-US': {
|
|
13
|
-
table: {
|
|
14
|
-
'no selection label': string;
|
|
15
|
-
'number column type label': string;
|
|
16
|
-
'boolean column type label': string;
|
|
17
|
-
'date column type label': string;
|
|
18
|
-
'string column type label': string;
|
|
19
|
-
'ref column type label': string;
|
|
20
|
-
'digits label': string;
|
|
21
|
-
'save label': string;
|
|
22
|
-
'delete label': string;
|
|
23
|
-
'column label label': string;
|
|
24
|
-
'property key label': string;
|
|
25
|
-
'column type label': string;
|
|
26
|
-
};
|
|
27
|
-
};
|
|
28
|
-
}[];
|
|
29
|
-
};
|
|
30
|
-
render: (props: ColumnSettingsProps) => React.JSX.Element;
|
|
31
|
-
};
|
|
32
|
-
export default _default;
|
|
33
|
-
export declare const Default: {
|
|
34
|
-
args: ColumnSettingsProps;
|
|
35
|
-
};
|
|
36
|
-
export declare const NumberColumn: {
|
|
37
|
-
args: {
|
|
38
|
-
column: {
|
|
39
|
-
id: string;
|
|
40
|
-
prop: string;
|
|
41
|
-
type: FieldValueType;
|
|
42
|
-
label: string;
|
|
43
|
-
digits: number;
|
|
44
|
-
};
|
|
45
|
-
tableDef: TableDef;
|
|
46
|
-
tablesToReference: TableDef[];
|
|
47
|
-
onUpdate?: (id: string, column: import("../../schema").ColumnDef) => void;
|
|
48
|
-
onDelete?: (id: string) => void;
|
|
49
|
-
onClose?: () => void;
|
|
50
|
-
};
|
|
51
|
-
};
|
|
52
|
-
export declare const ReferenceColumn: {
|
|
53
|
-
args: {
|
|
54
|
-
column: {
|
|
55
|
-
id: string;
|
|
56
|
-
prop: string;
|
|
57
|
-
type: FieldValueType;
|
|
58
|
-
label: string;
|
|
59
|
-
refTable: string;
|
|
60
|
-
refProp: string;
|
|
61
|
-
};
|
|
62
|
-
tableDef: TableDef;
|
|
63
|
-
tablesToReference: TableDef[];
|
|
64
|
-
onUpdate?: (id: string, column: import("../../schema").ColumnDef) => void;
|
|
65
|
-
onDelete?: (id: string) => void;
|
|
66
|
-
onClose?: () => void;
|
|
67
|
-
};
|
|
68
|
-
};
|
|
69
|
-
export declare const NewColumn: {
|
|
70
|
-
args: {
|
|
71
|
-
column: {
|
|
72
|
-
id: string;
|
|
73
|
-
prop: string;
|
|
74
|
-
type: FieldValueType;
|
|
75
|
-
label: string;
|
|
76
|
-
};
|
|
77
|
-
tableDef: TableDef;
|
|
78
|
-
tablesToReference: TableDef[];
|
|
79
|
-
onUpdate?: (id: string, column: import("../../schema").ColumnDef) => void;
|
|
80
|
-
onDelete?: (id: string) => void;
|
|
81
|
-
onClose?: () => void;
|
|
82
|
-
};
|
|
83
|
-
};
|
|
84
|
-
//# sourceMappingURL=ColumnSettings.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ColumnSettings.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/ColumnMenu/ColumnSettings.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAG9C,OAAO,EAAkB,KAAK,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAC5E,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,cAAc,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;oBAGvB,mBAAmB;;AAMzC,wBAQE;AAqCF,eAAO,MAAM,OAAO;;CAEnB,CAAC;AAEF,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;CAWxB,CAAC;AAEF,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;CAY3B,CAAC;AAEF,eAAO,MAAM,SAAS;;;;;;;;;;;;;;CAUrB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Schema.stories.d.ts","sourceRoot":"","sources":["../../../../src/schema/Schema.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAIrB,OAAO,KAAK,MAAM,OAAO,CAAC;;;;;AAQ1B,wBAGE;AAoBF,eAAO,MAAM,OAAO;;CAmBnB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"column-utils.d.ts","sourceRoot":"","sources":["../../../../src/schema/column-utils.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAEvD,OAAO,EAAE,KAAK,CAAC,EAAE,MAAM,mBAAmB,CAAC;AAK3C,eAAO,MAAM,kBAAkB,GAAI,CAAC,UAAU,CAAC,CAAC,MAAM,CAAC,CAAC,EAAE,GAAG,CAAC,KAAG,SAAS,CAAC,CAAC,EAAE,GAAG,CAAC,EAoCjF,CAAC"}
|