Skip to content

Commit

Permalink
⚡ Creating the initial view and configuring the project structure.
Browse files Browse the repository at this point in the history
  • Loading branch information
krrskl committed Jul 2, 2020
1 parent 5428fee commit 8ab46a7
Show file tree
Hide file tree
Showing 34 changed files with 319 additions and 174 deletions.
118 changes: 0 additions & 118 deletions App.tsx

This file was deleted.

Binary file added android/app/src/main/assets/fonts/AntDesign.ttf
Binary file not shown.
Binary file added android/app/src/main/assets/fonts/Entypo.ttf
Binary file not shown.
Binary file added android/app/src/main/assets/fonts/EvilIcons.ttf
Binary file not shown.
Binary file added android/app/src/main/assets/fonts/Feather.ttf
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added android/app/src/main/assets/fonts/Fontisto.ttf
Binary file not shown.
Binary file added android/app/src/main/assets/fonts/Foundation.ttf
Binary file not shown.
Binary file added android/app/src/main/assets/fonts/Ionicons.ttf
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added android/app/src/main/assets/fonts/Octicons.ttf
Binary file not shown.
Binary file not shown.
Binary file added android/app/src/main/assets/fonts/Zocial.ttf
Binary file not shown.
13 changes: 3 additions & 10 deletions android/app/src/main/java/com/lastfmlevelone/MainActivity.java
Original file line number Diff line number Diff line change
@@ -1,15 +1,8 @@
package com.lastfmlevelone;

import com.facebook.react.ReactActivity;
import com.reactnativenavigation.NavigationActivity;

public class MainActivity extends ReactActivity {
public class MainActivity extends NavigationActivity {

/**
* Returns the name of the main component registered from JavaScript. This is used to schedule
* rendering of the component.
*/
@Override
protected String getMainComponentName() {
return "LastFMLevelOne";
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,19 @@
import android.app.Application;
import android.content.Context;
import com.facebook.react.PackageList;
import com.facebook.react.ReactApplication;
import com.reactnativenavigation.NavigationApplication;
import com.facebook.react.ReactInstanceManager;
import com.facebook.react.ReactNativeHost;
import com.reactnativenavigation.react.NavigationReactNativeHost;
import com.facebook.react.ReactPackage;
import com.facebook.soloader.SoLoader;
import java.lang.reflect.InvocationTargetException;
import java.util.List;

public class MainApplication extends Application implements ReactApplication {
public class MainApplication extends NavigationApplication {

private final ReactNativeHost mReactNativeHost =
new ReactNativeHost(this) {
new NavigationReactNativeHost(this) {
@Override
public boolean getUseDeveloperSupport() {
return BuildConfig.DEBUG;
Expand Down Expand Up @@ -43,7 +44,7 @@ public ReactNativeHost getReactNativeHost() {
@Override
public void onCreate() {
super.onCreate();
SoLoader.init(this, /* native exopackage */ false);

initializeFlipper(this, getReactNativeHost().getReactInstanceManager());
}

Expand Down
4 changes: 3 additions & 1 deletion android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@

buildscript {
ext {
RNNKotlinVersion = "1.3.61"
buildToolsVersion = "28.0.3"
minSdkVersion = 16
minSdkVersion = 19
compileSdkVersion = 28
targetSdkVersion = 28
}
Expand All @@ -12,6 +13,7 @@ buildscript {
jcenter()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.61"
classpath("com.android.tools.build:gradle:3.5.2")

// NOTE: Do not place your application dependencies here; they belong
Expand Down
2 changes: 2 additions & 0 deletions android/settings.gradle
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
rootProject.name = 'LastFMLevelOne'
include ':react-native-vector-icons'
project(':react-native-vector-icons').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-vector-icons/android')
apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings)
include ':app'
20 changes: 20 additions & 0 deletions app/App.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import {registerScreens} from './core/navigation';
import {Navigation} from 'react-native-navigation';

registerScreens();

Navigation.events().registerAppLaunchedListener(async () => {
Navigation.setRoot({
root: {
stack: {
children: [
{
component: {
name: 'HomeScreen',
},
},
],
},
},
});
});
13 changes: 13 additions & 0 deletions app/components/Artist/ArtistScreen.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import React from 'react';
import {View} from 'react-native';
import {Text} from 'react-native-elements';

const ArtistScreen: React.FC = () => {
return (
<View>
<Text h3>ArtistScreen works!</Text>
</View>
);
};

export default ArtistScreen;
20 changes: 20 additions & 0 deletions app/components/Home/HomeScreen.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import React from 'react';
import {View} from 'react-native';
import {Text} from 'react-native-elements';
import HomeStyles from './styles';

const HomeScreen: React.FC = () => {
return (
<View style={HomeStyles.mainContainer}>
<Text h3>Bienvenido!</Text>
<Text style={HomeStyles.center}>
<Text>Esta app fue desarrollada por {'\n'} </Text>
<Text style={HomeStyles.bold}>Rubén Carrascal </Text>
<Text>para </Text>
<Text style={HomeStyles.bold}>valid.com</Text>
</Text>
</View>
);
};

export default HomeScreen;
9 changes: 9 additions & 0 deletions app/components/Home/styles.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import {StyleSheet} from 'react-native';

const HomeStyles = StyleSheet.create({
mainContainer: {flex: 1, justifyContent: 'center', alignItems: 'center'},
bold: {fontWeight: 'bold'},
center: {textAlign: 'center'},
});

export default HomeStyles;
3 changes: 3 additions & 0 deletions app/core/config/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export default {
api: 'http://ws.audioscrobbler.com/2.0',
};
6 changes: 6 additions & 0 deletions app/core/navigation/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import {Navigation} from 'react-native-navigation';
import HomeScreen from '../../components/Home/HomeScreen';

export function registerScreens() {
Navigation.registerComponent('HomeScreen', () => HomeScreen);
}
6 changes: 1 addition & 5 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
/**
* @format
*/

import {AppRegistry} from 'react-native';
import App from './App';
import App from './app/App';
import {name as appName} from './app.json';

AppRegistry.registerComponent(appName, () => App);
73 changes: 73 additions & 0 deletions ios/LastFMLevelOne.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,22 @@
2D02E4BD1E0B4A84006451C7 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
2DCD954D1E0B4F2C00145EB5 /* LastFMLevelOneTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* LastFMLevelOneTests.m */; };
AE53C1E88CB84E7AA3305C43 /* AntDesign.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 8D6F4DF074B64D6DA62A82A5 /* AntDesign.ttf */; };
740309451C384B0794A6B2C0 /* Entypo.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 3A4E1F4B2BDC4543A3D95DE9 /* Entypo.ttf */; };
FACDC7E6860649638EA33E54 /* EvilIcons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 26285873812647778C686837 /* EvilIcons.ttf */; };
5F4598A5A3D442D49142EBEA /* Feather.ttf in Resources */ = {isa = PBXBuildFile; fileRef = C66A31B93E6144E99A558C72 /* Feather.ttf */; };
457E5AC4DFF34994B644C478 /* FontAwesome.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 7C55DDA67DB644769F67AA61 /* FontAwesome.ttf */; };
2AFA6767E266431199C89A7C /* FontAwesome5_Brands.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 3D0EF57E76C04F489D92DB57 /* FontAwesome5_Brands.ttf */; };
5192F94291BB4BA1A986BBD2 /* FontAwesome5_Regular.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 5FCBDD2C1E2547308079C674 /* FontAwesome5_Regular.ttf */; };
E894EA324CC34DE389223CD3 /* FontAwesome5_Solid.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 685AD923CAD94F129D389F81 /* FontAwesome5_Solid.ttf */; };
A86C41B62BFA4F3DA5AC62B0 /* Fontisto.ttf in Resources */ = {isa = PBXBuildFile; fileRef = B2F5675A529B4AC3BFB74E3A /* Fontisto.ttf */; };
02E5290CF8EE4CFF941136D7 /* Foundation.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 9C404BF61E324B3AB4B9A7A0 /* Foundation.ttf */; };
35774314A1584D78B3D316A4 /* Ionicons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = F453B81B78564B118BCFA8BC /* Ionicons.ttf */; };
D41C05B7D34240CBA29A4671 /* MaterialCommunityIcons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = F19DA091E4B24B5A90CF8764 /* MaterialCommunityIcons.ttf */; };
EBCEE3B7E12A4909895AADC8 /* MaterialIcons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 5208D21F0C8A4BD79B7590E7 /* MaterialIcons.ttf */; };
2B3F807F06874971BE4988E6 /* Octicons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 44B34CECD3EA470C83DA6B02 /* Octicons.ttf */; };
E854049E27564307A0AB70BF /* SimpleLineIcons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 174FA6CFF0964B7D8BEC2E6A /* SimpleLineIcons.ttf */; };
7E10513DED7C4EEA93E0B20A /* Zocial.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 45C7FDCABEE74FDE8FEF5884 /* Zocial.ttf */; };
/* End PBXBuildFile section */

/* Begin PBXContainerItemProxy section */
Expand Down Expand Up @@ -51,6 +67,22 @@
2D02E4901E0B4A5D006451C7 /* LastFMLevelOne-tvOSTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "LastFMLevelOne-tvOSTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; };
ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
ED2971642150620600B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS12.0.sdk/System/Library/Frameworks/JavaScriptCore.framework; sourceTree = DEVELOPER_DIR; };
8D6F4DF074B64D6DA62A82A5 /* AntDesign.ttf */ = {isa = PBXFileReference; name = "AntDesign.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/AntDesign.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
3A4E1F4B2BDC4543A3D95DE9 /* Entypo.ttf */ = {isa = PBXFileReference; name = "Entypo.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/Entypo.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
26285873812647778C686837 /* EvilIcons.ttf */ = {isa = PBXFileReference; name = "EvilIcons.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/EvilIcons.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
C66A31B93E6144E99A558C72 /* Feather.ttf */ = {isa = PBXFileReference; name = "Feather.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/Feather.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
7C55DDA67DB644769F67AA61 /* FontAwesome.ttf */ = {isa = PBXFileReference; name = "FontAwesome.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/FontAwesome.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
3D0EF57E76C04F489D92DB57 /* FontAwesome5_Brands.ttf */ = {isa = PBXFileReference; name = "FontAwesome5_Brands.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/FontAwesome5_Brands.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
5FCBDD2C1E2547308079C674 /* FontAwesome5_Regular.ttf */ = {isa = PBXFileReference; name = "FontAwesome5_Regular.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/FontAwesome5_Regular.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
685AD923CAD94F129D389F81 /* FontAwesome5_Solid.ttf */ = {isa = PBXFileReference; name = "FontAwesome5_Solid.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/FontAwesome5_Solid.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
B2F5675A529B4AC3BFB74E3A /* Fontisto.ttf */ = {isa = PBXFileReference; name = "Fontisto.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/Fontisto.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
9C404BF61E324B3AB4B9A7A0 /* Foundation.ttf */ = {isa = PBXFileReference; name = "Foundation.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/Foundation.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
F453B81B78564B118BCFA8BC /* Ionicons.ttf */ = {isa = PBXFileReference; name = "Ionicons.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/Ionicons.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
F19DA091E4B24B5A90CF8764 /* MaterialCommunityIcons.ttf */ = {isa = PBXFileReference; name = "MaterialCommunityIcons.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/MaterialCommunityIcons.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
5208D21F0C8A4BD79B7590E7 /* MaterialIcons.ttf */ = {isa = PBXFileReference; name = "MaterialIcons.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/MaterialIcons.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
44B34CECD3EA470C83DA6B02 /* Octicons.ttf */ = {isa = PBXFileReference; name = "Octicons.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/Octicons.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
174FA6CFF0964B7D8BEC2E6A /* SimpleLineIcons.ttf */ = {isa = PBXFileReference; name = "SimpleLineIcons.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/SimpleLineIcons.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
45C7FDCABEE74FDE8FEF5884 /* Zocial.ttf */ = {isa = PBXFileReference; name = "Zocial.ttf"; path = "../node_modules/react-native-vector-icons/Fonts/Zocial.ttf"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
Expand Down Expand Up @@ -140,6 +172,7 @@
00E356EF1AD99517003FC87E /* LastFMLevelOneTests */,
83CBBA001A601CBA00E9B192 /* Products */,
2D16E6871FA4F8E400B85C8A /* Frameworks */,
1FCFD40ECE3C4ED487FA9F73 /* Resources */,
);
indentWidth = 2;
sourceTree = "<group>";
Expand All @@ -157,6 +190,30 @@
name = Products;
sourceTree = "<group>";
};
1FCFD40ECE3C4ED487FA9F73 /* Resources */ = {
isa = "PBXGroup";
children = (
8D6F4DF074B64D6DA62A82A5 /* AntDesign.ttf */,
3A4E1F4B2BDC4543A3D95DE9 /* Entypo.ttf */,
26285873812647778C686837 /* EvilIcons.ttf */,
C66A31B93E6144E99A558C72 /* Feather.ttf */,
7C55DDA67DB644769F67AA61 /* FontAwesome.ttf */,
3D0EF57E76C04F489D92DB57 /* FontAwesome5_Brands.ttf */,
5FCBDD2C1E2547308079C674 /* FontAwesome5_Regular.ttf */,
685AD923CAD94F129D389F81 /* FontAwesome5_Solid.ttf */,
B2F5675A529B4AC3BFB74E3A /* Fontisto.ttf */,
9C404BF61E324B3AB4B9A7A0 /* Foundation.ttf */,
F453B81B78564B118BCFA8BC /* Ionicons.ttf */,
F19DA091E4B24B5A90CF8764 /* MaterialCommunityIcons.ttf */,
5208D21F0C8A4BD79B7590E7 /* MaterialIcons.ttf */,
44B34CECD3EA470C83DA6B02 /* Octicons.ttf */,
174FA6CFF0964B7D8BEC2E6A /* SimpleLineIcons.ttf */,
45C7FDCABEE74FDE8FEF5884 /* Zocial.ttf */,
);
name = Resources;
sourceTree = "<group>";
path = "";
};
/* End PBXGroup section */

/* Begin PBXNativeTarget section */
Expand Down Expand Up @@ -295,6 +352,22 @@
files = (
13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */,
AE53C1E88CB84E7AA3305C43 /* AntDesign.ttf in Resources */,
740309451C384B0794A6B2C0 /* Entypo.ttf in Resources */,
FACDC7E6860649638EA33E54 /* EvilIcons.ttf in Resources */,
5F4598A5A3D442D49142EBEA /* Feather.ttf in Resources */,
457E5AC4DFF34994B644C478 /* FontAwesome.ttf in Resources */,
2AFA6767E266431199C89A7C /* FontAwesome5_Brands.ttf in Resources */,
5192F94291BB4BA1A986BBD2 /* FontAwesome5_Regular.ttf in Resources */,
E894EA324CC34DE389223CD3 /* FontAwesome5_Solid.ttf in Resources */,
A86C41B62BFA4F3DA5AC62B0 /* Fontisto.ttf in Resources */,
02E5290CF8EE4CFF941136D7 /* Foundation.ttf in Resources */,
35774314A1584D78B3D316A4 /* Ionicons.ttf in Resources */,
D41C05B7D34240CBA29A4671 /* MaterialCommunityIcons.ttf in Resources */,
EBCEE3B7E12A4909895AADC8 /* MaterialIcons.ttf in Resources */,
2B3F807F06874971BE4988E6 /* Octicons.ttf in Resources */,
E854049E27564307A0AB70BF /* SimpleLineIcons.ttf in Resources */,
7E10513DED7C4EEA93E0B20A /* Zocial.ttf in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down
Loading

0 comments on commit 8ab46a7

Please sign in to comment.