Changeset View
Changeset View
Standalone View
Standalone View
src/applications/files/document/PhabricatorJupyterDocumentEngine.php
Show First 20 Lines • Show All 254 Lines • ▼ Show 20 Lines | switch ($output_type) { | ||||
foreach ($image_formats as $image_format) { | foreach ($image_formats as $image_format) { | ||||
if (!isset($data[$image_format])) { | if (!isset($data[$image_format])) { | ||||
continue; | continue; | ||||
} | } | ||||
$raw_data = $data[$image_format]; | $raw_data = $data[$image_format]; | ||||
if (!is_array($raw_data)) { | if (!is_array($raw_data)) { | ||||
continue; | $raw_data = array($raw_data); | ||||
} | } | ||||
$raw_data = implode('', $raw_data); | $raw_data = implode('', $raw_data); | ||||
$content = phutil_tag( | $content = phutil_tag( | ||||
'img', | 'img', | ||||
array( | array( | ||||
'src' => 'data:'.$image_format.';base64,'.$raw_data, | 'src' => 'data:'.$image_format.';base64,'.$raw_data, | ||||
)); | )); | ||||
Show All 40 Lines |