Last active
September 21, 2023 11:56
-
-
Save tpluscode/a3c3772cc4f0088d0bfb6c53fb8ba467 to your computer and use it in GitHub Desktop.
Revisions
-
tpluscode revised this gist
Sep 21, 2023 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -5,7 +5,7 @@ # title is simple sh:path schema:title ; sh:group _:mainGroup ; sh:order 1 ; # properties are ordered within group ], [ # author concatenates first+last name using SHACL-AF sh:path ex:author ; -
tpluscode created this gist
Sep 21, 2023 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,16 @@ <book/a-macska-es-a-puding> a schema:Book ; schema:title "A Macska és a puding" ; schema:author [ schema:givenName "Biljana" ; schema:familyName "Nikolic" ] ; schema:associatedMedia [ schema:contentUrl <book/a-macska-es-a-puding.pdf> ; ] ; schema:image [ a schema:ImageObject ; schema:contentUrl <large-cover> ; schema:thumbnail [ a schema:ImageObject ; schema:contentUrl <small-cover> ; ] ; ] ; . This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,22 @@ <book-layout> #shadow-root <section id="left"> <slot name="image"></slot> </section> <section id="controls"> <slot name="controls"></slot> </section> <section id="main"> <slot></slot> </section> <!-- main group props go to default slot --> <span>A Macska és a puding</span> <span>Biljana Nikolic</span> <!-- image in slot --> <img src="small-cover" alt="?" slot="image" /> <!-- download button etc --> <a href="book/a-macska-es-a-puding.pdf" slot="controls" > </book-layout> This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,5 @@ <Page> a schema:WebPage ; schema:mainEntity <book/a-macska-es-a-puding> ; dash:shape <PageShape> ; . This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,34 @@ <PageShape> a sh:NodeShape ; dash:viewer ex:BookLayout ; sh:property [ # title is simple sh:path schema:title ; sh:group _:mainGroup ; sh:order 1 ; ], [ # author concatenates first+last name using SHACL-AF sh:path ex:author ; sh:values [ sparql:concat ( [ sh:path schema:givenName ] " " [ sh:path schema:familyName ] ) ; ] ; sh:group _:mainGroup ; sh:order 2 ; ], [ # image follows the schema:ImageObject to find the thumbnail sh:path (schema:image schema:thumbnail schema:contentUrl) ; dash:viewer dash:ImageViewer ; sh:group _:imageGroup ; ], [ sh:path ( schema:associatedMedia schema:contentUrl ) ; ] ; . _:imageGroup ex:slot "image" . _:buttonsGroup ex:slot "controls" . # main group does not have a slot, will use default