@vuu-ui/vuu-datatable 0.13.93 → 0.13.95-alpha.2
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/cjs/filter-table/FilterTable.js +8 -12
- package/cjs/filter-table/FilterTable.js.map +1 -1
- package/esm/filter-table/FilterTable.js +8 -12
- package/esm/filter-table/FilterTable.js.map +1 -1
- package/package.json +12 -12
- package/cjs/filter-table/FilterTable.css.js +0 -6
- package/cjs/filter-table/FilterTable.css.js.map +0 -1
- package/esm/filter-table/FilterTable.css.js +0 -4
- package/esm/filter-table/FilterTable.css.js.map +0 -1
|
@@ -3,26 +3,22 @@
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var vuuFilters = require('@vuu-ui/vuu-filters');
|
|
5
5
|
var vuuTable = require('@vuu-ui/vuu-table');
|
|
6
|
-
var styles = require('@salt-ds/styles');
|
|
7
|
-
var window = require('@salt-ds/window');
|
|
8
|
-
var cx = require('clsx');
|
|
9
6
|
var useFilterTable = require('./useFilterTable.js');
|
|
10
|
-
var FilterTable$1 = require('./FilterTable.css.js');
|
|
11
7
|
var vuuUtils = require('@vuu-ui/vuu-utils');
|
|
12
8
|
|
|
13
9
|
const classBase = "vuuFilterTable";
|
|
10
|
+
const filterTableStyles = {
|
|
11
|
+
"--vuuFilterBar-flex": "0 0 auto",
|
|
12
|
+
"--vuuMeasuredContainer-flex": "1 1 auto",
|
|
13
|
+
display: "flex",
|
|
14
|
+
flexDirection: "column"
|
|
15
|
+
};
|
|
14
16
|
const FilterTable = ({
|
|
15
17
|
FilterBarProps: FilterBarProps2,
|
|
16
18
|
TableProps: TableProps2,
|
|
17
19
|
style: styleProps,
|
|
18
20
|
...htmlAttributes
|
|
19
21
|
}) => {
|
|
20
|
-
const targetWindow = window.useWindow();
|
|
21
|
-
styles.useComponentCssInjection({
|
|
22
|
-
testId: "vuu-filter-table",
|
|
23
|
-
css: FilterTable$1,
|
|
24
|
-
window: targetWindow
|
|
25
|
-
});
|
|
26
22
|
const { filterBarProps } = useFilterTable.useFilterTable({
|
|
27
23
|
TableProps: TableProps2,
|
|
28
24
|
FilterBarProps: FilterBarProps2
|
|
@@ -31,8 +27,8 @@ const FilterTable = ({
|
|
|
31
27
|
"div",
|
|
32
28
|
{
|
|
33
29
|
...htmlAttributes,
|
|
34
|
-
className:
|
|
35
|
-
style: { ...styleProps },
|
|
30
|
+
className: classBase,
|
|
31
|
+
style: { ...styleProps, ...filterTableStyles },
|
|
36
32
|
children: [
|
|
37
33
|
/* @__PURE__ */ jsxRuntime.jsx(vuuFilters.FilterBar, { ...filterBarProps }),
|
|
38
34
|
/* @__PURE__ */ jsxRuntime.jsx(vuuTable.Table, { ...TableProps2, height: "auto", width: "auto" })
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FilterTable.js","sources":["../../../../packages/vuu-datatable/src/filter-table/FilterTable.tsx"],"sourcesContent":["import { FilterBar, FilterBarProps } from \"@vuu-ui/vuu-filters\";\nimport { Table, TableProps } from \"@vuu-ui/vuu-table\";\nimport {
|
|
1
|
+
{"version":3,"file":"FilterTable.js","sources":["../../../../packages/vuu-datatable/src/filter-table/FilterTable.tsx"],"sourcesContent":["import { FilterBar, FilterBarProps } from \"@vuu-ui/vuu-filters\";\nimport { Table, TableProps } from \"@vuu-ui/vuu-table\";\nimport { CSSProperties, HTMLAttributes } from \"react\";\nimport { useFilterTable } from \"./useFilterTable\";\nimport { DataSourceProvider } from \"@vuu-ui/vuu-utils\";\n\nconst classBase = \"vuuFilterTable\";\n\n// Use inline styles as the VuuFilter stylesheet may not have been loaded\n// by the time child elements need these val;ues to be in place.\nconst filterTableStyles: CSSProperties & {\n \"--vuuFilterBar-flex\": CSSProperties[\"flex\"];\n \"--vuuMeasuredContainer-flex\": CSSProperties[\"flex\"];\n} = {\n \"--vuuFilterBar-flex\": \"0 0 auto\",\n \"--vuuMeasuredContainer-flex\": \"1 1 auto\",\n display: \"flex\",\n flexDirection: \"column\",\n};\n\nexport interface FilterTableProps extends HTMLAttributes<HTMLDivElement> {\n FilterBarProps?: Partial<FilterBarProps>;\n TableProps: Omit<TableProps, \"height\" | \"width\">;\n}\n\nexport const FilterTable = ({\n FilterBarProps,\n TableProps,\n style: styleProps,\n ...htmlAttributes\n}: FilterTableProps) => {\n const { filterBarProps } = useFilterTable({\n TableProps,\n FilterBarProps,\n });\n\n return (\n <DataSourceProvider dataSource={TableProps.dataSource}>\n <div\n {...htmlAttributes}\n className={classBase}\n style={{ ...styleProps, ...filterTableStyles }}\n >\n <FilterBar {...filterBarProps} />\n <Table {...TableProps} height=\"auto\" width=\"auto\" />\n </div>\n </DataSourceProvider>\n );\n};\n"],"names":["FilterBarProps","TableProps","useFilterTable","jsx","DataSourceProvider","jsxs","FilterBar","Table"],"mappings":";;;;;;;;AAMA,MAAM,SAAY,GAAA,gBAAA;AAIlB,MAAM,iBAGF,GAAA;AAAA,EACF,qBAAuB,EAAA,UAAA;AAAA,EACvB,6BAA+B,EAAA,UAAA;AAAA,EAC/B,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA;AACjB,CAAA;AAOO,MAAM,cAAc,CAAC;AAAA,EAC1B,cAAAA,EAAAA,eAAAA;AAAA,EACA,UAAAC,EAAAA,WAAAA;AAAA,EACA,KAAO,EAAA,UAAA;AAAA,EACP,GAAG;AACL,CAAwB,KAAA;AACtB,EAAM,MAAA,EAAE,cAAe,EAAA,GAAIC,6BAAe,CAAA;AAAA,IACxC,UAAAD,EAAAA,WAAAA;AAAA,IACA,cAAAD,EAAAA;AAAA,GACD,CAAA;AAED,EAAA,uBACGG,cAAA,CAAAC,2BAAA,EAAA,EAAmB,UAAYH,EAAAA,WAAAA,CAAW,UACzC,EAAA,QAAA,kBAAAI,eAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACE,GAAG,cAAA;AAAA,MACJ,SAAW,EAAA,SAAA;AAAA,MACX,KAAO,EAAA,EAAE,GAAG,UAAA,EAAY,GAAG,iBAAkB,EAAA;AAAA,MAE7C,QAAA,EAAA;AAAA,wBAACF,cAAA,CAAAG,oBAAA,EAAA,EAAW,GAAG,cAAgB,EAAA,CAAA;AAAA,uCAC9BC,cAAO,EAAA,EAAA,GAAGN,aAAY,MAAO,EAAA,MAAA,EAAO,OAAM,MAAO,EAAA;AAAA;AAAA;AAAA,GAEtD,EAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1,26 +1,22 @@
|
|
|
1
1
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import { FilterBar } from '@vuu-ui/vuu-filters';
|
|
3
3
|
import { Table } from '@vuu-ui/vuu-table';
|
|
4
|
-
import { useComponentCssInjection } from '@salt-ds/styles';
|
|
5
|
-
import { useWindow } from '@salt-ds/window';
|
|
6
|
-
import cx from 'clsx';
|
|
7
4
|
import { useFilterTable } from './useFilterTable.js';
|
|
8
|
-
import filterTableCss from './FilterTable.css.js';
|
|
9
5
|
import { DataSourceProvider } from '@vuu-ui/vuu-utils';
|
|
10
6
|
|
|
11
7
|
const classBase = "vuuFilterTable";
|
|
8
|
+
const filterTableStyles = {
|
|
9
|
+
"--vuuFilterBar-flex": "0 0 auto",
|
|
10
|
+
"--vuuMeasuredContainer-flex": "1 1 auto",
|
|
11
|
+
display: "flex",
|
|
12
|
+
flexDirection: "column"
|
|
13
|
+
};
|
|
12
14
|
const FilterTable = ({
|
|
13
15
|
FilterBarProps: FilterBarProps2,
|
|
14
16
|
TableProps: TableProps2,
|
|
15
17
|
style: styleProps,
|
|
16
18
|
...htmlAttributes
|
|
17
19
|
}) => {
|
|
18
|
-
const targetWindow = useWindow();
|
|
19
|
-
useComponentCssInjection({
|
|
20
|
-
testId: "vuu-filter-table",
|
|
21
|
-
css: filterTableCss,
|
|
22
|
-
window: targetWindow
|
|
23
|
-
});
|
|
24
20
|
const { filterBarProps } = useFilterTable({
|
|
25
21
|
TableProps: TableProps2,
|
|
26
22
|
FilterBarProps: FilterBarProps2
|
|
@@ -29,8 +25,8 @@ const FilterTable = ({
|
|
|
29
25
|
"div",
|
|
30
26
|
{
|
|
31
27
|
...htmlAttributes,
|
|
32
|
-
className:
|
|
33
|
-
style: { ...styleProps },
|
|
28
|
+
className: classBase,
|
|
29
|
+
style: { ...styleProps, ...filterTableStyles },
|
|
34
30
|
children: [
|
|
35
31
|
/* @__PURE__ */ jsx(FilterBar, { ...filterBarProps }),
|
|
36
32
|
/* @__PURE__ */ jsx(Table, { ...TableProps2, height: "auto", width: "auto" })
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FilterTable.js","sources":["../../../../packages/vuu-datatable/src/filter-table/FilterTable.tsx"],"sourcesContent":["import { FilterBar, FilterBarProps } from \"@vuu-ui/vuu-filters\";\nimport { Table, TableProps } from \"@vuu-ui/vuu-table\";\nimport {
|
|
1
|
+
{"version":3,"file":"FilterTable.js","sources":["../../../../packages/vuu-datatable/src/filter-table/FilterTable.tsx"],"sourcesContent":["import { FilterBar, FilterBarProps } from \"@vuu-ui/vuu-filters\";\nimport { Table, TableProps } from \"@vuu-ui/vuu-table\";\nimport { CSSProperties, HTMLAttributes } from \"react\";\nimport { useFilterTable } from \"./useFilterTable\";\nimport { DataSourceProvider } from \"@vuu-ui/vuu-utils\";\n\nconst classBase = \"vuuFilterTable\";\n\n// Use inline styles as the VuuFilter stylesheet may not have been loaded\n// by the time child elements need these val;ues to be in place.\nconst filterTableStyles: CSSProperties & {\n \"--vuuFilterBar-flex\": CSSProperties[\"flex\"];\n \"--vuuMeasuredContainer-flex\": CSSProperties[\"flex\"];\n} = {\n \"--vuuFilterBar-flex\": \"0 0 auto\",\n \"--vuuMeasuredContainer-flex\": \"1 1 auto\",\n display: \"flex\",\n flexDirection: \"column\",\n};\n\nexport interface FilterTableProps extends HTMLAttributes<HTMLDivElement> {\n FilterBarProps?: Partial<FilterBarProps>;\n TableProps: Omit<TableProps, \"height\" | \"width\">;\n}\n\nexport const FilterTable = ({\n FilterBarProps,\n TableProps,\n style: styleProps,\n ...htmlAttributes\n}: FilterTableProps) => {\n const { filterBarProps } = useFilterTable({\n TableProps,\n FilterBarProps,\n });\n\n return (\n <DataSourceProvider dataSource={TableProps.dataSource}>\n <div\n {...htmlAttributes}\n className={classBase}\n style={{ ...styleProps, ...filterTableStyles }}\n >\n <FilterBar {...filterBarProps} />\n <Table {...TableProps} height=\"auto\" width=\"auto\" />\n </div>\n </DataSourceProvider>\n );\n};\n"],"names":["FilterBarProps","TableProps"],"mappings":";;;;;;AAMA,MAAM,SAAY,GAAA,gBAAA;AAIlB,MAAM,iBAGF,GAAA;AAAA,EACF,qBAAuB,EAAA,UAAA;AAAA,EACvB,6BAA+B,EAAA,UAAA;AAAA,EAC/B,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA;AACjB,CAAA;AAOO,MAAM,cAAc,CAAC;AAAA,EAC1B,cAAAA,EAAAA,eAAAA;AAAA,EACA,UAAAC,EAAAA,WAAAA;AAAA,EACA,KAAO,EAAA,UAAA;AAAA,EACP,GAAG;AACL,CAAwB,KAAA;AACtB,EAAM,MAAA,EAAE,cAAe,EAAA,GAAI,cAAe,CAAA;AAAA,IACxC,UAAAA,EAAAA,WAAAA;AAAA,IACA,cAAAD,EAAAA;AAAA,GACD,CAAA;AAED,EAAA,uBACG,GAAA,CAAA,kBAAA,EAAA,EAAmB,UAAYC,EAAAA,WAAAA,CAAW,UACzC,EAAA,QAAA,kBAAA,IAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACE,GAAG,cAAA;AAAA,MACJ,SAAW,EAAA,SAAA;AAAA,MACX,KAAO,EAAA,EAAE,GAAG,UAAA,EAAY,GAAG,iBAAkB,EAAA;AAAA,MAE7C,QAAA,EAAA;AAAA,wBAAC,GAAA,CAAA,SAAA,EAAA,EAAW,GAAG,cAAgB,EAAA,CAAA;AAAA,4BAC9B,KAAO,EAAA,EAAA,GAAGA,aAAY,MAAO,EAAA,MAAA,EAAO,OAAM,MAAO,EAAA;AAAA;AAAA;AAAA,GAEtD,EAAA,CAAA;AAEJ;;;;"}
|
package/package.json
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "0.13.
|
|
2
|
+
"version": "0.13.95-alpha.2",
|
|
3
3
|
"author": "heswell",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"@salt-ds/core": "1.
|
|
6
|
+
"@salt-ds/core": "1.54.1",
|
|
7
7
|
"@salt-ds/styles": "0.2.1",
|
|
8
8
|
"@salt-ds/window": "0.1.1",
|
|
9
|
-
"@vuu-ui/vuu-data-local": "0.13.
|
|
10
|
-
"@vuu-ui/vuu-table-types": "0.13.
|
|
11
|
-
"@vuu-ui/vuu-filters": "0.13.
|
|
12
|
-
"@vuu-ui/vuu-layout": "0.13.
|
|
13
|
-
"@vuu-ui/vuu-popups": "0.13.
|
|
14
|
-
"@vuu-ui/vuu-shell": "0.13.
|
|
15
|
-
"@vuu-ui/vuu-table": "0.13.
|
|
16
|
-
"@vuu-ui/vuu-table-extras": "0.13.
|
|
17
|
-
"@vuu-ui/vuu-ui-controls": "0.13.
|
|
18
|
-
"@vuu-ui/vuu-utils": "0.13.
|
|
9
|
+
"@vuu-ui/vuu-data-local": "0.13.95-alpha.2",
|
|
10
|
+
"@vuu-ui/vuu-table-types": "0.13.95-alpha.2",
|
|
11
|
+
"@vuu-ui/vuu-filters": "0.13.95-alpha.2",
|
|
12
|
+
"@vuu-ui/vuu-layout": "0.13.95-alpha.2",
|
|
13
|
+
"@vuu-ui/vuu-popups": "0.13.95-alpha.2",
|
|
14
|
+
"@vuu-ui/vuu-shell": "0.13.95-alpha.2",
|
|
15
|
+
"@vuu-ui/vuu-table": "0.13.95-alpha.2",
|
|
16
|
+
"@vuu-ui/vuu-table-extras": "0.13.95-alpha.2",
|
|
17
|
+
"@vuu-ui/vuu-ui-controls": "0.13.95-alpha.2",
|
|
18
|
+
"@vuu-ui/vuu-utils": "0.13.95-alpha.2"
|
|
19
19
|
},
|
|
20
20
|
"peerDependencies": {
|
|
21
21
|
"clsx": "^2.0.0",
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var filterTableCss = ".vuuFilterTable {\n --vuuMeasuredContainer-flex: 1 1 auto;\n --vuuMeasuredContainer-height: auto;\n display: flex;\n flex-direction: column;\n\n .vuuFilterBar {\n flex: 0 0 auto;\n }\n}\n";
|
|
4
|
-
|
|
5
|
-
module.exports = filterTableCss;
|
|
6
|
-
//# sourceMappingURL=FilterTable.css.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FilterTable.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;"}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
var filterTableCss = ".vuuFilterTable {\n --vuuMeasuredContainer-flex: 1 1 auto;\n --vuuMeasuredContainer-height: auto;\n display: flex;\n flex-direction: column;\n\n .vuuFilterBar {\n flex: 0 0 auto;\n }\n}\n";
|
|
2
|
-
|
|
3
|
-
export { filterTableCss as default };
|
|
4
|
-
//# sourceMappingURL=FilterTable.css.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FilterTable.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|