diff --git a/examples/audio_player_interaction/pubspec.lock b/examples/audio_player_interaction/pubspec.lock index 724cf4ed..602694c1 100644 --- a/examples/audio_player_interaction/pubspec.lock +++ b/examples/audio_player_interaction/pubspec.lock @@ -53,10 +53,10 @@ packages: dependency: transitive description: name: collection - sha256: "4a07be6cb69c84d677a6c3096fcf960cc3285a8330b4603e0d463d15d9bd934c" + sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a url: "https://pub.dev" source: hosted - version: "1.17.1" + version: "1.18.0" crypto: dependency: transitive description: @@ -140,26 +140,26 @@ packages: dependency: transitive description: name: matcher - sha256: "6501fbd55da300384b768785b83e5ce66991266cec21af89ab9ae7f5ce1c4cbb" + sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e" url: "https://pub.dev" source: hosted - version: "0.12.15" + version: "0.12.16" material_color_utilities: dependency: transitive description: name: material_color_utilities - sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 + sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41" url: "https://pub.dev" source: hosted - version: "0.2.0" + version: "0.5.0" meta: dependency: transitive description: name: meta - sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" + sha256: a6e590c838b18133bb482a2745ad77c5bb7715fb0451209e1a7567d416678b8e url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.10.0" path: dependency: transitive description: @@ -249,17 +249,17 @@ packages: dependency: transitive description: name: source_span - sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 + sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c" url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.10.0" speech_to_text: dependency: "direct main" description: path: "../../speech_to_text" relative: true source: path - version: "6.1.1" + version: "6.6.0" speech_to_text_macos: dependency: transitive description: @@ -272,26 +272,26 @@ packages: dependency: transitive description: name: speech_to_text_platform_interface - sha256: "13d90215a7554b9a8c1ce47c0a1739af8eacd2cf196ca66351e54dfd2172746d" + sha256: a0df1a907091ea09880077dc25aae02af9f79811264e6e97ddb08639b7f771c2 url: "https://pub.dev" source: hosted - version: "2.0.1" + version: "2.2.0" stack_trace: dependency: transitive description: name: stack_trace - sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 + sha256: "73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b" url: "https://pub.dev" source: hosted - version: "1.11.0" + version: "1.11.1" stream_channel: dependency: transitive description: name: stream_channel - sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" + sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7 url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.2" string_scanner: dependency: transitive description: @@ -312,10 +312,10 @@ packages: dependency: transitive description: name: test_api - sha256: eb6ac1540b26de412b3403a163d919ba86f6a973fe6cc50ae3541b80092fdcfb + sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b" url: "https://pub.dev" source: hosted - version: "0.5.1" + version: "0.6.1" typed_data: dependency: transitive description: @@ -340,6 +340,14 @@ packages: url: "https://pub.dev" source: hosted version: "2.1.4" + web: + dependency: transitive + description: + name: web + sha256: afe077240a270dcfd2aafe77602b4113645af95d0ad31128cc02bce5ac5d5152 + url: "https://pub.dev" + source: hosted + version: "0.3.0" win32: dependency: transitive description: @@ -357,5 +365,5 @@ packages: source: hosted version: "0.2.0" sdks: - dart: ">=3.0.0 <4.0.0" + dart: ">=3.2.0-194.0.dev <4.0.0" flutter: ">=3.10.0" diff --git a/speech_to_text/CHANGELOG.md b/speech_to_text/CHANGELOG.md index e774e651..79a2afa3 100644 --- a/speech_to_text/CHANGELOG.md +++ b/speech_to_text/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +## 6.6.0-dev + +### New +* `listen` now has a new `SpeechListenOptions listenOptions` parameter to specify the recognizer +options for the listen session. Some of the separate parameters have been deprecated as a +result. See the `listen` method for documentation. + ## 6.5.1 ### Fix diff --git a/speech_to_text/README.md b/speech_to_text/README.md index 002cb2e3..7678e1e0 100644 --- a/speech_to_text/README.md +++ b/speech_to_text/README.md @@ -1,6 +1,6 @@ # speech_to_text -[![pub package](https://img.shields.io/badge/pub-v6.5.1-blue)](https://pub.dartlang.org/packages/speech_to_text) [![build status](https://github.com/csdcorp/speech_to_text/workflows/Test/badge.svg)](https://github.com/csdcorp/speech_to_text/actions?query=workflow%3ATest) [![codecov](https://codecov.io/gh/csdcorp/speech_to_text/branch/main/graph/badge.svg?token=4LV3HESMS4)](undefined) +[![pub package](https://img.shields.io/badge/pub-v6.6.0-blue)](https://pub.dartlang.org/packages/speech_to_text) [![build status](https://github.com/csdcorp/speech_to_text/workflows/Test/badge.svg)](https://github.com/csdcorp/speech_to_text/actions?query=workflow%3ATest) [![codecov](https://codecov.io/gh/csdcorp/speech_to_text/branch/main/graph/badge.svg?token=4LV3HESMS4)](undefined) A library that exposes device specific speech recognition capability. @@ -24,10 +24,10 @@ _speech: means most speech recognition features work. Platforms with build but n ## Recent Updates -6.5.0 New `initialize` option to improve support for some mobile browsers, `SpeechToText.webDoNotAggregate`. Test the browser user agent to see if it should be used. +6.6.0 `listen` now uses 'SpeechListenOptions' to specify the options for the current listen session, including new +options for controlling haptics and punctuation during recognition on iOS. -6.4.0 Better support for newer Android devices, now returns the list of supported languages for -on device speech recognition. +6.5.0 New `initialize` option to improve support for some mobile browsers, `SpeechToText.webDoNotAggregate`. Test the browser user agent to see if it should be used. *Note*: Feedback from any test devices is welcome. diff --git a/speech_to_text/example/lib/main.dart b/speech_to_text/example/lib/main.dart index 36369c4e..49d83f0c 100644 --- a/speech_to_text/example/lib/main.dart +++ b/speech_to_text/example/lib/main.dart @@ -123,6 +123,13 @@ class _SpeechSampleAppState extends State { lastError = ''; final pauseFor = int.tryParse(_pauseForController.text); final listenFor = int.tryParse(_listenForController.text); + final options = SpeechListenOptions( + onDevice: _onDevice, + listenMode: ListenMode.confirmation, + cancelOnError: true, + partialResults: true, + autoPunctuation: true, + enableHapticFeedback: true); // Note that `listenFor` is the maximum, not the minimum, on some // systems recognition will be stopped before this value is reached. // Similarly `pauseFor` is a maximum not a minimum and may be ignored @@ -131,12 +138,9 @@ class _SpeechSampleAppState extends State { onResult: resultListener, listenFor: Duration(seconds: listenFor ?? 30), pauseFor: Duration(seconds: pauseFor ?? 3), - partialResults: true, localeId: _currentLocaleId, onSoundLevelChange: soundLevelListener, - cancelOnError: true, - listenMode: ListenMode.confirmation, - onDevice: _onDevice, + listenOptions: options, ); setState(() {}); } diff --git a/speech_to_text/example/pubspec.lock b/speech_to_text/example/pubspec.lock index 1cb298ad..a01523c7 100644 --- a/speech_to_text/example/pubspec.lock +++ b/speech_to_text/example/pubspec.lock @@ -58,10 +58,10 @@ packages: dependency: "direct dev" description: name: flutter_lints - sha256: ad76540d21c066228ee3f9d1dad64a9f7e46530e8bb7c85011a88bc1fd874bc5 + sha256: e2a421b7e59244faef694ba7b30562e489c2b489866e505074eb005cd7060db7 url: "https://pub.dev" source: hosted - version: "3.0.0" + version: "3.0.1" flutter_test: dependency: "direct dev" description: flutter @@ -148,18 +148,18 @@ packages: dependency: transitive description: name: plugin_platform_interface - sha256: da3fdfeccc4d4ff2da8f8c556704c08f912542c5fb3cf2233ed75372384a034d + sha256: "4820fbfdb9478b1ebae27888254d445073732dae3d6ea81f0b7e06d5dedc3f02" url: "https://pub.dev" source: hosted - version: "2.1.6" + version: "2.1.8" provider: dependency: "direct main" description: name: provider - sha256: cdbe7530b12ecd9eb455bdaa2fcb8d4dad22e80b8afb4798b41479d5ce26847f + sha256: "9a96a0a19b594dbc5bf0f1f27d2bc67d5f95957359b461cd9feb44ed6ae75096" url: "https://pub.dev" source: hosted - version: "6.0.5" + version: "6.1.1" sky_engine: dependency: transitive description: flutter @@ -179,23 +179,23 @@ packages: path: ".." relative: true source: path - version: "6.4.1" + version: "6.6.0" speech_to_text_macos: dependency: transitive description: name: speech_to_text_macos - sha256: "6b5575e5a8346be1779838b0a482c259474965b5943668830b479147a75b5bfc" + sha256: e685750f7542fcaa087a5396ee471e727ec648bf681f4da83c84d086322173f6 url: "https://pub.dev" source: hosted - version: "1.0.2" + version: "1.1.0" speech_to_text_platform_interface: dependency: transitive description: name: speech_to_text_platform_interface - sha256: "2ef9c0abf3b4340998fcb489afc4fc8cd7574eff21d912673be59b60ff16850c" + sha256: a0df1a907091ea09880077dc25aae02af9f79811264e6e97ddb08639b7f771c2 url: "https://pub.dev" source: hosted - version: "2.1.0" + version: "2.2.0" stack_trace: dependency: transitive description: diff --git a/speech_to_text/ios/Classes/SwiftSpeechToTextPlugin.swift b/speech_to_text/ios/Classes/SwiftSpeechToTextPlugin.swift index 1701a564..264d4715 100644 --- a/speech_to_text/ios/Classes/SwiftSpeechToTextPlugin.swift +++ b/speech_to_text/ios/Classes/SwiftSpeechToTextPlugin.swift @@ -111,11 +111,16 @@ public class SwiftSpeechToTextPlugin: NSObject, FlutterPlugin { initialize( result ) case SwiftSpeechToTextMethods.listen.rawValue: guard let argsArr = call.arguments as? Dictionary, - let partialResults = argsArr["partialResults"] as? Bool, let onDevice = argsArr["onDevice"] as? Bool, let listenModeIndex = argsArr["listenMode"] as? Int, let sampleRate = argsArr["sampleRate"] as? Int + let partialResults = argsArr["partialResults"] as? Bool, + let onDevice = argsArr["onDevice"] as? Bool, + let listenModeIndex = argsArr["listenMode"] as? Int, + let sampleRate = argsArr["sampleRate"] as? Int, + let autoPunctuation = argsArr["autoPunctuation"] as? Bool, + let enableHaptics = argsArr["enableHaptics"] as? Bool else { DispatchQueue.main.async { result(FlutterError( code: SpeechToTextErrors.missingOrInvalidArg.rawValue, - message:"Missing arg partialResults, onDevice, listenMode, and sampleRate are required", + message:"Missing arg partialResults, onDevice, listenMode, autoPunctuatio, enableHaptics and sampleRate are required", details: nil )) } return @@ -133,7 +138,7 @@ public class SwiftSpeechToTextPlugin: NSObject, FlutterPlugin { return } - listenForSpeech( result, localeStr: localeStr, partialResults: partialResults, onDevice: onDevice, listenMode: listenMode, sampleRate: sampleRate ) + listenForSpeech( result, localeStr: localeStr, partialResults: partialResults, onDevice: onDevice, listenMode: listenMode, sampleRate: sampleRate, autoPunctuation: autoPunctuation, enableHaptics: enableHaptics ) case SwiftSpeechToTextMethods.stop.rawValue: stopSpeech( result ) case SwiftSpeechToTextMethods.cancel.rawValue: @@ -348,7 +353,8 @@ public class SwiftSpeechToTextPlugin: NSObject, FlutterPlugin { stopping = false } - private func listenForSpeech( _ result: @escaping FlutterResult, localeStr: String?, partialResults: Bool, onDevice: Bool, listenMode: ListenMode, sampleRate: Int ) { + private func listenForSpeech( _ result: @escaping FlutterResult, localeStr: String?, partialResults: Bool, + onDevice: Bool, listenMode: ListenMode, sampleRate: Int, autoPunctuation: Bool, enableHaptics: Bool ) { if ( nil != currentTask || listening ) { sendBoolResult( false, result ); return @@ -381,6 +387,9 @@ public class SwiftSpeechToTextPlugin: NSObject, FlutterPlugin { } try self.audioSession.setMode(AVAudioSession.Mode.default) try self.audioSession.setActive(true, options: .notifyOthersOnDeactivation) + if #available(iOS 13.0, *) { + try self.audioSession.setAllowHapticsAndSystemSoundsDuringRecording(enableHaptics) + } if let sound = listeningSound { self.onPlayEnd = {()->Void in if ( !self.failedListen ) { @@ -417,7 +426,9 @@ public class SwiftSpeechToTextPlugin: NSObject, FlutterPlugin { default: break } - + if #available(iOS 16.0, *) { + currentRequest.addsPunctuation = autoPunctuation + } self.currentTask = self.recognizer?.recognitionTask(with: currentRequest, delegate: self ) let recordingFormat = inputNode?.outputFormat(forBus: self.busForNodeTap) let theSampleRate = audioSession.sampleRate diff --git a/speech_to_text/lib/speech_to_text.dart b/speech_to_text/lib/speech_to_text.dart index 5462dc3b..8d6d51fb 100644 --- a/speech_to_text/lib/speech_to_text.dart +++ b/speech_to_text/lib/speech_to_text.dart @@ -8,32 +8,8 @@ import 'package:flutter/services.dart'; import 'package:speech_to_text/speech_recognition_error.dart'; import 'package:speech_to_text/speech_recognition_result.dart'; import 'package:speech_to_text_platform_interface/speech_to_text_platform_interface.dart'; - -/// Describes the goal of your speech recognition to the system. -/// -/// Currently only supported on **iOS**. -/// -/// See also: -/// * https://developer.apple.com/documentation/speech/sfspeechrecognitiontaskhint -enum ListenMode { - /// The device default. - deviceDefault, - - /// When using captured speech for text entry. - /// - /// Use this when you are using speech recognition for a task that's similar to the keyboard's built-in dictation function. - dictation, - - /// When using captured speech to specify search terms. - /// - /// Use this when you are using speech recognition to identify search terms. - search, - - /// When using captured speech for short, confirmation-style requests. - /// - /// Use this when you are using speech recognition to handle confirmation commands, such as "yes", "no" or "maybe". - confirmation, -} +export 'package:speech_to_text_platform_interface/speech_to_text_platform_interface.dart' + show ListenMode, SpeechConfigOption, SpeechListenOptions; /// A single locale with a [name], localized to the current system locale, /// and a [localeId] which can be used in the [SpeechToText.listen] method to choose a @@ -419,32 +395,41 @@ class SpeechToText { /// called from the error handler. /// /// [partialResults] if true the listen reports results as they are recognized, - /// when false only final results are reported. Defaults to true. + /// when false only final results are reported. Defaults to true. Deprecated + /// use [listenOptions.partialResults] instead. /// /// [onDevice] if true the listen attempts to recognize locally with speech never /// leaving the device. If it cannot do this the listen attempt will fail. This is /// usually only needed for sensitive content where privacy or security is a concern. + /// Deprecated use [listenOptions.onDevice] instead. /// /// [listenMode] tunes the speech recognition engine to expect certain /// types of spoken content. It defaults to [ListenMode.confirmation] which /// is the most common use case, words or short phrases to confirm a command. /// [ListenMode.dictation] is for longer spoken content, sentences or /// paragraphs, while [ListenMode.search] expects a sequence of search terms. + /// Deprecated use [listenOptions.listenMode] instead. /// /// [sampleRate] optional for compatibility with certain iOS devices, some devices /// crash with `sampleRate != device's supported sampleRate`, try 44100 if seeing /// crashes. + /// Deprecated use [listenOptions.sampleRate] instead. + /// + /// [listenOptions] used to specify the options to use for the listen + /// session. See [SpeechListenOptions] for details. Future listen( {SpeechResultListener? onResult, Duration? listenFor, Duration? pauseFor, String? localeId, SpeechSoundLevelChange? onSoundLevelChange, - cancelOnError = false, - partialResults = true, - onDevice = false, + @Deprecated('Use listenOptions instead') cancelOnError = false, + @Deprecated('Use listenOptions instead') partialResults = true, + @Deprecated('Use listenOptions instead') onDevice = false, + @Deprecated('Use listenOptions instead') ListenMode listenMode = ListenMode.confirmation, - sampleRate = 0}) async { + @Deprecated('Use listenOptions instead') sampleRate = 0, + SpeechListenOptions? listenOptions}) async { if (!_initWorked) { throw SpeechToTextNotInitializedException(); } @@ -467,7 +452,8 @@ class SpeechToText { onDevice: onDevice, listenMode: listenMode.index, sampleRate: sampleRate, - localeId: localeId); + localeId: localeId, + options: listenOptions); if (started) { _listenStartedAt = clock.now().millisecondsSinceEpoch; _lastSpeechEventAt = _listenStartedAt; diff --git a/speech_to_text/lib/speech_to_text_web.dart b/speech_to_text/lib/speech_to_text_web.dart index d5318417..3620562e 100644 --- a/speech_to_text/lib/speech_to_text_web.dart +++ b/speech_to_text/lib/speech_to_text_web.dart @@ -142,14 +142,15 @@ class SpeechToTextPlugin extends SpeechToTextPlatform { @override Future listen( {String? localeId, - partialResults = true, - onDevice = false, - int listenMode = 0, - sampleRate = 0}) async { + @deprecated partialResults = true, + @deprecated onDevice = false, + @deprecated int listenMode = 0, + @deprecated sampleRate = 0, + SpeechListenOptions? options}) async { if (null == _webSpeech) return false; _webSpeech!.onResult.listen((speechEvent) => _onResult(speechEvent)); - _webSpeech!.interimResults = partialResults; - _webSpeech!.continuous = partialResults; + _webSpeech!.interimResults = options?.partialResults ?? partialResults; + _webSpeech!.continuous = options?.partialResults ?? partialResults; if (null != localeId) { _webSpeech!.lang = localeId; } diff --git a/speech_to_text/pubspec.lock b/speech_to_text/pubspec.lock index 0010ee98..7e8aff03 100644 --- a/speech_to_text/pubspec.lock +++ b/speech_to_text/pubspec.lock @@ -5,18 +5,18 @@ packages: dependency: transitive description: name: _fe_analyzer_shared - sha256: ae92f5d747aee634b87f89d9946000c2de774be1d6ac3e58268224348cd0101a + sha256: eb376e9acf6938204f90eb3b1f00b578640d3188b4c8a8ec054f9f479af8d051 url: "https://pub.dev" source: hosted - version: "61.0.0" + version: "64.0.0" analyzer: dependency: transitive description: name: analyzer - sha256: ea3d8652bda62982addfd92fdc2d0214e5f82e43325104990d4f4c4a2a313562 + sha256: "69f54f967773f6c26c7dcb13e93d7ccee8b17a641689da39e878d5cf13b06893" url: "https://pub.dev" source: hosted - version: "5.13.0" + version: "6.2.0" args: dependency: transitive description: @@ -61,26 +61,26 @@ packages: dependency: transitive description: name: build_daemon - sha256: "5f02d73eb2ba16483e693f80bee4f088563a820e47d1027d4cdfe62b5bb43e65" + sha256: "0343061a33da9c5810b2d6cee51945127d8f4c060b7fbdd9d54917f0a3feaaa1" url: "https://pub.dev" source: hosted - version: "4.0.0" + version: "4.0.1" build_resolvers: dependency: transitive description: name: build_resolvers - sha256: "64e12b0521812d1684b1917bc80945625391cb9bdd4312536b1d69dcb6133ed8" + sha256: "339086358431fa15d7eca8b6a36e5d783728cf025e559b834f4609a1fcfb7b0a" url: "https://pub.dev" source: hosted - version: "2.4.1" + version: "2.4.2" build_runner: dependency: "direct dev" description: name: build_runner - sha256: "10c6bcdbf9d049a0b666702cf1cee4ddfdc38f02a19d35ae392863b47519848b" + sha256: "581bacf68f89ec8792f5e5a0b2c4decd1c948e97ce659dc783688c8a88fbec21" url: "https://pub.dev" source: hosted - version: "2.4.6" + version: "2.4.8" build_runner_core: dependency: transitive description: @@ -101,10 +101,10 @@ packages: dependency: transitive description: name: built_value - sha256: a8de5955205b4d1dbbbc267daddf2178bd737e4bab8987c04a500478c9651e74 + sha256: a3ec2e0f967bc47f69f95009bb93db936288d61d5343b9436e378b28a2f830c6 url: "https://pub.dev" source: hosted - version: "8.6.3" + version: "8.9.0" characters: dependency: transitive description: @@ -133,10 +133,10 @@ packages: dependency: transitive description: name: code_builder - sha256: "1be9be30396d7e4c0db42c35ea6ccd7cc6a1e19916b5dc64d6ac216b5544d677" + sha256: f692079e25e7869c14132d39f223f8eec9830eb76131925143b2129c4bb01b37 url: "https://pub.dev" source: hosted - version: "4.7.0" + version: "4.10.0" collection: dependency: transitive description: @@ -165,10 +165,10 @@ packages: dependency: transitive description: name: dart_style - sha256: "1efa911ca7086affd35f463ca2fc1799584fb6aa89883cf0af8e3664d6a02d55" + sha256: "40ae61a5d43feea6d24bd22c0537a6629db858963b99b4bc1c3db80676f32368" url: "https://pub.dev" source: hosted - version: "2.3.2" + version: "2.3.4" fake_async: dependency: "direct dev" description: @@ -202,10 +202,10 @@ packages: dependency: "direct dev" description: name: flutter_lints - sha256: ad76540d21c066228ee3f9d1dad64a9f7e46530e8bb7c85011a88bc1fd874bc5 + sha256: e2a421b7e59244faef694ba7b30562e489c2b489866e505074eb005cd7060db7 url: "https://pub.dev" source: hosted - version: "3.0.0" + version: "3.0.1" flutter_test: dependency: "direct dev" description: flutter @@ -332,18 +332,18 @@ packages: dependency: transitive description: name: mime - sha256: e4ff8e8564c03f255408decd16e7899da1733852a9110a58fe6d1b817684a63e + sha256: "2e123074287cc9fd6c09de8336dae606d1ddb88d9ac47358826db698c176a1f2" url: "https://pub.dev" source: hosted - version: "1.0.4" + version: "1.0.5" mockito: dependency: "direct dev" description: name: mockito - sha256: "7d5b53bcd556c1bc7ffbe4e4d5a19c3e112b7e925e9e172dd7c6ad0630812616" + sha256: "6841eed20a7befac0ce07df8116c8b8233ed1f4486a7647c7fc5a02ae6163917" url: "https://pub.dev" source: hosted - version: "5.4.2" + version: "5.4.4" package_config: dependency: transitive description: @@ -372,10 +372,10 @@ packages: dependency: "direct dev" description: name: plugin_platform_interface - sha256: da3fdfeccc4d4ff2da8f8c556704c08f912542c5fb3cf2233ed75372384a034d + sha256: "4820fbfdb9478b1ebae27888254d445073732dae3d6ea81f0b7e06d5dedc3f02" url: "https://pub.dev" source: hosted - version: "2.1.6" + version: "2.1.8" pool: dependency: transitive description: @@ -425,10 +425,10 @@ packages: dependency: transitive description: name: source_gen - sha256: fc0da689e5302edb6177fdd964efcb7f58912f43c28c2047a808f5bfff643d16 + sha256: "14658ba5f669685cd3d63701d01b31ea748310f7ab854e471962670abcf57832" url: "https://pub.dev" source: hosted - version: "1.4.0" + version: "1.5.0" source_helper: dependency: transitive description: @@ -449,18 +449,18 @@ packages: dependency: "direct main" description: name: speech_to_text_macos - sha256: "6b5575e5a8346be1779838b0a482c259474965b5943668830b479147a75b5bfc" + sha256: e685750f7542fcaa087a5396ee471e727ec648bf681f4da83c84d086322173f6 url: "https://pub.dev" source: hosted - version: "1.0.2" + version: "1.1.0" speech_to_text_platform_interface: dependency: "direct main" description: name: speech_to_text_platform_interface - sha256: "2ef9c0abf3b4340998fcb489afc4fc8cd7574eff21d912673be59b60ff16850c" + sha256: a0df1a907091ea09880077dc25aae02af9f79811264e6e97ddb08639b7f771c2 url: "https://pub.dev" source: hosted - version: "2.1.0" + version: "2.2.0" stack_trace: dependency: transitive description: @@ -566,5 +566,5 @@ packages: source: hosted version: "3.1.2" sdks: - dart: ">=3.2.0-194.0.dev <4.0.0" + dart: ">=3.2.0 <4.0.0" flutter: ">=3.10.0" diff --git a/speech_to_text/pubspec.yaml b/speech_to_text/pubspec.yaml index b567448f..1c73067c 100644 --- a/speech_to_text/pubspec.yaml +++ b/speech_to_text/pubspec.yaml @@ -1,6 +1,6 @@ name: speech_to_text description: A Flutter plugin that exposes device specific speech to text recognition capability. -version: 6.5.1 +version: 6.6.0-dev homepage: https://github.com/csdcorp/speech_to_text environment: @@ -10,8 +10,8 @@ environment: dependencies: flutter: sdk: flutter - speech_to_text_platform_interface: ^2.1.0 - speech_to_text_macos: ^1.0.2 + speech_to_text_platform_interface: ^2.2.0 + speech_to_text_macos: ^1.1.0 json_annotation: ^4.0.0 clock: ^1.0.1 pedantic: ^1.9.2 diff --git a/speech_to_text/test/test_speech_to_text_platform.dart b/speech_to_text/test/test_speech_to_text_platform.dart index 4623a5cf..b9933161 100644 --- a/speech_to_text/test/test_speech_to_text_platform.dart +++ b/speech_to_text/test/test_speech_to_text_platform.dart @@ -83,7 +83,8 @@ class TestSpeechToTextPlatform extends SpeechToTextPlatform { partialResults = true, onDevice = false, int listenMode = 0, - sampleRate = 0}) async { + sampleRate = 0, + SpeechListenOptions? options}) async { listenInvoked = true; listenLocale = localeId; if (listenException) { diff --git a/speech_to_text_macos/macos/Flutter/ephemeral/Flutter-Generated.xcconfig b/speech_to_text_macos/macos/Flutter/ephemeral/Flutter-Generated.xcconfig deleted file mode 100644 index d772d158..00000000 --- a/speech_to_text_macos/macos/Flutter/ephemeral/Flutter-Generated.xcconfig +++ /dev/null @@ -1,11 +0,0 @@ -// This is a generated file; do not edit or check into version control. -FLUTTER_ROOT=/Users/stephen.owens/Documents/dev/flutter/sdk/flutter -FLUTTER_APPLICATION_PATH=/Users/stephen.owens/Documents/dev/csd/csd-flutter-plugins/speech_to_text_macos -COCOAPODS_PARALLEL_CODE_SIGN=true -FLUTTER_BUILD_DIR=build -FLUTTER_BUILD_NAME=1.0.0 -FLUTTER_BUILD_NUMBER=1.0.0 -DART_OBFUSCATION=false -TRACK_WIDGET_CREATION=false -TREE_SHAKE_ICONS=false -PACKAGE_CONFIG=.dart_tool/package_config.json diff --git a/speech_to_text_macos/macos/Flutter/ephemeral/flutter_export_environment.sh b/speech_to_text_macos/macos/Flutter/ephemeral/flutter_export_environment.sh deleted file mode 100755 index 1ac4df82..00000000 --- a/speech_to_text_macos/macos/Flutter/ephemeral/flutter_export_environment.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/sh -# This is a generated file; do not edit or check into version control. -export "FLUTTER_ROOT=/Users/stephen.owens/Documents/dev/flutter/sdk/flutter" -export "FLUTTER_APPLICATION_PATH=/Users/stephen.owens/Documents/dev/csd/csd-flutter-plugins/speech_to_text_macos" -export "COCOAPODS_PARALLEL_CODE_SIGN=true" -export "FLUTTER_BUILD_DIR=build" -export "FLUTTER_BUILD_NAME=1.0.0" -export "FLUTTER_BUILD_NUMBER=1.0.0" -export "DART_OBFUSCATION=false" -export "TRACK_WIDGET_CREATION=false" -export "TREE_SHAKE_ICONS=false" -export "PACKAGE_CONFIG=.dart_tool/package_config.json"