MCPcopy Index your code
hub / github.com/zxlie/FeHelper / getOrCreateImgPreview

Function getOrCreateImgPreview

apps/json-format/format-lib.js:1926–1932  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1924
1925 // 工具函数:获取或创建唯一图片预览浮窗节点
1926 function getOrCreateImgPreview() {
1927 let $img = $('#fh-img-preview');
1928 if (!$img.length) {
1929 $img = $('<div id="fh-img-preview" style="position:absolute;z-index:999999;border:1px solid #ccc;background:#fff;padding:4px;box-shadow:0 2px 8px #0002;pointer-events:none;"><img style="max-width:300px;max-height:200px;display:block;"></div>').appendTo('body');
1930 }
1931 return $img;
1932 }
1933
1934 // 格式化JSON为HTML(同步版本)
1935 function formatJsonToHtml(json, skin) {

Callers 1

_addEventsFunction · 0.85

Calls 1

$Function · 0.50

Tested by

no test coverage detected