This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const uploadFile = (file, callback) => { | |
const date = Date.now(); | |
const signature = `timestamp=${date}`; | |
RNFetchBlob.fetch( | |
'POST', | |
'https://api.cloudinary.com/v1_1/BUCKET_NAME/video/upload', | |
{ | |
'Content-Type': 'multipart/form-data' | |
}, | |
[ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const path = require('path'); | |
module.exports = { | |
entry: './src/index.js', | |
output: { | |
filename: 'bundle.js', | |
path: path.resolve(__dirname, 'dist'), | |
}, | |
module: { | |
rules: [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from "react"; | |
import { | |
Modal, | |
View, | |
Text, | |
WebView, | |
Dimensions, | |
TouchableOpacity, | |
} from "react-native"; | |
import Icon from "react-native-vector-icons/Ionicons"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import ReactDOM from 'react-dom'; | |
import { | |
Router, | |
Route, | |
browserHistory | |
} from 'react-router' | |
import Header from './Components/Header'; | |
import DayPicker from './Components/DayPicker'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
getActiveItems() { | |
const { filterVideos, videos, structuredVideos, unstructuredVideos} = this.state; | |
let item = null; | |
let activeItem = null; | |
if(!filterVideos || filterVideos === 'all') { | |
item = videos | |
activeItem = 'all'; | |
} else if (filterVideos === 'structured') { | |
item = structuredVideos; | |
activeItem = 'structured'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
render() { | |
let item = null; | |
let activeItem = null; | |
if(!this.state.filterVideos || this.state.filterVideos === 'all') { | |
item = this.state.videos | |
activeItem = 'all'; | |
} else if (this.state.filterVideos === 'structured') { | |
item = this.state.structuredVideos; | |
activeItem = 'structured'; | |
} else if ( this.state.filterVideos === 'unstructured') { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if(!this.state.filterVideos || this.state.filterVideos === 'all') { | |
return ( | |
<View> | |
<ScrollView> | |
<View style={ styles.container }> | |
<InfoBar | |
message="Please note, your CPD record can take up to 24 hours to update" | |
/> | |
<TabBar | |
filterVideos={ this.filterVideos } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$icon-width: 24px; | |
$icon-height: 24px; | |
$icon-tile-x: 10; | |
$icons: 'http://danhannigan.co.uk/social_spritesheet.png'; | |
%social-icon { | |
width: $icon-width; | |
height: $icon-height; | |
background-image: url($icons); | |
display: block; |