use StreamSvgIcon widget
This commit is contained in:
@@ -44,8 +44,8 @@ class _AdvancedOptionsPageState extends State<AdvancedOptionsPage> {
|
||||
),
|
||||
),
|
||||
leading: IconButton(
|
||||
icon: Icon(
|
||||
StreamIcons.left,
|
||||
icon: StreamSvgIcon(
|
||||
assetName: 'Icon_left.svg',
|
||||
color: Colors.black,
|
||||
),
|
||||
onPressed: () {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:stream_chat_flutter/src/stream_icons.dart';
|
||||
import 'package:stream_chat_flutter/stream_chat_flutter.dart';
|
||||
|
||||
typedef ChipBuilder<T> = Widget Function(BuildContext context, T chip);
|
||||
typedef OnChipAdded<T> = void Function(T chip);
|
||||
@@ -130,12 +130,13 @@ class ChipInputTextFieldState<T> extends State<ChipsInputTextField<T>> {
|
||||
Align(
|
||||
alignment: Alignment.bottomCenter,
|
||||
child: IconButton(
|
||||
icon: Icon(
|
||||
_chips.isEmpty
|
||||
? StreamIcons.user
|
||||
: StreamIcons.user_add,
|
||||
icon: StreamSvgIcon(
|
||||
assetName: _chips.isEmpty
|
||||
? 'Icon_user.svg'
|
||||
: 'Icon_User_add.svg',
|
||||
color: Colors.black.withOpacity(0.5),
|
||||
size: 24,
|
||||
height: 24,
|
||||
width: 24,
|
||||
),
|
||||
onPressed:
|
||||
!_pauseItemAddition ? null : resumeItemAddition,
|
||||
|
||||
@@ -196,8 +196,8 @@ class ChooseUserPage extends StatelessWidget {
|
||||
);
|
||||
},
|
||||
leading: CircleAvatar(
|
||||
child: Icon(
|
||||
StreamIcons.settings,
|
||||
child: StreamSvgIcon(
|
||||
assetName: 'settings.svg',
|
||||
color: Colors.black,
|
||||
),
|
||||
backgroundColor:
|
||||
|
||||
@@ -106,7 +106,9 @@ class _GroupChatDetailsScreenState extends State<GroupChatDetailsScreen> {
|
||||
NeumorphicButton(
|
||||
child: IconButton(
|
||||
padding: const EdgeInsets.all(0),
|
||||
icon: Icon(StreamIcons.check),
|
||||
icon: StreamSvgIcon(
|
||||
assetName: 'Icon_check.svg',
|
||||
),
|
||||
color: Color(0xFF006CFF),
|
||||
onPressed: _isGroupNameEmpty
|
||||
? null
|
||||
|
||||
+12
-3
@@ -141,7 +141,10 @@ class ChannelListPage extends StatelessWidget {
|
||||
),
|
||||
),
|
||||
ListTile(
|
||||
leading: Icon(StreamIcons.edit),
|
||||
leading: StreamSvgIcon(
|
||||
assetName: 'Icon_pen-write.svg',
|
||||
color: Colors.black.withOpacity(.5),
|
||||
),
|
||||
onTap: () {
|
||||
Navigator.of(context)
|
||||
..pop()
|
||||
@@ -157,7 +160,10 @@ class ChannelListPage extends StatelessWidget {
|
||||
),
|
||||
),
|
||||
ListTile(
|
||||
leading: Icon(StreamIcons.group),
|
||||
leading: StreamSvgIcon(
|
||||
assetName: 'Icon_contacts.svg',
|
||||
color: Colors.black.withOpacity(.5),
|
||||
),
|
||||
onTap: () {
|
||||
Navigator.of(context)
|
||||
..pop()
|
||||
@@ -189,7 +195,10 @@ class ChannelListPage extends StatelessWidget {
|
||||
),
|
||||
);
|
||||
},
|
||||
leading: Icon(StreamIcons.user),
|
||||
leading: StreamSvgIcon(
|
||||
assetName: 'Icon_user.svg',
|
||||
color: Colors.black.withOpacity(.5),
|
||||
),
|
||||
title: Text(
|
||||
'Sign out',
|
||||
style: TextStyle(
|
||||
|
||||
@@ -164,8 +164,8 @@ class _NewChatScreenState extends State<NewChatScreen> {
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
child: Icon(
|
||||
StreamIcons.close,
|
||||
child: StreamSvgIcon(
|
||||
assetName: 'Icon_close.svg',
|
||||
color: Colors.white,
|
||||
),
|
||||
),
|
||||
@@ -194,8 +194,8 @@ class _NewChatScreenState extends State<NewChatScreen> {
|
||||
child: Row(
|
||||
children: [
|
||||
NeumorphicButton(
|
||||
child: Icon(
|
||||
StreamIcons.group,
|
||||
child: StreamSvgIcon(
|
||||
assetName: 'Icon_contacts.svg',
|
||||
color: Color(0xFF006CFF),
|
||||
),
|
||||
),
|
||||
@@ -289,9 +289,10 @@ class _NewChatScreenState extends State<NewChatScreen> {
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(24),
|
||||
child: Icon(
|
||||
StreamIcons.search,
|
||||
size: 96,
|
||||
child: StreamSvgIcon(
|
||||
assetName: 'Icon_search.svg',
|
||||
height: 96,
|
||||
width: 96,
|
||||
color: Colors.grey,
|
||||
),
|
||||
),
|
||||
|
||||
@@ -65,8 +65,8 @@ class _NewGroupChatScreenState extends State<NewGroupChatScreen> {
|
||||
actions: [
|
||||
if (_selectedUsers.isNotEmpty)
|
||||
IconButton(
|
||||
icon: Icon(
|
||||
StreamIcons.arrow_right,
|
||||
icon: StreamSvgIcon(
|
||||
assetName: 'Icon_right.svg',
|
||||
color: Color(0xFF006CFF),
|
||||
),
|
||||
onPressed: () {
|
||||
@@ -101,10 +101,11 @@ class _NewGroupChatScreenState extends State<NewGroupChatScreen> {
|
||||
child: TextField(
|
||||
controller: _controller,
|
||||
decoration: InputDecoration(
|
||||
prefixIcon: Icon(
|
||||
StreamIcons.search,
|
||||
prefixIcon: StreamSvgIcon(
|
||||
assetName: 'Icon_search.svg',
|
||||
color: Colors.black,
|
||||
size: 24,
|
||||
height: 24,
|
||||
width: 24,
|
||||
),
|
||||
hintText: 'Search',
|
||||
hintStyle: TextStyle(
|
||||
@@ -162,9 +163,10 @@ class _NewGroupChatScreenState extends State<NewGroupChatScreen> {
|
||||
),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(0.0),
|
||||
child: Icon(
|
||||
StreamIcons.close,
|
||||
size: 24,
|
||||
child: StreamSvgIcon(
|
||||
assetName: 'Icon_close.svg',
|
||||
height: 24,
|
||||
width: 24,
|
||||
),
|
||||
),
|
||||
),
|
||||
@@ -260,9 +262,10 @@ class _NewGroupChatScreenState extends State<NewGroupChatScreen> {
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(24),
|
||||
child: Icon(
|
||||
StreamIcons.search,
|
||||
size: 96,
|
||||
child: StreamSvgIcon(
|
||||
assetName: 'Icon_search.svg',
|
||||
height: 96,
|
||||
width: 96,
|
||||
color: Colors.grey,
|
||||
),
|
||||
),
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
name: example
|
||||
description: A new Flutter project.
|
||||
version: 1.0.66+68
|
||||
version: 1.0.67+69
|
||||
|
||||
environment:
|
||||
sdk: ">=2.2.2 <3.0.0"
|
||||
|
||||
Reference in New Issue
Block a user