@lowdefy/blocks-antd 4.0.0-alpha.26 → 4.0.0-alpha.29
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/package.json +9 -10
- package/dist/blocks/Affix/Affix.js +0 -43
- package/dist/blocks/Affix/schema.json +0 -34
- package/dist/blocks/Affix/style.less +0 -17
- package/dist/blocks/Alert/Alert.js +0 -78
- package/dist/blocks/Alert/schema.json +0 -62
- package/dist/blocks/Alert/style.less +0 -17
- package/dist/blocks/AutoComplete/AutoComplete.js +0 -86
- package/dist/blocks/AutoComplete/schema.json +0 -148
- package/dist/blocks/AutoComplete/style.less +0 -17
- package/dist/blocks/Avatar/Avatar.js +0 -49
- package/dist/blocks/Avatar/schema.json +0 -71
- package/dist/blocks/Avatar/style.less +0 -17
- package/dist/blocks/Badge/Badge.js +0 -44
- package/dist/blocks/Badge/schema.json +0 -70
- package/dist/blocks/Badge/style.less +0 -17
- package/dist/blocks/Breadcrumb/Breadcrumb.js +0 -79
- package/dist/blocks/Breadcrumb/schema.json +0 -78
- package/dist/blocks/Breadcrumb/style.less +0 -17
- package/dist/blocks/Button/Button.js +0 -77
- package/dist/blocks/Button/schema.json +0 -91
- package/dist/blocks/Button/style.less +0 -17
- package/dist/blocks/ButtonSelector/ButtonSelector.js +0 -91
- package/dist/blocks/ButtonSelector/schema.json +0 -188
- package/dist/blocks/ButtonSelector/style.less +0 -18
- package/dist/blocks/Card/Card.js +0 -50
- package/dist/blocks/Card/schema.json +0 -58
- package/dist/blocks/Card/style.less +0 -17
- package/dist/blocks/CheckboxSelector/CheckboxSelector.js +0 -97
- package/dist/blocks/CheckboxSelector/schema.json +0 -193
- package/dist/blocks/CheckboxSelector/style.less +0 -19
- package/dist/blocks/CheckboxSwitch/CheckboxSwitch.js +0 -74
- package/dist/blocks/CheckboxSwitch/schema.json +0 -105
- package/dist/blocks/CheckboxSwitch/style.less +0 -19
- package/dist/blocks/Collapse/Collapse.js +0 -89
- package/dist/blocks/Collapse/schema.json +0 -90
- package/dist/blocks/Collapse/style.less +0 -17
- package/dist/blocks/Comment/Comment.js +0 -56
- package/dist/blocks/Comment/schema.json +0 -39
- package/dist/blocks/Comment/style.less +0 -18
- package/dist/blocks/ConfirmModal/ConfirmModal.js +0 -96
- package/dist/blocks/ConfirmModal/schema.json +0 -122
- package/dist/blocks/ConfirmModal/style.less +0 -17
- package/dist/blocks/Content/Content.js +0 -31
- package/dist/blocks/Content/schema.json +0 -16
- package/dist/blocks/Content/style.less +0 -17
- package/dist/blocks/ControlledList/ControlledList.js +0 -137
- package/dist/blocks/ControlledList/schema.json +0 -68
- package/dist/blocks/ControlledList/style.less +0 -19
- package/dist/blocks/DateRangeSelector/DateRangeSelector.js +0 -102
- package/dist/blocks/DateRangeSelector/schema.json +0 -221
- package/dist/blocks/DateRangeSelector/style.less +0 -18
- package/dist/blocks/DateSelector/DateSelector.js +0 -90
- package/dist/blocks/DateSelector/schema.json +0 -183
- package/dist/blocks/DateSelector/style.less +0 -18
- package/dist/blocks/DateTimeSelector/DateTimeSelector.js +0 -98
- package/dist/blocks/DateTimeSelector/schema.json +0 -215
- package/dist/blocks/DateTimeSelector/style.less +0 -18
- package/dist/blocks/Descriptions/Descriptions.js +0 -83
- package/dist/blocks/Descriptions/schema.json +0 -186
- package/dist/blocks/Descriptions/style.less +0 -17
- package/dist/blocks/Divider/Divider.js +0 -37
- package/dist/blocks/Divider/schema.json +0 -35
- package/dist/blocks/Divider/style.less +0 -17
- package/dist/blocks/Drawer/Drawer.js +0 -104
- package/dist/blocks/Drawer/schema.json +0 -113
- package/dist/blocks/Drawer/style.less +0 -17
- package/dist/blocks/Footer/Footer.js +0 -36
- package/dist/blocks/Footer/schema.json +0 -16
- package/dist/blocks/Footer/style.less +0 -17
- package/dist/blocks/Header/Header.js +0 -36
- package/dist/blocks/Header/schema.json +0 -22
- package/dist/blocks/Header/style.less +0 -17
- package/dist/blocks/Label/Label.js +0 -116
- package/dist/blocks/Label/getLabelCol.js +0 -55
- package/dist/blocks/Label/getWrapperCol.js +0 -69
- package/dist/blocks/Label/labelLogic.js +0 -106
- package/dist/blocks/Label/schema.json +0 -62
- package/dist/blocks/Label/style.less +0 -34
- package/dist/blocks/Layout/Layout.js +0 -30
- package/dist/blocks/Layout/schema.json +0 -16
- package/dist/blocks/Layout/style.less +0 -17
- package/dist/blocks/Menu/Menu.js +0 -209
- package/dist/blocks/Menu/schema.json +0 -236
- package/dist/blocks/Menu/style.less +0 -17
- package/dist/blocks/Message/Message.js +0 -53
- package/dist/blocks/Message/schema.json +0 -48
- package/dist/blocks/Message/style.less +0 -17
- package/dist/blocks/MobileMenu/MobileMenu.js +0 -128
- package/dist/blocks/MobileMenu/schema.json +0 -236
- package/dist/blocks/MobileMenu/style.less +0 -19
- package/dist/blocks/Modal/Modal.js +0 -130
- package/dist/blocks/Modal/schema.json +0 -118
- package/dist/blocks/Modal/style.less +0 -17
- package/dist/blocks/MonthSelector/MonthSelector.js +0 -90
- package/dist/blocks/MonthSelector/schema.json +0 -183
- package/dist/blocks/MonthSelector/style.less +0 -18
- package/dist/blocks/MultipleSelector/MultipleSelector.js +0 -146
- package/dist/blocks/MultipleSelector/schema.json +0 -239
- package/dist/blocks/MultipleSelector/style.less +0 -18
- package/dist/blocks/Notification/Notification.js +0 -77
- package/dist/blocks/Notification/schema.json +0 -85
- package/dist/blocks/Notification/style.less +0 -18
- package/dist/blocks/NumberInput/NumberInput.js +0 -82
- package/dist/blocks/NumberInput/schema.json +0 -157
- package/dist/blocks/NumberInput/style.less +0 -18
- package/dist/blocks/PageHCF/PageHCF.js +0 -70
- package/dist/blocks/PageHCF/schema.json +0 -64
- package/dist/blocks/PageHCF/style.less +0 -20
- package/dist/blocks/PageHCSF/PageHCSF.js +0 -98
- package/dist/blocks/PageHCSF/schema.json +0 -148
- package/dist/blocks/PageHCSF/style.less +0 -21
- package/dist/blocks/PageHSCF/PageHSCF.js +0 -98
- package/dist/blocks/PageHSCF/schema.json +0 -147
- package/dist/blocks/PageHSCF/style.less +0 -21
- package/dist/blocks/PageHeaderMenu/PageHeaderMenu.js +0 -290
- package/dist/blocks/PageHeaderMenu/schema.json +0 -215
- package/dist/blocks/PageHeaderMenu/style.less +0 -23
- package/dist/blocks/PageSHCF/PageSHCF.js +0 -98
- package/dist/blocks/PageSHCF/schema.json +0 -148
- package/dist/blocks/PageSHCF/style.less +0 -21
- package/dist/blocks/PageSiderMenu/PageSiderMenu.js +0 -406
- package/dist/blocks/PageSiderMenu/schema.json +0 -283
- package/dist/blocks/PageSiderMenu/style.less +0 -26
- package/dist/blocks/Pagination/Pagination.js +0 -98
- package/dist/blocks/Pagination/schema.json +0 -75
- package/dist/blocks/Pagination/style.less +0 -17
- package/dist/blocks/Paragraph/Paragraph.js +0 -102
- package/dist/blocks/Paragraph/schema.json +0 -131
- package/dist/blocks/Paragraph/style.less +0 -17
- package/dist/blocks/ParagraphInput/ParagraphInput.js +0 -125
- package/dist/blocks/ParagraphInput/schema.json +0 -162
- package/dist/blocks/ParagraphInput/style.less +0 -17
- package/dist/blocks/PasswordInput/PasswordInput.js +0 -78
- package/dist/blocks/PasswordInput/schema.json +0 -123
- package/dist/blocks/PasswordInput/style.less +0 -18
- package/dist/blocks/Progress/Progress.js +0 -42
- package/dist/blocks/Progress/schema.json +0 -76
- package/dist/blocks/Progress/style.less +0 -17
- package/dist/blocks/RadioSelector/RadioSelector.js +0 -96
- package/dist/blocks/RadioSelector/schema.json +0 -190
- package/dist/blocks/RadioSelector/style.less +0 -19
- package/dist/blocks/RatingSlider/RatingSlider.js +0 -240
- package/dist/blocks/RatingSlider/schema.json +0 -169
- package/dist/blocks/RatingSlider/style.less +0 -19
- package/dist/blocks/Result/Result.js +0 -48
- package/dist/blocks/Result/schema.json +0 -30
- package/dist/blocks/Result/style.less +0 -17
- package/dist/blocks/Selector/Selector.js +0 -140
- package/dist/blocks/Selector/schema.json +0 -236
- package/dist/blocks/Selector/style.less +0 -18
- package/dist/blocks/Sider/Sider.js +0 -85
- package/dist/blocks/Sider/schema.json +0 -71
- package/dist/blocks/Sider/style.less +0 -17
- package/dist/blocks/Statistic/Statistic.js +0 -51
- package/dist/blocks/Statistic/schema.json +0 -74
- package/dist/blocks/Statistic/style.less +0 -17
- package/dist/blocks/Switch/Switch.js +0 -101
- package/dist/blocks/Switch/schema.json +0 -136
- package/dist/blocks/Switch/style.less +0 -18
- package/dist/blocks/Tabs/Tabs.js +0 -108
- package/dist/blocks/Tabs/schema.json +0 -97
- package/dist/blocks/Tabs/style.less +0 -17
- package/dist/blocks/TextArea/TextArea.js +0 -87
- package/dist/blocks/TextArea/schema.json +0 -164
- package/dist/blocks/TextArea/style.less +0 -18
- package/dist/blocks/TextInput/TextInput.js +0 -92
- package/dist/blocks/TextInput/schema.json +0 -149
- package/dist/blocks/TextInput/style.less +0 -18
- package/dist/blocks/TimelineList/TimelineList.js +0 -102
- package/dist/blocks/TimelineList/schema.json +0 -65
- package/dist/blocks/TimelineList/style.less +0 -17
- package/dist/blocks/Title/Title.js +0 -109
- package/dist/blocks/Title/schema.json +0 -136
- package/dist/blocks/Title/style.less +0 -17
- package/dist/blocks/TitleInput/TitleInput.js +0 -122
- package/dist/blocks/TitleInput/schema.json +0 -171
- package/dist/blocks/TitleInput/style.less +0 -17
- package/dist/blocks/Tooltip/Tooltip.js +0 -48
- package/dist/blocks/Tooltip/schema.json +0 -91
- package/dist/blocks/Tooltip/style.less +0 -17
- package/dist/blocks/WeekSelector/WeekSelector.js +0 -91
- package/dist/blocks/WeekSelector/schema.json +0 -183
- package/dist/blocks/WeekSelector/style.less +0 -18
- package/dist/blocks.js +0 -74
- package/dist/color.js +0 -85
- package/dist/disabledDate.js +0 -45
- package/dist/getUniqueValues.js +0 -30
- package/dist/getValueIndex.js +0 -42
- package/dist/style.less +0 -17
- package/dist/types.js +0 -31
- package/dist/useRunAfterUpdate.js +0 -29
- package/dist/validationExamples.js +0 -40
|
@@ -1,290 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
Copyright 2020-2022 Lowdefy, Inc
|
|
3
|
-
|
|
4
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
you may not use this file except in compliance with the License.
|
|
6
|
-
You may obtain a copy of the License at
|
|
7
|
-
|
|
8
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
|
|
10
|
-
Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
See the License for the specific language governing permissions and
|
|
14
|
-
limitations under the License.
|
|
15
|
-
*/ import React from 'react';
|
|
16
|
-
import { blockDefaultProps } from '@lowdefy/block-utils';
|
|
17
|
-
import { get, mergeObjects, type } from '@lowdefy/helpers';
|
|
18
|
-
import Breadcrumb from '../Breadcrumb/Breadcrumb.js';
|
|
19
|
-
import Content from '../Content/Content.js';
|
|
20
|
-
import Footer from '../Footer/Footer.js';
|
|
21
|
-
import Header from '../Header/Header.js';
|
|
22
|
-
import Layout from '../Layout/Layout.js';
|
|
23
|
-
import Menu from '../Menu/Menu.js';
|
|
24
|
-
import MobileMenu from '../MobileMenu/MobileMenu.js';
|
|
25
|
-
const PageHeaderMenu = ({ basePath , blockId , components: { Icon , Link } , content , events , menus , methods , pageId , properties , })=>{
|
|
26
|
-
const styles = {
|
|
27
|
-
layout: {
|
|
28
|
-
minHeight: '100vh'
|
|
29
|
-
},
|
|
30
|
-
header: {
|
|
31
|
-
display: 'flex',
|
|
32
|
-
alignItems: 'center',
|
|
33
|
-
padding: '0 46px',
|
|
34
|
-
sm: {
|
|
35
|
-
padding: '0 15px'
|
|
36
|
-
},
|
|
37
|
-
md: {
|
|
38
|
-
padding: '0 30px'
|
|
39
|
-
},
|
|
40
|
-
lg: {
|
|
41
|
-
padding: '0 46px'
|
|
42
|
-
}
|
|
43
|
-
},
|
|
44
|
-
headerContent: {
|
|
45
|
-
display: 'flex',
|
|
46
|
-
flex: '1 1 auto',
|
|
47
|
-
alignItems: 'center',
|
|
48
|
-
justifyContent: 'flex-end'
|
|
49
|
-
},
|
|
50
|
-
logo: {
|
|
51
|
-
margin: '0px 30px',
|
|
52
|
-
flex: '0 1 auto',
|
|
53
|
-
sm: {
|
|
54
|
-
margin: '0 10px'
|
|
55
|
-
},
|
|
56
|
-
md: {
|
|
57
|
-
margin: '0 15px'
|
|
58
|
-
}
|
|
59
|
-
},
|
|
60
|
-
lgMenu: {
|
|
61
|
-
flex: '1 1 auto',
|
|
62
|
-
sm: {
|
|
63
|
-
display: 'none'
|
|
64
|
-
},
|
|
65
|
-
md: {
|
|
66
|
-
display: 'none'
|
|
67
|
-
},
|
|
68
|
-
lg: {
|
|
69
|
-
display: 'flex'
|
|
70
|
-
}
|
|
71
|
-
},
|
|
72
|
-
mdMenu: {
|
|
73
|
-
flex: '0 1 auto',
|
|
74
|
-
paddingLeft: '1rem',
|
|
75
|
-
sm: {
|
|
76
|
-
display: 'flex'
|
|
77
|
-
},
|
|
78
|
-
md: {
|
|
79
|
-
display: 'flex'
|
|
80
|
-
},
|
|
81
|
-
lg: {
|
|
82
|
-
display: 'none'
|
|
83
|
-
}
|
|
84
|
-
},
|
|
85
|
-
desktop: {
|
|
86
|
-
display: 'none',
|
|
87
|
-
lg: {
|
|
88
|
-
display: 'block'
|
|
89
|
-
}
|
|
90
|
-
},
|
|
91
|
-
mobile: {
|
|
92
|
-
display: 'block',
|
|
93
|
-
lg: {
|
|
94
|
-
display: 'none'
|
|
95
|
-
}
|
|
96
|
-
},
|
|
97
|
-
body: {
|
|
98
|
-
padding: '0 40px 40px 40px',
|
|
99
|
-
sm: {
|
|
100
|
-
padding: '0 10px 10px 10px'
|
|
101
|
-
},
|
|
102
|
-
md: {
|
|
103
|
-
padding: '0 20px 20px 20px'
|
|
104
|
-
},
|
|
105
|
-
lg: {
|
|
106
|
-
padding: '0 40px 40px 40px'
|
|
107
|
-
}
|
|
108
|
-
},
|
|
109
|
-
noBreadcrumb: {
|
|
110
|
-
padding: '20px 0',
|
|
111
|
-
sm: {
|
|
112
|
-
padding: '5px 0'
|
|
113
|
-
},
|
|
114
|
-
md: {
|
|
115
|
-
padding: '10px 0'
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
};
|
|
119
|
-
return /*#__PURE__*/ React.createElement(Layout, {
|
|
120
|
-
blockId: blockId,
|
|
121
|
-
events: events,
|
|
122
|
-
properties: {
|
|
123
|
-
style: mergeObjects([
|
|
124
|
-
{
|
|
125
|
-
minHeight: '100vh'
|
|
126
|
-
},
|
|
127
|
-
properties.style
|
|
128
|
-
])
|
|
129
|
-
},
|
|
130
|
-
components: {
|
|
131
|
-
Icon,
|
|
132
|
-
Link
|
|
133
|
-
},
|
|
134
|
-
content: {
|
|
135
|
-
content: ()=>/*#__PURE__*/ React.createElement(React.Fragment, null, /*#__PURE__*/ React.createElement(Header, {
|
|
136
|
-
blockId: `${blockId}_header`,
|
|
137
|
-
events: events,
|
|
138
|
-
components: {
|
|
139
|
-
Icon,
|
|
140
|
-
Link
|
|
141
|
-
},
|
|
142
|
-
properties: mergeObjects([
|
|
143
|
-
{
|
|
144
|
-
style: styles.header
|
|
145
|
-
},
|
|
146
|
-
properties.header,
|
|
147
|
-
]),
|
|
148
|
-
content: {
|
|
149
|
-
// TODO: use next/image
|
|
150
|
-
content: ()=>/*#__PURE__*/ React.createElement(React.Fragment, null, /*#__PURE__*/ React.createElement(Link, {
|
|
151
|
-
home: true
|
|
152
|
-
}, /*#__PURE__*/ React.createElement("img", {
|
|
153
|
-
src: properties.logo && properties.logo.src || (get(properties, 'header.theme') === 'light' ? `${basePath}/logo-light-theme.png` : `${basePath}/logo-dark-theme.png`),
|
|
154
|
-
srcSet: properties.logo && (properties.logo.srcSet || properties.logo.src) || (get(properties, 'header.theme') === 'light' ? `${basePath}/logo-square-light-theme.png 40w, ${basePath}/logo-light-theme.png 577w` : `${basePath}/logo-square-dark-theme.png 40w, ${basePath}/logo-dark-theme.png 577w`),
|
|
155
|
-
sizes: properties.logo && properties.logo.sizes || '(max-width: 576px) 40px, 577px',
|
|
156
|
-
alt: properties.logo && properties.logo.alt || 'Lowdefy',
|
|
157
|
-
className: methods.makeCssClass([
|
|
158
|
-
{
|
|
159
|
-
width: 130,
|
|
160
|
-
sm: {
|
|
161
|
-
width: properties.logo && properties.logo.src && !properties.logo.srcSet ? 130 : 40
|
|
162
|
-
},
|
|
163
|
-
md: {
|
|
164
|
-
width: 130
|
|
165
|
-
}
|
|
166
|
-
},
|
|
167
|
-
styles.logo,
|
|
168
|
-
properties.logo && properties.logo.style,
|
|
169
|
-
])
|
|
170
|
-
})), /*#__PURE__*/ React.createElement("div", {
|
|
171
|
-
className: methods.makeCssClass(styles.headerContent)
|
|
172
|
-
}, /*#__PURE__*/ React.createElement("div", {
|
|
173
|
-
className: methods.makeCssClass([
|
|
174
|
-
styles.desktop,
|
|
175
|
-
styles.lgMenu
|
|
176
|
-
])
|
|
177
|
-
}, /*#__PURE__*/ React.createElement(Menu, {
|
|
178
|
-
blockId: `${blockId}_menu`,
|
|
179
|
-
basePath: basePath,
|
|
180
|
-
components: {
|
|
181
|
-
Icon,
|
|
182
|
-
Link
|
|
183
|
-
},
|
|
184
|
-
events: events,
|
|
185
|
-
methods: methods,
|
|
186
|
-
menus: menus,
|
|
187
|
-
pageId: pageId,
|
|
188
|
-
properties: mergeObjects([
|
|
189
|
-
{
|
|
190
|
-
mode: 'horizontal',
|
|
191
|
-
collapsed: false,
|
|
192
|
-
theme: get(properties, 'header.theme') || 'dark'
|
|
193
|
-
},
|
|
194
|
-
properties.menu,
|
|
195
|
-
properties.menuLg,
|
|
196
|
-
])
|
|
197
|
-
})), content.header && content.header(mergeObjects([
|
|
198
|
-
{
|
|
199
|
-
width: 'auto',
|
|
200
|
-
flex: '0 1 auto'
|
|
201
|
-
},
|
|
202
|
-
properties.header && properties.header.contentStyle,
|
|
203
|
-
])), /*#__PURE__*/ React.createElement("div", {
|
|
204
|
-
className: methods.makeCssClass([
|
|
205
|
-
styles.mobile,
|
|
206
|
-
styles.mdMenu
|
|
207
|
-
])
|
|
208
|
-
}, /*#__PURE__*/ React.createElement(MobileMenu, {
|
|
209
|
-
blockId: `${blockId}_mobile_menu`,
|
|
210
|
-
basePath: basePath,
|
|
211
|
-
components: {
|
|
212
|
-
Icon,
|
|
213
|
-
Link
|
|
214
|
-
},
|
|
215
|
-
events: events,
|
|
216
|
-
methods: methods,
|
|
217
|
-
menus: menus,
|
|
218
|
-
pageId: pageId,
|
|
219
|
-
properties: mergeObjects([
|
|
220
|
-
properties.menu,
|
|
221
|
-
properties.menuMd
|
|
222
|
-
])
|
|
223
|
-
}))))
|
|
224
|
-
}
|
|
225
|
-
}), /*#__PURE__*/ React.createElement(Content, {
|
|
226
|
-
blockId: `${blockId}_content`,
|
|
227
|
-
components: {
|
|
228
|
-
Icon,
|
|
229
|
-
Link
|
|
230
|
-
},
|
|
231
|
-
events: events,
|
|
232
|
-
properties: mergeObjects([
|
|
233
|
-
properties.content,
|
|
234
|
-
{
|
|
235
|
-
style: styles.body
|
|
236
|
-
}
|
|
237
|
-
]),
|
|
238
|
-
content: {
|
|
239
|
-
content: ()=>/*#__PURE__*/ React.createElement(React.Fragment, null, !type.isNone(properties.breadcrumb) ? /*#__PURE__*/ React.createElement(Breadcrumb, {
|
|
240
|
-
blockId: `${blockId}_breadcrumb`,
|
|
241
|
-
basePath: basePath,
|
|
242
|
-
components: {
|
|
243
|
-
Icon,
|
|
244
|
-
Link
|
|
245
|
-
},
|
|
246
|
-
events: events,
|
|
247
|
-
methods: methods,
|
|
248
|
-
properties: mergeObjects([
|
|
249
|
-
properties.breadcrumb,
|
|
250
|
-
{
|
|
251
|
-
style: {
|
|
252
|
-
padding: '16px 0'
|
|
253
|
-
}
|
|
254
|
-
},
|
|
255
|
-
]),
|
|
256
|
-
rename: {
|
|
257
|
-
events: {
|
|
258
|
-
onClick: 'onBreadcrumbClick'
|
|
259
|
-
}
|
|
260
|
-
}
|
|
261
|
-
}) : /*#__PURE__*/ React.createElement("div", {
|
|
262
|
-
className: methods.makeCssClass(styles.noBreadcrumb)
|
|
263
|
-
}), content.content && content.content())
|
|
264
|
-
}
|
|
265
|
-
}), content.footer && /*#__PURE__*/ React.createElement(Footer, {
|
|
266
|
-
blockId: `${blockId}_footer`,
|
|
267
|
-
components: {
|
|
268
|
-
Icon,
|
|
269
|
-
Link
|
|
270
|
-
},
|
|
271
|
-
events: events,
|
|
272
|
-
properties: properties.footer,
|
|
273
|
-
content: {
|
|
274
|
-
content: ()=>content.footer()
|
|
275
|
-
}
|
|
276
|
-
}))
|
|
277
|
-
}
|
|
278
|
-
});
|
|
279
|
-
};
|
|
280
|
-
PageHeaderMenu.defaultProps = blockDefaultProps;
|
|
281
|
-
PageHeaderMenu.meta = {
|
|
282
|
-
category: 'container',
|
|
283
|
-
icons: [
|
|
284
|
-
...MobileMenu.meta.icons
|
|
285
|
-
],
|
|
286
|
-
styles: [
|
|
287
|
-
'blocks/PageHeaderMenu/style.less'
|
|
288
|
-
]
|
|
289
|
-
};
|
|
290
|
-
export default PageHeaderMenu;
|
|
@@ -1,215 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"type": "object",
|
|
3
|
-
"properties": {
|
|
4
|
-
"type": "object",
|
|
5
|
-
"additionalProperties": false,
|
|
6
|
-
"properties": {
|
|
7
|
-
"logo": {
|
|
8
|
-
"type": "object",
|
|
9
|
-
"description": "Header logo settings.",
|
|
10
|
-
"additionalProperties": false,
|
|
11
|
-
"properties": {
|
|
12
|
-
"src": {
|
|
13
|
-
"type": "string",
|
|
14
|
-
"description": "Header logo source url."
|
|
15
|
-
},
|
|
16
|
-
"srcSet": {
|
|
17
|
-
"type": "string",
|
|
18
|
-
"description": "Header logo srcSet for logo img element."
|
|
19
|
-
},
|
|
20
|
-
"size": {
|
|
21
|
-
"type": "string",
|
|
22
|
-
"description": "Header logo size for logo img element."
|
|
23
|
-
},
|
|
24
|
-
"alt": {
|
|
25
|
-
"type": "string",
|
|
26
|
-
"default": "Lowdefy",
|
|
27
|
-
"description": "Header logo alternative text."
|
|
28
|
-
},
|
|
29
|
-
"style": {
|
|
30
|
-
"type": "object",
|
|
31
|
-
"description": "Css style object to apply to logo.",
|
|
32
|
-
"docs": {
|
|
33
|
-
"displayType": "yaml"
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
},
|
|
38
|
-
"header": {
|
|
39
|
-
"type": "object",
|
|
40
|
-
"description": "Header properties.",
|
|
41
|
-
"additionalProperties": false,
|
|
42
|
-
"properties": {
|
|
43
|
-
"theme": {
|
|
44
|
-
"type": "string",
|
|
45
|
-
"enum": ["light", "dark"],
|
|
46
|
-
"default": "dark",
|
|
47
|
-
"description": "Header theme color."
|
|
48
|
-
},
|
|
49
|
-
"contentStyle": {
|
|
50
|
-
"type": "object",
|
|
51
|
-
"description": "Header content css style object.",
|
|
52
|
-
"docs": {
|
|
53
|
-
"displayType": "yaml"
|
|
54
|
-
}
|
|
55
|
-
},
|
|
56
|
-
"style": {
|
|
57
|
-
"type": "object",
|
|
58
|
-
"description": "Header css style object.",
|
|
59
|
-
"docs": {
|
|
60
|
-
"displayType": "yaml"
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
},
|
|
65
|
-
"footer": {
|
|
66
|
-
"type": "object",
|
|
67
|
-
"description": "Footer properties.",
|
|
68
|
-
"additionalProperties": false,
|
|
69
|
-
"properties": {
|
|
70
|
-
"style": {
|
|
71
|
-
"type": "object",
|
|
72
|
-
"description": "Footer css style object.",
|
|
73
|
-
"docs": {
|
|
74
|
-
"displayType": "yaml"
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
},
|
|
79
|
-
"content": {
|
|
80
|
-
"type": "object",
|
|
81
|
-
"description": "Content properties.",
|
|
82
|
-
"additionalProperties": false,
|
|
83
|
-
"properties": {
|
|
84
|
-
"style": {
|
|
85
|
-
"type": "object",
|
|
86
|
-
"description": "Content css style object.",
|
|
87
|
-
"docs": {
|
|
88
|
-
"displayType": "yaml"
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
},
|
|
93
|
-
"breadcrumb": {
|
|
94
|
-
"type": "object",
|
|
95
|
-
"description": "Breadcrumb properties.",
|
|
96
|
-
"properties": {
|
|
97
|
-
"separator": {
|
|
98
|
-
"type": "string",
|
|
99
|
-
"default": "/",
|
|
100
|
-
"description": "Use a custom separator string."
|
|
101
|
-
},
|
|
102
|
-
"list": {
|
|
103
|
-
"type": "array",
|
|
104
|
-
"description": "List of breadcrumb links.",
|
|
105
|
-
"items": {
|
|
106
|
-
"type": "string",
|
|
107
|
-
"description": "Title of the breadcrumb link."
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
},
|
|
112
|
-
"menu": {
|
|
113
|
-
"type": "object",
|
|
114
|
-
"description": "Menu properties.",
|
|
115
|
-
"properties": {
|
|
116
|
-
"theme": {
|
|
117
|
-
"type": "string",
|
|
118
|
-
"enum": ["dark", "light"],
|
|
119
|
-
"default": "dark",
|
|
120
|
-
"description": "Color theme of menu."
|
|
121
|
-
},
|
|
122
|
-
"links": {
|
|
123
|
-
"type": "array",
|
|
124
|
-
"items": {
|
|
125
|
-
"type": "object",
|
|
126
|
-
"required": ["id", "type"],
|
|
127
|
-
"properties": {
|
|
128
|
-
"id": {
|
|
129
|
-
"type": "string",
|
|
130
|
-
"description": "Menu item id."
|
|
131
|
-
},
|
|
132
|
-
"pageId": {
|
|
133
|
-
"type": "string",
|
|
134
|
-
"description": "Page to link to."
|
|
135
|
-
},
|
|
136
|
-
"properties": {
|
|
137
|
-
"type": "object",
|
|
138
|
-
"description": "properties from menu item.",
|
|
139
|
-
"properties": {
|
|
140
|
-
"title": {
|
|
141
|
-
"type": "string",
|
|
142
|
-
"description": "Menu item title."
|
|
143
|
-
},
|
|
144
|
-
"icon": {
|
|
145
|
-
"type": ["string", "object"],
|
|
146
|
-
"description": "Name of an React-Icon (See <a href='https://react-icons.github.io/react-icons/'>all icons</a>) or properties of an Icon block to customize icon on menu item.",
|
|
147
|
-
"docs": {
|
|
148
|
-
"displayType": "icon"
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
}
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
}
|
|
157
|
-
},
|
|
158
|
-
"menuLg": {
|
|
159
|
-
"type": "object",
|
|
160
|
-
"description": "Menu large screen properties. Overwrites menu properties on desktop screen sizes.",
|
|
161
|
-
"docs": {
|
|
162
|
-
"displayType": "yaml"
|
|
163
|
-
}
|
|
164
|
-
},
|
|
165
|
-
"menuMd": {
|
|
166
|
-
"type": "object",
|
|
167
|
-
"description": "Mobile menu properties. Overwrites menu properties on mobile screen sizes.",
|
|
168
|
-
"docs": {
|
|
169
|
-
"displayType": "yaml"
|
|
170
|
-
}
|
|
171
|
-
},
|
|
172
|
-
"style": {
|
|
173
|
-
"type": "object",
|
|
174
|
-
"description": "Css style object to apply to layout.",
|
|
175
|
-
"docs": {
|
|
176
|
-
"displayType": "yaml"
|
|
177
|
-
}
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
},
|
|
181
|
-
"events": {
|
|
182
|
-
"type": "object",
|
|
183
|
-
"additionalProperties": false,
|
|
184
|
-
"properties": {
|
|
185
|
-
"onBreadcrumbClick": {
|
|
186
|
-
"type": "array",
|
|
187
|
-
"description": "Trigger action when a breadcrumb item is clicked."
|
|
188
|
-
},
|
|
189
|
-
"onClose": {
|
|
190
|
-
"type": "array",
|
|
191
|
-
"description": "Trigger action when mobile menu is closed."
|
|
192
|
-
},
|
|
193
|
-
"onMenuItemClick": {
|
|
194
|
-
"type": "array",
|
|
195
|
-
"description": "Trigger action when menu item is clicked."
|
|
196
|
-
},
|
|
197
|
-
"onMenuItemSelect": {
|
|
198
|
-
"type": "array",
|
|
199
|
-
"description": "Trigger action when menu item is selected."
|
|
200
|
-
},
|
|
201
|
-
"onOpen": {
|
|
202
|
-
"type": "array",
|
|
203
|
-
"description": "Trigger action when mobile menu is open."
|
|
204
|
-
},
|
|
205
|
-
"onToggleDrawer": {
|
|
206
|
-
"type": "array",
|
|
207
|
-
"description": "Trigger action when mobile menu drawer is toggled."
|
|
208
|
-
},
|
|
209
|
-
"onToggleMenuGroup": {
|
|
210
|
-
"type": "array",
|
|
211
|
-
"description": "Trigger action when mobile menu group is opened."
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
}
|
|
215
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
Copyright 2020-2022 Lowdefy, Inc
|
|
3
|
-
|
|
4
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
you may not use this file except in compliance with the License.
|
|
6
|
-
You may obtain a copy of the License at
|
|
7
|
-
|
|
8
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
|
|
10
|
-
Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
See the License for the specific language governing permissions and
|
|
14
|
-
limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
|
|
17
|
-
@import '../Breadcrumb/style.less';
|
|
18
|
-
@import '../Content/style.less';
|
|
19
|
-
@import '../Footer/style.less';
|
|
20
|
-
@import '../Header/style.less';
|
|
21
|
-
@import '../Layout/style.less';
|
|
22
|
-
@import '../Menu/style.less';
|
|
23
|
-
@import '../MobileMenu/style.less';
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
Copyright 2020-2022 Lowdefy, Inc
|
|
3
|
-
|
|
4
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
you may not use this file except in compliance with the License.
|
|
6
|
-
You may obtain a copy of the License at
|
|
7
|
-
|
|
8
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
|
|
10
|
-
Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
See the License for the specific language governing permissions and
|
|
14
|
-
limitations under the License.
|
|
15
|
-
*/ import React from 'react';
|
|
16
|
-
import { blockDefaultProps } from '@lowdefy/block-utils';
|
|
17
|
-
import { mergeObjects } from '@lowdefy/helpers';
|
|
18
|
-
import Content from '../Content/Content.js';
|
|
19
|
-
import Footer from '../Footer/Footer.js';
|
|
20
|
-
import Header from '../Header/Header.js';
|
|
21
|
-
import Layout from '../Layout/Layout.js';
|
|
22
|
-
import Sider from '../Sider/Sider.js';
|
|
23
|
-
const PageSHCF = ({ blockId , components , events , content , properties , methods })=>/*#__PURE__*/ React.createElement(Layout, {
|
|
24
|
-
blockId: blockId,
|
|
25
|
-
components: components,
|
|
26
|
-
events: events,
|
|
27
|
-
properties: {
|
|
28
|
-
style: mergeObjects([
|
|
29
|
-
{
|
|
30
|
-
minHeight: '100vh'
|
|
31
|
-
},
|
|
32
|
-
properties.style
|
|
33
|
-
])
|
|
34
|
-
},
|
|
35
|
-
content: {
|
|
36
|
-
content: ()=>/*#__PURE__*/ React.createElement(React.Fragment, null, content.sider && /*#__PURE__*/ React.createElement(Sider, {
|
|
37
|
-
blockId: `${blockId}_sider`,
|
|
38
|
-
components: components,
|
|
39
|
-
events: events,
|
|
40
|
-
properties: properties.sider,
|
|
41
|
-
methods: methods,
|
|
42
|
-
content: {
|
|
43
|
-
content: ()=>content.sider()
|
|
44
|
-
},
|
|
45
|
-
rename: {
|
|
46
|
-
events: {
|
|
47
|
-
onClose: 'onSiderClose',
|
|
48
|
-
onOpen: 'onSiderOpen'
|
|
49
|
-
},
|
|
50
|
-
methods: {
|
|
51
|
-
toggleOpen: 'toggleSiderOpen',
|
|
52
|
-
setOpen: 'setSiderOpen'
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
}), /*#__PURE__*/ React.createElement(Layout, {
|
|
56
|
-
blockId: `${blockId}_layout`,
|
|
57
|
-
components: components,
|
|
58
|
-
events: events,
|
|
59
|
-
properties: properties.main,
|
|
60
|
-
content: {
|
|
61
|
-
content: ()=>/*#__PURE__*/ React.createElement(React.Fragment, null, content.header && /*#__PURE__*/ React.createElement(Header, {
|
|
62
|
-
blockId: `${blockId}_header`,
|
|
63
|
-
components: components,
|
|
64
|
-
events: events,
|
|
65
|
-
properties: properties.header,
|
|
66
|
-
content: {
|
|
67
|
-
content: ()=>content.header()
|
|
68
|
-
}
|
|
69
|
-
}), content.content && /*#__PURE__*/ React.createElement(Content, {
|
|
70
|
-
blockId: `${blockId}_content`,
|
|
71
|
-
components: components,
|
|
72
|
-
events: events,
|
|
73
|
-
properties: properties.content,
|
|
74
|
-
content: {
|
|
75
|
-
content: ()=>content.content()
|
|
76
|
-
}
|
|
77
|
-
}), content.footer && /*#__PURE__*/ React.createElement(Footer, {
|
|
78
|
-
blockId: `${blockId}_footer`,
|
|
79
|
-
components: components,
|
|
80
|
-
events: events,
|
|
81
|
-
properties: properties.footer,
|
|
82
|
-
content: {
|
|
83
|
-
content: ()=>content.footer()
|
|
84
|
-
}
|
|
85
|
-
}))
|
|
86
|
-
}
|
|
87
|
-
}))
|
|
88
|
-
}
|
|
89
|
-
});
|
|
90
|
-
PageSHCF.defaultProps = blockDefaultProps;
|
|
91
|
-
PageSHCF.meta = {
|
|
92
|
-
category: 'container',
|
|
93
|
-
icons: [],
|
|
94
|
-
styles: [
|
|
95
|
-
'blocks/PageSHCF/style.less'
|
|
96
|
-
]
|
|
97
|
-
};
|
|
98
|
-
export default PageSHCF;
|