- Framework7 教程
- Framework7 - 首页
- Framework7 - 概述
- Framework7 - 环境
- Framework7 组件
- Framework7 - 布局
- Framework7 - 导航栏
- Framework7 - 工具栏
- Framework7 - 搜索栏
- Framework7 - 状态栏
- Framework7 - 侧边面板
- Framework7 - 内容块
- Framework7 - 布局网格
- Framework7 - 覆盖层
- Framework7 - 预加载器
- Framework7 - 进度条
- Framework7 - 列表视图
- Framework7 - 手风琴
- Framework7 - 卡片
- Framework7 - 芯片
- Framework7 - 按钮
- Framework7 - 操作按钮
- Framework7 - 表单
- Framework7 - 标签页
- Framework7 - Swiper 滑块
- Framework7 - 图片浏览器
- Framework7 - 自动完成
- Framework7 - 选择器
- Framework7 - 日历
- Framework7 - 刷新
- Framework7 - 无限滚动
- Framework7 - 消息
- Framework7 - 消息栏
- Framework7 - 通知
- Framework7 - 懒加载
- Framework7 样式
- Framework7 - 颜色主题
- Framework7 - 分割线
- Framework7 模板
- Framework7 - 模板概述
- Framework7 - 自动编译
- Framework7 - Template7 页面
- Framework7 快速点击
- Framework7 - 活动状态
- Framework7 - 长按事件
- Framework7 - 触摸涟漪
- Framework7 有用资源
- Framework7 - 快速指南
- Framework7 - 有用资源
- Framework7 - 讨论
Framework7 - 通知布局
描述
虽然通知是使用 JavaScript 添加的,但为了自定义样式,理解它们是必要的。当您添加通知时,Framework7 会将特殊的 notifications div 与列表块一起添加到 body 中。此情况下的通知布局如下所示:
<body> ... <div class = "notifications list-block media-list"> <ul> <!-- Single notification item --> <li class = "notification-item"> <div class = "item-content"> <div class = "item-media"> <!-- Notification media --> </div> <div class = "item-inner"> <div class = "item-title-row"> <div class = "item-title"> <!-- Notification title goes here --> </div> <div class = "item-after"> <!-- Notification close icon --> <a href = "#" class = "close-notification"></a> </div> </div> <div class = "item-subtitle"> <!-- Notification subtitle goes here --> </div> <div class = "item-text"> <!-- Notification message goes here --> </div> </div> </div> </li> </ul> </div> </body>
自定义通知将具有以下布局:
<body> ... <div class = "notifications list-block media-list"> <ul> <!-- Single notification item --> <li class = "notification-item"> <!-- Custom notification content goes here --> </li> </ul> </div> </body>
framework7_notifications.htm
广告