当前位置: 首页 > news >正文

DeepSeek 助力 Vue3 开发:打造丝滑的弹性布局(Flexbox)

前言:哈喽,大家好,今天给大家分享一篇文章!并提供具体代码帮助大家深入理解,彻底掌握!创作不易,如果能帮助到大家或者给大家一些灵感和启发,欢迎收藏+关注哦 💕

共同探索软件研发!敬请关注【宝码香车】
关注描述

csdngif标识

目录

  • DeepSeek 助力 Vue3 开发:打造丝滑的弹性布局(Flexbox)
    • 📚前言
    • 📚页面效果
    • 📚指令输入
      • 定义属性
        • 容器相关属性
        • 子元素相关属性
      • 定义事件
      • 其他
    • 📚think
      • 📘组件代码
    • 📚代码测试
    • 📚测试代码正常跑通,附其他基本代码
      • 📘编写路由 src\router\index.js
      • 📘编写展示入口 src\App.vue
    • 📚页面效果
    • 📚相关文章


📚📗📕📘📖🕮💡📝🗂️✍️🛠️💻🚀🎉🏗️🌐🖼️🔗📊👉🔖⚠️🌟🔐⬇️·正文开始⬇️·🎥😊🎓📩😺🌈🤝🤖📜📋🔍✅🧰❓📄📢📈 🙋0️⃣1️⃣2️⃣3️⃣4️⃣5️⃣6️⃣7️⃣8️⃣9️⃣🔟🆗*️⃣#️⃣

DeepSeek 助力 Vue3 开发:打造丝滑的弹性布局(Flexbox)

📚前言

DeepSeek 的发展也面临着一些技术挑战,如算力需求、数据质量和模型优化等问题。为了应对这些挑战,DeepSeek 采取了一系列有效的措施,如创新算法和架构设计、建立严格的数据治理体系、进行多方面的技术革新等,展现出了强大的技术实力和创新能力。

📚页面效果

 DeepSeek 助力 Vue3 开发:打造丝滑的弹性布局(Flexbox)页面效果图片

📚指令输入

已经创建好了一个基于Vue3的组合式API的项目(Composition API),并能正常运行起来,请帮我用 Vue3的组合式API(Composition API) 生成一个 弹性布局(Flexbox) 的功能组件,所有代码都保存在components/Flexbox 下的文件夹中。功能组件的script标签中只有setup属性,使用普通 JavaScript 实现,不使用TypeScript。
功能要有,如下属性:

定义属性

容器相关属性
  1. display

    • 作用:指定元素是否以弹性容器显示,虽然默认是弹性布局,但可以提供一个属性让用户选择是否开启。
    • 类型:Boolean
    • 默认值:true
    • 说明:当设置为 false 时,组件不使用弹性布局。
  2. flexDirection

    • 作用:定义主轴的方向,即子元素的排列方向。
    • 类型:String
    • 可选值:'row''row-reverse''column''column-reverse'
    • 默认值:'row'
  3. flexWrap

    • 作用:定义子元素是否换行。
    • 类型:String
    • 可选值:'nowrap''wrap''wrap-reverse'
    • 默认值:'nowrap'
  4. flexFlow

    • 作用:是 flexDirectionflexWrap 的缩写属性。
    • 类型:String
    • 默认值:undefined
    • 说明:如果设置了 flexFlow,则 flexDirectionflexWrap 的设置将被忽略。
  5. justifyContent

    • 作用:定义子元素在主轴上的对齐方式。
    • 类型:String
    • 可选值:'flex-start''flex-end''center''space-between''space-around''space-evenly'
    • 默认值:'flex-start'
  6. alignItems

    • 作用:定义子元素在交叉轴上的对齐方式。
    • 类型:String
    • 可选值:'flex-start''flex-end''center''baseline''stretch'
    • 默认值:'stretch'
  7. alignContent

    • 作用:定义多根轴线的对齐方式,如果子元素只有一根轴线,该属性不起作用。
    • 类型:String
    • 可选值:'flex-start''flex-end''center''space-between''space-around''stretch'
    • 默认值:'stretch'
子元素相关属性
  1. gap

    • 作用:定义子元素之间的间距。
    • 类型:String
    • 默认值:'0'
  2. inline

    • 作用:指定弹性容器是否为行内元素。
    • 类型:Boolean
    • 默认值:false

定义事件

  1. resize

    • 作用:当弹性容器大小改变时触发,可用于在容器大小变化时进行一些额外的处理,比如重新计算子元素的布局。
    • 参数:{ width: number, height: number },表示容器的新宽度和高度。
  2. childAdded

    • 作用:当有新的子元素添加到弹性容器时触发,可用于在子元素添加后进行一些初始化操作。
    • 参数:HTMLElement,表示新添加的子元素。
  3. childRemoved

    • 作用:当有子元素从弹性容器中移除时触发,可用于在子元素移除后进行一些清理操作。
    • 参数:HTMLElement,表示被移除的子元素。

其他

  1. 提供插槽:使用 Vue 的插槽机制,允许用户将任意内容插入到弹性容器中,增加组件的灵活性。
  2. 样式隔离:确保组件的样式不会影响到外部的其他元素,同时也不会被外部样式影响,可以使用 CSS 作用域或者 CSS Modules。
  3. 响应式设计:考虑结合媒体查询或者 Vue 的响应式数据,让弹性布局在不同的屏幕尺寸下有不同的表现。
  4. 文档和示例:编写详细的文档,说明每个属性和事件的作用,并提供一些使用示例,方便其他开发者使用该组件。

你有更好的建议也可以添加,要注明。组件定义好后给出5个及以上的调用示例,示例中添加完整的数据和事件,确保每个示例是独立的。
下面是现有目录
DeepSeekAndVue/
├── src/ # 源代码目录
│ ├── assets/ # 静态资源
│ │ ├── base.css
│ │ ├── main.css
│ │ └── logo.svg
│ ├── components/ # 组件目录
│ │ ├── HelloWorld.vue
│ │ ├── TheWelcome.vue
│ │ ├── WelcomeItem.vue
│ │ ├── Progress/
│ │ │ └── Progress.vue
│ │ ├── Accordion/
│ │ ├── BackToTop/
│ │ ├── Card/
│ │ ├── InfiniteScroll/
│ │ ├── Notification/
│ │ ├── Timeline/
│ │ ├── Switch/
│ │ ├── Tabs/
│ │ ├── Sidebar/
│ │ ├── Breadcrumbs/
│ │ ├── MasonryLayout/
│ │ ├── Rating/
│ │ ├── ColorPicker/
│ │ ├── RightClickMenu/
│ │ ├── RangePicker/
│ │ ├── Navbar/
│ │ ├── FormValidation/
│ │ ├── CopyToClipboard/
│ │ ├── ClickAnimations/
│ │ ├── ThumbnailList/
│ │ ├── KeyboardShortcuts/
│ │ ├── CommentSystem/
│ │ ├── QRCode/
│ │ ├── RadioButton/
│ │ ├── Slider/
│ │ ├── ScrollAnimations/
│ │ ├── TextInput/
│ │ ├── Divider/
│ │ ├── Checkbox/
│ │ ├── TagInput/
│ │ ├── DropdownSelect/
│ │ ├── List/
│ │ ├── Header/
│ │ ├── Footer/
│ │ ├── Pagination/
│ │ ├── FloatingActionButton/
│ │ ├── PasswordInput/
│ │ ├── GridLayout/
│ │ ├── Flexbox/
│ │ ├── DatePicker/
│ │ └── icons/
│ ├── router/ # 路由配置
│ │ └── index.js
│ ├── stores/ # Pinia 状态管理
│ │ └── counter.js
│ ├── views/ # 页面组件
│ │ ├── ProgressView.vue
│ │ ├── TabsView.vue
│ │ ├── SwitchView.vue
│ │ ├── TimelineView.vue
│ │ ├── NotificationView.vue
│ │ ├── CardView.vue
│ │ ├── InfiniteScrollView.vue
│ │ ├── BackToTopView.vue
│ │ ├── AccordionView.vue
│ │ ├── SidebarView.vue
│ │ ├── BreadcrumbsView.vue
│ │ ├── MasonryLayoutView.vue
│ │ ├── RatingView.vue
│ │ ├── ColorPickerView.vue
│ │ ├── RightClickMenuView.vue
│ │ ├── RangePickerView.vue
│ │ ├── NavbarView.vue
│ │ ├── FormValidationView.vue
│ │ ├── CopyToClipboardView.vue
│ │ ├── ClickAnimationsView.vue
│ │ ├── ThumbnailListView.vue
│ │ ├── KeyboardShortcutsView.vue
│ │ ├── CommentSystemView.vue
│ │ ├── QRCodeView.vue
│ │ ├── RadioButtonView.vue
│ │ ├── SliderView.vue
│ │ ├── ScrollAnimationsView.vue
│ │ ├── TextInputView.vue
│ │ ├── DividerView.vue
│ │ ├── CheckboxView.vue
│ │ ├── TagInputView.vue
│ │ ├── DropdownSelectView.vue
│ │ ├── ListView.vue
│ │ ├── HeaderView.vue
│ │ ├── FooterView.vue
│ │ ├── PaginationView.vue
│ │ ├── FloatingActionButtonView.vue
│ │ ├── GridLayoutView.vue
│ │ ├── PasswordInputView.vue
│ │ ├── FlexboxView.vue
│ │ ├── DatePickerView.vue
│ │ └── AboutView.vue
│ ├── App.vue # 根组件
│ └── main.js # 应用入口
├── public/ # 公共资源目录
├── index.html # HTML 模板
├── package.json # 项目配置
├── vite.config.js # Vite 配置
└── node_modules/ # 依赖包目录

📚think

📘组件代码

我将为您创建一个功能完整的Flexbox组件,并提供使用示例。以下是组件的实现方案:

<!-- components/Flexbox/FlexContainer.vue -->
<template><divref="containerRef"class="flex-container":style="containerStyles"@slotchange="handleSlotChange"><slot></slot></div>
</template><script setup>
import { ref, computed, onMounted, onUnmounted } from 'vue'const props = defineProps({display: {type: Boolean,default: true},flexDirection: {type: String,default: 'row',validator: (value) => ['row','row-reverse','column','column-reverse'].includes(value)},flexWrap: {type: String,default: 'nowrap',validator: (value) => ['nowrap', 'wrap', 'wrap-reverse'].includes(value)},flexFlow: String,justifyContent: {type: String,default: 'flex-start',validator: (value) => ['flex-start','flex-end','center','space-between','space-around','space-evenly'].includes(value)},alignItems: {type: String,default: 'stretch',validator: (value) => ['flex-start','flex-end','center','baseline','stretch'].includes(value)},alignContent: {type: String,default: 'stretch',validator: (value) => ['flex-start','flex-end','center','space-between','space-around','stretch'].includes(value)},gap: {type: String,default: '0'},inline: {type: Boolean,default: false}
})const emit = defineEmits(['resize', 'childAdded', 'childRemoved'])const containerRef = ref(null)
let resizeObserver = null
let mutationObserver = nullconst containerStyles = computed(() => {const styles = {gap: props.gap,justifyContent: props.justifyContent,alignItems: props.alignItems,alignContent: props.alignContent}if (props.display) {styles.display = props.inline ? 'inline-flex' : 'flex'styles.flexFlow = props.flexFlow ? props.flexFlow : `${props.flexDirection} ${props.flexWrap}`} else {styles.display = props.inline ? 'inline-block' : 'block'}return styles
})const handleResize = (entries) => {for (const entry of entries) {const { width, height } = entry.contentRectemit('resize', { width, height })}
}const handleMutation = (mutations) => {for (const mutation of mutations) {mutation.addedNodes.forEach(node => {if (node.nodeType === Node.ELEMENT_NODE) {emit('childAdded', node)}})mutation.removedNodes.forEach(node => {if (node.nodeType === Node.ELEMENT_NODE) {emit('childRemoved', node)}})}
}onMounted(() => {// 初始化ResizeObserverresizeObserver = new ResizeObserver(handleResize)if (containerRef.value) {resizeObserver.observe(containerRef.value)}// 初始化MutationObservermutationObserver = new MutationObserver(handleMutation)mutationObserver.observe(containerRef.value, {childList: true,subtree: false})
})onUnmounted(() => {resizeObserver?.disconnect()mutationObserver?.disconnect()
})
</script><style scoped>
.flex-container {width: 100%;min-height: 50px;box-sizing: border-box;
}
</style>

以下是5个使用示例:

<!-- 示例1: 基本行布局 -->
<template><FlexContainer><div v-for="n in 3" :key="n" class="box">Item {{ n }}</div></FlexContainer>
</template><script setup>
import FlexContainer from '@/components/Flexbox/FlexContainer.vue'
</script><style>
.box {padding: 20px;background: #eee;margin: 5px;
}
</style><!-- 示例2: 列布局居中 -->
<template><FlexContainer flex-direction="column"justify-content="center"align-items="center"gap="10px"style="height: 300px; border: 1px solid #ccc;"><div v-for="n in 3" :key="n" class="box">Item {{ n }}</div></FlexContainer>
</template><!-- 示例3: 换行布局 -->
<template><FlexContainerflex-wrap="wrap"gap="20px"@resize="handleResize"><div v-for="n in 8" :key="n" style="width: 200px" class="box">Item {{ n }}</div></FlexContainer>
</template><script setup>
const handleResize = (size) => {console.log('Container size changed:', size)
}
</script><!-- 示例4: 响应式布局 -->
<template><FlexContainer:flex-direction="isMobile ? 'column' : 'row'":gap="isMobile ? '10px' : '20px'"><div v-for="n in 4" :key="n" class="box">Item {{ n }}</div></FlexContainer>
</template><script setup>
import { ref, onMounted, onUnmounted } from 'vue'const isMobile = ref(false)const checkMobile = () => {isMobile.value = window.innerWidth < 768
}onMounted(() => {window.addEventListener('resize', checkMobile)checkMobile()
})onUnmounted(() => {window.removeEventListener('resize', checkMobile)
})
</script><!-- 示例5: 事件处理 -->
<template><FlexContainer@child-added="handleChildAdded"@child-removed="handleChildRemoved"@resize="handleResize"style="border: 1px solid #ddd; padding: 10px;"><div v-for="item in items" :key="item" class="box">{{ item }}</div></FlexContainer><button @click="addItem">Add Item</button><button @click="removeItem">Remove Item</button>
</template><script setup>
import { ref } from 'vue'const items = ref(['A', 'B', 'C'])const addItem = () => {items.value.push(String.fromCharCode(65 + items.value.length))
}const removeItem = () => {if (items.value.length > 0) {items.value.pop()}
}const handleChildAdded = (element) => {console.log('Child added:', element)element.style.backgroundColor = '#e3f2fd'
}const handleChildRemoved = (element) => {console.log('Child removed:', element)
}const handleResize = ({ width, height }) => {console.log(`New container size: ${width}x${height}`)
}
</script>

优化建议:

  1. 性能优化:添加防抖处理resize事件
  2. 可访问性:添加ARIA属性
  3. 边界处理:处理无效属性值
  4. 扩展性:添加子元素order/flex属性支持
  5. 调试支持:开发模式下显示布局轮廓

组件特点:

  1. 完整的Flexbox属性支持
  2. 响应式尺寸监控
  3. 子元素变化追踪
  4. 样式隔离
  5. 类型验证
  6. 完善的文档支持
  7. 灵活的事件处理
  8. 良好的浏览器兼容性

使用时可以根据需要添加自定义样式,组件会自动处理布局逻辑。事件系统可以帮助实现动态布局调整和动画效果。

📚代码测试

运行正常

📚测试代码正常跑通,附其他基本代码

  • 添加路由
  • 页面展示入口

📘编写路由 src\router\index.js

\router\index.js

import { createRouter, createWebHistory } from 'vue-router'
import RightClickMenuView from '../views/RightClickMenuView.vue'
import RangePickerView from '../views/RangePickerView.vue'const router = createRouter({history: createWebHistory(import.meta.env.BASE_URL),routes: [{path: '/',name: 'progress',component:  () => import('../views/ProgressView.vue'),},{path: '/tabs',name: 'tabs',// route level code-splitting// this generates a separate chunk (About.[hash].js) for this route// which is lazy-loaded when the route is visited.// 标签页(Tabs)component: () => import('../views/TabsView.vue'),},{path: '/accordion',name: 'accordion',// 折叠面板(Accordion)component: () => import('../views/AccordionView.vue'),},{path: '/timeline',name: 'timeline',// 时间线(Timeline)component: () => import('../views/TimelineView.vue'),},{path: '/backToTop',name: 'backToTop',component: () => import('../views/BackToTopView.vue')},{path: '/notification',name: 'notification',component: () => import('../views/NotificationView.vue')},{path: '/card',name: 'card',component: () => import('../views/CardView.vue')},{path: '/infiniteScroll',name: 'infiniteScroll',component: () => import('../views/InfiniteScrollView.vue')},{path: '/switch',name: 'switch',component: () => import('../views/SwitchView.vue')},{path: '/sidebar',name: 'sidebar',component: () => import('../views/SidebarView.vue')},{path: '/breadcrumbs',name: 'breadcrumbs',component: () => import('../views/BreadcrumbsView.vue')},{path: '/masonryLayout',name: 'masonryLayout',component: () => import('../views/MasonryLayoutView.vue')},{path: '/rating',name: 'rating',component: () => import('../views/RatingView.vue')},{path: '/datePicker',name: 'datePicker',component: () => import('../views/DatePickerView.vue')},{path: '/colorPicker',name: 'colorPicker',component: () => import('../views/ColorPickerView.vue')},{path: '/rightClickMenu',name: 'rightClickMenu',component: RightClickMenuView},{path: '/rangePicker',name: 'rangePicker',component: () => import('../views/RangePickerView.vue')},{path: '/navbar',name: 'navbar',component: () => import('../views/NavbarView.vue')},{path: '/formValidation',name: 'formValidation',component: () => import('../views/FormValidationView.vue')},{path: '/copyToClipboard',name: 'copyToClipboard',component: () => import('../views/CopyToClipboardView.vue')},{path: '/clickAnimations',name: 'clickAnimations',component: () => import('../views/ClickAnimationsView.vue')},{path: '/thumbnailList',name: 'thumbnailList',component: () => import('../views/ThumbnailListView.vue')},{path: '/keyboardShortcuts',name: 'keyboardShortcuts',component: () => import('../views/KeyboardShortcutsView.vue')},{path: '/commentSystem',name: 'commentSystem',component: () => import('../views/CommentSystemView.vue')},{path: '/qRCode',name: 'qRCode',component: () => import('../views/QRCodeView.vue')},{path: '/radioButton',name: 'radioButton',component: () => import('../views/RadioButtonView.vue')},{path: '/slider',name: 'slider',component: () => import('../views/SliderView.vue')},{path: '/scrollAnimations',name: 'scrollAnimations',component: () => import('../views/ScrollAnimationsView.vue')},{path: '/textInputView',name: 'textInputView',component: () => import('../views/TextInputView.vue')},{path: '/divider',name: 'divider',component: () => import('../views/DividerView.vue')},{path: '/checkbox',name: 'checkbox',component: () => import('../views/CheckboxView.vue')},{path: '/tagInput',name: 'tagInput',component: () => import('../views/TagInputView.vue')},{path: '/dropdownSelect',name: 'dropdownSelect',component: () => import('../views/DropdownSelectView.vue')},{path: '/list',name: 'list',component: () => import('../views/ListView.vue')},{path: '/header',name: 'header',component: () => import('../views/HeaderView.vue')},{path: '/footer',name: 'footer',component: () => import('../views/FooterView.vue')},{path: '/pagination',name: 'pagination',component: () => import('../views/PaginationView.vue')},{path: '/floatingActionButton',name: 'floatingActionButton',component: () => import('../views/FloatingActionButtonView.vue')},{path: '/gridLayout',name: 'gridLayout',component: () => import('../views/GridLayoutView.vue')},{path: '/passwordInput',name: 'passwordInput',component: () => import('../views/PasswordInputView.vue')},{path: '/flexbox',name: 'flexbox',component: () => import('../views/FlexboxView.vue')}],
})export default router

📘编写展示入口 src\App.vue

 src\App.vue

<script setup>
import { RouterLink, RouterView } from 'vue-router'
import HelloWorld from './components/HelloWorld.vue'
</script><template><header><img alt="Vue logo" class="logo" src="@/assets/logo.svg" width="125" height="125" /><div class="wrapper"><HelloWorld msg="You did it!" /><nav><RouterLink to="/">Progress</RouterLink><RouterLink to="/tabs">Tabs</RouterLink><RouterLink to="/accordion">Accordion</RouterLink><RouterLink to="/timeline">Timeline</RouterLink><RouterLink to="/backToTop">BackToTop</RouterLink><RouterLink to="/notification">Notification</RouterLink><RouterLink to="/card">Card</RouterLink><RouterLink to="/infiniteScroll">InfiniteScroll</RouterLink><RouterLink to="/switch">Switch</RouterLink><RouterLink to="/sidebar">Sidebar</RouterLink><RouterLink to="/breadcrumbs">Breadcrumbs</RouterLink><RouterLink to="/masonryLayout">MasonryLayout</RouterLink><RouterLink to="/rating">Rating</RouterLink><RouterLink to="/datePicker">DatePicker</RouterLink><RouterLink to="/colorPicker">ColorPicker</RouterLink><RouterLink to="/rightClickMenu">RightClickMenu</RouterLink><RouterLink to="/rangePicker">RangePicker</RouterLink><RouterLink to="/navbar">Navbar</RouterLink><RouterLink to="/formValidation">FormValidation</RouterLink><RouterLink to="/copyToClipboard">CopyToClipboard</RouterLink><RouterLink to="/clickAnimations">ClickAnimations</RouterLink><RouterLink to="/thumbnailList">ThumbnailList</RouterLink><RouterLink to="/keyboardShortcuts">KeyboardShortcuts</RouterLink><RouterLink to="/commentSystem">CommentSystem</RouterLink><RouterLink to="/qRCode">QRCode</RouterLink><RouterLink to="/radioButton">RadioButton</RouterLink><RouterLink to="/slider">Slider</RouterLink><RouterLink to="/scrollAnimations">ScrollAnimations</RouterLink><RouterLink to="/textInputView">TextInput</RouterLink><RouterLink to="/divider">Divider</RouterLink><RouterLink to="/checkbox">Checkbox</RouterLink><RouterLink to="/tagInput">TagInput</RouterLink><RouterLink to="/dropdownSelect">DropdownSelect</RouterLink><RouterLink to="/list">List</RouterLink><RouterLink to="/header">Header</RouterLink><RouterLink to="/footer">Footer</RouterLink><RouterLink to="/pagination">Pagination</RouterLink><RouterLink to="/floatingActionButton">FloatingActionButton</RouterLink><RouterLink to="/gridLayout">GridLayout</RouterLink><RouterLink to="/passwordInput">PasswordInput</RouterLink><RouterLink to="/flexbox">Flexbox</RouterLink></nav></div></header><RouterView />
</template><style scoped>
header {line-height: 1.5;max-height: 100vh;
}.logo {display: block;margin: 0 auto 2rem;
}nav {width: 100%;font-size: 12px;text-align: center;margin-top: 2rem;
}nav a.router-link-exact-active {color: var(--color-text);
}nav a.router-link-exact-active:hover {background-color: transparent;
}nav a {display: inline-block;padding: 0 1rem;border-left: 1px solid var(--color-border);
}nav a:first-of-type {border: 0;
}@media (min-width: 1024px) {header {display: flex;place-items: center;padding-right: calc(var(--section-gap) / 2);}.logo {margin: 0 2rem 0 0;}header .wrapper {display: flex;place-items: flex-start;flex-wrap: wrap;}nav {text-align: left;margin-left: -1rem;font-size: 1rem;padding: 1rem 0;margin-top: 1rem;}
}
</style>

📚页面效果

 DeepSeek 助力 Vue3 开发:打造丝滑的弹性布局(Flexbox)页面效果图片

📚相关文章

 

———— 相 关 文 章 ————

 

  1. DeepSeek 助力 Vue 开发:打造丝滑的右键菜单(RightClickMenu)https://blog.csdn.net/qq_33650655/article/details/145706658

  2. DeepSeek 助力 Vue 开发:打造丝滑的范围选择器(Range Picker)https://blog.csdn.net/qq_33650655/article/details/145713572

  3. DeepSeek 助力 Vue 开发:打造丝滑的导航栏(Navbar)https://blog.csdn.net/qq_33650655/article/details/145732421

  4. DeepSeek 助力 Vue 开发:打造丝滑的表单验证(Form Validation)https://blog.csdn.net/qq_33650655/article/details/145735582

  5. DeepSeek 助力 Vue 开发:打造丝滑的复制到剪贴板(Copy to Clipboard)https://blog.csdn.net/qq_33650655/article/details/145739569

  6. DeepSeek 助力 Vue 开发:打造丝滑的点击动画(Click Animations)https://blog.csdn.net/qq_33650655/article/details/145766184

  7. DeepSeek 助力 Vue 开发:打造丝滑的缩略图列表(Thumbnail List)https://blog.csdn.net/qq_33650655/article/details/145776679

  8. DeepSeek 助力 Vue 开发:打造丝滑的 键盘快捷键(Keyboard Shortcuts) https://blog.csdn.net/qq_33650655/article/details/145780227

  9. DeepSeek 助力 Vue 开发:打造丝滑的评论系统(Comment System)https://blog.csdn.net/qq_33650655/article/details/145781104

  10. DeepSeek 助力 Vue 开发:打造丝滑的二维码生成(QR Code)https://blog.csdn.net/qq_33650655/article/details/145797928

  11. DeepSeek 助力 Vue 开发:打造丝滑的单选按钮(Radio Button)https://blog.csdn.net/qq_33650655/article/details/145810620

  12. DeepSeek 助力 Vue 开发:打造丝滑的滑块(Slider)https://blog.csdn.net/qq_33650655/article/details/145817161

  13. DeepSeek 助力 Vue 开发:打造丝滑的滚动动画(Scroll Animations)https://blog.csdn.net/qq_33650655/article/details/145818571

  14. DeepSeek 助力 Vue 开发:打造丝滑的文本输入框(Text Input)https://blog.csdn.net/qq_33650655/article/details/145837003

  15. DeepSeek 助力 Vue 开发:打造丝滑的分割线(Divider)https://blog.csdn.net/qq_33650655/article/details/145849100

  16. DeepSeek 助力 Vue 开发:打造丝滑的 复选框(Checkbox)https://blog.csdn.net/qq_33650655/article/details/145855695

  17. DeepSeek 助力 Vue3 开发:打造丝滑的标签输入(Tag Input)https://blog.csdn.net/qq_33650655/article/details/145858574

  18. DeepSeek 助力 Vue3 开发:打造丝滑的下拉选择框(Dropdown Select)https://blog.csdn.net/qq_33650655/article/details/145861882

  19. DeepSeek 助力 Vue3 开发:打造丝滑的列表(List)https://blog.csdn.net/qq_33650655/article/details/145866384

  20. DeepSeek 助力 Vue3 开发:打造丝滑的页眉(Header)https://blog.csdn.net/qq_33650655/article/details/145885122

  21. DeepSeek 助力 Vue3 开发:打造丝滑的页脚(Footer)https://blog.csdn.net/qq_33650655/article/details/145886306

  22. DeepSeek 助力 Vue3 开发:打造丝滑的分页(Pagination)https://blog.csdn.net/qq_33650655/article/details/145886824

  23. DeepSeek 助力 Vue3 开发:打造丝滑的悬浮按钮(Floating Action Button)
    https://blog.csdn.net/qq_33650655/article/details/145888339

  24. DeepSeek 助力 Vue3 开发:打造丝滑的网格布局(Grid Layout)https://blog.csdn.net/qq_33650655/article/details/145893422

  25. DeepSeek 助力 Vue3 开发:打造丝滑的密码输入框(Password Input)https://blog.csdn.net/qq_33650655/article/details/145903079

到此这篇文章就介绍到这了,更多精彩内容请关注本人以前的文章或继续浏览下面的文章,创作不易,如果能帮助到大家,希望大家多多支持宝码香车~💕,若转载本文,一定注明本文链接。


整理不易,点赞关注宝码香车

更多专栏订阅推荐:
👍 html+css+js 绚丽效果
💕 vue
✈️ Electron
⭐️ js
📝 字符串
✍️ 时间对象(Date())操作

相关文章:

DeepSeek 助力 Vue3 开发:打造丝滑的弹性布局(Flexbox)

前言&#xff1a;哈喽&#xff0c;大家好&#xff0c;今天给大家分享一篇文章&#xff01;并提供具体代码帮助大家深入理解&#xff0c;彻底掌握&#xff01;创作不易&#xff0c;如果能帮助到大家或者给大家一些灵感和启发&#xff0c;欢迎收藏关注哦 &#x1f495; 目录 Deep…...

jwt 存在的无状态的安全问题与解决方案

背景我的需求 解决方法方案1:黑名单存在的问题解决方案问题成本估算: 方案2: 双token刷新核心解决的问题存在的问题 方案3: token与session结合成本估算 方案4: 长连接(websocket) 背景 jwt是无状态的,除了自动失效之外无法手动过期 举个例子: 当我们的token泄露或者密码泄露…...

【Python爬虫】爬取公共交通路网数据

程序来自于Github&#xff0c;以下这篇博客作为完整的学习记录&#xff0c;也callback上一篇爬取公共交通站点的博文。 Bardbo/get_bus_lines_and_stations_data_from_gaode: 这个项目是基于高德开放平台和公交网获取公交线路及站点数据&#xff0c;并生成shp文件&#xff0c;…...

Deepseek API+Python测试用例一键生成与导出-V1

在实际使用场景中&#xff0c;可能只需要获取需求文档中的部分内容&#xff0c;例如特定标题的正文部分、特定段落的表格内容&#xff0c;或者指定图片中的内容。为了满足这一需求&#xff0c;可以对文档清理工具进行优化&#xff0c;支持按标题提取内容、按章节提取表格和图片…...

如何为JAR设置定时重启?

AI越来越火了&#xff0c;我们想要不被淘汰就得主动拥抱。推荐一个人工智能学习网站&#xff0c;通俗易懂&#xff0c;风趣幽默&#xff0c;最重要的屌图甚多&#xff0c;忍不住分享一下给大家。点击跳转到网站 前面我们说过了如何将jar交由Systemctl管理&#xff0c;下面我们…...

麒麟V10-SP2-x86_64架构系统下通过KVM创建虚拟机及配置虚机的NAT、Bridge两种网络模式全过程

文章目录 一、什么是虚拟化&#xff1f;虚拟化具有哪些优势 二、常见的虚拟化技术1、kvm介绍2、kvm工作原理3、kvm功能 三、安装kvm并启动第一个kvm机器1、环境准备2、安装kvm工具3、启动并设置开机自启 libvirtd 服务4、验证 KVM 模块是否加载5、上传系统镜像到指定目录6、网络…...

三方库总结

一、Glide 目标&#xff1a;熟练掌握各种使用方法&#xff0c;了解其设计&#xff0c;背后原理 如果我设计一个图片显示框架&#xff0c;我会怎么做&#xff1f; 1.加载图片资源-从网络上下载图片资源、从本地加载图片资源 如果是从网络上加载图片&#xff0c;需要用到相关的网…...

用DeepSeek-R1-Distill-data-110k蒸馏中文数据集 微调Qwen2.5-7B-Instruct!

下载模型与数据 模型下载&#xff1a; huggingface&#xff1a; Qwen/Qwen2.5-7B-Instruct HF MirrorWe’re on a journey to advance and democratize artificial intelligence through open source and open science.https://hf-mirror.com/Qwen/Qwen2.5-7B-Instruct 魔搭&a…...

知识图谱的推荐实现方案(Vue)

使用 Vue 实现知识图谱思维导图展示的完整方案&#xff0c;结合主流库和最佳实践&#xff1a; 一、技术选型 组件库特点适用场景MindElixir国产开源、中文文档完善、支持关系线教育类知识图谱GoJS功能强大、商业许可、适合复杂交互企业级应用&#xff08;需付费&#xff09;D3…...

Nessus安装

Nessus&#xff1a;https://pan.quark.cn/s/f5fb09b6d4fb 1.软件安装 点击安装&#xff0c;剩下的下一步即可。 直接下一步安装即可 2.Web端安装 会弹出一个web窗口 开始初始化 创建用户 开始初始化 3.Cracker 会弹一个黑窗口 运行完&#xff0c;回车即可。访问https://loc…...

【大模型基础_毛玉仁】0.概述

更多内容&#xff1a;XiaoJ的知识星球 【大模型基础_毛玉仁】 系列文章参考 系列文章 【大模型基础_毛玉仁】0.概述 【大模型基础_毛玉仁】1.1 基于统计方法的语言模型 更新中。。。。。。 参考 书籍&#xff1a;大模型基础_完整版.pdf Github&#xff1a;https://github.co…...

quillEditor 禁用复制粘贴图片,以及class转style等问题

<template><div><div class"search-term"><el-form :inline"true" :model"searchInfo" class"demo-form-inline"><el-form-item label"案例标题"><el-input v-model"searchInfo.titl…...

C语⾔数据类型和变量

C 语言的数据类型 类型分类&#xff1a; C 语言提供丰富的数据类型&#xff0c;包括字符型&#xff08;char、signed char、unsigned char&#xff09;、整型&#xff08;short、int、long 等多种&#xff0c;且各有 signed 和 unsigned 修饰形式&#xff09; 、浮点型&#x…...

centOS 环境 安装redis方法

一、准备centOS环境 参考文章&#xff1a;Hyper-V 安装CentOS7_代码草率了的博客-CSDN博客 二、redis官网 地址&#xff1a;Download | Redis 演示版本为?redis-5.0.14.tar.gz 三、redis源码编译 登录后创建soft目录 进入目录使用wget下载所需资源包 命令&#xff1a;w…...

【Mac】2025-MacOS系统下常用的开发环境配置

早期版本的一个环境搭建参考 1、brew Mac自带终端运行&#xff1a; /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" Installation successful!成功后运行三行命令后更新环境&#xff08;xxx是mac的username&a…...

深入理解动态绑定与多态

动态绑定介绍 Java中的动态绑定&#xff0c;是一种在程序运行时确定方法执行版本的过程。它与多态紧密联系。 在Java中&#xff0c;动态绑定通常发生在以下情况&#xff1a; 方法覆盖&#xff1a;当子类重写父类的一个方法时&#xff0c;调用该方法的行为会根据对象的实际类…...

【数据结构】二叉树总结篇

遍历 递归 递归三部曲&#xff1a; 1.参数和返回值 2.终止条件 3.单层逻辑&#xff08;遍历顺序&#xff09; var preorderTraversal function(root) { // 第一种let res[];const dfsfunction(root){if(rootnull)return ;//先序遍历所以从父节点开始res.push(root.val);//递归…...

Zookeeper 及 基于ZooKeeper实现的分布式锁

1 ZooKeeper 1.1 ZooKeeper 介绍 ZooKeeper是一个开源的分布式协调服务&#xff0c;它的设计目标是将那些复杂且容易出错的分布式一致性服务封装起来&#xff0c;构成一个高效可靠的原语集&#xff0c;并以一系列简单易用的接口提供给用户使用。 原语&#xff1a;操作系统或…...

内嵌踢脚线怎么做能省钱?

家里装修内嵌踢脚线应该怎么做&#xff1f;哪种做法更经济&#xff1f; 先回答内嵌踢脚线应该怎么做&#xff1f; 做内嵌踢脚线有两种办法&#xff0c;简单点来说就是前凸和后挖。 前凸是踢脚线安到原来墙面上&#xff0c;踢脚线是从墙面上凸出来的&#xff0c;想要实现内嵌的效…...

DeepSeek集成到VScode工具,让编程更高效

DeepSeek与VScode的强强联合&#xff0c;为编程效率树立了新标杆。 DeepSeek&#xff0c;一款卓越的代码搜索引擎&#xff0c;以其精准的索引和高速的检索能力&#xff0c;助力开发者在浩瀚的代码海洋中迅速定位关键信息。 集成至VScode后&#xff0c;开发者无需离开熟悉的编辑…...

大模型应用:多轮对话(prompt工程)

概述 在与大型语言模型&#xff08;如ChatGPT&#xff09;交互的过程中&#xff0c;我们常常体验到与智能助手进行连贯多轮对话的便利性。那么&#xff0c;当我们开启一个新的聊天时&#xff0c;系统是如何管理聊天上下文的呢&#xff1f; 一、初始上下文的建立 1. 创建新会…...

洛谷 P1601 A+B Problem(高精)详解c++

我们之前做题碰到的数据范围一般是10^9&#xff0c;多点会达到10^18级别&#xff0c;处理10^9用int就可以存下&#xff0c;10^18次方要用到long long&#xff0c;接着解决加减乘除的问题&#xff0c;但是当数据范围达到了10^10^6的时候&#xff0c;当数据的值特别⼤&#xff0c…...

【云原生】Spring Cloud是什么?Spring Cloud版本介绍

什么是SpringCloud 上一章节介绍了总体的SpringCloud的总体学习章节&#xff0c;因为最近项目刚好需要用到SpringCloud来搭建微服务项目、所以就跟着大家一起来再学习巩固下SpringCloud的相关知识 SpringCloud是基于SpringBoot提供了一套微服务解决方案&#xff0c;包括服务注…...

最节省成本的架构方案:无服务器架构

无服务器架构&#xff08;Serverless Architecture&#xff09;是一种颠覆性的云计算执行模型&#xff0c;它允许开发者专注于编写和部署代码&#xff0c;而无需担心底层服务器基础设施的管理。这种架构以其按需付费、自动伸缩和简化部署等优势&#xff0c;在成本优化方面表现出…...

C++入门续集:

1. 缺省参数&#xff1a; 我们看我们的上图&#xff0c;我们可以看我们的函数Func&#xff0c;我们可以看到我们的函数里面的参数写的是int a 0&#xff1b;这个写法是我们没有见过的&#xff0c;我们之前在C语言里面只见到过说是函数里面会设置参数&#xff0c;但是参数是没有…...

线代[9]|线性代数主要内容及其发展简史(任广千《线性代数的几何意义》的附录1)

文章目录 向量行列式矩阵线性方程组二次型 向量 向量又称为矢量&#xff0c;最初应用与物理学。很多物理量如力、速度、位移以及电场强度、磁感应强度等等都是向量。大约公元前350年前&#xff0c;古希腊著名学者亚里士多德就知道了力可以表示成向量&#xff0c;两个力的组合作…...

C++ Primer 动态内存与智能指针

欢迎阅读我的 【CPrimer】专栏 专栏简介&#xff1a;本专栏主要面向C初学者&#xff0c;解释C的一些基本概念和基础语言特性&#xff0c;涉及C标准库的用法&#xff0c;面向对象特性&#xff0c;泛型特性高级用法。通过使用标准库中定义的抽象设施&#xff0c;使你更加适应高级…...

AI在原型设计中的革命性应用:效率与创新的双重突破

引言 在数字化转型加速的今天&#xff0c;产品开发周期被压缩至前所未有的程度。原型设计作为产品开发的核心环节&#xff0c;其效率和质量直接影响最终产品的市场竞争力。传统原型设计流程依赖人工绘制、反复修改和用户测试&#xff0c;耗时且成本高昂。而人工智能&#xff0…...

网络学习(四)HTTPS中,SSL的单向认证与双向认证

目录 一、什么是SSL&#xff1f;1.1 SSL 的主要功能1.2 SSL 的工作原理1.3 SSL 的核心组件1.4 SSL 的应用场景1.5 SSL 与 TLS 的区别 二、SSL 单向认证、双向认证2.1 SSL 单向认证2.2 SSL 双向认证2.3 总结&#xff1a;SSL 单向认证和双向认证的区别 一、什么是SSL&#xff1f;…...

分类任务和回归任务的区别

分类任务和回归任务是机器学习中两种常见的监督学习任务&#xff0c;尽管它们都属于预测性的分析&#xff0c;但它们的目标和应用场景存在显著的差异。 分类任务 定义&#xff1a;分类任务是指将输入样本映射到一个有限且离散的类别集合中的过程。目标是对数据进行分类&#…...

android接入rocketmq

一 前言 RocketMQ 作为一个功能强大的消息队列系统&#xff0c;不仅支持基本的消息发布与订阅&#xff0c;还提供了顺序消息、延时消息、事务消息等高级功能&#xff0c;适应了复杂的分布式系统需求。其高可用性架构、多副本机制、完善的运维管理工具&#xff0c;以及安全控制…...

V4L2框架基础

一、V4L2视频设备驱动基础 1.V4L2是专门为Linux设备设计的整合视频框架&#xff08;其主要核心在Linux内核&#xff0c;相当于Linux操作系统上层的视频源捕获驱动框架&#xff09;。为上层访问系统底层的视频设备提供一个统一的标准接口。V4L2驱动框架能够支持多种类型&#x…...

【微知】如何通过mlxlink查看Mellanox网卡和光模块相关的信息?( mlxlink -d 01:00.0 -m)

背景 通过mlxlink可以查看Mellanox网卡的一些链路信息和硬件信息&#xff0c;也可以查看所插入的光模块的一些信息。 兄弟篇通过ethtool查看的方法&#xff1a;如何查看Mellanox网卡上的光模块的信息&#xff1f; 命令 mlxlink -d 01:00.0 -mman手册介绍&#xff1a; 如果…...

使用pytorch和opencv根据颜色相似性提取图像

需求&#xff1a;将下图中的花朵提取出来。 代码&#xff1a; import cv2 import torch import numpy as np import timedef get_similar_colors(image, color_list, threshold):# 将图像和颜色列表转换为torch张量device torch.device(cuda if torch.cuda.is_available() el…...

HTML label 标签使用

点击 <label> 标签通常会使与之关联的表单控件获得焦点或被激活。 通过正确使用 <label> 标签&#xff0c;可以使表单更加友好和易于使用&#xff0c;同时提高整体的可访问性。 基本用法 <label> 标签通过 for 属性与 id 为 username 的 <input> 元素…...

SQL注入的分类靶场实践

前言 SQL 注入&#xff08;SQL Injection&#xff09;是一种常见且危险的 Web 安全漏洞&#xff0c;攻击者通过在输入字段中插入恶意 SQL 代码&#xff0c;能够绕过应用程序的验证机制&#xff0c;直接操纵数据库。本文将介绍 SQL 注入的分类&#xff0c;并通过 Pikachu 靶场进…...

用matplotlib构建BI看板:Superset插件开发实战

目录 前言&#xff1a;当经典可视化库遇见BI航母 一、Superset插件架构精要 1.1 核心模块解析 1.2 插件通信机制 二、开发环境准备 2.1 依赖矩阵 三、开发自定义可视化插件 3.1 插件脚手架 3.2 渲染引擎适配 四、Superset深度集成 4.1 控制面板配置 4.2 动态参数传递…...

【Linux】之【Bug】VMware 虚拟机开机 一直卡在黑屏左上角下划线闪烁界面

解决 参考&#xff1a; 解决Ubuntu20.04 开机黑屏光标闪烁进不去系统 Centos根目录100%解决思路 当前界面 ctrlaltf3-f6 暂时进入终端界面 df -h 查看发现根目录 磁盘空间已满 执行命令 查看当前目录占用内存明细 sudo du -h -x --max-depth1清理无用的大内存文件 或者安装…...

【练习】【链表】力扣热题100 19. 删除链表的倒数第 N 个结点

题目 删除链表的倒数第 N 个结点 给你一个链表&#xff0c;删除链表的倒数第 n 个结点&#xff0c;并且返回链表的头结点。 示例 1&#xff1a; 输入&#xff1a;head [1,2,3,4,5], n 2 输出&#xff1a;[1,2,3,5] 示例 2&#xff1a; 输入&#xff1a;head [1], n 1 输出&…...

SQL-labs13-16闯关记录

http://127.0.0.1/sqli-labs/less-13/ 基于POST单引号双注入变形 1&#xff0c;依然是一个登录框&#xff0c;POST型SQL注入 2&#xff0c;挂上burpsuite&#xff0c;然后抓取请求&#xff0c;构造请求判断漏洞类型和闭合条件 admin 发生了报错&#xff0c;根据提示闭合方式是(…...

【Linux】进程信号——信号保存和信号捕捉

文章目录 信号保存信号相关的概念信号是如何保存的呢&#xff1f;有关信号保存的系统调用sigprocmask信号的增删查改查看pending表验证接口 信号捕捉用户态与内核态信号捕捉流程 总结 信号保存 信号相关的概念 信号递达&#xff1a;指 操作系统 将一个信号&#xff08;Signal…...

任务9:交换机基础及配置

CSDN 原创主页&#xff1a;不羁https://blog.csdn.net/2303_76492156?typeblog 一、交换机基础 交换机的概念&#xff1a;交换机是一种网络设备&#xff0c;用于连接多台计算机或网络设备&#xff0c;实现数据包在局域网内的快速交换。交换机基于MAC地址来转发数据包&#x…...

【DFS/回溯算法】2016年蓝桥杯真题之路径之谜详解

目录&#xff1a; 1.题目描述&#xff1a; 输入格式 输出格式 2.题解&#xff1a; 3.详细c代码 1.题目描述&#xff1a; 小明冒充 X 星球的骑士&#xff0c;进入了一个奇怪的城堡。 城堡里边什么都没有&#xff0c;只有方形石头铺成的地面。 假设城堡地面是 nn 个方格。…...

深度学习R8周:RNN实现阿尔兹海默症(pytorch)

&#x1f368; 本文为&#x1f517;365天深度学习训练营中的学习记录博客&#x1f356; 原作者&#xff1a;K同学啊 数据集包含2149名患者的广泛健康信息&#xff0c;每名患者的ID范围从4751到6900不等。该数据集包括人口统计详细信息、生活方式因素、病史、临床测量、认知和功…...

字节跳动发布 Trae AI IDE!支持 DeepSeek R1 V3,AI 编程新时代来了!

3 月 3 日&#xff0c;字节跳动重磅发布国内首款 AI 原生集成开发环境&#xff08;AI IDE&#xff09;——Trae 国内版&#xff01; Trae 不只是一个传统的 IDE&#xff0c;它深度融合 AI&#xff0c;搭载 doubao-1.5-pro 大模型&#xff0c;同时支持DeepSeek R1 & V3&…...

智能合约安全指南 [特殊字符]️

智能合约安全指南 &#x1f6e1;️ 1. 安全基础 1.1 常见漏洞类型 重入攻击整数溢出权限控制缺陷随机数漏洞前后运行攻击签名重放 1.2 安全开发原则 最小权限原则检查-生效-交互模式状态机安全失败保护机制 2. 重入攻击防护 2.1 基本防护模式 contract ReentrancyGuarde…...

DeepSeek 全套资料pdf合集免费下载(持续更新)

有很多朋友都关注DeepSeek相关使用的教程资料&#xff0c;本站也一直持续分享DeepSeek 学习相关的pdf资料&#xff0c;由于比较零散&#xff0c;这篇文章主要就是做一个汇总&#xff0c;并且持续更新&#xff0c;让大家可以及时获取下载最新的相关DeepSeek的资料。 持续更新地…...

IDEA 接入 Deepseek

在本篇文章中&#xff0c;我们将详细介绍如何在 JetBrains IDEA 中使用 Continue 插件接入 DeepSeek&#xff0c;让你的 AI 编程助手更智能&#xff0c;提高开发效率。 一、前置准备 在开始之前&#xff0c;请确保你已经具备以下条件&#xff1a; 安装了 JetBrains IDEA&…...

将md格式转jupyter并运行

将md格式转jupyter并运行 有时候我们需要将这种文档以学习的形式记笔记到jupyter中&#xff08;任务&#xff09; 但是内容太多了&#xff0c;一个一个粘贴又不方便&#xff0c;怎么办呢&#xff1f; 发现直接粘贴到md中是带格式的&#xff01;&#xff01;&#xff01; 那…...

SOUI基于Zint生成EAN码

EAN码广泛应用与欧洲的零售业。包括EAN-2、EAN-5、EAN-8和EAN-12码。分别编码 2、5、7 或 12 位数字。此外&#xff0c;可以使用 字符将 EAN-2 和 EAN-5 附加符号添加到 EAN-8 和 EAN-13 符号中&#xff0c;就像 UPC 符号一样。 EAN-8校验码计算&#xff1a; 从左往右奇数位的…...