Run prettier fix

Summary: Should also fix the build.

Reviewed By: jknoxville

Differential Revision: D14477777

fbshipit-source-id: 01fcfb2321c9b7a12acdf079473d91b6805d4dda
This commit is contained in:
Pascal Hartig
2019-03-15 05:09:43 -07:00
committed by Facebook Github Bot
parent b354a82066
commit 3141b954bf
16 changed files with 97 additions and 103 deletions

View File

@@ -94,8 +94,7 @@ export function setupMenuBar(
plugin.keyboardActions || [],
)
.reduce((acc: KeyboardActions, cv) => acc.concat(cv), [])
.map(
(action: DefaultKeyboardAction | KeyboardAction) =>
.map((action: DefaultKeyboardAction | KeyboardAction) =>
typeof action === 'string'
? defaultKeyboardActions.find(a => a.action === action)
: action,

View File

@@ -600,9 +600,7 @@ class NotificationItem extends Component<ItemProps, ItemState> {
</Actions>
)}
</NotificationContent>
{action &&
!inactive &&
!isSelected && (
{action && !inactive && !isSelected && (
<FlexColumn style={{alignSelf: 'center'}}>
{action && (
<NotificationButton compact onClick={this.openDeeplink}>

View File

@@ -35,9 +35,7 @@ beforeAll(() => {
return server.init();
});
test(
'Device can connect successfully',
done => {
test('Device can connect successfully', done => {
var testFinished = false;
var disconnectedTooEarly = false;
const registeredClients = [];
@@ -64,9 +62,7 @@ test(
disconnectedTooEarly = true;
}
});
},
20000,
);
}, 20000);
afterAll(() => {
return server.close();

View File

@@ -260,7 +260,8 @@ class BugReporterDialog extends Component<Props, State> {
'mailto:' + String(this.props.activePlugin?.bugs?.email)
}>
{this.props.activePlugin?.bugs?.email}
</Link>, the author/oncall of this plugin, directly
</Link>
, the author/oncall of this plugin, directly
</span>
)}
.

View File

@@ -257,7 +257,8 @@ class PluginDebugger extends Component<Props> {
known to have problems connecting to Flipper. Check out the{' '}
<Link href="https://fbflipper.com/docs/troubleshooting.html#known-incompatibilities">
known incompatibilities
</Link>.
</Link>
.
</InfoText>
);
} else if (
@@ -287,7 +288,8 @@ class PluginDebugger extends Component<Props> {
check out our documentation about{' '}
<Link href="https://fbflipper.com/docs/troubleshooting.html#connection-issues">
connection issues
</Link>.
</Link>
.
</InfoText>
</Fragment>
);

View File

@@ -88,7 +88,8 @@ class TitleBar extends Component<Props> {
<ScreenCaptureButtons />
{this.props.downloadingImportData && (
<Importing>
<LoadingIndicator size={16} />&nbsp;Importing data...
<LoadingIndicator size={16} />
&nbsp;Importing data...
</Importing>
)}
<Spacer />

View File

@@ -90,9 +90,7 @@ export default (store: Store, logger: Logger) => {
if (err.message === 'Connection closed') {
// adb server has shutdown, remove all android devices
const {connections} = store.getState();
const deviceIDsToRemove: Array<
string,
> = connections.devices
const deviceIDsToRemove: Array<string> = connections.devices
.filter(
(device: BaseDevice) => device instanceof AndroidDevice,
)

View File

@@ -405,8 +405,7 @@ class ImageItem extends PureComponent<{
return (
<ImageItem.Container onClick={this.onClick} size={size}>
{numberOfRequests > 0 &&
image != null && (
{numberOfRequests > 0 && image != null && (
<ImageItem.Events>{numberOfRequests}</ImageItem.Events>
)}
{image != null ? (

View File

@@ -36,7 +36,9 @@ export default class ImagesSidebar extends Component<
return (
<div>
{this.renderUri()}
{this.props.events.map(e => <EventDetails key={e.eventId} event={e} />)}
{this.props.events.map(e => (
<EventDetails key={e.eventId} event={e} />
))}
</div>
);
}

View File

@@ -1183,8 +1183,7 @@ class Layout extends FlipperPlugin<InspectorState> {
<LayoutSearchInput onSubmit={this.search.bind(this)} />
{outstandingSearchQuery && <LoadingSpinner size={16} />}
</SearchBox>
{inAXMode &&
showLithoAccessibilitySettings && (
{inAXMode && showLithoAccessibilitySettings && (
<SearchIconContainer
onClick={this.onOpenAccessibilitySettings}
role="button">

View File

@@ -247,12 +247,14 @@ export default class Layout extends FlipperPlugin<State, void, PersistedState> {
)}
{/* TODO: Remove this when rolling out publicly */}
<BetaBar position="bottom" compact>
<Glyph name="beta" color="#8157C7" />&nbsp;
<Glyph name="beta" color="#8157C7" />
&nbsp;
<strong>Version 2.0:</strong>&nbsp; Provide feedback about this plugin
in our&nbsp;
<Link href="https://fb.workplace.com/groups/246035322947653/">
feedback group
</Link>.
</Link>
.
</BetaBar>
</FlexColumn>
);

View File

@@ -314,8 +314,7 @@ export default function reducer(
return {
...state,
uninitializedClients: state.uninitializedClients
.map(
c =>
.map(c =>
isEqual(c.client, payload.client)
? {...c, deviceId: payload.deviceId}
: c,
@@ -337,8 +336,7 @@ export default function reducer(
return {
...state,
uninitializedClients: state.uninitializedClients
.map(
c =>
.map(c =>
isEqual(c.client, payload.client)
? {...c, errorMessage: errorMessage}
: c,

View File

@@ -168,8 +168,7 @@ class ElementsRowAttribute extends PureComponent<{
const {name, value, matchingSearchQuery, selected} = this.props;
return (
<ElementsRowAttributeContainer code={true}>
<ElementsRowAttributeKey>{name}</ElementsRowAttributeKey>
=
<ElementsRowAttributeKey>{name}</ElementsRowAttributeKey>=
<ElementsRowAttributeValue>
<PartialHighlight
content={value}

View File

@@ -68,7 +68,7 @@ export type SecureServerConfig = {|
* It also deploys the Flipper CA cert to the app.
* The app can trust a server if and only if it has a certificate signed by the
* Flipper CA.
*/
*/
export default class CertificateProvider {
logger: Logger;
adb: Promise<any>;

View File

@@ -74,8 +74,8 @@ export function processNotificationStates(
devicePlugins: Map<string, Class<FlipperDevicePlugin<>>>,
): Array<PluginNotification> {
let activeNotifications = allActiveNotifications.filter(notif => {
const filteredClients = clients.filter(
client => (notif.client ? client.id.includes(notif.client) : false),
const filteredClients = clients.filter(client =>
notif.client ? client.id.includes(notif.client) : false,
);
return (
filteredClients.length > 0 ||