Carousel: Difference between revisions

From Wikisphere
Jump to navigation Jump to search
No edit summary
Tag: 2017 source edit
No edit summary
Tag: 2017 source edit
 
(11 intermediate revisions by the same user not shown)
Line 1: Line 1:
VisualData provides a Carousel  [https://www.mediawiki.org/wiki/Extension:VisualData/Result_formats result format] based on [https://kenwheeler.github.io/slick/ Slick].
VisualData provides a Carousel  [https://www.mediawiki.org/wiki/Extension:VisualData/Result_formats result format] based on [https://kenwheeler.github.io/slick/ Slick].


The carousel is fueled with data retrieved from any page with associated data and all or almost all [https://github.com/kenwheeler/slick Slick options] are supported using the prefix "-slick".
The carousel is fueled with data retrieved from any page with associated data and all or almost all [https://github.com/kenwheeler/slick Slick options] are supported using the prefix "-slick".
 
 
The easiest way to use it is to create a schema with an array of items, each of them with the properties "file"<ref>note that in the related schema the file property has been associated to a Title input widget, with a "namespace" attribute set to 6 (the FILE namespace)</ref>, "title", "caption" and "link" (only the file property is required, and the properties can be mapped to those names in the parser function itself), to save a list of files and attributes in any page, and then to use a parser function as follows:
The easiest way to use it is to create a schema with an array of items, each of them with the properties "file"<ref>note that in the related schema the file property has been associated to a Title input widget, with a "namespace" attribute set to 6 (the FILE namespace)</ref>, "title", "caption" and "link" (only the file property is required, and the properties can be mapped to those names in the parser function itself), to save a list of files and attributes in any page, and then to use a parser function as follows:


Line 10: Line 10:
|format=carousel
|format=carousel
|height=400px
|height=400px
|width=400px
|slick-adaptiveHeight=true
}}
}}
</pre>
</pre>
Line 23: Line 21:
|format=carousel
|format=carousel
|height=400px
|height=400px
|width_=400px
|slick-rows=0
|slick-adaptiveHeight=true
|slick-dots=true
}}
}}



Latest revision as of 11:46, 20 January 2025

VisualData provides a Carousel result format based on Slick.

The carousel is fueled with data retrieved from any page with associated data and all or almost all Slick options are supported using the prefix "-slick".

The easiest way to use it is to create a schema with an array of items, each of them with the properties "file"[1], "title", "caption" and "link" (only the file property is required, and the properties can be mapped to those names in the parser function itself), to save a list of files and attributes in any page, and then to use a parser function as follows:

{{#visualdataprint: Carousel pictures
|schema=Carousel
|format=carousel
|height=400px
}}


The images in the Carousel has been uploaded into the wiki in a conventional way, and then associated to the page Carousel pictures (the form is editable clicking the tab button Edit data) using the schema VisualDataSchema:Carousel.


Automat
Edward Hopper
People in the sun
Edward Hopper
Sunlight on Brownstones
Edward Hopper
Room in New York
Edward Hopper

Instead than editing directly the page with the carousel data, they can be edited using a popup form as follows:

form is loading...
{{#visualdataform: Carousel
|title = Edit pictures
|action = edit
|edit-page = Carousel pictures
|return-page = Demo_VisualData/Carousel
|view = popup
|popup-size = medium
|css-class =
|pagename-formula =
|edit-freetext = true   
|edit-categories = false
|edit-content-model = false
|edit-target-slot = false
|target-slot = main
|default-categories = 
|default-content-model = wikitext
|preload=
|preload-data=
|layout-align = top
|popup-help = false 
|layout = tabs
|submit-button-text =
|validate-button-text =
|callback=
|overwrite-existing-article-on-create = false
}}



See also


support & questions: support at topway.it

Download the latest version!

  1. note that in the related schema the file property has been associated to a Title input widget, with a "namespace" attribute set to 6 (the FILE namespace)