Text formating for link list coming from Brave.

This commit is contained in:
Offray Vladimir Luna Cárdenas 2025-01-08 18:08:22 -05:00
parent c1b4c3e90b
commit ffa7ca5f3d

View File

@ -574,6 +574,24 @@ Tiddler >> renumberWihtMarkup [
self text: response contents
]
{ #category : #accessing }
Tiddler >> replaceRawLinksListWithNamedLinks [
| response |
response := '' writeStream.
self text lines do: [:line | | lineSegments webLink |
lineSegments := line splitOn: Character space.
webLink := lineSegments second asUrl.
webLink host isNil
ifTrue: [ response nextPutAll: line; cr ]
ifFalse: [ | linkTitle|
linkTitle := ((XMLHTMLParser parse: webLink retrieveContents) xpath: '/html/head/title')
firstElement contentString.
response nextPutAll: '# [[', linkTitle, '|', webLink asString, ']]'; cr
]
].
self text: response contents
]
{ #category : #accessing }
Tiddler >> revision [
^ revision