gulp-phug 1.3.3 → 1.3.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +23 -8
- package/package.json +4 -4
- package/support/composer.json +1 -1
- package/support/composer.lock +93 -178
- package/support/vendor/autoload.php +15 -0
- package/support/vendor/bin/phug +119 -0
- package/support/vendor/bin/var-dump-server +119 -0
- package/support/vendor/composer/ClassLoader.php +166 -32
- package/support/vendor/composer/InstalledVersions.php +387 -329
- package/support/vendor/composer/autoload_classmap.php +1 -5
- package/support/vendor/composer/autoload_files.php +2 -3
- package/support/vendor/composer/autoload_namespaces.php +1 -1
- package/support/vendor/composer/autoload_psr4.php +3 -4
- package/support/vendor/composer/autoload_real.php +12 -37
- package/support/vendor/composer/autoload_static.php +6 -17
- package/support/vendor/composer/installed.json +97 -184
- package/support/vendor/composer/installed.php +129 -151
- package/support/vendor/composer/platform_check.php +16 -4
- package/support/vendor/phug/phug/.github/workflows/coverage.yml +71 -0
- package/support/vendor/phug/phug/.github/workflows/multi-tester.yml +46 -0
- package/support/vendor/phug/phug/.github/workflows/split.yml +41 -0
- package/support/vendor/phug/phug/.github/workflows/style.yml +48 -0
- package/support/vendor/phug/phug/.github/workflows/tests.yml +49 -0
- package/support/vendor/phug/phug/.multi-tester.yml +42 -10
- package/support/vendor/phug/phug/composer.json +25 -16
- package/support/vendor/phug/phug/phpcs.xml +4 -0
- package/support/vendor/phug/phug/phpunit.xml +2 -0
- package/support/vendor/phug/phug/phug +1 -1
- package/support/vendor/phug/phug/release.php +8 -0
- package/support/vendor/phug/phug/src/Phug/Ast/Ast/Node.php +7 -1
- package/support/vendor/phug/phug/src/Phug/Ast/composer.json +1 -2
- package/support/vendor/phug/phug/src/Phug/Compiler/Compiler/Element/BlockElement.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Compiler/Compiler/NodeCompiler/AssignmentNodeCompiler.php +9 -1
- package/support/vendor/phug/phug/src/Phug/Compiler/Compiler/NodeCompiler/AttributeNodeCompiler.php +1 -0
- package/support/vendor/phug/phug/src/Phug/Compiler/Compiler/NodeCompiler/ElementNodeCompiler.php +6 -0
- package/support/vendor/phug/phug/src/Phug/Compiler/Compiler/NodeCompiler/ImportNodeCompiler.php +4 -4
- package/support/vendor/phug/phug/src/Phug/Compiler/Compiler/NodeCompilerInterface.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Compiler/composer.json +5 -2
- package/support/vendor/phug/phug/src/Phug/DependencyInjection/DependencyInjection.php +1 -1
- package/support/vendor/phug/phug/src/Phug/DependencyInjection/composer.json +1 -2
- package/support/vendor/phug/phug/src/Phug/Event/Event/ListenerQueue.php +3 -0
- package/support/vendor/phug/phug/src/Phug/Event/EventManagerTrait.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Event/composer.json +1 -2
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/AbstractFormat.php +15 -12
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/AssignmentContainerInterface.php +2 -1
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Element/AbstractAssignmentContainerElement.php +11 -1
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Element/AbstractMarkupElement.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Element/AssignmentElement.php +9 -4
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Element/AttributeElement.php +4 -1
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Element/CodeElement.php +2 -2
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Element/MarkupElement.php +10 -8
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Element/MixinCallElement.php +2 -1
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Element/MixinElement.php +2 -1
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Format/XmlFormat.php +213 -20
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Partial/AssignmentHelpersTrait.php +7 -4
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Partial/HandleVariable.php +4 -4
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter/Partial/MagicAccessorTrait.php +1 -7
- package/support/vendor/phug/phug/src/Phug/Formatter/Formatter.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Formatter/composer.json +1 -2
- package/support/vendor/phug/phug/src/Phug/Invoker/Invoker.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Invoker/composer.json +5 -2
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Partial/IndentStyleTrait.php +5 -5
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Scanner/AssignmentScanner.php +8 -2
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Scanner/AttributeScanner.php +23 -11
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Scanner/ConditionalScanner.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Scanner/FilterScanner.php +6 -10
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Scanner/IndentationScanner.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Scanner/KeywordScanner.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Scanner/MultilineScanner.php +6 -12
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Scanner/Partial/TrailingOutdentHandlerTrait.php +26 -0
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/Scanner/TextScanner.php +3 -3
- package/support/vendor/phug/phug/src/Phug/Lexer/Lexer/State.php +9 -9
- package/support/vendor/phug/phug/src/Phug/Lexer/composer.json +1 -2
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/Event/NodeEvent.php +3 -2
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/Node/AssignmentNode.php +5 -1
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/Node/AttributeNode.php +4 -1
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/Node/ElementNode.php +5 -1
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/Node/FilterNode.php +2 -1
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/Node/MixinCallNode.php +5 -1
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/Node/MixinNode.php +5 -1
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/AbstractTokenHandler.php +87 -0
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/AssignmentTokenHandler.php +6 -21
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/AttributeEndTokenHandler.php +5 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/AttributeStartTokenHandler.php +7 -23
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/AttributeTokenHandler.php +21 -19
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/AutoCloseTokenHandler.php +5 -17
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/BlockTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/CaseTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/ClassTokenHandler.php +7 -34
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/CodeTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/CommentTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/ConditionalTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/DoTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/DoctypeTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/EachTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/ExpansionTokenHandler.php +5 -11
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/ExpressionTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/FilterTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/ForTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/IdTokenHandler.php +7 -33
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/ImportTokenHandler.php +14 -20
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/IndentTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/InterpolationEndTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/InterpolationStartTokenHandler.php +29 -30
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/KeywordTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/MixinCallTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/MixinTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/NewLineTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/OutdentTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/Partial/StaticAttributeTrait.php +36 -0
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/TagInterpolationEndTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/TagInterpolationStartTokenHandler.php +7 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/TagTokenHandler.php +6 -21
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/TextTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/VariableTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/WhenTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/WhileTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser/TokenHandler/YieldTokenHandler.php +4 -10
- package/support/vendor/phug/phug/src/Phug/Parser/Parser.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Parser/composer.json +1 -2
- package/support/vendor/phug/phug/src/Phug/Phug/Phug/Cli.php +5 -5
- package/support/vendor/phug/phug/src/Phug/Phug/Phug/Partial/ExtensionsTrait.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Phug/Phug/Partial/FacadeOptionsTrait.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Phug/Phug/Phug.php +14 -5
- package/support/vendor/phug/phug/src/Phug/Phug/composer.json +5 -2
- package/support/vendor/phug/phug/src/Phug/Reader/Reader.php +9 -9
- package/support/vendor/phug/phug/src/Phug/Reader/composer.json +4 -0
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/Adapter/FileAdapter.php +21 -4
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/Adapter/Stream/Template.php +5 -0
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/Adapter/StreamAdapter.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/CacheInterface.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/Partial/AdapterTrait.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/Partial/Debug/DebuggerTrait.php +56 -10
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/Partial/RendererOptionsTrait.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/Profiler/Dump.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/Profiler/LinkDump.php +2 -2
- package/support/vendor/phug/phug/src/Phug/Renderer/Renderer/Profiler/ProfilerModule.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Renderer/composer.json +7 -3
- package/support/vendor/phug/phug/src/Phug/Util/CompatibilityUtil/TestCaseTyped.php +67 -0
- package/support/vendor/phug/phug/src/Phug/Util/CompatibilityUtil/TestCaseUntyped.php +67 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/AttributesInterface.php +16 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/AttributesOrderInterface.php +17 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/AttributesStorage.php +44 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/Collection.php +2 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/OrderableInterface.php +22 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/OrderedValue.php +25 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/Partial/AttributeTrait.php +2 -1
- package/support/vendor/phug/phug/src/Phug/Util/Util/Partial/AttributesOrderTrait.php +19 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/Partial/ModuleContainerTrait.php +3 -3
- package/support/vendor/phug/phug/src/Phug/Util/Util/Partial/OptionTrait.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Util/Util/Partial/OrderTrait.php +27 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/Partial/StaticMemberTrait.php +1 -1
- package/support/vendor/phug/phug/src/Phug/Util/Util/Partial/ValueTrait.php +5 -3
- package/support/vendor/phug/phug/src/Phug/Util/Util/SandBox.php +1 -0
- package/support/vendor/phug/phug/src/Phug/Util/Util/TestCase.php +47 -4
- package/support/vendor/phug/phug/src/Phug/Util/composer.json +5 -6
- package/support/vendor/symfony/deprecation-contracts/CHANGELOG.md +5 -0
- package/support/vendor/symfony/{polyfill-php72 → deprecation-contracts}/LICENSE +1 -1
- package/support/vendor/symfony/deprecation-contracts/README.md +26 -0
- package/support/vendor/symfony/{polyfill-php72 → deprecation-contracts}/composer.json +9 -9
- package/support/vendor/symfony/deprecation-contracts/function.php +27 -0
- package/support/vendor/symfony/polyfill-mbstring/LICENSE +1 -1
- package/support/vendor/symfony/polyfill-mbstring/Mbstring.php +256 -57
- package/support/vendor/symfony/polyfill-mbstring/README.md +1 -1
- package/support/vendor/symfony/polyfill-mbstring/Resources/unidata/caseFolding.php +119 -0
- package/support/vendor/symfony/polyfill-mbstring/Resources/unidata/lowerCase.php +1 -1
- package/support/vendor/symfony/polyfill-mbstring/Resources/unidata/upperCase.php +102 -27
- package/support/vendor/symfony/polyfill-mbstring/bootstrap.php +33 -8
- package/support/vendor/symfony/polyfill-mbstring/bootstrap80.php +167 -0
- package/support/vendor/symfony/polyfill-mbstring/composer.json +5 -4
- package/support/vendor/symfony/var-dumper/CHANGELOG.md +63 -0
- package/support/vendor/symfony/var-dumper/Caster/AddressInfoCaster.php +82 -0
- package/support/vendor/symfony/var-dumper/Caster/AmqpCaster.php +12 -10
- package/support/vendor/symfony/var-dumper/Caster/ArgsStub.php +6 -7
- package/support/vendor/symfony/var-dumper/Caster/Caster.php +59 -31
- package/support/vendor/symfony/var-dumper/Caster/ClassStub.php +7 -9
- package/support/vendor/symfony/var-dumper/Caster/ConstStub.php +20 -4
- package/support/vendor/symfony/var-dumper/Caster/CurlCaster.php +31 -0
- package/support/vendor/symfony/var-dumper/Caster/CutArrayStub.php +1 -1
- package/support/vendor/symfony/var-dumper/Caster/CutStub.php +2 -2
- package/support/vendor/symfony/var-dumper/Caster/DOMCaster.php +61 -156
- package/support/vendor/symfony/var-dumper/Caster/DateCaster.php +27 -26
- package/support/vendor/symfony/var-dumper/Caster/DoctrineCaster.php +6 -4
- package/support/vendor/symfony/var-dumper/Caster/DsCaster.php +1 -1
- package/support/vendor/symfony/var-dumper/Caster/DsPairStub.php +1 -1
- package/support/vendor/symfony/var-dumper/Caster/EnumStub.php +4 -5
- package/support/vendor/symfony/var-dumper/Caster/ExceptionCaster.php +64 -49
- package/support/vendor/symfony/var-dumper/Caster/FFICaster.php +171 -0
- package/support/vendor/symfony/var-dumper/Caster/FiberCaster.php +43 -0
- package/support/vendor/symfony/var-dumper/Caster/FrameStub.php +6 -8
- package/support/vendor/symfony/var-dumper/Caster/GdCaster.php +30 -0
- package/support/vendor/symfony/var-dumper/Caster/GmpCaster.php +4 -2
- package/support/vendor/symfony/var-dumper/Caster/ImagineCaster.php +2 -0
- package/support/vendor/symfony/var-dumper/Caster/ImgStub.php +1 -1
- package/support/vendor/symfony/var-dumper/Caster/IntlCaster.php +10 -8
- package/support/vendor/symfony/var-dumper/Caster/LinkStub.php +14 -17
- package/support/vendor/symfony/var-dumper/Caster/MemcachedCaster.php +10 -8
- package/support/vendor/symfony/var-dumper/Caster/MysqliCaster.php +33 -0
- package/support/vendor/symfony/var-dumper/Caster/OpenSSLCaster.php +69 -0
- package/support/vendor/symfony/var-dumper/Caster/PdoCaster.php +8 -6
- package/support/vendor/symfony/var-dumper/Caster/PgSqlCaster.php +21 -19
- package/support/vendor/symfony/var-dumper/Caster/ProxyManagerCaster.php +4 -2
- package/support/vendor/symfony/var-dumper/Caster/RdKafkaCaster.php +188 -0
- package/support/vendor/symfony/var-dumper/Caster/RedisCaster.php +31 -31
- package/support/vendor/symfony/var-dumper/Caster/ReflectionCaster.php +100 -44
- package/support/vendor/symfony/var-dumper/Caster/ResourceCaster.php +33 -46
- package/support/vendor/symfony/var-dumper/Caster/ScalarStub.php +27 -0
- package/support/vendor/symfony/var-dumper/Caster/SocketCaster.php +64 -0
- package/support/vendor/symfony/var-dumper/Caster/SplCaster.php +57 -44
- package/support/vendor/symfony/var-dumper/Caster/SqliteCaster.php +32 -0
- package/support/vendor/symfony/var-dumper/Caster/StubCaster.php +15 -5
- package/support/vendor/symfony/var-dumper/Caster/SymfonyCaster.php +66 -10
- package/support/vendor/symfony/var-dumper/Caster/TraceStub.php +7 -11
- package/support/vendor/symfony/var-dumper/Caster/UninitializedStub.php +25 -0
- package/support/vendor/symfony/var-dumper/Caster/UuidCaster.php +2 -0
- package/support/vendor/symfony/var-dumper/Caster/VirtualStub.php +21 -0
- package/support/vendor/symfony/var-dumper/Caster/XmlReaderCaster.php +25 -10
- package/support/vendor/symfony/var-dumper/Caster/XmlResourceCaster.php +7 -5
- package/support/vendor/symfony/var-dumper/Cloner/AbstractCloner.php +103 -72
- package/support/vendor/symfony/var-dumper/Cloner/ClonerInterface.php +1 -5
- package/support/vendor/symfony/var-dumper/Cloner/Cursor.php +21 -21
- package/support/vendor/symfony/var-dumper/Cloner/Data.php +51 -77
- package/support/vendor/symfony/var-dumper/Cloner/DumperInterface.php +11 -14
- package/support/vendor/symfony/var-dumper/Cloner/Stub.php +40 -31
- package/support/vendor/symfony/var-dumper/Cloner/VarCloner.php +21 -104
- package/support/vendor/symfony/var-dumper/Command/Descriptor/CliDescriptor.php +9 -19
- package/support/vendor/symfony/var-dumper/Command/Descriptor/HtmlDescriptor.php +10 -11
- package/support/vendor/symfony/var-dumper/Command/ServerDumpCommand.php +27 -15
- package/support/vendor/symfony/var-dumper/Dumper/AbstractDumper.php +68 -48
- package/support/vendor/symfony/var-dumper/Dumper/CliDumper.php +126 -113
- package/support/vendor/symfony/var-dumper/Dumper/ContextProvider/CliContextProvider.php +1 -1
- package/support/vendor/symfony/var-dumper/Dumper/ContextProvider/ContextProviderInterface.php +0 -3
- package/support/vendor/symfony/var-dumper/Dumper/ContextProvider/RequestContextProvider.php +5 -6
- package/support/vendor/symfony/var-dumper/Dumper/ContextProvider/SourceContextProvider.php +10 -15
- package/support/vendor/symfony/var-dumper/Dumper/ContextualizedDumper.php +8 -11
- package/support/vendor/symfony/var-dumper/Dumper/DataDumperInterface.php +3 -0
- package/support/vendor/symfony/var-dumper/Dumper/HtmlDumper.php +122 -146
- package/support/vendor/symfony/var-dumper/Dumper/ServerDumper.php +10 -10
- package/support/vendor/symfony/var-dumper/Exception/ThrowingCasterException.php +1 -1
- package/support/vendor/symfony/var-dumper/LICENSE +1 -1
- package/support/vendor/symfony/var-dumper/README.md +6 -6
- package/support/vendor/symfony/var-dumper/Resources/bin/var-dump-server +4 -0
- package/support/vendor/symfony/var-dumper/Resources/functions/dump.php +35 -10
- package/support/vendor/symfony/var-dumper/Server/Connection.php +16 -14
- package/support/vendor/symfony/var-dumper/Server/DumpServer.php +16 -14
- package/support/vendor/symfony/var-dumper/Test/VarDumperTestTrait.php +9 -9
- package/support/vendor/symfony/var-dumper/VarDumper.php +69 -17
- package/support/vendor/symfony/var-dumper/composer.json +10 -16
- package/support/vendor/symfony/polyfill-php72/Php72.php +0 -217
- package/support/vendor/symfony/polyfill-php72/README.md +0 -28
- package/support/vendor/symfony/polyfill-php72/bootstrap.php +0 -57
- package/support/vendor/symfony/polyfill-php80/LICENSE +0 -19
- package/support/vendor/symfony/polyfill-php80/Php80.php +0 -105
- package/support/vendor/symfony/polyfill-php80/README.md +0 -24
- package/support/vendor/symfony/polyfill-php80/Resources/stubs/Attribute.php +0 -22
- package/support/vendor/symfony/polyfill-php80/Resources/stubs/Stringable.php +0 -11
- package/support/vendor/symfony/polyfill-php80/Resources/stubs/UnhandledMatchError.php +0 -5
- package/support/vendor/symfony/polyfill-php80/Resources/stubs/ValueError.php +0 -5
- package/support/vendor/symfony/polyfill-php80/bootstrap.php +0 -42
- package/support/vendor/symfony/polyfill-php80/composer.json +0 -40
|
@@ -18,12 +18,14 @@ use Symfony\Component\VarDumper\Cloner\Stub;
|
|
|
18
18
|
*
|
|
19
19
|
* @author Nicolas Grekas <p@tchwork.com>
|
|
20
20
|
*
|
|
21
|
-
* @final
|
|
21
|
+
* @final
|
|
22
|
+
*
|
|
23
|
+
* @internal since Symfony 7.3
|
|
22
24
|
*/
|
|
23
25
|
class DOMCaster
|
|
24
26
|
{
|
|
25
|
-
private
|
|
26
|
-
|
|
27
|
+
private const ERROR_CODES = [
|
|
28
|
+
0 => 'DOM_PHP_ERR',
|
|
27
29
|
\DOM_INDEX_SIZE_ERR => 'DOM_INDEX_SIZE_ERR',
|
|
28
30
|
\DOMSTRING_SIZE_ERR => 'DOMSTRING_SIZE_ERR',
|
|
29
31
|
\DOM_HIERARCHY_REQUEST_ERR => 'DOM_HIERARCHY_REQUEST_ERR',
|
|
@@ -42,7 +44,7 @@ class DOMCaster
|
|
|
42
44
|
\DOM_VALIDATION_ERR => 'DOM_VALIDATION_ERR',
|
|
43
45
|
];
|
|
44
46
|
|
|
45
|
-
private
|
|
47
|
+
private const NODE_TYPES = [
|
|
46
48
|
\XML_ELEMENT_NODE => 'XML_ELEMENT_NODE',
|
|
47
49
|
\XML_ATTRIBUTE_NODE => 'XML_ATTRIBUTE_NODE',
|
|
48
50
|
\XML_TEXT_NODE => 'XML_TEXT_NODE',
|
|
@@ -63,26 +65,22 @@ class DOMCaster
|
|
|
63
65
|
\XML_NAMESPACE_DECL_NODE => 'XML_NAMESPACE_DECL_NODE',
|
|
64
66
|
];
|
|
65
67
|
|
|
66
|
-
public static function castException(\DOMException $e, array $a, Stub $stub, $isNested)
|
|
68
|
+
public static function castException(\DOMException|\Dom\Exception $e, array $a, Stub $stub, bool $isNested): array
|
|
67
69
|
{
|
|
68
70
|
$k = Caster::PREFIX_PROTECTED.'code';
|
|
69
|
-
if (isset($a[$k], self
|
|
70
|
-
$a[$k] = new ConstStub(self
|
|
71
|
+
if (isset($a[$k], self::ERROR_CODES[$a[$k]])) {
|
|
72
|
+
$a[$k] = new ConstStub(self::ERROR_CODES[$a[$k]], $a[$k]);
|
|
71
73
|
}
|
|
72
74
|
|
|
73
75
|
return $a;
|
|
74
76
|
}
|
|
75
77
|
|
|
76
|
-
public static function castLength($dom, array $a, Stub $stub, $isNested)
|
|
78
|
+
public static function castLength($dom, array $a, Stub $stub, bool $isNested): array
|
|
77
79
|
{
|
|
78
|
-
$a += [
|
|
79
|
-
'length' => $dom->length,
|
|
80
|
-
];
|
|
81
|
-
|
|
82
80
|
return $a;
|
|
83
81
|
}
|
|
84
82
|
|
|
85
|
-
public static function castImplementation($dom, array $a, Stub $stub, $isNested)
|
|
83
|
+
public static function castImplementation(\DOMImplementation|\Dom\Implementation $dom, array $a, Stub $stub, bool $isNested): array
|
|
86
84
|
{
|
|
87
85
|
$a += [
|
|
88
86
|
Caster::PREFIX_VIRTUAL.'Core' => '1.0',
|
|
@@ -92,70 +90,18 @@ class DOMCaster
|
|
|
92
90
|
return $a;
|
|
93
91
|
}
|
|
94
92
|
|
|
95
|
-
public static function castNode(\DOMNode $dom, array $a, Stub $stub, $isNested)
|
|
93
|
+
public static function castNode(\DOMNode|\Dom\Node $dom, array $a, Stub $stub, bool $isNested): array
|
|
96
94
|
{
|
|
97
|
-
$a
|
|
98
|
-
'nodeName' => $dom->nodeName,
|
|
99
|
-
'nodeValue' => new CutStub($dom->nodeValue),
|
|
100
|
-
'nodeType' => new ConstStub(self::$nodeTypes[$dom->nodeType], $dom->nodeType),
|
|
101
|
-
'parentNode' => new CutStub($dom->parentNode),
|
|
102
|
-
'childNodes' => $dom->childNodes,
|
|
103
|
-
'firstChild' => new CutStub($dom->firstChild),
|
|
104
|
-
'lastChild' => new CutStub($dom->lastChild),
|
|
105
|
-
'previousSibling' => new CutStub($dom->previousSibling),
|
|
106
|
-
'nextSibling' => new CutStub($dom->nextSibling),
|
|
107
|
-
'attributes' => $dom->attributes,
|
|
108
|
-
'ownerDocument' => new CutStub($dom->ownerDocument),
|
|
109
|
-
'namespaceURI' => $dom->namespaceURI,
|
|
110
|
-
'prefix' => $dom->prefix,
|
|
111
|
-
'localName' => $dom->localName,
|
|
112
|
-
'baseURI' => $dom->baseURI ? new LinkStub($dom->baseURI) : $dom->baseURI,
|
|
113
|
-
'textContent' => new CutStub($dom->textContent),
|
|
114
|
-
];
|
|
115
|
-
|
|
116
|
-
return $a;
|
|
95
|
+
return self::castDom($dom, $a, $stub, $isNested);
|
|
117
96
|
}
|
|
118
97
|
|
|
119
|
-
public static function castNameSpaceNode(\DOMNameSpaceNode $dom, array $a, Stub $stub, $isNested)
|
|
98
|
+
public static function castNameSpaceNode(\DOMNameSpaceNode $dom, array $a, Stub $stub, bool $isNested): array
|
|
120
99
|
{
|
|
121
|
-
$a
|
|
122
|
-
'nodeName' => $dom->nodeName,
|
|
123
|
-
'nodeValue' => new CutStub($dom->nodeValue),
|
|
124
|
-
'nodeType' => new ConstStub(self::$nodeTypes[$dom->nodeType], $dom->nodeType),
|
|
125
|
-
'prefix' => $dom->prefix,
|
|
126
|
-
'localName' => $dom->localName,
|
|
127
|
-
'namespaceURI' => $dom->namespaceURI,
|
|
128
|
-
'ownerDocument' => new CutStub($dom->ownerDocument),
|
|
129
|
-
'parentNode' => new CutStub($dom->parentNode),
|
|
130
|
-
];
|
|
131
|
-
|
|
132
|
-
return $a;
|
|
100
|
+
return self::castDom($dom, $a, $stub, $isNested);
|
|
133
101
|
}
|
|
134
102
|
|
|
135
|
-
public static function castDocument(\DOMDocument $dom, array $a, Stub $stub, $isNested, $filter = 0)
|
|
103
|
+
public static function castDocument(\DOMDocument $dom, array $a, Stub $stub, bool $isNested, int $filter = 0): array
|
|
136
104
|
{
|
|
137
|
-
$a += [
|
|
138
|
-
'doctype' => $dom->doctype,
|
|
139
|
-
'implementation' => $dom->implementation,
|
|
140
|
-
'documentElement' => new CutStub($dom->documentElement),
|
|
141
|
-
'actualEncoding' => $dom->actualEncoding,
|
|
142
|
-
'encoding' => $dom->encoding,
|
|
143
|
-
'xmlEncoding' => $dom->xmlEncoding,
|
|
144
|
-
'standalone' => $dom->standalone,
|
|
145
|
-
'xmlStandalone' => $dom->xmlStandalone,
|
|
146
|
-
'version' => $dom->version,
|
|
147
|
-
'xmlVersion' => $dom->xmlVersion,
|
|
148
|
-
'strictErrorChecking' => $dom->strictErrorChecking,
|
|
149
|
-
'documentURI' => $dom->documentURI ? new LinkStub($dom->documentURI) : $dom->documentURI,
|
|
150
|
-
'config' => $dom->config,
|
|
151
|
-
'formatOutput' => $dom->formatOutput,
|
|
152
|
-
'validateOnParse' => $dom->validateOnParse,
|
|
153
|
-
'resolveExternals' => $dom->resolveExternals,
|
|
154
|
-
'preserveWhiteSpace' => $dom->preserveWhiteSpace,
|
|
155
|
-
'recover' => $dom->recover,
|
|
156
|
-
'substituteEntities' => $dom->substituteEntities,
|
|
157
|
-
];
|
|
158
|
-
|
|
159
105
|
if (!($filter & Caster::EXCLUDE_VERBOSE)) {
|
|
160
106
|
$formatOutput = $dom->formatOutput;
|
|
161
107
|
$dom->formatOutput = true;
|
|
@@ -166,138 +112,97 @@ class DOMCaster
|
|
|
166
112
|
return $a;
|
|
167
113
|
}
|
|
168
114
|
|
|
169
|
-
public static function
|
|
115
|
+
public static function castXMLDocument(\Dom\XMLDocument $dom, array $a, Stub $stub, bool $isNested, int $filter = 0): array
|
|
170
116
|
{
|
|
171
|
-
$
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
117
|
+
if (!($filter & Caster::EXCLUDE_VERBOSE)) {
|
|
118
|
+
$formatOutput = $dom->formatOutput;
|
|
119
|
+
$dom->formatOutput = true;
|
|
120
|
+
$a += [Caster::PREFIX_VIRTUAL.'xml' => $dom->saveXML()];
|
|
121
|
+
$dom->formatOutput = $formatOutput;
|
|
122
|
+
}
|
|
175
123
|
|
|
176
124
|
return $a;
|
|
177
125
|
}
|
|
178
126
|
|
|
179
|
-
public static function
|
|
127
|
+
public static function castHTMLDocument(\Dom\HTMLDocument $dom, array $a, Stub $stub, bool $isNested, int $filter = 0): array
|
|
180
128
|
{
|
|
181
|
-
$
|
|
182
|
-
'
|
|
183
|
-
|
|
184
|
-
'value' => $dom->value,
|
|
185
|
-
'ownerElement' => $dom->ownerElement,
|
|
186
|
-
'schemaTypeInfo' => $dom->schemaTypeInfo,
|
|
187
|
-
];
|
|
129
|
+
if (!($filter & Caster::EXCLUDE_VERBOSE)) {
|
|
130
|
+
$a += [Caster::PREFIX_VIRTUAL.'html' => $dom->saveHTML()];
|
|
131
|
+
}
|
|
188
132
|
|
|
189
133
|
return $a;
|
|
190
134
|
}
|
|
191
135
|
|
|
192
|
-
public static function
|
|
136
|
+
public static function castCharacterData(\DOMCharacterData|\Dom\CharacterData $dom, array $a, Stub $stub, bool $isNested): array
|
|
193
137
|
{
|
|
194
|
-
$a += [
|
|
195
|
-
'tagName' => $dom->tagName,
|
|
196
|
-
'schemaTypeInfo' => $dom->schemaTypeInfo,
|
|
197
|
-
];
|
|
198
|
-
|
|
199
138
|
return $a;
|
|
200
139
|
}
|
|
201
140
|
|
|
202
|
-
public static function
|
|
141
|
+
public static function castAttr(\DOMAttr|\Dom\Attr $dom, array $a, Stub $stub, bool $isNested): array
|
|
203
142
|
{
|
|
204
|
-
$a += [
|
|
205
|
-
'wholeText' => $dom->wholeText,
|
|
206
|
-
];
|
|
207
|
-
|
|
208
143
|
return $a;
|
|
209
144
|
}
|
|
210
145
|
|
|
211
|
-
public static function
|
|
146
|
+
public static function castElement(\DOMElement|\Dom\Element $dom, array $a, Stub $stub, bool $isNested): array
|
|
212
147
|
{
|
|
213
|
-
$a += [
|
|
214
|
-
'typeName' => $dom->typeName,
|
|
215
|
-
'typeNamespace' => $dom->typeNamespace,
|
|
216
|
-
];
|
|
217
|
-
|
|
218
148
|
return $a;
|
|
219
149
|
}
|
|
220
150
|
|
|
221
|
-
public static function
|
|
151
|
+
public static function castText(\DOMText|\Dom\Text $dom, array $a, Stub $stub, bool $isNested): array
|
|
222
152
|
{
|
|
223
|
-
$a += [
|
|
224
|
-
'severity' => $dom->severity,
|
|
225
|
-
'message' => $dom->message,
|
|
226
|
-
'type' => $dom->type,
|
|
227
|
-
'relatedException' => $dom->relatedException,
|
|
228
|
-
'related_data' => $dom->related_data,
|
|
229
|
-
'location' => $dom->location,
|
|
230
|
-
];
|
|
231
|
-
|
|
232
153
|
return $a;
|
|
233
154
|
}
|
|
234
155
|
|
|
235
|
-
public static function
|
|
156
|
+
public static function castDocumentType(\DOMDocumentType|\Dom\DocumentType $dom, array $a, Stub $stub, bool $isNested): array
|
|
236
157
|
{
|
|
237
|
-
$a += [
|
|
238
|
-
'lineNumber' => $dom->lineNumber,
|
|
239
|
-
'columnNumber' => $dom->columnNumber,
|
|
240
|
-
'offset' => $dom->offset,
|
|
241
|
-
'relatedNode' => $dom->relatedNode,
|
|
242
|
-
'uri' => $dom->uri ? new LinkStub($dom->uri, $dom->lineNumber) : $dom->uri,
|
|
243
|
-
];
|
|
244
|
-
|
|
245
158
|
return $a;
|
|
246
159
|
}
|
|
247
160
|
|
|
248
|
-
public static function
|
|
161
|
+
public static function castNotation(\DOMNotation|\Dom\Notation $dom, array $a, Stub $stub, bool $isNested): array
|
|
249
162
|
{
|
|
250
|
-
$a += [
|
|
251
|
-
'name' => $dom->name,
|
|
252
|
-
'entities' => $dom->entities,
|
|
253
|
-
'notations' => $dom->notations,
|
|
254
|
-
'publicId' => $dom->publicId,
|
|
255
|
-
'systemId' => $dom->systemId,
|
|
256
|
-
'internalSubset' => $dom->internalSubset,
|
|
257
|
-
];
|
|
258
|
-
|
|
259
163
|
return $a;
|
|
260
164
|
}
|
|
261
165
|
|
|
262
|
-
public static function
|
|
166
|
+
public static function castEntity(\DOMEntity|\Dom\Entity $dom, array $a, Stub $stub, bool $isNested): array
|
|
263
167
|
{
|
|
264
|
-
$a += [
|
|
265
|
-
'publicId' => $dom->publicId,
|
|
266
|
-
'systemId' => $dom->systemId,
|
|
267
|
-
];
|
|
268
|
-
|
|
269
168
|
return $a;
|
|
270
169
|
}
|
|
271
170
|
|
|
272
|
-
public static function
|
|
171
|
+
public static function castProcessingInstruction(\DOMProcessingInstruction|\Dom\ProcessingInstruction $dom, array $a, Stub $stub, bool $isNested): array
|
|
273
172
|
{
|
|
274
|
-
$a += [
|
|
275
|
-
'publicId' => $dom->publicId,
|
|
276
|
-
'systemId' => $dom->systemId,
|
|
277
|
-
'notationName' => $dom->notationName,
|
|
278
|
-
'actualEncoding' => $dom->actualEncoding,
|
|
279
|
-
'encoding' => $dom->encoding,
|
|
280
|
-
'version' => $dom->version,
|
|
281
|
-
];
|
|
282
|
-
|
|
283
173
|
return $a;
|
|
284
174
|
}
|
|
285
175
|
|
|
286
|
-
public static function
|
|
176
|
+
public static function castXPath(\DOMXPath|\Dom\XPath $dom, array $a, Stub $stub, bool $isNested): array
|
|
287
177
|
{
|
|
288
|
-
$a
|
|
289
|
-
'target' => $dom->target,
|
|
290
|
-
'data' => $dom->data,
|
|
291
|
-
];
|
|
292
|
-
|
|
293
|
-
return $a;
|
|
178
|
+
return self::castDom($dom, $a, $stub, $isNested);
|
|
294
179
|
}
|
|
295
180
|
|
|
296
|
-
public static function
|
|
181
|
+
public static function castDom($dom, array $a, Stub $stub, bool $isNested, int $filter = 0): array
|
|
297
182
|
{
|
|
298
|
-
$a
|
|
299
|
-
'
|
|
300
|
-
|
|
183
|
+
foreach ($a as $k => $v) {
|
|
184
|
+
if ('encoding' === $k && $dom instanceof \DOMEntity
|
|
185
|
+
|| \in_array($k, ['actualEncoding', 'config', 'standalone', 'version'], true)
|
|
186
|
+
) {
|
|
187
|
+
continue; // deprecated properties
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
$v = $dom->$k;
|
|
191
|
+
|
|
192
|
+
$a[$k] = match (true) {
|
|
193
|
+
$v instanceof \DOMNode || $v instanceof \Dom\Node => new CutStub($v),
|
|
194
|
+
'nodeType' === $k => new ConstStub(self::NODE_TYPES[$v], $v),
|
|
195
|
+
'baseURI' === $k && $v,
|
|
196
|
+
'documentURI' === $k && $v => new LinkStub($v),
|
|
197
|
+
default => $v,
|
|
198
|
+
};
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
if ($dom instanceof \IteratorAggregate) {
|
|
202
|
+
foreach ($dom as $k => $v) {
|
|
203
|
+
$a[Caster::PREFIX_VIRTUAL.$k] = $v;
|
|
204
|
+
}
|
|
205
|
+
}
|
|
301
206
|
|
|
302
207
|
return $a;
|
|
303
208
|
}
|
|
@@ -18,17 +18,19 @@ use Symfony\Component\VarDumper\Cloner\Stub;
|
|
|
18
18
|
*
|
|
19
19
|
* @author Dany Maillard <danymaillard93b@gmail.com>
|
|
20
20
|
*
|
|
21
|
-
* @final
|
|
21
|
+
* @final
|
|
22
|
+
*
|
|
23
|
+
* @internal since Symfony 7.3
|
|
22
24
|
*/
|
|
23
25
|
class DateCaster
|
|
24
26
|
{
|
|
25
27
|
private const PERIOD_LIMIT = 3;
|
|
26
28
|
|
|
27
|
-
public static function castDateTime(\DateTimeInterface $d, array $a, Stub $stub, $isNested, $filter)
|
|
29
|
+
public static function castDateTime(\DateTimeInterface $d, array $a, Stub $stub, bool $isNested, int $filter): array
|
|
28
30
|
{
|
|
29
31
|
$prefix = Caster::PREFIX_VIRTUAL;
|
|
30
|
-
$location = $d->getTimezone()->getLocation();
|
|
31
|
-
$fromNow = (new \
|
|
32
|
+
$location = $d->getTimezone() ? $d->getTimezone()->getLocation() : null;
|
|
33
|
+
$fromNow = (new \DateTimeImmutable())->diff($d);
|
|
32
34
|
|
|
33
35
|
$title = $d->format('l, F j, Y')
|
|
34
36
|
."\n".self::formatInterval($fromNow).' from now'
|
|
@@ -47,9 +49,9 @@ class DateCaster
|
|
|
47
49
|
return $a;
|
|
48
50
|
}
|
|
49
51
|
|
|
50
|
-
public static function castInterval(\DateInterval $interval, array $a, Stub $stub, $isNested, $filter)
|
|
52
|
+
public static function castInterval(\DateInterval $interval, array $a, Stub $stub, bool $isNested, int $filter): array
|
|
51
53
|
{
|
|
52
|
-
$now = new \DateTimeImmutable();
|
|
54
|
+
$now = new \DateTimeImmutable('@0', new \DateTimeZone('UTC'));
|
|
53
55
|
$numberOfSeconds = $now->add($interval)->getTimestamp() - $now->getTimestamp();
|
|
54
56
|
$title = number_format($numberOfSeconds, 0, '.', ' ').'s';
|
|
55
57
|
|
|
@@ -63,7 +65,8 @@ class DateCaster
|
|
|
63
65
|
$format = '%R ';
|
|
64
66
|
|
|
65
67
|
if (0 === $i->y && 0 === $i->m && ($i->h >= 24 || $i->i >= 60 || $i->s >= 60)) {
|
|
66
|
-
$
|
|
68
|
+
$d = new \DateTimeImmutable('@0', new \DateTimeZone('UTC'));
|
|
69
|
+
$i = $d->diff($d->add($i)); // recalculate carry over points
|
|
67
70
|
$format .= 0 < $i->days ? '%ad ' : '';
|
|
68
71
|
} else {
|
|
69
72
|
$format .= ($i->y ? '%yy ' : '').($i->m ? '%mm ' : '').($i->d ? '%dd ' : '');
|
|
@@ -75,10 +78,10 @@ class DateCaster
|
|
|
75
78
|
return $i->format(rtrim($format));
|
|
76
79
|
}
|
|
77
80
|
|
|
78
|
-
public static function castTimeZone(\DateTimeZone $timeZone, array $a, Stub $stub, $isNested, $filter)
|
|
81
|
+
public static function castTimeZone(\DateTimeZone $timeZone, array $a, Stub $stub, bool $isNested, int $filter): array
|
|
79
82
|
{
|
|
80
83
|
$location = $timeZone->getLocation();
|
|
81
|
-
$formatted = (new \
|
|
84
|
+
$formatted = (new \DateTimeImmutable('now', $timeZone))->format($location ? 'e (P)' : 'P');
|
|
82
85
|
$title = $location && \extension_loaded('intl') ? \Locale::getDisplayRegion('-'.$location['country_code']) : '';
|
|
83
86
|
|
|
84
87
|
$z = [Caster::PREFIX_VIRTUAL.'timezone' => new ConstStub($formatted, $title)];
|
|
@@ -86,29 +89,27 @@ class DateCaster
|
|
|
86
89
|
return $filter & Caster::EXCLUDE_VERBOSE ? $z : $z + $a;
|
|
87
90
|
}
|
|
88
91
|
|
|
89
|
-
public static function castPeriod(\DatePeriod $p, array $a, Stub $stub, $isNested, $filter)
|
|
92
|
+
public static function castPeriod(\DatePeriod $p, array $a, Stub $stub, bool $isNested, int $filter): array
|
|
90
93
|
{
|
|
91
94
|
$dates = [];
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
$
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
break;
|
|
101
|
-
}
|
|
102
|
-
$dates[] = sprintf('%s) %s', $i + 1, self::formatDateTime($d));
|
|
95
|
+
foreach (clone $p as $i => $d) {
|
|
96
|
+
if (self::PERIOD_LIMIT === $i) {
|
|
97
|
+
$now = new \DateTimeImmutable('now', new \DateTimeZone('UTC'));
|
|
98
|
+
$dates[] = \sprintf('%s more', ($end = $p->getEndDate())
|
|
99
|
+
? ceil(($end->format('U.u') - $d->format('U.u')) / ((int) $now->add($p->getDateInterval())->format('U.u') - (int) $now->format('U.u')))
|
|
100
|
+
: $p->recurrences - $i
|
|
101
|
+
);
|
|
102
|
+
break;
|
|
103
103
|
}
|
|
104
|
+
$dates[] = \sprintf('%s) %s', $i + 1, self::formatDateTime($d));
|
|
104
105
|
}
|
|
105
106
|
|
|
106
|
-
$period = sprintf(
|
|
107
|
-
'every %s, from %s
|
|
107
|
+
$period = \sprintf(
|
|
108
|
+
'every %s, from %s%s %s',
|
|
108
109
|
self::formatInterval($p->getDateInterval()),
|
|
110
|
+
$p->include_start_date ? '[' : ']',
|
|
109
111
|
self::formatDateTime($p->getStartDate()),
|
|
110
|
-
$p->
|
|
111
|
-
($end = $p->getEndDate()) ? 'to '.self::formatDateTime($end) : 'recurring '.$p->recurrences.' time/s'
|
|
112
|
+
($end = $p->getEndDate()) ? 'to '.self::formatDateTime($end).($p->include_end_date ? ']' : '[') : 'recurring '.$p->recurrences.' time/s'
|
|
112
113
|
);
|
|
113
114
|
|
|
114
115
|
$p = [Caster::PREFIX_VIRTUAL.'period' => new ConstStub($period, implode("\n", $dates))];
|
|
@@ -123,6 +124,6 @@ class DateCaster
|
|
|
123
124
|
|
|
124
125
|
private static function formatSeconds(string $s, string $us): string
|
|
125
126
|
{
|
|
126
|
-
return sprintf('%02d.%s', $s, 0 === ($len = \strlen($t = rtrim($us, '0'))) ? '0' : ($len <= 3 ? str_pad($t, 3, '0') : $us));
|
|
127
|
+
return \sprintf('%02d.%s', $s, 0 === ($len = \strlen($t = rtrim($us, '0'))) ? '0' : ($len <= 3 ? str_pad($t, 3, '0') : $us));
|
|
127
128
|
}
|
|
128
129
|
}
|
|
@@ -21,11 +21,13 @@ use Symfony\Component\VarDumper\Cloner\Stub;
|
|
|
21
21
|
*
|
|
22
22
|
* @author Nicolas Grekas <p@tchwork.com>
|
|
23
23
|
*
|
|
24
|
-
* @final
|
|
24
|
+
* @final
|
|
25
|
+
*
|
|
26
|
+
* @internal since Symfony 7.3
|
|
25
27
|
*/
|
|
26
28
|
class DoctrineCaster
|
|
27
29
|
{
|
|
28
|
-
public static function castCommonProxy(CommonProxy $proxy, array $a, Stub $stub, $isNested)
|
|
30
|
+
public static function castCommonProxy(CommonProxy $proxy, array $a, Stub $stub, bool $isNested): array
|
|
29
31
|
{
|
|
30
32
|
foreach (['__cloner__', '__initializer__'] as $k) {
|
|
31
33
|
if (\array_key_exists($k, $a)) {
|
|
@@ -37,7 +39,7 @@ class DoctrineCaster
|
|
|
37
39
|
return $a;
|
|
38
40
|
}
|
|
39
41
|
|
|
40
|
-
public static function castOrmProxy(OrmProxy $proxy, array $a, Stub $stub, $isNested)
|
|
42
|
+
public static function castOrmProxy(OrmProxy $proxy, array $a, Stub $stub, bool $isNested): array
|
|
41
43
|
{
|
|
42
44
|
foreach (['_entityPersister', '_identifier'] as $k) {
|
|
43
45
|
if (\array_key_exists($k = "\0Doctrine\\ORM\\Proxy\\Proxy\0".$k, $a)) {
|
|
@@ -49,7 +51,7 @@ class DoctrineCaster
|
|
|
49
51
|
return $a;
|
|
50
52
|
}
|
|
51
53
|
|
|
52
|
-
public static function castPersistentCollection(PersistentCollection $coll, array $a, Stub $stub, $isNested)
|
|
54
|
+
public static function castPersistentCollection(PersistentCollection $coll, array $a, Stub $stub, bool $isNested): array
|
|
53
55
|
{
|
|
54
56
|
foreach (['snapshot', 'association', 'typeClass'] as $k) {
|
|
55
57
|
if (\array_key_exists($k = "\0Doctrine\\ORM\\PersistentCollection\0".$k, $a)) {
|
|
@@ -20,11 +20,10 @@ use Symfony\Component\VarDumper\Cloner\Stub;
|
|
|
20
20
|
*/
|
|
21
21
|
class EnumStub extends Stub
|
|
22
22
|
{
|
|
23
|
-
public
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
{
|
|
23
|
+
public function __construct(
|
|
24
|
+
array $values,
|
|
25
|
+
public bool $dumpKeys = true,
|
|
26
|
+
) {
|
|
27
27
|
$this->value = $values;
|
|
28
|
-
$this->dumpKeys = $dumpKeys;
|
|
29
28
|
}
|
|
30
29
|
}
|