From 8ca6cc32b2c789a3149861159ad258f2cb9491e3 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 28 Apr 2024 14:39:39 +0200 Subject: Adding upstream version 2.11.4. Signed-off-by: Daniel Baumann --- library/vendor/lessphp/lib/Less/Tree/Alpha.php | 48 ++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 library/vendor/lessphp/lib/Less/Tree/Alpha.php (limited to 'library/vendor/lessphp/lib/Less/Tree/Alpha.php') diff --git a/library/vendor/lessphp/lib/Less/Tree/Alpha.php b/library/vendor/lessphp/lib/Less/Tree/Alpha.php new file mode 100644 index 0000000..cd38c91 --- /dev/null +++ b/library/vendor/lessphp/lib/Less/Tree/Alpha.php @@ -0,0 +1,48 @@ +value = $val; + } + + // function accept( $visitor ){ + // $this->value = $visitor->visit( $this->value ); + //} + + public function compile( $env ) { + if ( is_object( $this->value ) ) { + $this->value = $this->value->compile( $env ); + } + + return $this; + } + + /** + * @see Less_Tree::genCSS + */ + public function genCSS( $output ) { + $output->add( "alpha(opacity=" ); + + if ( is_string( $this->value ) ) { + $output->add( $this->value ); + } else { + $this->value->genCSS( $output ); + } + + $output->add( ')' ); + } + + public function toCSS() { + return "alpha(opacity=" . ( is_string( $this->value ) ? $this->value : $this->value->toCSS() ) . ")"; + } + +} -- cgit v1.2.3