mirror of
https://github.com/chillerlan/php-qrcode.git
synced 2026-08-17 15:12:32 +00:00
:octocat: switch phan for phpstan (see #277)
This commit is contained in:
@@ -56,6 +56,8 @@ class QRImagickImageAsBackground extends QRImagick{
|
||||
|
||||
/**
|
||||
* augment the QROptions class
|
||||
*
|
||||
* @property string $background
|
||||
*/
|
||||
class ImageAsBackgroundOptions extends QROptions{
|
||||
|
||||
|
||||
@@ -65,6 +65,8 @@ class QRImagickWithLogo extends QRImagick{
|
||||
|
||||
/**
|
||||
* augment the QROptions class
|
||||
*
|
||||
* @property string $pngLogo
|
||||
*/
|
||||
class ImagickWithLogoOptions extends QROptions{
|
||||
|
||||
|
||||
@@ -13,6 +13,15 @@ use chillerlan\QRCode\Data\QRMatrix;
|
||||
|
||||
require_once '../vendor/autoload.php';
|
||||
|
||||
/**
|
||||
* @param array<string, mixed> $response
|
||||
*/
|
||||
function sendResponse(array $response):never{
|
||||
header('Content-type: application/json;charset=utf-8;');
|
||||
echo json_encode($response);
|
||||
exit;
|
||||
}
|
||||
|
||||
try{
|
||||
|
||||
$moduleValues = [
|
||||
@@ -89,14 +98,3 @@ catch(Throwable $e){
|
||||
header('HTTP/1.1 500 Internal Server Error');
|
||||
sendResponse(['error' => $e->getMessage()]);
|
||||
}
|
||||
|
||||
exit;
|
||||
|
||||
/**
|
||||
* @param array $response
|
||||
*/
|
||||
function sendResponse(array $response){
|
||||
header('Content-type: application/json;charset=utf-8;');
|
||||
echo json_encode($response);
|
||||
exit;
|
||||
}
|
||||
|
||||
@@ -217,6 +217,10 @@ class MeltedSVGQRCodeOutput extends QRMarkupSVG{
|
||||
|
||||
/**
|
||||
* the augmented options class
|
||||
*
|
||||
* @property bool $melt
|
||||
* @property bool $inverseMelt
|
||||
* @property float $meltRadius
|
||||
*/
|
||||
class MeltedOutputOptions extends QROptions{
|
||||
|
||||
|
||||
@@ -81,13 +81,19 @@ class RandomDotsSVGOutput extends QRMarkupSVG{
|
||||
|
||||
}
|
||||
|
||||
// the extended options with the $dotColors option
|
||||
|
||||
/**
|
||||
* the extended options with the $dotColors option
|
||||
*
|
||||
* @property array<int, string> $dotColors
|
||||
*/
|
||||
class RandomDotsOptions extends QROptions{
|
||||
|
||||
/**
|
||||
* a map of $M_TYPE_LAYER => color
|
||||
*
|
||||
* @see \array_rand()
|
||||
* @var array<int, string>
|
||||
*/
|
||||
protected array $dotColors = [];
|
||||
|
||||
|
||||
@@ -210,6 +210,12 @@ class RoundQuietzoneSVGoutput extends QRMarkupSVG{
|
||||
|
||||
/**
|
||||
* the augmented options class
|
||||
*
|
||||
* @property int $additionalModules
|
||||
* @property array<int, string> $dotColors
|
||||
* @property string $svgLogo
|
||||
* @property float $svgLogoScale
|
||||
* @property string $svgLogoCssClass
|
||||
*/
|
||||
class RoundQuietzoneOptions extends QROptions{
|
||||
|
||||
@@ -231,6 +237,7 @@ class RoundQuietzoneOptions extends QROptions{
|
||||
* a map of $M_TYPE_LAYER => color
|
||||
*
|
||||
* @see \array_rand()
|
||||
* @var array<int, string>
|
||||
*/
|
||||
protected array $dotColors = [];
|
||||
|
||||
|
||||
@@ -72,6 +72,10 @@ class QRSvgWithLogo extends QRMarkupSVG{
|
||||
|
||||
/**
|
||||
* augment the QROptions class
|
||||
*
|
||||
* @property string $svgLogo
|
||||
* @property float $svgLogoScale
|
||||
* @property string $svgLogoCssClass
|
||||
*/
|
||||
class SVGWithLogoOptions extends QROptions{
|
||||
// path to svg logo
|
||||
|
||||
@@ -130,6 +130,10 @@ class QRSvgWithLogoAndCustomShapes extends QRMarkupSVG{
|
||||
|
||||
/**
|
||||
* augment the QROptions class
|
||||
*
|
||||
* @property string $svgLogo
|
||||
* @property float $svgLogoScale
|
||||
* @property string $svgLogoCssClass
|
||||
*/
|
||||
class SVGWithLogoAndCustomShapesOptions extends QROptions{
|
||||
// path to svg logo
|
||||
|
||||
Reference in New Issue
Block a user