3 SPDX-FileCopyrightText: 2023, 2024 Lady <https://www.ladys.computer/about/#lady>
4 SPDX-License-Identifier: MPL-2.0
7 ⁌ ⛩📰 书社 ∷ lib/metadata2destinations.xslt
9 © 2024 Lady [@ Lady’s Computer].
11 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
12 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
15 xmlns="http://www.w3.org/1999/XSL/Transform"
16 xmlns:dct="http://purl.org/dc/terms/"
17 xmlns:exslstr="http://exslt.org/strings"
18 xmlns:nie="http://www.semanticdesktop.org/ontologies/2007/01/19/nie#"
19 xmlns:nfo="http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#"
20 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
21 xmlns:书社="urn:fdc:ladys.computer:20231231:Shu1She4"
22 extension-element-prefixes="exslstr"
26 <for-each select="/rdf:RDF/nfo:LocalFileDataObject[starts-with(@rdf:about, 'about:shushe?source=')]">
28 <when test="nie:interpretedAs/nfo:PlainTextDocument and dct:hasFormat/*/nie:interpretedAs/*[@nie:mimeType='application/xml']">
29 <variable name="destination" select="document(dct:hasFormat/*[nie:interpretedAs/*[@nie:mimeType='application/xml']]/@nfo:fileUrl[1])/*/@书社:destination"/>
30 <value-of select="@rdf:about"/>
33 <when test="$destination">
34 <value-of select="$destination"/>
37 <value-of select="substring-after(@rdf:about, 'about:shushe?source=')"/>
43 <value-of select="@rdf:about"/>
45 <value-of select="substring-after(@rdf:about, 'about:shushe?source=')"/>
51 <output method="text" encoding="UTF-8"/>