Skip to content

Commit 062c4f8

Browse files
committed
Formatting
1 parent 16fe40e commit 062c4f8

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+645
-605
lines changed

dwds/debug_extension/tool/copy_builder.dart

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ Builder copyBuilder(_) => _CopyBuilder();
1010
class _CopyBuilder extends Builder {
1111
@override
1212
Map<String, List<String>> get buildExtensions => {
13-
'web/{{}}.dart.js': ['compiled/{{}}.dart.js'],
14-
'web/static_assets/{{}}.png': ['compiled/static_assets/{{}}.png'],
15-
'web/static_assets/{{}}.html': ['compiled/static_assets/{{}}.html'],
16-
'web/static_assets/{{}}.css': ['compiled/static_assets/{{}}.css'],
17-
'web/manifest.json': ['compiled/manifest.json'],
18-
};
13+
'web/{{}}.dart.js': ['compiled/{{}}.dart.js'],
14+
'web/static_assets/{{}}.png': ['compiled/static_assets/{{}}.png'],
15+
'web/static_assets/{{}}.html': ['compiled/static_assets/{{}}.html'],
16+
'web/static_assets/{{}}.css': ['compiled/static_assets/{{}}.css'],
17+
'web/manifest.json': ['compiled/manifest.json'],
18+
};
1919

2020
@override
2121
Future<void> build(BuildStep buildStep) async {

dwds/debug_extension/web/background.dart

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -279,9 +279,8 @@ void _setWarningIcon(int tabId) {
279279
}
280280

281281
void _setDefaultIcon(int tabId) {
282-
final iconPath = isDevMode
283-
? 'static_assets/dart_dev.png'
284-
: 'static_assets/dart_grey.png';
282+
final iconPath =
283+
isDevMode ? 'static_assets/dart_dev.png' : 'static_assets/dart_grey.png';
285284
setExtensionIcon(IconInfo(path: iconPath));
286285
setExtensionPopup(PopupDetails(popup: '', tabId: tabId));
287286
}

dwds/debug_extension/web/cider_connection.dart

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,8 +170,7 @@ Future<void> _sendInspectorUrl({String? appId}) async {
170170
if (!alreadyDebugging) {
171171
sendErrorMessageToCider(
172172
errorType: CiderErrorType.invalidRequest,
173-
errorDetails:
174-
'Cannot send the inspector URL before '
173+
errorDetails: 'Cannot send the inspector URL before '
175174
'the debugger has been attached.',
176175
);
177176
return;

dwds/debug_extension/web/copier.dart

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@ void _copyAppId(String appId) {
4949
}
5050

5151
Future<bool> _notifyCopiedSuccess(String appId) => sendRuntimeMessage(
52-
type: MessageType.appId,
53-
body: appId,
54-
sender: Script.copier,
55-
recipient: Script.background,
56-
);
52+
type: MessageType.appId,
53+
body: appId,
54+
sender: Script.copier,
55+
recipient: Script.background,
56+
);

dwds/debug_extension/web/cross_extension_communication.dart

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -126,17 +126,19 @@ ExternalExtensionMessage _debugEventMessage({
126126
required String method,
127127
required dynamic params,
128128
required int tabId,
129-
}) => ExternalExtensionMessage(
130-
name: 'chrome.debugger.event',
131-
tabId: tabId,
132-
options: DebugEvent(method: method, params: params),
133-
);
129+
}) =>
130+
ExternalExtensionMessage(
131+
name: 'chrome.debugger.event',
132+
tabId: tabId,
133+
options: DebugEvent(method: method, params: params),
134+
);
134135

135136
ExternalExtensionMessage _dwdsEventMessage({
136137
required String method,
137138
required dynamic params,
138139
required int tabId,
139-
}) => ExternalExtensionMessage(name: method, tabId: tabId, options: params);
140+
}) =>
141+
ExternalExtensionMessage(name: method, tabId: tabId, options: params);
140142

141143
// This message is used for cross-extension communication between this extension
142144
// and the AngularDart DevTools extension.

dwds/debug_extension/web/data_serializers.g.dart

Lines changed: 16 additions & 17 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dwds/debug_extension/web/data_types.g.dart

Lines changed: 40 additions & 58 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dwds/debug_extension/web/debug_session.dart

Lines changed: 19 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,7 @@ import 'storage.dart';
3535
import 'utils.dart';
3636
import 'web_api.dart';
3737

38-
const _notADartAppAlert =
39-
'No Dart application detected.'
38+
const _notADartAppAlert = 'No Dart application detected.'
4039
' Are you trying to debug an application that includes a Chrome hosted app'
4140
' (an application listed in chrome://apps)? If so, debugging is disabled.'
4241
' You can fix this by removing the application from chrome://apps. Please'
@@ -82,11 +81,11 @@ enum Trigger {
8281
extensionIcon;
8382

8483
String get clientName => switch (this) {
85-
Trigger.angularDartDevTools => 'acx-devtools',
86-
Trigger.cider => 'cider',
87-
Trigger.extensionPanel => 'embedded-devtools',
88-
Trigger.extensionIcon => 'devtools',
89-
};
84+
Trigger.angularDartDevTools => 'acx-devtools',
85+
Trigger.cider => 'cider',
86+
Trigger.extensionPanel => 'embedded-devtools',
87+
Trigger.extensionIcon => 'devtools',
88+
};
9089
}
9190

9291
enum DebuggerLocation {
@@ -96,11 +95,11 @@ enum DebuggerLocation {
9695
ide;
9796

9897
String get displayName => switch (this) {
99-
DebuggerLocation.angularDartDevTools => 'AngularDart DevTools',
100-
DebuggerLocation.chromeDevTools => 'Chrome DevTools',
101-
DebuggerLocation.dartDevTools => 'a Dart DevTools tab',
102-
DebuggerLocation.ide => 'an IDE',
103-
};
98+
DebuggerLocation.angularDartDevTools => 'AngularDart DevTools',
99+
DebuggerLocation.chromeDevTools => 'Chrome DevTools',
100+
DebuggerLocation.dartDevTools => 'a Dart DevTools tab',
101+
DebuggerLocation.ide => 'an IDE',
102+
};
104103
}
105104

106105
bool get existsActiveDebugSession => _debugSessions.isNotEmpty;
@@ -313,8 +312,7 @@ Future<bool> _isDartFrame({required int tabId, required int contextId}) {
313312
Debuggee(tabId: tabId),
314313
'Runtime.evaluate',
315314
_InjectedParams(
316-
expression:
317-
'[window.\$dartAppId, '
315+
expression: '[window.\$dartAppId, '
318316
'window.\$dartAppInstanceId, '
319317
'window.\$dwdsVersion]',
320318
returnByValue: true,
@@ -644,11 +642,11 @@ Future<bool> _sendStopDebuggingMessage(
644642
_DebugSession? _debugSessionForTab(int tabId, {required TabType type}) {
645643
return switch (type) {
646644
TabType.dartApp => _debugSessions.firstWhereOrNull(
647-
(session) => session.appTabId == tabId,
648-
),
645+
(session) => session.appTabId == tabId,
646+
),
649647
TabType.devTools => _debugSessions.firstWhereOrNull(
650-
(session) => session.devToolsTabId == tabId,
651-
),
648+
(session) => session.devToolsTabId == tabId,
649+
),
652650
};
653651
}
654652

@@ -728,10 +726,9 @@ DebuggerLocation? _debuggerLocation(int dartAppTabId) {
728726
Trigger.angularDartDevTools => DebuggerLocation.angularDartDevTools,
729727
Trigger.cider => DebuggerLocation.ide,
730728
Trigger.extensionPanel => DebuggerLocation.chromeDevTools,
731-
Trigger.extensionIcon =>
732-
debugSession.devToolsTabId != null
733-
? DebuggerLocation.dartDevTools
734-
: DebuggerLocation.ide,
729+
Trigger.extensionIcon => debugSession.devToolsTabId != null
730+
? DebuggerLocation.dartDevTools
731+
: DebuggerLocation.ide,
735732
};
736733
}
737734

dwds/debug_extension/web/detector.dart

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,7 @@ void _detectMultipleDartAppsCallback(
9797
}
9898

9999
bool _isMultipleAppsMutation(dynamic mutation) {
100-
final isAttributeMutation =
101-
hasProperty(mutation, 'type') &&
100+
final isAttributeMutation = hasProperty(mutation, 'type') &&
102101
getProperty(mutation, 'type') == 'attributes';
103102
if (isAttributeMutation) {
104103
return hasProperty(mutation, 'attributeName') &&

0 commit comments

Comments
 (0)