diff options
Diffstat (limited to 'examples/webenginewidgets/recipebrowser/assets/pages/cupcakes.html')
-rw-r--r-- | examples/webenginewidgets/recipebrowser/assets/pages/cupcakes.html | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/examples/webenginewidgets/recipebrowser/assets/pages/cupcakes.html b/examples/webenginewidgets/recipebrowser/assets/pages/cupcakes.html new file mode 100644 index 000000000..e8e14a9b6 --- /dev/null +++ b/examples/webenginewidgets/recipebrowser/assets/pages/cupcakes.html @@ -0,0 +1,75 @@ +<!doctype html> +<html lang="en"> +<head> + <meta charset="utf-8"> + <title>Cupcakes</title> + <link rel="stylesheet" type="text/css" href="../3rdparty/markdown.css"> + <link rel="stylesheet" type="text/css" href="../custom.css"> + <script src="../3rdparty/marked.js"></script> + <script src="../custom.js"></script> + <script src="qrc:/qtwebchannel/qwebchannel.js"></script> +</head> +<body> + <div id="placeholder"></div> + <div id="content"> + +<img src="images/cupcakes.jpg" alt="Cupcakes" title="Cupcakes" /> + +Cupcakes +============= + +### Ingredients + +* 300 g caster sugar +* 150 ml sunflower oil +* 1 teaspoon vanilla extract +* 500 g dairy-free soya yoghurt +* 2 teaspoons cider vinegar +* 350 g plain flour +* 1 teaspoon bicarbonate of soda +* 1½ teaspoons baking powder + +#### For the vegan vanilla icing +* 200 g dairy-free soya spread , chilled +* 660 g icing sugar +* ½ teaspoon vanilla extract + +### Instructions +1. Preheat the oven to 170°C fan/375°F/gas 5. +2. Place the sugar, oil and vanilla extract in a large bowl, then beat with an electric mixer for 1 to 2 minutes, until well combined. +3. Mix the yoghurt and vinegar together in a bowl, then add to the mixture and beat for 1 to 2 minutes. +4. Add the remaining cupcake ingredients and 1 teaspoon of fine sea salt, then whisk until smooth and just combined. +5. Fill the paper cases two-thirds full with mixture, but don’t bother to smooth it out. +6. Bake for 20 minutes, or until they spring back when touched. Leave to cool, transferring to a wire cooling rack after 5 minutes. +7. Meanwhile, make the icing. Beat the soya spread with an electric mixer for 1 to 2 minutes, or until smooth. +8. Sift the icing sugar into a large bowl, then add to the soya spread in two stages, beating well between each. +9. Add the vanilla extract and a small splash of water, then whisk for a further few minutes, or until silky smooth – if it’s too stiff, add a splash more water to loosen. +10. Once the cupcakes are cool, decorate them with the icing and add a few sprinkles too if you like – whatever takes your fancy – then enjoy. + +**Enjoy!** + + </div><!--End of content--> + + <script> + 'use strict'; + + var jsContent = document.getElementById('content'); + var placeholder = document.getElementById('placeholder'); + + var updateText = function(text) { + placeholder.innerHTML = marked.parse(text); + } + + new QWebChannel(qt.webChannelTransport, + function(channel) { + var content = channel.objects.content; + content.setInitialText(jsContent.innerHTML); + content.textChanged.connect(updateText); + } + ); + </script> +</body> +</html> + + + |