first commit

This commit is contained in:
2025-06-17 11:53:18 +02:00
commit 9f0f7ba12b
8804 changed files with 1369176 additions and 0 deletions

View File

@ -0,0 +1,58 @@
table.phpdebugbar-widgets-languageStrings {
width: 100%;
margin-top: 5px;
margin-left: 5px;
font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, Courier, monospace;
line-height: 1.3em;
}
table.phpdebugbar-widgets-languageStrings th {
border-bottom: 1px solid #000;
}
table.phpdebugbar-widgets-languageStrings table.phpdebugbar-widgets-callstack {
display: none;
width: 100%;
margin: 10px;
font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, Courier, monospace;
border-collapse: collapse;
border: 1px solid #ddd;
}
table.phpdebugbar-widgets-languageStrings table.phpdebugbar-widgets-callstack tr.caller {
background-color: #fff9b6;
}
table.phpdebugbar-widgets-languageStrings table.phpdebugbar-widgets-callstack tbody tr:hover {
background-color: #eee;
}
table.phpdebugbar-widgets-languageStrings table.phpdebugbar-widgets-callstack th {
font-weight: bold;
}
table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye,
table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye-dash {
margin-left: 8px;
color: #888;
}
table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye-dash {
color: #000;
background-color: #eee;
}
table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye:before,
table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye-dash:before {
margin-right: 4px;
font-family: "Font Awesome 6 Free";
/*font-size: 12px;*/
}
table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye:before {
content: "\f06e";
}
table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye-dash:before {
content: "\f070";
}

View File

@ -0,0 +1,87 @@
(function ($) {
var csscls = PhpDebugBar.utils.makecsscls('phpdebugbar-widgets-')
var languageStringsWidget = PhpDebugBar.Widgets.languageStringsWidget = PhpDebugBar.Widget.extend({
tagName: 'table',
className: csscls('languageStrings'),
render: function () {
this.bindAttr('data', function (data) {
this.$el.empty()
for (var orphan in data.orphans) {
var tr = $('<tr />')
$('<th valign="top" style="width:10%" />').text(orphan).appendTo(tr)
var td = $('<th />').appendTo(tr)
var ul = $('<ul />').appendTo(td)
var tableStack
for (var oc in data.orphans[orphan]) {
var occurence = data.orphans[orphan][oc]
var relPath = occurence['caller'].replace(data.jroot, '')
var li = $('<li />')
if (data.xdebugLink) {
var parts = occurence['caller'].split(':')
var link = $('<a />')
.text(relPath)
.attr(
'href',
data.xdebugLink
.replace('%f', parts[0])
.replace('%l', parts[1])
)
li.append(link)
} else {
li.text(relPath)
}
if (occurence['trace'] && !$.isEmptyObject(occurence['trace'])) {
$('<span title="Call Stack" />')
.text('Stack')
.addClass(csscls('eye'))
.css('cursor', 'pointer')
.on('click', function (e) {
var btn = $(e.target)
var table = btn.next()
if (table.is(':visible')) {
table.hide()
btn.addClass(csscls('eye'))
btn.removeClass(csscls('eye-dash'))
} else {
table.show()
btn.addClass(csscls('eye-dash'))
btn.removeClass(csscls('eye'))
}
})
.appendTo(li)
tableStack = $('<table><thead><tr><th colspan="3">Call Stack</th></tr></thead></table>')
.addClass(csscls('callstack'))
.appendTo(li)
for (var i in occurence['trace']) {
var entry = occurence['trace'][i]
var location = entry[3] ? entry[3].replace(data.jroot, '') + ':' + entry[4] : ''
var caller = entry[2].replace(data.jroot, '')
var cssClass = entry[1] ? 'caller' : ''
if (location && data.xdebugLink) {
location = '<a href="' + data.xdebugLink.replace('%f', entry[3]).replace('%l', entry[4]) + '">' + location + '</a>'
}
tableStack.append('<tr class="' + cssClass + '"><th>' + entry[0] + '</th><td>' + caller + '</td><td>' + location + '</td></tr>')
}
}
li.appendTo(ul)
}
this.$el.append(tr)
}
})
}
})
})(PhpDebugBar.$)

View File

@ -0,0 +1 @@
table.phpdebugbar-widgets-languageStrings{font-family:SFMono-Regular,Consolas,Liberation Mono,Menlo,Courier,monospace;line-height:1.3em;margin-left:5px;margin-top:5px;width:100%}table.phpdebugbar-widgets-languageStrings th{border-bottom:1px solid #000}table.phpdebugbar-widgets-languageStrings table.phpdebugbar-widgets-callstack{border:1px solid #ddd;border-collapse:collapse;display:none;font-family:SFMono-Regular,Consolas,Liberation Mono,Menlo,Courier,monospace;margin:10px;width:100%}table.phpdebugbar-widgets-languageStrings table.phpdebugbar-widgets-callstack tr.caller{background-color:#fff9b6}table.phpdebugbar-widgets-languageStrings table.phpdebugbar-widgets-callstack tbody tr:hover{background-color:#eee}table.phpdebugbar-widgets-languageStrings table.phpdebugbar-widgets-callstack th{font-weight:700}table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye,table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye-dash{color:#888;margin-left:8px}table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye-dash{background-color:#eee;color:#000}table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye-dash:before,table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye:before{font-family:Font Awesome\ 6 Free;margin-right:4px}table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye:before{content:"\f06e"}table.phpdebugbar-widgets-languageStrings span.phpdebugbar-widgets-eye-dash:before{content:"\f070"}

View File

@ -0,0 +1 @@
!function(e){var a=PhpDebugBar.utils.makecsscls("phpdebugbar-widgets-");PhpDebugBar.Widgets.languageStringsWidget=PhpDebugBar.Widget.extend({tagName:"table",className:a("languageStrings"),render:function(){this.bindAttr("data",(function(t){for(var r in this.$el.empty(),t.orphans){var l=e("<tr />");e('<th valign="top" style="width:10%" />').text(r).appendTo(l);var s,p=e("<th />").appendTo(l),d=e("<ul />").appendTo(p);for(var n in t.orphans[r]){var i=t.orphans[r][n],c=i.caller.replace(t.jroot,""),o=e("<li />");if(t.xdebugLink){var h=i.caller.split(":"),g=e("<a />").text(c).attr("href",t.xdebugLink.replace("%f",h[0]).replace("%l",h[1]));o.append(g)}else o.text(c);if(i.trace&&!e.isEmptyObject(i.trace))for(var u in e('<span title="Call Stack" />').text("Stack").addClass(a("eye")).css("cursor","pointer").on("click",(function(t){var r=e(t.target),l=r.next();l.is(":visible")?(l.hide(),r.addClass(a("eye")),r.removeClass(a("eye-dash"))):(l.show(),r.addClass(a("eye-dash")),r.removeClass(a("eye")))})).appendTo(o),s=e('<table><thead><tr><th colspan="3">Call Stack</th></tr></thead></table>').addClass(a("callstack")).appendTo(o),i.trace){var b=i.trace[u],v=b[3]?b[3].replace(t.jroot,"")+":"+b[4]:"",f=b[2].replace(t.jroot,""),k=b[1]?"caller":"";v&&t.xdebugLink&&(v='<a href="'+t.xdebugLink.replace("%f",b[3]).replace("%l",b[4])+'">'+v+"</a>"),s.append('<tr class="'+k+'"><th>'+b[0]+"</th><td>"+f+"</td><td>"+v+"</td></tr>")}o.appendTo(d)}this.$el.append(l)}}))}})}(PhpDebugBar.$);