(Grav GitSync) Automatic Commit from dan
This commit is contained in:
parent
9773afcd97
commit
1ea4178c1a
7 changed files with 75 additions and 11 deletions
|
@ -0,0 +1,36 @@
|
||||||
|
---
|
||||||
|
title: 'Unser Tutorial/Leitfaden für den Android-Bereich ist fertig 🍻'
|
||||||
|
published: true
|
||||||
|
date: '09-03-2022 08:14'
|
||||||
|
taxonomy:
|
||||||
|
category:
|
||||||
|
- news
|
||||||
|
tag:
|
||||||
|
- tutorials
|
||||||
|
- privacy
|
||||||
|
- android
|
||||||
|
- magisk
|
||||||
|
- fdroid
|
||||||
|
- afwall
|
||||||
|
- xprivacylua
|
||||||
|
- lsposed
|
||||||
|
- microg
|
||||||
|
- shelter
|
||||||
|
- aurora
|
||||||
|
- lineage
|
||||||
|
- phone
|
||||||
|
- backup
|
||||||
|
- seedvault
|
||||||
|
aura:
|
||||||
|
author: dodi
|
||||||
|
---
|
||||||
|
|
||||||
|
Bist du daran interessiert, dein altes Android-Telefon über ein Custom ROM zu aktualisieren? Verwendest du ein Android-Gerät für deine digitale Privatsphäre?
|
||||||
|
|
||||||
|
Wir haben jetzt auch unser Tutorial/Leitfaden (deutsch) für unseren Android-Bereich fertiggestellt.
|
||||||
|
F-Droid, Magisk, AFWall, LSPosed, microG ... sie alle sind Teil davon.
|
||||||
|
|
||||||
|
Wirf einen Blick darauf:
|
||||||
|
https://wiki.techsaviours.org/de/phone/operating_systems/android
|
||||||
|
|
||||||
|
Wir haben ein paar Backup-Lösungen für unsere Android-Handys hinzugefügt - https://wiki.techsaviours.org/de/backup/phone.
|
|
@ -1,3 +1,10 @@
|
||||||
|
# v3.2.0
|
||||||
|
## 02/23/2022
|
||||||
|
|
||||||
|
1. [](#new)
|
||||||
|
* Support for HTML or Shortcode based headers with custom `id` attributes to specify an anchor
|
||||||
|
* Added German translation
|
||||||
|
|
||||||
# v3.1.3
|
# v3.1.3
|
||||||
## 01/03/2022
|
## 01/03/2022
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
name: Page Toc
|
name: Page Toc
|
||||||
type: plugin
|
type: plugin
|
||||||
slug: page-toc
|
slug: page-toc
|
||||||
version: 3.1.3
|
version: 3.2.0
|
||||||
description: Generate a table of contents and anchors from a page
|
description: Generate a table of contents and anchors from a page
|
||||||
icon: list
|
icon: list
|
||||||
author:
|
author:
|
||||||
|
|
|
@ -49,9 +49,10 @@ class MarkupFixer
|
||||||
/** @var DOMElement $node */
|
/** @var DOMElement $node */
|
||||||
foreach ($this->traverseHeaderTags($domDocument, $start, $depth) as $node) {
|
foreach ($this->traverseHeaderTags($domDocument, $start, $depth) as $node) {
|
||||||
if ($node->getAttribute('id')) {
|
if ($node->getAttribute('id')) {
|
||||||
continue;
|
$slug = $node->getAttribute('id');
|
||||||
}
|
} else {
|
||||||
$slug = $slugger->slugify($node->getAttribute('title') ?: $node->textContent, $options);
|
$slug = $slugger->slugify($node->getAttribute('title') ?: $node->textContent, $options);
|
||||||
|
}
|
||||||
|
|
||||||
$node->setAttribute('id', $slug);
|
$node->setAttribute('id', $slug);
|
||||||
|
|
||||||
|
|
|
@ -10,10 +10,12 @@ class AnchorShortcode extends Shortcode
|
||||||
{
|
{
|
||||||
public function init()
|
public function init()
|
||||||
{
|
{
|
||||||
$this->shortcode->getHandlers()->add('anchor', function(ProcessedShortcode $sc) {
|
$this->shortcode->getRawHandlers()->add('anchor', function(ProcessedShortcode $sc) {
|
||||||
$id = $sc->getParameter('id', $sc->getBbCode());
|
|
||||||
$prefix = $sc->getParameter('prefix', PageTOCPlugin::configVar('anchors.slug_prefix'));
|
$id = $this->cleanParam($sc->getParameter('id', $sc->getBbCode()));
|
||||||
$class = $sc->getParameter('class', 'inline-anchor');
|
$tag = $this->cleanParam($sc->getParameter('tag'));
|
||||||
|
$prefix = $this->cleanParam($sc->getParameter('prefix', PageTOCPlugin::configVar('anchors.slug_prefix')));
|
||||||
|
$class = $this->cleanParam($sc->getParameter('class', 'inline-anchor'));
|
||||||
$aria = PageTOCPlugin::configVar('anchors.aria');
|
$aria = PageTOCPlugin::configVar('anchors.aria');
|
||||||
$content = $sc->getContent();
|
$content = $sc->getContent();
|
||||||
|
|
||||||
|
@ -27,8 +29,23 @@ class AnchorShortcode extends Shortcode
|
||||||
$id = $prefix . $id;
|
$id = $prefix . $id;
|
||||||
}
|
}
|
||||||
|
|
||||||
return "<a id=\"$id\" href=\"#$id\" class=\"$class\" aria-label=\"$aria\">$content</a>";
|
if ($tag) {
|
||||||
|
$output = "<$tag id=\"$id\" class=\"$class\">$content</$tag>";
|
||||||
|
} else {
|
||||||
|
$output = "<a id=\"$id\" href=\"#$id\" class=\"$class\" aria-label=\"$aria\">$content</a>";
|
||||||
|
}
|
||||||
|
|
||||||
|
return $output;
|
||||||
});
|
});
|
||||||
$this->shortcode->getHandlers()->addAlias('#', 'anchor');
|
$this->shortcode->getRawHandlers()->addAlias('#', 'anchor');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param $param
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
protected function cleanParam($param)
|
||||||
|
{
|
||||||
|
return trim(html_entity_decode($param), '"');
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,3 +1,6 @@
|
||||||
|
de:
|
||||||
|
PLUGIN_PAGE_TOC:
|
||||||
|
TABLE_OF_CONTENTS: Inhaltsverzeichnis
|
||||||
en:
|
en:
|
||||||
PLUGIN_PAGE_TOC:
|
PLUGIN_PAGE_TOC:
|
||||||
TABLE_OF_CONTENTS: Table of Contents
|
TABLE_OF_CONTENTS: Table of Contents
|
||||||
|
|
|
@ -72,7 +72,7 @@ class PageTOCPlugin extends Plugin
|
||||||
'onTwigInitialized' => ['onTwigInitialized', 0],
|
'onTwigInitialized' => ['onTwigInitialized', 0],
|
||||||
'onTwigTemplatePaths' => ['onTwigTemplatePaths', 0],
|
'onTwigTemplatePaths' => ['onTwigTemplatePaths', 0],
|
||||||
'onTwigSiteVariables' => ['onTwigSiteVariables', 0],
|
'onTwigSiteVariables' => ['onTwigSiteVariables', 0],
|
||||||
'onPageContentProcessed' => ['onPageContentProcessed', 0],
|
'onPageContentProcessed' => ['onPageContentProcessed', -20],
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -86,7 +86,7 @@ class PageTOCPlugin extends Plugin
|
||||||
/** @var PageInterface $page */
|
/** @var PageInterface $page */
|
||||||
$page = $event['page'];
|
$page = $event['page'];
|
||||||
|
|
||||||
$content = $page->getRawContent();
|
$content = $page->content();
|
||||||
$shortcode_exists = preg_match($this->toc_regex, $content);
|
$shortcode_exists = preg_match($this->toc_regex, $content);
|
||||||
$active = $this->configVar('active', $page, false);
|
$active = $this->configVar('active', $page, false);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue