返回介绍

Material Components widgets

发布于 2019-12-09 21:31:26 字数 65331 浏览 1135 评论 0 收藏 0

Visual, behavioral, and motion-rich widgets implementing the Material Design guidelines.

See more widgets in the widget catalog.

App structure and navigation

Scaffold

Implements the basic Material Design visual layout structure. This class provides APIs for showing drawers, snack bars, and bottom sheets.

Documentation
Appbar

A Material Design app bar. An app bar consists of a toolbar and potentially other widgets, such as a TabBar and a FlexibleSpaceBar.

Documentation
BottomNavigationBar

Bottom navigation bars make it easy to explore and switch between top-level views in a single tap. The BottomNavigationBar widget implements this component.

Documentation
TabBar

A Material Design widget that displays a horizontal row of tabs.

Documentation
TabBarView

A page view that displays the widget which corresponds to the currently selected tab. Typically used in conjunction with a TabBar.

Documentation
MaterialApp

A convenience widget that wraps a number of widgets that are commonly required for applications implementing Material Design.

Documentation
WidgetsApp

A convenience class that wraps a number of widgets that are commonly required for an application.

Documentation
Drawer

A Material Design panel that slides in horizontally from the edge of a Scaffold to show navigation links in an application.

Documentation
SliverAppBar

A material design app bar that integrates with a CustomScrollView.

Documentation

Buttons

RaisedButton

A Material Design raised button. A raised button consists of a rectangular piece of material that hovers over the interface.

Documentation
FloatingActionButton

A floating action button is a circular icon button that hovers over content to promote a primary action in the application. Floating action buttons are most commonly used in the Scaffold.floatingActionButton field.

Documentation
FlatButton

A flat button is a section printed on a Material Components widget that reacts to touches by filling with color.

Documentation
IconButton

An icon button is a picture printed on a Material widget that reacts to touches by filling with color (ink).

Documentation
DropdownButton

Shows the currently selected item and an arrow that opens a menu for selecting another item.

Documentation
PopupMenuButton

Displays a menu when pressed and calls onSelected when the menu is dismissed because an item was selected.

Documentation
ButtonBar

A horizontal arrangement of buttons.

Documentation

Input and selections

TextField

Touching a text field places the cursor and displays the keyboard. The TextField widget implements this component.

Documentation
Checkbox

Checkboxes allow the user to select multiple options from a set. The Checkbox widget implements this component.

Documentation
Radio

Radio buttons allow the user to select one option from a set. Use radio buttons for exclusive selection if you think that the user needs to see all available options side-by-side.

Documentation
Switch

On/off switches toggle the state of a single settings option. The Switch widget implements this component.

Documentation
Slider

Sliders let users select from a range of values by moving the slider thumb.

Documentation
Date & Time Pickers

Date pickers use a dialog window to select a single date on mobile. Time pickers use a dialog to select a single time (in the hours:minutes format) on mobile.

Documentation

Dialogs, alerts, and panels

SimpleDialog

Simple dialogs can provide additional details or actions about a list item. For example they can display avatars icons clarifying subtext or orthogonal actions (such as adding an account).

Documentation
AlertDialog

Alerts are urgent interruptions requiring acknowledgement that inform the user about a situation. The AlertDialog widget implements this component.

Documentation
BottomSheet

Bottom sheets slide up from the bottom of the screen to reveal more content. You can call showBottomSheet() to implement a persistent bottom sheet or showModalBottomSheet() to implement a modal bottom sheet.

Documentation
ExpansionPanel

Expansion panels contain creation flows and allow lightweight editing of an element. The ExpansionPanel widget implements this component.

Documentation
SnackBar

A lightweight message with an optional action which briefly displays at the bottom of the screen.

Documentation

Information displays

Image

A widget that displays an image.

Documentation
Icon

A Material Design icon.

Documentation

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文