분류, 패키지 및 저장소 검색

flutter_week_view 표지
패키지 상세v1.4.5

flutter_week_view

이벤트를 표시할 수 있고 스크롤 가능하며 확대/축소가 가능한 고도로 사용자 정의 가능한 주간 보기(또는 일간 보기)를 표시합니다!

AndroidiOSWebmacOSWindowsLinux
30일 다운로드
1.7천
좋아요
121
Pub 점수
150

패키지 설치

flutter pub add flutter_week_view

패키지 개요

공개 정보를 바탕으로 생성한 선택 가이드입니다.

FlutterWeekView는 주간 또는 일일 보기로 표시되는 매우 사용자 정의 가능한 캘린더 위젯으로, 부드러운 스크롤링과 줌 기능을 통해 사용자가 이벤트를 시각화하고 관리할 수 있게 해줍니다. 동적 이벤트 렌더링, 직관적인 탐색, 여러 플랫폼에서 반응형 디자인을 지원합니다. 스케줄링 애플리케이션에 적합하며, 스타일 및 동작에 대한 광범위한 사용자 정의 옵션을 제공합니다. 패키지는 Flutter 앱에 원활하게 통합되며, 공급자의 지속적인 유지보수가 이루어지고 있습니다.

사용 사례

  • 예약 일정 조정
  • 일상 작업 관리
  • 이벤트 타임라인 표시
  • 업무 주간 계획 수립
  • 캘린더 대시보드 만들기

주요 기능

  • 사용자 정의 가능한 주/일 보기
  • 드래그 앤 드롭을 사용한 이벤트 렌더링
  • 확대/축소 기능
  • 부드러운 수평/수직 스크롤
  • 다중 플랫폼에 걸친 반응형 디자인
  • 확장 가능한 스타일 옵션

적합한 대상

  • 생산성 앱
  • 캘린더 애플리케이션
  • 작업 관리 도구
  • 시간 추적 소프트웨어
  • 이벤트 기획 플랫폼

고려 사항

  • 대규모 이벤트 데이터 세트를 신중하게 처리해야 합니다
  • 밀도 높은 캘린더에 대한 성능 최적화가 필요할 수 있습니다
  • 제한된 내장 지역화 지원
  • 사용자 정의 스타일링은 고급 플러터 지식이 필요할 수 있습니다

원본 README

연결된 소스 저장소의 README 원문 스냅샷입니다. 최신 내용은 저장소에서 확인하세요.

Flutter Week View

Likes Pub points

Displays a highly customizable week view (or day view) which is able to display events, to be scrolled, to be zoomed-in & out and a lot more !

Flutter Week View is highly inspired by Android Week View.

Getting Started

Getting started with Flutter Week View is very straight forward. You have the choice between two widgets : DayView and WeekView. Use the first one to display a single day and use the second one to display multiple days.

Example

If you want a real project example, you can check this one on Github.

Day View

Snippet :

// Let's get two dates :
DateTime now = DateTime.now();
DateTime date = DateTime(now.year, now.month, now.day);

// And here's our widget !
return DayView(
  date: now,
  events: [
    FlutterWeekViewEvent(
      title: 'An event 1',
      description: 'A description 1',
      start: date.subtract(Duration(hours: 1)),
      end: date.add(Duration(hours: 18, minutes: 30)),
    ),
    FlutterWeekViewEvent(
      title: 'An event 2',
      description: 'A description 2',
      start: date.add(Duration(hours: 19)),
      end: date.add(Duration(hours: 22)),
    ),
    FlutterWeekViewEvent(
      title: 'An event 3',
      description: 'A description 3',
      start: date.add(Duration(hours: 23, minutes: 30)),
      end: date.add(Duration(hours: 25, minutes: 30)),
    ),
    FlutterWeekViewEvent(
      title: 'An event 4',
      description: 'A description 4',
      start: date.add(Duration(hours: 20)),
      end: date.add(Duration(hours: 21)),
    ),
    FlutterWeekViewEvent(
      title: 'An event 5',
      description: 'A description 5',
      start: date.add(Duration(hours: 20)),
      end: date.add(Duration(hours: 21)),
    ),
  ],
  style: const DayViewStyle.fromDate(
    date: now,
    currentTimeCircleColor: Colors.pink,
  ),
);

Result :

Week view

Snippet :

// Let's get two dates :
DateTime now = DateTime.now();
DateTime date = DateTime(now.year, now.month, now.day);

// And here's our widget !
return WeekView(
  dates: [date.subtract(Duration(days: 1)), date, date.add(Duration(days: 1))],
  events: [
    FlutterWeekViewEvent(
      title: 'An event 1',
      description: 'A description 1',
      start: date.subtract(Duration(hours: 1)),
      end: date.add(Duration(hours: 18, minutes: 30)),
    ),
    FlutterWeekViewEvent(
      title: 'An event 2',
      description: 'A description 2',
      start: date.add(Duration(hours: 19)),
      end: date.add(Duration(hours: 22)),
    ),
    FlutterWeekViewEvent(
      title: 'An event 3',
      description: 'A description 3',
      start: date.add(Duration(hours: 23, minutes: 30)),
      end: date.add(Duration(hours: 25, minutes: 30)),
    ),
    FlutterWeekViewEvent(
      title: 'An event 4',
      description: 'A description 4',
      start: date.add(Duration(hours: 20)),
      end: date.add(Duration(hours: 21)),
    ),
    FlutterWeekViewEvent(
      title: 'An event 5',
      description: 'A description 5',
      start: date.add(Duration(hours: 20)),
      end: date.add(Duration(hours: 21)),
    ),
  ],
);

Result :

Options

Common options

Here are the options that are available for both DayView and WeekView :

  • events Events to display.
  • style Allows you to style your widget. A lot of different styles are available so don't hesitate to try them out !
  • hourColumnStyle Same, it allows you to style the hour column on the left.
  • controller Controllers allow you to manually change the zoom settings.
  • inScrollableWidget Whether to put the widget in a scrollable widget (disable if you want to manage the scroll by yourself).
  • minimumTime The minimum hour and minute to display in a day.
  • maximumTime The maximum hour and minute to display in a day.
  • initialTime The initial hour and minute to put the widget on.
  • userZoomable Whether the user is able to (un)zoom the widget.
  • currentTimeIndicatorBuilder Allows you to change the default current time indicator (rule and circle).
  • onHourColumnTappedDown Provides a tapped down callback for the hour column. Pretty useful if you want your users to add your own events at a specific time.
  • onBackgroundTappedDown Provides a similar callback as the above, but when the user clicks on the background (an empty region of the calendar).
  • onDayBarTappedDown Provides a tapped down callback for the day bar.
  • dragAndDropOptions Enables drag-and-drop of events.
  • resizeEventOptions Enables resizing events, by dragging the bottom of the event up/down.
  • eventWidgetBuilder The widget builder that customizes how events are rendered.
Flutter day view

Here are the specific options of DayView :

  • date The widget date.
  • dayBarStyle The day bar style.
Flutter week view

Here are the specific options of WeekView :

  • dates The widget dates.
  • dayViewStyleBuilder The function that allows to build a Day View style according to the provided date.
  • dayBarStyleBuilder The function that allows to build a Day Bar style according to the provided date.

Please note that you can create a WeekView instance using a builder. All previous options are still available but you don't need to provide the dates list. However, you need to provide a DateCreator (and a date count if you can, if it's impossible for you to do it then scrollToCurrentTime will not scroll to the current date).

Contributions

You have a lot of options to contribute to this project ! You can :

카테고리

소스 저장소

이 패키지를 사용하는 프로젝트

아직 데이터가 없습니다.