@invoicebox/ui 0.1.0-alpha.117 → 0.1.0-alpha.119
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/dist/components/common/QRCode/assets/invoiceboxQRLogo.png +0 -0
- package/dist/components/common/QRCode/index.d.ts +8 -0
- package/dist/components/common/QRCode/index.js +23 -0
- package/dist/components/common/QRCode/index.stories.d.ts +5 -0
- package/dist/components/common/QRCode/index.stories.js +19 -0
- package/dist/components/payment/PaymentCard/index.stories.d.ts +2 -0
- package/dist/components/payment/PaymentCard/index.stories.js +24 -1
- package/dist/components/payment/PaymentCard/styles.js +15 -12
- package/dist/declarations.d.js +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +7 -0
- package/package.json +3 -1
|
Binary file
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.QRCode = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _qrcode = _interopRequireDefault(require("qrcode.react"));
|
|
9
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
10
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
11
|
+
var invoiceboxIcon = "/public/a77a71d71b649b5aad848487ac3936b1.png";
|
|
12
|
+
var QRCode = exports.QRCode = function QRCode(props) {
|
|
13
|
+
return /*#__PURE__*/_react["default"].createElement(_qrcode["default"], _extends({}, props, {
|
|
14
|
+
renderAs: "canvas",
|
|
15
|
+
level: "M",
|
|
16
|
+
imageSettings: {
|
|
17
|
+
src: invoiceboxIcon,
|
|
18
|
+
height: 39,
|
|
19
|
+
width: 39,
|
|
20
|
+
excavate: false
|
|
21
|
+
}
|
|
22
|
+
}));
|
|
23
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = exports.Default = void 0;
|
|
7
|
+
var _ = require(".");
|
|
8
|
+
var meta = {
|
|
9
|
+
title: 'common/QRCode',
|
|
10
|
+
component: _.QRCode,
|
|
11
|
+
tags: ['autodocs']
|
|
12
|
+
};
|
|
13
|
+
var _default = exports["default"] = meta;
|
|
14
|
+
var Default = exports.Default = {
|
|
15
|
+
args: {
|
|
16
|
+
value: 'https://www.invoicebox.ru/ru/',
|
|
17
|
+
size: 132
|
|
18
|
+
}
|
|
19
|
+
};
|
|
@@ -5,3 +5,5 @@ declare const meta: Meta<typeof PaymentCard>;
|
|
|
5
5
|
export default meta;
|
|
6
6
|
export declare const Default: StoryObj<typeof PaymentCard>;
|
|
7
7
|
export declare const WithChildren: StoryObj<typeof PaymentCard>;
|
|
8
|
+
export declare const OverflowText: StoryObj<typeof PaymentCard>;
|
|
9
|
+
export declare const OverflowTextWithChildren: StoryObj<typeof PaymentCard>;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports["default"] = exports.WithChildren = exports.Default = void 0;
|
|
6
|
+
exports["default"] = exports.WithChildren = exports.OverflowTextWithChildren = exports.OverflowText = exports.Default = void 0;
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _ = require(".");
|
|
9
9
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
@@ -35,4 +35,27 @@ var WithChildren = exports.WithChildren = {
|
|
|
35
35
|
}),
|
|
36
36
|
comment: 'Комиссия 10 руб'
|
|
37
37
|
}
|
|
38
|
+
};
|
|
39
|
+
var OverflowText = exports.OverflowText = {
|
|
40
|
+
args: {
|
|
41
|
+
title: 'Длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование ',
|
|
42
|
+
isActive: false,
|
|
43
|
+
isDisabled: false,
|
|
44
|
+
comment: 'Комиссия 10 руб'
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
var OverflowTextWithChildren = exports.OverflowTextWithChildren = {
|
|
48
|
+
args: {
|
|
49
|
+
title: 'Длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование длинное наименование ',
|
|
50
|
+
isActive: false,
|
|
51
|
+
isDisabled: false,
|
|
52
|
+
comment: 'Комиссия 10 руб',
|
|
53
|
+
children: /*#__PURE__*/_react["default"].createElement("div", {
|
|
54
|
+
style: {
|
|
55
|
+
height: 22,
|
|
56
|
+
width: 121,
|
|
57
|
+
background: 'green'
|
|
58
|
+
}
|
|
59
|
+
})
|
|
60
|
+
}
|
|
38
61
|
};
|
|
@@ -33,32 +33,35 @@ var Content = exports.Content = _styledComponents["default"].div.withConfig({
|
|
|
33
33
|
var Title = exports.Title = (0, _styledComponents["default"])(_Typography.Typography).withConfig({
|
|
34
34
|
displayName: "styles__Title",
|
|
35
35
|
componentId: "sc-ykxt4t-3"
|
|
36
|
-
})(["white-space:", ";
|
|
36
|
+
})(["white-space:", ";text-overflow:ellipsis;overflow:hidden;", " max-width:100%;color:", ";"], function (_ref3) {
|
|
37
37
|
var $ellipsis = _ref3.$ellipsis;
|
|
38
38
|
return $ellipsis ? 'normal' : 'nowrap';
|
|
39
39
|
}, function (_ref4) {
|
|
40
|
-
var $
|
|
40
|
+
var $ellipsis = _ref4.$ellipsis;
|
|
41
|
+
return $ellipsis && "\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n ";
|
|
42
|
+
}, function (_ref5) {
|
|
43
|
+
var $pallete = _ref5.$pallete;
|
|
41
44
|
return $pallete.title;
|
|
42
45
|
});
|
|
43
46
|
var IconWrapper = exports.IconWrapper = _styledComponents["default"].div.withConfig({
|
|
44
47
|
displayName: "styles__IconWrapper",
|
|
45
48
|
componentId: "sc-ykxt4t-4"
|
|
46
|
-
})(["flex-shrink:0;flex-grow:0;width:36px;height:36px;border-radius:50%;background-color:", ";display:flex;align-items:center;justify-content:center;"], function (
|
|
47
|
-
var $isActive =
|
|
48
|
-
$pallete =
|
|
49
|
+
})(["flex-shrink:0;flex-grow:0;width:36px;height:36px;border-radius:50%;background-color:", ";display:flex;align-items:center;justify-content:center;"], function (_ref6) {
|
|
50
|
+
var $isActive = _ref6.$isActive,
|
|
51
|
+
$pallete = _ref6.$pallete;
|
|
49
52
|
return $isActive ? 'transparent' : $pallete.iconBg;
|
|
50
53
|
});
|
|
51
54
|
var Comment = exports.Comment = (0, _styledComponents["default"])(_Typography.Typography).withConfig({
|
|
52
55
|
displayName: "styles__Comment",
|
|
53
56
|
componentId: "sc-ykxt4t-5"
|
|
54
|
-
})(["color:", ";position:absolute;bottom:0;right:0;padding:0 8px;box-sizing:border-box;background:", ";border-radius:6px 0px 0px 0px;", ""], function (
|
|
55
|
-
var $pallete = _ref6.$pallete;
|
|
56
|
-
return $pallete.comment;
|
|
57
|
-
}, function (_ref7) {
|
|
57
|
+
})(["color:", ";position:absolute;bottom:0;right:0;padding:0 8px;box-sizing:border-box;background:", ";border-radius:6px 0px 0px 0px;", ""], function (_ref7) {
|
|
58
58
|
var $pallete = _ref7.$pallete;
|
|
59
|
-
return $pallete.
|
|
59
|
+
return $pallete.comment;
|
|
60
60
|
}, function (_ref8) {
|
|
61
|
-
var $
|
|
62
|
-
|
|
61
|
+
var $pallete = _ref8.$pallete;
|
|
62
|
+
return $pallete.commentBg;
|
|
63
|
+
}, function (_ref9) {
|
|
64
|
+
var $isActive = _ref9.$isActive,
|
|
65
|
+
$pallete = _ref9.$pallete;
|
|
63
66
|
return $isActive ? (0, _styledComponents.css)(["border-top:1px solid ", ";border-left:1px solid ", ";"], $pallete.borderActive, $pallete.borderActive) : (0, _styledComponents.css)(["border-top:1px solid ", ";border-left:1px solid ", ";"], $pallete.borderInactive, $pallete.borderInactive);
|
|
64
67
|
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";
|
package/dist/index.d.ts
CHANGED
|
@@ -39,6 +39,7 @@ export { AppCardLink } from './components/common/AppCardLink';
|
|
|
39
39
|
export { InvoiceboxLogo } from './components/common/InvoiceboxLogo';
|
|
40
40
|
export type { TProps as TAutocompleteProps } from './components/form/Autocomplete/index';
|
|
41
41
|
export { Autocomplete, AutocompleteDefaultOption, OrganizationAutocompleteItem, } from './components/form/Autocomplete/index';
|
|
42
|
+
export { QRCode } from './components/common/QRCode';
|
|
42
43
|
export { PaletteProvider, defaultAbstractPalette } from './palette';
|
|
43
44
|
export type { TAbstractPalette } from './palette';
|
|
44
45
|
export { useOutsideClick } from './hooks/useOutsideClick';
|
package/dist/index.js
CHANGED
|
@@ -129,6 +129,12 @@ Object.defineProperty(exports, "PureInput", {
|
|
|
129
129
|
return _PureInput.PureInput;
|
|
130
130
|
}
|
|
131
131
|
});
|
|
132
|
+
Object.defineProperty(exports, "QRCode", {
|
|
133
|
+
enumerable: true,
|
|
134
|
+
get: function get() {
|
|
135
|
+
return _QRCode.QRCode;
|
|
136
|
+
}
|
|
137
|
+
});
|
|
132
138
|
Object.defineProperty(exports, "Scrollbar", {
|
|
133
139
|
enumerable: true,
|
|
134
140
|
get: function get() {
|
|
@@ -277,6 +283,7 @@ var _PaymentCard = require("./components/payment/PaymentCard");
|
|
|
277
283
|
var _AppCardLink = require("./components/common/AppCardLink");
|
|
278
284
|
var _InvoiceboxLogo = require("./components/common/InvoiceboxLogo");
|
|
279
285
|
var _index = require("./components/form/Autocomplete/index");
|
|
286
|
+
var _QRCode = require("./components/common/QRCode");
|
|
280
287
|
var _palette = require("./palette");
|
|
281
288
|
var _useOutsideClick = require("./hooks/useOutsideClick");
|
|
282
289
|
var _useInputFocus = require("./hooks/useInputFocus");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@invoicebox/ui",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.119",
|
|
4
4
|
"description": "Invoicebox UI",
|
|
5
5
|
"license": "Apache License 2.0",
|
|
6
6
|
"scripts": {
|
|
@@ -32,6 +32,7 @@
|
|
|
32
32
|
"@storybook/test": "^7.6.13",
|
|
33
33
|
"@typescript-eslint/eslint-plugin": "^5.62.0",
|
|
34
34
|
"@typescript-eslint/parser": "^5.62.0",
|
|
35
|
+
"babel-plugin-file-loader": "^2.0.0",
|
|
35
36
|
"babel-plugin-inline-json-import": "^0.3.2",
|
|
36
37
|
"babel-plugin-styled-components": "^2.1.4",
|
|
37
38
|
"eslint": "^8.56.0",
|
|
@@ -54,6 +55,7 @@
|
|
|
54
55
|
"lottie-react": "^2.4.0",
|
|
55
56
|
"object.entries": "^1.1.8",
|
|
56
57
|
"object.fromentries": "^2.0.8",
|
|
58
|
+
"qrcode.react": "^3.1.0",
|
|
57
59
|
"react-calendar": "^4.8.0",
|
|
58
60
|
"react-responsive": "^9.0.2",
|
|
59
61
|
"react-scrollbars-custom": "^4.1.1",
|