diff --git a/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/.gitignore b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/.gitignore new file mode 100644 index 000000000..d1502b087 --- /dev/null +++ b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/.gitignore @@ -0,0 +1,2 @@ +vendor/ +composer.lock diff --git a/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/LICENSE b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/LICENSE new file mode 100644 index 000000000..3561efb48 --- /dev/null +++ b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2018 Vasil Rangelov + +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. diff --git a/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/composer.json b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/composer.json new file mode 100644 index 000000000..8c9f76912 --- /dev/null +++ b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/composer.json @@ -0,0 +1,31 @@ +{ + "name": "boenrobot/money_format_polyfill", + "description": "A polyfill for PHP's money_format() function, intended for Windows. Source from Rafael M. Salvioni (in the comments for money_format()).", + "license": "MIT", + "authors": [ + { + "name": "Vasil Rangelov", + "email": "boen.robot@gmail.com" + } + ], + "require": { + }, + "require-dev": { + "squizlabs/php_codesniffer": "@stable" + }, + "suggest": { + "boenrobot/composer-install-library-of-functions": "To remove the polyfill from the autoloader if not needed." + }, + "extra": { + "functionmap": { + "autoload": { + "money_format": "src/money_format.php" + } + } + }, + "autoload": { + "files": [ + "src/money_format.php" + ] + } +} diff --git a/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/phpcs.xml b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/phpcs.xml new file mode 100644 index 000000000..d1acbd531 --- /dev/null +++ b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/phpcs.xml @@ -0,0 +1,11 @@ + + + The money_format polyfill CS (which is PEAR). + src + + + + + + + diff --git a/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/src/money_format.php b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/src/money_format.php new file mode 100644 index 000000000..f83a52790 --- /dev/null +++ b/htdocs/class/libraries/vendor/boenrobot/money_format_polyfill/src/money_format.php @@ -0,0 +1,111 @@ + preg_match('/\=(.)/', $fmatch[1], $match) ? + $match[1] : ' ', + 'nogroup' => preg_match('/\^/', $fmatch[1]) > 0, + 'usesignal' => preg_match('/\+|\(/', $fmatch[1], $match) ? + $match[0] : '+', + 'nosimbol' => preg_match('/\!/', $fmatch[1]) > 0, + 'isleft' => preg_match('/\-/', $fmatch[1]) > 0 + ); + $width = trim($fmatch[2]) ? (int)$fmatch[2] : 0; + $left = trim($fmatch[3]) ? (int)$fmatch[3] : 0; + $right = trim($fmatch[4]) === '' + ? $locale['int_frac_digits'] : (int)$fmatch[4]; + $conversion = $fmatch[5]; + + $positive = true; + if ($value < 0) { + $positive = false; + $value *= -1; + } + $letter = $positive ? 'p' : 'n'; + + $prefix = $suffix = $cprefix = $csuffix = $signal = ''; + + $signal = $positive + ? $locale['positive_sign'] : $locale['negative_sign']; + switch (true) { + case $locale["{$letter}_sign_posn"] == 1 && $flags['usesignal'] == '+': + $prefix = $signal; + break; + case $locale["{$letter}_sign_posn"] == 2 && $flags['usesignal'] == '+': + $suffix = $signal; + break; + case $locale["{$letter}_sign_posn"] == 3 && $flags['usesignal'] == '+': + $cprefix = $signal; + break; + case $locale["{$letter}_sign_posn"] == 4 && $flags['usesignal'] == '+': + $csuffix = $signal; + break; + case $flags['usesignal'] == '(' && $letter === 'n': + case $locale["{$letter}_sign_posn"] == 0: + $prefix = '('; + $suffix = ')'; + break; + } + if (!$flags['nosimbol']) { + $currency = $cprefix . ($conversion == 'i' + ? $locale['int_curr_symbol'] : $locale['currency_symbol'] + ) . $csuffix; + } else { + $currency = ''; + } + $space = $locale["{$letter}_sep_by_space"] ? ' ' : ''; + + $value = number_format( + $value, + $right, + $locale['mon_decimal_point'], + $flags['nogroup'] ? '' : $locale['mon_thousands_sep'] + ); + $value = @explode($locale['mon_decimal_point'], $value); + + $n = strlen($prefix) + strlen($currency) + strlen($value[0]); + if ($left > 0 && $left > $n) { + $value[0] = str_repeat($flags['fillchar'], $left - $n) . $value[0]; + } + $value = implode($locale['mon_decimal_point'], $value); + if ($locale["{$letter}_cs_precedes"]) { + $value = $prefix . $currency . $space . $value . $suffix; + } else { + $value = $prefix . $value . $space . $currency . $suffix; + } + if ($width > 0) { + $value = str_pad( + $value, + $width, + $flags['fillchar'], + $flags['isleft'] ? STR_PAD_RIGHT : STR_PAD_LEFT + ); + } + + $format = str_replace($fmatch[0], $value, $format); + } + return $format; + } +} diff --git a/htdocs/class/libraries/vendor/firebase/php-jwt/src/Key.php b/htdocs/class/libraries/vendor/firebase/php-jwt/src/Key.php new file mode 100644 index 000000000..f1ede6f27 --- /dev/null +++ b/htdocs/class/libraries/vendor/firebase/php-jwt/src/Key.php @@ -0,0 +1,59 @@ +keyMaterial = $keyMaterial; + $this->algorithm = $algorithm; + } + + /** + * Return the algorithm valid for this key + * + * @return string + */ + public function getAlgorithm() + { + return $this->algorithm; + } + + /** + * @return string|resource|OpenSSLAsymmetricKey + */ + public function getKeyMaterial() + { + return $this->keyMaterial; + } +} diff --git a/htdocs/class/libraries/vendor/xoops/xmf/.github/workflows/pr_tests.yml b/htdocs/class/libraries/vendor/xoops/xmf/.github/workflows/pr_tests.yml new file mode 100644 index 000000000..cb58324d0 --- /dev/null +++ b/htdocs/class/libraries/vendor/xoops/xmf/.github/workflows/pr_tests.yml @@ -0,0 +1,24 @@ +name: CI + +on: [push, pull_request] + +jobs: + phpunit: + strategy: + fail-fast: false + matrix: + php_version: ["7.1", "7.4"] + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + - uses: php-actions/composer@v6 + with: + php_version: "7.4" + - name: Setup PHP + uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php_version }} + coverage: xdebug + - name: Unit Tests + run: vendor/bin/phpunit --stderr