@open-tender/store 1.1.25 → 1.1.26
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.
|
@@ -20,27 +20,36 @@ var keypad = {
|
|
|
20
20
|
classes: '',
|
|
21
21
|
props: {},
|
|
22
22
|
style: {
|
|
23
|
-
flexDirection: '
|
|
23
|
+
flexDirection: 'column',
|
|
24
24
|
flexWrap: 'wrap',
|
|
25
25
|
width: '100%',
|
|
26
26
|
gap: 5
|
|
27
27
|
}
|
|
28
28
|
},
|
|
29
|
-
|
|
29
|
+
keypad__buttonsLine: {
|
|
30
30
|
classes: '',
|
|
31
31
|
props: {},
|
|
32
|
-
style:
|
|
32
|
+
style: {
|
|
33
|
+
flexDirection: 'row',
|
|
34
|
+
flexWrap: 'nowrap',
|
|
35
|
+
width: '100%',
|
|
36
|
+
gap: 5
|
|
37
|
+
}
|
|
33
38
|
},
|
|
34
|
-
|
|
39
|
+
keypad__defaultButton: {
|
|
35
40
|
classes: '',
|
|
36
41
|
props: {},
|
|
37
|
-
style: {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
style: tslib_1.__assign(tslib_1.__assign({}, styles_1.default.textBody), { flexBasis: '100%', color: utils_1.theme.colors.text.primary, fontSize: utils_1.theme.fontSizes.large, height: 80, backgroundColor: utils_1.theme.colors.background.primary, borderWidth: utils_1.theme.spacing.borderWidth.medium, borderStyle: 'solid', borderColor: utils_1.theme.colors.border.primary, alignItems: 'center', justifyContent: 'center' })
|
|
43
|
+
},
|
|
44
|
+
keypad__numericButton: {
|
|
45
|
+
classes: '',
|
|
46
|
+
props: {},
|
|
47
|
+
style: tslib_1.__assign(tslib_1.__assign({}, styles_1.default.textBody), { flexBasis: '100%', color: utils_1.theme.colors.text.primary, fontSize: utils_1.theme.fontSizes.large, backgroundColor: utils_1.theme.colors.background.primary, borderWidth: utils_1.theme.spacing.borderWidth.medium, borderStyle: 'solid', borderColor: utils_1.theme.colors.border.primary, alignItems: 'center', justifyContent: 'center', aspectRatio: 1.5 })
|
|
48
|
+
},
|
|
49
|
+
keypad__fixedWidthButton: {
|
|
50
|
+
classes: '',
|
|
51
|
+
props: {},
|
|
52
|
+
style: tslib_1.__assign(tslib_1.__assign({}, styles_1.default.textBody), { width: 80, color: utils_1.theme.colors.text.primary, fontSize: utils_1.theme.fontSizes.large, height: 80, backgroundColor: utils_1.theme.colors.background.primary, borderWidth: utils_1.theme.spacing.borderWidth.medium, borderStyle: 'solid', borderColor: utils_1.theme.colors.border.primary, alignItems: 'center', justifyContent: 'center' })
|
|
44
53
|
}
|
|
45
54
|
};
|
|
46
55
|
exports.default = keypad;
|
|
@@ -2,12 +2,14 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.getKeyboardValue = void 0;
|
|
4
4
|
var getKeyboardValue = function (key, value, maxLength) {
|
|
5
|
-
if (key === '
|
|
5
|
+
if (key === 'Del')
|
|
6
6
|
return value.slice(0, -1);
|
|
7
|
-
else if (key === '
|
|
7
|
+
else if (key === 'Clr')
|
|
8
8
|
return '';
|
|
9
9
|
else if (maxLength && value.length >= maxLength)
|
|
10
10
|
return value;
|
|
11
|
+
else if (key === 'Space')
|
|
12
|
+
return value + ' ';
|
|
11
13
|
else
|
|
12
14
|
return value + key;
|
|
13
15
|
};
|
|
@@ -18,27 +18,36 @@ var keypad = {
|
|
|
18
18
|
classes: '',
|
|
19
19
|
props: {},
|
|
20
20
|
style: {
|
|
21
|
-
flexDirection: '
|
|
21
|
+
flexDirection: 'column',
|
|
22
22
|
flexWrap: 'wrap',
|
|
23
23
|
width: '100%',
|
|
24
24
|
gap: 5
|
|
25
25
|
}
|
|
26
26
|
},
|
|
27
|
-
|
|
27
|
+
keypad__buttonsLine: {
|
|
28
28
|
classes: '',
|
|
29
29
|
props: {},
|
|
30
|
-
style:
|
|
30
|
+
style: {
|
|
31
|
+
flexDirection: 'row',
|
|
32
|
+
flexWrap: 'nowrap',
|
|
33
|
+
width: '100%',
|
|
34
|
+
gap: 5
|
|
35
|
+
}
|
|
31
36
|
},
|
|
32
|
-
|
|
37
|
+
keypad__defaultButton: {
|
|
33
38
|
classes: '',
|
|
34
39
|
props: {},
|
|
35
|
-
style: {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
40
|
+
style: __assign(__assign({}, styles.textBody), { flexBasis: '100%', color: theme.colors.text.primary, fontSize: theme.fontSizes.large, height: 80, backgroundColor: theme.colors.background.primary, borderWidth: theme.spacing.borderWidth.medium, borderStyle: 'solid', borderColor: theme.colors.border.primary, alignItems: 'center', justifyContent: 'center' })
|
|
41
|
+
},
|
|
42
|
+
keypad__numericButton: {
|
|
43
|
+
classes: '',
|
|
44
|
+
props: {},
|
|
45
|
+
style: __assign(__assign({}, styles.textBody), { flexBasis: '100%', color: theme.colors.text.primary, fontSize: theme.fontSizes.large, backgroundColor: theme.colors.background.primary, borderWidth: theme.spacing.borderWidth.medium, borderStyle: 'solid', borderColor: theme.colors.border.primary, alignItems: 'center', justifyContent: 'center', aspectRatio: 1.5 })
|
|
46
|
+
},
|
|
47
|
+
keypad__fixedWidthButton: {
|
|
48
|
+
classes: '',
|
|
49
|
+
props: {},
|
|
50
|
+
style: __assign(__assign({}, styles.textBody), { width: 80, color: theme.colors.text.primary, fontSize: theme.fontSizes.large, height: 80, backgroundColor: theme.colors.background.primary, borderWidth: theme.spacing.borderWidth.medium, borderStyle: 'solid', borderColor: theme.colors.border.primary, alignItems: 'center', justifyContent: 'center' })
|
|
42
51
|
}
|
|
43
52
|
};
|
|
44
53
|
export default keypad;
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
export var getKeyboardValue = function (key, value, maxLength) {
|
|
2
|
-
if (key === '
|
|
2
|
+
if (key === 'Del')
|
|
3
3
|
return value.slice(0, -1);
|
|
4
|
-
else if (key === '
|
|
4
|
+
else if (key === 'Clr')
|
|
5
5
|
return '';
|
|
6
6
|
else if (maxLength && value.length >= maxLength)
|
|
7
7
|
return value;
|
|
8
|
+
else if (key === 'Space')
|
|
9
|
+
return value + ' ';
|
|
8
10
|
else
|
|
9
11
|
return value + key;
|
|
10
12
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@open-tender/store",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.26",
|
|
4
4
|
"description": "A library of hooks, reducers, utility functions, and types for use with Open Tender applications that utilize our in-store POS API",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"module": "./dist/esm/index.js",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"@babel/core": "^7.23.6",
|
|
37
37
|
"@emotion/react": "^11.11.1",
|
|
38
38
|
"@open-tender/types": "^0.4.44",
|
|
39
|
-
"@open-tender/ui": "^0.3.
|
|
39
|
+
"@open-tender/ui": "^0.3.19",
|
|
40
40
|
"@open-tender/utils": "^0.4.23",
|
|
41
41
|
"@reduxjs/toolkit": "^2.0.1",
|
|
42
42
|
"@types/react": "^18.2.45",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"peerDependencies": {
|
|
66
66
|
"@emotion/react": "^11.11.1",
|
|
67
67
|
"@open-tender/types": "^0.4.43",
|
|
68
|
-
"@open-tender/ui": "^0.3.
|
|
68
|
+
"@open-tender/ui": "^0.3.19",
|
|
69
69
|
"@open-tender/utils": "^0.4.23",
|
|
70
70
|
"@reduxjs/toolkit": "^2.0.1",
|
|
71
71
|
"date-fns": "2.30.0",
|