frontend/examking-app/plugins/uview-ui/components/u-collapse/u-collapse.vue

(开头部分) 2KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

<template>
	<view class="u-collapse">
		<slot />
	</view>
</template>

<script>
	/**
	 * collapse 手风琴
	 * @description 通过折叠面板收纳内容区域
	 * @tutorial https://www.uviewui.com/components/collapse.html
	 * @property {Boolean} accordion 是否手风琴模式(默认true)
	 * @property {Boolean} arrow 是否显示标题右侧的箭头(默认true)
	 * @property {String} arrow-color 标题右侧箭头的颜色(默认#909399)
	 * @property {Object} head-style 标题自定义样式,对象形式
	 * @property {Object} body-style 主体自定义样式,对象形式
	 * @property {String} hover-class 样式类名,按下时有效(默认u-hover-class)
	 * @event {Function} change 当前激活面板展开时触发(如果是手风琴模式,参数activeNames类型为String,否则为Array)
	 * @example <u-collapse></u-collapse>
	 */
	export default {
		name:"u-collapse",
		props: {
			// 是否手风琴模式
			accordion: {
				type: Boolean,
				default: true
			},
			// 头部的样式
			headStyle: {
				type: Object,
				default () {
					return {}
				}
			},
			// 主体的样式
			bodyStyle: {
				type: Object,
				default () {
					return {}
				}
			},
			// 每一个item的样式
			itemStyle: {
				type: Object,
				default () {
					return {}
				}
			},
			// 是否显示右侧的箭头
			arrow: {
				type: Boolean,
				default: true
			},
			// 箭头的颜色
			arrowColor: {
				type: String,
				default: '#909399'
			},
			// 标题部分按压时的样式类,"none"为无效果
后面还有 39 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。