Merge branch '84-clean-up-folder-structure' into 'master'
Resolve "clean up folder structure" Closes #48 See merge request bloodyhealth/drip!19
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
import { createStackNavigator } from 'react-navigation'
|
||||
import Home from './home'
|
||||
import Home from './components/home'
|
||||
|
||||
import Calendar from './calendar'
|
||||
import CycleDay from './cycle-day'
|
||||
import Chart from './components/chart'
|
||||
import Calendar from './components/calendar'
|
||||
import CycleDay from './components/cycle-day'
|
||||
import Chart from './components/chart/chart'
|
||||
|
||||
// this is until react native fixes this bug, see https://github.com/facebook/react-native/issues/18868#issuecomment-382671739
|
||||
import { YellowBox } from 'react-native'
|
||||
|
||||
@@ -6,9 +6,9 @@ import {
|
||||
Switch
|
||||
} from 'react-native'
|
||||
import RadioForm from 'react-native-simple-radio-button'
|
||||
import styles from './styles'
|
||||
import { saveBleeding } from './db'
|
||||
import { bleeding as labels } from './labels'
|
||||
import styles from '../styles/index'
|
||||
import { saveBleeding } from '../db'
|
||||
import { bleeding as labels } from '../labels/labels'
|
||||
|
||||
export default class Bleeding extends Component {
|
||||
constructor(props) {
|
||||
@@ -1,8 +1,8 @@
|
||||
import React, { Component } from 'react'
|
||||
import { View } from 'react-native'
|
||||
import { Calendar } from 'react-native-calendars'
|
||||
import * as styles from './styles'
|
||||
import { getOrCreateCycleDay, bleedingDaysSortedByDate } from './db'
|
||||
import * as styles from '../styles/index'
|
||||
import { getOrCreateCycleDay, bleedingDaysSortedByDate } from '../db'
|
||||
|
||||
export default class CalendarView extends Component {
|
||||
constructor(props) {
|
||||
@@ -10,8 +10,8 @@ import Svg,{
|
||||
Path
|
||||
} from 'react-native-svg'
|
||||
import { LocalDate } from 'js-joda'
|
||||
import { getCycleDay, getOrCreateCycleDay, cycleDaysSortedByDate } from '../db'
|
||||
import getCycleDayNumberModule from '../get-cycle-day-number'
|
||||
import { getCycleDay, getOrCreateCycleDay, cycleDaysSortedByDate } from '../../db'
|
||||
import getCycleDayNumberModule from '../../lib/get-cycle-day-number'
|
||||
import styles from './styles'
|
||||
import config from './config'
|
||||
|
||||
@@ -4,10 +4,10 @@ import {
|
||||
Button,
|
||||
Text
|
||||
} from 'react-native'
|
||||
import styles from './styles'
|
||||
import { bleeding as labels} from './labels'
|
||||
import cycleDayModule from './get-cycle-day-number'
|
||||
import { bleedingDaysSortedByDate } from './db'
|
||||
import styles from '../styles/index'
|
||||
import { bleeding as labels} from '../labels/labels'
|
||||
import cycleDayModule from '../lib/get-cycle-day-number'
|
||||
import { bleedingDaysSortedByDate } from '../db'
|
||||
|
||||
const getCycleDayNumber = cycleDayModule()
|
||||
|
||||
@@ -3,12 +3,12 @@ import {
|
||||
View,
|
||||
Text
|
||||
} from 'react-native'
|
||||
import cycleDayModule from './get-cycle-day-number'
|
||||
import cycleDayModule from '../lib/get-cycle-day-number'
|
||||
import DayView from './cycle-day-overview'
|
||||
import BleedingEditView from './bleeding'
|
||||
import TemperatureEditView from './temperature'
|
||||
import { formatDateForViewHeader } from './format'
|
||||
import styles from './styles'
|
||||
import { formatDateForViewHeader } from '../labels/format'
|
||||
import styles from '../styles/index'
|
||||
|
||||
const getCycleDayNumber = cycleDayModule()
|
||||
|
||||
@@ -5,9 +5,9 @@ import {
|
||||
Text
|
||||
} from 'react-native'
|
||||
import { LocalDate } from 'js-joda'
|
||||
import styles from './styles'
|
||||
import cycleDayModule from './get-cycle-day-number'
|
||||
import { getOrCreateCycleDay, bleedingDaysSortedByDate, deleteAll } from './db'
|
||||
import styles from '../styles/index'
|
||||
import cycleDayModule from '../lib/get-cycle-day-number'
|
||||
import { getOrCreateCycleDay, bleedingDaysSortedByDate, deleteAll } from '../db'
|
||||
|
||||
const getCycleDayNumber = cycleDayModule()
|
||||
|
||||
@@ -7,8 +7,8 @@ import {
|
||||
Switch
|
||||
} from 'react-native'
|
||||
|
||||
import { saveTemperature, getPreviousTemperature } from './db'
|
||||
import styles from './styles'
|
||||
import { saveTemperature, getPreviousTemperature } from '../db'
|
||||
import styles from '../styles/index'
|
||||
|
||||
export default class Temp extends Component {
|
||||
constructor(props) {
|
||||
@@ -6,7 +6,7 @@ export default function config(opts = {}) {
|
||||
let bleedingDaysSortedByDate
|
||||
if (!opts.bleedingDaysSortedByDate) {
|
||||
// we only want to require (and run) the db module when not running the tests
|
||||
bleedingDaysSortedByDate = require('./db').bleedingDaysSortedByDate
|
||||
bleedingDaysSortedByDate = require('../db').bleedingDaysSortedByDate
|
||||
} else {
|
||||
bleedingDaysSortedByDate = opts.bleedingDaysSortedByDate
|
||||
}
|
||||
@@ -4,7 +4,7 @@ import dirtyChai from 'dirty-chai'
|
||||
const expect = chai.expect
|
||||
chai.use(dirtyChai)
|
||||
|
||||
import getCycleDayNumberModule from '../get-cycle-day-number'
|
||||
import getCycleDayNumberModule from '../lib/get-cycle-day-number'
|
||||
|
||||
describe('getCycleDay', () => {
|
||||
it('works for a simple example', function () {
|
||||
|
||||
Reference in New Issue
Block a user