WorkFlowyのコマンド?
WF.getSelection()
たぶん、選択している項目を取得する
WF.focusedItem()
WF.createItem()
たぶん、新規項目を作成する
getParent()
たぶん、親を取得する
getPriority()
WF.moveItems(e,t,n)
項目を移動させる
eが移動したい項目
tが移動先の親項目
nが何番目の項目にするか。
定義
code:script.js
moveItems:function(e,t,n){var r=e.map((function(e){return e.data.projectReferenceOrThrow}));k.dv()?u.move(r,t.data.projectReferenceOrThrow,n):k.Qk((function(){u.move(r,t.data.projectReferenceOrThrow,n)}))},
WF.expandItem()
WF.editItemName()
by:
それっぽい部分。
code:document_view.min.js
focusedItem:function(){var e=a.getCurrentlyFocusedContent();return e?new T(a.getProjectReferenceFromElement(e0).getItem()):null},rootItem:function(){return new T(v.getMainProjectTree().getRootProject())}, getItemById:function(e){var t=r.g(e);return t?new T(t.getItem()):null},shortIdToId:function(e){return r.j(e)},search:b.u,clearSearch:b.d,currentSearchQuery:function(){return m.e().getSearchQuery()},
getItemTags:function(e){var t=e.getNameInPlainText();return t?O.h(t):[]},
getItemNameTags:function(e){var t=e.getNameInPlainText();return t?O.h(t):[]},getItemNoteTags:function(e){var t=e.getNoteInPlainText();return t?O.h(t):[]},
isCurrentItemStarred:x.d,isCurrentLocationStarred:x.d,toggleCurrentItemStarred:x.g,
toggleCurrentLocationStarred:x.g,starredItems:function(){return x.b(Object(_.g)().settings.saved_views_json).map(function(e){return e.toItem()}).filter(function(e){return!!e}).map(function(e){return new T(e)})},
starredLocations:function(){return x.b(Object(_.g)().settings.saved_views_json).map(function(e){var t=e.toItem();return t?{item:new T(t),search:e.getSearchQuery()}:null}).filter(function(e){return!!e})},
createItem:function(e,t){void 0===t&&(t=0);var n=a.addChild(e.data.projectReferenceOrThrow,t);return new T(n.getItem())},
deleteItem:function(t){var n=t.getElement();n&&a.deleteProjectsWithWarning(e(n),S.d())},
duplicateItem:function(e){if(e.getElement()){var t=e.data.projectReferenceOrThrow,n=a.duplicate(t,t.getParent(),t.getPriority()+1)0,r=n.getMatchingDomProject();return r.length>0&&r.is(":visible")&&c.s(r.children(".name").children(".content"),0),new T(n.getItem())}}, completeItem:function(e){a.toggleComplete(e.data)}, expandItem:function(e){e.data.isExpanded=!0,Object(o.a)();var t=e.getElement();t&&a.animateExpand(t)},
collapseItem:function(e){var t=e.getElement();t&&a.animateCollapse(t),e.data.isExpanded=!1,Object(o.a)()},
setItemName:function(e,t){var n=e.data.projectReferenceOrThrow;S.d()?n.applyLocalEdit(t,null):S.f(function(){n.applyLocalEdit(t,null)})},
setItemNote:function(e,t){var n=e.data.projectReferenceOrThrow;S.d()?n.applyLocalEdit(null,t):S.f(function(){n.applyLocalEdit(null,t)})},
moveItems:function(e,t,n){var r=e.map(function(e){return e.data.projectReferenceOrThrow});S.d()?a.move(r,t.data.projectReferenceOrThrow,n):S.f(function(){a.move(r,t.data.projectReferenceOrThrow,n)})},insertText:a.insertText,editGroup:S.f,save:function(){a.saveEditingContent(),Object(y.f)()},undo:S.l,redo:S.e,
getSelection:function(){return p.f().map(function(e){return new T(e)})},setSelection:function(e){p.c(),p.a(e.map(function(e){return e.data})),p.u()},
editItemName:function(t){var n=t.getElement();n&&c.s(e(n).children(".name").children(".content"),-1)},
editItemNote:function(t){var n=t.getElement();n&&a.editNote(e(n))},
getItemDOMElement:j("WF.getItemDOMElement","Item.getElement",function(e){return e.getElement()}),
export:j("WF.export","WF.showExportDialog",s.b),
showExportDialog:function(e){return s.b(e.map(function(e){return e.data.projectReferenceOrThrow}))},
exportHTML:function(e){return s.cs.a.Html(e.map(function(e){return e.data.projectReferenceOrThrow}),!0)}, exportText:function(e){return s.cs.a.Text(e.map(function(e){return e.data.projectReferenceOrThrow}),!0)}, exportOPML:function(e){return s.cs.a.Opml(e.map(function(e){return e.data.projectReferenceOrThrow}),!0)}, showShareDialog:function(t){var n=t.getElement();n&&w.e(e(n))},
zoomTo:function(e){return m.g(e.data.projectReferenceOrThrow)},
zoomOut:function(){var e=Object(_.g)().currentItem;e.isMainDocumentRoot||a.zoomTo(e.parentOrThrow.projectReferenceOrThrow,"last_selected")},
zoomIn:function(e){return a.zoomTo(e.data.projectReferenceOrThrow,"first_child")},
zoomToGuideId:function(e){var t=l.a.get(e);return void 0!==t&&(m.g(t),!0)},completedVisible:a.shouldShowCompletedProjects,toggleCompletedVisible:a.toggleCompletedVisibility,showMessage:g.m,hideMessage:g.f,
showAlertDialog:function(e,n){return void 0===n&&(n=""),u.e(t.createElement("div",{dangerouslySetInnerHTML:{__html:e}}),n)},hideDialog:u.c},C={$:e,createNewProject:j("createNewProject","WF.createItem(parent: Item, priority: string)",a.addChild),
focusFirstChildOfSelected:j("focusFirstChildOfSelected","WF.editItemName",a.focusFirstChildOfSelected),
toggleCompletedVisibility:j("toggleCompletedVisibility","WF.toggleCompleted",a.toggleCompletedVisibility),keyboardZoomOut:j("keyboardZoomOut","WF.zoomOut",function(){var e=Object(_.g)().currentItem;e.isMainDocumentRoot||a.zoomTo(e.parentOrThrow.projectReferenceOrThrow,"last_selected")}),
keyboardZoomIn:j("keyboardZoomIn","WF.zoomIn",function(){a.zoomTo(v.getProjectReferenceFromDomProject(a.getProject(e(this))),"first_child")}),
selectProjectReferenceInstantly:j("selectProjectReferenceInstantly","WF.zoomTo",m.g),
focusLastProject:a.focusLastProject,filterReadOnlyProjects:a.filterReadOnlyProjects,addItemToTopOfSelected:j("addItemToTopOfSelected","WF.createItem",a.addItemToTopOfSelected),applyLocalMoveForProjectReferences:v.applyLocalMoveForProjectReferences,
blurFocusedContent:a.blurFocusedContent,childrenAreInReadOnlyTree:j("itemData.childrenAreInReadOnlyTree","Item.isReadOnly",function(e){return e.childrenAreInReadOnlyTree}),
getActivePage:j("getActivePage",null,function(){return e(".page")}),
getMainProjectTree:v.getMainProjectTree,
getCurrentlyFocusedContent:j("getCurrentlyFocusedContent","WF.focusedItem",a.getCurrentlyFocusedContent),selectOnActivePage:e,
showSharePopup:j("showSharePopup()","WF.showShareDialog(item: Item)",w.e),
getProjectReferenceFromDomProject:j("project_tree.getProjectReferenceFromDomProject",null,v.getProjectReferenceFromDomProject),
getRootDescendantTagCounts:
getCurrentLocation:j("location_history.getCurrentLocation","WF.currentItem and WF.currentSearchQuery",function(){var e=m.e();return e?{_zoomedProjectId:e.getZoomedProjectId(),_searchQuery:e.getSearchQuery(),getNameText:function(){return e.getNameText()}}:null})},undo_redo:
e.fn.getContentText=j("JQuery.getContentText","WF.getItemName and WF.getItemNote",function(){return i.c(e(this)).getText()}),window.WF=k,C)windowP=CP}.call(this,n(43))},function(e,t,n){"use strict";n.d(t,"a",function(){return u});var r=n(0),o=n(16),i=n(517),a=r.memo(function(){var e=r.useCallback(function(){o.d(r.createElement(o.b,null,"You’ve updated your payment details."))},[]);