first commit

This commit is contained in:
Kevin Adametz 2021-01-08 17:48:20 +01:00
commit 0baac018a2
1011 changed files with 145854 additions and 0 deletions

View file

@ -0,0 +1 @@
require('./bootstrap');

65
resources/assets/js/bootstrap.js vendored Normal file
View file

@ -0,0 +1,65 @@
// Auto update layout
if (window.layoutHelpers) {
window.layoutHelpers.setAutoUpdate(true);
}
$(function() {
// Initialize sidenav
$('#layout-sidenav').each(function() {
new SideNav(this, {
orientation: $(this).hasClass('sidenav-horizontal') ? 'horizontal' : 'vertical'
});
});
// Initialize sidenav togglers
$('body').on('click', '.layout-sidenav-toggle', function(e) {
e.preventDefault();
window.layoutHelpers.toggleCollapsed();
});
// Swap dropdown menus in RTL mode
if ($('html').attr('dir') === 'rtl') {
$('#layout-navbar .dropdown-menu').toggleClass('dropdown-menu-right');
}
});
/**
* We'll load the axios HTTP library which allows us to easily issue requests
* to our Laravel back-end. This library automatically handles sending the
* CSRF token as a header based on the value of the "XSRF" token cookie.
*/
// window.axios = require('axios');
//
// window.axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest';
/**
* Next we will register the CSRF Token as a common header with Axios so that
* all outgoing HTTP requests automatically have it attached. This is just
* a simple convenience so we don't have to attach every token manually.
*/
// let token = document.head.querySelector('meta[name="csrf-token"]');
//
// if (token) {
// window.axios.defaults.headers.common['X-CSRF-TOKEN'] = token.content;
// } else {
// console.error('CSRF token not found: https://laravel.com/docs/csrf#csrf-x-csrf-token');
// }
/**
* Echo exposes an expressive API for subscribing to channels and listening
* for events that are broadcast by Laravel. Echo and event broadcasting
* allows your team to easily build robust real-time web applications.
*/
// import Echo from 'laravel-echo'
// window.Pusher = require('pusher-js');
// window.Echo = new Echo({
// broadcaster: 'pusher',
// key: process.env.MIX_PUSHER_APP_KEY,
// cluster: process.env.MIX_PUSHER_APP_CLUSTER,
// encrypted: true
// });

View file

@ -0,0 +1,2 @@
// Bootstrap
// @import '~bootstrap/scss/bootstrap';

13
resources/assets/vendor/fonts/fontawesome.css vendored Executable file

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 446 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 637 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

1
resources/assets/vendor/fonts/ionicons.css vendored Executable file

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 261 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

536
resources/assets/vendor/fonts/linearicons.css vendored Executable file
View file

@ -0,0 +1,536 @@
@font-face {
font-family: 'Linearicons-Free';
src:url('linearicons/Linearicons-Free.eot?w118d');
src:url('linearicons/Linearicons-Free.eot?#iefixw118d') format('embedded-opentype'),
url('linearicons/Linearicons-Free.woff2?w118d') format('woff2'),
url('linearicons/Linearicons-Free.woff?w118d') format('woff'),
url('linearicons/Linearicons-Free.ttf?w118d') format('truetype'),
url('linearicons/Linearicons-Free.svg?w118d#Linearicons-Free') format('svg');
font-weight: normal;
font-style: normal;
}
.lnr {
font-family: 'Linearicons-Free';
speak: none;
font-style: normal;
font-weight: normal;
font-variant: normal;
text-transform: none;
line-height: 1;
/* Better Font Rendering =========== */
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
.lnr-home:before {
content: "\e800";
}
.lnr-apartment:before {
content: "\e801";
}
.lnr-pencil:before {
content: "\e802";
}
.lnr-magic-wand:before {
content: "\e803";
}
.lnr-drop:before {
content: "\e804";
}
.lnr-lighter:before {
content: "\e805";
}
.lnr-poop:before {
content: "\e806";
}
.lnr-sun:before {
content: "\e807";
}
.lnr-moon:before {
content: "\e808";
}
.lnr-cloud:before {
content: "\e809";
}
.lnr-cloud-upload:before {
content: "\e80a";
}
.lnr-cloud-download:before {
content: "\e80b";
}
.lnr-cloud-sync:before {
content: "\e80c";
}
.lnr-cloud-check:before {
content: "\e80d";
}
.lnr-database:before {
content: "\e80e";
}
.lnr-lock:before {
content: "\e80f";
}
.lnr-cog:before {
content: "\e810";
}
.lnr-trash:before {
content: "\e811";
}
.lnr-dice:before {
content: "\e812";
}
.lnr-heart:before {
content: "\e813";
}
.lnr-star:before {
content: "\e814";
}
.lnr-star-half:before {
content: "\e815";
}
.lnr-star-empty:before {
content: "\e816";
}
.lnr-flag:before {
content: "\e817";
}
.lnr-envelope:before {
content: "\e818";
}
.lnr-paperclip:before {
content: "\e819";
}
.lnr-inbox:before {
content: "\e81a";
}
.lnr-eye:before {
content: "\e81b";
}
.lnr-printer:before {
content: "\e81c";
}
.lnr-file-empty:before {
content: "\e81d";
}
.lnr-file-add:before {
content: "\e81e";
}
.lnr-enter:before {
content: "\e81f";
}
.lnr-exit:before {
content: "\e820";
}
.lnr-graduation-hat:before {
content: "\e821";
}
.lnr-license:before {
content: "\e822";
}
.lnr-music-note:before {
content: "\e823";
}
.lnr-film-play:before {
content: "\e824";
}
.lnr-camera-video:before {
content: "\e825";
}
.lnr-camera:before {
content: "\e826";
}
.lnr-picture:before {
content: "\e827";
}
.lnr-book:before {
content: "\e828";
}
.lnr-bookmark:before {
content: "\e829";
}
.lnr-user:before {
content: "\e82a";
}
.lnr-users:before {
content: "\e82b";
}
.lnr-shirt:before {
content: "\e82c";
}
.lnr-store:before {
content: "\e82d";
}
.lnr-cart:before {
content: "\e82e";
}
.lnr-tag:before {
content: "\e82f";
}
.lnr-phone-handset:before {
content: "\e830";
}
.lnr-phone:before {
content: "\e831";
}
.lnr-pushpin:before {
content: "\e832";
}
.lnr-map-marker:before {
content: "\e833";
}
.lnr-map:before {
content: "\e834";
}
.lnr-location:before {
content: "\e835";
}
.lnr-calendar-full:before {
content: "\e836";
}
.lnr-keyboard:before {
content: "\e837";
}
.lnr-spell-check:before {
content: "\e838";
}
.lnr-screen:before {
content: "\e839";
}
.lnr-smartphone:before {
content: "\e83a";
}
.lnr-tablet:before {
content: "\e83b";
}
.lnr-laptop:before {
content: "\e83c";
}
.lnr-laptop-phone:before {
content: "\e83d";
}
.lnr-power-switch:before {
content: "\e83e";
}
.lnr-bubble:before {
content: "\e83f";
}
.lnr-heart-pulse:before {
content: "\e840";
}
.lnr-construction:before {
content: "\e841";
}
.lnr-pie-chart:before {
content: "\e842";
}
.lnr-chart-bars:before {
content: "\e843";
}
.lnr-gift:before {
content: "\e844";
}
.lnr-diamond:before {
content: "\e845";
}
.lnr-linearicons:before {
content: "\e846";
}
.lnr-dinner:before {
content: "\e847";
}
.lnr-coffee-cup:before {
content: "\e848";
}
.lnr-leaf:before {
content: "\e849";
}
.lnr-paw:before {
content: "\e84a";
}
.lnr-rocket:before {
content: "\e84b";
}
.lnr-briefcase:before {
content: "\e84c";
}
.lnr-bus:before {
content: "\e84d";
}
.lnr-car:before {
content: "\e84e";
}
.lnr-train:before {
content: "\e84f";
}
.lnr-bicycle:before {
content: "\e850";
}
.lnr-wheelchair:before {
content: "\e851";
}
.lnr-select:before {
content: "\e852";
}
.lnr-earth:before {
content: "\e853";
}
.lnr-smile:before {
content: "\e854";
}
.lnr-sad:before {
content: "\e855";
}
.lnr-neutral:before {
content: "\e856";
}
.lnr-mustache:before {
content: "\e857";
}
.lnr-alarm:before {
content: "\e858";
}
.lnr-bullhorn:before {
content: "\e859";
}
.lnr-volume-high:before {
content: "\e85a";
}
.lnr-volume-medium:before {
content: "\e85b";
}
.lnr-volume-low:before {
content: "\e85c";
}
.lnr-volume:before {
content: "\e85d";
}
.lnr-mic:before {
content: "\e85e";
}
.lnr-hourglass:before {
content: "\e85f";
}
.lnr-undo:before {
content: "\e860";
}
.lnr-redo:before {
content: "\e861";
}
.lnr-sync:before {
content: "\e862";
}
.lnr-history:before {
content: "\e863";
}
.lnr-clock:before {
content: "\e864";
}
.lnr-download:before {
content: "\e865";
}
.lnr-upload:before {
content: "\e866";
}
.lnr-enter-down:before {
content: "\e867";
}
.lnr-exit-up:before {
content: "\e868";
}
.lnr-bug:before {
content: "\e869";
}
.lnr-code:before {
content: "\e86a";
}
.lnr-link:before {
content: "\e86b";
}
.lnr-unlink:before {
content: "\e86c";
}
.lnr-thumbs-up:before {
content: "\e86d";
}
.lnr-thumbs-down:before {
content: "\e86e";
}
.lnr-magnifier:before {
content: "\e86f";
}
.lnr-cross:before {
content: "\e870";
}
.lnr-menu:before {
content: "\e871";
}
.lnr-list:before {
content: "\e872";
}
.lnr-chevron-up:before {
content: "\e873";
}
.lnr-chevron-down:before {
content: "\e874";
}
.lnr-chevron-left:before {
content: "\e875";
}
.lnr-chevron-right:before {
content: "\e876";
}
.lnr-arrow-up:before {
content: "\e877";
}
.lnr-arrow-down:before {
content: "\e878";
}
.lnr-arrow-left:before {
content: "\e879";
}
.lnr-arrow-right:before {
content: "\e87a";
}
.lnr-move:before {
content: "\e87b";
}
.lnr-warning:before {
content: "\e87c";
}
.lnr-question-circle:before {
content: "\e87d";
}
.lnr-menu-circle:before {
content: "\e87e";
}
.lnr-checkmark-circle:before {
content: "\e87f";
}
.lnr-cross-circle:before {
content: "\e880";
}
.lnr-plus-circle:before {
content: "\e881";
}
.lnr-circle-minus:before {
content: "\e882";
}
.lnr-arrow-up-circle:before {
content: "\e883";
}
.lnr-arrow-down-circle:before {
content: "\e884";
}
.lnr-arrow-left-circle:before {
content: "\e885";
}
.lnr-arrow-right-circle:before {
content: "\e886";
}
.lnr-chevron-up-circle:before {
content: "\e887";
}
.lnr-chevron-down-circle:before {
content: "\e888";
}
.lnr-chevron-left-circle:before {
content: "\e889";
}
.lnr-chevron-right-circle:before {
content: "\e88a";
}
.lnr-crop:before {
content: "\e88b";
}
.lnr-frame-expand:before {
content: "\e88c";
}
.lnr-frame-contract:before {
content: "\e88d";
}
.lnr-layers:before {
content: "\e88e";
}
.lnr-funnel:before {
content: "\e88f";
}
.lnr-text-format:before {
content: "\e890";
}
.lnr-text-format-remove:before {
content: "\e891";
}
.lnr-text-size:before {
content: "\e892";
}
.lnr-bold:before {
content: "\e893";
}
.lnr-italic:before {
content: "\e894";
}
.lnr-underline:before {
content: "\e895";
}
.lnr-strikethrough:before {
content: "\e896";
}
.lnr-highlight:before {
content: "\e897";
}
.lnr-text-align-left:before {
content: "\e898";
}
.lnr-text-align-center:before {
content: "\e899";
}
.lnr-text-align-right:before {
content: "\e89a";
}
.lnr-text-align-justify:before {
content: "\e89b";
}
.lnr-line-spacing:before {
content: "\e89c";
}
.lnr-indent-increase:before {
content: "\e89d";
}
.lnr-indent-decrease:before {
content: "\e89e";
}
.lnr-pilcrow:before {
content: "\e89f";
}
.lnr-direction-ltr:before {
content: "\e8a0";
}
.lnr-direction-rtl:before {
content: "\e8a1";
}
.lnr-page-break:before {
content: "\e8a2";
}
.lnr-sort-alpha-asc:before {
content: "\e8a3";
}
.lnr-sort-amount-asc:before {
content: "\e8a4";
}
.lnr-hand:before {
content: "\e8a5";
}
.lnr-pointer-up:before {
content: "\e8a6";
}
.lnr-pointer-right:before {
content: "\e8a7";
}
.lnr-pointer-down:before {
content: "\e8a8";
}
.lnr-pointer-left:before {
content: "\e8a9";
}

Binary file not shown.

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 189 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 151 KiB

Binary file not shown.

Binary file not shown.

View file

@ -0,0 +1,4 @@
<label class="theme-settings-bg-item">
<input type="radio">
<span class="theme-settings-bg-name"></span>
</label>

View file

@ -0,0 +1,8 @@
<label class="theme-settings-theme-item custom-controls-stacked">
<input type="radio" name="theme-settings-current-theme">
<span class="d-block mr-auto">
<span class="theme-settings-theme-checkmark"></span> &nbsp;&nbsp;
<span class="theme-settings-theme-name"></span>
</span>
<span class="theme-settings-theme-colors d-flex"></span>
</label>

View file

@ -0,0 +1,117 @@
<div id="theme-settings" class="theme-bg-white">
<a href="javascript:void(0)" class="theme-settings-open-btn" tabindex="-1"></a>
<h5 class="p-4 m-0 line-height-1 font-weight-bolder bg-light theme-settings-header">
<span class="theme-settings-t-panel_header"></span>
<a href="javascript:void(0)" class="theme-settings-close-btn font-weight-light px-4 py-2 text-body" tabindex="-1">&times;</a>
</h5>
<div class="theme-settings-inner pt-4">
<label class="m-0 px-4 pb-3 d-flex media align-items-middle theme-settings-rtl">
<div class="media-body"><span class="theme-settings-t-rtl_switcher"></span></div>
<div class="switcher switcher-sm d-block m-0">
<input class="switcher-input" type="checkbox">
<span class="switcher-indicator">
<span class="switcher-yes"></span>
<span class="switcher-no"></span>
</span>
</div>
</label>
<label class="m-0 px-4 pb-3 theme-settings-style w-100">
<select class="custom-select custom-select-sm d-block w-100"></select>
</label>
<div class="theme-settings-layout">
<hr class="m-0 border-light">
<h5 class="m-0 px-4 py-3 line-height-1 text-light d-block">
<span class="theme-settings-t-layout_header"></span>
</h5>
<label class="m-0 px-4 pb-3 d-block theme-settings-layoutPosition">
<select class="custom-select custom-select-sm d-block w-100">
<option value="static" class="theme-settings-t-layout_static"></option>
<option value="static-offcanvas" class="theme-settings-t-layout_offcanvas"></option>
<option value="fixed" class="theme-settings-t-layout_fixed"></option>
<option value="fixed-offcanvas" class="theme-settings-t-layout_fixed_offcanvas"></option>
</select>
</label>
<label class="m-0 px-4 pb-3 d-flex media align-items-middle theme-settings-layoutNavbarFixed">
<div class="media-body"><span class="theme-settings-t-layout_navbar_swicher"></span></div>
<div class="switcher switcher-sm d-block m-0">
<input class="switcher-input" type="checkbox">
<span class="switcher-indicator">
<span class="switcher-yes"></span>
<span class="switcher-no"></span>
</span>
</div>
</label>
<label class="m-0 px-4 pb-3 d-flex media align-items-middle theme-settings-layoutFooterFixed">
<div class="media-body"><span class="theme-settings-t-layout_footer_swicher"></span></div>
<div class="switcher switcher-sm d-block m-0">
<input class="switcher-input" type="checkbox">
<span class="switcher-indicator">
<span class="switcher-yes"></span>
<span class="switcher-no"></span>
</span>
</div>
</label>
<label class="m-0 px-4 pb-3 d-flex media align-items-middle theme-settings-layoutReversed">
<div class="media-body"><span class="theme-settings-t-layout_reversed_swicher"></span></div>
<div class="switcher switcher-sm d-block m-0">
<input class="switcher-input" type="checkbox">
<span class="switcher-indicator">
<span class="switcher-yes"></span>
<span class="switcher-no"></span>
</span>
</div>
</label>
</div>
<div class="theme-settings-navbarBg">
<hr class="m-0 border-light">
<h5 class="m-0 px-4 py-3 line-height-1 text-light d-block ">
<span class="theme-settings-t-navbar_bg_header"></span>
</h5>
<fieldset class="m-0 px-4 pb-3 d-block clearfix theme-settings-navbarBg-inner"></fieldset>
</div>
<div class="theme-settings-sidenavBg">
<hr class="m-0 border-light">
<h5 class="m-0 px-4 py-3 line-height-1 text-light d-block">
<span class="theme-settings-t-sidenav_bg_header"></span>
</h5>
<fieldset class="m-0 px-4 pb-3 d-block clearfix theme-settings-sidenavBg-inner"></fieldset>
</div>
<div class="theme-settings-footerBg">
<hr class="m-0 border-light">
<h5 class="m-0 px-4 py-3 line-height-1 text-light d-block">
<span class="theme-settings-t-footer_bg_header"></span>
</h5>
<fieldset class="m-0 px-4 pb-3 d-block clearfix theme-settings-footerBg-inner"></fieldset>
</div>
<div class="theme-settings-themes">
<hr class="m-0 border-light">
<h5 class="m-0 px-4 py-3 line-height-1 text-light d-block">
<span class="theme-settings-t-theme_header"></span>
</h5>
<div class="theme-settings-themes-inner"></div>
</div>
</div>
</div>

View file

@ -0,0 +1,321 @@
$container-width: 230px;
$container-spacer: 20px;
$open-btn-size: 40px;
$open-btn-spacer: 0;
$open-btn-bg: #444;
$open-btn-color: #fff;
$open-btn-font-size: 20px;
$open-btn-top: 90px;
#theme-settings {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol" !important;
font-size: 13px !important;
position: fixed;
top: 0;
right: 0;
height: 100%;
z-index: 99999999;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-orient: vertical;
-webkit-box-direction: normal;
-ms-flex-direction: column;
flex-direction: column;
width: $container-width;
-webkit-box-shadow: 0 0 20px 0 rgba(0, 0, 0, .2);
box-shadow: 0 0 20px 0 rgba(0, 0, 0, .2);
-webkit-transition: all .2s ease-in;
-o-transition: all .2s ease-in;
transition: all .2s ease-in;
-webkit-transform: translateX($container-width + $container-spacer);
-ms-transform: translateX($container-width + $container-spacer);
transform: translateX($container-width + $container-spacer);
h5 {
position: relative;
font-size: 11px;
font-weight: 600;
}
.theme-settings-header {
font-size: 11px;
}
.disabled {
color: #d1d2d3 !important;
}
&.theme-settings-open {
-webkit-transition-delay: .1s;
-o-transition-delay: .1s;
transition-delay: .1s;
-webkit-transform: none !important;
-ms-transform: none !important;
transform: none !important;
}
.theme-settings-open-btn {
position: absolute;
top: $open-btn-top;
left: 0;
z-index: -1;
display: block;
width: $open-btn-size;
height: $open-btn-size;
border-top-left-radius: 50%;
border-bottom-left-radius: 50%;
background: $open-btn-bg;
color: $open-btn-color !important;
text-align: center;
font-size: $open-btn-font-size !important;
line-height: $open-btn-size;
opacity: 1;
-webkit-transition: all .1s linear .2s;
-o-transition: all .1s linear .2s;
transition: all .1s linear .2s;
-webkit-transform: translateX(-($open-btn-size + $container-spacer + $open-btn-spacer));
-ms-transform: translateX(-($open-btn-size + $container-spacer + $open-btn-spacer));
transform: translateX(-($open-btn-size + $container-spacer + $open-btn-spacer));
&::before {
content: "";
width: 18px;
height: 18px;
display: block;
background-size: 100% 100%;
position: absolute;
background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA3BJREFUeNrUml1IFFEUx8fNh6jMkkjY2pDAaokksVrItGLXhQiUPiDIjOg58CmISPt4EyIK3yKQEKIPhKJeCnM/lMyHonop6CUKE01Eow+Mxe1/6AytSzvec+fOpH/4gei952NmnHvuuVOUzWYtF1oHDoGDIAHaFeddAntBD/NJOwJKQIM4GMjO1k8QVpgb5rG2ZkAaxHRikU6oY2eFNApqHObT38Yc5idArZcJOAVvKwO6QQNYyzTw7zIK8/skMRULn7gnoG6OMYvAMUZHvZLBAaHxKct7ffUygVIfEij1MoH9PiSwTzK4SLAORMBzHxKggLaDFyYTWMEG11v+6D0nMWXiEaJb+sbH4EmV4DWIS+7AHnAW9IExsBrEQNT6v+plvoByjuci6M9PgH6xy1oYSoPduY9QfAEFT6oHDbkJnDNkeAY8BCfABrAMLAYVoAl0gW+GfLXb1WiIK0K36gVbFOqXcnA9a0YhMthqwFAHCAgLw+a8slpHraoVppOuaO4piCMufafpf2AATGs+h8/AaRfP8R1wTXMuxZyyr8TmOTYahRRxcfVtVoIJod9RjtnK3y1lBEb6DQRvc1ngl2Lcas/NLSWo1rktuIUPDL7XJbZugVeFaqGbAkMvDSYgsdXtVMy9Exj6bDCB74Ld3lunBGYkewnD5UHAxKSwYG7QYPBLQYni2E1OCbQInG4zmIDE1vFCCVSBowJDTQYTkNiiGKvzW4sbwYjGQrbTwBpQBiY1FrKwvZC1gR+atcggKHaZQKemb4q5jQwkXRZUnS6Cb3HpOxHg9rYbnQJXuaUo0Ulww6XvHroKawxtaOhOVitc9SDoMuCPYg7am/qkvUk20JR6DO5zqT0CfvGaQW+5RnAALDHgK0WdFDuBqLQrPA9EMffltlVM3QU/lOQjqll9Ier7n+dbM86NrajCeYDXon7VU262reKLfIF3kkonNI1gOOu/htm3Y3yqzd0y3vBU+HTVP4AaMGGqhJ0Q1klu1awSvLQGHwRDPgQ/xK9gTzYRj3xIQORjPh7yTXqZQIkPCSz3MoGYYof6LpcNlQz9fE9xzy07UBGWv/Ug5fDuHgc7HOZHeEwhpdiHZ58a2ES5+sytYqdBlcLcKh47q0mr+7GH5Jj1XwpZfz63OcxL+xnFeR2g1vr7uc1H3QB+CzAA7A9pvcD5g+8AAAAASUVORK5CYII=');
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
margin-left: 2px;
}
[dir=rtl] & {
border-radius: 0;
border-top-right-radius: 50%;
border-bottom-right-radius: 50%;
&::before {
margin-left: -2px;
}
}
}
&.theme-settings-open .theme-settings-open-btn {
opacity: 0;
-webkit-transition-delay: 0s;
-o-transition-delay: 0s;
transition-delay: 0s;
-webkit-transform: none !important;
-ms-transform: none !important;
transform: none !important;
}
.theme-settings-close-btn {
position: absolute;
top: 50%;
right: 0;
display: block;
font-size: 20px;
-webkit-transform: translateY(-50%);
-ms-transform: translateY(-50%);
transform: translateY(-50%);
}
> h5 {
flex: 0 0 auto;
}
.theme-settings-inner {
position: relative;
overflow: auto;
-webkit-box-flex: 0;
-ms-flex: 0 1 auto;
flex: 0 1 auto;
opacity: 1;
-webkit-transition: opacity .2s;
-o-transition: opacity .2s;
transition: opacity .2s;
> div:first-child {
> hr:first-of-type {
display: none !important;
}
> h5:first-of-type {
padding-top: 0 !important;
}
}
}
.theme-settings-themes-inner {
position: relative;
opacity: 1;
-webkit-transition: opacity .2s;
-o-transition: opacity .2s;
transition: opacity .2s;
}
.theme-settings-theme-item {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-align: center;
align-items: center;
-ms-flex-align: center;
-webkit-box-flex: 1;
-ms-flex: 1 1 100%;
flex: 1 1 100%;
-webkit-box-pack: justify;
-ms-flex-pack: justify;
justify-content: space-between;
margin-bottom: 10px;
padding: 0 24px;
width: 100%;
cursor: pointer;
input {
position: absolute;
z-index: -1; // Put the input behind the label so it doesn't overlay text
opacity: 0;
}
input ~ span {
opacity: .25;
-webkit-transition: all .2s;
-o-transition: all .2s;
transition: all .2s;
}
.theme-settings-theme-checkmark {
display: inline-block;
width: 6px;
height: 12px;
border-right: 1px solid;
border-bottom: 1px solid;
opacity: 0;
-webkit-transition: all .2s;
-o-transition: all .2s;
transition: all .2s;
-webkit-transform: rotate(45deg);
-ms-transform: rotate(45deg);
transform: rotate(45deg);
[dir=rtl] & {
border-right: none;
border-left: 1px solid;
-webkit-transform: rotate(-45deg);
-ms-transform: rotate(-45deg);
transform: rotate(-45deg);
}
}
input:checked:not([disabled]) ~ span,
&:hover input:not([disabled]) ~ span {
opacity: 1;
}
input:checked:not([disabled]) ~ span .theme-settings-theme-checkmark {
opacity: 1;
}
}
.theme-settings-theme-colors {
span {
display: block;
margin: 0 1px;
width: 10px;
height: 10px;
border-radius: 50%;
-webkit-box-shadow: 0 0 0 1px rgba(0,0,0,.1) inset;
box-shadow: 0 0 0 1px rgba(0,0,0,.1) inset;
.dark-style & {
-webkit-box-shadow: 0 0 0 1px rgba(255, 255, 255, .1) inset;
box-shadow: 0 0 0 1px rgba(255, 255, 255, .1) inset;
}
}
}
&.theme-settings-loading .theme-settings-inner,
&.theme-settings-loading-theme .theme-settings-themes-inner {
opacity: .2;
&::after {
content: "";
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
z-index: 999;
display: block;
}
}
.theme-settings-navbarBg-inner[disabled] .theme-settings-bg-item,
.theme-settings-sidenavBg-inner[disabled] .theme-settings-bg-item,
.theme-settings-bg-item.disabled {
opacity: .2;
cursor: default;
}
.theme-settings-bg-item {
display: block;
float: left;
margin: 3px;
width: 16px;
height: 16px;
border-radius: 2px;
-webkit-box-shadow: 0 0 0 1px rgba(0,0,0,.1) inset;
box-shadow: 0 0 0 1px rgba(0,0,0,.1) inset;
cursor: pointer;
&.active {
-webkit-box-shadow: 0 0 0 2px #000;
box-shadow: 0 0 0 2px #000;
}
input {
position: absolute;
visibility: hidden;
clip: rect(0, 0, 0, 0);
pointer-events: none;
}
}
}
.layout-sidenav-100vh #theme-settings {
height: 100vh;
}
// RTL
//
[dir=rtl] {
#theme-settings {
right: auto;
left: 0;
-webkit-transform: translateX(-($container-width + $container-spacer));
-ms-transform: translateX(-($container-width + $container-spacer));
transform: translateX(-($container-width + $container-spacer));
}
#theme-settings .theme-settings-open-btn {
right: 0;
left: auto;
-webkit-transform: translateX($open-btn-size + $container-spacer + $open-btn-spacer);
-ms-transform: translateX($open-btn-size + $container-spacer + $open-btn-spacer);
transform: translateX($open-btn-size + $container-spacer + $open-btn-spacer);
}
#theme-settings .theme-settings-close-btn {
right: auto;
left: 0;
}
#theme-settings .theme-settings-bg-item {
float: right;
}
}

57
resources/assets/vendor/js/bootstrap.js vendored Executable file
View file

@ -0,0 +1,57 @@
import Util from 'bootstrap/js/src/util.js'
import Alert from 'bootstrap/js/src/alert.js'
import Button from 'bootstrap/js/src/button.js'
import Carousel from 'bootstrap/js/src/carousel.js'
import Collapse from 'bootstrap/js/src/collapse.js'
import Dropdown from 'bootstrap/js/src/dropdown.js'
import Modal from 'bootstrap/js/src/modal.js'
import Scrollspy from 'bootstrap/js/src/scrollspy.js'
import Tab from 'bootstrap/js/src/tab.js'
import Toast from 'bootstrap/js/src/toast.js'
import Tooltip from 'bootstrap/js/src/tooltip.js'
import Popover from 'bootstrap/js/src/popover.js'
// Tooltip extension
//
const bsTooltipSetContent = Tooltip.prototype.setContent
// Set tooltip state
Tooltip.prototype.setContent = function() {
const state = this.element.getAttribute('data-state')
if (state)
$(this.getTipElement()).addClass(`tooltip-${state.replace(/[^a-z0-9_-]/ig, '')}`)
bsTooltipSetContent.call(this)
}
// Popover extension
//
const bsPopoverSetContent = Popover.prototype.setContent
// Set popover state
Popover.prototype.setContent = function() {
const state = this.element.getAttribute('data-state')
if (state)
$(this.getTipElement()).addClass(`popover-${state.replace(/[^a-z0-9_-]/ig, '')}`)
bsPopoverSetContent.call(this)
}
export {
Util,
Alert,
Button,
Carousel,
Collapse,
Dropdown,
Modal,
Scrollspy,
Tab,
Toast,
Tooltip,
Popover
}

View file

@ -0,0 +1,78 @@
// Add onHover event for dropdowns
(function($) {
if (!$ || !$.fn) return
const SELECTOR = '[data-toggle=dropdown][data-trigger=hover]'
const TIMEOUT = 150
function openDropdown($i) {
let t = $i.data('dd-timeout')
if (t) {
clearTimeout(t)
t = null
$i.data('dd-timeout', t)
}
if ($i.attr('aria-expanded') !== 'true') $i.dropdown('toggle')
}
function closeDropdown($i) {
let t = $i.data('dd-timeout')
if (t) clearTimeout(t)
t = setTimeout(() => {
let t2 = $i.data('dd-timeout')
if (t2) {
clearTimeout(t2)
t2 = null
$i.data('dd-timeout', t2)
}
if ($i.attr('aria-expanded') === 'true') $i.dropdown('toggle')
}, TIMEOUT)
$i.data('dd-timeout', t)
}
$(function() {
$('body')
.on('mouseenter', `${SELECTOR}, ${SELECTOR} ~ .dropdown-menu`, function() {
const $toggle = $(this).hasClass('dropdown-toggle') ? $(this) : $(this).prev('.dropdown-toggle')
const $dropdown = $(this).hasClass('dropdown-menu') ? $(this) : $(this).next('.dropdown-menu')
if (window.getComputedStyle($dropdown[0], null).getPropertyValue('position') === 'static') return
// Set hovered flag
if ($(this).is(SELECTOR)) {
$(this).data('hovered', true)
}
openDropdown(
$(this).hasClass('dropdown-toggle') ? $(this) : $(this).prev('.dropdown-toggle')
)
})
.on('mouseleave', `${SELECTOR}, ${SELECTOR} ~ .dropdown-menu`, function() {
const $toggle = $(this).hasClass('dropdown-toggle') ? $(this) : $(this).prev('.dropdown-toggle')
const $dropdown = $(this).hasClass('dropdown-menu') ? $(this) : $(this).next('.dropdown-menu')
if (window.getComputedStyle($dropdown[0], null).getPropertyValue('position') === 'static') return
// Remove hovered flag
if ($(this).is(SELECTOR)) {
$(this).data('hovered', false)
}
closeDropdown(
$(this).hasClass('dropdown-toggle') ? $(this) : $(this).prev('.dropdown-toggle')
)
})
.on('hide.bs.dropdown', function(e) {
if ($(this).find(SELECTOR).data('hovered')) e.preventDefault()
})
})
})(window.jQuery)

View file

@ -0,0 +1,680 @@
// Constants
const TRANSITION_EVENTS = ['transitionend','webkitTransitionEnd','oTransitionEnd']
const TRANSITION_PROPERTIES = ['transition', 'MozTransition', 'webkitTransition', 'WebkitTransition', 'OTransition']
const INLINE_STYLE = `
.layout-fixed .layout-1 .layout-sidenav,
.layout-fixed-offcanvas .layout-1 .layout-sidenav {
top: {navbarHeight}px !important;
}
.layout-container {
padding-top: {navbarHeight}px !important;
}
.layout-content {
padding-bottom: {footerHeight}px !important;
}`
// Guard
function requiredParam(name) {
throw new Error(`Parameter required${name ? ': `' + name + '`' : ''}`)
}
const layoutHelpers = {
// Root container
CONTAINER: typeof window !== 'undefined' ? document.documentElement : null,
// Large screens breakpoint
LAYOUT_BREAKPOINT: 992,
// Resize delay in milliseconds
RESIZE_DELAY: 200,
// Internal variables
_curStyle: null,
_styleEl: null,
_resizeTimeout: null,
_resizeCallback: null,
_transitionCallback: null,
_transitionCallbackTimeout: null,
_listeners: [],
_initialized: false,
_autoUpdate: false,
_lastWindowHeight: 0,
// *******************************************************************************
// * Utilities
// ---
// Add class
_addClass(cls, el = this.CONTAINER) {
cls.split(' ').forEach(c => el.classList.add(c))
},
// ---
// Remove class
_removeClass(cls, el = this.CONTAINER) {
cls.split(' ').forEach(c => el.classList.remove(c))
},
// ---
// Has class
_hasClass(cls, el = this.CONTAINER) {
let result = false
cls.split(' ').forEach(c => {
if (el.classList.contains(c)) result = true
})
return result
},
// ---
// Check for transition support
_supportsTransitionEnd() {
if (window.QUnit) return false
const el = document.body || document.documentElement
if (!el) return false
let result = false
TRANSITION_PROPERTIES.forEach(evnt => {
if (typeof el.style[evnt] !== 'undefined') result = true
})
return result
},
// ---
// Get animation duration of element
_getAnimationDuration(el) {
let duration = window.getComputedStyle(el).transitionDuration
return parseFloat(duration) * (duration.indexOf('ms') !== -1 ? 1 : 1000)
},
// ---
// Trigger window event
_triggerWindowEvent(name) {
if (typeof window === 'undefined') return
if (document.createEvent) {
let event
if (typeof(Event) === 'function') {
event = new Event(name)
} else {
event = document.createEvent('Event')
event.initEvent(name, false, true)
}
window.dispatchEvent(event)
} else {
window.fireEvent(`on${name}`, document.createEventObject())
}
},
// ---
// Trigger event
_triggerEvent(name) {
this._triggerWindowEvent(`layout${name}`)
this._listeners
.filter(listener => listener.event === name)
.forEach(listener => listener.callback.call(null))
},
// ---
// Update style
_updateInlineStyle(navbarHeight = 0, footerHeight = 0) {
if (!this._styleEl) {
this._styleEl = document.createElement('style')
this._styleEl.type = 'text/css'
document.head.appendChild(this._styleEl)
}
const newStyle = INLINE_STYLE
.replace(/\{navbarHeight\}/ig, navbarHeight)
.replace(/\{footerHeight\}/ig, footerHeight)
if (this._curStyle !== newStyle) {
this._curStyle = newStyle
this._styleEl.textContent = newStyle
}
},
// ---
// Remove style
_removeInlineStyle() {
if (this._styleEl) document.head.removeChild(this._styleEl)
this._styleEl = null
this._curStyle = null
},
// ---
// Redraw layout sidenav (Safari bugfix)
_redrawLayoutSidenav() {
const layoutSidenav = this.getLayoutSidenav()
if (layoutSidenav && layoutSidenav.querySelector('.sidenav')) {
const inner = layoutSidenav.querySelector('.sidenav-inner')
const scrollTop = inner.scrollTop
const pageScrollTop = document.documentElement.scrollTop
layoutSidenav.style.display = 'none'
layoutSidenav.offsetHeight
layoutSidenav.style.display = ''
inner.scrollTop = scrollTop
document.documentElement.scrollTop = pageScrollTop
return true
}
return false
},
// ---
// Calculate current navbar height
_getNavbarHeight() {
const layoutNavbar = this.getLayoutNavbar()
if (!layoutNavbar) return 0
if (!this.isSmallScreen()) return layoutNavbar.getBoundingClientRect().height
// Needs some logic to get navbar height on small screens
const clonedEl = layoutNavbar.cloneNode(true)
clonedEl.id = null
clonedEl.style.visibility = 'hidden'
clonedEl.style.position = 'absolute'
Array.prototype.slice.call(clonedEl.querySelectorAll('.collapse.show'))
.forEach(el => this._removeClass('show', el))
layoutNavbar.parentNode.insertBefore(clonedEl, layoutNavbar)
const navbarHeight = clonedEl.getBoundingClientRect().height
clonedEl.parentNode.removeChild(clonedEl)
return navbarHeight
},
// ---
// Get current footer height
_getFooterHeight() {
const layoutFooter = this.getLayoutFooter()
if (!layoutFooter) return 0
return layoutFooter.getBoundingClientRect().height
},
// ---
// Add layout sivenav toggle animationEnd event
_bindLayoutAnimationEndEvent(modifier, cb) {
const sidenav = this.getSidenav()
const duration = sidenav ? this._getAnimationDuration(sidenav) + 50 : 0
if (!duration) {
modifier.call(this)
cb.call(this)
return
}
this._transitionCallback = e => {
if (e.target !== sidenav) return
this._unbindLayoutAnimationEndEvent()
cb.call(this)
}
TRANSITION_EVENTS.forEach(e => {
sidenav.addEventListener(e, this._transitionCallback, false)
})
modifier.call(this)
this._transitionCallbackTimeout = setTimeout(() => {
this._transitionCallback.call(this, { target: sidenav })
}, duration)
},
// ---
// Remove layout sivenav toggle animationEnd event
_unbindLayoutAnimationEndEvent() {
const sidenav = this.getSidenav()
if (this._transitionCallbackTimeout) {
clearTimeout(this._transitionCallbackTimeout)
this._transitionCallbackTimeout = null
}
if (sidenav && this._transitionCallback) {
TRANSITION_EVENTS.forEach(e => {
sidenav.removeEventListener(e, this._transitionCallback, false)
})
}
if (this._transitionCallback) {
this._transitionCallback = null
}
},
// ---
// Bind delayed window resize event
_bindWindowResizeEvent() {
this._unbindWindowResizeEvent()
const cb = () => {
if (this._resizeTimeout) {
clearTimeout(this._resizeTimeout)
this._resizeTimeout = null
}
this._triggerEvent('resize')
}
this._resizeCallback = () => {
if (this._resizeTimeout) clearTimeout(this._resizeTimeout)
this._resizeTimeout = setTimeout(cb, this.RESIZE_DELAY)
}
window.addEventListener('resize', this._resizeCallback, false)
},
// ---
// Unbind delayed window resize event
_unbindWindowResizeEvent() {
if (this._resizeTimeout) {
clearTimeout(this._resizeTimeout)
this._resizeTimeout = null
}
if (this._resizeCallback) {
window.removeEventListener('resize', this._resizeCallback, false)
this._resizeCallback = null
}
},
// ---
// Set sidenav hover state
_setSidenavHoverState(hovered) {
this[hovered ? '_addClass' : '_removeClass']('layout-sidenav-hover')
},
// ---
// Toggle collapsed
_setCollapsed(collapsed) {
if (this.isSmallScreen()) {
if (collapsed) {
this._removeClass('layout-expanded')
} else {
setTimeout(() => {
this._addClass('layout-expanded')
}, this._redrawLayoutSidenav() ? 5 : 0)
}
} else {
this[collapsed ? '_addClass' : '_removeClass']('layout-collapsed')
}
},
_findParent(el, cls) {
if (el && el.tagName.toUpperCase() === 'BODY') return null
el = el.parentNode
while (el && el.tagName.toUpperCase() !== 'BODY' && !el.classList.contains(cls)) {
el = el.parentNode
}
el = el && el.tagName.toUpperCase() !== 'BODY' ? el : null
return el
},
_bindSidenavMouseEvents() {
if (this._sidenavMouseEnter && this._sidenavMouseLeave && this._windowTouchStart) return
const layoutSidenav = this.getLayoutSidenav()
if (!layoutSidenav) return this._unbindSidenavMouseEvents()
if (!this._sidenavMouseEnter) {
this._sidenavMouseEnter = () => {
if (this.isSmallScreen() || !this._hasClass('layout-collapsed') ||
this.isOffcanvas() || this._hasClass('layout-transitioning')) {
return this._setSidenavHoverState(false)
}
this._setSidenavHoverState(true)
}
layoutSidenav.addEventListener('mouseenter', this._sidenavMouseEnter, false)
layoutSidenav.addEventListener('touchstart', this._sidenavMouseEnter, false)
}
if (!this._sidenavMouseLeave) {
this._sidenavMouseLeave = () => {
this._setSidenavHoverState(false)
}
layoutSidenav.addEventListener('mouseleave', this._sidenavMouseLeave, false)
}
if (!this._windowTouchStart) {
this._windowTouchStart = e => {
if (!e || !e.target || !this._findParent(e.target, '.layout-sidenav')) {
this._setSidenavHoverState(false)
}
}
window.addEventListener('touchstart', this._windowTouchStart, true)
}
},
_unbindSidenavMouseEvents() {
if (!this._sidenavMouseEnter && !this._sidenavMouseLeave && !this._windowTouchStart) return
const layoutSidenav = this.getLayoutSidenav()
if (this._sidenavMouseEnter) {
if (layoutSidenav) {
layoutSidenav.removeEventListener('mouseenter', this._sidenavMouseEnter, false)
layoutSidenav.removeEventListener('touchstart', this._sidenavMouseEnter, false)
}
this._sidenavMouseEnter = null
}
if (this._sidenavMouseLeave) {
if (layoutSidenav) {
layoutSidenav.removeEventListener('mouseleave', this._sidenavMouseLeave, false)
}
this._sidenavMouseLeave = null
}
if (this._windowTouchStart) {
if (layoutSidenav) {
window.addEventListener('touchstart', this._windowTouchStart, true)
}
this._windowTouchStart = null
}
this._setSidenavHoverState(false)
},
// *******************************************************************************
// * Getters
getLayoutSidenav() {
return document.querySelector('.layout-sidenav')
},
getSidenav() {
const layoutSidenav = this.getLayoutSidenav()
if (!layoutSidenav) return null
return !this._hasClass('sidenav', layoutSidenav) ?
layoutSidenav.querySelector('.sidenav') :
layoutSidenav
},
getLayoutNavbar() {
return document.querySelector('.layout-navbar')
},
getLayoutFooter() {
return document.querySelector('.layout-footer')
},
getLayoutContainer() {
return document.querySelector('.layout-container')
},
// *******************************************************************************
// * Tests
isMobileDevice() {
return (typeof window.orientation !== "undefined") || (navigator.userAgent.indexOf('IEMobile') !== -1)
},
isSmallScreen() {
return (
window.innerWidth ||
document.documentElement.clientWidth ||
document.body.clientWidth
) < this.LAYOUT_BREAKPOINT
},
isLayout1() {
return !!document.querySelector('.layout-wrapper.layout-1')
},
isCollapsed() {
if (this.isSmallScreen()) {
return !this._hasClass('layout-expanded')
} else {
return this._hasClass('layout-collapsed')
}
},
isFixed() {
return this._hasClass('layout-fixed layout-fixed-offcanvas')
},
isOffcanvas() {
return this._hasClass('layout-offcanvas layout-fixed-offcanvas')
},
isNavbarFixed() {
return this._hasClass('layout-navbar-fixed') ||
(!this.isSmallScreen() && this.isFixed() && this.isLayout1())
},
isFooterFixed() {
return this._hasClass('layout-footer-fixed')
},
isReversed() {
return this._hasClass('layout-reversed')
},
// *******************************************************************************
// * Methods
// ---
// Collapse / expand layout
setCollapsed(collapsed = requiredParam('collapsed'), animate = true) {
const layoutSidenav = this.getLayoutSidenav()
if (!layoutSidenav) return
this._unbindLayoutAnimationEndEvent()
if (animate && this._supportsTransitionEnd()) {
this._addClass('layout-transitioning')
if (collapsed) this._setSidenavHoverState(false)
this._bindLayoutAnimationEndEvent(() => {
// Collapse / Expand
this._setCollapsed(collapsed)
}, () => {
this._removeClass('layout-transitioning')
this._triggerWindowEvent('resize')
this._triggerEvent('toggle')
this._setSidenavHoverState(false)
})
} else {
this._addClass('layout-no-transition')
if (collapsed) this._setSidenavHoverState(false)
// Collapse / Expand
this._setCollapsed(collapsed)
setTimeout(() => {
this._removeClass('layout-no-transition')
this._triggerWindowEvent('resize')
this._triggerEvent('toggle')
this._setSidenavHoverState(false)
}, 1)
}
},
// ---
// Toggle layout
toggleCollapsed(animate = true) {
this.setCollapsed(!this.isCollapsed(), animate)
},
// ---
// Set layout positioning
setPosition(fixed = requiredParam('fixed'), offcanvas = requiredParam('offcanvas')) {
this._removeClass('layout-offcanvas layout-fixed layout-fixed-offcanvas')
if (!fixed && offcanvas) {
this._addClass('layout-offcanvas')
} else if (fixed && !offcanvas) {
this._addClass('layout-fixed')
this._redrawLayoutSidenav()
} else if (fixed && offcanvas) {
this._addClass('layout-fixed-offcanvas')
this._redrawLayoutSidenav()
}
this.update()
},
setNavbarFixed(fixed = requiredParam('fixed')) {
this[fixed ? '_addClass' : '_removeClass']('layout-navbar-fixed')
this.update()
},
setFooterFixed(fixed = requiredParam('fixed')) {
this[fixed ? '_addClass' : '_removeClass']('layout-footer-fixed')
this.update()
},
setReversed(reversed = requiredParam('reversed')) {
this[reversed ? '_addClass' : '_removeClass']('layout-reversed')
},
// *******************************************************************************
// * Update
update() {
if (
(this.getLayoutNavbar() && (
(!this.isSmallScreen() && this.isLayout1() && this.isFixed()) || this.isNavbarFixed()
)) || (this.getLayoutFooter() && this.isFooterFixed())
) {
this._updateInlineStyle(this._getNavbarHeight(), this._getFooterHeight())
}
this._bindSidenavMouseEvents()
},
setAutoUpdate(enable = requiredParam('enable')) {
if (enable && !this._autoUpdate) {
this.on('resize.layoutHelpers:autoUpdate', () => this.update())
this._autoUpdate = true
} else if (!enable && this._autoUpdate) {
this.off('resize.layoutHelpers:autoUpdate')
this._autoUpdate = false
}
},
// *******************************************************************************
// * Events
on(event = requiredParam('event'), callback = requiredParam('callback')) {
let [_event, ...namespace] = event.split('.')
namespace = namespace.join('.') || null
this._listeners.push({ event: _event, namespace, callback })
},
off(event = requiredParam('event')) {
let [_event, ...namespace] = event.split('.')
namespace = namespace.join('.') || null
this._listeners
.filter(listener => listener.event === _event && listener.namespace === namespace)
.forEach(listener => this._listeners.splice(this._listeners.indexOf(listener), 1))
},
// *******************************************************************************
// * Life cycle
init() {
if (this._initialized) return
this._initialized = true
// Initialize `style` element
this._updateInlineStyle(0)
// Bind window resize event
this._bindWindowResizeEvent()
// Bind init event
this.off('init._layoutHelpers')
this.on('init._layoutHelpers', () => {
this.off('resize._layoutHelpers:redrawSidenav')
this.on('resize._layoutHelpers:redrawSidenav', () => {
this.isSmallScreen() && !this.isCollapsed() && this._redrawLayoutSidenav()
})
// Force repaint in IE 10
if (typeof document.documentMode === 'number' && document.documentMode < 11) {
this.off('resize._layoutHelpers:ie10RepaintBody')
this.on('resize._layoutHelpers:ie10RepaintBody', () => {
if (this.isFixed()) return
const scrollTop = document.documentElement.scrollTop
document.body.style.display = 'none'
document.body.offsetHeight
document.body.style.display = 'block'
document.documentElement.scrollTop = scrollTop
})
}
})
this._triggerEvent('init')
},
destroy() {
if (!this._initialized) return
this._initialized = false
this._removeClass('layout-transitioning')
this._removeInlineStyle()
this._unbindLayoutAnimationEndEvent()
this._unbindWindowResizeEvent()
this._unbindSidenavMouseEvents()
this.setAutoUpdate(false)
this.off('init._layoutHelpers')
// Remove all listeners except `init`
this._listeners
.filter(listener => listener.event !== 'init')
.forEach(listener => this._listeners.splice(this._listeners.indexOf(listener), 1))
}
}
// *******************************************************************************
// * Initialization
if (typeof window !== 'undefined') {
layoutHelpers.init()
if (layoutHelpers.isMobileDevice() && window.chrome) {
document.documentElement.classList.add('layout-sidenav-100vh')
}
// Update layout after page load
if (document.readyState === 'complete') layoutHelpers.update()
else document.addEventListener('DOMContentLoaded', function onContentLoaded() {
layoutHelpers.update()
document.removeEventListener('DOMContentLoaded', onContentLoaded)
})
}
// ---
export { layoutHelpers }

View file

@ -0,0 +1,79 @@
import style from 'node-waves/dist/waves.css'
import Waves from 'node-waves/dist/waves.js'
function isElementWithRipple(el) {
const cls = (el.className || '').split(' ')
return (
cls.indexOf('btn') !== -1 ||
cls.indexOf('page-link') !== -1 ||
cls.indexOf('dropdown-item') !== -1 ||
(
el.tagName &&
el.tagName.toUpperCase() === 'A' &&
el.parentNode.tagName.toUpperCase() === 'LI'
&& (
el.parentNode.parentNode.className.indexOf('dropdown-menu') !== -1 ||
el.parentNode.parentNode.className.indexOf('pagination') !== -1
)
)
)
}
function getElementWithRipple(target) {
if (!target) return null
if (typeof target.className.indexOf !== 'function' || target.className.indexOf('waves-effect') !== -1) return null
if (isElementWithRipple(target)) return target
let el = target.parentNode
while (el && el.tagName.toUpperCase() !== 'BODY' && el.className.indexOf('waves-effect') === -1) {
if (isElementWithRipple(el)) return el
el = el.parentNode
}
return null
}
function attachWaves(e) {
if (e.button === 2) return
const el = getElementWithRipple(e.target)
el && Waves.attach(el)
}
function attachMaterialRipple() {
if (typeof window === 'undefined') return
if (typeof document['documentMode'] === 'number' && document['documentMode'] < 11) return
document.body.addEventListener('mousedown', attachWaves, false)
if ('ontouchstart' in window) document.body.addEventListener('touchstart', attachWaves, false)
Waves.init({ duration: 500 })
}
function attachMaterialRippleOnLoad() {
if (document.body) {
attachMaterialRipple()
} else {
window.addEventListener('DOMContentLoaded', function windowOnLoad() {
attachMaterialRipple()
window.removeEventListener('DOMContentLoaded', windowOnLoad)
})
}
}
function detachMaterialRipple() {
if (typeof window === 'undefined' || !document.body) return
if (typeof document['documentMode'] === 'number' && document['documentMode'] < 11) return
document.body.removeEventListener('mousedown', attachWaves, false)
if ('ontouchstart' in window) document.body.removeEventListener('touchstart', attachWaves, false)
Waves.calm('.waves-effect')
}
export { attachMaterialRipple, attachMaterialRippleOnLoad, detachMaterialRipple }

View file

@ -0,0 +1,207 @@
const TIMEOUT = 150
class MegaDropdown {
constructor(element, options = {}) {
this._onHover = options.trigger === 'hover' || element.getAttribute('data-trigger') === 'hover'
this._container = this._findParent(element, 'mega-dropdown')
if (!this._container) return
this._menu = this._container.querySelector('.dropdown-toggle ~ .dropdown-menu')
if (!this._menu) return
element.setAttribute('aria-expanded', 'false')
this._el = element
this._bindEvents()
}
open() {
if (this._timeout) {
clearTimeout(this._timeout)
this._timeout = null
}
if (this._focusTimeout) {
clearTimeout(this._focusTimeout)
this._focusTimeout = null
}
if (this._el.getAttribute('aria-expanded') !== 'true') {
this._triggerEvent('show')
this._container.classList.add('show')
this._menu.classList.add('show')
this._el.setAttribute('aria-expanded', 'true')
this._el.focus()
this._triggerEvent('shown')
}
}
close(force) {
if (this._timeout) {
clearTimeout(this._timeout)
this._timeout = null
}
if (this._focusTimeout) {
clearTimeout(this._focusTimeout)
this._focusTimeout = null
}
if (this._onHover && !force) {
this._timeout = setTimeout(() => {
if (this._timeout) {
clearTimeout(this._timeout)
this._timeout = null
}
this._close()
}, TIMEOUT)
} else {
this._close()
}
}
toggle() {
this._el.getAttribute('aria-expanded') === 'true' ?
this.close(true) :
this.open()
}
destroy() {
this._unbindEvents()
this._el = null
if (this._timeout) {
clearTimeout(this._timeout)
this._timeout = null
}
if (this._focusTimeout) {
clearTimeout(this._focusTimeout)
this._focusTimeout = null
}
}
_close() {
if (this._el.getAttribute('aria-expanded') === 'true') {
this._triggerEvent('hide')
this._container.classList.remove('show')
this._menu.classList.remove('show')
this._el.setAttribute('aria-expanded', 'false')
this._triggerEvent('hidden')
}
}
_bindEvents() {
this._elClickEvnt = (e) => {
e.preventDefault()
this.toggle()
}
this._el.addEventListener('click', this._elClickEvnt)
this._bodyClickEvnt = (e) => {
if (!this._container.contains(e.target) && this._container.classList.contains('show')) {
this.close(true)
}
}
document.body.addEventListener('click', this._bodyClickEvnt, true)
this._menuClickEvnt = (e) => {
if (e.target.classList.contains('mega-link')) {
this.close(true)
}
}
this._menu.addEventListener('click', this._menuClickEvnt, true)
this._focusoutEvnt = (e) => {
if (this._focusTimeout) {
clearTimeout(this._focusTimeout)
this._focusTimeout = null
}
if (this._el.getAttribute('aria-expanded') !== 'true') return
this._focusTimeout = setTimeout(() => {
if (
document.activeElement.tagName.toUpperCase() !== 'BODY' &&
this._findParent(document.activeElement, 'mega-dropdown') !== this._container
) {
this.close(true)
}
}, 100)
}
this._container.addEventListener('focusout', this._focusoutEvnt, true)
if (this._onHover) {
this._enterEvnt = (e) => {
if (window.getComputedStyle(this._menu, null).getPropertyValue('position') === 'static') return
this.open()
}
this._leaveEvnt = (e) => {
if (window.getComputedStyle(this._menu, null).getPropertyValue('position') === 'static') return
this.close()
}
this._el.addEventListener('mouseenter', this._enterEvnt)
this._menu.addEventListener('mouseenter', this._enterEvnt)
this._el.addEventListener('mouseleave', this._leaveEvnt)
this._menu.addEventListener('mouseleave', this._leaveEvnt)
}
}
_unbindEvents() {
if (this._elClickEvnt) {
this._el.removeEventListener('click', this._elClickEvnt)
this._elClickEvnt = null
}
if (this._bodyClickEvnt) {
document.body.removeEventListener('click', this._bodyClickEvnt, true)
this._bodyClickEvnt = null
}
if (this._menuClickEvnt) {
this._menu.removeEventListener('click', this._menuClickEvnt, true)
this._menuClickEvnt = null
}
if (this._focusoutEvnt) {
this._container.removeEventListener('focusout', this._focusoutEvnt, true)
this._focusoutEvnt = null
}
if (this._enterEvnt) {
this._el.removeEventListener('mouseenter', this._enterEvnt)
this._menu.removeEventListener('mouseenter', this._enterEvnt)
this._enterEvnt = null
}
if (this._leaveEvnt) {
this._el.removeEventListener('mouseleave', this._leaveEvnt)
this._menu.removeEventListener('mouseleave', this._leaveEvnt)
this._leaveEvnt = null
}
}
_findParent(el, cls) {
if (el.tagName.toUpperCase() === 'BODY') return null
el = el.parentNode
while (el.tagName.toUpperCase() !== 'BODY' && !el.classList.contains(cls)) {
el = el.parentNode
}
return el.tagName.toUpperCase() !== 'BODY' ? el : null
}
_triggerEvent(event) {
if (document.createEvent) {
let customEvent
if (typeof(Event) === 'function') {
customEvent = new Event(event)
} else {
customEvent = document.createEvent('Event')
customEvent.initEvent(event, false, true)
}
this._container.dispatchEvent(customEvent)
} else {
this._container.fireEvent('on' + event, document.createEventObject())
}
}
}
export { MegaDropdown }

90
resources/assets/vendor/js/pace.js vendored Normal file
View file

@ -0,0 +1,90 @@
window.paceOptions = { startOnPageLoad: false }
import * as Pace from 'pace-js/pace.js'
function appendStylesheets() {
if (document.getElementById('pace-js-stylesheets')) return
const style = document.createElement('style')
style.type = 'text/css'
style.id = 'pace-js-stylesheets'
style.innerHTML = `
.pace {
display: block !important;
}
.page-loader {
display: none;
position: fixed;
height: 2px;
overflow: hidden;
top: 0;
left: 0;
right: 0;
z-index: 999999;
}
.page-loader div {
position: absolute;
top: 0;
bottom: 0;
transform: translate3d(0, 0, 0);
}
.pace-running:not(.pace-done) .page-loader {
display: block;
}
.pace-running:not(.pace-done) .page-loader div {
animation-duration: 1.2s;
animation-name: pageLoaderAnimation;
animation-iteration-count: infinite;
animation-timing-function: ease-in-out;
}
.turbolinks-progress-bar {
visibility: hidden !important;
}
[dir=rtl] .pace-running:not(.pace-done) .page-loader div,
[dir=rtl].pace-running:not(.pace-done) .page-loader div {
animation-name: pageLoaderAnimationRTL;
}
@-webkit-keyframes pageLoaderAnimation {
0% { right: 100%; left: 0; }
40% { right: 0; left: 0; }
60% { left: 0; right: 0; }
100% { left: 100%; right: 0; }
}
@keyframes pageLoaderAnimation {
0% { right: 100%; left: 0; }
40% { right: 0; left: 0; }
60% { left: 0; right: 0; }
100% { left: 100%; right: 0; }
}
@-webkit-keyframes pageLoaderAnimationRTL {
0% { left: 100%; right: 0; }
40% { left: 0; right: 0; }
60% { right: 0; left: 0; }
100% { right: 100%; left: 0; }
}
@keyframes pageLoaderAnimationRTL {
0% { left: 100%; right: 0; }
40% { left: 0; right: 0; }
60% { right: 0; left: 0; }
100% { right: 100%; left: 0; }
}
`
document.querySelector('head').appendChild(style)
}
appendStylesheets()
Pace.start()
// Ensure that Pace.js will be hidden on page loaded
function hidePaceLoader() {
setTimeout(function() {
Pace.stop()
}, 3000)
}
if (document.readyState === 'complete') hidePaceLoader()
else document.addEventListener('DOMContentLoaded', hidePaceLoader)

12
resources/assets/vendor/js/polyfills.js vendored Normal file
View file

@ -0,0 +1,12 @@
import 'core-js/features/promise'
import 'core-js/features/array'
import 'core-js/features/string'
import 'core-js/features/object'
import 'core-js/features/set'
import 'core-js/features/map'
import 'core-js/features/weak-map'
import 'core-js/features/symbol'
import 'core-js/es/number/is-nan'
import 'core-js/es/math/trunc'
import 'url-polyfill'
import 'custom-event-polyfill'

789
resources/assets/vendor/js/sidenav.js vendored Normal file
View file

@ -0,0 +1,789 @@
const TRANSITION_EVENTS = ['transitionend','webkitTransitionEnd','oTransitionEnd']
const TRANSITION_PROPERTIES = ['transition', 'MozTransition', 'webkitTransition', 'WebkitTransition', 'OTransition']
const DELTA = 5
class SideNav {
constructor(el, options = {}, _PS = null) {
this._el = el
this._horizontal = options.orientation === 'horizontal'
this._animate = options.animate !== false && this._supportsTransitionEnd()
this._accordion = options.accordion !== false
this._closeChildren = Boolean(options.closeChildren)
this._showDropdownOnHover = Boolean(options.showDropdownOnHover)
this._rtl = document.documentElement.getAttribute('dir') === 'rtl' || document.body.getAttribute('dir') === 'rtl'
this._lastWidth = this._horizontal ? window.innerWidth : null
this._onOpen = options.onOpen || (() => {})
this._onOpened = options.onOpened || (() => {})
this._onClose = options.onClose || (() => {})
this._onClosed = options.onClosed || (() => {})
el.classList.add('sidenav')
el.classList[this._animate ? 'remove' : 'add']('sidenav-no-animation')
if (!this._horizontal) {
el.classList.add('sidenav-vertical')
el.classList.remove('sidenav-horizontal')
const PerfectScrollbarLib = _PS || window.PerfectScrollbar
if (PerfectScrollbarLib) {
this._scrollbar = new PerfectScrollbarLib(
el.querySelector('.sidenav-inner'),
{
suppressScrollX: true,
wheelPropagation: true
}
)
}
} else {
el.classList.add('sidenav-horizontal')
el.classList.remove('sidenav-vertical')
this._inner = el.querySelector('.sidenav-inner')
const container = this._inner.parentNode
this._prevBtn = el.querySelector('.sidenav-horizontal-prev')
if (!this._prevBtn) {
this._prevBtn = document.createElement('a')
this._prevBtn.href = '#'
this._prevBtn.className = 'sidenav-horizontal-prev'
container.appendChild(this._prevBtn)
}
this._wrapper = el.querySelector('.sidenav-horizontal-wrapper')
if (!this._wrapper) {
this._wrapper = document.createElement('div')
this._wrapper.className = 'sidenav-horizontal-wrapper'
this._wrapper.appendChild(this._inner)
container.appendChild(this._wrapper)
}
this._nextBtn = el.querySelector('.sidenav-horizontal-next')
if (!this._nextBtn) {
this._nextBtn = document.createElement('a')
this._nextBtn.href = '#'
this._nextBtn.className = 'sidenav-horizontal-next'
container.appendChild(this._nextBtn)
}
this._innerPosition = 0
this.update()
}
this._bindEvents()
// Link sidenav instance to element
el.sidenavInstance = this
}
open(el, closeChildren=this._closeChildren) {
const item = this._findUnopenedParent(this._getItem(el, true), closeChildren)
if (!item) return
const toggleLink = this._getLink(item, true)
this._promisify(this._onOpen, this, item, toggleLink, this._findMenu(item))
.then(() => {
if (!this._horizontal || !this._isRoot(item)) {
if (this._animate) {
window.requestAnimationFrame(() => this._toggleAnimation(true, item, false))
if (this._accordion) this._closeOther(item, closeChildren)
} else {
item.classList.add('open')
this._onOpened && this._onOpened(this, item, toggleLink, this._findMenu(item))
if (this._accordion) this._closeOther(item, closeChildren)
}
} else {
this._toggleDropdown(true, item, closeChildren)
this._onOpened && this._onOpened(this, item, toggleLink, this._findMenu(item))
}
})
.catch(() => {})
}
close(el, closeChildren=this._closeChildren, _autoClose=false) {
const item = this._getItem(el, true)
const toggleLink = this._getLink(el, true)
if (!item.classList.contains('open') || item.classList.contains('disabled')) return
this._promisify(this._onClose, this, item, toggleLink, this._findMenu(item), _autoClose)
.then(() => {
if (!this._horizontal || !this._isRoot(item)) {
if (this._animate) {
window.requestAnimationFrame(() => this._toggleAnimation(false, item, closeChildren))
} else {
item.classList.remove('open')
if (closeChildren) {
const opened = item.querySelectorAll('.sidenav-item.open')
for (let i = 0, l = opened.length; i < l; i++) opened[i].classList.remove('open')
}
this._onClosed && this._onClosed(this, item, toggleLink, this._findMenu(item))
}
} else {
this._toggleDropdown(false, item, closeChildren)
this._onClosed && this._onClosed(this, item, toggleLink, this._findMenu(item))
}
})
.catch(() => {})
}
toggle(el, closeChildren=this._closeChildren) {
const item = this._getItem(el, true)
if (item.classList.contains('open')) this.close(item, closeChildren)
else this.open(item, closeChildren)
}
closeAll(closeChildren=this._closeChildren) {
const opened = this._el.querySelectorAll('.sidenav-inner > .sidenav-item.open')
for (let i = 0, l = opened.length; i < l; i++) this.close(opened[i], closeChildren)
}
setActive(el, active, openTree=true, deactivateOthers=true) {
let item = this._getItem(el, false)
if (active && deactivateOthers) {
const activeItems = this._el.querySelectorAll('.sidenav-inner .sidenav-item.active')
for (let i = 0, l = activeItems.length; i < l; i++) activeItems[i].classList.remove('active')
}
if (active && openTree) {
const parentItem = this._findParent(item, 'sidenav-item', false)
parentItem && this.open(parentItem)
}
while (item) {
item.classList[active ? 'add' : 'remove']('active')
item = this._findParent(item, 'sidenav-item', false)
}
}
setDisabled(el, disabled) {
this._getItem(el, false).classList[disabled ? 'add' : 'remove']('disabled')
}
isActive(el) {
return this._getItem(el, false).classList.contains('active')
}
isOpened(el) {
return this._getItem(el, false).classList.contains('open')
}
isDisabled(el) {
return this._getItem(el, false).classList.contains('disabled')
}
update() {
if (!this._horizontal) {
if (this._scrollbar) {
this._scrollbar.update()
}
} else {
this.closeAll()
const wrapperWidth = Math.round(this._wrapper.getBoundingClientRect().width)
const innerWidth = this._innerWidth
let position = this._innerPosition
if ((wrapperWidth - position) > innerWidth) {
position = wrapperWidth - innerWidth
if (position > 0) position = 0
this._innerPosition = position
}
this._updateSlider(wrapperWidth, innerWidth, position)
}
}
_updateSlider(wrapperWidth = null, innerWidth = null, position = null) {
const _wrapperWidth = wrapperWidth !== null ? wrapperWidth : Math.round(this._wrapper.getBoundingClientRect().width)
const _innerWidth = innerWidth !== null ? innerWidth : this._innerWidth
const _position = position !== null ? position : this._innerPosition
if (_position === 0) this._prevBtn.classList.add('disabled')
else this._prevBtn.classList.remove('disabled')
if (_innerWidth + _position <= _wrapperWidth) this._nextBtn.classList.add('disabled')
else this._nextBtn.classList.remove('disabled')
}
_promisify(fn, ...args) {
const result = fn(...args)
return result instanceof Promise
? result
: (result === false ? Promise.reject() : Promise.resolve())
}
destroy() {
if (!this._el) return
this._unbindEvents()
const items = this._el.querySelectorAll('.sidenav-item')
for (let i = 0, l = items.length; i < l; i++) {
this._unbindAnimationEndEvent(items[i])
items[i].classList.remove('sidenav-item-animating')
items[i].classList.remove('open')
items[i].style.overflow = null
items[i].style.height = null
}
const menus = this._el.querySelectorAll('.sidenav-menu')
for (let i2 = 0, l2 = menus.length; i2 < l2; i2++) {
menus[i2].style.marginRight = null
menus[i2].style.marginLeft = null
}
this._el.classList.remove('sidenav-no-animation')
if (this._wrapper) {
this._prevBtn.parentNode.removeChild(this._prevBtn)
this._nextBtn.parentNode.removeChild(this._nextBtn)
this._wrapper.parentNode.insertBefore(this._inner, this._wrapper)
this._wrapper.parentNode.removeChild(this._wrapper)
this._inner.style.marginLeft = null
this._inner.style.marginRight = null
}
this._el.sidenavInstance = null
delete this._el.sidenavInstance
this._el = null
this._horizontal = null
this._animate = null
this._accordion = null
this._closeChildren = null
this._showDropdownOnHover = null
this._rtl = null
this._onOpen = null
this._onOpened = null
this._onClose = null
this._onClosed = null
if (this._scrollbar) {
this._scrollbar.destroy()
this._scrollbar = null
}
this._inner = null
this._prevBtn = null
this._wrapper = null
this._nextBtn = null
}
_getLink(el, toggle) {
let found = []
const selector = toggle ? 'sidenav-toggle' : 'sidenav-link'
if (el.classList.contains(selector)) found = [el]
else if (el.classList.contains('sidenav-item')) found = this._findChild(el, [selector])
if (!found.length) throw new Error(`\`${selector}\` element not found.`)
return found[0]
}
_getItem(el, toggle) {
let item = null
const selector = toggle ? 'sidenav-toggle' : 'sidenav-link'
if (el.classList.contains('sidenav-item')) {
if (this._findChild(el, [selector]).length) item = el
} else if (el.classList.contains(selector)) {
item = el.parentNode.classList.contains('sidenav-item') ? el.parentNode : null
}
if (!item) {
throw new Error(`${toggle ? 'Toggable ' : ''}\`.sidenav-item\` element not found.`)
}
return item
}
_findUnopenedParent(item, closeChildren) {
let tree = []
let parentItem = null
while (item) {
if (item.classList.contains('disabled')) {
parentItem = null
tree = []
} else {
if (!item.classList.contains('open')) parentItem = item
tree.push(item)
}
item = this._findParent(item, 'sidenav-item', false)
}
if (!parentItem) return null
if (tree.length === 1) return parentItem
tree = tree.slice(0, tree.indexOf(parentItem))
for (let i = 0, l = tree.length; i < l; i++) {
tree[i].classList.add('open')
if (this._accordion) {
let openedItems = this._findChild(tree[i].parentNode, ['sidenav-item', 'open'])
for (let j = 0, k = openedItems.length; j < k; j++) {
if (openedItems[j] === tree[i]) continue
openedItems[j].classList.remove('open')
if (closeChildren) {
let openedChildren = openedItems[j].querySelectorAll('.sidenav-item.open')
for (let x = 0, z = openedChildren.length; x < z; x++) {
openedChildren[x].classList.remove('open')
}
}
}
}
}
return parentItem
}
_closeOther(item, closeChildren) {
const opened = this._findChild(item.parentNode, ['sidenav-item', 'open'])
for (let i = 0, l = opened.length; i < l; i++) {
if (opened[i] !== item) this.close(opened[i], closeChildren, true)
}
}
_toggleAnimation(open, item, closeChildren) {
const toggleLink = this._getLink(item, true)
const menu = this._findMenu(item)
this._unbindAnimationEndEvent(item)
const linkHeight = Math.round(toggleLink.getBoundingClientRect().height)
item.style.overflow = 'hidden'
const clearItemStyle = () => {
item.classList.remove('sidenav-item-animating')
item.classList.remove('sidenav-item-closing')
item.style.overflow = null
item.style.height = null
if (!this._horizontal) this.update()
}
if (open) {
item.style.height = `${linkHeight}px`
item.classList.add('sidenav-item-animating')
item.classList.add('open')
this._bindAnimationEndEvent(item, () => {
clearItemStyle()
this._onOpened && this._onOpened(this, item, toggleLink, menu)
})
setTimeout(() => item.style.height = `${linkHeight + Math.round(menu.getBoundingClientRect().height)}px`, 50)
} else {
item.style.height = `${linkHeight + Math.round(menu.getBoundingClientRect().height)}px`
item.classList.add('sidenav-item-animating')
item.classList.add('sidenav-item-closing')
this._bindAnimationEndEvent(item, () => {
item.classList.remove('open')
clearItemStyle()
if (closeChildren) {
const opened = item.querySelectorAll('.sidenav-item.open')
for (let i = 0, l = opened.length; i < l; i++) opened[i].classList.remove('open')
}
this._onClosed && this._onClosed(this, item, toggleLink, menu)
})
setTimeout(() => item.style.height = `${linkHeight}px`, 50)
}
}
_toggleDropdown(show, item, closeChildren) {
const menu = this._findMenu(item)
if (show) {
const wrapperWidth = Math.round(this._wrapper.getBoundingClientRect().width)
const position = this._innerPosition
const itemOffset = this._getItemOffset(item)
const itemWidth = Math.round(item.getBoundingClientRect().width)
if ((itemOffset - DELTA) <= (-1 * position)) {
this._innerPosition = -1 * itemOffset
} else if ((itemOffset + position + itemWidth + DELTA) >= wrapperWidth) {
if (itemWidth > wrapperWidth) {
this._innerPosition = -1 * itemOffset
} else {
this._innerPosition = -1 * (itemOffset + itemWidth - wrapperWidth)
}
}
item.classList.add('open')
const menuWidth = Math.round(menu.getBoundingClientRect().width)
if ((itemOffset + this._innerPosition + menuWidth) > wrapperWidth && menuWidth < wrapperWidth && menuWidth > itemWidth) {
menu.style[this._rtl ? 'marginRight' : 'marginLeft'] = `-${menuWidth - itemWidth}px`
}
this._closeOther(item, closeChildren)
this._updateSlider()
} else {
const toggle = this._findChild(item, ['sidenav-toggle'])
toggle.length && toggle[0].removeAttribute('data-hover', 'true')
item.classList.remove('open')
menu.style[this._rtl ? 'marginRight' : 'marginLeft'] = null
if (closeChildren) {
const opened = menu.querySelectorAll('.sidenav-item.open')
for (let i = 0, l = opened.length; i < l; i++) opened[i].classList.remove('open')
}
}
}
_slide(direction) {
const wrapperWidth = Math.round(this._wrapper.getBoundingClientRect().width)
const innerWidth = this._innerWidth
let newPosition
if (direction === 'next') {
newPosition = this._getSlideNextPos()
if (innerWidth + newPosition < wrapperWidth) {
newPosition = wrapperWidth - innerWidth
}
} else {
newPosition = this._getSlidePrevPos()
if (newPosition > 0) newPosition = 0
}
this._innerPosition = newPosition
this.update()
}
_getSlideNextPos() {
const wrapperWidth = Math.round(this._wrapper.getBoundingClientRect().width)
const position = this._innerPosition
let curItem = this._inner.childNodes[0]
let left = 0
while(curItem) {
if (curItem.tagName) {
let curItemWidth = Math.round(curItem.getBoundingClientRect().width)
if ((left + position - DELTA) <= wrapperWidth && (left + position + curItemWidth + DELTA) >= wrapperWidth) {
if (curItemWidth > wrapperWidth && left === (-1 * position)) left += curItemWidth
break
}
left += curItemWidth
}
curItem = curItem.nextSibling
}
return -1 * left
}
_getSlidePrevPos() {
const wrapperWidth = Math.round(this._wrapper.getBoundingClientRect().width)
const position = this._innerPosition
let curItem = this._inner.childNodes[0]
let left = 0
while(curItem) {
if (curItem.tagName) {
let curItemWidth = Math.round(curItem.getBoundingClientRect().width)
if ((left - DELTA) <= (-1 * position) && (left + curItemWidth + DELTA) >= (-1 * position)) {
if (curItemWidth <= wrapperWidth) left = left + curItemWidth - wrapperWidth
break
}
left += curItemWidth
}
curItem = curItem.nextSibling
}
return -1 * left
}
_getItemOffset(item) {
let curItem = this._inner.childNodes[0]
let left = 0
while(curItem !== item) {
if (curItem.tagName) {
left += Math.round(curItem.getBoundingClientRect().width)
}
curItem = curItem.nextSibling
}
return left
}
_bindAnimationEndEvent(el, handler) {
const cb = e => {
if (e.target !== el) return
this._unbindAnimationEndEvent(el)
handler(e)
}
let duration = window.getComputedStyle(el).transitionDuration
duration = parseFloat(duration) * (duration.indexOf('ms') !== -1 ? 1 : 1000)
el._sideNavAnimationEndEventCb = cb
TRANSITION_EVENTS.forEach(ev => el.addEventListener(ev, el._sideNavAnimationEndEventCb, false))
el._sideNavAnimationEndEventTimeout = setTimeout(function() {
cb({ target: el })
}, duration + 50)
}
_unbindAnimationEndEvent(el) {
const cb = el._sideNavAnimationEndEventCb
if (el._sideNavAnimationEndEventTimeout) {
clearTimeout(el._sideNavAnimationEndEventTimeout)
el._sideNavAnimationEndEventTimeout = null
}
if (!cb) return
TRANSITION_EVENTS.forEach(ev => el.removeEventListener(ev, cb, false))
el._sideNavAnimationEndEventCb = null
}
_bindEvents() {
this._evntElClick = (e) => {
const toggleLink = e.target.classList.contains('sidenav-toggle') ?
e.target :
this._findParent(e.target, 'sidenav-toggle', false)
if (toggleLink) {
e.preventDefault()
if (toggleLink.getAttribute('data-hover') !== 'true') {
this.toggle(toggleLink)
}
}
}
this._el.addEventListener('click', this._evntElClick)
this._evntWindowResize = () => {
if (!this._horizontal) {
this.update()
} else if (this._lastWidth !== window.innerWidth) {
this._lastWidth = window.innerWidth
this.update()
}
}
window.addEventListener('resize', this._evntWindowResize)
if (this._horizontal) {
this._evntPrevBtnClick = (e) => {
e.preventDefault()
if (this._prevBtn.classList.contains('disabled')) return
this._slide('prev')
}
this._prevBtn.addEventListener('click', this._evntPrevBtnClick)
this._evntNextBtnClick = (e) => {
e.preventDefault()
if (this._nextBtn.classList.contains('disabled')) return
this._slide('next')
}
this._nextBtn.addEventListener('click', this._evntNextBtnClick)
this._evntBodyClick = (e) => {
if (!this._inner.contains(e.target) && this._el.querySelectorAll('.sidenav-inner > .sidenav-item.open').length) this.closeAll()
}
document.body.addEventListener('click', this._evntBodyClick)
this._evntHorizontalElClick = (e) => {
const link = e.target.classList.contains('sidenav-link') ? e.target : this._findParent(e.target, 'sidenav-link', false)
if (link && !link.classList.contains('sidenav-toggle')) this.closeAll()
}
this._el.addEventListener('click', this._evntHorizontalElClick)
if (this._showDropdownOnHover) {
this._evntInnerMousemove = (e) => {
let curItem = this._findParent(e.target, 'sidenav-item', false)
let item = null
while (curItem) {
item = curItem
curItem = this._findParent(curItem, 'sidenav-item', false)
}
if (item && !item.classList.contains('open')) {
const toggle = this._findChild(item, ['sidenav-toggle'])
if (toggle.length) {
toggle[0].setAttribute('data-hover', 'true')
this.open(toggle[0], this._closeChildren, true)
setTimeout(() => {
toggle[0].removeAttribute('data-hover')
}, 500)
}
}
}
this._inner.addEventListener('mousemove', this._evntInnerMousemove)
this._evntInnerMouseleave = (e) => {
this.closeAll()
}
this._inner.addEventListener('mouseleave', this._evntInnerMouseleave)
}
}
}
_unbindEvents() {
if (this._evntElClick) {
this._el.removeEventListener('click', this._evntElClick)
this._evntElClick = null
}
if (this._evntWindowResize) {
window.removeEventListener('resize', this._evntWindowResize)
this._evntWindowResize = null
}
if (this._evntPrevBtnClick) {
this._prevBtn.removeEventListener('click', this._evntPrevBtnClick)
this._evntPrevBtnClick = null
}
if (this._evntNextBtnClick) {
this._nextBtn.removeEventListener('click', this._evntNextBtnClick)
this._evntNextBtnClick = null
}
if (this._evntBodyClick) {
document.body.removeEventListener('click', this._evntBodyClick)
this._evntBodyClick = null
}
if (this._evntHorizontalElClick) {
this._el.removeEventListener('click', this._evntHorizontalElClick)
this._evntHorizontalElClick = null
}
if (this._evntInnerMousemove) {
this._inner.removeEventListener('mousemove', this._evntInnerMousemove)
this._evntInnerMousemove = null
}
if (this._evntInnerMouseleave) {
this._inner.removeEventListener('mouseleave', this._evntInnerMouseleave)
this._evntInnerMouseleave = null
}
}
_findMenu(item) {
let curEl = item.childNodes[0]
let menu = null
while (curEl && !menu) {
if (curEl.classList && curEl.classList.contains('sidenav-menu')) menu = curEl
curEl = curEl.nextSibling
}
if (!menu) throw new Error('Cannot find `.sidenav-menu` element for the current `.sidenav-toggle`')
return menu
}
_isRoot(item) {
return !this._findParent(item, 'sidenav-item', false)
}
_findParent(el, cls, throwError = true) {
if (el.tagName.toUpperCase() === 'BODY') return null
el = el.parentNode
while (el && el.tagName.toUpperCase() !== 'BODY' && !el.classList.contains(cls)) {
el = el.parentNode
}
el = el && el.tagName.toUpperCase() !== 'BODY' ? el : null
if (!el && throwError) throw new Error(`Cannot find \`.${cls}\` parent element`)
return el
}
_findChild(el, cls) {
const items = el.childNodes
const found = []
for (let i = 0, l = items.length; i < l; i++) {
if (items[i].classList) {
let passed = 0
for (let j = 0; j < cls.length; j++) {
if (items[i].classList.contains(cls[j])) passed++
}
if (cls.length === passed) found.push(items[i])
}
}
return found
}
_supportsTransitionEnd() {
if (window.QUnit) {
return false
}
const el = document.body || document.documentElement
let result = false
TRANSITION_PROPERTIES.forEach(evnt => {
if (typeof el.style[evnt] !== 'undefined') result = true
})
return result
}
get _innerWidth() {
const items = this._inner.childNodes
let width = 0
for (let i = 0, l = items.length; i < l; i++) {
if (items[i].tagName) {
width += Math.round(items[i].getBoundingClientRect().width)
}
}
return width
}
get _innerPosition() {
return parseInt(this._inner.style[this._rtl ? 'marginRight' : 'marginLeft'] || '0px')
}
set _innerPosition(value) {
this._inner.style[this._rtl ? 'marginRight' : 'marginLeft'] = `${value}px`
return value
}
}
export { SideNav }

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1 @@
@import "~animate.css/animate";

View file

@ -0,0 +1,3 @@
import * as autosize from 'autosize/dist/autosize.js'
export { autosize }

View file

@ -0,0 +1 @@
import 'block-ui/jquery.blockUI.js'

View file

@ -0,0 +1 @@
import 'blueimp-gallery/js/blueimp-gallery-fullscreen.js'

View file

@ -0,0 +1 @@
import 'blueimp-gallery/js/blueimp-gallery-indicator.js'

View file

@ -0,0 +1 @@
@import '~blueimp-gallery/css/blueimp-gallery-indicator';

View file

@ -0,0 +1 @@
import 'blueimp-gallery/js/blueimp-gallery-video.js'

View file

@ -0,0 +1,15 @@
@import '~blueimp-gallery/css/blueimp-gallery-video';
.blueimp-gallery > .slides > .slide {
> .video-content > a {
// background-image: url(img/video-play.png);
}
> .video-loading > a {
// background-image: url(img/loading.gif);
}
body:last-child & > .video-content:not(.video-loading) > a {
// background-image: url(img/video-play.svg);
}
}

View file

@ -0,0 +1 @@
import 'blueimp-gallery/js/blueimp-gallery-vimeo.js'

View file

@ -0,0 +1 @@
import 'blueimp-gallery/js/blueimp-gallery-youtube.js'

View file

@ -0,0 +1,32 @@
import * as blueimpGallery from 'blueimp-gallery/js/blueimp-gallery.js'
if ($('html').attr('dir') === 'rtl' || $('body').attr('dir') === 'rtl') {
const galleryTranslateX = blueimpGallery.prototype.translateX
blueimpGallery.prototype.translateX = function (index, x, speed) {
const newX = this.touchStart && this.touchStart.x ? x : -1 * x
galleryTranslateX.call(this, index, newX, 0, speed)
}
blueimpGallery.prototype.positionSlide = function (index) {
const slide = this.slides[index]
slide.style.width = `${this.slideWidth}px`
if (this.support.transform) {
const moveTo = this.index > index
? (-1 * this.slideWidth)
: (this.index < index ? this.slideWidth : 0)
slide.style.right = `${-1 * index * this.slideWidth}px`
this.move(index, moveTo, 0)
}
}
blueimpGallery.prototype.ontouchstart = function() {}
blueimpGallery.prototype.ontouchmove = function() {}
blueimpGallery.prototype.ontouchend = function() {}
blueimpGallery.prototype.ontouchcancel = function() {}
}
export { blueimpGallery }

View file

@ -0,0 +1,109 @@
@import '../../sass/_custom-variables/libs';
@import '~blueimp-gallery/css/blueimp-gallery';
.blueimp-gallery > .slides > .slide-loading {
// background-image: url(img/loading.gif);
}
.blueimp-gallery > .slides > .slide-error {
// background-image: url(img/error.png);
}
.blueimp-gallery > .play-pause {
// background-image: url(img/play-pause.png);
}
body:last-child .blueimp-gallery > .slides > .slide-error {
// background-image: url(img/error.svg);
}
body:last-child .blueimp-gallery > .play-pause {
// background-image: url(img/play-pause.svg);
}
.blueimp-gallery {
a.close,
a.prev,
a.next {
color: #fff !important;
}
.prev,
.next {
border-color: transparent;
}
}
.blueimp-gallery a.close {
&:hover,
&:focus {
opacity: .5 !important;
}
}
.blueimp-gallery-carousel {
box-shadow: none;
}
@include feature-rtl(false) {
.blueimp-gallery {
direction: rtl;
}
.blueimp-gallery > .slides > .slide {
float: right;
}
.blueimp-gallery > .prev,
.blueimp-gallery > .next {
left: auto;
right: 15px;
}
.blueimp-gallery > .next {
right: auto;
left: 15px;
}
.blueimp-gallery > .play-pause {
transform: scaleX(-1);
}
.blueimp-gallery > .close,
.blueimp-gallery > .title {
left: auto;
right: 15px;
margin-right: 0;
margin-left: 40px;
}
.blueimp-gallery > .close {
left: 15px;
right: auto;
margin: -15px;
}
.blueimp-gallery > .play-pause {
right: auto;
left: 15px;
}
}
@if $enable-light-style {
.light-style {
@import "../../sass/_appwork/include";
.blueimp-gallery:not(.blueimp-gallery-carousel) {
z-index: $zindex-modal-top;
}
}
}
@if $enable-material-style {
.material-style {
@import "../../sass/_appwork/include-material";
.blueimp-gallery:not(.blueimp-gallery-carousel) {
z-index: $zindex-modal-top;
}
}
}
@if $enable-dark-style {
.dark-style {
@import "../../sass/_appwork/include-dark";
.blueimp-gallery:not(.blueimp-gallery-carousel) {
z-index: $zindex-modal-top;
}
}
}

View file

@ -0,0 +1 @@
import 'blueimp-gallery/js/jquery.blueimp-gallery.js'

View file

@ -0,0 +1,3 @@
import * as bootbox from 'bootbox/bootbox.all.js'
export { bootbox }

View file

@ -0,0 +1,69 @@
@mixin bs-datepicker-theme($background, $color: null) {
$color: if($color, $color, yiq($background));
$range-bg: rgba-to-hex(rgba($background, .15), #fff);
$range-color: yiq($range-bg);
.datepicker table tr td {
&.active,
&.active.highlighted,
&.active.today,
span.active,
span.active.disabled,
&.range-start,
&.range-end {
background: $background !important;
color: $color !important;
}
&.range,
&.range.highlighted,
&.range.today {
background: $range-bg !important;
color: $range-color !important;
&.focused {
background: darken($range-bg, 6%) !important;
}
&.disabled {
background: transparentize($range-bg, .5) !important;
color: transparentize($range-color, .5) !important;
}
}
}
}
@mixin bs-datepicker-dark-theme($background, $color: null) {
$color: if($color, $color, yiq($background));
$range-bg: rgba-to-hex(rgba($background, .15), #383b40);
$range-color: yiq($range-bg);
.datepicker table tr td {
&.active,
&.active.highlighted,
&.active.today,
span.active,
span.active.disabled,
&.range-start,
&.range-end {
background: $background !important;
color: $color !important;
}
&.range,
&.range.highlighted,
&.range.today {
background: $range-bg !important;
color: $range-color !important;
&.focused {
background: darken($range-bg, 6%) !important;
}
&.disabled {
background: transparentize($range-bg, .5) !important;
color: transparentize($range-color, .5) !important;
}
}
}
}

View file

@ -0,0 +1 @@
import 'bootstrap-datepicker/dist/js/bootstrap-datepicker.js'

View file

@ -0,0 +1,546 @@
@import '../../sass/_custom-variables/libs';
$datepicker-today-bg: #fff4df !default;
$datepicker-highlighted-bg: #eff8fc !default;
$datepicker-today-bg-dark: #73654C !default;
$datepicker-highlighted-bg-dark: #45565F !default;
$datepicker-arrow-size: .5rem !default;
.datepicker {
direction: ltr;
&.datepicker-rtl {
direction: rtl;
table tr td span {
float: right;
}
}
@include feature-rtl {
direction: rtl;
}
.next,
.prev {
position: relative;
color: transparent !important;
}
.next::after,
.prev::after {
content: "";
position: absolute;
display: block;
width: $datepicker-arrow-size;
height: $datepicker-arrow-size;
border-style: solid;
border-radius: 0;
top: 50%;
left: 50%;
transform: rotate(-45deg);
transform-origin: left;
}
.next::after {
border-width: 0 1px 1px 0;
margin-left: -$datepicker-arrow-size / 2;
@include feature-rtl {
margin-left: 0;
border-width: 1px 0 0 1px;
transform: rotate(-45deg);
}
}
.prev::after {
border-width: 1px 0 0 1px;
@include feature-rtl {
margin-left: -$datepicker-arrow-size / 2;
border-width: 0 1px 1px 0;
transform: rotate(-45deg);
}
}
}
.datepicker-dropdown {
top: 0;
left: 0;
padding: .25rem;
}
.datepicker table {
margin: 0;
user-select: none;
}
.datepicker table tr td,
.datepicker table tr th {
width: 2rem;
height: 2rem;
border: none;
text-align: center;
line-height: calc(#{"2rem - 2px"});
}
.datepicker table tr td {
&.day:hover,
&.focused {
cursor: pointer;
}
&.disabled,
&.disabled:hover {
background: none;
cursor: default;
}
&.highlighted {
border-radius: 0 !important;
}
&.range {
border-radius: 0 !important;
}
&.range-start:not(.range-end) {
@include feature-ltr {
border-top-right-radius: 0 !important;
border-bottom-right-radius: 0 !important;
}
@include feature-rtl {
border-top-left-radius: 0 !important;
border-bottom-left-radius: 0 !important;
}
}
&.range-end:not(.range-start) {
@include feature-ltr {
border-top-left-radius: 0 !important;
border-bottom-left-radius: 0 !important;
}
@include feature-rtl {
border-top-right-radius: 0 !important;
border-bottom-right-radius: 0 !important;
}
}
&.selected,
&.selected:hover,
&.selected.highlighted {
color: #fff;
}
}
.light-style .datepicker table tr td,
.material-style .datepicker table tr td {
&.highlighted { background: $datepicker-highlighted-bg; }
&.highlighted.focused { background: darken($datepicker-highlighted-bg, 6%); }
&.today { background: $datepicker-today-bg !important; }
&.today.focused { background: darken($datepicker-today-bg, 6%) !important; }
&.today.disabled, &.today.disabled:active { background: $datepicker-today-bg !important; }
&.range.highlighted {
$range-highlighted-bg: darken($datepicker-highlighted-bg, 3%);
background: $range-highlighted-bg;
&.focused { background: darken($range-highlighted-bg, 6%); }
}
&.range.today {
$range-today-bg: darken($datepicker-today-bg, 3%) !important;
background: $range-today-bg !important;
&.disabled, &.disabled:active { background: $range-today-bg !important; }
}
}
.dark-style .datepicker table tr td {
&.highlighted { background: $datepicker-highlighted-bg-dark; }
&.highlighted.focused { background: lighten($datepicker-highlighted-bg-dark, 6%); }
&.today { background: $datepicker-today-bg-dark !important; color: #fff !important; }
&.today.focused { background: lighten($datepicker-today-bg-dark, 6%) !important; }
&.today.disabled, &.today.disabled:active { background: $datepicker-today-bg-dark !important; }
&.range.highlighted {
$range-highlighted-bg: lighten($datepicker-highlighted-bg-dark, 3%);
background: $range-highlighted-bg;
&.focused { background: lighten($range-highlighted-bg, 6%); }
}
&.range.today {
$range-today-bg: lighten($datepicker-today-bg-dark, 3%) !important;
background: $range-today-bg !important;
&.disabled, &.disabled:active { background: $range-today-bg !important; }
}
}
.datepicker table tr td span {
display: block;
float: left;
width: 3.375rem;
height: 3.375rem;
line-height: 3.375rem;
cursor: pointer;
&.disabled,
&.disabled:hover {
background: none;
cursor: default;
}
@include feature-rtl {
float: right;
}
}
.table-striped .datepicker table tr td,
.table-striped .datepicker table tr th {
background-color: transparent;
}
.datepicker .datepicker-switch,
.datepicker .prev,
.datepicker .next,
.datepicker tfoot tr th {
cursor: pointer;
}
// Basic styling for calendar-week cells
.datepicker .cw {
padding: 0 .125rem;
width: .75rem;
vertical-align: middle;
font-size: .625rem;
}
.datepicker-months table,
.datepicker-years table,
.datepicker-decades table,
.datepicker-centuries table {
width: (3.375rem * 3) + 2.625rem;
td {
padding: 0 0 1.25rem 1.25rem;
@include feature-rtl {
padding: 0 1.25rem 1.25rem 0;
}
}
}
.input-group.date .input-group-addon {
cursor: pointer;
}
.input-daterange input {
text-align: center;
}
@if $enable-light-style {
.light-style {
@import "../../sass/_appwork/include";
$datepicker-hover-bg : $gray-50;
$datepicker-old-new-color : $text-light;
.datepicker-dropdown {
z-index: $zindex-popover !important;
}
.datepicker {
border-radius: $border-radius;
}
.datepicker table tr td,
.datepicker table tr th {
border-radius: $border-radius;
}
.datepicker table tr td {
&.old,
&.new {
color: $datepicker-old-new-color;
}
&.day:hover,
&.focused {
background: $datepicker-hover-bg;
}
&.disabled,
&.disabled:hover {
background: none;
color: $datepicker-old-new-color;
}
&.highlighted.disabled,
&.highlighted.disabled:active {
color: $datepicker-old-new-color;
}
&.today.disabled,
&.today.disabled:active {
color: $datepicker-old-new-color;
}
}
.datepicker table tr td span {
border-radius: $border-radius;
&:hover,
&.focused {
background: $datepicker-hover-bg;
}
&.disabled,
&.disabled:hover {
color: $datepicker-old-new-color;
}
&.old,
&.new {
color: $datepicker-old-new-color;
}
}
.datepicker .next,
.datepicker .prev {
&::after {
color: $text-light;
}
&:hover::after {
color: $body-color;
}
}
.datepicker .datepicker-switch:hover,
.datepicker tfoot tr th:hover {
background: $datepicker-hover-bg;
}
.datepicker tfoot tr th,
.datepicker .datepicker-switch {
font-weight: $font-weight-semibold;
}
.datepicker .cw,
.datepicker .dow {
color: $datepicker-old-new-color;
font-size: $font-size-sm;
font-weight: $font-weight-semibold;
background: $gray-50;
border-radius: 0 !important;
}
}
}
@if $enable-material-style {
.material-style {
@import "../../sass/_appwork/include-material";
$datepicker-hover-bg : $gray-50;
$datepicker-old-new-color : $text-light;
.datepicker-dropdown {
z-index: $zindex-popover !important;
animation: none !important;
}
.datepicker {
border-radius: $border-radius;
}
.datepicker table tr td,
.datepicker table tr th,
.datepicker table tr td span {
border-radius: 99rem;
}
.datepicker table tr td.day,
.datepicker tfoot tr th {
font-size: $font-size-sm;
font-weight: $font-weight-semibold;
}
.datepicker table tr td {
&.old,
&.new {
color: $datepicker-old-new-color;
}
&.day:hover,
&.focused {
background: $datepicker-hover-bg;
}
&.disabled,
&.disabled:hover {
background: none;
color: $datepicker-old-new-color;
}
&.highlighted.disabled,
&.highlighted.disabled:active {
color: $datepicker-old-new-color;
}
&.today.disabled,
&.today.disabled:active {
color: $datepicker-old-new-color;
}
}
.datepicker table tr td span {
&:hover,
&.focused {
background: $datepicker-hover-bg;
}
&.disabled,
&.disabled:hover {
color: $datepicker-old-new-color;
}
&.old,
&.new {
color: $datepicker-old-new-color;
}
}
.datepicker .next,
.datepicker .prev {
&::after {
color: $text-light;
}
&:hover::after {
color: $body-color;
}
}
.datepicker .datepicker-switch:hover,
.datepicker tfoot tr th:hover {
background: $datepicker-hover-bg;
}
.datepicker tfoot tr th,
.datepicker .datepicker-switch {
font-weight: $font-weight-semibold;
}
.datepicker .cw,
.datepicker .dow {
color: $datepicker-old-new-color;
font-size: $font-size-sm;
font-weight: $font-weight-semibold;
background: $gray-50;
border-radius: 0 !important;
}
}
}
@if $enable-dark-style {
.dark-style {
@import "../../sass/_appwork/include-dark";
$datepicker-hover-bg: $gray-100;
$datepicker-old-new-color: $text-light;
.datepicker-dropdown {
z-index: $zindex-popover !important;
}
.datepicker {
border-radius: $border-radius;
}
.datepicker table tr td,
.datepicker table tr th {
border-radius: $border-radius;
}
.datepicker table tr td {
&.old,
&.new {
color: $datepicker-old-new-color;
}
&.day:hover,
&.focused {
background: $datepicker-hover-bg;
}
&.disabled,
&.disabled:hover {
background: none;
color: $datepicker-old-new-color;
}
&.highlighted.disabled,
&.highlighted.disabled:active {
color: $datepicker-old-new-color;
}
&.today.disabled,
&.today.disabled:active {
color: $datepicker-old-new-color;
}
}
.datepicker table tr td span {
border-radius: $border-radius;
&:hover,
&.focused {
background: $datepicker-hover-bg;
}
&.disabled,
&.disabled:hover {
color: $datepicker-old-new-color;
}
&.old,
&.new {
color: $datepicker-old-new-color;
}
}
.datepicker .next,
.datepicker .prev {
&::after {
color: $text-light;
}
&:hover::after {
color: $body-color;
}
}
.datepicker .datepicker-switch:hover,
.datepicker tfoot tr th:hover {
background: $datepicker-hover-bg;
}
.datepicker tfoot tr th,
.datepicker .datepicker-switch {
font-weight: $font-weight-semibold;
}
.datepicker .cw,
.datepicker .dow {
color: $gray-500;
font-size: $font-size-sm;
font-weight: $font-weight-semibold;
background: $gray-100;
border-radius: 0 !important;
}
}
}

View file

@ -0,0 +1,49 @@
@mixin bs-daterangepicker-theme($background, $color: null) {
$color: if($color, $color, yiq($background));
$higlighted-bg: rgba-to-hex(rgba($background, .15), #fff);
$higlighted-color: yiq($higlighted-bg);
.daterangepicker td.active {
background-color: $background !important;
color: $color !important;
}
.daterangepicker td.in-range:not(.start-date):not(.end-date):not(.off) {
background-color: $higlighted-bg !important;
color: $higlighted-color !important;
}
.daterangepicker .input-mini.active {
border-color: $background !important;
}
.ranges li.active {
background-color: $background !important;
color: $color !important;
}
}
@mixin bs-daterangepicker-dark-theme($background, $color: null) {
$color: if($color, $color, yiq($background));
$higlighted-bg: rgba-to-hex(rgba($background, .15), #383b40);
$higlighted-color: yiq($higlighted-bg);
.daterangepicker td.active {
background-color: $background !important;
color: $color !important;
}
.daterangepicker td.in-range:not(.start-date):not(.end-date):not(.off) {
background-color: $higlighted-bg !important;
color: $higlighted-color !important;
}
.daterangepicker .input-mini.active {
border-color: $background !important;
}
.ranges li.active {
background-color: $background !important;
color: $color !important;
}
}

View file

@ -0,0 +1,20 @@
import 'bootstrap-daterangepicker/daterangepicker.js'
// Monkey-patch to detect when weeks are shown
const fnDaterangepicker = $.fn.daterangepicker
$.fn.daterangepicker = function (options, callback) {
fnDaterangepicker.call(this, options, callback)
if (options && (options.showWeekNumbers || options.showISOWeekNumbers)) {
this.each(function () {
const instance = $(this).data('daterangepicker')
if (instance && instance.container)
instance.container.addClass('with-week-numbers')
})
}
return this
}

View file

@ -0,0 +1,765 @@
@import '../../sass/_custom-variables/libs';
$daterangepicker-cell-size: 2rem !default;
$daterangepicker-padding: .5rem !default;
$daterangepicker-arrow-size: .5rem !default;
$daterangepicker-select-width: 3.125rem !default;
// Calculate widths
$daterangepicker-width: ($daterangepicker-cell-size * 7) + ($daterangepicker-padding * 2);
$daterangepicker-width-with-weeks: $daterangepicker-width + $daterangepicker-cell-size;
.daterangepicker {
position: absolute;
top: 100px;
left: 20px;
display: none;
padding: 0;
max-width: none;
background-clip: padding-box;
@include feature-rtl {
direction: rtl !important;
}
}
.daterangepicker.single {
.daterangepicker .ranges,
.drp-calendar {
float: none;
}
.drp-selected {
display: none;
}
}
.daterangepicker.show-calendar .drp-calendar,
.daterangepicker.show-calendar .drp-buttons {
display: block;
}
.daterangepicker.auto-apply .drp-buttons {
display: none;
}
.daterangepicker .drp-calendar {
display: none;
padding: $daterangepicker-padding;
&.single .calendar-table {
border: 0;
}
}
.daterangepicker .calendar-table {
border: 0;
.next,
.prev {
background: transparent !important;
}
.next span,
.prev span {
display: inline-block;
width: $daterangepicker-arrow-size;
height: $daterangepicker-arrow-size;
border-width: 0 1px 1px 0;
border-style: solid;
border-radius: 0;
}
.next span {
margin-left: -$daterangepicker-arrow-size / 2;
transform: rotate(-45deg);
@include feature-rtl {
margin-right: -$daterangepicker-arrow-size / 2;
margin-left: 0;
transform: rotate(135deg);
}
}
.prev span {
margin-right: -$daterangepicker-arrow-size / 2;
transform: rotate(135deg);
@include feature-rtl {
margin-right: 0;
margin-left: -$daterangepicker-arrow-size / 2;
transform: rotate(-45deg);
}
}
table {
margin: 0;
width: 100%;
border: 0;
border-spacing: 0;
border-collapse: collapse;
}
th,
td {
min-width: $daterangepicker-cell-size;
width: $daterangepicker-cell-size;
height: $daterangepicker-cell-size;
border: 1px solid transparent;
vertical-align: middle;
text-align: center;
white-space: nowrap;
white-space: nowrap;
line-height: calc(#{$daterangepicker-cell-size} - 2px);
cursor: pointer;
}
}
.daterangepicker td {
@include feature-ltr {
&.start-date:not(.end-date) {
border-top-right-radius: 0 !important;
border-bottom-right-radius: 0 !important;
}
&.end-date:not(.start-date) {
border-top-left-radius: 0 !important;
border-bottom-left-radius: 0 !important;
}
}
@include feature-rtl {
&.start-date:not(.end-date) {
border-top-left-radius: 0 !important;
border-bottom-left-radius: 0 !important;
}
&.end-date:not(.start-date) {
border-top-right-radius: 0 !important;
border-bottom-right-radius: 0 !important;
}
}
&.in-range:not(.start-date):not(.end-date) {
border-radius: 0 !important;
}
}
.daterangepicker th.month {
width: auto;
}
.daterangepicker td.disabled,
.daterangepicker option.disabled {
text-decoration: line-through;
cursor: not-allowed;
}
.daterangepicker select {
&.monthselect,
&.yearselect {
margin: 0;
padding: 1px;
height: auto;
cursor: default;
}
&.monthselect {
margin-right: 2%;
width: 56%;
@include feature-rtl {
margin-right: 0;
margin-left: 2%;
}
}
&.yearselect {
width: 40%;
}
&.hourselect,
&.minuteselect,
&.secondselect,
&.ampmselect {
margin: 0 auto;
padding: 2px;
width: $daterangepicker-select-width;
outline: 0;
}
}
.daterangepicker .calendar-time {
position: relative;
margin: 0 auto;
text-align: center;
line-height: 30px;
select.disabled {
cursor: not-allowed;
}
}
.daterangepicker .drp-buttons {
display: none;
clear: both;
padding: $daterangepicker-padding;
border-top: 1px solid;
vertical-align: middle;
text-align: right;
.btn {
margin-left: $daterangepicker-padding;
}
@include feature-rtl {
text-align: left;
.btn {
margin-right: $daterangepicker-padding;
margin-left: 0;
}
}
}
.daterangepicker .drp-selected {
display: block;
padding-bottom: $daterangepicker-padding;
width: 100%;
}
.daterangepicker .ranges {
float: none;
margin: 0;
text-align: left;
@include feature-rtl {
text-align: right;
}
ul {
margin: 0 auto;
padding: 0;
width: 100%;
list-style: none;
}
}
.daterangepicker.show-calendar .ranges {
border-bottom: 1px solid;
&:empty {
display: none;
}
}
@if $enable-light-style {
.light-style {
@import "../../sass/_appwork/include";
.daterangepicker {
z-index: $zindex-popover !important;
margin-top: $dropdown-spacer;
width: calc(#{$daterangepicker-width} + #{$dropdown-border-width * 2});
border: $dropdown-border-width solid $dropdown-border-color;
border-radius: $border-radius;
background-color: $dropdown-bg;
box-shadow: $dropdown-box-shadow;
&.drop-up {
margin-top: -$dropdown-spacer;
}
&.with-week-numbers {
width: calc(#{$daterangepicker-width-with-weeks} + #{$dropdown-border-width * 2});
}
}
.daterangepicker .calendar-table td {
border-radius: $border-radius;
}
.daterangepicker .drp-buttons,
.daterangepicker .ranges {
border-color: $border-color;
}
.daterangepicker .drp-selected {
font-size: $font-size-sm;
}
.daterangepicker .calendar-table thead tr:last-child th {
border-radius: 0 !important;
background: $gray-50;
font-weight: $font-weight-semibold;
font-size: $font-size-sm;
}
.daterangepicker td.week,
.daterangepicker th.week {
color: $text-light;
}
.daterangepicker th.month {
font-weight: $font-weight-semibold;
}
.daterangepicker td.available:hover,
.daterangepicker th.available:hover {
background-color: $gray-50;
}
.daterangepicker td.disabled,
.daterangepicker option.disabled {
color: $text-lighter;
}
.daterangepicker td.off,
.daterangepicker td.off.in-range,
.daterangepicker td.off.start-date,
.daterangepicker td.off.end-date {
color: $text-light;
}
.daterangepicker .ranges li {
padding: $dropdown-item-padding-y $dropdown-item-padding-x;
cursor: pointer;
&:hover {
background-color: $dropdown-link-hover-bg;
}
}
.daterangepicker .calendar-table .next,
.daterangepicker .calendar-table .prev {
span {
border-color: $text-light;
}
&:hover span {
border-color: $body-color;
}
}
.daterangepicker select {
&.monthselect,
&.yearselect,
&.hourselect,
&.minuteselect,
&.secondselect,
&.ampmselect {
border: 1px solid transparent;
background: $gray-100;
color: $body-color;
font-size: $font-size-sm;
}
}
.daterangepicker .calendar-time select.disabled {
color: $text-light;
}
@media (min-width: map-get($grid-breakpoints, md)) {
.daterangepicker {
width: auto !important;
.drp-selected {
display: inline-block;
padding: 0;
width: auto;
}
}
@include feature-ltr-style {
.daterangepicker .drp-calendar {
float: left;
&.left {
padding-right: 0;
}
}
}
@include feature-rtl-style {
.daterangepicker .drp-calendar {
float: right;
&.left {
padding-left: 0;
}
}
}
}
@media (min-width: map-get($grid-breakpoints, lg)) {
.daterangepicker .ranges {
border-bottom: 0;
}
@include feature-ltr-style {
.daterangepicker {
.ranges {
float: left;
}
.drp-calendar.left {
border-left: 1px solid $border-color;
}
}
}
@include feature-rtl-style {
.daterangepicker {
.ranges {
float: right;
}
.drp-calendar.left {
border-right: 1px solid $border-color;
}
}
}
}
}
}
@if $enable-material-style {
.material-style {
@import "../../sass/_appwork/include-material";
.daterangepicker {
z-index: $zindex-popover !important;
margin-top: $dropdown-spacer;
width: calc(#{$daterangepicker-width} + #{$dropdown-border-width * 2});
border: $dropdown-border-width solid $dropdown-border-color;
border-radius: $border-radius;
background-color: $dropdown-bg;
box-shadow: $dropdown-box-shadow;
&.drop-up {
margin-top: -$dropdown-spacer;
}
&.with-week-numbers {
width: calc(#{$daterangepicker-width-with-weeks} + #{$dropdown-border-width * 2});
}
}
.daterangepicker .calendar-table td {
border-radius: 99rem;
font-weight: $font-weight-semibold;
font-size: $font-size-sm;
}
.daterangepicker .drp-buttons,
.daterangepicker .ranges {
border-color: $border-color;
}
.daterangepicker .drp-selected {
font-size: $font-size-sm;
}
.daterangepicker .calendar-table thead tr:last-child th {
background: $gray-50;
font-weight: $font-weight-semibold;
font-size: $font-size-sm;
}
.daterangepicker td.week,
.daterangepicker th.week {
color: $text-light;
}
.daterangepicker th.month {
font-weight: $font-weight-semibold;
}
.daterangepicker td.available:hover,
.daterangepicker th.available:hover {
background-color: $gray-50;
}
.daterangepicker td.disabled,
.daterangepicker option.disabled {
color: $text-lighter;
}
.daterangepicker td.off,
.daterangepicker td.off.in-range,
.daterangepicker td.off.start-date,
.daterangepicker td.off.end-date {
color: $text-light;
}
.daterangepicker .ranges li {
padding: $dropdown-item-padding-y $dropdown-item-padding-x;
cursor: pointer;
&:hover {
background-color: $dropdown-link-hover-bg;
}
}
.daterangepicker .calendar-table .next,
.daterangepicker .calendar-table .prev {
span {
border-color: $text-light;
}
&:hover span {
border-color: $body-color;
}
}
.daterangepicker select {
&.monthselect,
&.yearselect,
&.hourselect,
&.minuteselect,
&.secondselect,
&.ampmselect {
border: 1px solid transparent;
background: $gray-100;
color: $body-color;
font-size: $font-size-sm;
}
}
.daterangepicker .calendar-time select.disabled {
color: $text-light;
}
@media (min-width: map-get($grid-breakpoints, md)) {
.daterangepicker {
width: auto !important;
.drp-selected {
display: inline-block;
padding: 0;
width: auto;
}
}
@include feature-ltr-style {
.daterangepicker .drp-calendar {
float: left;
&.left {
padding-right: 0;
}
}
}
@include feature-rtl-style {
.daterangepicker .drp-calendar {
float: right;
&.left {
padding-left: 0;
}
}
}
}
@media (min-width: map-get($grid-breakpoints, lg)) {
.daterangepicker .ranges {
border-bottom: 0;
}
@include feature-ltr-style {
.daterangepicker {
.ranges {
float: left;
}
.drp-calendar.left {
border-left: 1px solid $border-color;
}
}
}
@include feature-rtl-style {
.daterangepicker {
.ranges {
float: right;
}
.drp-calendar.left {
border-right: 1px solid $border-color;
}
}
}
}
}
}
@if $enable-dark-style {
.dark-style {
@import "../../sass/_appwork/include-dark";
.daterangepicker {
z-index: $zindex-popover !important;
margin-top: $dropdown-spacer;
width: calc(#{$daterangepicker-width} + #{$dropdown-border-width * 2});
border: $dropdown-border-width solid $dropdown-border-color;
border-radius: $border-radius;
background-color: $dropdown-bg;
box-shadow: $dropdown-box-shadow;
&.drop-up {
margin-top: -$dropdown-spacer;
}
&.with-week-numbers {
width: calc(#{$daterangepicker-width-with-weeks} + #{$dropdown-border-width * 2});
}
}
.daterangepicker .calendar-table td {
border-radius: $border-radius;
}
.daterangepicker .drp-buttons,
.daterangepicker .ranges {
border-color: $border-color;
}
.daterangepicker .drp-selected {
font-size: $font-size-sm;
}
.daterangepicker .calendar-table thead tr:last-child th {
border-radius: 0 !important;
background: $gray-100;
font-weight: $font-weight-semibold;
font-size: $font-size-sm;
}
.daterangepicker td.week,
.daterangepicker th.week {
color: $text-light;
}
.daterangepicker th.month {
font-weight: $font-weight-semibold;
}
.daterangepicker td.available:hover,
.daterangepicker th.available:hover {
background-color: $gray-100;
}
.daterangepicker td.disabled,
.daterangepicker option.disabled {
color: $text-lighter;
}
.daterangepicker td.off,
.daterangepicker td.off.in-range,
.daterangepicker td.off.start-date,
.daterangepicker td.off.end-date {
color: $text-light;
}
.daterangepicker .ranges li {
padding: $dropdown-item-padding-y $dropdown-item-padding-x;
cursor: pointer;
&:hover {
background-color: $dropdown-link-hover-bg;
}
}
.daterangepicker .calendar-table .next,
.daterangepicker .calendar-table .prev {
span {
border-color: $text-light;
}
&:hover span {
border-color: $body-color;
}
}
.daterangepicker select {
&.monthselect,
&.yearselect,
&.hourselect,
&.minuteselect,
&.secondselect,
&.ampmselect {
border: 1px solid transparent;
background: $gray-100;
color: $body-color;
font-size: $font-size-sm;
}
}
.daterangepicker .calendar-time select.disabled {
color: $text-light;
}
@media (min-width: map-get($grid-breakpoints, md)) {
.daterangepicker {
width: auto !important;
.drp-selected {
display: inline-block;
padding: 0;
width: auto;
}
}
@include feature-ltr-style {
.daterangepicker .drp-calendar {
float: left;
&.left {
padding-right: 0;
}
}
}
@include feature-rtl-style {
.daterangepicker .drp-calendar {
float: right;
&.left {
padding-left: 0;
}
}
}
}
@media (min-width: map-get($grid-breakpoints, lg)) {
.daterangepicker .ranges {
border-bottom: 0;
}
@include feature-ltr-style {
.daterangepicker {
.ranges {
float: left;
}
.drp-calendar.left {
border-left: 1px solid $border-color;
}
}
}
@include feature-rtl-style {
.daterangepicker {
.ranges {
float: right;
}
.drp-calendar.left {
border-right: 1px solid $border-color;
}
}
}
}
}
}

View file

@ -0,0 +1 @@
import 'bootstrap-duallistbox/src/jquery.bootstrap-duallistbox.js'

View file

@ -0,0 +1,43 @@
@import '../../sass/_custom-variables/libs';
@import "~bootstrap-duallistbox/src/bootstrap-duallistbox";
.bootstrap-duallistbox-container .glyphicon-arrow-left,
.bootstrap-duallistbox-container .glyphicon-arrow-right {
position: relative;
top: 1px;
display: inline-block;
font-weight: normal;
font-style: normal;
line-height: 1;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
@include feature-rtl {
transform: scaleX(-1);
}
}
.bootstrap-duallistbox-container .glyphicon-arrow-left:before {
content: "";
}
.bootstrap-duallistbox-container .glyphicon-arrow-right:before {
content: "";
}
.bootstrap-duallistbox-container select {
padding: .3125rem 0;
option {
padding: .1875rem .625rem;
line-height: 1;
}
}
@if $enable-material-style {
.material-style {
.bootstrap-duallistbox-container select {
padding: .625rem 0;
}
}
}

View file

@ -0,0 +1,5 @@
@mixin bs-markdown-theme($border) {
.md-editor.active {
border-color: $border !important;
}
}

View file

@ -0,0 +1 @@
import 'bootstrap-markdown/js/bootstrap-markdown.js'

View file

@ -0,0 +1,143 @@
@import '../../sass/_custom-variables/libs';
@import "~bootstrap-markdown/css/bootstrap-markdown.min";
.md-editor.active {
box-shadow: none !important;
}
.md-editor > textarea,
.md-editor > .md-preview {
padding: 14px;
}
.md-editor > .md-header > .btn-group {
margin-right: .3125rem;
@include feature-rtl {
margin-right: 0;
margin-left: .3125rem;
}
}
@include feature-rtl(false) {
.md-controls {
float: left;
}
.md-controls .md-control {
right: auto;
left: 5px;
padding-left: 3px;
padding-right: 10px;
}
.md-fullscreen-mode .md-fullscreen-controls {
right: auto;
left: 20px;
text-align: left;
}
}
@if $enable-light-style {
.light-style {
@import "../../sass/_appwork/include";
.md-editor>.md-header,
.md-editor .md-footer,
.md-editor>textarea,
.md-editor>.md-preview {
background: $input-bg;
}
.md-editor {
border-color: $input-border-color;
&.md-fullscreen-mode {
z-index: $zindex-modal-top;
}
}
.md-editor:not(.md-fullscreen-mode) > .md-header,
.md-editor:not(.md-fullscreen-mode) .md-footer {
padding-left: $input-btn-padding-x / 2 !important;
padding-right: $input-btn-padding-x / 2 !important;
}
.md-editor > textarea,
.md-editor > .md-preview {
border-color: $input-border-color;
padding: $input-btn-padding-x !important;
}
}
}
@if $enable-material-style {
.material-style {
@import "../../sass/_appwork/include-material";
.md-editor>.md-header,
.md-editor .md-footer,
.md-editor>textarea,
.md-editor>.md-preview {
background: #fff;
}
.md-editor {
border-color: $input-border-color;
&.md-fullscreen-mode {
z-index: $zindex-modal-top;
}
}
.md-editor:not(.md-fullscreen-mode) > .md-header,
.md-editor:not(.md-fullscreen-mode) .md-footer {
padding-left: $input-btn-padding-x / 2 !important;
padding-right: $input-btn-padding-x / 2 !important;
}
.md-fullscreen-mode > .md-header .btn {
box-shadow: none !important;
}
// Some hack to rewrite default form-contol style
:not(.input-group) > div.md-editor[class] > textarea.md-input[class],
.md-editor > .md-preview {
border-color: $input-border-color;
padding: $input-btn-padding-x !important;
}
}
}
@if $enable-dark-style {
.dark-style {
@import "../../sass/_appwork/include-dark";
.md-editor>.md-header,
.md-editor .md-footer,
.md-editor>textarea,
.md-editor>.md-preview {
background: $input-bg;
}
.md-editor {
border-color: $input-border-color;
&.md-fullscreen-mode {
z-index: $zindex-modal-top;
}
}
.md-editor:not(.md-fullscreen-mode)>.md-header,
.md-editor:not(.md-fullscreen-mode) .md-footer {
padding-left: $input-btn-padding-x / 2 !important;
padding-right: $input-btn-padding-x / 2 !important;
}
.md-editor>textarea,
.md-editor>.md-preview {
border-color: $input-border-color;
padding: $input-btn-padding-x !important;
}
}
}

View file

@ -0,0 +1,22 @@
const originalPicker = $.fn.bootstrapMaterialDatePicker
$.fn.bootstrapMaterialDatePicker = function (...args) {
this.each(function() {
const newInstance = !$.data(this, 'plugin_bootstrapMaterialDatePicker')
originalPicker.apply($(this), args)
if (newInstance) {
const $template = $('body').find(`> #${$.data(this, 'plugin_bootstrapMaterialDatePicker').name}`)
// Add animation
$template.addClass('animated fadeIn')
// Styling buttons
$template.find('.dtp-btn-now,.dtp-btn-clear,.dtp-btn-cancel').addClass('btn-default btn-sm')
$template.find('.dtp-btn-ok').addClass('btn-primary btn-sm')
}
})
return this
}

View file

@ -0,0 +1,35 @@
@mixin bs-material-datetimepicker-theme($background, $color: null) {
$color: if($color, $color, yiq($background));
.dtp-date,
.dtp-time {
background: $background;
color: $color;
}
.dtp-close > a { color: $color; }
header.dtp-header {
background: rgba-to-hex(rgba($background, .85), $background: #000);
color: $color;
}
table.dtp-picker-days tr > td > a.selected {
background: $background;
color: $color !important;
}
.dtp-actual-meridien a.selected {
background: $background !important;
color: $color !important;
}
.dtp .year-picker-item {
&:hover { color: $background; }
&.active { color: $background; }
}
.dtp .svg-clock [stroke="#8BC34A"] { stroke: $background !important; }
.dtp .svg-clock [fill="#8BC34A"] { fill: $background !important; }
.dtp .svg-clock [fill="#fff"] { fill: $color !important; }
}

View file

@ -0,0 +1,2 @@
import 'bootstrap-material-datetimepicker/js/bootstrap-material-datetimepicker.js'
import './_extension.js'

View file

@ -0,0 +1,449 @@
@import '../../sass/_custom-variables/libs';
$dtp-padding: 1rem !default;
$dtp-header-height: 2rem !default;
.dtp {
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
animation-duration: .3s;
user-select: none;
&.hidden {
display: none;
}
}
// Utilities
//
.dtp .p10 {
display: inline-block;
width: 10%;
> a {
display: block;
width: 100%;
color: rgba(#000, .2);
text-decoration: none;
}
}
.dtp .p20 {
display: inline-block;
width: 20%;
}
.dtp .p60 {
display: inline-block;
width: 60%;
}
.dtp .p80 {
display: inline-block;
width: 80%;
}
.dtp .hidden {
display: none;
}
.dtp .invisible {
visibility: hidden;
}
.dtp .left {
float: left;
@include feature-rtl {
float: right;
}
}
.dtp .right {
float: right;
@include feature-rtl {
float: left;
}
}
.dtp .clearfix {
clear: both;
}
.dtp .center {
text-align: center;
}
// Icons
//
.dtp-select-month-before,
.dtp-select-month-after,
.dtp-select-year-before,
.dtp-select-year-after,
.dtp-select-year-range.before,
.dtp-select-year-range.after,
.dtp-close > a {
font-size: 1.25rem;
> .material-icons {
display: none;
}
}
.dtp-select-month-before:before,
.dtp-select-year-before:before {
content: "";
}
.dtp-select-month-after:before,
.dtp-select-year-after:before {
content: "";
}
.dtp-select-year-range.before:before {
content: "";
display: inline-block;
transform: rotate(-90deg);
direction: ltr !important;
}
.dtp-select-year-range.after:before {
content: "";
display: inline-block;
transform: rotate(90deg);
direction: ltr !important;
}
.dtp-close > a:before {
content: "×";
}
// Content
//
.dtp-content {
position: relative;
left: 50%;
max-width: 18.75rem;
background: #fff;
@include feature-rtl {
right: 50%;
left: auto;
margin-left: 0 !important;
transform: translate(50%, 0);
}
}
// Header
//
header.dtp-header {
text-align: center;
line-height: $dtp-header-height;
}
.dtp-close {
position: absolute;
top: 0;
right: $dtp-padding;
@include feature-rtl {
right: auto;
left: $dtp-padding;
}
> a {
line-height: 1;
}
}
.dtp-date,
.dtp-time {
padding: $dtp-padding;
text-align: center;
}
.dtp-date > div {
margin: 0;
padding: 0;
}
.dtp-actual-month,
.dtp-actual-year {
font-size: 1.375rem;
}
.dtp-actual-num,
.dtp-actual-maxtime {
font-size: 2.625rem;
line-height: .9;
}
.dtp-actual-year {
&:hover {
cursor: pointer;
}
&.disabled:hover {
cursor: inherit;
}
}
.dtp-actual-time {
text-align: center;
font-weight: 500;
}
// Picker
//
.dtp-picker {
padding: $dtp-padding;
text-align: center;
}
.dtp-picker-year {
margin-bottom: .0625rem;
}
.dtp-select-year-range {
display: inline-block;
width: 100%;
text-align: center;
line-height: 1;
&.before {
margin-bottom: .625rem !important;
}
&.after {
margin-top: .625rem !important;
}
}
.dtp-picker-month {
padding-bottom: 1.25rem !important;
text-align: center;
text-transform: uppercase !important;
font-weight: 500;
}
.dtp .year-picker-item {
margin: 0 auto;
padding-top: .3125rem;
text-align: center;
cursor: pointer;
&.active {
font-weight: bold;
}
}
table.dtp-picker-days tr > td > a,
.dtp-picker-time > a {
padding: .4375rem;
border-radius: 50% !important;
text-decoration: none;
}
table.dtp-picker-days {
margin: 0;
min-height: 13.8125rem;
border: none;
}
table.dtp-picker-days tr {
border: none;
}
table.dtp-picker-days tr > td {
padding: .25rem;
border: none;
text-align: center;
font-weight: 700;
font-size: .8125rem;
> span.dtp-select-day {
padding: .4375rem;
}
}
table.dtp-picker-days tr > th {
padding: .25rem;
text-align: center;
font-weight: 700;
}
.dtp-picker-time > .dtp-select-hour,
.dtp-picker-time > .dtp-select-minute {
cursor: pointer;
}
a.dtp-meridien-am,
a.dtp-meridien-pm {
position: relative;
top: .625rem;
padding: .7em .5em;
border-radius: 50% !important;
text-decoration: none;
font-weight: 500;
}
// Buttons
//
.dtp-buttons {
padding: 0 $dtp-padding $dtp-padding $dtp-padding;
text-align: right;
@include feature-rtl {
text-align: left;
}
.btn + .btn {
margin-left: .3125rem;
@include feature-rtl {
margin-right: .3125rem;
margin-left: 0;
}
}
}
@if $enable-light-style {
.light-style {
@import "../../sass/_appwork/include";
.dtp {
z-index: $zindex-modal-top;
background: rgba($modal-backdrop-bg, $modal-backdrop-opacity);
}
.dtp-content {
border-radius: $border-radius;
box-shadow: $modal-content-box-shadow-xs;
background: $modal-content-bg;
}
header.dtp-header {
@include border-top-radius(if($border-radius, calc(#{$border-radius} - 2px), 0));
}
.dtp .year-picker-item {
font-size: $font-size-xl;
}
table.dtp-picker-days tr > td > a,
.dtp-picker-time > a {
color: $body-color;
}
table.dtp-picker-days tr > td > span.dtp-select-day {
color: $text-muted !important;
}
table.dtp-picker-days tr > th {
color: $text-muted;
}
a.dtp-meridien-am,
a.dtp-meridien-pm {
position: relative;
background: $gray-100;
color: $body-color;
}
}
}
@if $enable-material-style {
.material-style {
@import "../../sass/_appwork/include-material";
.dtp {
z-index: $zindex-modal-top;
background: rgba($modal-backdrop-bg, $modal-backdrop-opacity);
}
.dtp-content {
border-radius: 0;
box-shadow: $modal-content-box-shadow-xs;
background: $modal-content-bg;
}
.dtp .year-picker-item {
font-size: $font-size-xl;
}
table.dtp-picker-days tr > td > a,
.dtp-picker-time > a {
color: $body-color;
}
table.dtp-picker-days tr > td > span.dtp-select-day {
color: $text-muted !important;
}
table.dtp-picker-days tr > th {
color: $text-muted;
}
a.dtp-meridien-am,
a.dtp-meridien-pm {
position: relative;
background: $gray-100;
color: $body-color;
}
}
}
@if $enable-dark-style {
.dark-style {
@import "../../sass/_appwork/include-dark";
.dtp {
z-index: $zindex-modal-top;
background: rgba($modal-backdrop-bg, $modal-backdrop-opacity);
}
.dtp-content {
border-radius: $border-radius;
box-shadow: $modal-content-box-shadow-xs;
background: $modal-content-bg;
}
header.dtp-header {
@include border-top-radius(if($border-radius, calc(#{$border-radius} - 2px), 0));
}
.dtp .year-picker-item {
font-size: $font-size-xl;
}
table.dtp-picker-days tr > td > a,
.dtp-picker-time > a {
color: $body-color;
}
table.dtp-picker-days tr > td > span.dtp-select-day {
color: $text-muted !important;
}
table.dtp-picker-days tr > th {
color: $text-muted;
}
a.dtp-meridien-am,
a.dtp-meridien-pm {
position: relative;
background: $gray-100;
color: $body-color;
}
}
}

View file

@ -0,0 +1 @@
import 'bootstrap-maxlength/src/bootstrap-maxlength.js'

View file

@ -0,0 +1,67 @@
@import '../../sass/_custom-variables/libs';
.bootstrap-maxlength {
vertical-align: baseline;
text-align: center;
line-height: 1;
}
@if $enable-light-style {
.light-style {
@import '../../sass/_appwork/include';
.bootstrap-maxlength {
padding: $badge-padding-y $badge-padding-x;
background: $badge-default-bg;
font-weight: $badge-font-weight;
font-size: $badge-font-size;
@include border-bottom-radius($badge-border-radius);
&.label-danger {
background: map-get($theme-colors, danger);
color: yiq(map-get($theme-colors, danger));
}
}
}
}
@if $enable-material-style {
.material-style {
@import '../../sass/_appwork/include-material';
.bootstrap-maxlength {
padding: $badge-padding-y $badge-padding-x;
background: $badge-default-bg;
font-weight: $badge-font-weight;
font-size: $badge-font-size;
@include border-bottom-radius($badge-border-radius);
&.label-danger {
background: map-get($theme-colors, danger);
color: yiq(map-get($theme-colors, danger));
}
}
}
}
@if $enable-dark-style {
.dark-style {
@import '../../sass/_appwork/include-dark';
.bootstrap-maxlength {
padding: $badge-padding-y $badge-padding-x;
background: $badge-default-bg;
font-weight: $badge-font-weight;
font-size: $badge-font-size;
@include border-bottom-radius($badge-border-radius);
&.label-danger {
background: map-get($theme-colors, danger);
color: yiq(map-get($theme-colors, danger));
}
}
}
}

View file

@ -0,0 +1,3 @@
import * as BootstrapMenu from 'bootstrap-menu/src/BootstrapMenu.js'
export { BootstrapMenu }

View file

@ -0,0 +1,8 @@
@mixin bs-select-theme($background, $color: null) {
$color: if($color, $color, yiq($background));
.bootstrap-select .dropdown-menu.inner a[aria-selected=true] {
background: $background !important;
color: $color !important;
}
}

View file

@ -0,0 +1 @@
import 'bootstrap-select/js/bootstrap-select.js'

View file

@ -0,0 +1,101 @@
$width-default: 100%;
@import '../../sass/_custom-variables/libs';
@import "~bootstrap-select/sass/bootstrap-select";
.bootstrap-select *,
.bootstrap-select .dropdown-toggle:focus {
outline: 0 !important;
}
.bootstrap-select .dropdown-toggle:after {
position: absolute;
top: 50%;
right: 13px;
transform: rotate(45deg) translateY(-50%);
@include feature-rtl {
right: auto;
left: 13px;
}
}
.bootstrap-select.dropup .dropdown-toggle:after {
transform: rotate(-45deg) translateY(-50%);
}
@include feature-rtl(false) {
.bootstrap-select .dropdown-toggle .filter-option {
text-align: right;
left: auto;
right: 0;
float: right;
padding-right: 0;
padding-left: inherit;
margin-right: 0;
margin-left: -100%;
}
}
.bootstrap-select.show-tick .dropdown-menu {
li a {
position: relative;
}
@include feature-rtl {
li a span.text {
margin-right: 0;
margin-left: 2.125rem;
}
}
.selected span.check-mark {
top: 50%;
right: 1rem;
display: block;
line-height: 1;
transform: translateY(-50%);
margin: 0;
@include feature-rtl {
right: auto;
left: 1rem;
}
}
}
@include feature-rtl(false) {
.bootstrap-select .dropdown-toggle .filter-option-inner {
padding-right: 0;
padding-left: inherit;
}
}
html[class] .bootstrap-select.custom-select {
margin: 0 !important;
padding: 0 !important;
border: 0 !important;
background: none !important;
}
.bootstrap-select:not(.input-group-btn),
.bootstrap-select[class*="col-"] {
display: block;
}
.bootstrap-select .dropdown-menu.inner .selected .waves-ripple {
display: none !important;
}
@if $enable-material-style {
.material-style {
@import "../../sass/_appwork/include-material";
// IE has a strange material ripple bug, so just hide the ripple element
@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {
.bootstrap-select .waves-ripple {
display: none !important;
}
}
}
}

View file

@ -0,0 +1,32 @@
@mixin bs-slider-variant($background) {
.slider-selection,
.slider-reversed .slider-track-high,
&.slider-reversed .slider-track-high {
background: $background;
}
}
@mixin material-bs-slider-variant($background) {
.slider-handle {
box-shadow: none !important;
}
.slider-handle,
.slider-selection,
.slider-reversed .slider-track-high,
&.slider-reversed .slider-track-high {
background: $background;
}
}
@mixin bs-slider-theme($background) {
.slider-primary {
@include bs-slider-variant($background);
}
}
@mixin material-bs-slider-theme($background) {
.slider-primary {
@include material-bs-slider-variant($background);
}
}

View file

@ -0,0 +1 @@
import 'bootstrap-slider/src/js/bootstrap-slider.js'

View file

@ -0,0 +1,197 @@
@import '../../sass/_custom-variables/libs';
$slider-line-height: .75rem !default;
$slider-border-radius: 6.1875rem !default;
$slider-horizontal-width: 100% !default;
// DUMMY
@mixin slider_background-image ($v...) {}
@mixin slider_box-sizing ($v...) {}
@mixin slider_box-shadow ($v...) {}
@mixin slider_border-radius ($value) { border-radius: $value; }
@function slider_border-radius($value) { @return $value; }
// Imports
@import "~bootstrap-slider/src/sass/variables";
@import "mixins";
@import "~bootstrap-slider/src/sass/rules";
.slider {
user-select: none;
}
.slider .tooltip {
transition: opacity .2s;
line-height: 1;
&.top,
&.bottom {
transform: translateX(-50%);
@include feature-rtl {
transform: translateX(50%);
}
}
&.left,
&.right {
transform: translateY(-50%);
}
&.in {
opacity: 1;
}
&.top {
margin-top: -($slider-line-height * 2.2) - .125rem;
}
&.right {
margin-left: .5rem;
}
&.left {
margin-right: .5rem;
}
.tooltip-inner {
padding-top: .375rem;
padding-bottom: .375rem;
}
}
.slider-handle {
background: #fff;
transition: transform .2s;
transform-origin: center;
&:active {
transform: scale(1.4, 1.4);
}
}
// Horizontal track
.slider.slider-horizontal .slider-track {
margin-top: -.0625rem;
height: .125rem;
}
// Vertical track
.slider.slider-vertical .slider-track {
margin-left: .125rem;
width: .125rem;
}
// Reversed slider
.slider-reversed .slider-selection {
background: transparent !important;
}
// Disabled
//
.slider-disabled .slider-track {
opacity: .3;
cursor: not-allowed;
}
.slider-disabled .slider-handle {
box-shadow: 0 0 0 1px rgba(0,0,0,.07);
cursor: not-allowed;
transform: none;
}
// Horizontal labels
.slider.slider-horizontal .slider-tick-label-container .slider-tick-label {
padding-top: .25rem;
}
@include feature-rtl(false) {
.slider.slider-vertical {
.slider-track {
margin-left: 0;
margin-right: .125rem;
}
}
}
@if $enable-light-style {
.light-style {
@import '../../sass/_appwork/include';
.slider-handle {
box-shadow: 0 0 0 1px rgba(0,0,0,.1), $floating-component-shadow;
}
.slider-track {
background: $gray-200;
}
.slider-tick-label-container .slider-tick-label {
color: $text-muted;
font-size: $small-font-size;
}
@each $color, $value in $theme-colors {
@if $color != primary {
.slider-#{$color} {
@include bs-slider-variant($value);
}
}
}
}
}
@if $enable-material-style {
.material-style {
@import '../../sass/_appwork/include-material';
.slider-handle {
box-shadow: 0 0 0 1px rgba(0,0,0,.1), $floating-component-shadow;
}
.slider-track {
background: $gray-200;
}
.slider-tick-label-container .slider-tick-label {
color: $text-muted;
font-size: $small-font-size;
}
@each $color, $value in $theme-colors {
@if $color != primary {
.slider-#{$color} {
@include material-bs-slider-variant($value);
}
}
}
}
}
@if $enable-dark-style {
.dark-style {
@import '../../sass/_appwork/include-dark';
.slider-handle {
box-shadow: 0 0 0 1px rgba(0, 0, 0, .1), $floating-component-shadow;
}
.slider-track {
background: $gray-200;
}
.slider-tick-label-container .slider-tick-label {
color: $text-muted;
font-size: $small-font-size;
}
@each $color, $value in $theme-colors {
@if $color !=primary {
.slider-#{$color} {
@include bs-slider-variant(if($color=='dark'and $dark-style, $white, $value));
}
}
}
}
}

View file

@ -0,0 +1,110 @@
/**
* adding sorting ability to HTML tables with Bootstrap styling
* @summary HTML tables sorting ability
* @version 2.0.0
* @requires tinysort, moment.js, jQuery
* @license MIT
* @author Matus Brlit (drvic10k)
* @copyright Matus Brlit (drvic10k), bootstrap-sortable contributors
*/
table.sortable span.sign {
display: block;
position: absolute;
top: 50%;
right: 5px;
font-size: 12px;
margin-top: -10px;
color: #bfbfc1;
}
table.sortable th:after {
display: block;
position: absolute;
top: 50%;
right: 5px;
font-size: 12px;
margin-top: -10px;
color: #bfbfc1;
}
table.sortable th.arrow:after {
content: '';
}
table.sortable span.arrow, span.reversed, th.arrow.down:after, th.reversedarrow.down:after, th.arrow.up:after, th.reversedarrow.up:after {
border-style: solid;
border-width: 5px;
font-size: 0;
border-color: #ccc transparent transparent transparent;
line-height: 0;
height: 0;
width: 0;
margin-top: -2px;
}
table.sortable span.arrow.up, th.arrow.up:after {
border-color: transparent transparent #ccc transparent;
margin-top: -7px;
}
table.sortable span.reversed, th.reversedarrow.down:after {
border-color: transparent transparent #ccc transparent;
margin-top: -7px;
}
table.sortable span.reversed.up, th.reversedarrow.up:after {
border-color: #ccc transparent transparent transparent;
margin-top: -2px;
}
table.sortable span.az:before, th.az.down:after {
content: "a .. z";
}
table.sortable span.az.up:before, th.az.up:after {
content: "z .. a";
}
table.sortable th.az.nosort:after, th.AZ.nosort:after, th._19.nosort:after, th.month.nosort:after {
content: "..";
}
table.sortable span.AZ:before, th.AZ.down:after {
content: "A .. Z";
}
table.sortable span.AZ.up:before, th.AZ.up:after {
content: "Z .. A";
}
table.sortable span._19:before, th._19.down:after {
content: "1 .. 9";
}
table.sortable span._19.up:before, th._19.up:after {
content: "9 .. 1";
}
table.sortable span.month:before, th.month.down:after {
content: "jan .. dec";
}
table.sortable span.month.up:before, th.month.up:after {
content: "dec .. jan";
}
table.sortable>thead th:not([data-defaultsort=disabled]) {
cursor: pointer;
position: relative;
top: 0;
left: 0;
}
table.sortable>thead th:hover:not([data-defaultsort=disabled]) {
background: #efefef;
}
table.sortable>thead th div.mozilla {
position: relative;
}

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,98 @@
@import '../../sass/_custom-variables/libs';
@import "./_bootstrap-sortable";
@include feature-rtl(false) {
table.sortable {
span.sign {
right: auto;
left: .3125rem;
}
th:after {
right: auto;
left: .3125rem;
}
>thead th:not([data-defaultsort=disabled]) {
right: 0;
left: auto;
}
span.az:before,
th.az.down:after {
content: "z .. a";
}
span.az.up:before,
th.az.up:after {
content: "a .. z";
}
th.az.nosort:after,
th.AZ.nosort:after,
th._19.nosort:after,
th.month.nosort:after {
content: "..";
}
span.AZ:before,
th.AZ.down:after {
content: "Z .. A";
}
span.AZ.up:before,
th.AZ.up:after {
content: "A .. Z";
}
span._19:before,
th._19.down:after {
content: "9 .. 1";
}
span._19.up:before,
th._19.up:after {
content: "1 .. 9";
}
span.month:before,
th.month.down:after {
content: "dec .. jan";
}
span.month.up:before,
th.month.up:after {
content: "jan .. dec";
}
}
}
@if $enable-light-style {
.light-style {
@import "../../sass/_appwork/include";
table.sortable>thead th:hover:not([data-defaultsort=disabled]) {
background: $table-hover-bg;
}
}
}
@if $enable-material-style {
.material-style {
@import "../../sass/_appwork/include-material";
table.sortable>thead th:hover:not([data-defaultsort=disabled]) {
background: $table-hover-bg;
}
}
}
@if $enable-dark-style {
.dark-style {
@import "../../sass/_appwork/include-dark";
table.sortable>thead th:hover:not([data-defaultsort=disabled]) {
background: $table-hover-bg;
}
}
}

View file

@ -0,0 +1 @@
import 'bootstrap-table/src/bootstrap-table.js'

View file

@ -0,0 +1,145 @@
@import '../../sass/_custom-variables/libs';
@import "~bootstrap-table/src/bootstrap-table";
.bootstrap-table .bs-checkbox label {
margin-bottom: 0;
}
@include feature-ltr(false) {
.bootstrap-table {
.fixed-table-container .table {
thead th .sortable {
padding-right: 30px !important;
}
}
}
}
@include feature-rtl(false) {
.bootstrap-table {
.fixed-table-toolbar {
.columns .btn-group>.btn-group {
margin-left: 0 !important;
margin-right: -1px !important;
}
.columns .dropdown-menu {
text-align: right;
}
.columns-left {
margin-left: 5px;
margin-right: 0;
}
.columns-right {
margin-left: 0;
margin-right: 5px;
}
.pull-right .dropdown-menu {
right: auto;
left: 0;
}
}
.fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .loading-text {
margin-right: 0;
margin-left: 6px;
}
.table {
thead th .sortable {
padding-left: 30px !important;
background-position: left;
}
tbody tr .card-view .card-view-title {
text-align: right !important;
}
}
.fixed-table-pagination > .pagination-detail .pagination-info {
margin-left: 5px;
margin-right: 0;
}
}
div.fixed-table-scroll-outer {
left: auto;
right: 0;
}
}
@if $enable-light-style {
.light-style {
@import "../../sass/_appwork/include";
.bootstrap-table .fixed-table-container.fixed-height {
&:not(.has-footer),
.fixed-table-border,
.table thead th {
border-color: $table-border-color;
}
}
.bootstrap-table .fixed-table-container .table {
thead th .th-inner {
padding: $table-cell-padding;
}
&.table-sm .th-inner {
padding: $table-cell-padding-sm;
}
}
}
}
@if $enable-material-style {
.material-style {
@import "../../sass/_appwork/include-material";
.bootstrap-table .fixed-table-container.fixed-height {
&:not(.has-footer),
.fixed-table-border,
.table thead th {
border-color: $table-border-color;
}
}
.bootstrap-table .fixed-table-container .table {
thead th .th-inner {
padding: $table-cell-padding;
}
&.table-sm .th-inner {
padding: $table-cell-padding-sm;
}
}
}
}
@if $enable-dark-style {
.dark-style {
@import "../../sass/_appwork/include-dark";
.bootstrap-table .fixed-table-container.fixed-height {
&:not(.has-footer),
.fixed-table-border,
.table thead th {
border-color: $table-border-color;
}
}
.bootstrap-table .fixed-table-container .table {
thead th .th-inner {
padding: $table-cell-padding;
}
&.table-sm .th-inner {
padding: $table-cell-padding-sm;
}
}
}
}

View file

@ -0,0 +1 @@
import 'bootstrap-table/src/extensions/accent-neutralise/bootstrap-table-accent-neutralise.js'

View file

@ -0,0 +1 @@
import 'bootstrap-table/src/extensions/addrbar/bootstrap-table-addrbar.js'

Some files were not shown because too many files have changed in this diff Show more