@antscorp/antsomi-ui 1.3.5-beta.127 → 1.3.5-beta.129
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/es/components/common/ConfigProvider/GlobalStyle.js +1 -3
- package/es/components/molecules/ShareAccess/components/GeneralAccess/GeneralAccess.js +2 -2
- package/es/components/molecules/TemplateSaveAs/TemplateSaveAs.js +1 -1
- package/es/components/molecules/ThumbnailCard/ThumbnailCard.js +2 -2
- package/es/components/organism/PreviewTemplateModal/components/Information/index.js +11 -6
- package/es/components/organism/PreviewTemplateModal/styled.js +1 -1
- package/es/constants/theme.js +5 -5
- package/package.json +1 -1
|
@@ -35,10 +35,10 @@ export const GeneralAccess = ({ generalAccessSettings }) => {
|
|
|
35
35
|
const renderDescription = () => {
|
|
36
36
|
let description = 'Only people with access can open this item';
|
|
37
37
|
if (isPublic && publicRole === PUBLIC_ROLE.ONLY_VIEWER) {
|
|
38
|
-
description = 'Anyone on the portal can view this item
|
|
38
|
+
description = 'Anyone on the portal can view this item';
|
|
39
39
|
}
|
|
40
40
|
if (isPublic && publicRole === PUBLIC_ROLE.ONLY_EDITOR) {
|
|
41
|
-
description = 'Anyone on the portal can edit this item
|
|
41
|
+
description = 'Anyone on the portal can edit this item';
|
|
42
42
|
}
|
|
43
43
|
return description;
|
|
44
44
|
};
|
|
@@ -25,7 +25,7 @@ export const TemplateSaveAs = props => {
|
|
|
25
25
|
const { className, shareAccess, saveOptions, imageReview, isLoadingCategories, categories, omitCategories, templateNames: templateNameList, templateNamesOptions, descriptionOptions, form, value, onChange, onEvent, } = props;
|
|
26
26
|
const { show: isShowShareAccess } = shareAccess, shareAccessProps = __rest(shareAccess, ["show"]);
|
|
27
27
|
const { label: imageReviewLabel } = imageReview, restImageReviewProps = __rest(imageReview, ["label"]);
|
|
28
|
-
const { isLoading, label: templateLabel, defaultNewTemplateName = `Untitled Media Template#${dayjs().format('YYYY-MM-DD HH:mm:ss')}`, selectPlaceholder, placeholder = 'Enter your media template name', onSearch, onNamePopupScroll, onScrollToBottom, } = templateNamesOptions || {};
|
|
28
|
+
const { isLoading, label: templateLabel, defaultNewTemplateName = `Untitled Media Template#${dayjs().format('YYYY-MM-DD HH:mm:ss')}`, selectPlaceholder = 'Please select an item', placeholder = 'Enter your media template name', onSearch, onNamePopupScroll, onScrollToBottom, } = templateNamesOptions || {};
|
|
29
29
|
const { label: descriptionLabel, placeholder: descriptionPlaceholder } = descriptionOptions || {};
|
|
30
30
|
const { saveNewText = 'Save as a new media Template', saveExistText = 'Save as an existing media Template', saveNewValue = 'save-new', saveExistValue = 'save-exist', } = saveOptions || {};
|
|
31
31
|
const { saveOption = saveNewValue, templateName = saveOption === saveNewValue || !saveOption
|
|
@@ -37,9 +37,9 @@ export const ThumbnailCard = memo(props => {
|
|
|
37
37
|
// Handlers
|
|
38
38
|
const handleRemoveThumbnail = e => {
|
|
39
39
|
e.stopPropagation();
|
|
40
|
-
modal.confirm(Object.assign(Object.assign({ title: 'Remove
|
|
40
|
+
modal.confirm(Object.assign(Object.assign({ title: 'Remove template', centered: true, icon: React.createElement(Icon, { type: "icon-ants-info", style: { fontSize: 16, lineHeight: '25px' } }), content: (React.createElement("div", null,
|
|
41
41
|
React.createElement("p", null, "Are you sure you want to remove the template?"),
|
|
42
|
-
React.createElement("p", null, "This action
|
|
42
|
+
React.createElement("p", null, "This action can not be undone."))), okText: 'Remove', cancelText: 'Cancel', closable: true }, restOfRemoveTemplateModalProps), { onOk: () => __awaiter(void 0, void 0, void 0, function* () {
|
|
43
43
|
if (onOk)
|
|
44
44
|
onOk(id);
|
|
45
45
|
}) }));
|
|
@@ -7,17 +7,22 @@ import { InformationWrapper } from './styled';
|
|
|
7
7
|
import { Button, Radio, Typography, Flex } from '../../../../atoms';
|
|
8
8
|
// Constants
|
|
9
9
|
import { DEVICE_TYPE } from '../../constants';
|
|
10
|
+
import { THEME } from '@antscorp/antsomi-ui/es/constants';
|
|
10
11
|
export const Information = memo(props => {
|
|
12
|
+
var _a;
|
|
11
13
|
const { deviceType, itemName = 'Template name', buttonText = 'Use template', description, categoryListing, showDeviceRadios = true, onButtonClick, onDeviceTypeChange, } = props;
|
|
12
14
|
return (React.createElement(InformationWrapper, { gap: 20, vertical: true },
|
|
13
15
|
React.createElement("div", { style: { flexShrink: 0 }, className: "title" }, itemName),
|
|
14
16
|
React.createElement(Flex, { gap: 20, vertical: true, className: "content-information" },
|
|
15
|
-
description && React.createElement("div", null, description), categoryListing === null || categoryListing === void 0 ? void 0 :
|
|
16
|
-
categoryListing.map(({ key, label, children }) =>
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
":
|
|
20
|
-
|
|
17
|
+
description && React.createElement("div", { style: { color: (_a = THEME.token) === null || _a === void 0 ? void 0 : _a.bw8 } }, description), categoryListing === null || categoryListing === void 0 ? void 0 :
|
|
18
|
+
categoryListing.map(({ key, label, children }) => {
|
|
19
|
+
var _a;
|
|
20
|
+
return (React.createElement("div", { key: key },
|
|
21
|
+
React.createElement("div", { style: { color: (_a = THEME.token) === null || _a === void 0 ? void 0 : _a.bw8 } },
|
|
22
|
+
label,
|
|
23
|
+
":"),
|
|
24
|
+
React.createElement("div", { style: { fontWeight: 'bold' } }, children === null || children === void 0 ? void 0 : children.map(({ label }) => label).join(', '))));
|
|
25
|
+
})),
|
|
21
26
|
React.createElement(Flex, { gap: 20, style: { flexShrink: 0 }, vertical: true },
|
|
22
27
|
showDeviceRadios && (React.createElement(Radio.Group, { options: Object.values(DEVICE_TYPE).map(({ value, label, icon }) => ({
|
|
23
28
|
label: (React.createElement(Flex, { gap: 5, align: "center" },
|
package/es/constants/theme.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u;
|
|
1
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
|
|
2
2
|
// Types
|
|
3
3
|
import { theme } from 'antd';
|
|
4
4
|
// Variables
|
|
@@ -148,7 +148,7 @@ THEME.components = {
|
|
|
148
148
|
paddingMD: 0,
|
|
149
149
|
},
|
|
150
150
|
Tabs: {
|
|
151
|
-
|
|
151
|
+
itemColor: (_s = THEME.token) === null || _s === void 0 ? void 0 : _s.bw8,
|
|
152
152
|
horizontalItemPadding: '17px 30px',
|
|
153
153
|
horizontalItemGutter: 0,
|
|
154
154
|
lineWidthBold: 3,
|
|
@@ -163,11 +163,11 @@ THEME.components = {
|
|
|
163
163
|
headerPadding: '15px 10px',
|
|
164
164
|
},
|
|
165
165
|
Switch: {
|
|
166
|
-
colorTextQuaternary: (
|
|
167
|
-
colorTextTertiary: (
|
|
166
|
+
colorTextQuaternary: (_t = THEME.token) === null || _t === void 0 ? void 0 : _t.bw0,
|
|
167
|
+
colorTextTertiary: (_u = THEME.token) === null || _u === void 0 ? void 0 : _u.bw0,
|
|
168
168
|
handleSize: 12,
|
|
169
169
|
handleSizeSM: 7,
|
|
170
170
|
trackMinWidth: 30,
|
|
171
|
-
handleBg: (
|
|
171
|
+
handleBg: (_v = THEME.token) === null || _v === void 0 ? void 0 : _v.colorPrimary,
|
|
172
172
|
},
|
|
173
173
|
};
|