nothumanallowed 13.2.51 → 13.2.53
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/constants.mjs +1 -1
- package/src/services/web-ui.mjs +26 -12
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nothumanallowed",
|
|
3
|
-
"version": "13.2.
|
|
3
|
+
"version": "13.2.53",
|
|
4
4
|
"description": "NotHumanAllowed — 38 AI agents, 80 tools, Studio (visual agentic workflows). Email, calendar, browser automation, screen capture, canvas, cron/heartbeat, Alexandria E2E messaging, GitHub, Notion, Slack, voice chat, free AI (Liara), 28 languages. Zero-dependency CLI.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
package/src/constants.mjs
CHANGED
|
@@ -5,7 +5,7 @@ import { fileURLToPath } from 'url';
|
|
|
5
5
|
const __filename = fileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = path.dirname(__filename);
|
|
7
7
|
|
|
8
|
-
export const VERSION = '13.2.
|
|
8
|
+
export const VERSION = '13.2.53';
|
|
9
9
|
export const BASE_URL = 'https://nothumanallowed.com/cli';
|
|
10
10
|
export const API_BASE = 'https://nothumanallowed.com/api/v1';
|
|
11
11
|
|
package/src/services/web-ui.mjs
CHANGED
|
@@ -3123,20 +3123,34 @@ function downloadStudioPDF() {
|
|
|
3123
3123
|
var nodes = studioState.nodes || [];
|
|
3124
3124
|
|
|
3125
3125
|
// Build sections for each agent
|
|
3126
|
+
function mdToPdfHtml(raw) {
|
|
3127
|
+
var lines = raw.split(String.fromCharCode(10));
|
|
3128
|
+
var out = '';
|
|
3129
|
+
var inList = false;
|
|
3130
|
+
for (var li = 0; li < lines.length; li++) {
|
|
3131
|
+
var line = lines[li]
|
|
3132
|
+
.replace(/&/g,'&').replace(/</g,'<').replace(/>/g,'>');
|
|
3133
|
+
// Inline bold: **text**
|
|
3134
|
+
line = line.replace(new RegExp('[*][*]([^*]+)[*][*]','g'),'<strong>$1</strong>');
|
|
3135
|
+
// Inline italic: *text*
|
|
3136
|
+
line = line.replace(new RegExp('[*]([^*]+)[*]','g'),'<em>$1</em>');
|
|
3137
|
+
if (line.slice(0,4) === '### ') { if(inList){out+='</ul>';inList=false;} out += '<h3>' + line.slice(4) + '</h3>'; continue; }
|
|
3138
|
+
if (line.slice(0,3) === '## ') { if(inList){out+='</ul>';inList=false;} out += '<h2>' + line.slice(3) + '</h2>'; continue; }
|
|
3139
|
+
if (line.slice(0,2) === '# ') { if(inList){out+='</ul>';inList=false;} out += '<h2>' + line.slice(2) + '</h2>'; continue; }
|
|
3140
|
+
if (line.slice(0,2) === '- ' || line.slice(0,2) === '* ') {
|
|
3141
|
+
if (!inList) { out += '<ul>'; inList = true; }
|
|
3142
|
+
out += '<li>' + line.slice(2) + '</li>';
|
|
3143
|
+
continue;
|
|
3144
|
+
}
|
|
3145
|
+
if (inList) { out += '</ul>'; inList = false; }
|
|
3146
|
+
if (line.trim() === '') { out += '</p><p>'; } else { out += line + '<br>'; }
|
|
3147
|
+
}
|
|
3148
|
+
if (inList) out += '</ul>';
|
|
3149
|
+
return '<p>' + out + '</p>';
|
|
3150
|
+
}
|
|
3126
3151
|
var sectionsHtml = nodes.map(function(n) {
|
|
3127
3152
|
if (!n.output || n.output === '(no output)' || n.agent === 'CanvasAgent') return '';
|
|
3128
|
-
|
|
3129
|
-
.replace(/&/g,'&').replace(/</g,'<').replace(/>/g,'>')
|
|
3130
|
-
.replace(/\*\*(.*?)\*\*/g,'<strong>$1</strong>')
|
|
3131
|
-
.replace(/\*(.*?)\*/g,'<em>$1</em>')
|
|
3132
|
-
.replace(new RegExp('^#{3}[ \\t]+(.+)$','gm'),'<h3>$1</h3>')
|
|
3133
|
-
.replace(new RegExp('^#{2}[ \\t]+(.+)$','gm'),'<h2>$1</h2>')
|
|
3134
|
-
.replace(new RegExp('^#{1}[ \\t]+(.+)$','gm'),'<h2>$1</h2>')
|
|
3135
|
-
.replace(new RegExp('^-[ \\t]+(.+)$','gm'),'<li>$1</li>')
|
|
3136
|
-
.replace(/(<li>[\s\S]*?<\/li>)/g,'<ul>$1</ul>')
|
|
3137
|
-
.replace(/\n{2,}/g,'</p><p>')
|
|
3138
|
-
.replace(/\n/g,'<br>');
|
|
3139
|
-
return '<div class="section"><div class="agent-label">' + (n.icon||'') + ' ' + esc(n.label||n.agent) + '</div><div class="section-body"><p>' + mdHtml + '</p></div></div>';
|
|
3153
|
+
return '<div class="section"><div class="agent-label">' + (n.icon||'') + ' ' + esc(n.label||n.agent) + '</div><div class="section-body">' + mdToPdfHtml(n.output) + '</div></div>';
|
|
3140
3154
|
}).join('');
|
|
3141
3155
|
|
|
3142
3156
|
// Include canvas if present (as an embedded iframe screenshot fallback note)
|