MCPcopy Create free account
hub / github.com/su-kaka/gcli2api / highlightHttpLinks

Function highlightHttpLinks

front/common.js:2103–2109  ·  view source on GitHub ↗
(text)

Source from the content-addressed store, hash-verified

2101
2102// 高亮HTTP链接函数
2103function highlightHttpLinks(text) {
2104 // 匹配 http:// 或 https:// 开头的URL
2105 const urlRegex = /(https?:\/\/[^\s<>"]+)/gi;
2106 return text.replace(urlRegex, function(url) {
2107 return `<a href="${url}" target="_blank" style="color: #007bff; text-decoration: underline; word-break: break-all;" title="点击打开: ${url}">${url}</a>`;
2108 });
2109}
2110
2111async function batchVerifyProjectIds() {
2112 const selectedFiles = Array.from(AppState.creds.selectedFiles);

Callers 1

toggleErrorDetailsCommonFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected