added static libraries: clocklet (timepicker), flatpickr and litepicker (data pickers)

master
Tomasz Sowa 1 year ago
parent c3122fb82f
commit 9b8e48e7b2

@ -11,6 +11,12 @@
[def? winix_load_uikit true]
[def? winix_load_htmx true]
[def? winix_load_clocklet false]
[def? winix_clocklet_uikit_theme true]
[def? winix_load_flatpickr false]
[def? winix_load_litepicker false]
[if winix_set_charset]
@ -307,6 +313,72 @@ cm.save()
[end]
[if winix_load_clocklet]
[# https://github.com/luncheon/clocklet ]
[# https://luncheon.github.io/clocklet/demo.html - color samples here too]
<link rel="stylesheet" href="[doc_base_url_common]/clocklet/0.3.0/clocklet.min.css">
<script src="[doc_base_url_common]/clocklet/0.3.0/clocklet.js"></script>
[if winix_clocklet_uikit_theme]
<link rel="stylesheet" href="[doc_base_url_common]/clocklet/0.3.0/uikit-theme.css">
[end]
[end]
[if winix_load_flatpickr]
[# date picker, time picker, date and time picker, date range picker (selecting time works only for the first day), available different themes ]
[# the datepicker on mobile devices is a native datepicker (this functionality can be disabled via disableMobile option) ]
[# https://flatpickr.js.org ]
[# https://github.com/flatpickr/flatpickr ]
[# options: https://flatpickr.js.org/options/ ]
<link rel="stylesheet" href="[doc_base_url_common]/flatpickr/4.6.9/flatpickr.min.css">
<script src="[doc_base_url_common]/flatpickr/4.6.9/flatpickr.js"></script>
[if is_not [lang "flatpickr_locale_url"] "none"]
<script src="[doc_base_url_common]/flatpickr/4.6.9/l10n/[lang "flatpickr_locale_url"]"></script>
<script>
flatpickr.localize(flatpickr.l10ns.{flatpickr_locale_config_prefix});
</script>
[end]
[if false]
[# can be inserted in this way: ]
<script>
flatpickr("#my-input-id", \{
\});
</script>
[end]
[end]
[if winix_load_litepicker]
[# date picker and date range picker ]
[# can show a dialog with more than one month, config parameters: numberOfColumns and numberOfMonths]
[# https://litepicker.com ]
[# https://github.com/wakirin/litepicker/ ]
[# options: https://litepicker.com/docs/options ]
[# in bundle.js there are all plugins, you can use litepicker.js to load the datepicker without plugins]
<script src="[doc_base_url_common]/litepicker/2.0.11/bundle.js"></script>
[if false]
[# can be inserted in this way: ]
<script>
const picker = new Litepicker(\{
element: document.getElementById('my-input-id'),
plugins: \['mobilefriendly'\],
lang: "{winix_html_lang_attr}"
\});
</script>
[end]
[end]
[if false]
[# temporarily blocked]
[if winix_has_plugin "stats"]

@ -667,6 +667,6 @@ seo_description = Description
seo_keywords = Keywords
flatpickr_locale_url = "none"
flatpickr_locale_config_prefix = ""

@ -684,5 +684,6 @@ seo_keywords = "Słowa kluczowe (tag meta keywords)"
flatpickr_locale_url = "pl.js"
flatpickr_locale_config_prefix = "pl"

Loading…
Cancel
Save