pds-dev-kit-web 0.3.49 → 0.4.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/README.md +2 -2
- package/dist/index.d.ts +8 -7
- package/dist/index.js +5 -2
- package/dist/src/common/index.d.ts +2 -1
- package/dist/src/common/index.js +3 -1
- package/dist/src/common/services/i18n/resources/en.json +45 -21
- package/dist/src/common/services/i18n/resources/es.json +45 -21
- package/dist/src/common/services/i18n/resources/index.d.ts +96 -0
- package/dist/src/common/services/i18n/resources/jp.json +45 -21
- package/dist/src/common/services/i18n/resources/ko.json +45 -21
- package/dist/src/common/styles/colorSet/PaletteColor_Dark.json +2 -1
- package/dist/src/common/styles/colorSet/PaletteColor_light.json +2 -1
- package/dist/src/common/styles/colorSet/SemanticColor.json +2 -1
- package/dist/src/common/styles/colorSet/index.d.ts +57 -54
- package/dist/src/common/styles/colorSet/index.js +2 -2
- package/dist/src/common/styles/ui-colors.d.ts +2 -0
- package/dist/src/common/styles/ui-colors.js +22 -4
- package/dist/src/desktop/components/Hero/Hero.js +5 -0
- package/dist/src/{hybrid → desktop}/components/IconButton/IconButton.d.ts +1 -1
- package/dist/src/{hybrid → desktop}/components/IconButton/IconButton.js +3 -2
- package/dist/src/{hybrid → desktop}/components/IconButton/index.d.ts +0 -0
- package/dist/src/{hybrid → desktop}/components/IconButton/index.js +0 -0
- package/dist/src/desktop/components/StatusBlock/StatusBlock.js +2 -0
- package/dist/src/desktop/components/index.d.ts +2 -1
- package/dist/src/desktop/components/index.js +3 -1
- package/dist/src/desktop/index.d.ts +2 -2
- package/dist/src/desktop/index.js +2 -1
- package/dist/src/hybrid/components/index.d.ts +1 -2
- package/dist/src/hybrid/components/index.js +1 -3
- package/dist/src/hybrid/index.d.ts +2 -2
- package/dist/src/hybrid/index.js +1 -2
- package/dist/src/mobile/components/IconButton/IconButton.d.ts +26 -0
- package/dist/src/mobile/components/IconButton/IconButton.js +148 -0
- package/dist/src/mobile/components/IconButton/index.d.ts +1 -0
- package/dist/src/mobile/components/IconButton/index.js +8 -0
- package/dist/src/mobile/components/index.d.ts +2 -1
- package/dist/src/mobile/components/index.js +3 -1
- package/dist/src/mobile/index.d.ts +2 -2
- package/dist/src/mobile/index.js +2 -1
- package/package.json +1 -1
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
|
|
3
|
+
if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
|
|
4
|
+
return cooked;
|
|
5
|
+
};
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
var react_1 = __importDefault(require("react"));
|
|
30
|
+
var styled_components_1 = __importStar(require("styled-components"));
|
|
31
|
+
var ui_colors_1 = require("../../../common/styles/ui-colors");
|
|
32
|
+
var hybrid_1 = require("../../../hybrid");
|
|
33
|
+
function IconButton(_a) {
|
|
34
|
+
var _b = _a.fillType, fillType = _b === void 0 ? 'fill' : _b, _c = _a.shapeType, shapeType = _c === void 0 ? 'rectangle' : _c, _d = _a.baseSize, baseSize = _d === void 0 ? 'small' : _d, baseColorKey = _a.baseColorKey, borderColorKey = _a.borderColorKey, _e = _a.iconSize, iconSize = _e === void 0 ? 24 : _e, _f = _a.iconFillType, iconFillType = _f === void 0 ? 'line' : _f, iconName = _a.iconName, iconColorKey = _a.iconColorKey, _g = _a.shadow, shadow = _g === void 0 ? 'hidden' : _g, _h = _a.colorTheme, colorTheme = _h === void 0 ? 'none' : _h, _j = _a.type, type = _j === void 0 ? 'button' : _j, _k = _a.state, state = _k === void 0 ? 'normal' : _k, onClick = _a.onClick, onTouchStart = _a.onTouchStart;
|
|
35
|
+
var iconStateColorObj = {
|
|
36
|
+
fill: 'ui_cpnt_button_icon_on_primary',
|
|
37
|
+
line: 'ui_cpnt_button_icon_enabled'
|
|
38
|
+
};
|
|
39
|
+
var iconThemeColorLineObj = {
|
|
40
|
+
line1: 'ui_cpnt_button_icon_error',
|
|
41
|
+
line2: 'ui_cpnt_button_icon_primary'
|
|
42
|
+
};
|
|
43
|
+
var IconColorSelect = function () {
|
|
44
|
+
if (state === 'disabled') {
|
|
45
|
+
return 'ui_cpnt_button_icon_disabled';
|
|
46
|
+
}
|
|
47
|
+
if (colorTheme !== 'none' && fillType === 'line') {
|
|
48
|
+
return iconThemeColorLineObj[colorTheme];
|
|
49
|
+
}
|
|
50
|
+
if (iconColorKey) {
|
|
51
|
+
return iconColorKey;
|
|
52
|
+
}
|
|
53
|
+
return iconStateColorObj[fillType];
|
|
54
|
+
};
|
|
55
|
+
return (react_1.default.createElement(S_IconButton, { fillType: fillType, shapeType: shapeType, baseSize: baseSize, baseColorKey: baseColorKey, borderColorKey: borderColorKey, shadow: shadow, colorTheme: colorTheme, type: type, state: state, disabled: state === 'disabled', onClick: onClick, onTouchStart: onTouchStart },
|
|
56
|
+
react_1.default.createElement(hybrid_1.Icon, { iconName: iconName, size: iconSize, colorKey: IconColorSelect(), fillType: iconFillType })));
|
|
57
|
+
}
|
|
58
|
+
var fillDisabled = (0, styled_components_1.css)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n background-color: ", ";\n"], ["\n background-color: ", ";\n"])), function (_a) {
|
|
59
|
+
var theme = _a.theme, baseColorKey = _a.baseColorKey;
|
|
60
|
+
return baseColorKey === 'ui_cpnt_button_fill_base_transparent'
|
|
61
|
+
? ''
|
|
62
|
+
: theme.ui_cpnt_button_fill_base_disabled;
|
|
63
|
+
});
|
|
64
|
+
var fill = (0, styled_components_1.css)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n background-color: ", ";\n\n &:active:enabled {\n ", "\n }\n\n ", ";\n"], ["\n background-color: ", ";\n\n &:active:enabled {\n ", "\n }\n\n ", ";\n"])), function (_a) {
|
|
65
|
+
var theme = _a.theme, baseColorKey = _a.baseColorKey;
|
|
66
|
+
return baseColorKey ? ui_colors_1.uiColors[baseColorKey] : theme.ui_cpnt_button_fill_base_primary;
|
|
67
|
+
}, function (_a) {
|
|
68
|
+
var theme = _a.theme, baseColorKey = _a.baseColorKey;
|
|
69
|
+
return baseColorKey === 'ui_cpnt_button_fill_base_transparent'
|
|
70
|
+
? ''
|
|
71
|
+
: "background-image: linear-gradient(\n to top,\n " + theme.ui_cpnt_button_fill_on_base_pressed + ",\n " + theme.ui_cpnt_button_fill_on_base_pressed + "\n );";
|
|
72
|
+
}, function (_a) {
|
|
73
|
+
var state = _a.state;
|
|
74
|
+
return state === 'disabled' && fillDisabled;
|
|
75
|
+
});
|
|
76
|
+
var lineDisabled = (0, styled_components_1.css)(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n border-color: ", ";\n background-color: ", ";\n"], ["\n border-color: ", ";\n background-color: ", ";\n"])), function (_a) {
|
|
77
|
+
var theme = _a.theme;
|
|
78
|
+
return theme.ui_cpnt_button_line_border_disabled;
|
|
79
|
+
}, function (_a) {
|
|
80
|
+
var theme = _a.theme;
|
|
81
|
+
return theme.ui_cpnt_button_line_base_default;
|
|
82
|
+
});
|
|
83
|
+
var line = (0, styled_components_1.css)(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n background-color: ", ";\n border-color: ", ";\n\n ", ";\n\n &:active:enabled {\n ", "\n }\n\n ", ";\n"], ["\n background-color: ", ";\n border-color: ", ";\n\n ", ";\n\n &:active:enabled {\n ", "\n }\n\n ", ";\n"])), function (_a) {
|
|
84
|
+
var theme = _a.theme;
|
|
85
|
+
return theme.ui_cpnt_button_line_base_default;
|
|
86
|
+
}, function (_a) {
|
|
87
|
+
var theme = _a.theme, borderColorKey = _a.borderColorKey;
|
|
88
|
+
return borderColorKey ? ui_colors_1.uiColors[borderColorKey] : theme.ui_cpnt_button_line_border_enabled;
|
|
89
|
+
}, function (_a) {
|
|
90
|
+
var colorTheme = _a.colorTheme;
|
|
91
|
+
switch (colorTheme) {
|
|
92
|
+
case 'line1':
|
|
93
|
+
return line1ColorTheme;
|
|
94
|
+
case 'line2':
|
|
95
|
+
return line2ColorTheme;
|
|
96
|
+
default:
|
|
97
|
+
return '';
|
|
98
|
+
}
|
|
99
|
+
}, function (_a) {
|
|
100
|
+
var theme = _a.theme;
|
|
101
|
+
return "background-color: " + theme.ui_cpnt_button_line_base_pressed + "\n ;";
|
|
102
|
+
}, function (_a) {
|
|
103
|
+
var state = _a.state;
|
|
104
|
+
return state === 'disabled' && lineDisabled;
|
|
105
|
+
});
|
|
106
|
+
var xxlarge = (0, styled_components_1.css)(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n height: 96px;\n width: 96px;\n"], ["\n height: 96px;\n width: 96px;\n"])));
|
|
107
|
+
var large = (0, styled_components_1.css)(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n height: 48px;\n width: 48px;\n"], ["\n height: 48px;\n width: 48px;\n"])));
|
|
108
|
+
var medium = (0, styled_components_1.css)(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n height: 40px;\n width: 40px;\n"], ["\n height: 40px;\n width: 40px;\n"])));
|
|
109
|
+
var small = (0, styled_components_1.css)(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n height: 32px;\n width: 32px;\n"], ["\n height: 32px;\n width: 32px;\n"])));
|
|
110
|
+
var xsmall = (0, styled_components_1.css)(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n height: 24px;\n width: 24px;\n"], ["\n height: 24px;\n width: 24px;\n"])));
|
|
111
|
+
var line1ColorTheme = (0, styled_components_1.css)(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n border-color: ", ";\n"], ["\n border-color: ", ";\n"])), function (_a) {
|
|
112
|
+
var theme = _a.theme;
|
|
113
|
+
return theme.ui_cpnt_button_line_border_error;
|
|
114
|
+
});
|
|
115
|
+
var line2ColorTheme = (0, styled_components_1.css)(templateObject_11 || (templateObject_11 = __makeTemplateObject(["\n border-color: ", ";\n"], ["\n border-color: ", ";\n"])), function (_a) {
|
|
116
|
+
var theme = _a.theme;
|
|
117
|
+
return theme.ui_cpnt_button_line_border_primary;
|
|
118
|
+
});
|
|
119
|
+
var iconButtonStyle = (0, styled_components_1.css)(templateObject_12 || (templateObject_12 = __makeTemplateObject(["\n align-items: center;\n background-color: transparent;\n border: 1px solid transparent;\n cursor: ", ";\n display: flex;\n justify-content: center;\n ", ";\n ", ";\n ", ";\n ", ";\n"], ["\n align-items: center;\n background-color: transparent;\n border: 1px solid transparent;\n cursor: ", ";\n display: flex;\n justify-content: center;\n ", ";\n ", ";\n ", ";\n ", ";\n"])), function (_a) {
|
|
120
|
+
var state = _a.state;
|
|
121
|
+
return (state === 'normal' ? 'pointer' : 'default');
|
|
122
|
+
}, function (_a) {
|
|
123
|
+
var shapeType = _a.shapeType;
|
|
124
|
+
return shapeType && { circular: 'border-radius: 50%', rectangle: '' }[shapeType];
|
|
125
|
+
}, function (_a) {
|
|
126
|
+
var theme = _a.theme, shadow = _a.shadow;
|
|
127
|
+
return shadow === 'visible' && "box-shadow: " + theme.boxShadow.elevation2;
|
|
128
|
+
}, function (_a) {
|
|
129
|
+
var fillType = _a.fillType;
|
|
130
|
+
return fillType &&
|
|
131
|
+
{
|
|
132
|
+
fill: fill,
|
|
133
|
+
line: line
|
|
134
|
+
}[fillType];
|
|
135
|
+
}, function (_a) {
|
|
136
|
+
var baseSize = _a.baseSize;
|
|
137
|
+
return baseSize &&
|
|
138
|
+
{
|
|
139
|
+
xxlarge: xxlarge,
|
|
140
|
+
large: large,
|
|
141
|
+
medium: medium,
|
|
142
|
+
small: small,
|
|
143
|
+
xsmall: xsmall
|
|
144
|
+
}[baseSize];
|
|
145
|
+
});
|
|
146
|
+
var S_IconButton = styled_components_1.default.button(templateObject_13 || (templateObject_13 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), iconButtonStyle);
|
|
147
|
+
exports.default = IconButton;
|
|
148
|
+
var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7, templateObject_8, templateObject_9, templateObject_10, templateObject_11, templateObject_12, templateObject_13;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as IconButton } from './IconButton';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.IconButton = void 0;
|
|
7
|
+
var IconButton_1 = require("./IconButton");
|
|
8
|
+
Object.defineProperty(exports, "IconButton", { enumerable: true, get: function () { return __importDefault(IconButton_1).default; } });
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.TextLabel = exports.StatusBlock = void 0;
|
|
3
|
+
exports.TextLabel = exports.StatusBlock = exports.IconButton = void 0;
|
|
4
|
+
var IconButton_1 = require("./IconButton");
|
|
5
|
+
Object.defineProperty(exports, "IconButton", { enumerable: true, get: function () { return IconButton_1.IconButton; } });
|
|
4
6
|
var StatusBlock_1 = require("./StatusBlock");
|
|
5
7
|
Object.defineProperty(exports, "StatusBlock", { enumerable: true, get: function () { return StatusBlock_1.StatusBlock; } });
|
|
6
8
|
var TextLabel_1 = require("./TextLabel");
|
|
@@ -13,5 +13,5 @@ import { LayoutMS } from './layout/LayoutMS';
|
|
|
13
13
|
import { NavigationContainer as MSNavigationContainer } from './layout/LayoutMS/Containers';
|
|
14
14
|
import { ContainersBox as MSContainersBox } from './layout/LayoutMS/ContainersBox';
|
|
15
15
|
export { LayoutMS, MSNavigationContainer, MSContainersBox };
|
|
16
|
-
import { StatusBlock as M_StatusBlock, TextLabel as M_TextLabel } from './components';
|
|
17
|
-
export { M_StatusBlock, M_TextLabel };
|
|
16
|
+
import { IconButton as M_IconButton, StatusBlock as M_StatusBlock, TextLabel as M_TextLabel } from './components';
|
|
17
|
+
export { M_IconButton, M_StatusBlock, M_TextLabel };
|
package/dist/src/mobile/index.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
/* eslint-disable import/order */
|
|
3
3
|
/* eslint-disable import/first */
|
|
4
4
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
-
exports.M_TextLabel = exports.M_StatusBlock = exports.MSContainersBox = exports.MSNavigationContainer = exports.LayoutMS = exports.MPContainersBox = exports.MPTabContainer = exports.MPNavigationContainer = exports.LayoutMP = exports.MMContainersBox = exports.MMNavigationContainer = exports.LayoutMM = exports.MFContainersBox = exports.LayoutMF = void 0;
|
|
5
|
+
exports.M_TextLabel = exports.M_StatusBlock = exports.M_IconButton = exports.MSContainersBox = exports.MSNavigationContainer = exports.LayoutMS = exports.MPContainersBox = exports.MPTabContainer = exports.MPNavigationContainer = exports.LayoutMP = exports.MMContainersBox = exports.MMNavigationContainer = exports.LayoutMM = exports.MFContainersBox = exports.LayoutMF = void 0;
|
|
6
6
|
// layoutMF
|
|
7
7
|
var LayoutMF_1 = require("./layout/LayoutMF");
|
|
8
8
|
Object.defineProperty(exports, "LayoutMF", { enumerable: true, get: function () { return LayoutMF_1.LayoutMF; } });
|
|
@@ -32,5 +32,6 @@ var ContainersBox_4 = require("./layout/LayoutMS/ContainersBox");
|
|
|
32
32
|
Object.defineProperty(exports, "MSContainersBox", { enumerable: true, get: function () { return ContainersBox_4.ContainersBox; } });
|
|
33
33
|
// components
|
|
34
34
|
var components_1 = require("./components");
|
|
35
|
+
Object.defineProperty(exports, "M_IconButton", { enumerable: true, get: function () { return components_1.IconButton; } });
|
|
35
36
|
Object.defineProperty(exports, "M_StatusBlock", { enumerable: true, get: function () { return components_1.StatusBlock; } });
|
|
36
37
|
Object.defineProperty(exports, "M_TextLabel", { enumerable: true, get: function () { return components_1.TextLabel; } });
|