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

from_to_time_picker 封面
套件詳情v1.2.2

from_to_time_picker

一個簡單的持續時間範圍選擇器,允許使用者以24小時和12小時格式選擇一天中的開始時間和結束時間

AndroidiOSWebmacOSWindowsLinux
近 30 天下載
61
喜歡數
61
Pub 分數
140

安裝套件

flutter pub add from_to_time_picker

套件介紹

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

一個簡單的 Flutter 套件,用於在一天內選擇時間範圍,允許使用者選擇開始和結束時間。支援跨多個平台的 24 小時和 12 小時格式。設計乾淨直覺,可輕鬆整合至需要持續時間輸入的應用程式中。非常適合用於排程、預訂或活動建立功能。

適用情境

  • 安排預約
  • 預訂時間槽
  • 活動策劃
  • 任務持續時間選擇
  • 時間追蹤

主要特色

  • 支援24小時與12小時時間格式
  • 簡單開始/結束時間選擇
  • 跨平台相容性
  • 可自訂的 UI
  • 與 Flutter 表單輕鬆整合

適合對象

  • 需要時間範圍輸入的應用程式開發者
  • 排程或日曆應用程式
  • 基於時間的工作流行動與網頁應用

使用建議

  • 僅限單日時間範圍
  • 無時區處理
  • 需要手動驗證邏輯時間順序

原始 README

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

From To Time Picker

Pub Version License: MIT GitHub code size in bytes

Simple interactive time range picker that enables users to pick a specific duration of the day by selecting start time and end time and defining whether it was AM or PM then it returns the duration chosen in 24H format.

time_picker_gif time_picker_gif

Usage

In the pubspec.yaml of your flutter project, add the following dependency:

dependencies:
...
from_to_time_picker: ^1.2.2

In your library add the following import:

import 'package:from_to_time_picker/from_to_time_picker.dart';

Example

default mode


showDialog(
        context: context,
        builder: (_) => FromToTimePicker(
              onTab: (from, to) {
                print('from $from to $to');
              },
            ));

customized mode

showDialog(
      context: context,
      builder: (_) => FromToTimePicker(
        onTab: (from, to) {
          print('from $from to $to');
        },
        dialogBackgroundColor: Color(0xFF121212),
        fromHeadlineColor: Colors.white,
        toHeadlineColor: Colors.white,
        upIconColor: Colors.white,
        downIconColor: Colors.white,
        timeBoxColor: Color(0xFF1E1E1E),
        timeHintColor: Colors.grey,
        timeTextColor: Colors.white,
        dividerColor: Color(0xFF121212),
        doneTextColor: Colors.white,
        dismissTextColor: Colors.white,
        defaultDayNightColor: Color(0xFF1E1E1E),
        defaultDayNightTextColor: Colors.white,
        colonColor: Colors.white,
        showHeaderBullet: true,
        headerText: 'Time available from 01:00 AM to 11:00 PM',
      ),
    );

Contributing

We accept the following contribution:

  • Improving documentation
  • Reporting issues
  • fixing bugs

Maintainer

  • Ahmed Elsarag

所屬分類

依賴

依賴清單 1 項

原始碼儲存庫

使用此套件的專案

暫無相關資料。