From 21c97c8893b87d3fc66ccead3fc364cb6ae66df4 Mon Sep 17 00:00:00 2001 From: ruidajo Date: Sat, 12 Mar 2022 12:51:08 -0500 Subject: [PATCH] Improving filtering tiddlers. --- repository/TiddlyWiki/TiddlyWiki.class.st | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/repository/TiddlyWiki/TiddlyWiki.class.st b/repository/TiddlyWiki/TiddlyWiki.class.st index 3bcb93b..1df79bb 100644 --- a/repository/TiddlyWiki/TiddlyWiki.class.st +++ b/repository/TiddlyWiki/TiddlyWiki.class.st @@ -534,12 +534,25 @@ TiddlyWiki >> resynchronize [ yourself. ] +{ #category : #accessing } +TiddlyWiki >> selectByTagsIncludes: string [ + + ^ (self tiddlers select: [ :tiddler | tiddler tags notNil ]) + select: [ :tiddler | tiddler tags includesSubstring: string ] +] + { #category : #accessing } TiddlyWiki >> selectContentType: mimeType [ ^ self tiddlers select: [ :tiddler | tiddler type isNotNil and: [tiddler type beginsWith: mimeType ]] ] +{ #category : #accessing } +TiddlyWiki >> selectTitleIncludes: string [ + + ^ self tiddlers select: [ :tiddler | tiddler title includesSubstring: string ] +] + { #category : #accessing } TiddlyWiki >> shadow [ "Shadow tiddlers are tiddlers that are loaded from plugins.