Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/matthinc/flutter_cupertino_settings

A Flutter widget to create an iOS settings-table (static TableView).
https://github.com/matthinc/flutter_cupertino_settings

dart flutter ios ui widget

Last synced: about 2 months ago
JSON representation

A Flutter widget to create an iOS settings-table (static TableView).

Awesome Lists containing this project

README

        

# flutter_cupertino_settings

[![Pub badge](https://img.shields.io/pub/v/flutter_cupertino_settings.svg)](https://pub.dartlang.org/packages/flutter_cupertino_settings) ![](https://img.shields.io/github/license/matthinc/flutter_cupertino_settings.svg)

A Flutter widget to create an iOS settings-table (static TableView).

```dart

import 'package:flutter_cupertino_settings/flutter_cupertino_settings.dart';

CSWidgetStyle brightnessStyle = const CSWidgetStyle(
icon: const Icon(Icons.brightness_medium, color: Colors.black54)
);

CupertinoSettings(
items: [
const CSHeader('Brightness'),
CSWidget(CupertinoSlider(value: 0.5), style: brightnessStyle),
CSControl(
nameWidget: Text('Auto brightness'),
contentWidget: CupertinoSwitch(value: true),
style: brightnessStyle,
),
CSHeader('Selection'),
CSSelection(
items: const >[
CSSelectionItem(text: 'Day mode', value: 0),
CSSelectionItem(text: 'Night mode', value: 1),
],
onSelected: (index) {print(index);},
currentSelection: 0,
),
CSDescription('Using Night mode extends battery life on devices with OLED display',),
const CSHeader(''),
CSControl(
nameWidget: Text('Loading...'),
contentWidget: CupertinoActivityIndicator(),
),
CSButton(CSButtonType.DEFAULT, "Licenses", (){ print("It works!"); }),
const CSHeader(''),
CSButton(CSButtonType.DESTRUCTIVE, "Delete all data", (){})
]
);
```

![](screenshots/scr1.png)

### Contributors
- Dark theme & example by [AppleEducate](https://github.com/appleeducate)
- CSSecret by [SimonIT](https://github.com/SimonIT)
- iOS 13 support by [Tim Bierbaum](https://github.com/bierbaumtim)