@telia-ace/widget-types-grid 1.0.3 → 1.0.7
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/lib/ui/component.d.ts
CHANGED
|
@@ -9,6 +9,9 @@ declare type Props = {
|
|
|
9
9
|
node?: ComponentNode;
|
|
10
10
|
ariaLabel?: string;
|
|
11
11
|
tabIndex?: number;
|
|
12
|
+
context?: {
|
|
13
|
+
[key: string]: any;
|
|
14
|
+
};
|
|
12
15
|
};
|
|
13
16
|
declare const Component: React.ForwardRefExoticComponent<Props & React.RefAttributes<HTMLElement>>;
|
|
14
17
|
export declare const styling: import("styled-components").FlattenInterpolation<import("styled-components").ThemedStyledProps<{
|
package/lib/ui/component.js
CHANGED
|
@@ -88,7 +88,7 @@ var isVisible = function (size, node) {
|
|
|
88
88
|
};
|
|
89
89
|
var Component = (0, react_1.forwardRef)(function (_a, ref) {
|
|
90
90
|
var _b;
|
|
91
|
-
var _c = _a.className, className = _c === void 0 ? '' : _c, _d = _a.isTabbing, isTabbing = _d === void 0 ? false : _d, id = _a.id, branch = _a.branch, node = _a.node, ariaLabel = _a.ariaLabel, tabIndex = _a.tabIndex, other = __rest(_a, ["className", "isTabbing", "id", "branch", "node", "ariaLabel", "tabIndex"]);
|
|
91
|
+
var _c = _a.className, className = _c === void 0 ? '' : _c, _d = _a.isTabbing, isTabbing = _d === void 0 ? false : _d, id = _a.id, branch = _a.branch, node = _a.node, ariaLabel = _a.ariaLabel, tabIndex = _a.tabIndex, extraContext = _a.context, other = __rest(_a, ["className", "isTabbing", "id", "branch", "node", "ariaLabel", "tabIndex", "context"]);
|
|
92
92
|
var components = (0, widget_ui_1.useComponentPlatform)();
|
|
93
93
|
var container = (0, widget_ui_1.useContainer)();
|
|
94
94
|
var _e = __read((0, react_1.useState)(), 2), descriptor = _e[0], setDescriptor = _e[1];
|
|
@@ -124,7 +124,8 @@ var Component = (0, react_1.forwardRef)(function (_a, ref) {
|
|
|
124
124
|
if (!descriptor || !visible) {
|
|
125
125
|
return null;
|
|
126
126
|
}
|
|
127
|
-
var
|
|
127
|
+
var mergedContexts = __assign(__assign({}, context), (extraContext || {}));
|
|
128
|
+
var cardinal = mergedContexts.cardinal, _j = mergedContexts.fonts, contextFonts = _j === void 0 ? {} : _j, _k = mergedContexts.accessibility, accessibility = _k === void 0 ? {} : _k, restContext = __rest(mergedContexts, ["cardinal", "fonts", "accessibility"]);
|
|
128
129
|
var fonts = {
|
|
129
130
|
type: contextFonts.type,
|
|
130
131
|
base: contextFonts.base || '16px',
|
|
@@ -9,6 +9,9 @@ declare type Props = {
|
|
|
9
9
|
node?: ComponentNode;
|
|
10
10
|
ariaLabel?: string;
|
|
11
11
|
tabIndex?: number;
|
|
12
|
+
context?: {
|
|
13
|
+
[key: string]: any;
|
|
14
|
+
};
|
|
12
15
|
};
|
|
13
16
|
declare const Component: React.ForwardRefExoticComponent<Props & React.RefAttributes<HTMLElement>>;
|
|
14
17
|
export declare const styling: import("styled-components").FlattenInterpolation<import("styled-components").ThemedStyledProps<{
|
package/lib-esm/ui/component.js
CHANGED
|
@@ -59,7 +59,7 @@ var isVisible = function (size, node) {
|
|
|
59
59
|
};
|
|
60
60
|
var Component = forwardRef(function (_a, ref) {
|
|
61
61
|
var _b;
|
|
62
|
-
var _c = _a.className, className = _c === void 0 ? '' : _c, _d = _a.isTabbing, isTabbing = _d === void 0 ? false : _d, id = _a.id, branch = _a.branch, node = _a.node, ariaLabel = _a.ariaLabel, tabIndex = _a.tabIndex, other = __rest(_a, ["className", "isTabbing", "id", "branch", "node", "ariaLabel", "tabIndex"]);
|
|
62
|
+
var _c = _a.className, className = _c === void 0 ? '' : _c, _d = _a.isTabbing, isTabbing = _d === void 0 ? false : _d, id = _a.id, branch = _a.branch, node = _a.node, ariaLabel = _a.ariaLabel, tabIndex = _a.tabIndex, extraContext = _a.context, other = __rest(_a, ["className", "isTabbing", "id", "branch", "node", "ariaLabel", "tabIndex", "context"]);
|
|
63
63
|
var components = useComponentPlatform();
|
|
64
64
|
var container = useContainer();
|
|
65
65
|
var _e = __read(useState(), 2), descriptor = _e[0], setDescriptor = _e[1];
|
|
@@ -95,7 +95,8 @@ var Component = forwardRef(function (_a, ref) {
|
|
|
95
95
|
if (!descriptor || !visible) {
|
|
96
96
|
return null;
|
|
97
97
|
}
|
|
98
|
-
var
|
|
98
|
+
var mergedContexts = __assign(__assign({}, context), (extraContext || {}));
|
|
99
|
+
var cardinal = mergedContexts.cardinal, _j = mergedContexts.fonts, contextFonts = _j === void 0 ? {} : _j, _k = mergedContexts.accessibility, accessibility = _k === void 0 ? {} : _k, restContext = __rest(mergedContexts, ["cardinal", "fonts", "accessibility"]);
|
|
99
100
|
var fonts = {
|
|
100
101
|
type: contextFonts.type,
|
|
101
102
|
base: contextFonts.base || '16px',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@telia-ace/widget-types-grid",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.7",
|
|
4
4
|
"description": "Type definition for Grid widget.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"author": "Telia Company AB",
|
|
@@ -25,12 +25,12 @@
|
|
|
25
25
|
"sideEffects": false,
|
|
26
26
|
"typings": "lib/index.d.ts",
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@telia-ace/knowledge-serviceclient": "^1.0.
|
|
29
|
-
"@telia-ace/widget-core": "^1.0.
|
|
30
|
-
"@telia-ace/widget-forms": "^1.0.
|
|
31
|
-
"@telia-ace/widget-routing": "^1.0.
|
|
32
|
-
"@telia-ace/widget-services": "^1.0.
|
|
33
|
-
"@telia-ace/widget-ui": "^1.0.
|
|
28
|
+
"@telia-ace/knowledge-serviceclient": "^1.0.3",
|
|
29
|
+
"@telia-ace/widget-core": "^1.0.4",
|
|
30
|
+
"@telia-ace/widget-forms": "^1.0.7",
|
|
31
|
+
"@telia-ace/widget-routing": "^1.0.5",
|
|
32
|
+
"@telia-ace/widget-services": "^1.0.4",
|
|
33
|
+
"@telia-ace/widget-ui": "^1.0.7",
|
|
34
34
|
"@telia-ace/widget-utilities": "^1.0.1",
|
|
35
35
|
"@webprovisions/bootstrapping": "^1.0.12",
|
|
36
36
|
"@webprovisions/platform": "^1.1.2",
|
|
@@ -48,5 +48,5 @@
|
|
|
48
48
|
"@types/react-transition-group": "^4.4.4",
|
|
49
49
|
"@types/styled-components": "^5.1.7"
|
|
50
50
|
},
|
|
51
|
-
"gitHead": "
|
|
51
|
+
"gitHead": "d0810784ed9655d556f5653a168d13b8f71910b7"
|
|
52
52
|
}
|