@pedidopago/ui 1.3.7 → 1.3.10
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/DateInput/components/ModalWrapper/index.d.ts.map +1 -1
- package/dist/components/DateInput/components/ModalWrapper/index.js +0 -5
- package/dist/components/DateInput/components/ModalWrapper/styles.d.ts.map +1 -1
- package/dist/components/DateInput/components/ModalWrapper/styles.js +1 -1
- package/dist/components/DateInput/components/ModalWrapper/types.d.ts +0 -2
- package/dist/components/DateInput/components/ModalWrapper/types.d.ts.map +1 -1
- package/dist/components/DateInput/dateInput.test.js +11 -0
- package/dist/components/DateInput/index.d.ts +1 -1
- package/dist/components/DateInput/index.d.ts.map +1 -1
- package/dist/components/DateInput/index.js +16 -16
- package/dist/components/DateInput/types.d.ts +2 -0
- package/dist/components/DateInput/types.d.ts.map +1 -1
- package/dist/components/DatePicker/components/DatePickerContent.d.ts.map +1 -1
- package/dist/components/DatePicker/components/DatePickerContent.js +17 -7
- package/dist/components/DatePicker/index.d.ts.map +1 -1
- package/dist/components/DatePicker/index.js +5 -4
- package/dist/components/DatePicker/styles.d.ts.map +1 -1
- package/dist/components/DatePicker/styles.js +1 -1
- package/dist/components/Icon/data/dash.d.ts.map +1 -1
- package/dist/components/Icon/data/dash.js +1 -1
- package/dist/components/Icon/data/payment.d.ts.map +1 -1
- package/dist/components/Icon/data/payment.js +7 -0
- package/dist/components/Icon/types.d.ts +1 -1
- package/dist/components/Icon/types.d.ts.map +1 -1
- package/dist/components/Illustration/BoletoSvg/index.d.ts +5 -0
- package/dist/components/Illustration/BoletoSvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/BoletoSvg/index.js +168 -0
- package/dist/components/Illustration/BoxClosedSvg/index.d.ts +5 -0
- package/dist/components/Illustration/BoxClosedSvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/BoxClosedSvg/index.js +99 -0
- package/dist/components/Illustration/BoxDeliverySvg/index.d.ts +5 -0
- package/dist/components/Illustration/BoxDeliverySvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/BoxDeliverySvg/index.js +111 -0
- package/dist/components/Illustration/BoxOpenSvg/index.d.ts +5 -0
- package/dist/components/Illustration/BoxOpenSvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/BoxOpenSvg/index.js +108 -0
- package/dist/components/Illustration/CalendarSvg/index.d.ts +5 -0
- package/dist/components/Illustration/CalendarSvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/CalendarSvg/index.js +109 -0
- package/dist/components/Illustration/CardSvg/index.d.ts +5 -0
- package/dist/components/Illustration/CardSvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/CardSvg/index.js +110 -0
- package/dist/components/Illustration/InquirySvg/index.d.ts +5 -0
- package/dist/components/Illustration/InquirySvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/InquirySvg/index.js +219 -0
- package/dist/components/Illustration/OrderSvg/index.d.ts +5 -0
- package/dist/components/Illustration/OrderSvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/OrderSvg/index.js +135 -0
- package/dist/components/Illustration/PixSvg/index.d.ts +5 -0
- package/dist/components/Illustration/PixSvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/PixSvg/index.js +93 -0
- package/dist/components/Illustration/PrescriptionSvg/index.d.ts +5 -0
- package/dist/components/Illustration/PrescriptionSvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/PrescriptionSvg/index.js +81 -0
- package/dist/components/Illustration/TransportSvg/index.d.ts +5 -0
- package/dist/components/Illustration/TransportSvg/index.d.ts.map +1 -0
- package/dist/components/Illustration/TransportSvg/index.js +102 -0
- package/dist/components/Illustration/illustration.test.d.ts +2 -0
- package/dist/components/Illustration/illustration.test.d.ts.map +1 -0
- package/dist/components/Illustration/illustration.test.js +61 -0
- package/dist/components/Illustration/index.d.ts +5 -0
- package/dist/components/Illustration/index.d.ts.map +1 -0
- package/dist/components/Illustration/index.js +134 -0
- package/dist/components/Illustration/styles.d.ts +11 -0
- package/dist/components/Illustration/styles.d.ts.map +1 -0
- package/dist/components/Illustration/styles.js +38 -0
- package/dist/components/Illustration/types.d.ts +7 -0
- package/dist/components/Illustration/types.d.ts.map +1 -0
- package/dist/components/Illustration/types.js +1 -0
- package/dist/components/Steps/components/StepIcon/index.d.ts +2 -2
- package/dist/components/Steps/components/StepIcon/index.d.ts.map +1 -1
- package/dist/components/Steps/components/StepIconMobile/index.d.ts +2 -2
- package/dist/components/Steps/components/StepIconMobile/index.d.ts.map +1 -1
- package/dist/components/Steps/index.d.ts +2 -2
- package/dist/components/Steps/index.d.ts.map +1 -1
- package/dist/components/Steps/index.js +22 -9
- package/dist/components/Steps/styles.d.ts.map +1 -1
- package/dist/components/Steps/styles.js +30 -19
- package/dist/components/Steps/types.d.ts +10 -5
- package/dist/components/Steps/types.d.ts.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +9 -0
- package/package.json +1 -1
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { IllustrationProps } from './types';
|
|
3
|
+
export declare const IllustrationContainer: import("@emotion/styled").StyledComponent<{
|
|
4
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
5
|
+
as?: import("react").ElementType<any> | undefined;
|
|
6
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
7
|
+
export declare const IconContainer: import("@emotion/styled").StyledComponent<{
|
|
8
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
9
|
+
as?: import("react").ElementType<any> | undefined;
|
|
10
|
+
} & Partial<IllustrationProps>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
11
|
+
//# sourceMappingURL=styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/components/Illustration/styles.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAE5C,eAAO,MAAM,qBAAqB;;;yGAKjC,CAAC;AAEF,eAAO,MAAM,aAAa;;;sIAiCzB,CAAC"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.IllustrationContainer = exports.IconContainer = void 0;
|
|
7
|
+
|
|
8
|
+
var _styled = _interopRequireDefault(require("@emotion/styled"));
|
|
9
|
+
|
|
10
|
+
var _templateObject, _templateObject2;
|
|
11
|
+
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
+
|
|
14
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
15
|
+
|
|
16
|
+
var IllustrationContainer = _styled.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n position: relative;\n width: fit-content;\n height: fit-content;\n"])));
|
|
17
|
+
|
|
18
|
+
exports.IllustrationContainer = IllustrationContainer;
|
|
19
|
+
|
|
20
|
+
var IconContainer = _styled.default.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n display: flex;\n position: absolute;\n align-items: center;\n justify-content: center;\n\n ", "\n"])), function (_ref) {
|
|
21
|
+
var name = _ref.name;
|
|
22
|
+
|
|
23
|
+
switch (name) {
|
|
24
|
+
case 'illust-order':
|
|
25
|
+
return "\n top: 40px;\n left: 54px;\n ";
|
|
26
|
+
|
|
27
|
+
case 'illust-box-delivery':
|
|
28
|
+
return "\n top: 123px;\n left: 122px;\n width: 35px;\n ";
|
|
29
|
+
|
|
30
|
+
case 'illust-transport':
|
|
31
|
+
return "\n top: 123px;\n left: 122px;\n width: 35px;\n ";
|
|
32
|
+
|
|
33
|
+
default:
|
|
34
|
+
return "\n top: 123px;\n left: 10px;\n width: 35px;\n ";
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
exports.IconContainer = IconContainer;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { IconName } from '../Icon/types';
|
|
2
|
+
export interface IllustrationProps {
|
|
3
|
+
iconName?: IconName;
|
|
4
|
+
name?: 'illust-inquiry' | 'illust-order' | 'illust-prescription' | 'illust-calendar' | 'illust-card' | 'illust-pix' | 'illust-boleto' | 'illust-box-closed' | 'illust-box-open' | 'illust-box-delivery' | 'illust-transport';
|
|
5
|
+
type?: 'default' | 'success' | 'warning' | 'error' | 'critical' | 'informative';
|
|
6
|
+
}
|
|
7
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/Illustration/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAEzC,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,IAAI,CAAC,EACD,gBAAgB,GAChB,cAAc,GACd,qBAAqB,GACrB,iBAAiB,GACjB,aAAa,GACb,YAAY,GACZ,eAAe,GACf,mBAAmB,GACnB,iBAAiB,GACjB,qBAAqB,GACrB,kBAAkB,CAAC;IACvB,IAAI,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,UAAU,GAAG,aAAa,CAAC;CACjF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
3
|
-
export declare const StepIcon: ({ isSelectedStep, stepPosition, hasStartGradient, hasEndGratient, activeColor, }:
|
|
2
|
+
import { StepIconProps } from '../../types';
|
|
3
|
+
export declare const StepIcon: ({ isSelectedStep, stepPosition, hasStartGradient, hasEndGratient, activeColor, }: StepIconProps) => JSX.Element;
|
|
4
4
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Steps/components/StepIcon/index.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Steps/components/StepIcon/index.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAa5C,eAAO,MAAM,QAAQ,qFAMlB,aAAa,gBAsFf,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
3
|
-
export declare const StepIconMobile: ({ stepPosition, isSelectedStep, hasStartGradient, hasEndGratient, activeColor, }:
|
|
2
|
+
import { StepIconProps } from '../../types';
|
|
3
|
+
export declare const StepIconMobile: ({ stepPosition, isSelectedStep, hasStartGradient, hasEndGratient, activeColor, }: StepIconProps) => JSX.Element;
|
|
4
4
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Steps/components/StepIconMobile/index.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Steps/components/StepIconMobile/index.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAO5C,eAAO,MAAM,cAAc,qFAMxB,aAAa,gBAgGf,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
3
|
-
declare const Steps: ({ current, steps, activeColor, fullWidth, isReducedSteps, enableCurrentStepChecked, }:
|
|
2
|
+
import { StepsProps } from './types';
|
|
3
|
+
declare const Steps: ({ current, steps, activeColor, fullWidth, isReducedSteps, enableCurrentStepChecked, }: StepsProps) => JSX.Element;
|
|
4
4
|
export default Steps;
|
|
5
5
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Steps/index.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Steps/index.tsx"],"names":[],"mappings":";AAiBA,OAAO,EAAc,UAAU,EAAE,MAAM,SAAS,CAAC;AAEjD,QAAA,MAAM,KAAK,0FAOR,UAAU,gBA2GZ,CAAC;AAEF,eAAe,KAAK,CAAC"}
|
|
@@ -5,6 +5,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
|
|
8
|
+
var _react = require("react");
|
|
9
|
+
|
|
8
10
|
var _Icon = _interopRequireDefault(require("../Icon"));
|
|
9
11
|
|
|
10
12
|
var _StepIcon = require("./components/StepIcon");
|
|
@@ -15,12 +17,12 @@ var _utils = require("./utils");
|
|
|
15
17
|
|
|
16
18
|
var _styles = require("./styles");
|
|
17
19
|
|
|
18
|
-
var _react = require("react");
|
|
19
|
-
|
|
20
20
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
21
21
|
|
|
22
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
23
23
|
|
|
24
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
25
|
+
|
|
24
26
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
25
27
|
|
|
26
28
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -48,6 +50,17 @@ var Steps = function Steps(_ref) {
|
|
|
48
50
|
isMobile = _useState2[0],
|
|
49
51
|
setIsMobile = _useState2[1];
|
|
50
52
|
|
|
53
|
+
var handleEnableControlledSteps = function handleEnableControlledSteps(step, index) {
|
|
54
|
+
var isControlledSteps = _typeof(step) === 'object';
|
|
55
|
+
if (isControlledSteps) return step.isCompleted;
|
|
56
|
+
return current > index + 1 || enableCurrentStepChecked && current === index + 1;
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
var handleStepName = function handleStepName(step) {
|
|
60
|
+
if (_typeof(step) === 'object') return step.name;
|
|
61
|
+
return step;
|
|
62
|
+
};
|
|
63
|
+
|
|
51
64
|
var getStepIconPosition = function getStepIconPosition(index) {
|
|
52
65
|
if (index === 0 && index < steps.length - 1) {
|
|
53
66
|
return _utils.STEP_POSITION.INITIAL_BEFORE_UNSELECTED;
|
|
@@ -93,12 +106,12 @@ var Steps = function Steps(_ref) {
|
|
|
93
106
|
activeColor: activeColor
|
|
94
107
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_styles.StepsItemText, {
|
|
95
108
|
isReducedSteps: isReducedSteps,
|
|
96
|
-
children: step
|
|
109
|
+
children: handleStepName(step)
|
|
97
110
|
})]
|
|
98
|
-
}, "".concat(step, "-").concat(index)) : /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.ReducedStepsContainer, {
|
|
111
|
+
}, "".concat(handleStepName(step), "-").concat(index)) : /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.ReducedStepsContainer, {
|
|
99
112
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_styles.StepsItemText, {
|
|
100
113
|
isReducedSteps: isReducedSteps,
|
|
101
|
-
children: step
|
|
114
|
+
children: handleStepName(step)
|
|
102
115
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_StepIcon.StepIcon, {
|
|
103
116
|
stepPosition: getStepIconPosition(index),
|
|
104
117
|
isSelectedStep: index < current,
|
|
@@ -106,7 +119,7 @@ var Steps = function Steps(_ref) {
|
|
|
106
119
|
hasEndGratient: checkEndGradient(index),
|
|
107
120
|
activeColor: activeColor
|
|
108
121
|
})]
|
|
109
|
-
}, step) : /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.StepsItemContainer, {
|
|
122
|
+
}, handleStepName(step)) : /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.StepsItemContainer, {
|
|
110
123
|
id: "simple-step-".concat(index + 1),
|
|
111
124
|
tabIndex: index + 1 === current ? 0 : -1,
|
|
112
125
|
isCurrent: current === index + 1,
|
|
@@ -114,13 +127,13 @@ var Steps = function Steps(_ref) {
|
|
|
114
127
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_styles.StepsCircle, {
|
|
115
128
|
activeColor: activeColor,
|
|
116
129
|
isCurrent: current === index + 1,
|
|
117
|
-
isFinished:
|
|
118
|
-
children:
|
|
130
|
+
isFinished: handleEnableControlledSteps(step, index),
|
|
131
|
+
children: handleEnableControlledSteps(step, index) ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_Icon.default, {
|
|
119
132
|
name: "check"
|
|
120
133
|
}) : index + 1
|
|
121
134
|
}), current === index + 1 && /*#__PURE__*/(0, _jsxRuntime.jsx)(_styles.StepsItemText, {
|
|
122
135
|
isDisabled: enableCurrentStepChecked,
|
|
123
|
-
children: step
|
|
136
|
+
children: handleStepName(step)
|
|
124
137
|
})]
|
|
125
138
|
}), current === index + 1 && current < steps.length && /*#__PURE__*/(0, _jsxRuntime.jsx)(_styles.StepsSeparator, {})]
|
|
126
139
|
}, index);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/components/Steps/styles.ts"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/components/Steps/styles.ts"],"names":[],"mappings":";AAGA,eAAO,MAAM,cAAc;;;;;;yGAc1B,CAAC;AAEF,eAAO,MAAM,WAAW;;;;iBACT,SAAS,GAAG,WAAW,GAAG,UAAU;;;yGA0DlD,CAAC;AAEF,eAAO,MAAM,cAAc;;;yGAM1B,CAAC;AAEF,eAAO,MAAM,kBAAkB;;;;eAClB,OAAO;yGAkBnB,CAAC;AAEF,eAAO,MAAM,qBAAqB;;;yGAajC,CAAC;AAEF,eAAO,MAAM,2BAA2B;;;yGAIvC,CAAC;AAEF,eAAO,MAAM,0BAA0B;;;yGAItC,CAAC;AAEF,eAAO,MAAM,aAAa;;;;;;iHA0CzB,CAAC"}
|
|
@@ -5,9 +5,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.StepsSeparator = exports.StepsItemsDetailsContainer = exports.StepsItemText = exports.StepsItemContainer = exports.StepsContainer = exports.StepsCircle = exports.ReducedStepsMobileContainer = exports.ReducedStepsContainer = void 0;
|
|
7
7
|
|
|
8
|
+
var _react = require("@emotion/react");
|
|
9
|
+
|
|
8
10
|
var _styled = _interopRequireDefault(require("@emotion/styled"));
|
|
9
11
|
|
|
10
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8;
|
|
12
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11;
|
|
11
13
|
|
|
12
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
15
|
|
|
@@ -26,47 +28,56 @@ var StepsContainer = _styled.default.div(_templateObject || (_templateObject = _
|
|
|
26
28
|
|
|
27
29
|
exports.StepsContainer = StepsContainer;
|
|
28
30
|
|
|
29
|
-
var StepsCircle = _styled.default.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n display: flex;\n justify-content: center;\n align-items: center;\n\n width:
|
|
30
|
-
var theme = _ref4.theme
|
|
31
|
-
|
|
32
|
-
isFinished = _ref4.isFinished,
|
|
33
|
-
isCurrent = _ref4.isCurrent;
|
|
34
|
-
return theme.colors[activeColor] && "\n background-color: ".concat(isFinished ? theme.colors[activeColor].default : isCurrent ? theme.colors[activeColor].disabled : 'transparent', ";\n color: ").concat(isFinished ? theme.colors.body.light : isCurrent ? theme.colors.neutral.black : theme.colors.neutral.neutral3, ";\n\n ").concat(!isCurrent && !isFinished && "\n border: solid 2px ".concat(theme.colors.neutral.neutral1, ";\n "), "\n ");
|
|
31
|
+
var StepsCircle = _styled.default.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n display: flex;\n justify-content: center;\n align-items: center;\n\n width: 32px;\n height: 32px;\n min-width: 32px;\n min-height: 32px;\n border-radius: 99999px;\n\n ", "\n\n font-family: inherit;\n font-weight: 600;\n font-size: 1.125rem;\n\n ", "\n\n & svg {\n stroke: ", ";\n stroke-width: 2px;\n }\n"])), function (_ref4) {
|
|
32
|
+
var theme = _ref4.theme;
|
|
33
|
+
return (0, _react.css)(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n @media screen and (min-width: ", ") {\n width: 42px;\n height: 42px;\n min-width: 42px;\n min-height: 42px;\n }\n "])), theme.breakpoints.md);
|
|
35
34
|
}, function (_ref5) {
|
|
36
|
-
var theme = _ref5.theme
|
|
35
|
+
var theme = _ref5.theme,
|
|
36
|
+
activeColor = _ref5.activeColor,
|
|
37
|
+
isFinished = _ref5.isFinished,
|
|
38
|
+
isCurrent = _ref5.isCurrent;
|
|
39
|
+
return theme.colors[activeColor] && "\n background-color: ".concat(isFinished ? theme.colors[activeColor].default : isCurrent ? theme.colors[activeColor].disabled : 'transparent', ";\n color: ").concat(isFinished ? theme.colors.body.light : isCurrent ? theme.colors.neutral.black : theme.colors.neutral.neutral3, ";\n\n ").concat(!isCurrent && !isFinished && "\n border: solid 2px ".concat(theme.colors.neutral.neutral1, ";\n "), "\n ");
|
|
40
|
+
}, function (_ref6) {
|
|
41
|
+
var theme = _ref6.theme;
|
|
37
42
|
return theme.colors.body.light;
|
|
38
43
|
});
|
|
39
44
|
|
|
40
45
|
exports.StepsCircle = StepsCircle;
|
|
41
46
|
|
|
42
|
-
var StepsSeparator = _styled.default.div(
|
|
43
|
-
var theme =
|
|
47
|
+
var StepsSeparator = _styled.default.div(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n height: 2px;\n width: 100%;\n min-width: 40px;\n max-width: 20px;\n background-color: ", ";\n"])), function (_ref7) {
|
|
48
|
+
var theme = _ref7.theme;
|
|
44
49
|
return theme.colors.neutral.neutral1;
|
|
45
50
|
});
|
|
46
51
|
|
|
47
52
|
exports.StepsSeparator = StepsSeparator;
|
|
48
53
|
|
|
49
|
-
var StepsItemContainer = _styled.default.div(
|
|
54
|
+
var StepsItemContainer = _styled.default.div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n\n flex: ", ";\n\n gap: 8px;\n\n &:last-of-type {\n flex-direction: row-reverse;\n }\n\n ", "\n"])), function (props) {
|
|
50
55
|
return props.isCurrent ? 1 : 0;
|
|
56
|
+
}, function (_ref8) {
|
|
57
|
+
var theme = _ref8.theme;
|
|
58
|
+
return (0, _react.css)(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n @media screen and (min-width: ", ") {\n gap: 12px;\n }\n "])), theme.breakpoints.sm);
|
|
51
59
|
});
|
|
52
60
|
|
|
53
61
|
exports.StepsItemContainer = StepsItemContainer;
|
|
54
62
|
|
|
55
|
-
var ReducedStepsContainer = _styled.default.div(
|
|
63
|
+
var ReducedStepsContainer = _styled.default.div(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 100px;\n\n @media only screen and (max-width: 500px) {\n flex-direction: row;\n height: max-content;\n width: 300px;\n justify-content: start;\n }\n"])));
|
|
56
64
|
|
|
57
65
|
exports.ReducedStepsContainer = ReducedStepsContainer;
|
|
58
66
|
|
|
59
|
-
var ReducedStepsMobileContainer = _styled.default.div(
|
|
67
|
+
var ReducedStepsMobileContainer = _styled.default.div(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n width: 100%;\n"])));
|
|
60
68
|
|
|
61
69
|
exports.ReducedStepsMobileContainer = ReducedStepsMobileContainer;
|
|
62
70
|
|
|
63
|
-
var StepsItemsDetailsContainer = _styled.default.div(
|
|
71
|
+
var StepsItemsDetailsContainer = _styled.default.div(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n gap: 12px;\n"])));
|
|
64
72
|
|
|
65
73
|
exports.StepsItemsDetailsContainer = StepsItemsDetailsContainer;
|
|
66
74
|
|
|
67
|
-
var StepsItemText = _styled.default.h3(
|
|
68
|
-
var
|
|
69
|
-
|
|
75
|
+
var StepsItemText = _styled.default.h3(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["\n font-family: inherit;\n font-weight: 600;\n font-size: 1rem;\n\n white-space: nowrap;\n\n ", "\n\n ", "\n\n @media only screen and (max-width: 500px) {\n ", ";\n white-space: normal;\n }\n"])), function (_ref9) {
|
|
76
|
+
var theme = _ref9.theme;
|
|
77
|
+
return (0, _react.css)(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["\n @media screen and (min-width: ", ") {\n font-size: 1.25rem;\n }\n "])), theme.breakpoints.sm);
|
|
78
|
+
}, function (_ref10) {
|
|
79
|
+
var isDisabled = _ref10.isDisabled,
|
|
80
|
+
theme = _ref10.theme;
|
|
70
81
|
|
|
71
82
|
if (isDisabled) {
|
|
72
83
|
return "\n color: ".concat({
|
|
@@ -79,8 +90,8 @@ var StepsItemText = _styled.default.h3(_templateObject8 || (_templateObject8 = _
|
|
|
79
90
|
light: theme.colors.neutral.black,
|
|
80
91
|
dark: theme.colors.neutral.white
|
|
81
92
|
}[theme.colorMode], ";\n ");
|
|
82
|
-
}, function (
|
|
83
|
-
var isReducedSteps =
|
|
93
|
+
}, function (_ref11) {
|
|
94
|
+
var isReducedSteps = _ref11.isReducedSteps;
|
|
84
95
|
return isReducedSteps ? "width: 100%;" : "";
|
|
85
96
|
});
|
|
86
97
|
|
|
@@ -1,16 +1,21 @@
|
|
|
1
|
-
export
|
|
2
|
-
|
|
1
|
+
export interface StepsControlled {
|
|
2
|
+
name: string;
|
|
3
|
+
isCompleted: boolean;
|
|
4
|
+
}
|
|
5
|
+
export declare type StepsItems = string | StepsControlled;
|
|
6
|
+
export interface StepsProps {
|
|
7
|
+
steps: StepsItems[];
|
|
3
8
|
current: number;
|
|
4
9
|
activeColor?: 'primary' | 'secondary' | 'tertiary';
|
|
5
10
|
fullWidth?: boolean;
|
|
6
11
|
isReducedSteps?: boolean;
|
|
7
12
|
enableCurrentStepChecked?: boolean;
|
|
8
|
-
}
|
|
9
|
-
export
|
|
13
|
+
}
|
|
14
|
+
export interface StepIconProps {
|
|
10
15
|
isSelectedStep: boolean;
|
|
11
16
|
hasStartGradient: boolean;
|
|
12
17
|
hasEndGratient: boolean;
|
|
13
18
|
stepPosition: string;
|
|
14
19
|
activeColor: 'primary' | 'secondary' | 'tertiary';
|
|
15
|
-
}
|
|
20
|
+
}
|
|
16
21
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/Steps/types.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/Steps/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,OAAO,CAAC;CACtB;AAED,oBAAY,UAAU,GAAG,MAAM,GAAG,eAAe,CAAC;AAElD,MAAM,WAAW,UAAU;IACzB,KAAK,EAAE,UAAU,EAAE,CAAC;IACpB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,SAAS,GAAG,WAAW,GAAG,UAAU,CAAC;IACnD,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,wBAAwB,CAAC,EAAE,OAAO,CAAC;CACpC;AAED,MAAM,WAAW,aAAa;IAC5B,cAAc,EAAE,OAAO,CAAC;IACxB,gBAAgB,EAAE,OAAO,CAAC;IAC1B,cAAc,EAAE,OAAO,CAAC;IACxB,YAAY,EAAE,MAAM,CAAC;IACrB,WAAW,EAAE,SAAS,GAAG,WAAW,GAAG,UAAU,CAAC;CACnD"}
|
package/dist/index.d.ts
CHANGED
|
@@ -13,6 +13,7 @@ export { default as Icon } from './components/Icon';
|
|
|
13
13
|
export { type IconName } from './components/Icon/types';
|
|
14
14
|
export { default as IconItem } from './components/IconItem';
|
|
15
15
|
export { ReactPortal } from './components/ReactPortal';
|
|
16
|
+
export { default as Illustration } from './components/Illustration';
|
|
16
17
|
export { default as Label } from './components/Label';
|
|
17
18
|
export { default as List } from './components/List';
|
|
18
19
|
export { Modal } from './components/Modal';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AACzC,OAAO,EAAE,OAAO,IAAI,W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AwB,CAAC;AACnD,cAAc,uBAAuB,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAGhE,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,6BAA6B,CAAC;AACxE,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AACjE,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,+CAA+C,CAAC;AACtF,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAExD,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,mCAAmC,CAAC;AACxE,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,2CAA2C,CAAC;AAGrF,cAAc,gBAAgB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -18,6 +18,7 @@ var _exportNames = {
|
|
|
18
18
|
Icon: true,
|
|
19
19
|
IconItem: true,
|
|
20
20
|
ReactPortal: true,
|
|
21
|
+
Illustration: true,
|
|
21
22
|
Label: true,
|
|
22
23
|
List: true,
|
|
23
24
|
Modal: true,
|
|
@@ -142,6 +143,12 @@ Object.defineProperty(exports, "IconItem", {
|
|
|
142
143
|
return _IconItem.default;
|
|
143
144
|
}
|
|
144
145
|
});
|
|
146
|
+
Object.defineProperty(exports, "Illustration", {
|
|
147
|
+
enumerable: true,
|
|
148
|
+
get: function get() {
|
|
149
|
+
return _Illustration.default;
|
|
150
|
+
}
|
|
151
|
+
});
|
|
145
152
|
Object.defineProperty(exports, "Input", {
|
|
146
153
|
enumerable: true,
|
|
147
154
|
get: function get() {
|
|
@@ -321,6 +328,8 @@ var _IconItem = _interopRequireDefault(require("./components/IconItem"));
|
|
|
321
328
|
|
|
322
329
|
var _ReactPortal = require("./components/ReactPortal");
|
|
323
330
|
|
|
331
|
+
var _Illustration = _interopRequireDefault(require("./components/Illustration"));
|
|
332
|
+
|
|
324
333
|
var _Label = _interopRequireDefault(require("./components/Label"));
|
|
325
334
|
|
|
326
335
|
var _List = _interopRequireDefault(require("./components/List"));
|