最新研发Vite7+Vue3+Pinia3+Arco仿macos/windows网页版webos管理系统。
vite7-webos原创基于vite7.1+vue3.5+pinia3+arco-design+echarts从0-1搭建pc网页版os式管理系统模板。支持macos+windows两种桌面布局风格、自定义桌面栅格模板、可拖拽栅格菜单/dock菜单等功能。
技术栈
- 编辑器:VScode
- 技术框架:vite7.1.2+vue3.5.18+vue-router4.5.1+pinia3
- 组件库:arco-design^2.57.0 (字节桌面版vue3组件库)
- 状态管理:pinia^3.0.3
- 图表插件:echarts^6.0.0
- 拖拽组件:sortablejs^1.15.6
- 模拟数据:mockjs^1.1.0
- 样式编译:sass^1.92.1
- 构建工具:vite^7.1.2
项目框架目录
使用最新前端构建工具 vite7 搭建项目,采用 vue3 setup 语法糖开发页面。
vite7-vue3-webos网页os系统已经更新到我的原创作品集。
vite7+vue3+arco-design仿macOS网页版os管理系统
项目入口配置main.js
- import { createApp } from 'vue'
- import './style.scss'
- import App from './App.vue'
- // 引入arco.design组件库
- import ArcoDesign from '@arco-design/web-vue'
- import '@arco-design/web-vue/dist/arco.css'
- // 额外引入图标库
- import ArcoIcon from '@arco-design/web-vue/es/icon'
- import VEPlus from 've-plus'
- import 've-plus/dist/ve-plus.css'
- // 引入路由及状态管理
- import Router from './router'
- import Pinia from './pinia'
- createApp(App)
- .use(ArcoDesign)
- .use(ArcoIcon)
- .use(VEPlus)
- .use(Router)
- .use(Pinia)
- .mount('#app')
复制代码
桌面布局结构
支持macos和windows两种桌面布局风格。
- <template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>
复制代码- <template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template><template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template><template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template><template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template><template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template><template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>
复制代码
vue3-webos桌面栅格模板
- // 自定义桌面图标变量
- const deskVariable = ref({
- '--icon-radius': '10px', // 圆角
- '--icon-size': '60px', // 图标尺寸(设置rpx自定义手机设备)
- '--icon-gap-col': '30px', // 水平间距
- '--icon-gap-row': '30px', // 垂直间距
- '--icon-labelSize': '12px', // 标签文字大小
- '--icon-labelColor': '#fff', // 标签颜色
- '--icon-fit': 'contain', // 图标自适应模式
- })
复制代码 桌面菜单配置参数- /**
- * ====== desk菜单配置项 ======
- * label 图标标题
- * imgico 图标(本地或网络图片) 支持Arco Design内置图标或自定义iconfont图标
- * path 跳转路由页面
- * link 跳转外部链接
- * hideLabel 是否隐藏图标标题
- * filter 是否禁用拖拽
- * background 自定义图标背景色
- * color 自定义图标颜色
- * size 栅格磁贴布局(16种) 1x1 ... 12x12
- * padding 内边距
- * onClick 点击图标回调函数
- * children 二级菜单
- */
复制代码
配置children参数,支持弹窗显示二级菜单。
桌面菜单代码片段- const deskMenu = [ { uid: '9a16fb90-12c4-11e1-840d-1a25c5bb775a', list: [ ... {label: '日历', imgico: markRaw(Calendar4x2), size: '4x2'}, {label: '每日箴言', imgico: markRaw(DayTalk), size: '3x2'}, {label: '倒计时', imgico: markRaw(CountDown), size: '3x2'}, {label: 'DeepSeek', imgico: 'https://cdn.deepseek.com/logo.png', link: 'https://chat.deepseek.com/', size: '2x1'}, {label: 'Vite^7.1.2', imgico: 'https://vite.dev/logo.svg', link: 'https://vite.dev/'}, ] }, { uid: '9a16fb90-12c4-11e1-840d-1c25d5cc775a', list: [ {label: 'Appstore', imgico: '/static/mac/appstore.png'}, {label: '地图', imgico: '/static/mac/maps.png'}, {label: '浏览器', imgico: '/static/mac/safari.png'}, ... ] }, { uid: '9a16fb90-12c4-11e1-840d-7d25e5ff775a', list: [ {label: 'Vite7.1.2', imgico: 'vite.svg', link: 'https://vite.dev/', background: '#EAFAFF', padding: '20px', size: '2x2'}, {label: 'Github', imgico: '/static/svg/github.svg', link: 'https://github.com/', background: '#607d8b', size: '2x1'}, {label: '码云Gitee', imgico: '/static/svg/gitee.svg', link: 'https://gitee.com/', background: '#bb2124', size: '1x2'}, ... ] }, { uid: 'u738f210-807e-1e4e-1550-4deefac27e48', list: [ {label: 'DeepSeek', imgico: 'https://cdn.deepseek.com/logo.png', link: 'https://chat.deepseek.com/', size: '3x2'}, {label: '豆包', imgico: 'https://lf-flow-web-cdn.doubao.com/obj/flow-doubao/doubao/web/static/image/OnboardingAvatar.0f4f29a4.webp', size: '2x2'}, ... ] }, { uid: 'd141f210-207e-1e8e-9950-9heefyu27e48', list: [ {label: 'Vite^7.1.2', imgico: 'https://vite.dev/logo.svg', link: 'https://vite.dev/'}, {<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>label: '编程开发',<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>children: [<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> {label: 'DeepSeek', imgico: 'https://www.faxianai.com/wp-content/uploads/2025/02/20250205134524-1febd.png', link: 'https://chat.deepseek.com/',},<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> ...<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>] }, {label: '首页', imgico: markRaw(IconHome), path: '/home', color: '#fff'}, {<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>label: '组件',<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>children: [<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> {label: '表格', imgico: '/static/svg/table.svg', path: '/components/table/all'},<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> ...<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>] }, {<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>label: '个人中心',<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>children: [<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> {label: '主页', imgico: '/static/svg/my.svg', path: '/setting'},<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> {label: '用户管理', imgico: markRaw(IconUser), path: '/user', color: '#fff'},<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> ...<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>] }, {<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>label: '设置',<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>children: [<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> {label: '网站设置', imgico: '/static/svg/settings.svg', path: '/setting/system/website'},<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> {label: '邮件服务', imgico: '/static/mac/mail.png', path: '/setting/system/mail'},<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>] }, {<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>label: '公众号', imgico: markRaw(IconWechat), color: '#07c160',<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>onClick: () => {<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template> ...<template>
-
- <component :is="DeskLayout[appstate.config.layout]" />
-
- </template>} }, ] }]
复制代码 vue3-webos自定义dock菜单
以上就是vite7+pinia3+arco-design搭建网页版webos系统的一些分享,希望对大家有些帮助~
最后附上几个最新实战项目
Electron38-Wechat电脑端聊天|vite7+electron38仿微信桌面端聊天系统
uniapp-vue3-os手机oa系统|uni-app+vue3跨三端os后台管理模板
Vite7网页版聊天|Vue3.5+Pinia3+ElementPlus仿微信网页端web聊天系统
最新版uni-app+vue3+uv-ui跨三端仿微信app聊天应用【h5+小程序+app端】
Flutter3-MacOS桌面OS系统|flutter3.32+window_manager客户端OS模板
最新研发flutter3.27+bitsdojo_window+getx客户端仿微信聊天Exe应用
最新版uniapp+vue3+uv-ui跨三端短视频+直播+聊天【H5+小程序+App端】
Uniapp-DeepSeek跨三端AI助手|uniapp+vue3+deepseek-v3流式ai聊天模板
vue3-webseek网页版AI问答|Vite6+DeepSeek+Arco流式ai聊天打字效果
flutter3-dymall仿抖音直播商城|Flutter3.27短视频+直播+聊天App实例
tauri2.0-admin桌面端后台系统|Tauri2+Vite5+ElementPlus管理后台EXE程序
Electron32-ViteOS桌面版os系统|vue3+electron+arco客户端OS管理模板
来源:程序园用户自行投稿发布,如果侵权,请联系站长删除
免责声明:如果侵犯了您的权益,请联系站长,我们会及时删除侵权内容,谢谢合作! |