Bump tp version 0.1.0 and cleanup
Signed-off-by: Justin Georgi <justin.georgi@gmail.com>
This commit is contained in:
@@ -134,26 +134,6 @@ class GlModelHandler extends ImageHandler {
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This is used to generate an array element for each metadata value. That array is then used to generate the table of metadata values on the image page.
|
||||
*
|
||||
* @param array &$array An array containing elements for each type of visibility and each of those elements being an array of metadata items. This function adds a value to that array.
|
||||
* @param string $visibility ('visible' or 'collapsed') if this value is hidden by default.
|
||||
* @param string $type Type of metadata tag (currently always 'exif')
|
||||
* @param string $id The name of the metadata tag (like 'artist' for example). its name in the table displayed is the message "$type-$id" (Ex exif-artist ).
|
||||
* @param string $value Thingy goes into a wikitext table; it used to be escaped but that was incompatible with previous practise of customized display with wikitext formatting via messages such as 'exif-model-value'. So the escaping is taken back out, but generally this seems a confusing interface.
|
||||
* @param bool | string $param Value to pass to the message for the name of the field as $1. Currently this parameter doesn't seem to ever be used.
|
||||
*/
|
||||
//public static function addMeta (&$array, $visibility, $type, $id, $value, $param = false ) {
|
||||
// $array[$visibility][] = [
|
||||
// 'id' => "$type-$id",
|
||||
// 'name' => $name,
|
||||
// 'value' => $value
|
||||
// ];
|
||||
//}
|
||||
|
||||
|
||||
/**
|
||||
* Get image size information and metadata array.
|
||||
*
|
||||
|
||||
@@ -42,13 +42,6 @@ class GlModelHooks {
|
||||
* @param OutputPage $out compiled page html and manipulation methods
|
||||
*/
|
||||
public static function onBeforePageDisplay($out) {
|
||||
$file = MediaWikiServices::getInstance()->getRepoGroup()->findFile($out->getTitle());
|
||||
if ($file) {
|
||||
echo '<script>';
|
||||
self::console_log('Metadata:');
|
||||
self::console_log($file->getMetadata());
|
||||
echo '</script>';
|
||||
}
|
||||
preg_match('/(<model-viewer src="\S*?\.(glb|gltf"))/',$out->getHTML(),$findGltf);
|
||||
if ($findGltf[0]) {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user