mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-03 16:51:40 +09:00
Add unit test for inline styles in template v2
This commit is contained in:
parent
0bc3635b6c
commit
49f57980dd
3 changed files with 12 additions and 0 deletions
|
|
@ -64,3 +64,7 @@
|
|||
const foo = '<?php echo $this->config->context === 'HTML' ? htmlspecialchars($__Context->foo ?? '', \ENT_QUOTES, 'UTF-8', false) : $this->_v2_escape($__Context->foo ?? ''); ?>';
|
||||
const bar = <?php echo $this->config->context === 'JS' ? json_encode($__Context->bar, self::$_json_options2) : htmlspecialchars(json_encode($__Context->bar, self::$_json_options), \ENT_QUOTES, 'UTF-8', false); ?>;
|
||||
<?php $this->config->context = 'HTML'; ?></script>
|
||||
|
||||
<style<?php $this->config->context = 'CSS'; ?>>
|
||||
body { background-color: <?php echo $this->config->context === 'HTML' ? htmlspecialchars('#ffffff', \ENT_QUOTES, 'UTF-8', false) : $this->_v2_escape('#ffffff'); ?>; }
|
||||
<?php $this->config->context = 'HTML'; ?></style>
|
||||
|
|
|
|||
|
|
@ -60,3 +60,7 @@
|
|||
const foo = 'FOOFOO\u003C\u0022FOO\u0022\u003EBAR';
|
||||
const bar = ["Rhy","miX","is","da","BEST!"];
|
||||
</script>
|
||||
|
||||
<style>
|
||||
body { background-color: #ffffff; }
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -64,3 +64,7 @@
|
|||
const foo = '{{ $foo }}';
|
||||
const bar = @json($bar);
|
||||
</script>
|
||||
|
||||
<style>
|
||||
body { background-color: {{ '#ffffff' }}; }
|
||||
</style>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue