conf.js 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. exports.default = void 0;
  6. var iconPrefix = 'vxe-icon--';
  7. var GlobalConfig = {
  8. size: null,
  9. // 全局尺寸
  10. zIndex: 100,
  11. // 全局 zIndex 起始值,如果项目的的 z-index 样式值过大时就需要跟随设置更大,避免被遮挡
  12. version: 0,
  13. // 版本号,对于某些带数据缓存的功能有用到,上升版本号可以用于重置数据
  14. // resizeInterval: 500,
  15. emptyCell: ' ',
  16. table: {
  17. fit: true,
  18. showHeader: true,
  19. delayHover: 250,
  20. // keepSource: false,
  21. // showOverflow: null,
  22. // showHeaderOverflow: null,
  23. // showFooterOverflow: null,
  24. // resizeInterval: 500,
  25. // size: null,
  26. // zIndex: null,
  27. // resizable: false,
  28. // autoResize: false,
  29. // stripe: false,
  30. // border: false,
  31. // round: false,
  32. // emptyRender: {
  33. // name: ''
  34. // },
  35. // radioConfig: {
  36. // trigger: 'default'
  37. // },
  38. // checkboxConfig: {
  39. // trigger: 'default'
  40. // },
  41. // tooltipConfig: {
  42. // theme: 'dark',
  43. // enterable: false
  44. // },
  45. validConfig: {
  46. showMessage: true,
  47. message: 'default'
  48. },
  49. // menuConfig: {
  50. // visibleMethod () {}
  51. // },
  52. // customConfig: {
  53. // storage: false,
  54. // checkMethod () {}
  55. // },
  56. // rowId: '_XID', // 行数据的唯一主键字段名
  57. sortConfig: {
  58. // remote: false,
  59. // trigger: 'default',
  60. // orders: ['asc', 'desc', null],
  61. // sortMethod: null,
  62. showIcon: true
  63. },
  64. filterConfig: {
  65. // remote: false,
  66. // filterMethod: null,
  67. showIcon: true
  68. },
  69. treeConfig: {
  70. children: 'children',
  71. hasChild: 'hasChild',
  72. indent: 20,
  73. showIcon: true
  74. },
  75. expandConfig: {
  76. // trigger: 'default',
  77. showIcon: true
  78. },
  79. editConfig: {
  80. // mode: 'cell',
  81. showIcon: true,
  82. showAsterisk: true
  83. },
  84. importConfig: {
  85. modes: ['insert', 'covering']
  86. },
  87. exportConfig: {
  88. modes: ['current', 'selected']
  89. },
  90. printConfig: {
  91. modes: ['current', 'selected']
  92. },
  93. mouseConfig: {
  94. extension: true
  95. },
  96. areaConfig: {
  97. selectCellByHeader: true
  98. },
  99. clipConfig: {
  100. isCopy: true,
  101. isCut: true,
  102. isPaste: true
  103. },
  104. fnrConfig: {
  105. isFind: true,
  106. isReplace: true
  107. },
  108. scrollX: {
  109. enabled: true,
  110. gt: 60 // oSize: 0
  111. },
  112. scrollY: {
  113. enabled: true,
  114. gt: 100 // oSize: 0
  115. }
  116. },
  117. export: {
  118. types: {}
  119. },
  120. icon: {
  121. // table
  122. TABLE_SORT_ASC: iconPrefix + 'caret-top',
  123. TABLE_SORT_DESC: iconPrefix + 'caret-bottom',
  124. TABLE_FILTER_NONE: iconPrefix + 'funnel',
  125. TABLE_FILTER_MATCH: iconPrefix + 'funnel',
  126. TABLE_EDIT: iconPrefix + 'edit-outline',
  127. TABLE_HELP: iconPrefix + 'question',
  128. TABLE_TREE_LOADED: iconPrefix + 'refresh roll',
  129. TABLE_TREE_OPEN: iconPrefix + 'caret-right rotate90',
  130. TABLE_TREE_CLOSE: iconPrefix + 'caret-right',
  131. TABLE_EXPAND_LOADED: iconPrefix + 'refresh roll',
  132. TABLE_EXPAND_OPEN: iconPrefix + 'arrow-right rotate90',
  133. TABLE_EXPAND_CLOSE: iconPrefix + 'arrow-right',
  134. // button
  135. BUTTON_DROPDOWN: iconPrefix + 'arrow-bottom',
  136. BUTTON_LOADING: iconPrefix + 'refresh roll',
  137. // select
  138. SELECT_OPEN: iconPrefix + 'caret-bottom rotate180',
  139. SELECT_CLOSE: iconPrefix + 'caret-bottom',
  140. // pager
  141. PAGER_JUMP_PREV: iconPrefix + 'd-arrow-left',
  142. PAGER_JUMP_NEXT: iconPrefix + 'd-arrow-right',
  143. PAGER_PREV_PAGE: iconPrefix + 'arrow-left',
  144. PAGER_NEXT_PAGE: iconPrefix + 'arrow-right',
  145. PAGER_JUMP_MORE: iconPrefix + 'more',
  146. // input
  147. INPUT_CLEAR: iconPrefix + 'close',
  148. INPUT_PWD: iconPrefix + 'eye-slash',
  149. INPUT_SHOW_PWD: iconPrefix + 'eye',
  150. INPUT_PREV_NUM: iconPrefix + 'caret-top',
  151. INPUT_NEXT_NUM: iconPrefix + 'caret-bottom',
  152. INPUT_DATE: iconPrefix + 'calendar',
  153. INPUT_SEARCH: iconPrefix + 'search',
  154. // modal
  155. MODAL_ZOOM_IN: iconPrefix + 'square',
  156. MODAL_ZOOM_OUT: iconPrefix + 'zoomout',
  157. MODAL_CLOSE: iconPrefix + 'close',
  158. MODAL_INFO: iconPrefix + 'info',
  159. MODAL_SUCCESS: iconPrefix + 'success',
  160. MODAL_WARNING: iconPrefix + 'warning',
  161. MODAL_ERROR: iconPrefix + 'error',
  162. MODAL_QUESTION: iconPrefix + 'question',
  163. MODAL_LOADING: iconPrefix + 'refresh roll',
  164. // toolbar
  165. TOOLBAR_TOOLS_REFRESH: iconPrefix + 'refresh',
  166. TOOLBAR_TOOLS_REFRESH_LOADING: iconPrefix + 'refresh roll',
  167. TOOLBAR_TOOLS_IMPORT: iconPrefix + 'upload',
  168. TOOLBAR_TOOLS_EXPORT: iconPrefix + 'download',
  169. TOOLBAR_TOOLS_PRINT: iconPrefix + 'print',
  170. TOOLBAR_TOOLS_ZOOM_IN: iconPrefix + 'zoomin',
  171. TOOLBAR_TOOLS_ZOOM_OUT: iconPrefix + 'zoomout',
  172. TOOLBAR_TOOLS_CUSTOM: iconPrefix + 'menu',
  173. // form
  174. FORM_PREFIX: iconPrefix + 'question',
  175. FORM_SUFFIX: iconPrefix + 'question',
  176. FORM_FOLDING: iconPrefix + 'arrow-top rotate180',
  177. FORM_UNFOLDING: iconPrefix + 'arrow-top'
  178. },
  179. grid: {
  180. // size: null,
  181. // zoomConfig: {
  182. // escRestore: true
  183. // },
  184. formConfig: {
  185. enabled: true
  186. },
  187. pagerConfig: {
  188. enabled: true // perfect: false
  189. },
  190. toolbarConfig: {
  191. enabled: true // perfect: false
  192. },
  193. proxyConfig: {
  194. enabled: true,
  195. autoLoad: true,
  196. message: true,
  197. props: {
  198. list: null,
  199. result: 'result',
  200. total: 'page.total',
  201. message: 'message'
  202. } // beforeItem: null,
  203. // beforeColumn: null,
  204. // beforeQuery: null,
  205. // afterQuery: null,
  206. // beforeDelete: null,
  207. // afterDelete: null,
  208. // beforeSave: null,
  209. // afterSave: null
  210. }
  211. },
  212. tooltip: {
  213. // size: null,
  214. trigger: 'hover',
  215. theme: 'dark',
  216. leaveDelay: 300
  217. },
  218. pager: {// size: null,
  219. // autoHidden: false,
  220. // perfect: true,
  221. // pageSize: 10,
  222. // pagerCount: 7,
  223. // pageSizes: [10, 15, 20, 50, 100],
  224. // layouts: ['PrevJump', 'PrevPage', 'Jump', 'PageCount', 'NextPage', 'NextJump', 'Sizes', 'Total']
  225. },
  226. form: {
  227. // preventSubmit: false,
  228. validConfig: {
  229. showMessage: true,
  230. autoPos: true
  231. },
  232. // size: null,
  233. // colon: false,
  234. titleAsterisk: true
  235. },
  236. input: {
  237. // size: null,
  238. // transfer: false
  239. // parseFormat: 'yyyy-MM-dd HH:mm:ss.SSS',
  240. // labelFormat: '',
  241. // valueFormat: '',
  242. minDate: new Date(1900, 0, 1),
  243. maxDate: new Date(2100, 0, 1),
  244. startWeek: 1,
  245. digits: 2,
  246. controls: true
  247. },
  248. textarea: {// size: null,
  249. // autosize: {
  250. // minRows: 1,
  251. // maxRows: 10
  252. // }
  253. },
  254. select: {
  255. // size: null,
  256. // transfer: false,
  257. multiCharOverflow: 8
  258. },
  259. toolbar: {// size: null,
  260. // import: {
  261. // mode: 'covering'
  262. // },
  263. // export: {
  264. // types: ['csv', 'html', 'xml', 'txt']
  265. // },
  266. // custom: {
  267. // isFooter: true
  268. // },
  269. // buttons: []
  270. },
  271. button: {// size: null,
  272. // transfer: false
  273. },
  274. radio: {// size: null
  275. },
  276. checkbox: {// size: null
  277. },
  278. switch: {// size: null
  279. },
  280. modal: {
  281. // size: null,
  282. top: 15,
  283. showHeader: true,
  284. minWidth: 340,
  285. minHeight: 140,
  286. lockView: true,
  287. mask: true,
  288. duration: 3000,
  289. marginSize: 0,
  290. dblclickZoom: true,
  291. showTitleOverflow: true,
  292. animat: true,
  293. // storage: false,
  294. storageKey: 'VXE_MODAL_POSITION'
  295. },
  296. list: {
  297. // size: null,
  298. scrollY: {
  299. enabled: true,
  300. gt: 100 // oSize: 0
  301. }
  302. },
  303. i18n: function i18n(key) {
  304. return key;
  305. }
  306. };
  307. var _default = GlobalConfig;
  308. exports.default = _default;