@lideralia/alife-uikit 1.3.13 → 1.3.15
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/atoms/Input/styles.js +1 -0
- package/dist/atoms/Typography/Typography.js +4 -1
- package/dist/atoms/Uploader/Uploader.js +18 -8
- package/dist/atoms/imgs/AI.js +39 -0
- package/dist/atoms/imgs/BiographicalEditor.js +240 -0
- package/dist/atoms/imgs/Briefcase.js +39 -0
- package/dist/atoms/imgs/Camera.js +41 -0
- package/dist/atoms/imgs/Cover.js +170 -0
- package/dist/atoms/imgs/Diamond.js +41 -0
- package/dist/atoms/imgs/Happy.js +38 -0
- package/dist/atoms/imgs/Heart.js +38 -0
- package/dist/atoms/imgs/Music.js +38 -0
- package/dist/atoms/imgs/Plant.js +38 -0
- package/dist/atoms/imgs/Sunrise.js +39 -0
- package/dist/atoms/imgs/index.js +88 -0
- package/dist/index.js +63 -0
- package/dist/molecules/BiographicalEditor/QuestionCard/QuestionCard.js +86 -0
- package/dist/molecules/BiographicalEditor/QuestionCard/QuestionCard.stories.js +120 -0
- package/dist/molecules/BiographicalEditor/QuestionCard/index.js +13 -0
- package/dist/molecules/BlockCard/BlockCard.js +140 -0
- package/dist/molecules/BlockCard/BlockCard.stories.js +130 -0
- package/dist/molecules/BlockCard/index.js +13 -0
- package/dist/organisms/BiographicalEditor/BlockProgress/BlockProgress.js +89 -0
- package/dist/organisms/BiographicalEditor/BlockProgress/BlockProgress.stories.js +159 -0
- package/dist/organisms/BiographicalEditor/BlockProgress/index.js +15 -0
- package/dist/organisms/BiographicalEditor/EditorBanner/EditorBanner.js +97 -0
- package/dist/organisms/BiographicalEditor/EditorBanner/EditorBanner.stories.js +46 -0
- package/dist/organisms/BiographicalEditor/EditorBanner/index.js +13 -0
- package/dist/organisms/BiographicalEditor/EditorBlockFooter/EditorBlockFooter.js +147 -0
- package/dist/organisms/BiographicalEditor/EditorBlockFooter/EditorBlockFooter.stories.js +166 -0
- package/dist/organisms/BiographicalEditor/EditorBlockFooter/index.js +15 -0
- package/dist/organisms/BiographicalEditor/EditorGeneratingCard/EditorGeneratingCard.js +146 -0
- package/dist/organisms/BiographicalEditor/EditorGeneratingCard/EditorGeneratingCard.stories.js +113 -0
- package/dist/organisms/BiographicalEditor/EditorGeneratingCard/index.js +15 -0
- package/dist/organisms/BiographicalEditor/EditorProgress/EditorProgress.js +136 -0
- package/dist/organisms/BiographicalEditor/EditorProgress/EditorProgress.stories.js +213 -0
- package/dist/organisms/BiographicalEditor/EditorProgress/index.js +15 -0
- package/dist/organisms/Cards/Adviser.js +1 -0
- package/dist/organisms/Cards/Badges.js +1 -0
- package/dist/organisms/Cards/CardUsersResultOfFlowers.js +1 -0
- package/dist/organisms/Cards/Ceremony.js +2 -0
- package/dist/organisms/Cards/Content.js +1 -0
- package/dist/organisms/Cards/Gone.js +7 -3
- package/dist/organisms/Cards/GoneBasic.js +2 -1
- package/dist/organisms/Cards/GoneCeremony.js +3 -0
- package/dist/organisms/Cards/PersonalData.js +5 -0
- package/dist/organisms/Cards/Udiana.js +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.EditorBanner = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireDefault(require("react"));
|
|
11
|
+
|
|
12
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
13
|
+
|
|
14
|
+
var _Icon = require("../../../atoms/Icon");
|
|
15
|
+
|
|
16
|
+
var _Icons = require("../../../atoms/Icons");
|
|
17
|
+
|
|
18
|
+
var _imgs = require("../../../atoms/imgs");
|
|
19
|
+
|
|
20
|
+
var _Layout = require("../../../atoms/Layout");
|
|
21
|
+
|
|
22
|
+
var _Typography = require("../../../atoms/Typography");
|
|
23
|
+
|
|
24
|
+
const BannerWrapper = (0, _styledComponents.default)(_Layout.Flex).withConfig({
|
|
25
|
+
displayName: "EditorBanner__BannerWrapper",
|
|
26
|
+
componentId: "sc-1hovzse-0"
|
|
27
|
+
})(["cursor:pointer;background-color:#feae36;border:1px solid #feae36;border-radius:18px;box-shadow:0px 8px 18px 0px rgba(60,54,58,0.1);overflow:hidden;position:relative;width:100%;align-items:center;padding:18px 18px 18px 12px;gap:9px;&::before{content:'';position:absolute;inset:0;background-color:rgba(255,255,255,0.6);pointer-events:none;}"]);
|
|
28
|
+
const IllustrationBox = (0, _styledComponents.default)(_Layout.Flex).withConfig({
|
|
29
|
+
displayName: "EditorBanner__IllustrationBox",
|
|
30
|
+
componentId: "sc-1hovzse-1"
|
|
31
|
+
})(["flex-shrink:0;align-items:center;justify-content:center;width:48px;height:48px;position:relative;"]);
|
|
32
|
+
const Badge = (0, _styledComponents.default)(_Layout.Box).withConfig({
|
|
33
|
+
displayName: "EditorBanner__Badge",
|
|
34
|
+
componentId: "sc-1hovzse-2"
|
|
35
|
+
})(["background-color:#f87818;border-radius:19px;padding:2px 10px;display:inline-flex;align-items:center;justify-content:center;width:fit-content;"]);
|
|
36
|
+
const ArrowCircle = (0, _styledComponents.default)(_Layout.Flex).withConfig({
|
|
37
|
+
displayName: "EditorBanner__ArrowCircle",
|
|
38
|
+
componentId: "sc-1hovzse-3"
|
|
39
|
+
})(["background-color:#f87818;border-radius:100px;flex-shrink:0;align-items:center;justify-content:center;width:36px;height:36px;position:relative;"]);
|
|
40
|
+
|
|
41
|
+
const OverlayLayer = _styledComponents.default.div.withConfig({
|
|
42
|
+
displayName: "EditorBanner__OverlayLayer",
|
|
43
|
+
componentId: "sc-1hovzse-4"
|
|
44
|
+
})(["position:absolute;inset:0;z-index:0;border-radius:18px;background:linear-gradient(345deg,rgba(255,255,255,0.15) 14.95%,rgba(255,255,255,0.50) 23.45%,rgba(255,255,255,0.70) 31.96%,rgba(255,255,255,0.80) 40.46%,rgba(255,255,255,0.90) 48.97%,rgba(255,255,255,0.90) 49.82%,rgba(255,255,255,0.95) 57.47%,rgba(255,255,255,0.98) 60.88%,#FFF 65.98%);pointer-events:none;opacity:0.72;"]);
|
|
45
|
+
|
|
46
|
+
const EditorBanner = _ref => {
|
|
47
|
+
let {
|
|
48
|
+
onClick,
|
|
49
|
+
badgeLabel,
|
|
50
|
+
title
|
|
51
|
+
} = _ref;
|
|
52
|
+
return _react.default.createElement(BannerWrapper, {
|
|
53
|
+
onClick: onClick,
|
|
54
|
+
role: "button",
|
|
55
|
+
tabIndex: 0,
|
|
56
|
+
onKeyDown: e => e.key === 'Enter' && onClick && onClick()
|
|
57
|
+
}, _react.default.createElement(OverlayLayer, null), _react.default.createElement(_Layout.Flex, {
|
|
58
|
+
flex: "1",
|
|
59
|
+
gap: "9px",
|
|
60
|
+
alignItems: "center",
|
|
61
|
+
position: "relative",
|
|
62
|
+
minWidth: 0
|
|
63
|
+
}, _react.default.createElement(IllustrationBox, null, _react.default.createElement(_imgs.BiographicalEditor, {
|
|
64
|
+
width: "48",
|
|
65
|
+
height: "48"
|
|
66
|
+
})), _react.default.createElement(_Layout.Flex, {
|
|
67
|
+
flexDirection: "column",
|
|
68
|
+
gap: "2px",
|
|
69
|
+
justifyContent: "center",
|
|
70
|
+
flex: "1",
|
|
71
|
+
minWidth: 0
|
|
72
|
+
}, _react.default.createElement(Badge, null, _react.default.createElement(_Typography.Text, {
|
|
73
|
+
as: "span",
|
|
74
|
+
sizeText: "display12",
|
|
75
|
+
color: "white",
|
|
76
|
+
fontWeight: "bold",
|
|
77
|
+
style: {
|
|
78
|
+
whiteSpace: 'nowrap'
|
|
79
|
+
}
|
|
80
|
+
}, badgeLabel)), _react.default.createElement(_Typography.Text, {
|
|
81
|
+
sizeText: "display16",
|
|
82
|
+
color: "black96",
|
|
83
|
+
fontWeight: "bold",
|
|
84
|
+
style: {
|
|
85
|
+
whiteSpace: 'nowrap'
|
|
86
|
+
}
|
|
87
|
+
}, title))), _react.default.createElement(ArrowCircle, {
|
|
88
|
+
position: "relative"
|
|
89
|
+
}, _react.default.createElement(_Icon.Icon, {
|
|
90
|
+
sizeIcon: "display24",
|
|
91
|
+
color: "white"
|
|
92
|
+
}, _react.default.createElement(_Icons.IconArrowRight, {
|
|
93
|
+
stroke: "white"
|
|
94
|
+
}))));
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
exports.EditorBanner = EditorBanner;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = exports.Default = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireDefault(require("react"));
|
|
11
|
+
|
|
12
|
+
var _Layout = require("../../../atoms/Layout");
|
|
13
|
+
|
|
14
|
+
var _EditorBanner = require("./EditorBanner");
|
|
15
|
+
|
|
16
|
+
var _default = {
|
|
17
|
+
title: 'Organisms/BiographicalEditor/EditorBanner',
|
|
18
|
+
component: _EditorBanner.EditorBanner,
|
|
19
|
+
argTypes: {
|
|
20
|
+
badgeLabel: {
|
|
21
|
+
control: 'text'
|
|
22
|
+
},
|
|
23
|
+
title: {
|
|
24
|
+
control: 'text'
|
|
25
|
+
},
|
|
26
|
+
onClick: {
|
|
27
|
+
action: 'clicked'
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
};
|
|
31
|
+
exports.default = _default;
|
|
32
|
+
|
|
33
|
+
const Template = args => _react.default.createElement(_Layout.Container, null, _react.default.createElement(_Layout.Row, {
|
|
34
|
+
justifyContent: "center",
|
|
35
|
+
alignItems: "center"
|
|
36
|
+
}, _react.default.createElement(_Layout.Col, {
|
|
37
|
+
width: [1, 1, 1 / 2]
|
|
38
|
+
}, _react.default.createElement(_EditorBanner.EditorBanner, args))));
|
|
39
|
+
|
|
40
|
+
const Default = Template.bind({});
|
|
41
|
+
exports.Default = Default;
|
|
42
|
+
Default.args = {
|
|
43
|
+
badgeLabel: 'Pruébalo',
|
|
44
|
+
title: 'Editor Biográfico'
|
|
45
|
+
};
|
|
46
|
+
Default.storyName = 'EditorBanner (default)';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
Object.defineProperty(exports, "EditorBanner", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function () {
|
|
9
|
+
return _EditorBanner.EditorBanner;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
|
|
13
|
+
var _EditorBanner = require("./EditorBanner");
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = exports.EditorBlockFooter = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireDefault(require("react"));
|
|
11
|
+
|
|
12
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
13
|
+
|
|
14
|
+
var _Icon = require("../../../atoms/Icon");
|
|
15
|
+
|
|
16
|
+
var _Icons = require("../../../atoms/Icons");
|
|
17
|
+
|
|
18
|
+
const Wrap = _styledComponents.default.div.withConfig({
|
|
19
|
+
displayName: "EditorBlockFooter__Wrap",
|
|
20
|
+
componentId: "sc-9x2kud-0"
|
|
21
|
+
})(["width:100%;background:#ffffff;border-radius:18px 18px 0 0;box-shadow:0px -8px 18px 0px rgba(60,54,58,0.1);display:flex;flex-direction:column;padding-top:18px;"]);
|
|
22
|
+
|
|
23
|
+
const ProgressSection = _styledComponents.default.div.withConfig({
|
|
24
|
+
displayName: "EditorBlockFooter__ProgressSection",
|
|
25
|
+
componentId: "sc-9x2kud-1"
|
|
26
|
+
})(["padding:0 18px;display:flex;flex-direction:column;gap:6px;"]);
|
|
27
|
+
|
|
28
|
+
const BarWrap = _styledComponents.default.div.withConfig({
|
|
29
|
+
displayName: "EditorBlockFooter__BarWrap",
|
|
30
|
+
componentId: "sc-9x2kud-2"
|
|
31
|
+
})(["position:relative;width:100%;height:6px;border-radius:12px;overflow:hidden;display:flex;background:transparent;"]);
|
|
32
|
+
|
|
33
|
+
const Segment = _styledComponents.default.div.withConfig({
|
|
34
|
+
displayName: "EditorBlockFooter__Segment",
|
|
35
|
+
componentId: "sc-9x2kud-3"
|
|
36
|
+
})(["flex:1 0 0;height:6px;min-width:1px;background-color:", ";"], _ref => {
|
|
37
|
+
let {
|
|
38
|
+
filled
|
|
39
|
+
} = _ref;
|
|
40
|
+
return filled ? '#2396fb' : '#e5e5e8';
|
|
41
|
+
});
|
|
42
|
+
|
|
43
|
+
const BarFill = _styledComponents.default.div.withConfig({
|
|
44
|
+
displayName: "EditorBlockFooter__BarFill",
|
|
45
|
+
componentId: "sc-9x2kud-4"
|
|
46
|
+
})(["height:100%;width:", "%;background-color:", ";border-radius:12px;transition:width 0.2s ease;"], _ref2 => {
|
|
47
|
+
let {
|
|
48
|
+
percent
|
|
49
|
+
} = _ref2;
|
|
50
|
+
return percent;
|
|
51
|
+
}, _ref3 => {
|
|
52
|
+
let {
|
|
53
|
+
over
|
|
54
|
+
} = _ref3;
|
|
55
|
+
return over ? '#e53e3e' : '#5fb3fc';
|
|
56
|
+
});
|
|
57
|
+
|
|
58
|
+
const InfoRow = _styledComponents.default.div.withConfig({
|
|
59
|
+
displayName: "EditorBlockFooter__InfoRow",
|
|
60
|
+
componentId: "sc-9x2kud-5"
|
|
61
|
+
})(["display:flex;justify-content:space-between;align-items:flex-start;padding:0 6px;font-family:Inter,sans-serif;font-size:12px;font-weight:700;line-height:18px;white-space:nowrap;"]);
|
|
62
|
+
|
|
63
|
+
const StepLabel = _styledComponents.default.span.withConfig({
|
|
64
|
+
displayName: "EditorBlockFooter__StepLabel",
|
|
65
|
+
componentId: "sc-9x2kud-6"
|
|
66
|
+
})(["color:#7f7f8a;"]);
|
|
67
|
+
|
|
68
|
+
const BlockName = _styledComponents.default.span.withConfig({
|
|
69
|
+
displayName: "EditorBlockFooter__BlockName",
|
|
70
|
+
componentId: "sc-9x2kud-7"
|
|
71
|
+
})(["color:#2396fb;"]);
|
|
72
|
+
|
|
73
|
+
const ButtonsRow = _styledComponents.default.div.withConfig({
|
|
74
|
+
displayName: "EditorBlockFooter__ButtonsRow",
|
|
75
|
+
componentId: "sc-9x2kud-8"
|
|
76
|
+
})(["display:flex;gap:18px;align-items:center;padding:12px 18px 18px;background:#ffffff;"]);
|
|
77
|
+
|
|
78
|
+
const BackBtn = _styledComponents.default.button.withConfig({
|
|
79
|
+
displayName: "EditorBlockFooter__BackBtn",
|
|
80
|
+
componentId: "sc-9x2kud-9"
|
|
81
|
+
})(["display:flex;align-items:center;justify-content:center;flex-shrink:0;height:48px;padding:0 21px;border:none;border-radius:14px;background-color:#e5e5e8;font-family:Inter,sans-serif;font-size:14px;font-weight:700;line-height:24px;color:#7f7f8a;cursor:pointer;white-space:nowrap;box-sizing:border-box;&:hover{background-color:#d5d5da;}&:active{background-color:#c8c8ce;}"]);
|
|
82
|
+
|
|
83
|
+
const SaveBtn = _styledComponents.default.button.withConfig({
|
|
84
|
+
displayName: "EditorBlockFooter__SaveBtn",
|
|
85
|
+
componentId: "sc-9x2kud-10"
|
|
86
|
+
})(["display:flex;align-items:center;justify-content:center;gap:6px;flex:1 0 0;height:48px;min-height:48px;min-width:1px;border:none;border-radius:14px;background-color:#2396fb;opacity:", ";cursor:", ";pointer-events:", ";padding:0 12px;font-family:Inter,sans-serif;font-size:14px;font-weight:700;line-height:24px;color:#ffffff;box-sizing:border-box;transition:opacity 0.2s ease;&:not(:disabled):hover{background-color:#1d85e0;}&:not(:disabled):active{background-color:#1773c6;}"], _ref4 => {
|
|
87
|
+
let {
|
|
88
|
+
disabled
|
|
89
|
+
} = _ref4;
|
|
90
|
+
return disabled ? 0.48 : 1;
|
|
91
|
+
}, _ref5 => {
|
|
92
|
+
let {
|
|
93
|
+
disabled
|
|
94
|
+
} = _ref5;
|
|
95
|
+
return disabled ? 'not-allowed' : 'pointer';
|
|
96
|
+
}, _ref6 => {
|
|
97
|
+
let {
|
|
98
|
+
disabled
|
|
99
|
+
} = _ref6;
|
|
100
|
+
return disabled ? 'none' : 'auto';
|
|
101
|
+
});
|
|
102
|
+
|
|
103
|
+
const EditorBlockFooter = _ref7 => {
|
|
104
|
+
let {
|
|
105
|
+
currentStep,
|
|
106
|
+
totalSteps,
|
|
107
|
+
stepLabel,
|
|
108
|
+
blockName,
|
|
109
|
+
barPercent,
|
|
110
|
+
backLabel,
|
|
111
|
+
saveLabel,
|
|
112
|
+
saveDisabled,
|
|
113
|
+
onBack,
|
|
114
|
+
onSave
|
|
115
|
+
} = _ref7;
|
|
116
|
+
return _react.default.createElement(Wrap, null, _react.default.createElement(ProgressSection, null, _react.default.createElement(BarWrap, null, barPercent != null ? _react.default.createElement(BarFill, {
|
|
117
|
+
percent: barPercent,
|
|
118
|
+
over: currentStep > totalSteps
|
|
119
|
+
}) : Array.from({
|
|
120
|
+
length: totalSteps
|
|
121
|
+
}, (_, i) => _react.default.createElement(Segment, {
|
|
122
|
+
key: i,
|
|
123
|
+
filled: i < currentStep
|
|
124
|
+
}))), _react.default.createElement(InfoRow, null, _react.default.createElement(StepLabel, null, stepLabel !== null && stepLabel !== void 0 ? stepLabel : "".concat(currentStep, " / ").concat(totalSteps)), _react.default.createElement(BlockName, null, blockName))), _react.default.createElement(ButtonsRow, null, _react.default.createElement(BackBtn, {
|
|
125
|
+
type: "button",
|
|
126
|
+
onClick: onBack
|
|
127
|
+
}, backLabel), _react.default.createElement(SaveBtn, {
|
|
128
|
+
type: "button",
|
|
129
|
+
disabled: saveDisabled,
|
|
130
|
+
onClick: onSave
|
|
131
|
+
}, _react.default.createElement(_Icon.Icon, {
|
|
132
|
+
sizeIcon: "display24",
|
|
133
|
+
color: "#ffffff"
|
|
134
|
+
}, _react.default.createElement(_Icons.IconCloud, null)), saveLabel)));
|
|
135
|
+
};
|
|
136
|
+
|
|
137
|
+
exports.EditorBlockFooter = EditorBlockFooter;
|
|
138
|
+
EditorBlockFooter.defaultProps = {
|
|
139
|
+
stepLabel: undefined,
|
|
140
|
+
backLabel: 'Volver',
|
|
141
|
+
saveLabel: 'Guardar bloque',
|
|
142
|
+
saveDisabled: false,
|
|
143
|
+
onBack: undefined,
|
|
144
|
+
onSave: undefined
|
|
145
|
+
};
|
|
146
|
+
var _default = EditorBlockFooter;
|
|
147
|
+
exports.default = _default;
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = exports.RelacionPersonal = exports.Playground = exports.Identidad = exports.FormaDeSerVacio = exports.FamiliaYEntorno = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireDefault(require("react"));
|
|
11
|
+
|
|
12
|
+
var _Layout = require("../../../atoms/Layout");
|
|
13
|
+
|
|
14
|
+
var _EditorBlockFooter = require("./EditorBlockFooter");
|
|
15
|
+
|
|
16
|
+
var _default = {
|
|
17
|
+
title: 'Organisms/BiographicalEditor/EditorBlockFooter',
|
|
18
|
+
component: _EditorBlockFooter.EditorBlockFooter,
|
|
19
|
+
argTypes: {
|
|
20
|
+
currentStep: {
|
|
21
|
+
control: {
|
|
22
|
+
type: 'number',
|
|
23
|
+
min: 0,
|
|
24
|
+
max: 8,
|
|
25
|
+
step: 1
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
totalSteps: {
|
|
29
|
+
control: {
|
|
30
|
+
type: 'number',
|
|
31
|
+
min: 1,
|
|
32
|
+
max: 12,
|
|
33
|
+
step: 1
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
blockName: {
|
|
37
|
+
control: 'text'
|
|
38
|
+
},
|
|
39
|
+
backLabel: {
|
|
40
|
+
control: 'text'
|
|
41
|
+
},
|
|
42
|
+
saveLabel: {
|
|
43
|
+
control: 'text'
|
|
44
|
+
},
|
|
45
|
+
saveDisabled: {
|
|
46
|
+
control: 'boolean'
|
|
47
|
+
},
|
|
48
|
+
onBack: {
|
|
49
|
+
action: 'onBack'
|
|
50
|
+
},
|
|
51
|
+
onSave: {
|
|
52
|
+
action: 'onSave'
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
parameters: {
|
|
56
|
+
layout: 'fullscreen'
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
exports.default = _default;
|
|
60
|
+
|
|
61
|
+
const MobileFrame = _ref => {
|
|
62
|
+
let {
|
|
63
|
+
children
|
|
64
|
+
} = _ref;
|
|
65
|
+
return _react.default.createElement(_Layout.Container, null, _react.default.createElement(_Layout.Row, {
|
|
66
|
+
justifyContent: "center"
|
|
67
|
+
}, _react.default.createElement(_Layout.Col, {
|
|
68
|
+
width: [1, 1, '375px']
|
|
69
|
+
}, _react.default.createElement("div", {
|
|
70
|
+
style: {
|
|
71
|
+
position: 'relative',
|
|
72
|
+
minHeight: '200px',
|
|
73
|
+
display: 'flex',
|
|
74
|
+
alignItems: 'flex-end'
|
|
75
|
+
}
|
|
76
|
+
}, children))));
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
const Identidad = args => _react.default.createElement(MobileFrame, null, _react.default.createElement(_EditorBlockFooter.EditorBlockFooter, args));
|
|
80
|
+
|
|
81
|
+
exports.Identidad = Identidad;
|
|
82
|
+
Identidad.args = {
|
|
83
|
+
currentStep: 1,
|
|
84
|
+
totalSteps: 8,
|
|
85
|
+
blockName: 'Identidad',
|
|
86
|
+
backLabel: 'Volver',
|
|
87
|
+
saveLabel: 'Guardar bloque',
|
|
88
|
+
saveDisabled: false
|
|
89
|
+
};
|
|
90
|
+
Identidad.storyName = 'Paso 1 – Identidad';
|
|
91
|
+
Identidad.parameters = {
|
|
92
|
+
design: {
|
|
93
|
+
type: 'figma',
|
|
94
|
+
url: 'https://www.figma.com/design/2PtpPtWT9wUKUrteJBkvlV?node-id=17941-41955'
|
|
95
|
+
}
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
const FormaDeSerVacio = args => _react.default.createElement(MobileFrame, null, _react.default.createElement(_EditorBlockFooter.EditorBlockFooter, args));
|
|
99
|
+
|
|
100
|
+
exports.FormaDeSerVacio = FormaDeSerVacio;
|
|
101
|
+
FormaDeSerVacio.args = {
|
|
102
|
+
currentStep: 2,
|
|
103
|
+
totalSteps: 8,
|
|
104
|
+
blockName: 'Forma de ser',
|
|
105
|
+
backLabel: 'Volver',
|
|
106
|
+
saveLabel: 'Guardar bloque',
|
|
107
|
+
saveDisabled: true
|
|
108
|
+
};
|
|
109
|
+
FormaDeSerVacio.storyName = 'Paso 2 – Forma de ser (deshabilitado)';
|
|
110
|
+
FormaDeSerVacio.parameters = {
|
|
111
|
+
design: {
|
|
112
|
+
type: 'figma',
|
|
113
|
+
url: 'https://www.figma.com/design/2PtpPtWT9wUKUrteJBkvlV?node-id=17941-41970'
|
|
114
|
+
}
|
|
115
|
+
};
|
|
116
|
+
|
|
117
|
+
const RelacionPersonal = args => _react.default.createElement(MobileFrame, null, _react.default.createElement(_EditorBlockFooter.EditorBlockFooter, args));
|
|
118
|
+
|
|
119
|
+
exports.RelacionPersonal = RelacionPersonal;
|
|
120
|
+
RelacionPersonal.args = {
|
|
121
|
+
currentStep: 3,
|
|
122
|
+
totalSteps: 8,
|
|
123
|
+
blockName: 'Relación personal',
|
|
124
|
+
backLabel: 'Volver',
|
|
125
|
+
saveLabel: 'Guardar bloque',
|
|
126
|
+
saveDisabled: false
|
|
127
|
+
};
|
|
128
|
+
RelacionPersonal.storyName = 'Paso 3 – Relación personal';
|
|
129
|
+
RelacionPersonal.parameters = {
|
|
130
|
+
design: {
|
|
131
|
+
type: 'figma',
|
|
132
|
+
url: 'https://www.figma.com/design/2PtpPtWT9wUKUrteJBkvlV?node-id=17941-41984'
|
|
133
|
+
}
|
|
134
|
+
};
|
|
135
|
+
|
|
136
|
+
const FamiliaYEntorno = args => _react.default.createElement(MobileFrame, null, _react.default.createElement(_EditorBlockFooter.EditorBlockFooter, args));
|
|
137
|
+
|
|
138
|
+
exports.FamiliaYEntorno = FamiliaYEntorno;
|
|
139
|
+
FamiliaYEntorno.args = {
|
|
140
|
+
currentStep: 4,
|
|
141
|
+
totalSteps: 8,
|
|
142
|
+
blockName: 'Familia y entorno',
|
|
143
|
+
backLabel: 'Volver',
|
|
144
|
+
saveLabel: 'Guardar bloque',
|
|
145
|
+
saveDisabled: false
|
|
146
|
+
};
|
|
147
|
+
FamiliaYEntorno.storyName = 'Paso 4 – Familia y entorno';
|
|
148
|
+
FamiliaYEntorno.parameters = {
|
|
149
|
+
design: {
|
|
150
|
+
type: 'figma',
|
|
151
|
+
url: 'https://www.figma.com/design/2PtpPtWT9wUKUrteJBkvlV?node-id=17941-41992'
|
|
152
|
+
}
|
|
153
|
+
};
|
|
154
|
+
|
|
155
|
+
const Playground = args => _react.default.createElement(MobileFrame, null, _react.default.createElement(_EditorBlockFooter.EditorBlockFooter, args));
|
|
156
|
+
|
|
157
|
+
exports.Playground = Playground;
|
|
158
|
+
Playground.args = {
|
|
159
|
+
currentStep: 2,
|
|
160
|
+
totalSteps: 8,
|
|
161
|
+
blockName: 'Forma de ser',
|
|
162
|
+
backLabel: 'Volver',
|
|
163
|
+
saveLabel: 'Guardar bloque',
|
|
164
|
+
saveDisabled: false
|
|
165
|
+
};
|
|
166
|
+
Playground.storyName = 'Playground (interactivo)';
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
Object.defineProperty(exports, "EditorBlockFooter", {
|
|
9
|
+
enumerable: true,
|
|
10
|
+
get: function () {
|
|
11
|
+
return _EditorBlockFooter.default;
|
|
12
|
+
}
|
|
13
|
+
});
|
|
14
|
+
|
|
15
|
+
var _EditorBlockFooter = _interopRequireDefault(require("./EditorBlockFooter"));
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = exports.EditorGeneratingCard = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireDefault(require("react"));
|
|
11
|
+
|
|
12
|
+
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
13
|
+
|
|
14
|
+
var _Icon = require("../../../atoms/Icon");
|
|
15
|
+
|
|
16
|
+
var _imgs = require("../../../atoms/imgs");
|
|
17
|
+
|
|
18
|
+
var _Typography = require("../../../atoms/Typography");
|
|
19
|
+
|
|
20
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
21
|
+
|
|
22
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
23
|
+
|
|
24
|
+
const spin = (0, _styledComponents.keyframes)(["from{transform:rotate(0deg);}to{transform:rotate(360deg);}"]);
|
|
25
|
+
|
|
26
|
+
const Card = _styledComponents.default.div.withConfig({
|
|
27
|
+
displayName: "EditorGeneratingCard__Card",
|
|
28
|
+
componentId: "sc-1hvs2dw-0"
|
|
29
|
+
})(["background:#ffffff;border-radius:18px;box-shadow:0px 8px 18px 0px rgba(60,54,58,0.1);padding:36px 18px;display:flex;flex-direction:column;align-items:center;gap:12px;width:100%;box-sizing:border-box;overflow:hidden;"]);
|
|
30
|
+
|
|
31
|
+
const RingWrap = _styledComponents.default.div.withConfig({
|
|
32
|
+
displayName: "EditorGeneratingCard__RingWrap",
|
|
33
|
+
componentId: "sc-1hvs2dw-1"
|
|
34
|
+
})(["position:relative;width:102px;height:102px;flex-shrink:0;display:flex;align-items:center;justify-content:center;"]);
|
|
35
|
+
|
|
36
|
+
const SpinningSVG = _styledComponents.default.svg.withConfig({
|
|
37
|
+
displayName: "EditorGeneratingCard__SpinningSVG",
|
|
38
|
+
componentId: "sc-1hvs2dw-2"
|
|
39
|
+
})(["position:absolute;inset:0;animation:", " 2s linear infinite;transform-origin:51px 51px;"], spin);
|
|
40
|
+
|
|
41
|
+
const ARC_R = 48;
|
|
42
|
+
const ARC_CX = 51;
|
|
43
|
+
const ARC_CY = 51;
|
|
44
|
+
const ARC_CIRC = 2 * Math.PI * ARC_R;
|
|
45
|
+
const ARC_LEN = ARC_CIRC * 0.28;
|
|
46
|
+
|
|
47
|
+
const InnerCircle = _styledComponents.default.div.withConfig({
|
|
48
|
+
displayName: "EditorGeneratingCard__InnerCircle",
|
|
49
|
+
componentId: "sc-1hvs2dw-3"
|
|
50
|
+
})(["position:relative;z-index:1;width:72px;height:72px;border-radius:50%;background:#5fb3fc;display:flex;align-items:center;justify-content:center;box-sizing:border-box;padding:6px;overflow:hidden;"]);
|
|
51
|
+
|
|
52
|
+
const Block = _styledComponents.default.div.withConfig({
|
|
53
|
+
displayName: "EditorGeneratingCard__Block",
|
|
54
|
+
componentId: "sc-1hvs2dw-4"
|
|
55
|
+
})(["display:flex;flex-direction:column;align-items:flex-start;width:100%;"]);
|
|
56
|
+
|
|
57
|
+
const TitleRow = _styledComponents.default.div.withConfig({
|
|
58
|
+
displayName: "EditorGeneratingCard__TitleRow",
|
|
59
|
+
componentId: "sc-1hvs2dw-5"
|
|
60
|
+
})(["display:flex;align-items:center;justify-content:center;width:100%;gap:6px;min-height:48px;"]);
|
|
61
|
+
|
|
62
|
+
const StatusSection = _styledComponents.default.div.withConfig({
|
|
63
|
+
displayName: "EditorGeneratingCard__StatusSection",
|
|
64
|
+
componentId: "sc-1hvs2dw-6"
|
|
65
|
+
})(["display:flex;flex-direction:column;align-items:center;padding:12px 6px 0;width:100%;"]);
|
|
66
|
+
|
|
67
|
+
const EditorGeneratingCard = _ref => {
|
|
68
|
+
let {
|
|
69
|
+
title,
|
|
70
|
+
subtitle,
|
|
71
|
+
statusLabel,
|
|
72
|
+
illustration
|
|
73
|
+
} = _ref;
|
|
74
|
+
return _react.default.createElement(Card, null, _react.default.createElement(RingWrap, null, _react.default.createElement(SpinningSVG, {
|
|
75
|
+
width: 102,
|
|
76
|
+
height: 102,
|
|
77
|
+
viewBox: "0 0 102 102",
|
|
78
|
+
fill: "none",
|
|
79
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
80
|
+
"aria-hidden": true
|
|
81
|
+
}, _react.default.createElement("circle", {
|
|
82
|
+
cx: ARC_CX,
|
|
83
|
+
cy: ARC_CY,
|
|
84
|
+
r: ARC_R,
|
|
85
|
+
stroke: "#e5e5e8",
|
|
86
|
+
strokeWidth: 3
|
|
87
|
+
}), _react.default.createElement("circle", {
|
|
88
|
+
cx: ARC_CX,
|
|
89
|
+
cy: ARC_CY,
|
|
90
|
+
r: ARC_R,
|
|
91
|
+
stroke: "#2396fb",
|
|
92
|
+
strokeWidth: 3,
|
|
93
|
+
strokeLinecap: "round",
|
|
94
|
+
strokeDasharray: "".concat(ARC_LEN, " ").concat(ARC_CIRC - ARC_LEN),
|
|
95
|
+
transform: "rotate(-90 ".concat(ARC_CX, " ").concat(ARC_CY, ")")
|
|
96
|
+
})), _react.default.createElement(InnerCircle, null, illustration)), _react.default.createElement(Block, null, _react.default.createElement(TitleRow, null, _react.default.createElement(_Icon.Icon, {
|
|
97
|
+
sizeIcon: "display24",
|
|
98
|
+
color: "#2396fb"
|
|
99
|
+
}, _react.default.createElement(_imgs.AI, {
|
|
100
|
+
color: "#2396fb"
|
|
101
|
+
})), _react.default.createElement(_Typography.Text, {
|
|
102
|
+
as: "p",
|
|
103
|
+
sizeText: "display14",
|
|
104
|
+
fontWeight: "bold",
|
|
105
|
+
color: "#2396fb",
|
|
106
|
+
margin: 0,
|
|
107
|
+
style: {
|
|
108
|
+
lineHeight: '24px',
|
|
109
|
+
textAlign: 'center'
|
|
110
|
+
}
|
|
111
|
+
}, title)), subtitle && _react.default.createElement(_Typography.Text, {
|
|
112
|
+
as: "p",
|
|
113
|
+
sizeText: "display13",
|
|
114
|
+
fontWeight: "medium",
|
|
115
|
+
color: "#7f7f8a",
|
|
116
|
+
margin: 0,
|
|
117
|
+
style: {
|
|
118
|
+
lineHeight: '18px',
|
|
119
|
+
textAlign: 'center',
|
|
120
|
+
width: '100%'
|
|
121
|
+
}
|
|
122
|
+
}, subtitle)), statusLabel && _react.default.createElement(StatusSection, null, _react.default.createElement(_Typography.Text, {
|
|
123
|
+
as: "p",
|
|
124
|
+
sizeText: "display12",
|
|
125
|
+
fontWeight: "medium",
|
|
126
|
+
color: "#2396fb",
|
|
127
|
+
margin: 0,
|
|
128
|
+
style: {
|
|
129
|
+
lineHeight: '18px',
|
|
130
|
+
whiteSpace: 'nowrap'
|
|
131
|
+
}
|
|
132
|
+
}, statusLabel)));
|
|
133
|
+
};
|
|
134
|
+
|
|
135
|
+
exports.EditorGeneratingCard = EditorGeneratingCard;
|
|
136
|
+
EditorGeneratingCard.defaultProps = {
|
|
137
|
+
title: 'Generando memoria biográfica',
|
|
138
|
+
subtitle: 'Estamos creando un texto único\nbasado en tus respuestas',
|
|
139
|
+
statusLabel: 'Razonando...',
|
|
140
|
+
illustration: _react.default.createElement(_imgs.Cover, {
|
|
141
|
+
width: 60,
|
|
142
|
+
height: 60
|
|
143
|
+
})
|
|
144
|
+
};
|
|
145
|
+
var _default = EditorGeneratingCard;
|
|
146
|
+
exports.default = _default;
|