* Add class assignment to DOM node in editor
* Fix indentation in assignDomNodeClasses method
* Fix conditional check for changedAttributes class
* Improve class assignment in EditTextWidget
Refactor class assignment logic to avoid duplicates and handle whitespace.
* Refactor DOM class assignment in EditTextWidget
* Refactor updateDomNodeClasses for clarity and efficiency
* Add changenote for enhancement in editor refresh behavior
* make sort order more consistent
* Fix tests, as they are to be different due to the change.
* Add ChangeNote
* sortby: add "end" operand to place unlisted last
Give the sortby filter operator an optional second operand `end` that
places input titles missing from the reference list after the listed
ones, while the default still keeps them at the start.
* x-listops: read a second operand; `end` sorts unlisted titles to the
end of the list, the default (no operand) leaves them at the start
* Document the optional `place` parameter on the sortby operator and
rename the operator and examples tiddlers to match their titles
* Add a `sortby[...],[end]` example to the operator examples
* Replace the 5.5.0 change note with one describing the new `end`
operand and its unchanged default
* Extend the sortby tests to cover both default (unlisted first) and
`end` (unlisted last) placement
* Make the sortby end flag a suffix
Specify the placement of unlisted titles with an operator suffix.
Eg: `sortby:end[a b c]`
* Read the flag from `operator.suffix`
* Move the example and the change note to the suffix syntax
* Switch the sortby tests to the suffix syntax
* Cover the sortby guard and unlisted ordering
Close gaps found by mutating the sortby operator
* Sort two titles to catch an off-by-one in the length guard
* Keep unlisted titles in input order under the `end` suffix to catch a
comparator tie break
* Return a single title untouched, exercising the early return
* Touch a temp tiddler when removing a tag
Like that removing a tag doesn't make TiddlyWiki5 wait for the Typing timeout to remove it but removes it instantly, because also a non-draft Tiddler has changed
* Add release notes for bugfix in Edit Mode tags
Fixes an issue where tags of Tiddlers in Edit Mode don't animate instantly when they get removed.
* Add inline comment
* Update release version to 5.5.0 in changenote
* Fix $tw.utils.pulseElement() by replacing missing $tw.browser.animationEnd
Use $tw.utils.convertEventName("animationEnd") and add pulse CSS animation
Fixes#6835
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* Add ChangeNote
* add tc- prefix to pulse class
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* Keep retained tiddler subdirectories on save
Make generateTiddlerFilepath keep a retained tiddler's recorded subdirectory
and produce a valid filename for every path segment.
* Normalise originalpath separators to "/" before the sanitiser, so recorded
subdirectories survive
* Validate each path segment (reserved names, trailing dots or spaces), so
"sub/CON" is valid on every OS
* Run that pass after transliteration, which can itself create a reserved name
* Add filesystem and adversarial specs, covering generateTiddlerFileInfo and
generateTiddlerExtension
* update changenote
Make the button widget apply selectedClass correctly when the state is
addressed with setTitle instead of set.
Issue #9949, the button could not be rendered at all
* Guard the setField read in isSelected(), which dereferenced the result of
getTiddler() directly. A missing state tiddler threw a TypeError, and that
tiddler is normally only created by the first click
Issue #9950, every button of a set reported itself as selected
* Rewrite isSelected() as an if/else. The nested ternary mixed `||` with
`?:`, so the setTitle branch returned a fallback value instead of a
comparison
* Watch the setTitle state tiddler in refresh(), so the selected class
follows the state as it already does for set
Documentation and tests
* Document that setField takes preference over setIndex. That has always
been the behaviour, it was never written down
* Document that selectedClass and default apply to setTitle as well as to set
* Add wiki based test cases for the set, setTitle, setField and setIndex
selection paths. Six of the seven fail against v5.4.1, the one that passes
uses set, which was never broken
Fixes#9949Fixes#9950
* feat: enhance makepatches function to support multiple suffixes and JSON output format
* feat: add release notes for makepatches JSON output enhancement
* doc: update makepatches operator documentation to document new json output
* doc: add JSON output examples to makepatches and applypatches documentation
* chore: convert space indentations to tabs
* test: add tests for makepatches operator with JSON output support
* chore: change space to tab indentation
* test: add DiffMergePatch4 integration test for testing makepatches json output
* fix: remove superfluous heading character
* refactor the parsing of the makepatches suffixes
Co-authored-by: Saq Imtiaz <saq.imtiaz@gmail.com>
* refactor: improve makepatches function for better readability and performance
* chore: apply style guide by collapsing consecutive variable assignments
* chore: remove extraneous tabs
---------
Co-authored-by: Saq Imtiaz <saq.imtiaz@gmail.com>
* New test for all "forbidden" directory characters
* Fix for 9814 Pragma: \define creates dir problem
* improve handling of tiddlers in root/community directory
* Add ChangeNote
* Apply suggestion from @saqimtiaz
* Apply suggestion from @saqimtiaz
---------
Co-authored-by: Saq Imtiaz <saq.imtiaz@gmail.com>
* Fix regex for code block end detection in wikiparser
* Anchor the codeblock end fence to its own line
Close an empty code block without consuming the tiddler, while a fence
only counts when it stands alone on its line.
* Match the end fence with (^|\r?\n) so the empty block case closes at
the line start and a code line ending in ``` stays inside the block
* Add test-codeblock-parser.js covering empty blocks with language and
CRLF, delimiter newline handling, mid-line fences and a missing fence
* Move background action log inside platforms check
* Add change note for #9891
* Shorten change note
* Release notes: move #9891 from 5.4.1 to 5.5.0
PR #9891 is still open, so the background-action log change is planned for 5.5.0 instead of 5.4.1.
* Fix change-category for #9891 release note
is not a valid category; use instead.
* Update docs: running a custom Node.js TiddlyWiki version with npx
* Update docs: document different options of running multiple TW versions
---------
Co-authored-by: shadow <shadow@darkstar.localdomain>
Co-authored-by: me <me@localhost>
* Fix the CSV parser blanking a table
getCellInfo read the loop variable i before its declaration, so hoisting made
it undefined and charAt(undefined) read the first character of the whole text.
Any CSV opening with a separator therefore returned every cell empty.
- Test the cell against the start of the cell rather than the hoisted i
- Keep a separator inside a quoted cell literal
- Cover the parser with tests
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Add a change note for the CSV fix
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Skip system tiddlers in back-indexer updates
Fix#9916: editing a system tiddler that links or transcludes another
tiddler made it a backlinks[]/backtranscludes[] source until the next
index rebuild (shipped since v5.3.4).
* Guard BackSubIndexer.update() with isSystemTiddler() on both sides,
matching the initial scan; this also skips parsing $:/StoryList on
every navigation
* Add test-back-indexer.js: regression guards plus adversarial probes
for shadow reveals and hostile __proto__ titles
* Add ChangeNote
* Fakedom: uppercase tagName for HTML elements per DOM spec
Browsers uppercase tagName for HTML elements. Other namespaces (SVG,
MathML, XML) preserve case. Fakedom now matches, so widget code can use
the natural `node.tagName === "OPTGROUP"` form in both environments.
https://dom.spec.whatwg.org/#dom-element-tagname
* Tests: cover fakedom tagName spec compliance
Three specs pin the DOM contract for tagName: uppercase for HTML
elements, case preservation for other namespaces, and non-mutating
reads. Includes the OPTGROUP predicate the select widget will rely on
once it can drop its defensive .toUpperCase() call.
https://dom.spec.whatwg.org/#dom-element-tagname
* Fakedom: empty or null namespace creates a no-namespace element
Per DOM spec, createElementNS("") and createElementNS(null) have to produce
elements with no namespace. Fakedom previously defaults both to HTML,
which made tagName incorrectly uppercase non-HTML elements.
createElement without arguments still defaults to HTML.
https://dom.spec.whatwg.org/#dom-document-createelementns
* Add ChangeNote
* Fix Node.js deprecated warning
* Add ChangeNote
* Change deprecation to bugfix for DEP0169 warning
Updated change type from 'deprecation' to 'bugfix' for the Node.js server's handling of the DEP0169 warning.
01d3cde96 refactored parseMacroParameterAsAttribute to use a
do/while(false) construct with break statements - this updates
parseAttribute with an analogous refactoring for consistency