pds-dev-kit-web-test 2.7.536 → 2.7.538
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/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Button/Button.js +10 -1
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Image/Image.js +6 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Text/Text.js +15 -1
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/VideoPlayer/VideoPlayer.js +6 -0
- package/package.json +1 -1
|
@@ -106,16 +106,25 @@ function Button(props) {
|
|
|
106
106
|
CB_CONTENT_PROP_TEXT_SPEC_VALUETYPE === 'DELEGATEDDATA';
|
|
107
107
|
if (isDataConnected) {
|
|
108
108
|
if (queryContext === null || queryContext === void 0 ? void 0 : queryContext.queryData) {
|
|
109
|
+
if (!queryContext.queryData.hasOwn(CB_CONTENT_PROP_TEXT_SPEC_CONNECTDATA)) {
|
|
110
|
+
if (mode === 'EDIT') {
|
|
111
|
+
return (0, jsx_runtime_1.jsx)(DataNotFound_1.default, { stringKey: "str_10478" });
|
|
112
|
+
}
|
|
113
|
+
return '';
|
|
114
|
+
}
|
|
109
115
|
var value = queryContext.queryData[CB_CONTENT_PROP_TEXT_SPEC_CONNECTDATA];
|
|
110
116
|
if (formatOption) {
|
|
111
117
|
return formatOption.formatter(value);
|
|
112
118
|
}
|
|
119
|
+
if (!value && mode === 'EDIT') {
|
|
120
|
+
return (0, jsx_runtime_1.jsx)(DataNotFound_1.default, { stringKey: "str_10597" });
|
|
121
|
+
}
|
|
113
122
|
return value;
|
|
114
123
|
}
|
|
115
124
|
if (mode === 'EDIT') {
|
|
116
125
|
return (0, jsx_runtime_1.jsx)(DataNotFound_1.default, { stringKey: "str_10478" });
|
|
117
126
|
}
|
|
118
|
-
return
|
|
127
|
+
return '';
|
|
119
128
|
}
|
|
120
129
|
if (device === 'MOBILE' &&
|
|
121
130
|
mode !== 'EDIT' &&
|
|
@@ -118,6 +118,12 @@ function Image(props) {
|
|
|
118
118
|
if (!(queryContext === null || queryContext === void 0 ? void 0 : queryContext.queryData)) {
|
|
119
119
|
return true;
|
|
120
120
|
}
|
|
121
|
+
if (!queryContext.queryData.hasOwn(CB_CONTENT_PROP_IMAGE.CB_CONTENT_PROP_IMAGE_SPEC_CONNECTDATA)) {
|
|
122
|
+
if (mode === 'EDIT') {
|
|
123
|
+
return true;
|
|
124
|
+
}
|
|
125
|
+
return false;
|
|
126
|
+
}
|
|
121
127
|
if (!queryContext.queryData[CB_CONTENT_PROP_IMAGE.CB_CONTENT_PROP_IMAGE_SPEC_CONNECTDATA]) {
|
|
122
128
|
return true;
|
|
123
129
|
}
|
|
@@ -94,11 +94,25 @@ function Text(props) {
|
|
|
94
94
|
CB_CONTENT_PROP_TEXT_SPEC_VALUETYPE === 'DELEGATEDDATA';
|
|
95
95
|
if (isDataConnected) {
|
|
96
96
|
if (queryContext === null || queryContext === void 0 ? void 0 : queryContext.queryData) {
|
|
97
|
+
if (!queryContext.queryData.hasOwn(CB_CONTENT_PROP_TEXT_SPEC_CONNECTDATA)) {
|
|
98
|
+
if (mode === 'EDIT') {
|
|
99
|
+
return (0, jsx_runtime_1.jsx)(DataNotFound_1.default, { stringKey: "str_10478" });
|
|
100
|
+
}
|
|
101
|
+
return (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, {});
|
|
102
|
+
}
|
|
97
103
|
var value = queryContext.queryData[CB_CONTENT_PROP_TEXT_SPEC_CONNECTDATA];
|
|
98
104
|
if (Array.isArray(value)) {
|
|
99
105
|
// 각 객체에서 name만 추출하여 문자열 배열로 만든 뒤 결합
|
|
100
106
|
return value.map(function (item) { return item.name; }).join(', ');
|
|
101
107
|
}
|
|
108
|
+
if (CB_CONTENT_PROP_TEXT_SPEC_CONNECTDATA === 'saleStatus') {
|
|
109
|
+
if (value === 'ACTIVE') {
|
|
110
|
+
return t('str_commerce_products_status_sale_active');
|
|
111
|
+
}
|
|
112
|
+
if (value === 'DISCONTINUED') {
|
|
113
|
+
return t('str_commerce_products_status_sale_stopped');
|
|
114
|
+
}
|
|
115
|
+
}
|
|
102
116
|
if (CB_CONTENT_PROP_TEXT_SPEC_CONNECTDATA === 'paid') {
|
|
103
117
|
if (value === 'PAID') {
|
|
104
118
|
return t('str_paid');
|
|
@@ -121,7 +135,7 @@ function Text(props) {
|
|
|
121
135
|
return formatOption.formatter(convertToUTC(value));
|
|
122
136
|
}
|
|
123
137
|
if (!value && mode === 'EDIT') {
|
|
124
|
-
return
|
|
138
|
+
return (0, jsx_runtime_1.jsx)(DataNotFound_1.default, { stringKey: "str_10597" });
|
|
125
139
|
}
|
|
126
140
|
return value;
|
|
127
141
|
}
|
|
@@ -152,6 +152,12 @@ function VideoPlayer(props) {
|
|
|
152
152
|
if (!(queryContext === null || queryContext === void 0 ? void 0 : queryContext.queryData)) {
|
|
153
153
|
return true;
|
|
154
154
|
}
|
|
155
|
+
if (!queryContext.queryData.hasOwn(CB_CONTENT_PROP_VIDEO.CB_CONTENT_PROP_VIDEO_SPEC_CONNECTDATA)) {
|
|
156
|
+
if (mode === 'EDIT') {
|
|
157
|
+
return true;
|
|
158
|
+
}
|
|
159
|
+
return false;
|
|
160
|
+
}
|
|
155
161
|
if (!queryContext.queryData[CB_CONTENT_PROP_VIDEO.CB_CONTENT_PROP_VIDEO_SPEC_CONNECTDATA]) {
|
|
156
162
|
return true;
|
|
157
163
|
}
|