standard_ui_core 0.0.6

SDKflutter
Platformandroidioswindowslinuxmacosweb

This package contain standarization to make application using flutter framework. it will make easier to make boring component like button or form.

Project Title

Standard UI Core

Table Of Contents

Description

Flutter simple UI core. This plugin is about UI only. All of the UI here are header text, body text, buttons, chips, FAB and form. You can customize their color and make your own color. This plugin is focused on making your development fast and easy while still having a beautiful UI. More components will added shortly.

Vision

Fast and Easy while develop boring component without any UI sacrifice

Getting started

WARNING: BREAKING IN VERSION 0.0.6

use ScreenSizeInitializer or ScreenSizeCustomInitializer to set size. Default will be width 120 and height 120 (view example). Primary button and secondary button use ValueListenableBuilder to make it responsive

return MaterialApp(
      title: 'Standard UI Core',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: const ScreenSizeInitializer(
          child: MyHomePage(title: 'Standard UI Core Demo')
      ),
    );

You can change color default, there are many color default thay i prepare, they are : neutral color, primary color, secondary color, success color, danger color, grey color, and blue-grey color all with 9 shade, example primary500, danger300. Here to change them :

void setColorPrimary() {
  InitialValue.setPrimaryColor(
    /// InitialValue.setPrimaryColor can be change to any group color you want to change  
    /// here just change primary 500 and primary700
      primary500: const Color(0xff00e9ff),
      primary700: const Color(0xff7FFFD4)
  );
}  

You can change default size for any header text and body text, just use this function

void setInitialBodyFontSize(){
  InitialValue.setBodyFontSize(
    /// Here to change body font size   
      bodyTextXxl: 64,
      bodyTextXl: 24,
      bodyTextL: 52,
      bodyTextM: 48,
      bodyTextS: 40,
      bodyTextXs: 38,
      bodyTextXxs: 24
  ); }  

Components

Text

Header Text

for the default size is H3 and color is ColorTheme.black

TypeDefault ColorDefault Size
H1ColorTheme.black32
H2ColorTheme.black28
H3ColorTheme.black24
H4ColorTheme.black20
H5ColorTheme.black16
H6ColorTheme.black12

Body Text

for the default size is bodyTextS and color is ColorTheme.black

TypeDefault ColorDefault Size
bodyTextXxlColorTheme.black28
bodyTextXlColorTheme.black24
bodyTextLColorTheme.black20
bodyTextMColorTheme.black16
bodyTextSColorTheme.black12
bodyTextXsColorTheme.black10
bodyTextXxsColorTheme.black8

Button

Button State

  • Enable
  • Loading
  • Disable

Button Type

  • Primary Button
PropertiesDefault Value
titlenull
marginEdgeInsets.symmetric(vertical: 4)
buttonSizeButtonSize.fullWidth
borderRadius12
elevation1
isLoadingfalse
isDisabledfalse
backgroundColorColorTheme.primary700
disabledBackgroundColorColorTheme.grey700
titleColorColorTheme.black
disabledTitleColorColorTheme.black
splashColorColorTheme.white
disabledSplashColorColors.transparent
borderColorColorTheme.primary500
disabledBorderColorColorTheme.black
loadingColortitleColor ?? ColorTheme.black
loadingWidgetCircularProgressIndicator()
onTap(){}
iconPositionIconPosition.left
iconWidgetnull
  • Secondary Button
PropertiesDefault Value
titlenull
marginEdgeInsets.symmetric(vertical: 4)
buttonSizeButtonSize.fullWidth
borderRadius12
elevation1
isLoadingfalse
isDisabledfalse
backgroundColorColorTheme.white
disabledBackgroundColorColorTheme.grey700
titleColorColorTheme.black
disabledTitleColorColorTheme.black
splashColorColorTheme.primary500
disabledSplashColorColors.transparent
borderColorColorTheme.primary500
disabledBorderColorColorTheme.black
loadingColortitleColor ?? ColorTheme.black
loadingWidgetCircularProgressIndicator()
onTap(){}
iconPositionIconPosition.left
iconWidgetnull
  • Tertiary Button
PropertiesDefault Value
titlenull
marginEdgeInsets.symmetric(vertical: 4)
isLoadingfalse
isDisabledfalse
titleColorColorTheme.black
disabledTitleColorColorTheme.black
onTap(){}

Chip

Chip Size

  • large
  • medium
  • small

Chip Properties

PropertiesDefault Value
titlenull
marginEdgeInsets.symmetric(vertical: 4)
chipSizeChipSize.medium
borderRadius12
elevation1
isDisabledfalse
isUsingCloseIconfalse
backgroundColorColorTheme.primary700
disabledbackgroundColorColorTheme.grey700
titleColorColorTheme.black
disabledTitleColorColorTheme.black
splashColorColorTheme.white
borderColorColorTheme.primary500
disabledBorderColorColorTheme.black
onTap(){}
onTapClose(){}
iconCloseWidgetIcons.close
iconWidgetnull

Floating Action Button

FAB Properties

PropertiesDefault Value
titlenull
iconWidgetSizedBox()
isLoadingfalse
isDisabledfalse
onTap(){}
backgroundColorColorTheme.primary700
disabledbackgroundColorColorTheme.grey700
titleColorColorTheme.black
disabledTitleColorColorTheme.black
loadingColortitleColor ?? ColorTheme.black
elevation1
iconPositionIconPosition.left

Form

Form Properties

PropertiesDefault Value
marginnull
hintTextnull
controllernull
initialValuenull
labelTextnull
obscureTextfalse
enabledtrue
autofocusfalse
readOnlyfalse
labelPositionLabelPosition.left
maxLines1
prefixIconnull
suffixIconnull
hintTextnull
textCapitalizationTextCapitalization.none
keyboardTypenull
inputFormattersnull
onTapnull
onChangednull
onFieldSubmittednull
hintStyleBodyTextStyle.textStyle( color: ColorTheme.grey700, fontSize: StandardFontSize.bodyTextXs)
labelColorColorTheme.black
disableLabelColorColorTheme.grey700
textColorColorTheme.black
disableTextColorColorTheme.grey700
focusedColorColorTheme.primary500
errorColorColorTheme.danger500
disabledColorColorTheme.grey500
borderColorColorTheme.black
errorMaxLines2
errorStyleTextStyle(color: ColorTheme.danger500,fontSize: StandardFontSize.bodyTextS)

To Do / Roadmap

Version 1.0.0

  • More Type of Form
  • Card Components
  • Avatar

Information

Github Repo