Skip to content

Commit

Permalink
Merge branch 'develop' of https://github.com/takenet/blip-ds-flutter
Browse files Browse the repository at this point in the history
…into develop
  • Loading branch information
PaollaLira committed Apr 12, 2023
2 parents 9766757 + 308b22f commit 1660d48
Show file tree
Hide file tree
Showing 4 changed files with 130 additions and 84 deletions.
168 changes: 103 additions & 65 deletions lib/src/widgets/toast/ds_toast.widget.dart
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ class _DSToastState extends State<DSToast> with AutomaticKeepAliveClientMixin {

Widget _setIcon(final IconData icon) {
return Padding(
padding: const EdgeInsets.only(top: 8),
padding: const EdgeInsets.only(top: 8.0),
child: Icon(
icon,
color: DSColors.neutralDarkCity,
Expand All @@ -125,85 +125,123 @@ class _DSToastState extends State<DSToast> with AutomaticKeepAliveClientMixin {
child: Stack(
children: [
Positioned(
left: -15,
top: -2,
left: -15.0,
top: -2.0,
child: SvgPicture.asset(
'assets/images/blip_balloon.svg',
package: DSUtils.packageName,
),
),
Container(
padding: const EdgeInsets.symmetric(vertical: 8, horizontal: 16),
decoration: BoxDecoration(
color: backgroundColor,
borderRadius: BorderRadius.circular(8.0),
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
if (icon != null) icon!,
Expanded(
child: Padding(
padding: const EdgeInsets.symmetric(
vertical: 8,
horizontal: 16.0,
if (props.actionType == DSToastActionType.icon)
Container(
padding:
const EdgeInsets.symmetric(vertical: 8.0, horizontal: 16.0),
decoration: BoxDecoration(
color: backgroundColor,
borderRadius: BorderRadius.circular(8.0),
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
if (icon != null) icon!,
Expanded(
child: Padding(
padding: const EdgeInsets.symmetric(
vertical: 8.0,
horizontal: 16.0,
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
if (props.title != null)
DSHeadlineSmallText(
props.title,
overflow: TextOverflow.visible,
),
if (props.message != null)
DSBodyText(
props.message,
overflow: TextOverflow.visible,
),
],
),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
if (props.title != null)
DSHeadlineSmallText(
props.title,
overflow: TextOverflow.visible,
),
DSIconButton(
size: 40.0,
icon: const Icon(DSIcons.close_outline),
onPressed: () {
state!(() {
_stopTimer();
_controlAnimation = Control.playReverse;
});
},
),
],
),
),
if (props.actionType == DSToastActionType.button)
Container(
padding:
const EdgeInsets.symmetric(vertical: 8.0, horizontal: 16.0),
decoration: BoxDecoration(
color: backgroundColor,
borderRadius: BorderRadius.circular(8.0),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.end,
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
if (icon != null) icon!,
Expanded(
child: Padding(
padding: const EdgeInsets.symmetric(
vertical: 8.0,
horizontal: 16.0,
),
if (props.message != null)
DSBodyText(
props.message,
overflow: TextOverflow.visible,
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
if (props.title != null)
DSHeadlineSmallText(
props.title,
overflow: TextOverflow.visible,
),
if (props.message != null)
DSBodyText(
props.message,
overflow: TextOverflow.visible,
),
],
),
],
),
),
),
],
),
DSTertiaryButton(
label: props.buttonText,
onPressed: () {
props.onPressedButton!();
state!(
() {
_stopTimer();
_controlAnimation = Control.playReverse;
},
);
},
),
),
_setMainButton(),
],
],
),
),
),
],
),
);
}

/// Switches between exit button types
Widget _setMainButton() {
return props.actionType == DSToastActionType.icon
? DSIconButton(
size: 40.0,
icon: const Icon(DSIcons.close_outline),
onPressed: () {
state!(() {
_stopTimer();
_controlAnimation = Control.playReverse;
});
},
)
: props.actionType == DSToastActionType.button
? DSTertiaryButton(
label: props.buttonText,
onPressed: () {
props.onPressedButton!();
state!(
() {
_stopTimer();
_controlAnimation = Control.playReverse;
},
);
},
)
: const SizedBox.shrink();
}

/// Create and manage the toast animation
@override
Widget build(BuildContext context) {
Expand Down
10 changes: 9 additions & 1 deletion sample/ios/Podfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Uncomment this line to define a global platform for your project
platform :ios, '12.1'
platform :ios, '14.0'

# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
Expand Down Expand Up @@ -38,4 +38,12 @@ post_install do |installer|
installer.pods_project.targets.each do |target|
flutter_additional_ios_build_settings(target)
end

installer.generated_projects.each do |project|
project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '14.0'
end
end
end
end
24 changes: 12 additions & 12 deletions sample/ios/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
PODS:
- audio_session (0.0.1):
- Flutter
- ffmpeg-kit-ios-https (5.1)
- ffmpeg_kit_flutter (5.1.0):
- ffmpeg_kit_flutter/https (= 5.1.0)
- ffmpeg-kit-ios-full-gpl (5.1)
- ffmpeg_kit_flutter_full_gpl (5.1.0):
- ffmpeg_kit_flutter_full_gpl/full-gpl (= 5.1.0)
- Flutter
- ffmpeg_kit_flutter/https (5.1.0):
- ffmpeg-kit-ios-https (= 5.1)
- ffmpeg_kit_flutter_full_gpl/full-gpl (5.1.0):
- ffmpeg-kit-ios-full-gpl (= 5.1)
- Flutter
- Flutter (1.0.0)
- FMDB (2.7.5):
Expand All @@ -31,7 +31,7 @@ PODS:

DEPENDENCIES:
- audio_session (from `.symlinks/plugins/audio_session/ios`)
- ffmpeg_kit_flutter (from `.symlinks/plugins/ffmpeg_kit_flutter/ios`)
- ffmpeg_kit_flutter_full_gpl (from `.symlinks/plugins/ffmpeg_kit_flutter_full_gpl/ios`)
- Flutter (from `Flutter`)
- just_audio (from `.symlinks/plugins/just_audio/ios`)
- open_filex (from `.symlinks/plugins/open_filex/ios`)
Expand All @@ -43,14 +43,14 @@ DEPENDENCIES:

SPEC REPOS:
trunk:
- ffmpeg-kit-ios-https
- ffmpeg-kit-ios-full-gpl
- FMDB

EXTERNAL SOURCES:
audio_session:
:path: ".symlinks/plugins/audio_session/ios"
ffmpeg_kit_flutter:
:path: ".symlinks/plugins/ffmpeg_kit_flutter/ios"
ffmpeg_kit_flutter_full_gpl:
:path: ".symlinks/plugins/ffmpeg_kit_flutter_full_gpl/ios"
Flutter:
:path: Flutter
just_audio:
Expand All @@ -70,8 +70,8 @@ EXTERNAL SOURCES:

SPEC CHECKSUMS:
audio_session: 4f3e461722055d21515cf3261b64c973c062f345
ffmpeg-kit-ios-https: 8dffbe1623a2f227be98fc314294847a97f818e4
ffmpeg_kit_flutter: 17e9f35a4ec996ac55051c20be05240f2a0b53e8
ffmpeg-kit-ios-full-gpl: 2682965e5b3e7f13a05836d46d302eafe6c5039e
ffmpeg_kit_flutter_full_gpl: 7dcfcdc419f4667252cde1871859976bca328169
Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
FMDB: 2ce00b547f966261cd18927a3ddb07cb6f3db82a
just_audio: baa7252489dbcf47a4c7cc9ca663e9661c99aafa
Expand All @@ -82,6 +82,6 @@ SPEC CHECKSUMS:
video_player_avfoundation: e489aac24ef5cf7af82702979ed16f2a5ef84cff
wakelock: d0fc7c864128eac40eba1617cb5264d9c940b46f

PODFILE CHECKSUM: 7adbc9d59f05e1b01f554ea99b6c79e97f2214a2
PODFILE CHECKSUM: da491a8b7d2d8eef05b8be02236cf916620dd0f4

COCOAPODS: 1.12.0
12 changes: 6 additions & 6 deletions sample/ios/Runner.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.1;
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;
Expand All @@ -360,7 +360,7 @@
DEVELOPMENT_TEAM = CZXK68F2MF;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 12.1;
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down Expand Up @@ -420,7 +420,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.1;
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
Expand Down Expand Up @@ -469,7 +469,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.1;
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;
Expand All @@ -490,7 +490,7 @@
DEVELOPMENT_TEAM = CZXK68F2MF;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 12.1;
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -514,7 +514,7 @@
DEVELOPMENT_TEAM = CZXK68F2MF;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 12.1;
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down

0 comments on commit 1660d48

Please sign in to comment.