Bdaya-Dev / flutter_gantt_chart

Flutter Gantt chart UI library
BSD 3-Clause "New" or "Revised" License
11 stars 9 forks source link

Added parameter to customize weekDay decoration #4

Closed mauriziopinotti closed 1 year ago

mauriziopinotti commented 2 years ago

Hi,

I added a new parameter weekHeaderDecoration to make the view more customizable, e.g.

        weekHeaderDecoration: BoxDecoration(
          color: primaryColor,
          border: const BorderDirectional(
            end: BorderSide(color: Colors.white),
          ),
        ),

would produce

Screenshot from 2022-07-28 11-30-20

I know there's a weekHeaderBuilder already, but I think that's too much effort to override that altogether, some users might want to "use the default with a little help".

ahmednfwela commented 2 years ago

i was thinking about providing a class per customization area to handle all its possible styles, e.g.

class WeekHeaderAreaStyle {
    ... weekHeaderBuilder;
    ... weekHeaderDecoration;
}

and then pass it to the GanttView constructor instead

GanttView(
  weekHeaderStyle: WeekHeaderAreaStyle( ... )
)