@elliemae/ds-ribbon 2.0.0-alpha.10 → 2.0.0-alpha.14
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/DSRibbon.js +23 -36
- package/esm/DSRibbon.js +23 -36
- package/package.json +4 -5
- package/types/DSRibbon.d.ts +92 -14
- package/cjs/package.json +0 -7
- package/esm/package.json +0 -7
package/cjs/DSRibbon.js
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
+
require('core-js/modules/esnext.async-iterator.filter.js');
|
|
6
|
+
require('core-js/modules/esnext.iterator.constructor.js');
|
|
7
|
+
require('core-js/modules/esnext.iterator.filter.js');
|
|
8
|
+
require('core-js/modules/esnext.async-iterator.for-each.js');
|
|
9
|
+
require('core-js/modules/esnext.iterator.for-each.js');
|
|
5
10
|
var _defineProperty = require('@babel/runtime/helpers/defineProperty');
|
|
6
11
|
var _jsx = require('@babel/runtime/helpers/jsx');
|
|
7
12
|
require('react');
|
|
@@ -22,32 +27,13 @@ const RibbonRow = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
|
22
27
|
componentId: "sc-9boes5-0"
|
|
23
28
|
})(["width:100%;display:flex;flex-direction:row;align-items:center;min-height:4rem;@media screen and (-ms-high-contrast:active),(-ms-high-contrast:none){height:5rem;overflow-y:hidden;}flex-wrap:nowrap;overflow-x:auto;", ";", ";"], props => {
|
|
24
29
|
if (props.alignLeft) {
|
|
25
|
-
return
|
|
26
|
-
align-items: stretch;
|
|
27
|
-
& > ${RibbonCol} {
|
|
28
|
-
align-items: flex-start;
|
|
29
|
-
align-self: stretch;
|
|
30
|
-
flex: 0;
|
|
31
|
-
@media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {
|
|
32
|
-
flex: 1;
|
|
33
|
-
}
|
|
34
|
-
`;
|
|
30
|
+
return "\n align-items: stretch;\n & > ".concat(RibbonCol, " {\n align-items: flex-start;\n align-self: stretch; \n flex: 0;\n @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {\n flex: 1;\n }\n ");
|
|
35
31
|
}
|
|
36
32
|
|
|
37
|
-
return
|
|
38
|
-
// flex:1;
|
|
39
|
-
align-items: center;
|
|
40
|
-
`;
|
|
33
|
+
return "\n // flex:1;\n align-items: center;\n ";
|
|
41
34
|
}, props => {
|
|
42
35
|
if (props.solid) {
|
|
43
|
-
return
|
|
44
|
-
& > ${RibbonCol} {
|
|
45
|
-
&:after{
|
|
46
|
-
top: 0%;
|
|
47
|
-
height: 100%;
|
|
48
|
-
border-right: solid 1px #CBCFD7;
|
|
49
|
-
}
|
|
50
|
-
`;
|
|
36
|
+
return "\n & > ".concat(RibbonCol, " {\n &:after{\n top: 0%;\n height: 100%;\n border-right: solid 1px #CBCFD7;\n }\n ");
|
|
51
37
|
}
|
|
52
38
|
|
|
53
39
|
return '';
|
|
@@ -96,22 +82,23 @@ const RibbonBlock = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
|
96
82
|
componentId: "sc-9boes5-9"
|
|
97
83
|
})(["flex:1;height:100%;"]);
|
|
98
84
|
|
|
99
|
-
function RibbonCard({
|
|
100
|
-
containerProps = {},
|
|
101
|
-
icon = null,
|
|
102
|
-
label = '',
|
|
103
|
-
value = '',
|
|
104
|
-
additionalValue = '',
|
|
105
|
-
additionalLabel = '',
|
|
106
|
-
info = false,
|
|
107
|
-
error = false,
|
|
108
|
-
warning = false,
|
|
109
|
-
success = false,
|
|
110
|
-
center = false,
|
|
111
|
-
solid = false
|
|
112
|
-
}) {
|
|
85
|
+
function RibbonCard(_ref) {
|
|
113
86
|
var _RibbonBlockValue;
|
|
114
87
|
|
|
88
|
+
let {
|
|
89
|
+
containerProps = {},
|
|
90
|
+
icon = null,
|
|
91
|
+
label = '',
|
|
92
|
+
value = '',
|
|
93
|
+
additionalValue = '',
|
|
94
|
+
additionalLabel = '',
|
|
95
|
+
info = false,
|
|
96
|
+
error = false,
|
|
97
|
+
warning = false,
|
|
98
|
+
success = false,
|
|
99
|
+
center = false,
|
|
100
|
+
solid = false
|
|
101
|
+
} = _ref;
|
|
115
102
|
const labelPlace = icon ? /*#__PURE__*/_jsx__default["default"](RibbonBlockIcon, {
|
|
116
103
|
error: error,
|
|
117
104
|
info: info,
|
package/esm/DSRibbon.js
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
import 'core-js/modules/esnext.async-iterator.filter.js';
|
|
2
|
+
import 'core-js/modules/esnext.iterator.constructor.js';
|
|
3
|
+
import 'core-js/modules/esnext.iterator.filter.js';
|
|
4
|
+
import 'core-js/modules/esnext.async-iterator.for-each.js';
|
|
5
|
+
import 'core-js/modules/esnext.iterator.for-each.js';
|
|
1
6
|
import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
|
|
2
7
|
import _jsx from '@babel/runtime/helpers/esm/jsx';
|
|
3
8
|
import 'react';
|
|
@@ -12,32 +17,13 @@ const RibbonRow = /*#__PURE__*/styled.div.withConfig({
|
|
|
12
17
|
componentId: "sc-9boes5-0"
|
|
13
18
|
})(["width:100%;display:flex;flex-direction:row;align-items:center;min-height:4rem;@media screen and (-ms-high-contrast:active),(-ms-high-contrast:none){height:5rem;overflow-y:hidden;}flex-wrap:nowrap;overflow-x:auto;", ";", ";"], props => {
|
|
14
19
|
if (props.alignLeft) {
|
|
15
|
-
return
|
|
16
|
-
align-items: stretch;
|
|
17
|
-
& > ${RibbonCol} {
|
|
18
|
-
align-items: flex-start;
|
|
19
|
-
align-self: stretch;
|
|
20
|
-
flex: 0;
|
|
21
|
-
@media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {
|
|
22
|
-
flex: 1;
|
|
23
|
-
}
|
|
24
|
-
`;
|
|
20
|
+
return "\n align-items: stretch;\n & > ".concat(RibbonCol, " {\n align-items: flex-start;\n align-self: stretch; \n flex: 0;\n @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {\n flex: 1;\n }\n ");
|
|
25
21
|
}
|
|
26
22
|
|
|
27
|
-
return
|
|
28
|
-
// flex:1;
|
|
29
|
-
align-items: center;
|
|
30
|
-
`;
|
|
23
|
+
return "\n // flex:1;\n align-items: center;\n ";
|
|
31
24
|
}, props => {
|
|
32
25
|
if (props.solid) {
|
|
33
|
-
return
|
|
34
|
-
& > ${RibbonCol} {
|
|
35
|
-
&:after{
|
|
36
|
-
top: 0%;
|
|
37
|
-
height: 100%;
|
|
38
|
-
border-right: solid 1px #CBCFD7;
|
|
39
|
-
}
|
|
40
|
-
`;
|
|
26
|
+
return "\n & > ".concat(RibbonCol, " {\n &:after{\n top: 0%;\n height: 100%;\n border-right: solid 1px #CBCFD7;\n }\n ");
|
|
41
27
|
}
|
|
42
28
|
|
|
43
29
|
return '';
|
|
@@ -86,22 +72,23 @@ const RibbonBlock = /*#__PURE__*/styled.div.withConfig({
|
|
|
86
72
|
componentId: "sc-9boes5-9"
|
|
87
73
|
})(["flex:1;height:100%;"]);
|
|
88
74
|
|
|
89
|
-
function RibbonCard({
|
|
90
|
-
containerProps = {},
|
|
91
|
-
icon = null,
|
|
92
|
-
label = '',
|
|
93
|
-
value = '',
|
|
94
|
-
additionalValue = '',
|
|
95
|
-
additionalLabel = '',
|
|
96
|
-
info = false,
|
|
97
|
-
error = false,
|
|
98
|
-
warning = false,
|
|
99
|
-
success = false,
|
|
100
|
-
center = false,
|
|
101
|
-
solid = false
|
|
102
|
-
}) {
|
|
75
|
+
function RibbonCard(_ref) {
|
|
103
76
|
var _RibbonBlockValue;
|
|
104
77
|
|
|
78
|
+
let {
|
|
79
|
+
containerProps = {},
|
|
80
|
+
icon = null,
|
|
81
|
+
label = '',
|
|
82
|
+
value = '',
|
|
83
|
+
additionalValue = '',
|
|
84
|
+
additionalLabel = '',
|
|
85
|
+
info = false,
|
|
86
|
+
error = false,
|
|
87
|
+
warning = false,
|
|
88
|
+
success = false,
|
|
89
|
+
center = false,
|
|
90
|
+
solid = false
|
|
91
|
+
} = _ref;
|
|
105
92
|
const labelPlace = icon ? /*#__PURE__*/_jsx(RibbonBlockIcon, {
|
|
106
93
|
error: error,
|
|
107
94
|
info: info,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-ribbon",
|
|
3
|
-
"version": "2.0.0-alpha.
|
|
3
|
+
"version": "2.0.0-alpha.14",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Ribbon",
|
|
6
6
|
"module": "./esm/index.js",
|
|
@@ -36,17 +36,16 @@
|
|
|
36
36
|
"build": "node ../../scripts/build/build.js"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"
|
|
40
|
-
"@elliemae/ds-classnames": "2.0.0-alpha.10"
|
|
39
|
+
"react-desc": "~4.1.3"
|
|
41
40
|
},
|
|
42
41
|
"devDependencies": {
|
|
43
|
-
"styled-components": "~5.3.
|
|
42
|
+
"styled-components": "~5.3.3"
|
|
44
43
|
},
|
|
45
44
|
"peerDependencies": {
|
|
46
45
|
"lodash": "^4.17.21",
|
|
47
46
|
"react": "~17.0.2",
|
|
48
47
|
"react-dom": "^17.0.2",
|
|
49
|
-
"styled-components": "^5.3.
|
|
48
|
+
"styled-components": "^5.3.3"
|
|
50
49
|
},
|
|
51
50
|
"publishConfig": {
|
|
52
51
|
"access": "public",
|
package/types/DSRibbon.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference path="../../../../shared/typings/react-desc.d.ts" />
|
|
1
2
|
/// <reference types="react" />
|
|
2
3
|
declare function RibbonCard({ containerProps, icon, label, value, additionalValue, additionalLabel, info, error, warning, success, center, solid, }: {
|
|
3
4
|
containerProps?: {} | undefined;
|
|
@@ -16,37 +17,114 @@ declare function RibbonCard({ containerProps, icon, label, value, additionalValu
|
|
|
16
17
|
declare namespace RibbonCard {
|
|
17
18
|
var propTypes: {
|
|
18
19
|
/** props to inject to wrapper */
|
|
19
|
-
containerProps:
|
|
20
|
+
containerProps: {
|
|
21
|
+
defaultValue<T = unknown>(arg: T): {
|
|
22
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
23
|
+
};
|
|
24
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
25
|
+
};
|
|
20
26
|
/** icon for ribbon card */
|
|
21
|
-
icon:
|
|
27
|
+
icon: {
|
|
28
|
+
defaultValue<T = unknown>(arg: T): {
|
|
29
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
30
|
+
};
|
|
31
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
32
|
+
};
|
|
22
33
|
/** label for ribbon card */
|
|
23
|
-
label:
|
|
34
|
+
label: {
|
|
35
|
+
defaultValue<T = unknown>(arg: T): {
|
|
36
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
37
|
+
};
|
|
38
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
39
|
+
};
|
|
24
40
|
/** value for ribbon */
|
|
25
|
-
value:
|
|
41
|
+
value: {
|
|
42
|
+
defaultValue<T = unknown>(arg: T): {
|
|
43
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
44
|
+
};
|
|
45
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
46
|
+
};
|
|
26
47
|
/** additional value */
|
|
27
|
-
additionalValue:
|
|
48
|
+
additionalValue: {
|
|
49
|
+
defaultValue<T = unknown>(arg: T): {
|
|
50
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
51
|
+
};
|
|
52
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
53
|
+
};
|
|
28
54
|
/** additional label */
|
|
29
|
-
additionalLabel:
|
|
55
|
+
additionalLabel: {
|
|
56
|
+
defaultValue<T = unknown>(arg: T): {
|
|
57
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
58
|
+
};
|
|
59
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
60
|
+
};
|
|
30
61
|
/** for main label */
|
|
31
|
-
info:
|
|
62
|
+
info: {
|
|
63
|
+
defaultValue<T = unknown>(arg: T): {
|
|
64
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
65
|
+
};
|
|
66
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
67
|
+
};
|
|
32
68
|
/** error state toggle */
|
|
33
|
-
error:
|
|
69
|
+
error: {
|
|
70
|
+
defaultValue<T = unknown>(arg: T): {
|
|
71
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
72
|
+
};
|
|
73
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
74
|
+
};
|
|
34
75
|
/** warning state toggle */
|
|
35
|
-
warning:
|
|
76
|
+
warning: {
|
|
77
|
+
defaultValue<T = unknown>(arg: T): {
|
|
78
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
79
|
+
};
|
|
80
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
81
|
+
};
|
|
36
82
|
/** success state toggle */
|
|
37
|
-
success:
|
|
83
|
+
success: {
|
|
84
|
+
defaultValue<T = unknown>(arg: T): {
|
|
85
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
86
|
+
};
|
|
87
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
88
|
+
};
|
|
38
89
|
/** align center */
|
|
39
|
-
center:
|
|
90
|
+
center: {
|
|
91
|
+
defaultValue<T = unknown>(arg: T): {
|
|
92
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
93
|
+
};
|
|
94
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
95
|
+
};
|
|
40
96
|
/** solid style */
|
|
41
|
-
solid:
|
|
97
|
+
solid: {
|
|
98
|
+
defaultValue<T = unknown>(arg: T): {
|
|
99
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
100
|
+
};
|
|
101
|
+
isRequired: import("react-desc").PropTypesDescValidator;
|
|
102
|
+
};
|
|
42
103
|
};
|
|
43
104
|
}
|
|
44
105
|
declare const DSRibbon: {
|
|
45
|
-
RibbonWrapper: import("styled-components").StyledComponent<"div",
|
|
106
|
+
RibbonWrapper: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
46
107
|
RibbonRow: any;
|
|
47
108
|
RibbonCol: any;
|
|
48
109
|
RibbonCard: typeof RibbonCard;
|
|
49
110
|
};
|
|
50
|
-
declare const DSRibbonCardWithSchema:
|
|
111
|
+
declare const DSRibbonCardWithSchema: {
|
|
112
|
+
(props?: {
|
|
113
|
+
containerProps?: {} | undefined;
|
|
114
|
+
icon?: null | undefined;
|
|
115
|
+
label?: string | undefined;
|
|
116
|
+
value?: string | undefined;
|
|
117
|
+
additionalValue?: string | undefined;
|
|
118
|
+
additionalLabel?: string | undefined;
|
|
119
|
+
info?: boolean | undefined;
|
|
120
|
+
error?: boolean | undefined;
|
|
121
|
+
warning?: boolean | undefined;
|
|
122
|
+
success?: boolean | undefined;
|
|
123
|
+
center?: boolean | undefined;
|
|
124
|
+
solid?: boolean | undefined;
|
|
125
|
+
} | undefined): JSX.Element;
|
|
126
|
+
propTypes: unknown;
|
|
127
|
+
toTypescript: () => import("react-desc").TypescriptSchema;
|
|
128
|
+
};
|
|
51
129
|
export default DSRibbon;
|
|
52
130
|
export { DSRibbonCardWithSchema };
|
package/cjs/package.json
DELETED