Skip to content

Commit

Permalink
Merge branch 'develop' into ts-history-screen
Browse files Browse the repository at this point in the history
* develop:
  Final removal of Private Kit (leaving only attributions) (#465)
  Adjust text vertical centering around pulse (#466)
  • Loading branch information
tstirrat committed Apr 12, 2020
2 parents 6831b97 + ee6d3c1 commit 614ff68
Show file tree
Hide file tree
Showing 59 changed files with 192 additions and 166 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,10 @@ jobs:
- name: Bundle iOS JS
run: npx react-native bundle --dev false --entry-file index.js --bundle-output ios/main.jsbundle --platform ios --verbose
# - name: Build App
# # xcodebuild -workspace PrivateKit.xcworkspace -configuration Debug -scheme PrivateKit
# # xcodebuild -workspace PrivateKit.xcworkspace -scheme PrivateKit archive -archivePath PrivateKit.xcarchive -allowProvisioningUpdates
# # xcodebuild -exportArchive -archivePath ./PrivateKit.xcarchive -exportPath . -exportOptionsPlist PrivateKit/Info.plist
# run: xcodebuild -workspace PrivateKit.xcworkspace -scheme PrivateKit archive -archivePath PrivateKit.xcarchive -allowProvisioningUpdates
# # xcodebuild -workspace COVIDSafePaths.xcworkspace -configuration Debug -scheme COVIDSafePaths
# # xcodebuild -workspace COVIDSafePaths.xcworkspace -scheme COVIDSafePaths archive -archivePath COVIDSafePaths.xcarchive -allowProvisioningUpdates
# # xcodebuild -exportArchive -archivePath ./COVIDSafePaths.xcarchive -exportPath . -exportOptionsPlist COVIDSafePaths/Info.plist
# run: xcodebuild -workspace COVIDSafePaths.xcworkspace -scheme COVIDSafePaths archive -archivePath COVIDSafePaths.xcarchive -allowProvisioningUpdates
# working-directory: ./ios
# - name: Upload Artifact
# uses: actions/upload-artifact@v1
Expand Down
12 changes: 6 additions & 6 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

## 1. Purpose

A primary goal of Private Kit is to be inclusive to the largest number of contributors, with the most varied and diverse backgrounds possible. As such, we are committed to providing a friendly, safe and welcoming environment for all, regardless of gender, sexual orientation, ability, ethnicity, socioeconomic status, and religion (or lack thereof).
A primary goal of COVID Safe Paths is to be inclusive to the largest number of contributors, with the most varied and diverse backgrounds possible. As such, we are committed to providing a friendly, safe and welcoming environment for all, regardless of gender, sexual orientation, ability, ethnicity, socioeconomic status, and religion (or lack thereof).

This code of conduct outlines our expectations for all those who participate in our community, as well as the consequences for unacceptable behavior.

We invite all those who participate in Private Kit to help us create safe and positive experiences for everyone.
We invite all those who participate in COVID Safe Paths to help us create safe and positive experiences for everyone.

## 2. Open [Source/Culture/Tech] Citizenship

Expand Down Expand Up @@ -45,7 +45,7 @@ The following behaviors are considered harassment and are unacceptable within ou

## 5. Weapons Policy

No weapons will be allowed at Private Kit events, community spaces, or in other spaces covered by the scope of this Code of Conduct. Weapons include but are not limited to guns, explosives (including fireworks), and large knives such as those used for hunting or display, as well as any other item used for the purpose of causing injury or harm to others. Anyone seen in possession of one of these items will be asked to leave immediately, and will only be allowed to return without the weapon. Community members are further expected to comply with all state and local laws on this matter.
No weapons will be allowed at COVID Safe Paths events, community spaces, or in other spaces covered by the scope of this Code of Conduct. Weapons include but are not limited to guns, explosives (including fireworks), and large knives such as those used for hunting or display, as well as any other item used for the purpose of causing injury or harm to others. Anyone seen in possession of one of these items will be asked to leave immediately, and will only be allowed to return without the weapon. Community members are further expected to comply with all state and local laws on this matter.

## 6. Consequences of Unacceptable Behavior

Expand All @@ -57,15 +57,15 @@ If a community member engages in unacceptable behavior, the community organizers

## 7. Reporting Guidelines

If you are subject to or witness unacceptable behavior, or have any other concerns, please notify a community organizer as soon as possible. [email protected].
If you are subject to or witness unacceptable behavior, or have any other concerns, please notify a community organizer as soon as possible.



Additionally, community organizers are available to help community members engage with local law enforcement or to otherwise help those experiencing unacceptable behavior feel safe. In the context of in-person events, organizers will also provide escorts as desired by the person experiencing distress.

## 8. Addressing Grievances

If you feel you have been falsely or unfairly accused of violating this Code of Conduct, you should notify Private Kit with a concise description of your grievance. Your grievance will be handled in accordance with our existing governing policies.
If you feel you have been falsely or unfairly accused of violating this Code of Conduct, you should notify COVID Safe Paths with a concise description of your grievance. Your grievance will be handled in accordance with our existing governing policies.



Expand All @@ -77,7 +77,7 @@ This code of conduct and its related procedures also applies to unacceptable beh

## 10. Contact info

[email protected]
[email protected]

## 11. License and attribution

Expand Down
8 changes: 4 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ cd ~ # get to your home directory or where ever you want to go

git clone https://github.com/YOURACCOUNT/

# set upstream against Private Kit repository
# set upstream against COVID Safe Paths repository
git remote add upstream https://github.com/tripleblindmarket/covid-safe-paths.git

```
Expand Down Expand Up @@ -63,11 +63,11 @@ notes to yourself. It's as simple as `git commit -m "commit message goes here"`!
5. Rebase your feature branch with upstream/develop to avoid any code conflicts:

```bash
# 1. Rebase Base(Private Kit) repository with fork repository - develop branch
# 1. Rebase Base(COVID Safe Paths) repository with fork repository - develop branch

git checkout develop # switch to base branch(local)

git fetch upstream # fetch latest commits from "Private kit" develop branch
git fetch upstream # fetch latest commits from "COVID Safe Paths" develop branch

git rebase upstream/develop # rebase code against your forked develop branch(local)

Expand All @@ -81,7 +81,7 @@ git rebase develop # now rebase your feature branch(local) against develop branc

git push origin feature/<your-feature-branch-name> # after resolving all conflicts, push your new feature branch to the remote forked repository

# now your feature branch is ready for PR against Private Kit develop branch.
# now your feature branch is ready for PR against COVID Safe Paths develop branch.
```

6. Start a PR to submit your changes back to the original project:
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# COVID Safe Paths <img align="left" src="./assets/ShieldKeyHold512x512.png" data-canonical-src="./assets/ShieldKeyHold512x512.png" width="40" height="40"/> ![Android and iOS build on MacOS](https://github.com/tripleblindmarket/private-kit/workflows/Android%20and%20iOS%20build%20on%20MacOS/badge.svg)
# COVID Safe Paths <img align="left" src="./assets/ShieldKeyHold512x512.png" data-canonical-src="./assets/ShieldKeyHold512x512.png" width="40" height="40"/> ![Android and iOS build on MacOS](https://github.com/tripleblindmarket/covid-safe-paths/workflows/Android%20and%20iOS%20build%20on%20MacOS/badge.svg)

**applying the technology and philosophy of Private Kit to COVID**

Expand All @@ -24,7 +24,7 @@ Safe Paths logs your device’s location once every five minutes and stores 28 d

**Downloads for COVID Safe Paths:** _coming soon!_

**Downloads for Private Kit:** [Google Play](https://play.google.com/store/apps/details?id=edu.mit.privatekit) | [Apple Store](https://apps.apple.com/us/app/private-kit-prototype/id1501903733)
**Downloads for COVID Safe Paths:** [Google Play](https://play.google.com/store/apps/details?id=edu.mit.privatekit) | [Apple Store](https://apps.apple.com/us/app/private-kit-prototype/id1501903733)

# Development Overview

Expand Down
4 changes: 2 additions & 2 deletions android/app/BUCK
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ android_library(

android_build_config(
name = "build_config",
package = "edu.mit.privatekit",
package = "org.pathcheck.covidsafepaths",
)

android_resource(
name = "res",
package = "edu.mit.privatekit",
package = "org.pathcheck.covidsafepaths",
res = "src/main/res",
)

Expand Down
2 changes: 1 addition & 1 deletion android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ android {
}

defaultConfig {
applicationId "edu.mit.privatekit"
applicationId "org.pathcheck.covidsafepaths"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
multiDexEnabled true
Expand Down
4 changes: 2 additions & 2 deletions android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="edu.mit.privatekit">
package="org.pathcheck.covidsafepaths">

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
Expand Down Expand Up @@ -42,7 +42,7 @@
</activity>
<activity android:name="com.facebook.react.devsupport.DevSettingsActivity" />
<meta-data android:name="com.dieam.reactnativepushnotification.notification_channel_name"
android:value="private_kit_notification_channel"/>
android:value="covidsafepaths_kit_notification_channel"/>
<meta-data android:name="com.dieam.reactnativepushnotification.notification_channel_description"
android:value="Handle all local notifications"/>
<!-- Change the resource name to your App's accent color - or any other color you want -->
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package edu.mit.privatekit;
package org.pathcheck.covidsafepaths;

import android.os.Bundle;
import com.facebook.react.ReactActivity;
Expand All @@ -21,7 +21,7 @@ protected void onCreate(Bundle savedInstanceState) {
*/
@Override
protected String getMainComponentName() {
return "PrivateKit";
return "COVIDSafePaths";
}

@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package edu.mit.privatekit;
package org.pathcheck.covidsafepaths;

import android.app.Application;
import android.content.Context;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package edu.mit.privatekit;
package org.pathcheck.covidsafepaths;

import android.content.Intent;
import android.os.Bundle;
Expand Down
2 changes: 1 addition & 1 deletion android/settings.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
rootProject.name = 'PrivateKit'
rootProject.name = 'COVIDSafePaths'
include ':react-native-reanimated'
project(':react-native-reanimated').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-reanimated/android')
include ':react-native-gesture-handler'
Expand Down
2 changes: 1 addition & 1 deletion app.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"name": "PrivateKit",
"name": "COVIDSafePaths",
"displayName": "COVID Safe Paths"
}
2 changes: 1 addition & 1 deletion app/services/BroadcastingService.js
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ export default class BroadcastingServices {
setTimeout(
() =>
Alert.alert(
'Private Kit requires bluetooth to be enabled',
'COVID Safe Paths requires bluetooth to be enabled',
'Would you like to enable Bluetooth?',
[
{
Expand Down
2 changes: 1 addition & 1 deletion app/services/LocationService.js
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ export default class LocationServices {
BackgroundGeolocation.on('stop', () => {
PushNotification.localNotification({
title: 'Location Tracking Was Disabled',
message: 'Private Kit requires location services.',
message: 'COVID Safe Paths requires location services.',
});
console.log('[INFO] stop');
});
Expand Down
4 changes: 2 additions & 2 deletions app/views/Export.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,9 @@ function ExportScreen(props) {

var options = {};
var jsonData = JSON.stringify(locationData);
const title = 'PrivateKit.json';
const title = 'COVIDSafePaths.json';
const filename = unixtimeUTC + '.json';
const message = 'Here is my location log from Private Kit.';
const message = 'Here is my location log from COVID Safe Paths.';
if (isPlatformiOS()) {
var url = RNFS.DocumentDirectoryPath + '/' + filename;
await RNFS.writeFile(url, jsonData, 'utf8')
Expand Down
50 changes: 38 additions & 12 deletions app/views/LocationTracking.js
Original file line number Diff line number Diff line change
Expand Up @@ -420,14 +420,21 @@ class LocationTracking extends Component {
translucent={true}
/>
{this.getPulseIfNeeded()}

<View style={styles.mainContainer}>
<View style={styles.contentContainer}>
{this.getMainText()}
<View style={styles.contentAbovePulse}>
{this.state.currentState === StateEnum.AT_RISK &&
this.getMainText()}
<Text style={styles.subsubheaderText}>{this.getSubSubText()}</Text>
</View>
<View style={styles.contentBelowPulse}>
{this.state.currentState !== StateEnum.AT_RISK &&
this.getMainText()}
<Text style={styles.subheaderText}>{this.getSubText()}</Text>
{this.getCTAIfNeeded()}
</View>
</View>

<View>
<TouchableOpacity
onPress={this.getMayoInfoPressed.bind(this)}
Expand Down Expand Up @@ -459,21 +466,40 @@ class LocationTracking extends Component {
}
}

const PULSE_GAP = 80;

const styles = StyleSheet.create({
backgroundImage: {
width: '100%',
height: '100%',
resizeMode: 'cover',
flex: 1,
justifyContent: 'flex-end',
},
mainContainer: {
top: '50%',
position: 'absolute',
// resizeMode: 'contain',
// aligns the center of the main container with center of pulse
// so that two `flex: 1` views will be have a reasonable chance at natural
// flex flow for above and below the pulse.
top: '-10%',
left: 0,
right: 0,
height: '100%',
paddingHorizontal: '12%',
paddingBottom: 12,
},
contentAbovePulse: {
flex: 1,
justifyContent: 'flex-end',
alignItems: 'center',
paddingBottom: PULSE_GAP / 2,
},
contentContainer: {
width: width * 0.65,
contentBelowPulse: {
flex: 1,
alignSelf: 'center',
justifyContent: 'flex-start',
alignItems: 'center',
paddingTop: PULSE_GAP,
},
settingsContainer: {
position: 'absolute',
Expand All @@ -483,11 +509,12 @@ const styles = StyleSheet.create({
alignSelf: 'flex-end',
},
buttonContainer: {
top: '9%',
top: 24,
},
pulseContainer: {
position: 'absolute',
resizeMode: 'contain',
height: '100%',
top: '-13%',
left: 0,
right: 0,
Expand All @@ -496,8 +523,7 @@ const styles = StyleSheet.create({
mainTextAbove: {
textAlign: 'center',
lineHeight: 34,
marginTop: -210,
marginBottom: 125,
marginBottom: 24,
color: Colors.WHITE,
fontSize: 28,
fontFamily: fontFamily.primaryMedium,
Expand All @@ -508,23 +534,23 @@ const styles = StyleSheet.create({
color: Colors.WHITE,
fontSize: 26,
fontFamily: fontFamily.primaryMedium,
marginBottom: 24,
},
subheaderText: {
marginTop: 120,
marginBottom: 24,
textAlign: 'center',
lineHeight: 24.5,
color: Colors.WHITE,
fontSize: 18,
fontFamily: fontFamily.primaryRegular,
},
subsubheaderText: {
marginTop: -115,
textAlign: 'center',
lineHeight: 24.5,
color: Colors.WHITE,
fontSize: 16,
fontFamily: fontFamily.primaryLight,
marginBottom: '8%',
marginBottom: 24,
},
mayoInfoRow: {
flexDirection: 'row',
Expand Down
Loading

0 comments on commit 614ff68

Please sign in to comment.