1
0
mirror of https://github.com/laurent22/joplin.git synced 2024-12-15 09:04:04 +02:00
joplin/ReactNativeClient/lib/components/folder-list.js

27 lines
714 B
JavaScript
Raw Normal View History

2017-05-15 21:46:34 +02:00
import React, { Component } from 'react';
import { connect } from 'react-redux'
import { ListView, Text, TouchableHighlight } from 'react-native';
2017-06-24 20:06:28 +02:00
import { Log } from 'lib/log.js';
import { ItemListComponent } from 'lib/components/item-list.js';
import { Note } from 'lib/models/note.js';
import { Folder } from 'lib/models/folder.js';
import { _ } from 'lib/locale.js';
2017-07-05 23:29:00 +02:00
import { NotesScreenUtils } from 'lib/components/screens/notes-utils.js'
2017-05-15 21:46:34 +02:00
class FolderListComponent extends ItemListComponent {
2017-06-06 22:01:43 +02:00
listView_itemPress(folderId) {
2017-07-05 23:29:00 +02:00
NotesScreenUtils.openNoteList(folderId);
2017-05-15 21:46:34 +02:00
}
}
const FolderList = connect(
(state) => {
2017-05-15 22:50:14 +02:00
return {
items: state.folders,
};
2017-05-15 21:46:34 +02:00
}
)(FolderListComponent)
export { FolderList };