WordPress Button Plugin MaxButtons - Version 8.8.1

Version Description

  • Fix - Moved external libraries to own namespace to prevent conflicts.
Download this release

Release Info

Developer basszje
Plugin Icon 128x128 WordPress Button Plugin MaxButtons
Version 8.8.1
Comparing to
See all releases

Code changes from version 8.8 to 8.8.1

Files changed (53) hide show
  1. assets/libraries/scss.inc.php.new +18 -0
  2. assets/libraries/scssphp/LICENSE.md +0 -20
  3. assets/libraries/scssphp/README.md +0 -71
  4. assets/libraries/scssphp/composer.json +0 -108
  5. assets/libraries/scssphp/scss.inc.php +3 -6
  6. assets/libraries/scssphp/src/Base/Range.php +1 -1
  7. assets/libraries/scssphp/src/Block.php +1 -1
  8. assets/libraries/scssphp/src/Cache.php +3 -3
  9. assets/libraries/scssphp/src/Colors.php +1 -1
  10. assets/libraries/scssphp/src/CompilationResult.php +1 -1
  11. assets/libraries/scssphp/src/Compiler.php +17 -17
  12. assets/libraries/scssphp/src/Compiler/CachedResult.php +2 -2
  13. assets/libraries/scssphp/src/Compiler/Environment.php +1 -1
  14. assets/libraries/scssphp/src/Exception/CompilerException.php +1 -1
  15. assets/libraries/scssphp/src/Exception/ParserException.php +1 -1
  16. assets/libraries/scssphp/src/Exception/RangeException.php +1 -1
  17. assets/libraries/scssphp/src/Exception/SassException.php +1 -1
  18. assets/libraries/scssphp/src/Exception/SassScriptException.php +1 -1
  19. assets/libraries/scssphp/src/Exception/ServerException.php +1 -1
  20. assets/libraries/scssphp/src/Formatter.php +3 -3
  21. assets/libraries/scssphp/src/Formatter/Compact.php +2 -2
  22. assets/libraries/scssphp/src/Formatter/Compressed.php +2 -2
  23. assets/libraries/scssphp/src/Formatter/Crunched.php +2 -2
  24. assets/libraries/scssphp/src/Formatter/Debug.php +2 -2
  25. assets/libraries/scssphp/src/Formatter/Expanded.php +2 -2
  26. assets/libraries/scssphp/src/Formatter/Nested.php +3 -3
  27. assets/libraries/scssphp/src/Formatter/OutputBlock.php +1 -1
  28. assets/libraries/scssphp/src/Logger/LoggerInterface.php +1 -1
  29. assets/libraries/scssphp/src/Logger/QuietLogger.php +1 -1
  30. assets/libraries/scssphp/src/Logger/StreamLogger.php +1 -1
  31. assets/libraries/scssphp/src/Node.php +1 -1
  32. assets/libraries/scssphp/src/Node/Number.php +9 -9
  33. assets/libraries/scssphp/src/OutputStyle.php +1 -1
  34. assets/libraries/scssphp/src/Parser.php +4 -4
  35. assets/libraries/scssphp/src/SourceMap/Base64.php +1 -1
  36. assets/libraries/scssphp/src/SourceMap/Base64VLQ.php +1 -1
  37. assets/libraries/scssphp/src/SourceMap/SourceMapGenerator.php +2 -2
  38. assets/libraries/scssphp/src/Type.php +1 -1
  39. assets/libraries/scssphp/src/Util.php +4 -4
  40. assets/libraries/scssphp/src/Util/Path.php +1 -1
  41. assets/libraries/scssphp/src/ValueConverter.php +2 -2
  42. assets/libraries/scssphp/src/Version.php +1 -1
  43. assets/libraries/scssphp/src/Warn.php +1 -1
  44. assets/libraries/simplehtmldom/simple_html_dom.php +2 -0
  45. blocks/container.php +1 -1
  46. classes/button.php +2 -2
  47. classes/maxCSSParser.php +3 -4
  48. classes/maxbuttons-class.php +1 -1
  49. js/maxajax.js +1 -4
  50. js/maxmodal.js +1 -1
  51. js/min/maxmodal.js +1 -1
  52. maxbuttons.php +3 -3
  53. readme.txt +5 -1
assets/libraries/scss.inc.php.new ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+
4
+ if (! class_exists('\MaxButtons\ScssPhp\ScssPhp\Version')) {
5
+ spl_autoload_register(function ($class) {
6
+ if (0 !== strpos($class, 'MaxButtons\ScssPhp\ScssPhp\\')) {
7
+ // Not a ScssPhp class
8
+ return;
9
+ }
10
+
11
+ $subClass = substr($class, strlen('MaxButtons\ScssPhp\ScssPhp\\'));
12
+ $path = __DIR__ . '/src/' . str_replace('\\', '/', $subClass) . '.php';
13
+
14
+ if (file_exists($path)) {
15
+ require $path;
16
+ }
17
+ });
18
+ }
assets/libraries/scssphp/LICENSE.md DELETED
@@ -1,20 +0,0 @@
1
- Copyright (c) 2015 Leaf Corcoran, http://scssphp.github.io/scssphp
2
-
3
- Permission is hereby granted, free of charge, to any person obtaining
4
- a copy of this software and associated documentation files (the
5
- "Software"), to deal in the Software without restriction, including
6
- without limitation the rights to use, copy, modify, merge, publish,
7
- distribute, sublicense, and/or sell copies of the Software, and to
8
- permit persons to whom the Software is furnished to do so, subject to
9
- the following conditions:
10
-
11
- The above copyright notice and this permission notice shall be
12
- included in all copies or substantial portions of the Software.
13
-
14
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
- NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
- LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
- OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
- WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
assets/libraries/scssphp/README.md DELETED
@@ -1,71 +0,0 @@
1
- # scssphp
2
- ### <https://scssphp.github.io/scssphp>
3
-
4
- ![Build](https://github.com/scssphp/scssphp/workflows/CI/badge.svg)
5
- [![License](https://poser.pugx.org/scssphp/scssphp/license)](https://packagist.org/packages/scssphp/scssphp)
6
-
7
- `scssphp` is a compiler for SCSS written in PHP.
8
-
9
- Checkout the homepage, <https://scssphp.github.io/scssphp>, for directions on how to use.
10
-
11
- ## Running Tests
12
-
13
- `scssphp` uses [PHPUnit](https://github.com/sebastianbergmann/phpunit) for testing.
14
-
15
- Run the following command from the root directory to run every test:
16
-
17
- vendor/bin/phpunit tests
18
-
19
- There are several tests in the `tests/` directory:
20
-
21
- * `ApiTest.php` contains various unit tests that test the PHP interface.
22
- * `ExceptionTest.php` contains unit tests that test for exceptions thrown by the parser and compiler.
23
- * `FailingTest.php` contains tests reported in Github issues that demonstrate compatibility bugs.
24
- * `InputTest.php` compiles every `.scss` file in the `tests/inputs` directory
25
- then compares to the respective `.css` file in the `tests/outputs` directory.
26
- * `SassSpecTest.php` extracts tests from the `sass/sass-spec` repository.
27
-
28
- When changing any of the tests in `tests/inputs`, the tests will most likely
29
- fail because the output has changed. Once you verify that the output is correct
30
- you can run the following command to rebuild all the tests:
31
-
32
- BUILD=1 vendor/bin/phpunit tests
33
-
34
- This will compile all the tests, and save results into `tests/outputs`. It also
35
- updates the list of excluded specs from sass-spec.
36
-
37
- To enable the full `sass-spec` compatibility tests:
38
-
39
- TEST_SASS_SPEC=1 vendor/bin/phpunit tests
40
-
41
- ## Coding Standard
42
-
43
- `scssphp` source conforms to [PSR12](https://www.php-fig.org/psr/psr-12/).
44
-
45
- Run the following command from the root directory to check the code for "sniffs".
46
-
47
- vendor/bin/phpcs --standard=PSR12 --extensions=php bin src tests *.php
48
-
49
- ## Static Analysis
50
-
51
- `scssphp` uses [phpstan](https://phpstan.org/) for static analysis.
52
-
53
- Run the following command from the root directory to analyse the codebase:
54
-
55
- make phpstan
56
-
57
- As most of the codebase is composed of legacy code which cannot be type-checked
58
- fully, the setup contains a baseline file with all errors we want to ignore. In
59
- particular, we ignore all errors related to not specifying the types inside arrays
60
- when these arrays correspond to the representation of Sass values and Sass AST nodes
61
- in the parser and compiler.
62
- When contributing, the proper process to deal with static analysis is the following:
63
-
64
- 1. Make your change in the codebase
65
- 2. Run `make phpstan`
66
- 3. Fix errors reported by phpstan when possible
67
- 4. Repeat step 2 and 3 until nothing gets fixed anymore at step 3
68
- 5. Run `make phpstan-baseline` to regenerate the phpstan baseline
69
-
70
- Additions to the baseline will be reviewed to avoid ignoring errors that should have
71
- been fixed.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
assets/libraries/scssphp/composer.json DELETED
@@ -1,108 +0,0 @@
1
- {
2
- "name": "scssphp/scssphp",
3
- "type": "library",
4
- "description": "scssphp is a compiler for SCSS written in PHP.",
5
- "keywords": ["css", "stylesheet", "scss", "sass", "less"],
6
- "homepage": "http://scssphp.github.io/scssphp/",
7
- "license": [
8
- "MIT"
9
- ],
10
- "authors": [
11
- {
12
- "name": "Anthon Pang",
13
- "email": "apang@softwaredevelopment.ca",
14
- "homepage": "https://github.com/robocoder"
15
- },
16
- {
17
- "name": "Cédric Morin",
18
- "email": "cedric@yterium.com",
19
- "homepage": "https://github.com/Cerdic"
20
- }
21
- ],
22
- "autoload": {
23
- "psr-4": { "ScssPhp\\ScssPhp\\": "src/" }
24
- },
25
- "autoload-dev": {
26
- "psr-4": { "ScssPhp\\ScssPhp\\Tests\\": "tests/" }
27
- },
28
- "require": {
29
- "php": ">=5.6.0",
30
- "ext-json": "*",
31
- "ext-ctype": "*"
32
- },
33
- "suggest": {
34
- "ext-mbstring": "For best performance, mbstring should be installed as it is faster than ext-iconv",
35
- "ext-iconv": "Can be used as fallback when ext-mbstring is not available"
36
- },
37
- "require-dev": {
38
- "bamarni/composer-bin-plugin": "^1.4",
39
- "phpunit/phpunit": "^5.7 || ^6.5 || ^7.5 || ^8.3 || ^9.4",
40
- "sass/sass-spec": "*",
41
- "squizlabs/php_codesniffer": "~3.5",
42
- "symfony/phpunit-bridge": "^5.1",
43
- "thoughtbot/bourbon": "^7.0",
44
- "twbs/bootstrap": "~5.0",
45
- "twbs/bootstrap4": "4.6.0",
46
- "zurb/foundation": "~6.5"
47
- },
48
- "repositories": [
49
- {
50
- "type": "package",
51
- "package": {
52
- "name": "sass/sass-spec",
53
- "version": "2021.09.15",
54
- "source": {
55
- "type": "git",
56
- "url": "https://github.com/sass/sass-spec.git",
57
- "reference": "eb2d7a0865c1faf0b55a39ff962b24aca9b4c955"
58
- },
59
- "dist": {
60
- "type": "zip",
61
- "url": "https://api.github.com/repos/sass/sass-spec/zipball/eb2d7a0865c1faf0b55a39ff962b24aca9b4c955",
62
- "reference": "eb2d7a0865c1faf0b55a39ff962b24aca9b4c955",
63
- "shasum": ""
64
- }
65
- }
66
- },
67
- {
68
- "type": "package",
69
- "package": {
70
- "name": "thoughtbot/bourbon",
71
- "version": "v7.0.0",
72
- "source": {
73
- "type": "git",
74
- "url": "https://github.com/thoughtbot/bourbon.git",
75
- "reference": "fbe338ee6807e7f7aa996d82c8a16f248bb149b3"
76
- },
77
- "dist": {
78
- "type": "zip",
79
- "url": "https://api.github.com/repos/thoughtbot/bourbon/zipball/fbe338ee6807e7f7aa996d82c8a16f248bb149b3",
80
- "reference": "fbe338ee6807e7f7aa996d82c8a16f248bb149b3",
81
- "shasum": ""
82
- }
83
- }
84
- },
85
- {
86
- "type": "package",
87
- "package": {
88
- "name": "twbs/bootstrap4",
89
- "version": "v4.6.0",
90
- "source": {
91
- "type": "git",
92
- "url": "https://github.com/twbs/bootstrap.git",
93
- "reference": "6ffb0b48e455430f8a5359ed689ad64c1143fac2"
94
- },
95
- "dist": {
96
- "type": "zip",
97
- "url": "https://api.github.com/repos/twbs/bootstrap/zipball/6ffb0b48e455430f8a5359ed689ad64c1143fac2",
98
- "reference": "6ffb0b48e455430f8a5359ed689ad64c1143fac2",
99
- "shasum": ""
100
- }
101
- }
102
- }
103
- ],
104
- "bin": ["bin/pscss"],
105
- "config": {
106
- "sort-packages": true
107
- }
108
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
assets/libraries/scssphp/scss.inc.php CHANGED
@@ -1,17 +1,14 @@
1
  <?php
2
 
3
- if (version_compare(PHP_VERSION, '5.6') < 0) {
4
- throw new \Exception('scssphp requires PHP 5.6 or above');
5
- }
6
 
7
- if (! class_exists('ScssPhp\ScssPhp\Version')) {
8
  spl_autoload_register(function ($class) {
9
- if (0 !== strpos($class, 'ScssPhp\ScssPhp\\')) {
10
  // Not a ScssPhp class
11
  return;
12
  }
13
 
14
- $subClass = substr($class, strlen('ScssPhp\ScssPhp\\'));
15
  $path = __DIR__ . '/src/' . str_replace('\\', '/', $subClass) . '.php';
16
 
17
  if (file_exists($path)) {
1
  <?php
2
 
 
 
 
3
 
4
+ if (! class_exists('\MaxButtons\ScssPhp\ScssPhp\Version')) {
5
  spl_autoload_register(function ($class) {
6
+ if (0 !== strpos($class, 'MaxButtons\ScssPhp\ScssPhp\\')) {
7
  // Not a ScssPhp class
8
  return;
9
  }
10
 
11
+ $subClass = substr($class, strlen('MaxButtons\ScssPhp\ScssPhp\\'));
12
  $path = __DIR__ . '/src/' . str_replace('\\', '/', $subClass) . '.php';
13
 
14
  if (file_exists($path)) {
assets/libraries/scssphp/src/Base/Range.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Base;
14
 
15
  /**
16
  * Range
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Base;
14
 
15
  /**
16
  * Range
assets/libraries/scssphp/src/Block.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
  /**
16
  * Block
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
  /**
16
  * Block
assets/libraries/scssphp/src/Cache.php CHANGED
@@ -10,10 +10,10 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
- use Exception;
16
- use ScssPhp\ScssPhp\Version;
17
 
18
  /**
19
  * The scss cache manager.
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
+ use MaxButtons\Exception;
16
+ use MaxButtons\ScssPhp\ScssPhp\Version;
17
 
18
  /**
19
  * The scss cache manager.
assets/libraries/scssphp/src/Colors.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
  /**
16
  * CSS Colors
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
  /**
16
  * CSS Colors
assets/libraries/scssphp/src/CompilationResult.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
  class CompilationResult
16
  {
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
  class CompilationResult
16
  {
assets/libraries/scssphp/src/Compiler.php CHANGED
@@ -10,23 +10,23 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
-
15
- use ScssPhp\ScssPhp\Base\Range;
16
- use ScssPhp\ScssPhp\Compiler\CachedResult;
17
- use ScssPhp\ScssPhp\Compiler\Environment;
18
- use ScssPhp\ScssPhp\Exception\CompilerException;
19
- use ScssPhp\ScssPhp\Exception\ParserException;
20
- use ScssPhp\ScssPhp\Exception\SassException;
21
- use ScssPhp\ScssPhp\Exception\SassScriptException;
22
- use ScssPhp\ScssPhp\Formatter\Compressed;
23
- use ScssPhp\ScssPhp\Formatter\Expanded;
24
- use ScssPhp\ScssPhp\Formatter\OutputBlock;
25
- use ScssPhp\ScssPhp\Logger\LoggerInterface;
26
- use ScssPhp\ScssPhp\Logger\StreamLogger;
27
- use ScssPhp\ScssPhp\Node\Number;
28
- use ScssPhp\ScssPhp\SourceMap\SourceMapGenerator;
29
- use ScssPhp\ScssPhp\Util\Path;
30
 
31
  /**
32
  * The scss compiler and parser.
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
+
15
+ use MaxButtons\ScssPhp\ScssPhp\Base\Range;
16
+ use MaxButtons\ScssPhp\ScssPhp\Compiler\CachedResult;
17
+ use MaxButtons\ScssPhp\ScssPhp\Compiler\Environment;
18
+ use MaxButtons\ScssPhp\ScssPhp\Exception\CompilerException;
19
+ use MaxButtons\ScssPhp\ScssPhp\Exception\ParserException;
20
+ use MaxButtons\ScssPhp\ScssPhp\Exception\SassException;
21
+ use MaxButtons\ScssPhp\ScssPhp\Exception\SassScriptException;
22
+ use MaxButtons\ScssPhp\ScssPhp\Formatter\Compressed;
23
+ use MaxButtons\ScssPhp\ScssPhp\Formatter\Expanded;
24
+ use MaxButtons\ScssPhp\ScssPhp\Formatter\OutputBlock;
25
+ use MaxButtons\ScssPhp\ScssPhp\Logger\LoggerInterface;
26
+ use MaxButtons\ScssPhp\ScssPhp\Logger\StreamLogger;
27
+ use MaxButtons\ScssPhp\ScssPhp\Node\Number;
28
+ use MaxButtons\ScssPhp\ScssPhp\SourceMap\SourceMapGenerator;
29
+ use MaxButtons\ScssPhp\ScssPhp\Util\Path;
30
 
31
  /**
32
  * The scss compiler and parser.
assets/libraries/scssphp/src/Compiler/CachedResult.php CHANGED
@@ -10,9 +10,9 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Compiler;
14
 
15
- use ScssPhp\ScssPhp\CompilationResult;
16
 
17
  /**
18
  * @internal
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Compiler;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\CompilationResult;
16
 
17
  /**
18
  * @internal
assets/libraries/scssphp/src/Compiler/Environment.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Compiler;
14
 
15
  /**
16
  * Compiler environment
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Compiler;
14
 
15
  /**
16
  * Compiler environment
assets/libraries/scssphp/src/Exception/CompilerException.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Exception;
14
 
15
  /**
16
  * Compiler exception
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Exception;
14
 
15
  /**
16
  * Compiler exception
assets/libraries/scssphp/src/Exception/ParserException.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Exception;
14
 
15
  /**
16
  * Parser Exception
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Exception;
14
 
15
  /**
16
  * Parser Exception
assets/libraries/scssphp/src/Exception/RangeException.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Exception;
14
 
15
  /**
16
  * Range exception
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Exception;
14
 
15
  /**
16
  * Range exception
assets/libraries/scssphp/src/Exception/SassException.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
 
3
- namespace ScssPhp\ScssPhp\Exception;
4
 
5
  interface SassException
6
  {
1
  <?php
2
 
3
+ namespace MaxButtons\ScssPhp\ScssPhp\Exception;
4
 
5
  interface SassException
6
  {
assets/libraries/scssphp/src/Exception/SassScriptException.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
 
3
- namespace ScssPhp\ScssPhp\Exception;
4
 
5
  /**
6
  * An exception thrown by SassScript.
1
  <?php
2
 
3
+ namespace MaxButtons\ScssPhp\ScssPhp\Exception;
4
 
5
  /**
6
  * An exception thrown by SassScript.
assets/libraries/scssphp/src/Exception/ServerException.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Exception;
14
 
15
  @trigger_error(sprintf('The "%s" class is deprecated.', ServerException::class), E_USER_DEPRECATED);
16
 
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Exception;
14
 
15
  @trigger_error(sprintf('The "%s" class is deprecated.', ServerException::class), E_USER_DEPRECATED);
16
 
assets/libraries/scssphp/src/Formatter.php CHANGED
@@ -10,10 +10,10 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
- use ScssPhp\ScssPhp\Formatter\OutputBlock;
16
- use ScssPhp\ScssPhp\SourceMap\SourceMapGenerator;
17
 
18
  /**
19
  * Base formatter
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Formatter\OutputBlock;
16
+ use MaxButtons\ScssPhp\ScssPhp\SourceMap\SourceMapGenerator;
17
 
18
  /**
19
  * Base formatter
assets/libraries/scssphp/src/Formatter/Compact.php CHANGED
@@ -10,9 +10,9 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Formatter;
14
 
15
- use ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Compact formatter
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Formatter;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Compact formatter
assets/libraries/scssphp/src/Formatter/Compressed.php CHANGED
@@ -10,9 +10,9 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Formatter;
14
 
15
- use ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Compressed formatter
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Formatter;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Compressed formatter
assets/libraries/scssphp/src/Formatter/Crunched.php CHANGED
@@ -10,9 +10,9 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Formatter;
14
 
15
- use ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Crunched formatter
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Formatter;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Crunched formatter
assets/libraries/scssphp/src/Formatter/Debug.php CHANGED
@@ -10,9 +10,9 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Formatter;
14
 
15
- use ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Debug formatter
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Formatter;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Debug formatter
assets/libraries/scssphp/src/Formatter/Expanded.php CHANGED
@@ -10,9 +10,9 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Formatter;
14
 
15
- use ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Expanded formatter
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Formatter;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Formatter;
16
 
17
  /**
18
  * Expanded formatter
assets/libraries/scssphp/src/Formatter/Nested.php CHANGED
@@ -10,10 +10,10 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Formatter;
14
 
15
- use ScssPhp\ScssPhp\Formatter;
16
- use ScssPhp\ScssPhp\Type;
17
 
18
  /**
19
  * Nested formatter
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Formatter;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Formatter;
16
+ use MaxButtons\ScssPhp\ScssPhp\Type;
17
 
18
  /**
19
  * Nested formatter
assets/libraries/scssphp/src/Formatter/OutputBlock.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Formatter;
14
 
15
  /**
16
  * Output block
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Formatter;
14
 
15
  /**
16
  * Output block
assets/libraries/scssphp/src/Logger/LoggerInterface.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Logger;
14
 
15
  /**
16
  * Interface implemented by loggers for warnings and debug messages.
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Logger;
14
 
15
  /**
16
  * Interface implemented by loggers for warnings and debug messages.
assets/libraries/scssphp/src/Logger/QuietLogger.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Logger;
14
 
15
  /**
16
  * A logger that silently ignores all messages.
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Logger;
14
 
15
  /**
16
  * A logger that silently ignores all messages.
assets/libraries/scssphp/src/Logger/StreamLogger.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Logger;
14
 
15
  /**
16
  * A logger that prints to a PHP stream (for instance stderr)
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Logger;
14
 
15
  /**
16
  * A logger that prints to a PHP stream (for instance stderr)
assets/libraries/scssphp/src/Node.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
  /**
16
  * Base node
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
  /**
16
  * Base node
assets/libraries/scssphp/src/Node/Number.php CHANGED
@@ -10,15 +10,15 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\Node;
14
-
15
- use ScssPhp\ScssPhp\Base\Range;
16
- use ScssPhp\ScssPhp\Compiler;
17
- use ScssPhp\ScssPhp\Exception\RangeException;
18
- use ScssPhp\ScssPhp\Exception\SassScriptException;
19
- use ScssPhp\ScssPhp\Node;
20
- use ScssPhp\ScssPhp\Type;
21
- use ScssPhp\ScssPhp\Util;
22
 
23
  /**
24
  * Dimension + optional units
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\Node;
14
+
15
+ use MaxButtons\ScssPhp\ScssPhp\Base\Range;
16
+ use MaxButtons\ScssPhp\ScssPhp\Compiler;
17
+ use MaxButtons\ScssPhp\ScssPhp\Exception\RangeException;
18
+ use MaxButtons\ScssPhp\ScssPhp\Exception\SassScriptException;
19
+ use MaxButtons\ScssPhp\ScssPhp\Node;
20
+ use MaxButtons\ScssPhp\ScssPhp\Type;
21
+ use MaxButtons\ScssPhp\ScssPhp\Util;
22
 
23
  /**
24
  * Dimension + optional units
assets/libraries/scssphp/src/OutputStyle.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
 
3
- namespace ScssPhp\ScssPhp;
4
 
5
  final class OutputStyle
6
  {
1
  <?php
2
 
3
+ namespace MaxButtons\ScssPhp\ScssPhp;
4
 
5
  final class OutputStyle
6
  {
assets/libraries/scssphp/src/Parser.php CHANGED
@@ -10,11 +10,11 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
- use ScssPhp\ScssPhp\Exception\ParserException;
16
- use ScssPhp\ScssPhp\Logger\LoggerInterface;
17
- use ScssPhp\ScssPhp\Logger\QuietLogger;
18
 
19
  /**
20
  * Parser
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Exception\ParserException;
16
+ use MaxButtons\ScssPhp\ScssPhp\Logger\LoggerInterface;
17
+ use MaxButtons\ScssPhp\ScssPhp\Logger\QuietLogger;
18
 
19
  /**
20
  * Parser
assets/libraries/scssphp/src/SourceMap/Base64.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\SourceMap;
14
 
15
  /**
16
  * Base 64 Encode/Decode
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\SourceMap;
14
 
15
  /**
16
  * Base 64 Encode/Decode
assets/libraries/scssphp/src/SourceMap/Base64VLQ.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\SourceMap;
14
 
15
  /**
16
  * Base 64 VLQ
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\SourceMap;
14
 
15
  /**
16
  * Base 64 VLQ
assets/libraries/scssphp/src/SourceMap/SourceMapGenerator.php CHANGED
@@ -10,9 +10,9 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp\SourceMap;
14
 
15
- use ScssPhp\ScssPhp\Exception\CompilerException;
16
 
17
  /**
18
  * Source Map Generator
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp\SourceMap;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Exception\CompilerException;
16
 
17
  /**
18
  * Source Map Generator
assets/libraries/scssphp/src/Type.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
  /**
16
  * Block/node types
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
  /**
16
  * Block/node types
assets/libraries/scssphp/src/Util.php CHANGED
@@ -10,11 +10,11 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
- use ScssPhp\ScssPhp\Base\Range;
16
- use ScssPhp\ScssPhp\Exception\RangeException;
17
- use ScssPhp\ScssPhp\Node\Number;
18
 
19
  /**
20
  * Utility functions
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Base\Range;
16
+ use MaxButtons\ScssPhp\ScssPhp\Exception\RangeException;
17
+ use MaxButtons\ScssPhp\ScssPhp\Node\Number;
18
 
19
  /**
20
  * Utility functions
assets/libraries/scssphp/src/Util/Path.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
 
3
- namespace ScssPhp\ScssPhp\Util;
4
 
5
  /**
6
  * @internal
1
  <?php
2
 
3
+ namespace MaxButtons\ScssPhp\ScssPhp\Util;
4
 
5
  /**
6
  * @internal
assets/libraries/scssphp/src/ValueConverter.php CHANGED
@@ -10,9 +10,9 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
- use ScssPhp\ScssPhp\Node\Number;
16
 
17
  final class ValueConverter
18
  {
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
+ use MaxButtons\ScssPhp\ScssPhp\Node\Number;
16
 
17
  final class ValueConverter
18
  {
assets/libraries/scssphp/src/Version.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
  /**
16
  * SCSSPHP version
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
  /**
16
  * SCSSPHP version
assets/libraries/scssphp/src/Warn.php CHANGED
@@ -10,7 +10,7 @@
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
- namespace ScssPhp\ScssPhp;
14
 
15
  final class Warn
16
  {
10
  * @link http://scssphp.github.io/scssphp
11
  */
12
 
13
+ namespace MaxButtons\ScssPhp\ScssPhp;
14
 
15
  final class Warn
16
  {
assets/libraries/simplehtmldom/simple_html_dom.php CHANGED
@@ -1,4 +1,6 @@
1
  <?php
 
 
2
  /** https://simplehtmldom.sourceforge.io/docs/1.9/index.html
3
 
4
  * Website: http://sourceforge.net/projects/simplehtmldom/
1
  <?php
2
+ namespace MaxButtons;
3
+
4
  /** https://simplehtmldom.sourceforge.io/docs/1.9/index.html
5
 
6
  * Website: http://sourceforge.net/projects/simplehtmldom/
blocks/container.php CHANGED
@@ -4,7 +4,7 @@ defined('ABSPATH') or die('No direct access permitted');
4
  $blockClass["container"] = "containerBlock";
5
  $blockOrder[70][] = "container";
6
 
7
- use \simple_html_dom as simple_html_dom;
8
 
9
  class containerBlock extends maxBlock
10
  {
4
  $blockClass["container"] = "containerBlock";
5
  $blockOrder[70][] = "container";
6
 
7
+ //use \simple_html_dom as simple_html_dom;
8
 
9
  class containerBlock extends maxBlock
10
  {
classes/button.php CHANGED
@@ -5,7 +5,7 @@ defined('ABSPATH') or die('No direct access permitted');
5
  /* Datamodel and base functionality for a button
6
  */
7
 
8
- use \simple_html_dom as simple_html_dom;
9
 
10
  class maxButton
11
  {
@@ -665,7 +665,7 @@ class maxButton
665
 
666
  }
667
  /* Remove the button from database
668
- *
669
  */
670
  public function delete(int $id)
671
  {
5
  /* Datamodel and base functionality for a button
6
  */
7
 
8
+ //use simple_html_dom as simple_html_dom;
9
 
10
  class maxButton
11
  {
665
 
666
  }
667
  /* Remove the button from database
668
+ *
669
  */
670
  public function delete(int $id)
671
  {
classes/maxCSSParser.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  namespace MaxButtons;
3
- use ScssPhp\ScssPhp\Compiler;
4
 
5
  defined('ABSPATH') or die('No direct access permitted');
6
 
@@ -79,7 +79,6 @@ class maxCSSParser
79
 
80
  $this->struct = $struct;
81
 
82
-
83
  }
84
 
85
 
@@ -171,7 +170,7 @@ class maxCSSParser
171
 
172
  if ($minify == 1)
173
  {
174
- $scss->setOutputStyle(\ScssPhp\ScssPhp\OutputStyle::COMPRESSED);
175
  }
176
 
177
  $compile = ' @import "_mixins.scss";' . $css;
@@ -179,7 +178,7 @@ class maxCSSParser
179
  //maxUtils::addTime("CSSParser: Compile start ");
180
  try
181
  {
182
- $css = $scss->compileString($compile)->getCss();
183
  } catch (\Exception $e) {
184
  $this->has_compile_error = true;
185
  $this->compile_error = array('error' => $e,
1
  <?php
2
  namespace MaxButtons;
3
+ use MaxButtons\ScssPhp\ScssPhp\Compiler as Compiler;
4
 
5
  defined('ABSPATH') or die('No direct access permitted');
6
 
79
 
80
  $this->struct = $struct;
81
 
 
82
  }
83
 
84
 
170
 
171
  if ($minify == 1)
172
  {
173
+ $scss->setOutputStyle(\MaxButtons\ScssPhp\ScssPhp\OutputStyle::COMPRESSED);
174
  }
175
 
176
  $compile = ' @import "_mixins.scss";' . $css;
178
  //maxUtils::addTime("CSSParser: Compile start ");
179
  try
180
  {
181
+ $css = $scss->compileString($compile)->getCss();
182
  } catch (\Exception $e) {
183
  $this->has_compile_error = true;
184
  $this->compile_error = array('error' => $e,
classes/maxbuttons-class.php CHANGED
@@ -433,7 +433,7 @@ class maxButtonsPlugin
433
 
434
  if ($libname == 'simplehtmldom')
435
  {
436
- if (! class_exists('simple_html_dom_node'))
437
  require_once($this->get_plugin_path() . "assets/libraries/simplehtmldom/simple_html_dom.php");
438
  }
439
 
433
 
434
  if ($libname == 'simplehtmldom')
435
  {
436
+ // if (! class_exists('simple_html_dom_node'))
437
  require_once($this->get_plugin_path() . "assets/libraries/simplehtmldom/simple_html_dom.php");
438
  }
439
 
js/maxajax.js CHANGED
@@ -22,7 +22,7 @@ maxAjax.prototype.ajaxInit = function()
22
  {
23
  data = {
24
  action: maxajax.ajax_action,
25
- nonce: maxajax.nonce,
26
  }
27
 
28
  return data;
@@ -47,7 +47,6 @@ maxAjax.prototype.ajaxForm = function (e)
47
  var data = this.ajaxInit();
48
  data['form'] = form.serialize();
49
  data['plugin_action'] = action;
50
- // data['action'] = 'mb_button_action';
51
 
52
  $(document).trigger('maxajax_formpost_' + action, [data,target]);
53
 
@@ -98,9 +97,7 @@ maxAjax.prototype.showSpinner = function(target)
98
  {
99
  // spinner styling in elements
100
  var spinner = '<div class="maxajax-load-spinner"></div>';
101
- //$('.maxajax-load-spinner').remove();
102
  $(target).after(spinner);
103
- //return spinner;
104
  }
105
 
106
  maxAjax.prototype.removeSpinner = function()
22
  {
23
  data = {
24
  action: maxajax.ajax_action,
25
+ nonce: maxajax.nonce
26
  }
27
 
28
  return data;
47
  var data = this.ajaxInit();
48
  data['form'] = form.serialize();
49
  data['plugin_action'] = action;
 
50
 
51
  $(document).trigger('maxajax_formpost_' + action, [data,target]);
52
 
97
  {
98
  // spinner styling in elements
99
  var spinner = '<div class="maxajax-load-spinner"></div>';
 
100
  $(target).after(spinner);
 
101
  }
102
 
103
  maxAjax.prototype.removeSpinner = function()
js/maxmodal.js CHANGED
@@ -104,7 +104,7 @@ jQuery(document).ready(function(jq) {
104
  $(document).off('keydown', $.proxy(this.keyPressHandler, this));
105
  $(document).on('keydown', $.proxy(this.keyPressHandler, this));
106
 
107
- this.currentModal.focus();
108
  }
109
 
110
  maxModal.prototype.keyPressHandler = function (e)
104
  $(document).off('keydown', $.proxy(this.keyPressHandler, this));
105
  $(document).on('keydown', $.proxy(this.keyPressHandler, this));
106
 
107
+ this.currentModal.trigger('focus');
108
  }
109
 
110
  maxModal.prototype.keyPressHandler = function (e)
js/min/maxmodal.js CHANGED
@@ -1 +1 @@
1
- var maxModal;jQuery(document).ready(function(t){$=t,(maxModal=function(){}).prototype={currentModal:null,modals:[],controls:[],parent:"#maxbuttons",multiple:!1,windowHeight:!1,windowWidth:!1,setWidth:!1,setHeight:!1,target:!1},maxModal.prototype.init=function(){this.windowHeight=$(window).height(),this.windowWidth=$(window).width(),$(document).off("click",".maxmodal"),$(document).on("click",".maxmodal",$.proxy(this.buildModal,this)),$(window).on("resize",$.proxy(this.checkResize,this))},maxModal.prototype.focus=function(){this.currentModal.show()},maxModal.prototype.get=function(){return this.currentModal},maxModal.prototype.show=function(){$(".maxmodal_overlay").remove(),$("body").removeClass("max-modal-active"),this.writeOverlay(),this.currentModal.show(),this.setWidth&&this.currentModal.width(this.setWidth),this.setHeight&&this.currentModal.height(this.setHeight),$m=this.currentModal;var t=$m.find(".modal_header").outerHeight(),o=$m.find(".modal_content").outerHeight(),e=$m.find(".modal_content").width(),a=$m.find(".modal_controls").outerHeight(),i=t+o+a,d=e,n=(this.windowHeight-i)/2,s=(this.windowWidth-d)/2;if(n<30&&(n=30),i>this.windowHeight){newHeight=this.windowHeight-n-5,this.currentModal.height(newHeight);var l=newHeight-t-a;$m.find(".modal_content").height(l)}this.currentModal.css("left",s+"px"),this.currentModal.css("top",n+"px"),this.currentModal.css("height",i),$(".maxmodal_overlay").show(),$("body").addClass("max-modal-active"),$(document).off("keydown",$.proxy(this.keyPressHandler,this)),$(document).on("keydown",$.proxy(this.keyPressHandler,this)),this.currentModal.focus()},maxModal.prototype.keyPressHandler=function(t){27===t.keyCode&&this.close()},maxModal.prototype.checkResize=function(){this.windowHeight=$(window).height(),this.windowWidth=$(window).width(),null!==this.currentModal&&(this.currentModal.removeAttr("style"),this.currentModal.find(".modal_content").removeAttr("style"),this.currentModal.removeAttr("style"),this.show())},maxModal.prototype.close=function(){this.currentModal.trigger("modal_close",[this]),this.currentModal.remove(),this.currentModal=null,$(".maxmodal_overlay").remove(),$("body").removeClass("max-modal-active"),$(document).off("keydown",$.proxy(this.keyPressHandler,this))},maxModal.prototype.fadeOut=function(t){void 0==typeof t&&(t=600);var o=this;this.currentModal.fadeOut(t,function(){o.close()})},maxModal.prototype.setTitle=function(t){this.currentModal.find(".modal_title").text(t)},maxModal.prototype.resetControls=function(){this.controls=[]},maxModal.prototype.setControls=function(t){var o=this.currentModal.find(".modal_content"),e=$('<div class="modal_controls controls">');for(i=0;i<this.controls.length;i++)e.append(this.controls[i]);void 0!==t&&e.append(t),o.append(e),$(this.currentModal).find(".modal_close").off("click"),$(this.currentModal).find(".modal_close").on("click",$.proxy(this.close,this))},maxModal.prototype.addControl=function(t,o,e){var a="";switch(t){case"yes":a=modaltext.yes;break;case"ok":a=modaltext.ok;break;case"no":a=modaltext.no;break;case"cancel":a=modaltext.cancel;break;default:a=t,t="custom"}var i=$('<a class="button-primary '+t+'">'+a+"</a>");i.on("click",o,e),this.controls.push(i)},maxModal.prototype.setContent=function(t){null!==this.currentModal&&this.currentModal.find(".modal_content").html(t)},maxModal.prototype.buildModal=function(t){t.preventDefault();var o=$(t.target);void 0===o.data("modal")&&(o=o.parents(".maxmodal")),this.target=o;var e=o.data("modal"),a=$("#"+e);void 0!==a.data("width")?this.setWidth=a.data("width"):this.setWidth=!1,void 0!==a.data("height")?this.setHeight=a.data("height"):this.setHeight=!1;var i=$(a).find(".title").text(),d=$(a).find(".controls").html(),n=$(a).find(".content").html();if(this.newModal(e),this.setTitle(i),this.setContent(n),this.setControls(d),void 0!==$(a).data("load")){var s=a.data("load")+"(modal)",l=new Function("modal",s);try{l(this)}catch(t){console.error("MB Modal Callback Error: "+t.message),console.error("MB Modal tried calling: "+s)}}this.show()},maxModal.prototype.newModal=function(t){null!==this.currentModal&&this.close();var o=$('<div class="max-modal '+t+'" > \t\t\t\t\t\t <div class="modal_header"> \t\t\t\t\t\t\t <div class="modal_close dashicons dashicons-no"></div><h3 class="modal_title"></h3> \t\t\t\t\t\t </div> \t\t\t\t\t\t <div class="inner modal_content"></div>\t\t\t\t\t </div>');return $(this.parent).length>0?$(this.parent).append(o):$("body").append(o),$(o).draggable({handle:".modal_header"}),this.modals.push(o),this.currentModal=o,this.controls=[],this},maxModal.prototype.writeOverlay=function(){$(this.parent).append('<div class="maxmodal_overlay"></div>'),$(".maxmodal_overlay").on("click",$.proxy(this.close,this))}});
1
+ var maxModal;jQuery(document).ready(function(t){$=t,(maxModal=function(){}).prototype={currentModal:null,modals:[],controls:[],parent:"#maxbuttons",multiple:!1,windowHeight:!1,windowWidth:!1,setWidth:!1,setHeight:!1,target:!1},maxModal.prototype.init=function(){this.windowHeight=$(window).height(),this.windowWidth=$(window).width(),$(document).off("click",".maxmodal"),$(document).on("click",".maxmodal",$.proxy(this.buildModal,this)),$(window).on("resize",$.proxy(this.checkResize,this))},maxModal.prototype.focus=function(){this.currentModal.show()},maxModal.prototype.get=function(){return this.currentModal},maxModal.prototype.show=function(){$(".maxmodal_overlay").remove(),$("body").removeClass("max-modal-active"),this.writeOverlay(),this.currentModal.show(),this.setWidth&&this.currentModal.width(this.setWidth),this.setHeight&&this.currentModal.height(this.setHeight),$m=this.currentModal;var t=$m.find(".modal_header").outerHeight(),o=$m.find(".modal_content").outerHeight(),e=$m.find(".modal_content").width(),a=$m.find(".modal_controls").outerHeight(),i=t+o+a,d=e,n=(this.windowHeight-i)/2,s=(this.windowWidth-d)/2;if(n<30&&(n=30),i>this.windowHeight){newHeight=this.windowHeight-n-5,this.currentModal.height(newHeight);var l=newHeight-t-a;$m.find(".modal_content").height(l)}this.currentModal.css("left",s+"px"),this.currentModal.css("top",n+"px"),this.currentModal.css("height",i),$(".maxmodal_overlay").show(),$("body").addClass("max-modal-active"),$(document).off("keydown",$.proxy(this.keyPressHandler,this)),$(document).on("keydown",$.proxy(this.keyPressHandler,this)),this.currentModal.trigger("focus")},maxModal.prototype.keyPressHandler=function(t){27===t.keyCode&&this.close()},maxModal.prototype.checkResize=function(){this.windowHeight=$(window).height(),this.windowWidth=$(window).width(),null!==this.currentModal&&(this.currentModal.removeAttr("style"),this.currentModal.find(".modal_content").removeAttr("style"),this.currentModal.removeAttr("style"),this.show())},maxModal.prototype.close=function(){this.currentModal.trigger("modal_close",[this]),this.currentModal.remove(),this.currentModal=null,$(".maxmodal_overlay").remove(),$("body").removeClass("max-modal-active"),$(document).off("keydown",$.proxy(this.keyPressHandler,this))},maxModal.prototype.fadeOut=function(t){void 0==typeof t&&(t=600);var o=this;this.currentModal.fadeOut(t,function(){o.close()})},maxModal.prototype.setTitle=function(t){this.currentModal.find(".modal_title").text(t)},maxModal.prototype.resetControls=function(){this.controls=[]},maxModal.prototype.setControls=function(t){var o=this.currentModal.find(".modal_content"),e=$('<div class="modal_controls controls">');for(i=0;i<this.controls.length;i++)e.append(this.controls[i]);void 0!==t&&e.append(t),o.append(e),$(this.currentModal).find(".modal_close").off("click"),$(this.currentModal).find(".modal_close").on("click",$.proxy(this.close,this))},maxModal.prototype.addControl=function(t,o,e){var a="";switch(t){case"yes":a=modaltext.yes;break;case"ok":a=modaltext.ok;break;case"no":a=modaltext.no;break;case"cancel":a=modaltext.cancel;break;default:a=t,t="custom"}var i=$('<a class="button-primary '+t+'">'+a+"</a>");i.on("click",o,e),this.controls.push(i)},maxModal.prototype.setContent=function(t){null!==this.currentModal&&this.currentModal.find(".modal_content").html(t)},maxModal.prototype.buildModal=function(t){t.preventDefault();var o=$(t.target);void 0===o.data("modal")&&(o=o.parents(".maxmodal")),this.target=o;var e=o.data("modal"),a=$("#"+e);void 0!==a.data("width")?this.setWidth=a.data("width"):this.setWidth=!1,void 0!==a.data("height")?this.setHeight=a.data("height"):this.setHeight=!1;var i=$(a).find(".title").text(),d=$(a).find(".controls").html(),n=$(a).find(".content").html();if(this.newModal(e),this.setTitle(i),this.setContent(n),this.setControls(d),void 0!==$(a).data("load")){var s=a.data("load")+"(modal)",l=new Function("modal",s);try{l(this)}catch(t){console.error("MB Modal Callback Error: "+t.message),console.error("MB Modal tried calling: "+s)}}this.show()},maxModal.prototype.newModal=function(t){null!==this.currentModal&&this.close();var o=$('<div class="max-modal '+t+'" > \t\t\t\t\t\t <div class="modal_header"> \t\t\t\t\t\t\t <div class="modal_close dashicons dashicons-no"></div><h3 class="modal_title"></h3> \t\t\t\t\t\t </div> \t\t\t\t\t\t <div class="inner modal_content"></div>\t\t\t\t\t </div>');return $(this.parent).length>0?$(this.parent).append(o):$("body").append(o),$(o).draggable({handle:".modal_header"}),this.modals.push(o),this.currentModal=o,this.controls=[],this},maxModal.prototype.writeOverlay=function(){$(this.parent).append('<div class="maxmodal_overlay"></div>'),$(".maxmodal_overlay").on("click",$.proxy(this.close,this))}});
maxbuttons.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: MaxButtons
4
  Plugin URI: http://maxbuttons.com
5
  Description: The best WordPress button generator. This is the free version; the Pro version <a href="http://maxbuttons.com/?ref=mbfree">can be found here</a>.
6
- Version: 8.8
7
  Author: Max Foundry
8
  Author URI: http://maxfoundry.com
9
  Text Domain: maxbuttons
@@ -16,9 +16,9 @@ namespace MaxButtons;
16
  if (! defined('MAXBUTTONS_ROOT_FILE'))
17
  define("MAXBUTTONS_ROOT_FILE", __FILE__);
18
  if (! defined('MAXBUTTONS_VERSION_NUM'))
19
- define('MAXBUTTONS_VERSION_NUM', '8.8');
20
 
21
- define('MAXBUTTONS_RELEASE',"30 September 2021");
22
 
23
  if (! function_exists('MaxButtons\maxbutton_double_load'))
24
  {
3
  Plugin Name: MaxButtons
4
  Plugin URI: http://maxbuttons.com
5
  Description: The best WordPress button generator. This is the free version; the Pro version <a href="http://maxbuttons.com/?ref=mbfree">can be found here</a>.
6
+ Version: 8.8.1
7
  Author: Max Foundry
8
  Author URI: http://maxfoundry.com
9
  Text Domain: maxbuttons
16
  if (! defined('MAXBUTTONS_ROOT_FILE'))
17
  define("MAXBUTTONS_ROOT_FILE", __FILE__);
18
  if (! defined('MAXBUTTONS_VERSION_NUM'))
19
+ define('MAXBUTTONS_VERSION_NUM', '8.8.1');
20
 
21
+ define('MAXBUTTONS_RELEASE',"8 October 2021");
22
 
23
  if (! function_exists('MaxButtons\maxbutton_double_load'))
24
  {
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: wordpress button plugin, share button, wordpress buttons, css3 button gene
4
  Requires at least: 4.8
5
  Tested up to: 5.8
6
  Requires PHP: 7.0
7
- Stable tag: 8.8
8
  WordPress button plugin so powerful and easy to use anyone can create beautiful buttons, share buttons and social icons.
9
 
10
  == Description ==
@@ -268,6 +268,10 @@ Secondly, please use latin only characters for button name ( Basic settings) and
268
 
269
  == Changelog ==
270
 
 
 
 
 
271
  = 8.8 =
272
 
273
  * Updated SCSSPHP library to 1.8.1
4
  Requires at least: 4.8
5
  Tested up to: 5.8
6
  Requires PHP: 7.0
7
+ Stable tag: 8.8.1
8
  WordPress button plugin so powerful and easy to use anyone can create beautiful buttons, share buttons and social icons.
9
 
10
  == Description ==
268
 
269
  == Changelog ==
270
 
271
+ = 8.8.1 =
272
+
273
+ * Fix - Moved external libraries to own namespace to prevent conflicts.
274
+
275
  = 8.8 =
276
 
277
  * Updated SCSSPHP library to 1.8.1