first commit
|
|
@ -0,0 +1,13 @@
|
||||||
|
{
|
||||||
|
"presets": ["@babel/preset-env"],
|
||||||
|
"plugins": [
|
||||||
|
[
|
||||||
|
"module-resolver", {
|
||||||
|
"root": ["."],
|
||||||
|
"alias": {
|
||||||
|
"helpers": "./tests/js/helpers"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,12 @@
|
||||||
|
# EditorConfig is awesome: http://EditorConfig.org
|
||||||
|
|
||||||
|
# top-most EditorConfig file
|
||||||
|
root = true
|
||||||
|
|
||||||
|
[*]
|
||||||
|
end_of_line = lf
|
||||||
|
charset = utf-8
|
||||||
|
trim_trailing_whitespace = true
|
||||||
|
insert_final_newline = true
|
||||||
|
indent_style = space
|
||||||
|
indent_size = 4
|
||||||
|
|
@ -0,0 +1,33 @@
|
||||||
|
APP_DEBUG=true
|
||||||
|
APP_URL=http://localhost
|
||||||
|
APP_KEY=base64:l9GsGrhw5RLlAybs8em56Jr0ZfzSV25SmoZPB6LiVJQ==
|
||||||
|
|
||||||
|
DB_CONNECTION=mysql
|
||||||
|
DB_HOST=localhost
|
||||||
|
DB_PORT=3306
|
||||||
|
DB_DATABASE=shift
|
||||||
|
DB_USERNAME=root
|
||||||
|
DB_PASSWORD=bt110226
|
||||||
|
REDIS_HOST=127.0.0.1
|
||||||
|
REDIS_PASSWORD=null
|
||||||
|
REDIS_PORT=6379
|
||||||
|
DB_USE_CONFIG_FOR_TESTING=false
|
||||||
|
|
||||||
|
CACHE_DRIVER=file
|
||||||
|
|
||||||
|
SESSION_DRIVER=cookie
|
||||||
|
|
||||||
|
QUEUE_DRIVER=sync
|
||||||
|
|
||||||
|
MAIL_DRIVER=smtp
|
||||||
|
MAIL_HOST=smtp.mailgun.org
|
||||||
|
MAIL_PORT=587
|
||||||
|
MAIL_ENCRYPTION=tls
|
||||||
|
MAIL_USERNAME=null
|
||||||
|
MAIL_PASSWORD=null
|
||||||
|
|
||||||
|
ROUTES_CACHE=false
|
||||||
|
ASSET_CACHE=false
|
||||||
|
DATABASE_TEMPLATES=false
|
||||||
|
LINK_POLICY=detect
|
||||||
|
ENABLE_CSRF=true
|
||||||
|
|
@ -0,0 +1,60 @@
|
||||||
|
<IfModule mod_rewrite.c>
|
||||||
|
|
||||||
|
<IfModule mod_negotiation.c>
|
||||||
|
Options -MultiViews
|
||||||
|
</IfModule>
|
||||||
|
|
||||||
|
RewriteEngine On
|
||||||
|
|
||||||
|
##
|
||||||
|
## You may need to uncomment the following line for some hosting environments,
|
||||||
|
## if you have installed to a subdirectory, enter the name here also.
|
||||||
|
##
|
||||||
|
# RewriteBase /
|
||||||
|
|
||||||
|
##
|
||||||
|
## Uncomment following lines to force HTTPS.
|
||||||
|
##
|
||||||
|
# RewriteCond %{HTTPS} off
|
||||||
|
# RewriteRule (.*) https://%{SERVER_NAME}/$1 [L,R=301]
|
||||||
|
|
||||||
|
##
|
||||||
|
## Black listed folders
|
||||||
|
##
|
||||||
|
RewriteRule ^bootstrap/.* index.php [L,NC]
|
||||||
|
RewriteRule ^config/.* index.php [L,NC]
|
||||||
|
RewriteRule ^vendor/.* index.php [L,NC]
|
||||||
|
RewriteRule ^storage/cms/.* index.php [L,NC]
|
||||||
|
RewriteRule ^storage/logs/.* index.php [L,NC]
|
||||||
|
RewriteRule ^storage/framework/.* index.php [L,NC]
|
||||||
|
RewriteRule ^storage/temp/protected/.* index.php [L,NC]
|
||||||
|
RewriteRule ^storage/app/uploads/protected/.* index.php [L,NC]
|
||||||
|
|
||||||
|
##
|
||||||
|
## White listed folders
|
||||||
|
##
|
||||||
|
RewriteCond %{REQUEST_FILENAME} -f
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !/.well-known/*
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !/storage/app/uploads/public/.*
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !/storage/app/media/.*
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !/storage/app/resized/.*
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !/storage/temp/public/.*
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !/themes/.*/(assets|resources)/.*
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !/plugins/.*/(assets|resources)/.*
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !/modules/.*/(assets|resources)/.*
|
||||||
|
RewriteRule !^index.php index.php [L,NC]
|
||||||
|
|
||||||
|
##
|
||||||
|
## Block all PHP files, except index
|
||||||
|
##
|
||||||
|
RewriteCond %{REQUEST_FILENAME} -f
|
||||||
|
RewriteCond %{REQUEST_FILENAME} \.php$
|
||||||
|
RewriteRule !^index.php index.php [L,NC]
|
||||||
|
|
||||||
|
##
|
||||||
|
## Standard routes
|
||||||
|
##
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !-f
|
||||||
|
RewriteRule ^ index.php [L]
|
||||||
|
|
||||||
|
</IfModule>
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
View the changelog on the [OctoberCMS website](https://octobercms.com/changelog)
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
# Code of Conduct
|
||||||
|
|
||||||
|
We promise to extend courtesy and respect to everyone opening an issue. We expect anyone using the bug trackers to do the same.
|
||||||
|
|
||||||
|
All reported issues to this project are valuable. Please act with respect and avoid demeaning, condescending, racist, sexist and other inappropriate language and conduct. Please ensure comments stay professional and constructive.
|
||||||
|
|
@ -0,0 +1,21 @@
|
||||||
|
MIT License
|
||||||
|
|
||||||
|
Copyright (c) 2013-2021 Alexey Bobkov, Samuel Georges, October CMS
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in all
|
||||||
|
copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
SOFTWARE.
|
||||||
|
|
@ -0,0 +1,75 @@
|
||||||
|
<p align="center">
|
||||||
|
<img src="https://github.com/octobercms/october/blob/develop/themes/demo/assets/images/october.png?raw=true" alt="October" width="25%" height="25%" />
|
||||||
|
</p>
|
||||||
|
|
||||||
|
[October](https://octobercms.com) is a Content Management System (CMS) and web platform whose sole purpose is to make your development workflow simple again. It was born out of frustration with existing systems. We feel building websites has become a convoluted and confusing process that leaves developers unsatisfied. We want to turn you around to the simpler side and get back to basics.
|
||||||
|
|
||||||
|
October's mission is to show the world that web development is not rocket science.
|
||||||
|
|
||||||
|

|
||||||
|
[](https://packagist.org/packages/october/october)
|
||||||
|
|
||||||
|
## Installing October
|
||||||
|
|
||||||
|
Instructions on how to install October can be found at the [installation guide](https://octobercms.com/docs/setup/installation).
|
||||||
|
|
||||||
|
### Quick Start Installation
|
||||||
|
|
||||||
|
If you have composer installed, run this in your terminal to install October CMS from command line. This will place the files in a directory named **myoctober**.
|
||||||
|
|
||||||
|
composer create-project october/october myoctober
|
||||||
|
|
||||||
|
If you plan on using a database, run this command inside the application directory.
|
||||||
|
|
||||||
|
php artisan october:install
|
||||||
|
|
||||||
|
## Learning October
|
||||||
|
|
||||||
|
The best place to learn October is by [reading the documentation](https://octobercms.com/docs), [watching some screencasts](https://octobercms.com/support/topic/screencast) or [following some tutorials](https://octobercms.com/support/articles/tutorials).
|
||||||
|
|
||||||
|
You may also watch these introductory videos for [beginners](https://vimeo.com/79963873) and [advanced users](https://vimeo.com/172202661).
|
||||||
|
|
||||||
|
## Development Team
|
||||||
|
|
||||||
|
October was created by [Alexey Bobkov](https://www.linkedin.com/in/alexey-bobkov-232ba02b/) and [Samuel Georges](https://www.linkedin.com/in/samuel-georges-0a964131/), who both continue to develop the platform.
|
||||||
|
|
||||||
|
## Foundation library
|
||||||
|
|
||||||
|
The CMS uses [Laravel](https://laravel.com) as a foundation PHP framework.
|
||||||
|
|
||||||
|
## Contact
|
||||||
|
|
||||||
|
You can communicate with us using the following mediums:
|
||||||
|
|
||||||
|
* [Follow us on Twitter](https://twitter.com/octobercms) for announcements and updates.
|
||||||
|
* [Follow us on Facebook](https://facebook.com/octobercms) for announcements and updates.
|
||||||
|
* [Join the Official Forum](https://octobercms.com/forum) to engage with the community.
|
||||||
|
* [Join us on Discord](https://octobercms.com/chat) to chat with us.
|
||||||
|
|
||||||
|
### Premium Support
|
||||||
|
|
||||||
|
October CMS can provide premium support for a monthly fee. Find out more via the [Premium Support Program](https://octobercms.com/premium-support).
|
||||||
|
|
||||||
|
## Contributing
|
||||||
|
|
||||||
|
Before sending a Pull Request, be sure to review the [Contributing Guidelines](.github/CONTRIBUTING.md) first. We are currently operating on a smaller staff and it may take some time to reach your issue. For priority issues, consider purchasing a [premium support plan](https://octobercms.com/premium-support).
|
||||||
|
|
||||||
|
### Coding standards
|
||||||
|
|
||||||
|
Please follow the following guides and code standards:
|
||||||
|
|
||||||
|
* [PSR 4 Autoloader](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-4-autoloader.md)
|
||||||
|
* [PSR 2 Coding Style Guide](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)
|
||||||
|
* [PSR 1 Coding Standards](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-1-basic-coding-standard.md)
|
||||||
|
|
||||||
|
### Code of Conduct
|
||||||
|
|
||||||
|
In order to ensure that the October CMS community is welcoming to all, please review and abide by the [Code of Conduct](CODE_OF_CONDUCT.md).
|
||||||
|
|
||||||
|
## License
|
||||||
|
|
||||||
|
The October CMS platform is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).
|
||||||
|
|
||||||
|
## Security Vulnerabilities
|
||||||
|
|
||||||
|
Please review [our security policy](https://github.com/octobercms/october/security/policy) on how to report security vulnerabilities.
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
# Security Policy
|
||||||
|
|
||||||
|
**Please do NOT disclose security-related issues in public, [see instructions below](#reporting-a-vulnerability).**
|
||||||
|
|
||||||
|
## Supported Versions
|
||||||
|
|
||||||
|
October CMS is an evergreen product, no one version is singled out for security fixes because there is no way to update just one version. Builds are continually released and security fixes will always be available in the latest build. We encourage all users to upgrade their websites to the latest version.
|
||||||
|
|
||||||
|
In cases where there are platform versioning constraints, such as old version of Laravel or PHP, we will make a best effort to backport security fixes to these compatible versions.
|
||||||
|
|
||||||
|
## Reporting a Vulnerability
|
||||||
|
|
||||||
|
If you discover a security vulnerability within October CMS, please send an email the security team at hello@octobercms.com. All security vulnerabilities will be promptly addressed.
|
||||||
|
|
@ -0,0 +1,51 @@
|
||||||
|
#!/usr/bin/env php
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Register The Auto Loader
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Composer provides a convenient, automatically generated class loader
|
||||||
|
| for our application. We just need to utilize it! We'll require it
|
||||||
|
| into the script here so that we do not have to worry about the
|
||||||
|
| loading of any our classes "manually". Feels great to relax.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
require __DIR__.'/bootstrap/autoload.php';
|
||||||
|
|
||||||
|
$app = require_once __DIR__.'/bootstrap/app.php';
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Run The Artisan Application
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| When we run the console application, the current CLI command will be
|
||||||
|
| executed in this console and the response sent back to a terminal
|
||||||
|
| or another output device for the developers. Here goes nothing!
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
$kernel = $app->make(Illuminate\Contracts\Console\Kernel::class);
|
||||||
|
|
||||||
|
$status = $kernel->handle(
|
||||||
|
$input = new Symfony\Component\Console\Input\ArgvInput,
|
||||||
|
new Symfony\Component\Console\Output\ConsoleOutput
|
||||||
|
);
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Shutdown The Application
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Once Artisan has finished running. We will fire off the shutdown events
|
||||||
|
| so that any final work may be done by the application before we shut
|
||||||
|
| down the process. This is the last thing to happen to the request.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
$kernel->terminate($input, $status);
|
||||||
|
|
||||||
|
exit($status);
|
||||||
|
|
@ -0,0 +1,55 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Create The Application
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The first thing we will do is create a new Laravel application instance
|
||||||
|
| which serves as the "glue" for all the components of Laravel, and is
|
||||||
|
| the IoC container for the system binding all of the various parts.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
$app = new October\Rain\Foundation\Application(
|
||||||
|
realpath(__DIR__.'/../')
|
||||||
|
);
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Bind Important Interfaces
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Next, we need to bind some important interfaces into the container so
|
||||||
|
| we will be able to resolve them when needed. The kernels serve the
|
||||||
|
| incoming requests to this application from both the web and CLI.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
$app->singleton(
|
||||||
|
Illuminate\Contracts\Http\Kernel::class,
|
||||||
|
October\Rain\Foundation\Http\Kernel::class
|
||||||
|
);
|
||||||
|
|
||||||
|
$app->singleton(
|
||||||
|
Illuminate\Contracts\Console\Kernel::class,
|
||||||
|
October\Rain\Foundation\Console\Kernel::class
|
||||||
|
);
|
||||||
|
|
||||||
|
$app->singleton(
|
||||||
|
Illuminate\Contracts\Debug\ExceptionHandler::class,
|
||||||
|
October\Rain\Foundation\Exception\Handler::class
|
||||||
|
);
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Return The Application
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This script returns the application instance. The instance is given to
|
||||||
|
| the calling script so we can separate the building of the instances
|
||||||
|
| from the actual running of the application and sending responses.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
return $app;
|
||||||
|
|
@ -0,0 +1,37 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
define('LARAVEL_START', microtime(true));
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Register Core Helpers
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| We cannot rely on Composer's load order when calculating the weight of
|
||||||
|
| each package. This line ensures that the core global helpers are
|
||||||
|
| always given priority one status.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
$helperPath = __DIR__.'/../vendor/october/rain/src/Support/helpers.php';
|
||||||
|
|
||||||
|
if (!file_exists($helperPath)) {
|
||||||
|
echo 'Missing vendor files, try running "composer install" or use the Wizard installer.'.PHP_EOL;
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
require $helperPath;
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Register The Composer Auto Loader
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Composer provides a convenient, automatically generated class loader
|
||||||
|
| for our application. We just need to utilize it! We'll require it
|
||||||
|
| into the script here so that we do not have to worry about the
|
||||||
|
| loading of any our classes "manually". Feels great to relax.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
require __DIR__.'/../vendor/autoload.php';
|
||||||
|
|
@ -0,0 +1,73 @@
|
||||||
|
{
|
||||||
|
"name": "october/october",
|
||||||
|
"description": "October CMS",
|
||||||
|
"homepage": "https://octobercms.com",
|
||||||
|
"type": "project",
|
||||||
|
"keywords": ["october", "cms", "octobercms", "laravel"],
|
||||||
|
"license": "MIT",
|
||||||
|
"authors": [
|
||||||
|
{
|
||||||
|
"name": "Alexey Bobkov",
|
||||||
|
"email": "aleksey.bobkov@gmail.com",
|
||||||
|
"role": "Co-founder"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Samuel Georges",
|
||||||
|
"email": "daftspunky@gmail.com",
|
||||||
|
"role": "Co-founder"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"support": {
|
||||||
|
"paid": "https://octobercms.com/premium-support",
|
||||||
|
"issues": "https://github.com/octobercms/october/issues",
|
||||||
|
"forum": "https://octobercms.com/forum/",
|
||||||
|
"docs": "https://octobercms.com/docs/",
|
||||||
|
"source": "https://github.com/octobercms/october"
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"php": ">=7.2.9",
|
||||||
|
"october/rain": "1.1.*",
|
||||||
|
"october/system": "1.1.*",
|
||||||
|
"october/backend": "1.1.*",
|
||||||
|
"october/cms": "1.1.*",
|
||||||
|
"laravel/framework": "~6.0"
|
||||||
|
},
|
||||||
|
"require-dev": {
|
||||||
|
"phpunit/phpunit": "^8.4|^9.3.3",
|
||||||
|
"mockery/mockery": "~1.3.3|^1.4.2",
|
||||||
|
"fzaninotto/faker": "~1.9",
|
||||||
|
"squizlabs/php_codesniffer": "3.*",
|
||||||
|
"php-parallel-lint/php-parallel-lint": "^1.0",
|
||||||
|
"dms/phpunit-arraysubset-asserts": "^0.1.0|^0.2.1"
|
||||||
|
},
|
||||||
|
"autoload-dev": {
|
||||||
|
"classmap": [
|
||||||
|
"tests/concerns/InteractsWithAuthentication.php",
|
||||||
|
"tests/fixtures/backend/models/UserFixture.php",
|
||||||
|
"tests/TestCase.php",
|
||||||
|
"tests/PluginTestCase.php"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"scripts": {
|
||||||
|
"post-create-project-cmd": [
|
||||||
|
"php artisan key:generate"
|
||||||
|
],
|
||||||
|
"post-update-cmd": [
|
||||||
|
"php artisan october:version"
|
||||||
|
],
|
||||||
|
"test": [
|
||||||
|
"phpunit --stop-on-failure"
|
||||||
|
],
|
||||||
|
"lint": [
|
||||||
|
"parallel-lint --exclude vendor --exclude storage --exclude tests/fixtures/plugins/testvendor/goto/Plugin.php ."
|
||||||
|
],
|
||||||
|
"sniff": [
|
||||||
|
"phpcs --colors -nq --report=\"full\" --extensions=\"php\""
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"config": {
|
||||||
|
"preferred-install": "dist"
|
||||||
|
},
|
||||||
|
"minimum-stability": "dev",
|
||||||
|
"prefer-stable": true
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,199 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Application Debug Mode
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| When your application is in debug mode, detailed error messages with
|
||||||
|
| stack traces will be shown on every error that occurs within your
|
||||||
|
| application. If disabled, a simple generic error page is shown.
|
||||||
|
|
|
||||||
|
| You can create a CMS page with route "/error" to set the contents
|
||||||
|
| of this page. Otherwise a default error page is shown.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'debug' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Application Name
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This value is the name of your application. This value is used when the
|
||||||
|
| framework needs to place the application's name in a notification or
|
||||||
|
| any other location as required by the application or its packages.
|
||||||
|
*/
|
||||||
|
|
||||||
|
'name' => 'October CMS',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Application URL
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This URL is used by the console to properly generate URLs when using
|
||||||
|
| the Artisan command line tool. You should set this to the root of
|
||||||
|
| your application so that it is used when running Artisan tasks.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'url' => 'http://localhost',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Trusted hosts
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| You may specify valid hosts for your application as an array or boolean
|
||||||
|
| below. This helps prevent host header poisoning attacks.
|
||||||
|
|
|
||||||
|
| Possible values:
|
||||||
|
| - `true`: Trust the host specified in app.url, as well as the "www"
|
||||||
|
| subdomain, if applicable.
|
||||||
|
| - `false`: Disable the trusted hosts feature.
|
||||||
|
| - array: Defines the domains to be trusted hosts. Each item should be
|
||||||
|
| a string defining a domain, IP address, or a regex pattern.
|
||||||
|
|
|
||||||
|
| Example of array values:
|
||||||
|
|
|
||||||
|
| 'trustedHosts' => [
|
||||||
|
| 'example.com', // Matches just example.com
|
||||||
|
| 'www.example.com', // Matches just www.example.com
|
||||||
|
| '^(.+\.)?example\.com$', // Matches example.com and all subdomains
|
||||||
|
| 'https://example.com', // Matches just example.com
|
||||||
|
| ],
|
||||||
|
|
|
||||||
|
| NOTE: Even when set to `false`, this functionality is explicitly enabled
|
||||||
|
| on the Backend password reset flow for security reasons.
|
||||||
|
*/
|
||||||
|
|
||||||
|
'trustedHosts' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Application Timezone
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may specify the default timezone for your application, which
|
||||||
|
| will be used by the PHP date and date-time functions. We have gone
|
||||||
|
| ahead and set this to a sensible default for you out of the box.
|
||||||
|
|
|
||||||
|
|
|
||||||
|
| -------- STOP! --------
|
||||||
|
| Before you change this value, consider carefully if that is actually
|
||||||
|
| what you want to do. It is HIGHLY recommended that this is always set
|
||||||
|
| to UTC (as your server & DB timezone should be as well) and instead you
|
||||||
|
| use cms.backendTimezone to set the default timezone used in the backend
|
||||||
|
| to display dates & times.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'timezone' => 'UTC',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Application Locale Configuration
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The application locale determines the default locale that will be used
|
||||||
|
| by the translation service provider. You are free to set this value
|
||||||
|
| to any of the locales which will be supported by the application.
|
||||||
|
|
|
||||||
|
| WARNING: Avoid setting this to a locale that is not supported by the
|
||||||
|
| backend yet, as this can cause issues in the backend.
|
||||||
|
|
|
||||||
|
| Currently supported backend locales are listed in
|
||||||
|
| Backend\Models\Preference->getLocaleOptions())
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'locale' => 'en',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Application Fallback Locale
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The fallback locale determines the locale to use when the current one
|
||||||
|
| is not available. You may change the value to correspond to any of
|
||||||
|
| the language folders that are provided through your application.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'fallback_locale' => 'en',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Encryption Key
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This key is used by the Illuminate encrypter service and should be set
|
||||||
|
| to a random, 32 character string, otherwise these encrypted strings
|
||||||
|
| will not be safe. Please do this before deploying an application!
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'key' => 'yXK5LlJbDEh8DLyRbkK1LXivSmw6GscH',
|
||||||
|
|
||||||
|
'cipher' => 'AES-256-CBC',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Autoloaded Service Providers
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The service providers listed here will be automatically loaded on the
|
||||||
|
| request to your application. Feel free to add your own services to
|
||||||
|
| this array to grant expanded functionality to your applications.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'providers' => array_merge(include(base_path('modules/system/providers.php')), [
|
||||||
|
|
||||||
|
// 'Illuminate\Html\HtmlServiceProvider', // Example
|
||||||
|
|
||||||
|
'System\ServiceProvider',
|
||||||
|
]),
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Load automatically discovered packages
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| By default, October CMS disables the loading of discovered packages
|
||||||
|
| through Laravel's package discovery service, in order to allow packages
|
||||||
|
| used by plugins to be disabled if the plugin itself is disabled.
|
||||||
|
|
|
||||||
|
| Set this to `true` to enable automatic loading of these packages. This
|
||||||
|
| will result in packages being loaded, even if the plugin using them is
|
||||||
|
| disabled. This is NOT RECOMMENDED.
|
||||||
|
|
|
||||||
|
| Please note that packages defined in `app.providers` will still be loaded
|
||||||
|
| even if discovery is disabled.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'loadDiscoveredPackages' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Class Aliases
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This array of class aliases will be registered when this application
|
||||||
|
| is started. However, feel free to register as many as you wish as
|
||||||
|
| the aliases are "lazy" loaded so they don't hinder performance.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'aliases' => array_merge(include(base_path('modules/system/aliases.php')), [
|
||||||
|
|
||||||
|
// 'Str' => 'Illuminate\Support\Str', // Example
|
||||||
|
|
||||||
|
]),
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,39 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
'throttle' => [
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Enable throttling of Backend authentication attempts
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If set to true, users will be given a limited number of attempts to sign
|
||||||
|
| in to the Backend before being blocked for a specified number of minutes.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
'enabled' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Failed Authentication Attempt Limit
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Number of failed attempts allowed while trying to authenticate a user.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
'attemptLimit' => 5,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Suspension Time
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The number of minutes to suspend further attempts on authentication once
|
||||||
|
| the attempt limit is reached.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
'suspensionTime' => 15,
|
||||||
|
],
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Broadcaster
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This option controls the default broadcaster that will be used by the
|
||||||
|
| framework when an event needs to be broadcast. You may set this to
|
||||||
|
| any of the connections defined in the "connections" array below.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'default' => 'pusher',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Broadcast Connections
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may define all of the broadcast connections that will be used
|
||||||
|
| to broadcast events to other systems or over websockets. Samples of
|
||||||
|
| each available type of connection are provided inside this array.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'connections' => [
|
||||||
|
|
||||||
|
'pusher' => [
|
||||||
|
'driver' => 'pusher',
|
||||||
|
'key' => '',
|
||||||
|
'secret' => '',
|
||||||
|
'app_id' => '',
|
||||||
|
'options' => [
|
||||||
|
//
|
||||||
|
],
|
||||||
|
],
|
||||||
|
|
||||||
|
'redis' => [
|
||||||
|
'driver' => 'redis',
|
||||||
|
'connection' => 'default',
|
||||||
|
],
|
||||||
|
|
||||||
|
'log' => [
|
||||||
|
'driver' => 'log',
|
||||||
|
],
|
||||||
|
|
||||||
|
],
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,116 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Cache Store
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This option controls the default cache connection that gets used while
|
||||||
|
| using this caching library. This connection is used when another is
|
||||||
|
| not explicitly specified when executing a given caching function.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'default' => 'file',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Cache Stores
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may define all of the cache "stores" for your application as
|
||||||
|
| well as their drivers. You may even define multiple stores for the
|
||||||
|
| same cache driver to group types of items stored in your caches.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'stores' => [
|
||||||
|
|
||||||
|
'apc' => [
|
||||||
|
'driver' => 'apc',
|
||||||
|
],
|
||||||
|
|
||||||
|
'array' => [
|
||||||
|
'driver' => 'array',
|
||||||
|
],
|
||||||
|
|
||||||
|
'database' => [
|
||||||
|
'driver' => 'database',
|
||||||
|
'table' => 'cache',
|
||||||
|
'connection' => null,
|
||||||
|
],
|
||||||
|
|
||||||
|
'file' => [
|
||||||
|
'driver' => 'file',
|
||||||
|
'path' => storage_path('framework/cache'),
|
||||||
|
],
|
||||||
|
|
||||||
|
'memcached' => [
|
||||||
|
'driver' => 'memcached',
|
||||||
|
'servers' => [
|
||||||
|
[
|
||||||
|
'host' => '127.0.0.1',
|
||||||
|
'port' => 11211,
|
||||||
|
'weight' => 100,
|
||||||
|
],
|
||||||
|
],
|
||||||
|
],
|
||||||
|
|
||||||
|
'redis' => [
|
||||||
|
'driver' => 'redis',
|
||||||
|
'connection' => 'default',
|
||||||
|
],
|
||||||
|
|
||||||
|
],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Cache Key Prefix
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| When utilizing a RAM based store such as APC or Memcached, there might
|
||||||
|
| be other applications utilizing the same cache. So, we'll specify a
|
||||||
|
| value to get prefixed to all our keys so we can avoid collisions.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'prefix' => 'october',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Cache Key for the CMS' PHP code parser cache
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This option controls the cache key used by the CMS when storing generated
|
||||||
|
| PHP from the theme PHP sections. Recommended to change this when multiple
|
||||||
|
| servers running OctoberCMS are connected to the same cache server to
|
||||||
|
| prevent conflicts.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'codeParserDataCacheKey' => 'cms-php-file-data',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Disable Request Cache
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The request cache stores cache retrievals from the cache store
|
||||||
|
| in memory to speed up consecutive retrievals within the same request.
|
||||||
|
|
|
||||||
|
| true - always disable this in-memory request cache
|
||||||
|
|
|
||||||
|
| false - always enable; be aware that long-running console commands
|
||||||
|
| (including queue workers) may retain cache entries in memory that
|
||||||
|
| have been changed in other processes or would have otherwise
|
||||||
|
| expired, causing issues with the `queue:restart` command, for
|
||||||
|
| example
|
||||||
|
|
|
||||||
|
| null - enable for HTTP requests, disable when running in CLI
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'disableRequestCache' => null,
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,470 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Specifies the default CMS theme.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This parameter value can be overridden by the CMS back-end settings.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'activeTheme' => 'demo',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Bleeding edge updates
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If you are developing with October, it is important to have the latest
|
||||||
|
| code base. Set this value to 'true' to tell the platform to download
|
||||||
|
| and use the development copies of core files and plugins.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'edgeUpdates' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Back-end URI prefix
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies the URL name used for accessing back-end pages.
|
||||||
|
| For example: backend -> http://localhost/backend
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'backendUri' => 'backend',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Back-end force HTTPS security
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Use this setting to force a secure protocol when accessing any back-end
|
||||||
|
| pages, including the authentication pages. This is usually handled by
|
||||||
|
| web server config, but can be handled by the app for added security.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'backendForceSecure' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Back-end login remember
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Define live duration of backend sessions:
|
||||||
|
|
|
||||||
|
| true - session never expire (cookie expiration in 5 years)
|
||||||
|
|
|
||||||
|
| false - session have a limited time (see session.lifetime)
|
||||||
|
|
|
||||||
|
| null - The form login display a checkbox that allow user to choose
|
||||||
|
| wanted behavior
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'backendForceRemember' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Back-end timezone
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This acts as the default setting for a back-end user's timezone. This can
|
||||||
|
| be changed by the user at any time using the backend preferences. All
|
||||||
|
| dates displayed in the back-end will be converted to this timezone.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'backendTimezone' => 'UTC',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Back-end Skin
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies the back-end skin to use.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'backendSkin' => 'Backend\Skins\Standard',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Automatically run migrations on login
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If value is true, UpdateManager will be run on logging in to the backend.
|
||||||
|
| It's recommended to set this value to 'null' in production enviroments
|
||||||
|
| because it clears the cache every time a user logs in to the backend.
|
||||||
|
| If set to null, this setting is enabled when debug mode (app.debug) is enabled
|
||||||
|
| and disabled when debug mode is disabled.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'runMigrationsOnLogin' => null,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Determines which modules to load
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specify which modules should be registered when using the application.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'loadModules' => ['System', 'Backend', 'Cms'],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Prevents application updates
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If using composer or git to download updates to the core files, set this
|
||||||
|
| value to 'true' to prevent the update gateway from trying to download
|
||||||
|
| these files again as part of the application update process. Plugins
|
||||||
|
| and themes will still be downloaded.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'disableCoreUpdates' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Specific plugins to disable
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specify plugin codes which will always be disabled in the application.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'disablePlugins' => [],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Determines if the routing caching is enabled.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If the caching is enabled, the page URL map is saved in the cache. If a page
|
||||||
|
| URL was changed on the disk, the old URL value could be still saved in the cache.
|
||||||
|
| To update the cache the back-end Clear Cache feature should be used. It is recommended
|
||||||
|
| to disable the caching during the development, and enable it in the production mode.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableRoutesCache' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Time to live for the URL map.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The URL map used in the CMS page routing process. By default
|
||||||
|
| the map is updated every time when a page is saved in the back-end or when the
|
||||||
|
| interval, in minutes, specified with the urlMapCacheTTL parameter expires.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'urlCacheTtl' => 10,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Time to live for parsed CMS objects.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies the number of minutes the CMS object cache lives. After the interval
|
||||||
|
| is expired item are re-cached. Note that items are re-cached automatically when
|
||||||
|
| the corresponding template file is modified.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'parsedPageCacheTTL' => 10,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Determines if the asset caching is enabled.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If the caching is enabled, combined assets are cached. If a asset file
|
||||||
|
| is changed on the disk, the old file contents could be still saved in the cache.
|
||||||
|
| To update the cache the back-end Clear Cache feature should be used. It is recommended
|
||||||
|
| to disable the caching during the development, and enable it in the production mode.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableAssetCache' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Determines if the asset minification is enabled.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If the minification is enabled, combined assets are compressed (minified).
|
||||||
|
| It is recommended to disable the minification during development, and
|
||||||
|
| enable it in production mode. If set to null, assets are minified
|
||||||
|
| when debug mode (app.debug) is disabled.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableAssetMinify' => null,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Check import timestamps when combining assets
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If deep hashing is enabled, the combiner cache will be reset when a change
|
||||||
|
| is detected on imported files, in addition to those referenced directly.
|
||||||
|
| This will cause slower page performance. If set to null, deep hashing
|
||||||
|
| is used when debug mode (app.debug) is enabled.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableAssetDeepHashing' => null,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Database-driven Themes
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Stores theme templates in the database instead of the filesystem.
|
||||||
|
|
|
||||||
|
| false - All theme templates are sourced from the filesystem.
|
||||||
|
|
|
||||||
|
| true - Source theme templates from the database with fallback to the filesytem.
|
||||||
|
|
|
||||||
|
| null - Setting equal to the inverse of app.debug: debug enabled, this disabled.
|
||||||
|
|
|
||||||
|
| The database layer stores all modified CMS files in the database. Files that are
|
||||||
|
| not modified continue to be loaded from the filesystem. The `theme:sync $themeDir`
|
||||||
|
| console command is available to populate the database from the filesystem with
|
||||||
|
| the `--toFile` flag to sync in the other direction (database to filesystem) and
|
||||||
|
| the `--paths="/path/to/file.md,/path/to/file2.md" flag to sync only specific files.
|
||||||
|
|
|
||||||
|
| Files modified in the database are cached to indicate that they should be loaded
|
||||||
|
| from the database.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'databaseTemplates' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Public plugins path
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies the public plugins path relative to the application base URL,
|
||||||
|
| or you can specify a full URL path.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'pluginsPath' => '/plugins',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Public themes path
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies the public themes path relative to the application base URL,
|
||||||
|
| or you can specify a full URL path.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'themesPath' => '/themes',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Resource storage
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies the configuration for resource storage, such as media and
|
||||||
|
| upload files. These resources are used:
|
||||||
|
|
|
||||||
|
| media - generated by the media manager.
|
||||||
|
| uploads - generated by attachment model relationships.
|
||||||
|
| resized - generated by System\Classes\ImageResizer or the resize() Twig filter
|
||||||
|
|
|
||||||
|
| For each resource you can specify:
|
||||||
|
|
|
||||||
|
| disk - filesystem disk, as specified in filesystems.php config.
|
||||||
|
| folder - a folder prefix for storing all generated files inside.
|
||||||
|
| path - the public path relative to the application base URL,
|
||||||
|
| or you can specify a full URL path.
|
||||||
|
|
|
||||||
|
| Optionally, you can specify how long temporary URLs to protected files
|
||||||
|
| in cloud storage (ex. AWS, RackSpace) are valid for by setting
|
||||||
|
| temporaryUrlTTL to a value in seconds to define a validity period. This
|
||||||
|
| is only used for the 'uploads' config when using a supported cloud disk
|
||||||
|
|
|
||||||
|
| NOTE: If you have installed October in a subfolder, are using local
|
||||||
|
| storage and are not using a linkPolicy of 'force' you should include
|
||||||
|
| the path to the subfolder in the `path` option for these storage
|
||||||
|
| configurations.
|
||||||
|
|
|
||||||
|
| Example: October is installed under https://localhost/projects/october.
|
||||||
|
| You should then specify `/projects/october/storage/app/uploads` as the
|
||||||
|
| path for the uploads disk and `/projects/october/storage/app/media` as
|
||||||
|
| the path for the media disk.
|
||||||
|
*/
|
||||||
|
|
||||||
|
'storage' => [
|
||||||
|
|
||||||
|
'uploads' => [
|
||||||
|
'disk' => 'local',
|
||||||
|
'folder' => 'uploads',
|
||||||
|
'path' => '/storage/app/uploads',
|
||||||
|
'temporaryUrlTTL' => 3600,
|
||||||
|
],
|
||||||
|
|
||||||
|
'media' => [
|
||||||
|
'disk' => 'local',
|
||||||
|
'folder' => 'media',
|
||||||
|
'path' => '/storage/app/media',
|
||||||
|
],
|
||||||
|
|
||||||
|
'resized' => [
|
||||||
|
'disk' => 'local',
|
||||||
|
'folder' => 'resized',
|
||||||
|
'path' => '/storage/app/resized',
|
||||||
|
],
|
||||||
|
|
||||||
|
],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Convert Line Endings
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Determines if October should convert line endings from the windows style
|
||||||
|
| \r\n to the unix style \n.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'convertLineEndings' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Linking policy
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Controls how URL links are generated throughout the application.
|
||||||
|
|
|
||||||
|
| detect - detect hostname and use the current schema
|
||||||
|
| secure - detect hostname and force HTTPS schema
|
||||||
|
| insecure - detect hostname and force HTTP schema
|
||||||
|
| force - force hostname and schema using app.url config value
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'linkPolicy' => 'detect',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default permission mask
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies a default file and folder permission for newly created objects.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'defaultMask' => ['file' => '777', 'folder' => '777'],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Safe mode
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If safe mode is enabled, the PHP code section is disabled in the CMS
|
||||||
|
| for security reasons. If set to null, safe mode is enabled when
|
||||||
|
| debug mode (app.debug) is disabled.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableSafeMode' => null,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Cross Site Request Forgery (CSRF) Protection
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If the CSRF protection is enabled, all "postback" & AJAX requests are
|
||||||
|
| checked for a valid security token.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableCsrfProtection' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Force bytecode invalidation
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| When using OPcache with opcache.validate_timestamps set to 0 or APC
|
||||||
|
| with apc.stat set to 0 and Twig cache enabled, clearing the template
|
||||||
|
| cache won't update the cache, set to true to get around this.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'forceBytecodeInvalidation' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Twig Strict Variables
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If strict_variables is disabled, Twig will silently ignore invalid
|
||||||
|
| variables (variables and or attributes/methods that do not exist) and
|
||||||
|
| replace them with a null value. When enabled, Twig throws an exception
|
||||||
|
| instead. If set to null, it is enabled when debug mode (app.debug) is
|
||||||
|
| enabled.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableTwigStrictVariables' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Base Directory Restriction
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Restricts loading backend template and config files to within the base
|
||||||
|
| directory of the application.
|
||||||
|
|
|
||||||
|
| WARNING: This should always be enabled for security reasons. However, in
|
||||||
|
| some cases you may need to disable this; for instance when developing
|
||||||
|
| plugins that are stored elsewhere in the filesystem for organizational
|
||||||
|
| reasons and then symlinked into the application plugins/ directory.
|
||||||
|
|
|
||||||
|
| NEVER have this disabled in production.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'restrictBaseDir' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Backend Service Worker
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Allow plugins to run Service Workers in the backend.
|
||||||
|
|
|
||||||
|
| WARNING: This should always be disabled for security reasons as Service
|
||||||
|
| Workers can be hijacked and used to run XSS into the backend. Turning
|
||||||
|
| this feature on can create a conflict if you have a frontend Service
|
||||||
|
| Worker running. The 'scope' needs to be correctly set and not have a
|
||||||
|
| duplicate subfolder structure on the frontend, otherwise it will run
|
||||||
|
| on both the frontend and backend of your website.
|
||||||
|
|
|
||||||
|
| true - allow service workers to run in the backend
|
||||||
|
|
|
||||||
|
| false - disallow service workers to run in the backend
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableBackendServiceWorkers' => false,
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,21 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Cookies that should not be encrypted
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| OctoberCMS encrypts/decrypts cookies by default. You can specify cookies
|
||||||
|
| that should not be encrypted or decrypted here. This is useful, for
|
||||||
|
| example, when you want to pass data from frontend to server side backend
|
||||||
|
| via cookies, and vice versa.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'unencryptedCookies' => [
|
||||||
|
// 'my_cookie',
|
||||||
|
],
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,148 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| PDO Fetch Style
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| By default, database results will be returned as instances of the PHP
|
||||||
|
| stdClass object; however, you may desire to retrieve records in an
|
||||||
|
| array format for simplicity. Here you can tweak the fetch style.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'fetch' => PDO::FETCH_CLASS,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Database Connection Name
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may specify which of the database connections below you wish
|
||||||
|
| to use as your default connection for all database work. Of course
|
||||||
|
| you may use many connections at once using the Database library.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'default' => 'mysql',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Database Connections
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here are each of the database connections setup for your application.
|
||||||
|
| Of course, examples of configuring each database platform that is
|
||||||
|
| supported by Laravel is shown below to make development simple.
|
||||||
|
|
|
||||||
|
|
|
||||||
|
| All database work in Laravel is done through the PHP PDO facilities
|
||||||
|
| so make sure you have the driver for your particular database of
|
||||||
|
| choice installed on your machine before you begin development.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'connections' => [
|
||||||
|
|
||||||
|
'sqlite' => [
|
||||||
|
'driver' => 'sqlite',
|
||||||
|
'database' => 'storage/database.sqlite',
|
||||||
|
'prefix' => '',
|
||||||
|
],
|
||||||
|
|
||||||
|
'mysql' => [
|
||||||
|
'driver' => 'mysql',
|
||||||
|
'engine' => 'InnoDB',
|
||||||
|
'host' => 'localhost',
|
||||||
|
'port' => 3306,
|
||||||
|
'database' => 'tkf3',
|
||||||
|
'username' => 'root',
|
||||||
|
'password' => 'bt110226',
|
||||||
|
'charset' => 'utf8mb4',
|
||||||
|
'collation' => 'utf8mb4_unicode_ci',
|
||||||
|
'prefix' => '',
|
||||||
|
'varcharmax' => 191,
|
||||||
|
],
|
||||||
|
|
||||||
|
'pgsql' => [
|
||||||
|
'driver' => 'pgsql',
|
||||||
|
'host' => 'localhost',
|
||||||
|
'port' => 5432,
|
||||||
|
'database' => 'database',
|
||||||
|
'username' => 'root',
|
||||||
|
'password' => '',
|
||||||
|
'charset' => 'utf8',
|
||||||
|
'prefix' => '',
|
||||||
|
'schema' => 'public',
|
||||||
|
],
|
||||||
|
|
||||||
|
'sqlsrv' => [
|
||||||
|
'driver' => 'sqlsrv',
|
||||||
|
'host' => 'localhost',
|
||||||
|
'port' => 1433,
|
||||||
|
'database' => 'database',
|
||||||
|
'username' => 'root',
|
||||||
|
'password' => '',
|
||||||
|
'prefix' => '',
|
||||||
|
],
|
||||||
|
|
||||||
|
],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Migration Repository Table
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This table keeps track of all the migrations that have already run for
|
||||||
|
| your application. Using this information, we can determine which of
|
||||||
|
| the migrations on disk have not actually be run in the databases.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'migrations' => 'migrations',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Redis Databases
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Redis is an open source, fast, and advanced key-value store that also
|
||||||
|
| provides a richer set of commands than a typical key-value systems
|
||||||
|
| such as APC or Memcached. Laravel makes it easy to dig right in.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'redis' => [
|
||||||
|
|
||||||
|
'client' => 'predis',
|
||||||
|
'cluster' => false,
|
||||||
|
|
||||||
|
'default' => [
|
||||||
|
'host' => '127.0.0.1',
|
||||||
|
'password' => null,
|
||||||
|
'port' => 6379,
|
||||||
|
'database' => 0,
|
||||||
|
],
|
||||||
|
|
||||||
|
],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Use DB configuration for testing
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| When running plugin tests OctoberCMS by default uses SQLite in memory.
|
||||||
|
| You can override this behavior by setting `useConfigForTesting` to true.
|
||||||
|
|
|
||||||
|
| After that OctoberCMS will take DB parameters from the config.
|
||||||
|
| If file `/config/testing/database.php` exists, config will be read from it,
|
||||||
|
| but remember that when not specified it will use parameters specified in
|
||||||
|
| `/config/database.php`.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'useConfigForTesting' => false,
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,2 @@
|
||||||
|
*
|
||||||
|
!.gitignore
|
||||||
|
|
@ -0,0 +1,46 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Decompile backend assets
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Enabling this will load all individual backend asset files, instead of
|
||||||
|
| loading the compiled asset files generated by `october:util compile
|
||||||
|
| assets`. This is useful only for development purposes, and should not be
|
||||||
|
| enabled in production. Please note that enabling this will make the
|
||||||
|
| Backend load a LOT of individual asset files.
|
||||||
|
|
|
||||||
|
| true - allow decompiled backend assets
|
||||||
|
|
|
||||||
|
| false - use compiled backend assets (default)
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'decompileBackendAssets' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Allow deep-level symlinks
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| October CMS, by default, will allow symlinks within the first level of
|
||||||
|
| subdirectories. When this feature is enabled, the system will allow
|
||||||
|
| symlinks to be used at any directory level. This can be useful for
|
||||||
|
| symlinking individual plugins or themes.
|
||||||
|
|
|
||||||
|
| Please note that this has a negative effect on performance. This feature
|
||||||
|
| abides by "cms.restrictBaseDir" - if enabled, symlinks cannot point to
|
||||||
|
| resources outside of the root folder.
|
||||||
|
|
|
||||||
|
| true - allow symlinks at any level
|
||||||
|
|
|
||||||
|
| false - only allow symlinks at the first level of subdirectories (default)
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'allowDeepSymlinks' => false,
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,35 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Application Environment
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This value determines the "environment" your application is currently
|
||||||
|
| running in. This may determine how you prefer to configure various
|
||||||
|
| services your application utilizes. Set this in your ".env" file.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'default' => 'development',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Environment Multitenancy
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| You may specify a different environment according to the hostname that
|
||||||
|
| is provided with the HTTP request. This is useful if you want to use
|
||||||
|
| different configuration, such as database and theme, per hostname.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'hosts' => [
|
||||||
|
|
||||||
|
'localhost' => 'dev',
|
||||||
|
|
||||||
|
],
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,71 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Filesystem Disk
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may specify the default filesystem disk that should be used
|
||||||
|
| by the framework. A "local" driver, as well as a variety of cloud
|
||||||
|
| based drivers are available for your choosing. Just store away!
|
||||||
|
|
|
||||||
|
| Supported: "local", "ftp", "sftp", "s3", "rackspace"
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'default' => 'local',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Cloud Filesystem Disk
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Many applications store files both locally and in the cloud. For this
|
||||||
|
| reason, you may specify a default "cloud" driver here. This driver
|
||||||
|
| will be bound as the Cloud disk implementation in the container.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'cloud' => 's3',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Filesystem Disks
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may configure as many filesystem "disks" as you wish, and you
|
||||||
|
| may even configure multiple disks of the same driver. Defaults have
|
||||||
|
| been setup for each driver as an example of the required options.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'disks' => [
|
||||||
|
|
||||||
|
'local' => [
|
||||||
|
'driver' => 'local',
|
||||||
|
'root' => storage_path('app'),
|
||||||
|
'url' => '/storage/app',
|
||||||
|
],
|
||||||
|
|
||||||
|
's3' => [
|
||||||
|
'driver' => 's3',
|
||||||
|
'key' => 'your-key',
|
||||||
|
'secret' => 'your-secret',
|
||||||
|
'region' => 'your-region',
|
||||||
|
'bucket' => 'your-bucket',
|
||||||
|
],
|
||||||
|
|
||||||
|
'rackspace' => [
|
||||||
|
'driver' => 'rackspace',
|
||||||
|
'username' => 'your-username',
|
||||||
|
'key' => 'your-key',
|
||||||
|
'container' => 'your-container',
|
||||||
|
'endpoint' => 'https://identity.api.rackspacecloud.com/v2.0/',
|
||||||
|
'region' => 'IAD',
|
||||||
|
],
|
||||||
|
|
||||||
|
],
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Hash Driver
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This option controls the default hash driver that will be used to hash
|
||||||
|
| passwords for your application. By default, the bcrypt algorithm is
|
||||||
|
| used; however, you remain free to modify this option if you wish.
|
||||||
|
|
|
||||||
|
| Supported: "bcrypt", "argon", "argon2id"
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'driver' => 'bcrypt',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Bcrypt Options
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may specify the configuration options that should be used when
|
||||||
|
| passwords are hashed using the Bcrypt algorithm. This will allow you
|
||||||
|
| to control the amount of time it takes to hash the given password.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'bcrypt' => [
|
||||||
|
'rounds' => env('BCRYPT_ROUNDS', 10),
|
||||||
|
],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Argon Options
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may specify the configuration options that should be used when
|
||||||
|
| passwords are hashed using the Argon algorithm. These will allow you
|
||||||
|
| to control the amount of time it takes to hash the given password.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'argon' => [
|
||||||
|
'memory' => 1024,
|
||||||
|
'threads' => 2,
|
||||||
|
'time' => 2,
|
||||||
|
],
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,91 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Log Channel
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This option defines the default log channel that gets used when writing
|
||||||
|
| messages to the logs. The name specified in this option should match
|
||||||
|
| one of the channels defined in the "channels" configuration array.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'default' => env('LOG_CHANNEL', 'single'),
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Log Channels
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may configure the log channels for your application. Out of
|
||||||
|
| the box, Laravel uses the Monolog PHP logging library. This gives
|
||||||
|
| you a variety of powerful log handlers / formatters to utilize.
|
||||||
|
|
|
||||||
|
| Available Drivers: "single", "daily", "slack", "syslog",
|
||||||
|
| "errorlog", "monolog",
|
||||||
|
| "custom", "stack"
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'channels' => [
|
||||||
|
'stack' => [
|
||||||
|
'driver' => 'stack',
|
||||||
|
'channels' => ['daily'],
|
||||||
|
'ignore_exceptions' => false,
|
||||||
|
],
|
||||||
|
|
||||||
|
'single' => [
|
||||||
|
'driver' => 'single',
|
||||||
|
'path' => storage_path('logs/system.log'),
|
||||||
|
'level' => 'debug',
|
||||||
|
],
|
||||||
|
|
||||||
|
'daily' => [
|
||||||
|
'driver' => 'daily',
|
||||||
|
'path' => storage_path('logs/system.log'),
|
||||||
|
'level' => 'debug',
|
||||||
|
'days' => 14,
|
||||||
|
],
|
||||||
|
|
||||||
|
'slack' => [
|
||||||
|
'driver' => 'slack',
|
||||||
|
'url' => env('LOG_SLACK_WEBHOOK_URL'),
|
||||||
|
'username' => 'October CMS Log',
|
||||||
|
'emoji' => ':boom:',
|
||||||
|
'level' => 'critical',
|
||||||
|
],
|
||||||
|
|
||||||
|
'papertrail' => [
|
||||||
|
'driver' => 'monolog',
|
||||||
|
'level' => 'debug',
|
||||||
|
'handler' => \Monolog\Handler\SyslogUdpHandler::class,
|
||||||
|
'handler_with' => [
|
||||||
|
'host' => env('PAPERTRAIL_URL'),
|
||||||
|
'port' => env('PAPERTRAIL_PORT'),
|
||||||
|
],
|
||||||
|
],
|
||||||
|
|
||||||
|
'stderr' => [
|
||||||
|
'driver' => 'monolog',
|
||||||
|
'handler' => \Monolog\Handler\StreamHandler::class,
|
||||||
|
'formatter' => env('LOG_STDERR_FORMATTER'),
|
||||||
|
'with' => [
|
||||||
|
'stream' => 'php://stderr',
|
||||||
|
],
|
||||||
|
],
|
||||||
|
|
||||||
|
'syslog' => [
|
||||||
|
'driver' => 'syslog',
|
||||||
|
'level' => 'debug',
|
||||||
|
],
|
||||||
|
|
||||||
|
'errorlog' => [
|
||||||
|
'driver' => 'errorlog',
|
||||||
|
'level' => 'debug',
|
||||||
|
],
|
||||||
|
],
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,115 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Mail Driver
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Laravel supports both SMTP and PHP's "mail" function as drivers for the
|
||||||
|
| sending of e-mail. You may specify which one you're using throughout
|
||||||
|
| your application here. By default, Laravel is setup for SMTP mail.
|
||||||
|
|
|
||||||
|
| Supported: "smtp", "sendmail", "mailgun", "mandrill", "ses",
|
||||||
|
| "postmark", "sparkpost", "log", "array"
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'driver' => 'smtp',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| SMTP Host Address
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may provide the host address of the SMTP server used by your
|
||||||
|
| applications. A default option is provided that is compatible with
|
||||||
|
| the Mailgun mail service which will provide reliable deliveries.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'host' => 'smtp.mailgun.org',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| SMTP Host Port
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This is the SMTP port used by your application to deliver e-mails to
|
||||||
|
| users of the application. Like the host we have set this value to
|
||||||
|
| stay compatible with the Mailgun e-mail application by default.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'port' => 587,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Global "From" Address
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| You may wish for all e-mails sent by your application to be sent from
|
||||||
|
| the same address. Here, you may specify a name and address that is
|
||||||
|
| used globally for all e-mails that are sent by your application.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'from' => [
|
||||||
|
'address' => 'noreply@domain.tld',
|
||||||
|
'name' => 'OctoberCMS',
|
||||||
|
],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| E-Mail Encryption Protocol
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may specify the encryption protocol that should be used when
|
||||||
|
| the application send e-mail messages. A sensible default using the
|
||||||
|
| transport layer security protocol should provide great security.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'encryption' => 'tls',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| SMTP Server Username
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If your SMTP server requires a username for authentication, you should
|
||||||
|
| set it here. This will get used to authenticate with your server on
|
||||||
|
| connection. You may also set the "password" value below this one.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'username' => null,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| SMTP Server Password
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may set the password required by your SMTP server to send out
|
||||||
|
| messages from your application. This will be given to the server on
|
||||||
|
| connection so that the application will be able to send messages.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'password' => null,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Sendmail System Path
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| When using the "sendmail" driver to send e-mails, we will need to know
|
||||||
|
| the path to where Sendmail lives on this server. A default path has
|
||||||
|
| been provided here, which will work well on most of your systems.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'sendmail' => '/usr/sbin/sendmail -bs',
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,93 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Queue Driver
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The Laravel queue API supports a variety of back-ends via an unified
|
||||||
|
| API, giving you convenient access to each back-end using the same
|
||||||
|
| syntax for each one. Here you may set the default queue driver.
|
||||||
|
|
|
||||||
|
| Supported: "null", "sync", "database", "beanstalkd",
|
||||||
|
| "sqs", "iron", "redis"
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'default' => 'sync',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Queue Connections
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may configure the connection information for each server that
|
||||||
|
| is used by your application. A default configuration has been added
|
||||||
|
| for each back-end shipped with Laravel. You are free to add more.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'connections' => [
|
||||||
|
|
||||||
|
'sync' => [
|
||||||
|
'driver' => 'sync',
|
||||||
|
],
|
||||||
|
|
||||||
|
'database' => [
|
||||||
|
'driver' => 'database',
|
||||||
|
'table' => 'jobs',
|
||||||
|
'queue' => 'default',
|
||||||
|
'expire' => 60,
|
||||||
|
],
|
||||||
|
|
||||||
|
'beanstalkd' => [
|
||||||
|
'driver' => 'beanstalkd',
|
||||||
|
'host' => 'localhost',
|
||||||
|
'queue' => 'default',
|
||||||
|
'ttr' => 60,
|
||||||
|
],
|
||||||
|
|
||||||
|
'sqs' => [
|
||||||
|
'driver' => 'sqs',
|
||||||
|
'key' => 'your-public-key',
|
||||||
|
'secret' => 'your-secret-key',
|
||||||
|
'queue' => 'your-queue-url',
|
||||||
|
'region' => 'us-east-1',
|
||||||
|
],
|
||||||
|
|
||||||
|
'iron' => [
|
||||||
|
'driver' => 'iron',
|
||||||
|
'host' => 'mq-aws-us-east-1.iron.io',
|
||||||
|
'token' => 'your-token',
|
||||||
|
'project' => 'your-project-id',
|
||||||
|
'queue' => 'your-queue-name',
|
||||||
|
'encrypt' => true,
|
||||||
|
],
|
||||||
|
|
||||||
|
'redis' => [
|
||||||
|
'driver' => 'redis',
|
||||||
|
'queue' => 'default',
|
||||||
|
'expire' => 60,
|
||||||
|
],
|
||||||
|
|
||||||
|
],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Failed Queue Jobs
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| These options configure the behavior of failed queue job logging so you
|
||||||
|
| can control which database and table are used to store the jobs that
|
||||||
|
| have failed. You may change them to any database / table you wish.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'failed' => [
|
||||||
|
'database' => 'mysql',
|
||||||
|
'table' => 'failed_jobs',
|
||||||
|
],
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,46 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Third Party Services
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This file is for storing the credentials for third party services such
|
||||||
|
| as Stripe, Mailgun, Mandrill, and others. This file provides a sane
|
||||||
|
| default location for this type of information, allowing packages
|
||||||
|
| to have a conventional place to find your various credentials.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'mailgun' => [
|
||||||
|
'domain' => '',
|
||||||
|
'secret' => '',
|
||||||
|
'endpoint' => 'api.mailgun.net', // api.eu.mailgun.net for EU
|
||||||
|
],
|
||||||
|
|
||||||
|
'mandrill' => [
|
||||||
|
'secret' => '',
|
||||||
|
],
|
||||||
|
|
||||||
|
'postmark' => [
|
||||||
|
'token' => '',
|
||||||
|
],
|
||||||
|
|
||||||
|
'ses' => [
|
||||||
|
'key' => '',
|
||||||
|
'secret' => '',
|
||||||
|
'region' => 'us-east-1',
|
||||||
|
],
|
||||||
|
|
||||||
|
'sparkpost' => [
|
||||||
|
'secret' => '',
|
||||||
|
],
|
||||||
|
|
||||||
|
'stripe' => [
|
||||||
|
'model' => 'User',
|
||||||
|
'secret' => '',
|
||||||
|
],
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,199 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Default Session Driver
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This option controls the default session "driver" that will be used on
|
||||||
|
| requests. By default, we will use the lightweight native driver but
|
||||||
|
| you may specify any of the other wonderful drivers provided here.
|
||||||
|
|
|
||||||
|
| Supported: "file", "cookie", "database", "apc",
|
||||||
|
| "memcached", "redis", "array"
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'driver' => 'file',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Session Lifetime
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may specify the number of minutes that you wish the session
|
||||||
|
| to be allowed to remain idle for it is expired. If you want them
|
||||||
|
| to immediately expire when the browser closes, set it to zero.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'lifetime' => 120,
|
||||||
|
|
||||||
|
'expire_on_close' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Session Encryption
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This option allows you to easily specify that all of your session data
|
||||||
|
| should be encrypted before it is stored. All encryption will be run
|
||||||
|
| automatically by Laravel and you can use the Session like normal.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'encrypt' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Session File Location
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| When using the native session driver, we need a location where session
|
||||||
|
| files may be stored. A default has been set for you but a different
|
||||||
|
| location may be specified. This is only needed for file sessions.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'files' => storage_path('framework/sessions'),
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Session Database Connection
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| When using the "database" or "redis" session drivers, you may specify a
|
||||||
|
| connection that should be used to manage these sessions. This should
|
||||||
|
| correspond to a connection in your database configuration options.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'connection' => null,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Session Database Table
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| When using the "database" session driver, you may specify the table we
|
||||||
|
| should use to manage the sessions. Of course, a sensible default is
|
||||||
|
| provided for you; however, you are free to change this as needed.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'table' => 'sessions',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Session Sweeping Lottery
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Some session drivers must manually sweep their storage location to get
|
||||||
|
| rid of old sessions from storage. Here are the chances that it will
|
||||||
|
| happen on a given request. By default, the odds are 2 out of 100.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'lottery' => [2, 100],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Session Cookie Name
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may change the name of the cookie used to identify a session
|
||||||
|
| instance by ID. The name specified here will get used every time a
|
||||||
|
| new session cookie is created by the framework for every driver.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'cookie' => 'october_session',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Session Cookie Path
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The session cookie path determines the path for which the cookie will
|
||||||
|
| be regarded as available. Typically, this will be the root path of
|
||||||
|
| your application but you are free to change this when necessary.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'path' => '/',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Session Cookie Domain
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Here you may change the domain of the cookie used to identify a session
|
||||||
|
| in your application. This will determine which domains the cookie is
|
||||||
|
| available to in your application. A sensible default has been set.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'domain' => null,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| HTTP Access Only
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Setting this value to true will prevent JavaScript from accessing the
|
||||||
|
| value of the cookie and the cookie will only be accessible through
|
||||||
|
| the HTTP protocol. You are free to modify this option if needed.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'http_only' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| HTTPS Only Cookies
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| By setting this option to true, session cookies will only be sent back
|
||||||
|
| to the server if the browser has a HTTPS connection. This will keep
|
||||||
|
| the cookie from being sent to you if it can not be done securely.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'secure' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Same-Site Cookies
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This option determines how your cookies behave when cross-site requests
|
||||||
|
| take place and can be used to mitigate CSRF attacks.
|
||||||
|
|
|
||||||
|
| Cookies that match the domain of the current site, i.e. what's displayed
|
||||||
|
| in the browser's address bar, are referred to as first-party cookies.
|
||||||
|
| Similarly, cookies from domains other than the current site are referred
|
||||||
|
| to as third-party cookies.
|
||||||
|
|
|
||||||
|
| Cookies without a SameSite attribute will be treated as `SameSite=Lax`,
|
||||||
|
| meaning the default behaviour will be to restrict cookies to first party
|
||||||
|
| contexts only.
|
||||||
|
|
|
||||||
|
| Cookies for cross-site usage must specify `same_site` as 'None' and `secure`
|
||||||
|
| as `true` to work correctly.
|
||||||
|
|
|
||||||
|
| Lax - Cookies are allowed to be sent with top-level navigations and will
|
||||||
|
| be sent along with GET request initiated by third party website.
|
||||||
|
| This is the default value in modern browsers.
|
||||||
|
|
|
||||||
|
| Strict - Cookies will only be sent in a first-party context and not be
|
||||||
|
| sent along with requests initiated by third party websites.
|
||||||
|
|
|
||||||
|
| Supported: "Lax", "Strict" and "None"
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'same_site' => 'Lax',
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,124 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Specifies the default CMS theme
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This parameter value can be overridden by the CMS back-end settings.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'activeTheme' => 'test',
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Time to live for parsed CMS objects.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies the number of minutes the CMS object cache lives. After the interval
|
||||||
|
| is expired item are re-cached. Note that items are re-cached automatically when
|
||||||
|
| the corresponding template file is modified.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'parsedPageCacheTTL' => 1440,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Determines if the routing caching is enabled.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If the caching is enabled, the page URL map is saved in the cache. If a page
|
||||||
|
| URL was changed on the disk, the old URL value could be still saved in the cache.
|
||||||
|
| To update the cache the back-end Clear Cache feature should be used. It is recommended
|
||||||
|
| to disable the caching during the development, and enable it in the production mode.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableRoutesCache' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Time to live for the URL map.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| The URL map used in the CMS page routing process. By default
|
||||||
|
| the map is updated every time when a page is saved in the back-end or when the
|
||||||
|
| interval, in minutes, specified with the urlMapCacheTTL parameter expires.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'urlCacheTtl' => 1,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Determines if the asset caching is enabled.
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If the caching is enabled, combined assets are cached. If a asset file
|
||||||
|
| is changed on the disk, the old file contents could be still saved in the cache.
|
||||||
|
| To update the cache the back-end Clear Cache feature should be used. It is recommended
|
||||||
|
| to disable the caching during the development, and enable it in the production mode.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableAssetCache' => false,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Disables Twig caching for unit tests
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
*/
|
||||||
|
|
||||||
|
'twigNoCache' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Convert Line Endings
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Determines if October should convert line endings from the windows style
|
||||||
|
| \r\n to the unix style \n.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'convertLineEndings' => true,
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Local plugins path
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies the absolute local plugins path.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'pluginsPathLocal' => base_path('tests/fixtures/plugins'),
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Local themes path
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Specifies the absolute local themes path.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'themesPathLocal' => base_path('tests/fixtures/themes'),
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Cross Site Request Forgery (CSRF) Protection
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| If the CSRF protection is enabled, all "postback" requests are checked
|
||||||
|
| for a valid security token.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'enableCsrfProtection' => false,
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,34 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| View Storage Paths
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Most templating systems load templates from disk. Here you may specify
|
||||||
|
| an array of paths that should be checked for your views. Of course
|
||||||
|
| the usual Laravel view path has already been registered for you.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'paths' => [
|
||||||
|
// Default Laravel Blade template location
|
||||||
|
// realpath(base_path('resources/views'))
|
||||||
|
],
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Compiled View Path
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This option determines where all the compiled Blade templates will be
|
||||||
|
| stored for your application. Typically, this is within the storage
|
||||||
|
| directory. However, as usual, you are free to change this value.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
'compiled' => realpath(storage_path('framework/views')),
|
||||||
|
|
||||||
|
];
|
||||||
|
|
@ -0,0 +1,48 @@
|
||||||
|
<?php
|
||||||
|
/**
|
||||||
|
* October - The PHP platform that gets back to basics.
|
||||||
|
*
|
||||||
|
* @package October
|
||||||
|
* @author Alexey Bobkov, Samuel Georges
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Register composer
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Composer provides a generated class loader for the application.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
require __DIR__.'/bootstrap/autoload.php';
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Load framework
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| This bootstraps the framework and loads up this application.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
$app = require_once __DIR__.'/bootstrap/app.php';
|
||||||
|
|
||||||
|
/*
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
| Process request
|
||||||
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
| Execute the request and send the response back to the client.
|
||||||
|
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
$kernel = $app->make(Illuminate\Contracts\Http\Kernel::class);
|
||||||
|
|
||||||
|
$response = $kernel->handle(
|
||||||
|
$request = Illuminate\Http\Request::capture()
|
||||||
|
);
|
||||||
|
|
||||||
|
$response->send();
|
||||||
|
|
||||||
|
$kernel->terminate($request, $response);
|
||||||
|
|
@ -0,0 +1,275 @@
|
||||||
|
<?php namespace Backend;
|
||||||
|
|
||||||
|
use App;
|
||||||
|
use Backend;
|
||||||
|
use BackendMenu;
|
||||||
|
use BackendAuth;
|
||||||
|
use Backend\Models\UserRole;
|
||||||
|
use Backend\Classes\WidgetManager;
|
||||||
|
use System\Classes\MailManager;
|
||||||
|
use System\Classes\CombineAssets;
|
||||||
|
use System\Classes\SettingsManager;
|
||||||
|
use October\Rain\Support\ModuleServiceProvider;
|
||||||
|
|
||||||
|
class ServiceProvider extends ModuleServiceProvider
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Register the service provider.
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
|
public function register()
|
||||||
|
{
|
||||||
|
parent::register('backend');
|
||||||
|
|
||||||
|
$this->registerMailer();
|
||||||
|
$this->registerAssetBundles();
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Backend specific
|
||||||
|
*/
|
||||||
|
if (App::runningInBackend()) {
|
||||||
|
$this->registerBackendNavigation();
|
||||||
|
$this->registerBackendReportWidgets();
|
||||||
|
$this->registerBackendWidgets();
|
||||||
|
$this->registerBackendPermissions();
|
||||||
|
$this->registerBackendSettings();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Bootstrap the module events.
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
|
public function boot()
|
||||||
|
{
|
||||||
|
parent::boot('backend');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register mail templates
|
||||||
|
*/
|
||||||
|
protected function registerMailer()
|
||||||
|
{
|
||||||
|
MailManager::instance()->registerCallback(function ($manager) {
|
||||||
|
$manager->registerMailTemplates([
|
||||||
|
'backend::mail.invite',
|
||||||
|
'backend::mail.restore',
|
||||||
|
]);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register asset bundles
|
||||||
|
*/
|
||||||
|
protected function registerAssetBundles()
|
||||||
|
{
|
||||||
|
CombineAssets::registerCallback(function ($combiner) {
|
||||||
|
$combiner->registerBundle('~/modules/backend/assets/less/october.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/assets/js/october.js');
|
||||||
|
$combiner->registerBundle('~/modules/backend/widgets/table/assets/js/build.js');
|
||||||
|
$combiner->registerBundle('~/modules/backend/widgets/mediamanager/assets/js/mediamanager-browser.js');
|
||||||
|
$combiner->registerBundle('~/modules/backend/widgets/mediamanager/assets/less/mediamanager.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/codeeditor/assets/less/codeeditor.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/repeater/assets/less/repeater.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/codeeditor/assets/js/build.js');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/fileupload/assets/less/fileupload.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/nestedform/assets/less/nestedform.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/richeditor/assets/js/build-plugins.js');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/colorpicker/assets/less/colorpicker.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/permissioneditor/assets/less/permissioneditor.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/markdowneditor/assets/less/markdowneditor.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/sensitive/assets/less/sensitive.less');
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Rich Editor is protected by DRM
|
||||||
|
*/
|
||||||
|
if (file_exists(base_path('modules/backend/formwidgets/richeditor/assets/vendor/froala_drm'))) {
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/richeditor/assets/less/richeditor.less');
|
||||||
|
$combiner->registerBundle('~/modules/backend/formwidgets/richeditor/assets/js/build.js');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Register navigation
|
||||||
|
*/
|
||||||
|
protected function registerBackendNavigation()
|
||||||
|
{
|
||||||
|
BackendMenu::registerCallback(function ($manager) {
|
||||||
|
$manager->registerMenuItems('October.Backend', [
|
||||||
|
'dashboard' => [
|
||||||
|
'label' => 'backend::lang.dashboard.menu_label',
|
||||||
|
'icon' => 'icon-dashboard',
|
||||||
|
'iconSvg' => 'modules/backend/assets/images/dashboard-icon.svg',
|
||||||
|
'url' => Backend::url('backend'),
|
||||||
|
'permissions' => ['backend.access_dashboard'],
|
||||||
|
'order' => 10
|
||||||
|
],
|
||||||
|
'media' => [
|
||||||
|
'label' => 'backend::lang.media.menu_label',
|
||||||
|
'icon' => 'icon-folder',
|
||||||
|
'iconSvg' => 'modules/backend/assets/images/media-icon.svg',
|
||||||
|
'url' => Backend::url('backend/media'),
|
||||||
|
'permissions' => ['media.*'],
|
||||||
|
'order' => 200
|
||||||
|
]
|
||||||
|
]);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Register report widgets
|
||||||
|
*/
|
||||||
|
protected function registerBackendReportWidgets()
|
||||||
|
{
|
||||||
|
WidgetManager::instance()->registerReportWidgets(function ($manager) {
|
||||||
|
$manager->registerReportWidget(\Backend\ReportWidgets\Welcome::class, [
|
||||||
|
'label' => 'backend::lang.dashboard.welcome.widget_title_default',
|
||||||
|
'context' => 'dashboard'
|
||||||
|
]);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Register permissions
|
||||||
|
*/
|
||||||
|
protected function registerBackendPermissions()
|
||||||
|
{
|
||||||
|
BackendAuth::registerCallback(function ($manager) {
|
||||||
|
$manager->registerPermissions('October.Backend', [
|
||||||
|
'backend.access_dashboard' => [
|
||||||
|
'label' => 'system::lang.permissions.view_the_dashboard',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
],
|
||||||
|
'backend.manage_default_dashboard' => [
|
||||||
|
'label' => 'system::lang.permissions.manage_default_dashboard',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
'roles' => UserRole::CODE_DEVELOPER,
|
||||||
|
],
|
||||||
|
'backend.manage_users' => [
|
||||||
|
'label' => 'system::lang.permissions.manage_other_administrators',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
'roles' => UserRole::CODE_DEVELOPER,
|
||||||
|
],
|
||||||
|
'backend.impersonate_users' => [
|
||||||
|
'label' => 'system::lang.permissions.impersonate_users',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
'roles' => UserRole::CODE_DEVELOPER,
|
||||||
|
],
|
||||||
|
'backend.manage_preferences' => [
|
||||||
|
'label' => 'system::lang.permissions.manage_preferences',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
],
|
||||||
|
'backend.manage_editor' => [
|
||||||
|
'label' => 'system::lang.permissions.manage_editor',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
'roles' => UserRole::CODE_DEVELOPER,
|
||||||
|
],
|
||||||
|
'backend.manage_own_editor' => [
|
||||||
|
'label' => 'system::lang.permissions.manage_own_editor',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
],
|
||||||
|
'backend.manage_branding' => [
|
||||||
|
'label' => 'system::lang.permissions.manage_branding',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
'roles' => UserRole::CODE_DEVELOPER,
|
||||||
|
],
|
||||||
|
'media.manage_media' => [
|
||||||
|
'label' => 'backend::lang.permissions.manage_media',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
],
|
||||||
|
'backend.allow_unsafe_markdown' => [
|
||||||
|
'label' => 'backend::lang.permissions.allow_unsafe_markdown',
|
||||||
|
'tab' => 'system::lang.permissions.name',
|
||||||
|
'roles' => UserRole::CODE_DEVELOPER,
|
||||||
|
],
|
||||||
|
]);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Register widgets
|
||||||
|
*/
|
||||||
|
protected function registerBackendWidgets()
|
||||||
|
{
|
||||||
|
WidgetManager::instance()->registerFormWidgets(function ($manager) {
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\CodeEditor', 'codeeditor');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\RichEditor', 'richeditor');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\MarkdownEditor', 'markdown');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\FileUpload', 'fileupload');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\Relation', 'relation');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\DatePicker', 'datepicker');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\TimePicker', 'timepicker');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\ColorPicker', 'colorpicker');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\DataTable', 'datatable');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\RecordFinder', 'recordfinder');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\Repeater', 'repeater');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\TagList', 'taglist');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\MediaFinder', 'mediafinder');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\NestedForm', 'nestedform');
|
||||||
|
$manager->registerFormWidget('Backend\FormWidgets\Sensitive', 'sensitive');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Register settings
|
||||||
|
*/
|
||||||
|
protected function registerBackendSettings()
|
||||||
|
{
|
||||||
|
SettingsManager::instance()->registerCallback(function ($manager) {
|
||||||
|
$manager->registerSettingItems('October.Backend', [
|
||||||
|
'branding' => [
|
||||||
|
'label' => 'backend::lang.branding.menu_label',
|
||||||
|
'description' => 'backend::lang.branding.menu_description',
|
||||||
|
'category' => SettingsManager::CATEGORY_SYSTEM,
|
||||||
|
'icon' => 'icon-paint-brush',
|
||||||
|
'class' => 'Backend\Models\BrandSetting',
|
||||||
|
'permissions' => ['backend.manage_branding'],
|
||||||
|
'order' => 500,
|
||||||
|
'keywords' => 'brand style'
|
||||||
|
],
|
||||||
|
'editor' => [
|
||||||
|
'label' => 'backend::lang.editor.menu_label',
|
||||||
|
'description' => 'backend::lang.editor.menu_description',
|
||||||
|
'category' => SettingsManager::CATEGORY_SYSTEM,
|
||||||
|
'icon' => 'icon-code',
|
||||||
|
'class' => 'Backend\Models\EditorSetting',
|
||||||
|
'permissions' => ['backend.manage_editor'],
|
||||||
|
'order' => 500,
|
||||||
|
'keywords' => 'html code class style'
|
||||||
|
],
|
||||||
|
'myaccount' => [
|
||||||
|
'label' => 'backend::lang.myaccount.menu_label',
|
||||||
|
'description' => 'backend::lang.myaccount.menu_description',
|
||||||
|
'category' => SettingsManager::CATEGORY_MYSETTINGS,
|
||||||
|
'icon' => 'icon-user',
|
||||||
|
'url' => Backend::url('backend/users/myaccount'),
|
||||||
|
'order' => 500,
|
||||||
|
'context' => 'mysettings',
|
||||||
|
'keywords' => 'backend::lang.myaccount.menu_keywords'
|
||||||
|
],
|
||||||
|
'preferences' => [
|
||||||
|
'label' => 'backend::lang.backend_preferences.menu_label',
|
||||||
|
'description' => 'backend::lang.backend_preferences.menu_description',
|
||||||
|
'category' => SettingsManager::CATEGORY_MYSETTINGS,
|
||||||
|
'icon' => 'icon-laptop',
|
||||||
|
'url' => Backend::url('backend/preferences'),
|
||||||
|
'permissions' => ['backend.manage_preferences'],
|
||||||
|
'order' => 510,
|
||||||
|
'context' => 'mysettings'
|
||||||
|
],
|
||||||
|
'access_logs' => [
|
||||||
|
'label' => 'backend::lang.access_log.menu_label',
|
||||||
|
'description' => 'backend::lang.access_log.menu_description',
|
||||||
|
'category' => SettingsManager::CATEGORY_LOGS,
|
||||||
|
'icon' => 'icon-lock',
|
||||||
|
'url' => Backend::url('backend/accesslogs'),
|
||||||
|
'permissions' => ['system.access_logs'],
|
||||||
|
'order' => 920
|
||||||
|
]
|
||||||
|
]);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,12 @@
|
||||||
|
.dashboard-container > .report-container.loading {
|
||||||
|
position: absolute;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
.dashboard-container > .report-container.loading .loading-indicator-container {
|
||||||
|
position: absolute;
|
||||||
|
left: 0;
|
||||||
|
top: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<svg width="40px" height="40px" viewBox="0 0 40 40" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
||||||
|
<!-- Generator: Sketch 3.4.4 (17249) - http://www.bohemiancoding.com/sketch -->
|
||||||
|
<title>dashboard-icon</title>
|
||||||
|
<desc>Created with Sketch.</desc>
|
||||||
|
<defs></defs>
|
||||||
|
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
||||||
|
<g id="speed" sketch:type="MSLayerGroup">
|
||||||
|
<path fill="#7986CB" d="M20 3.542C9.14 3.542.336 12.347.336 23.207c0 4.713 1.66 9.032 4.424 12.42l1.552-3.105H33.69l1.55 3.104c2.763-3.387 4.425-7.706 4.425-12.42 0-10.86-8.806-19.664-19.665-19.664z"/>
|
||||||
|
<path fill="#ECEFF1" d="M36.56 23.206c0-9.145-7.415-16.56-16.56-16.56-9.144 0-16.56 7.415-16.56 16.56 0 3.454 1.062 6.66 2.872 9.314L4.76 35.625h30.48l-1.55-3.104c1.807-2.654 2.87-5.86 2.87-9.314z"/>
|
||||||
|
<path fill="#455A64" d="M3.473 22.17c-.02.345-.032.687-.032 1.036 0 .35.012.69.033 1.035h4.16c-.028-.34-.053-.686-.053-1.034 0-.35.024-.694.052-1.036h-4.16zm6.402 8.192c-.407-.557-.768-1.145-1.08-1.766l-3.55 2.157c.325.614.67 1.2 1.067 1.767l3.563-2.158zm2.823-17.187c.557-.405 1.146-.765 1.77-1.075l-2.114-3.585c-.615.322-1.226.69-1.792 1.083l2.136 3.577zM8.75 17.97c.293-.63.63-1.233 1.02-1.8l-3.567-2.125c-.378.576-.77 1.247-1.075 1.87L8.75 17.97zm12.286-7.13V6.68c-.346-.023-.687-.033-1.036-.033s-.69-.022-1.035 0v4.193c.343-.03.687-.054 1.035-.054s.692.025 1.036.053zm9.074 19.626l3.6 2.055c.378-.574.76-1.215 1.064-1.836l-3.646-2.018c-.293.628-.63 1.232-1.018 1.8zm6.417-6.226c.02-.344.032-.686.032-1.034 0-.35-.012-.69-.033-1.036h-4.16c.027.342.052.687.052 1.036 0 .35-.025.693-.053 1.035h4.16zm-7.41-14.858c-.573-.38-1.205-.74-1.827-1.047l-2.055 3.622c.63.293 1.235.63 1.802 1.02l2.08-3.595z"/>
|
||||||
|
<path fill="#90A4AE" d="M15.86 28.38h8.28v2.07h-8.28v-2.07z"/>
|
||||||
|
<path fill="none" stroke="#FF1744" stroke-miterlimit="10" d="M20 23.206l12.42-7.245"/>
|
||||||
|
<path fill="#FF1744" d="M19.883 20.002c1.683 0 3.047 1.365 3.047 3.045 0 1.685-1.363 3.048-3.047 3.048-1.682 0-3.045-1.363-3.045-3.048 0-1.68 1.363-3.045 3.045-3.045z"/>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.3 KiB |
|
After Width: | Height: | Size: 4.5 KiB |
|
|
@ -0,0 +1,22 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<svg width="42px" height="42px" viewBox="0 0 42 42" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
||||||
|
<!-- Generator: Sketch 3.4.4 (17249) - http://www.bohemiancoding.com/sketch -->
|
||||||
|
<title>media-icon</title>
|
||||||
|
<desc>Created with Sketch.</desc>
|
||||||
|
<defs></defs>
|
||||||
|
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
||||||
|
<g id="slr_back_side" sketch:type="MSLayerGroup" transform="translate(0.000000, 2.000000)">
|
||||||
|
<path d="M37.8,4.22222222 L29.82,4.22222222 L27.72,1.05555556 C27.3,0.422222222 26.67,0.105555556 25.935,0.105555556 L15.855,0.105555556 C15.12,0.105555556 14.49,0.422222222 14.07,1.05555556 L11.97,4.22222222 L4.2,4.22222222 C1.89,4.22222222 0,6.12222222 0,8.44444444 L0,33.7777778 C0,36.1 1.89,38 4.2,38 L37.8,38 C40.11,38 42,36.1 42,33.7777778 L42,8.44444444 C42,6.12222222 40.11,4.22222222 37.8,4.22222222 L37.8,4.22222222 Z" id="Shape" fill="#5E35B1" sketch:type="MSShapeGroup"></path>
|
||||||
|
<path d="M7.35,10.5555556 L28.35,10.5555556 C28.98,10.5555556 29.4,10.9777778 29.4,11.6111111 L29.4,28.5 C29.4,29.1333333 28.98,29.5555556 28.35,29.5555556 L7.35,29.5555556 C6.72,29.5555556 6.3,29.1333333 6.3,28.5 L6.3,11.6111111 C6.3,10.9777778 6.72,10.5555556 7.35,10.5555556 L7.35,10.5555556 Z" id="Shape" fill="#F57C00" sketch:type="MSShapeGroup"></path>
|
||||||
|
<path d="M15.645,16.8888889 L8.4,27.4444444 L22.89,27.4444444 L15.645,16.8888889 Z" id="Shape" fill="#942A09" sketch:type="MSShapeGroup"></path>
|
||||||
|
<ellipse id="Oval" fill="#FFF9C4" sketch:type="MSShapeGroup" cx="24.15" cy="15.8333333" rx="2.1" ry="2.11111111"></ellipse>
|
||||||
|
<path d="M22.26,21.1111111 L17.22,27.4444444 L27.3,27.4444444 L22.26,21.1111111 Z" id="Shape" fill="#BF360C" sketch:type="MSShapeGroup"></path>
|
||||||
|
<g id="Group" transform="translate(31.500000, 2.111111)" fill="#8667C4" sketch:type="MSShapeGroup">
|
||||||
|
<path d="M0,2.11111111 L6.3,2.11111111 L6.3,1.26666667 C6.3,0.527777778 5.775,0 5.04,0 L1.26,0 C0.525,0 0,0.527777778 0,1.26666667 L0,2.11111111 L0,2.11111111 Z" id="Shape"></path>
|
||||||
|
<ellipse id="Oval" cx="4.2" cy="10.5555556" rx="2.1" ry="2.11111111"></ellipse>
|
||||||
|
<ellipse id="Oval" cx="4.2" cy="16.8888889" rx="2.1" ry="2.11111111"></ellipse>
|
||||||
|
<ellipse id="Oval" cx="4.2" cy="23.2222222" rx="2.1" ry="2.11111111"></ellipse>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.5 KiB |
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<svg width="49px" height="65px" viewBox="0 0 49 65" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
||||||
|
<!-- Generator: Sketch 3.4.4 (17249) - http://www.bohemiancoding.com/sketch -->
|
||||||
|
<title>october-leaf</title>
|
||||||
|
<desc>Created with Sketch.</desc>
|
||||||
|
<defs>
|
||||||
|
<path id="path-1" d="M0,0.658 L48.736,0.658 L48.736,65 L0,65"></path>
|
||||||
|
</defs>
|
||||||
|
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
||||||
|
<g id="logo" sketch:type="MSLayerGroup">
|
||||||
|
<mask id="mask-2" sketch:name="Clip 2" fill="white">
|
||||||
|
<use xlink:href="#path-1"></use>
|
||||||
|
</mask>
|
||||||
|
<g id="Clip-2"></g>
|
||||||
|
<path d="M48.6875,31.4795 C47.6665,15.0415 29.5165,0.8175 22.0395,0.6595 C14.5595,0.5005 0.5805,17.9095 0.0145,35.5975 C-0.5155,52.1825 13.8335,63.5555 20.0105,65.0005 C20.1825,57.1965 20.8155,28.4665 20.9215,25.1165 C21.1445,18.2705 21.4855,7.6195 22.6445,7.2645 C23.3095,7.0615 24.2155,13.0495 24.1045,16.5885 C24.0815,17.2635 24.0735,19.4515 24.0735,22.5545 C25.3245,21.2995 26.6305,19.9975 27.4245,19.2265 C29.6015,17.1175 30.5645,17.3685 29.5205,19.2505 C28.8775,20.4075 26.1125,24.2575 24.0795,27.0475 C24.0905,32.6745 24.1165,39.7565 24.1435,46.3565 C27.0145,43.0425 30.5295,39.0675 32.3755,37.2995 C36.2485,33.5965 36.6605,34.0645 34.8315,37.9515 C33.7085,40.3335 28.2165,46.6875 24.1635,51.6985 C24.1885,57.5535 24.2085,62.4765 24.2125,64.8275 C35.0855,62.4675 49.6865,47.6185 48.6875,31.4795" id="Fill-1" fill="#DB6A26" sketch:type="MSShapeGroup" mask="url(#mask-2)"></path>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 1.7 KiB |
|
After Width: | Height: | Size: 6.3 KiB |
|
|
@ -0,0 +1,75 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- Generator: Adobe Illustrator 13.0.0, SVG Export Plug-In -->
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" [
|
||||||
|
<!ENTITY ns_flows "http://ns.adobe.com/Flows/1.0/">
|
||||||
|
]>
|
||||||
|
<svg version="1.0"
|
||||||
|
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/"
|
||||||
|
x="0px" y="0px" width="408px" height="71px" viewBox="-5.208 -4.384 408 71" enable-background="new -5.208 -4.384 408 71"
|
||||||
|
xml:space="preserve">
|
||||||
|
<defs>
|
||||||
|
</defs>
|
||||||
|
<path opacity="0.3" fill="#596667" d="M111.401,42.425c-1.112,0-2.896,0.109-4.007,1.986c-0.441,0.744-0.816,1.564-1.631,2.516
|
||||||
|
c-1.481,1.727-3.297,3.045-5.44,3.952c-2.146,0.908-4.589,1.36-7.325,1.36c-2.766,0-5.23-0.452-7.385-1.36
|
||||||
|
c-2.162-0.907-3.98-2.226-5.462-3.952c-1.485-1.73-2.618-3.84-3.411-6.334c-0.789-2.489-1.185-5.306-1.185-8.444
|
||||||
|
c0-3.114,0.396-5.913,1.185-8.406c0.793-2.489,1.926-4.603,3.411-6.33c1.482-1.729,3.3-3.052,5.462-3.976
|
||||||
|
c2.155-0.922,4.619-1.383,7.385-1.383c2.736,0,5.179,0.461,7.325,1.383c2.143,0.924,3.959,2.247,5.44,3.976
|
||||||
|
c0.716,0.834,1.352,1.757,1.903,2.772c1.064,1.96,3.735,1.726,3.735,1.726h12.112c-0.248-0.817-0.505-1.63-0.817-2.422
|
||||||
|
c-1.538-3.918-3.702-7.318-6.497-10.198c-2.794-2.88-6.16-5.148-10.097-6.807C102.163,0.827,97.799,0,92.998,0
|
||||||
|
C88.2,0,83.827,0.82,79.876,2.462c-3.951,1.642-7.331,3.902-10.14,6.783c-2.811,2.884-4.981,6.28-6.521,10.197
|
||||||
|
c-0.092,0.235-0.173,0.476-0.26,0.713c-0.083-0.222-0.159-0.447-0.247-0.667c-1.562-3.918-3.757-7.318-6.594-10.198
|
||||||
|
c-2.835-2.879-6.251-5.147-10.248-6.807c-3.997-1.656-8.428-2.483-13.299-2.483c-4.87,0-9.308,0.819-13.319,2.461
|
||||||
|
c-4.01,1.642-7.439,3.903-10.29,6.784c-2.854,2.883-5.056,6.279-6.619,10.196C0.78,23.363,0,27.598,0,32.148
|
||||||
|
c0,4.553,0.78,8.787,2.34,12.705c1.563,3.917,3.765,7.324,6.619,10.218c2.851,2.894,6.28,5.162,10.29,6.804
|
||||||
|
c4.011,1.643,8.449,2.465,13.319,2.465c4.871,0,9.302-0.822,13.299-2.465c3.997-1.642,7.413-3.91,10.248-6.804
|
||||||
|
c2.837-2.894,5.032-6.301,6.594-10.218c0.091-0.228,0.169-0.46,0.255-0.689c0.084,0.229,0.162,0.462,0.251,0.689
|
||||||
|
c1.54,3.917,3.71,7.324,6.521,10.218c2.809,2.894,6.189,5.162,10.14,6.804c3.951,1.643,8.324,2.465,13.122,2.465
|
||||||
|
c4.801,0,9.165-0.822,13.104-2.465c3.937-1.642,7.303-3.91,10.097-6.804c2.795-2.894,4.959-6.301,6.497-10.218
|
||||||
|
c0.312-0.793,0.57-1.609,0.818-2.428H111.401z M48.981,40.593c-0.8,2.494-1.954,4.604-3.458,6.334
|
||||||
|
c-1.503,1.727-3.346,3.045-5.521,3.951c-2.178,0.909-4.657,1.361-7.434,1.361c-2.807,0-5.308-0.452-7.496-1.361
|
||||||
|
c-2.193-0.906-4.038-2.225-5.543-3.951c-1.506-1.73-2.657-3.84-3.462-6.334c-0.8-2.489-1.202-5.306-1.202-8.445
|
||||||
|
c0-3.113,0.402-5.912,1.202-8.405c0.805-2.489,1.956-4.603,3.462-6.329c1.505-1.73,3.35-3.053,5.543-3.977
|
||||||
|
c2.188-0.921,4.689-1.382,7.496-1.382c2.777,0,5.256,0.461,7.434,1.382c2.175,0.924,4.018,2.247,5.521,3.977
|
||||||
|
c1.504,1.726,2.658,3.84,3.458,6.329c0.802,2.493,1.204,5.292,1.204,8.405C50.185,35.288,49.783,38.104,48.981,40.593z"/>
|
||||||
|
<path opacity="0.3" fill="#596667" d="M208.964,32.148c0,4.553-0.784,8.787-2.341,12.705c-1.564,3.917-3.761,7.324-6.594,10.218
|
||||||
|
c-2.838,2.894-6.252,5.162-10.251,6.804c-3.996,1.643-8.427,2.465-13.299,2.465c-4.87,0-9.307-0.822-13.317-2.465
|
||||||
|
c-4.012-1.642-7.442-3.91-10.29-6.804c-2.856-2.894-5.059-6.301-6.62-10.218c-1.56-3.918-2.34-8.152-2.34-12.705
|
||||||
|
c0-4.55,0.78-8.785,2.34-12.706c1.561-3.917,3.764-7.313,6.62-10.196c2.848-2.881,6.278-5.142,10.29-6.784
|
||||||
|
c4.01-1.642,8.447-2.461,13.317-2.461c4.872,0,9.303,0.827,13.299,2.483c3.999,1.66,7.413,3.928,10.251,6.807
|
||||||
|
c2.833,2.88,5.029,6.28,6.594,10.198C208.18,23.406,208.964,27.626,208.964,32.148 M194.097,32.148c0-3.113-0.401-5.912-1.202-8.405
|
||||||
|
c-0.8-2.489-1.954-4.603-3.458-6.329c-1.504-1.73-3.347-3.053-5.521-3.977c-2.179-0.921-4.658-1.382-7.436-1.382
|
||||||
|
c-2.806,0-5.306,0.461-7.494,1.382c-2.195,0.924-4.04,2.247-5.544,3.977c-1.506,1.726-2.658,3.84-3.462,6.329
|
||||||
|
c-0.8,2.493-1.203,5.292-1.203,8.405c0,3.14,0.403,5.956,1.203,8.445c0.804,2.494,1.956,4.604,3.462,6.334
|
||||||
|
c1.504,1.727,3.349,3.045,5.544,3.951c2.188,0.909,4.688,1.361,7.494,1.361c2.778,0,5.257-0.452,7.436-1.361
|
||||||
|
c2.174-0.906,4.017-2.225,5.521-3.951c1.504-1.73,2.658-3.84,3.458-6.334C193.696,38.104,194.097,35.288,194.097,32.148"/>
|
||||||
|
<path opacity="0.3" fill="#596667" d="M210.603,63.648V0.69h23.159c4.351,0,8.053,0.405,11.104,1.21
|
||||||
|
c3.053,0.808,5.546,1.944,7.475,3.415c1.931,1.468,3.334,3.255,4.214,5.358c0.878,2.103,1.319,4.452,1.319,7.044
|
||||||
|
c0,1.41-0.204,2.77-0.606,4.082c-0.404,1.312-1.036,2.542-1.902,3.696c-0.864,1.15-1.971,2.193-3.326,3.133
|
||||||
|
c-1.354,0.935-2.982,1.748-4.885,2.44c4.151,1.01,7.217,2.645,9.208,4.906c1.985,2.262,2.979,5.161,2.979,8.705
|
||||||
|
c0,2.676-0.519,5.17-1.556,7.473c-1.037,2.307-2.558,4.314-4.557,6.031c-2.004,1.713-4.474,3.053-7.412,4.016
|
||||||
|
c-2.938,0.967-6.294,1.449-10.069,1.449H210.603z M225.208,27.178h7.604c1.612,0,3.066-0.114,4.365-0.343
|
||||||
|
c1.294-0.232,2.397-0.633,3.306-1.21c0.907-0.577,1.596-1.369,2.074-2.378c0.476-1.009,0.71-2.275,0.71-3.804
|
||||||
|
c0-1.494-0.185-2.742-0.56-3.738c-0.375-0.991-0.952-1.79-1.73-2.398c-0.775-0.605-1.765-1.034-2.958-1.294
|
||||||
|
c-1.197-0.26-2.614-0.39-4.256-0.39h-8.555V27.178z M225.208,36.944V52.63h10.279c1.931,0,3.511-0.246,4.735-0.734
|
||||||
|
c1.224-0.492,2.183-1.126,2.872-1.902c0.692-0.777,1.166-1.656,1.426-2.639c0.259-0.977,0.389-1.971,0.389-2.978
|
||||||
|
c0-1.153-0.15-2.19-0.452-3.112c-0.302-0.921-0.82-1.698-1.554-2.334c-0.736-0.634-1.711-1.123-2.921-1.471
|
||||||
|
c-1.21-0.344-2.735-0.517-4.578-0.517H225.208z"/>
|
||||||
|
<polygon opacity="0.3" fill="#596667" points="301.985,0.689 301.985,11.924 276.144,11.924 276.144,26.616 295.934,26.616
|
||||||
|
295.934,37.419 276.144,37.419 276.144,52.412 301.985,52.412 301.985,63.647 261.454,63.647 261.454,0.689 "/>
|
||||||
|
<path opacity="0.3" fill="#596667" d="M319.388,40.358v23.29h-14.604V0.689h20.481c4.549,0,8.431,0.472,11.646,1.407
|
||||||
|
c3.211,0.936,5.835,2.24,7.862,3.91c2.032,1.672,3.506,3.643,4.433,5.919c0.919,2.275,1.38,4.753,1.38,7.434
|
||||||
|
c0,2.046-0.274,3.973-0.823,5.787c-0.543,1.815-1.36,3.496-2.438,5.036c-1.08,1.54-2.406,2.915-3.975,4.126
|
||||||
|
c-1.572,1.211-3.38,2.203-5.426,2.98c0.98,0.492,1.896,1.098,2.745,1.814c0.848,0.721,1.592,1.6,2.229,2.637l13.393,21.908h-13.221
|
||||||
|
c-2.451,0-4.207-0.922-5.272-2.764l-10.457-18.279c-0.461-0.809-1.003-1.382-1.622-1.73c-0.617-0.344-1.491-0.517-2.611-0.517
|
||||||
|
H319.388z M319.388,30.291h5.877c1.985,0,3.679-0.253,5.076-0.756c1.397-0.506,2.544-1.203,3.437-2.097
|
||||||
|
c0.894-0.892,1.54-1.937,1.944-3.131c0.4-1.197,0.606-2.487,0.606-3.869c0-2.764-0.902-4.927-2.702-6.48
|
||||||
|
c-1.8-1.558-4.588-2.335-8.361-2.335h-5.877V30.291z"/>
|
||||||
|
<path opacity="0.3" fill="#596667" d="M127.329,0.689v25.243h-16.043c-1.452,0-2.628,1.128-2.628,2.517v7.438
|
||||||
|
c0,1.392,1.176,2.519,2.628,2.519h16.043v25.241h14.604V0.689H127.329z"/>
|
||||||
|
<path opacity="0.3" fill="#DB6B26" d="M400.482,30.821c-1.021-16.438-19.171-30.662-26.648-30.819
|
||||||
|
c-7.479-0.159-21.459,17.25-22.024,34.938c-0.53,16.585,13.818,27.958,19.996,29.401c0.172-7.803,0.805-36.532,0.911-39.882
|
||||||
|
c0.223-6.846,0.563-17.498,1.723-17.852c0.665-0.203,1.571,5.785,1.46,9.324c-0.023,0.675-0.031,2.862-0.031,5.966
|
||||||
|
c1.251-1.255,2.558-2.558,3.352-3.328c2.177-2.11,3.14-1.859,2.096,0.023c-0.643,1.158-3.408,5.008-5.441,7.798
|
||||||
|
c0.012,5.627,0.037,12.709,0.064,19.309c2.871-3.315,6.386-7.289,8.232-9.057c3.872-3.702,4.284-3.235,2.455,0.651
|
||||||
|
c-1.123,2.382-6.614,8.736-10.668,13.747c0.025,5.855,0.045,10.778,0.05,13.129C386.88,61.81,401.481,46.96,400.482,30.821"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 7.2 KiB |
|
|
@ -0,0 +1,75 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- Generator: Adobe Illustrator 13.0.0, SVG Export Plug-In -->
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" [
|
||||||
|
<!ENTITY ns_flows "http://ns.adobe.com/Flows/1.0/">
|
||||||
|
]>
|
||||||
|
<svg version="1.0"
|
||||||
|
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/"
|
||||||
|
x="0px" y="0px" viewBox="-5.208 -4.384 408 71" enable-background="new -5.208 -4.384 408 71"
|
||||||
|
xml:space="preserve">
|
||||||
|
<defs>
|
||||||
|
</defs>
|
||||||
|
<path fill="#FFFFFF" d="M111.401,42.425c-1.112,0-2.896,0.109-4.007,1.986c-0.441,0.744-0.816,1.564-1.631,2.516
|
||||||
|
c-1.481,1.727-3.297,3.045-5.44,3.952c-2.146,0.908-4.589,1.36-7.325,1.36c-2.766,0-5.23-0.452-7.385-1.36
|
||||||
|
c-2.162-0.907-3.98-2.226-5.462-3.952c-1.485-1.73-2.618-3.84-3.411-6.334c-0.789-2.489-1.185-5.306-1.185-8.444
|
||||||
|
c0-3.114,0.396-5.913,1.185-8.406c0.793-2.489,1.926-4.603,3.411-6.33c1.482-1.729,3.3-3.052,5.462-3.976
|
||||||
|
c2.155-0.922,4.619-1.383,7.385-1.383c2.736,0,5.179,0.461,7.325,1.383c2.143,0.924,3.959,2.247,5.44,3.976
|
||||||
|
c0.716,0.834,1.352,1.757,1.903,2.772c1.064,1.96,3.735,1.726,3.735,1.726h12.112c-0.248-0.817-0.505-1.63-0.817-2.422
|
||||||
|
c-1.538-3.918-3.702-7.318-6.497-10.198c-2.794-2.88-6.16-5.148-10.097-6.807C102.163,0.827,97.799,0,92.998,0
|
||||||
|
C88.2,0,83.827,0.82,79.876,2.462c-3.951,1.642-7.331,3.902-10.14,6.783c-2.811,2.884-4.981,6.28-6.521,10.197
|
||||||
|
c-0.092,0.235-0.173,0.476-0.26,0.713c-0.083-0.222-0.159-0.447-0.247-0.667c-1.562-3.918-3.757-7.318-6.594-10.198
|
||||||
|
c-2.835-2.879-6.251-5.147-10.248-6.807c-3.997-1.656-8.428-2.483-13.299-2.483c-4.87,0-9.308,0.819-13.319,2.461
|
||||||
|
c-4.01,1.642-7.439,3.903-10.29,6.784c-2.854,2.883-5.056,6.279-6.619,10.196C0.78,23.363,0,27.598,0,32.148
|
||||||
|
c0,4.553,0.78,8.787,2.34,12.705c1.563,3.917,3.765,7.324,6.619,10.218c2.851,2.894,6.28,5.162,10.29,6.804
|
||||||
|
c4.011,1.643,8.449,2.465,13.319,2.465c4.871,0,9.302-0.822,13.299-2.465c3.997-1.642,7.413-3.91,10.248-6.804
|
||||||
|
c2.837-2.894,5.032-6.301,6.594-10.218c0.091-0.228,0.169-0.46,0.255-0.689c0.084,0.229,0.162,0.462,0.251,0.689
|
||||||
|
c1.54,3.917,3.71,7.324,6.521,10.218c2.809,2.894,6.189,5.162,10.14,6.804c3.951,1.643,8.324,2.465,13.122,2.465
|
||||||
|
c4.801,0,9.165-0.822,13.104-2.465c3.937-1.642,7.303-3.91,10.097-6.804c2.795-2.894,4.959-6.301,6.497-10.218
|
||||||
|
c0.312-0.793,0.57-1.609,0.818-2.428H111.401z M48.981,40.593c-0.8,2.494-1.954,4.604-3.458,6.334
|
||||||
|
c-1.503,1.727-3.346,3.045-5.521,3.951c-2.178,0.909-4.657,1.361-7.434,1.361c-2.807,0-5.308-0.452-7.496-1.361
|
||||||
|
c-2.193-0.906-4.038-2.225-5.543-3.951c-1.506-1.73-2.657-3.84-3.462-6.334c-0.8-2.489-1.202-5.306-1.202-8.445
|
||||||
|
c0-3.113,0.402-5.912,1.202-8.405c0.805-2.489,1.956-4.603,3.462-6.329c1.505-1.73,3.35-3.053,5.543-3.977
|
||||||
|
c2.188-0.921,4.689-1.382,7.496-1.382c2.777,0,5.256,0.461,7.434,1.382c2.175,0.924,4.018,2.247,5.521,3.977
|
||||||
|
c1.504,1.726,2.658,3.84,3.458,6.329c0.802,2.493,1.204,5.292,1.204,8.405C50.185,35.288,49.783,38.104,48.981,40.593z"/>
|
||||||
|
<path fill="#FFFFFF" d="M208.964,32.148c0,4.553-0.784,8.787-2.341,12.705c-1.564,3.917-3.761,7.324-6.594,10.218
|
||||||
|
c-2.838,2.894-6.252,5.162-10.251,6.804c-3.996,1.643-8.427,2.465-13.299,2.465c-4.87,0-9.307-0.822-13.317-2.465
|
||||||
|
c-4.012-1.642-7.442-3.91-10.29-6.804c-2.856-2.894-5.059-6.301-6.62-10.218c-1.56-3.918-2.34-8.152-2.34-12.705
|
||||||
|
c0-4.55,0.78-8.785,2.34-12.706c1.561-3.917,3.764-7.313,6.62-10.196c2.848-2.881,6.278-5.142,10.29-6.784
|
||||||
|
c4.01-1.642,8.447-2.461,13.317-2.461c4.872,0,9.303,0.827,13.299,2.483c3.999,1.66,7.413,3.928,10.251,6.807
|
||||||
|
c2.833,2.88,5.029,6.28,6.594,10.198C208.18,23.406,208.964,27.626,208.964,32.148 M194.097,32.148c0-3.113-0.401-5.912-1.202-8.405
|
||||||
|
c-0.8-2.489-1.954-4.603-3.458-6.329c-1.504-1.73-3.347-3.053-5.521-3.977c-2.179-0.921-4.658-1.382-7.436-1.382
|
||||||
|
c-2.806,0-5.306,0.461-7.494,1.382c-2.195,0.924-4.04,2.247-5.544,3.977c-1.506,1.726-2.658,3.84-3.462,6.329
|
||||||
|
c-0.8,2.493-1.203,5.292-1.203,8.405c0,3.14,0.403,5.956,1.203,8.445c0.804,2.494,1.956,4.604,3.462,6.334
|
||||||
|
c1.504,1.727,3.349,3.045,5.544,3.951c2.188,0.909,4.688,1.361,7.494,1.361c2.778,0,5.257-0.452,7.436-1.361
|
||||||
|
c2.174-0.906,4.017-2.225,5.521-3.951c1.504-1.73,2.658-3.84,3.458-6.334C193.696,38.104,194.097,35.288,194.097,32.148"/>
|
||||||
|
<path fill="#FFFFFF" d="M210.603,63.648V0.69h23.159c4.351,0,8.053,0.405,11.104,1.21
|
||||||
|
c3.053,0.808,5.546,1.944,7.475,3.415c1.931,1.468,3.334,3.255,4.214,5.358c0.878,2.103,1.319,4.452,1.319,7.044
|
||||||
|
c0,1.41-0.204,2.77-0.606,4.082c-0.404,1.312-1.036,2.542-1.902,3.696c-0.864,1.15-1.971,2.193-3.326,3.133
|
||||||
|
c-1.354,0.935-2.982,1.748-4.885,2.44c4.151,1.01,7.217,2.645,9.208,4.906c1.985,2.262,2.979,5.161,2.979,8.705
|
||||||
|
c0,2.676-0.519,5.17-1.556,7.473c-1.037,2.307-2.558,4.314-4.557,6.031c-2.004,1.713-4.474,3.053-7.412,4.016
|
||||||
|
c-2.938,0.967-6.294,1.449-10.069,1.449H210.603z M225.208,27.178h7.604c1.612,0,3.066-0.114,4.365-0.343
|
||||||
|
c1.294-0.232,2.397-0.633,3.306-1.21c0.907-0.577,1.596-1.369,2.074-2.378c0.476-1.009,0.71-2.275,0.71-3.804
|
||||||
|
c0-1.494-0.185-2.742-0.56-3.738c-0.375-0.991-0.952-1.79-1.73-2.398c-0.775-0.605-1.765-1.034-2.958-1.294
|
||||||
|
c-1.197-0.26-2.614-0.39-4.256-0.39h-8.555V27.178z M225.208,36.944V52.63h10.279c1.931,0,3.511-0.246,4.735-0.734
|
||||||
|
c1.224-0.492,2.183-1.126,2.872-1.902c0.692-0.777,1.166-1.656,1.426-2.639c0.259-0.977,0.389-1.971,0.389-2.978
|
||||||
|
c0-1.153-0.15-2.19-0.452-3.112c-0.302-0.921-0.82-1.698-1.554-2.334c-0.736-0.634-1.711-1.123-2.921-1.471
|
||||||
|
c-1.21-0.344-2.735-0.517-4.578-0.517H225.208z"/>
|
||||||
|
<polygon fill="#FFFFFF" points="301.985,0.689 301.985,11.924 276.144,11.924 276.144,26.616 295.934,26.616
|
||||||
|
295.934,37.419 276.144,37.419 276.144,52.412 301.985,52.412 301.985,63.647 261.454,63.647 261.454,0.689 "/>
|
||||||
|
<path fill="#FFFFFF" d="M319.388,40.358v23.29h-14.604V0.689h20.481c4.549,0,8.431,0.472,11.646,1.407
|
||||||
|
c3.211,0.936,5.835,2.24,7.862,3.91c2.032,1.672,3.506,3.643,4.433,5.919c0.919,2.275,1.38,4.753,1.38,7.434
|
||||||
|
c0,2.046-0.274,3.973-0.823,5.787c-0.543,1.815-1.36,3.496-2.438,5.036c-1.08,1.54-2.406,2.915-3.975,4.126
|
||||||
|
c-1.572,1.211-3.38,2.203-5.426,2.98c0.98,0.492,1.896,1.098,2.745,1.814c0.848,0.721,1.592,1.6,2.229,2.637l13.393,21.908h-13.221
|
||||||
|
c-2.451,0-4.207-0.922-5.272-2.764l-10.457-18.279c-0.461-0.809-1.003-1.382-1.622-1.73c-0.617-0.344-1.491-0.517-2.611-0.517
|
||||||
|
H319.388z M319.388,30.291h5.877c1.985,0,3.679-0.253,5.076-0.756c1.397-0.506,2.544-1.203,3.437-2.097
|
||||||
|
c0.894-0.892,1.54-1.937,1.944-3.131c0.4-1.197,0.606-2.487,0.606-3.869c0-2.764-0.902-4.927-2.702-6.48
|
||||||
|
c-1.8-1.558-4.588-2.335-8.361-2.335h-5.877V30.291z"/>
|
||||||
|
<path fill="#FFFFFF" d="M127.329,0.689v25.243h-16.043c-1.452,0-2.628,1.128-2.628,2.517v7.438
|
||||||
|
c0,1.392,1.176,2.519,2.628,2.519h16.043v25.241h14.604V0.689H127.329z"/>
|
||||||
|
<path fill="#DB6B26" d="M400.482,30.821c-1.021-16.438-19.171-30.662-26.648-30.819
|
||||||
|
c-7.479-0.159-21.459,17.25-22.024,34.938c-0.53,16.585,13.818,27.958,19.996,29.401c0.172-7.803,0.805-36.532,0.911-39.882
|
||||||
|
c0.223-6.846,0.563-17.498,1.723-17.852c0.665-0.203,1.571,5.785,1.46,9.324c-0.023,0.675-0.031,2.862-0.031,5.966
|
||||||
|
c1.251-1.255,2.558-2.558,3.352-3.328c2.177-2.11,3.14-1.859,2.096,0.023c-0.643,1.158-3.408,5.008-5.441,7.798
|
||||||
|
c0.012,5.627,0.037,12.709,0.064,19.309c2.871-3.315,6.386-7.289,8.232-9.057c3.872-3.702,4.284-3.235,2.455,0.651
|
||||||
|
c-1.123,2.382-6.614,8.736-10.668,13.747c0.025,5.855,0.045,10.778,0.05,13.129C386.88,61.81,401.481,46.96,400.482,30.821"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 7.1 KiB |
|
|
@ -0,0 +1,75 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- Generator: Adobe Illustrator 13.0.0, SVG Export Plug-In -->
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" [
|
||||||
|
<!ENTITY ns_flows "http://ns.adobe.com/Flows/1.0/">
|
||||||
|
]>
|
||||||
|
<svg version="1.0"
|
||||||
|
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/"
|
||||||
|
x="0px" y="0px" width="408px" height="71px" viewBox="-5.208 -4.384 408 71" enable-background="new -5.208 -4.384 408 71"
|
||||||
|
xml:space="preserve">
|
||||||
|
<defs>
|
||||||
|
</defs>
|
||||||
|
<path fill="#596667" d="M111.401,42.425c-1.112,0-2.896,0.109-4.007,1.986c-0.441,0.744-0.816,1.564-1.631,2.516
|
||||||
|
c-1.481,1.727-3.297,3.045-5.44,3.952c-2.146,0.908-4.589,1.36-7.325,1.36c-2.766,0-5.23-0.452-7.385-1.36
|
||||||
|
c-2.162-0.907-3.98-2.226-5.462-3.952c-1.485-1.73-2.618-3.84-3.411-6.334c-0.789-2.489-1.185-5.306-1.185-8.444
|
||||||
|
c0-3.114,0.396-5.913,1.185-8.406c0.793-2.489,1.926-4.603,3.411-6.33c1.482-1.729,3.3-3.052,5.462-3.976
|
||||||
|
c2.155-0.922,4.619-1.383,7.385-1.383c2.736,0,5.179,0.461,7.325,1.383c2.143,0.924,3.959,2.247,5.44,3.976
|
||||||
|
c0.716,0.834,1.352,1.757,1.903,2.772c1.064,1.96,3.735,1.726,3.735,1.726h12.112c-0.248-0.817-0.505-1.63-0.817-2.422
|
||||||
|
c-1.538-3.918-3.702-7.318-6.497-10.198c-2.794-2.88-6.16-5.148-10.097-6.807C102.163,0.827,97.799,0,92.998,0
|
||||||
|
C88.2,0,83.827,0.82,79.876,2.462c-3.951,1.642-7.331,3.902-10.14,6.783c-2.811,2.884-4.981,6.28-6.521,10.197
|
||||||
|
c-0.092,0.235-0.173,0.476-0.26,0.713c-0.083-0.222-0.159-0.447-0.247-0.667c-1.562-3.918-3.757-7.318-6.594-10.198
|
||||||
|
c-2.835-2.879-6.251-5.147-10.248-6.807c-3.997-1.656-8.428-2.483-13.299-2.483c-4.87,0-9.308,0.819-13.319,2.461
|
||||||
|
c-4.01,1.642-7.439,3.903-10.29,6.784c-2.854,2.883-5.056,6.279-6.619,10.196C0.78,23.363,0,27.598,0,32.148
|
||||||
|
c0,4.553,0.78,8.787,2.34,12.705c1.563,3.917,3.765,7.324,6.619,10.218c2.851,2.894,6.28,5.162,10.29,6.804
|
||||||
|
c4.011,1.643,8.449,2.465,13.319,2.465c4.871,0,9.302-0.822,13.299-2.465c3.997-1.642,7.413-3.91,10.248-6.804
|
||||||
|
c2.837-2.894,5.032-6.301,6.594-10.218c0.091-0.228,0.169-0.46,0.255-0.689c0.084,0.229,0.162,0.462,0.251,0.689
|
||||||
|
c1.54,3.917,3.71,7.324,6.521,10.218c2.809,2.894,6.189,5.162,10.14,6.804c3.951,1.643,8.324,2.465,13.122,2.465
|
||||||
|
c4.801,0,9.165-0.822,13.104-2.465c3.937-1.642,7.303-3.91,10.097-6.804c2.795-2.894,4.959-6.301,6.497-10.218
|
||||||
|
c0.312-0.793,0.57-1.609,0.818-2.428H111.401z M48.981,40.593c-0.8,2.494-1.954,4.604-3.458,6.334
|
||||||
|
c-1.503,1.727-3.346,3.045-5.521,3.951c-2.178,0.909-4.657,1.361-7.434,1.361c-2.807,0-5.308-0.452-7.496-1.361
|
||||||
|
c-2.193-0.906-4.038-2.225-5.543-3.951c-1.506-1.73-2.657-3.84-3.462-6.334c-0.8-2.489-1.202-5.306-1.202-8.445
|
||||||
|
c0-3.113,0.402-5.912,1.202-8.405c0.805-2.489,1.956-4.603,3.462-6.329c1.505-1.73,3.35-3.053,5.543-3.977
|
||||||
|
c2.188-0.921,4.689-1.382,7.496-1.382c2.777,0,5.256,0.461,7.434,1.382c2.175,0.924,4.018,2.247,5.521,3.977
|
||||||
|
c1.504,1.726,2.658,3.84,3.458,6.329c0.802,2.493,1.204,5.292,1.204,8.405C50.185,35.288,49.783,38.104,48.981,40.593z"/>
|
||||||
|
<path fill="#596667" d="M208.964,32.148c0,4.553-0.784,8.787-2.341,12.705c-1.564,3.917-3.761,7.324-6.594,10.218
|
||||||
|
c-2.838,2.894-6.252,5.162-10.251,6.804c-3.996,1.643-8.427,2.465-13.299,2.465c-4.87,0-9.307-0.822-13.317-2.465
|
||||||
|
c-4.012-1.642-7.442-3.91-10.29-6.804c-2.856-2.894-5.059-6.301-6.62-10.218c-1.56-3.918-2.34-8.152-2.34-12.705
|
||||||
|
c0-4.55,0.78-8.785,2.34-12.706c1.561-3.917,3.764-7.313,6.62-10.196c2.848-2.881,6.278-5.142,10.29-6.784
|
||||||
|
c4.01-1.642,8.447-2.461,13.317-2.461c4.872,0,9.303,0.827,13.299,2.483c3.999,1.66,7.413,3.928,10.251,6.807
|
||||||
|
c2.833,2.88,5.029,6.28,6.594,10.198C208.18,23.406,208.964,27.626,208.964,32.148 M194.097,32.148c0-3.113-0.401-5.912-1.202-8.405
|
||||||
|
c-0.8-2.489-1.954-4.603-3.458-6.329c-1.504-1.73-3.347-3.053-5.521-3.977c-2.179-0.921-4.658-1.382-7.436-1.382
|
||||||
|
c-2.806,0-5.306,0.461-7.494,1.382c-2.195,0.924-4.04,2.247-5.544,3.977c-1.506,1.726-2.658,3.84-3.462,6.329
|
||||||
|
c-0.8,2.493-1.203,5.292-1.203,8.405c0,3.14,0.403,5.956,1.203,8.445c0.804,2.494,1.956,4.604,3.462,6.334
|
||||||
|
c1.504,1.727,3.349,3.045,5.544,3.951c2.188,0.909,4.688,1.361,7.494,1.361c2.778,0,5.257-0.452,7.436-1.361
|
||||||
|
c2.174-0.906,4.017-2.225,5.521-3.951c1.504-1.73,2.658-3.84,3.458-6.334C193.696,38.104,194.097,35.288,194.097,32.148"/>
|
||||||
|
<path fill="#596667" d="M210.603,63.648V0.69h23.159c4.351,0,8.053,0.405,11.104,1.21
|
||||||
|
c3.053,0.808,5.546,1.944,7.475,3.415c1.931,1.468,3.334,3.255,4.214,5.358c0.878,2.103,1.319,4.452,1.319,7.044
|
||||||
|
c0,1.41-0.204,2.77-0.606,4.082c-0.404,1.312-1.036,2.542-1.902,3.696c-0.864,1.15-1.971,2.193-3.326,3.133
|
||||||
|
c-1.354,0.935-2.982,1.748-4.885,2.44c4.151,1.01,7.217,2.645,9.208,4.906c1.985,2.262,2.979,5.161,2.979,8.705
|
||||||
|
c0,2.676-0.519,5.17-1.556,7.473c-1.037,2.307-2.558,4.314-4.557,6.031c-2.004,1.713-4.474,3.053-7.412,4.016
|
||||||
|
c-2.938,0.967-6.294,1.449-10.069,1.449H210.603z M225.208,27.178h7.604c1.612,0,3.066-0.114,4.365-0.343
|
||||||
|
c1.294-0.232,2.397-0.633,3.306-1.21c0.907-0.577,1.596-1.369,2.074-2.378c0.476-1.009,0.71-2.275,0.71-3.804
|
||||||
|
c0-1.494-0.185-2.742-0.56-3.738c-0.375-0.991-0.952-1.79-1.73-2.398c-0.775-0.605-1.765-1.034-2.958-1.294
|
||||||
|
c-1.197-0.26-2.614-0.39-4.256-0.39h-8.555V27.178z M225.208,36.944V52.63h10.279c1.931,0,3.511-0.246,4.735-0.734
|
||||||
|
c1.224-0.492,2.183-1.126,2.872-1.902c0.692-0.777,1.166-1.656,1.426-2.639c0.259-0.977,0.389-1.971,0.389-2.978
|
||||||
|
c0-1.153-0.15-2.19-0.452-3.112c-0.302-0.921-0.82-1.698-1.554-2.334c-0.736-0.634-1.711-1.123-2.921-1.471
|
||||||
|
c-1.21-0.344-2.735-0.517-4.578-0.517H225.208z"/>
|
||||||
|
<polygon fill="#596667" points="301.985,0.689 301.985,11.924 276.144,11.924 276.144,26.616 295.934,26.616
|
||||||
|
295.934,37.419 276.144,37.419 276.144,52.412 301.985,52.412 301.985,63.647 261.454,63.647 261.454,0.689 "/>
|
||||||
|
<path fill="#596667" d="M319.388,40.358v23.29h-14.604V0.689h20.481c4.549,0,8.431,0.472,11.646,1.407
|
||||||
|
c3.211,0.936,5.835,2.24,7.862,3.91c2.032,1.672,3.506,3.643,4.433,5.919c0.919,2.275,1.38,4.753,1.38,7.434
|
||||||
|
c0,2.046-0.274,3.973-0.823,5.787c-0.543,1.815-1.36,3.496-2.438,5.036c-1.08,1.54-2.406,2.915-3.975,4.126
|
||||||
|
c-1.572,1.211-3.38,2.203-5.426,2.98c0.98,0.492,1.896,1.098,2.745,1.814c0.848,0.721,1.592,1.6,2.229,2.637l13.393,21.908h-13.221
|
||||||
|
c-2.451,0-4.207-0.922-5.272-2.764l-10.457-18.279c-0.461-0.809-1.003-1.382-1.622-1.73c-0.617-0.344-1.491-0.517-2.611-0.517
|
||||||
|
H319.388z M319.388,30.291h5.877c1.985,0,3.679-0.253,5.076-0.756c1.397-0.506,2.544-1.203,3.437-2.097
|
||||||
|
c0.894-0.892,1.54-1.937,1.944-3.131c0.4-1.197,0.606-2.487,0.606-3.869c0-2.764-0.902-4.927-2.702-6.48
|
||||||
|
c-1.8-1.558-4.588-2.335-8.361-2.335h-5.877V30.291z"/>
|
||||||
|
<path fill="#596667" d="M127.329,0.689v25.243h-16.043c-1.452,0-2.628,1.128-2.628,2.517v7.438
|
||||||
|
c0,1.392,1.176,2.519,2.628,2.519h16.043v25.241h14.604V0.689H127.329z"/>
|
||||||
|
<path fill="#DB6B26" d="M400.482,30.821c-1.021-16.438-19.171-30.662-26.648-30.819
|
||||||
|
c-7.479-0.159-21.459,17.25-22.024,34.938c-0.53,16.585,13.818,27.958,19.996,29.401c0.172-7.803,0.805-36.532,0.911-39.882
|
||||||
|
c0.223-6.846,0.563-17.498,1.723-17.852c0.665-0.203,1.571,5.785,1.46,9.324c-0.023,0.675-0.031,2.862-0.031,5.966
|
||||||
|
c1.251-1.255,2.558-2.558,3.352-3.328c2.177-2.11,3.14-1.859,2.096,0.023c-0.643,1.158-3.408,5.008-5.441,7.798
|
||||||
|
c0.012,5.627,0.037,12.709,0.064,19.309c2.871-3.315,6.386-7.289,8.232-9.057c3.872-3.702,4.284-3.235,2.455,0.651
|
||||||
|
c-1.123,2.382-6.614,8.736-10.668,13.747c0.025,5.855,0.045,10.778,0.05,13.129C386.88,61.81,401.481,46.96,400.482,30.821"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 7.1 KiB |
|
|
@ -0,0 +1,16 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- Generator: Adobe Illustrator 13.0.0, SVG Export Plug-In -->
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [
|
||||||
|
<!ENTITY ns_flows "http://ns.adobe.com/Flows/1.0/">
|
||||||
|
]>
|
||||||
|
<svg version="1.1"
|
||||||
|
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/"
|
||||||
|
x="0px" y="0px" width="77px" height="25px" viewBox="0 -0.167 77 25" enable-background="new 0 -0.167 77 25"
|
||||||
|
xml:space="preserve">
|
||||||
|
<defs>
|
||||||
|
</defs>
|
||||||
|
<path fill="#FFFFFF" d="M60,25h15c-5.037,0-5-25-15-25V25z"/>
|
||||||
|
<g>
|
||||||
|
<path fill="#FFFFFF" d="M15,25H0C5.037,25,5,0,15,0V25z"/>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 704 B |
|
|
@ -0,0 +1,16 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- Generator: Adobe Illustrator 13.0.0, SVG Export Plug-In -->
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [
|
||||||
|
<!ENTITY ns_flows "http://ns.adobe.com/Flows/1.0/">
|
||||||
|
]>
|
||||||
|
<svg version="1.1"
|
||||||
|
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/"
|
||||||
|
x="0px" y="0px" width="100px" height="110px" viewBox="0 0 100 110" enable-background="new 0 0 100 110" xml:space="preserve">
|
||||||
|
<defs>
|
||||||
|
</defs>
|
||||||
|
<path d="M0,30C5,30,10,0,20,0c5,0,60,0,65,0c10,0,10,30,15,30"/>
|
||||||
|
<path fill="#E67E22" d="M0,70c5,0,10-30,20-30c0,10,0,15,0,15v15"/>
|
||||||
|
<path fill="#E67E22" d="M100,70c-5,0-10-30-20-30c0,10,0,15,0,15v15"/>
|
||||||
|
<path fill="#B9530F" d="M0,110c5,0,10-30,20-30c0,10,0,15,0,15v15"/>
|
||||||
|
<path fill="#B9530F" d="M100,110c-5,0-10-30-20-30c0,10,0,15,0,15v15"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 909 B |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 2.7 KiB |
|
|
@ -0,0 +1,5 @@
|
||||||
|
$(document).ready(function(){
|
||||||
|
$(document.body).removeClass('preload')
|
||||||
|
|
||||||
|
$('form input[type=text], form input[type=password]').first().focus()
|
||||||
|
})
|
||||||
|
|
@ -0,0 +1,238 @@
|
||||||
|
/*
|
||||||
|
* October General Utilities
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Ensure the CSRF token is added to all AJAX requests.
|
||||||
|
*/
|
||||||
|
|
||||||
|
$.ajaxPrefilter(function(options) {
|
||||||
|
var token = $('meta[name="csrf-token"]').attr('content')
|
||||||
|
|
||||||
|
if (token) {
|
||||||
|
if (!options.headers) options.headers = {}
|
||||||
|
options.headers['X-CSRF-TOKEN'] = token
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Path helpers
|
||||||
|
*/
|
||||||
|
|
||||||
|
if ($.oc === undefined)
|
||||||
|
$.oc = {}
|
||||||
|
|
||||||
|
$.oc.backendUrl = function(url) {
|
||||||
|
var backendBasePath = $('meta[name="backend-base-path"]').attr('content')
|
||||||
|
|
||||||
|
if (!backendBasePath)
|
||||||
|
return url
|
||||||
|
|
||||||
|
if (url.substr(0, 1) == '/')
|
||||||
|
url = url.substr(1)
|
||||||
|
|
||||||
|
return backendBasePath + '/' + url
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Asset Manager
|
||||||
|
*
|
||||||
|
* Usage: assetManager.load({ css:[], js:[], img:[] }, onLoadedCallback)
|
||||||
|
*/
|
||||||
|
|
||||||
|
AssetManager = function() {
|
||||||
|
|
||||||
|
var o = {
|
||||||
|
|
||||||
|
load: function(collection, callback) {
|
||||||
|
var jsList = (collection.js) ? collection.js : [],
|
||||||
|
cssList = (collection.css) ? collection.css : [],
|
||||||
|
imgList = (collection.img) ? collection.img : []
|
||||||
|
|
||||||
|
jsList = $.grep(jsList, function(item){
|
||||||
|
return $('head script[src="'+item+'"]').length == 0
|
||||||
|
})
|
||||||
|
|
||||||
|
cssList = $.grep(cssList, function(item){
|
||||||
|
return $('head link[href="'+item+'"]').length == 0
|
||||||
|
})
|
||||||
|
|
||||||
|
var cssCounter = 0,
|
||||||
|
jsLoaded = false,
|
||||||
|
imgLoaded = false
|
||||||
|
|
||||||
|
if (jsList.length === 0 && cssList.length === 0 && imgList.length === 0) {
|
||||||
|
callback && callback()
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
o.loadJavaScript(jsList, function(){
|
||||||
|
jsLoaded = true
|
||||||
|
checkLoaded()
|
||||||
|
})
|
||||||
|
|
||||||
|
$.each(cssList, function(index, source){
|
||||||
|
o.loadStyleSheet(source, function(){
|
||||||
|
cssCounter++
|
||||||
|
checkLoaded()
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
o.loadImage(imgList, function(){
|
||||||
|
imgLoaded = true
|
||||||
|
checkLoaded()
|
||||||
|
})
|
||||||
|
|
||||||
|
function checkLoaded() {
|
||||||
|
if (!imgLoaded)
|
||||||
|
return false
|
||||||
|
|
||||||
|
if (!jsLoaded)
|
||||||
|
return false
|
||||||
|
|
||||||
|
if (cssCounter < cssList.length)
|
||||||
|
return false
|
||||||
|
|
||||||
|
callback && callback()
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Loads StyleSheet files
|
||||||
|
*/
|
||||||
|
loadStyleSheet: function(source, callback) {
|
||||||
|
var cssElement = document.createElement('link')
|
||||||
|
|
||||||
|
cssElement.setAttribute('rel', 'stylesheet')
|
||||||
|
cssElement.setAttribute('type', 'text/css')
|
||||||
|
cssElement.setAttribute('href', source)
|
||||||
|
cssElement.addEventListener('load', callback, false)
|
||||||
|
|
||||||
|
if (typeof cssElement != 'undefined') {
|
||||||
|
document.getElementsByTagName('head')[0].appendChild(cssElement)
|
||||||
|
}
|
||||||
|
|
||||||
|
return cssElement
|
||||||
|
},
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Loads JavaScript files in sequence
|
||||||
|
*/
|
||||||
|
loadJavaScript: function(sources, callback) {
|
||||||
|
if (sources.length <= 0)
|
||||||
|
return callback()
|
||||||
|
|
||||||
|
var source = sources.shift(),
|
||||||
|
jsElement = document.createElement('script');
|
||||||
|
|
||||||
|
jsElement.setAttribute('type', 'text/javascript')
|
||||||
|
jsElement.setAttribute('src', source)
|
||||||
|
jsElement.addEventListener('load', function() {
|
||||||
|
o.loadJavaScript(sources, callback)
|
||||||
|
}, false)
|
||||||
|
|
||||||
|
if (typeof jsElement != 'undefined') {
|
||||||
|
document.getElementsByTagName('head')[0].appendChild(jsElement)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Loads Image files
|
||||||
|
*/
|
||||||
|
loadImage: function(sources, callback) {
|
||||||
|
if (sources.length <= 0)
|
||||||
|
return callback()
|
||||||
|
|
||||||
|
var loaded = 0
|
||||||
|
$.each(sources, function(index, source){
|
||||||
|
var img = new Image()
|
||||||
|
img.onload = function() {
|
||||||
|
if (++loaded == sources.length && callback)
|
||||||
|
callback()
|
||||||
|
}
|
||||||
|
img.src = source
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
return o;
|
||||||
|
};
|
||||||
|
|
||||||
|
assetManager = new AssetManager();
|
||||||
|
|
||||||
|
/*
|
||||||
|
* String escape
|
||||||
|
*/
|
||||||
|
if ($.oc === undefined)
|
||||||
|
$.oc = {}
|
||||||
|
|
||||||
|
$.oc.escapeHtmlString = function(string) {
|
||||||
|
var htmlEscapes = {
|
||||||
|
'&': '&',
|
||||||
|
'<': '<',
|
||||||
|
'>': '>',
|
||||||
|
'"': '"',
|
||||||
|
"'": ''',
|
||||||
|
'/': '/'
|
||||||
|
},
|
||||||
|
htmlEscaper = /[&<>"'\/]/g
|
||||||
|
|
||||||
|
return ('' + string).replace(htmlEscaper, function(match) {
|
||||||
|
return htmlEscapes[match];
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Inverse Click Event (not used)
|
||||||
|
*
|
||||||
|
* Calls the handler function if the user has clicked outside the object
|
||||||
|
* and not on any of the elements in the exception list.
|
||||||
|
*/
|
||||||
|
/*
|
||||||
|
$.fn.extend({
|
||||||
|
clickOutside: function(handler, exceptions) {
|
||||||
|
var $this = this;
|
||||||
|
|
||||||
|
$('body').on('click', function(event) {
|
||||||
|
if (exceptions && $.inArray(event.target, exceptions) > -1) {
|
||||||
|
return;
|
||||||
|
} else if ($.contains($this[0], event.target)) {
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
handler(event, $this);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
})
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Browser Fixes
|
||||||
|
* - If another fix using JS is necessary, move this logic to backend.fixes.js
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Internet Explorer v11
|
||||||
|
* - IE11 will not honor height 100% when overflow is used on the Y axis.
|
||||||
|
*/
|
||||||
|
if (!!window.MSInputMethodContext && !!document.documentMode) {
|
||||||
|
$(window).on('resize', function() {
|
||||||
|
fixMediaManager()
|
||||||
|
fixSidebar()
|
||||||
|
})
|
||||||
|
|
||||||
|
function fixMediaManager() {
|
||||||
|
var $el = $('div[data-control="media-manager"] .control-scrollpad')
|
||||||
|
$el.height($el.parent().height())
|
||||||
|
}
|
||||||
|
|
||||||
|
function fixSidebar() {
|
||||||
|
$('#layout-sidenav').height(Math.max(
|
||||||
|
$('#layout-body').innerHeight(),
|
||||||
|
$(window).height() - $('#layout-mainmenu').height()
|
||||||
|
))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,90 @@
|
||||||
|
/*
|
||||||
|
* Alerts
|
||||||
|
*
|
||||||
|
* Displays alert and confirmation dialogs
|
||||||
|
*
|
||||||
|
* JavaScript API:
|
||||||
|
* $.oc.alert()
|
||||||
|
* $.oc.confirm()
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - Sweet Alert
|
||||||
|
* - Translations (october.lang.js)
|
||||||
|
*/
|
||||||
|
(function($){
|
||||||
|
|
||||||
|
if ($.oc === undefined)
|
||||||
|
$.oc = {}
|
||||||
|
|
||||||
|
$.oc.alert = function alert(message) {
|
||||||
|
swal({
|
||||||
|
title: message,
|
||||||
|
confirmButtonClass: 'btn-primary'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
$.oc.confirm = function confirm(message, callback) {
|
||||||
|
|
||||||
|
swal({
|
||||||
|
title: message,
|
||||||
|
showCancelButton: true,
|
||||||
|
confirmButtonClass: 'btn-primary'
|
||||||
|
}, callback)
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
})(jQuery);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Implement alerts with AJAX framework
|
||||||
|
*/
|
||||||
|
|
||||||
|
$(window).on('ajaxErrorMessage', function(event, message){
|
||||||
|
if (!message) return
|
||||||
|
|
||||||
|
$.oc.alert(message)
|
||||||
|
|
||||||
|
// Prevent the default alert() message
|
||||||
|
event.preventDefault()
|
||||||
|
})
|
||||||
|
|
||||||
|
$(window).on('ajaxConfirmMessage', function(event, message){
|
||||||
|
if (!message) return
|
||||||
|
|
||||||
|
$.oc.confirm(message, function(isConfirm){
|
||||||
|
isConfirm
|
||||||
|
? event.promise.resolve()
|
||||||
|
: event.promise.reject()
|
||||||
|
})
|
||||||
|
|
||||||
|
// Prevent the default confirm() message
|
||||||
|
event.preventDefault()
|
||||||
|
return true
|
||||||
|
})
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Override "Sweet Alert" functions to translate default buttons
|
||||||
|
*/
|
||||||
|
|
||||||
|
$(document).ready(function(){
|
||||||
|
if (!window.swal) return
|
||||||
|
|
||||||
|
var swal = window.swal
|
||||||
|
|
||||||
|
window.sweetAlert = window.swal = function(message, callback) {
|
||||||
|
if (typeof message === 'object') {
|
||||||
|
// Do not override if texts are provided
|
||||||
|
message.confirmButtonText = message.confirmButtonText || $.oc.lang.get('alert.confirm_button_text')
|
||||||
|
message.cancelButtonText = message.cancelButtonText || $.oc.lang.get('alert.cancel_button_text')
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
message = {
|
||||||
|
title: message,
|
||||||
|
confirmButtonText: $.oc.lang.get('alert.confirm_button_text'),
|
||||||
|
cancelButtonText: $.oc.lang.get('alert.cancel_button_text')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
swal(message, callback)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
@ -0,0 +1,175 @@
|
||||||
|
/*
|
||||||
|
* Date time converter.
|
||||||
|
* See moment.js for format options.
|
||||||
|
* http://momentjs.com/docs/#/displaying/format/
|
||||||
|
*
|
||||||
|
* Usage:
|
||||||
|
*
|
||||||
|
* <time
|
||||||
|
* data-datetime-control
|
||||||
|
* datetime="2014-11-19 01:21:57"
|
||||||
|
* data-format="dddd Do [o]f MMMM YYYY hh:mm:ss A"
|
||||||
|
* data-timezone="Australia/Sydney"
|
||||||
|
* data-locale="en-au">This text will be replaced</time>
|
||||||
|
*
|
||||||
|
* Alias options:
|
||||||
|
*
|
||||||
|
* time -> 6:28 AM
|
||||||
|
* timeLong -> 6:28:01 AM
|
||||||
|
* date -> 04/23/2016
|
||||||
|
* dateMin -> 4/23/2016
|
||||||
|
* dateLong -> April 23, 2016
|
||||||
|
* dateLongMin -> Apr 23, 2016
|
||||||
|
* dateTime -> April 23, 2016 6:28 AM
|
||||||
|
* dateTimeMin -> Apr 23, 2016 6:28 AM
|
||||||
|
* dateTimeLong -> Saturday, April 23, 2016 6:28 AM
|
||||||
|
* dateTimeLongMin -> Sat, Apr 23, 2016 6:29 AM
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
+function ($) { "use strict";
|
||||||
|
var Base = $.oc.foundation.base,
|
||||||
|
BaseProto = Base.prototype
|
||||||
|
|
||||||
|
var DateTimeConverter = function (element, options) {
|
||||||
|
this.$el = $(element)
|
||||||
|
this.options = options || {}
|
||||||
|
|
||||||
|
$.oc.foundation.controlUtils.markDisposable(element)
|
||||||
|
Base.call(this)
|
||||||
|
this.init()
|
||||||
|
}
|
||||||
|
|
||||||
|
DateTimeConverter.prototype = Object.create(BaseProto)
|
||||||
|
DateTimeConverter.prototype.constructor = DateTimeConverter
|
||||||
|
|
||||||
|
DateTimeConverter.prototype.init = function() {
|
||||||
|
this.initDefaults()
|
||||||
|
|
||||||
|
this.$el.text(this.getDateTimeValue())
|
||||||
|
|
||||||
|
this.$el.one('dispose-control', this.proxy(this.dispose))
|
||||||
|
}
|
||||||
|
|
||||||
|
DateTimeConverter.prototype.initDefaults = function() {
|
||||||
|
if (!this.options.timezone) {
|
||||||
|
this.options.timezone = $('meta[name="backend-timezone"]').attr('content')
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!this.options.locale) {
|
||||||
|
this.options.locale = $('meta[name="backend-locale"]').attr('content')
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!this.options.format) {
|
||||||
|
this.options.format = 'llll'
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.options.formatAlias) {
|
||||||
|
this.options.format = this.getFormatFromAlias(this.options.formatAlias)
|
||||||
|
}
|
||||||
|
|
||||||
|
this.appTimezone = $('meta[name="app-timezone"]').attr('content')
|
||||||
|
if (!this.appTimezone) {
|
||||||
|
this.appTimezone = 'UTC'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
DateTimeConverter.prototype.getDateTimeValue = function() {
|
||||||
|
this.datetime = this.$el.attr('datetime')
|
||||||
|
|
||||||
|
if (this.$el.get(0).hasAttribute('data-ignore-timezone')) {
|
||||||
|
this.appTimezone = 'UTC'
|
||||||
|
this.options.timezone = 'UTC'
|
||||||
|
}
|
||||||
|
|
||||||
|
var momentObj = moment.tz(this.datetime, this.appTimezone),
|
||||||
|
result
|
||||||
|
|
||||||
|
if (this.options.locale) {
|
||||||
|
momentObj = momentObj.locale(this.options.locale)
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.options.timezone) {
|
||||||
|
momentObj = momentObj.tz(this.options.timezone)
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.options.timeSince) {
|
||||||
|
result = momentObj.fromNow()
|
||||||
|
}
|
||||||
|
else if (this.options.timeTense) {
|
||||||
|
result = momentObj.calendar()
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
result = momentObj.format(this.options.format)
|
||||||
|
}
|
||||||
|
|
||||||
|
return result
|
||||||
|
}
|
||||||
|
|
||||||
|
DateTimeConverter.prototype.getFormatFromAlias = function(alias) {
|
||||||
|
var map = {
|
||||||
|
time: 'LT',
|
||||||
|
timeLong: 'LTS',
|
||||||
|
date: 'L',
|
||||||
|
dateMin: 'l',
|
||||||
|
dateLong: 'LL',
|
||||||
|
dateLongMin: 'll',
|
||||||
|
dateTime: 'LLL',
|
||||||
|
dateTimeMin: 'lll',
|
||||||
|
dateTimeLong: 'LLLL',
|
||||||
|
dateTimeLongMin: 'llll'
|
||||||
|
}
|
||||||
|
|
||||||
|
return map[alias] ? map[alias] : 'llll'
|
||||||
|
}
|
||||||
|
|
||||||
|
DateTimeConverter.prototype.dispose = function() {
|
||||||
|
this.$el.off('dispose-control', this.proxy(this.dispose))
|
||||||
|
this.$el.removeData('oc.dateTimeConverter')
|
||||||
|
|
||||||
|
this.$el = null
|
||||||
|
this.options = null
|
||||||
|
|
||||||
|
BaseProto.dispose.call(this)
|
||||||
|
}
|
||||||
|
|
||||||
|
DateTimeConverter.DEFAULTS = {
|
||||||
|
format: null,
|
||||||
|
formatAlias: null,
|
||||||
|
timezone: null,
|
||||||
|
locale: null,
|
||||||
|
timeTense: false,
|
||||||
|
timeSince: false
|
||||||
|
}
|
||||||
|
|
||||||
|
// PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.dateTimeConverter
|
||||||
|
|
||||||
|
$.fn.dateTimeConverter = function (option) {
|
||||||
|
var args = Array.prototype.slice.call(arguments, 1), items, result
|
||||||
|
|
||||||
|
items = this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.dateTimeConverter')
|
||||||
|
var options = $.extend({}, DateTimeConverter.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
if (!data) $this.data('oc.dateTimeConverter', (data = new DateTimeConverter(this, options)))
|
||||||
|
if (typeof option == 'string') result = data[option].apply(data, args)
|
||||||
|
if (typeof result != 'undefined') return false
|
||||||
|
})
|
||||||
|
|
||||||
|
return result ? result : items
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.dateTimeConverter.Constructor = DateTimeConverter
|
||||||
|
|
||||||
|
$.fn.dateTimeConverter.noConflict = function () {
|
||||||
|
$.fn.dateTimeConverter = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
$(document).render(function (){
|
||||||
|
$('time[data-datetime-control]').dateTimeConverter()
|
||||||
|
})
|
||||||
|
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,169 @@
|
||||||
|
/*
|
||||||
|
* File List
|
||||||
|
*
|
||||||
|
* Creates a tree list of clickable folders and files.
|
||||||
|
*
|
||||||
|
* Data attributes:
|
||||||
|
* - data-control="filelist" - enables the file list plugin
|
||||||
|
* - data-group-status-handler - AJAX handler to execute when a group is collapsed or expanded by a user
|
||||||
|
*
|
||||||
|
* JavaScript API:
|
||||||
|
* $('#list').fileList()
|
||||||
|
*
|
||||||
|
* Events
|
||||||
|
* - open.oc.list - this event is triggered on the list element when an item is clicked.
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - Null
|
||||||
|
*/
|
||||||
|
|
||||||
|
+function ($) { "use strict";
|
||||||
|
|
||||||
|
// FILELIST CLASS DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var FileList = function(element, options) {
|
||||||
|
this.options = options
|
||||||
|
this.$el = $(element)
|
||||||
|
|
||||||
|
this.init();
|
||||||
|
}
|
||||||
|
|
||||||
|
FileList.DEFAULTS = {
|
||||||
|
ignoreItemClick: false
|
||||||
|
}
|
||||||
|
|
||||||
|
FileList.prototype.init = function (){
|
||||||
|
var self = this
|
||||||
|
|
||||||
|
this.$el.on('click', 'li.group > h4 > a, li.group > div.group', function() {
|
||||||
|
self.toggleGroup($(this).closest('li'))
|
||||||
|
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
|
||||||
|
if (!this.options.ignoreItemClick) {
|
||||||
|
this.$el.on('click', 'li.item > a', function(event) {
|
||||||
|
var e = $.Event('open.oc.list', {relatedTarget: $(this).parent().get(0), clickEvent: event})
|
||||||
|
self.$el.trigger(e, this)
|
||||||
|
|
||||||
|
return false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$el.on('ajaxUpdate', $.proxy(this.update, this))
|
||||||
|
}
|
||||||
|
|
||||||
|
FileList.prototype.toggleGroup = function(group) {
|
||||||
|
var $group = $(group);
|
||||||
|
|
||||||
|
$group.attr('data-status') == 'expanded' ?
|
||||||
|
this.collapseGroup($group) :
|
||||||
|
this.expandGroup($group)
|
||||||
|
}
|
||||||
|
|
||||||
|
FileList.prototype.collapseGroup = function(group) {
|
||||||
|
var
|
||||||
|
$list = $('> ul, > div.subitems', group),
|
||||||
|
self = this;
|
||||||
|
|
||||||
|
$list.css('overflow', 'hidden')
|
||||||
|
$list.animate({'height': 0}, { duration: 100, queue: false, complete: function() {
|
||||||
|
$list.css({
|
||||||
|
'overflow': 'visible',
|
||||||
|
'display': 'none'
|
||||||
|
})
|
||||||
|
$(group).attr('data-status', 'collapsed')
|
||||||
|
$(window).trigger('resize')
|
||||||
|
} })
|
||||||
|
|
||||||
|
this.sendGroupStatusRequest(group, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
FileList.prototype.expandGroup = function(group) {
|
||||||
|
var
|
||||||
|
$list = $('> ul, > div.subitems', group),
|
||||||
|
self = this;
|
||||||
|
|
||||||
|
$list.css({
|
||||||
|
'overflow': 'hidden',
|
||||||
|
'display': 'block',
|
||||||
|
'height': 0
|
||||||
|
})
|
||||||
|
$list.animate({'height': $list[0].scrollHeight}, { duration: 100, queue: false, complete: function() {
|
||||||
|
$list.css({
|
||||||
|
'overflow': 'visible',
|
||||||
|
'height': 'auto'
|
||||||
|
})
|
||||||
|
$(group).attr('data-status', 'expanded')
|
||||||
|
$(window).trigger('resize')
|
||||||
|
} })
|
||||||
|
|
||||||
|
this.sendGroupStatusRequest(group, 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
FileList.prototype.sendGroupStatusRequest = function(group, status) {
|
||||||
|
if (this.options.groupStatusHandler !== undefined) {
|
||||||
|
var groupId = $(group).data('group-id')
|
||||||
|
if (groupId === undefined)
|
||||||
|
groupId = $('> h4 a', group).text();
|
||||||
|
|
||||||
|
$(group).request(this.options.groupStatusHandler, {data: {group: groupId, status: status}})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
FileList.prototype.markActive = function(dataId) {
|
||||||
|
$('li.item', this.$el).removeClass('active')
|
||||||
|
if (dataId)
|
||||||
|
$('li.item[data-id="'+dataId+'"]', this.$el).addClass('active')
|
||||||
|
|
||||||
|
this.dataId = dataId
|
||||||
|
}
|
||||||
|
|
||||||
|
FileList.prototype.update = function() {
|
||||||
|
if (this.dataId !== undefined)
|
||||||
|
this.markActive(this.dataId)
|
||||||
|
}
|
||||||
|
|
||||||
|
// FILELIST PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.fileList
|
||||||
|
|
||||||
|
$.fn.fileList = function (option) {
|
||||||
|
var args = arguments;
|
||||||
|
|
||||||
|
return this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.fileList')
|
||||||
|
var options = $.extend({}, FileList.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
|
||||||
|
if (!data) $this.data('oc.fileList', (data = new FileList(this, options)))
|
||||||
|
if (typeof option == 'string') {
|
||||||
|
var methodArgs = [];
|
||||||
|
for (var i=1; i<args.length; i++)
|
||||||
|
methodArgs.push(args[i])
|
||||||
|
|
||||||
|
data[option].apply(data, methodArgs)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.fileList.Constructor = FileList
|
||||||
|
|
||||||
|
// FILELIST NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.fileList.noConflict = function () {
|
||||||
|
$.fn.fileList = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// FILELIST DATA-API
|
||||||
|
// ===============
|
||||||
|
|
||||||
|
$(document).ready(function () {
|
||||||
|
$('[data-control=filelist]').fileList()
|
||||||
|
})
|
||||||
|
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,224 @@
|
||||||
|
/*
|
||||||
|
* Flyout plugin.
|
||||||
|
*/
|
||||||
|
+function ($) { "use strict";
|
||||||
|
|
||||||
|
var Base = $.oc.foundation.base,
|
||||||
|
BaseProto = Base.prototype
|
||||||
|
|
||||||
|
// SCROLLPAD CLASS DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var Flyout = function(element, options) {
|
||||||
|
this.$el = $(element)
|
||||||
|
this.$overlay = null
|
||||||
|
this.options = options
|
||||||
|
|
||||||
|
Base.call(this)
|
||||||
|
|
||||||
|
this.init()
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype = Object.create(BaseProto)
|
||||||
|
Flyout.prototype.constructor = Flyout
|
||||||
|
|
||||||
|
Flyout.prototype.dispose = function() {
|
||||||
|
this.removeOverlay()
|
||||||
|
this.$el.removeData('oc.flyout')
|
||||||
|
this.$el = null
|
||||||
|
|
||||||
|
if (this.options.flyoutToggle) {
|
||||||
|
this.removeToggle()
|
||||||
|
}
|
||||||
|
|
||||||
|
BaseProto.dispose.call(this)
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.show = function() {
|
||||||
|
var $cells = this.$el.find('> .layout-cell'),
|
||||||
|
$flyout = this.$el.find('> .flyout')
|
||||||
|
|
||||||
|
$('[data-control=layout-sidepanel]').sidePanelTab('hideSidePanel')
|
||||||
|
|
||||||
|
this.removeOverlay()
|
||||||
|
|
||||||
|
for (var i = 0; i < $cells.length; i++) {
|
||||||
|
var $cell = $($cells[i]),
|
||||||
|
width = $cell.width()
|
||||||
|
|
||||||
|
$cell.css('width', width)
|
||||||
|
}
|
||||||
|
|
||||||
|
this.createOverlay()
|
||||||
|
|
||||||
|
window.setTimeout(this.proxy(this.setBodyClass), 1)
|
||||||
|
$flyout.css('width', this.options.flyoutWidth)
|
||||||
|
|
||||||
|
this.hideToggle()
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.hide = function() {
|
||||||
|
var $cells = this.$el.find('> .layout-cell'),
|
||||||
|
$flyout = this.$el.find('> .flyout')
|
||||||
|
|
||||||
|
for (var i = 0; i < $cells.length; i++) {
|
||||||
|
var $cell = $($cells[i])
|
||||||
|
|
||||||
|
$cell.css('width', '')
|
||||||
|
}
|
||||||
|
|
||||||
|
$flyout.css('width', 0)
|
||||||
|
|
||||||
|
window.setTimeout(this.proxy(this.removeBodyClass), 1)
|
||||||
|
window.setTimeout(this.proxy(this.removeOverlayAndShowToggle), 300)
|
||||||
|
}
|
||||||
|
|
||||||
|
// FLYOUT INTERNAL METHODS
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
Flyout.prototype.init = function() {
|
||||||
|
this.build()
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.build = function() {
|
||||||
|
if (this.options.flyoutToggle) {
|
||||||
|
this.buildToggle()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.buildToggle = function() {
|
||||||
|
var $toggleContainer = $(this.options.flyoutToggle),
|
||||||
|
$toggle = $('<div class="flyout-toggle"><i class="icon-chevron-right"></i></div>')
|
||||||
|
|
||||||
|
$toggle.on('click', this.proxy(this.show))
|
||||||
|
$toggleContainer.append($toggle)
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.removeToggle = function() {
|
||||||
|
var $toggle = this.getToggle()
|
||||||
|
|
||||||
|
$toggle.off('click', this.proxy(this.show))
|
||||||
|
$toggle.remove()
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.hideToggle = function() {
|
||||||
|
if (!this.options.flyoutToggle) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
this.getToggle().hide()
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.showToggle = function() {
|
||||||
|
if (!this.options.flyoutToggle) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
this.getToggle().show()
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.getToggle = function() {
|
||||||
|
var $toggleContainer = $(this.options.flyoutToggle)
|
||||||
|
|
||||||
|
return $toggleContainer.find('.flyout-toggle')
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.setBodyClass = function() {
|
||||||
|
$(document.body).addClass('flyout-visible')
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.removeBodyClass = function() {
|
||||||
|
$(document.body).removeClass('flyout-visible')
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.createOverlay = function() {
|
||||||
|
this.$overlay = $('<div class="flyout-overlay"/>')
|
||||||
|
|
||||||
|
var position = this.$el.offset()
|
||||||
|
|
||||||
|
this.$overlay.css({
|
||||||
|
top: position.top,
|
||||||
|
left: this.options.flyoutWidth
|
||||||
|
})
|
||||||
|
|
||||||
|
this.$overlay.on('click', this.proxy(this.onOverlayClick))
|
||||||
|
$(document.body).on('keydown', this.proxy(this.onDocumentKeydown))
|
||||||
|
|
||||||
|
$(document.body).append(this.$overlay)
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.removeOverlay = function() {
|
||||||
|
if (!this.$overlay) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$overlay.off('click', this.proxy(this.onOverlayClick))
|
||||||
|
$(document.body).off('keydown', this.proxy(this.onDocumentKeydown))
|
||||||
|
|
||||||
|
this.$overlay.remove()
|
||||||
|
this.$overlay = null
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.removeOverlayAndShowToggle = function() {
|
||||||
|
this.removeOverlay()
|
||||||
|
this.showToggle()
|
||||||
|
}
|
||||||
|
|
||||||
|
// EVENT HANDLERS
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
Flyout.prototype.onOverlayClick = function() {
|
||||||
|
this.hide()
|
||||||
|
}
|
||||||
|
|
||||||
|
Flyout.prototype.onDocumentKeydown = function(ev) {
|
||||||
|
if (ev.key === 'Escape') {
|
||||||
|
this.hide();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// FLYOUT PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
Flyout.DEFAULTS = {
|
||||||
|
flyoutWidth: 400,
|
||||||
|
flyoutToggle: null
|
||||||
|
}
|
||||||
|
|
||||||
|
var old = $.fn.flyout
|
||||||
|
|
||||||
|
$.fn.flyout = function (option) {
|
||||||
|
var args = Array.prototype.slice.call(arguments, 1),
|
||||||
|
result = undefined
|
||||||
|
|
||||||
|
this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.flyout')
|
||||||
|
var options = $.extend({}, Flyout.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
if (!data) $this.data('oc.flyout', (data = new Flyout(this, options)))
|
||||||
|
if (typeof option == 'string') result = data[option].apply(data, args)
|
||||||
|
if (typeof result != 'undefined') return false
|
||||||
|
})
|
||||||
|
|
||||||
|
return result ? result : this
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.flyout.Constructor = Flyout
|
||||||
|
|
||||||
|
// FLYOUT NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.flyout.noConflict = function () {
|
||||||
|
$.fn.flyout = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// FLYOUT DATA-API
|
||||||
|
// ===============
|
||||||
|
|
||||||
|
// Currently flyouts don't use the document render event
|
||||||
|
// and can't be created dynamically (performance considerations).
|
||||||
|
$(document).ready(function(){
|
||||||
|
$('div[data-control=flyout]').flyout()
|
||||||
|
})
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,36 @@
|
||||||
|
/*
|
||||||
|
* This is a bundle file, you can compile this in two ways:
|
||||||
|
* (1) Using your favorite JS combiner
|
||||||
|
* (2) Using CLI command:
|
||||||
|
* php artisan october:util compile assets
|
||||||
|
*
|
||||||
|
* @see october-min.js
|
||||||
|
*
|
||||||
|
|
||||||
|
=require vendor/jquery.touchwipe.js
|
||||||
|
=require vendor/jquery.autoellipsis.js
|
||||||
|
=require vendor/jquery.waterfall.js
|
||||||
|
=require vendor/jquery.cookie.js
|
||||||
|
=require ../vendor/dropzone/dropzone.js
|
||||||
|
=require ../vendor/sweet-alert/sweet-alert.js
|
||||||
|
=require ../vendor/jcrop/js/jquery.Jcrop.js
|
||||||
|
=require ../../../system/assets/vendor/prettify/prettify.js
|
||||||
|
=require ../../widgets/mediamanager/assets/js/mediamanager-global.js
|
||||||
|
|
||||||
|
=require october.lang.js
|
||||||
|
=require october.alert.js
|
||||||
|
=require october.scrollpad.js
|
||||||
|
=require october.verticalmenu.js
|
||||||
|
=require october.navbar.js
|
||||||
|
=require october.sidenav.js
|
||||||
|
=require october.scrollbar.js
|
||||||
|
=require october.filelist.js
|
||||||
|
=require october.layout.js
|
||||||
|
=require october.sidepaneltab.js
|
||||||
|
=require october.simplelist.js
|
||||||
|
=require october.treelist.js
|
||||||
|
=require october.sidenav-tree.js
|
||||||
|
=require october.datetime.js
|
||||||
|
|
||||||
|
=require backend.js
|
||||||
|
*/
|
||||||
|
|
@ -0,0 +1,50 @@
|
||||||
|
/*
|
||||||
|
* Client side translations
|
||||||
|
*/
|
||||||
|
|
||||||
|
if ($.oc === undefined)
|
||||||
|
$.oc = {}
|
||||||
|
|
||||||
|
if ($.oc.langMessages === undefined)
|
||||||
|
$.oc.langMessages = {}
|
||||||
|
|
||||||
|
$.oc.lang = (function(lang, messages) {
|
||||||
|
|
||||||
|
lang.load = function(locale) {
|
||||||
|
if (messages[locale] === undefined) {
|
||||||
|
messages[locale] = {}
|
||||||
|
}
|
||||||
|
|
||||||
|
lang.loadedMessages = messages[locale]
|
||||||
|
}
|
||||||
|
|
||||||
|
lang.get = function(name, defaultValue) {
|
||||||
|
if (!name) return
|
||||||
|
|
||||||
|
var result = lang.loadedMessages
|
||||||
|
|
||||||
|
if (!defaultValue) defaultValue = name
|
||||||
|
|
||||||
|
$.each(name.split('.'), function(index, value) {
|
||||||
|
if (result[value] === undefined) {
|
||||||
|
result = defaultValue
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
result = result[value]
|
||||||
|
})
|
||||||
|
|
||||||
|
return result
|
||||||
|
}
|
||||||
|
|
||||||
|
if (lang.locale === undefined) {
|
||||||
|
lang.locale = $('html').attr('lang') || 'en'
|
||||||
|
}
|
||||||
|
|
||||||
|
if (lang.loadedMessages === undefined) {
|
||||||
|
lang.load(lang.locale)
|
||||||
|
}
|
||||||
|
|
||||||
|
return lang
|
||||||
|
|
||||||
|
})($.oc.lang || {}, $.oc.langMessages);
|
||||||
|
|
@ -0,0 +1,84 @@
|
||||||
|
(function($){
|
||||||
|
var OctoberLayout = function() {
|
||||||
|
this.$accountMenuOverlay = null
|
||||||
|
}
|
||||||
|
|
||||||
|
OctoberLayout.prototype.setPageTitle = function(title) {
|
||||||
|
var $title = $('title')
|
||||||
|
|
||||||
|
if (this.pageTitleTemplate === undefined)
|
||||||
|
this.pageTitleTemplate = $title.data('titleTemplate')
|
||||||
|
|
||||||
|
$title.text(this.pageTitleTemplate.replace('%s', title))
|
||||||
|
}
|
||||||
|
|
||||||
|
OctoberLayout.prototype.updateLayout = function(title) {
|
||||||
|
var $children, $el, fixedWidth, margin
|
||||||
|
|
||||||
|
$('[data-calculate-width]').each(function(){
|
||||||
|
$children = $(this).children()
|
||||||
|
|
||||||
|
if ($children.length > 0) {
|
||||||
|
fixedWidth = 0
|
||||||
|
|
||||||
|
$children.each(function() {
|
||||||
|
$el = $(this)
|
||||||
|
margin = $el.data('oc.layoutMargin')
|
||||||
|
|
||||||
|
if (margin === undefined) {
|
||||||
|
margin = parseInt($el.css('marginRight')) + parseInt($el.css('marginLeft'))
|
||||||
|
$el.data('oc.layoutMargin', margin)
|
||||||
|
}
|
||||||
|
fixedWidth += $el.get(0).offsetWidth + margin
|
||||||
|
})
|
||||||
|
|
||||||
|
$(this).width(fixedWidth)
|
||||||
|
$(this).trigger('oc.widthFixed')
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
OctoberLayout.prototype.toggleAccountMenu = function(el) {
|
||||||
|
var self = this,
|
||||||
|
$el = $(el),
|
||||||
|
$parent = $(el).parent(),
|
||||||
|
$menu = $el.next()
|
||||||
|
|
||||||
|
$el.tooltip('hide')
|
||||||
|
|
||||||
|
if ($menu.hasClass('active')) {
|
||||||
|
self.$accountMenuOverlay.remove()
|
||||||
|
$parent.removeClass('highlight')
|
||||||
|
$menu.removeClass('active')
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
self.$accountMenuOverlay = $('<div />').addClass('popover-overlay')
|
||||||
|
$(document.body).append(self.$accountMenuOverlay)
|
||||||
|
$parent.addClass('highlight')
|
||||||
|
$menu.addClass('active')
|
||||||
|
|
||||||
|
self.$accountMenuOverlay.one('click', function(){
|
||||||
|
self.$accountMenuOverlay.remove()
|
||||||
|
$menu.removeClass('active')
|
||||||
|
$parent.removeClass('highlight')
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($.oc === undefined)
|
||||||
|
$.oc = {}
|
||||||
|
|
||||||
|
$.oc.layout = new OctoberLayout()
|
||||||
|
|
||||||
|
$(document).ready(function(){
|
||||||
|
$.oc.layout.updateLayout()
|
||||||
|
|
||||||
|
window.setTimeout($.oc.layout.updateLayout, 100)
|
||||||
|
})
|
||||||
|
$(window).on('resize', function() {
|
||||||
|
$.oc.layout.updateLayout()
|
||||||
|
})
|
||||||
|
$(window).on('oc.updateUi', function() {
|
||||||
|
$.oc.layout.updateLayout()
|
||||||
|
})
|
||||||
|
})(jQuery);
|
||||||
|
|
@ -0,0 +1,41 @@
|
||||||
|
/*
|
||||||
|
* Top navigation bar. Features of the bar:
|
||||||
|
* - Hide content if the display width is less than 768px. In this case the menu icon is displayed.
|
||||||
|
* When the icon is clicked, the menu content is displayed on the left side of the page.
|
||||||
|
* - If the content doesn't fit the navbar, it can be dragged left and right.
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - DragScroll (october.dragscroll.js)
|
||||||
|
* - VerticalMenu (october.verticalmenu.js)
|
||||||
|
*/
|
||||||
|
|
||||||
|
(function($){
|
||||||
|
$(document).ready(function(){
|
||||||
|
$('nav.navbar').each(function(){
|
||||||
|
var
|
||||||
|
navbar = $(this),
|
||||||
|
nav = $('ul.nav', navbar),
|
||||||
|
collapseMode = navbar.hasClass('navbar-mode-collapse'),
|
||||||
|
isMobile = $('html').hasClass('mobile')
|
||||||
|
|
||||||
|
nav.verticalMenu($('a.menu-toggle', navbar), {
|
||||||
|
breakpoint: collapseMode ? Infinity : 769
|
||||||
|
})
|
||||||
|
|
||||||
|
$('li.with-tooltip:not(.active) > a', navbar).tooltip({
|
||||||
|
container: 'body',
|
||||||
|
placement: 'bottom',
|
||||||
|
template: '<div class="tooltip mainmenu-tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>'
|
||||||
|
})
|
||||||
|
.on('show.bs.tooltip', function (e) {
|
||||||
|
if (isMobile) e.preventDefault()
|
||||||
|
})
|
||||||
|
|
||||||
|
// Scroll to the currently active nav item.
|
||||||
|
var dragScroll = $('[data-control=toolbar]', navbar).data('oc.dragScroll')
|
||||||
|
if (dragScroll) {
|
||||||
|
dragScroll.goToElement($('ul.nav > li.active', navbar), undefined, {'duration': 0})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})(jQuery);
|
||||||
|
|
@ -0,0 +1,409 @@
|
||||||
|
/*
|
||||||
|
* Creates a scrollbar in a container.
|
||||||
|
*
|
||||||
|
* Note the element must have a height set for vertical,
|
||||||
|
* and a width set for horizontal.
|
||||||
|
*
|
||||||
|
* Data attributes:
|
||||||
|
* - data-control="scrollbar" - enables the scrollbar plugin
|
||||||
|
*
|
||||||
|
* JavaScript API:
|
||||||
|
* $('#area').scrollbar()
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - Mouse Wheel plugin (mousewheel.js)
|
||||||
|
*/
|
||||||
|
+function ($) { "use strict";
|
||||||
|
var Base = $.oc.foundation.base,
|
||||||
|
BaseProto = Base.prototype
|
||||||
|
|
||||||
|
var Scrollbar = function (element, options) {
|
||||||
|
|
||||||
|
var
|
||||||
|
$el = this.$el = $(element),
|
||||||
|
el = $el.get(0),
|
||||||
|
self = this,
|
||||||
|
options = this.options = options || {},
|
||||||
|
sizeName = this.sizeName = options.vertical ? 'height' : 'width',
|
||||||
|
isNative = $('html').hasClass('mobile'),
|
||||||
|
isTouch = this.isTouch = Modernizr.touchevents,
|
||||||
|
isScrollable = this.isScrollable = false,
|
||||||
|
isLocked = this.isLocked = false,
|
||||||
|
eventElementName = options.vertical ? 'pageY' : 'pageX',
|
||||||
|
dragStart = 0,
|
||||||
|
startOffset = 0;
|
||||||
|
|
||||||
|
$.oc.foundation.controlUtils.markDisposable(element)
|
||||||
|
|
||||||
|
Base.call(this)
|
||||||
|
|
||||||
|
this.$el.one('dispose-control', this.proxy(this.dispose))
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Native (mobile) environments use overflow auto in CSS
|
||||||
|
*/
|
||||||
|
if (isNative) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Create Scrollbar
|
||||||
|
*/
|
||||||
|
this.$scrollbar = $('<div />').addClass('scrollbar-scrollbar')
|
||||||
|
this.$track = $('<div />').addClass('scrollbar-track').appendTo(this.$scrollbar)
|
||||||
|
this.$thumb = $('<div />').addClass('scrollbar-thumb').appendTo(this.$track)
|
||||||
|
|
||||||
|
$el
|
||||||
|
.addClass('drag-scrollbar')
|
||||||
|
.addClass(options.vertical ? 'vertical' : 'horizontal')
|
||||||
|
.prepend(this.$scrollbar)
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Bind events
|
||||||
|
*/
|
||||||
|
if (isTouch) {
|
||||||
|
this.$el.on('touchstart', function (event){
|
||||||
|
var touchEvent = event.originalEvent;
|
||||||
|
if (touchEvent.touches.length == 1) {
|
||||||
|
startDrag(touchEvent.touches[0])
|
||||||
|
event.stopPropagation()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
this.$thumb.on('mousedown', function (event){
|
||||||
|
startDrag(event)
|
||||||
|
})
|
||||||
|
this.$track.on('mouseup', function (event){
|
||||||
|
moveDrag(event)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
$el.mousewheel(function (event){
|
||||||
|
var offset = self.options.vertical
|
||||||
|
? ((event.deltaFactor * event.deltaY) * -1)
|
||||||
|
: (event.deltaFactor * event.deltaX)
|
||||||
|
|
||||||
|
return !scrollWheel(offset * self.options.scrollSpeed)
|
||||||
|
})
|
||||||
|
|
||||||
|
$el.on('oc.scrollbar.gotoStart', function(event){
|
||||||
|
self.options.vertical
|
||||||
|
? $el.scrollTop(0)
|
||||||
|
: $el.scrollLeft(0)
|
||||||
|
|
||||||
|
self.update()
|
||||||
|
event.stopPropagation()
|
||||||
|
})
|
||||||
|
|
||||||
|
$(window).on('resize', $.proxy(this.update, this))
|
||||||
|
$(window).on('oc.updateUi', $.proxy(this.update, this))
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Internal event, drag has started
|
||||||
|
*/
|
||||||
|
function startDrag(event) {
|
||||||
|
$('body').addClass('drag-noselect')
|
||||||
|
$el.trigger('oc.scrollStart')
|
||||||
|
|
||||||
|
dragStart = event[eventElementName]
|
||||||
|
startOffset = self.options.vertical ? $el.scrollTop() : $el.scrollLeft()
|
||||||
|
|
||||||
|
if (isTouch) {
|
||||||
|
$(window).on('touchmove.scrollbar', function(event) {
|
||||||
|
var touchEvent = event.originalEvent
|
||||||
|
if (moveDrag(touchEvent.touches[0]))
|
||||||
|
event.preventDefault();
|
||||||
|
});
|
||||||
|
|
||||||
|
$el.on('touchend.scrollbar', stopDrag)
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$(window).on('mousemove.scrollbar', function(event){
|
||||||
|
moveDrag(event)
|
||||||
|
return false
|
||||||
|
})
|
||||||
|
|
||||||
|
$(window).on('mouseup.scrollbar', function(){
|
||||||
|
stopDrag()
|
||||||
|
return false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Internal event, drag is active
|
||||||
|
*/
|
||||||
|
function moveDrag(event) {
|
||||||
|
self.isLocked = true;
|
||||||
|
|
||||||
|
var
|
||||||
|
offset,
|
||||||
|
dragTo = event[eventElementName]
|
||||||
|
|
||||||
|
// Touch devices use an inverse scrolling interface
|
||||||
|
// with a 1:1 ratio
|
||||||
|
if (self.isTouch) {
|
||||||
|
offset = dragStart - dragTo
|
||||||
|
}
|
||||||
|
// Mouse devices use a natural scrolling interface
|
||||||
|
// with a track:canvas ratio
|
||||||
|
else {
|
||||||
|
var ratio = self.getCanvasSize() / self.getViewportSize()
|
||||||
|
offset = (dragTo - dragStart) * ratio
|
||||||
|
}
|
||||||
|
|
||||||
|
self.options.vertical
|
||||||
|
? $el.scrollTop(startOffset + offset)
|
||||||
|
: $el.scrollLeft(startOffset + offset)
|
||||||
|
|
||||||
|
self.setThumbPosition()
|
||||||
|
|
||||||
|
return self.options.vertical
|
||||||
|
? el.scrollTop != startOffset
|
||||||
|
: el.scrollLeft != startOffset
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Internal event, drag has ended
|
||||||
|
*/
|
||||||
|
function stopDrag() {
|
||||||
|
$('body').removeClass('drag-noselect')
|
||||||
|
$el.trigger('oc.scrollEnd')
|
||||||
|
|
||||||
|
$(window).off('.scrollbar')
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Scroll wheel has moved by supplied offset
|
||||||
|
*/
|
||||||
|
|
||||||
|
var isWebkit = $(document.documentElement).hasClass('webkit')
|
||||||
|
|
||||||
|
function scrollWheel(offset) {
|
||||||
|
startOffset = self.options.vertical ? el.scrollTop : el.scrollLeft
|
||||||
|
$el.trigger('oc.scrollStart')
|
||||||
|
|
||||||
|
self.options.vertical
|
||||||
|
? $el.scrollTop(startOffset + offset)
|
||||||
|
: $el.scrollLeft(startOffset + offset)
|
||||||
|
|
||||||
|
var scrolled = self.options.vertical
|
||||||
|
? el.scrollTop != startOffset
|
||||||
|
: el.scrollLeft != startOffset
|
||||||
|
|
||||||
|
self.setThumbPosition()
|
||||||
|
if (!isWebkit) {
|
||||||
|
if (self.endScrollTimeout !== undefined) {
|
||||||
|
clearTimeout(self.endScrollTimeout)
|
||||||
|
self.endScrollTimeout = undefined
|
||||||
|
}
|
||||||
|
|
||||||
|
self.endScrollTimeout = setTimeout(function() {
|
||||||
|
$el.trigger('oc.scrollEnd')
|
||||||
|
self.endScrollTimeout = undefined
|
||||||
|
}, 50)
|
||||||
|
} else {
|
||||||
|
$el.trigger('oc.scrollEnd')
|
||||||
|
}
|
||||||
|
|
||||||
|
return scrolled
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Give the DOM a second, then set the track and thumb size
|
||||||
|
*/
|
||||||
|
setTimeout(function() { self.update() }, 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype = Object.create(BaseProto)
|
||||||
|
Scrollbar.prototype.constructor = Scrollbar
|
||||||
|
|
||||||
|
Scrollbar.prototype.dispose = function() {
|
||||||
|
this.unregisterHandlers()
|
||||||
|
|
||||||
|
BaseProto.dispose.call(this)
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype.unregisterHandlers = function() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.DEFAULTS = {
|
||||||
|
vertical: true,
|
||||||
|
scrollSpeed: 2,
|
||||||
|
animation: true,
|
||||||
|
start: function() {},
|
||||||
|
drag: function() {},
|
||||||
|
stop: function() {}
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype.update = function() {
|
||||||
|
if (!this.$scrollbar)
|
||||||
|
return
|
||||||
|
|
||||||
|
this.$scrollbar.hide()
|
||||||
|
this.setThumbSize()
|
||||||
|
this.setThumbPosition()
|
||||||
|
this.$scrollbar.show()
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype.setThumbSize = function() {
|
||||||
|
var properties = this.calculateProperties()
|
||||||
|
|
||||||
|
this.isScrollable = !(properties.thumbSizeRatio >= 1);
|
||||||
|
this.$scrollbar.toggleClass('disabled', !this.isScrollable)
|
||||||
|
|
||||||
|
if (this.options.vertical) {
|
||||||
|
this.$track.height(properties.canvasSize)
|
||||||
|
this.$thumb.height(properties.thumbSize)
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
this.$track.width(properties.canvasSize)
|
||||||
|
this.$thumb.width(properties.thumbSize)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype.setThumbPosition = function() {
|
||||||
|
var properties = this.calculateProperties()
|
||||||
|
|
||||||
|
if (this.options.vertical)
|
||||||
|
this.$thumb.css({top: properties.thumbPosition})
|
||||||
|
else
|
||||||
|
this.$thumb.css({left: properties.thumbPosition})
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype.calculateProperties = function() {
|
||||||
|
|
||||||
|
var $el = this.$el,
|
||||||
|
properties = {};
|
||||||
|
|
||||||
|
properties.viewportSize = this.getViewportSize()
|
||||||
|
properties.canvasSize = this.getCanvasSize()
|
||||||
|
properties.scrollAmount = (this.options.vertical) ? $el.scrollTop() : $el.scrollLeft()
|
||||||
|
|
||||||
|
properties.thumbSizeRatio = properties.viewportSize / properties.canvasSize
|
||||||
|
properties.thumbSize = properties.viewportSize * properties.thumbSizeRatio
|
||||||
|
|
||||||
|
properties.thumbPositionRatio = properties.scrollAmount / (properties.canvasSize - properties.viewportSize)
|
||||||
|
properties.thumbPosition = ((properties.viewportSize - properties.thumbSize) * properties.thumbPositionRatio) + properties.scrollAmount
|
||||||
|
|
||||||
|
if (isNaN(properties.thumbPosition))
|
||||||
|
properties.thumbPosition = 0
|
||||||
|
|
||||||
|
return properties;
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype.getViewportSize = function() {
|
||||||
|
return (this.options.vertical)
|
||||||
|
? this.$el.height()
|
||||||
|
: this.$el.width();
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype.getCanvasSize = function() {
|
||||||
|
return (this.options.vertical)
|
||||||
|
? this.$el.get(0).scrollHeight
|
||||||
|
: this.$el.get(0).scrollWidth;
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype.gotoElement = function(element, callback) {
|
||||||
|
var $el = $(element)
|
||||||
|
if (!$el.length)
|
||||||
|
return;
|
||||||
|
|
||||||
|
var self = this,
|
||||||
|
offset = 0,
|
||||||
|
animated = false,
|
||||||
|
params = {
|
||||||
|
duration: 300,
|
||||||
|
queue: false,
|
||||||
|
complete: function(){
|
||||||
|
if (callback !== undefined)
|
||||||
|
callback()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!this.options.vertical) {
|
||||||
|
offset = $el.get(0).offsetLeft - this.$el.scrollLeft()
|
||||||
|
|
||||||
|
if (offset < 0) {
|
||||||
|
this.$el.animate({'scrollLeft': $el.get(0).offsetLeft}, params)
|
||||||
|
animated = true
|
||||||
|
} else {
|
||||||
|
offset = $el.get(0).offsetLeft + $el.outerWidth() - (this.$el.scrollLeft() + this.$el.outerWidth())
|
||||||
|
if (offset > 0) {
|
||||||
|
this.$el.animate({'scrollLeft': $el.get(0).offsetLeft + $el.outerWidth() - this.$el.outerWidth()}, params)
|
||||||
|
animated = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
offset = $el.get(0).offsetTop - this.$el.scrollTop()
|
||||||
|
|
||||||
|
if (this.options.animation) {
|
||||||
|
if (offset < 0) {
|
||||||
|
this.$el.animate({'scrollTop': $el.get(0).offsetTop}, params)
|
||||||
|
animated = true
|
||||||
|
} else {
|
||||||
|
offset = $el.get(0).offsetTop - (this.$el.scrollTop() + this.$el.outerHeight())
|
||||||
|
if (offset > 0) {
|
||||||
|
this.$el.animate({'scrollTop': $el.get(0).offsetTop + $el.outerHeight() - this.$el.outerHeight()}, params)
|
||||||
|
animated = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (offset < 0) {
|
||||||
|
this.$el.scrollTop($el.get(0).offsetTop)
|
||||||
|
} else {
|
||||||
|
offset = $el.get(0).offsetTop - (this.$el.scrollTop() + this.$el.outerHeight())
|
||||||
|
if (offset > 0)
|
||||||
|
this.$el.scrollTop($el.get(0).offsetTop + $el.outerHeight() - this.$el.outerHeight())
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!animated && callback !== undefined)
|
||||||
|
callback()
|
||||||
|
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollbar.prototype.dispose = function() {
|
||||||
|
this.$el = null
|
||||||
|
this.$scrollbar = null
|
||||||
|
this.$track = null
|
||||||
|
this.$thumb = null
|
||||||
|
}
|
||||||
|
|
||||||
|
// SCROLLBAR PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.scrollbar
|
||||||
|
|
||||||
|
$.fn.scrollbar = function (option) {
|
||||||
|
return this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.scrollbar')
|
||||||
|
var options = $.extend({}, Scrollbar.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
|
||||||
|
if (!data) $this.data('oc.scrollbar', (data = new Scrollbar(this, options)))
|
||||||
|
if (typeof option == 'string') data[option].call($this)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.scrollbar.Constructor = Scrollbar
|
||||||
|
|
||||||
|
// SCROLLBAR NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.scrollbar.noConflict = function () {
|
||||||
|
$.fn.scrollbar = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// SCROLLBAR DATA-API
|
||||||
|
// ===============
|
||||||
|
$(document).render(function(){
|
||||||
|
$('[data-control=scrollbar]').scrollbar()
|
||||||
|
})
|
||||||
|
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,310 @@
|
||||||
|
/*
|
||||||
|
* ScrollPad plugin.
|
||||||
|
*
|
||||||
|
* This plugin creates a scrollable area with features similar (but more limited)
|
||||||
|
* to october.scrollbar.js, with virtual scroll bars. This plugin is more lightweight
|
||||||
|
* in terms of calculations and more responsive. It doesn't use scripting for scrolling,
|
||||||
|
* instead it uses the native scrolling and listens for the onscroll event to update
|
||||||
|
* the virtual scroll bars.
|
||||||
|
*
|
||||||
|
* The plugin is partially based on Trackpad Scroll Emulator
|
||||||
|
* https://github.com/jnicol/trackpad-scroll-emulator, cleaned up for the better CPU and
|
||||||
|
* memory (DOM references) management.
|
||||||
|
*
|
||||||
|
* Expected markup:
|
||||||
|
* <div class="control-scrollpad" data-control="scrollpad" data-direction="vertical">
|
||||||
|
* <div>
|
||||||
|
* <div>
|
||||||
|
* The content goes here. The two wrapping
|
||||||
|
* DIV elements are required.
|
||||||
|
* </div>
|
||||||
|
* </div>
|
||||||
|
* </div>
|
||||||
|
*
|
||||||
|
* Data attributes:
|
||||||
|
* - data-control="scrollpad" - enables the plugin.
|
||||||
|
* - data-direction="vertical|horizontal" - sets the scrolling direction.
|
||||||
|
*
|
||||||
|
* JavaScript API:
|
||||||
|
* $('#area').scrollpad({direction: 'vertical'})
|
||||||
|
* $('#area').scrollpad('dispose')
|
||||||
|
* $('#area').scrollpad('scrollToStart')
|
||||||
|
*
|
||||||
|
* TODO: In FireFox the control in the horizontal mode displays the native scrollbars,
|
||||||
|
* because negative margin-bottom in the scrollable element doesn't work for some reason.
|
||||||
|
* Try to align the scrollable element with absolute positioning (negative right and bottom)
|
||||||
|
* instead of negative margins.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
+function ($) { "use strict";
|
||||||
|
|
||||||
|
var Base = $.oc.foundation.base,
|
||||||
|
BaseProto = Base.prototype
|
||||||
|
|
||||||
|
// SCROLLPAD CLASS DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var Scrollpad = function(element, options) {
|
||||||
|
this.$el = $(element)
|
||||||
|
this.scrollbarElement = null
|
||||||
|
this.dragHandleElement = null
|
||||||
|
this.scrollContentElement = null
|
||||||
|
this.contentElement = null
|
||||||
|
this.options = options
|
||||||
|
this.scrollbarSize = null
|
||||||
|
this.updateScrollbarTimer = null
|
||||||
|
this.dragOffset = null
|
||||||
|
|
||||||
|
Base.call(this)
|
||||||
|
|
||||||
|
//
|
||||||
|
// Initialization
|
||||||
|
//
|
||||||
|
|
||||||
|
this.init()
|
||||||
|
|
||||||
|
$.oc.foundation.controlUtils.markDisposable(element)
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype = Object.create(BaseProto)
|
||||||
|
Scrollpad.prototype.constructor = Scrollpad
|
||||||
|
|
||||||
|
Scrollpad.prototype.dispose = function() {
|
||||||
|
this.unregisterHandlers()
|
||||||
|
|
||||||
|
this.$el.get(0).removeChild(this.scrollbarElement)
|
||||||
|
this.$el.removeData('oc.scrollpad')
|
||||||
|
this.$el = null
|
||||||
|
|
||||||
|
this.scrollbarElement = null
|
||||||
|
this.dragHandleElement = null
|
||||||
|
this.scrollContentElement = null
|
||||||
|
this.contentElement = null
|
||||||
|
|
||||||
|
BaseProto.dispose.call(this)
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.scrollToStart = function() {
|
||||||
|
var scrollAttr = this.options.direction == 'vertical' ? 'scrollTop' : 'scrollLeft'
|
||||||
|
this.scrollContentElement[scrollAttr] = 0
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.update = function() {
|
||||||
|
this.updateScrollbarSize()
|
||||||
|
}
|
||||||
|
|
||||||
|
// SCROLLPAD INTERNAL METHODS
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
Scrollpad.prototype.init = function() {
|
||||||
|
this.build()
|
||||||
|
this.setScrollContentSize()
|
||||||
|
this.registerHandlers()
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.build = function() {
|
||||||
|
var el = this.$el.get(0)
|
||||||
|
|
||||||
|
this.scrollContentElement = el.children[0]
|
||||||
|
this.contentElement = this.scrollContentElement.children[0]
|
||||||
|
this.$el.prepend('<div class="scrollpad-scrollbar"><div class="drag-handle"></div></div>')
|
||||||
|
this.scrollbarElement = el.querySelector('.scrollpad-scrollbar')
|
||||||
|
this.dragHandleElement = el.querySelector('.scrollpad-scrollbar > .drag-handle')
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.registerHandlers = function() {
|
||||||
|
this.$el.on('mouseenter', this.proxy(this.onMouseEnter))
|
||||||
|
this.$el.on('mouseleave', this.proxy(this.onMouseLeave))
|
||||||
|
|
||||||
|
this.$el.one('dispose-control', this.proxy(this.dispose))
|
||||||
|
|
||||||
|
this.scrollContentElement.addEventListener('scroll', this.proxy(this.onScroll))
|
||||||
|
this.dragHandleElement.addEventListener('mousedown', this.proxy(this.onStartDrag))
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.unregisterHandlers = function() {
|
||||||
|
this.$el.off('mouseenter', this.proxy(this.onMouseEnter))
|
||||||
|
this.$el.off('mouseleave', this.proxy(this.onMouseLeave))
|
||||||
|
this.$el.off('dispose-control', this.proxy(this.dispose))
|
||||||
|
this.scrollContentElement.removeEventListener('scroll', this.proxy(this.onScroll))
|
||||||
|
this.dragHandleElement.removeEventListener('mousedown', this.proxy(this.onStartDrag))
|
||||||
|
|
||||||
|
document.removeEventListener('mousemove', this.proxy(this.onMouseMove))
|
||||||
|
document.removeEventListener('mouseup', this.proxy(this.onEndDrag))
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.setScrollContentSize = function() {
|
||||||
|
var scrollbarSize = this.getScrollbarSize()
|
||||||
|
|
||||||
|
if (this.options.direction == 'vertical')
|
||||||
|
this.scrollContentElement.setAttribute('style', 'margin-right: -' + scrollbarSize + 'px')
|
||||||
|
else
|
||||||
|
this.scrollContentElement.setAttribute('style', 'margin-bottom: -' + scrollbarSize + 'px')
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.getScrollbarSize = function() {
|
||||||
|
if (this.scrollbarSize !== null)
|
||||||
|
return this.scrollbarSize
|
||||||
|
|
||||||
|
var testerElement = document.createElement('div')
|
||||||
|
testerElement.setAttribute('class', 'scrollpad-scrollbar-size-tester')
|
||||||
|
testerElement.appendChild(document.createElement('div'))
|
||||||
|
|
||||||
|
document.body.appendChild(testerElement)
|
||||||
|
|
||||||
|
var width = testerElement.offsetWidth,
|
||||||
|
innerWidth = testerElement.querySelector('div').offsetWidth
|
||||||
|
|
||||||
|
document.body.removeChild(testerElement)
|
||||||
|
|
||||||
|
// Some magic for FireFox, see
|
||||||
|
// https://github.com/jnicol/trackpad-scroll-emulator/blob/master/jquery.trackpad-scroll-emulator.js
|
||||||
|
if (width === innerWidth && navigator.userAgent.toLowerCase().indexOf('firefox') > -1)
|
||||||
|
return this.scrollbarSize = 17
|
||||||
|
|
||||||
|
return this.scrollbarSize = width - innerWidth
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.updateScrollbarSize = function() {
|
||||||
|
this.scrollbarElement.removeAttribute('data-hidden')
|
||||||
|
|
||||||
|
var contentSize = this.options.direction == 'vertical' ? this.contentElement.scrollHeight : this.contentElement.scrollWidth,
|
||||||
|
scrollOffset = this.options.direction == 'vertical' ? this.scrollContentElement.scrollTop : this.scrollContentElement.scrollLeft,
|
||||||
|
scrollbarSize = this.options.direction == 'vertical' ? this.scrollbarElement.offsetHeight : this.scrollbarElement.offsetWidth,
|
||||||
|
scrollbarRatio = scrollbarSize / contentSize,
|
||||||
|
handleOffset = Math.round(scrollbarRatio * scrollOffset) + 2,
|
||||||
|
handleSize = Math.floor(scrollbarRatio * (scrollbarSize - 2)) - 2;
|
||||||
|
|
||||||
|
if (scrollbarSize < contentSize) {
|
||||||
|
if (this.options.direction == 'vertical')
|
||||||
|
this.dragHandleElement.setAttribute('style', 'top: ' + handleOffset + 'px; height: ' + handleSize + 'px')
|
||||||
|
else
|
||||||
|
this.dragHandleElement.setAttribute('style', 'left: ' + handleOffset + 'px; width: ' + handleSize + 'px')
|
||||||
|
|
||||||
|
this.scrollbarElement.removeAttribute('data-hidden')
|
||||||
|
}
|
||||||
|
else
|
||||||
|
this.scrollbarElement.setAttribute('data-hidden', true)
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.displayScrollbar = function() {
|
||||||
|
this.clearUpdateScrollbarTimer()
|
||||||
|
|
||||||
|
this.updateScrollbarSize()
|
||||||
|
this.scrollbarElement.setAttribute('data-visible', 'true')
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.hideScrollbar = function() {
|
||||||
|
this.scrollbarElement.removeAttribute('data-visible')
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.clearUpdateScrollbarTimer = function() {
|
||||||
|
if (this.updateScrollbarTimer === null)
|
||||||
|
return
|
||||||
|
|
||||||
|
clearTimeout(this.updateScrollbarTimer)
|
||||||
|
this.updateScrollbarTimer = null
|
||||||
|
}
|
||||||
|
|
||||||
|
// EVENT HANDLERS
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
Scrollpad.prototype.onMouseEnter = function() {
|
||||||
|
this.displayScrollbar()
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.onMouseLeave = function() {
|
||||||
|
this.hideScrollbar()
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.onScroll = function() {
|
||||||
|
if (this.updateScrollbarTimer !== null)
|
||||||
|
return
|
||||||
|
|
||||||
|
this.updateScrollbarTimer = setTimeout(this.proxy(this.displayScrollbar), 10)
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.onStartDrag = function(ev) {
|
||||||
|
$.oc.foundation.event.stop(ev)
|
||||||
|
|
||||||
|
var pageCoords = $.oc.foundation.event.pageCoordinates(ev),
|
||||||
|
eventOffset = this.options.direction == 'vertical' ? pageCoords.y : pageCoords.x,
|
||||||
|
handleCoords = $.oc.foundation.element.absolutePosition(this.dragHandleElement),
|
||||||
|
handleOffset = this.options.direction == 'vertical' ? handleCoords.top : handleCoords.left
|
||||||
|
|
||||||
|
this.dragOffset = eventOffset - handleOffset
|
||||||
|
|
||||||
|
document.addEventListener('mousemove', this.proxy(this.onMouseMove))
|
||||||
|
document.addEventListener('mouseup', this.proxy(this.onEndDrag))
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.onMouseMove = function(ev) {
|
||||||
|
$.oc.foundation.event.stop(ev)
|
||||||
|
|
||||||
|
var eventCoordsAttr = this.options.direction == 'vertical' ? 'y' : 'x',
|
||||||
|
elementCoordsAttr = this.options.direction == 'vertical' ? 'top' : 'left',
|
||||||
|
offsetAttr = this.options.direction == 'vertical' ? 'offsetHeight' : 'offsetWidth',
|
||||||
|
scrollAttr = this.options.direction == 'vertical' ? 'scrollTop' : 'scrollLeft'
|
||||||
|
|
||||||
|
var eventOffset = $.oc.foundation.event.pageCoordinates(ev)[eventCoordsAttr],
|
||||||
|
scrollbarOffset = $.oc.foundation.element.absolutePosition(this.scrollbarElement)[elementCoordsAttr],
|
||||||
|
dragPos = eventOffset - scrollbarOffset - this.dragOffset,
|
||||||
|
scrollbarSize = this.scrollbarElement[offsetAttr],
|
||||||
|
contentSize = this.contentElement[offsetAttr],
|
||||||
|
dragPerc = dragPos / scrollbarSize
|
||||||
|
|
||||||
|
if (dragPerc > 1)
|
||||||
|
dragPerc = 1
|
||||||
|
|
||||||
|
var scrollPos = dragPerc * contentSize;
|
||||||
|
|
||||||
|
this.scrollContentElement[scrollAttr] = scrollPos
|
||||||
|
}
|
||||||
|
|
||||||
|
Scrollpad.prototype.onEndDrag = function(ev) {
|
||||||
|
document.removeEventListener('mousemove', this.proxy(this.onMouseMove))
|
||||||
|
document.removeEventListener('mouseup', this.proxy(this.onEndDrag))
|
||||||
|
}
|
||||||
|
|
||||||
|
// SCROLLPAD PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
Scrollpad.DEFAULTS = {
|
||||||
|
direction: 'vertical'
|
||||||
|
}
|
||||||
|
|
||||||
|
var old = $.fn.scrollpad
|
||||||
|
|
||||||
|
$.fn.scrollpad = function (option) {
|
||||||
|
var args = Array.prototype.slice.call(arguments, 1),
|
||||||
|
result = undefined
|
||||||
|
|
||||||
|
this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.scrollpad')
|
||||||
|
var options = $.extend({}, Scrollpad.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
if (!data) $this.data('oc.scrollpad', (data = new Scrollpad(this, options)))
|
||||||
|
if (typeof option == 'string') result = data[option].apply(data, args)
|
||||||
|
if (typeof result != 'undefined') return false
|
||||||
|
})
|
||||||
|
|
||||||
|
return result ? result : this
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.scrollpad.Constructor = Scrollpad
|
||||||
|
|
||||||
|
// SCROLLPAD NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.scrollpad.noConflict = function () {
|
||||||
|
$.fn.scrollpad = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// SCROLLPAD DATA-API
|
||||||
|
// ===============
|
||||||
|
|
||||||
|
$(document).on('render', function(){
|
||||||
|
$('div[data-control=scrollpad]').scrollpad()
|
||||||
|
})
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,268 @@
|
||||||
|
/*
|
||||||
|
* Side navigation tree
|
||||||
|
*
|
||||||
|
* Data attributes:
|
||||||
|
* - data-control="sidenav-tree" - enables the plugin
|
||||||
|
* - data-tree-name - unique name of the tree control. The name is used for storing user configuration in the browser cookies.
|
||||||
|
*
|
||||||
|
* JavaScript API:
|
||||||
|
* $('#tree').sidenavTree()
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - Null
|
||||||
|
*/
|
||||||
|
|
||||||
|
+function ($) { "use strict";
|
||||||
|
|
||||||
|
// SIDENAVTREE CLASS DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var SidenavTree = function(element, options) {
|
||||||
|
this.options = options
|
||||||
|
this.$el = $(element)
|
||||||
|
|
||||||
|
this.init()
|
||||||
|
}
|
||||||
|
|
||||||
|
SidenavTree.DEFAULTS = {
|
||||||
|
treeName: 'sidenav_tree'
|
||||||
|
}
|
||||||
|
|
||||||
|
SidenavTree.prototype.init = function (){
|
||||||
|
var self = this
|
||||||
|
|
||||||
|
$(document.body).addClass('has-sidenav-tree')
|
||||||
|
|
||||||
|
this.statusCookieName = this.options.treeName + 'groupStatus'
|
||||||
|
this.searchCookieName = this.options.treeName + 'search'
|
||||||
|
this.$searchInput = $(this.options.searchInput)
|
||||||
|
|
||||||
|
this.$el.on('click', 'li > div.group', function() {
|
||||||
|
self.toggleGroup($(this).closest('li'))
|
||||||
|
return false
|
||||||
|
})
|
||||||
|
|
||||||
|
this.$searchInput.on('input', function(){
|
||||||
|
self.handleSearchChange()
|
||||||
|
})
|
||||||
|
|
||||||
|
var searchTerm = $.cookie(this.searchCookieName)
|
||||||
|
if (searchTerm !== undefined && searchTerm.length > 0) {
|
||||||
|
this.$searchInput.val(searchTerm)
|
||||||
|
this.applySearch()
|
||||||
|
}
|
||||||
|
|
||||||
|
var scrollbar = $('[data-control=scrollbar]', this.$el).data('oc.scrollbar'),
|
||||||
|
active = $('li.active', this.$el)
|
||||||
|
|
||||||
|
if (active.length > 0) {
|
||||||
|
scrollbar.gotoElement(active)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
SidenavTree.prototype.toggleGroup = function(group) {
|
||||||
|
var $group = $(group),
|
||||||
|
status = $group.attr('data-status')
|
||||||
|
|
||||||
|
status === undefined || status == 'expanded'
|
||||||
|
? this.collapseGroup($group)
|
||||||
|
: this.expandGroup($group)
|
||||||
|
}
|
||||||
|
|
||||||
|
SidenavTree.prototype.collapseGroup = function(group) {
|
||||||
|
var
|
||||||
|
$list = $('> ul', group),
|
||||||
|
self = this
|
||||||
|
|
||||||
|
$list.css('overflow', 'hidden')
|
||||||
|
$list.animate({ 'height': 0 }, {
|
||||||
|
duration: 100,
|
||||||
|
queue: false,
|
||||||
|
complete: function() {
|
||||||
|
$list.css({
|
||||||
|
'overflow': 'visible',
|
||||||
|
'display': 'none'
|
||||||
|
})
|
||||||
|
|
||||||
|
$(group).attr('data-status', 'collapsed')
|
||||||
|
$(window).trigger('oc.updateUi')
|
||||||
|
self.saveGroupStatus($(group).data('group-code'), true)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
SidenavTree.prototype.expandGroup = function(group, duration) {
|
||||||
|
var
|
||||||
|
$list = $('> ul', group),
|
||||||
|
self = this
|
||||||
|
|
||||||
|
duration = duration === undefined ? 100 : duration
|
||||||
|
|
||||||
|
$list.css({
|
||||||
|
'overflow': 'hidden',
|
||||||
|
'height': 0
|
||||||
|
})
|
||||||
|
$list.animate({'height': $list[0].scrollHeight}, { duration: duration, queue: false, complete: function() {
|
||||||
|
$list.css({
|
||||||
|
'overflow': 'visible',
|
||||||
|
'height': 'auto',
|
||||||
|
'display': ''
|
||||||
|
})
|
||||||
|
$(group).attr('data-status', 'expanded')
|
||||||
|
$(window).trigger('oc.updateUi')
|
||||||
|
self.saveGroupStatus($(group).data('group-code'), false)
|
||||||
|
} })
|
||||||
|
}
|
||||||
|
|
||||||
|
SidenavTree.prototype.saveGroupStatus = function(groupCode, collapsed) {
|
||||||
|
var collapsedGroups = $.cookie(this.statusCookieName),
|
||||||
|
updatedGroups = []
|
||||||
|
|
||||||
|
if (collapsedGroups === undefined) {
|
||||||
|
collapsedGroups = ''
|
||||||
|
}
|
||||||
|
|
||||||
|
collapsedGroups = collapsedGroups.split('|')
|
||||||
|
$.each(collapsedGroups, function() {
|
||||||
|
if (groupCode != this)
|
||||||
|
updatedGroups.push(this)
|
||||||
|
})
|
||||||
|
|
||||||
|
if (collapsed) {
|
||||||
|
updatedGroups.push(groupCode)
|
||||||
|
}
|
||||||
|
|
||||||
|
$.cookie(this.statusCookieName, updatedGroups.join('|'), { expires: 30, path: '/' })
|
||||||
|
}
|
||||||
|
|
||||||
|
SidenavTree.prototype.handleSearchChange = function() {
|
||||||
|
var lastValue = this.$searchInput.data('oc.lastvalue');
|
||||||
|
|
||||||
|
if (lastValue !== undefined && lastValue == this.$searchInput.val()) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$searchInput.data('oc.lastvalue', this.$searchInput.val())
|
||||||
|
|
||||||
|
if (this.dataTrackInputTimer !== undefined) {
|
||||||
|
window.clearTimeout(this.dataTrackInputTimer)
|
||||||
|
}
|
||||||
|
|
||||||
|
var self = this
|
||||||
|
this.dataTrackInputTimer = window.setTimeout(function(){
|
||||||
|
self.applySearch()
|
||||||
|
}, 300);
|
||||||
|
|
||||||
|
$.cookie(this.searchCookieName, $.trim(this.$searchInput.val()), { expires: 30, path: '/' })
|
||||||
|
}
|
||||||
|
|
||||||
|
SidenavTree.prototype.applySearch = function() {
|
||||||
|
var query = $.trim(this.$searchInput.val()),
|
||||||
|
words = query.toLowerCase().split(' '),
|
||||||
|
visibleGroups = [],
|
||||||
|
visibleItems = [],
|
||||||
|
self = this
|
||||||
|
|
||||||
|
if (query.length == 0) {
|
||||||
|
$('li', this.$el).removeClass('hidden')
|
||||||
|
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Find visible groups and items
|
||||||
|
*/
|
||||||
|
$('ul.top-level > li', this.$el).each(function() {
|
||||||
|
var $li = $(this)
|
||||||
|
|
||||||
|
if (self.textContainsWords($('div.group h3', $li).text(), words)) {
|
||||||
|
visibleGroups.push($li.get(0))
|
||||||
|
|
||||||
|
$('ul li', $li).each(function(){
|
||||||
|
visibleItems.push(this)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$('ul li', $li).each(function(){
|
||||||
|
if (self.textContainsWords($(this).text(), words) || self.textContainsWords($(this).data('keywords'), words)) {
|
||||||
|
visibleGroups.push($li.get(0))
|
||||||
|
visibleItems.push(this)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Hide invisible groups and items
|
||||||
|
*/
|
||||||
|
$('ul.top-level > li', this.$el).each(function() {
|
||||||
|
var $li = $(this),
|
||||||
|
groupIsVisible = $.inArray(this, visibleGroups) !== -1
|
||||||
|
|
||||||
|
$li.toggleClass('hidden', !groupIsVisible)
|
||||||
|
if (groupIsVisible)
|
||||||
|
self.expandGroup($li, 0)
|
||||||
|
|
||||||
|
$('ul li', $li).each(function(){
|
||||||
|
var $itemLi = $(this)
|
||||||
|
|
||||||
|
$itemLi.toggleClass('hidden', $.inArray(this, visibleItems) == -1)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
SidenavTree.prototype.textContainsWords = function(text, words) {
|
||||||
|
text = text.toLowerCase()
|
||||||
|
|
||||||
|
for (var i = 0; i < words.length; i++) {
|
||||||
|
if (text.indexOf(words[i]) === -1)
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIDENAVTREE PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.sidenavTree
|
||||||
|
|
||||||
|
$.fn.sidenavTree = function (option) {
|
||||||
|
var args = arguments;
|
||||||
|
|
||||||
|
return this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.sidenavTree')
|
||||||
|
var options = $.extend({}, SidenavTree.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
|
||||||
|
if (!data) $this.data('oc.sidenavTree', (data = new SidenavTree(this, options)))
|
||||||
|
if (typeof option == 'string') {
|
||||||
|
var methodArgs = [];
|
||||||
|
for (var i=1; i<args.length; i++)
|
||||||
|
methodArgs.push(args[i])
|
||||||
|
|
||||||
|
data[option].apply(data, methodArgs)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.sidenavTree.Constructor = SidenavTree
|
||||||
|
|
||||||
|
// SIDENAVREE NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.sidenavTree.noConflict = function () {
|
||||||
|
$.fn.sidenavTree = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIDENAVTREE DATA-API
|
||||||
|
// ===============
|
||||||
|
|
||||||
|
$(document).ready(function () {
|
||||||
|
$('[data-control=sidenav-tree]').sidenavTree()
|
||||||
|
})
|
||||||
|
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,140 @@
|
||||||
|
/*
|
||||||
|
* Side Navigation
|
||||||
|
*
|
||||||
|
* Data attributes:
|
||||||
|
* - data-control="sidenav" - enables the side navigation plugin
|
||||||
|
*
|
||||||
|
* JavaScript API:
|
||||||
|
* $('#nav').sideNav()
|
||||||
|
* $.oc.sideNav.setCounter('cms/partials', 5); - sets the counter value for a particular menu item
|
||||||
|
* $.oc.sideNav.increaseCounter('cms/partials', 5); - increases the counter value for a particular menu item
|
||||||
|
* $.oc.sideNav.dropCounter('cms/partials'); - drops the counter value for a particular menu item
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - Drag Scroll (october.dragscroll.js)
|
||||||
|
*/
|
||||||
|
|
||||||
|
+function ($) { "use strict";
|
||||||
|
if ($.oc === undefined)
|
||||||
|
$.oc = {}
|
||||||
|
|
||||||
|
// SIDENAV CLASS DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var SideNav = function(element, options) {
|
||||||
|
this.options = options
|
||||||
|
this.$el = $(element)
|
||||||
|
this.$list = $('ul', this.$el)
|
||||||
|
this.$items = $('li', this.$list)
|
||||||
|
|
||||||
|
this.init();
|
||||||
|
}
|
||||||
|
|
||||||
|
SideNav.DEFAULTS = {
|
||||||
|
activeClass: 'active'
|
||||||
|
}
|
||||||
|
|
||||||
|
SideNav.prototype.init = function (){
|
||||||
|
var self = this
|
||||||
|
|
||||||
|
this.$list.dragScroll({
|
||||||
|
vertical: true,
|
||||||
|
useNative: true,
|
||||||
|
start: function() { self.$list.addClass('drag') },
|
||||||
|
stop: function() { self.$list.removeClass('drag') },
|
||||||
|
scrollClassContainer: self.$el,
|
||||||
|
scrollMarkerContainer: self.$el
|
||||||
|
})
|
||||||
|
|
||||||
|
this.$list.on('click', function() {
|
||||||
|
/* Do not handle menu item clicks while dragging */
|
||||||
|
if (self.$list.hasClass('drag')) {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
SideNav.prototype.unsetActiveItem = function (itemId){
|
||||||
|
this.$items.removeClass(this.options.activeClass)
|
||||||
|
}
|
||||||
|
|
||||||
|
SideNav.prototype.setActiveItem = function (itemId){
|
||||||
|
if (!itemId) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$items
|
||||||
|
.removeClass(this.options.activeClass)
|
||||||
|
.filter('[data-menu-item='+itemId+']')
|
||||||
|
.addClass(this.options.activeClass)
|
||||||
|
}
|
||||||
|
|
||||||
|
SideNav.prototype.setCounter = function (itemId, value){
|
||||||
|
var $counter = $('span.counter[data-menu-id="'+itemId+'"]', this.$el)
|
||||||
|
|
||||||
|
$counter.removeClass('empty')
|
||||||
|
$counter.toggleClass('empty', value == 0)
|
||||||
|
$counter.text(value)
|
||||||
|
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
SideNav.prototype.increaseCounter = function (itemId, value){
|
||||||
|
var $counter = $('span.counter[data-menu-id="'+itemId+'"]', this.$el)
|
||||||
|
|
||||||
|
var originalValue = parseInt($counter.text())
|
||||||
|
if (isNaN(originalValue))
|
||||||
|
originalValue = 0
|
||||||
|
|
||||||
|
var newValue = value + originalValue
|
||||||
|
$counter.toggleClass('empty', newValue == 0)
|
||||||
|
$counter.text(newValue)
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
SideNav.prototype.dropCounter = function (itemId){
|
||||||
|
this.setCounter(itemId, 0)
|
||||||
|
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIDENAV PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.sideNav
|
||||||
|
|
||||||
|
$.fn.sideNav = function (option) {
|
||||||
|
var args = Array.prototype.slice.call(arguments, 1), result
|
||||||
|
this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.sideNav')
|
||||||
|
var options = $.extend({}, SideNav.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
if (!data) $this.data('oc.sideNav', (data = new SideNav(this, options)))
|
||||||
|
if (typeof option == 'string') result = data[option].apply(data, args)
|
||||||
|
if (typeof result != 'undefined') return false
|
||||||
|
|
||||||
|
if ($.oc.sideNav === undefined)
|
||||||
|
$.oc.sideNav = data
|
||||||
|
})
|
||||||
|
|
||||||
|
return result ? result : this
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.sideNav.Constructor = SideNav
|
||||||
|
|
||||||
|
// SIDENAV NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.sideNav.noConflict = function () {
|
||||||
|
$.fn.sideNav = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIDENAV DATA-API
|
||||||
|
// ===============
|
||||||
|
|
||||||
|
$(document).ready(function(){
|
||||||
|
$('[data-control="sidenav"]').sideNav()
|
||||||
|
})
|
||||||
|
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,258 @@
|
||||||
|
/*
|
||||||
|
* Side Panel Tabs
|
||||||
|
*/
|
||||||
|
|
||||||
|
+function ($) { "use strict";
|
||||||
|
|
||||||
|
var SidePanelTab = function(element, options) {
|
||||||
|
this.options = options
|
||||||
|
this.$el = $(element)
|
||||||
|
this.init()
|
||||||
|
}
|
||||||
|
|
||||||
|
SidePanelTab.prototype.init = function() {
|
||||||
|
var self = this
|
||||||
|
this.tabOpenDelay = 200
|
||||||
|
this.tabOpenTimeout = undefined
|
||||||
|
this.panelOpenTimeout = undefined
|
||||||
|
this.$sideNav = $('#layout-sidenav')
|
||||||
|
this.$sideNavItems = $('ul li', this.$sideNav)
|
||||||
|
this.$sidePanelItems = $('[data-content-id]', this.$el)
|
||||||
|
this.sideNavWidth = this.$sideNavItems.outerWidth()
|
||||||
|
this.mainNavHeight = $('#layout-mainmenu').outerHeight()
|
||||||
|
this.panelVisible = false
|
||||||
|
this.visibleItemId = false
|
||||||
|
this.$fixButton = $('<a href="#" class="fix-button"><i class="icon-thumb-tack"></i></a>')
|
||||||
|
|
||||||
|
this.$fixButton.click(function() {
|
||||||
|
self.fixPanel()
|
||||||
|
return false
|
||||||
|
})
|
||||||
|
$('.fix-button-container', this.$el).append(this.$fixButton)
|
||||||
|
|
||||||
|
this.$sideNavItems.click(function() {
|
||||||
|
if ($(this).data('no-side-panel')) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
if (Modernizr.touchevents && $(window).width() < self.options.breakpoint) {
|
||||||
|
if ($(this).data('menu-item') == self.visibleItemId && self.panelVisible) {
|
||||||
|
self.hideSidePanel()
|
||||||
|
return
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
self.displaySidePanel()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
self.displayTab(this)
|
||||||
|
|
||||||
|
return false
|
||||||
|
})
|
||||||
|
|
||||||
|
if (!Modernizr.touchevents) {
|
||||||
|
// The side panel now opens only when a menu item is hovered and
|
||||||
|
// when the item doesn't have the "data-no-side-panel" attribute.
|
||||||
|
// TODO: remove the comment and the code below if no issues noticed.
|
||||||
|
// self.$sideNav.mouseenter(function() {
|
||||||
|
// if ($(window).width() < self.options.breakpoint || !self.panelFixed()) {
|
||||||
|
// self.panelOpenTimeout = setTimeout(function() {
|
||||||
|
// self.displaySidePanel()
|
||||||
|
// }, self.tabOpenDelay)
|
||||||
|
// }
|
||||||
|
// })
|
||||||
|
|
||||||
|
self.$sideNav.mouseleave(function() {
|
||||||
|
clearTimeout(self.panelOpenTimeout)
|
||||||
|
})
|
||||||
|
|
||||||
|
self.$el.mouseleave(function() {
|
||||||
|
self.hideSidePanel()
|
||||||
|
})
|
||||||
|
|
||||||
|
self.$sideNavItems.mouseenter(function() {
|
||||||
|
if ($(window).width() < self.options.breakpoint || !self.panelFixed()) {
|
||||||
|
if ($(this).data('no-side-panel')) {
|
||||||
|
self.hideSidePanel()
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
var _this = this
|
||||||
|
self.tabOpenTimeout = setTimeout(function() {
|
||||||
|
self.displaySidePanel()
|
||||||
|
self.displayTab(_this)
|
||||||
|
}, self.tabOpenDelay)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
self.$sideNavItems.mouseleave(function() {
|
||||||
|
clearTimeout(self.tabOpenTimeout)
|
||||||
|
})
|
||||||
|
|
||||||
|
$(window).resize(function() {
|
||||||
|
self.updatePanelPosition()
|
||||||
|
self.updateActiveTab()
|
||||||
|
})
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$('#layout-body').click(function() {
|
||||||
|
if (self.panelVisible) {
|
||||||
|
self.hideSidePanel()
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
self.$el.on('close.oc.sidePanel', function() {
|
||||||
|
self.hideSidePanel()
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
this.updateActiveTab()
|
||||||
|
}
|
||||||
|
|
||||||
|
SidePanelTab.prototype.displayTab = function(menuItem) {
|
||||||
|
var menuItemId = $(menuItem).data('menu-item')
|
||||||
|
|
||||||
|
this.visibleItemId = menuItemId
|
||||||
|
|
||||||
|
if ($.oc.sideNav !== undefined) {
|
||||||
|
$.oc.sideNav.setActiveItem(menuItemId)
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$sidePanelItems.each(function() {
|
||||||
|
var $el = $(this)
|
||||||
|
$el.toggleClass('hide', $el.data('content-id') != menuItemId)
|
||||||
|
})
|
||||||
|
|
||||||
|
$(window).trigger('resize')
|
||||||
|
}
|
||||||
|
|
||||||
|
SidePanelTab.prototype.displaySidePanel = function() {
|
||||||
|
$(document.body).addClass('display-side-panel')
|
||||||
|
|
||||||
|
this.$el.appendTo('#layout-canvas')
|
||||||
|
this.panelVisible = true
|
||||||
|
this.$el.css({
|
||||||
|
left: this.sideNavWidth,
|
||||||
|
top: this.mainNavHeight
|
||||||
|
})
|
||||||
|
|
||||||
|
this.updatePanelPosition()
|
||||||
|
$(window).trigger('resize')
|
||||||
|
}
|
||||||
|
|
||||||
|
SidePanelTab.prototype.hideSidePanel = function() {
|
||||||
|
$(document.body).removeClass('display-side-panel')
|
||||||
|
if (this.$el.next('#layout-body').length == 0) {
|
||||||
|
$('#layout-body').before(this.$el)
|
||||||
|
}
|
||||||
|
|
||||||
|
this.panelVisible = false
|
||||||
|
|
||||||
|
this.updateActiveTab()
|
||||||
|
}
|
||||||
|
|
||||||
|
SidePanelTab.prototype.updatePanelPosition = function() {
|
||||||
|
if (!this.panelFixed() || Modernizr.touchevents) {
|
||||||
|
this.$el.height($(document).height() - this.mainNavHeight)
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
this.$el.css('height', '')
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.panelVisible && $(window).width() > this.options.breakpoint && this.panelFixed()) {
|
||||||
|
this.hideSidePanel()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
SidePanelTab.prototype.updateActiveTab = function() {
|
||||||
|
if ($.oc.sideNav === undefined) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!this.panelVisible && ($(window).width() < this.options.breakpoint || !this.panelFixed())) {
|
||||||
|
$.oc.sideNav.unsetActiveItem()
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$.oc.sideNav.setActiveItem(this.visibleItemId)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
SidePanelTab.prototype.panelFixed = function() {
|
||||||
|
return !($(window).width() < this.options.breakpoint) &&
|
||||||
|
!$(document.body).hasClass('side-panel-not-fixed')
|
||||||
|
}
|
||||||
|
|
||||||
|
SidePanelTab.prototype.fixPanel = function() {
|
||||||
|
$(document.body).toggleClass('side-panel-not-fixed')
|
||||||
|
|
||||||
|
var self = this
|
||||||
|
|
||||||
|
window.setTimeout(function() {
|
||||||
|
var fixed = self.panelFixed()
|
||||||
|
|
||||||
|
if (fixed) {
|
||||||
|
self.updateActiveTab()
|
||||||
|
$(document.body).addClass('side-panel-fix-shadow')
|
||||||
|
} else {
|
||||||
|
$(document.body).removeClass('side-panel-fix-shadow')
|
||||||
|
self.hideSidePanel()
|
||||||
|
}
|
||||||
|
|
||||||
|
if (typeof(localStorage) !== 'undefined')
|
||||||
|
localStorage.ocSidePanelFixed = fixed ? 1 : 0
|
||||||
|
}, 0)
|
||||||
|
}
|
||||||
|
|
||||||
|
SidePanelTab.DEFAULTS = {
|
||||||
|
breakpoint: 769
|
||||||
|
}
|
||||||
|
|
||||||
|
// PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.sidePanelTab
|
||||||
|
|
||||||
|
$.fn.sidePanelTab = function (option) {
|
||||||
|
return this.each(function() {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.sidePanelTab')
|
||||||
|
var options = $.extend({}, SidePanelTab.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
if (!data) $this.data('oc.sidePanelTab', (data = new SidePanelTab(this, options)))
|
||||||
|
if (typeof option == 'string') data[option].call(data)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.sidePanelTab.Constructor = SidePanelTab
|
||||||
|
|
||||||
|
// NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.sidePanelTab.noConflict = function() {
|
||||||
|
$.fn.sidePanelTab = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// DATA-API
|
||||||
|
// ============
|
||||||
|
|
||||||
|
$(document).ready(function(){
|
||||||
|
$('[data-control=layout-sidepanel]').sidePanelTab()
|
||||||
|
})
|
||||||
|
|
||||||
|
// STORED PREFERENCES
|
||||||
|
// ====================
|
||||||
|
|
||||||
|
$(document).ready(function() {
|
||||||
|
if (Modernizr.touchevents || (typeof(localStorage) !== 'undefined')) {
|
||||||
|
if (localStorage.ocSidePanelFixed == 0) {
|
||||||
|
$(document.body).addClass('side-panel-not-fixed')
|
||||||
|
$(window).trigger('resize')
|
||||||
|
}
|
||||||
|
else if (localStorage.ocSidePanelFixed == 1) {
|
||||||
|
$(document.body).removeClass('side-panel-not-fixed')
|
||||||
|
$(window).trigger('resize')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,81 @@
|
||||||
|
/*
|
||||||
|
* SimpleList control.
|
||||||
|
*
|
||||||
|
* Data attributes:
|
||||||
|
* - data-control="simplelist" - enables the simplelist plugin
|
||||||
|
*
|
||||||
|
* JavaScript API:
|
||||||
|
* $('#simplelist').simplelist()
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - Sortable (jquery-sortable.js)
|
||||||
|
*/
|
||||||
|
+function ($) { "use strict";
|
||||||
|
|
||||||
|
var SimpleList = function (element, options) {
|
||||||
|
|
||||||
|
var $el = this.$el = $(element)
|
||||||
|
|
||||||
|
this.options = options || {}
|
||||||
|
|
||||||
|
if ($el.hasClass('is-sortable')) {
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Make each list inside sortable
|
||||||
|
*/
|
||||||
|
var sortableOptions = {
|
||||||
|
distance: 10
|
||||||
|
}
|
||||||
|
if (this.options.sortableHandle)
|
||||||
|
sortableOptions[handle] = this.options.sortableHandle
|
||||||
|
|
||||||
|
$el.find('> ul, > ol').sortable(sortableOptions)
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($el.hasClass('is-scrollable')) {
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Inject a scrollbar container
|
||||||
|
*/
|
||||||
|
$el.wrapInner($('<div />').addClass('control-scrollbar'))
|
||||||
|
var $scrollbar = $el.find('>.control-scrollbar:first')
|
||||||
|
$scrollbar.scrollbar()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
SimpleList.DEFAULTS = {
|
||||||
|
sortableHandle: null
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIMPLE LIST PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.simplelist
|
||||||
|
|
||||||
|
$.fn.simplelist = function (option) {
|
||||||
|
return this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.simplelist')
|
||||||
|
var options = $.extend({}, SimpleList.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
if (!data) $this.data('oc.simplelist', (data = new SimpleList(this, options)))
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.simplelist.Constructor = SimpleList
|
||||||
|
|
||||||
|
// SIMPLE LIST NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.simplelist.noConflict = function () {
|
||||||
|
$.fn.simplelist = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// SIMPLE LIST DATA-API
|
||||||
|
// ===============
|
||||||
|
|
||||||
|
$(document).render(function(){
|
||||||
|
$('[data-control="simplelist"]').simplelist()
|
||||||
|
})
|
||||||
|
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,163 @@
|
||||||
|
/*
|
||||||
|
* Extends the fancy tabs layout with expand controls in the tab
|
||||||
|
* form sections. See main Builder page for example.
|
||||||
|
* TODO: A similar layout is used in the CMS, Pages and Builder areas,
|
||||||
|
* but only Builder uses this class.
|
||||||
|
*/
|
||||||
|
+function ($) { "use strict";
|
||||||
|
var Base = $.oc.foundation.base,
|
||||||
|
BaseProto = Base.prototype
|
||||||
|
|
||||||
|
var TabFormExpandControls = function ($tabsControlElement, options) {
|
||||||
|
this.$tabsControlElement = $tabsControlElement
|
||||||
|
this.options = $.extend(TabFormExpandControls.DEFAULTS, typeof options == 'object' && options)
|
||||||
|
this.tabsControlId = null
|
||||||
|
|
||||||
|
Base.call(this)
|
||||||
|
this.init()
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype = Object.create(BaseProto)
|
||||||
|
TabFormExpandControls.prototype.constructor = TabFormExpandControls
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.init = function() {
|
||||||
|
this.tabsControlId = this.$tabsControlElement.attr('id')
|
||||||
|
|
||||||
|
if (!this.tabsControlId) {
|
||||||
|
throw new Error('The tab controls element should have the id attribute value.')
|
||||||
|
}
|
||||||
|
|
||||||
|
this.registerHandlers()
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.dispose = function() {
|
||||||
|
this.unregisterHandlers()
|
||||||
|
|
||||||
|
this.$tabsControlElement = null
|
||||||
|
|
||||||
|
BaseProto.dispose.call(this)
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.registerHandlers = function() {
|
||||||
|
this.$tabsControlElement.on('initTab.oc.tab', this.proxy(this.initTab))
|
||||||
|
this.$tabsControlElement.on('click', '[data-control="tabless-collapse-icon"]', this.proxy(this.tablessCollapseClicked))
|
||||||
|
this.$tabsControlElement.on('click', '[data-control="primary-collapse-icon"]', this.proxy(this.primaryCollapseClicked))
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.unregisterHandlers = function() {
|
||||||
|
this.$tabsControlElement.off('initTab.oc.tab', this.proxy(this.initTab))
|
||||||
|
this.$tabsControlElement.off('click', '[data-control="tabless-collapse-icon"]', this.proxy(this.tablessCollapseClicked))
|
||||||
|
this.$tabsControlElement.off('click', '[data-control="primary-collapse-icon"]', this.proxy(this.primaryCollapseClicked))
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.initTab = function(ev, data) {
|
||||||
|
if ($(ev.target).attr('id') != this.tabsControlId)
|
||||||
|
return
|
||||||
|
|
||||||
|
var $primaryPanel = this.findPrimaryPanel(data.pane),
|
||||||
|
$panel = $('.form-tabless-fields', data.pane),
|
||||||
|
$secondaryPanel = this.findSecondaryPanel(data.pane),
|
||||||
|
hasSecondaryTabs = $secondaryPanel.length > 0
|
||||||
|
|
||||||
|
$secondaryPanel.addClass('secondary-content-tabs')
|
||||||
|
$panel.append(this.createTablessCollapseIcon())
|
||||||
|
|
||||||
|
if (!hasSecondaryTabs) {
|
||||||
|
$('.tab-pane', $primaryPanel).addClass('pane-compact')
|
||||||
|
}
|
||||||
|
|
||||||
|
$('.nav-tabs', $primaryPanel).addClass('master-area')
|
||||||
|
|
||||||
|
if ($primaryPanel.length > 0) {
|
||||||
|
$secondaryPanel.append(this.createPrimaryCollapseIcon())
|
||||||
|
} else {
|
||||||
|
$secondaryPanel.addClass('primary-collapsed')
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!$('a', data.tab).hasClass('new-template') && this.getLocalStorageValue('tabless', 0) == 1) {
|
||||||
|
$panel.addClass('collapsed')
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.getLocalStorageValue('primary', 0) == 1 && hasSecondaryTabs) {
|
||||||
|
$primaryPanel.addClass('collapsed')
|
||||||
|
$secondaryPanel.addClass('primary-collapsed')
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.options.onInitTab) {
|
||||||
|
this.options.onInitTab($('form', data.pane))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.tablessCollapseClicked = function(ev) {
|
||||||
|
var $panel = $(ev.target).closest('.form-tabless-fields')
|
||||||
|
|
||||||
|
$panel.toggleClass('collapsed')
|
||||||
|
this.setLocalStorageValue('tabless', $panel.hasClass('collapsed') ? 1 : 0)
|
||||||
|
window.setTimeout(this.proxy(this.updateUi), 500)
|
||||||
|
|
||||||
|
ev.stopPropagation()
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.primaryCollapseClicked = function(ev) {
|
||||||
|
var $pane = $(ev.target).closest('.tab-pane'),
|
||||||
|
$primaryPanel = this.findPrimaryPanel($pane),
|
||||||
|
$secondaryPanel = this.findSecondaryPanel($pane)
|
||||||
|
|
||||||
|
$primaryPanel.toggleClass('collapsed')
|
||||||
|
$secondaryPanel.toggleClass('primary-collapsed')
|
||||||
|
|
||||||
|
this.updateUi()
|
||||||
|
this.setLocalStorageValue('primary', $primaryPanel.hasClass('collapsed') ? 1 : 0)
|
||||||
|
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.updateUi = function() {
|
||||||
|
$(window).trigger('oc.updateUi')
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.createTablessCollapseIcon = function() {
|
||||||
|
return $('<a href="javascript:;" class="tab-collapse-icon tabless" data-control="tabless-collapse-icon"><i class="icon-chevron-up"></i></a>')
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.createPrimaryCollapseIcon = function() {
|
||||||
|
return $('<a href="javascript:;" class="tab-collapse-icon primary" data-control="primary-collapse-icon"><i class="icon-chevron-down"></i></a>')
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.generateStorageKey = function(section) {
|
||||||
|
return 'oc' + section + this.tabsControlId.replace('-', '') + 'collapsed'
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.findPrimaryPanel = function(pane) {
|
||||||
|
return $(pane).find('.control-tabs.primary-tabs')
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.findSecondaryPanel = function(pane) {
|
||||||
|
return $(pane).find('.control-tabs.secondary-tabs')
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.getLocalStorageValue = function(section, defaultValue) {
|
||||||
|
var key = this.generateStorageKey(section)
|
||||||
|
|
||||||
|
if (typeof(localStorage) !== 'undefined') {
|
||||||
|
return localStorage[key]
|
||||||
|
}
|
||||||
|
|
||||||
|
return defaultValue
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.prototype.setLocalStorageValue = function(section, value) {
|
||||||
|
var key = this.generateStorageKey(section)
|
||||||
|
|
||||||
|
if (typeof(localStorage) !== 'undefined') {
|
||||||
|
localStorage[key] = value
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
TabFormExpandControls.DEFAULTS = {
|
||||||
|
onInitTab: null
|
||||||
|
}
|
||||||
|
|
||||||
|
$.oc.tabFormExpandControls = TabFormExpandControls
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,133 @@
|
||||||
|
/*
|
||||||
|
* TreeList Widget
|
||||||
|
*
|
||||||
|
* Supported options:
|
||||||
|
* - handle - class name to use as a handle
|
||||||
|
* - nested - set to false if sorting should be kept within each OL container, if using
|
||||||
|
* a handle it should be focused enough to exclude nested handles.
|
||||||
|
*
|
||||||
|
* Events:
|
||||||
|
* - move.oc.treelist - triggered when a node on the tree is moved.
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - Sortable Plugin (october.sortable.js)
|
||||||
|
*/
|
||||||
|
+function ($) { "use strict";
|
||||||
|
var Base = $.oc.foundation.base,
|
||||||
|
BaseProto = Base.prototype
|
||||||
|
|
||||||
|
var TreeListWidget = function (element, options) {
|
||||||
|
this.$el = $(element)
|
||||||
|
this.options = options || {};
|
||||||
|
|
||||||
|
Base.call(this)
|
||||||
|
|
||||||
|
$.oc.foundation.controlUtils.markDisposable(element)
|
||||||
|
this.init()
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeListWidget.prototype = Object.create(BaseProto)
|
||||||
|
TreeListWidget.prototype.constructor = TreeListWidget
|
||||||
|
|
||||||
|
TreeListWidget.prototype.init = function() {
|
||||||
|
var sortableOptions = {
|
||||||
|
handle: this.options.handle,
|
||||||
|
nested: this.options.nested,
|
||||||
|
onDrop: this.proxy(this.onDrop),
|
||||||
|
afterMove: this.proxy(this.onAfterMove)
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$el.find('> ol').sortable($.extend(sortableOptions, this.options))
|
||||||
|
|
||||||
|
if (!this.options.nested)
|
||||||
|
this.$el.find('> ol ol').sortable($.extend(sortableOptions, this.options))
|
||||||
|
|
||||||
|
this.$el.one('dispose-control', this.proxy(this.dispose))
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeListWidget.prototype.dispose = function() {
|
||||||
|
this.unbind()
|
||||||
|
BaseProto.dispose.call(this)
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeListWidget.prototype.unbind = function() {
|
||||||
|
this.$el.off('dispose-control', this.proxy(this.dispose))
|
||||||
|
|
||||||
|
this.$el.find('> ol').sortable('destroy')
|
||||||
|
|
||||||
|
if (!this.options.nested) {
|
||||||
|
this.$el.find('> ol ol').sortable('destroy')
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$el.removeData('oc.treelist')
|
||||||
|
|
||||||
|
this.$el = null
|
||||||
|
this.options = null
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeListWidget.DEFAULTS = {
|
||||||
|
handle: null,
|
||||||
|
nested: true
|
||||||
|
}
|
||||||
|
|
||||||
|
// TREELIST EVENT HANDLERS
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
TreeListWidget.prototype.onDrop = function($item, container, _super) {
|
||||||
|
// The event handler could be registered after the
|
||||||
|
// sortable is destroyed. This should be fixed later.
|
||||||
|
if (!this.$el) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$el.trigger('move.oc.treelist', { item: $item, container: container })
|
||||||
|
_super($item, container)
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeListWidget.prototype.onAfterMove = function($placeholder, container, $closestEl) {
|
||||||
|
if (!this.$el) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$el.trigger('aftermove.oc.treelist', { placeholder: $placeholder, container: container, closestEl: $closestEl })
|
||||||
|
}
|
||||||
|
|
||||||
|
// TREELIST WIDGET PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.treeListWidget
|
||||||
|
|
||||||
|
$.fn.treeListWidget = function (option) {
|
||||||
|
var args = arguments,
|
||||||
|
result
|
||||||
|
|
||||||
|
this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.treelist')
|
||||||
|
var options = $.extend({}, TreeListWidget.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
if (!data) $this.data('oc.treelist', (data = new TreeListWidget(this, options)))
|
||||||
|
if (typeof option == 'string') result = data[option].call(data)
|
||||||
|
if (typeof result != 'undefined') return false
|
||||||
|
})
|
||||||
|
|
||||||
|
return result ? result : this
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.treeListWidget.Constructor = TreeListWidget
|
||||||
|
|
||||||
|
// TREELIST WIDGET NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.treeListWidget.noConflict = function () {
|
||||||
|
$.fn.treeListWidget = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// TREELIST WIDGET DATA-API
|
||||||
|
// ==============
|
||||||
|
|
||||||
|
$(document).render(function(){
|
||||||
|
$('[data-control="treelist"]').treeListWidget();
|
||||||
|
})
|
||||||
|
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,437 @@
|
||||||
|
/*
|
||||||
|
* TreeView Widget. Represents a sortable and draggable tree view. This widget was first used in the Pages plugin, for the sidebar page tree.
|
||||||
|
*
|
||||||
|
* Data attributes:
|
||||||
|
* - data-group-status-handler - AJAX handler to execute when an item is collapsed or expanded by a user
|
||||||
|
* - data-reorder-handler - AJAX handler to execute when items are reordered
|
||||||
|
*
|
||||||
|
* Events
|
||||||
|
* - open.oc.treeview - this event is triggered on the list element when an item is clicked.
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - Tree list (october.treelist.js)
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
+function ($) { "use strict";
|
||||||
|
var Base = $.oc.foundation.base,
|
||||||
|
BaseProto = Base.prototype
|
||||||
|
|
||||||
|
var TreeView = function (element, options) {
|
||||||
|
this.$el = $(element)
|
||||||
|
this.options = options
|
||||||
|
this.$allItems = null
|
||||||
|
this.$scrollbar = null
|
||||||
|
|
||||||
|
Base.call(this)
|
||||||
|
|
||||||
|
$.oc.foundation.controlUtils.markDisposable(element)
|
||||||
|
this.init()
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype = Object.create(BaseProto)
|
||||||
|
TreeView.prototype.constructor = TreeView
|
||||||
|
|
||||||
|
TreeView.prototype.init = function () {
|
||||||
|
this.$allItems = $('li', this.$el)
|
||||||
|
this.$scrollbar = this.$el.closest('[data-control=scrollbar]')
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Init the sortable
|
||||||
|
*/
|
||||||
|
|
||||||
|
this.initSortable()
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Create expand/collapse icons and drag handles
|
||||||
|
*/
|
||||||
|
|
||||||
|
this.createItemControls()
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Bind the click events
|
||||||
|
*/
|
||||||
|
|
||||||
|
this.$el.on('click.treeview', 'li > div > ul.submenu li a', this.proxy(this.onOpenSubmenu))
|
||||||
|
this.$el.on('click.treeview', 'li > div > a', this.proxy(this.onOpen))
|
||||||
|
this.$el.on('click.treeview', 'li span.expand', this.proxy(this.onItemExpandClick))
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Listen for the AJAX updates and dispose the widget
|
||||||
|
*/
|
||||||
|
|
||||||
|
this.$el.one('dispose-control', this.proxy(this.dispose))
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Mark previously active item, if it was set
|
||||||
|
*/
|
||||||
|
var dataId = this.$el.data('oc.active-item')
|
||||||
|
if (dataId !== undefined) {
|
||||||
|
this.markActive(dataId)
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$scrollbar.on('oc.scrollEnd', this.proxy(this.onScroll))
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.dispose = function() {
|
||||||
|
this.unregisterHandlers()
|
||||||
|
this.clearScrollTimeout()
|
||||||
|
|
||||||
|
this.options = null
|
||||||
|
this.$el.removeData('oc.treeView')
|
||||||
|
this.$el = null
|
||||||
|
this.$allItems = null
|
||||||
|
this.$scrollbar = null
|
||||||
|
|
||||||
|
BaseProto.dispose.call(this)
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.unregisterHandlers = function() {
|
||||||
|
this.$scrollbar.off('oc.scrollEnd', this.proxy(this.onScroll))
|
||||||
|
this.$el.off('.treeview')
|
||||||
|
this.$el.off('move.oc.treelist', this.proxy(this.onNodeMove))
|
||||||
|
this.$el.off('aftermove.oc.treelist', this.proxy(this.onAfterNodeMove))
|
||||||
|
this.$el.off('dispose-control', this.proxy(this.dispose))
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.createItemControls = function() {
|
||||||
|
$('li', this.$el).each(function() {
|
||||||
|
var $container = $('> div', this),
|
||||||
|
$expand = $('> span.expand', $container)
|
||||||
|
|
||||||
|
if ($expand.length > 0)
|
||||||
|
return
|
||||||
|
|
||||||
|
$expand = $('<span class="expand">Expand</span>')
|
||||||
|
|
||||||
|
$container.prepend($expand)
|
||||||
|
|
||||||
|
if (!$('.drag-handle', $container).length)
|
||||||
|
$container.append($('<span class="drag-handle">Drag</span>'))
|
||||||
|
|
||||||
|
$container.append($('<span class="borders"></span>'))
|
||||||
|
|
||||||
|
if ($(this).attr('data-no-drag-mode') !== undefined)
|
||||||
|
$('span.drag-handle', this).attr('title', 'Dragging is disabled when the Search is active')
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.collapseGroup = function($group) {
|
||||||
|
var $subitems = $('> ol', $group)
|
||||||
|
|
||||||
|
$subitems.css({
|
||||||
|
'overflow': 'hidden'
|
||||||
|
})
|
||||||
|
|
||||||
|
$subitems.animate({'height': 0}, { duration: 100, queue: false, complete: function() {
|
||||||
|
$subitems.css({
|
||||||
|
'overflow': 'visible',
|
||||||
|
'display': 'none',
|
||||||
|
'height' : 'auto'
|
||||||
|
})
|
||||||
|
$group.attr('data-status', 'collapsed')
|
||||||
|
$(window).trigger('resize')
|
||||||
|
} })
|
||||||
|
|
||||||
|
this.sendGroupStatusRequest($group, 0)
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.expandGroup = function($group) {
|
||||||
|
var $subitems = $('> ol', $group)
|
||||||
|
|
||||||
|
$subitems.css({
|
||||||
|
'overflow': 'hidden',
|
||||||
|
'display': 'block',
|
||||||
|
'height': 0
|
||||||
|
})
|
||||||
|
|
||||||
|
$group.attr('data-status', 'expanded')
|
||||||
|
$subitems.animate({'height': $subitems[0].scrollHeight}, { duration: 100, queue: false, complete: function() {
|
||||||
|
$subitems.css({
|
||||||
|
'overflow': 'visible',
|
||||||
|
'height': 'auto'
|
||||||
|
})
|
||||||
|
$(window).trigger('resize')
|
||||||
|
} })
|
||||||
|
|
||||||
|
this.sendGroupStatusRequest($group, 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.fixSubItems = function() {
|
||||||
|
$('li', this.$el).each(function(){
|
||||||
|
var $li = $(this),
|
||||||
|
$subitems = $('> ol > li', $li)
|
||||||
|
$li.toggleClass('has-subitems', $subitems.length > 0)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.toggleGroup = function(group) {
|
||||||
|
var $group = $(group);
|
||||||
|
|
||||||
|
$group.attr('data-status') == 'expanded'
|
||||||
|
? this.collapseGroup($group)
|
||||||
|
: this.expandGroup($group)
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.sendGroupStatusRequest = function($group, status) {
|
||||||
|
if (this.options.groupStatusHandler !== undefined) {
|
||||||
|
var groupId = $group.data('group-id')
|
||||||
|
|
||||||
|
$group.request(this.options.groupStatusHandler, {data: {group: groupId, status: status}})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.sendReorderRequest = function() {
|
||||||
|
if (this.options.reorderHandler === undefined)
|
||||||
|
return
|
||||||
|
|
||||||
|
var groups = {}
|
||||||
|
|
||||||
|
function iterator($container, node) {
|
||||||
|
$('> li', $container).each(function(){
|
||||||
|
var subnodes = {}
|
||||||
|
iterator($('> ol', this), subnodes)
|
||||||
|
|
||||||
|
node[$(this).data('groupId')] = subnodes
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
iterator($('> ol', this.$el), groups)
|
||||||
|
|
||||||
|
this.$el.request(this.options.reorderHandler, {data: {structure: JSON.stringify(groups)}})
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.initSortable = function() {
|
||||||
|
var $noDragItems = $('[data-no-drag-mode]', this.$el)
|
||||||
|
|
||||||
|
if ($noDragItems.length > 0)
|
||||||
|
return
|
||||||
|
|
||||||
|
if (this.$el.data('oc.treelist'))
|
||||||
|
this.$el.treeListWidget('unbind')
|
||||||
|
|
||||||
|
this.$el.treeListWidget({
|
||||||
|
tweakCursorAdjustment: this.proxy(this.tweakCursorAdjustment),
|
||||||
|
isValidTarget: this.proxy(this.isValidTarget),
|
||||||
|
useAnimation: false,
|
||||||
|
usePlaceholderClone: true,
|
||||||
|
handle: 'span.drag-handle',
|
||||||
|
onDrag: this.proxy(this.onDrag),
|
||||||
|
tolerance: -20 // Give 20px of carry between containers
|
||||||
|
})
|
||||||
|
|
||||||
|
this.$el.on('move.oc.treelist', this.proxy(this.onNodeMove))
|
||||||
|
this.$el.on('aftermove.oc.treelist', this.proxy(this.onAfterNodeMove))
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.markActive = function(dataId) {
|
||||||
|
$('li', this.$el).removeClass('active')
|
||||||
|
|
||||||
|
if (dataId)
|
||||||
|
$('li[data-id="'+dataId+'"]', this.$el).addClass('active')
|
||||||
|
|
||||||
|
this.$el.data('oc.active-item', dataId)
|
||||||
|
}
|
||||||
|
|
||||||
|
// It seems the method is not used anymore as we re-create the control
|
||||||
|
// instead of updating it. Remove later if nothing weird is noticed.
|
||||||
|
// -ab Apr 26 2015
|
||||||
|
//
|
||||||
|
TreeView.prototype.update = function() {
|
||||||
|
this.$allItems = $('li', this.$el)
|
||||||
|
this.createItemControls()
|
||||||
|
//this.initSortable()
|
||||||
|
|
||||||
|
var dataId = this.$el.data('oc.active-item')
|
||||||
|
if (dataId !== undefined) {
|
||||||
|
this.markActive(dataId)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.handleMovedNode = function() {
|
||||||
|
this.$el.trigger('change')
|
||||||
|
this.$allItems.removeClass('drop-target')
|
||||||
|
this.fixSubItems()
|
||||||
|
this.sendReorderRequest()
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.tweakCursorAdjustment = function(adjustment) {
|
||||||
|
if (!adjustment) {
|
||||||
|
return adjustment
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.$scrollbar.length > 0) {
|
||||||
|
adjustment.top -= this.$scrollbar.scrollTop()
|
||||||
|
}
|
||||||
|
|
||||||
|
return adjustment
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.isValidTarget = function($item, container) {
|
||||||
|
return $(container.el).closest('li').attr('data-status') != 'collapsed'
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.DEFAULTS = {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
// TREEVIEW EVENT HANDLERS
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
TreeView.prototype.onOpenSubmenu = function(ev) {
|
||||||
|
var e = $.Event('submenu.oc.treeview', {relatedTarget: ev.currentTarget, clickEvent: ev})
|
||||||
|
this.$el.trigger(e, this)
|
||||||
|
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.onOpen = function(ev) {
|
||||||
|
var e = $.Event('open.oc.treeview', {relatedTarget: $(ev.currentTarget).closest('li').get(0), clickEvent: ev})
|
||||||
|
this.$el.trigger(e, ev.currentTarget)
|
||||||
|
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.onNodeMove = function() {
|
||||||
|
setTimeout(this.proxy(this.handleMovedNode), 50)
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.onAfterNodeMove = function(ev, data) {
|
||||||
|
this.$allItems.removeClass('drop-target')
|
||||||
|
data.container.el.closest('li').addClass('drop-target')
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.onItemExpandClick = function(ev) {
|
||||||
|
this.toggleGroup($(ev.currentTarget).closest('li'))
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
// TREEVIEW SCROLL ON DRAG
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
TreeView.prototype.onScroll = function () {
|
||||||
|
if (!$('body').hasClass('dragging')) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
var changed = this.lastScrollPos - this.$scrollbar.scrollTop()
|
||||||
|
|
||||||
|
this.$el.children('ol').each(function() {
|
||||||
|
var sortable = $(this).data('oc.sortable')
|
||||||
|
sortable.refresh()
|
||||||
|
sortable.cursorAdjustment.top += changed // Keep cursor adjustment in sync with scroll
|
||||||
|
});
|
||||||
|
|
||||||
|
this.dragCallback()
|
||||||
|
|
||||||
|
this.lastScrollPos = this.$scrollbar.scrollTop()
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.onDrag = function ($item, position, _super, event) {
|
||||||
|
this.lastScrollPos = this.$scrollbar.scrollTop()
|
||||||
|
|
||||||
|
this.dragCallback = function() {
|
||||||
|
_super($item, position, null, event)
|
||||||
|
};
|
||||||
|
|
||||||
|
this.clearScrollTimeout()
|
||||||
|
this.dragCallback()
|
||||||
|
|
||||||
|
if (!this.$scrollbar || this.$scrollbar.length === 0)
|
||||||
|
return
|
||||||
|
|
||||||
|
if (position.top < 0) {
|
||||||
|
this.scrollOffset = -10 + Math.floor(position.top / 5)
|
||||||
|
}
|
||||||
|
else if (position.top > this.$scrollbar.height()) {
|
||||||
|
this.scrollOffset = 10 + Math.ceil((position.top - this.$scrollbar.height()) / 5)
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
this.dragScroll()
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.scrollMax = function() {
|
||||||
|
return this.$el.height() - this.$scrollbar.height()
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.dragScroll = function() {
|
||||||
|
var startScrollTop = this.$scrollbar.scrollTop()
|
||||||
|
var changed
|
||||||
|
|
||||||
|
this.scrollTimeout = null
|
||||||
|
|
||||||
|
this.$scrollbar.scrollTop(Math.min(startScrollTop + this.scrollOffset, this.scrollMax()))
|
||||||
|
|
||||||
|
changed = this.$scrollbar.scrollTop() - startScrollTop
|
||||||
|
if (changed === 0) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$el.children('ol').each(function() {
|
||||||
|
var sortable = $(this).data('oc.sortable')
|
||||||
|
sortable.refresh()
|
||||||
|
sortable.cursorAdjustment.top -= changed // Keep cursor adjustment in sync with scroll
|
||||||
|
});
|
||||||
|
|
||||||
|
this.dragCallback()
|
||||||
|
|
||||||
|
this.$scrollbar.data('oc.scrollbar').setThumbPosition() // Update scrollbar position
|
||||||
|
|
||||||
|
this.scrollTimeout = window.setTimeout(this.proxy(this.dragScroll), 100)
|
||||||
|
}
|
||||||
|
|
||||||
|
TreeView.prototype.clearScrollTimeout = function() {
|
||||||
|
if (this.scrollTimeout) {
|
||||||
|
window.clearTimeout(this.scrollTimeout)
|
||||||
|
this.scrollTimeout = null
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// TREEVIEW PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.treeView
|
||||||
|
|
||||||
|
$.fn.treeView = function (option) {
|
||||||
|
var args = arguments
|
||||||
|
|
||||||
|
return this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.treeView')
|
||||||
|
var options = $.extend({}, TreeView.DEFAULTS, $this.data(), typeof option == 'object' && option)
|
||||||
|
if (!data) $this.data('oc.treeView', (data = new TreeView(this, options)))
|
||||||
|
|
||||||
|
if (typeof option == 'string' && data) {
|
||||||
|
var methodArgs = [];
|
||||||
|
for (var i=1; i<args.length; i++)
|
||||||
|
methodArgs.push(args[i])
|
||||||
|
|
||||||
|
if (data[option])
|
||||||
|
data[option].apply(data, methodArgs)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.treeView.Constructor = TreeView
|
||||||
|
|
||||||
|
// TREEVIEW NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.treeView.noConflict = function () {
|
||||||
|
$.fn.treeView = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
// TREEVIEW DATA-API
|
||||||
|
// ===============
|
||||||
|
// $(window).load(function(){
|
||||||
|
// $('[data-control=treeview]').treeView()
|
||||||
|
// })
|
||||||
|
|
||||||
|
$(document).render(function(){
|
||||||
|
$('[data-control=treeview]').treeView()
|
||||||
|
})
|
||||||
|
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,159 @@
|
||||||
|
/*
|
||||||
|
* Creates a vertical responsive menu.
|
||||||
|
*
|
||||||
|
* JavaScript API:
|
||||||
|
* $('#menu').verticalMenu()
|
||||||
|
*
|
||||||
|
* Dependences:
|
||||||
|
* - Drag Scroll (october.dragscroll.js)
|
||||||
|
*/
|
||||||
|
+function ($) { "use strict";
|
||||||
|
|
||||||
|
var VerticalMenu = function (element, toggle, options) {
|
||||||
|
this.$el = $(element)
|
||||||
|
this.body = $('body')
|
||||||
|
this.toggle = $(toggle)
|
||||||
|
this.options = options || {}
|
||||||
|
this.options = $.extend({}, VerticalMenu.DEFAULTS, this.options)
|
||||||
|
this.wrapper = $(this.options.contentWrapper)
|
||||||
|
this.breakpoint = options.breakpoint
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Insert the menu
|
||||||
|
*/
|
||||||
|
this.menuPanel = $('<div></div>').appendTo('body').addClass(this.options.collapsedMenuClass).css('width', 0)
|
||||||
|
this.menuContainer = $('<div></div>').appendTo(this.menuPanel).css('display', 'none')
|
||||||
|
this.menuElement = this.$el.clone().appendTo(this.menuContainer).css('width', 'auto')
|
||||||
|
|
||||||
|
var self = this
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Handle the menu toggle click
|
||||||
|
*/
|
||||||
|
this.toggle.click(function() {
|
||||||
|
if (!self.body.hasClass(self.options.bodyMenuOpenClass)) {
|
||||||
|
var wrapperWidth = self.wrapper.outerWidth()
|
||||||
|
|
||||||
|
self.menuElement.dragScroll('goToStart')
|
||||||
|
|
||||||
|
self.wrapper.css({
|
||||||
|
'position': 'absolute',
|
||||||
|
'min-width': self.wrapper.width(),
|
||||||
|
'height': '100%'
|
||||||
|
})
|
||||||
|
self.body.addClass(self.options.bodyMenuOpenClass)
|
||||||
|
self.menuContainer.css('display', 'block')
|
||||||
|
|
||||||
|
self.wrapper.animate({'left': self.options.menuWidth}, { duration: 200, queue: false })
|
||||||
|
self.menuPanel.animate({'width': self.options.menuWidth}, {
|
||||||
|
duration: 200,
|
||||||
|
queue: false,
|
||||||
|
complete: function() {
|
||||||
|
self.menuElement.css('width', self.options.menuWidth)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
closeMenu()
|
||||||
|
}
|
||||||
|
|
||||||
|
return false
|
||||||
|
})
|
||||||
|
|
||||||
|
this.wrapper.click(function() {
|
||||||
|
if (self.body.hasClass(self.options.bodyMenuOpenClass)) {
|
||||||
|
closeMenu()
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Disable the menu if the window is wider than the breakpoint width
|
||||||
|
*/
|
||||||
|
$(window).resize(function() {
|
||||||
|
if (self.body.hasClass(self.options.bodyMenuOpenClass)) {
|
||||||
|
if ($(window).width() > self.breakpoint) {
|
||||||
|
hideMenu()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Make the menu draggable
|
||||||
|
*/
|
||||||
|
this.menuElement.dragScroll({
|
||||||
|
vertical: true,
|
||||||
|
useNative: true,
|
||||||
|
start: function(){self.menuElement.addClass('drag')},
|
||||||
|
stop: function(){self.menuElement.removeClass('drag')},
|
||||||
|
scrollClassContainer: self.menuPanel,
|
||||||
|
scrollMarkerContainer: self.menuContainer
|
||||||
|
})
|
||||||
|
|
||||||
|
this.menuElement.on('click', function() {
|
||||||
|
// Do not handle menu item clicks while dragging
|
||||||
|
if (self.menuElement.hasClass('drag'))
|
||||||
|
return false
|
||||||
|
})
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Internal event, completely hides the menu
|
||||||
|
*/
|
||||||
|
function hideMenu() {
|
||||||
|
self.body.removeClass(self.options.bodyMenuOpenClass)
|
||||||
|
self.wrapper.css({
|
||||||
|
'position': 'static',
|
||||||
|
'min-width': 0,
|
||||||
|
'right': 0,
|
||||||
|
'height': '100%'
|
||||||
|
})
|
||||||
|
self.menuPanel.css('width', 0)
|
||||||
|
self.menuElement.css('width', 'auto')
|
||||||
|
self.menuContainer.css('display', 'none')
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Internal event, smoothly collapses the menu
|
||||||
|
*/
|
||||||
|
function closeMenu() {
|
||||||
|
self.wrapper.animate({'left': 0}, { duration: 200, queue: false})
|
||||||
|
self.menuPanel.animate({'width': 0}, { duration: 200, queue: false, complete: hideMenu })
|
||||||
|
self.menuElement.animate({'width': 0}, { duration: 200, queue: false })
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
VerticalMenu.DEFAULTS = {
|
||||||
|
menuWidth: 230,
|
||||||
|
breakpoint: 769,
|
||||||
|
bodyMenuOpenClass: 'mainmenu-open',
|
||||||
|
collapsedMenuClass: 'mainmenu-collapsed',
|
||||||
|
contentWrapper: '#layout-canvas'
|
||||||
|
}
|
||||||
|
|
||||||
|
// VERTICAL MENU PLUGIN DEFINITION
|
||||||
|
// ============================
|
||||||
|
|
||||||
|
var old = $.fn.verticalMenu
|
||||||
|
|
||||||
|
$.fn.verticalMenu = function (toggleSelector, option) {
|
||||||
|
return this.each(function () {
|
||||||
|
var $this = $(this)
|
||||||
|
var data = $this.data('oc.verticalMenu')
|
||||||
|
var options = typeof option == 'object' && option
|
||||||
|
|
||||||
|
if (!data) $this.data('oc.verticalMenu', (data = new VerticalMenu(this, toggleSelector, options)))
|
||||||
|
if (typeof option == 'string') data[option].call($this)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
$.fn.verticalMenu.Constructor = VerticalMenu
|
||||||
|
|
||||||
|
// VERTICAL MENU NO CONFLICT
|
||||||
|
// =================
|
||||||
|
|
||||||
|
$.fn.verticalMenu.noConflict = function () {
|
||||||
|
$.fn.verticalMenu = old
|
||||||
|
return this
|
||||||
|
}
|
||||||
|
|
||||||
|
}(window.jQuery);
|
||||||
|
|
@ -0,0 +1,71 @@
|
||||||
|
$(document).ready(function() {
|
||||||
|
|
||||||
|
var editorEl = $('#editorpreferencesCodeeditor'),
|
||||||
|
editor = editorEl.codeEditor('getEditorObject'),
|
||||||
|
session = editor.getSession(),
|
||||||
|
renderer = editor.renderer
|
||||||
|
|
||||||
|
editorEl.height($('#editorSettingsForm').height() - 23)
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_theme').on('change', function() {
|
||||||
|
editorEl.codeEditor('setTheme', $(this).val())
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_font_size').on('change', function() {
|
||||||
|
editor.setFontSize(parseInt($(this).val()))
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_word_wrap').on('change', function() {
|
||||||
|
editorEl.codeEditor('setWordWrap', $(this).val())
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_code_folding').on('change', function() {
|
||||||
|
session.setFoldStyle($(this).val())
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_autocompletion').on('change', function() {
|
||||||
|
editor.setOption('enableBasicAutocompletion', false)
|
||||||
|
editor.setOption('enableLiveAutocompletion', false)
|
||||||
|
|
||||||
|
var val = $(this).val()
|
||||||
|
if (val == 'basic') {
|
||||||
|
editor.setOption('enableBasicAutocompletion', true)
|
||||||
|
}
|
||||||
|
else if (val == 'live') {
|
||||||
|
editor.setOption('enableLiveAutocompletion', true)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_tab_size').on('change', function() {
|
||||||
|
session.setTabSize($(this).val())
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_show_invisibles').on('change', function() {
|
||||||
|
editor.setShowInvisibles($(this).is(':checked'))
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_enable_snippets').on('change', function() {
|
||||||
|
editor.setOption('enableSnippets', $(this).is(':checked'))
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_display_indent_guides').on('change', function() {
|
||||||
|
editor.setDisplayIndentGuides($(this).is(':checked'))
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_show_print_margin').on('change', function() {
|
||||||
|
editor.setShowPrintMargin($(this).is(':checked'))
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_highlight_active_line').on('change', function() {
|
||||||
|
editor.setHighlightActiveLine($(this).is(':checked'))
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_use_hard_tabs').on('change', function() {
|
||||||
|
session.setUseSoftTabs(!$(this).is(':checked'))
|
||||||
|
})
|
||||||
|
|
||||||
|
$('#Form-field-Preference-editor_show_gutter').on('change', function() {
|
||||||
|
renderer.setShowGutter($(this).is(':checked'))
|
||||||
|
})
|
||||||
|
|
||||||
|
})
|
||||||
|
|
@ -0,0 +1,215 @@
|
||||||
|
/*! jQuery Migrate v3.0.1 | (c) jQuery Foundation and other contributors | jquery.org/license */
|
||||||
|
|
||||||
|
void 0 === jQuery.migrateMute && (jQuery.migrateMute = !0), function(e) {
|
||||||
|
"function" == typeof define && define.amd ? define([ "jquery" ], window, e) : "object" == typeof module && module.exports ? module.exports = e(require("jquery"), window) : e(jQuery, window);
|
||||||
|
}(function(e, t) {
|
||||||
|
"use strict";
|
||||||
|
function r(r) {
|
||||||
|
var n = t.console;
|
||||||
|
o[r] || (o[r] = !0, e.migrateWarnings.push(r), n && n.warn && !e.migrateMute && (n.warn("JQMIGRATE: " + r),
|
||||||
|
e.migrateTrace && n.trace && n.trace()));
|
||||||
|
}
|
||||||
|
function n(e, t, n, a) {
|
||||||
|
Object.defineProperty(e, t, {
|
||||||
|
configurable: !0,
|
||||||
|
enumerable: !0,
|
||||||
|
get: function() {
|
||||||
|
return r(a), n;
|
||||||
|
},
|
||||||
|
set: function(e) {
|
||||||
|
r(a), n = e;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function a(e, t, n, a) {
|
||||||
|
e[t] = function() {
|
||||||
|
return r(a), n.apply(this, arguments);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
e.migrateVersion = "3.0.1", function() {
|
||||||
|
var r = /^[12]\./;
|
||||||
|
t.console && t.console.log && (e && !r.test(e.fn.jquery) || t.console.log("JQMIGRATE: jQuery 3.0.0+ REQUIRED"),
|
||||||
|
e.migrateWarnings && t.console.log("JQMIGRATE: Migrate plugin loaded multiple times"),
|
||||||
|
t.console.log("JQMIGRATE: Migrate is installed" + (e.migrateMute ? "" : " with logging active") + ", version " + e.migrateVersion));
|
||||||
|
}();
|
||||||
|
var o = {};
|
||||||
|
e.migrateWarnings = [], void 0 === e.migrateTrace && (e.migrateTrace = !0), e.migrateReset = function() {
|
||||||
|
o = {}, e.migrateWarnings.length = 0;
|
||||||
|
}, "BackCompat" === t.document.compatMode && r("jQuery is not compatible with Quirks Mode");
|
||||||
|
var i = e.fn.init, s = e.isNumeric, u = e.find, c = /\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/, l = /\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/g;
|
||||||
|
e.fn.init = function(e) {
|
||||||
|
var t = Array.prototype.slice.call(arguments);
|
||||||
|
return "string" == typeof e && "#" === e && (r("jQuery( '#' ) is not a valid selector"),
|
||||||
|
t[0] = []), i.apply(this, t);
|
||||||
|
}, e.fn.init.prototype = e.fn, e.find = function(e) {
|
||||||
|
var n = Array.prototype.slice.call(arguments);
|
||||||
|
if ("string" == typeof e && c.test(e)) try {
|
||||||
|
t.document.querySelector(e);
|
||||||
|
} catch (a) {
|
||||||
|
e = e.replace(l, function(e, t, r, n) {
|
||||||
|
return "[" + t + r + '"' + n + '"]';
|
||||||
|
});
|
||||||
|
try {
|
||||||
|
t.document.querySelector(e), r("Attribute selector with '#' must be quoted: " + n[0]),
|
||||||
|
n[0] = e;
|
||||||
|
} catch (e) {
|
||||||
|
r("Attribute selector with '#' was not fixed: " + n[0]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return u.apply(this, n);
|
||||||
|
};
|
||||||
|
var d;
|
||||||
|
for (d in u) Object.prototype.hasOwnProperty.call(u, d) && (e.find[d] = u[d]);
|
||||||
|
e.fn.size = function() {
|
||||||
|
return r("jQuery.fn.size() is deprecated and removed; use the .length property"),
|
||||||
|
this.length;
|
||||||
|
}, e.parseJSON = function() {
|
||||||
|
return r("jQuery.parseJSON is deprecated; use JSON.parse"), JSON.parse.apply(null, arguments);
|
||||||
|
}, e.isNumeric = function(t) {
|
||||||
|
var n = s(t), a = function(t) {
|
||||||
|
var r = t && t.toString();
|
||||||
|
return !e.isArray(t) && r - parseFloat(r) + 1 >= 0;
|
||||||
|
}(t);
|
||||||
|
return n !== a && r("jQuery.isNumeric() should not be called on constructed objects"),
|
||||||
|
a;
|
||||||
|
}, a(e, "holdReady", e.holdReady, "jQuery.holdReady is deprecated"), a(e, "unique", e.uniqueSort, "jQuery.unique is deprecated; use jQuery.uniqueSort"),
|
||||||
|
n(e.expr, "filters", e.expr.pseudos, "jQuery.expr.filters is deprecated; use jQuery.expr.pseudos"),
|
||||||
|
n(e.expr, ":", e.expr.pseudos, "jQuery.expr[':'] is deprecated; use jQuery.expr.pseudos");
|
||||||
|
var p = e.ajax;
|
||||||
|
e.ajax = function() {
|
||||||
|
var e = p.apply(this, arguments);
|
||||||
|
return e.promise && (a(e, "success", e.done, "jQXHR.success is deprecated and removed"),
|
||||||
|
a(e, "error", e.fail, "jQXHR.error is deprecated and removed"), a(e, "complete", e.always, "jQXHR.complete is deprecated and removed")),
|
||||||
|
e;
|
||||||
|
};
|
||||||
|
var f = e.fn.removeAttr, y = e.fn.toggleClass, m = /\S+/g;
|
||||||
|
e.fn.removeAttr = function(t) {
|
||||||
|
var n = this;
|
||||||
|
return e.each(t.match(m), function(t, a) {
|
||||||
|
e.expr.match.bool.test(a) && (r("jQuery.fn.removeAttr no longer sets boolean properties: " + a),
|
||||||
|
n.prop(a, !1));
|
||||||
|
}), f.apply(this, arguments);
|
||||||
|
}, e.fn.toggleClass = function(t) {
|
||||||
|
return void 0 !== t && "boolean" != typeof t ? y.apply(this, arguments) : (r("jQuery.fn.toggleClass( boolean ) is deprecated"),
|
||||||
|
this.each(function() {
|
||||||
|
var r = this.getAttribute && this.getAttribute("class") || "";
|
||||||
|
r && e.data(this, "__className__", r), this.setAttribute && this.setAttribute("class", r || !1 === t ? "" : e.data(this, "__className__") || "");
|
||||||
|
}));
|
||||||
|
};
|
||||||
|
var h = !1;
|
||||||
|
e.swap && e.each([ "height", "width", "reliableMarginRight" ], function(t, r) {
|
||||||
|
var n = e.cssHooks[r] && e.cssHooks[r].get;
|
||||||
|
n && (e.cssHooks[r].get = function() {
|
||||||
|
var e;
|
||||||
|
return h = !0, e = n.apply(this, arguments), h = !1, e;
|
||||||
|
});
|
||||||
|
}), e.swap = function(e, t, n, a) {
|
||||||
|
var o, i, s = {};
|
||||||
|
h || r("jQuery.swap() is undocumented and deprecated");
|
||||||
|
for (i in t) s[i] = e.style[i], e.style[i] = t[i];
|
||||||
|
o = n.apply(e, a || []);
|
||||||
|
for (i in t) e.style[i] = s[i];
|
||||||
|
return o;
|
||||||
|
};
|
||||||
|
var g = e.data;
|
||||||
|
e.data = function(t, n, a) {
|
||||||
|
var o;
|
||||||
|
if (n && "object" == typeof n && 2 === arguments.length) {
|
||||||
|
o = e.hasData(t) && g.call(this, t);
|
||||||
|
var i = {};
|
||||||
|
for (var s in n) s !== e.camelCase(s) ? (r("jQuery.data() always sets/gets camelCased names: " + s),
|
||||||
|
o[s] = n[s]) : i[s] = n[s];
|
||||||
|
return g.call(this, t, i), n;
|
||||||
|
}
|
||||||
|
return n && "string" == typeof n && n !== e.camelCase(n) && (o = e.hasData(t) && g.call(this, t)) && n in o ? (r("jQuery.data() always sets/gets camelCased names: " + n),
|
||||||
|
arguments.length > 2 && (o[n] = a), o[n]) : g.apply(this, arguments);
|
||||||
|
};
|
||||||
|
var v = e.Tween.prototype.run, j = function(e) {
|
||||||
|
return e;
|
||||||
|
};
|
||||||
|
e.Tween.prototype.run = function() {
|
||||||
|
e.easing[this.easing].length > 1 && (r("'jQuery.easing." + this.easing.toString() + "' should use only one argument"),
|
||||||
|
e.easing[this.easing] = j), v.apply(this, arguments);
|
||||||
|
}, e.fx.interval = e.fx.interval || 13, t.requestAnimationFrame && n(e.fx, "interval", e.fx.interval, "jQuery.fx.interval is deprecated");
|
||||||
|
var Q = e.fn.load, b = e.event.add, w = e.event.fix;
|
||||||
|
e.event.props = [], e.event.fixHooks = {}, n(e.event.props, "concat", e.event.props.concat, "jQuery.event.props.concat() is deprecated and removed"),
|
||||||
|
e.event.fix = function(t) {
|
||||||
|
var n, a = t.type, o = this.fixHooks[a], i = e.event.props;
|
||||||
|
if (i.length) for (r("jQuery.event.props are deprecated and removed: " + i.join()); i.length; ) e.event.addProp(i.pop());
|
||||||
|
if (o && !o._migrated_ && (o._migrated_ = !0, r("jQuery.event.fixHooks are deprecated and removed: " + a),
|
||||||
|
(i = o.props) && i.length)) for (;i.length; ) e.event.addProp(i.pop());
|
||||||
|
return n = w.call(this, t), o && o.filter ? o.filter(n, t) : n;
|
||||||
|
}, e.event.add = function(e, n) {
|
||||||
|
return e === t && "load" === n && "complete" === t.document.readyState && r("jQuery(window).on('load'...) called after load event occurred"),
|
||||||
|
b.apply(this, arguments);
|
||||||
|
}, e.each([ "load", "unload", "error" ], function(t, n) {
|
||||||
|
e.fn[n] = function() {
|
||||||
|
var e = Array.prototype.slice.call(arguments, 0);
|
||||||
|
return "load" === n && "string" == typeof e[0] ? Q.apply(this, e) : (r("jQuery.fn." + n + "() is deprecated"),
|
||||||
|
e.splice(0, 0, n), arguments.length ? this.on.apply(this, e) : (this.triggerHandler.apply(this, e),
|
||||||
|
this));
|
||||||
|
};
|
||||||
|
}), e.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "), function(t, n) {
|
||||||
|
e.fn[n] = function(e, t) {
|
||||||
|
return r("jQuery.fn." + n + "() event shorthand is deprecated"), arguments.length > 0 ? this.on(n, null, e, t) : this.trigger(n);
|
||||||
|
};
|
||||||
|
}), e(function() {
|
||||||
|
e(t.document).triggerHandler("ready");
|
||||||
|
}), e.event.special.ready = {
|
||||||
|
setup: function() {
|
||||||
|
this === t.document && r("'ready' event is deprecated");
|
||||||
|
}
|
||||||
|
}, e.fn.extend({
|
||||||
|
bind: function(e, t, n) {
|
||||||
|
return r("jQuery.fn.bind() is deprecated"), this.on(e, null, t, n);
|
||||||
|
},
|
||||||
|
unbind: function(e, t) {
|
||||||
|
return r("jQuery.fn.unbind() is deprecated"), this.off(e, null, t);
|
||||||
|
},
|
||||||
|
delegate: function(e, t, n, a) {
|
||||||
|
return r("jQuery.fn.delegate() is deprecated"), this.on(t, e, n, a);
|
||||||
|
},
|
||||||
|
undelegate: function(e, t, n) {
|
||||||
|
return r("jQuery.fn.undelegate() is deprecated"), 1 === arguments.length ? this.off(e, "**") : this.off(t, e || "**", n);
|
||||||
|
},
|
||||||
|
hover: function(e, t) {
|
||||||
|
return r("jQuery.fn.hover() is deprecated"), this.on("mouseenter", e).on("mouseleave", t || e);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
var x = e.fn.offset;
|
||||||
|
e.fn.offset = function() {
|
||||||
|
var n, a = this[0], o = {
|
||||||
|
top: 0,
|
||||||
|
left: 0
|
||||||
|
};
|
||||||
|
return a && a.nodeType ? (n = (a.ownerDocument || t.document).documentElement, e.contains(n, a) ? x.apply(this, arguments) : (r("jQuery.fn.offset() requires an element connected to a document"),
|
||||||
|
o)) : (r("jQuery.fn.offset() requires a valid DOM element"), o);
|
||||||
|
};
|
||||||
|
var k = e.param;
|
||||||
|
e.param = function(t, n) {
|
||||||
|
var a = e.ajaxSettings && e.ajaxSettings.traditional;
|
||||||
|
return void 0 === n && a && (r("jQuery.param() no longer uses jQuery.ajaxSettings.traditional"),
|
||||||
|
n = a), k.call(this, t, n);
|
||||||
|
};
|
||||||
|
var A = e.fn.andSelf || e.fn.addBack;
|
||||||
|
e.fn.andSelf = function() {
|
||||||
|
return r("jQuery.fn.andSelf() is deprecated and removed, use jQuery.fn.addBack()"),
|
||||||
|
A.apply(this, arguments);
|
||||||
|
};
|
||||||
|
var S = e.Deferred, q = [ [ "resolve", "done", e.Callbacks("once memory"), e.Callbacks("once memory"), "resolved" ], [ "reject", "fail", e.Callbacks("once memory"), e.Callbacks("once memory"), "rejected" ], [ "notify", "progress", e.Callbacks("memory"), e.Callbacks("memory") ] ];
|
||||||
|
return e.Deferred = function(t) {
|
||||||
|
var n = S(), a = n.promise();
|
||||||
|
return n.pipe = a.pipe = function() {
|
||||||
|
var t = arguments;
|
||||||
|
return r("deferred.pipe() is deprecated"), e.Deferred(function(r) {
|
||||||
|
e.each(q, function(o, i) {
|
||||||
|
var s = e.isFunction(t[o]) && t[o];
|
||||||
|
n[i[1]](function() {
|
||||||
|
var t = s && s.apply(this, arguments);
|
||||||
|
t && e.isFunction(t.promise) ? t.promise().done(r.resolve).fail(r.reject).progress(r.notify) : r[i[0] + "With"](this === a ? r.promise() : this, s ? [ t ] : arguments);
|
||||||
|
});
|
||||||
|
}), t = null;
|
||||||
|
}).promise();
|
||||||
|
}, t && t.call(n, n), n;
|
||||||
|
}, e.Deferred.exceptionHook = S.exceptionHook, e;
|
||||||
|
});
|
||||||
|
|
@ -0,0 +1,447 @@
|
||||||
|
/*!
|
||||||
|
|
||||||
|
Copyright (c) 2011 Peter van der Spek
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in
|
||||||
|
all copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
|
THE SOFTWARE.
|
||||||
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
(function($) {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Hash containing mapping of selectors to settings hashes for target selectors that should be live updated.
|
||||||
|
*
|
||||||
|
* @type {Object.<string, Object>}
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
var liveUpdatingTargetSelectors = {};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Interval ID for live updater. Contains interval ID when the live updater interval is active, or is undefined
|
||||||
|
* otherwise.
|
||||||
|
*
|
||||||
|
* @type {number}
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
var liveUpdaterIntervalId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Boolean indicating whether the live updater is running.
|
||||||
|
*
|
||||||
|
* @type {boolean}
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
var liveUpdaterRunning = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set of default settings.
|
||||||
|
*
|
||||||
|
* @type {Object.<string, string>}
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
var defaultSettings = {
|
||||||
|
ellipsis: '...',
|
||||||
|
setTitle: 'never',
|
||||||
|
live: false
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Perform ellipsis on selected elements.
|
||||||
|
*
|
||||||
|
* @param {string} selector the inner selector of elements that ellipsis may work on. Inner elements not referred to by this
|
||||||
|
* selector are left untouched.
|
||||||
|
* @param {Object.<string, string>=} options optional options to override default settings.
|
||||||
|
* @return {jQuery} the current jQuery object for chaining purposes.
|
||||||
|
* @this {jQuery} the current jQuery object.
|
||||||
|
*/
|
||||||
|
$.fn.ellipsis = function(selector, options) {
|
||||||
|
var subjectElements, settings;
|
||||||
|
|
||||||
|
subjectElements = $(this);
|
||||||
|
|
||||||
|
// Check for options argument only.
|
||||||
|
if (typeof selector !== 'string') {
|
||||||
|
options = selector;
|
||||||
|
selector = undefined;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Create the settings from the given options and the default settings.
|
||||||
|
settings = $.extend({}, defaultSettings, options);
|
||||||
|
|
||||||
|
// If selector is not set, work on immediate children (default behaviour).
|
||||||
|
settings.selector = selector;
|
||||||
|
|
||||||
|
// Do ellipsis on each subject element.
|
||||||
|
subjectElements.each(function() {
|
||||||
|
var elem = $(this);
|
||||||
|
|
||||||
|
// Do ellipsis on subject element.
|
||||||
|
ellipsisOnElement(elem, settings);
|
||||||
|
});
|
||||||
|
|
||||||
|
// If live option is enabled, add subject elements to live updater. Otherwise remove from live updater.
|
||||||
|
if (settings.live) {
|
||||||
|
addToLiveUpdater(subjectElements.selector, settings);
|
||||||
|
|
||||||
|
} else {
|
||||||
|
removeFromLiveUpdater(subjectElements.selector);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Return jQuery object for chaining.
|
||||||
|
return this;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Perform ellipsis on the given container.
|
||||||
|
*
|
||||||
|
* @param {jQuery} containerElement jQuery object containing one DOM element to perform ellipsis on.
|
||||||
|
* @param {Object.<string, string>} settings the settings for this ellipsis operation.
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
function ellipsisOnElement(containerElement, settings) {
|
||||||
|
var containerData = containerElement.data('jqae');
|
||||||
|
if (!containerData) containerData = {};
|
||||||
|
|
||||||
|
// Check if wrapper div was already created and bound to the container element.
|
||||||
|
var wrapperElement = containerData.wrapperElement;
|
||||||
|
|
||||||
|
// If not, create wrapper element.
|
||||||
|
if (!wrapperElement) {
|
||||||
|
wrapperElement = containerElement.wrapInner('<div/>').find('>div');
|
||||||
|
|
||||||
|
// Wrapper div should not add extra size.
|
||||||
|
wrapperElement.css({
|
||||||
|
margin: 0,
|
||||||
|
padding: 0,
|
||||||
|
border: 0
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// Check if the original wrapper element content was already bound to the wrapper element.
|
||||||
|
var wrapperElementData = wrapperElement.data('jqae');
|
||||||
|
if (!wrapperElementData) wrapperElementData = {};
|
||||||
|
|
||||||
|
var wrapperOriginalContent = wrapperElementData.originalContent;
|
||||||
|
|
||||||
|
// If so, clone the original content, re-bind the original wrapper content to the clone, and replace the
|
||||||
|
// wrapper with the clone.
|
||||||
|
if (wrapperOriginalContent) {
|
||||||
|
wrapperElement = wrapperElementData.originalContent.clone(true)
|
||||||
|
.data('jqae', {originalContent: wrapperOriginalContent}).replaceAll(wrapperElement);
|
||||||
|
|
||||||
|
} else {
|
||||||
|
// Otherwise, clone the current wrapper element and bind it as original content to the wrapper element.
|
||||||
|
|
||||||
|
wrapperElement.data('jqae', {originalContent: wrapperElement.clone(true)});
|
||||||
|
}
|
||||||
|
|
||||||
|
// Bind the wrapper element and current container width and height to the container element. Current container
|
||||||
|
// width and height are stored to detect changes to the container size.
|
||||||
|
containerElement.data('jqae', {
|
||||||
|
wrapperElement: wrapperElement,
|
||||||
|
containerWidth: containerElement.width(),
|
||||||
|
containerHeight: containerElement.height()
|
||||||
|
});
|
||||||
|
|
||||||
|
// Calculate with current container element height.
|
||||||
|
var containerElementHeight = containerElement.height();
|
||||||
|
|
||||||
|
// Calculate wrapper offset.
|
||||||
|
var wrapperOffset = (parseInt(containerElement.css('padding-top'), 10) || 0) + (parseInt(containerElement.css('border-top-width'), 10) || 0) - (wrapperElement.offset().top - containerElement.offset().top);
|
||||||
|
|
||||||
|
// Normally the ellipsis characters are applied to the last non-empty text-node in the selected element. If the
|
||||||
|
// selected element becomes empty during ellipsis iteration, the ellipsis characters cannot be applied to that
|
||||||
|
// selected element, and must be deferred to the previous selected element. This parameter keeps track of that.
|
||||||
|
var deferAppendEllipsis = false;
|
||||||
|
|
||||||
|
// Loop through all selected elements in reverse order.
|
||||||
|
var selectedElements = wrapperElement;
|
||||||
|
if (settings.selector) selectedElements = $(wrapperElement.find(settings.selector).get().reverse());
|
||||||
|
|
||||||
|
selectedElements.each(function() {
|
||||||
|
var selectedElement = $(this),
|
||||||
|
originalText = selectedElement.text(),
|
||||||
|
ellipsisApplied = false;
|
||||||
|
|
||||||
|
// Check if we can safely remove the selected element. This saves a lot of unnecessary iterations.
|
||||||
|
if (wrapperElement.innerHeight() - selectedElement.innerHeight() > containerElementHeight + wrapperOffset) {
|
||||||
|
selectedElement.remove();
|
||||||
|
|
||||||
|
} else {
|
||||||
|
// Reverse recursively remove empty elements, until the element that contains a non-empty text-node.
|
||||||
|
removeLastEmptyElements(selectedElement);
|
||||||
|
|
||||||
|
// If the selected element has not become empty, start ellipsis iterations on the selected element.
|
||||||
|
if (selectedElement.contents().length) {
|
||||||
|
|
||||||
|
// If a deffered ellipsis is still pending, apply it now to the last text-node.
|
||||||
|
if (deferAppendEllipsis) {
|
||||||
|
getLastTextNode(selectedElement).get(0).nodeValue += settings.ellipsis;
|
||||||
|
deferAppendEllipsis = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Iterate until wrapper element height is less than or equal to the original container element
|
||||||
|
// height plus possible wrapperOffset.
|
||||||
|
while (wrapperElement.innerHeight() > containerElementHeight + wrapperOffset) {
|
||||||
|
// Apply ellipsis on last text node, by removing one word.
|
||||||
|
ellipsisApplied = ellipsisOnLastTextNode(selectedElement);
|
||||||
|
|
||||||
|
// If ellipsis was succesfully applied, remove any remaining empty last elements and append the
|
||||||
|
// ellipsis characters.
|
||||||
|
if (ellipsisApplied) {
|
||||||
|
removeLastEmptyElements(selectedElement);
|
||||||
|
|
||||||
|
// If the selected element is not empty, append the ellipsis characters.
|
||||||
|
if (selectedElement.contents().length) {
|
||||||
|
getLastTextNode(selectedElement).get(0).nodeValue += settings.ellipsis;
|
||||||
|
|
||||||
|
} else {
|
||||||
|
// If the selected element has become empty, defer the appending of the ellipsis characters
|
||||||
|
// to the previous selected element.
|
||||||
|
deferAppendEllipsis = true;
|
||||||
|
selectedElement.remove();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
// If ellipsis could not be applied, defer the appending of the ellipsis characters to the
|
||||||
|
// previous selected element.
|
||||||
|
deferAppendEllipsis = true;
|
||||||
|
selectedElement.remove();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// If the "setTitle" property is set to "onEllipsis" and the ellipsis has been applied, or if the
|
||||||
|
// property is set to "always", the add the "title" attribute with the original text. Else remove the
|
||||||
|
// "title" attribute. When the "setTitle" property is set to "never" we do not touch the "title"
|
||||||
|
// attribute.
|
||||||
|
if (((settings.setTitle == 'onEllipsis') && ellipsisApplied) || (settings.setTitle == 'always')) {
|
||||||
|
selectedElement.attr('title', originalText);
|
||||||
|
|
||||||
|
} else if (settings.setTitle != 'never') {
|
||||||
|
selectedElement.removeAttr('title');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Performs ellipsis on the last text node of the given element. Ellipsis is done by removing a full word.
|
||||||
|
*
|
||||||
|
* @param {jQuery} element jQuery object containing a single DOM element.
|
||||||
|
* @return {boolean} true when ellipsis has been done, false otherwise.
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
function ellipsisOnLastTextNode(element) {
|
||||||
|
var lastTextNode = getLastTextNode(element);
|
||||||
|
|
||||||
|
// If the last text node is found, do ellipsis on that node.
|
||||||
|
if (lastTextNode.length) {
|
||||||
|
var text = lastTextNode.get(0).nodeValue;
|
||||||
|
|
||||||
|
// Find last space character, and remove text from there. If no space is found the full remaining text is
|
||||||
|
// removed.
|
||||||
|
var pos = text.lastIndexOf(' ');
|
||||||
|
if (pos > -1) {
|
||||||
|
text = $.trim(text.substring(0, pos));
|
||||||
|
lastTextNode.get(0).nodeValue = text;
|
||||||
|
|
||||||
|
} else {
|
||||||
|
lastTextNode.get(0).nodeValue = '';
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get last text node of the given element.
|
||||||
|
*
|
||||||
|
* @param {jQuery} element jQuery object containing a single element.
|
||||||
|
* @return {jQuery} jQuery object containing a single text node.
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
function getLastTextNode(element) {
|
||||||
|
if (element.contents().length) {
|
||||||
|
|
||||||
|
// Get last child node.
|
||||||
|
var contents = element.contents();
|
||||||
|
var lastNode = contents.eq(contents.length - 1);
|
||||||
|
|
||||||
|
// If last node is a text node, return it.
|
||||||
|
if (lastNode.filter(textNodeFilter).length) {
|
||||||
|
return lastNode;
|
||||||
|
|
||||||
|
} else {
|
||||||
|
// Else it is an element node, and we recurse into it.
|
||||||
|
|
||||||
|
return getLastTextNode(lastNode);
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
// If there is no last child node, we append an empty text node and return that. Normally this should not
|
||||||
|
// happen, as we test for emptiness before calling getLastTextNode.
|
||||||
|
|
||||||
|
element.append('');
|
||||||
|
var contents = element.contents();
|
||||||
|
return contents.eq(contents.length - 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Remove last empty elements. This is done recursively until the last element contains a non-empty text node.
|
||||||
|
*
|
||||||
|
* @param {jQuery} element jQuery object containing a single element.
|
||||||
|
* @return {boolean} true when elements have been removed, false otherwise.
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
function removeLastEmptyElements(element) {
|
||||||
|
if (element.contents().length) {
|
||||||
|
|
||||||
|
// Get last child node.
|
||||||
|
var contents = element.contents();
|
||||||
|
var lastNode = contents.eq(contents.length - 1);
|
||||||
|
|
||||||
|
// If last child node is a text node, check for emptiness.
|
||||||
|
if (lastNode.filter(textNodeFilter).length) {
|
||||||
|
var text = lastNode.get(0).nodeValue;
|
||||||
|
text = $.trim(text);
|
||||||
|
|
||||||
|
if (text == '') {
|
||||||
|
// If empty, remove the text node.
|
||||||
|
lastNode.remove();
|
||||||
|
|
||||||
|
return true;
|
||||||
|
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
// If the last child node is an element node, remove the last empty child nodes on that node.
|
||||||
|
while (removeLastEmptyElements(lastNode)) {
|
||||||
|
}
|
||||||
|
|
||||||
|
// If the last child node contains no more child nodes, remove the last child node.
|
||||||
|
if (lastNode.contents().length) {
|
||||||
|
return false;
|
||||||
|
|
||||||
|
} else {
|
||||||
|
lastNode.remove();
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Filter for testing on text nodes.
|
||||||
|
*
|
||||||
|
* @return {boolean} true when this node is a text node, false otherwise.
|
||||||
|
* @this {Node}
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
function textNodeFilter() {
|
||||||
|
return this.nodeType === 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Add target selector to hash of target selectors. If this is the first target selector added, start the live
|
||||||
|
* updater.
|
||||||
|
*
|
||||||
|
* @param {string} targetSelector the target selector to run the live updater for.
|
||||||
|
* @param {Object.<string, string>} settings the settings to apply on this target selector.
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
function addToLiveUpdater(targetSelector, settings) {
|
||||||
|
// Store target selector with its settings.
|
||||||
|
liveUpdatingTargetSelectors[targetSelector] = settings;
|
||||||
|
|
||||||
|
// If the live updater has not yet been started, start it now.
|
||||||
|
if (!liveUpdaterIntervalId) {
|
||||||
|
liveUpdaterIntervalId = window.setInterval(function() {
|
||||||
|
doLiveUpdater();
|
||||||
|
}, 200);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Remove the target selector from the hash of target selectors. It this is the last remaining target selector
|
||||||
|
* being removed, stop the live updater.
|
||||||
|
*
|
||||||
|
* @param {string} targetSelector the target selector to stop running the live updater for.
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
function removeFromLiveUpdater(targetSelector) {
|
||||||
|
// If the hash contains the target selector, remove it.
|
||||||
|
if (liveUpdatingTargetSelectors[targetSelector]) {
|
||||||
|
delete liveUpdatingTargetSelectors[targetSelector];
|
||||||
|
|
||||||
|
// If no more target selectors are in the hash, stop the live updater.
|
||||||
|
if (!liveUpdatingTargetSelectors.length) {
|
||||||
|
if (liveUpdaterIntervalId) {
|
||||||
|
window.clearInterval(liveUpdaterIntervalId);
|
||||||
|
liveUpdaterIntervalId = undefined;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Run the live updater. The live updater is periodically run to check if its monitored target selectors require
|
||||||
|
* re-applying of the ellipsis.
|
||||||
|
*
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
function doLiveUpdater() {
|
||||||
|
// If the live updater is already running, skip this time. We only want one instance running at a time.
|
||||||
|
if (!liveUpdaterRunning) {
|
||||||
|
liveUpdaterRunning = true;
|
||||||
|
|
||||||
|
// Loop through target selectors.
|
||||||
|
for (var targetSelector in liveUpdatingTargetSelectors) {
|
||||||
|
$(targetSelector).each(function() {
|
||||||
|
var containerElement, containerData;
|
||||||
|
|
||||||
|
containerElement = $(this);
|
||||||
|
containerData = containerElement.data('jqae');
|
||||||
|
|
||||||
|
// If container element dimensions have changed, or the container element is new, run ellipsis on
|
||||||
|
// that container element.
|
||||||
|
if ((containerData.containerWidth != containerElement.width()) ||
|
||||||
|
(containerData.containerHeight != containerElement.height())) {
|
||||||
|
ellipsisOnElement(containerElement, liveUpdatingTargetSelectors[targetSelector]);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
liveUpdaterRunning = false;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
})(jQuery);
|
||||||
|
|
@ -0,0 +1,117 @@
|
||||||
|
/*!
|
||||||
|
* jQuery Cookie Plugin v1.4.1
|
||||||
|
* https://github.com/carhartl/jquery-cookie
|
||||||
|
*
|
||||||
|
* Copyright 2006, 2014 Klaus Hartl
|
||||||
|
* Released under the MIT license
|
||||||
|
*/
|
||||||
|
(function (factory) {
|
||||||
|
if (typeof define === 'function' && define.amd) {
|
||||||
|
// AMD
|
||||||
|
define(['jquery'], factory);
|
||||||
|
} else if (typeof exports === 'object') {
|
||||||
|
// CommonJS
|
||||||
|
factory(require('jquery'));
|
||||||
|
} else {
|
||||||
|
// Browser globals
|
||||||
|
factory(jQuery);
|
||||||
|
}
|
||||||
|
}(function ($) {
|
||||||
|
|
||||||
|
var pluses = /\+/g;
|
||||||
|
|
||||||
|
function encode(s) {
|
||||||
|
return config.raw ? s : encodeURIComponent(s);
|
||||||
|
}
|
||||||
|
|
||||||
|
function decode(s) {
|
||||||
|
return config.raw ? s : decodeURIComponent(s);
|
||||||
|
}
|
||||||
|
|
||||||
|
function stringifyCookieValue(value) {
|
||||||
|
return encode(config.json ? JSON.stringify(value) : String(value));
|
||||||
|
}
|
||||||
|
|
||||||
|
function parseCookieValue(s) {
|
||||||
|
if (s.indexOf('"') === 0) {
|
||||||
|
// This is a quoted cookie as according to RFC2068, unescape...
|
||||||
|
s = s.slice(1, -1).replace(/\\"/g, '"').replace(/\\\\/g, '\\');
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
// Replace server-side written pluses with spaces.
|
||||||
|
// If we can't decode the cookie, ignore it, it's unusable.
|
||||||
|
// If we can't parse the cookie, ignore it, it's unusable.
|
||||||
|
s = decodeURIComponent(s.replace(pluses, ' '));
|
||||||
|
return config.json ? JSON.parse(s) : s;
|
||||||
|
} catch(e) {}
|
||||||
|
}
|
||||||
|
|
||||||
|
function read(s, converter) {
|
||||||
|
var value = config.raw ? s : parseCookieValue(s);
|
||||||
|
return $.isFunction(converter) ? converter(value) : value;
|
||||||
|
}
|
||||||
|
|
||||||
|
var config = $.cookie = function (key, value, options) {
|
||||||
|
|
||||||
|
// Write
|
||||||
|
|
||||||
|
if (arguments.length > 1 && !$.isFunction(value)) {
|
||||||
|
options = $.extend({}, config.defaults, options);
|
||||||
|
|
||||||
|
if (typeof options.expires === 'number') {
|
||||||
|
var days = options.expires, t = options.expires = new Date();
|
||||||
|
t.setTime(+t + days * 864e+5);
|
||||||
|
}
|
||||||
|
|
||||||
|
return (document.cookie = [
|
||||||
|
encode(key), '=', stringifyCookieValue(value),
|
||||||
|
options.expires ? '; expires=' + options.expires.toUTCString() : '', // use expires attribute, max-age is not supported by IE
|
||||||
|
options.path ? '; path=' + options.path : '',
|
||||||
|
options.domain ? '; domain=' + options.domain : '',
|
||||||
|
options.secure ? '; secure' : ''
|
||||||
|
].join(''));
|
||||||
|
}
|
||||||
|
|
||||||
|
// Read
|
||||||
|
|
||||||
|
var result = key ? undefined : {};
|
||||||
|
|
||||||
|
// To prevent the for loop in the first place assign an empty array
|
||||||
|
// in case there are no cookies at all. Also prevents odd result when
|
||||||
|
// calling $.cookie().
|
||||||
|
var cookies = document.cookie ? document.cookie.split('; ') : [];
|
||||||
|
|
||||||
|
for (var i = 0, l = cookies.length; i < l; i++) {
|
||||||
|
var parts = cookies[i].split('=');
|
||||||
|
var name = decode(parts.shift());
|
||||||
|
var cookie = parts.join('=');
|
||||||
|
|
||||||
|
if (key && key === name) {
|
||||||
|
// If second argument (value) is a function it's a converter...
|
||||||
|
result = read(cookie, value);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Prevent storing a cookie that we couldn't decode.
|
||||||
|
if (!key && (cookie = read(cookie)) !== undefined) {
|
||||||
|
result[name] = cookie;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
};
|
||||||
|
|
||||||
|
config.defaults = {};
|
||||||
|
|
||||||
|
$.removeCookie = function (key, options) {
|
||||||
|
if ($.cookie(key) === undefined) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Must not alter options, thus extending a fresh object...
|
||||||
|
$.cookie(key, '', $.extend({}, options, { expires: -1 }));
|
||||||
|
return !$.cookie(key);
|
||||||
|
};
|
||||||
|
|
||||||
|
}));
|
||||||
|
|
@ -0,0 +1,82 @@
|
||||||
|
/**
|
||||||
|
* jQuery Plugin to obtain touch gestures from iPhone, iPod Touch and iPad, should also work with Android mobile phones (not tested yet!)
|
||||||
|
* Common usage: wipe images (left and right to show the previous or next image)
|
||||||
|
*
|
||||||
|
* @author Andreas Waltl, netCU Internetagentur (http://www.netcu.de)
|
||||||
|
* @version 1.1.1 (9th December 2010) - fix bug (older IE's had problems)
|
||||||
|
* @version 1.1 (1st September 2010) - support wipe up and wipe down
|
||||||
|
* @version 1.0 (15th July 2010)
|
||||||
|
*/
|
||||||
|
(function($) {
|
||||||
|
$.fn.touchwipe = function(settings) {
|
||||||
|
var config = {
|
||||||
|
min_move_x: 20,
|
||||||
|
min_move_y: 20,
|
||||||
|
wipeLeft: function() { },
|
||||||
|
wipeRight: function() { },
|
||||||
|
wipeUp: function() { },
|
||||||
|
wipeDown: function() { },
|
||||||
|
preventDefaultEvents: true
|
||||||
|
};
|
||||||
|
|
||||||
|
if (settings) $.extend(config, settings);
|
||||||
|
|
||||||
|
this.each(function() {
|
||||||
|
var startX;
|
||||||
|
var startY;
|
||||||
|
var isMoving = false;
|
||||||
|
|
||||||
|
function cancelTouch() {
|
||||||
|
this.removeEventListener('touchmove', onTouchMove);
|
||||||
|
startX = null;
|
||||||
|
isMoving = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
function onTouchMove(e) {
|
||||||
|
if(config.preventDefaultEvents) {
|
||||||
|
e.preventDefault();
|
||||||
|
}
|
||||||
|
if(isMoving) {
|
||||||
|
var x = e.touches[0].pageX;
|
||||||
|
var y = e.touches[0].pageY;
|
||||||
|
var dx = startX - x;
|
||||||
|
var dy = startY - y;
|
||||||
|
if(Math.abs(dx) >= config.min_move_x) {
|
||||||
|
cancelTouch();
|
||||||
|
if(dx > 0) {
|
||||||
|
config.wipeLeft();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
config.wipeRight();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if(Math.abs(dy) >= config.min_move_y) {
|
||||||
|
cancelTouch();
|
||||||
|
if(dy > 0) {
|
||||||
|
config.wipeDown();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
config.wipeUp();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function onTouchStart(e)
|
||||||
|
{
|
||||||
|
if (e.touches.length == 1) {
|
||||||
|
startX = e.touches[0].pageX;
|
||||||
|
startY = e.touches[0].pageY;
|
||||||
|
isMoving = true;
|
||||||
|
this.addEventListener('touchmove', onTouchMove, false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ('ontouchstart' in document.documentElement) {
|
||||||
|
this.addEventListener('touchstart', onTouchStart, false);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
return this;
|
||||||
|
};
|
||||||
|
|
||||||
|
})(jQuery);
|
||||||
|
|
@ -0,0 +1,63 @@
|
||||||
|
(function($) {
|
||||||
|
/**
|
||||||
|
* Runs functions given in arguments in series, each functions passing their results to the next one.
|
||||||
|
* Return jQuery Deferred object.
|
||||||
|
*
|
||||||
|
* @example
|
||||||
|
* $.waterfall(
|
||||||
|
* function() { return $.ajax({url : first_url}) },
|
||||||
|
* function() { return $.ajax({url : second_url}) },
|
||||||
|
* function() { return $.ajax({url : another_url}) }
|
||||||
|
*).fail(function() {
|
||||||
|
* console.log(arguments)
|
||||||
|
*).done(function() {
|
||||||
|
* console.log(arguments)
|
||||||
|
*})
|
||||||
|
*
|
||||||
|
* @example2
|
||||||
|
* event_chain = [];
|
||||||
|
* event_chain.push(function() { var deferred = $.Deferred(); deferred.resolve(); return deferred; });
|
||||||
|
* $.waterfall.apply(this, event_chain).fail(function(){}).done(function(){});
|
||||||
|
*
|
||||||
|
* @author Dmitry (dio) Levashov, dio@std42.ru
|
||||||
|
* @return jQuery.Deferred
|
||||||
|
*/
|
||||||
|
$.waterfall = function() {
|
||||||
|
var steps = [],
|
||||||
|
dfrd = $.Deferred(),
|
||||||
|
pointer = 0;
|
||||||
|
|
||||||
|
$.each(arguments, function(i, a) {
|
||||||
|
steps.push(function() {
|
||||||
|
var args = [].slice.apply(arguments), d;
|
||||||
|
|
||||||
|
if (typeof(a) == 'function') {
|
||||||
|
if (!((d = a.apply(null, args)) && d.promise)) {
|
||||||
|
d = $.Deferred()[d === false ? 'reject' : 'resolve'](d);
|
||||||
|
}
|
||||||
|
} else if (a && a.promise) {
|
||||||
|
d = a;
|
||||||
|
} else {
|
||||||
|
d = $.Deferred()[a === false ? 'reject' : 'resolve'](a);
|
||||||
|
}
|
||||||
|
|
||||||
|
d.fail(function() {
|
||||||
|
dfrd.reject.apply(dfrd, [].slice.apply(arguments));
|
||||||
|
})
|
||||||
|
.done(function(data) {
|
||||||
|
pointer++;
|
||||||
|
args.push(data);
|
||||||
|
|
||||||
|
pointer == steps.length
|
||||||
|
? dfrd.resolve.apply(dfrd, args)
|
||||||
|
: steps[pointer].apply(null, args);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
steps.length ? steps[0]() : dfrd.resolve();
|
||||||
|
|
||||||
|
return dfrd;
|
||||||
|
}
|
||||||
|
|
||||||
|
})(jQuery);
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
*.css
|
||||||
|
|
@ -0,0 +1,37 @@
|
||||||
|
//
|
||||||
|
// Custom alerts (Based on Sweet Alert)
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
.sweet-overlay {
|
||||||
|
background-color: @overlay-background;
|
||||||
|
z-index: @zindex-alert - 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sweet-alert {
|
||||||
|
text-align: right;
|
||||||
|
border-radius: @border-radius-base;
|
||||||
|
.box-shadow(@popup-box-shadow);
|
||||||
|
z-index: @zindex-alert;
|
||||||
|
|
||||||
|
h2 {
|
||||||
|
word-break: break-word;
|
||||||
|
word-wrap: break-word;
|
||||||
|
max-height: 350px;
|
||||||
|
overflow-y: auto;
|
||||||
|
|
||||||
|
margin: 10px 0 17px 0;
|
||||||
|
color: #2b3e50;
|
||||||
|
text-align: left;
|
||||||
|
font-size: 15px;
|
||||||
|
line-height: 23px;
|
||||||
|
}
|
||||||
|
|
||||||
|
p {
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
p.text-muted {
|
||||||
|
margin-bottom: 20px;
|
||||||
|
color: #555555;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,66 @@
|
||||||
|
//
|
||||||
|
// Common control styles
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
//
|
||||||
|
// The scroll panel can host a scrollbar control. It has a right border that covers
|
||||||
|
// the scrollbar to satisfy the design requirements.
|
||||||
|
//
|
||||||
|
.control-scrollpanel {
|
||||||
|
position: relative;
|
||||||
|
background: @color-panel-light;
|
||||||
|
|
||||||
|
.control-scrollbar {
|
||||||
|
&.vertical > .scrollbar-scrollbar {right: 0;}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.tooltip {
|
||||||
|
.tooltip-inner {
|
||||||
|
text-align: left;
|
||||||
|
padding: 5px 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.in {
|
||||||
|
.opacity(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Logos
|
||||||
|
//
|
||||||
|
|
||||||
|
.oc-logo-white {
|
||||||
|
background-image: url(../images/october-logo-white.svg);
|
||||||
|
background-position: 50% 50%;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-size: contain;
|
||||||
|
}
|
||||||
|
|
||||||
|
.oc-logo {
|
||||||
|
background-image: url(../images/october-logo.svg);
|
||||||
|
background-position: 50% 50%;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-size: contain;
|
||||||
|
}
|
||||||
|
|
||||||
|
.layout.control-tabs.oc-logo-transparent:not(.has-tabs),
|
||||||
|
.flex-layout-column.oc-logo-transparent:not(.has-tabs),
|
||||||
|
.layout-cell.oc-logo-transparent {
|
||||||
|
background-size: 50% auto;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-image: url(../images/october-logo.svg);
|
||||||
|
background-position: 50% 50%;
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
content: '';
|
||||||
|
display: table-cell;
|
||||||
|
position: absolute;
|
||||||
|
left: 0;
|
||||||
|
top: 0;
|
||||||
|
height: 100%;
|
||||||
|
width: 100%;
|
||||||
|
background: rgba(249,249,249,0.7);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,426 @@
|
||||||
|
//
|
||||||
|
// File list control
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
.control-filelist {
|
||||||
|
.listPaddings (@level, @offset-base) when (@level > 0) {
|
||||||
|
> li.group {
|
||||||
|
> ul {
|
||||||
|
> li > a {
|
||||||
|
padding-left: (@level+2)*@offset-base;
|
||||||
|
margin-left: -1*@level*@offset-base;
|
||||||
|
}
|
||||||
|
|
||||||
|
.listPaddings(@level - 1, @offset-base);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.listPaddings (0, 27px) {}
|
||||||
|
|
||||||
|
p.no-data {
|
||||||
|
padding: 22px 0;
|
||||||
|
margin: 0;
|
||||||
|
color: @color-filelist-norecords-text;
|
||||||
|
font-size: @font-size-base;
|
||||||
|
text-align: center;
|
||||||
|
font-weight: normal;
|
||||||
|
.border-radius(@border-radius-base);
|
||||||
|
}
|
||||||
|
|
||||||
|
ul {
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
|
||||||
|
li {
|
||||||
|
font-weight: normal;
|
||||||
|
line-height: 150%;
|
||||||
|
position: relative;
|
||||||
|
list-style: none;
|
||||||
|
|
||||||
|
a:hover {
|
||||||
|
background: @color-list-hover;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.active > a {
|
||||||
|
background: @color-list-active;
|
||||||
|
position: relative;
|
||||||
|
&:after {
|
||||||
|
position: absolute;
|
||||||
|
height: 100%;
|
||||||
|
width: 4px;
|
||||||
|
left: 0;
|
||||||
|
top: 0;
|
||||||
|
background: @color-list-active-border;
|
||||||
|
display: block;
|
||||||
|
content: ' ';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
a {
|
||||||
|
display: block;
|
||||||
|
padding: 10px 45px 10px 20px;
|
||||||
|
outline: none;
|
||||||
|
|
||||||
|
&:hover, &:focus, &:active {text-decoration: none;}
|
||||||
|
|
||||||
|
span {
|
||||||
|
display: block;
|
||||||
|
|
||||||
|
&.title {
|
||||||
|
font-weight: normal;
|
||||||
|
color: @color-text-title;
|
||||||
|
font-size: @font-size-base;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.description {
|
||||||
|
color: @color-text-description;
|
||||||
|
font-size: @font-size-base - 2;
|
||||||
|
white-space: nowrap;
|
||||||
|
font-weight: normal;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
|
||||||
|
strong {
|
||||||
|
color: @color-text-title;
|
||||||
|
font-weight: normal;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.group {
|
||||||
|
> h4, > div.group > h4 {
|
||||||
|
font-weight: normal;
|
||||||
|
font-size: @font-size-base;
|
||||||
|
margin-top: 0;
|
||||||
|
margin-bottom: 0;
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
a {
|
||||||
|
padding: 10px 20px 10px 53px;
|
||||||
|
color: @color-text-title;
|
||||||
|
position: relative;
|
||||||
|
outline: none;
|
||||||
|
|
||||||
|
&:hover { background: transparent; }
|
||||||
|
|
||||||
|
&:before, &:after {
|
||||||
|
width: 10px;
|
||||||
|
height: 10px;
|
||||||
|
display: block;
|
||||||
|
position: absolute;
|
||||||
|
top: 1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
left: 33px;
|
||||||
|
top: 9px;
|
||||||
|
.icon(@folder);
|
||||||
|
color: @color-list-icon;
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
left: 20px;
|
||||||
|
top: 9px;
|
||||||
|
color: @color-list-arrow;
|
||||||
|
.icon(@caret-right);
|
||||||
|
.transform( ~'rotate(90deg) translate(5px, 0)' );
|
||||||
|
.transition(all 0.1s ease);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> ul {
|
||||||
|
> li > a {
|
||||||
|
padding-left: 52px;
|
||||||
|
}
|
||||||
|
|
||||||
|
> li.group {
|
||||||
|
padding-left: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.listPaddings(10, 27px);
|
||||||
|
}
|
||||||
|
|
||||||
|
&[data-status=collapsed] {
|
||||||
|
> h4 a:before, > div.group > h4 a:before {
|
||||||
|
.transform(~'rotate(0deg) translate(3px, 0)');
|
||||||
|
}
|
||||||
|
|
||||||
|
& > ul, & > div.subitems {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> div.controls {
|
||||||
|
position: absolute;
|
||||||
|
right: 19px;
|
||||||
|
top: 6px;
|
||||||
|
|
||||||
|
.dropdown {
|
||||||
|
width: 14px;
|
||||||
|
height: 21px;
|
||||||
|
|
||||||
|
&.open a.control {
|
||||||
|
display: block!important;
|
||||||
|
&:before {
|
||||||
|
visibility: visible;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
a.control {
|
||||||
|
color: @color-text-title;
|
||||||
|
font-size: @font-size-base;
|
||||||
|
visibility: hidden;
|
||||||
|
overflow: hidden;
|
||||||
|
width: 14px;
|
||||||
|
height: 21px;
|
||||||
|
display: none;
|
||||||
|
text-decoration: none;
|
||||||
|
cursor: pointer;
|
||||||
|
padding: 0;
|
||||||
|
.opacity(0.5);
|
||||||
|
&:before {
|
||||||
|
visibility: visible;
|
||||||
|
display: block;
|
||||||
|
margin-right: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
.opacity(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
> div.controls, > a.control {
|
||||||
|
display: block!important;
|
||||||
|
|
||||||
|
> a.control {
|
||||||
|
display: block!important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.checkbox {
|
||||||
|
position: absolute;
|
||||||
|
top: -5px;
|
||||||
|
right: 0;
|
||||||
|
|
||||||
|
label {
|
||||||
|
margin-right: 0;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
border-color: @color-filelist-cb-border;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.single-line {
|
||||||
|
ul {
|
||||||
|
li a span.title {
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
overflow: hidden;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Templates have emphasis
|
||||||
|
//
|
||||||
|
|
||||||
|
&.filelist-hero {
|
||||||
|
.a-hover() {
|
||||||
|
background: @color-filelist-hero-hover-bg;
|
||||||
|
border-bottom: 1px solid @color-filelist-hero-hover-bg !important;
|
||||||
|
span.title, span.description {
|
||||||
|
color: @color-filelist-hero-hover-text !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.list-icon {
|
||||||
|
color: @color-filelist-hero-hover-text !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.a-active() {
|
||||||
|
background: @color-filelist-hero-active-bg;
|
||||||
|
border-bottom: 1px solid @color-filelist-hero-active-bg !important;
|
||||||
|
span.title, span.description {
|
||||||
|
color: @color-filelist-hero-active-text !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.list-icon {
|
||||||
|
color: @color-filelist-hero-active-text !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
ul {
|
||||||
|
li {
|
||||||
|
background: @color-filelist-hero-item-bg;
|
||||||
|
border-bottom: none;
|
||||||
|
|
||||||
|
> a {
|
||||||
|
padding: 11px 45px 10px 50px;
|
||||||
|
font-size: @font-size-base - 1;
|
||||||
|
border-bottom: 1px solid @color-panel-light;
|
||||||
|
|
||||||
|
span.title {
|
||||||
|
font-size: @font-size-base;
|
||||||
|
font-weight: normal;
|
||||||
|
color: @color-filelist-title-hero;
|
||||||
|
}
|
||||||
|
|
||||||
|
span.description {
|
||||||
|
font-size: @font-size-base - 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.list-icon {
|
||||||
|
position: absolute;
|
||||||
|
left: 14px;
|
||||||
|
top: 15px;
|
||||||
|
font-size: 22px;
|
||||||
|
color: #b7c0c2;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
.a-hover();
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active {
|
||||||
|
.a-active();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.checkbox {
|
||||||
|
top: -2px;
|
||||||
|
right: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.active {
|
||||||
|
> a {
|
||||||
|
border-bottom: 1px solid @color-list-active;
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
top: -1px;
|
||||||
|
bottom: -1px;
|
||||||
|
height: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
> span.borders {
|
||||||
|
&:before {
|
||||||
|
content: ' ';
|
||||||
|
position: absolute;
|
||||||
|
width: 100%;
|
||||||
|
height: 1px;
|
||||||
|
display: block;
|
||||||
|
left: 0;
|
||||||
|
background-color: @color-list-active;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before {top: -1px;}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover > span.borders:before {
|
||||||
|
background-color: @color-filelist-hero-hover-bg;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active > span.borders:before {
|
||||||
|
background-color: @color-filelist-hero-active-bg;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> h4 {
|
||||||
|
padding-top: 7px;
|
||||||
|
padding-bottom: 6px;
|
||||||
|
border-bottom: 1px solid @color-panel-light;
|
||||||
|
}
|
||||||
|
|
||||||
|
> div.controls {
|
||||||
|
display: none;
|
||||||
|
position: absolute;
|
||||||
|
right: 16px;
|
||||||
|
top: 15px;
|
||||||
|
|
||||||
|
> a.control {
|
||||||
|
width: 16px;
|
||||||
|
height: 23px;
|
||||||
|
background: transparent;
|
||||||
|
overflow: hidden;
|
||||||
|
display: inline-block;
|
||||||
|
color: @color-filelist-hero-hover-text!important;
|
||||||
|
padding: 0;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
font-size: 17px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover > div.controls {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.separator {
|
||||||
|
position: relative;
|
||||||
|
border-bottom: 1px solid #95a5a6;
|
||||||
|
padding: 12px 15px 13px 15px;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
z-index: 31;
|
||||||
|
.triangle(down, 19px, 11px, white);
|
||||||
|
position: absolute;
|
||||||
|
left: 13px;
|
||||||
|
bottom: -8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
z-index: 30;
|
||||||
|
.triangle(down, 17px, 9px, #95a5a6);
|
||||||
|
position: absolute;
|
||||||
|
left: 14px;
|
||||||
|
bottom: -9px;
|
||||||
|
}
|
||||||
|
|
||||||
|
h5 {
|
||||||
|
color: #2b3e50;
|
||||||
|
font-size: @font-size-base;
|
||||||
|
margin: 0;
|
||||||
|
font-weight: normal;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> li.group {
|
||||||
|
> ul > li > a {
|
||||||
|
padding-left: 66px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.single-level {
|
||||||
|
ul li:hover {
|
||||||
|
background: @color-filelist-hero-hover-bg;
|
||||||
|
|
||||||
|
> a {
|
||||||
|
.a-hover();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
ul li:active {
|
||||||
|
background: @color-filelist-hero-active-bg;
|
||||||
|
|
||||||
|
> a {
|
||||||
|
.a-active();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,27 @@
|
||||||
|
table.name-value-list {
|
||||||
|
border-collapse: collapse;
|
||||||
|
font-size: 13px;
|
||||||
|
|
||||||
|
th, td {
|
||||||
|
padding: 4px 0 4px 0;
|
||||||
|
vertical-align: top;
|
||||||
|
}
|
||||||
|
|
||||||
|
tr:first-child {
|
||||||
|
th, td {
|
||||||
|
padding-top: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
th {
|
||||||
|
font-weight: 600;
|
||||||
|
color: #95a5a6;
|
||||||
|
padding-right: 15px;
|
||||||
|
text-transform: uppercase;
|
||||||
|
}
|
||||||
|
|
||||||
|
td {
|
||||||
|
color: #2b3e50;
|
||||||
|
word-wrap: break-word;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,77 @@
|
||||||
|
div.panel {
|
||||||
|
@panel-border-color: #e8eaeb;
|
||||||
|
|
||||||
|
padding: 20px;
|
||||||
|
|
||||||
|
&.no-padding {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.no-padding-bottom {
|
||||||
|
padding-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.padding-top {
|
||||||
|
padding-top: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.padding-less {
|
||||||
|
padding: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.transparent {
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.border-left {
|
||||||
|
border-left: 1px solid @panel-border-color;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.border-right {
|
||||||
|
border-right: 1px solid @panel-border-color;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.border-bottom {
|
||||||
|
border-bottom: 1px solid @panel-border-color;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.border-top {
|
||||||
|
border-top: 1px solid @panel-border-color;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.triangle-down {
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
.triangle(down, 15px, 8px, white);
|
||||||
|
position: absolute;
|
||||||
|
left: 15px;
|
||||||
|
bottom: -8px;
|
||||||
|
z-index: 101;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
.triangle(down, 17px, 9px, #e8eaeb);
|
||||||
|
position: absolute;
|
||||||
|
left: 14px;
|
||||||
|
bottom: -9px;
|
||||||
|
z-index: 100;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Panel sections
|
||||||
|
*/
|
||||||
|
|
||||||
|
h3.section, > label {
|
||||||
|
text-transform: uppercase;
|
||||||
|
color: #95a5a6;
|
||||||
|
font-size: 13px;
|
||||||
|
font-weight: 600;
|
||||||
|
margin: 0 0 15px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
> label {
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,51 @@
|
||||||
|
.report-widget {
|
||||||
|
padding: 15px;
|
||||||
|
background: white;
|
||||||
|
.box-sizing(border-box);
|
||||||
|
.border-radius(@border-radius-base);
|
||||||
|
font-size: @font-size-base - 1;
|
||||||
|
|
||||||
|
h3 {
|
||||||
|
font-size: @font-size-base;
|
||||||
|
color: @color-report-widget-title;
|
||||||
|
text-transform: uppercase;
|
||||||
|
font-weight: 600;
|
||||||
|
margin-top: 0;
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.height-100 { height: 100px; }
|
||||||
|
.height-200 { height: 200px; }
|
||||||
|
.height-300 { height: 300px; }
|
||||||
|
.height-400 { height: 400px; }
|
||||||
|
.height-500 { height: 500px; }
|
||||||
|
|
||||||
|
p.report-description {
|
||||||
|
margin-bottom: 0;
|
||||||
|
margin-top: 15px;
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 190%;
|
||||||
|
color: @color-report-widget-description;
|
||||||
|
}
|
||||||
|
|
||||||
|
a:not(.btn) {
|
||||||
|
color: @color-report-widget-link;
|
||||||
|
text-decoration: none;
|
||||||
|
&:hover {
|
||||||
|
color: @link-color;
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
p.flash-message.static {
|
||||||
|
margin-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-circle {
|
||||||
|
&.success { color: @brand-success; }
|
||||||
|
&.primary { color: @brand-primary; }
|
||||||
|
&.warning { color: @brand-warning; }
|
||||||
|
&.danger { color: @brand-danger; }
|
||||||
|
&.info { color: @brand-info; }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,125 @@
|
||||||
|
//
|
||||||
|
// Scrollbar
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
.drag-noselect {
|
||||||
|
.user-select(none);
|
||||||
|
}
|
||||||
|
|
||||||
|
@scrollbar-thumb-size: 6px;
|
||||||
|
|
||||||
|
.control-scrollbar {
|
||||||
|
position: relative;
|
||||||
|
overflow: hidden;
|
||||||
|
height: 100%;
|
||||||
|
|
||||||
|
>.scrollbar-scrollbar {
|
||||||
|
position: absolute;
|
||||||
|
z-index: 100;
|
||||||
|
.scrollbar-track {
|
||||||
|
background-color: @color-scrollbar-track;
|
||||||
|
position: relative;
|
||||||
|
.border-radius(5px);
|
||||||
|
|
||||||
|
.scrollbar-thumb {
|
||||||
|
background-color: @color-scrollbar-thumb;
|
||||||
|
.border-radius(5px);
|
||||||
|
cursor: pointer;
|
||||||
|
overflow: hidden;
|
||||||
|
position: absolute;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.disabled {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.vertical {
|
||||||
|
>.scrollbar-scrollbar {
|
||||||
|
right: 0;
|
||||||
|
margin-right: 5px;
|
||||||
|
width: @scrollbar-thumb-size;
|
||||||
|
.scrollbar-track {
|
||||||
|
height: 100%;
|
||||||
|
width: @scrollbar-thumb-size;
|
||||||
|
.scrollbar-thumb {
|
||||||
|
height: 20px;
|
||||||
|
width: @scrollbar-thumb-size;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active, &:hover {
|
||||||
|
width: @scrollbar-thumb-size + 2px;
|
||||||
|
.transition(width .3s);
|
||||||
|
.scrollbar-track,
|
||||||
|
.scrollbar-thumb {
|
||||||
|
width: @scrollbar-thumb-size + 2px;
|
||||||
|
.transition(width .3s);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.horizontal {
|
||||||
|
>.scrollbar-scrollbar {
|
||||||
|
margin: 0 0 5px;
|
||||||
|
clear: both;
|
||||||
|
height: @scrollbar-thumb-size;
|
||||||
|
.scrollbar-track {
|
||||||
|
width: 100%;
|
||||||
|
height: @scrollbar-thumb-size;
|
||||||
|
.scrollbar-thumb {
|
||||||
|
height: @scrollbar-thumb-size;
|
||||||
|
margin: 2px 0;
|
||||||
|
left: 0;
|
||||||
|
top: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active, &:hover {
|
||||||
|
height: @scrollbar-thumb-size + 2px;
|
||||||
|
.transition(height .3s);
|
||||||
|
.scrollbar-track,
|
||||||
|
.scrollbar-thumb {
|
||||||
|
height: @scrollbar-thumb-size + 2px;
|
||||||
|
.transition(height .3s);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
html.mobile {
|
||||||
|
.control-scrollbar {
|
||||||
|
overflow: auto;
|
||||||
|
-webkit-overflow-scrolling: touch;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.no-touch .control-scrollbar {
|
||||||
|
>.scrollbar-scrollbar {
|
||||||
|
opacity: 0;
|
||||||
|
.transition(opacity 0.3s);
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active >.scrollbar-scrollbar,
|
||||||
|
&:hover >.scrollbar-scrollbar {opacity: 1;}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: @screen-sm) {
|
||||||
|
&.responsive-sidebar {
|
||||||
|
> .layout-cell:last-child {
|
||||||
|
.control-scrollbar {
|
||||||
|
overflow: visible;
|
||||||
|
height: auto;
|
||||||
|
|
||||||
|
.scrollbar-scrollbar {
|
||||||
|
display: none!important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,98 @@
|
||||||
|
.scrollpad-scrollbar-size-tester {
|
||||||
|
width: 50px;
|
||||||
|
height: 50px;
|
||||||
|
overflow-y: scroll;
|
||||||
|
position: absolute;
|
||||||
|
top: -200px;
|
||||||
|
left: -200px;
|
||||||
|
|
||||||
|
div {
|
||||||
|
height: 100px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&::-webkit-scrollbar {
|
||||||
|
width: 0;
|
||||||
|
height: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
div.control-scrollpad {
|
||||||
|
position: relative;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
overflow: hidden;
|
||||||
|
|
||||||
|
> div {
|
||||||
|
overflow: hidden;
|
||||||
|
overflow-y: scroll;
|
||||||
|
height: 100%;
|
||||||
|
|
||||||
|
&::-webkit-scrollbar {
|
||||||
|
width: 0;
|
||||||
|
height: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&[data-direction=horizontal] > div {
|
||||||
|
overflow-x: scroll;
|
||||||
|
overflow-y: hidden;
|
||||||
|
width: 100%;
|
||||||
|
|
||||||
|
&::-webkit-scrollbar {
|
||||||
|
width: auto;
|
||||||
|
height: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> .scrollpad-scrollbar {
|
||||||
|
z-index: 199; // Be careful here
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: 0;
|
||||||
|
width: 11px;
|
||||||
|
background-color: @color-scrollbar-track;
|
||||||
|
opacity: 0;
|
||||||
|
overflow: hidden;
|
||||||
|
.border-radius(5px);
|
||||||
|
.transition(opacity 0.3s);
|
||||||
|
|
||||||
|
.drag-handle {
|
||||||
|
position: absolute;
|
||||||
|
right: 2px;
|
||||||
|
min-height: 10px;
|
||||||
|
width: 7px;
|
||||||
|
background-color: @color-scrollbar-thumb;
|
||||||
|
.border-radius(5px);
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
.opacity(.7);
|
||||||
|
.transition(opacity 0 linear);
|
||||||
|
}
|
||||||
|
|
||||||
|
&[data-visible] {
|
||||||
|
.opacity(.7);
|
||||||
|
}
|
||||||
|
|
||||||
|
&[data-hidden] {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&[data-direction=horizontal] > .scrollpad-scrollbar {
|
||||||
|
top: auto;
|
||||||
|
left: 0;
|
||||||
|
width: auto;
|
||||||
|
height: 11px;
|
||||||
|
|
||||||
|
.drag-handle {
|
||||||
|
right: auto;
|
||||||
|
top: 2px;
|
||||||
|
height: 7px;
|
||||||
|
min-height: 0;
|
||||||
|
min-width: 10px;
|
||||||
|
width: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,35 @@
|
||||||
|
.nav.selector-group {
|
||||||
|
font-size: 13px;
|
||||||
|
letter-spacing: 0.01em;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
|
||||||
|
li {
|
||||||
|
a {
|
||||||
|
padding: 7px 20px 7px 23px;
|
||||||
|
color: #95a5a6;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.active {
|
||||||
|
border-left: 3px solid #e6802b;
|
||||||
|
padding-left: 0;
|
||||||
|
|
||||||
|
a {
|
||||||
|
padding-left: 20px;
|
||||||
|
color: #2b3e50;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
i[class^="icon-"] {
|
||||||
|
font-size: 17px;
|
||||||
|
margin-right: 6px;
|
||||||
|
position: relative;
|
||||||
|
top: 1px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
div.panel {
|
||||||
|
.nav.selector-group {
|
||||||
|
margin: 0 -20px 20px -20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,270 @@
|
||||||
|
.sidenav-tree {
|
||||||
|
width: 300px;
|
||||||
|
|
||||||
|
.control-toolbar {
|
||||||
|
padding: 0;
|
||||||
|
|
||||||
|
.toolbar-item {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
input.form-control {
|
||||||
|
border: none;
|
||||||
|
outline: none;
|
||||||
|
padding: 12px 13px 13px;
|
||||||
|
.border-radius(0);
|
||||||
|
.box-shadow(inset -3px 0 3px rgba(0,0,0,0.1));
|
||||||
|
|
||||||
|
&.search {
|
||||||
|
background-position: right -78px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
ul {
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
list-style: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.scrollbar-thumb {
|
||||||
|
background: rgba(0,0,0,.2) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
ul.top-level > li {
|
||||||
|
&[data-status=collapsed] {
|
||||||
|
> div.group {
|
||||||
|
h3:before {
|
||||||
|
.transform(~'rotate(0deg) translate(2px, -2px)');
|
||||||
|
}
|
||||||
|
|
||||||
|
// Hide triangle
|
||||||
|
&:before, &:after {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
ul {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> div.group {
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
h3 {
|
||||||
|
background: @color-sidebarnav-tree-group-bg;
|
||||||
|
color: @color-sidebarnav-tree-group;
|
||||||
|
text-transform: uppercase;
|
||||||
|
font-size: 15px;
|
||||||
|
padding: 15px 15px 15px 40px;
|
||||||
|
margin: 0;
|
||||||
|
position: relative;
|
||||||
|
cursor: pointer;
|
||||||
|
font-weight: 400;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
display: block;
|
||||||
|
position: absolute;
|
||||||
|
width: 10px;
|
||||||
|
height: 10px;
|
||||||
|
left: 16px;
|
||||||
|
top: 15px;
|
||||||
|
color: @color-list-arrow;
|
||||||
|
.icon(@angle-right);
|
||||||
|
.transform(~'rotate(90deg) translate(5px, -3px)');
|
||||||
|
.transition(all 0.1s ease);
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Use two triangles to achieve the darkening effect
|
||||||
|
&:before,
|
||||||
|
&:after {
|
||||||
|
.triangle(down, 15px, 8px, @brand-primary);
|
||||||
|
position: absolute;
|
||||||
|
left: 15px;
|
||||||
|
bottom: -8px;
|
||||||
|
z-index: 101;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
.triangle(down, 15px, 8px, @color-sidebarnav-tree-group-bg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> ul {
|
||||||
|
li {
|
||||||
|
|
||||||
|
a {
|
||||||
|
display: block;
|
||||||
|
position: relative;
|
||||||
|
padding: 18px 25px 18px 55px;
|
||||||
|
background: @color-sidebarnav-tree-inactive-bg;
|
||||||
|
border-bottom: 1px solid @color-sidebarnav-tree-group-bg;
|
||||||
|
color: @color-sidebarnav-tree-inactive-text;
|
||||||
|
text-decoration: none !important;
|
||||||
|
.opacity(.65);
|
||||||
|
|
||||||
|
&:active,
|
||||||
|
&:hover {
|
||||||
|
.opacity(1);
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
i {
|
||||||
|
position: absolute;
|
||||||
|
left: 16px;
|
||||||
|
top: 18px;
|
||||||
|
font-size: 22px;
|
||||||
|
}
|
||||||
|
|
||||||
|
span {
|
||||||
|
display: block;
|
||||||
|
line-height: 150%;
|
||||||
|
|
||||||
|
&.header {
|
||||||
|
color: @color-sidebarnav-tree-inactive-header;
|
||||||
|
font-size: @font-size-base + 1;
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.description {
|
||||||
|
color: @color-sidebarnav-tree-inactive-desc;
|
||||||
|
font-size: @font-size-base - 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover a,
|
||||||
|
&.active a {
|
||||||
|
.opacity(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
&.active {
|
||||||
|
border-left: 5px solid @brand-secondary;
|
||||||
|
|
||||||
|
a {
|
||||||
|
color: @color-sidebarnav-tree-active-text;
|
||||||
|
padding-right: 20px;
|
||||||
|
|
||||||
|
span.header {
|
||||||
|
color: @color-sidebarnav-tree-active-header;
|
||||||
|
}
|
||||||
|
|
||||||
|
span.description {
|
||||||
|
color: @color-sidebarnav-tree-active-text;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// &:last-child a {
|
||||||
|
// border-bottom: none;
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.back-link {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (min-width: @screen-sm-min) {
|
||||||
|
.sidenav-tree-root .sidenav-tree {
|
||||||
|
width: 600px;
|
||||||
|
|
||||||
|
ul.top-level > li > ul {
|
||||||
|
font-size: 0;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
justify-content: flex-start;
|
||||||
|
align-items: stretch;
|
||||||
|
align-content: stretch;
|
||||||
|
|
||||||
|
> li {
|
||||||
|
display: inline-block;
|
||||||
|
// flex-grow: 1;
|
||||||
|
width: 300px;
|
||||||
|
|
||||||
|
a {
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (min-width: @screen-sm-min) and (max-width: @screen-sm-max) {
|
||||||
|
.sidenav-tree-root .sidenav-tree {
|
||||||
|
width: 100%;
|
||||||
|
|
||||||
|
ul.top-level > li > ul > li {
|
||||||
|
width: 50%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (min-width: @screen-lg-min) {
|
||||||
|
.sidenav-tree-root .sidenav-tree {
|
||||||
|
width: 900px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: @screen-sm) {
|
||||||
|
.sidenav-tree {
|
||||||
|
width: 100%;
|
||||||
|
height: auto !important;
|
||||||
|
display: block !important;
|
||||||
|
|
||||||
|
> .layout {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.sidenav-tree-root {
|
||||||
|
.sidenav-tree {
|
||||||
|
width: 100% !important;
|
||||||
|
height: 100% !important;
|
||||||
|
display: table-cell !important;
|
||||||
|
|
||||||
|
.back-link {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
> .layout {
|
||||||
|
display: table !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#layout-body {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
body.has-sidenav-tree {
|
||||||
|
.sidenav-tree {
|
||||||
|
.back-link {
|
||||||
|
display: block;
|
||||||
|
padding: 13px 15px;
|
||||||
|
background: @color-sidebarnav-back-link-bg;
|
||||||
|
color: @color-sidebarnav-back-link-text;
|
||||||
|
font-size: 14px;
|
||||||
|
line-height: 14px;
|
||||||
|
text-transform: uppercase;
|
||||||
|
i {
|
||||||
|
display: inline-block;
|
||||||
|
margin-right: 10px;
|
||||||
|
}
|
||||||
|
&:hover {
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#layout-body {
|
||||||
|
display: block !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,265 @@
|
||||||
|
//
|
||||||
|
// Simple List
|
||||||
|
// --------------------------------------------------
|
||||||
|
// Usage (bullets):
|
||||||
|
// <div class="control-simplelist">
|
||||||
|
// <ul>
|
||||||
|
// <li>Hello friend</li>
|
||||||
|
// </ul>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
// With icons (no bullets):
|
||||||
|
// <div class="control-simplelist with-icons">
|
||||||
|
// <ul>
|
||||||
|
// <li class="oc-icon-check">Hello friend</li>
|
||||||
|
// </ul>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
// With checkboxes:
|
||||||
|
// <div class="control-simplelist with-checkboxes">
|
||||||
|
// <ul>
|
||||||
|
// <li>
|
||||||
|
// <div class="checkbox custom-checkbox">
|
||||||
|
// <input id="checkbox-example1" name="checkbox" value="1" type="checkbox">
|
||||||
|
// <label class="choice" for="checkbox-example1"> Dodge Viper</label>
|
||||||
|
// </div>
|
||||||
|
// </li>
|
||||||
|
// </ul>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
// Divided (basic):
|
||||||
|
// <div class="control-simplelist is-divided">
|
||||||
|
// <ul>
|
||||||
|
// <li>Hello friend</li>
|
||||||
|
// </ul>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
// Selectable:
|
||||||
|
// <div class="control-simplelist is-selectable">
|
||||||
|
// <ul>
|
||||||
|
// <li>
|
||||||
|
// <a href="#">
|
||||||
|
// <h5 class="heading">Hello friend</h5>
|
||||||
|
// <p class="description">Something cool over here</p>
|
||||||
|
// </a>
|
||||||
|
// </li>
|
||||||
|
// </ul>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
// Selectable (box):
|
||||||
|
// <div class="control-simplelist is-selectable-box">
|
||||||
|
// <ul>
|
||||||
|
// <li>
|
||||||
|
// <a href="#">
|
||||||
|
// <div class="box">
|
||||||
|
// <div class="image"><i class="icon-user"></i></div>
|
||||||
|
// </div>
|
||||||
|
// <h5 class="heading">Hello friend</h5>
|
||||||
|
// <p class="description">Something cool over here</p>
|
||||||
|
// </a>
|
||||||
|
// </li>
|
||||||
|
// </ul>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
|
||||||
|
.control-simplelist {
|
||||||
|
font-size: 13px;
|
||||||
|
padding: 20px 20px 2px 20px;
|
||||||
|
margin-bottom: @padding-standard;
|
||||||
|
background: @color-form-checkboxlist-background;
|
||||||
|
.border-radius(@border-radius-base);
|
||||||
|
|
||||||
|
ul { padding-left: 15px; }
|
||||||
|
|
||||||
|
&.form-control {
|
||||||
|
ul { margin-bottom: 0; }
|
||||||
|
li {
|
||||||
|
padding-top: 5px;
|
||||||
|
padding-bottom: 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.with-icons,
|
||||||
|
&.with-checkboxes,
|
||||||
|
&.is-divided,
|
||||||
|
&.is-selectable {
|
||||||
|
ul {
|
||||||
|
list-style-type: none;
|
||||||
|
padding-left: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.with-checkboxes {
|
||||||
|
li {
|
||||||
|
margin-top: -5px;
|
||||||
|
|
||||||
|
&:first-child {
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:last-child {
|
||||||
|
div.custom-checkbox {
|
||||||
|
margin-bottom: 0;
|
||||||
|
|
||||||
|
label {
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.is-sortable {
|
||||||
|
|
||||||
|
li.placeholder {
|
||||||
|
position: relative;
|
||||||
|
&:before {
|
||||||
|
top: -10px;
|
||||||
|
position: absolute;
|
||||||
|
.triangle(right, 5px, 9px, @color-sortable-caret);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
li.dragged {
|
||||||
|
position: absolute;
|
||||||
|
.opacity(.5);
|
||||||
|
z-index: 2000;
|
||||||
|
color: @color-sortable-active;
|
||||||
|
|
||||||
|
width: auto !important; // Prevent browser scrollbars
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.is-scrollable {
|
||||||
|
height: 200px;
|
||||||
|
&.size-tiny { min-height: @size-tiny + 200; }
|
||||||
|
&.size-small { min-height: @size-small + 200; }
|
||||||
|
&.size-large { min-height: @size-large + 200; }
|
||||||
|
&.size-huge { min-height: @size-huge + 200; }
|
||||||
|
&.size-giant { min-height: @size-giant + 200; }
|
||||||
|
}
|
||||||
|
|
||||||
|
&.is-divided,
|
||||||
|
&.is-selectable,
|
||||||
|
&.is-selectable-box {
|
||||||
|
padding: 0;
|
||||||
|
|
||||||
|
li {
|
||||||
|
.heading {
|
||||||
|
font-size: 14px;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
|
.description {}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.is-divided,
|
||||||
|
&.is-selectable {
|
||||||
|
li {
|
||||||
|
padding: 5px 10px;
|
||||||
|
border-bottom: 1px solid @color-list-border;
|
||||||
|
|
||||||
|
&:last-child {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.is-selectable {
|
||||||
|
li {
|
||||||
|
a {
|
||||||
|
padding: 5px 10px;
|
||||||
|
margin: -5px -10px;
|
||||||
|
display: block;
|
||||||
|
color: @text-color;
|
||||||
|
}
|
||||||
|
&:hover {
|
||||||
|
background: @color-list-hover-bg;
|
||||||
|
cursor: pointer;
|
||||||
|
&, a { color: white; }
|
||||||
|
a { text-decoration: none; }
|
||||||
|
}
|
||||||
|
|
||||||
|
&.active {
|
||||||
|
a {
|
||||||
|
background: #f0f0f0;
|
||||||
|
&:hover {
|
||||||
|
background: @color-list-hover-bg;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.is-selectable-box {
|
||||||
|
padding-top: 15px;
|
||||||
|
margin-bottom: 0;
|
||||||
|
|
||||||
|
li {
|
||||||
|
width: 155px;
|
||||||
|
margin: 8px;
|
||||||
|
display: inline-block;
|
||||||
|
text-align: center;
|
||||||
|
vertical-align: top;
|
||||||
|
|
||||||
|
a {
|
||||||
|
text-decoration: none;
|
||||||
|
display: block;
|
||||||
|
color: @text-color;
|
||||||
|
|
||||||
|
.box {
|
||||||
|
display: block;
|
||||||
|
width: 155px;
|
||||||
|
height: 155px;
|
||||||
|
border: 3px solid rgba(0,0,0,.1);
|
||||||
|
position: relative;
|
||||||
|
.transition(border .3s ease);
|
||||||
|
}
|
||||||
|
|
||||||
|
.image {
|
||||||
|
display: block;
|
||||||
|
width: 56px;
|
||||||
|
height: 56px;
|
||||||
|
position: absolute;
|
||||||
|
top: 50%;
|
||||||
|
left: 50%;
|
||||||
|
margin-top: -28px;
|
||||||
|
margin-left: -28px;
|
||||||
|
|
||||||
|
> i {
|
||||||
|
font-size: 56px;
|
||||||
|
color: rgba(0,0,0,.25);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.heading {
|
||||||
|
margin: 7px 0;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.description {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
.box {
|
||||||
|
border-color: rgba(0,0,0,.2);
|
||||||
|
}
|
||||||
|
|
||||||
|
.image > i {
|
||||||
|
color: rgba(0,0,0,.45);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.list-preview .control-simplelist {
|
||||||
|
&.is-selectable {
|
||||||
|
ul {
|
||||||
|
margin-bottom: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,33 @@
|
||||||
|
.svg-icon-container {
|
||||||
|
img.svg-icon {
|
||||||
|
// SVG icons are invisible until SVG support is detected
|
||||||
|
// with JavaScript to reduce flickering on page load.
|
||||||
|
// This should be overridden in a specific control,
|
||||||
|
// inside html.svg {}
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.svg-active-effects {
|
||||||
|
img.svg-icon {
|
||||||
|
-webkit-filter: grayscale(100%);
|
||||||
|
filter: grayscale(100%);
|
||||||
|
.opacity(0.6);
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover, &.active {
|
||||||
|
img.svg-icon {
|
||||||
|
-webkit-filter: none;
|
||||||
|
filter: none;
|
||||||
|
.opacity(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
html.svg {
|
||||||
|
.svg-icon-container {
|
||||||
|
i.svg-replace {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,61 @@
|
||||||
|
ul.tree-path {
|
||||||
|
list-style: none;
|
||||||
|
padding: 0;
|
||||||
|
margin-bottom: 0;
|
||||||
|
|
||||||
|
li {
|
||||||
|
display: inline-block;
|
||||||
|
margin-right: 1px;
|
||||||
|
font-size: 13px;
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
.icon(@angle-right);
|
||||||
|
display: inline-block;
|
||||||
|
font-size: 13px;
|
||||||
|
margin-left: 5px;
|
||||||
|
position: relative;
|
||||||
|
top: 1px;
|
||||||
|
color: #95a5a6;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:last-child {
|
||||||
|
a {
|
||||||
|
cursor: default;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.go-up {
|
||||||
|
font-size: 12px;
|
||||||
|
margin-right: 7px;
|
||||||
|
|
||||||
|
a {
|
||||||
|
color: #95a5a6;
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
color: @link-color;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.root a {
|
||||||
|
font-weight: 600;
|
||||||
|
color: #405261;
|
||||||
|
}
|
||||||
|
|
||||||
|
a {
|
||||||
|
color: #95a5a6;
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,93 @@
|
||||||
|
//
|
||||||
|
// Tree List
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
.control-treelist {
|
||||||
|
ol {
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
list-style: none;
|
||||||
|
|
||||||
|
ol {
|
||||||
|
margin: 0;
|
||||||
|
margin-left: 15px;
|
||||||
|
padding-left: 15px;
|
||||||
|
border-left: 1px solid #dbdee0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> ol > li > div.record:before {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
li {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
> div.record {
|
||||||
|
margin: 0;
|
||||||
|
font-size: 12px;
|
||||||
|
margin-bottom: 5px;
|
||||||
|
position: relative;
|
||||||
|
display: block;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
color: #bdc3c7;
|
||||||
|
.icon(@circle);
|
||||||
|
font-size: 6px;
|
||||||
|
position: absolute;
|
||||||
|
left: -18px;
|
||||||
|
top: 11px;
|
||||||
|
}
|
||||||
|
|
||||||
|
> a.move {
|
||||||
|
display: inline-block;
|
||||||
|
padding: 7px 0 7px 10px;
|
||||||
|
text-decoration: none;
|
||||||
|
color: #bdc3c7;
|
||||||
|
&:hover {
|
||||||
|
color: @color-list-hover-bg;
|
||||||
|
}
|
||||||
|
&:before { .icon(@bars); }
|
||||||
|
}
|
||||||
|
> span {
|
||||||
|
color: @color-list-text;
|
||||||
|
display: inline-block;
|
||||||
|
padding: 7px 15px 7px 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.dragged {
|
||||||
|
position: absolute;
|
||||||
|
z-index: 2000;
|
||||||
|
width: auto !important; // Prevent browser scrollbars
|
||||||
|
height: auto !important;
|
||||||
|
> div.record {
|
||||||
|
.opacity(.5);
|
||||||
|
background: @color-list-hover-bg !important;
|
||||||
|
> a.move:before, > span { color: white; }
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.placeholder {
|
||||||
|
display: inline-block;
|
||||||
|
position: relative;
|
||||||
|
background: @color-list-hover-bg !important;
|
||||||
|
height: 25px;
|
||||||
|
margin-bottom: 5px;
|
||||||
|
&:before {
|
||||||
|
display: block;
|
||||||
|
position: absolute;
|
||||||
|
.icon(@chevron-left);
|
||||||
|
color: #d35714;
|
||||||
|
left: -10px;
|
||||||
|
top: 8px;
|
||||||
|
z-index: 2000;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,622 @@
|
||||||
|
.control-treeview {
|
||||||
|
margin-bottom: 40px;
|
||||||
|
|
||||||
|
.no-data() {
|
||||||
|
padding: 18px 0;
|
||||||
|
margin: 0;
|
||||||
|
color: @color-filelist-norecords-text;
|
||||||
|
font-size: @font-size-base;
|
||||||
|
text-align: center;
|
||||||
|
font-weight: 400;
|
||||||
|
}
|
||||||
|
|
||||||
|
ol {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
list-style: none;
|
||||||
|
background: @color-treeview-item-bg;
|
||||||
|
|
||||||
|
> li {
|
||||||
|
.transition(width 1s);
|
||||||
|
|
||||||
|
> div {
|
||||||
|
font-size: @font-size-base;
|
||||||
|
font-weight: normal;
|
||||||
|
background: @color-treeview-item-bg;
|
||||||
|
border-bottom: 1px solid @color-panel-light;
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
> a {
|
||||||
|
color: @color-treeview-item-title;
|
||||||
|
padding: 11px 45px 10px 61px;
|
||||||
|
display: block;
|
||||||
|
line-height: 150%;
|
||||||
|
text-decoration: none;
|
||||||
|
.box-sizing(border-box);
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
content: ' ';
|
||||||
|
background-image: url(../images/treeview-icons.png);
|
||||||
|
background-position: 0px -28px;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-size: 42px auto;
|
||||||
|
|
||||||
|
position: absolute;
|
||||||
|
width: 21px;
|
||||||
|
height: 22px;
|
||||||
|
left: 28px;
|
||||||
|
top: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
span.comment {
|
||||||
|
display: block;
|
||||||
|
font-weight: 400;
|
||||||
|
color: @color-treeview-item-comment;
|
||||||
|
font-size: @font-size-base - 1;
|
||||||
|
margin-top: 2px;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
}
|
||||||
|
|
||||||
|
> span.expand {
|
||||||
|
.hide-text();
|
||||||
|
display: none;
|
||||||
|
position: absolute;
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
top: 19px;
|
||||||
|
left: 2px;
|
||||||
|
cursor: pointer;
|
||||||
|
color: @color-treeview-control;
|
||||||
|
.transition(transform 0.1s ease);
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
.icon(@caret-right);
|
||||||
|
line-height: 100%;
|
||||||
|
font-size: @font-size-base + 1;
|
||||||
|
|
||||||
|
position: relative;
|
||||||
|
left: 8px;
|
||||||
|
top: 2px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> span.drag-handle {
|
||||||
|
.hide-text();
|
||||||
|
.transition(opacity 0.4s);
|
||||||
|
|
||||||
|
position: absolute;
|
||||||
|
right: 9px;
|
||||||
|
bottom: 0;
|
||||||
|
width: 18px;
|
||||||
|
height: 19px;
|
||||||
|
cursor: move;
|
||||||
|
color: @color-treeview-control;
|
||||||
|
.opacity(0);
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
.icon(@bars);
|
||||||
|
font-size: 18px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
span.borders {
|
||||||
|
font-size: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
> ul.submenu {
|
||||||
|
position: absolute;
|
||||||
|
left: 20px;
|
||||||
|
bottom: -36.9px;
|
||||||
|
padding: 0;
|
||||||
|
list-style: none;
|
||||||
|
z-index: 200;
|
||||||
|
height: 37px;
|
||||||
|
display: none;
|
||||||
|
margin-left: 15px;
|
||||||
|
|
||||||
|
background: transparent url(../images/treeview-submenu-tabs.png) repeat-x left -39px;
|
||||||
|
|
||||||
|
&:before, &:after {
|
||||||
|
background: transparent url(../images/treeview-submenu-tabs.png) no-repeat left top;
|
||||||
|
content: ' ';
|
||||||
|
display: block;
|
||||||
|
width: 20px;
|
||||||
|
height: 37px;
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
left: -20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
background-position: -100px top;
|
||||||
|
right: -20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
li {
|
||||||
|
font-size: @font-size-base - 2;
|
||||||
|
|
||||||
|
a {
|
||||||
|
display: block;
|
||||||
|
padding: 4px 3px 0 3px;
|
||||||
|
color: @color-treeview-submenu-text;
|
||||||
|
text-decoration: none;
|
||||||
|
outline: none;
|
||||||
|
|
||||||
|
i {
|
||||||
|
margin-right: 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
> ul.submenu {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active {
|
||||||
|
> ul.submenu {
|
||||||
|
background-position: left -116px;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
background-position: left -77px;
|
||||||
|
}
|
||||||
|
&:after {
|
||||||
|
background-position: -100px -77px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.checkbox {
|
||||||
|
position: absolute;
|
||||||
|
top: -2px;
|
||||||
|
right: 0;
|
||||||
|
|
||||||
|
label {
|
||||||
|
margin-right: 0;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
border-color: @color-filelist-cb-border;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.popover-highlight {
|
||||||
|
background-color: @color-treeview-hover-bg !important;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
background-position: 0px -80px;
|
||||||
|
}
|
||||||
|
|
||||||
|
> a {
|
||||||
|
color: @color-treeview-hover-text !important;
|
||||||
|
cursor: default;
|
||||||
|
}
|
||||||
|
|
||||||
|
span {
|
||||||
|
color: @color-treeview-hover-text !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
> ul.submenu, > span.drag-handle {
|
||||||
|
display: none!important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.dragged div, > div:hover {
|
||||||
|
background-color: @color-treeview-hover-bg !important;
|
||||||
|
|
||||||
|
> a {
|
||||||
|
color: @color-treeview-hover-text !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
background-position: 0px -80px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
top: 0 !important;
|
||||||
|
bottom: 0 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
span {
|
||||||
|
color: @color-treeview-hover-text !important;
|
||||||
|
|
||||||
|
&.drag-handle {
|
||||||
|
cursor: move;
|
||||||
|
.opacity(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
&.borders {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> div:active {
|
||||||
|
background-color: @color-treeview-active-bg !important;
|
||||||
|
|
||||||
|
> a {
|
||||||
|
color: @color-treeview-active-text !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&[data-no-drag-mode] div:hover {
|
||||||
|
span.drag-handle {
|
||||||
|
cursor: default!important;
|
||||||
|
.opacity(.3)!important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.dragged {
|
||||||
|
li.has-subitems, &.has-subitems {
|
||||||
|
> div:before {
|
||||||
|
background-position: 0px -52px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
div > ul.submenu {
|
||||||
|
display: none!important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> ol {
|
||||||
|
padding-left: 20px;
|
||||||
|
padding-right: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&[data-status=collapsed] > ol {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.has-subitems {
|
||||||
|
> div {
|
||||||
|
&:before {
|
||||||
|
background-position: 0 0;
|
||||||
|
width: 23px;
|
||||||
|
height: 26px;
|
||||||
|
left: 26px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover, &.popover-highlight {
|
||||||
|
&:before { background-position: 0px -52px; }
|
||||||
|
}
|
||||||
|
|
||||||
|
span.expand {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.placeholder {
|
||||||
|
position: relative;
|
||||||
|
.opacity(.5);
|
||||||
|
}
|
||||||
|
|
||||||
|
&.dragged {
|
||||||
|
position: absolute;
|
||||||
|
z-index: 2000;
|
||||||
|
.opacity(.25);
|
||||||
|
|
||||||
|
> div {
|
||||||
|
.border-radius(3px);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.drop-target {
|
||||||
|
> div {
|
||||||
|
background-color: #2581b8!important;
|
||||||
|
|
||||||
|
> a {
|
||||||
|
color: @color-treeview-hover-text;
|
||||||
|
> span.comment {
|
||||||
|
color: @color-treeview-hover-text;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
background-position: 0px -80px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.has-subitems > div:before {
|
||||||
|
background-position: 0px -52px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&[data-status=expanded] > div > span.expand {
|
||||||
|
.transform( ~'rotate(90deg) translate(0, 0)' );
|
||||||
|
}
|
||||||
|
|
||||||
|
&.drag-ghost {
|
||||||
|
background-color: transparent;
|
||||||
|
box-sizing: content-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.active {
|
||||||
|
> div {
|
||||||
|
background: @color-list-active;
|
||||||
|
|
||||||
|
&:after {
|
||||||
|
position: absolute;
|
||||||
|
width: 4px;
|
||||||
|
left: 0;
|
||||||
|
top: -1px;
|
||||||
|
bottom: -1px;
|
||||||
|
background: @color-list-active-border;
|
||||||
|
display: block;
|
||||||
|
content: ' ';
|
||||||
|
}
|
||||||
|
|
||||||
|
> span.comment, > span.expand {
|
||||||
|
color: @color-treeview-item-active-comment;
|
||||||
|
}
|
||||||
|
|
||||||
|
> span.borders {
|
||||||
|
&:before, &:after {
|
||||||
|
content: ' ';
|
||||||
|
position: absolute;
|
||||||
|
width: 100%;
|
||||||
|
height: 1px;
|
||||||
|
display: block;
|
||||||
|
left: 0;
|
||||||
|
background-color: @color-list-active;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before {top: -1px;}
|
||||||
|
&:after {bottom: -1px;}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.no-data {
|
||||||
|
.no-data();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@max-level: 10;
|
||||||
|
|
||||||
|
.tree-view-paddings (@level) when (@level > 0) {
|
||||||
|
> li {
|
||||||
|
> ol {
|
||||||
|
> li > div {
|
||||||
|
margin-left: -20-(@max-level - @level)*20px;
|
||||||
|
margin-right: -20-(@max-level - @level)*20px;
|
||||||
|
padding-left: 61+(@max-level - @level + 1)*10px;
|
||||||
|
|
||||||
|
> a {
|
||||||
|
margin-left: -61-(@max-level - @level + 1)*10px;
|
||||||
|
padding-left: 61+(@max-level - @level + 1)*10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
margin-left: (@max-level - @level + 1)*10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
> span.expand {
|
||||||
|
left: 2+(@max-level - @level + 1)*10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.tree-view-paddings(@level - 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.tree-view-paddings (@max-level);
|
||||||
|
}
|
||||||
|
|
||||||
|
p.no-data {
|
||||||
|
.no-data();
|
||||||
|
}
|
||||||
|
|
||||||
|
a.menu-control {
|
||||||
|
display: block;
|
||||||
|
margin: 20px;
|
||||||
|
padding: 13px 15px;
|
||||||
|
border: dotted 2px #ebebeb;
|
||||||
|
color: #bdc3c7;
|
||||||
|
font-size: @font-size-base - 2;
|
||||||
|
font-weight: 600;
|
||||||
|
text-transform: uppercase;
|
||||||
|
border-radius: 5px;
|
||||||
|
vertical-align: middle;
|
||||||
|
|
||||||
|
&:hover, &:focus {
|
||||||
|
text-decoration: none;
|
||||||
|
background-color: @color-treeview-hover-bg;
|
||||||
|
color: @color-treeview-hover-text;
|
||||||
|
border: none;
|
||||||
|
padding: 15px 17px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active {
|
||||||
|
background: @color-treeview-active-bg;
|
||||||
|
color: @color-treeview-active-text;
|
||||||
|
}
|
||||||
|
|
||||||
|
i {
|
||||||
|
margin-right: 10px;
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Light version of the treeview - transparent background, no bottom borders,
|
||||||
|
* smaller paddings, inline submenu
|
||||||
|
*/
|
||||||
|
&.treeview-light {
|
||||||
|
margin-bottom: 0;
|
||||||
|
margin-top: 20px;
|
||||||
|
|
||||||
|
ol {
|
||||||
|
background-color: transparent;
|
||||||
|
> li {
|
||||||
|
> div {
|
||||||
|
background-color: transparent;
|
||||||
|
border-bottom: none;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
top: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
> a {
|
||||||
|
padding-top: 10px;
|
||||||
|
padding-bottom: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
span.expand {
|
||||||
|
top: 19px;
|
||||||
|
}
|
||||||
|
|
||||||
|
> span.drag-handle {
|
||||||
|
top: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: auto;
|
||||||
|
height: 100%;
|
||||||
|
width: 60px;
|
||||||
|
background: @color-treeview-light-submenu-bg;
|
||||||
|
.transition(none)!important;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
position: absolute;
|
||||||
|
left: 50%;
|
||||||
|
top: 50%;
|
||||||
|
margin-left: -6px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
> ul.submenu {
|
||||||
|
right: 60px;
|
||||||
|
left: auto;
|
||||||
|
bottom: auto;
|
||||||
|
top: 0;
|
||||||
|
height: 100%;
|
||||||
|
margin: 0;
|
||||||
|
background: transparent;
|
||||||
|
white-space: nowrap;
|
||||||
|
font-size: 0;
|
||||||
|
|
||||||
|
&:before, &:after {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
li {
|
||||||
|
height: 100%;
|
||||||
|
display: inline-block;
|
||||||
|
background: @color-treeview-light-submenu-bg;
|
||||||
|
border-right: 1px solid @color-treeview-light-submenu-border;
|
||||||
|
|
||||||
|
p {
|
||||||
|
display: table;
|
||||||
|
height: 100%;
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
|
||||||
|
a {
|
||||||
|
display: table-cell;
|
||||||
|
vertical-align: middle;
|
||||||
|
height: 100%;
|
||||||
|
padding: 0 20px;
|
||||||
|
font-size: @font-size-base - 1;
|
||||||
|
.box-sizing(border-box);
|
||||||
|
|
||||||
|
i.control-icon {
|
||||||
|
font-size: 22px;
|
||||||
|
margin-right: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Sorting guides
|
||||||
|
//
|
||||||
|
|
||||||
|
body.dragging .control-treeview {
|
||||||
|
ol.dragging, ol.dragging ol {
|
||||||
|
background: #ccc;
|
||||||
|
padding-right: 20px;
|
||||||
|
.transition(padding 1s);
|
||||||
|
|
||||||
|
> li {
|
||||||
|
> div {
|
||||||
|
margin-right: 0;
|
||||||
|
.transition(margin 1s);
|
||||||
|
|
||||||
|
.custom-checkbox {
|
||||||
|
.transition(opacity .5s);
|
||||||
|
.opacity(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.treeview-light {
|
||||||
|
ol.dragging, ol.dragging ol {
|
||||||
|
> li > div {
|
||||||
|
background-color: #f9f9f9;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Retina
|
||||||
|
//
|
||||||
|
|
||||||
|
@media only screen and (min--moz-device-pixel-ratio: 1.5), only screen and (-o-min-device-pixel-ratio: 3/2), only screen and (-webkit-min-device-pixel-ratio: 1.5), only screen and (min-devicepixel-ratio: 1.5), only screen and (min-resolution: 1.5dppx) {
|
||||||
|
.control-treeview {
|
||||||
|
ol {
|
||||||
|
> li {
|
||||||
|
> div{
|
||||||
|
&:before {
|
||||||
|
background-position: 0px -79px;
|
||||||
|
background-size: 21px auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.has-subitems > div {
|
||||||
|
&:before {background-position: 0px -52px;}
|
||||||
|
&:hover, &.popover-highlight {
|
||||||
|
&:before {background-position: 0px -102px;}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.dragged > div, &.dragged li > div, > div:hover, > div.popover-highlight {
|
||||||
|
&:before {background-position: 0px -129px;}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.dragged {
|
||||||
|
li.has-subitems, &.has-subitems {
|
||||||
|
> div:before {
|
||||||
|
background-position: 0px -102px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.drop-target {
|
||||||
|
> div:before {
|
||||||
|
background-position: 0px -129px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.has-subitems > div:before {
|
||||||
|
background-position: 0px -102px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,363 @@
|
||||||
|
//
|
||||||
|
// Fade In
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeIn {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeIn {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeIn {
|
||||||
|
-webkit-animation-name: fadeIn;
|
||||||
|
animation-name: fadeIn;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Fade In Down
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeInDown {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(0, -100%, 0);
|
||||||
|
transform: translate3d(0, -100%, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transform: none;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeInDown {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(0, -100%, 0);
|
||||||
|
-ms-transform: translate3d(0, -100%, 0);
|
||||||
|
transform: translate3d(0, -100%, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transform: none;
|
||||||
|
-ms-transform: none;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeInDown {
|
||||||
|
-webkit-animation-name: fadeInDown;
|
||||||
|
animation-name: fadeInDown;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Fade In Left
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeInLeft {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(-100%, 0, 0);
|
||||||
|
transform: translate3d(-100%, 0, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transform: none;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeInLeft {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(-100%, 0, 0);
|
||||||
|
-ms-transform: translate3d(-100%, 0, 0);
|
||||||
|
transform: translate3d(-100%, 0, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transform: none;
|
||||||
|
-ms-transform: none;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeInLeft {
|
||||||
|
-webkit-animation-name: fadeInLeft;
|
||||||
|
animation-name: fadeInLeft;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Fade In Right
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeInRight {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(100%, 0, 0);
|
||||||
|
transform: translate3d(100%, 0, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transform: none;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeInRight {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(100%, 0, 0);
|
||||||
|
-ms-transform: translate3d(100%, 0, 0);
|
||||||
|
transform: translate3d(100%, 0, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transform: none;
|
||||||
|
-ms-transform: none;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeInRight {
|
||||||
|
-webkit-animation-name: fadeInRight;
|
||||||
|
animation-name: fadeInRight;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Fade In Up
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeInUp {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(0, 100%, 0);
|
||||||
|
transform: translate3d(0, 100%, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transform: none;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeInUp {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(0, 100%, 0);
|
||||||
|
-ms-transform: translate3d(0, 100%, 0);
|
||||||
|
transform: translate3d(0, 100%, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transform: none;
|
||||||
|
-ms-transform: none;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeInUp {
|
||||||
|
-webkit-animation-name: fadeInUp;
|
||||||
|
animation-name: fadeInUp;
|
||||||
|
}
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeInUpBig {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(0, 2000px, 0);
|
||||||
|
transform: translate3d(0, 2000px, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transform: none;
|
||||||
|
transform: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Fade Out
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeOut {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeOut {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeOut {
|
||||||
|
-webkit-animation-name: fadeOut;
|
||||||
|
animation-name: fadeOut;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Fade Out Down
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeOutDown {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(0, 100%, 0);
|
||||||
|
transform: translate3d(0, 100%, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeOutDown {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(0, 100%, 0);
|
||||||
|
-ms-transform: translate3d(0, 100%, 0);
|
||||||
|
transform: translate3d(0, 100%, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeOutDown {
|
||||||
|
-webkit-animation-name: fadeOutDown;
|
||||||
|
animation-name: fadeOutDown;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Fade Out Left
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeOutLeft {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(-100%, 0, 0);
|
||||||
|
transform: translate3d(-100%, 0, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeOutLeft {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(-100%, 0, 0);
|
||||||
|
-ms-transform: translate3d(-100%, 0, 0);
|
||||||
|
transform: translate3d(-100%, 0, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeOutLeft {
|
||||||
|
-webkit-animation-name: fadeOutLeft;
|
||||||
|
animation-name: fadeOutLeft;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Fade Out Right
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeOutRight {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(100%, 0, 0);
|
||||||
|
transform: translate3d(100%, 0, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeOutRight {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(100%, 0, 0);
|
||||||
|
-ms-transform: translate3d(100%, 0, 0);
|
||||||
|
transform: translate3d(100%, 0, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeOutRight {
|
||||||
|
-webkit-animation-name: fadeOutRight;
|
||||||
|
animation-name: fadeOutRight;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Fade Out Up
|
||||||
|
//
|
||||||
|
|
||||||
|
@-webkit-keyframes fadeOutUp {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(0, -100%, 0);
|
||||||
|
transform: translate3d(0, -100%, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeOutUp {
|
||||||
|
0% {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
opacity: 0;
|
||||||
|
-webkit-transform: translate3d(0, -100%, 0);
|
||||||
|
-ms-transform: translate3d(0, -100%, 0);
|
||||||
|
transform: translate3d(0, -100%, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeOutUp {
|
||||||
|
-webkit-animation-name: fadeOutUp;
|
||||||
|
animation-name: fadeOutUp;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,11 @@
|
||||||
|
//
|
||||||
|
// Boots the Core LESS
|
||||||
|
//
|
||||||
|
// Includes non-output LESS files such as mixins and variables
|
||||||
|
//
|
||||||
|
|
||||||
|
// Core variables and mixins
|
||||||
|
@import "../../../../system/assets/ui/less/global.less";
|
||||||
|
|
||||||
|
@import "variables.less";
|
||||||
|
@import "mixins.less";
|
||||||
|
|
@ -0,0 +1,165 @@
|
||||||
|
// --------------------------------------------------
|
||||||
|
// Flexbox LESS mixins
|
||||||
|
// The spec: http://www.w3.org/TR/css3-flexbox
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
// Flexbox display
|
||||||
|
// flex or inline-flex
|
||||||
|
.flex-display() {
|
||||||
|
display: ~"-webkit-box";
|
||||||
|
display: ~"-webkit-flex";
|
||||||
|
display: ~"-moz-flex";
|
||||||
|
display: ~"-ms-flexbox"; // IE10 uses -ms-flexbox
|
||||||
|
display: ~"-ms-flex"; // IE11
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
|
||||||
|
// The 'flex: 0 0 auto' shorthand
|
||||||
|
.flex-fix() {
|
||||||
|
-webkit-box-flex: 0;
|
||||||
|
-webkit-flex: 0 0 auto;
|
||||||
|
-moz-flex: 0 0 auto;
|
||||||
|
-ms-flex: 0 0 auto;
|
||||||
|
flex: 0 0 auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
// The 'flex: 1 1 auto' shorthand
|
||||||
|
.flex-stretch() {
|
||||||
|
-webkit-box-flex: 1;
|
||||||
|
-webkit-flex: 1 1 auto;
|
||||||
|
-moz-flex: 1 1 auto;
|
||||||
|
-ms-flex: 1 1 auto;
|
||||||
|
flex: 1 1 auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
// The 'flex: 1' shorthand
|
||||||
|
.flex-stretch-constrain() {
|
||||||
|
-webkit-box-flex: 1;
|
||||||
|
-webkit-flex: 1;
|
||||||
|
-moz-flex: 1;
|
||||||
|
-ms-flex: 1;
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Flex Flow Direction Column
|
||||||
|
// - applies to: flex containers
|
||||||
|
.flex-direction-column() {
|
||||||
|
-webkit-flex-direction: column;
|
||||||
|
-moz-flex-direction: column;
|
||||||
|
-webkit-box-orient: vertical;
|
||||||
|
-ms-flex-direction: column;
|
||||||
|
flex-direction: column;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Flex Flow Direction Row
|
||||||
|
// - applies to: flex containers
|
||||||
|
.flex-direction-row() {
|
||||||
|
-webkit-flex-direction: row;
|
||||||
|
-moz-flex-direction: row;
|
||||||
|
-webkit-box-orient: horizontal;
|
||||||
|
-ms-flex-direction: row;
|
||||||
|
flex-direction: row;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Flex Line Wrapping
|
||||||
|
// - applies to: flex containers
|
||||||
|
// nowrap | wrap | wrap-reverse
|
||||||
|
.flex-wrap(@wrap: nowrap) {
|
||||||
|
-webkit-flex-wrap: @wrap;
|
||||||
|
-moz-flex-wrap: @wrap;
|
||||||
|
-ms-flex-wrap: @wrap;
|
||||||
|
flex-wrap: @wrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Flex Direction and Wrap
|
||||||
|
// - applies to: flex containers
|
||||||
|
// <flex-direction> || <flex-wrap>
|
||||||
|
.flex-flow(@flow) {
|
||||||
|
-webkit-flex-flow: @flow;
|
||||||
|
-moz-flex-flow: @flow;
|
||||||
|
-ms-flex-flow: @flow;
|
||||||
|
flex-flow: @flow;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Display Order
|
||||||
|
// - applies to: flex items
|
||||||
|
// <integer>
|
||||||
|
.flex-order(@order: 0) {
|
||||||
|
-webkit-order: @order;
|
||||||
|
-moz-order: @order;
|
||||||
|
-ms-order: @order;
|
||||||
|
order: @order;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Flex grow factor
|
||||||
|
// - applies to: flex items
|
||||||
|
// <number>
|
||||||
|
.flex-grow(@grow: 0) {
|
||||||
|
-webkit-flex-grow: @grow;
|
||||||
|
-moz-flex-grow: @grow;
|
||||||
|
-ms-flex-grow: @grow;
|
||||||
|
flex-grow: @grow;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Flex shr
|
||||||
|
// - applies to: flex itemsink factor
|
||||||
|
// <number>
|
||||||
|
.flex-shrink(@shrink: 1) {
|
||||||
|
-webkit-flex-shrink: @shrink;
|
||||||
|
-moz-flex-shrink: @shrink;
|
||||||
|
-ms-flex-shrink: @shrink;
|
||||||
|
flex-shrink: @shrink;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Flex basis
|
||||||
|
// - the initial main size of the flex item
|
||||||
|
// - applies to: flex itemsnitial main size of the flex item
|
||||||
|
// <width>
|
||||||
|
.flex-basis(@width: auto) {
|
||||||
|
-webkit-flex-basis: @width;
|
||||||
|
-moz-flex-basis: @width;
|
||||||
|
-ms-flex-basis: @width;
|
||||||
|
flex-basis: @width;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Axis Alignment
|
||||||
|
// - applies to: flex containers
|
||||||
|
// flex-start | flex-end | center | space-between | space-around
|
||||||
|
.justify-content(@justify: flex-start) {
|
||||||
|
-webkit-justify-content: @justify;
|
||||||
|
-moz-justify-content: @justify;
|
||||||
|
-ms-justify-content: @justify;
|
||||||
|
-webkit-box-pack: @justify;
|
||||||
|
justify-content: @justify;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Packing Flex Lines
|
||||||
|
// - applies to: multi-line flex containers
|
||||||
|
// flex-start | flex-end | center | space-between | space-around | stretch
|
||||||
|
.align-content(@align: stretch) {
|
||||||
|
-webkit-align-content: @align;
|
||||||
|
-moz-align-content: @align;
|
||||||
|
-webkit-box-align: @align;
|
||||||
|
-ms-align-content: @align;
|
||||||
|
align-content: @align;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Cross-axis Alignment
|
||||||
|
// - applies to: flex containers
|
||||||
|
// flex-start | flex-end | center | baseline | stretch
|
||||||
|
.align-items(@align: stretch) {
|
||||||
|
-webkit-align-items: @align;
|
||||||
|
-moz-align-items: @align;
|
||||||
|
-ms-align-items: @align;
|
||||||
|
align-items: @align;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Cross-axis Alignment
|
||||||
|
// - applies to: flex items
|
||||||
|
// auto | flex-start | flex-end | center | baseline | stretch
|
||||||
|
.align-self(@align: auto) {
|
||||||
|
-webkit-align-self: @align;
|
||||||
|
-moz-align-self: @align;
|
||||||
|
-ms-align-self: @align;
|
||||||
|
align-self: @align;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,153 @@
|
||||||
|
//
|
||||||
|
// Override UI variables
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
@font-family-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
|
||||||
|
|
||||||
|
//
|
||||||
|
// Paths
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
@type-font-path: "../font";
|
||||||
|
|
||||||
|
//
|
||||||
|
// Colors
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
@color-border: #cccccc;
|
||||||
|
@color-border-light: #e1e1e1;
|
||||||
|
|
||||||
|
@color-mainmenu: #000000;
|
||||||
|
@color-mainmenu-inactive: rgba(255,255,255,.6);
|
||||||
|
@color-mainmenu-active: #ffffff;
|
||||||
|
@color-mainmenu-active-bg: #262626;
|
||||||
|
@color-mainmenu-collapsed: #000000;
|
||||||
|
|
||||||
|
@color-accountmenu-bg: #f9f9f9;
|
||||||
|
@color-accountmenu-text: #666666;
|
||||||
|
@color-accountmenu-divider: #e0e0e0;
|
||||||
|
|
||||||
|
@color-footer: rgba(255,255,255,.8);
|
||||||
|
@color-footer-border: #dfdfdf;
|
||||||
|
@color-footer-text: #666666;
|
||||||
|
|
||||||
|
@color-sidebarnav-active-text: #ffffff;
|
||||||
|
@color-sidebarnav-active-icon: #ffffff;
|
||||||
|
@color-sidebarnav-inactive-text: rgba(255,255,255,.6);
|
||||||
|
@color-sidebarnav-inactive-icon: rgba(255,255,255,.6);
|
||||||
|
@color-sidebarnav-counter-bg: #d9350f;
|
||||||
|
@color-sidebarnav-counter-text: #ffffff;
|
||||||
|
|
||||||
|
@color-sidebarnav-tree-group: #ecf0f1;
|
||||||
|
@color-sidebarnav-tree-group-bg: rgba(0,0,0,.15);
|
||||||
|
@color-sidebarnav-tree-inactive-header: #ffffff;
|
||||||
|
@color-sidebarnav-tree-inactive-desc: rgba(255,255,255,.6);
|
||||||
|
@color-sidebarnav-tree-inactive-text: #ffffff;
|
||||||
|
@color-sidebarnav-tree-active-header: #ffffff;
|
||||||
|
@color-sidebarnav-tree-inactive-bg: transparent;
|
||||||
|
@color-sidebarnav-tree-active-text: rgba(255,255,255,.91);
|
||||||
|
@color-sidebarnav-tree-active-marker: @brand-secondary;
|
||||||
|
@color-sidebarnav-back-link-bg: #2b3e50;
|
||||||
|
@color-sidebarnav-back-link-text: #bdc3c7;
|
||||||
|
|
||||||
|
@color-scrollbar-track: transparent;
|
||||||
|
@color-scrollbar-thumb: rgba(0,0,0,.35);
|
||||||
|
@color-scrollpanel-border: #efefef;
|
||||||
|
@color-scrollpanel-fix-button: #aaaaaa;
|
||||||
|
@color-scrollpanel-fix-button-light: #eeeeee;
|
||||||
|
@color-scroll-indicator: #bbbbbb;
|
||||||
|
|
||||||
|
@color-panel-light: #ECF0F1;
|
||||||
|
|
||||||
|
@color-outer-muted-text: rgba(255,255,255,.44);
|
||||||
|
@color-outer-heading: #feffff;
|
||||||
|
@color-outer-description: #999999;
|
||||||
|
@color-outer-bg: #2b3e50;
|
||||||
|
@color-outer-header: @body-bg;
|
||||||
|
@color-outer-form-label: #666666;
|
||||||
|
|
||||||
|
@color-breadcrumb-text-active: #9da3a7;
|
||||||
|
@color-breadcrumb-text: #9B9B9B;
|
||||||
|
@color-breadcrumb-background: #2b343d;
|
||||||
|
|
||||||
|
@color-custom-input-icon: #666666;
|
||||||
|
@color-custom-input-border: #999999;
|
||||||
|
|
||||||
|
@color-input-sidebar-control: #C4C4C4;
|
||||||
|
|
||||||
|
@color-switch-input-bg: #f6f6f6;
|
||||||
|
@color-switch-input-on: #8da85e;
|
||||||
|
@color-switch-input-off: #cc3300;
|
||||||
|
|
||||||
|
@color-custom-select-border: #b2b9be;
|
||||||
|
@color-custom-select-bg: #f6f6f6;
|
||||||
|
@color-custom-select-bg-hover: #4da7e8;
|
||||||
|
|
||||||
|
@color-filelist-norecords-text: #666666;
|
||||||
|
@color-filelist-norecords-bg: #eeeeee;
|
||||||
|
@color-filelist-cb-border: #cccccc;
|
||||||
|
@color-filelist-title-hero: #2b3e50;
|
||||||
|
@color-filelist-hero-item-bg: #ffffff;
|
||||||
|
@color-filelist-hero-hover-bg: @highlight-hover-bg;
|
||||||
|
@color-filelist-hero-hover-text: @highlight-hover-text;
|
||||||
|
@color-filelist-hero-active-bg: @highlight-active-bg;
|
||||||
|
@color-filelist-hero-active-text: @highlight-active-text;
|
||||||
|
|
||||||
|
@color-fancy-master-tabs-bg: #d35400;
|
||||||
|
@color-fancy-master-tabs-active-text: #ffffff;
|
||||||
|
@color-fancy-master-tabs-inactive-text: rgba(255, 255, 255, .35);
|
||||||
|
@color-fancy-master-panel-bg: #d35400;
|
||||||
|
|
||||||
|
@color-fancy-secondary-tabs-bg: #475354;
|
||||||
|
@color-fancy-secondary-tabs-active-text: #ffffff;
|
||||||
|
@color-fancy-secondary-tabs-inactive-text: #919898;
|
||||||
|
|
||||||
|
@color-fancy-primary-tabs-bg: #7F8C8D;
|
||||||
|
@color-fancy-primary-tabs-inactive-text: #95a5a6;
|
||||||
|
@color-fancy-primary-tabs-active-text: #808c8d;
|
||||||
|
@color-fancy-primary-tabs-active-bg: #fafafa;
|
||||||
|
@color-fancy-primary-tabs-inactive-bg: #d5d9d8;
|
||||||
|
|
||||||
|
@color-fancy-form-tabless-fields-bg: @brand-secondary;
|
||||||
|
@color-fancy-form-label: rgba(255, 255, 255, .5);
|
||||||
|
@color-fancy-form-text: #ffffff;
|
||||||
|
@color-fancy-form-text-selection: #d35400;
|
||||||
|
@color-fancy-form-placeholder: rgba(255, 255, 255, .5);
|
||||||
|
@color-fancy-form-inactive-tab: #b9530f;
|
||||||
|
|
||||||
|
@color-sortable-caret: #999999;
|
||||||
|
@color-sortable-active: @brand-secondary;
|
||||||
|
|
||||||
|
@color-report-widget-title: #7e8c8d;
|
||||||
|
@color-report-widget-control-inactive: #b6b6b6;
|
||||||
|
@color-report-widget-description: @color-report-widget-title;
|
||||||
|
@color-report-widget-link: @color-report-widget-title;
|
||||||
|
|
||||||
|
@color-treeview-item-bg: #ffffff;
|
||||||
|
@color-treeview-item-title: #2b3e50;
|
||||||
|
@color-treeview-item-comment: #95a5a6;
|
||||||
|
@color-treeview-control: #bdc3c7;
|
||||||
|
@color-treeview-hover-bg: @highlight-hover-bg;
|
||||||
|
@color-treeview-hover-text: @highlight-hover-text;
|
||||||
|
@color-treeview-active-bg: @highlight-active-bg;
|
||||||
|
@color-treeview-active-text: @highlight-active-text;
|
||||||
|
@color-treeview-item-active-comment: #8f8f8f;
|
||||||
|
@color-treeview-submenu-text: #ffffff;
|
||||||
|
@color-treeview-light-submenu-bg: #2581b8;
|
||||||
|
@color-treeview-light-submenu-border: #328ec8;
|
||||||
|
|
||||||
|
//
|
||||||
|
// Sizes
|
||||||
|
// --------------------------------------------------
|
||||||
|
@size-tiny: 50px;
|
||||||
|
@size-small: 100px;
|
||||||
|
@size-large: 200px;
|
||||||
|
@size-huge: 250px;
|
||||||
|
@size-giant: 350px;
|
||||||
|
|
||||||
|
//
|
||||||
|
// Media breakpoints
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
@menu-breakpoint-min: 770px;
|
||||||
|
@menu-breakpoint-max: (@menu-breakpoint-min - 1);
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
@import "../../../../backend/assets/less/core/boot.less";
|
||||||
|
|
||||||
|
.dashboard-container > .report-container {
|
||||||
|
&.loading {
|
||||||
|
position: absolute;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
|
||||||
|
.loading-indicator-container {
|
||||||
|
position: absolute;
|
||||||
|
left: 0;
|
||||||
|
top: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||