Starting support for Freeplane importation.
This commit is contained in:
parent
b5f4602796
commit
3ef7b531f0
@ -54,6 +54,14 @@ TiddlyWiki class >> fromJSONUrl: anUrlString [
|
|||||||
name: anUrlString
|
name: anUrlString
|
||||||
]
|
]
|
||||||
|
|
||||||
|
{ #category : #accessing }
|
||||||
|
TiddlyWiki class >> fromMindMapFile: mindmapFile [
|
||||||
|
"mindmapFile is a FileReference to a Mind map created in Freeplane."
|
||||||
|
| mindMapXML mindMapNodes |
|
||||||
|
mindMapXML := (XMLDOMParser on: mindmapFile contents) parseDocument.
|
||||||
|
mindMapNodes := mindMapXML xpath: '//node'.
|
||||||
|
]
|
||||||
|
|
||||||
{ #category : #accessing }
|
{ #category : #accessing }
|
||||||
TiddlyWiki class >> loadFromLocalFolder: aFolder [
|
TiddlyWiki class >> loadFromLocalFolder: aFolder [
|
||||||
|
|
||||||
@ -355,7 +363,7 @@ TiddlyWiki >> exportJSONTiddlersTagged: aTag in: aFolder named: aFileName [
|
|||||||
|
|
||||||
| taggedTiddlers jsonString |
|
| taggedTiddlers jsonString |
|
||||||
self tiddlers.
|
self tiddlers.
|
||||||
taggedTiddlers := self taggedWith: aTag.
|
taggedTiddlers := self tagWith: aTag.
|
||||||
jsonString := '[', (',' join: (taggedTiddlers collect: [ :each | each asJsonString ])), ']'.
|
jsonString := '[', (',' join: (taggedTiddlers collect: [ :each | each asJsonString ])), ']'.
|
||||||
^ MarkupFile exportAsFileOn: aFolder / (aFileName, '.json') containing: jsonString
|
^ MarkupFile exportAsFileOn: aFolder / (aFileName, '.json') containing: jsonString
|
||||||
]
|
]
|
||||||
@ -958,7 +966,7 @@ TiddlyWiki >> syncRemoteLocalDestructive [
|
|||||||
]
|
]
|
||||||
|
|
||||||
{ #category : #accessing }
|
{ #category : #accessing }
|
||||||
TiddlyWiki >> taggedWith: aTag [
|
TiddlyWiki >> tagWith: aTag [
|
||||||
^ self tiddlers select: [:tiddler |
|
^ self tiddlers select: [:tiddler |
|
||||||
tiddler tags isNotNil and: [tiddler tags includesSubstring: aTag ]
|
tiddler tags isNotNil and: [tiddler tags includesSubstring: aTag ]
|
||||||
]
|
]
|
||||||
|
Loading…
Reference in New Issue
Block a user