新增前端vue

This commit is contained in:
2025-11-26 13:55:01 +08:00
parent ae391f1b94
commit ffd5a6ad66
781 changed files with 83348 additions and 0 deletions

View File

@@ -0,0 +1,46 @@
// Used to configure the general configuration of some components without modifying the components
import type { SorterResult } from '../components/Table';
export default {
// basic-table setting
table: {
// Form interface request general configuration
// support xxx.xxx.xxx
fetchSetting: {
// The field name of the current page passed to the background
pageField: 'pageNo',
// The number field name of each page displayed in the background
sizeField: 'pageSize',
// Field name of the form data returned by the interface
listField: 'list',
// Total number of tables returned by the interface field name
totalField: 'count',
},
// Number of pages that can be selected
pageSizeOptions: ['10', '20', '50', '80', '100'],
// Default display quantity on one page
defaultPageSize: 20,
// Default Size
defaultSize: 'middle',
// Custom general sort function
defaultSortFn: (sortInfo: SorterResult) => {
const { order, columnKey } = sortInfo;
if (order && columnKey) {
return {
orderBy: columnKey + ' ' + order.replace('end', ''),
};
}
},
// Custom general filter function
defaultFilterFn: (data: Partial<Recordable<string[]>>) => {
return data;
},
},
// scrollbar setting
scrollbar: {
// Whether to use native scroll bar
// After opening, the menu, modal, drawer will change the pop-up scroll bar to native
native: false,
},
};

View File

@@ -0,0 +1,46 @@
import { ThemeEnum } from '../enums/appEnum';
export const darkMode = ThemeEnum.LIGHT;
// header preset color
export const HEADER_PRESET_BG_COLOR_LIST: string[] = [
'#1951be',
'#1677ff',
'#394664',
'#ffffff',
'#009688',
'#5172DC',
'#e74c3c',
'#001529',
'#151515',
'#24292e',
'#383f45',
];
// app theme preset color
export const APP_PRESET_COLOR_LIST: string[] = [
'#2a50ec',
'#1677ff',
'#009688',
'#536dfe',
'#ff5c93',
'#ee4f12',
'#0096c7',
'#9c27b0',
'#ff9800',
];
// sider preset color
export const SIDE_BAR_BG_COLOR_LIST: string[] = [
'#ffffff',
'#001529',
'#273352',
'#151515',
'#191b24',
'#191a23',
'#304156',
'#001628',
'#28333E',
'#344058',
'#383f45',
];

View File

@@ -0,0 +1,13 @@
import { isDevMode } from '@jeesite/core/utils/env';
// System default cache time, in seconds ( 60 days )
export const DEFAULT_CACHE_TIME = 60 * 60 * 24 * 60;
// aes encryption keykey and iv 16 bits
export const cacheCipher = {
key: '_11111000001111@',
iv: '@11111000001111_',
};
// Whether the system cache is encrypted using aes
export const enableStorageEncryption = !isDevMode();

View File

@@ -0,0 +1,29 @@
import type { DropMenu } from '../components/Dropdown';
import type { LocaleSetting, LocaleType } from '@jeesite/types/config';
export const LOCALE: { [key: string]: LocaleType } = {
ZH_CN: 'zh_CN',
EN_US: 'en',
};
export const localeSetting: LocaleSetting = {
showPicker: true,
// Locale
locale: LOCALE.ZH_CN,
// Default locale
fallback: LOCALE.ZH_CN,
// available Locales
availableLocales: [LOCALE.ZH_CN, LOCALE.EN_US],
};
// locale list
export const localeList: DropMenu[] = [
{
text: '简体中文',
event: LOCALE.ZH_CN,
},
{
text: 'English',
event: LOCALE.EN_US,
},
];

View File

@@ -0,0 +1,182 @@
import type { ProjectConfig } from '@jeesite/types/config';
import { MenuTypeEnum, MenuModeEnum, TriggerEnum, MixSidebarTriggerEnum } from '@jeesite/core/enums/menuEnum';
import { CacheTypeEnum } from '@jeesite/core/enums/cacheEnum';
import {
ContentEnum,
PermissionModeEnum,
ThemeEnum,
RouterTransitionEnum,
SettingButtonPositionEnum,
SessionTimeoutProcessingEnum,
} from '@jeesite/core/enums/appEnum';
import { SIDE_BAR_BG_COLOR_LIST, HEADER_PRESET_BG_COLOR_LIST } from './designSetting';
import { primaryColor } from '@jeesite/vite/theme/themeConfig';
// ! You need to clear the browser cache after the change
const setting: ProjectConfig = {
// Whether to show the configuration button
showSettingButton: true,
// Whether to show the theme switch button
showDarkModeToggle: true,
// `Settings` button position
settingButtonPosition: SettingButtonPositionEnum.AUTO,
// Permission mode
permissionMode: PermissionModeEnum.BACK,
// Permission-related cache is stored in sessionStorage or localStorage
permissionCacheType: CacheTypeEnum.SESSION,
// Session timeout processing
sessionTimeoutProcessing: SessionTimeoutProcessingEnum.ROUTE_JUMP,
// color
themeColor: primaryColor,
// Website gray mode, open for possible mourning dates
grayMode: false,
// Color Weakness Mode
colorWeak: false,
// Whether to cancel the menu, the top, the multi-tab page display, for possible embedded in other systems
fullContent: false,
// content mode
contentMode: ContentEnum.FULL,
// Whether to display the logo
showLogo: true,
// Whether to show footer
showFooter: false,
// Header configuration
headerSetting: {
// header bg color
bgColor: HEADER_PRESET_BG_COLOR_LIST[0],
// Fixed at the top
fixed: true,
// Whether to show top
show: true,
// theme
theme: ThemeEnum.LIGHT,
// Whether to enable the lock screen function
useLockPage: true,
// Whether to show the full screen button
showFullScreen: true,
// Whether to show the document button
showDoc: true,
// Whether to show the notification button
showNotice: true,
// Whether to display the menu search
showSearch: true,
},
// Menu configuration
menuSetting: {
// sidebar menu bg color
bgColor: SIDE_BAR_BG_COLOR_LIST[0],
// Whether to fix the left menu
fixed: true,
// Menu collapse
collapsed: false,
// Whether to display the menu name when folding the menu
collapsedShowTitle: false,
// Whether it can be dragged
// Only limited to the opening of the left menu, the mouse has a drag bar on the right side of the menu
canDrag: false,
// Whether to show no dom
show: true,
// Whether to show dom
hidden: false,
// Menu width
menuWidth: 200,
// Menu mode
mode: MenuModeEnum.INLINE,
// Menu type
type: MenuTypeEnum.MIX,
// Menu theme
theme: ThemeEnum.LIGHT,
// Split menu
split: true,
// Top menu layout
topMenuAlign: 'center',
// Fold trigger position
trigger: TriggerEnum.HEADER,
// Turn on accordion mode, only show a menu
accordion: true,
// Switch page to close menu
closeMixSidebarOnChange: false,
// Module opening method click |'hover'
mixSideTrigger: MixSidebarTriggerEnum.HOVER,
// Fixed expanded menu
mixSideFixed: true,
},
// Multi-label
multiTabsSetting: {
cache: false,
// Turn on
show: true,
// Tabs style, Optional value: 1、2、3
style: '3',
// Is it possible to drag and drop sorting tabs
canDrag: true,
// Turn on quick actions
showQuick: true,
// Whether to show the refresh button
showRedo: true,
// Whether to show the collapse button
showFold: true,
},
// Transition Setting
transitionSetting: {
// Whether to open the page switching animation
// The disabled state will also disable pageLoadinng
enable: true,
// Route basic switching animation
basicTransition: RouterTransitionEnum.FADE_SIDE,
// Whether to open page switching loading
// Only open when enable=true
openPageLoading: true,
// Whether to open the top progress bar
// openNProgress: false,
},
// Whether to enable KeepAlive cache is best to close during development, otherwise the cache needs to be cleared every time
openKeepAlive: true,
// Automatic screen lock time, 0 does not lock the screen. Unit minute default 0
lockTime: 0,
// Whether to show breadcrumbs
showBreadCrumb: true,
// Whether to show the breadcrumb icon
showBreadCrumbIcon: false,
// Use error-handler-plugin
useErrorHandle: false,
// Whether to open back to top
useOpenBackTop: true,
// Is it possible to embed iframe pages
canEmbedIFramePage: true,
// Whether to delete unclosed messages and notify when switching the interface
closeMessageOnSwitch: true,
// Whether to cancel the http request that has been sent but not responded when switching the interface.
// If it is enabled, I want to overwrite a single interface. Can be set in a separate interface
removeAllHttpPending: false,
};
export default setting;

View File

@@ -0,0 +1,11 @@
// github repo url
export const GITHUB_URL = 'https://gitee.com/thinkgem';
// jeesite docs
export const DOC_URL = 'http://docs.jeesite.com';
// linker url
export const LINK_URL = 'http://s.jeesite.com';
// site url
export const SITE_URL = 'https://jeesite.com';