1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-15 10:46:32 +00:00
This commit is contained in:
Rokt33r
2015-12-28 16:11:42 +09:00
parent f9539ab50a
commit e4d8438801
5 changed files with 125 additions and 34 deletions

View File

@@ -5,6 +5,7 @@ export const CLEAR_NEW_ARTICLE = 'CLEAR_NEW_ARTICLE'
export const ARTICLE_UPDATE = 'ARTICLE_UPDATE'
export const ARTICLE_DESTROY = 'ARTICLE_DESTROY'
export const ARTICLE_SAVE = 'ARTICLE_SAVE'
export const ARTICLE_SAVE_ALL = 'ARTICLE_SAVE_ALL'
export const ARTICLE_CACHE = 'ARTICLE_CACHE'
export const FOLDER_CREATE = 'FOLDER_CREATE'
export const FOLDER_UPDATE = 'FOLDER_UPDATE'
@@ -16,7 +17,6 @@ export const SWITCH_ARTICLE = 'SWITCH_ARTICLE'
export const SET_SEARCH_FILTER = 'SET_SEARCH_FILTER'
export const SET_TAG_FILTER = 'SET_TAG_FILTER'
export const CLEAR_SEARCH = 'CLEAR_SEARCH'
export const TOGGLE_ONLY_UNSAVED_FILTER = 'TOGGLE_ONLY_UNSAVED_FILTER'
export const TOGGLE_TUTORIAL = 'TOGGLE_TUTORIAL'
@@ -51,6 +51,12 @@ export function saveArticle (key, article, forceSwitch) {
}
}
export function saveAllArticles () {
return {
type: ARTICLE_SAVE_ALL
}
}
export function updateArticle (article) {
return {
type: ARTICLE_UPDATE,
@@ -132,12 +138,6 @@ export function clearSearch () {
}
}
export function toggleOnlyUnsavedFilter () {
return {
type: TOGGLE_ONLY_UNSAVED_FILTER
}
}
export function toggleTutorial () {
return {
type: TOGGLE_TUTORIAL
@@ -146,20 +146,23 @@ export function toggleTutorial () {
export default {
updateUser,
clearNewArticle,
updateArticle,
destroyArticle,
cacheArticle,
saveArticle,
saveAllArticles,
createFolder,
updateFolder,
destroyFolder,
replaceFolder,
switchFolder,
switchArticle,
setSearchFilter,
setTagFilter,
clearSearch,
toggleOnlyUnsavedFilter,
toggleTutorial
}