@elliemae/ds-page-layout 2.0.0-alpha.1 → 2.0.0-alpha.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/cjs/PageLayout.js +18 -16
- package/cjs/index.js +1 -1
- package/esm/PageLayout.js +11 -9
- package/package.json +4 -5
- package/types/PageLayout.d.ts +40 -2
- package/types/props.d.ts +33 -7
- package/cjs/package.json +0 -7
- package/esm/package.json +0 -7
package/cjs/PageLayout.js
CHANGED
|
@@ -12,15 +12,17 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
|
|
|
12
12
|
|
|
13
13
|
var _jsx__default = /*#__PURE__*/_interopDefaultLegacy(_jsx);
|
|
14
14
|
|
|
15
|
-
const PageLayout =
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
15
|
+
const PageLayout = _ref => {
|
|
16
|
+
let {
|
|
17
|
+
GlobalHeader,
|
|
18
|
+
ContextHeader,
|
|
19
|
+
PageHeader,
|
|
20
|
+
ContentRegion,
|
|
21
|
+
LeftNav,
|
|
22
|
+
SidePanel,
|
|
23
|
+
Footer
|
|
24
|
+
} = _ref;
|
|
25
|
+
|
|
24
26
|
const mainRegionRows = () => {
|
|
25
27
|
if (PageHeader && Footer) return ['auto', '1fr', 'auto'];
|
|
26
28
|
if (PageHeader && !Footer) return ['auto', '1fr'];
|
|
@@ -28,29 +30,29 @@ const PageLayout = ({
|
|
|
28
30
|
if (!PageHeader && Footer) return ['1fr', 'auto'];
|
|
29
31
|
};
|
|
30
32
|
|
|
31
|
-
return /*#__PURE__*/_jsx__default[
|
|
33
|
+
return /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
32
34
|
style: {
|
|
33
35
|
width: '100%'
|
|
34
36
|
},
|
|
35
37
|
height: "100vh",
|
|
36
38
|
rows: ContextHeader ? ['auto', 'auto', '1fr'] : ['auto', '1fr'],
|
|
37
39
|
"data-testid": "page-layout"
|
|
38
|
-
}, void 0, GlobalHeader && /*#__PURE__*/_jsx__default[
|
|
40
|
+
}, void 0, GlobalHeader && /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {}, void 0, /*#__PURE__*/_jsx__default["default"](GlobalHeader, {})), ContextHeader && /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {}, void 0, /*#__PURE__*/_jsx__default["default"](ContextHeader, {})), /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
39
41
|
cols: LeftNav ? ['auto', '1fr'] : ['auto']
|
|
40
|
-
}, void 0, LeftNav && /*#__PURE__*/_jsx__default[
|
|
42
|
+
}, void 0, LeftNav && /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {}, void 0, /*#__PURE__*/_jsx__default["default"](LeftNav, {})), /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
41
43
|
rows: mainRegionRows()
|
|
42
|
-
}, void 0, PageHeader && /*#__PURE__*/_jsx__default[
|
|
44
|
+
}, void 0, PageHeader && /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
43
45
|
style: {
|
|
44
46
|
minHeight: "48px"
|
|
45
47
|
}
|
|
46
|
-
}, void 0, /*#__PURE__*/_jsx__default[
|
|
48
|
+
}, void 0, /*#__PURE__*/_jsx__default["default"](PageHeader, {})), ContentRegion && /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
47
49
|
cols: SidePanel ? ['auto', 'fit-content(100%)'] : ['auto']
|
|
48
|
-
}, void 0, /*#__PURE__*/_jsx__default[
|
|
50
|
+
}, void 0, /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
49
51
|
style: {
|
|
50
52
|
minHeight: "480px",
|
|
51
53
|
overflow: "scroll"
|
|
52
54
|
}
|
|
53
|
-
}, void 0, /*#__PURE__*/_jsx__default[
|
|
55
|
+
}, void 0, /*#__PURE__*/_jsx__default["default"](ContentRegion, {})), SidePanel && /*#__PURE__*/_jsx__default["default"](SidePanel, {})), Footer && /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {}, void 0, /*#__PURE__*/_jsx__default["default"](Footer, {})))));
|
|
54
56
|
};
|
|
55
57
|
|
|
56
58
|
const PageLayoutWithSchema = reactDesc.describe(PageLayout);
|
package/cjs/index.js
CHANGED
package/esm/PageLayout.js
CHANGED
|
@@ -4,15 +4,17 @@ import { pageLayoutProps } from './props.js';
|
|
|
4
4
|
import { describe } from 'react-desc';
|
|
5
5
|
import { Grid } from '@elliemae/ds-grid';
|
|
6
6
|
|
|
7
|
-
const PageLayout =
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
7
|
+
const PageLayout = _ref => {
|
|
8
|
+
let {
|
|
9
|
+
GlobalHeader,
|
|
10
|
+
ContextHeader,
|
|
11
|
+
PageHeader,
|
|
12
|
+
ContentRegion,
|
|
13
|
+
LeftNav,
|
|
14
|
+
SidePanel,
|
|
15
|
+
Footer
|
|
16
|
+
} = _ref;
|
|
17
|
+
|
|
16
18
|
const mainRegionRows = () => {
|
|
17
19
|
if (PageHeader && Footer) return ['auto', '1fr', 'auto'];
|
|
18
20
|
if (PageHeader && !Footer) return ['auto', '1fr'];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-page-layout",
|
|
3
|
-
"version": "2.0.0-alpha.
|
|
3
|
+
"version": "2.0.0-alpha.13",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Page Layout",
|
|
6
6
|
"module": "./esm/index.js",
|
|
@@ -40,18 +40,17 @@
|
|
|
40
40
|
"build": "node ../../scripts/build/build.js"
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
|
-
"@elliemae/ds-grid": "2.0.0-alpha.
|
|
44
|
-
"@elliemae/ds-system": "2.0.0-alpha.1",
|
|
43
|
+
"@elliemae/ds-grid": "2.0.0-alpha.13",
|
|
45
44
|
"react-desc": "~4.1.3"
|
|
46
45
|
},
|
|
47
46
|
"devDependencies": {
|
|
48
|
-
"styled-components": "~5.3.
|
|
47
|
+
"styled-components": "~5.3.3"
|
|
49
48
|
},
|
|
50
49
|
"peerDependencies": {
|
|
51
50
|
"lodash": "^4.17.21",
|
|
52
51
|
"react": "^17.0.2",
|
|
53
52
|
"react-dom": "^17.0.2",
|
|
54
|
-
"styled-components": "^5.3.
|
|
53
|
+
"styled-components": "^5.3.3"
|
|
55
54
|
},
|
|
56
55
|
"publishConfig": {
|
|
57
56
|
"access": "public",
|
package/types/PageLayout.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference path="../../../../shared/typings/react-desc.d.ts" />
|
|
1
2
|
/// <reference types="react" />
|
|
2
3
|
declare const PageLayout: {
|
|
3
4
|
({ GlobalHeader, ContextHeader, PageHeader, ContentRegion, LeftNav, SidePanel, Footer, }: {
|
|
@@ -10,6 +11,42 @@ declare const PageLayout: {
|
|
|
10
11
|
Footer: any;
|
|
11
12
|
}): JSX.Element;
|
|
12
13
|
propTypes: {
|
|
14
|
+
GlobalHeader: import("react-desc").PropTypesDescValidator;
|
|
15
|
+
ContextHeader: {
|
|
16
|
+
defaultValue<T = unknown>(arg: T): {
|
|
17
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
18
|
+
};
|
|
19
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
20
|
+
};
|
|
21
|
+
PageHeader: {
|
|
22
|
+
defaultValue<T = unknown>(arg: T): {
|
|
23
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
24
|
+
};
|
|
25
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
26
|
+
};
|
|
27
|
+
ContentRegion: import("react-desc").PropTypesDescValidator;
|
|
28
|
+
LeftNav: {
|
|
29
|
+
defaultValue<T = unknown>(arg: T): {
|
|
30
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
31
|
+
};
|
|
32
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
33
|
+
};
|
|
34
|
+
SidePanel: {
|
|
35
|
+
defaultValue<T = unknown>(arg: T): {
|
|
36
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
37
|
+
};
|
|
38
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
39
|
+
};
|
|
40
|
+
Footer: {
|
|
41
|
+
defaultValue<T = unknown>(arg: T): {
|
|
42
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
43
|
+
};
|
|
44
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
declare const PageLayoutWithSchema: {
|
|
49
|
+
(props?: {
|
|
13
50
|
GlobalHeader: any;
|
|
14
51
|
ContextHeader: any;
|
|
15
52
|
PageHeader: any;
|
|
@@ -17,7 +54,8 @@ declare const PageLayout: {
|
|
|
17
54
|
LeftNav: any;
|
|
18
55
|
SidePanel: any;
|
|
19
56
|
Footer: any;
|
|
20
|
-
};
|
|
57
|
+
} | undefined): JSX.Element;
|
|
58
|
+
propTypes: unknown;
|
|
59
|
+
toTypescript: () => import("react-desc").TypescriptSchema;
|
|
21
60
|
};
|
|
22
|
-
declare const PageLayoutWithSchema: any;
|
|
23
61
|
export { PageLayout, PageLayoutWithSchema };
|
package/types/props.d.ts
CHANGED
|
@@ -1,9 +1,35 @@
|
|
|
1
|
+
/// <reference path="../../../../shared/typings/react-desc.d.ts" />
|
|
1
2
|
export declare const pageLayoutProps: {
|
|
2
|
-
GlobalHeader:
|
|
3
|
-
ContextHeader:
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
3
|
+
GlobalHeader: import("react-desc").PropTypesDescValidator;
|
|
4
|
+
ContextHeader: {
|
|
5
|
+
defaultValue<T = unknown>(arg: T): {
|
|
6
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
7
|
+
};
|
|
8
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
9
|
+
};
|
|
10
|
+
PageHeader: {
|
|
11
|
+
defaultValue<T = unknown>(arg: T): {
|
|
12
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
13
|
+
};
|
|
14
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
15
|
+
};
|
|
16
|
+
ContentRegion: import("react-desc").PropTypesDescValidator;
|
|
17
|
+
LeftNav: {
|
|
18
|
+
defaultValue<T = unknown>(arg: T): {
|
|
19
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
20
|
+
};
|
|
21
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
22
|
+
};
|
|
23
|
+
SidePanel: {
|
|
24
|
+
defaultValue<T = unknown>(arg: T): {
|
|
25
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
26
|
+
};
|
|
27
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
28
|
+
};
|
|
29
|
+
Footer: {
|
|
30
|
+
defaultValue<T = unknown>(arg: T): {
|
|
31
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
32
|
+
};
|
|
33
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
34
|
+
};
|
|
9
35
|
};
|
package/cjs/package.json
DELETED