area17 / twill

Twill is an open source CMS toolkit for Laravel that helps developers rapidly create a custom admin console that is intuitive, powerful and flexible. Chat with us on Discord at https://discord.gg/cnWk7EFv8R.
https://twillcms.com
Apache License 2.0
3.72k stars 568 forks source link

Input labels are double encoded #2500

Open Tofandel opened 6 months ago

Tofandel commented 6 months ago

Description

image

It seems input labels are double encoded

            Input::make()->name('wrong_hint')
                ->label("A label with a 'single quote'")

Simple fix is to use label: '{!! addslashes($label) !!}', in blade but I don't know if it's the best solution

ifox commented 6 months ago

I can check if that would cause any unexpected issues, but in the meantime I'd suggest you use curly quotes , which is more “correct”: https://practicaltypography.com/straight-and-curly-quotes.html.