pds-dev-kit-web-test 0.1.8 → 0.1.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/README.md +12 -1
- package/dist/index.d.ts +3 -2
- package/dist/index.js +8 -1
- package/dist/src/common/assets/icons/line/SectionIframe32.d.ts +4 -0
- package/dist/src/common/assets/icons/line/SectionIframe32.js +30 -0
- package/dist/src/common/assets/icons/line/SectionIframe40.d.ts +4 -0
- package/dist/src/common/assets/icons/line/SectionIframe40.js +30 -0
- package/dist/src/common/assets/icons/line/SectionMembership32.d.ts +4 -0
- package/dist/src/common/assets/icons/line/SectionMembership32.js +30 -0
- package/dist/src/common/assets/icons/line/SectionMembership40.d.ts +4 -0
- package/dist/src/common/assets/icons/line/SectionMembership40.js +30 -0
- package/dist/src/common/assets/icons/line/index.d.ts +4 -0
- package/dist/src/common/assets/icons/line/index.js +8 -0
- package/dist/src/common/styles/colorSet/PaletteColor_Dark.json +15 -1
- package/dist/src/common/styles/colorSet/PaletteColor_light.json +15 -1
- package/dist/src/common/styles/colorSet/SemanticColor.json +4 -1
- package/dist/src/common/styles/colorSet/UIColor.json +17 -1
- package/dist/src/common/styles/colorSet/index.d.ts +49 -2
- package/dist/src/common/styles/colorSet/index.js +2 -2
- package/dist/src/common/styles/colorSet/ui-type.d.ts +16 -0
- package/dist/src/desktop/common/components/TextFieldBase/TextFieldBase.js +1 -1
- package/dist/src/desktop/components/AdminList/AdminList.js +13 -5
- package/dist/src/desktop/components/BasicListItem/BasicListItem.d.ts +1 -0
- package/dist/src/desktop/components/BasicListItem/BasicListItem.js +10 -99
- package/dist/src/desktop/components/BasicListItem/Contents.d.ts +16 -0
- package/dist/src/desktop/components/BasicListItem/Contents.js +31 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Badge.d.ts +7 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Badge.js +27 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Checkbox.d.ts +6 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Checkbox.js +19 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Icon.d.ts +8 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Icon.js +19 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Image.d.ts +8 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Image.js +9 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/LeftBox.d.ts +17 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/LeftBox.js +42 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Radio.d.ts +9 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/Radio.js +13 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/index.d.ts +2 -0
- package/dist/src/desktop/components/BasicListItem/LeftBox/index.js +8 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/Description.d.ts +8 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/Description.js +10 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/IconButton.d.ts +9 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/IconButton.js +19 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/MainButton.d.ts +9 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/MainButton.js +10 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/RightBox.d.ts +15 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/RightBox.js +40 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/Switch.d.ts +10 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/Switch.js +19 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/index.d.ts +2 -0
- package/dist/src/desktop/components/BasicListItem/RightBox/index.js +8 -0
- package/dist/src/desktop/components/Dropdown/Dropdown.d.ts +2 -3
- package/dist/src/desktop/components/Radio/Radio.js +2 -2
- package/dist/src/desktop/layout/LayoutWT/Containers/ContentsContainer/ContentsContainer.d.ts +1 -1
- package/dist/src/desktop/layout/LayoutWT/Containers/ContentsContainer/ContentsContainer.js +2 -1
- package/dist/src/desktop/layout/LayoutWT/Containers/ContentsContainer/variation/WTV.d.ts +15 -0
- package/dist/src/desktop/layout/LayoutWT/Containers/ContentsContainer/variation/WTV.js +81 -0
- package/dist/src/desktop/layout/LayoutWT/Containers/ContentsContainer/variation/index.d.ts +1 -0
- package/dist/src/desktop/layout/LayoutWT/Containers/ContentsContainer/variation/index.js +3 -1
- package/dist/src/desktop/layout/LayoutWT/ContainersBox/ContainersBox.d.ts +1 -1
- package/dist/src/desktop/layout/LayoutWT/ContainersBox/ContainersBox.js +8 -4
- package/dist/src/mobile/components/BasicListItem/BasicListItem.d.ts +1 -0
- package/dist/src/mobile/components/BasicListItem/BasicListItem.js +10 -99
- package/dist/src/mobile/components/BasicListItem/Contents.d.ts +16 -0
- package/dist/src/mobile/components/BasicListItem/Contents.js +31 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Badge.d.ts +7 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Badge.js +27 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Checkbox.d.ts +6 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Checkbox.js +19 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Icon.d.ts +8 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Icon.js +19 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Image.d.ts +8 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Image.js +9 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/LeftBox.d.ts +17 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/LeftBox.js +42 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Radio.d.ts +9 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/Radio.js +13 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/index.d.ts +2 -0
- package/dist/src/mobile/components/BasicListItem/LeftBox/index.js +8 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/Description.d.ts +8 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/Description.js +10 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/IconButton.d.ts +9 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/IconButton.js +19 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/MainButton.d.ts +9 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/MainButton.js +10 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/RightBox.d.ts +15 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/RightBox.js +40 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/Switch.d.ts +10 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/Switch.js +19 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/index.d.ts +2 -0
- package/dist/src/mobile/components/BasicListItem/RightBox/index.js +8 -0
- package/dist/src/mobile/components/Dropdown/Dropdown.d.ts +2 -3
- package/dist/src/mobile/layout/LayoutMF/Containers/ContentsContainer/variation/MFA.js +2 -2
- package/dist/src/mobile/layout/LayoutMF/Containers/ContentsContainer/variation/MFB.js +4 -4
- package/dist/src/mobile/layout/LayoutMF/Containers/ContentsContainer/variation/MFC.js +2 -2
- package/dist/src/mobile/layout/LayoutMF/Containers/ContentsContainer/variation/MFD.js +2 -2
- package/dist/src/mobile/layout/LayoutMF/Containers/ContentsContainer/variation/MFE.js +4 -4
- package/dist/src/mobile/layout/LayoutMM/Containers/ContentsContainer/variation/MMA.js +2 -2
- package/dist/src/mobile/layout/LayoutMM/Containers/ContentsContainer/variation/MMB.js +2 -2
- package/dist/src/mobile/layout/LayoutMP/Containers/ContentsContainer/variation/MPA.js +2 -2
- package/dist/src/mobile/layout/LayoutMP/Containers/ContentsContainer/variation/MPB.js +2 -2
- package/dist/src/mobile/layout/LayoutMP/Containers/ContentsContainer/variation/MPC.js +4 -4
- package/dist/src/mobile/layout/LayoutMP/Containers/ContentsContainer/variation/MPD.js +2 -2
- package/dist/src/mobile/layout/LayoutMP/Containers/ContentsContainer/variation/MPE.js +2 -2
- package/dist/src/mobile/layout/LayoutMP/Containers/ContentsContainer/variation/MPF.js +4 -4
- package/dist/src/mobile/layout/LayoutMS/Containers/ContentsContainer/variation/MSA.js +2 -2
- package/dist/src/mobile/layout/LayoutMS/Containers/ContentsContainer/variation/MSB.js +2 -2
- package/dist/src/mobile/layout/LayoutMS/Containers/ContentsContainer/variation/MSC.js +4 -4
- package/dist/src/mobile/layout/LayoutMS/Containers/ContentsContainer/variation/MSD.js +2 -2
- package/dist/src/mobile/layout/LayoutMS/Containers/ContentsContainer/variation/MSE.js +2 -2
- package/dist/src/mobile/layout/LayoutMS/Containers/ContentsContainer/variation/MSF.js +4 -4
- package/dist/src/mobile/layout/LayoutMS/Containers/ContentsContainer/variation/MSG.js +2 -2
- package/dist/src/mobile/layout/LayoutMS/Containers/ContentsContainer/variation/MSH.js +2 -2
- package/dist/src/sub/AdminList/AdminList/AdminList.d.ts +47 -0
- package/dist/src/sub/AdminList/AdminList/AdminList.js +229 -0
- package/dist/src/sub/AdminList/AdminList/HeaderRow.d.ts +30 -0
- package/dist/src/sub/AdminList/AdminList/HeaderRow.js +83 -0
- package/dist/src/sub/AdminList/AdminList/index.d.ts +1 -0
- package/dist/src/sub/AdminList/AdminList/index.js +8 -0
- package/dist/src/sub/AdminList/AdminListHeader/AdminListHeader.d.ts +17 -0
- package/dist/src/sub/AdminList/AdminListHeader/AdminListHeader.js +57 -0
- package/dist/src/sub/AdminList/AdminListHeader/HeaderBar.d.ts +16 -0
- package/dist/src/sub/AdminList/AdminListHeader/HeaderBar.js +82 -0
- package/dist/src/sub/AdminList/AdminListHeader/index.d.ts +1 -0
- package/dist/src/sub/AdminList/AdminListHeader/index.js +8 -0
- package/dist/src/sub/AdminList/AdminListItem/AdminListItem.d.ts +56 -0
- package/dist/src/sub/AdminList/AdminListItem/AdminListItem.js +275 -0
- package/dist/src/sub/AdminList/AdminListItem/index.d.ts +1 -0
- package/dist/src/sub/AdminList/AdminListItem/index.js +8 -0
- package/dist/src/sub/AdminList/BulkActionBar/BulkActionBar.d.ts +30 -0
- package/dist/src/sub/AdminList/BulkActionBar/BulkActionBar.js +28 -0
- package/dist/src/sub/AdminList/BulkActionBar/index.d.ts +1 -0
- package/dist/src/sub/AdminList/BulkActionBar/index.js +8 -0
- package/dist/src/sub/AdminList/ToolBar/ChipList.d.ts +9 -0
- package/dist/src/sub/AdminList/ToolBar/ChipList.js +32 -0
- package/dist/src/sub/AdminList/ToolBar/SearchField.d.ts +15 -0
- package/dist/src/sub/AdminList/ToolBar/SearchField.js +265 -0
- package/dist/src/sub/AdminList/ToolBar/ToolBar.d.ts +26 -0
- package/dist/src/sub/AdminList/ToolBar/ToolBar.js +86 -0
- package/dist/src/sub/AdminList/ToolBar/index.d.ts +1 -0
- package/dist/src/sub/AdminList/ToolBar/index.js +8 -0
- package/dist/src/sub/AdminList/index.d.ts +5 -0
- package/dist/src/sub/AdminList/index.js +13 -0
- package/dist/src/sub/DynamicLayout/DynamicLayout.d.ts +1 -1
- package/dist/src/sub/DynamicLayout/DynamicLayout.js +4 -3
- package/dist/src/sub/DynamicLayout/components/EditModeSectionMatcher/EditModeSectionMatcher.js +2 -1
- package/dist/src/sub/DynamicLayout/components/EditModeSectionMatcher/SectionBox.d.ts +2 -1
- package/dist/src/sub/DynamicLayout/components/EditModeSectionMatcher/SectionBox.js +6 -3
- package/dist/src/sub/DynamicLayout/components/Section/Section.js +5 -2
- package/dist/src/sub/DynamicLayout/components/SectionMatcher/SectionMatcher.js +2 -0
- package/dist/src/sub/DynamicLayout/components/desktop/Item/Item.js +1 -1
- package/dist/src/sub/DynamicLayout/components/mobile/Item/Item.js +1 -1
- package/dist/src/sub/DynamicLayout/mock_samplePage.d.ts +1 -0
- package/dist/src/sub/DynamicLayout/mock_samplePage.js +84 -8
- package/dist/src/sub/DynamicLayout/sectionActionTypes.d.ts +19 -0
- package/dist/src/sub/DynamicLayout/sectionActionTypes.js +2 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/FullscreenIframeSection.d.ts +4 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/FullscreenIframeSection.js +51 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/index.d.ts +1 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/index.js +8 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/TemplateA.d.ts +3 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/TemplateA.js +15 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/desktop/D_TemplateA.d.ts +3 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/desktop/D_TemplateA.js +20 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/desktop/index.d.ts +1 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/desktop/index.js +8 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/index.d.ts +1 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/index.js +8 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/mobile/M_TemplateA.d.ts +3 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/mobile/M_TemplateA.js +20 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/mobile/index.d.ts +1 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/TemplateA/mobile/index.js +8 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/index.d.ts +1 -0
- package/dist/src/sub/DynamicLayout/sections/FullscreenIframeSection/templates/index.js +5 -0
- package/dist/src/sub/DynamicLayout/sections/index.d.ts +1 -0
- package/dist/src/sub/DynamicLayout/sections/index.js +3 -1
- package/dist/src/sub/DynamicLayout/types.d.ts +7 -4
- package/dist/src/sub/index.d.ts +1 -0
- package/dist/src/sub/index.js +11 -1
- package/package.json +4 -2
- package/release-note.md +6 -7
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
|
|
3
|
+
if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
|
|
4
|
+
return cooked;
|
|
5
|
+
};
|
|
6
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
7
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
8
|
+
};
|
|
9
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
+
var jsx_runtime_1 = require("react/jsx-runtime");
|
|
11
|
+
var components_1 = require("../../../desktop/components");
|
|
12
|
+
var styled_components_1 = __importDefault(require("styled-components"));
|
|
13
|
+
function ChipList(_a) {
|
|
14
|
+
var textArray = _a.textArray, value = _a.value, onClickChip = _a.onClickChip;
|
|
15
|
+
return ((0, jsx_runtime_1.jsx)(S_ChipBox, { children: textArray.map(function (option) { return ((0, jsx_runtime_1.jsx)(S_ChipWrapper, { children: (0, jsx_runtime_1.jsx)(components_1.Chip, { displayType: "filter_single", text: option.text, value: value === null || value === void 0 ? void 0 : value.value, id: option.value, onClickChip: function () { return onClickChip && onClickChip(option); } }, void 0) }, option.value)); }) }, void 0));
|
|
16
|
+
}
|
|
17
|
+
var S_ChipBox = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n display: flex;\n flex-wrap: wrap;\n margin-right: ", ";\n\n & > div {\n margin-bottom: ", ";\n margin-top: ", ";\n }\n"], ["\n display: flex;\n flex-wrap: wrap;\n margin-right: ", ";\n\n & > div {\n margin-bottom: ", ";\n margin-top: ", ";\n }\n"])), function (_a) {
|
|
18
|
+
var theme = _a.theme;
|
|
19
|
+
return theme.spacing.spacingE;
|
|
20
|
+
}, function (_a) {
|
|
21
|
+
var theme = _a.theme;
|
|
22
|
+
return theme.spacing.spacingA;
|
|
23
|
+
}, function (_a) {
|
|
24
|
+
var theme = _a.theme;
|
|
25
|
+
return theme.spacing.spacingA;
|
|
26
|
+
});
|
|
27
|
+
var S_ChipWrapper = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n padding-right: ", ";\n\n &:last-child {\n padding-right: 0;\n }\n"], ["\n padding-right: ", ";\n\n &:last-child {\n padding-right: 0;\n }\n"])), function (_a) {
|
|
28
|
+
var theme = _a.theme;
|
|
29
|
+
return theme.spacing.spacingB;
|
|
30
|
+
});
|
|
31
|
+
exports.default = ChipList;
|
|
32
|
+
var templateObject_1, templateObject_2;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { PDSTextType } from '../../../common';
|
|
3
|
+
declare type Props = {
|
|
4
|
+
name: string;
|
|
5
|
+
hintText?: PDSTextType;
|
|
6
|
+
defaultText?: PDSTextType;
|
|
7
|
+
responsiveMode?: 'none' | 'use';
|
|
8
|
+
size?: 'small' | 'medium' | 'large';
|
|
9
|
+
customWidth?: string;
|
|
10
|
+
onTarget?: () => void;
|
|
11
|
+
onClickArrowIBtn?: () => void;
|
|
12
|
+
onClickSearchIBtn?: (value: string) => void;
|
|
13
|
+
};
|
|
14
|
+
declare function SearchField({ name, hintText, defaultText, responsiveMode, size, customWidth, onTarget, onClickArrowIBtn, onClickSearchIBtn }: Props): JSX.Element;
|
|
15
|
+
export default SearchField;
|
|
@@ -0,0 +1,265 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
|
|
3
|
+
if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
|
|
4
|
+
return cooked;
|
|
5
|
+
};
|
|
6
|
+
var __assign = (this && this.__assign) || function () {
|
|
7
|
+
__assign = Object.assign || function(t) {
|
|
8
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
9
|
+
s = arguments[i];
|
|
10
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
11
|
+
t[p] = s[p];
|
|
12
|
+
}
|
|
13
|
+
return t;
|
|
14
|
+
};
|
|
15
|
+
return __assign.apply(this, arguments);
|
|
16
|
+
};
|
|
17
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
18
|
+
if (k2 === undefined) k2 = k;
|
|
19
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
20
|
+
}) : (function(o, m, k, k2) {
|
|
21
|
+
if (k2 === undefined) k2 = k;
|
|
22
|
+
o[k2] = m[k];
|
|
23
|
+
}));
|
|
24
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
25
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
26
|
+
}) : function(o, v) {
|
|
27
|
+
o["default"] = v;
|
|
28
|
+
});
|
|
29
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
30
|
+
if (mod && mod.__esModule) return mod;
|
|
31
|
+
var result = {};
|
|
32
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
33
|
+
__setModuleDefault(result, mod);
|
|
34
|
+
return result;
|
|
35
|
+
};
|
|
36
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
|
+
var jsx_runtime_1 = require("react/jsx-runtime");
|
|
38
|
+
var react_1 = require("react");
|
|
39
|
+
var react_hook_form_1 = require("react-hook-form");
|
|
40
|
+
var styles_1 = require("../../../common/styles");
|
|
41
|
+
var components_1 = require("../../../desktop/common/components");
|
|
42
|
+
var components_2 = require("../../../desktop/components");
|
|
43
|
+
var components_3 = require("../../../hybrid/components");
|
|
44
|
+
var styled_components_1 = __importStar(require("styled-components"));
|
|
45
|
+
function SearchField(_a) {
|
|
46
|
+
var name = _a.name, hintText = _a.hintText, defaultText = _a.defaultText, _b = _a.responsiveMode, responsiveMode = _b === void 0 ? 'none' : _b, _c = _a.size, size = _c === void 0 ? 'medium' : _c, customWidth = _a.customWidth, onTarget = _a.onTarget, onClickArrowIBtn = _a.onClickArrowIBtn, onClickSearchIBtn = _a.onClickSearchIBtn;
|
|
47
|
+
var _d = (0, react_1.useState)(false), isFocused = _d[0], setIsFocused = _d[1];
|
|
48
|
+
var textFieldBaseRef = (0, react_1.useRef)(null);
|
|
49
|
+
var _e = (0, react_hook_form_1.useFormContext)(), register = _e.register, getValues = _e.getValues, trigger = _e.trigger;
|
|
50
|
+
var validateOnBlur = register(name).onBlur;
|
|
51
|
+
var handleFocus = function () {
|
|
52
|
+
setIsFocused(true);
|
|
53
|
+
};
|
|
54
|
+
var handleArrowIBtnClick = function () {
|
|
55
|
+
if (onClickArrowIBtn) {
|
|
56
|
+
onClickArrowIBtn();
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
var handleSearchIBtnClick = function () {
|
|
60
|
+
var searchValue = getValues(name);
|
|
61
|
+
if (onClickSearchIBtn) {
|
|
62
|
+
onClickSearchIBtn(searchValue);
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
var handleBlur = function (e) {
|
|
66
|
+
validateOnBlur(e);
|
|
67
|
+
setIsFocused(false);
|
|
68
|
+
trigger(name);
|
|
69
|
+
};
|
|
70
|
+
var handleTarget = function () {
|
|
71
|
+
if (onTarget) {
|
|
72
|
+
onTarget();
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
return ((0, jsx_runtime_1.jsx)(S_SearchFieldBox, __assign({ "x-pds-name": "SearchField", "x-pds-element-type": "component", "x-pds-device-type": "desktop", size: size, responsiveMode: responsiveMode, customWidth: customWidth }, { children: (0, jsx_runtime_1.jsxs)(S_SearchFieldWrapper, __assign({ size: size, textLineType: "single", isFocused: isFocused, state: "normal", colorTheme: "none", responsiveMode: responsiveMode, customWidth: customWidth }, { children: [(0, jsx_runtime_1.jsx)(components_2.IconButton, { baseSize: "medium", iconSize: 20, iconName: "ic_arrow_left", baseColorKey: "ui_cpnt_button_fill_base_transparent", onClick: handleArrowIBtnClick }, void 0), (0, jsx_runtime_1.jsx)(components_1.TextFieldBase, { inputRef: textFieldBaseRef, name: name, size: size, hintText: hintText, defaultText: defaultText, enterSubmitMode: "use", textLineType: "single", textSize: "form2", textWeight: "normal", textPadding: "0 0 0 8px", deleteIconMode: "use", deleteIconSize: size === 'large' ? 20 : 16, deleteIconColor: "ui_cpnt_button_icon_disabled", isFocused: isFocused, onFocus: handleFocus, onBlur: handleBlur, onTarget: handleTarget, onChange: register('searchField').onChange }, void 0), (0, jsx_runtime_1.jsx)(components_3.Spacing, { size: "spacing_a", spacingType: "width" }, void 0), (0, jsx_runtime_1.jsx)(components_2.IconButton, { baseSize: "medium", iconSize: 20, iconName: "ic_search", baseColorKey: "ui_cpnt_button_fill_base_transparent", onClick: handleSearchIBtnClick }, void 0)] }), void 0) }), void 0));
|
|
76
|
+
}
|
|
77
|
+
var S_SearchFieldBox = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n ", ";\n ", ";\n ", "\n"], ["\n ", ";\n ", ";\n ", "\n"])), function (_a) {
|
|
78
|
+
var size = _a.size;
|
|
79
|
+
return size &&
|
|
80
|
+
{
|
|
81
|
+
small: 'width: 188px;',
|
|
82
|
+
medium: 'width: 188px;',
|
|
83
|
+
large: 'width: 432px;'
|
|
84
|
+
}[size];
|
|
85
|
+
}, function (_a) {
|
|
86
|
+
var responsiveMode = _a.responsiveMode;
|
|
87
|
+
return responsiveMode === 'use' && 'width: 100%';
|
|
88
|
+
}, function (_a) {
|
|
89
|
+
var customWidth = _a.customWidth;
|
|
90
|
+
return customWidth && "width: " + customWidth + ";";
|
|
91
|
+
});
|
|
92
|
+
var multi = (0, styled_components_1.css)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n height: auto;\n padding: 14px;\n"], ["\n height: auto;\n padding: 14px;\n"])));
|
|
93
|
+
var auto = (0, styled_components_1.css)(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n height: auto;\n padding-bottom: ", "px;\n padding-top: ", "px;\n"], ["\n height: auto;\n padding-bottom: ", "px;\n padding-top: ", "px;\n"])), function (_a) {
|
|
94
|
+
var theme = _a.theme;
|
|
95
|
+
return (46 -
|
|
96
|
+
Number(theme.desktopFontSize.form2.substring(0, 2)) * Number(theme.desktopLineHeight.form2)) /
|
|
97
|
+
2;
|
|
98
|
+
}, function (_a) {
|
|
99
|
+
var theme = _a.theme;
|
|
100
|
+
return (46 -
|
|
101
|
+
Number(theme.desktopFontSize.form2.substring(0, 2)) * Number(theme.desktopLineHeight.form2)) /
|
|
102
|
+
2;
|
|
103
|
+
});
|
|
104
|
+
var small = (0, styled_components_1.css)(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n border-radius: 10px;\n height: 32px;\n padding-right: ", ";\n width: 188px;\n"], ["\n border-radius: 10px;\n height: 32px;\n padding-right: ", ";\n width: 188px;\n"])), function (_a) {
|
|
105
|
+
var theme = _a.theme;
|
|
106
|
+
return theme.spacing.spacingB;
|
|
107
|
+
});
|
|
108
|
+
var medium = (0, styled_components_1.css)(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n height: 40px;\n padding-right: ", ";\n width: 188px;\n"], ["\n height: 40px;\n padding-right: ", ";\n width: 188px;\n"])), function (_a) {
|
|
109
|
+
var theme = _a.theme;
|
|
110
|
+
return theme.spacing.spacingB;
|
|
111
|
+
});
|
|
112
|
+
var large = (0, styled_components_1.css)(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n height: 48px;\n padding-right: ", ";\n width: 432px;\n ", "\n ", "\n"], ["\n height: 48px;\n padding-right: ", ";\n width: 432px;\n ", "\n ", "\n"])), function (_a) {
|
|
113
|
+
var theme = _a.theme;
|
|
114
|
+
return theme.spacing.spacingB;
|
|
115
|
+
}, function (_a) {
|
|
116
|
+
var textLineType = _a.textLineType;
|
|
117
|
+
return textLineType === 'multi' && multi;
|
|
118
|
+
}, function (_a) {
|
|
119
|
+
var textLineType = _a.textLineType;
|
|
120
|
+
return textLineType === 'auto' && auto;
|
|
121
|
+
});
|
|
122
|
+
var normal = (0, styled_components_1.css)(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n background-color: ", ";\n border: solid 2px\n ", ";\n"], ["\n background-color: ", ";\n border: solid 2px\n ", ";\n"])), function (_a) {
|
|
123
|
+
var theme = _a.theme;
|
|
124
|
+
return theme.ui_cpnt_textfield_base_normal;
|
|
125
|
+
}, function (_a) {
|
|
126
|
+
var theme = _a.theme, isError = _a.isError, isFocused = _a.isFocused;
|
|
127
|
+
if (isError)
|
|
128
|
+
return theme.ui_cpnt_textfield_border_error;
|
|
129
|
+
if (isFocused)
|
|
130
|
+
return theme.ui_cpnt_textfield_border_focus;
|
|
131
|
+
return theme.ui_cpnt_textfield_border_normal;
|
|
132
|
+
});
|
|
133
|
+
var read_only = (0, styled_components_1.css)(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n background-color: ", ";\n border: solid 2px ", ";\n"], ["\n background-color: ", ";\n border: solid 2px ", ";\n"])), function (_a) {
|
|
134
|
+
var theme = _a.theme;
|
|
135
|
+
return theme.ui_cpnt_textfield_base_disabled;
|
|
136
|
+
}, function (_a) {
|
|
137
|
+
var theme = _a.theme;
|
|
138
|
+
return theme.ui_cpnt_textfield_border_disabled;
|
|
139
|
+
});
|
|
140
|
+
var disabled = (0, styled_components_1.css)(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n background-color: ", ";\n border: solid 2px ", ";\n"], ["\n background-color: ", ";\n border: solid 2px ", ";\n"])), function (_a) {
|
|
141
|
+
var theme = _a.theme;
|
|
142
|
+
return theme.ui_cpnt_textfield_base_disabled;
|
|
143
|
+
}, function (_a) {
|
|
144
|
+
var theme = _a.theme;
|
|
145
|
+
return theme.ui_cpnt_textfield_border_disabled;
|
|
146
|
+
});
|
|
147
|
+
var dark_normal = (0, styled_components_1.css)(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n background-color: ", ";\n border: solid 2px\n ", ";\n"], ["\n background-color: ", ";\n border: solid 2px\n ", ";\n"])), function (_a) {
|
|
148
|
+
var theme = _a.theme;
|
|
149
|
+
return theme.ui_cpnt_textfield_base_darktheme_normal;
|
|
150
|
+
}, function (_a) {
|
|
151
|
+
var theme = _a.theme, isError = _a.isError, isFocused = _a.isFocused;
|
|
152
|
+
if (isError)
|
|
153
|
+
return theme.ui_cpnt_textfield_border_darktheme_error;
|
|
154
|
+
if (isFocused)
|
|
155
|
+
return theme.ui_cpnt_textfield_border_darktheme_focus;
|
|
156
|
+
return theme.ui_cpnt_textfield_border_darktheme_normal;
|
|
157
|
+
});
|
|
158
|
+
var dark_read_only = (0, styled_components_1.css)(templateObject_11 || (templateObject_11 = __makeTemplateObject(["\n background-color: ", ";\n border: solid 2px ", ";\n"], ["\n background-color: ", ";\n border: solid 2px ", ";\n"])), function (_a) {
|
|
159
|
+
var theme = _a.theme;
|
|
160
|
+
return theme.ui_cpnt_textfield_base_darktheme_disabled;
|
|
161
|
+
}, function (_a) {
|
|
162
|
+
var theme = _a.theme;
|
|
163
|
+
return theme.ui_cpnt_textfield_border_darktheme_normal;
|
|
164
|
+
});
|
|
165
|
+
var dark_disabled = (0, styled_components_1.css)(templateObject_12 || (templateObject_12 = __makeTemplateObject(["\n background-color: ", ";\n border: solid 2px ", ";\n"], ["\n background-color: ", ";\n border: solid 2px ", ";\n"])), function (_a) {
|
|
166
|
+
var theme = _a.theme;
|
|
167
|
+
return theme.ui_cpnt_textfield_base_darktheme_disabled;
|
|
168
|
+
}, function (_a) {
|
|
169
|
+
var theme = _a.theme;
|
|
170
|
+
return theme.ui_cpnt_textfield_border_darktheme_normal;
|
|
171
|
+
});
|
|
172
|
+
var transparent_normal = (0, styled_components_1.css)(templateObject_13 || (templateObject_13 = __makeTemplateObject(["\n background-color: ", ";\n border: solid 2px\n ", ";\n"], ["\n background-color: ", ";\n border: solid 2px\n ", ";\n"])), function (_a) {
|
|
173
|
+
var theme = _a.theme;
|
|
174
|
+
return theme.ui_cpnt_textfield_base_colortheme_transparent_normal;
|
|
175
|
+
}, function (_a) {
|
|
176
|
+
var theme = _a.theme, isError = _a.isError, isFocused = _a.isFocused;
|
|
177
|
+
if (isError)
|
|
178
|
+
return theme.ui_cpnt_textfield_border_colortheme_transparent_error;
|
|
179
|
+
if (isFocused)
|
|
180
|
+
return theme.ui_cpnt_textfield_border_colortheme_transparent_focus;
|
|
181
|
+
return theme.ui_cpnt_textfield_border_colortheme_transparent_normal;
|
|
182
|
+
});
|
|
183
|
+
var transparent_read_only = (0, styled_components_1.css)(templateObject_14 || (templateObject_14 = __makeTemplateObject(["\n background-color: ", ";\n border: solid 2px ", ";\n"], ["\n background-color: ", ";\n border: solid 2px ", ";\n"])), function (_a) {
|
|
184
|
+
var theme = _a.theme;
|
|
185
|
+
return theme.ui_cpnt_textfield_base_colortheme_transparent_readonly;
|
|
186
|
+
}, function (_a) {
|
|
187
|
+
var theme = _a.theme;
|
|
188
|
+
return theme.ui_cpnt_textfield_border_colortheme_transparent_readonly;
|
|
189
|
+
});
|
|
190
|
+
var transparent_disabled = (0, styled_components_1.css)(templateObject_15 || (templateObject_15 = __makeTemplateObject(["\n background-color: ", ";\n border: solid 2px ", ";\n"], ["\n background-color: ", ";\n border: solid 2px ", ";\n"])), function (_a) {
|
|
191
|
+
var theme = _a.theme;
|
|
192
|
+
return theme.ui_cpnt_textfield_base_colortheme_transparent_disabled;
|
|
193
|
+
}, function (_a) {
|
|
194
|
+
var theme = _a.theme;
|
|
195
|
+
return theme.ui_cpnt_textfield_border_colortheme_transparent_disabled;
|
|
196
|
+
});
|
|
197
|
+
var backgroundHoverColor = (0, styled_components_1.css)(templateObject_16 || (templateObject_16 = __makeTemplateObject(["\n ", ";\n"], ["\n ", ";\n"])), function (_a) {
|
|
198
|
+
var colorTheme = _a.colorTheme, theme = _a.theme;
|
|
199
|
+
switch (colorTheme) {
|
|
200
|
+
case 'none':
|
|
201
|
+
return theme.ui_cpnt_textfield_base_hover;
|
|
202
|
+
case 'dark':
|
|
203
|
+
return theme.ui_cpnt_textfield_base_hover_darktheme;
|
|
204
|
+
case 'transparent':
|
|
205
|
+
return theme.ui_cpnt_textfield_base_hover_transparent;
|
|
206
|
+
default:
|
|
207
|
+
return theme.ui_cpnt_textfield_base_hover;
|
|
208
|
+
}
|
|
209
|
+
});
|
|
210
|
+
var backgroundActiveColor = (0, styled_components_1.css)(templateObject_17 || (templateObject_17 = __makeTemplateObject(["\n ", ";\n"], ["\n ", ";\n"])), function (_a) {
|
|
211
|
+
var colorTheme = _a.colorTheme, theme = _a.theme;
|
|
212
|
+
switch (colorTheme) {
|
|
213
|
+
case 'none':
|
|
214
|
+
return theme.ui_cpnt_textfield_base_pressed;
|
|
215
|
+
case 'dark':
|
|
216
|
+
return theme.ui_cpnt_textfield_base_pressed_darktheme;
|
|
217
|
+
case 'transparent':
|
|
218
|
+
return theme.ui_cpnt_textfield_base_pressed_transparent;
|
|
219
|
+
default:
|
|
220
|
+
return theme.ui_cpnt_textfield_base_pressed;
|
|
221
|
+
}
|
|
222
|
+
});
|
|
223
|
+
var normalActionColor = (0, styled_components_1.css)(templateObject_18 || (templateObject_18 = __makeTemplateObject(["\n &:hover {\n background-color: ", ";\n }\n\n &:active {\n background-color: ", ";\n }\n"], ["\n &:hover {\n background-color: ", ";\n }\n\n &:active {\n background-color: ", ";\n }\n"])), backgroundHoverColor, backgroundActiveColor);
|
|
224
|
+
var S_SearchFieldWrapper = styled_components_1.default.div(templateObject_19 || (templateObject_19 = __makeTemplateObject(["\n align-items: center;\n border-radius: 14px;\n box-sizing: border-box;\n cursor: ", ";\n display: flex;\n ", ";\n ", ";\n\n ", "\n\n ", "\n\n ", ";\n ", "\n"], ["\n align-items: center;\n border-radius: 14px;\n box-sizing: border-box;\n cursor: ", ";\n display: flex;\n ", ";\n ", ";\n\n ", "\n\n ", "\n\n ", ";\n ", "\n"])), function (_a) {
|
|
225
|
+
var state = _a.state;
|
|
226
|
+
return (state === 'disabled' ? 'not-allowed' : 'text');
|
|
227
|
+
}, function (_a) {
|
|
228
|
+
var size = _a.size;
|
|
229
|
+
return size &&
|
|
230
|
+
{
|
|
231
|
+
small: small,
|
|
232
|
+
medium: medium,
|
|
233
|
+
large: large
|
|
234
|
+
}[size];
|
|
235
|
+
}, function (_a) {
|
|
236
|
+
var state = _a.state, colorTheme = _a.colorTheme;
|
|
237
|
+
if (state) {
|
|
238
|
+
switch (colorTheme) {
|
|
239
|
+
case 'none': {
|
|
240
|
+
return { normal: normal, read_only: read_only, disabled: disabled }[state];
|
|
241
|
+
}
|
|
242
|
+
case 'dark': {
|
|
243
|
+
return { normal: dark_normal, read_only: dark_read_only, disabled: dark_disabled }[state];
|
|
244
|
+
}
|
|
245
|
+
case 'transparent': {
|
|
246
|
+
return {
|
|
247
|
+
normal: transparent_normal,
|
|
248
|
+
read_only: transparent_read_only,
|
|
249
|
+
disabled: transparent_disabled
|
|
250
|
+
}[state];
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
}, styles_1.InputTransition, function (_a) {
|
|
255
|
+
var state = _a.state;
|
|
256
|
+
return state === 'normal' && normalActionColor;
|
|
257
|
+
}, function (_a) {
|
|
258
|
+
var responsiveMode = _a.responsiveMode;
|
|
259
|
+
return responsiveMode === 'use' && 'width: 100%';
|
|
260
|
+
}, function (_a) {
|
|
261
|
+
var customWidth = _a.customWidth;
|
|
262
|
+
return customWidth && "width: " + customWidth + ";";
|
|
263
|
+
});
|
|
264
|
+
exports.default = SearchField;
|
|
265
|
+
var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7, templateObject_8, templateObject_9, templateObject_10, templateObject_11, templateObject_12, templateObject_13, templateObject_14, templateObject_15, templateObject_16, templateObject_17, templateObject_18, templateObject_19;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { FillIconNameKeys, LineIconNameKeys, PDSTextType, PDSValueOption } from '../../../common/types';
|
|
3
|
+
declare type Props = {
|
|
4
|
+
searchFieldHintText?: PDSTextType;
|
|
5
|
+
searchFieldDefaultText?: PDSTextType;
|
|
6
|
+
chipTextArray?: PDSValueOption[];
|
|
7
|
+
chipValue?: PDSValueOption;
|
|
8
|
+
searchMode?: 'none' | 'use';
|
|
9
|
+
chipMode?: 'none' | 'use';
|
|
10
|
+
iBtnMode?: 'none' | 'iBtn_amount1' | 'iBtn_amount2' | 'iBtn_amount3';
|
|
11
|
+
iBtn1IconName?: FillIconNameKeys | LineIconNameKeys;
|
|
12
|
+
iBtn1IconFillType?: 'fill' | 'line';
|
|
13
|
+
iBtn2IconName?: FillIconNameKeys | LineIconNameKeys;
|
|
14
|
+
iBtn2IconFillType?: 'fill' | 'line';
|
|
15
|
+
iBtn3IconName?: FillIconNameKeys | LineIconNameKeys;
|
|
16
|
+
iBtn3IconFillType?: 'fill' | 'line';
|
|
17
|
+
onClickChip?: (option: PDSValueOption) => void;
|
|
18
|
+
onClickSearchFieldResetIBtn?: () => void;
|
|
19
|
+
onClickSearchIBtn?: (value: string) => void;
|
|
20
|
+
onEnterKeyDown?: (value: string) => void;
|
|
21
|
+
onClickIBtn1?: () => void;
|
|
22
|
+
onClickIBtn2?: () => void;
|
|
23
|
+
onClickIBtn3?: () => void;
|
|
24
|
+
};
|
|
25
|
+
declare function ToolBar({ searchFieldHintText, searchFieldDefaultText, chipTextArray, chipValue, searchMode, chipMode, iBtnMode, iBtn1IconName, iBtn1IconFillType, iBtn2IconName, iBtn2IconFillType, iBtn3IconName, iBtn3IconFillType, onClickChip, onClickSearchFieldResetIBtn, onClickSearchIBtn, onEnterKeyDown, onClickIBtn1, onClickIBtn2, onClickIBtn3 }: Props): JSX.Element;
|
|
26
|
+
export default ToolBar;
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
|
|
3
|
+
if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
|
|
4
|
+
return cooked;
|
|
5
|
+
};
|
|
6
|
+
var __assign = (this && this.__assign) || function () {
|
|
7
|
+
__assign = Object.assign || function(t) {
|
|
8
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
9
|
+
s = arguments[i];
|
|
10
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
11
|
+
t[p] = s[p];
|
|
12
|
+
}
|
|
13
|
+
return t;
|
|
14
|
+
};
|
|
15
|
+
return __assign.apply(this, arguments);
|
|
16
|
+
};
|
|
17
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
18
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
19
|
+
};
|
|
20
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
|
+
var jsx_runtime_1 = require("react/jsx-runtime");
|
|
22
|
+
var react_1 = require("react");
|
|
23
|
+
var react_hook_form_1 = require("react-hook-form");
|
|
24
|
+
var components_1 = require("../../../common/components");
|
|
25
|
+
var components_2 = require("../../../desktop/components");
|
|
26
|
+
var components_3 = require("../../../hybrid/components");
|
|
27
|
+
var styled_components_1 = __importDefault(require("styled-components"));
|
|
28
|
+
var ChipList_1 = __importDefault(require("./ChipList"));
|
|
29
|
+
var SearchField_1 = __importDefault(require("./SearchField"));
|
|
30
|
+
function ToolBar(_a) {
|
|
31
|
+
var searchFieldHintText = _a.searchFieldHintText, searchFieldDefaultText = _a.searchFieldDefaultText, chipTextArray = _a.chipTextArray, chipValue = _a.chipValue, _b = _a.searchMode, searchMode = _b === void 0 ? 'none' : _b, _c = _a.chipMode, chipMode = _c === void 0 ? 'none' : _c, _d = _a.iBtnMode, iBtnMode = _d === void 0 ? 'none' : _d, iBtn1IconName = _a.iBtn1IconName, _e = _a.iBtn1IconFillType, iBtn1IconFillType = _e === void 0 ? 'line' : _e, iBtn2IconName = _a.iBtn2IconName, _f = _a.iBtn2IconFillType, iBtn2IconFillType = _f === void 0 ? 'line' : _f, iBtn3IconName = _a.iBtn3IconName, _g = _a.iBtn3IconFillType, iBtn3IconFillType = _g === void 0 ? 'line' : _g, onClickChip = _a.onClickChip, onClickSearchFieldResetIBtn = _a.onClickSearchFieldResetIBtn, onClickSearchIBtn = _a.onClickSearchIBtn, onEnterKeyDown = _a.onEnterKeyDown, onClickIBtn1 = _a.onClickIBtn1, onClickIBtn2 = _a.onClickIBtn2, onClickIBtn3 = _a.onClickIBtn3;
|
|
32
|
+
var _h = (0, react_1.useState)(!!searchFieldDefaultText), isShowSearchField = _h[0], setIsShowSearchField = _h[1];
|
|
33
|
+
var methods = (0, react_hook_form_1.useForm)();
|
|
34
|
+
var reset = methods.reset, handleSubmit = methods.handleSubmit;
|
|
35
|
+
var onSubmit = function (_a) {
|
|
36
|
+
var searchField = _a.searchField;
|
|
37
|
+
if (onEnterKeyDown) {
|
|
38
|
+
onEnterKeyDown(searchField);
|
|
39
|
+
}
|
|
40
|
+
};
|
|
41
|
+
var handleArrowIBtnClick = function () {
|
|
42
|
+
setIsShowSearchField(false);
|
|
43
|
+
reset();
|
|
44
|
+
if (onClickSearchFieldResetIBtn) {
|
|
45
|
+
onClickSearchFieldResetIBtn();
|
|
46
|
+
}
|
|
47
|
+
};
|
|
48
|
+
var handleSearchIBtnClick = function (value) {
|
|
49
|
+
if (onClickSearchIBtn) {
|
|
50
|
+
onClickSearchIBtn(value);
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
var handleSearchFieldShowIBtnClick = function () {
|
|
54
|
+
setIsShowSearchField(function (prev) { return !prev; });
|
|
55
|
+
};
|
|
56
|
+
var handleChipClick = function (option) {
|
|
57
|
+
if (onClickChip) {
|
|
58
|
+
onClickChip(option);
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
var handleIBtn1Click = function () {
|
|
62
|
+
if (onClickIBtn1) {
|
|
63
|
+
onClickIBtn1();
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
var handleIBtn2Click = function () {
|
|
67
|
+
if (onClickIBtn2) {
|
|
68
|
+
onClickIBtn2();
|
|
69
|
+
}
|
|
70
|
+
};
|
|
71
|
+
var handleIBtn3Click = function () {
|
|
72
|
+
if (onClickIBtn3) {
|
|
73
|
+
onClickIBtn3();
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: (0, jsx_runtime_1.jsxs)(S_ToolBarBox, { children: [(0, jsx_runtime_1.jsx)(S_FilterBox, { children: isShowSearchField ? ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: searchMode === 'use' && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(components_3.Spacing, { size: "spacing_e", spacingType: "width" }, void 0), (0, jsx_runtime_1.jsx)(react_hook_form_1.FormProvider, __assign({}, methods, { children: (0, jsx_runtime_1.jsx)(components_1.Form, __assign({ onSubmit: handleSubmit(onSubmit) }, { children: (0, jsx_runtime_1.jsx)(SearchField_1.default, { name: "searchField", hintText: searchFieldHintText, defaultText: searchFieldDefaultText, onClickArrowIBtn: handleArrowIBtnClick, onClickSearchIBtn: handleSearchIBtnClick, customWidth: "424px" }, void 0) }), void 0) }), void 0)] }, void 0)) }, void 0)) : ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [searchMode === 'use' && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(components_3.Spacing, { size: "spacing_d", spacingType: "width" }, void 0), (0, jsx_runtime_1.jsx)(S_SearchIconWrapper, { children: (0, jsx_runtime_1.jsx)(components_2.IconButton, { fillType: "fill", baseSize: "small", iconSize: 24, shapeType: "rectangle", iconName: "ic_search", iconFillType: "fill", iconColorKey: "ui_cpnt_list_icon_01", baseColorKey: "ui_cpnt_button_fill_base_transparent", onClick: handleSearchFieldShowIBtnClick }, void 0) }, void 0)] }, void 0)), chipMode === 'use' && chipTextArray && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(components_3.Spacing, { size: "spacing_d", spacingType: "width" }, void 0), (0, jsx_runtime_1.jsx)(ChipList_1.default, { textArray: chipTextArray, value: chipValue, onClickChip: handleChipClick }, void 0)] }, void 0))] }, void 0)) }, void 0), (0, jsx_runtime_1.jsx)(S_IconButtonBox, { children: iBtnMode !== 'none' && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [iBtnMode === 'iBtn_amount3' && iBtn3IconName && ((0, jsx_runtime_1.jsx)(components_2.IconButton, { fillType: "fill", baseSize: "medium", iconSize: 24, shapeType: "rectangle", iconName: iBtn3IconName, iconFillType: iBtn3IconFillType, iconColorKey: "ui_cpnt_list_icon_01", baseColorKey: "ui_cpnt_button_fill_base_transparent", onClick: handleIBtn3Click }, void 0)), (iBtnMode === 'iBtn_amount2' || iBtnMode === 'iBtn_amount3') && iBtn2IconName && ((0, jsx_runtime_1.jsx)(components_2.IconButton, { fillType: "fill", baseSize: "medium", iconSize: 24, shapeType: "rectangle", iconName: iBtn2IconName, iconFillType: iBtn2IconFillType, iconColorKey: "ui_cpnt_list_icon_01", baseColorKey: "ui_cpnt_button_fill_base_transparent", onClick: handleIBtn2Click }, void 0)), iBtn1IconName && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(components_2.IconButton, { fillType: "fill", baseSize: "medium", iconSize: 24, shapeType: "rectangle", iconName: iBtn1IconName, iconFillType: iBtn1IconFillType, iconColorKey: "ui_cpnt_list_icon_01", baseColorKey: "ui_cpnt_button_fill_base_transparent", onClick: handleIBtn1Click }, void 0), (0, jsx_runtime_1.jsx)(components_3.Spacing, { size: "spacing_d", spacingType: "width" }, void 0)] }, void 0))] }, void 0)) }, void 0)] }, void 0) }, void 0));
|
|
77
|
+
}
|
|
78
|
+
var S_ToolBarBox = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n align-items: flex-start;\n display: flex;\n justify-content: space-between;\n min-height: 40px;\n"], ["\n align-items: flex-start;\n display: flex;\n justify-content: space-between;\n min-height: 40px;\n"])));
|
|
79
|
+
var S_FilterBox = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n display: flex;\n"], ["\n display: flex;\n"])));
|
|
80
|
+
var S_SearchIconWrapper = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n align-items: center;\n display: flex;\n height: 40px;\n"], ["\n align-items: center;\n display: flex;\n height: 40px;\n"])));
|
|
81
|
+
var S_IconButtonBox = styled_components_1.default.div(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n display: flex;\n height: 40px;\n\n & > :not(:first-child) {\n margin-left: ", ";\n }\n"], ["\n display: flex;\n height: 40px;\n\n & > :not(:first-child) {\n margin-left: ", ";\n }\n"])), function (_a) {
|
|
82
|
+
var theme = _a.theme;
|
|
83
|
+
return theme.spacing.spacingB;
|
|
84
|
+
});
|
|
85
|
+
exports.default = ToolBar;
|
|
86
|
+
var templateObject_1, templateObject_2, templateObject_3, templateObject_4;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ToolBar } from './ToolBar';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.ToolBar = void 0;
|
|
7
|
+
var ToolBar_1 = require("./ToolBar");
|
|
8
|
+
Object.defineProperty(exports, "ToolBar", { enumerable: true, get: function () { return __importDefault(ToolBar_1).default; } });
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ToolBar = exports.BulkActionBar = exports.AdminListItem = exports.AdminListHeader = exports.AdminList = void 0;
|
|
4
|
+
var AdminList_1 = require("./AdminList");
|
|
5
|
+
Object.defineProperty(exports, "AdminList", { enumerable: true, get: function () { return AdminList_1.AdminList; } });
|
|
6
|
+
var AdminListHeader_1 = require("./AdminListHeader");
|
|
7
|
+
Object.defineProperty(exports, "AdminListHeader", { enumerable: true, get: function () { return AdminListHeader_1.AdminListHeader; } });
|
|
8
|
+
var AdminListItem_1 = require("./AdminListItem");
|
|
9
|
+
Object.defineProperty(exports, "AdminListItem", { enumerable: true, get: function () { return AdminListItem_1.AdminListItem; } });
|
|
10
|
+
var BulkActionBar_1 = require("./BulkActionBar");
|
|
11
|
+
Object.defineProperty(exports, "BulkActionBar", { enumerable: true, get: function () { return BulkActionBar_1.BulkActionBar; } });
|
|
12
|
+
var ToolBar_1 = require("./ToolBar");
|
|
13
|
+
Object.defineProperty(exports, "ToolBar", { enumerable: true, get: function () { return ToolBar_1.ToolBar; } });
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import type { DynamicLayoutProps } from './types';
|
|
3
|
-
declare function DynamicLayout({ device, mode, isPreview, sections, scrollDownTargetSectionId, editingSectionId, navigationHandler, onClickEditSection }: DynamicLayoutProps): JSX.Element;
|
|
3
|
+
declare function DynamicLayout({ device, mode, isPreview, sections, scrollDownTargetSectionId, editingSectionId, navigationHandler, sectionActionHandler, onClickEditSection }: DynamicLayoutProps): JSX.Element;
|
|
4
4
|
export default DynamicLayout;
|
|
@@ -25,10 +25,11 @@ var EditModeSectionMatcher_1 = require("./components/EditModeSectionMatcher");
|
|
|
25
25
|
var SectionMatcher_1 = require("./components/SectionMatcher");
|
|
26
26
|
var dynamicLayoutContext_1 = require("./dynamicLayoutContext");
|
|
27
27
|
function DynamicLayout(_a) {
|
|
28
|
-
var device = _a.device, _b = _a.mode, mode = _b === void 0 ? 'NORMAL' : _b, isPreview = _a.isPreview, sections = _a.sections, scrollDownTargetSectionId = _a.scrollDownTargetSectionId, editingSectionId = _a.editingSectionId, navigationHandler = _a.navigationHandler, onClickEditSection = _a.onClickEditSection;
|
|
28
|
+
var device = _a.device, _b = _a.mode, mode = _b === void 0 ? 'NORMAL' : _b, isPreview = _a.isPreview, sections = _a.sections, scrollDownTargetSectionId = _a.scrollDownTargetSectionId, editingSectionId = _a.editingSectionId, navigationHandler = _a.navigationHandler, sectionActionHandler = _a.sectionActionHandler, onClickEditSection = _a.onClickEditSection;
|
|
29
29
|
var filteredSortedSection = __spreadArray([], sections, true).filter(function (section) { return section.display; })
|
|
30
30
|
.sort(function (a, b) { return a.order - b.order; });
|
|
31
|
-
|
|
32
|
-
|
|
31
|
+
var iframeSection = filteredSortedSection.find(function (section) { return section.manifest.schema === 'EXP_IFRAME' && section.display; });
|
|
32
|
+
return ((0, jsx_runtime_1.jsxs)(dynamicLayoutContext_1.dynamicLayoutContext.Provider, __assign({ value: { device: device, mode: mode, isPreview: isPreview, navigationHandler: navigationHandler, sectionActionHandler: sectionActionHandler } }, { children: [mode === 'EDIT' && onClickEditSection && ((0, jsx_runtime_1.jsx)(EditModeSectionMatcher_1.EditModeSectionMatcher, { editingSectionId: editingSectionId, scrollDownTargetSectionId: scrollDownTargetSectionId, filteredSortedSection: filteredSortedSection, onClickEditSection: onClickEditSection }, void 0)), mode !== 'EDIT' &&
|
|
33
|
+
(iframeSection ? ((0, jsx_runtime_1.jsx)(SectionMatcher_1.SectionMatcher, __assign({}, iframeSection), iframeSection.id)) : (filteredSortedSection.map(function (section) { return (0, jsx_runtime_1.jsx)(SectionMatcher_1.SectionMatcher, __assign({}, section), section.id); })))] }), void 0));
|
|
33
34
|
}
|
|
34
35
|
exports.default = DynamicLayout;
|
package/dist/src/sub/DynamicLayout/components/EditModeSectionMatcher/EditModeSectionMatcher.js
CHANGED
|
@@ -19,6 +19,7 @@ var SectionMatcher_1 = require("../SectionMatcher");
|
|
|
19
19
|
var SectionBox_1 = __importDefault(require("./SectionBox"));
|
|
20
20
|
function EditModeSectionMatcher(_a) {
|
|
21
21
|
var filteredSortedSection = _a.filteredSortedSection, scrollDownTargetSectionId = _a.scrollDownTargetSectionId, editingSectionId = _a.editingSectionId, onClickEditSection = _a.onClickEditSection;
|
|
22
|
-
|
|
22
|
+
var iframeSection = filteredSortedSection.find(function (section) { return section.manifest.schema === 'EXP_IFRAME' && section.display; });
|
|
23
|
+
return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: iframeSection ? ((0, jsx_runtime_1.jsx)(SectionBox_1.default, __assign({ isIframeSection: true, isEditing: editingSectionId === iframeSection.id, scrollIntoThisSection: iframeSection.id === scrollDownTargetSectionId, onClick: function () { return onClickEditSection(iframeSection); } }, { children: (0, jsx_runtime_1.jsx)(SectionMatcher_1.SectionMatcher, __assign({}, iframeSection), iframeSection.id) }), iframeSection.id)) : (filteredSortedSection.map(function (section) { return ((0, jsx_runtime_1.jsx)(SectionBox_1.default, __assign({ isEditing: editingSectionId === section.id, scrollIntoThisSection: section.id === scrollDownTargetSectionId, onClick: function () { return onClickEditSection(section); } }, { children: (0, jsx_runtime_1.jsx)(SectionMatcher_1.SectionMatcher, __assign({}, section), section.id) }), section.id)); })) }, void 0));
|
|
23
24
|
}
|
|
24
25
|
exports.default = EditModeSectionMatcher;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
export default function SectionBox({ scrollIntoThisSection, isEditing, children, onClick }: {
|
|
2
|
+
export default function SectionBox({ scrollIntoThisSection, isIframeSection, isEditing, children, onClick }: {
|
|
3
3
|
scrollIntoThisSection: boolean;
|
|
4
|
+
isIframeSection?: boolean;
|
|
4
5
|
isEditing: boolean;
|
|
5
6
|
children: React.ReactNode;
|
|
6
7
|
onClick: () => void;
|
|
@@ -26,7 +26,7 @@ var desktop_1 = require("../../../../desktop");
|
|
|
26
26
|
var useLazyUnmount_1 = require("../../hooks/useLazyUnmount");
|
|
27
27
|
var OverlayBorders_1 = __importDefault(require("./OverlayBorders"));
|
|
28
28
|
function SectionBox(_a) {
|
|
29
|
-
var scrollIntoThisSection = _a.scrollIntoThisSection, isEditing = _a.isEditing, children = _a.children, onClick = _a.onClick;
|
|
29
|
+
var scrollIntoThisSection = _a.scrollIntoThisSection, isIframeSection = _a.isIframeSection, isEditing = _a.isEditing, children = _a.children, onClick = _a.onClick;
|
|
30
30
|
var t = (0, react_i18next_1.useTranslation)('translation').t;
|
|
31
31
|
var sectionRef = (0, react_1.useRef)(null);
|
|
32
32
|
var _b = (0, react_1.useState)(false), isHover = _b[0], setIsHover = _b[1];
|
|
@@ -72,14 +72,17 @@ function SectionBox(_a) {
|
|
|
72
72
|
setIsHover(false);
|
|
73
73
|
onClickDelayedAsync();
|
|
74
74
|
};
|
|
75
|
-
return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: (0, jsx_runtime_1.jsxs)(S_SectionBox, __assign({ ref: sectionRef, onClick: onClickSectionBox, onMouseEnter: onMouseEnter, onMouseLeave: onMouseLeaveAsync, isEditing: isEditing }, { children: [isEditing && !hasNoChild && ((0, jsx_runtime_1.jsxs)(S_Editing, { children: [(0, jsx_runtime_1.jsx)(OverlayBorders_1.default, { zIndex: 1 }, void 0), (0, jsx_runtime_1.jsx)(TopRightAbsoluteBox, { children: (0, jsx_runtime_1.jsx)(desktop_1.D_TextLabel, { text: t('str_4657'), styleTheme: "caption1Bold", colorOverride: "ui_cpnt_textlabel_sys_black", singleLineMode: "use", customFontWeight: "bold", textAlign: "center" }, void 0) }, void 0)] }, void 0)), !isEditing && ((0, jsx_runtime_1.jsx)(DimmedEditOverlay, __assign({ isHover: isHover, fadeOut: fadeOut }, { children: (0, jsx_runtime_1.jsx)(S_EditButton, { children: (0, jsx_runtime_1.jsx)(desktop_1.D_TextLabel, { text: t('str_4653'), colorOverride: "ui_cpnt_textlabel_sys_black", singleLineMode: "use", customFontWeight: "bold", textAlign: "center" }, void 0) }, void 0) }), void 0)), children] }), void 0) }, void 0));
|
|
75
|
+
return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: (0, jsx_runtime_1.jsxs)(S_SectionBox, __assign({ ref: sectionRef, onClick: onClickSectionBox, onMouseEnter: onMouseEnter, onMouseLeave: onMouseLeaveAsync, isEditing: isEditing, isIframeSection: isIframeSection }, { children: [isEditing && !hasNoChild && ((0, jsx_runtime_1.jsxs)(S_Editing, { children: [(0, jsx_runtime_1.jsx)(OverlayBorders_1.default, { zIndex: 1 }, void 0), (0, jsx_runtime_1.jsx)(TopRightAbsoluteBox, { children: (0, jsx_runtime_1.jsx)(desktop_1.D_TextLabel, { text: t('str_4657'), styleTheme: "caption1Bold", colorOverride: "ui_cpnt_textlabel_sys_black", singleLineMode: "use", customFontWeight: "bold", textAlign: "center" }, void 0) }, void 0)] }, void 0)), !isEditing && ((0, jsx_runtime_1.jsx)(DimmedEditOverlay, __assign({ isHover: isHover, fadeOut: fadeOut }, { children: (0, jsx_runtime_1.jsx)(S_EditButton, { children: (0, jsx_runtime_1.jsx)(desktop_1.D_TextLabel, { text: t('str_4653'), colorOverride: "ui_cpnt_textlabel_sys_black", singleLineMode: "use", customFontWeight: "bold", textAlign: "center" }, void 0) }, void 0) }), void 0)), children] }), void 0) }, void 0));
|
|
76
76
|
}
|
|
77
77
|
exports.default = SectionBox;
|
|
78
78
|
var TopRightAbsoluteBox = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n background-color: ", ";\n padding: 8px 10px;\n position: absolute;\n right: 0;\n top: 0;\n transition: background-color 0.2s ease-out;\n z-index: 4;\n"], ["\n background-color: ", ";\n padding: 8px 10px;\n position: absolute;\n right: 0;\n top: 0;\n transition: background-color 0.2s ease-out;\n z-index: 4;\n"])), function (_a) {
|
|
79
79
|
var theme = _a.theme;
|
|
80
80
|
return theme.ui_editor_preview_editing;
|
|
81
81
|
});
|
|
82
|
-
var S_SectionBox = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n position: relative;\n"], ["\n position: relative;\n"])))
|
|
82
|
+
var S_SectionBox = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n height: ", ";\n position: relative;\n"], ["\n height: ", ";\n position: relative;\n"])), function (_a) {
|
|
83
|
+
var isIframeSection = _a.isIframeSection;
|
|
84
|
+
return (isIframeSection ? '100%' : 'auto');
|
|
85
|
+
});
|
|
83
86
|
var DimmedEditOverlay = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n align-items: center;\n animation: ", ";\n background-color: ", ";\n bottom: 0;\n cursor: pointer;\n display: flex;\n justify-content: center;\n left: 0;\n\n opacity: ", ";\n\n position: absolute;\n right: 0;\n top: 0;\n transition: opacity 0.2s ease-out;\n z-index: 10;\n\n @keyframes fadeOut {\n 0% {\n opacity: 1;\n }\n\n 50% {\n opacity: 0.6;\n }\n\n 100% {\n opacity: 0;\n }\n }\n"], ["\n align-items: center;\n animation: ", ";\n background-color: ", ";\n bottom: 0;\n cursor: pointer;\n display: flex;\n justify-content: center;\n left: 0;\n\n opacity: ", ";\n\n position: absolute;\n right: 0;\n top: 0;\n transition: opacity 0.2s ease-out;\n z-index: 10;\n\n @keyframes fadeOut {\n 0% {\n opacity: 1;\n }\n\n 50% {\n opacity: 0.6;\n }\n\n 100% {\n opacity: 0;\n }\n }\n"])), function (_a) {
|
|
84
87
|
var fadeOut = _a.fadeOut;
|
|
85
88
|
return fadeOut && 'fadeOut 0.2s ease-out';
|
|
@@ -37,9 +37,12 @@ var YouTubeIframe_1 = require("../YouTubeIframe");
|
|
|
37
37
|
var sectionContext_1 = require("./sectionContext");
|
|
38
38
|
function Section(_a) {
|
|
39
39
|
var children = _a.children, props = __rest(_a, ["children"]);
|
|
40
|
-
return ((0, jsx_runtime_1.jsx)(sectionContext_1.sectionContext.Provider, __assign({ value: props }, { children: (0, jsx_runtime_1.jsxs)(S_Section, { children: [(0, jsx_runtime_1.jsx)(Background, {}, void 0), children] }, void 0) }), void 0));
|
|
40
|
+
return ((0, jsx_runtime_1.jsx)(sectionContext_1.sectionContext.Provider, __assign({ value: props }, { children: (0, jsx_runtime_1.jsxs)(S_Section, __assign({ isIframeSection: props.manifest.schema === 'EXP_IFRAME' }, { children: [(0, jsx_runtime_1.jsx)(Background, {}, void 0), children] }), void 0) }), void 0));
|
|
41
41
|
}
|
|
42
|
-
var S_Section = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n box-sizing: border-box;\n position: relative;\n width: 100%;\n z-index: 0;\n"], ["\n box-sizing: border-box;\n position: relative;\n width: 100%;\n z-index: 0;\n"])))
|
|
42
|
+
var S_Section = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n box-sizing: border-box;\n height: ", ";\n position: relative;\n width: 100%;\n z-index: 0;\n"], ["\n box-sizing: border-box;\n height: ", ";\n position: relative;\n width: 100%;\n z-index: 0;\n"])), function (_a) {
|
|
43
|
+
var isIframeSection = _a.isIframeSection;
|
|
44
|
+
return (isIframeSection ? '100%' : 'auto');
|
|
45
|
+
});
|
|
43
46
|
function Background() {
|
|
44
47
|
var context = (0, react_1.useContext)(sectionContext_1.sectionContext);
|
|
45
48
|
var id = context.id;
|
|
@@ -38,6 +38,8 @@ function SectionMatcher(_a) {
|
|
|
38
38
|
return (0, jsx_runtime_1.jsx)(sections_1.FooterSection, __assign({}, props), void 0);
|
|
39
39
|
case 'BASE_INFO_BOX':
|
|
40
40
|
return (0, jsx_runtime_1.jsx)(sections_1.InfoBoxSection, __assign({}, props), void 0);
|
|
41
|
+
case 'EXP_IFRAME':
|
|
42
|
+
return (0, jsx_runtime_1.jsx)(sections_1.FullscreenIframeSection, __assign({}, props), void 0);
|
|
41
43
|
default:
|
|
42
44
|
return (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, {}, void 0);
|
|
43
45
|
}
|
|
@@ -181,7 +181,7 @@ function HTMLReader(_a) {
|
|
|
181
181
|
}, [data]);
|
|
182
182
|
return ((0, jsx_runtime_1.jsx)(S_Content, { ref: contentRef, styleTheme: styleTheme, colorTheme: colorTheme, color: color, textAlign: textAlign, isPreview: isPreview !== null && isPreview !== void 0 ? isPreview : mode === 'PREVIEW' }, void 0));
|
|
183
183
|
}
|
|
184
|
-
var S_Content = styled_components_1.default.div(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n color: ", ";\n line-height: 1.5;\n text-align: ", ";\n
|
|
184
|
+
var S_Content = styled_components_1.default.div(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n color: ", ";\n line-height: 1.5;\n text-align: ", ";\n white-space: pre-wrap;\n width: 100%;\n word-break: break-word;\n\n ", "\n\n a {\n color: ", ";\n }\n\n img {\n width: 100%;\n }\n\n figure {\n margin: 0;\n max-width: 100%;\n\n img {\n width: 100%;\n }\n }\n\n blockquote {\n border-left: 4px solid ", ";\n margin: 4px;\n padding: 4px;\n\n p {\n font-style: oblique;\n margin: 0;\n }\n }\n\n ", ";\n\n ", ";\n\n ", "\n"], ["\n color: ", ";\n line-height: 1.5;\n text-align: ", ";\n white-space: pre-wrap;\n width: 100%;\n word-break: break-word;\n\n ", "\n\n a {\n color: ", ";\n }\n\n img {\n width: 100%;\n }\n\n figure {\n margin: 0;\n max-width: 100%;\n\n img {\n width: 100%;\n }\n }\n\n blockquote {\n border-left: 4px solid ", ";\n margin: 4px;\n padding: 4px;\n\n p {\n font-style: oblique;\n margin: 0;\n }\n }\n\n ", ";\n\n ", ";\n\n ", "\n"])), function (_a) {
|
|
185
185
|
var theme = _a.theme;
|
|
186
186
|
return theme.ui_temp_grey_01;
|
|
187
187
|
}, function (_a) {
|
|
@@ -178,7 +178,7 @@ function HTMLReader(_a) {
|
|
|
178
178
|
}, [data]);
|
|
179
179
|
return ((0, jsx_runtime_1.jsx)(S_Content, { ref: contentRef, styleTheme: styleTheme, colorTheme: colorTheme, color: color, textAlign: textAlign, isPreview: isPreview !== null && isPreview !== void 0 ? isPreview : mode === 'PREVIEW' }, void 0));
|
|
180
180
|
}
|
|
181
|
-
var S_Content = styled_components_1.default.div(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n color: ", ";\n line-height: 1.5;\n text-align: ", ";\n
|
|
181
|
+
var S_Content = styled_components_1.default.div(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n color: ", ";\n line-height: 1.5;\n text-align: ", ";\n white-space: pre-wrap;\n width: 100%;\n word-break: break-word;\n\n ", "\n\n a {\n color: ", ";\n }\n\n img {\n width: 100%;\n }\n\n figure {\n margin: 0;\n max-width: 100%;\n\n img {\n width: 100%;\n }\n }\n\n blockquote {\n border-left: 4px solid ", ";\n margin: 4px;\n padding: 4px;\n\n p {\n font-style: oblique;\n margin: 0;\n }\n }\n\n ", ";\n\n ", ";\n\n ", "\n"], ["\n color: ", ";\n line-height: 1.5;\n text-align: ", ";\n white-space: pre-wrap;\n width: 100%;\n word-break: break-word;\n\n ", "\n\n a {\n color: ", ";\n }\n\n img {\n width: 100%;\n }\n\n figure {\n margin: 0;\n max-width: 100%;\n\n img {\n width: 100%;\n }\n }\n\n blockquote {\n border-left: 4px solid ", ";\n margin: 4px;\n padding: 4px;\n\n p {\n font-style: oblique;\n margin: 0;\n }\n }\n\n ", ";\n\n ", ";\n\n ", "\n"])), function (_a) {
|
|
182
182
|
var theme = _a.theme;
|
|
183
183
|
return theme.ui_temp_grey_01;
|
|
184
184
|
}, function (_a) {
|
|
@@ -6,4 +6,5 @@ export declare const samplePageContentsSection: ISection;
|
|
|
6
6
|
export declare const samplePageInfoBoxSection: ISection;
|
|
7
7
|
export declare const samplePageIntroSection3: ISection;
|
|
8
8
|
export declare const samplePageFooterSection: ISection;
|
|
9
|
+
export declare const samplePageFullscreenIframeSection: ISection;
|
|
9
10
|
export declare const samplePage: ISection[];
|