]> git.mxchange.org Git - friendica.git/commitdiff
Deactivated not working stuff
authorMichael <heluecht@pirati.ca>
Sun, 2 Apr 2023 19:53:58 +0000 (19:53 +0000)
committerMichael <heluecht@pirati.ca>
Sun, 2 Apr 2023 19:53:58 +0000 (19:53 +0000)
src/Content/Text/NPF.php

index f57ea15a87025fdfab798e2059e018808f7a1023..d60b3a8e79462bb56eb2a9ec3b179ff07fcaa067 100644 (file)
@@ -52,7 +52,6 @@ class NPF
                self::setHeadingSubStyles($doc);
 
                $element = $doc->getElementsByTagName('body')->item(0);
-//             echo $element->ownerDocument->saveHTML($element) . "\n";
 
                list($npf, $text, $formatting) = self::routeChildren($element, $uri_id, true, []);
 
@@ -186,6 +185,9 @@ class NPF
 
        static private function getLevelByCallstack($callstack): int
        {
+               // Deactivated, since Tumblr seems to have issues with the indent level
+               return 0;
+
                $level = 0;
                foreach ($callstack as $entry) {
                        if (in_array($entry, ['ol', 'ul', 'blockquote'])) {
@@ -489,12 +491,13 @@ class NPF
                        $block = [
                                'type' => 'text',
                                'text' => $element->textContent,
-                               'formatting' => [
-                                       'start' => 0,
-                                       'end'   => strlen($element->textContent),
-                                       'type'  => 'link',
-                                       'url'   => $attributes['href']
-                               ]
+                               // Deactivated, since Tumblr has got issues with the formatting
+                               //'formatting' => [
+                               //      'start' => 0,
+                               //      'end'   => strlen($element->textContent),
+                               //      'type'  => 'link',
+                               //      'url'   => $attributes['href']
+                               //]
                        ];
                }