FLUTTER ECOSYSTEM

victorbonnet/flutter_web_browser

用於 Flutter 的外掛程式,可透過 Chrome 自訂標籤頁和 SFSafariViewController 開啟網頁

flutter_web_browser 專案封面
Stars
66
Forks
52
最近推送(UTC)
2025年3月15日
專案狀態
未封存
Victor Bonnet GitHub avatar
GITHUB User

Victor Bonnet ↗

Staff Engineer · AI Research Lead · Builder I'm a builder first. Started shipping mobile apps in 2011, got acquired in 2012, never stopped building since.

NexthinkLausanne
語言DartObjective-CJavaRuby

此儲存庫發佈的套件

使用的依賴

依賴清單 1 項
  • flutter{"sdk":"flutter"}

原始 README

以下為英文專案原文快照,最新內容請造訪 GitHub。

展開 / 收合專案 README

flutter_web_browser

Pub

A flutter plugin to open a web page with Chrome Custom Tabs & SFSafariViewController.

This plugin is under development, APIs might change.

Getting Started

Installation

Install the library from pub:

dependencies:
  flutter_web_browser: "^0.17.3"
Import the library
import 'package:flutter_web_browser/flutter_web_browser.dart';
Open the web page
FlutterWebBrowser.openWebPage(
  url: "https://flutter.io/",
  customTabsOptions: const CustomTabsOptions(
    colorScheme: CustomTabsColorScheme.dark,
    toolbarColor: Colors.deepPurple,
    secondaryToolbarColor: Colors.green,
    navigationBarColor: Colors.amber,
    shareState: CustomTabsShareState.on,
    instantAppsEnabled: true,
    showTitle: true,
    urlBarHidingEnabled: true,
  ),
  safariVCOptions: const SafariViewControllerOptions(
    barCollapsingEnabled: true,
    preferredBarTintColor: Colors.green,
    preferredControlTintColor: Colors.amber,
    dismissButtonStyle: SafariViewControllerDismissButtonStyle.close,
    modalPresentationCapturesStatusBarAppearance: true,
  ),
);

License

This project is licensed under the terms of the MIT license.