List Builder

mail@pastecode.io avatar
unknown
dart
2 years ago
7.5 kB
3
Indexable
Never
    ListView.builder(
                                              shrinkWrap: true,
                                              padding: EdgeInsets.zero,
                                              physics: ClampingScrollPhysics(),
                                              scrollDirection: Axis.vertical,
                                              itemCount: dataServices.length,
                                              itemBuilder: (BuildContext context, int index) => Container(
                                                child:  Padding(
                                                  padding: EdgeInsets.fromLTRB(0, 0, 0, 15),
                                                  child: Container(
                                                    width: MediaQuery.of(context).size.width,
                                                    decoration: BoxDecoration(),
                                                    child: Padding(
                                                      padding: EdgeInsets.fromLTRB(15, 0, 15, 0),
                                                      child: Row(
                                                        mainAxisSize: MainAxisSize.max,
                                                        crossAxisAlignment: CrossAxisAlignment.start,
                                                        children: [
                                                          Expanded(
                                                            child: Container(
                                                              width: 100,
                                                              decoration: BoxDecoration(),
                                                              child: Column(
                                                                mainAxisSize: MainAxisSize.max,
                                                                crossAxisAlignment: CrossAxisAlignment.start,
                                                                children: [
                                                                  Row(
                                                                    mainAxisSize: MainAxisSize.max,
                                                                    children: [
                                                                      SizedBox(
                                                                        width: 20,
                                                                        height: 20,
                                                                        child: new Radio(
                                                                          value: index,
                                                                          groupValue:  _radioValue,
                                                                          activeColor: FlutterFlowTheme.tertiaryColor,
                                                                          onChanged: _handleRadioValueChange,
                                                                          
                                                                        ),
                                                                      ),
                                                                      Padding(
                                                                        padding: EdgeInsets.fromLTRB(10,0,0,0),
                                                                            
                                                                        child: Text(
                                                                          dataServices[index].name,
                                                                          textScaleFactor: 1.0,
                                                                          style: FlutterFlowTheme .bodyText1.override(
                                                                            fontFamily: 'Poppins',
                                                                            color: FlutterFlowTheme.greyDark,
                                                                            fontWeight: FontWeight.w500,
                                                                          ),
                                                                        ),
                                                                      )
                                                                    ],
                                                                  ),
                                                                  Padding(
                                                                    padding: EdgeInsets.fromLTRB(30,3,0,0),
                                                                            
                                                                    child: Text(
                                                                      dataServices[index] .description,
                                                                      textScaleFactor: 1.0,
                                                                      style: FlutterFlowTheme.bodyText1.override(
                                                                        fontFamily: 'Poppins',
                                                                        color: FlutterFlowTheme.greyLight,
                                                                        fontSize: 12,
                                                                      ),
                                                                    ),
                                                                  )
                                                                ],
                                                              ),
                                                            ),
                                                          ),
                                                          Container(
                                                            width: 100,
                                                            decoration: BoxDecoration(),
                                                            child: Text(
                                                              Helper.rupiah(dataServices[index].charge),
                                                              textScaleFactor: 1.0,
                                                              textAlign: TextAlign.end,
                                                              style: FlutterFlowTheme.bodyText1.override(
                                                                fontFamily: 'Poppins',
                                                                fontWeight: FontWeight.w600,
                                                              ),
                                                            ),
                                                          )
                                                        ],
                                                      ),
                                                    ),
                                                  ),
                                                ),
                                              ),
                                            )