Skip to content
This repository was archived by the owner on Dec 5, 2023. It is now read-only.

Commit 11045e3

Browse files
committed
feat: added readme
1 parent 1a9a3f2 commit 11045e3

File tree

3 files changed

+33
-27
lines changed

3 files changed

+33
-27
lines changed

README.md

Lines changed: 26 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,40 @@
11
[![pub package](https://img.shields.io/pub/v/[PACKAGE NAME ON PUB].svg)](https://github.com/Iconica-Development) [![Build status](URL TO REPO)](URL TO GITHUB ACTIONS) [![style: effective dart](https://img.shields.io/badge/style-effective_dart-40c4ff.svg)](https://github.com/tenhobi/effective_dart)
22

3-
Short description of what your package is, why you created it. What issues it fixes and how it works. Also mention the available platforms
3+
# Introduction Widget
4+
Flutter Introduction Widget for showing a list of introduction pages on a single scrollable page or horizontal pageview.
45

5-
## Setup
6+
If nothing is provided a few default pages are shown with a simple description of the package.
67

7-
What setup steps are neccesarry and why>
88

9-
<details>
10-
<summary>PLATFORM</summary>
11-
12-
specific platform steps
9+
Supports all Flutter platforms.
1310

14-
</details>
11+
## Usage
12+
13+
To use this package, add `flutter_introduction_widget` as a [dependency in your pubspec.yaml file](https://flutter.dev/docs/development/platform-integration/platform-channels).
1514

1615
## How to use
1716

18-
How can we use the package descibe the most common ways with examples in
17+
Simple way to use the introduction widget:
1918
```dart
20-
codeblocks
19+
Introduction(
20+
introductionSettings: const IntroductionSettings(
21+
buttonMode: IntroductionScreenButtonMode.Text,
22+
showSkipButton: true,
23+
showFinishButton: true,
24+
),
25+
onComplete: () {
26+
debugPrint('done!');
27+
},
28+
pages: [
29+
IntroductionPage(title: 'Page1', text: 'hello'),
30+
IntroductionPage(title: 'Page2', text: 'world'),
31+
IntroductionPage(title: 'Page3', text: 'text'),
32+
],
33+
),
2134
```
35+
### Example
36+
37+
See [Example Code](example/lib/main.dart) for more info.
2238

2339
## Issues
2440

example/lib/main.dart

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import 'package:flutter/foundation.dart';
21
import 'package:flutter/material.dart';
32
import 'package:flutter_introduction_widget/flutter_introduction_widget.dart';
43

@@ -21,22 +20,13 @@ class FlutterIntroductionDemo extends StatelessWidget {
2120
showFinishButton: true,
2221
),
2322
onComplete: () {
24-
if (kDebugMode) {
25-
print('done!');
26-
}
23+
debugPrint('done!');
2724
},
2825
pages: [
29-
IntroductionPage(title: 'title', text: 'hello'),
30-
IntroductionPage(text: 'hello'),
31-
IntroductionPage(text: 'hello'),
26+
IntroductionPage(title: 'Page1', text: 'hello'),
27+
IntroductionPage(title: 'Page2', text: 'world'),
28+
IntroductionPage(title: 'Page3', text: 'text'),
3229
],
33-
child: Container(
34-
child: const Center(
35-
child: Text(
36-
'child',
37-
),
38-
),
39-
),
4030
),
4131
),
4232
);

pubspec.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: flutter_introduction_widget
2-
description: A standard flutter package.
3-
version: 0.0.1
2+
description: Flutter Introduction Widget for showing a list of introduction pages on a single scrollable page or horizontal pageview
3+
version: 0.0.2
44
homepage: https://github.com/Iconica-Development/flutter_introduction_widget
55

66
environment:
7-
sdk: '>=2.18.0 <3.0.0'
7+
sdk: ">=2.18.0 <3.0.0"
88
flutter: ">=1.17.0"
99

1010
dependencies:

0 commit comments

Comments
 (0)