搜尋套件、儲存庫與 APP 分類

套件詳情v0.6.0

mdc_web

Material Components Web JavaScript 庫的 Dart 包裝器。

Web
近 30 天下載
7440
喜歡數
20
Pub 分數
130

安裝套件

flutter pub add mdc_web

套件介紹

根據套件公開資料產生的選型評估,僅供參考。

mdc_web 套件是 Material Components for Web (MDC-Web) JavaScript 庫的 Dart 包裝,讓開發者能在 Flutter 網頁應用中使用 Material Design 組件。它提供一組豐富的預建 UI 元素,例如按鈕、卡片與文字欄位,並依照 Google 的 Material Design 指引進行樣式設計。透過將 Dart 與 MDC-Web 的 JavaScript 實現連結,確保網頁介面的一致性與高品質,同時大幅減少自訂樣式的需要。此套件非常適合希望在 Flutter 網頁生態系統中使用原生 Material Design 組件的團隊。

適用情境

  • 在Flutter網頁應用中整合Material Design組件
  • 建構響應式、現代的網頁介面
  • 透過 Material Design 提升 UI 一致性
  • 在 Dart 中利用現有的 MDC-Web 組件
  • 建立跨平台網路體驗

主要特色

  • MDC-Web JavaScript 的 Dart 接口
  • 符合 Material Design 的元件
  • 與 Flutter Web 的無縫整合
  • 支援 Web 特有的 Material 功能
  • 輕量且模組化

適合對象

  • Flutter web 開發人員
  • 使用 Material Design 的團隊
  • 需要原生 Web 組件支援的專案
  • 熟悉 MDC-Web 的開發者
  • 需要一致網頁 UI 的應用

使用建議

  • 需要 JavaScript 知識以進行進階自定義
  • 僅限Web平台
  • JavaScript 互操作可能帶來的效能開銷
  • 依賴外部 MDC-Web 庫
  • 可能需要手動處理非同步初始化

原始 README

以下為關聯原始碼儲存庫的 README 原文快照,最新內容請造訪原始碼儲存庫。

pub points

mdc_web

Dart wrapper for the material-components-web javascript library.

Usage

In your index.html, include the script just before the main.dart.js script.

<!--
  This exposes the `mdc` global variable required by this package.
  For debugging purposes you can replace the ".min.js" extension with ".js".
-->
<script defer src="packages/mdc_web/material-components-web.min.js"></script>
<script defer src="main.dart.js"></script>

Now in your dart application you can use all of the MDC* classes as described by the Material Design Web component reference.

Documentation

Each class and notable members are documented. Class documentation includes links to corresponding (if available):

Limitations

Only the components themselves were mirrored. Their foundation and adapter classes are currently beyond the scope of this package as they are for deep customization within other web frameworks. However, the base MDCFoundation and MDCComponent classes are included. This limitation should not affect most implementations, but if it does affect you, please let me know.

所屬分類

依賴

依賴清單 2 項

  • js^0.6.1+1
  • meta^1.1.7

原始碼儲存庫

使用此套件的專案

暫無相關資料。