mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-11-02 00:22:59 +00:00
Get rid of the qualifyTiddlerTitles hack
Now, finally, we can implement qualifyTiddlerTitles as a macro.
This commit is contained in:
32
core/modules/macros/qualify.js
Normal file
32
core/modules/macros/qualify.js
Normal file
@@ -0,0 +1,32 @@
|
||||
/*\
|
||||
title: $:/core/modules/macros/qualify.js
|
||||
type: application/javascript
|
||||
module-type: macro
|
||||
|
||||
Macro to qualify a state tiddler title according
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
|
||||
/*jslint node: true, browser: true */
|
||||
/*global $tw: false */
|
||||
"use strict";
|
||||
|
||||
/*
|
||||
Information about this macro
|
||||
*/
|
||||
|
||||
exports.name = "qualify";
|
||||
|
||||
exports.params = [
|
||||
{name: "title"}
|
||||
];
|
||||
|
||||
/*
|
||||
Run the macro
|
||||
*/
|
||||
exports.run = function(title) {
|
||||
return title + "-" + this.getStateQualifier();
|
||||
};
|
||||
|
||||
})();
|
||||
Reference in New Issue
Block a user