@jetlinks-web/components 2.0.2-2 → 2.0.2-4

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.
Files changed (225) hide show
  1. package/es/AMap/Map.js +124 -0
  2. package/es/AMap/index.js +2 -0
  3. package/es/AMap/util.js +56 -0
  4. package/es/BadgeStatus/Badge.js +54 -0
  5. package/es/BadgeStatus/color.js +21 -0
  6. package/es/BadgeStatus/index.js +3 -0
  7. package/es/CardSelect/CardSelect.js +123 -0
  8. package/es/CardSelect/index.js +2 -0
  9. package/es/CheckButton/CheckButton.js +121 -0
  10. package/es/CheckButton/index.js +2 -0
  11. package/es/ConfigProvider/context.js +12 -0
  12. package/es/ConfigProvider/index.js +31 -0
  13. package/es/Echarts/Echarts.js +47 -0
  14. package/es/Echarts/index.js +2 -0
  15. package/es/Ellipsis/Ellipsis.js +189 -0
  16. package/es/Ellipsis/index.js +2 -0
  17. package/es/Empty/Empty.js +56 -0
  18. package/es/Empty/image.js +2 -0
  19. package/es/Empty/index.js +2 -0
  20. package/es/FullPage/FullPage.js +31 -0
  21. package/es/FullPage/index.js +2 -0
  22. package/es/Icon/icon.js +43 -0
  23. package/{src/Icon/index.ts → es/Icon/index.js} +2 -3
  24. package/es/MonacoEditor/Monaco.js +238 -0
  25. package/es/MonacoEditor/index.js +2 -0
  26. package/es/PermissionButton/index.js +117 -0
  27. package/es/ProLayout/Basic/BasicLayout.js +255 -0
  28. package/es/ProLayout/Basic/Header.js +93 -0
  29. package/es/ProLayout/PageContainer/index.js +318 -0
  30. package/es/ProLayout/PageContainer/typings.js +1 -0
  31. package/es/ProLayout/RouteContext.js +22 -0
  32. package/es/ProLayout/SiderMenu/BaseMenu.js +262 -0
  33. package/es/ProLayout/SiderMenu/SiderMenu.js +258 -0
  34. package/es/ProLayout/SiderMenu/index.js +2 -0
  35. package/es/ProLayout/SiderMenu/typings.js +1 -0
  36. package/es/ProLayout/TopHeader/index.js +155 -0
  37. package/es/ProLayout/defaultSettings.js +66 -0
  38. package/{src/ProLayout/index.ts → es/ProLayout/index.js} +4 -6
  39. package/{src → es}/ProLayout/style/default.less +4 -4
  40. package/es/ProLayout/style/index.js +1 -0
  41. package/es/ProLayout/typings.js +1 -0
  42. package/es/ProLayout/util.js +61 -0
  43. package/es/ProTable/index.js +406 -0
  44. package/es/ProTable/proTableTypes.js +11 -0
  45. package/es/ProTable/style/index.css +65 -0
  46. package/es/ProTable/style/index.js +1 -0
  47. package/es/Scrollbar/Bar.js +114 -0
  48. package/es/Scrollbar/Scrollbar.js +100 -0
  49. package/es/Scrollbar/Thumb.js +10 -0
  50. package/es/Scrollbar/constants.js +1 -0
  51. package/es/Scrollbar/index.js +2 -0
  52. package/es/Scrollbar/util.js +30 -0
  53. package/es/Search/Advanced/History.js +183 -0
  54. package/es/Search/Advanced/SaveHistory.js +153 -0
  55. package/es/Search/Advanced/index.js +520 -0
  56. package/es/Search/Item.js +497 -0
  57. package/es/Search/Search.js +249 -0
  58. package/es/Search/hooks/index.js +1 -0
  59. package/es/Search/hooks/useSearchItems.js +40 -0
  60. package/es/Search/index.js +4 -0
  61. package/es/Search/setting.js +91 -0
  62. package/es/Search/typing.js +1 -0
  63. package/es/Search/util.js +234 -0
  64. package/es/ValueItem/ValueItem.js +233 -0
  65. package/es/ValueItem/index.js +2 -0
  66. package/es/ValueItem/util.js +16 -0
  67. package/es/index.js +24 -0
  68. package/es/style/index.js +3 -0
  69. package/es/style/variable.css +0 -0
  70. package/{src → es}/style/variable.less +0 -2
  71. package/lib/AMap/Map.js +124 -0
  72. package/lib/AMap/index.js +9 -0
  73. package/lib/AMap/util.js +62 -0
  74. package/lib/BadgeStatus/Badge.js +54 -0
  75. package/lib/BadgeStatus/color.js +27 -0
  76. package/lib/BadgeStatus/index.js +22 -0
  77. package/lib/CardSelect/CardSelect.js +123 -0
  78. package/lib/CardSelect/index.js +9 -0
  79. package/lib/CheckButton/CheckButton.js +121 -0
  80. package/lib/CheckButton/index.js +9 -0
  81. package/lib/ConfigProvider/context.js +19 -0
  82. package/lib/ConfigProvider/index.js +37 -0
  83. package/lib/Echarts/Echarts.js +47 -0
  84. package/lib/Echarts/index.js +9 -0
  85. package/lib/Ellipsis/Ellipsis.js +189 -0
  86. package/lib/Ellipsis/index.js +9 -0
  87. package/lib/Empty/Empty.js +56 -0
  88. package/lib/Empty/image.js +8 -0
  89. package/lib/Empty/index.js +9 -0
  90. package/lib/FullPage/FullPage.js +31 -0
  91. package/lib/FullPage/index.js +9 -0
  92. package/lib/Icon/icon.js +52 -0
  93. package/lib/Icon/index.js +9 -0
  94. package/lib/MonacoEditor/Monaco.js +238 -0
  95. package/lib/MonacoEditor/index.js +9 -0
  96. package/lib/PermissionButton/index.js +124 -0
  97. package/lib/ProLayout/Basic/BasicLayout.js +264 -0
  98. package/lib/ProLayout/Basic/BasicLayout.less +66 -0
  99. package/lib/ProLayout/Basic/Header.js +99 -0
  100. package/lib/ProLayout/Basic/Header.less +8 -0
  101. package/lib/ProLayout/PageContainer/index.js +323 -0
  102. package/lib/ProLayout/PageContainer/index.less +103 -0
  103. package/lib/ProLayout/PageContainer/typings.js +5 -0
  104. package/lib/ProLayout/RouteContext.js +28 -0
  105. package/lib/ProLayout/SiderMenu/BaseMenu.js +268 -0
  106. package/lib/ProLayout/SiderMenu/SiderMenu.js +267 -0
  107. package/lib/ProLayout/SiderMenu/index.js +20 -0
  108. package/lib/ProLayout/SiderMenu/index.less +212 -0
  109. package/lib/ProLayout/SiderMenu/typings.js +5 -0
  110. package/lib/ProLayout/TopHeader/index.js +161 -0
  111. package/lib/ProLayout/TopHeader/index.less +174 -0
  112. package/lib/ProLayout/defaultSettings.js +72 -0
  113. package/lib/ProLayout/index.js +16 -0
  114. package/lib/ProLayout/style/default.less +4 -0
  115. package/lib/ProLayout/style/index.js +3 -0
  116. package/lib/ProLayout/style/style.less +7 -0
  117. package/lib/ProLayout/typings.js +5 -0
  118. package/lib/ProLayout/util.js +72 -0
  119. package/lib/ProTable/index.js +412 -0
  120. package/lib/ProTable/proTableTypes.js +17 -0
  121. package/lib/ProTable/style/index.css +65 -0
  122. package/lib/ProTable/style/index.js +3 -0
  123. package/lib/ProTable/style/index.less +92 -0
  124. package/lib/Scrollbar/Bar.js +114 -0
  125. package/{src/Scrollbar/scrollbar.ts → lib/Scrollbar/Scrollbar.js} +106 -108
  126. package/lib/Scrollbar/Thumb.js +16 -0
  127. package/lib/Scrollbar/constants.js +7 -0
  128. package/lib/Scrollbar/index.js +9 -0
  129. package/lib/Scrollbar/util.js +37 -0
  130. package/lib/Search/Advanced/History.js +183 -0
  131. package/lib/Search/Advanced/SaveHistory.js +153 -0
  132. package/lib/Search/Advanced/index.js +520 -0
  133. package/lib/Search/Item.js +497 -0
  134. package/lib/Search/Search.js +249 -0
  135. package/lib/Search/hooks/index.js +16 -0
  136. package/lib/Search/hooks/useSearchItems.js +47 -0
  137. package/lib/Search/index.js +16 -0
  138. package/lib/Search/setting.js +97 -0
  139. package/lib/Search/typing.js +5 -0
  140. package/lib/Search/util.js +241 -0
  141. package/lib/ValueItem/ValueItem.js +233 -0
  142. package/lib/ValueItem/index.js +9 -0
  143. package/lib/ValueItem/util.js +22 -0
  144. package/lib/index.js +158 -0
  145. package/lib/style/components.less +1 -0
  146. package/lib/style/index.js +4 -0
  147. package/lib/style/variable.css +0 -0
  148. package/lib/style/variable.less +2 -0
  149. package/package.json +121 -12
  150. package/index.ts +0 -64
  151. package/src/AMap/Map.vue +0 -110
  152. package/src/AMap/index.ts +0 -1
  153. package/src/AMap/util.ts +0 -56
  154. package/src/BadgeStatus/Badge.vue +0 -41
  155. package/src/BadgeStatus/color.ts +0 -25
  156. package/src/BadgeStatus/index.ts +0 -4
  157. package/src/CardSelect/CardSelect.vue +0 -136
  158. package/src/CardSelect/index.ts +0 -3
  159. package/src/CheckButton/CheckButton.vue +0 -146
  160. package/src/CheckButton/index.md +0 -27
  161. package/src/CheckButton/index.ts +0 -3
  162. package/src/ConfigProvider/context.ts +0 -17
  163. package/src/ConfigProvider/index.tsx +0 -40
  164. package/src/Echarts/Echarts.vue +0 -43
  165. package/src/Echarts/index.ts +0 -3
  166. package/src/Ellipsis/Ellipsis.vue +0 -182
  167. package/src/Ellipsis/index.ts +0 -3
  168. package/src/Empty/Empty.vue +0 -43
  169. package/src/Empty/image.ts +0 -3
  170. package/src/Empty/index.ts +0 -2
  171. package/src/FullPage/FullPage.vue +0 -30
  172. package/src/FullPage/index.ts +0 -3
  173. package/src/Icon/icon.tsx +0 -40
  174. package/src/MonacoEditor/Monaco.vue +0 -242
  175. package/src/MonacoEditor/index.md +0 -26
  176. package/src/MonacoEditor/index.ts +0 -2
  177. package/src/PermissionButton/index.tsx +0 -110
  178. package/src/ProLayout/Basic/BasicLayout.tsx +0 -395
  179. package/src/ProLayout/Basic/Header.tsx +0 -115
  180. package/src/ProLayout/PageContainer/index.tsx +0 -441
  181. package/src/ProLayout/PageContainer/typings.ts +0 -56
  182. package/src/ProLayout/RouteContext.ts +0 -87
  183. package/src/ProLayout/SiderMenu/BaseMenu.tsx +0 -296
  184. package/src/ProLayout/SiderMenu/SiderMenu.tsx +0 -320
  185. package/src/ProLayout/SiderMenu/index.ts +0 -2
  186. package/src/ProLayout/SiderMenu/typings.ts +0 -49
  187. package/src/ProLayout/TopHeader/index.tsx +0 -210
  188. package/src/ProLayout/defaultSettings.ts +0 -106
  189. package/src/ProLayout/style/index.ts +0 -1
  190. package/src/ProLayout/typings.ts +0 -87
  191. package/src/ProLayout/util.ts +0 -64
  192. package/src/ProTable/index.md +0 -53
  193. package/src/ProTable/index.tsx +0 -551
  194. package/src/ProTable/proTableTypes.ts +0 -70
  195. package/src/ProTable/style/index.ts +0 -1
  196. package/src/Scrollbar/Bar.vue +0 -75
  197. package/src/Scrollbar/Scrollbar.vue +0 -260
  198. package/src/Scrollbar/Thumb.vue +0 -163
  199. package/src/Scrollbar/constants.ts +0 -10
  200. package/src/Scrollbar/index.ts +0 -4
  201. package/src/Scrollbar/thumb.ts +0 -16
  202. package/src/Scrollbar/util.ts +0 -38
  203. package/src/Search/Advanced/History.vue +0 -140
  204. package/src/Search/Advanced/SaveHistory.vue +0 -108
  205. package/src/Search/Advanced/index.vue +0 -435
  206. package/src/Search/Item.vue +0 -525
  207. package/src/Search/Search.vue +0 -398
  208. package/src/Search/hooks/index.ts +0 -1
  209. package/src/Search/hooks/useSearchItems.ts +0 -68
  210. package/src/Search/index.md +0 -57
  211. package/src/Search/index.ts +0 -5
  212. package/src/Search/setting.ts +0 -55
  213. package/src/Search/typing.ts +0 -76
  214. package/src/Search/util.ts +0 -263
  215. package/src/ValueItem/ValueItem.vue +0 -192
  216. package/src/ValueItem/index.ts +0 -3
  217. package/src/ValueItem/util.ts +0 -16
  218. package/src/style/index.ts +0 -3
  219. /package/{src → es}/ProLayout/Basic/BasicLayout.less +0 -0
  220. /package/{src → es}/ProLayout/Basic/Header.less +0 -0
  221. /package/{src → es}/ProLayout/PageContainer/index.less +0 -0
  222. /package/{src → es}/ProLayout/SiderMenu/index.less +0 -0
  223. /package/{src → es}/ProLayout/TopHeader/index.less +0 -0
  224. /package/{src → es}/ProLayout/style/style.less +0 -0
  225. /package/{src → es}/ProTable/style/index.less +0 -0
@@ -0,0 +1,323 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.pageHeaderTabConfig = exports.pageContainerProps = exports.default = void 0;
8
+ var _vue = require("vue");
9
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
10
+ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
11
+ var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
12
+ var _type = require("ant-design-vue/es/_util/type");
13
+ var _antDesignVue = require("ant-design-vue");
14
+ var _pageHeader = require("ant-design-vue/es/page-header");
15
+ var _RouteContext = require("../RouteContext");
16
+ var _util = require("../util");
17
+ require("./index.less");
18
+ var _excluded = ["title", "tabList", "tabActiveKey", "content", "pageHeaderRender", "header", "extraContent", "prefixedClassName", "prefixCls", "fixedHeader", "showBack"];
19
+ var pageHeaderTabConfig = exports.pageHeaderTabConfig = {
20
+ /**
21
+ * @name tabs 的列表
22
+ */
23
+ tabList: {
24
+ type: [Object, Function, Array],
25
+ default: function _default() {
26
+ return undefined;
27
+ }
28
+ },
29
+ /**
30
+ * @name 当前选中 tab 的 key
31
+ */
32
+ tabActiveKey: String,
33
+ /**
34
+ * @name tab 上多余的区域
35
+ */
36
+ tabBarExtraContent: {
37
+ type: [Object, Function],
38
+ default: function _default() {
39
+ return undefined;
40
+ }
41
+ },
42
+ /**
43
+ * @name tabs 的其他配置
44
+ */
45
+ tabProps: {
46
+ type: Object,
47
+ default: function _default() {
48
+ return undefined;
49
+ }
50
+ },
51
+ /**
52
+ * @name 固定 PageHeader 到页面顶部
53
+ */
54
+ fixedHeader: Boolean,
55
+ // events
56
+ onTabChange: Function,
57
+ pure: Boolean
58
+ };
59
+ var pageContainerProps = exports.pageContainerProps = (0, _objectSpread2.default)((0, _objectSpread2.default)((0, _objectSpread2.default)({}, pageHeaderTabConfig), _pageHeader.pageHeaderProps), {}, {
60
+ prefixCls: {
61
+ type: String,
62
+ default: 'ant-pro'
63
+ },
64
+ title: {
65
+ type: [Object, String, Boolean, Function],
66
+ default: function _default() {
67
+ return null;
68
+ }
69
+ },
70
+ subTitle: {
71
+ type: [Object, String, Boolean, Function],
72
+ default: function _default() {
73
+ return null;
74
+ }
75
+ },
76
+ content: {
77
+ type: [Object, String, Boolean, Function],
78
+ default: function _default() {
79
+ return null;
80
+ }
81
+ },
82
+ extra: {
83
+ type: [Object, String, Boolean, Function],
84
+ default: function _default() {
85
+ return null;
86
+ }
87
+ },
88
+ extraContent: {
89
+ type: [Object, String, Boolean, Function],
90
+ default: function _default() {
91
+ return null;
92
+ }
93
+ },
94
+ header: {
95
+ type: [Object, String, Boolean, Function],
96
+ default: function _default() {
97
+ return null;
98
+ }
99
+ },
100
+ pageHeaderRender: {
101
+ type: [Object, Function, Boolean],
102
+ default: function _default() {
103
+ return undefined;
104
+ }
105
+ },
106
+ affixProps: {
107
+ type: [Object, Function]
108
+ },
109
+ ghost: {
110
+ type: Boolean,
111
+ default: function _default() {
112
+ return false;
113
+ }
114
+ },
115
+ loading: {
116
+ type: Boolean,
117
+ default: function _default() {
118
+ return undefined;
119
+ }
120
+ },
121
+ childrenFullHeight: {
122
+ type: Boolean,
123
+ default: function _default() {
124
+ return true;
125
+ }
126
+ },
127
+ pure: {
128
+ type: Boolean,
129
+ default: false
130
+ },
131
+ showBack: {
132
+ type: Boolean,
133
+ default: false
134
+ },
135
+ contentStyle: {
136
+ type: Object,
137
+ default: function _default() {
138
+ return {};
139
+ }
140
+ }
141
+ });
142
+ var renderFooter = function renderFooter(props) {
143
+ var tabList = props.tabList,
144
+ tabActiveKey = props.tabActiveKey,
145
+ onTabChange = props.onTabChange,
146
+ tabBarExtraContent = props.tabBarExtraContent,
147
+ tabProps = props.tabProps;
148
+ var tabPane = function tabPane(item) {
149
+ return (0, _vue.createVNode)("span", {
150
+ "class": item.class || "tab-pane-".concat(item.key)
151
+ }, [item.tab]);
152
+ };
153
+ if (tabList && tabList.length) {
154
+ return (0, _vue.createVNode)(_antDesignVue.Tabs, (0, _objectSpread2.default)({
155
+ "class": "page-container-tabs",
156
+ "activeKey": tabActiveKey,
157
+ "onChange": function onChange(key) {
158
+ if (onTabChange) {
159
+ onTabChange(key);
160
+ }
161
+ },
162
+ "tabBarExtraContent": tabBarExtraContent
163
+ }, tabProps), {
164
+ default: function _default() {
165
+ return [tabList.map(function (item) {
166
+ return (0, _vue.createVNode)(_antDesignVue.Tabs.TabPane, (0, _objectSpread2.default)((0, _objectSpread2.default)({}, item), {}, {
167
+ "tab": tabPane(item),
168
+ "key": item.key
169
+ }), null);
170
+ })];
171
+ }
172
+ });
173
+ }
174
+ return null;
175
+ };
176
+ var renderPageHeader = function renderPageHeader(content, extraContent, prefixedClassName) {
177
+ if (!content && !extraContent) {
178
+ return null;
179
+ }
180
+ return (0, _vue.createVNode)("div", {
181
+ "class": "".concat(prefixedClassName, "-detail")
182
+ }, [(0, _vue.createVNode)("div", {
183
+ "class": "".concat(prefixedClassName, "-main")
184
+ }, [(0, _vue.createVNode)("div", {
185
+ "class": "".concat(prefixedClassName, "-row")
186
+ }, [content && (0, _vue.createVNode)("div", {
187
+ "class": "".concat(prefixedClassName, "-content")
188
+ }, [
189
+ // @ts-ignore
190
+ typeof content === 'function' && content() || content]), extraContent && (0, _vue.createVNode)("div", {
191
+ "class": "".concat(prefixedClassName, "-extraContent")
192
+ }, [
193
+ // @ts-ignore
194
+ typeof extraContent === 'function' && extraContent() || extraContent])])])]);
195
+ };
196
+ var ProPageHeader = function ProPageHeader(props) {
197
+ var title = props.title,
198
+ tabList = props.tabList,
199
+ tabActiveKey = props.tabActiveKey,
200
+ content = props.content,
201
+ pageHeaderRender = props.pageHeaderRender,
202
+ header = props.header,
203
+ extraContent = props.extraContent,
204
+ prefixedClassName = props.prefixedClassName,
205
+ prefixCls = props.prefixCls,
206
+ _ = props.fixedHeader,
207
+ showBack = props.showBack,
208
+ restProps = (0, _objectWithoutProperties2.default)(props, _excluded);
209
+ var value = (0, _RouteContext.useRouteContext)();
210
+ if (pageHeaderRender === false) {
211
+ return null;
212
+ }
213
+ if (pageHeaderRender) {
214
+ return pageHeaderRender((0, _objectSpread2.default)({}, props));
215
+ }
216
+ var pageHeaderTitle = title;
217
+ if (!title && title !== false) {
218
+ pageHeaderTitle = value.title;
219
+ }
220
+ var unrefBreadcrumb = (0, _vue.unref)(value.breadcrumb || {});
221
+ var breadcrumb = props.breadcrumb || (0, _objectSpread2.default)((0, _objectSpread2.default)({}, unrefBreadcrumb), {}, {
222
+ routes: unrefBreadcrumb.routes,
223
+ itemRender: unrefBreadcrumb.itemRender
224
+ });
225
+ var backProps = {};
226
+ if (showBack) {
227
+ // @ts-ignore
228
+ backProps.backIcon = (0, _vue.createVNode)(_antDesignVue.Button, null, {
229
+ default: function _default() {
230
+ return [(0, _vue.createTextVNode)("\u8FD4\u56DE")];
231
+ }
232
+ });
233
+ backProps.onBack = function () {
234
+ var _value$back;
235
+ (_value$back = value.back) === null || _value$back === void 0 ? void 0 : _value$back.call(value);
236
+ };
237
+ }
238
+ return (0, _vue.createVNode)("div", {
239
+ "class": "".concat(prefixedClassName, "-wrap")
240
+ }, [(0, _vue.createVNode)(_antDesignVue.PageHeader, (0, _objectSpread2.default)((0, _objectSpread2.default)((0, _objectSpread2.default)({}, backProps), restProps), {}, {
241
+ "title": pageHeaderTitle,
242
+ "breadcrumb": breadcrumb,
243
+ "footer": renderFooter((0, _objectSpread2.default)((0, _objectSpread2.default)({}, restProps), {}, {
244
+ tabList: tabList,
245
+ tabActiveKey: tabActiveKey
246
+ })),
247
+ "prefixCls": prefixCls
248
+ }), {
249
+ default: function _default() {
250
+ return [header || renderPageHeader(content, extraContent, prefixedClassName)];
251
+ }
252
+ })]);
253
+ };
254
+ var PageContainer = (0, _vue.defineComponent)({
255
+ name: 'JPageContainer',
256
+ inheritAttrs: false,
257
+ props: pageContainerProps,
258
+ setup: function setup(props, _ref) {
259
+ var slots = _ref.slots,
260
+ attrs = _ref.attrs;
261
+ var _toRefs = (0, _vue.toRefs)(props),
262
+ loading = _toRefs.loading,
263
+ affixProps = _toRefs.affixProps,
264
+ ghost = _toRefs.ghost,
265
+ childrenFullHeight = _toRefs.childrenFullHeight;
266
+ var value = (0, _RouteContext.useRouteContext)();
267
+ var getPrefixCls = value.getPrefixCls;
268
+ var prefixCls = props.prefixCls || getPrefixCls();
269
+ var prefixedClassName = (0, _vue.computed)(function () {
270
+ return "".concat(prefixCls, "-page-container");
271
+ });
272
+ var classNames = (0, _vue.computed)(function () {
273
+ return (0, _defineProperty2.default)((0, _defineProperty2.default)({}, prefixedClassName.value, true), "".concat(prefixCls, "-page-container-ghost"), ghost.value);
274
+ });
275
+ var headerDom = (0, _vue.computed)(function () {
276
+ // const tags = getSlotVNode<DefaultPropRender>(slots, props, 'tags');
277
+ var headerContent = (0, _util.getSlotVNode)(slots, props, 'content');
278
+ var extra = (0, _util.getSlotVNode)(slots, props, 'extra');
279
+ var extraContent = (0, _util.getSlotVNode)(slots, props, 'extraContent');
280
+ var subTitle = (0, _util.getSlotVNode)(slots, props, 'subTitle');
281
+ var title = (0, _util.getSlotVNode)(slots, props, 'title');
282
+ // @ts-ignore
283
+ return (0, _vue.createVNode)(ProPageHeader, (0, _objectSpread2.default)((0, _objectSpread2.default)({}, props), {}, {
284
+ "prefixCls": undefined,
285
+ "prefixedClassName": prefixedClassName.value,
286
+ "ghost": ghost.value,
287
+ "title": title,
288
+ "subTitle": subTitle,
289
+ "content": headerContent,
290
+ "extra": extra,
291
+ "extraContent": extraContent
292
+ }), null);
293
+ });
294
+ return function () {
295
+ var _slots$default;
296
+ var fixedHeader = props.fixedHeader,
297
+ pure = props.pure;
298
+ return (0, _vue.createVNode)(_vue.Fragment, null, [pure ? (0, _vue.createVNode)("div", {
299
+ "class": classNames.value
300
+ }, [(_slots$default = slots.default) === null || _slots$default === void 0 ? void 0 : _slots$default.call(slots)]) : (0, _vue.createVNode)("div", {
301
+ "class": classNames.value,
302
+ "style": (0, _objectSpread2.default)({}, attrs.style || {})
303
+ }, [fixedHeader && headerDom.value ? (0, _vue.createVNode)(_antDesignVue.Affix, (0, _objectSpread2.default)((0, _objectSpread2.default)({}, affixProps.value), {}, {
304
+ "offsetTop": value.hasHeader && value.fixedHeader ? value.headerHeight : 0
305
+ }), {
306
+ default: function _default() {
307
+ return [headerDom.value];
308
+ }
309
+ }) : headerDom.value, (0, _vue.createVNode)("div", {
310
+ "class": "".concat(prefixedClassName.value, "-grid-content")
311
+ }, [loading.value ? (0, _vue.createVNode)(_antDesignVue.Spin, null, null) : slots.default ? (0, _vue.createVNode)("div", null, [(0, _vue.createVNode)("div", {
312
+ "class": "".concat(prefixedClassName.value, "-children-content ").concat(childrenFullHeight.value ? 'children-full-height' : ''),
313
+ "style": (0, _objectSpread2.default)({}, props.contentStyle || {})
314
+ }, [slots.default()]), value.hasFooterToolbar && (0, _vue.createVNode)("div", {
315
+ "style": {
316
+ height: 48,
317
+ marginTop: 24
318
+ }
319
+ }, null)]) : null])])]);
320
+ };
321
+ }
322
+ });
323
+ var _default2 = exports.default = (0, _type.withInstall)(PageContainer);
@@ -0,0 +1,103 @@
1
+ @import '../style/default.less';
2
+
3
+ @pro-layout-page-container: ~'@{ant-prefix}-pro-page-container';
4
+
5
+ .@{pro-layout-page-container}-children-content {
6
+ margin: 24px 24px 0;
7
+ }
8
+
9
+ .@{pro-layout-page-container} {
10
+ &-warp {
11
+ background-color: @component-background;
12
+ .@{ant-prefix}-tabs-bar {
13
+ margin: 0;
14
+ }
15
+ }
16
+ &-ghost {
17
+ .@{pro-layout-page-container}-warp {
18
+ background-color: @component-background;
19
+ }
20
+ }
21
+ }
22
+
23
+ .@{pro-layout-page-container}-main {
24
+ .@{pro-layout-page-container}-detail {
25
+ display: flex;
26
+ }
27
+
28
+ .@{pro-layout-page-container}-row {
29
+ display: flex;
30
+ width: 100%;
31
+ }
32
+
33
+ .@{pro-layout-page-container}-title-content {
34
+ margin-bottom: 16px;
35
+ }
36
+
37
+ .@{pro-layout-page-container}-title,
38
+ .@{pro-layout-page-container}-content {
39
+ flex: auto;
40
+ }
41
+
42
+ .@{pro-layout-page-container}-extraContent,
43
+ .@{pro-layout-page-container}-main {
44
+ flex: 0 1 auto;
45
+ }
46
+
47
+ .@{pro-layout-page-container}-main {
48
+ width: 100%;
49
+ }
50
+
51
+ .@{pro-layout-page-container}-title {
52
+ margin-bottom: 16px;
53
+ }
54
+
55
+ .@{pro-layout-page-container}-logo {
56
+ margin-bottom: 16px;
57
+ }
58
+
59
+ .@{pro-layout-page-container}-extraContent {
60
+ min-width: 242px;
61
+ margin-left: 88px;
62
+ text-align: right;
63
+ }
64
+ }
65
+
66
+ @media screen and (max-width: @screen-xl) {
67
+ .@{pro-layout-page-container}-main {
68
+ .@{pro-layout-page-container}-extraContent {
69
+ margin-left: 44px;
70
+ }
71
+ }
72
+ }
73
+
74
+ @media screen and (max-width: @screen-lg) {
75
+ .@{pro-layout-page-container}-main {
76
+ .@{pro-layout-page-container}-extraContent {
77
+ margin-left: 20px;
78
+ }
79
+ }
80
+ }
81
+
82
+ @media screen and (max-width: @screen-md) {
83
+ .@{pro-layout-page-container}-main {
84
+ .@{pro-layout-page-container}-row {
85
+ display: block;
86
+ }
87
+
88
+ .@{pro-layout-page-container}-action,
89
+ .@{pro-layout-page-container}-extraContent {
90
+ margin-left: 0;
91
+ text-align: left;
92
+ }
93
+ }
94
+ }
95
+
96
+ @media screen and (max-width: @screen-sm) {
97
+ .@{pro-layout-page-container}-detail {
98
+ display: block;
99
+ }
100
+ .@{pro-layout-page-container}-extraContent {
101
+ margin-left: 0;
102
+ }
103
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
@@ -0,0 +1,28 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.useRouteContext = exports.routeContextInjectKey = exports.provideRouteContext = exports.getPrefixCls = exports.defaultRouteContext = exports.defaultPrefixCls = void 0;
7
+ var _vue = require("vue");
8
+ var _hooks = require("@jetlinks-web/hooks");
9
+ var defaultPrefixCls = exports.defaultPrefixCls = 'ant-pro';
10
+ var getPrefixCls = exports.getPrefixCls = function getPrefixCls(suffixCls, customizePrefixCls) {
11
+ if (customizePrefixCls) return customizePrefixCls;
12
+ return suffixCls ? "".concat(defaultPrefixCls, "-").concat(suffixCls) : defaultPrefixCls;
13
+ };
14
+ var defaultRouteContext = exports.defaultRouteContext = (0, _vue.reactive)({
15
+ getPrefixCls: getPrefixCls,
16
+ locale: function locale(t) {
17
+ return t;
18
+ },
19
+ contentWidth: 'Fluid',
20
+ hasFooterToolbar: false
21
+ });
22
+ var routeContextInjectKey = exports.routeContextInjectKey = Symbol('jetlinks-route-context');
23
+ var provideRouteContext = exports.provideRouteContext = function provideRouteContext(value) {
24
+ (0, _vue.provide)(routeContextInjectKey, value);
25
+ };
26
+ var useRouteContext = exports.useRouteContext = function useRouteContext() {
27
+ return (0, _hooks.useContext)(routeContextInjectKey, defaultRouteContext);
28
+ };