当前位置:网站首页>Web page user step-by-step operation guide plug-in driver js
Web page user step-by-step operation guide plug-in driver js
2022-07-02 05:58:00 【Want to eat pineapple crisp】
driver.js It is a step-by-step guide operation for user operation on the web side , Users can be guided to operate on the whole page , Use this method to guide the user to operate after entering the page , So that users can get familiar with the system functions faster !
install
npm install driver.js
Use
stay main.ts Import and bind in
import {
createApp } from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
// introduce
import Driver from 'driver.js'
import 'driver.js/dist/driver.min.css'
const app = createApp(App)
// binding
app.config.globalProperties.$driver = new Driver({
doneBtnText: ' complete ', // Text on the final button
closeBtnText: ' close ', // Text on the close button for this step
stageBackground: '#fff', // Background color for the staged behind highlighted element
nextBtnText: ' next step ', // Next button text for this step
prevBtnText: ' The previous step ', // Previous button text for this step
})
app.use(store)
app.use(router)
app.mount('#app')
Configure the boot node ( New file driver.ts)
export default [
{
element: '#userInfo',
popover: {
title: ' User information ',
description: ' Display the user name , sign out , Full screen operation , Skin changing operation ',
position: 'left',
}
},
{
element: '#grid',
popover: {
title: ' shrinkage , Bread crumbs ',
description: ' Click on the switch navigation bar , Crumb display ',
position: 'right',
}
},
{
element: '#tagGroup',
popover: {
title: 'tag label ',
description: ' Record the open page ',
position: 'bottom',
}
},
{
element: '#mainInfo',
popover: {
title: ' Content area ',
description: ' Display page content ',
position: 'left',
}
},
{
element: '#nav',
popover: {
title: ' Navigation area ',
description: ' Navigation function display ',
position: 'right',
}
},
]
Import the node configuration file in the page that needs to be booted
<script lang="ts">
import {
Options, Vue } from "vue-class-component";
import driverStep from "@/utils/driver";
@Options({
components: {
},
mounted() {
this.$driver.defineSteps(driverStep);
this.$driver.start();
},
})
export default class HomeView extends Vue {
}
</script>
driver.ts Inside id There should be ,json The order of data is the order of guidance
边栏推荐
- 【LeetCode】Day92-盛最多水的容器
- Regular expression summary
- How vite is compatible with lower version browsers
- Vscode paste image plugin saves image path settings
- Alibaba: open source and self-developed liquid cooling data center technology
- 神机百炼3.54-染色法判定二分图
- Typora installation (no need to enter serial number)
- MUI底部导航的样式修改
- 格式校验js
- Lantern Festival gift - plant vs zombie game (realized by Matlab)
猜你喜欢
all3dp.com网站中全部Arduino项目(2022.7.1)
ESP8266与STC8H8K单片机联动——天气时钟
"Simple" infinite magic cube
Eco express micro engine system has supported one click deployment to cloud hosting
PHP development and testing WebService (soap) -win
数理统计与机器学习
Redis key value database [primary]
深度学习分类网络 -- AlexNet
OLED12864 液晶屏
Summary of MySQL constraints
随机推荐
Stc8h8k series assembly and C51 actual combat - keys allow key counting (using falling edge interrupt control)
"Simple" infinite magic cube
PHP obtains some values in the string according to the specified characters, and reorganizes the remaining strings into a new array
Several keywords in C language
【LeetCode】Day92-盛最多水的容器
keepalived安装使用与快速入门
VSCode paste image插件保存图片路径设置
文件包含漏洞(一)
500. 键盘行
Addchild() and addattribute() functions in PHP
PHP read file (read the specified line containing a string in the file)
Redis Key-Value数据库【初级】
Vite打包后的dist不能直接在浏览器打开吗
The Hong Kong Stock Exchange learned from US stocks and pushed spac: the follow-up of many PE companies could not hide the embarrassment of the world's worst stock market
token过期自动续费方案和实现
LCD之MIPI协议的一些说明
[paper translation] gcnet: non local networks meet squeeze exception networks and beyond
memcached安装
文件包含漏洞(二)
PHP read file (read JSON file, convert to array)